]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/ChangeLog
Make "break foo" find "A::foo", A::B::foo", etc. [C++ and wild matching]
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
a20714ff
PA
12017-11-29 Pedro Alves <palves@redhat.com>
2
3 * NEWS: Mention that breakpoints on C++ functions are now set on
4 on all namespaces/classes by default, and mention "break
5 -qualified".
6 * ax-gdb.c (agent_command_1): Adjust to pass a
7 symbol_name_match_type to new_linespec_location.
8 * breakpoint.c (parse_breakpoint_sals): Adjust to
9 get_linespec_location's return type change.
10 (strace_marker_create_sals_from_location): Adjust to pass a
11 symbol_name_match_type to new_linespec_location.
12 (strace_marker_decode_location): Adjust to get_linespec_location's
13 return type change.
14 (strace_command): Adjust to pass a symbol_name_match_type to
15 new_linespec_location.
16 (LOCATION_HELP_STRING): Add paragraph about wildmatching, and
17 mention "-qualified".
18 * c-lang.c (cplus_language_defn): Install cp_search_name_hash.
19 * completer.c (explicit_location_match_type::MATCH_QUALIFIED): New
20 enumerator.
21 (complete_address_and_linespec_locations): New parameter
22 'match_type'. Pass it down.
23 (explicit_options): Add "-qualified".
24 (collect_explicit_location_matches): Pass the requested match type
25 to the linespec completers. Handle MATCH_QUALIFIED.
26 (location_completer): Handle "-qualified" combined with linespecs.
27 * cp-support.c (cp_search_name_hash): New.
28 (cp_symbol_name_matches_1): Implement wild matching for C++.
29 (cp_fq_symbol_name_matches): Reimplement.
30 (cp_get_symbol_name_matcher): Return different matchers depending
31 on the lookup name's match type.
32 (selftests::test_cp_symbol_name_matches): Add wild matching tests.
33 * cp-support.h (cp_search_name_hash): New declaration.
34 * dwarf2read.c
35 (selftests::dw2_expand_symtabs_matching::test_symbols): Add
36 symbols.
37 (test_dw2_expand_symtabs_matching_symbol): Add wild matching
38 tests.
39 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Adjust to
40 pass a symbol_name_match_type to new_linespec_location.
41 * linespec.c (linespec_parse_basic): Lookup function symbols using
42 the parser's symbol name match type.
43 (convert_explicit_location_to_linespec): New
44 symbol_name_match_type parameter. Pass it down to
45 find_linespec_symbols.
46 (convert_explicit_location_to_sals): Pass the location's name
47 match type to convert_explicit_location_to_linespec.
48 (parse_linespec): New match_type parameter. Save it in the
49 parser.
50 (linespec_parser_new): Default to symbol_name_match_type::WILD.
51 (linespec_complete_function): New symbol_name_match_type
52 parameter. Use it.
53 (complete_linespec_component): Pass down the parser's recorded
54 name match type.
55 (linespec_complete_label): New symbol_name_match_type parameter.
56 Use it.
57 (linespec_complete): New symbol_name_match_type parameter. Save
58 it in the parser and pass it down. Adjust to
59 get_linespec_location's prototype change.
60 (find_function_symbols, find_linespec_symbols): New
61 symbol_name_match_type parameter. Pass it down instead of
62 assuming symbol_name_match_type::WILD.
63 * linespec.h (linespec_complete, linespec_complete_function)
64 (linespec_complete_label): New symbol_name_match_type parameter.
65 * location.c (event_location::linespec_location): Now a struct
66 linespec_location.
67 (EL_LINESPEC): Adjust.
68 (initialize_explicit_location): Default to
69 symbol_name_match_type::WILD.
70 (new_linespec_location): New symbol_name_match_type parameter.
71 Record it in the location.
72 (get_linespec_location): Now returns a struct linespec_location.
73 (new_explicit_location): Also copy func_name_match_type.
74 (explicit_to_string_internal)
75 (string_to_explicit_location): Handle "-qualified".
76 (copy_event_location): Adjust to LINESPEC_LOCATION type change.
77 Copy symbol_name_match_type fields.
78 (event_location_deleter::operator()): Adjust to LINESPEC_LOCATION
79 type change.
80 (event_location_to_string): Adjust to LINESPEC_LOCATION type
81 change. Handle "-qualfied".
82 (string_to_explicit_location): Handle "-qualified".
83 (string_to_event_location_basic): New symbol_name_match_type
84 parameter. Pass it down.
85 (string_to_event_location): Handle "-qualified".
86 * location.h (struct linespec_location): New.
87 (explicit_location::func_name_match_type): New field.
88 (new_linespec_location): Now returns a const linespec_location *.
89 (string_to_event_location_basic): New symbol_name_match_type
90 parameter.
91 (explicit_completion_info::saw_explicit_location_option): New
92 field.
93 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Adjust to pass a
94 symbol_name_match_type to new_linespec_location.
95 * python/py-breakpoint.c (bppy_init): Likewise.
96 * python/python.c (gdbpy_decode_line): Likewise.
97
a207cff2
PA
982017-11-29 Pedro Alves <palves@redhat.com>
99
100 * ada-lang.c (ada_lookup_name_info::matches): Change type of
101 parameter from completion_match to completion_match_result.
102 Adjust.
103 (do_wild_match, do_full_match, ada_symbol_name_matches): Likewise.
104 * completer.c (completion_tracker::maybe_add_completion): Add
105 match_for_lcd parameter and use it.
106 (completion_tracker::add_completion): Likewise.
107 * completer.h (class completion_match_for_lcd): New class.
108 (completion_match_result::match_for_lcd): New field.
109 (completion_match_result::set_match): New method.
110 (completion_tracker): Add comments.
111 (completion_tracker::add_completion): Add match_for_lcd parameter.
112 (completion_tracker::reset_completion_match_result): Reset
113 match_for_lcd too.
114 (completion_tracker::maybe_add_completion): Add match_for_lcd
115 parameter.
116 (completion_tracker::m_lowest_common_denominator_unique): Extend
117 comments.
118 * cp-support.c (cp_symbol_name_matches_1)
119 (cp_fq_symbol_name_matches): Change type of parameter from
120 completion_match to completion_match_result. Adjust.
121 * language.c (default_symbol_name_matcher): Change type of
122 parameter from completion_match to completion_match_result.
123 Adjust.
124 * language.h (completion_match_for_lcd): Forward declare.
125 (default_symbol_name_matcher): Change type of parameter from
126 completion_match to completion_match_result.
127 * symtab.c (compare_symbol_name): Adjust.
128 (completion_list_add_name): Pass the match_for_lcd to the tracker.
129 * symtab.h (ada_lookup_name_info::matches): Change type of
130 parameter from completion_match to completion_match_result.
131 (symbol_name_matcher_ftype): Likewise, and update comments.
132
4024cf2b
PA
1332017-11-29 Pedro Alves <palves@redhat.com>
134
135 * linespec.c (minsym_found, add_minsym): Use msymbol_is_function.
136 * minsyms.c (msymbol_is_text): Delete.
137 (msymbol_is_function): New function.
138 * minsyms.h (msymbol_is_text): Delete.
139 (msymbol_is_function): New declaration.
140 * symtab.c (find_function_alias_target): Use msymbol_is_function.
141
5dcf52c1
TT
1422017-11-29 Tom Tromey <tom@tromey.com>
143
144 * Makefile.in (distclean): Handle the case where rmdir fails.
145
8ca2f0b9
TT
1462017-11-29 Tom Tromey <tom@tromey.com>
147
148 * symfile.c (_initialize_symfile): Update usage text for
149 add-symbol-file, symbol-file, load.
150
02ca603a
TT
1512017-11-29 Tom Tromey <tom@tromey.com>
152
153 * symfile.c (add_symbol_file_command): Error if some arguments to
154 -s are missing. Change unrecognized-argument error message.
155 (_initialize_symfile): Fix usage text for add-symbol-file.
156
18ca7347
TT
1572017-11-27 Tom Tromey <tom@tromey.com>
158
159 * Makefile.in (REMOTE_OBS): Remove.
160 (SFILES): Remove remote sources.
161 (COMMON_SFILES): Add remote sources.
162 (ALLDEPFILES): Remove dcache.c.
163
66599a7d
TT
1642017-11-27 Tom Tromey <tom@tromey.com>
165
166 * Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
167 variables.
168 (SFILES): Use SUBDIR_TARGET_SRCS.
169 (COMMON_OBS): Use SUBDIR_TARGET_OBS. Remove waitstatus.o.
170 (CONFIG_SRC_SUBDIR): Add target.
171 (%.o): Remove target rule.
172
4f04fba8
TT
1732017-11-27 Tom Tromey <tom@tromey.com>
174
175 * Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
176 registry.o, thread-fsm.o, debug.o.
177 (COMMON_SFILES): Add filename-seen-cache.c, registry.c,
178 thread-fsm.c, debug.c.
179
b5adff3b
TT
1802017-11-27 Tom Tromey <tom@tromey.com>
181
182 * Makefile.in (COMMON_SFILES): New.
183 (SFILES): Move some entries to COMMON_SFILES.
184 (COMMON_OBS): Use COMMON_SFILES.
185
afa0a411
TT
1862017-11-27 Tom Tromey <tom@tromey.com>
187
188 * Makefile.in (YYFILES): Update comment.
189 (YYOBJ): Redefine.
190
8fd8d003
TT
1912017-11-27 Tom Tromey <tom@tromey.com>
192
193 * Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
194 (CONFIG_SRC_SUBDIR): Add python.
195 (%.o): Remove python rule.
196 (python/%.o): New rule.
197 * configure: Rebuild.
198 * configure.ac (CONFIG_OBS): Refer to python/python.o
199
bd810fff
TT
2002017-11-27 Tom Tromey <tom@tromey.com>
201
202 * configure: Rebuild.
203 * configure.ac (CONFIG_OBS): Refer to guile/guile.o.
204 * Makefile.in (SUBDIR_GUILE_OBS): Redefine.
205 (CONFIG_SRC_SUBDIR): Add guile.
206 (%.o): Remove guile rule.
207
75787ac1
TT
2082017-11-27 Tom Tromey <tom@tromey.com>
209
210 * Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
211 (%.o): Remove unittests rule.
212 (CONFIG_SRC_SUBDIR): Add unittests.
213
5c8a9431
TT
2142017-11-27 Tom Tromey <tom@tromey.com>
215
216 * Makefile.in (SUBDIR_TUI_OBS): Redefine.
217 (CONFIG_SRC_SUBDIR): Add tui.
218 (%.o): Remove tui rule.
219
a26aa30c
TT
2202017-11-27 Tom Tromey <tom@tromey.com>
221
222 * Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
223 (%.o): Remove compile rule.
224 (CONFIG_SRC_SUBDIR): Add compile.
225
6f3cdf9a
TT
2262017-11-27 Tom Tromey <tom@tromey.com>
227
228 * Makefile.in (SUBDIR_MI_OBS): Redefine.
229 (%.o): Remove mi rule.
230 (CONFIG_SRC_SUBDIR): Add mi.
231 (COMMON_OBS): Use mi/mi-common.o
232
f06afa53
TT
2332017-11-27 Tom Tromey <tom@tromey.com>
234
235 * Makefile.in (SUBDIR_CLI_OBS): Redefine.
236 (%.o): Remove cli rule.
237 (CONFIG_SRC_SUBDIR): Add cli.
238
b22c88c2
TT
2392017-11-27 Tom Tromey <tom@tromey.com>
240
241 * configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
242 * configure: Rebuild.
243 * Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
244 (CONFIG_DEP_SUBDIR): New variable.
245 (%.o): Add order-only dependency.
246 ($(CONFIG_DEP_SUBDIR)): New target.
247
ee9a09e9
DC
2482017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
249
250 PR gdb/21945
251 * findcmd.c (_initialize_mem_search): Update find command help
252 text.
253
e8e7d10c
SM
2542017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
255
256 * python/python.c (do_start_initialization): Change progname
257 type to gdb::unique_xmalloc_ptr. Release the pointer when using
258 Python 2.
259
6a997029
TT
2602017-11-26 Tom Tromey <tom@tromey.com>
261
262 * common/format.h: Add include guards.
263
41272101
TT
2642017-11-26 Tom Tromey <tom@tromey.com>
265
266 * nat/linux-personality.h (class
267 maybe_disable_address_space_randomization): New class.
268 (maybe_disable_address_space_randomization): Don't declare
269 function.
270 * nat/linux-personality.c (restore_personality)
271 (make_disable_asr_cleanup): Remove.
272 (maybe_disable_address_space_randomization): Now a constructor.
273 (~maybe_disable_address_space_randomization): New destructor.
274 * linux-nat.c (linux_nat_create_inferior): Update.
275
44287fd8
TT
2762017-11-26 Tom Tromey <tom@tromey.com>
277
278 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
279
5ffd2cb7
UW
2802017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
281
282 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
283 "cooked" register. Access only first four bytes of branch target
284 registers.
285
0e5457dc
SDJ
2862017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
287
288 PR gdb/22491
289 * stap-probe.c (relocate_address): New function.
290 (stap_probe::get_relocated_address): Use 'relocate_address'.
291 (stap_probe::set_semaphore): Use 'relocate_address' and pass
292 'm_sem_addr'.
293 (stap_probe::clear_semaphore): Likewise.
294
deeeba55
PA
2952017-11-25 Pedro Alves <palves@redhat.com>
296
297 * dictionary.c: Include "safe-ctype.h".
298 * minsyms.c: Include "safe-ctype.h".
299 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
300
a81aaca0
PA
3012017-11-25 Pedro Alves <palves@redhat.com>
302
303 * completer.c (complete_line_internal_1): Skip spaces until the
304 start of the command.
305
0662b6a7
PA
3062017-11-24 Pedro Alves <palves@redhat.com>
307
308 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
309 cp_fq_symbol_name_matches. Pass language_cplus to
310 strncmp_with_mode.
311 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
312 (selftests::test_cp_symbol_name_cmp): New.
313 (_initialize_cp_support): Register "cp_symbol_name_matches"
314 selftests.
315 * language.c (default_symbol_name_matcher): Pass language_minimal
316 to strncmp_iw_with_mode.
317 * utils.c: Include "cp-support.h" and <algorithm>.
318 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
319 (cp_is_operator): New functions.
320 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
321 skip whitespace in the symbol name when the lookup name doesn't
322 have spaces, and vice versa.
323 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
324 * utils.h (strncmp_iw_with_mode): Add language parameter.
325
e547c119
JB
3262017-11-24 Joel Brobecker <brobecker@adacore.com>
327
328 * ada-lang.c (ada_exception_message_1, ada_exception_message):
329 New functions.
330 (print_it_exception): If available, display the exception
331 message as well.
332 * NEWS: Document new feature.
333
d7fcdff9
UW
3342017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
335
336 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
337
30649c14
PR
3382017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
339
340 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
341 (dtrace_probe::is_enabled, dtrace_probe::enable)
342 (dtrace_probe::disable): Remove keyword 'struct' at for-range
343 variable
344 * probe.c (gen_ui_out_table_header_info)
345 (print_ui_out_not_applicables): Remove keyword 'struct' at
346 for-range variable
347
7696f5c9
AH
3482017-11-24 Alan Hayward <alan.hayward@arm.com>
349
350 * configure.tgt: Add arch/aarch64.o
351
8172f16b
SM
3522017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
353
354 * common/common-utils.h: Include poison.h.
355 (xfree): Remove declaration, add definition with static_assert.
356 * common/common-utils.c (xfree): Remove.
357 * common/poison.h (IsMallocatable): Define.
358 (IsFreeable): Define.
359 (free): Delete for non-freeable types.
360 (xnew): New.
361 (XNEW): Undef and redefine.
362 (xcnew): New.
363 (XCNEW): Undef and redefine.
364 (xdelete): New.
365 (XDELETE): Undef and redefine.
366 (xnewvec): New.
367 (XNEWVEC): Undef and redefine.
368 (xcnewvec): New.
369 (XCNEWVEC): Undef and redefine.
370 (xresizevec): New.
371 (XRESIZEVEC): Undef and redefine.
372 (xdeletevec): New.
373 (XDELETEVEC): Undef and redefine.
374 (xnewvar): New.
375 (XNEWVAR): Undef and redefine.
376 (xcnewvar): New.
377 (XCNEWVAR): Undef and redefine.
378 (xresizevar): New.
379 (XRESIZEVAR): Undef and redefine.
380
7aabaf9d
SM
3812017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
382
383 * gdbthread.h (private_thread_info): Define structure type, add
384 virtual pure destructor.
385 (thread_info) <priv>: Change type to unique_ptr.
386 <private_dtor>: Remove.
387 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
388 (private_thread_info::~private_thread_info): Provide default
389 implementation.
390 (thread_info::~thread_info): Don't call private_dtor nor
391 manually free priv.
392 * aix-thread.c (private_thread_info): Rename to ...
393 (aix_thread_info): ... this.
394 (get_aix_thread_info): New.
395 (sync_threadlists): Adjust.
396 (iter_tid): Adjust.
397 (aix_thread_resume): Adjust.
398 (aix_thread_fetch_registers): Adjust.
399 (aix_thread_store_registers): Adjust.
400 (aix_thread_extra_thread_info): Adjust.
401 * darwin-nat.h (private_thread_info): Rename to ...
402 (darwin_thread_info): ... this.
403 (get_darwin_thread_info): New.
404 * darwin-nat.c (darwin_init_thread_list): Adjust.
405 (darwin_check_new_threads): Adjust.
406 (thread_info_from_private_thread_info): Adjust.
407 * linux-thread-db.c (private_thread_info): Rename to ...
408 (thread_db_thread_info): ... this, initialize fields.
409 (get_thread_db_thread_info): New.
410 <dying>: Change type to bool.
411 (update_thread_state): Adjust to type rename.
412 (record_thread): Adjust to type rename an use of unique_ptr.
413 (thread_db_pid_to_str): Likewise.
414 (thread_db_extra_thread_info): Likewise.
415 (thread_db_thread_handle_to_thread_info): Likewise.
416 (thread_db_get_thread_local_address): Likewise.
417 * nto-tdep.h (private_thread_info): Rename to ...
418 (nto_thread_info): ... this, initialize fields.
419 (get_nto_thread_info): New.
420 <name>: Change type to std::string.
421 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
422 use of unique_ptr.
423 * nto-procfs.c (update_thread_private_data_name): Adjust to
424 std::string change, allocate nto_private_thread_info with new.
425 (update_thread_private_data): Adjust to unique_ptr.
426 * remote.c (private_thread_info): Rename to ...
427 (remote_thread_info): ... this, initialize data members with
428 default values.
429 <extra, name>: Change type to std::string.
430 <thread_handle>: Change type to non-pointer.
431 (free_private_thread_info): Remove.
432 (get_private_info_thread): Rename to...
433 (get_remote_thread_info): ... this, change return type, adjust to
434 use of unique_ptr, use remote_thread_info constructor.
435 (remote_add_thread): Adjust.
436 (get_private_info_ptid): Rename to...
437 (get_remote_thread_info): ...this, change return type.
438 (remote_thread_name): Use get_remote_thread_info, adjust to
439 change to std::string.
440 (struct thread_item) <~thread_item>: Remove.
441 <thread_handle>: Make non pointer.
442 (start_thread): Adjust to thread_item::thread_handle type
443 change.
444 (remote_update_thread_list): Adjust to type name change, move
445 strings from temporary to long-lived object instead of
446 duplicating.
447 (remote_threads_extra_info): Use get_remote_thread_info.
448 (process_initial_stop_replies): Likewise.
449 (resume_clear_thread_private_info): Likewise.
450 (remote_resume): Adjust to type name change.
451 (remote_commit_resume): Use get_remote_thread_info.
452 (process_stop_reply): Adjust to type name change.
453 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
454 (remote_stopped_by_hw_breakpoint): Likewise.
455 (remote_stopped_by_watchpoint): Likewise.
456 (remote_stopped_data_address): Likewise.
457 (remote_core_of_thread): Likewise.
458 (remote_thread_handle_to_thread_info): Use
459 get_private_info_thread, adjust to thread_handle field type
460 change.
461
21fe1c75
SM
4622017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
463
464 * remote.c (struct thread_item): Add constructor, disable copy
465 construction and copy assignment, define default move
466 construction and move assignment.
467 <extra, name>: Change type to std::string.
468 <core>: Initialize.
469 <thread_handle>: Make non-pointer.
470 (thread_item_t): Remove typedef.
471 (DEF_VEC_O(thread_item_t)): Remove.
472 (threads_listing_context) <contains_thread>: New method.
473 <remove_thread>: New method.
474 <items>: Change type to std::vector.
475 (clear_threads_listing_context): Remove.
476 (threads_listing_context_remove): Remove.
477 (remote_newthread_step): Use thread_item constructor, adjust to
478 change to std::vector.
479 (start_thread): Use thread_item constructor, adjust to change to
480 std::vector.
481 (end_thread): Adjust to change to std::vector and std::string.
482 (remote_get_threads_with_qthreadinfo): Use thread_item
483 constructor, adjust to std::vector.
484 (remote_update_thread_list): Adjust to change to std::vector and
485 std::string, use threads_listing_context methods.
486 (remove_child_of_pending_fork): Adjust.
487 (remove_new_fork_children): Adjust.
488 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
489 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
490 * unittests/rsp-low-selftests.c: New file.
491 * common/rsp-low.h: Include common/byte-vector.h.
492 (hex2bin): New overload.
493 * common/rsp-low.c (hex2bin): New overload.
494
089354bb
SM
4952017-11-24 Simon Marchi <simon.marchi@ericsson.com>
496
497 * inferior.h (private_inferior): Define structure type, add
498 virtual pure destructor.
499 (inferior) <priv>: Change type to unique_ptr.
500 * inferior.c (private_inferior::~private_inferior): Provide
501 default implementation.
502 (inferior::~inferior): Don't free priv field.
503 (exit_inferior_1): Likewise.
504 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
505 (darwin_exception_info): Remove typedef.
506 (DEF_VEC_O (darwin_thread_t)); Remove.
507 (private_inferior): Rename to ...
508 (darwin_private_inferior): ... this, extend private_inferior.
509 (get_darwin_inferior): New.
510 <threads>: Change type to std::vector of darwin_thread_t pointers.
511 * darwin-nat.c (darwin_check_new_threads): Adjust.
512 (find_inferior_task_it): Adjust.
513 (darwin_find_thread); Adjust.
514 (darwin_suspend_inferior): Adjust.
515 (darwin_resume_inferior): Adjust.
516 (darwin_find_new_inferior): Adjust.
517 (darwin_decode_notify_message): Adjust.
518 (darwin_send_reply): Adjust.
519 (darwin_resume_inferior_threads): Adjust.
520 (darwin_suspend_inferior_threads): Adjust.
521 (darwin_decode_message): Adjust.
522 (darwin_wait): Adjust.
523 (darwin_interrupt): Adjust.
524 (darwin_deallocate_threads): Adjust.
525 (darwin_mourn_inferior): Adjust, don't free private data.
526 (darwin_reply_to_all_pending_messages): Adjust.
527 (darwin_stop_inferior): Adjust.
528 (darwin_setup_exceptions): Adjust.
529 (darwin_kill_inferior): Adjust.
530 (darwin_setup_request_notification): Adjust.
531 (darwin_attach_pid): Adjust.
532 (darwin_init_thread_list): Adjust.
533 (darwin_setup_fake_stop_event): Adjust.
534 (darwin_attach): Adjust.
535 (darwin_detach): Adjust.
536 (darwin_xfer_partial): Adjust.
537 (set_enable_mach_exceptions): Adjust.
538 (darwin_pid_to_exec_file): Adjust.
539 (darwin_get_ada_task_ptid): Adjust.
540 * darwin-nat-info.c (get_task_from_args): Adjust.
541 (info_mach_ports_command): Adjust.
542 (info_mach_region_command): Adjust.
543 (info_mach_exceptions_command): Adjust.
544 * remote.c (private_inferior): Rename to ...
545 (remote_private_inferior): ... this, initialize fields.
546 (get_remote_inferior); New.
547 (remote_commit_resume): Use get_remote_inferior.
548 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
549
d044bac8
PA
5502017-11-24 Pedro Alves <palves@redhat.com>
551
552 * NEWS: Mention linespecs and explicit locations, and completion
553 improvements.
554
e8d58cba
YQ
5552017-11-24 Yao Qi <yao.qi@linaro.org>
556
557 * regcache.c (regcache::dump): Remove footnote_register_size.
558
a63f2d2f
YQ
5592017-11-24 Yao Qi <yao.qi@linaro.org>
560
561 * regcache.c (cooked_read_test): Add more test for readonly
562 regcache.
563
1b30aaa5
YQ
5642017-11-24 Yao Qi <yao.qi@linaro.org>
565
566 * gdbarch-selftests.c (test_target_has_registers): Move it to
567 target.c.
568 (test_target_has_stack): Likewise.
569 (test_target_has_memory): Likewise.
570 (test_target_prepare_to_store): Likewise.
571 (test_target_store_registers): Likewise.
572 (test_target_ops): Likewise.
573 * regcache.c: Include selftest-arch.h and gdbthread.h.
574 (target_ops_no_register): New class.
575 (test_target_fetch_registers): New.
576 (test_target_store_registers): New.
577 (test_target_xfer_partial): New.
578 (readwrite_regcache): New.
579 (cooked_read_test): New.
580 (_initialize_regcache): Register the test.
581 * target.c: (test_target_has_registers): Moved from
582 gdbarch-selftests.c.
583 (test_target_has_stack): Likewise.
584 (test_target_has_memory): Likewise.
585 (test_target_prepare_to_store): Likewise.
586 (test_target_store_registers): Likewise.
587 * target.h (test_target_ops): New class.
588
6654d750
AH
5892017-11-24 Alan Hayward <alan.hayward@arm.com>
590
591 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
592 selftest.
593
49bdb7ee
AH
5942017-11-24 Alan Hayward <alan.hayward@arm.com>
595
596 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
597 * arch/aarch64.c (aarch64_create_target_description): Create
598 new target description.
599 * features/Makefile: Add new files.
600 * features/aarch64.c: Remove file.
601 * features/aarch64-core.c: New autogenerated file.
602 * features/aarch64-fpu.c: New autogenerated file.
603 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
da434ccb
AH
604
6052017-11-24 Alan Hayward <alan.hayward@arm.com>
606
607 * Makefile.in: Add new files.
608 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
609 aarch64_read_description.
610 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
611 Call aarch64_read_description.
612 * aarch64-tdep.c (aarch64_read_description): New function.
613 (aarch64_gdbarch_init): Call aarch64_read_description.
614 * aarch64-tdep.h (aarch64_read_description): New function.
615 * arch/aarch64.c: New file.
616 * configure.tgt: Add new files.
617
98ead37e
YQ
6182017-11-24 Yao Qi <yao.qi@linaro.org>
619
620 * mi/mi-main.c (register_changed_p): Update.
621 * value.c (value_contents_bits_eq): Change return type.
622 (value_contents_eq): Likewise.
623 * value.h: Update comments.
624
62ad7ce7
YQ
6252017-11-24 Yao Qi <yao.qi@linaro.org>
626
627 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
628 local 'changed'. Remove error.
629 (register_changed_p): Change return type to bool.
630
506fe5f4
YQ
6312017-11-24 Yao Qi <yao.qi@linaro.org>
632
633 * arch/tic6x.c: New file.
634 * arch/tic6x.h: New file.
635 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
636 tic6x-core.xml and tic6x-gp.xml.
637 * features/tic6x-c6xp.c: Generated.
638 * features/tic6x-core.c: Generated.
639 * features/tic6x-gp.c: Generated.
640 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
641 "tic6x-".
642
00ea2e2a
SM
6432017-11-23 Simon Marchi <simon.marchi@ericsson.com>
644
645 * mi/mi-main.c (list_available_thread_groups): Change map value
646 type to std::vector.
647
f45e2a77
SM
6482017-11-23 Simon Marchi <simon.marchi@ericsson.com>
649
650 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
651
bd046f64
SM
6522017-11-23 Simon Marchi <simon.marchi@ericsson.com>
653
654 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
655 back to...
656 <children_requested>: ... this.
657 (varobj_get_num_children, varobj_update): Adjust.
658
4c37490d
SM
6592017-11-23 Simon Marchi <simon.marchi@ericsson.com>
660
661 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
662 (ada_value_has_mutated): Likewise.
663 * c-varobj.c (varobj_is_anonymous_child): Likewise.
664 (c_is_path_expr_parent): Likewise.
665 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
666 (mi_cmd_var_set_frozen): Likewise.
667 (mi_cmd_var_update_iter): Likewise.
668 (mi_cmd_var_update): Likewise.
669 * varobj.c (pretty_printing): Likewise.
670 (varobj_enable_pretty_printing): Likewise.
671 (struct varobj_root) <floating, is_valid>: Likewise.
672 (struct varobj_dynamic) <children_requested>: Likewise.
673 (delete_variable): Likewise.
674 (delete_variable_1): Likewise.
675 (install_variable): Likewise.
676 (update_type_if_necessary): Likewise.
677 (install_new_value): Likewise.
678 (value_of_root): Likewise.
679 (is_root_p): Likewise.
680 (varobj_create): Likewise.
681 (varobj_delete): Likewise.
682 (varobj_has_more): Likewise.
683 (varobj_set_frozen): Likewise.
684 (varobj_get_frozen): Likewise.
685 (install_dynamic_child): Likewise.
686 (dynamic_varobj_has_child_method): Likewise.
687 (update_dynamic_varobj_children): Likewise.
688 (varobj_get_num_children): Likewise.
689 (varobj_list_children): Likewise.
690 (is_path_expr_parent): Likewise.
691 (varobj_default_is_path_expr_parent): Likewise.
692 (varobj_is_dynamic_p): Likewise.
693 (varobj_set_value): Likewise.
694 (varobj_value_has_mutated): Likewise.
695 (varobj_update): Likewise.
696 (check_scope): Likewise.
697 (value_of_root_1): Likewise.
698 (varobj_value_get_print_value): Likewise.
699 (varobj_editable_p): Likewise.
700 (varobj_value_is_changeable_p): Likewise.
701 (varobj_floating_p): Likewise.
702 (varobj_default_value_is_changeable_p): Likewise.
703 (varobj_invalidate_iter): Likewise.
704 * varobj.h (struct varobj_update_result) <type_changed,
705 children_changed, changed, value_installed>: Likewise.
706 (struct varobj) <updated, frozen, not_fetched>: Likewise.
707 (struct lang_varobj_ops) <value_is_changeable_p,
708 value_has_mutated, is_path_expr_parent>: Likewise.
709 (varobj_delete): Likewise.
710 (varobj_set_frozen): Likewise.
711 (varobj_get_frozen): Likewise.
712 (varobj_set_value): Likewise.
713 (varobj_update): Likewise.
714 (varobj_editable_p): Likewise.
715 (varobj_floating_p): Likewise.
716 (varobj_has_more): Likewise.
717 (varobj_is_dynamic_p): Likewise.
718 (varobj_default_value_is_changeable_p): Likewise.
719 (varobj_value_is_changeable_p): Likewise.
720 (varobj_is_anonymous_child): Likewise.
721 (varobj_default_is_path_expr_parent): Likewise.
722
9c23b42f
SDJ
7232017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
724
725 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
726 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
727 <type_str>: Convert to 'std::string'.
728 <expr>: Convert to 'expression_up'.
729 (dtrace_probe_arg_s): Delete type and VEC.
730 (dtrace_probe_enabler_s): Likewise.
731 (struct dtrace_probe): Replace by...
732 (class dtrace_static_probe_ops): ...this and...
733 (class dtrace_probe): ...this.
734 (dtrace_probe_is_linespec): Rename to...
735 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
736 to reflect change.
737 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
738 Adjust code. Create new instance of 'dtrace_probe'.
739 (dtrace_build_arg_exprs): Rename to...
740 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
741 reflect change.
742 (dtrace_get_probes): Rename to...
743 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
744 to reflect change.
745 (dtrace_get_arg): Rename to...
746 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
747 reflect change.
748 (dtrace_probe_is_enabled): Rename to...
749 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
750 change.
751 (dtrace_get_probe_address): Rename to...
752 (dtrace_probe::get_relocated_address): ...this. Adjust code
753 to reflect change.
754 (dtrace_get_probe_argument_count): Rename to...
755 (dtrace_probe::get_argument_count): ...this. Adjust code to
756 reflect change.
757 (dtrace_can_evaluate_probe_arguments): Rename to...
758 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
759 to reflect change.
760 (dtrace_evaluate_probe_argument): Rename to...
761 (dtrace_probe::evaluate_argument): ...this. Adjust code to
762 reflect change.
763 (dtrace_compile_to_ax): Rename to...
764 (dtrace_probe::compile_to_ax): ...this. Adjust code to
765 reflect change.
766 (dtrace_probe_destroy): Delete.
767 (dtrace_type_name): Rename to...
768 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
769 reflect change.
770 (dtrace_probe::get_static_ops): New method.
771 (dtrace_gen_info_probes_table_header): Rename to...
772 (dtrace_static_probe_ops::gen_info_probes_table_header):
773 ...this. Adjust code to reflect change.
774 (dtrace_gen_info_probes_table_values): Rename to...
775 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
776 code to reflect change.
777 (dtrace_enable_probe): Rename to...
778 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
779 change.
780 (dtrace_disable_probe): Rename to...
781 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
782 change.
783 (struct probe_ops dtrace_probe_ops): Delete.
784 (info_probes_dtrace_command): Call 'info_probes_for_spops'
785 instead of 'info_probes_for_ops'.
786 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
787 of 'all_probe_ops'.
788
0e9ae10f
SDJ
7892017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
790 Simon Marchi <simark@simark.ca>
791
792 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
793 variable.
794 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
795 <aexpr>: Change type to 'expression_up'.
796 (stap_probe_arg_s): Delete type and VEC.
797 (struct stap_probe): Delete. Replace by...
798 (class stap_static_probe_ops): ...this and...
799 (class stap_probe): ...this. Rename variables to add 'm_'
800 prefix. Do not use 'union' for arguments anymore.
801 (stap_get_expected_argument_type): Receive probe name instead
802 of 'struct stap_probe'. Adjust code.
803 (stap_parse_probe_arguments): Rename to...
804 (stap_probe::parse_arguments): ...this. Adjust code to
805 reflect change.
806 (stap_get_probe_address): Rename to...
807 (stap_probe::get_relocated_address): ...this. Adjust code
808 to reflect change.
809 (stap_get_probe_argument_count): Rename to...
810 (stap_probe::get_argument_count): ...this. Adjust code
811 to reflect change.
812 (stap_get_arg): Rename to...
813 (stap_probe::get_arg_by_number'): ...this. Adjust code to
814 reflect change.
815 (can_evaluate_probe_arguments): Rename to...
816 (stap_probe::can_evaluate_arguments): ...this. Adjust code
817 to reflect change.
818 (stap_evaluate_probe_argument): Rename to...
819 (stap_probe::evaluate_argument): ...this. Adjust code
820 to reflect change.
821 (stap_compile_to_ax): Rename to...
822 (stap_probe::compile_to_ax): ...this. Adjust code to
823 reflect change.
824 (stap_probe_destroy): Delete.
825 (stap_modify_semaphore): Adjust comment.
826 (stap_set_semaphore): Rename to...
827 (stap_probe::set_semaphore): ...this. Adjust code to reflect
828 change.
829 (stap_clear_semaphore): Rename to...
830 (stap_probe::clear_semaphore): ...this. Adjust code to
831 reflect change.
832 (stap_probe::get_static_ops): New method.
833 (handle_stap_probe): Adjust code to create instance of
834 'stap_probe'.
835 (stap_get_probes): Rename to...
836 (stap_static_probe_ops::get_probes): ...this. Adjust code to
837 reflect change.
838 (stap_probe_is_linespec): Rename to...
839 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
840 reflect change.
841 (stap_type_name): Rename to...
842 (stap_static_probe_ops::type_name): ...this. Adjust code to
843 reflect change.
844 (stap_gen_info_probes_table_header): Rename to...
845 (stap_static_probe_ops::gen_info_probes_table_header):
846 ...this. Adjust code to reflect change.
847 (stap_gen_info_probes_table_values): Rename to...
848 (stap_probe::gen_info_probes_table_values): ...this. Adjust
849 code to reflect change.
850 (struct probe_ops stap_probe_ops): Delete.
851 (info_probes_stap_command): Use 'info_probes_for_spops'
852 instead of 'info_probes_for_ops'.
853 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
854 of 'all_probe_ops'.
855
935676c9
SDJ
8562017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
857
858 * break-catch-throw.c (fetch_probe_arguments): Use
859 'probe.prob' instead of 'probe.probe'.
860 * breakpoint.c (create_longjmp_master_breakpoint): Call
861 'can_evaluate_arguments' and 'get_relocated_address' methods
862 from probe.
863 (create_exception_master_breakpoint): Likewise.
864 (add_location_to_breakpoint): Use 'sal->prob' instead of
865 'sal->probe'.
866 (bkpt_probe_insert_location): Call 'set_semaphore' method from
867 probe.
868 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
869 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
870 of 'probe_ops'.
871 (probe_key_free): Call 'delete' on probe.
872 (check_exception_resume): Use 'probe.prob' instead of
873 'probe.probe'.
874 * location.c (string_to_event_location_basic): Call
875 'probe_linespec_to_static_ops'.
876 * probe.c (class any_static_probe_ops): New class.
877 (any_static_probe_ops any_static_probe_ops): New variable.
878 (parse_probes_in_pspace): Receive 'static_probe_ops' as
879 argument. Adjust code to reflect change.
880 (parse_probes): Use 'static_probe_ops' instead of
881 'probe_ops'. Adjust code to reflect change.
882 (find_probes_in_objfile): Call methods to get name and
883 provider from probe.
884 (find_probe_by_pc): Use 'result.prob' instead of
885 'result.probe'. Call 'get_relocated_address' method from
886 probe.
887 (collect_probes): Adjust comment and argument list to receive
888 'static_probe_ops' instead of 'probe_ops'. Adjust code to
889 reflect change. Call necessary methods from probe.
890 (compare_probes): Call methods to get name and provider from
891 probes.
892 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
893 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
894 adjust code accordingly.
895 (print_ui_out_not_applicables): Likewise.
896 (info_probes_for_ops): Rename to...
897 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
898 as argument instead of 'probe_ops'. Adjust code. Call
899 necessary methods from probe.
900 (info_probes_command): Use 'info_probes_for_spops'.
901 (enable_probes_command): Pass correct argument to
902 'collect_probes'. Call methods from probe.
903 (disable_probes_command): Likewise.
904 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
905 (get_probe_argument_count): Move to
906 'any_static_probe_ops::get_argument_count'.
907 (can_evaluate_probe_arguments): Move to
908 'any_static_probe_ops::can_evaluate_arguments'.
909 (evaluate_probe_argument): Move to
910 'any_static_probe_ops::evaluate_argument'.
911 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
912 'probe.probe'.
913 (probe_linespec_to_ops): Rename to...
914 (probe_linespec_to_static_ops): ...this. Adjust code.
915 (probe_any_is_linespec): Rename to...
916 (any_static_probe_ops::is_linespec): ...this.
917 (probe_any_get_probes): Rename to...
918 (any_static_probe_ops::get_probes): ...this.
919 (any_static_probe_ops::type_name): New method.
920 (any_static_probe_ops::gen_info_probes_table_header): New
921 method.
922 (compute_probe_arg): Use 'pc_probe.prob' instead of
923 'pc_probe.probe'. Call methods from probe.
924 (compile_probe_arg): Likewise.
925 (std::vector<const probe_ops *> all_probe_ops): Delete.
926 (std::vector<const static_probe_ops *> all_static_probe_ops):
927 New variable.
928 (_initialize_probe): Use 'all_static_probe_ops' instead of
929 'all_probe_ops'.
930 * probe.h (struct info_probe_column) <field_name>: Delete
931 extraneous newline
932 (info_probe_column_s): Delete type and VEC.
933 (struct probe_ops): Delete. Replace with...
934 (class static_probe_ops): ...this and...
935 (clas probe): ...this.
936 (struct bound_probe) <bound_probe>: Delete extraneous
937 newline. Adjust constructor to receive 'probe' instead of
938 'struct probe'.
939 <probe>: Rename to...
940 <prob>: ...this. Delete extraneous newline.
941 <objfile>: Delete extraneous newline.
942 (register_probe_ops): Delete unused prototype.
943 (info_probes_for_ops): Rename to...
944 (info_probes_for_spops): ...this. Adjust comment.
945 (get_probe_address): Move to 'probe::get_address'.
946 (get_probe_argument_count): Move to
947 'probe::get_argument_count'.
948 (can_evaluate_probe_arguments): Move to
949 'probe::can_evaluate_arguments'.
950 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
951 * solib-svr4.c (struct svr4_info): Adjust comment.
952 (struct probe_and_action) <probe>: Rename to...
953 <prob>: ...this.
954 (register_solib_event_probe): Receive 'probe' instead of
955 'struct probe' as argument. Use 'prob' instead of 'probe'
956 when applicable.
957 (solib_event_probe_action): Call 'get_argument_count' method
958 from probe. Adjust comment.
959 (svr4_handle_solib_event): Adjust comment. Call
960 'evaluate_argument' method from probe.
961 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
962 from probe.
963 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
964 'struct probe'. Call 'can_evaluate_arguments' from probe.
965 * symfile.h: Forward declare 'class probe' instead of 'struct
966 probe'.
967 * symtab.h: Likewise.
968 (struct symtab_and_line) <probe>: Rename to...
969 <prob>: ...this.
970 * tracepoint.c (start_tracing): Use 'prob' when applicable.
971 Call probe methods.
972 (stop_tracing): Likewise.
973
8f6cb6c3
JB
9742017-11-22 Joel Brobecker <brobecker@adacore.com>
975
976 * ravenscar-thread.c (ravenscar_inferior_created): Remove
977 trailing newline at end of string in call to warning.
978
479f8de1
SM
9792017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
980
981 * osdata.h: Include vector isntead of vec.h.
982 (osdata_column_s): Remove typedef.
983 (struct osdata_column): Add constructor.
984 <name, value>: Change type to std::string.
985 (DEF_VEC_O (osdata_column_s)): Remove.
986 (osdata_item_s): Remove typedef.
987 (struct osdata_item) <columns>: Change type to std::vector.
988 (DEF_VEC_O (osdata_item_s)): Remove.
989 (struct osdata): Add constructor.
990 <type>: Change type to std::string.
991 <items>: Change type to std::vector.
992 (osdata_p): Remove typedef.
993 (DEF_VEC_P (osdata_p)): Remove.
994 (osdata_parse): Return a unique_ptr.
995 (osdata_free): Remove.
996 (make_cleanup_osdata_free): Remove.
997 (get_osdata): Return a unique_ptr.
998 (get_osdata_column): Return pointer to std::string, take a
999 reference to osdata_item as parameter.
1000 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
1001 unique_ptr.
1002 <property_name>: Change type to std::string.
1003 (osdata_start_osdata): Allocate osdata with new and adjust.
1004 (osdata_start_item): Adjust.
1005 (osdata_start_column): Adjust.
1006 (osdata_end_column): Adjust.
1007 (clear_parsing_data): Remove.
1008 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
1009 (osdata_item_clear): Remove.
1010 (get_osdata): return a unique_ptr and adjust.
1011 (get_osdata_column): Return a pointer to std::string and adjust.
1012 (info_osdata): Adjust.
1013 * mi/mi-main.c: Include <map>.
1014 (free_vector_of_osdata_items): Remove.
1015 (list_available_thread_groups): Adjust, use std::map instead of
1016 splay tree.
1017
41bd68f5
SM
10182017-11-22 Simon Marchi <simon.marchi@ericsson.com>
1019
1020 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
1021 case in switch.
1022
7e2fd2f4
SM
10232017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1024
1025 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
1026
0604393c
SM
10272017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1028
1029 * varobj.h (struct varobj_update_result): Add constructor, add
1030 move constructor, disable copy and assign, initialize fields.
1031 <newobj>: Change type to std::vector.
1032 (varobj_update): Return std::vector.
1033 * varobj.c (install_dynamic_child): Change VEC parameters to
1034 std::vector and adjust.
1035 (update_dynamic_varobj_children): Likewise.
1036 (varobj_update): Return std::vector and adjust.
1037 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
1038
ddf0ea08
SM
10392017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1040
1041 * varobj.h (struct varobj) <parent>: Remove const.
1042 <children>: Change type to std::vector.
1043 (varobj_list_children): Return std::vector const reference.
1044 (varobj_restrict_range): Change parameter type to std::vector
1045 const reference.
1046 * varobj.c (varobj_has_more): Adjust.
1047 (varobj_restrict_range): Change parameter type to std::vector
1048 const reference and adjust.
1049 (install_dynamic_child): Adjust.
1050 (update_dynamic_varobj_children): Adjust.
1051 (varobj_list_children): Return std::vector const reference and
1052 adjust.
1053 (varobj_add_child): Adjust.
1054 (update_type_if_necessary): Adjust.
1055 (varobj_update): Adjust.
1056 (delete_variable_1): Adjust.
1057 * ada-varobj.c (ada_value_has_mutated): Adjust.
1058 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
1059
9e5b9d2b
SM
10602017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1061
1062 * varobj.h (struct varobj): Add constructor and destructor,
1063 initialize fields.
1064 * varobj.c (struct varobj_root): Initialize fields.
1065 (struct varobj_dynamic): Initialize fields.
1066 (varobj_create): Use unique_ptr instead of cleanup. Create
1067 varobj with new instead of new_root_variable.
1068 (delete_variable_1): Free variable with delete instead of
1069 free_variable.
1070 (create_child_with_value): Create variable with new instead of
1071 new_variable.
1072 (varobj::varobj): New.
1073 (varobj::~varobj): New (body mostly coming from free_variable).
1074 (new_variable): Remove.
1075 (free_variable): Remove.
1076 (do_free_variable_cleanup): Remove.
1077 (make_cleanup_free_variable): Remove.
1078
fc35dab1
UW
10792017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1080
1081 * core-regset.c: Remove file.
1082 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
1083
2400729e
UW
10842017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1085
1086 * NEWS: Document use of GNU MPFR.
1087 * README: Likewise.
1088
1089 * Makefile.in (LIBMPFR): Add define.
1090 (CLIBS): Add $(LIBMPFR).
1091 * configure.ac: Add --with-mpfr configure option.
1092 * configure: Regenerate.
1093 * config.in: Regenerate.
1094
1095 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
1096 (class mpfr_float_ops): New type.
1097 (mpfr_float_ops::from_target): Two new overloaded functions.
1098 (mpfr_float_ops::to_target): Likewise.
1099 (mpfr_float_ops::to_string): New function.
1100 (mpfr_float_ops::from_string): Likewise.
1101 (mpfr_float_ops::to_longest): Likewise.
1102 (mpfr_float_ops::from_longest): Likewise.
1103 (mpfr_float_ops::from_ulongest): Likewise.
1104 (mpfr_float_ops::to_host_double): Likewise.
1105 (mpfr_float_ops::from_host_double): Likewise.
1106 (mpfr_float_ops::convert): Likewise.
1107 (mpfr_float_ops::binop): Likewise.
1108 (mpfr_float_ops::compare): Likewise.
1109 (get_target_float_ops): Use mpfr_float_ops if available.
1110
7a26362d
UW
11112017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1112
1113 * target-float.c: Do not include <math.h>.
1114 Include <cmath> and <limits>.
1115 (DOUBLEST): Do not define.
1116 (class target_float_ops): New type.
1117 (class host_float_ops): New templated type.
1118 (class decimal_float_ops): New type.
1119
1120 (floatformat_to_doublest): Rename to ...
1121 (host_float_ops<T>::from_target): ... this. Use template type T
1122 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
1123 (host_float_ops<T>::from_target): New overload using a type argument.
1124 (floatformat_from_doublest): Rename to ...
1125 (host_float_ops<T>::to_target): ... this. Use template type T
1126 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
1127 (host_float_ops<T>::to_target): New overload using a type argument.
1128 (floatformat_printf_format): New function.
1129 (struct printf_length_modifier): New templated type.
1130 (floatformat_to_string): Rename to ...
1131 (host_float_ops<T>::to_string): ... this. Use type instead of
1132 floatformat argument. Use floatformat_printf_format and
1133 printf_length_modifier. Remove special handling of invalid numbers,
1134 infinities and NaN (moved to target_float_to_string).
1135 (struct scanf_length_modifier): New templated type.
1136 (floatformat_from_string): Rename to ...
1137 (host_float_ops<T>::from_string): ... this. Use type instead of
1138 floatformat argument. Use scanf_length_modifier.
1139 (floatformat_to_longest): Rename to ...
1140 (host_float_ops<T>::to_longest): ... this. Use type instead of
1141 floatformat argument. Handle out-of-range values deterministically.
1142 (floatformat_from_longest): Rename to ...
1143 (host_float_ops<T>::from_longest): ... this. Use type instead of
1144 floatformat argument.
1145 (floatformat_from_ulongest): Rename to ...
1146 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
1147 floatformat argument.
1148 (floatformat_to_host_double): Rename to ...
1149 (host_float_ops<T>::to_host_double): ... this. Use type instead of
1150 floatformat argument.
1151 (floatformat_from_host_double): Rename to ...
1152 (host_float_ops<T>::from_host_double): ... this. Use type instead of
1153 floatformat argument.
1154 (floatformat_convert): Rename to ...
1155 (host_float_ops<T>::convert): ... this. Use type instead of
1156 floatformat arguments. Remove handling of no-op conversions.
1157 (floatformat_binop): Rename to ...
1158 (host_float_ops<T>::binop): ... this. Use type instead of
1159 floatformat arguments.
1160 (floatformat_compare): Rename to ...
1161 (host_float_ops<T>::compare): ... this. Use type instead of
1162 floatformat arguments.
1163
1164 (match_endianness): Use type instead of length/byte_order arguments.
1165 (set_decnumber_context): Likewise.
1166 (decimal_from_number): Likewise. Update calls.
1167 (decimal_to_number): Likewise.
1168 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
1169 (decimal_float_ops::to_host_double): New dummy function.
1170 (decimal_float_ops::from_host_double): Likewise.
1171 (decimal_to_string): Rename to ...
1172 (decimal_float_ops::to_string): ... this. Use type instead of
1173 length/byte_order arguments. Update calls.
1174 (decimal_from_string): Rename to ...
1175 (decimal_float_ops::from_string): ... this. Use type instead of
1176 length/byte_order arguments. Update calls.
1177 (decimal_from_longest): Rename to ...
1178 (decimal_float_ops::from_longest): ... this. Use type instead of
1179 length/byte_order arguments. Update calls.
1180 (decimal_from_ulongest): Rename to ...
1181 (decimal_float_ops::from_ulongest): ... this. Use type instead of
1182 length/byte_order arguments. Update calls.
1183 (decimal_to_longest): Rename to ...
1184 (decimal_float_ops::to_longest): ... this. Use type instead of
1185 length/byte_order arguments. Update calls.
1186 (decimal_binop): Rename to ...
1187 (decimal_float_ops::binop): ... this. Use type instead of
1188 length/byte_order arguments. Update calls.
1189 (decimal_compare): Rename to ...
1190 (decimal_float_ops::compare): ... this. Use type instead of
1191 length/byte_order arguments. Update calls.
1192 (decimal_convert): Rename to ...
1193 (decimal_float_ops::convert): ... this. Use type instead of
1194 length/byte_order arguments. Update calls.
1195
1196 (target_float_same_category_p): New function.
1197 (target_float_same_format_p): Likewise.
1198 (target_float_format_length): Likewise.
1199 (enum target_float_ops_kind): New type.
1200 (get_target_float_ops_kind): New function.
1201 (get_target_float_ops): Three new overloaded functions.
1202
1203 (target_float_is_zero): Update call.
1204 (target_float_to_string): Add special handling of invalid numbers,
1205 infinities and NaN (moved from floatformat_to_string). Use
1206 target_float_ops callback.
1207 (target_float_from_string): Use target_float_ops callback.
1208 (target_float_to_longest): Likewise.
1209 (target_float_from_longest): Likewise.
1210 (target_float_from_ulongest): Likewise.
1211 (target_float_to_host_double): Likewise.
1212 (target_float_from_host_double): Likewise.
1213 (target_float_convert): Add special case for no-op conversions.
1214 Use target_float_ops callback.
1215 (target_float_binop): Use target_float_ops callback.
1216 (target_float_compare): Likewise.
1217
a9f26f60
YQ
12182017-11-22 Yao Qi <yao.qi@linaro.org>
1219
1220 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
1221
29f9a567
YQ
12222017-11-22 Yao Qi <yao.qi@linaro.org>
1223
1224 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
1225 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
1226
3b1b69bf
JG
12272017-11-21 Jerome Guitton <guitton@adacore.com>
1228
1229 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
1230 with event ptid from the lower layer before doing the
1231 ravenscar-specific update.
1232
54aa6c67
JB
12332017-11-21 Joel Brobecker <brobecker@adacore.com>
1234
1235 * ravenscar-thread.c (is_ravenscar_task): Also verify that
1236 the ptid's TID is nonzero.
1237
cf3fbed4
JB
12382017-11-21 Joel Brobecker <brobecker@adacore.com>
1239
1240 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
1241 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
1242 Make non-static. Change return type to char *. Adjust code
1243 accordingly. Rewrite the function's documentation.
1244 (read_atcb): Adjust call to get_tcb_types_info accordingly.
1245 * ravenscar-thread.c (ravenscar_inferior_created): Check that
1246 we have enough debugging information in the runtime to support
1247 Ada task debugging before we enable the ravenscar-thread layer.
1248
9edcc12f
JB
12492017-11-21 Joel Brobecker <brobecker@adacore.com>
1250
1251 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
1252 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
1253 * ravenscar-thread.c: Add into comment.
1254 (base_magic_null_ptid): Delete.
1255 (base_ptid): Change documentation.
1256 (ravenscar_active_task): Renames ravenscar_running_thread.
1257 All callers updated throughout.
1258 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
1259 (ravenscar_task_is_currently_active): Likewise.
1260 (get_base_thread_from_ravenscar_task): Ditto.
1261 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
1262 (ravenscar_runtime_initialized): Likewise.
1263 (get_running_thread_id): Add new parameter "cpu". Adjust
1264 implementation to handle this new parameter.
1265 (ravenscar_fetch_registers): Small adjustment to use
1266 is_ravenscar_task and ravenscar_task_is_currently_active in
1267 order to decide whether to use the target beneath or this
1268 module's arch_ops.
1269 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
1270 (ravenscar_stopped_by_sw_breakpoint): Use
1271 get_base_thread_from_ravenscar_task to get the underlying
1272 thread, rather than using base_ptid.
1273 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1274 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1275 Likewise.
1276 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
1277
65d40437
JB
12782017-11-21 Joel Brobecker <brobecker@adacore.com>
1279
1280 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
1281 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
1282 (get_tcb_types_info): Set fieldnos.base_cpu.
1283 (read_atcb): Set task_info->base_cpu.
1284 (info_task): Print "Base CPU" info if set by runtime.
1285
e02544b2
JB
12862017-11-21 Joel Brobecker <brobecker@adacore.com>
1287
1288 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
1289 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1290 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1291 New functions.
1292 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
1293 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
1294 to_stopped_data_address and to_core_of_thread fields of
1295 ravenscar_ops.
1296
ed0f4273
UW
12972017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
1298
1299 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
1300 (struct gdbarch_tdep): New member long_double_abi.
1301 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
1302 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
1303 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
1304 format depending on long_double_abi tdep member.
1305 (ppc_floatformat_for_type): Handle __ibm128 type.
1306
0fc76421
SM
13072017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
1308
1309 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
1310
e6b2f5ef
PA
13112017-11-21 Pedro Alves <palves@redhat.com>
1312
1313 * dwarf2read.c (mapped_index::find_name_components_bounds)
1314 <completion mode, upper bound>: Use std::lower_bound instead of
1315 std::upper_bound.
1316 (test_mapped_index_find_name_component_bounds): Remove incorrect
1317 "t1_fund" from expected symbols.
1318
5c58de74
PA
13192017-11-21 Pedro Alves <palves@redhat.com>
1320
1321 * dwarf2read.c (mapped_index::name_components_casing): New field.
1322 (mapped_index) <build_name_components,
1323 find_name_components_bounds): Declare new methods.
1324 (mapped_index::find_name_components_bounds)
1325 (mapped_index::build_name_components): New methods, factored out
1326 from dw2_expand_symtabs_matching_symbol.
1327 (check_find_bounds_finds)
1328 (test_mapped_index_find_name_component_bounds): New.
1329 (run_test): Rename to ...
1330 (test_dw2_expand_symtabs_matching_symbol): ... this.
1331 (run_test): Reimplement.
1332
e1ef7d7a
PA
13332017-11-21 Pedro Alves <palves@redhat.com>
1334
1335 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
1336 (symbol_end): Use cp_ident_is_alnum.
1337 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
1338 * dwarf2read.c (make_sort_after_prefix_name): New function.
1339 (dw2_expand_symtabs_matching_symbol): Use it.
1340 (test_symbols): Add more symbols.
1341 (run_test): Add tests.
1342
cf724bc9
TT
13432017-11-17 Tom Tromey <tom@tromey.com>
1344
1345 * symtab.h (enum symbol_subclass_kind): New.
1346 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
1347 Remove.
1348 <subclass>: New member.
1349 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
1350 * rust-lang.c (rust_get_trait_object_pointer): Update.
1351 * dwarf2read.c (read_func_scope): Update.
1352 (read_variable): Update.
1353
68e745e3
TT
13542017-11-17 Tom Tromey <tom@tromey.com>
1355
1356 * dwarf2read.c (read_func_scope): Update.
1357 * symtab.h (struct template_symbol): Derive from symbol.
1358 <base>: Remove.
1359
71a3c369
TT
13602017-11-17 Tom Tromey <tom@tromey.com>
1361
1362 * symtab.h (struct symbol) <is_rust_vtable>: New member.
1363 (struct rust_vtable_symbol): New.
1364 (find_symbol_at_address): Declare.
1365 * symtab.c (find_symbol_at_address): New function.
1366 * symfile.h (struct quick_symbol_functions)
1367 <find_compunit_symtab_by_address>: New member.
1368 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
1369 function.
1370 (debug_sym_quick_functions): Link to
1371 debug_qf_find_compunit_symtab_by_address.
1372 * rust-lang.c (rust_get_trait_object_pointer): New function.
1373 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
1374 rust_get_trait_object_pointer.
1375 * psymtab.c (psym_relocate): Clear psymbol_map.
1376 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
1377 functions.
1378 (psym_functions): Link to psym_find_compunit_symtab_by_address.
1379 * objfiles.h (struct objfile) <psymbol_map>: New member.
1380 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
1381 (process_die) <DW_TAG_variable>: New case. Call read_variable.
1382 (rust_containing_type, read_variable): New functions.
1383
7468702d
SM
13842017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1385
1386 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
1387
37269bc9
SM
13882017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1389
1390 * common/filestuff.c: Include <algorithm>.
1391 (open_fds): Change type to std::vector<int>.
1392 (do_mark_open_fd): Adjust.
1393 (unmark_fd_no_cloexec): Adjust.
1394 (do_close): Adjust.
1395
5c632425
SM
13962017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1397
1398 * breakpoint.c (output_thread_groups): Take an std::vector.
1399 (print_one_breakpoint_location): Adjust.
1400
ced9779b
JB
14012017-11-17 Joel Brobecker <brobecker@adacore.com>
1402
1403 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
1404 (ada_evaluate_subexp_for_cast): New function.
1405 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
1406 ada_evaluate_subexp_for_cast.
1407 (ada_evaluate_subexp) <nosideret>: Replace code by call to
1408 eval_skip_value.
1409 * eval.c (evaluate_var_value): Make non-static.
1410 (evaluate_var_msym_value, eval_skip_value): Likewise.
1411 * value.h (evaluate_var_value, evaluate_var_msym_value)
1412 (eval_skip_value): Declare.
1413
b7e22850
JB
14142017-11-16 Joel Brobecker <brobecker@adacore.com>
1415
1416 * ada-lang.c (ada_value_cast): Remove parameter "noside".
1417 Update all callers.
1418
9ccabccd
PA
14192017-11-16 Pedro Alves <palves@redhat.com>
1420
1421 * python/py-unwind.c (pyuw_sniffer): Translate
1422 PyExc_KeyboardInterrupt to a GDB Quit exception.
1423
d930703d
PA
14242017-11-16 Pedro Alves <palves@redhat.com>
1425
1426 * infrun.c (resume_cleanups): Delete.
1427 (resume): No longer install a resume_cleanups cleanup nor call
1428 QUIT.
1429 (proceed): Pass the terminal to the inferior.
1430 (keep_going_pass_signal): No longer install a resume_cleanups
1431 cleanup.
1432
38dc2859
PA
14332017-11-16 Pedro Alves <palves@redhat.com>
1434
1435 * inf-loop.c (inferior_event_handler): Don't swallow the exception
1436 if the prompt is blocked.
1437
688fca4f
PA
14382017-11-16 Pedro Alves <palves@redhat.com>
1439
1440 * breakpoint.c (insert_bp_location): Replace bp_err and
1441 bp_err_message locals by a gdb_exception local.
1442
e2c33ac7
PA
14432017-11-16 Pedro Alves <palves@redhat.com>
1444
1445 * inflow.c (scoped_ignore_sigttou): New class.
1446 (child_terminal_ours_1, new_tty): Use it.
1447
d7236961
UW
14482017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
1449
1450 * target-float.c (decimal_from_number): Add byte_order argument and
1451 call match_endianness. Error if unknown floating-point type.
1452 (decimal_to_number): Add byte_order argument and call match_endianness.
1453 (decimal_from_longest): Update call. Do not call match_endianness.
1454 (decimal_from_ulongest): Likewise.
1455 (decimal_binop): Likewise.
1456 (decimal_is_zero): Likewise.
1457 (decimal_compare): Likewise.
1458 (decimal_convert): Likewise.
1459
d8ae99a7
PM
14602017-11-16 Phil Muldoon <pmuldoon@redhat.com>
1461
1462 * python/python.c (gdbpy_rbreak): New function.
1463 * NEWS: Document Python rbreak feature.
1464
c632b645
YQ
14652017-11-16 Yao Qi <yao.qi@linaro.org>
1466
1467 * features/tic6x-c62x.xml: Remove.
1468 * features/tic6x-c64x.xml: Remove.
1469 * features/tic6x-c64xp.xml: Remove.
1470
a014b87a
JB
14712017-11-15 John Baldwin <jhb@FreeBSD.org>
1472
1473 * symtab.h: Include <array>.
1474
94765011
JB
14752017-11-15 John Baldwin <jhb@FreeBSD.org>
1476
1477 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
1478 (bsd_kvm_proc_cmd): Likewise.
1479
625ad440
SM
14802017-11-15 Simon Marchi <simon.marchi@ericsson.com>
1481
1482 * tui/tui-win.c (window_name_completer): Replace VEC with
1483 std::vector.
1484
c0c11fa9
AC
14852017-11-15 Andrew Cagney <cagney@gnu.org>
1486
1487 * MAINTAINERS: Remove no-longer applicable entries.
1488
34a7ebaf
AC
14892017-11-15 Andrew Cagney <cagney@gnu.org>
1490
1491 * MAINTAINERS: Move self to Past Maintainers.
1492
5334ef39
YQ
14932017-11-15 Yao Qi <yao.qi@linaro.org>
1494
1495 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
1496 * features/nios2-linux.c: Remove.
1497 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
1498 initialize_tdesc_nios2_linux.
1499
a714b0d6
YQ
15002017-11-15 Yao Qi <yao.qi@linaro.org>
1501
1502 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
1503 M68HC11_LAST_HARD_REG + 1.
1504
92ffd475
PC
15052017-11-14 Paul Carroll <pcarroll@codesourcery.com>
1506
1507 PR gdb/22388
1508 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
1509 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
1510 Return TARGET_XFER_EOF if size of returned data is 0.
1511
07431908
SM
15122017-11-14 Simon Marchi <simon.marchi@ericsson.com>
1513
1514 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1515 memory-map-selftests.c.
1516 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
1517 * memory-map.c (memory_map_start_memory): Fix computation of hi
1518 address.
1519 * unittests/memory-map-selftests.c: New file.
1520
31432a67
JB
15212017-11-09 Joel Brobecker <brobecker@adacore.com>
1522
1523 * ada-lang.c: Fix some typos in the general command documenting
1524 how Ada expressions are being evaluated and how their result
1525 is printed.
1526
e793c052
TT
15272017-11-09 Tom Tromey <tom@tromey.com>
1528
1529 * psymtab.c (psymbol_hash): Do not hash string contents.
1530 (psymbol_compare): Add comment.
1531
7e8835c5
TT
15322017-11-09 Tom Tromey <tom@tromey.com>
1533
1534 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
1535
286acbb5
JB
15362017-11-08 Joel Brobecker <brobecker@adacore.com>
1537
1538 * ada-exp.y (write_var_from_sym): Remove parameter
1539 "orig_left_context". Update all callers.
1540
b44ec619
SM
15412017-11-08 Simon Marchi <simon.marchi@ericsson.com>
1542
1543 * tracepoint.h (class collection_list) <stringify>: Return
1544 std::vector<std::string>.
1545 (encode_actions_rsp): Change parameters to
1546 std::vector<std::string> *.
1547 * tracepoint.c (collection_list::stringify): Return
1548 std::vector<std::string> and adjust accordingly.
1549 (encode_actions_rsp): Changee parameters to
1550 std::vector<std::string> and adjust accordingly.
1551 * remote.c (free_actions_list),
1552 free_actions_list_cleanup_wrapper): Remove.
1553 (remote_download_tracepoint): Adjust to std::vector.
1554
2f4732b0
TT
15552017-11-08 Tom Tromey <tom@tromey.com>
1556
1557 * dwarf2read.c (symbolp): Remove typedef.
1558 (read_func_scope): Use std::vector.
1559 (process_structure_scope): Use std::vector.
1560
f9d67a22
PA
15612017-11-08 Pedro Alves <palves@redhat.com>
1562
1563 * ada-lang.c (ada_make_symbol_completion_list): Use
1564 completion_skip_symbol.
1565 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
1566 (symbol_is_function_or_method(symbol*)): New.
1567 (add_symtab_completions): Add complete_symbol_mode parameter. Use
1568 completion_skip_symbol.
1569 (default_collect_symbol_completion_matches_break_on): Use
1570 completion_skip_symbol. Pass down mode.
1571 (collect_file_symbol_completion_matches): Pass down mode.
1572 * symtab.h (symbol_is_function_or_method): New declarations.
1573 (completion_skip_symbol): New template function.
1574
56d87ef7
PA
15752017-11-08 Pedro Alves <palves@redhat.com>
1576
1577 * linespec.c (iterate_over_all_matching_symtabs): Add
1578 search_domain parameter. Pass it down to expand_symtabs_matching.
1579 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
1580 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
1581 search_domain.
1582 (add_all_symbol_names_from_pspace): Add search_domain parameter.
1583 Pass it down.
1584 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
1585 symbols.
1586 (add_matching_symbols_to_info): Add search_domain parameter. Pass
1587 it down.
1588
1b026119
PA
15892017-11-08 Pedro Alves <palves@redhat.com>
1590
1591 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
1592 text_len locals and don't pass them down.
1593 * symtab.c (completion_list_add_name): Remove
1594 sym_text/sym_text_len parameters and adjust.
1595 (completion_list_add_symbol, completion_list_add_msymbol)
1596 (completion_list_objc_symbol, completion_list_add_fields)
1597 (add_symtab_completions): Likewise.
1598 (default_collect_symbol_completion_matches_break_on)
1599 (collect_file_symbol_completion_matches): Remove sym_text_len
1600 local and don't pass it down.
1601 * symtab.h (completion_list_add_name): Remove
1602 sym_text/sym_text_len parameters.
1603
c62446b1
PA
16042017-11-08 Pedro Alves <palves@redhat.com>
1605
1606 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1607 unittests/lookup_name_info-selftests.c.
1608 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
1609 * cp-support.c: Include "selftest.h".
1610 (cp_remove_params_1): Rename from cp_remove_params. Add
1611 'require_param' parameter, and handle it.
1612 (cp_remove_params): Reimplement.
1613 (cp_remove_params_if_any): New.
1614 (selftests::quote): New.
1615 (selftests::check_remove_params): New.
1616 (selftests::test_cp_remove_params): New.
1617 (_initialize_cp_support): Install
1618 selftests::test_cp_remove_params.
1619 * cp-support.h (cp_remove_params_if_any): Declare.
1620 * dwarf2read.c :Include "selftest.h".
1621 (dw2_expand_symtabs_matching_symbol): Use
1622 lookup_name_info::make_ignore_params.
1623 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
1624 (selftests::dw2_expand_symtabs_matching::string_or_null)
1625 (selftests::dw2_expand_symtabs_matching::check_match)
1626 (selftests::dw2_expand_symtabs_matching::test_symbols)
1627 (selftests::dw2_expand_symtabs_matching::run_test): New.
1628 (_initialize_dwarf2_read): Register
1629 selftests::dw2_expand_symtabs_matching::run_test.
1630 * psymtab.c (psym_expand_symtabs_matching): Use
1631 lookup_name_info::make_ignore_params.
1632 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
1633 If the lookup name wants to ignore parameters, strip them.
1634 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
1635 code handling '('.
1636 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
1637 (default_collect_symbol_completion_matches_break_on): Don't try to
1638 strip parameters.
1639 * symtab.h (lookup_name_info::lookup_name_info): Add
1640 'ignore_parameters' parameter.
1641 (lookup_name_info::ignore_parameters)
1642 (lookup_name_info::make_ignore_params): New methods.
1643 (lookup_name_info::m_ignore_parameters): New field.
1644 * unittests/lookup_name_info-selftests.c: New file.
1645
61920122
PA
16462017-11-08 Pedro Alves <palves@redhat.com>
1647
1648 * dwarf2read.c (dw2_expand_marked_cus)
1649 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
1650 (dw2_expand_symtabs_matching): Move further below.
1651 (dw2_expand_marked_cus): Reindent.
1652
3f563c84
PA
16532017-11-08 Pedro Alves <palves@redhat.com>
1654
1655 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
1656 (struct name_component): New.
1657 (mapped_index::name_components): New field.
1658 (mapped_index::symbol_name_at): New method.
1659 (dwarf2_read_index): Call mapped_index ctor.
1660 (dw2_map_matching_symbols): Add comment about name_components
1661 table.
1662 (dw2_expand_symtabs_matching): Factor part to...
1663 (dw2_expand_symtabs_matching_symbol): ... this new function.
1664 Build name components table, and lookup symbols in it before
1665 calling the name matcher.
1666 (dw2_expand_marked_cus): New, factored out from
1667 dw2_expand_symtabs_matching.
1668 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
1669
b5ec771e
PA
16702017-11-08 Pedro Alves <palves@redhat.com>
1671
1672 * ada-lang.c (ada_encode): Rename to ..
1673 (ada_encode_1): ... this. Add throw_errors parameter and handle
1674 it.
1675 (ada_encode): Reimplement.
1676 (match_name): Delete, folded into full_name.
1677 (resolve_subexp): No longer pass the encoded name to
1678 ada_lookup_symbol_list.
1679 (should_use_wild_match): Delete.
1680 (name_match_type_from_name): New.
1681 (ada_lookup_simple_minsym): Use lookup_name_info and the
1682 language's symbol_name_matcher_ftype.
1683 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
1684 (ada_add_block_renamings): Adjust to use lookup_name_info.
1685 (ada_lookup_name): New.
1686 (add_nonlocal_symbols, ada_add_all_symbols)
1687 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
1688 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
1689 (ada_name_for_lookup): Delete.
1690 (ada_lookup_encoded_symbol): Construct a verbatim name.
1691 (wild_match): Reverse sense of return type. Use bool.
1692 (full_match): Reverse sense of return type. Inline bits of old
1693 match_name here.
1694 (ada_add_block_symbols): Adjust to use lookup_name_info.
1695 (symbol_completion_match): Delete, folded into...
1696 (ada_lookup_name_info::matches): ... .this new method.
1697 (symbol_completion_add): Delete.
1698 (ada_collect_symbol_completion_matches): Add name_match_type
1699 parameter. Adjust to use lookup_name_info and
1700 completion_list_add_name.
1701 (get_var_value, ada_add_global_exceptions): Adjust to use
1702 lookup_name_info.
1703 (ada_get_symbol_name_cmp): Delete.
1704 (do_wild_match, do_full_match): New functions.
1705 (ada_lookup_name_info::ada_lookup_name_info): New method.
1706 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
1707 functions.
1708 (ada_language_defn): Install ada_get_symbol_name_matcher.
1709 * ada-lex.l (processId): If name starts with '<', copy it
1710 verbatim.
1711 * block.c (block_iter_match_step, block_iter_match_first)
1712 (block_iter_match_next, block_lookup_symbol)
1713 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
1714 lookup_name_info.
1715 * block.h (block_iter_match_first, block_iter_match_next)
1716 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
1717 * c-lang.c (c_language_defn, cplus_language_defn)
1718 (asm_language_defn, minimal_language_defn): Adjust comments to
1719 refer to la_get_symbol_name_matcher.
1720 * completer.c (complete_files_symbols)
1721 (collect_explicit_location_matches, symbol_completer): Pass a
1722 symbol_name_match_type down.
1723 * completer.h (class completion_match, completion_match_result):
1724 New classes.
1725 (completion_tracker::reset_completion_match_result): New method.
1726 (completion_tracker::m_completion_match_result): New field.
1727 * cp-support.c (make_symbol_overload_list_block): Adjust to use
1728 lookup_name_info.
1729 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
1730 functions.
1731 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
1732 * d-lang.c: Adjust comments to refer to
1733 la_get_symbol_name_matcher.
1734 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
1735 Adjust to use lookup_name_info.
1736 (dict_iter_match_first, dict_iter_match_next)
1737 (iter_match_first_hashed, iter_match_next_hashed)
1738 (iter_match_first_linear, iter_match_next_linear): Adjust to work
1739 with a lookup_name_info.
1740 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
1741 Likewise.
1742 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
1743 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
1744 (gdb_index_symbol_name_matcher): New class.
1745 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
1746 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
1747 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
1748 with a symbol_name_match_type.
1749 (f_language_defn): Adjust comments to refer to
1750 la_get_symbol_name_matcher.
1751 * go-lang.c (go_language_defn): Adjust comments to refer to
1752 la_get_symbol_name_matcher.
1753 * language.c (default_symbol_name_matcher)
1754 (language_get_symbol_name_matcher): New functions.
1755 (unknown_language_defn, auto_language_defn): Adjust comments to
1756 refer to la_get_symbol_name_matcher.
1757 * language.h (symbol_name_cmp_ftype): Delete.
1758 (language_defn) <la_collect_symbol_completion_matches>: Add match
1759 type parameter.
1760 <la_get_symbol_name_cmp>: Delete field.
1761 <la_get_symbol_name_matcher>: New field.
1762 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
1763 (default_symbol_name_matcher, language_get_symbol_name_matcher):
1764 Declare.
1765 * linespec.c (iterate_over_all_matching_symtabs)
1766 (iterate_over_file_blocks): Adjust to use lookup_name_info.
1767 (find_methods): Add language parameter, and use lookup_name_info
1768 and the language's symbol_name_matcher_ftype.
1769 (linespec_complete_function): Adjust.
1770 (lookup_prefix_sym): Use lookup_name_info.
1771 (add_all_symbol_names_from_pspace): Adjust.
1772 (find_superclass_methods): Add language parameter and pass it
1773 down.
1774 (find_method): Pass symbol language down.
1775 (find_linespec_symbols): Don't demangle or Ada encode here.
1776 (search_minsyms_for_name): Add lookup_name_info parameter.
1777 (add_matching_symbols_to_info): Add name_match_type parameter.
1778 Use lookup_name_info.
1779 * m2-lang.c (m2_language_defn): Adjust comments to refer to
1780 la_get_symbol_name_matcher.
1781 * minsyms.c: Include <algorithm>.
1782 (add_minsym_to_demangled_hash_table): Remove table parameter and
1783 add objfile parameter. Use search_name_hash, and add language to
1784 demangled languages vector.
1785 (struct found_minimal_symbols): New struct.
1786 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
1787 New functions.
1788 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
1789 input names here. Use lookup_name_info instead. Lookup up
1790 demangled names once for each language in the demangled names
1791 vector.
1792 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
1793 demangled names once for each language in the demangled names
1794 vector.
1795 (build_minimal_symbol_hash_tables): Adjust.
1796 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
1797 lookup_name_info.
1798 * objc-lang.c (objc_language_defn): Adjust comment to refer to
1799 la_get_symbol_name_matcher.
1800 * objfiles.h: Include <vector>.
1801 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
1802 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
1803 la_get_symbol_name_matcher.
1804 * p-lang.c (pascal_language_defn): Adjust comment to refer to
1805 la_get_symbol_name_matcher.
1806 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
1807 (match_partial_symbol): Use symbol_name_match_type,
1808 lookup_name_info and psymbol_name_matches.
1809 (lookup_partial_symbol): Use lookup_name_info.
1810 (map_block): Use symbol_name_match_type and lookup_name_info.
1811 (psym_map_matching_symbols): Use symbol_name_match_type.
1812 (psymbol_name_matches): New.
1813 (recursively_search_psymtabs): Use lookup_name_info and
1814 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
1815 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
1816 'kind' parameter to 'domain'.
1817 * rust-lang.c (rust_language_defn): Adjust comment to refer to
1818 la_get_symbol_name_matcher.
1819 * symfile-debug.c (debug_qf_map_matching_symbols)
1820 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
1821 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
1822 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
1823 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
1824 Adjust to use symbol_name_match_type.
1825 <expand_symtabs_matching>: Adjust to use lookup_name_info.
1826 (expand_symtabs_matching): Adjust to use lookup_name_info.
1827 * symmisc.c (maintenance_expand_symtabs): Use
1828 lookup_name_info::match_any ().
1829 * symtab.c (symbol_matches_search_name): New.
1830 (eq_symbol_entry): Adjust to use lookup_name_info and the
1831 language's matcher.
1832 (demangle_for_lookup_info::demangle_for_lookup_info): New.
1833 (lookup_name_info::match_any): New.
1834 (iterate_over_symbols, search_symbols): Use lookup_name_info.
1835 (compare_symbol_name): Add language, lookup_name_info and
1836 completion_match_result parameters, and use them.
1837 (completion_list_add_name): Make extern. Add language and
1838 lookup_name_info parameters. Use them.
1839 (completion_list_add_symbol, completion_list_add_msymbol)
1840 (completion_list_objc_symbol): Add lookup_name_info parameters and
1841 adjust. Pass down language.
1842 (completion_list_add_fields): Add lookup_name_info parameters and
1843 adjust. Pass down language.
1844 (add_symtab_completions): Add lookup_name_info parameters and
1845 adjust.
1846 (default_collect_symbol_completion_matches_break_on): Add
1847 name_match_type parameter, and use it. Use lookup_name_info.
1848 (default_collect_symbol_completion_matches)
1849 (collect_symbol_completion_matches): Add name_match_type
1850 parameter, and pass it down.
1851 (collect_symbol_completion_matches_type): Adjust.
1852 (collect_file_symbol_completion_matches): Add name_match_type
1853 parameter, and use lookup_name_info.
1854 * symtab.h: Include <string> and "common/gdb_optional.h".
1855 (enum class symbol_name_match_type): New.
1856 (class ada_lookup_name_info): New.
1857 (struct demangle_for_lookup_info): New.
1858 (class lookup_name_info): New.
1859 (symbol_name_matcher_ftype): New.
1860 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
1861 (symbol_matches_search_name): Declare.
1862 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
1863 (default_collect_symbol_completion_matches)
1864 (collect_symbol_completion_matches)
1865 (collect_file_symbol_completion_matches): Add name_match_type
1866 parameter.
1867 (iterate_over_symbols): Use lookup_name_info.
1868 (completion_list_add_name): Declare.
1869 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
1870 (strncmp_iw_with_mode): Now extern.
1871 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
1872 (strncmp_iw_with_mode): Declare.
1873
5ffa0793
PA
18742017-11-08 Keith Seitz <keiths@redhat.com>
1875 Pedro Alves <palves@redhat.com>
1876
1877 * ada-lang.c (ada_language_defn): Install
1878 default_search_name_hash.
1879 * buildsym.c (struct buildsym_compunit): <language>: New field.
1880 (finish_block_internal): Pass language when creating dictionaries.
1881 (start_buildsym_compunit, start_symtab): New language parameters.
1882 Use them.
1883 (restart_symtab): Pass down compilation unit's language.
1884 * buildsym.h (enum language): Forward declare.
1885 (start_symtab): New 'language' parameter.
1886 * c-lang.c (c_language_defn, cplus_language_defn)
1887 (asm_language_defn, minimal_language_defn): Install
1888 default_search_name_hash.
1889 * coffread.c (coff_start_symtab): Adjust.
1890 * d-lang.c (d_language_defn): Install default_search_name_hash.
1891 * dbxread.c (struct symloc): Add 'pst_language' field.
1892 (PST_LANGUAGE): Define.
1893 (start_psymtab, read_ofile_symtab): Use it.
1894 (process_one_symbol): New 'language' parameter. Pass it down.
1895 * dictionary.c (struct dictionary) <language>: New field.
1896 (DICT_LANGUAGE): Define.
1897 (dict_create_hashed, dict_create_hashed_expandable)
1898 (dict_create_linear, dict_create_linear_expandable): New parameter
1899 'language'. Set the dictionary's language.
1900 (iter_match_first_hashed): Adjust to rename.
1901 (insert_symbol_hashed): Assert we don't see mismatching
1902 languages. Adjust to rename.
1903 (dict_hash): Rename to ...
1904 (default_search_name_hash): ... this and make extern.
1905 * dictionary.h (struct language_defn): Forward declare.
1906 (dict_create_hashed): New parameter 'language'.
1907 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
1908 * f-lang.c (f_language_defn): Install default_search_name_hash.
1909 * go-lang.c (go_language_defn): Install default_search_name_hash.
1910 * jit.c (finalize_symtab): Pass compunit's language to dictionary
1911 creation.
1912 * language.c (unknown_language_defn, auto_language_defn):
1913 * language.h (language_defn::la_search_name_hash): New field.
1914 (default_search_name_hash): Declare.
1915 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
1916 * mdebugread.c (new_block): New parameter 'language'.
1917 * mdebugread.c (parse_symbol): Pass symbol language to block
1918 allocation.
1919 (psymtab_to_symtab_1): Pass down language.
1920 (new_symtab): Pass compunit's language to block allocation.
1921 * objc-lang.c (objc_language_defn): Install
1922 default_search_name_hash.
1923 * opencl-lang.c (opencl_language_defn):
1924 * p-lang.c (pascal_language_defn): Install
1925 default_search_name_hash.
1926 * rust-lang.c (rust_language_defn): Install
1927 default_search_name_hash.
1928 * stabsread.h (enum language): Forward declare.
1929 (process_one_symbol): Add 'language' parameter.
1930 * symtab.c (search_name_hash): New function.
1931 * symtab.h (search_name_hash): Declare.
1932 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
1933
2a1dde5d
PA
19342017-11-08 Pedro Alves <palves@redhat.com>
1935
1936 * cp-name-parser.y (main): Don't initialize extra_chars.
1937
95a6b0a1
TT
19382017-11-07 Tom Tromey <tom@tromey.com>
1939
1940 * event-top.h (command_handler): Constify.
1941 * record-full.c (cmd_record_full_start): Update.
1942 * thread.c (thread_apply_all_command): Update.
1943 * printcmd.c (eval_command): Update.
1944 * mi/mi-main.c (mi_execute_cli_command): Update.
1945 (mi_execute_async_cli_command): Update.
1946 * tui/tui-stack.c (tui_update_command): Update.
1947 * cli/cli-interp.c (safe_execute_command): Constify.
1948 * record.c (record_start): Update.
1949 (record_start, record_stop, cmd_record_start): Update.
1950 * record-btrace.c (cmd_record_btrace_bts_start): Update.
1951 (cmd_record_btrace_pt_start): Update.
1952 (cmd_record_btrace_start): Update.
1953 (cmd_record_btrace_start): Update.
1954 * reverse.c (exec_reverse_once): Update.
1955 * python/python.c (execute_gdb_command): Don't copy the command.
1956 * event-top.c (command_line_handler): Update.
1957 (command_handler): Constify.
1958 * defs.h (deprecated_call_command_hook): Constify.
1959 * cli/cli-script.h (execute_user_command): Constify.
1960 * cli/cli-script.c (execute_user_command): Constify.
1961 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
1962 (enum command_control_type): Update.
1963 * main.c (catch_command_errors): Remove non-const overload.
1964 (catch_command_errors_ftype): Remove.
1965 * python/py-cmd.c (cmdpy_function): Constify.
1966 * guile/scm-cmd.c (cmdscm_function): Constify.
1967 * cli/cli-dump.c (call_dump_func): Constify.
1968 * cli/cli-decode.c (do_const_cfunc): Constify.
1969 (do_sfunc): Constify.
1970 (cmd_func): Constify.
1971 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
1972 * top.h (execute_command): Constify.
1973 * top.c (execute_command): Constify.
1974 (execute_command_to_string): Constify.
1975 (deprecated_call_command_hook): Constify.
1976 * command.h (cmd_func): Constify.
1977 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
1978
eb4c3f4a
TT
19792017-11-07 Tom Tromey <tom@tromey.com>
1980
1981 * ada-lang.c (catch_ada_exception_command): Constify.
1982 (catch_assert_command): Constify.
1983 * break-catch-throw.c (catch_catch_command, catch_throw_command)
1984 (catch_rethrow_command): Constify.
1985 (catch_exception_command_1): Constify.
1986 * breakpoint.h (add_catch_command): Constify.
1987 * break-catch-syscall.c (catch_syscall_command_1): Constify.
1988 (catch_syscall_split_args): Constify.
1989 * break-catch-sig.c (catch_signal_command): Constify.
1990 (catch_signal_split_args): Constify.
1991 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
1992 cmd_const_sfunc_ftype.
1993 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
1994 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
1995 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
1996 (add_setshow_string_cmd, struct cmd_list_element)
1997 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
1998 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
1999 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
2000 Constify.
2001 (set_cmd_sfunc): Constify.
2002 (empty_sfunc): Constify.
2003 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
2004 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
2005 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
2006 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
2007 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
2008 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
2009 Constify.
2010 (set_cmd_sfunc): Constify.
2011 (cmd_sfunc_ftype): Remove.
2012 * compile/compile.c (set_compile_args): Constify.
2013 * infrun.c (set_disable_randomization): Constify.
2014 * infcmd.c (set_args_command, set_cwd_command): Constify.
2015 * breakpoint.c (set_condition_evaluation_mode): Constify.
2016 (add_catch_command): Constify.
2017 (catch_fork_command_1, catch_exec_command_1)
2018 (catch_load_command_1, catch_unload_command_1): Constify.
2019 (catch_load_or_unload): Constify.
2020 * guile/scm-param.c (pascm_set_func): Constify.
2021 (add_setshow_generic): Constify.
2022 * python/py-param.c (get_set_value): Constify.
2023 * top.h (set_verbose): Constify.
2024 * tui/tui-win.c (tui_set_var_cmd): Constify.
2025 * mi/mi-main.c (set_mi_async_command): Constify.
2026 * cli/cli-logging.c (set_logging_overwrite)
2027 (set_logging_redirect): Constify.
2028 * value.c (set_max_value_size): Constify.
2029 * valprint.c (set_input_radix, set_output_radix): Constify.
2030 * utils.c (set_width_command, set_height_command): Constify.
2031 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
2032 * tracepoint.c (set_disconnected_tracing)
2033 (set_circular_trace_buffer, set_trace_buffer_size)
2034 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
2035 * top.c (set_history_size_command, set_verbose, set_editing)
2036 (set_gdb_datadir, set_history_filename): Constify.
2037 * target.c (set_targetdebug, maint_set_target_async_command)
2038 (maint_set_target_non_stop_command, set_target_permissions)
2039 (set_write_memory_permission): Constify.
2040 (open_target): Constify.
2041 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
2042 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
2043 * symtab.c (set_symbol_cache_size_handler): Constify.
2044 * symfile.c (set_ext_lang_command): Constify.
2045 * symfile-debug.c (set_debug_symfile): Constify.
2046 * source.c (set_directories_command): Constify.
2047 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
2048 * serial.c (set_parity): Constify.
2049 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
2050 * remote.c (set_remote_exec_file, set_remotebreak)
2051 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
2052 * record.c (set_record_insn_history_size)
2053 (set_record_call_history_size): Constify.
2054 * record-full.c (set_record_full_insn_max_num): Constify.
2055 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
2056 * osabi.c (set_osabi): Constify.
2057 * mips-tdep.c (set_mips64_transfers_32bit_regs)
2058 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
2059 * maint.c (maintenance_set_profile_cmd): Constify.
2060 * linux-thread-db.c (set_libthread_db_search_path): Constify.
2061 * language.c (set_language_command, set_range_command)
2062 (set_case_command): Constify.
2063 * infrun.c (set_non_stop, set_observer_mode)
2064 (set_stop_on_solib_events, set_schedlock_func)
2065 (set_exec_direction_func): Constify.
2066 * infcmd.c (set_inferior_tty_command): Constify.
2067 * disasm.c (set_disassembler_options_sfunc): Constify.
2068 * demangle.c (set_demangling_command): Constify.
2069 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
2070 * cris-tdep.c (set_cris_version, set_cris_mode)
2071 (set_cris_dwarf2_cfi): Constify.
2072 * corefile.c (set_gnutarget_command): Constify.
2073 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
2074 (set_target_wide_charset_sfunc): Constify.
2075 * breakpoint.c (update_dprintf_commands): Constify.
2076 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
2077 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
2078 (set_disassembly_style_sfunc): Constify.
2079 * arch-utils.c (set_endian, set_architecture): Constify.
2080 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
2081 * agent.c (set_can_use_agent): Constify.
2082
5fed81ff
TT
20832017-11-07 Tom Tromey <tom@tromey.com>
2084
2085 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
2086 (go32_pde, go32_pte, go32_pte_for_address): Constify.
2087 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
2088 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
2089 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
2090 (parse_int_arg, show_thread_default_detach_sc_cmd)
2091 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
2092 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
2093 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
2094 (show_task_pause_cmd, set_task_detach_sc_cmd)
2095 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
2096 (set_noninvasive_cmd, set_thread_pause_cmd)
2097 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
2098 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
2099 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
2100 * windows-nat.c (display_selectors): Constify.
2101 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
2102 non-const "cfunc".
2103 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
2104 (cmd_cfunc_eq): Likewise.
2105 (struct cmd_list_element): Likewise.
2106 (do_cfunc): Remove.
2107 (cli_user_command_p): Update.
2108 * command.h (add_cmd): Remove non-const overload.
2109 (cmd_cfunc_ftype): Remove typedef.
2110 (cmd_cfunc_eq): Remove non-const overload.
2111 * value.c (show_values): Constify.
2112 * thread.c (thread_apply_all_command): Constify.
2113 * symfile.c (load_command): Constify.
2114 * source.c (directory_command): Constify.
2115 * maint.c (maintenance_internal_error)
2116 (maintenance_demangler_warning, maintenance_space_display)
2117 (maintenance_print_architecture, maintenance_translate_address)
2118 (maintenance_info_selftests, maintenance_internal_warning):
2119 Constify.
2120 * breakpoint.c (disable_trace_command, enable_trace_command):
2121 Constify.
2122 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
2123 Constify.
2124 (add_auto_load_safe_path): Constify.
2125 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
2126 * top.h (show_commands): Constify.
2127 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
2128 * sparc64-tdep.c (adi_examine_command): Constify.
2129 (adi_assign_command): Constify.
2130
1d12d88f
TT
21312017-11-07 Tom Tromey <tom@tromey.com>
2132
2133 * frame.h (info_locals_command, info_args_command): Constify.
2134 * auto-load.h (auto_load_info_scripts): Constify.
2135 * inferior.h (registers_info): Constify.
2136 * copying.c: Rebuild.
2137 * copying.awk: Constify generated commands.
2138 * auto-load.c (auto_load_info_scripts)
2139 (info_auto_load_gdb_scripts): Constify.
2140 * cli/cli-decode.c (struct cmd_list_element): Take a
2141 cmd_const_cfunc_ftype.
2142 * command.h (add_info): Take a cmd_const_cfunc_ftype.
2143 * tui/tui-win.c (tui_all_windows_info): Constify.
2144 * python/py-auto-load.c (info_auto_load_python_scripts):
2145 Constify.
2146 * cli/cli-cmds.c (show_command): Remove non-const overload.
2147 * tracepoint.c (info_tvariables_command, info_scope_command):
2148 Constify.
2149 (info_static_tracepoint_markers_command): Constify.
2150 * thread.c (info_threads_command): Constify.
2151 (print_thread_info_1): Constify.
2152 * target.c (info_target_command): Constify.
2153 * symtab.c (info_sources_command, info_functions_command)
2154 (info_types_command): Constify.
2155 (info_variables_command): Remove non-const overload.
2156 * symfile.c (info_ext_lang_command): Constify.
2157 * stack.c (info_frame_command, info_locals_command)
2158 (info_args_command): Constify.
2159 (backtrace_command): Remove non-const overload.
2160 * source.c (info_source_command, info_line_command): Constify.
2161 * solib.c (info_sharedlibrary_command): Constify.
2162 * skip.c (info_skip_command): Constify.
2163 * ser-go32.c (info_serial_command): Constify.
2164 * reverse.c (info_bookmarks_command): Constify.
2165 * printcmd.c (info_symbol_command, info_address_command)
2166 (info_display_command): Constify.
2167 * osdata.c (info_osdata_command): Constify.
2168 * objc-lang.c (info_selectors_command, info_classes_command):
2169 Constify.
2170 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
2171 * memattr.c (info_mem_command): Constify.
2172 * macrocmd.c (info_macro_command, info_macros_command): Constify.
2173 * linux-fork.c (info_checkpoints_command): Constify.
2174 * infrun.c (info_signals_command): Constify.
2175 * inflow.c (info_terminal_command): Constify.
2176 * inferior.c (info_inferiors_command): Constify.
2177 (print_inferior): Constify.
2178 * infcmd.c (info_program_command, info_all_registers_command)
2179 (info_registers_command, info_vector_command)
2180 (info_float_command): Constify.
2181 (registers_info): Constify.
2182 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
2183 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
2184 Constify.
2185 * f-valprint.c (info_common_command): Constify.
2186 * dcache.c (info_dcache_command): Constify.
2187 (dcache_info_1): Constify.
2188 * darwin-nat-info.c (info_mach_tasks_command)
2189 (info_mach_task_command, info_mach_ports_command)
2190 (info_mach_port_command, info_mach_threads_command)
2191 (info_mach_thread_command, info_mach_regions_command)
2192 (info_mach_regions_recurse_command, info_mach_region_command)
2193 (info_mach_exceptions_command): Constify.
2194 (get_task_from_args): Constify.
2195 * cp-support.c (info_vtbl_command): Constify.
2196 * breakpoint.c (info_watchpoints_command)
2197 (info_tracepoints_command): Constify.
2198 (info_breakpoints_command): Remove non-const overload.
2199 * avr-tdep.c (avr_io_reg_read_command): Constify.
2200 * auxv.c (info_auxv_command): Constify.
2201 * ada-tasks.c (info_tasks_command): Constify.
2202 (info_task): Constify.
2203 * ada-lang.c (info_exceptions_command): Constify.
2204
0b39b52e
TT
22052017-11-07 Tom Tromey <tom@tromey.com>
2206
2207 * solib.h (no_shared_libraries): Constify.
2208 * frame.h (return_command): Constify.
2209 * cli/cli-cmds.h (quit_command): Constify.
2210 * top.h (quit_command, execute_command): Constify.
2211 * target.h (flash_erase_command): Constify.
2212 * inferior.h (set_inferior_args, attach_command): Constify.
2213 * tracepoint.h (start_tracing, stop_tracing): Constify.
2214 * breakpoint.h (break_command, tbreak_command)
2215 (hbreak_command_wrapper, thbreak_command_wrapper)
2216 (rbreak_command_wrapper, watch_command_wrapper)
2217 (awatch_command_wrapper, rwatch_command_wrapper)
2218 (get_tracepoint_by_number): Constify.
2219 * symtab.c (info_variables_command, rbreak_command)
2220 (symtab_symbol_info): Constify.
2221 (info_variables_command): Add non-const overload.
2222 * top.c (dont_repeat_command): Constify.
2223 * breakpoint.c (ignore_command, commands_command)
2224 (condition_command, tbreak_command, hbreak_command)
2225 (thbreak_command, clear_command, break_command)
2226 (info_breakpoints_command, watch_command, rwatch_command)
2227 (awatch_command, trace_command, ftrace_command, strace_command)
2228 (trace_pass_command, break_range_command, dprintf_command)
2229 (agent_printf_command, get_tracepoint_by_number)
2230 (watch_maybe_just_location, trace_pass_command): Constify.
2231 (info_breakpoints_command): Add non-const overload.
2232 * tracefile.c (tsave_command): Constify.
2233 * infcmd.c (attach_command, disconnect_command, signal_command)
2234 (queue_signal_command, stepi_command, nexti_command)
2235 (finish_command, next_command, step_command, until_command)
2236 (advance_command, jump_command, continue_command, run_command)
2237 (start_command, starti_command, interrupt_command)
2238 (run_command_1, set_inferior_args, step_1): Constify.
2239 * inferior.c (add_inferior_command, remove_inferior_command)
2240 (clone_inferior_command): Constify.
2241 * linux-fork.c (checkpoint_command, restart_command): Constify.
2242 * windows-nat.c (signal_event_command): Constify.
2243 * guile/guile.c (guile_repl_command, guile_command): Constify.
2244 * printcmd.c (x_command, display_command, printf_command)
2245 (output_command, set_command, call_command, print_command)
2246 (eval_command): Constify.
2247 (non_const_set_command): Remove.
2248 (_initialize_printcmd): Update.
2249 * source.c (forward_search_command, reverse_search_command):
2250 Constify.
2251 * jit.c (jit_reader_load_command, jit_reader_unload_command):
2252 Constify.
2253 * infrun.c (handle_command): Constify.
2254 * memattr.c (mem_command): Constify.
2255 * stack.c (return_command, up_command, up_silently_command)
2256 (down_command, down_silently_command, frame_command)
2257 (backtrace_command, func_command, backtrace_command_1): Constify.
2258 (backtrace_command): Add non-const overload.
2259 * remote-sim.c (simulator_command): Constify.
2260 * exec.c (set_section_command): Constify.
2261 * tracepoint.c (tdump_command, trace_variable_command)
2262 (tstatus_command, tstop_command, tstart_command)
2263 (end_actions_pseudocommand, while_stepping_pseudocommand)
2264 (collect_pseudocommand, teval_pseudocommand, actions_command)
2265 (start_tracing, stop_tracing): Constify.
2266 * value.c (init_if_undefined_command): Constify.
2267 * tui/tui-stack.c (tui_update_command): Constify.
2268 * tui/tui-win.c (tui_refresh_all_command)
2269 (tui_set_tab_width_command, tui_set_win_height_command)
2270 (tui_set_focus_command, tui_scroll_forward_command)
2271 (tui_scroll_backward_command, tui_scroll_left_command)
2272 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
2273 (tui_set_win_height): Constify.
2274 * tui/tui-layout.c (tui_layout_command): Constify.
2275 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
2276 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
2277 (proc_untrace_sysexit_cmd): Constify.
2278 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
2279 (threadset_test_cmd, threadlist_update_test_cmd)
2280 (threadalive_test): Constify.
2281 * objc-lang.c (print_object_command): Constify.
2282 * command.h (add_com): Constify.
2283 * cli/cli-dump.c (restore_command): Constify.
2284 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
2285 (help_command, complete_command, shell_command, edit_command)
2286 (list_command, disassemble_command, make_command)
2287 (apropos_command, alias_command): Constify.
2288 * cli/cli-script.c (document_command, define_command)
2289 (while_command, if_command, validate_comname): Constify.
2290 * cli/cli-decode.c (struct cmd_list_element): Change type of
2291 "fun".
2292 * target.c (do_monitor_command, flash_erase_command): Constify.
2293 * regcache.c (reg_flush_command): Constify.
2294 * reverse.c (reverse_step, reverse_next, reverse_stepi)
2295 (reverse_nexti, reverse_continue, reverse_finish)
2296 (save_bookmark_command, goto_bookmark_command)
2297 (exec_reverse_once): Constify.
2298 * python/python.c (python_interactive_command, python_command):
2299 Constify.
2300 * typeprint.c (ptype_command, whatis_command, whatis_exp):
2301 Constify.
2302 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
2303 * gcore.c (gcore_command): Constify.
2304
85c4be7c
TT
23052017-11-07 Tom Tromey <tom@tromey.com>
2306
2307 * printcmd.c (x_command): Call set_repeat_arguments.
2308 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
2309 * top.c (repeat_arguments): New global.
2310 (set_repeat_arguments): New function.
2311 (execute_command): Handle repeat_arguments.
2312 (show_commands): Calls set_repeat_arguments.
2313 * command.h (set_repeat_arguments): Declare.
2314
022643b4
TT
23152017-11-07 Tom Tromey <tom@tromey.com>
2316
2317 * stack.c (backtrace_command): Use std::string.
2318 (backtrace_command_1): Make "count_exp" const.
2319
5614fb77
TT
23202017-11-07 Tom Tromey <tom@tromey.com>
2321
2322 * source.c (directory_switch, mod_path, add_path): Constify.
2323 * defs.h (add_path, mod_path, directory_switch): Constify.
2324 * mi/mi-cmd-env.c (env_mod_path): Constify.
2325
6be9a197
TT
23262017-11-07 Tom Tromey <tom@tromey.com>
2327
2328 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
2329 (run_command_1, continue_command, step_1, jump_command)
2330 (signal_command, until_command, advance_command, finish_command)
2331 (attach_command): Update.
2332
c2252c0d
TT
23332017-11-07 Tom Tromey <tom@tromey.com>
2334
2335 * command.h (set_cmd_cfunc): Don't declare.
2336 * cli/cli-decode.c (set_cmd_cfunc): Now static.
2337
1ee870c5
TT
23382017-11-07 Tom Tromey <tom@tromey.com>
2339
2340 * stack.c (select_frame_command): Constify.
2341 * cli/cli-decode.c (add_com_suppress_notification): Constify.
2342 * command.h (add_com_suppress_notification): Constify.
2343
ee7ddd71
TT
23442017-11-07 Tom Tromey <tom@tromey.com>
2345
2346 * breakpoint.c (stop_command): Constify.
2347 * cli/cli-decode.c (struct cmd_list_element): Constify.
2348 * command.h (add_abbrev_prefix_cmd): Constify.
2349
95e95a6d
PA
23502017-11-07 Pedro Alves <palves@redhat.com>
2351
2352 * breakpoint.c (extract_bp_kind): New enum.
2353 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
2354 factored out from ...
2355 (extract_bp_number_and_location): ... here.
2356 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
2357
cc638e86
PA
23582017-11-07 Pedro Alves <palves@redhat.com>
2359
2360 * breakpoint.c (extract_bp_number_and_location): Change return
2361 type to void. Throw error instead of warning.
2362 (enable_disable_command): Adjust.
2363
d0fe4701
XR
23642017-11-07 Xavier Roirand <roirand@adacore.com>
2365 Pedro Alves <palves@redhat.com>
2366
2367 * breakpoint.c (map_breakpoint_number_range): New, factored out
2368 from ...
2369 (map_breakpoint_numbers): ... here.
2370 (find_location_by_number): Change parameters from string to
2371 breakpoint number and location.
2372 (extract_bp_number_and_location): New function.
2373 (enable_disable_bp_num_loc)
2374 (enable_disable_breakpoint_location_range)
2375 (enable_disable_command): New functions, factored out ...
2376 (enable_command, disable_command): ... these functions, and
2377 adjusted to support ranges.
2378 * NEWS: Document enable/disable breakpoint location range feature.
2379
635dc5b2
LM
23802017-11-06 Luis Machado <luis.machado@linaro.org>
2381
2382 * MAINTAINERS (Write After Approval): Update my e-mail address.
2383
556e5da5
PA
23842017-11-06 Pedro Alves <palves@redhat.com>
2385
2386 * gnu-nat.c (gnu_terminal_init): Delete.
2387 (gnu_target): Don't install gnu_terminal_init.
2388 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
2389 (child_terminal_init): ... this function.
2390
d1928160
PA
23912017-11-06 Pedro Alves <palves@redhat.com>
2392
2393 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
2394 sgtty.h.
2395 * config.in, configure: Regenerate.
2396
6aa899ce
PA
23972017-11-06 Pedro Alves <palves@redhat.com>
2398
2399 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
2400 (async_init_signals): Adjust.
2401 (handle_stop_sig): Rename to ...
2402 (handle_sigtstp): ... this.
2403 (async_stop_sig): Rename to ...
2404 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
2405 SIGTSTP path.
2406 * event-top.h: Move signal.h include to the top. Check SIGTSTP
2407 instead of STOP_SIGNAL thoughout.
2408 (handle_stop_sig): Rename to ...
2409 (handle_sigtstp): ... this.
2410 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
2411
a94799ac
PA
24122017-11-06 Pedro Alves <palves@redhat.com>
2413
2414 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
2415 longer set flags twice in row.
2416
726e1356
PA
24172017-11-06 Pedro Alves <palves@redhat.com>
2418
2419 * Makefile.in (SER_HARDWIRE): Update comment.
2420 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
2421 * common/gdb_termios.h: Delete file.
2422 * common/job-control.c: Include termios.h and unistd.h instead of
2423 gdb_termios.h.
2424 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
2425 check.
2426 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
2427 Remove sgtty code.
2428 * configure.ac: No longer check for termio.h and sgtty.h.
2429 * configure: Regenerate.
2430 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
2431 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
2432 Replace PROCESS_GROUP_TYPE references with pid_t references
2433 throughout.
2434 (gdb_getpgrp): Delete.
2435 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
2436 (child_terminal_inferior): Remove comment. Remove sgtty code.
2437 (child_terminal_ours_1): Use tcgetpgrp directly instead of
2438 gdb_getpgrp. Use serial_set_tty_state instead aof
2439 serial_noflush_set_tty_state. Remove sgtty code.
2440 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
2441 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
2442 (inferior_process_group): Now returns pid_t.
2443 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
2444 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
2445 * ser-event.c (serial_event_ops): Update.
2446 * ser-go32.c (dos_noflush_set_tty_state): Delete.
2447 (dos_ops): Update.
2448 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
2449 * ser-pipe.c (pipe_ops): Update.
2450 * ser-tcp.c (tcp_ops): Update.
2451 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
2452 HAVE_TERMIOS checks.
2453 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
2454 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
2455 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
2456 assume termios.
2457 (hardwire_noflush_set_tty_state): Delete.
2458 (hardwire_print_tty_state, hardwire_drain_output)
2459 (hardwire_flush_output, hardwire_flush_input)
2460 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
2461 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
2462 code, and assume termios.
2463 (hardwire_ops): Update.
2464 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
2465 * serial.c (serial_noflush_set_tty_state): Delete.
2466 * serial.h (serial_noflush_set_tty_state): Delete.
2467 (serial_ops::noflush_set_tty_state): Delete.
2468
1cfb73db
UW
24692017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2470
2471 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
2472 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
2473 (COMMON_OBS): Remove doublest.o and dfp.o.
2474 Do not build target-float.c (instead of doublest.c)
2475 with -Wformat-nonliteral.
2476
2477 * doublest.c: Remove file.
2478 * doublest.h: Remove file.
2479 * dfp.c: Remove file.
2480 * dfp.h: Remove file.
2481
2482 * target-float.c: Do not include "doublest.h" and "dfp.h".
2483 (DOUBLEST): Move here from doublest.h.
2484 (enum float_kind): Likewise.
2485 (FLOATFORMAT_CHAR_BIT): Likewise.
2486 (FLOATFORMAT_LARGEST_BYTES): Likewise.
2487 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
2488 (floatformat_precision): Likewise.
2489 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
2490 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
2491 Likewise.
2492 (host_float_format, host_double_format, host_long_double_format):
2493 Likewise.
2494 (floatformat_to_string, floatformat_from_string): Likewise.
2495 (floatformat_to_doublest): Likewise. Also, inline the original
2496 convert_floatformat_to_doublest.
2497 (floatformat_from_doublest): Likewise. Also, inline the original
2498 convert_floatformat_from_doublest.
2499
2500 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
2501 (MAX_DECIMAL_STRING): Move here from dfp.c.
2502 (match_endianness): Likewise.
2503 (set_decnumber_context, decimal_check_errors): Likewise.
2504 (decimal_from_number, decimal_to_number): Likewise.
2505 (decimal_to_string, decimal_from_string): Likewise. Make static.
2506 (decimal_from_longest, decimal_from_ulongest): Likewise.
2507 (decimal_to_longest): Likewise.
2508 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
2509 (decimal_convert): Likewise.
2510
b07e9c46
UW
25112017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2512
2513 * doublest.c: Do not include "gdbtypes.h".
2514 (extract_typed_floating): Remove.
2515 (store_typed_floating): Remove.
2516 (convert_typed_floating): Remove.
2517 * doublest.h (struct type): Remove.
2518 (DOUBLEST_PRINT_FORMAT): Remove.
2519 (DOUBLEST_SCAN_FORMAT): Remove.
2520 (extract_typed_floating): Remove.
2521 (store_typed_floating): Remove.
2522 (convert_typed_floating): Remove.
2523
2524 * dfp.c (decimal_from_doublest): Remove.
2525 (decimal_to_doublest): Remove.
2526 * dfp.h: Do not include "doublest.h".
2527 (decimal_from_doublest): Remove.
2528 (decimal_to_doublest): Remove.
2529
2530 * value.c: Do not include "doublest.h" and "dfp.h".
2531 (value_as_double): Remove.
2532 (unpack_double): Remove.
2533 (value_from_double): Remove.
2534 (value_from_decfloat): Remove.
2535 * value.h: Do not include "doublest.h".
2536 (value_as_double): Remove.
2537 (unpack_double): Remove.
2538 (value_from_double): Remove.
2539 (value_from_decfloat): Remove.
2540
3b2ca824
UW
25412017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2542
2543 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
2544 (i386_extract_return_value): Use target_float_convert.
2545 (i386_store_return_value): Likewise.
2546 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
2547 (i387_value_to_register): Likewise.
2548 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
2549 (ia64_register_to_value): Use target_float_convert.
2550 (ia64_value_to_register): Likewise.
2551 (ia64_extract_return_value): Likewise.
2552 (ia64_store_return_value): Likewise.
2553 (ia64_push_dummy_call): Likewise.
2554 * m68k-tdep.c: Include "target-float.h".
2555 (m68k_register_to_value): Use target_float_convert.
2556 (m68k_value_to_register): Likewise.
2557 (m68k_svr4_extract_return_value): Likewise.
2558 (m68k_svr4_store_return_value): Likewise.
2559 * ppc-sysv-tdep.c: Include "target-float.h".
2560 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
2561 (do_ppc_sysv_return_value): Likewise.
2562 (ppc64_sysv_abi_push_freg): Likewise.
2563 (ppc64_sysv_abi_return_value_base): Likewise.
2564 * rs6000-aix-tdep.c: Include "target-float.h".
2565 (rs6000_push_dummy_call): Use target_float_convert.
2566 (rs6000_return_value): Likewise.
2567 * rs6000-lynx178-tdep.c: Include "target-float.h".
2568 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
2569 (rs6000_lynx178_return_value): Likewise.
2570 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
2571 (rs6000_register_to_value): Use target_float_convert.
2572 (rs6000_value_to_register): Likewise.
2573 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
2574 (arm_extract_return_value): Use target_float_convert.
2575 (arm_store_return_value): Likewise.
2576 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
2577 (sh_register_convert_to_virtual): Use target_float_convert.
2578 (sh_register_convert_to_raw): Likewise.
2579 * sh64-tdep.c: Include "target-float.h".
2580 (sh64_extract_return_value): Use target_float_convert.
2581 (sh64_register_convert_to_virtual): Likewise.
2582 (sh64_register_convert_to_raw): Likewise. Fix argument types.
2583
14ad9311
UW
25842017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2585
2586 * target-float.c (floatformat_to_host_double): New function.
2587 (floatformat_from_host_double): Likewise.
2588 (target_float_to_host_double): Likewise.
2589 (target_float_from_host_double): Likewise.
2590 * target-float.h (target_float_to_host_double): Add prototype.
2591 (target_float_from_host_double): Likewise.
2592
2593 * guile/scm-value.c: Include "target-float.h".
2594 (gdbscm_value_to_real): Use target_float_to_host_double.
2595 Handle integer source values via value_as_long.
2596 * guile/scm-math.c: Include "target-float.h". Do not include
2597 "doublest.h", "dfp.h", and "expression.h".
2598 (vlscm_convert_typed_number): Use target_float_from_host_double.
2599 (vlscm_convert_number): Likewise.
2600
2601 * python/py-value.c (valpy_float): Use target_float_to_host_double.
2602 (convert_value_from_python): Use target_float_from_host_double.
2603
50eff16b
UW
26042017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2605
2606 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
2607 (cast_from_fixed): Likewise.
2608 (ada_scaling_type): New function.
2609 (ada_delta): Return value instead of DOUBLEST. Perform target
2610 arithmetic instead of host arithmetic.
2611 (scaling_factor): Rename to ...
2612 (ada_scaling_factor) ... this. Make non-static. Return value instead
2613 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
2614 (ada_fixed_to_float): Remove.
2615 (ada_float_to_fixed): Remove.
2616 * ada-lang.h (ada_fixed_to_float): Remove.
2617 (ada_float_to_fixed): Remove.
2618 (ada_delta): Return value instead of DOUBLEST.
2619 (ada_scaling_factor): Add prototype.
2620
2621 * ada-typeprint.c: Include "target-float.h".
2622 (print_fixed_point_type): Perform target arithmetic instead of
2623 host arithmetic.
2624 * ada-valprint.c: Include "target-float.h".
2625 (ada_val_print_num): Perform target arithmetic instead of
2626 host arithmetic for fixed-point types.
2627
66c02b9e
UW
26282017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2629
2630 * target-float.c: Include <math.h>.
2631 (floatformat_binop): New function.
2632 (floatformat_compare): Likewise.
2633 (target_float_binop): Likewise.
2634 (target_float_compare): Likewise.
2635 * target-float.h: Include "expression.h".
2636 (target_float_binop): Add prototype.
2637 (target_float_compare): Likewise.
2638
2639 * valarith.c: Do not include "doublest.h" and "dfp.h".
2640 Include "common/byte-vector.h".
2641 (value_args_as_decimal): Remove, replace by ...
2642 (value_args_as_target_float): ... this function. Handle both
2643 binary and decimal target floating-point formats.
2644 (scalar_binop): Handle both binary and decimal FP using
2645 value_args_as_target_float and target_float_binop.
2646 (value_equal): Handle both binary and decimal FP using
2647 value_args_as_target_float and target_float_compare.
2648 (value_less): Likewise.
2649 (value_pos): Handle all scalar types as simple copy.
2650 (value_neg): Handle all scalar types via BINOP_SUB from 0.
2651 * dfp.c (decimal_binop): Throw error instead of internal_error
2652 when called with an unsupported operation code.
2653
f69fdf9b
UW
26542017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2655
2656 * target-float.c (target_float_to_string): New function.
2657 (target_float_from_string): New function.
2658 * target-float.h (target_float_to_string): Add prototype.
2659 (target_float_from_string): Add prototype.
2660
2661 * valprint.c: Include "target-float.h". Do not include
2662 "doublest.h" and "dfp.h".
2663 (print_floating): Use target_float_to_string.
2664 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
2665 (printf_floating): Use target_float_to_string.
2666 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
2667 (print_i387_value): Use target_float_to_string.
2668 * mips-tdep.c: Include "target-float.h".
2669 (mips_print_fp_register): Use target_float_to_string.
2670 * sh64-tdep.c: Include "target-float.h".
2671 (sh64_do_fp_register): Use target_float_to_string.
2672
2673 * parse.c: Include "target-float.h". Do not include
2674 "doublest.h" and "dfp.h".
2675 (parse_float): Use target_float_from_string.
2676 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
2677 (define_symbol): Use target_float_from_string.
2678 * gdbarch-selftests.c: Include "target-float.h".
2679 (register_to_value_test): Use target_float_from_string.
2680
70100014
UW
26812017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2682
2683 * Makefile.c (SFILES): Add target-float.c.
2684 (HFILES_NO_SRCDIR): Add target-float.h.
2685 (COMMON_OBS): Add target-float.o.
2686 * target-float.h: New file.
2687 * target-float.c: New file.
2688
2689 * doublest.c (floatformat_classify): Fix detection of float_zero.
2690
2691 * gdbtypes.c (is_floating_type): New function.
2692 * gdbtypes.h (is_floating_type): Add prototype.
2693
2694 * value.c: Do not include "floatformat.h".
2695 (unpack_double): Use target_float_is_valid.
2696 (is_floating_value): New function.
2697 * value.h (is_floating_value): Add prototype-
2698
2699 * valarith.c: Include "target-float.h".
2700 (value_logical_not): Use target_float_is_zero.
2701
2702 * python/py-value.c: Include "target-float.h".
2703 (valpy_nonzero): Use target_float_is_zero.
2704
ab4b1c46
TT
27052017-11-04 Tom Tromey <tom@tromey.com>
2706
2707 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
2708
454dafbd
TT
27092017-11-04 Tom Tromey <tom@tromey.com>
2710
2711 * breakpoint.c (set_momentary_breakpoint): Return
2712 breakpoint_up.
2713 (until_break_command): Update.
2714 (new_until_break_fsm): Change argument types to
2715 breakpoint_up.
2716 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
2717 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
2718 Remove.
2719 * infcmd.c (finish_forward): Update.
2720 * breakpoint.h (set_momentary_breakpoint)
2721 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
2722 (make_cleanup_delete_breakpoint): Remove.
2723 (struct breakpoint_deleter): New.
2724 (breakpoint_up): New typedef.
2725 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
2726 (insert_exception_resume_breakpoint): Update.
2727 (insert_exception_resume_from_probe): Update.
2728 (insert_longjmp_resume_breakpoint): Update.
2729 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
2730 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
2731 * infcall.c (call_function_by_hand_dummy): Update
2732
331b71e5
TT
27332017-11-04 Tom Tromey <tom@tromey.com>
2734
2735 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
2736
9f584b37
TT
27372017-11-04 Tom Tromey <tom@tromey.com>
2738
2739 * linux-tdep.c (linux_core_info_proc_mappings): Use
2740 gdb::def_vector.
2741 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
2742 "size" argument.
2743 (linux_corefile_thread): Update.
2744 (linux_make_corefile_notes): Remove unused variable.
2745
779bc38e
TT
27462017-11-04 Tom Tromey <tom@tromey.com>
2747
2748 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
2749 gdb::byte_vector.
2750
ed2b3126
TT
27512017-11-04 Tom Tromey <tom@tromey.com>
2752
2753 * objfiles.c (do_free_objfile_cleanup): Remove.
2754 * compile/compile-object-load.c (compile_object_load): Update.
2755 * objfiles.h (make_cleanup_free_objfile): Remove.
2756
7f6743fd
TT
27572017-11-04 Tom Tromey <tom@tromey.com>
2758
2759 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
2760 (adi_read_versions): Change "tags" to "gdb_byte *".
2761 (adi_print_versions): Likewise.
2762
c80049d3
TT
27632017-11-04 Tom Tromey <tom@tromey.com>
2764
2765 * breakpoint.c
2766 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
2767 from start_rbreak_breakpoints.
2768 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
2769 * breakpoint.h (class scoped_rbreak_breakpoints): New.
2770 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
2771 * symtab.c (do_end_rbreak_breakpoints): Remove.
2772 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
2773
167b0be1
TT
27742017-11-04 Tom Tromey <tom@tromey.com>
2775
2776 * cp-namespace.c (reset_directive_searched): Remove.
2777 (cp_lookup_symbol_via_imports): Use scoped_restore.
2778 * cp-support.c (reset_directive_searched): Remove.
2779 (make_symbol_overload_list_using): Use scoped_restore.
2780 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
2781 (reset_directive_searched): Remove.
2782
5eae7aea
TT
27832017-11-04 Tom Tromey <tom@tromey.com>
2784
2785 * symfile.c (find_separate_debug_file_by_debuglink): Use
2786 unique_xmalloc_ptr.
2787
c6bcad5f
TT
27882017-11-04 Tom Tromey <tom@tromey.com>
2789
2790 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
2791 type of "info".
2792 (compute_stack_depth): Likewise.
2793 (do_compile_dwarf_expr_to_c): Use std::vector.
2794
20dcd8ca
TT
27952017-11-04 Tom Tromey <tom@tromey.com>
2796
2797 * compile/compile-object-load.c (link_callbacks_einfo): Use
2798 std::string.
2799
33c7c59d
TT
28002017-11-04 Tom Tromey <tom@tromey.com>
2801
2802 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
2803 Use scoped_free_pendings.
2804 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
2805 scoped_free_pendings.
2806 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
2807 (xcoff_initial_scan): Likewise.
2808 * buildsym.c (reset_symtab_globals): Update comment.
2809 (scoped_free_pendings): Rename from really_free_pendings.
2810 (prepare_for_building): Update comment.
2811 (buildsym_init): Likewise.
2812 * buildsym.h (class scoped_free_pendings): New class.
2813 (really_free_pendings): Don't declare.
2814
67fa57cf
UW
28152017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
2816
2817 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
2818 output when converting a zero value to a special byteorder format.
2819
f26ae15b
YQ
28202017-11-02 Yao Qi <yao.qi@linaro.org>
2821
2822 * frame.c (do_frame_register_read): Remove aspace.
2823 * jit.c (jit_frame_sniffer): Likwise.
2824 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
2825 * regcache.c (regcache::regcache): Pass nullptr.
2826 (regcache_print): Caller updated.
2827 * regcache.h (regcache::regcache): Remove one constructor
2828 parameter aspace.
2829
6c6e9412
YQ
28302017-11-02 Yao Qi <yao.qi@linaro.org>
2831
2832 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
2833
8b86c959
YQ
28342017-11-02 Yao Qi <yao.qi@linaro.org>
2835
2836 * breakpoint.c (insert_single_step_breakpoints): Update.
2837 * frame.c (struct frame_info) <aspace>: Add const.
2838 (frame_save_as_regcache): Add const.
2839 (get_frame_address_space): Return const address_space *.
2840 * frame.h (get_frame_address_space): Update declaration.
2841 * infrun.c (struct step_over_info) <aspace>: Add const.
2842 (set_step_over_info): Make aspace const.
2843 (displaced_step_prepare_throw): Change variable const.
2844 (resume): Likewise.
2845 (proceed): Likewise.
2846 (adjust_pc_after_break): Likewise.
2847 (save_waitstatus): Likewise.
2848 (handle_signal_stop): Likewise.
2849 (keep_going_pass_signal): Likewise.
2850 * jit.c (jit_frame_sniffer): Add const.
2851 * mips-tdep.c (mips_single_step_through_delay): Likewise.
2852 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
2853 * record-full.c (record_full_wait_1): Likewise.
2854 * regcache.c (regcache::regcache): Change parameter to const.
2855 * regcache.h (regcache::regcache): Likewise.
2856 (regcache::aspace): Return const address_space *.
2857 (regcache) <m_aspace>: Add const.
2858
a01bda52
YQ
28592017-11-02 Yao Qi <yao.qi@linaro.org>
2860
2861 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
2862 * frame.c (create_sentinel_frame): Likewise.
2863 * infrun.c (displaced_step_prepare_throw): Likewise.
2864 (resume): Likewise.
2865 (thread_still_needs_step_over_bp): Likewise.
2866 (proceed): Likewise.
2867 (do_target_wait): Likewise.
2868 (adjust_pc_after_break): Likewise.
2869 (handle_syscall_event): Likewise.
2870 (save_waitstatus): Likewise.
2871 (handle_inferior_event_1): Likewise.
2872 (handle_signal_stop): Likewise.
2873 (keep_going_pass_signal): Likewise.
2874 * linux-nat.c (status_callback): Likewise.
2875 (save_stop_reason): Likewise.
2876 (resume_stopped_resumed_lwps): Likewise.
2877 * record-full.c (record_full_exec_insn): Likewise.
2878 (record_full_wait_1): Likewise.
2879 * regcache.c (get_regcache_aspace): Remove.
2880 * regcache.h (get_regcache_aspace): Remove.
2881
d999647b
YQ
28822017-11-02 Yao Qi <yao.qi@linaro.org>
2883
2884 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
2885 (init_regcache_descr): Use gdbarch_num_regs.
2886 (regcache::regcache): Likewise.
2887 (regcache::get_register_status): Likewise.
2888 (regcache::assert_raw_regnum): Likewise.
2889 (regcache::cooked_read): Likewise.
2890 (regcache::cooked_read_value): Likewise.
2891 (regcache::cooked_write): Likewise.
2892 (regcache::dump): Likewise.
2893 (regcache::num_raw_registers): New method.
2894 * regcache.h (class regcache) <num_raw_registers>: New.
2895
4e888c28
YQ
28962017-11-02 Yao Qi <yao.qi@linaro.org>
2897
2898 * regcache.c (regcache::assert_regnum): New method.
2899 (regcache::invalidate): Call assert_regnum.
2900 (regcache::raw_update): Likewise.
2901 (regcache::raw_write): Likewise.
2902 (regcache::raw_read_part): Likewise.
2903 (regcache::raw_write_part): Likewise.
2904 (regcache::raw_supply): Likewise.
2905 (regcache::raw_supply_integer): Likewise.
2906 (regcache::raw_supply_zeroed): Likewise.
2907 (regcache::raw_collect): Likewise.
2908 (regcache::raw_collect_integer): Likewise.
2909 * regcache.h (regcache::assert_regnum): Declare.
2910
2e1b49b3
YQ
29112017-11-02 Yao Qi <yao.qi@linaro.org>
2912
2913 * regcache.c (regcache::dump): Remove code.
2914
6c5218df
YQ
29152017-11-02 Yao Qi <yao.qi@linaro.org>
2916
2917 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
2918 Remove.
2919 <sizeof_cooked_register_status>: Remove.
2920 (init_regcache_descr): Update.
2921 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
2922 (regcache::save): Likewise.
2923 (regcache::dump): Likewise.
2924
dcc31d28
JB
29252017-11-01 James Bowman <james.bowman@ftdichip.com>
2926
2927 * ft32-tdep.c (ft32_fetch_instruction): New function.
2928 (ft32_analyze_prologue): Use ft32_fetch_instruction().
2929
3a87ae65
SM
29302017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
2931
2932 * cli/cli-script.c (execute_control_command): Rename to ...
2933 (execute_control_command_1): ... this.
2934 (execute_control_command): New function.
2935
09b847f3
SM
29362017-10-31 Simon Marchi <simon.marchi@ericsson.com>
2937
2938 * tracepoint.c (tfind_command): Remove const_cast.
2939
f871c485
MG
29402017-10-30 Mike Gulick <mgulick@mathworks.com>
2941
2942 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
2943
b020ff80
SM
29442017-10-30 Simon Marchi <simon.marchi@ericsson.com>
2945
2946 * common/common-utils.h (in_inclusive_range): New function.
2947 * arm-tdep.c (arm_record_extension_space): Use
2948 in_inclusive_range.
2949 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
2950 * cris-tdep.c (cris_spec_reg_applicable): Use
2951 in_inclusive_range.
2952
1b81856f
PA
29532017-10-30 Pedro Alves <palves@redhat.com>
2954 Simon Marchi <simon.marchi@ericsson.com>
2955
2956 * remote.c (remote_set_syscall_catchpoint): Build a std::string
2957 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
2958
31b833b3
PA
29592017-10-30 Pedro Alves <palves@redhat.com>
2960
2961 * common/common-utils.c (string_appendf, string_vappendf): New
2962 functions.
2963 * common/common-utils.h (string_appendf, string_vappendf): New
2964 declarations.
2965 * unittests/common-utils-selftests.c (string_appendf_func)
2966 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
2967 (string_vappendf_tests): New functions.
2968 (_initialize_common_utils_selftests): Register "string_appendf" and
2969 "string_vappendf tests".
2970
4a250334
PA
29712017-10-30 Pedro Alves <palves@redhat.com>
2972
2973 * unittests/common-utils-selftests.c (format_func): New typedef.
2974 (string_printf_tests, string_vprintf_tests): Tests factored out
2975 and merged to ...
2976 (test_format_func): ... this new function.
2977 (string_printf_tests, string_vprintf_tests): Reimplement on top of
2978 test_format_func.
2979
16c5c17e
SM
29802017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2981
2982 * darwin-nat.c: Remove include of gdb.h.
2983
7ca51576
SM
29842017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2985
2986 * xtensa-xtregs.c: Fix formatting issues.
2987
c1342859
SM
29882017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2989
2990 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
2991
484d8d36
MD
29922017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
2993
2994 PR python/21213
2995 * python/py-infthread.c (thpy_get_inferior): Increment reference
2996 of inferior before returning it.
2997
b5540b5f
SM
29982017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2999
3000 * unittests/common-utils-selftests.c (format): Add
3001 ATTRIBUTE_PRINTF.
3002
5a9dcda1
SM
30032017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
3004
3005 * xml-syscall.c (struct syscall_desc): Add constructor.
3006 <name>: Change type to std::string.
3007 (syscall_desc_up): New typedef.
3008 (syscall_desc_p): Remove typeder.
3009 (DEF_VEC_P(syscall_desc_p)): Remove.
3010 (struct syscall_group_desc): Add constructor.
3011 <name>: Change type to std::string.
3012 <syscalls>: Change type to std::vector.
3013 (syscall_group_desc_up): New typedef.
3014 (syscall_group_desc_p): Remove typedef.
3015 (DEF_VEC_P(syscall_group_desc_p)): Remove.
3016 (struct syscalls_info) <syscalls>: Change type to std::vector of
3017 unique_ptr.
3018 <groups>: Likewise.
3019 <my_gdb_datadir>: Change type to std::string.
3020 (syscalls_info_up): New typedef.
3021 (allocate_syscalls_info): Remove.
3022 (syscalls_info_free_syscalls_desc): Remove.
3023 (syscalls_info_free_syscall_group_desc): Remove.
3024 (free_syscalls_info): Remove.
3025 (make_cleanup_free_syscalls_info): Remove.
3026 (syscall_group_create_syscall_group_desc): Adjust.
3027 (syscall_group_add_syscall): Adjust.
3028 (syscall_create_syscall_desc): Adjust.
3029 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
3030 (init_syscalls_info): Adjust.
3031 (syscall_group_get_group_by_name): Adjust.
3032 (xml_get_syscall_number): Adjust.
3033 (xml_get_syscall_name): Adjust.
3034 (xml_list_of_syscalls): Adjust.
3035 (xml_list_syscalls_by_group): Adjust.
3036 (xml_list_of_groups): Adjust.
3037
45461e0d
SM
30382017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3039
3040 * probe.h: Don't include gdb_vecs.h.
3041 (DEF_VEC_P (probe_p)): Remove.
3042 (find_probes_in_objfile): Return an std::vector.
3043 * probe.c (find_probes_in_objfile): Likewise.
3044 * breakpoint.c (breakpoint_objfile_data)
3045 <longjmp_probes>: Change type to std::vector.
3046 <exception_probes>: Likewise.
3047 (free_breakpoint_probes): Don't manually free vectors.
3048 (create_longjmp_master_breakpoint): Adjust.
3049 (create_exception_master_breakpoint): Adjust.
3050 * solib-svr4.c (svr4_create_probe_breakpoints): Change
3051 parameter type, adjust.
3052 (svr4_create_solib_event_breakpoints): Adjust.
3053
43dce439
SM
30542017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3055
3056 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
3057 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
3058 with new.
3059 (free_breakpoint_probes): Rename to ...
3060 (free_breakpoint_objfile_data): ... this, and call delete on
3061 bp_objfile_data..
3062
6a1b9516
SM
30632017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
3064
3065 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
3066 (loaded_script_ptr): Remove typedef.
3067 (DEF_VEC_P (loaded_script_ptr)): Remove.
3068 (struct collect_matching_scripts_data): Add constructor.
3069 <scripts_p>: Change type to (pointer to) std::vector.
3070 (collect_matching_scripts_data): Adjust.
3071 (sort_scripts_by_name): Make suitable for std::sort.
3072 (print_scripts): Don't sort vector, adjust to std::vector.
3073 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
3074
593e3209
SM
30752017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3076
3077 * symfile.c (filename_language): Make struct, not typedef. Add
3078 constructor.
3079 <ext>: Change type to std::string.
3080 (DEF_VEC_O (filename_language)): Remove.
3081 (filename_language_table): Change type to std::vector.
3082 (add_filename_language): Adjust.
3083 (set_ext_lang_command): Adjust.
3084 (info_ext_lang_command): Adjust.
3085 (deduce_language_from_filename): Adjust.
3086 (class scoped_restore_filename_language_table): Remove.
3087 (test_filename_language): Use scoped_restore.
3088 (test_set_ext_lang_command): Use scoped_restore, adjust to
3089 std::vector change.
3090
32fa66eb
SM
30912017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3092
3093 * symfile.c: Include selftest.h.
3094 (class scoped_restore_filename_language_table): New.
3095 (test_filename_language): New test.
3096 (test_set_ext_lang_command): New test.
3097 (_initialize_symfile): Register tests.
3098
4a27f119
KS
30992017-10-27 Keith Seitz <keiths@redhat.com>
3100
3101 * breakpoint.c (print_breakpoint_location): Use the symbol saved
3102 in the bp_location, falling back to find_pc_sect_function when
3103 needed.
3104 (add_location_to_breakpoint): Save sal->symbol.
3105 * breakpoint.h (struct bp_location) <symbol>: New field.
3106 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
3107 * symtab.h (struct symtab_and_line) <symbol>: New field.
3108
a43f3893
PF
31092017-10-26 Patrick Frants <osscontribute@gmail.com>
3110
7453e6b2 3111 PR gdb/13669
a43f3893
PF
3112 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
3113 to rewind obstack.
3114
23cc4e1b
PA
31152017-10-26 Pedro Alves <palves@redhat.com>
3116
3117 * remote.c (remote_async_terminal_ours_p): Delete.
3118 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
3119 Remove references to 'remote_async_terminal_ours_p'.
3120
6abc18bb
YQ
31212017-10-26 Yao Qi <yao.qi@linaro.org>
3122
3123 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
3124
bd522513
YQ
31252017-10-26 Yao Qi <yao.qi@linaro.org>
3126
3127 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
3128 aspace const.
3129 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
3130 Likewise.
3131 * breakpoint.c (bpstat_check_location): Remove cast.
3132 (breakpoint_hit_catch_fork): Make aspce const.
3133 (breakpoint_hit_catch_solib): Likewise.
3134 (breakpoint_hit_catch_exec): Likewise.
3135 (breakpoint_hit_ranged_breakpoint): Likewise.
3136 (breakpoint_hit_watchpoint): Likewise.
3137 (base_breakpoint_breakpoint_hit): Likewise.
3138 (bkpt_breakpoint_hit): Likewise.
3139 (dprintf_breakpoint_hit): Likewise.
3140 (tracepoint_breakpoint_hit): Likewise.
3141 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
3142
accd0bcd
YQ
31432017-10-26 Yao Qi <yao.qi@linaro.org>
3144
3145 * breakpoint.c (breakpoint_location_address_match): Change
3146 "struct address_space *" to "const address_space".
3147 (breakpoint_location_address_range_overlap): Likewise.
3148 (breakpoint_here_p): Likewise.
3149 (breakpoint_in_range_p): Likewise.
3150 (moribund_breakpoint_here_p): Likewise.
3151 (bp_location_inserted_here_p): Likewise.
3152 (software_breakpoint_inserted_here_p): Likewise.
3153 (hardware_breakpoint_inserted_here_p): Likewise.
3154 (hardware_watchpoint_inserted_in_range): Likewise.
3155 (bpstat_check_location): Likewise.
3156 (bpstat_stop_status): Likewise.
3157 (breakpoint_address_match): Likewise.
3158 (breakpoint_address_match_range): Likewise.
3159 (breakpoint_location_address_match): Likewise.
3160 (breakpoint_location_address_range_overlap): Likewise.
3161 (insert_single_step_breakpoint): Likewise.
3162 (breakpoint_has_location_inserted_here): Likewise.
3163 (single_step_breakpoint_inserted_here_p): Likewise.
3164 (pc_at_non_inline_function): Likewise.
3165 * breakpoint.h (bpstat_stop_status): Update declaration.
3166 (breakpoint_here_p): Likewise.
3167 (breakpoint_in_range_p): Likewise.
3168 (moribund_breakpoint_here_p): Likewise.
3169 (breakpoint_inserted_here_p): Likewise.
3170 (software_breakpoint_inserted_here_p): Likewise.
3171 (hardware_breakpoint_inserted_here_p): Likewise.
3172 (breakpoint_has_location_inserted_here): Likewise.
3173 (single_step_breakpoint_inserted_here_p): Likewise.
3174 (hardware_watchpoint_inserted_in_range): Likewise.
3175 (breakpoint_address_match): Likewise.
3176 (insert_single_step_breakpoint): Likewise.
3177 (pc_at_non_inline_function): Likewise.
3178 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
3179 * record.c (record_check_stopped_by_breakpoint): Likewise.
3180 * record.h (record_check_stopped_by_breakpoint): Likewise.
3181 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
3182
ac7936df
YQ
31832017-10-25 Yao Qi <yao.qi@linaro.org>
3184
3185 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
3186 regcache->arch () instead get_regcache_arch.
3187 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
3188 Likewise.
3189 (aarch64_fbsd_store_inferior_registers): Likewise.
3190 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
3191 (store_gregs_to_thread): Likewise.
3192 (fetch_fpregs_from_thread): Likewise.
3193 (store_fpregs_to_thread): Likewise.
3194 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
3195 (aarch64_store_return_value): Likewise.
3196 (aarch64_software_single_step): Likewise.
3197 * aix-thread.c (aix_thread_wait): Likewise.
3198 (supply_reg32): Likewise.
3199 (supply_sprs64): Likewise.
3200 (supply_sprs32): Likewise.
3201 (fill_gprs64): Likewise.
3202 (fill_gprs32): Likewise.
3203 (fill_sprs64): Likewise.
3204 (fill_sprs32): Likewise.
3205 (store_regs_user_thread): Likewise.
3206 (store_regs_kernel_thread): Likewise.
3207 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
3208 (alphabsd_store_inferior_registers): Likewise.
3209 * alpha-tdep.c (alpha_extract_return_value): Likewise.
3210 (alpha_store_return_value): Likewise.
3211 (alpha_deal_with_atomic_sequence): Likewise.
3212 (alpha_next_pc): Likewise.
3213 (alpha_software_single_step): Likewise.
3214 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
3215 (amd64bsd_store_inferior_registers): Likewise.
3216 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
3217 Likewise.
3218 (amd64_linux_store_inferior_registers): Likewise.
3219 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
3220 (amd64_collect_native_gregset): Likewise.
3221 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
3222 (amd64obsd_collect_uthread): Likewise.
3223 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
3224 (amd64_collect_fpregset): Likewise.
3225 (amd64_supply_fxsave): Likewise.
3226 (amd64_supply_xsave): Likewise.
3227 (amd64_collect_fxsave): Likewise.
3228 (amd64_collect_xsave): Likewise.
3229 * arc-tdep.c (arc_write_pc): Likewise.
3230 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
3231 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
3232 (arm_fbsd_store_inferior_registers): Likewise.
3233 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
3234 (store_vfp_regs): Likewise.
3235 (arm_linux_fetch_inferior_registers): Likewise.
3236 (arm_linux_store_inferior_registers): Likewise.
3237 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
3238 (arm_linux_sigreturn_next_pc): Likewise.
3239 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
3240 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
3241 (fetch_register): Likewise.
3242 (store_register): Likewise.
3243 * arm-tdep.c (arm_is_thumb): Likewise.
3244 (displaced_in_arm_mode): Likewise.
3245 (bx_write_pc): Likewise.
3246 (arm_get_next_pcs_addr_bits_remove): Likewise.
3247 (arm_software_single_step): Likewise.
3248 (arm_extract_return_value): Likewise.
3249 (arm_store_return_value): Likewise.
3250 (arm_write_pc): Likewise.
3251 * bfin-tdep.c (bfin_extract_return_value): Likewise.
3252 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
3253 (bsd_uthread_store_registers): Likewise.
3254 * core-regset.c (fetch_core_registers): Likewise.
3255 * corelow.c (get_core_registers): Likewise.
3256 * cris-tdep.c (cris_store_return_value): Likewise.
3257 (cris_extract_return_value): Likewise.
3258 (find_step_target): Likewise.
3259 (find_step_target): Likewise.
3260 (cris_software_single_step): Likewise.
3261 * ctf.c (ctf_fetch_registers): Likewise.
3262 * darwin-nat.c (cancel_breakpoint): Likewise.
3263 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
3264 * frv-tdep.c (frv_extract_return_value): Likewise.
3265 * ft32-tdep.c (ft32_store_return_value): Likewise.
3266 (ft32_extract_return_value): Likewise.
3267 * go32-nat.c (fetch_register): Likewise.
3268 (go32_fetch_registers): Likewise.
3269 (go32_store_registers): Likewise.
3270 (store_register): Likewise.
3271 * h8300-tdep.c (h8300_extract_return_value): Likewise.
3272 (h8300_store_return_value): Likewise.
3273 * hppa-linux-nat.c (fetch_register): Likewise.
3274 (store_register): Likewise.
3275 (hppa_linux_fetch_inferior_registers): Likewise.
3276 (hppa_linux_store_inferior_registers): Likewise.
3277 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
3278 (i386_darwin_store_inferior_registers): Likewise.
3279 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
3280 (gnu_store_registers): Likewise.
3281 * i386-linux-nat.c (fetch_register): Likewise.
3282 (store_register): Likewise.
3283 (supply_gregset): Likewise.
3284 (fill_gregset): Likewise.
3285 (i386_linux_fetch_inferior_registers): Likewise.
3286 (i386_linux_store_inferior_registers): Likewise.
3287 (i386_linux_resume): Likewise.
3288 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
3289 Likewise.
3290 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
3291 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
3292 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
3293 (i386obsd_collect_uthread): Likewise.
3294 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
3295 (i386_supply_gregset): Likewise.
3296 (i386_collect_gregset): Likewise.
3297 (i386_supply_fpregset): Likewise.
3298 (i386_collect_fpregset): Likewise.
3299 (i386_mpx_bd_base): Likewise.
3300 * i386-v4-nat.c (supply_fpregset): Likewise.
3301 (fill_fpregset): Likewise.
3302 * i387-tdep.c (i387_supply_fsave): Likewise.
3303 (i387_collect_fsave): Likewise.
3304 (i387_supply_fxsave): Likewise.
3305 (i387_collect_fxsave): Likewise.
3306 (i387_supply_xsave): Likewise.
3307 (i387_collect_xsave): Likewise.
3308 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
3309 (ia64_linux_store_registers): Likewise.
3310 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
3311 (ia64_extract_return_value): Likewise.
3312 (ia64_store_return_value): Likewise.
3313 (find_func_descr): Likewise.
3314 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
3315 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
3316 (inf_ptrace_store_registers): Likewise.
3317 * infrun.c (use_displaced_stepping): Likewise.
3318 (displaced_step_prepare_throw): Likewise.
3319 (resume): Likewise.
3320 (proceed): Likewise.
3321 (do_target_wait): Likewise.
3322 (adjust_pc_after_break): Likewise.
3323 (handle_inferior_event_1): Likewise.
3324 (handle_signal_stop): Likewise.
3325 (save_infcall_suspend_state): Likewise.
3326 (restore_infcall_suspend_state): Likewise.
3327 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
3328 * jit.c (jit_frame_prev_register): Likewise.
3329 * linux-nat.c (save_stop_reason): Likewise.
3330 (linux_nat_wait_1): Likewise.
3331 (resume_stopped_resumed_lwps): Likewise.
3332 * linux-record.c (record_linux_sockaddr): Likewise.
3333 (record_linux_msghdr): Likewise.
3334 (record_linux_system_call): Likewise.
3335 * linux-tdep.c (linux_collect_thread_registers): Likewise.
3336 * lm32-tdep.c (lm32_extract_return_value): Likewise.
3337 (lm32_store_return_value): Likewise.
3338 * m32c-tdep.c (m32c_read_flg): Likewise.
3339 (m32c_pseudo_register_read): Likewise.
3340 (m32c_pseudo_register_write): Likewise.
3341 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
3342 (m32r_linux_collect_gregset): Likewise.
3343 * m32r-tdep.c (m32r_store_return_value): Likewise.
3344 (m32r_extract_return_value): Likewise.
3345 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
3346 (m68kbsd_collect_fpregset): Likewise.
3347 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
3348 * m68k-linux-nat.c (fetch_register): Likewise.
3349 (old_fetch_inferior_registers): Likewise.
3350 (old_store_inferior_registers): Likewise.
3351 (store_regs): Likewise.
3352 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
3353 (m68k_svr4_store_return_value): Likewise.
3354 * m88k-tdep.c (m88k_store_arguments): Likewise.
3355 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
3356 (mi_cmd_data_write_register_values): Likewise.
3357 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
3358 (mips_fbsd_store_inferior_registers): Likewise.
3359 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
3360 (mips_fbsd_supply_gregs): Likewise.
3361 (mips_fbsd_collect_fpregs): Likewise.
3362 (mips_fbsd_collect_gregs): Likewise.
3363 (mips_fbsd_supply_fpregset): Likewise.
3364 (mips_fbsd_collect_fpregset): Likewise.
3365 (mips_fbsd_supply_gregset): Likewise.
3366 (mips_fbsd_collect_gregset): Likewise.
3367 * mips-linux-nat.c (supply_gregset): Likewise.
3368 (fill_gregset): Likewise.
3369 (supply_fpregset): Likewise.
3370 (fill_fpregset): Likewise.
3371 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
3372 (mips_fill_gregset): Likewise.
3373 (mips_supply_fpregset): Likewise.
3374 (mips_fill_fpregset): Likewise.
3375 (mips64_supply_gregset): Likewise.
3376 (micromips_linux_sigframe_validate): Likewise.
3377 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
3378 (mipsnbsd_fetch_inferior_registers): Likewise.
3379 (mipsnbsd_store_inferior_registers): Likewise.
3380 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
3381 (mipsnbsd_supply_gregset): Likewise.
3382 (mipsnbsd_iterate_over_regset_sections): Likewise.
3383 (mipsnbsd_supply_reg): Likewise.
3384 (mipsnbsd_supply_fpreg): Likewise.
3385 * mips-tdep.c (mips_in_frame_stub): Likewise.
3386 (mips_dummy_id): Likewise.
3387 (is_octeon_bbit_op): Likewise.
3388 (micromips_bc1_pc): Likewise.
3389 (extended_mips16_next_pc): Likewise.
3390 (mips16_next_pc): Likewise.
3391 (deal_with_atomic_sequence): Likewise.
3392 * moxie-tdep.c (moxie_process_readu): Likewise.
3393 * nios2-tdep.c (nios2_get_next_pc): Likewise.
3394 * nto-procfs.c (procfs_store_registers): Likewise.
3395 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
3396 (ppcfbsd_store_inferior_registers): Likewise.
3397 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
3398 (fetch_altivec_register): Likewise.
3399 (get_spe_registers): Likewise.
3400 (fetch_spe_register): Likewise.
3401 (fetch_altivec_registers): Likewise.
3402 (fetch_all_gp_regs): Likewise.
3403 (fetch_all_fp_regs): Likewise.
3404 (store_vsx_register): Likewise.
3405 (store_altivec_register): Likewise.
3406 (set_spe_registers): Likewise.
3407 (store_spe_register): Likewise.
3408 (store_altivec_registers): Likewise.
3409 (store_all_gp_regs): Likewise.
3410 (store_all_fp_regs): Likewise.
3411 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
3412 (ppc_linux_collect_gregset): Likewise.
3413 (ppc_canonicalize_syscall): Likewise.
3414 (ppc_linux_record_signal): Likewise.
3415 (ppu2spu_prev_register): Likewise.
3416 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
3417 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
3418 (ppcobsd_store_registers): Likewise.
3419 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
3420 Likewise.
3421 (ppc_ravenscar_generic_store_registers): Likewise.
3422 * procfs.c (procfs_fetch_registers): Likewise.
3423 (procfs_store_registers): Likewise.
3424 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
3425 (ravenscar_store_registers): Likewise.
3426 (ravenscar_prepare_to_store): Likewise.
3427 * record-btrace.c (record_btrace_fetch_registers): Likewise.
3428 * record-full.c (record_full_wait_1): Likewise.
3429 (record_full_registers_change): Likewise.
3430 (record_full_store_registers): Likewise.
3431 (record_full_core_fetch_registers): Likewise.
3432 (record_full_save): Likewise.
3433 (record_full_goto_insn): Likewise.
3434 * regcache.c (regcache_register_size): Likewise.
3435 (get_regcache_arch): Remove.
3436 (regcache_read_pc): Likewise.
3437 * regcache.h (get_regcache_arch): Remove.
3438 * remote-sim.c (gdbsim_fetch_register): Likewise.
3439 (gdbsim_store_register): Likewise.
3440 * remote.c (fetch_register_using_p): Likewise.
3441 (send_g_packet): Likewise.
3442 (remote_prepare_to_store): Likewise.
3443 (store_registers_using_G): Likewise.
3444 * reverse.c (save_bookmark_command): Likewise.
3445 (goto_bookmark_command): Likewise.
3446 * rs6000-aix-tdep.c (branch_dest): Likewise.
3447 * rs6000-nat.c (rs6000_ptrace64): Likewise.
3448 (fetch_register): Likewise.
3449 * rs6000-tdep.c (ppc_supply_reg): Likewise.
3450 (ppc_collect_reg): Likewise.
3451 (ppc_collect_gregset): Likewise.
3452 (ppc_collect_fpregset): Likewise.
3453 (ppc_collect_vsxregset): Likewise.
3454 (ppc_collect_vrregset): Likewise.
3455 (ppc_displaced_step_hw_singlestep): Likewise.
3456 (rs6000_pseudo_register_read): Likewise.
3457 (rs6000_pseudo_register_write): Likewise.
3458 * s390-linux-nat.c (supply_gregset): Likewise.
3459 (fill_gregset): Likewise.
3460 (s390_linux_fetch_inferior_registers): Likewise.
3461 * s390-linux-tdep.c (s390_write_pc): Likewise.
3462 (s390_software_single_step): Likewise.
3463 (s390_all_but_pc_registers_record): Likewise.
3464 (s390_linux_syscall_record): Likewise.
3465 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
3466 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
3467 (shnbsd_store_inferior_registers): Likewise.
3468 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
3469 (sh_extract_return_value_fpu): Likewise.
3470 (sh_store_return_value_nofpu): Likewise.
3471 (sh_corefile_supply_regset): Likewise.
3472 (sh_corefile_collect_regset): Likewise.
3473 * sh64-tdep.c (sh64_extract_return_value): Likewise.
3474 (sh64_store_return_value): Likewise.
3475 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
3476 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
3477 (sparc_store_inferior_registers): Likewise.
3478 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
3479 (sparc_ravenscar_prepare_to_store): Likewise.
3480 * sparc-tdep.c (sparc32_store_arguments): Likewise.
3481 (sparc_analyze_control_transfer): Likewise.
3482 (sparc_step_trap): Likewise.
3483 (sparc_software_single_step): Likewise.
3484 (sparc32_gdbarch_init): Likewise.
3485 (sparc_supply_rwindow): Likewise.
3486 (sparc_collect_rwindow): Likewise.
3487 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
3488 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
3489 (sparc64nbsd_collect_gregset): Likewise.
3490 (sparc64nbsd_supply_fpregset): Likewise.
3491 (sparc64nbsd_collect_fpregset): Likewise.
3492 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
3493 (sparc64_supply_gregset): Likewise.
3494 (sparc64_collect_gregset): Likewise.
3495 (sparc64_supply_fpregset): Likewise.
3496 (sparc64_collect_fpregset): Likewise.
3497 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
3498 * spu-tdep.c (spu_unwind_sp): Likewise.
3499 (spu2ppu_prev_register): Likewise.
3500 (spu_memory_remove_breakpoint): Likewise.
3501 * stack.c (return_command): Likewise.
3502 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
3503 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
3504 * tracefile.c (trace_save_ctf): Likewise.
3505 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
3506 (do_windows_store_inferior_registers): Likewise.
3507 (windows_resume): Likewise.
3508 * xtensa-linux-nat.c (fill_gregset): Likewise.
3509 (supply_gregset_reg): Likewise.
3510 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
3511 (xtensa_register_read_masked): Likewise.
3512 (xtensa_supply_gregset): Likewise.
3513 (xtensa_extract_return_value): Likewise.
3514 (xtensa_store_return_value): Likewise.
3515
edd079d9
UW
35162017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
3517
3518 * doublest.c (floatformat_from_string): New function.
3519 * doublest.h (floatformat_from_string): Add prototype.
3520
3521 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
3522 (OP_FLOAT): ... this.
3523 * expression.h: Do not include "doublest.h".
3524 (union exp_element): Replace doubleconst and decfloatconst by
3525 new element floatconst.
3526 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
3527 (ada_evaluate_subexp): Likewise.
3528 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
3529 OP_DOUBLE and OP_DECFLOAT.
3530 * expprint.c (print_subexp_standard): Likewise.
3531 (dump_subexp_body_standard): Likewise.
3532 * breakpoint.c (watchpoint_exp_is_const): Likewise.
3533
3534 * parse.c: Include "dfp.h".
3535 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
3536 (write_exp_elt_floatcst): New function.
3537 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
3538 and OP_DECFLOAT.
3539 (operator_check_standard): Likewise.
3540 (parse_float): Do not accept suffix. Take type as input. Return bool.
3541 Return target format buffer instead of host DOUBLEST.
3542 Use floatformat_from_string and decimal_from_string to parse
3543 either binary or decimal floating-point types.
3544 (parse_c_float): Remove.
3545 * parser-defs.h: Do not include "doublest.h".
3546 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
3547 (write_exp_elt_floatcst): Add prototype.
3548 (parse_float): Update prototype.
3549 (parse_c_float): Remove.
3550
3551 * c-exp.y: Do not include "dfp.h".
3552 (typed_val_float): Use byte buffer instead of DOUBLEST.
3553 (typed_val_decfloat): Remove.
3554 (DECFLOAT): Remove.
3555 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3556 (parse_number): Update to new parse_float interface.
3557 Parse suffixes and determine type before calling parse_float.
3558 Handle decimal and binary FP types the same way.
3559
3560 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3561 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
3562 (parse_number): Update to new parse_float interface.
3563 Parse suffixes and determine type before calling parse_float.
3564
3565 * f-exp.y: Replace dval by typed_val_float.
3566 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3567 (parse_number): Use parse_float instead of atof.
3568
3569 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3570 (parse_go_float): Remove.
3571 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3572 (parse_number): Call parse_float instead of parse_go_float.
3573 Parse suffixes and determine type before calling parse_float.
3574
3575 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3576 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3577 (parse_number): Update to new parse_float interface.
3578 Parse suffixes and determine type before calling parse_float.
3579
3580 * m2-exp.y: Replace dval by byte buffer val.
3581 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3582 (parse_number): Call parse_float instead of atof.
3583
3584 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3585 (lex_number): Call parse_float instead of strtod.
3586 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
3587 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
3588 Use write_exp_elt_floatcst.
3589 (unit_testing): Remove static variable.
3590 (rust_type): Do not check unit_testing.
3591 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
3592
3593 * ada-exp.y (type_float, type_double): Remove.
3594 (typed_val_float): Use byte buffer instead of DOUBLEST.
3595 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3596 * ada-lex.l (processReal): Use parse_float instead of sscanf.
3597
cc628f3d
AH
35982017-10-25 Alan Hayward <alan.hayward@arm.com>
3599
3600 * aarch64-tdep.h (enum aarch64_regnum): Remove.
3601 * arch/aarch64.h: New file.
3602
09a7c6aa
UW
36032017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3604
3605 * dfp.h (decimal_from_string): Use const reference for argument.
3606 * dfp.c (decimal_from_string): Likewise.
3607
8ba0dd51
UW
36082017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3609
3610 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
3611 * sh64-tdep.c (sh64_do_fp_register): Likewise.
3612 * mips-tdep.c (mips_print_fp_register): Likewise.
3613
16e812b2
UW
36142017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3615
3616 * common/format.h (enum argclass): Replace decfloat_arg by
3617 dec32float_arg, dec64float_arg, and dec128float_arg.
3618 * common/format.c (parse_format_string): Update to return
3619 new decimal float argument classes.
3620
3621 * printcmd.c (printf_decfloat): Rename to ...
3622 (printf_floating): ... this. Add argclass argument, and use it
3623 instead of parsing the format string again. Add support for
3624 binary floating-point values, using floatformat_to_string.
3625 Convert value to the target format if it doesn't already match.
3626 (ui_printf): Call printf_floating instead of printf_decfloat,
3627 also for double_arg / long_double_arg. Pass argclass.
3628
3629 * dfp.c (decimal_to_string): Add format string argument.
3630 * dfp.h (decimal_to_string): Likewise.
3631
3632 * doublest.c (floatformat_to_string): Add format string argument.
3633 * doublest.h (floatformat_to_string): Likewise.
3634
fdf0cbc2
UW
36352017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3636
3637 * doublest.c (floatformat_precision): New routine.
3638 (floatformat_to_string): Likewise.
3639 * doublest.c (floatformat_to_string): Add prototype.
3640
3641 * printcmd.c (print_scalar_formatted): Only call print_floating
3642 on floating-point types.
3643 * valprint.c: Do not include "floatformat.h".
3644 (generic_val_print_decfloat): Remove.
3645 (generic_val_print): Call generic_val_print_float for both
3646 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
3647 (print_floating): Use floatformat_to_string. Handle decimal float.
3648 (print_decimal_floating): Remove, merge into floatformat_to_string.
3649 * value.h (print_decimal_floating): Remove.
3650
3651 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
3652
5033013f
UW
36532017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3654
3655 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
3656
a664f67e
SM
36572017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3658
3659 * memattr.h: Don't include vec.h.
3660 (struct mem_attrib): Initialize fields.
3661 <unknown>: New static method.
3662 (struct mem_region): Add constructors, operator<, initialize
3663 fields.
3664 * memattr.c: Include algorithm.
3665 (default_mem_attrib, unknown_mem_attrib): Remove.
3666 (user_mem_region_list): New global.
3667 (target_mem_region_list, mem_region_list): Change type to
3668 std::vector<mem_region>.
3669 (mem_use_target): Now a function.
3670 (target_mem_regions_valid): Change type to bool.
3671 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
3672 (require_user_regions): Adjust.
3673 (require_target_regions): Adjust.
3674 (create_mem_region): Adjust.
3675 (lookup_mem_region): Adjust.
3676 (invalidate_target_mem_regions): Adjust.
3677 (mem_clear): Rename to...
3678 (user_mem_clear): ... this, and adjust.
3679 (mem_command): Adjust.
3680 (info_mem_command): Adjust.
3681 (mem_enable, enable_mem_command, mem_disable,
3682 disable_mem_command): Adjust.
3683 (mem_delete): Adjust.
3684 (delete_mem_command): Adjust.
3685 * memory-map.h (parse_memory_map): Return an std::vector.
3686 * memory-map.c (parse_memory_map): Likewise.
3687 (struct memory_map_parsing_data): Add constructor.
3688 <memory_map>: Point to std::vector.
3689 (memory_map_start_memory): Adjust.
3690 (memory_map_end_memory): Adjust.
3691 (memory_map_end_property): Adjust.
3692 (clear_result): Remove.
3693 * remote.c (remote_memory_map): Return an std::vector.
3694 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
3695 Remove.
3696 (target_debug_print_mem_region_vector): New.
3697 * target-delegates.c: Regenerate.
3698 * target.h (mem_region_vector): New typedef.
3699 (to_memory_map): Return mem_region_vector.
3700 (target_memory_map): Return an std::vector.
3701 * target.c (target_memory_map): Return an std::vector.
3702 (flash_erase_command): Adjust.
3703
6e17c565
SM
37042017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3705
3706 * memory-map.c (struct memory_map_parsing_data) <property_name>:
3707 Change type to std::string.
3708 (memory_map_start_property): Adjust.
3709 (memory_map_end_property): Adjust.
3710
cfba9872
SM
37112017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
3712
3713 * infrun.h: Include common/byte-vector.h.
3714 (struct displaced_step_closure): New struct.
3715 (struct buf_displaced_step_closure): New struct.
3716 * infrun.c (displaced_step_closure::~displaced_step_closure):
3717 Provide default implementation.
3718 (displaced_step_clear): Deallocate step closure with delete.
3719 * aarch64-tdep.c (displaced_step_closure): Rename to ...
3720 (aarch64_displaced_step_closure): ... this, extend
3721 displaced_step_closure.
3722 (aarch64_displaced_step_data) <dsc>: Change type to
3723 aarch64_displaced_step_closure.
3724 (aarch64_displaced_step_copy_insn): Adjust to type change, use
3725 unique_ptr.
3726 (aarch64_displaced_step_fixup): Add cast for displaced step
3727 closure.
3728 * amd64-tdep.c (displaced_step_closure): Rename to ...
3729 (amd64_displaced_step_closure): ... this, extend
3730 displaced_step_closure.
3731 <insn_buf>: Change type to std::vector<gdb_byte>.
3732 <max_len>: Remove.
3733 (fixup_riprel): Change type of DSC parameter, adjust to type
3734 change of insn_buf.
3735 (fixup_displaced_copy): Change type of DSC parameter.
3736 (amd64_displaced_step_copy_insn): Instantiate
3737 amd64_displaced_step_closure.
3738 (amd64_displaced_step_fixup): Add cast for closure type, adjust
3739 to type change of insn_buf.
3740 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
3741 parameter DSC.
3742 (arm_linux_copy_svc): Likewise.
3743 (cleanup_kernel_helper_return): Likewise.
3744 (arm_catch_kernel_helper_return): Likewise.
3745 (arm_linux_displaced_step_copy_insn): Instantiate
3746 arm_displaced_step_closure.
3747 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
3748 (displaced_read_reg): Change type of parameter DSC.
3749 (branch_write_pc): Likewise.
3750 (load_write_pc): Likewise.
3751 (alu_write_pc): Likewise.
3752 (displaced_write_reg): Likewise.
3753 (arm_copy_unmodified): Likewise.
3754 (thumb_copy_unmodified_32bit): Likewise.
3755 (thumb_copy_unmodified_16bit): Likewise.
3756 (cleanup_preload): Likewise.
3757 (install_preload): Likewise.
3758 (arm_copy_preload): Likewise.
3759 (thumb2_copy_preload): Likewise.
3760 (install_preload_reg): Likewise.
3761 (arm_copy_preload_reg): Likewise.
3762 (cleanup_copro_load_store): Likewise.
3763 (install_copro_load_store): Likewise.
3764 (arm_copy_copro_load_store) Likewise.
3765 (thumb2_copy_copro_load_store): Likewise.
3766 (cleanup_branch): Likewise.
3767 (install_b_bl_blx): Likewise.
3768 (arm_copy_b_bl_blx): Likewise.
3769 (thumb2_copy_b_bl_blx): Likewise.
3770 (thumb_copy_b): Likewise.
3771 (install_bx_blx_reg): Likewise.
3772 (arm_copy_bx_blx_reg): Likewise.
3773 (thumb_copy_bx_blx_reg): Likewise.
3774 (cleanup_alu_imm): Likewise.
3775 (arm_copy_alu_imm): Likewise.
3776 (thumb2_copy_alu_imm): Likewise.
3777 (cleanup_alu_reg): Likewise.
3778 (install_alu_reg): Likewise.
3779 (arm_copy_alu_reg): Likewise.
3780 (thumb_copy_alu_reg): Likewise.
3781 (cleanup_alu_shifted_reg): Likewise.
3782 (install_alu_shifted_reg): Likewise.
3783 (arm_copy_alu_shifted_reg): Likewise.
3784 (cleanup_load): Likewise.
3785 (cleanup_store): Likewise.
3786 (arm_copy_extra_ld_st): Likewise.
3787 (install_load_store): Likewise.
3788 (thumb2_copy_load_literal): Likewise.
3789 (thumb2_copy_load_reg_imm): Likewise.
3790 (arm_copy_ldr_str_ldrb_strb): Likewise.
3791 (cleanup_block_load_all): Likewise.
3792 (cleanup_block_store_pc): Likewise.
3793 (cleanup_block_load_pc): Likewise.
3794 (arm_copy_block_xfer): Likewise.
3795 (thumb2_copy_block_xfer): Likewise.
3796 (cleanup_svc): Likewise.
3797 (install_svc): Likewise.
3798 (arm_copy_svc): Likewise.
3799 (thumb_copy_svc): Likewise.
3800 (arm_copy_undef): Likewise.
3801 (thumb_32bit_copy_undef): Likewise.
3802 (arm_copy_unpred): Likewise.
3803 (arm_decode_misc_memhint_neon): Likewise.
3804 (arm_decode_unconditional): Likewise.
3805 (arm_decode_miscellaneous): Likewise.
3806 (arm_decode_dp_misc): Likewise.
3807 (arm_decode_ld_st_word_ubyte): Likewise.
3808 (arm_decode_media): Likewise.
3809 (arm_decode_b_bl_ldmstm): Likewise.
3810 (arm_decode_ext_reg_ld_st): Likewise.
3811 (thumb2_decode_dp_shift_reg): Likewise.
3812 (thumb2_decode_ext_reg_ld_st): Likewise.
3813 (arm_decode_svc_copro): Likewise.
3814 (thumb2_decode_svc_copro): Likewise.
3815 (install_pc_relative): Likewise.
3816 (thumb_copy_pc_relative_16bit): Likewise.
3817 (thumb_decode_pc_relative_16bit): Likewise.
3818 (thumb_copy_pc_relative_32bit): Likewise.
3819 (thumb_copy_16bit_ldr_literal): Likewise.
3820 (thumb_copy_cbnz_cbz): Likewise.
3821 (thumb2_copy_table_branch): Likewise.
3822 (cleanup_pop_pc_16bit_all): Likewise.
3823 (thumb_copy_pop_pc_16bit): Likewise.
3824 (thumb_process_displaced_16bit_insn): Likewise.
3825 (decode_thumb_32bit_ld_mem_hints): Likewise.
3826 (thumb_process_displaced_32bit_insn): Likewise.
3827 (thumb_process_displaced_insn): Likewise.
3828 (arm_process_displaced_insn): Likewise.
3829 (arm_displaced_init_closure): Likewise.
3830 (arm_displaced_step_fixup): Add cast for closure.
3831 * arm-tdep.h: Include infrun.h.
3832 (displaced_step_closure): Rename to ...
3833 (arm_displaced_step_closure): ... this, extend
3834 displaced_step_closure.
3835 <u::svc::copy_svc_os>: Change type of parameter DSC.
3836 <cleanup>: Likewise.
3837 (arm_process_displaced_insn): Likewise.
3838 (arm_displaced_init_closure): Likewise.
3839 (displaced_read_reg): Likewise.
3840 (displaced_write_reg): Likewise.
3841 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
3842 Adjust.
3843 * i386-tdep.h: Include infrun.h.
3844 (i386_displaced_step_closure): New typedef.
3845 * i386-tdep.c (i386_displaced_step_copy_insn): Use
3846 i386_displaced_step_closure.
3847 (i386_displaced_step_fixup): Adjust.
3848 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
3849 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
3850 and unique_ptr.
3851 (ppc_displaced_step_fixup): Adjust.
3852 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
3853 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
3854 and unique_ptr.
3855 (s390_displaced_step_fixup): Adjust.
3856
b392b304
SM
38572017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
3858
3859 * interps.h (interp_resume, interp_suspend, interp_set_temp):
3860 Remove declarations.
3861
d5833c62
TT
38622017-10-20 Tom Tromey <tom@tromey.com>
3863
3864 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
3865 std::vector.
3866 (gdb_bfd_record_inclusion): Update.
3867 (bfdp): Remove typedef.
3868
06d5bbc8
TT
38692017-10-20 Tom Tromey <tom@tromey.com>
3870
3871 * gdb_bfd.c (gdb_bfd_ref): Use new.
3872 (struct gdb_bfd_data): Add constructor, destructor, and member
3873 initializers.
3874 (gdb_bfd_unref): Use delete.
3875
2712ce2e
TT
38762017-10-20 Tom Tromey <tom@tromey.com>
3877
3878 * exec.c (exec_file_attach): Use new_bfd_ref.
3879 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
3880 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
3881 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
3882 new_bfd_ref.
3883 * gdb_bfd.h (new_bfd_ref): New function.
3884
fcc8fb2f
PA
38852017-10-20 Pedro Alves <palves@redhat.com>
3886
3887 * main.c (captured_command_loop): Add attribute noinline.
3888
4c2287b0
SM
38892017-10-19 Simon Marchi <simon.marchi@ericsson.com>
3890
3891 * interps.c (struct interp_factory): Add constructor.
3892 (interp_factory_p): Remove typedef.
3893 (DEF_VEC_P(interp_factory_p)): Remove.
3894 (interpreter_factories): Change type to std::vector.
3895 (interp_factory_register): Adjust.
3896 (interp_lookup): Adjust.
3897 (interpreter_completer): Adjust.
3898
3d415c26
TT
38992017-10-19 Tom Tromey <tom@tromey.com>
3900
3901 * break-catch-syscall.c (catch_syscall_completer): Use
3902 std::string, gdb::unique_xmalloc_ptr.
3903
395423c4
TT
39042017-10-19 Tom Tromey <tom@tromey.com>
3905
3906 * infcall.c (call_function_by_hand_dummy): Use std::string.
3907
54f70bc1
TT
39082017-10-19 Tom Tromey <tom@tromey.com>
3909
3910 * mi/mi-main.c (mi_cmd_execute): Update.
3911 * top.h (prepare_execute_command): Return scoped_value_mark.
3912 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
3913 Add move constructor.
3914 * top.c (prepare_execute_command): Return scoped_value_mark.
3915 (execute_command): Update.
3916
63929e84
PA
39172017-10-19 Pedro Alves <palves@redhat.com>
3918
3919 * xml-support.c (xml_fetch_content_from_file): Check fread's
3920 return.
3921
a75868f5
PA
39222017-10-19 Pedro Alves <palves@redhat.com>
3923
3924 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
3925 async.
3926 (handle_error_fd): New function.
3927 (ser_base_async): Add/delete an event loop file handler for
3928 error_fd.
3929
2edf834e
PA
39302017-10-19 Pedro Alves <palves@redhat.com>
3931
3932 * xml-support.c (xml_fetch_content_from_file): Don't read in
3933 chunks. Instead use fseek to determine the file's size, and read
3934 it in one go.
3935
c8ba13ad
KS
39362017-11-18 Keith Seitz <keiths@redhat.com>
3937
3938 * c-exp.y (oper): Canonicalize conversion operators of user-defined
3939 types.
3940 Add whitespace to front of type name.
3941
37534686
KS
39422017-10-18 Keith Seitz <keiths@redhat.com>
3943
3944 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
3945 DW_AT_accessibility.
3946
28c7c158
YQ
39472017-10-18 Yao Qi <yao.qi@linaro.org>
3948
3949 * features/tic6x-c62x-linux.c: Remove.
3950
30f0b101
TT
39512017-10-17 Tom Tromey <tom@tromey.com>
3952
3953 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
3954 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
3955 (do_mixed_source_and_assembly): Likewise.
3956
57e12da9
TT
39572017-10-17 Tom Tromey <tom@tromey.com>
3958
3959 * regcache.c (regcache::xfer_part): Remove assertion.
3960
7b700999
PA
39612017-10-17 Pedro Alves <palves@redhat.com>
3962
3963 * xml-support.c (xml_fetch_content_from_file): Call
3964 unique_ptr::release() instead unique_ptr::get() when passing
3965 through xrealloc.
3966
d3037ba6
YQ
39672017-10-17 Yao Qi <yao.qi@linaro.org>
3968
3969 * regcache.c (regcache::xfer_part): Remove parameters read and
3970 write, add parameter is_raw. All callers are updated.
3971
83d5a34d
KS
39722017-10-16 Keith Seitz <keiths@redhat.com>
3973
3974 * c-typeprint.c (enum access_specifier): Moved here from
3975 c_type_print_base.
3976 (output_access_specifier): New function.
3977 (c_type_print_base): Consider typedefs when assessing
3978 whether access labels are needed.
3979 Use output_access_specifier as needed.
3980 Output access specifier for typedefs, if needed.
3981 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
3982 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
3983 fields.
3984 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
3985 accessor macros.
3986
87028b87
TT
39872017-10-16 Tom Tromey <tom@tromey.com>
3988
3989 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
3990 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
3991 * target.c (target_fileio_read_stralloc): Update.
3992 * sparc64-tdep.c (adi_is_addr_mapped): Update.
3993 * target.h (target_fileio_read_stralloc): Return
3994 unique_xmalloc_ptr.
3995
b7b030ad
TT
39962017-10-16 Tom Tromey <tom@tromey.com>
3997
3998 * xml-syscall.c (xml_init_syscalls_info): Update.
3999 * xml-support.c (xinclude_start_include): Update.
4000 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
4001 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
4002 (xml_fetch_content_from_file): Likewise.
4003 * osdata.c (get_osdata): Update.
4004 * target.h (target_read_stralloc, target_get_osdata): Return
4005 unique_xmalloc_ptr.
4006 * solib-aix.c (solib_aix_get_library_list): Update.
4007 * solib-target.c (solib_target_current_sos): Update.
4008 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
4009 * xml-tdesc.c (fetch_available_features_from_target): Update.
4010 (target_fetch_description_xml): Update.
4011 (file_read_description_xml): Update.
4012 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
4013 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
4014 (remote_pid_to_exec_file): Update.
4015 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
4016 (target_get_osdata): Likewise.
4017
b80406ac
TT
40182017-10-16 Tom Tromey <tom@tromey.com>
4019
4020 * remote.c (remote_register_number_and_offset): Use std::vector.
4021 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
4022 (putpkt_binary): Use gdb::def_vector.
4023 (compare_sections_command): Use gdb::byte_vector.
4024
a90ecff8
TT
40252017-10-16 Tom Tromey <tom@tromey.com>
4026
4027 * ppc-linux-nat.c (hwdebug_insert_point): Use
4028 gdb::unique_xmalloc_ptr, XDUP.
4029
2dc0e219
TT
40302017-10-16 Tom Tromey <tom@tromey.com>
4031
4032 * probe.c (parse_probes): Use std::string.
4033 (info_probes_for_ops, enable_probes_command)
4034 (disable_probes_command): Remove cleanups.
4035
b05628f0
TT
40362017-10-16 Tom Tromey <tom@tromey.com>
4037
4038 * buildsym.c (block_compar): Remove.
4039 (end_symtab_get_static_block): Use std::vector.
4040
a79b1bc6
SM
40412017-10-16 Simon Marchi <simon.marchi@ericsson.com>
4042
4043 * memrange.h (struct mem_range): Define operator< and operator==.
4044 (mem_range_s): Remove.
4045 (DEF_VEC_O (mem_range_s)): Remove.
4046 (normalize_mem_ranges): Change parameter type to std::vector.
4047 * memrange.c (compare_mem_ranges): Remove.
4048 (normalize_mem_ranges): Change parameter type to std::vector,
4049 adjust to vector change.
4050 * exec.c (section_table_available_memory): Return vector, remove
4051 parameter.
4052 (section_table_read_available_memory): Adjust to std::vector
4053 change.
4054 * remote.c (remote_read_bytes): Adjust to std::vector
4055 change.
4056 * tracepoint.h (traceframe_available_memory): Change parameter
4057 type to std::vector.
4058 * tracepoint.c (traceframe_available_memory): Change parameter
4059 type to std::vector, adjust.
4060 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
4061 std::vector change.
4062 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4063 unittests/memrange-selftests.c.
4064 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
4065 * gdb/unittests/memrange-selftests.c: New file.
4066
63f0e930
PA
40672017-10-16 Pedro Alves <palves@redhat.com>
4068
4069 * elfread.c (probe_key_free): Rename range-for variable.
4070 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
4071 (find_probe_by_pc, collect_probes): Rename range-for variable.
4072
c40c7bfc
YQ
40732017-10-16 Yao Qi <yao.qi@linaro.org>
4074
4075 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
4076 * features/tic6x-c62x.c: Remove.
4077 * features/tic6x-c64x-linux.c: Remove.
4078 * features/tic6x-c64x.c: Remove.
4079 * features/tic6x-c64xp-linux.c: Remove.
4080 * features/tic6x-c64xp.c: Remove.
4081 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
4082 initialize_tdesc_tic6x_*_linux functions.
4083 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
4084 initialize_tdesc_tic6x_* functions.
4085
df27ae6a
YQ
40862017-10-16 Yao Qi <yao.qi@linaro.org>
4087
4088 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
4089 tic6x-c62x.
4090 * regformats/tic6x-c62x.dat: Remove.
4091 * regformats/tic6x-c64x.dat: Remove.
4092 * regformats/tic6x-c64xp.dat: Remove.
4093
86766165
SM
40942017-10-15 Simon Marchi <simon.marchi@ericsson.com>
4095
4096 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
4097 (the !HAVE_LIBEXPAT version).
4098
824dfcc3
SM
40992017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4100
4101 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
4102 const.
4103
2098b393
SM
41042017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4105
4106 * target.h: Include tracepoint.h.
4107 (enum trace_find_type): Move to tracepoint.h.
4108 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
4109 * tracepoint.h: Don't include target.h
4110 (enum trace_find_type): Move from target.h.
4111 (parse_traceframe_info): Return a unique ptr.
4112 * tracepoint.c (current_traceframe_info): Change type to unique
4113 ptr.
4114 (free_traceframe_info): Remove.
4115 (clear_traceframe_info): Don't manually free
4116 current_traceframe_info.
4117 (free_result): Remove.
4118 (parse_traceframe_info): Return a unique ptr.
4119 (get_traceframe_info): Adjust to unique ptr.
4120 * ctf.c (ctf_traceframe_info): Return a unique ptr.
4121 * remote.c (remote_traceframe_info): Return a unique ptr.
4122 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
4123 ptr.
4124 * target-debug.h (target_debug_print_traceframe_info_up): New
4125 macro.
4126 * target-delegates.c: Regenerate.
4127
4cdd21a8
SM
41282017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4129
4130 * memrange.h (struct mem_range): Add constructors.
4131 * tracepoint.h (struct traceframe_info) <memory>: Change type to
4132 std::vector<mem_range>.
4133 * tracepoint.c (free_traceframe_info): Don't manually free
4134 vector.
4135 (traceframe_info_start_memory): Adjust to vector change.
4136 (traceframe_available_memory): Likewise.
4137 * tracefile-tfile.c (build_traceframe_info): Likewise.
4138 * ctf.c (ctf_traceframe_info): Likewise.
4139
d0d292a2
SM
41402017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4141
4142 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
4143 std::vector<int>.
4144 * tracepoint.c (free_traceframe_info): Deallocate with delete.
4145 (traceframe_info_start_tvar): Adjust to vector change.
4146 (parse_traceframe_info): Allocate with new.
4147 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
4148 vector change.
4149 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
4150 change.
4151 tfile_traceframe_info): Allocate with new.
4152 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
4153 change.
4154
8d3c73ef
SM
41552017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4156
4157 * tracepoint.c (traceframe_info): Rename to...
4158 (current_traceframe_info): ...this.
4159 (clear_traceframe_info): Adjust.
4160 (get_traceframe_info): Adjust.
4161
b129dcac
SM
41622017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4163
4164 * nat/linux-osdata.c: Include algorithm.
4165 (compare_processes): Remove.
4166 (struct pid_pgid_entry): New struct.
4167 (linux_xfer_osdata_processgroups): Use std::vector instead of
4168 XNEWVEC.
4169
af5bf4ad
SM
41702017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4171
4172 * objfiles.h: Don't include symfile.h.
4173 (struct partial_symbol): Remove forward-declaration.
4174 (struct objfile) <global_psymbols, static_psymbols>: Change type
4175 to std::vector<partial_symbol *>.
4176 * objfiles.c (objfile::objfile): Don't memset those fields.
4177 (objfile::~objfile): Don't free those fields.
4178 * psympriv.h (struct psymbol_allocation_list): Remove
4179 forward-declaration.
4180 (add_psymbol_to_list): Change psymbol_allocation_list parameter
4181 to std::vector.
4182 (start_psymtab_common): Change parameters to std::vector.
4183 * psymtab.c: Include algorithm.
4184 (require_partial_symbols): Call shrink_to_fit.
4185 (find_pc_sect_psymbol): Adjust to vector change.
4186 (match_partial_symbol): Likewise.
4187 (lookup_partial_symbol): Likewise.
4188 (psym_relocate): Likewise.
4189 (dump_psymtab): Likewise.
4190 (recursively_search_psymtabs): Likewise.
4191 (compare_psymbols): Remove.
4192 (sort_pst_symbols): Adjust to vector change.
4193 (start_psymtab_common): Likewise.
4194 (end_psymtab_common): Likewise.
4195 (psymbol_bcache_full): De-constify return value.
4196 (add_psymbol_to_bcache): Likewise.
4197 (extend_psymbol_list): Remove.
4198 (append_psymbol_to_list): Adjust to vector change.
4199 (add_psymbol_to_list): Likewise.
4200 (init_psymbol_list): Likewise.
4201 (maintenance_info_psymtabs): Likewise.
4202 (maintenance_check_psymtabs): Likewise.
4203 * symfile.h (struct psymbol_allocation_list): Remove.
4204 * symfile.c (reread_symbols): Adjust to vector change.
4205 * dbxread.c (start_psymtab): Change type of parameters.
4206 (dbx_symfile_read): Adjust to vector change.
4207 (read_dbx_symtab): Likewise.
4208 (start_psymtab): Change type of parameters.
4209 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
4210 (create_partial_symtab): Likewise.
4211 (add_partial_symbol): Likewise.
4212 (write_one_signatured_type): Likewise.
4213 (recursively_write_psymbols): Likewise.
4214 * mdebugread.c (parse_partial_symbols): Likewise.
4215 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
4216 (scan_xcoff_symtab): Adjust to vector change.
4217 (xcoff_initial_scan): Likewise.
4218
3ec5942f
SM
42192017-10-13 Simon Marchi <simon.marchi@ericsson.com>
4220
4221 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
4222
2399fe6a
YQ
42232017-10-13 Yao Qi <yao.qi@linaro.org>
4224
4225 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
4226 Remove s390x-*-expedite, add s390x-expedite.
4227
4bf3f4a8
YQ
42282017-10-13 Yao Qi <yao.qi@linaro.org>
4229
4230 * features/s390-gs-linux64.c: Regenerated.
4231 * features/s390x-gs-linux64.c: Regenerated.
4232
9e86da07
TT
42332017-10-13 Tom Tromey <tom@tromey.com>
4234
4235 * compile/compile-object-run.c (do_module_cleanup): Use delete.
4236 * solib.c (update_solib_list, reload_shared_libraries_1): Use
4237 delete.
4238 * symfile.c (symbol_file_add_with_addrs): Use new.
4239 (symbol_file_add_separate): Update comment.
4240 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
4241 * jit.c (jit_object_close_impl): Use new.
4242 (jit_unregister_code): Use delete.
4243 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
4244 (~objfile): Rename from free_objfile.
4245 (free_objfile_separate_debug, do_free_objfile_cleanup)
4246 (free_all_objfiles, objfile_purge_solibs): Use delete.
4247 * objfiles.h (struct objfile): Add constructor and destructor.
4248 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
4249 (allocate_objfile, free_objfile): Don't declare.
4250 (struct objstats): Add initializers.
4251
c2508e90
SM
42522017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4253
4254 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
4255 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
4256 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
4257 * gdbarch.h: Regenerate.
4258 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4259 Adjust comment.
4260 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
4261 (i386_displaced_step_fixup): Adjust comment.
4262 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
4263
a900ff72
TT
42642017-10-12 Tom Tromey <tom@tromey.com>
4265
4266 * prologue-value.h (pv_area::store_would_trash): Return bool.
4267 (pv_area::find_reg): Likewise.
4268 * prologue-value.c (pv_area::store_would_trash): Return bool.
4269 (pv_area::find_reg): Likewise.
4270
f7b7ed97
TT
42712017-10-12 Tom Tromey <tom@tromey.com>
4272
4273 * s390-linux-tdep.c (s390_store, s390_load)
4274 (s390_check_for_saved, s390_analyze_prologue): Update.
4275 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
4276 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
4277 * prologue-value.h (class pv_area): Move from prologue-value.c.
4278 Change names of members. Add constructor, destructor, member
4279 functions.
4280 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
4281 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
4282 (pv_area_fetch, pv_area_scan): Don't declare.
4283 * prologue-value.c (struct pv_area::area_entry): Now member of
4284 pv_area.
4285 (struct pv_area): Move to prologue-value.h.
4286 (pv_area::pv_area): Rename from make_pv_area.
4287 (pv_area::~pv_area): Rename from free_pv_area.
4288 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
4289 (clear_entries, find_entry, overlaps, store_would_trash, store)
4290 (fetch, find_reg, scan): Now member of pv_area.
4291 Remove "area" argument. Update.
4292 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
4293 Update.
4294 * mn10300-tdep.c (push_reg, check_for_saved)
4295 (mn10300_analyze_prologue): Update.
4296 * mep-tdep.c (is_arg_spill, check_for_saved)
4297 (mep_analyze_prologue): Update.
4298 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
4299 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
4300 (m32c_is_struct_return, m32c_analyze_prologue): Update.
4301 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
4302 Update.
4303 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
4304 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
4305
466eecee
SM
43062017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4307
4308 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
4309 * linux-nat.c (linux_nat_delete_thread): New variable.
4310 (lwp_free): Invoke linux_nat_delete_thread if set.
4311 (linux_nat_set_delete_thread): New function.
4312 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
4313 thread delete callback.
4314 * arm-linux-nat.c (arm_linux_delete_thread): New function.
4315 (_initialize_arm_linux_nat): Assign thread delete callback.
4316 * s390-linux-nat.c (s390_delete_thread): New function.
4317 (_initialize_s390_nat): Assign thread delete callback.
4318 * x86-linux-nat.c (x86_linux_add_target): Likewise.
4319 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
4320 function.
4321 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
4322 declaration.
4323 * nat/x86-linux.c (x86_linux_delete_thread): New function.
4324 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
4325
f71c8822
TT
43262017-10-09 Tom Tromey <tom@tromey.com>
4327
4328 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
4329 std::string.
4330 * tui/tui-layout.c (enum tui_status): Use std::string.
4331
981a3fb3
TT
43322017-10-11 Tom Tromey <tom@tromey.com>
4333
4334 * gdbthread.h (thread_command): Constify.
4335 * inferior.h (detach_command): Constify.
4336 * top.h (set_history, show_history): Constify.
4337 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
4338 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
4339 * bsd-kvm.c (bsd_kvm_cmd): Constify.
4340 * printcmd.c (set_command): Constify.
4341 (non_const_set_command): New function.
4342 * dcache.c (set_dcache_command, show_dcache_command): Constify.
4343 * breakpoint.c (enable_command, disable_command, delete_command)
4344 (catch_command, tcatch_command, set_breakpoint_cmd)
4345 (show_breakpoint_cmd): Constify.
4346 * macrocmd.c (macro_command): Constify.
4347 * infcmd.c (unset_command, kill_command, detach_command)
4348 (info_proc_cmd): Constify.
4349 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
4350 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
4351 (info_auto_load_cmd): Constify.
4352 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
4353 (unset_tdesc_cmd): Constify.
4354 * ada-lang.c (set_ada_command, show_ada_command)
4355 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
4356 * guile/guile.c (set_guile_command, show_guile_command)
4357 (info_guile_command): Constify.
4358 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
4359 Constify.
4360 * skip.c (skip_command): Constify.
4361 * compile/compile.c (_initialize_compile): Constify.
4362 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
4363 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
4364 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
4365 (maint_btrace_pt_show_cmd): Constify.
4366 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
4367 Constify.
4368 * python/python.c (user_show_python, user_set_python): Constify.
4369 * mips-tdep.c (set_mips_command, show_mips_command)
4370 (set_mipsfpu_command): Constify.
4371 * record-btrace.c (cmd_record_btrace_start)
4372 (cmd_set_record_btrace, cmd_show_record_btrace)
4373 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
4374 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
4375 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
4376 Constify.
4377 * symfile.c (overlay_command): Constify.
4378 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
4379 * cli/cli-logging.c (set_logging_command, show_logging_command):
4380 Constify.
4381 * cli/cli-dump.c (dump_command, append_command)
4382 (srec_dump_command, ihex_dump_command, verilog_dump_command)
4383 (tekhex_dump_command, binary_dump_command)
4384 (binary_append_command): Constify.
4385 * cli/cli-decode.c (struct cmd_list_element): Change type of
4386 "fun".
4387 * cli/cli-cmds.c (info_command, show_command, set_debug)
4388 (show_debug): Constify.
4389 (show_command): Add non-const overload.
4390 * top.c (set_history, show_history): Constify.
4391 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
4392 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
4393 * target.c (target_command): Constify.
4394 * sparc64-tdep.c (info_adi_command): Constify.
4395 * record-full.c (cmd_record_full_start): Constify.
4396 (set_record_full_command): Constify. Fix typo.
4397 (show_record_full_command): Constify.
4398 * thread.c (thread_command, thread_apply_command): Constify.
4399 * memattr.c (dummy_cmd): Constify.
4400 * value.c (function_command): Constify.
4401 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
4402 * probe.c (info_probes_command): Constify.
4403 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
4404 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
4405 (show_thread_cmd, set_thread_default_cmd)
4406 (show_thread_default_cmd): Constify.
4407 (check_empty): Constify.
4408 * tracepoint.c (tfind_command): Constify.
4409 * cp-support.c (maint_cplus_command): Constify.
4410 * windows-tdep.c (info_w32_command): Constify.
4411 * record.c (cmd_record_start, set_record_command)
4412 (show_record_command, info_record_command, cmd_record_goto):
4413 Constify.
4414 * ravenscar-thread.c (set_ravenscar_command)
4415 (show_ravenscar_command): Constify.
4416 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
4417 Constify.
4418 (add_internal_problem_command): Remove casts.
4419 * arc-tdep.c (maintenance_print_arc_command): Constify.
4420 * valprint.c (set_print, show_print, set_print_raw)
4421 (show_print_raw): Constify.
4422 * maint.c (maintenance_command, maintenance_info_command)
4423 (maintenance_print_command, maintenance_set_cmd)
4424 (maintenance_show_cmd, set_per_command_cmd)
4425 (show_per_command_cmd, maintenance_check_command): Constify.
4426 * language.c (set_check, show_check): Constify.
4427 * typeprint.c (show_print_type, set_print_type): Constify.
4428 * go32-nat.c (go32_info_dos_command): Constify.
4429
fdf44873
TT
44302017-10-11 Tom Tromey <tom@tromey.com>
4431
4432 * breakpoint.c (prepare_re_set_context): Remove.
4433 (breakpoint_re_set_one): Update. Don't use cleanups.
4434 (breakpoint_re_set): Use scoped_restore, std::string, and
4435 scoped_restore_current_language.
4436
81b1e71c
TT
44372017-10-11 Tom Tromey <tom@tromey.com>
4438
4439 * breakpoint.c (commands_command_1): Use std::string.
4440 (cleanup_executing_breakpoints): Remove.
4441 (bpstat_do_actions_1): Use scoped_restore.
4442 (bpstat_check_watchpoint): Use std::string.
4443 (decode_static_tracepoint_spec): Likewise.
4444 (break_range_command): Likewise.
4445 (watch_command_1): Likewise.
4446 (compare_breakpoints): Change argument types.
4447 (clear_command): Use std::vector.
4448 (cleanup_executing_breakpoints): Remove.
4449 (update_global_location_list): Use unique_xmalloc_ptr.
4450 (strace_command): Remove unused declaration.
4451
4f9d9906
JB
44522017-10-11 John Baldwin <jhb@FreeBSD.org>
4453
4454 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
4455 * NEWS: Mention new FreeBSD/arm native configuration.
4456 * configure.host: Add arm*-*-freebsd*.
4457 * configure.nat: Likewise.
4458 * arm-fbsd-nat.c: New file.
4459
7176dfd2
JB
44602017-10-11 John Baldwin <jhb@FreeBSD.org>
4461
4462 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
4463 (ALLDEPFILES): Add arm-fbsd-tdep.c.
4464 * NEWS: Mention new FreeBSD/arm target.
4465 * configure.tgt: Add arm*-*-freebsd*.
4466 * arm-fbsd-tdep.c: New file.
4467 * arm-fbsd-tdep.h: New file.
4468
fe220226
MR
44692017-10-11 Maciej W. Rozycki <macro@imgtec.com>
4470
4471 * linux-tdep.c (linux_make_corefile_notes): Remove call to
4472 `gdbarch_elfcore_write_linux_prpsinfo'.
4473 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
4474 method.
4475 (elf_internal_linux_prpsinfo): Remove declaration.
4476 * gdbarch.h: Regenerate.
4477 * gdbarch.c: Regenerate.
4478
a2f63b2e
MR
44792017-10-11 Maciej W. Rozycki <macro@imgtec.com>
4480
4481 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
4482 `set_gdbarch_elfcore_write_linux_prpsinfo'.
4483
458ca1d0
PA
44842017-10-11 Pedro Alves <palves@redhat.com>
4485
4486 * breakpoint.c (reattach_breakpoints): Delete.
4487 * breakpoint.h (reattach_breakpoints): Delete.
4488
905014d7
SM
44892017-10-11 Simon Marchi <simon.marchi@ericsson.com>
4490
4491 * symfile.c (registered_sym_fns): Make struct, not typedef.
4492 (DEF_VEC_O (registered_sym_fns)): Remove.
4493 (symtab_fns): Change type to std::vector.
4494 (add_symtab_fns): Adjust.
4495 (find_sym_fns): Adjust.
4496
56d704da
AK
44972017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
4498
4499 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
4500 * arc-tdep.h (arc_arch_is_em): New function.
4501 (arc_arch_is_hs): Likewise.
4502
7fa29be9
EB
45032017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
4504
4505 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
4506 parentheses in the declaration.
4507 (macro_lookup_inclusion): Likewise.
4508 (macro_lookup_definition): Likewise.
4509 * p-lang.h (pascal_builtin_types): Likewise.
4510 * tui/tui-data.c (tui_win_list): Likewise.
4511 * tui/tui-data.h (tui_win_list): Likewise.
4512 * utils.h (make_cleanup_free_section_addr_info): Likewise.
4513
d9b477e3
KB
45142017-10-11 Mark Rages <markrages@gmail.com>
4515
4516 * target-memory.c (block_boundaries): Fix for block address not
4517 aligned on block size.
4518
65630365
PA
45192017-10-10 Pedro Alves <palves@redhat.com>
4520 Tom Tromey <tom@tromey.com>
4521
4522 * breakpoint.c (struct captured_breakpoint_query_args)
4523 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
4524 (print_breakpoint): New.
4525 * breakpoint.h (print_breakpoint): Declare.
4526 * common/common-exceptions.h (enum return_reason): Remove
4527 references to catch_exceptions.
4528 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
4529 Delete.
4530 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
4531 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
4532 * gdb.h: Delete.
4533 * gdbthread.h (thread_select): Declare.
4534 * mi/mi-cmd-break.c: Don't include gdb.h.
4535 (breakpoint_notify): Use print_breakpoint.
4536 * mi/mi-cmd-catch.c: Don't include gdb.h.
4537 * mi/mi-interp.c: Don't include gdb.h.
4538 (mi_print_breakpoint_for_event): New.
4539 (mi_breakpoint_created, mi_breakpoint_modified): Use
4540 mi_print_breakpoint_for_event.
4541 * mi/mi-main.c: Don't include gdb.h.
4542 (mi_cmd_thread_select): Parse the global thread ID here. Use
4543 thread_select instead of gdb_thread_select.
4544 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
4545 of using gdb_list_thread_ids.
4546 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
4547 FILEIO_ENOSYS here.
4548 (remote_fileio_request): Use TRY/CATCH instead of
4549 catch_exceptions.
4550 * symfile-mem.c (struct symbol_file_add_from_memory_args)
4551 (symbol_file_add_from_memory_wrapper): Delete.
4552 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
4553 * thread.c: Don't include gdb.h.
4554 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
4555 (thread_alive): Use thread_select.
4556 (do_captured_thread_select): Delete, parts salvaged as ...
4557 (thread_select): ... this new function.
4558 (gdb_thread_select): Delete.
4559
bf469271
PA
45602017-10-10 Pedro Alves <palves@redhat.com>
4561 Tom Tromey <tom@tromey.com>
4562
4563 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
4564 and reverse logic.
4565 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
4566 No longer macros. Instead ...
4567 (enum wp_check_result): They're now values of this new
4568 enumeration.
4569 (watchpoint_check): Change return type to wp_check_result and
4570 parameter type to bpstat.
4571 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
4572 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
4573 catch_errors. Reverse logic of watchpoint_check call.
4574 (breakpoint_re_set_one): Now returns void and takes a breakpoint
4575 pointer as parameter.
4576 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
4577 * common/common-exceptions.c (throw_exception_sjlj): Update
4578 comments to avoid mentioning catch_errors.
4579 * exceptions.c (catch_errors): Delete.
4580 * exceptions.h: Update comments to avoid mentioning catch_errors.
4581 (catch_errors_ftype, catch_errors): Delete.
4582 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
4583 (hook_stop_stub): Delete.
4584 (restore_selected_frame): Change return type to void, and
4585 parameter type to const frame_id &.
4586 (restore_infcall_control_state): Use TRY/CATCH instead of
4587 catch_errors.
4588 * main.c (captured_command_loop): Return void and remove
4589 parameter. Remove references to catch_errors.
4590 (captured_main): Use TRY/CATCH instead of catch_errors.
4591 * objc-lang.c (objc_submethod_helper_data)
4592 (find_objc_msgcall_submethod_helper): Delete.
4593 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
4594 catch_errors.
4595 * record-full.c (record_full_message): Return void.
4596 (record_full_message_args, record_full_message_wrapper): Delete.
4597 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
4598 instead of catch_errors.
4599 * solib-aix.c (solib_aix_open_symbol_file_object): Change
4600 parameter type to int.
4601 * solib-darwin.c (open_symbol_file_object): Ditto.
4602 * solib-dsbt.c (open_symbol_file_object): Ditto.
4603 * solib-frv.c (open_symbol_file_object): Ditto.
4604 * solib-svr4.c (open_symbol_file_object): Ditto.
4605 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
4606 * solib.c (update_solib_list): Use TRY/CATCH instead of
4607 catch_errors.
4608 * solist.h (struct target_so_ops) <open_symbol_file_object>:
4609 Change type.
4610 * symmisc.c (struct print_symbol_args): Remove.
4611 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
4612 (print_symbol): Change type.
4613 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
4614 and remove parameters.
4615 (catch_errors): New.
4616 (get_windows_debug_event): Adjust.
4617
1a56bfa5
TT
46182017-10-09 Tom Tromey <tom@tromey.com>
4619
4620 * mi/mi-main.c (free_splay_tree): Remove.
4621 (list_available_thread_groups): Use splay_tree_up.
4622 * common/gdb_splay_tree.h: New file.
4623
0c478e2d
TT
46242017-10-09 Tom Tromey <tom@tromey.com>
4625
4626 * mi/mi-main.c (do_nothing): Remove.
4627 (list_available_thread_groups): Update.
4628
cbd2b4e3
PA
46292017-10-09 Pedro Alves <palves@redhat.com>
4630
4631 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
4632 reading registers when switching context.
4633
a181c0bf
JB
46342017-10-09 John Baldwin <jhb@FreeBSD.org>
4635
4636 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
4637 (fbsd_convert_siginfo): Likewise.
4638 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
4639
6e66f753
SM
46402017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
4641
4642 * configure.ac (try_guile_versions): Remove guile-2.2.
4643 * configure: Regenerate.
4644
890e9790
TT
46452017-10-09 Tom Tromey <tom@tromey.com>
4646
4647 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
4648 (COMPILE.pre): Use $(CXX).
4649
109483d9
PA
46502017-10-09 Pedro Alves <palves@redhat.com>
4651
4652 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
4653 Use bool.
4654 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
4655 * cp-support.h (cp_remove_params): Now returns a
4656 gdb::unique_xmalloc_ptr.
4657 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
4658 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
4659 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
4660 returning a gdb::unique_xmalloc_ptr.
4661 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
4662 * stack.c (find_frame_funname): Adjust to cp_remove_params
4663 returning a gdb::unique_xmalloc_ptr.
4664
791afaa2
TT
46652017-10-08 Tom Tromey <tom@tromey.com>
4666
4667 * dwarf2read.c (dwarf2_get_dwz_file): Use
4668 gdb::unique_xmalloc_ptr.
4669 (find_slot_in_mapped_hash): Likewise.
4670 (dwarf2_physname): Likewise.
4671 (create_dwo_unit_in_dwp_v1): Use std::string.
4672 (create_dwo_unit_in_dwp_v2): Likewise.
4673 (lookup_dwo_cutu): Likewise.
4674 (inherit_abstract_dies): Use std::vector.
4675 (read_array_type): Likewise.
4676 (dwarf_decode_macros): Remove unused declaration.
4677 (unsigned_int_compar): Remove.
4678 (dwarf2_build_psymtabs_hard): Use scoped_restore.
4679 (psymtabs_addrmap_cleanup): Remove.
4680
30a9c02f
TT
46812017-10-08 Tom Tromey <tom@tromey.com>
4682
4683 * frame-unwind.c (frame_unwind_try_unwinder): Update.
4684 * frame.h (frame_cleanup_after_sniffer): Declare.
4685 (frame_prepare_for_sniffer): Return void.
4686 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
4687 type of argument.
4688 (frame_prepare_for_sniffer): Return void.
4689
757325a3
TT
46902017-10-08 Tom Tromey <tom@tromey.com>
4691
4692 * utils.h (make_cleanup_value_free): Remove.
4693 * utils.c (do_value_free, struct cleanup): Remove.
4694 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
4695 Use gdb_value_up.
4696 * value.h (struct value_deleter): New.
4697 (gdb_value_up): New typedef.
4698
b9c04fb2
TT
46992017-10-08 Tom Tromey <tom@tromey.com>
4700
4701 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
4702 (make_cleanup_free_search_symbols): Remove.
4703 (search_symbols): Return std::vector.
4704 (symbol_search::compare_search_syms): Now member of
4705 symbol_search. Change arguments.
4706 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
4707 (symtab_symbol_info, rbreak_command): Update.
4708 * symtab.h (struct symbol_search) <next>: Remove.
4709 Add constructors.
4710 (symbol_search::operator<): New function.
4711 (symbol_search::operator==): New function.
4712 (search_symbols): Remove std::vector.
4713 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
4714 (symbol_search::compare_search_syms): Declare.
4715
0d28b0a5
YQ
47162017-10-06 Yao Qi <yao.qi@linaro.org>
4717
4718 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
4719 arch/aarch64-insn.o.
4720 Remove one rule.
4721 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
4722
71917808
YQ
47232017-10-06 Yao Qi <yao.qi@linaro.org>
4724
4725 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
4726 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
4727 arch/arm-linux.o respectively.
4728 * configure.tgt: Likewise.
4729
2081b2b2
YQ
47302017-10-06 Yao Qi <yao.qi@linaro.org>
4731
4732 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
4733 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
4734
a1b85d28
PA
47352017-10-06 Pedro Alves <palves@redhat.com>
4736
4737 * windows-nat.c: Include <algorithm>.
4738
d97987e2
YQ
47392017-10-06 Yao Qi <yao.qi@linaro.org>
4740
4741 * configure.tgt (i386_tobjs): New variable.
4742 (amd64_tobjs): New variable.
4743 Set $cpu_obs and $os_obs.
4744
f38307f5
YQ
47452017-10-06 Yao Qi <yao.qi@linaro.org>
4746
4747 * Makefile.in (CONFIG_SRC_SUBDIR): New.
4748 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
4749 (clean): Remove object files and dependency files.
4750 (distclean): Remove the directory.
4751 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4752 * configure: Re-generated.
4753 * configure.tgt: Replace amd64.o with arch/amd64.o.
4754
2f924de6
JM
47552017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
4756
4757 PR build/22188
4758 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
4759 and SETEND.
4760
2fd9d7ca
PA
47612017-10-05 Pedro Alves <palves@redhat.com>
4762
4763 * linux-nat.c (linux_child_follow_fork): When following the parent
4764 and detaching the child, consult the parent thread's architecture
4765 instead of the child's.
4766
d13b8493
UW
47672017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4768
4769 * ax.h: Do not include "doublest.h".
4770 (union agent_val): Remove.
4771
3b4b2f16
UW
47722017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4773
4774 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
4775 (decimal_to_string): Return std::string object.
4776 (decimal_from_string): Accept std::string object. Return bool.
4777 (decimal_from_integral, decimal_from_doublest): Remove.
4778 (decimal_from_longest): Add prototype.
4779 (decimal_from_ulongest): Likewise.
4780 (decimal_to_longest): Likewise.
4781 (decimal_from_doublest): Likewise.
4782 * dfp.c: Do not include "gdbtypes.h" or "value.h".
4783 (MAX_DECIMAL_STRING): Move here.
4784 (decimal_to_string): Return std::string object.
4785 (decimal_from_string): Accept std::string object. Return bool.
4786 (decimal_from_integral): Remove, replace by ...
4787 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
4788 (decimal_to_longest): New function.
4789 (decimal_from_floating): Remove, replace by ...
4790 (decimal_from_doublest): ... this new function.
4791 (decimal_to_doublest): Update to new decimal_to_string interface.
4792
4793 * value.c (unpack_long): Use decimal_to_longest.
4794 * valops.c (value_cast): Use decimal_from_doublest instead of
4795 decimal_from_floating. Use decimal_from_[u]longest isntead of
4796 decimal_from_integral.
4797 * valarith.c (value_args_as_decimal): Likewise.
4798 * valprint.c (print_decimal_floating): Update to new
4799 decimal_to_string interface.
4800 * printcmd.c (printf_decfloat): Likewise.
4801 * c-exp.y (parse_number): Update to new decimal_from_string interface.
4802
1841ee5d
UW
48032017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4804
4805 * doublest.h: Do not include "floatformat.h". Remove stale comments.
4806 * gdbtypes.c: Include "floatformat.h".
4807 * value.c: Likewise.
4808 * m68k-tdep.c: Likewise.
4809
4810 * findvar.c: Do not include "floatformat.h".
4811 * amd64-darwin-tdep.c: Likewise.
4812 * arm-linux-tdep.c: Likewise.
4813 * i386-darwin-tdep.c: Likewise.
4814 * i387-tdep.c: Likewise.
4815 * m68k-linux-tdep.c: Likewise.
4816 * mep-tdep.c: Likewise.
4817 * mips-tdep.c: Likewise.
4818 * nios2-tdep.c: Likewise.
4819 * s390-linux-tdep.c: Likewise.
4820 * sparc-obsd-tdep.c: Likewise.
4821 * sparc-tdep.c: Likewise.
4822 * sparc64-tdep.c: Likewise.
4823 * spu-tdep.c: Likewise.
4824 * tic6x-tdep.c: Likewise.
4825 * tilegx-tdep.c: Likewise.
4826 * vax-tdep.c: Likewise.
4827 * xstormy16-tdep.c: Likewise.
4828 * xtensa-tdep.c: Likewise.
4829
4830 * top.c: Do not include "doublest.h".
4831 * aarch64-tdep.c: Likewise.
4832 * alpha-tdep.c: Likewise.
4833 * arm-linux-tdep.c: Likewise.
4834 * m68k-linux-tdep.c: Likewise.
4835 * tilegx-tdep.c: Likewise.
4836 * xstormy16-tdep.c: Likewise.
4837
a80a6471
JB
48382017-10-05 John Baldwin <jhb@FreeBSD.org>
4839
4840 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
4841 (mipsn32_fbsd_sigframe): Define.
4842 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
4843 for FreeBSD/mipsn32.
4844
12c4bd7f
JB
48452017-10-05 John Baldwin <jhb@FreeBSD.org>
4846
4847 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
4848 AT_HWCAP.
4849
c91933e9
TG
48502017-10-05 Tristan Gingold <tgingold@free.fr>
4851
4852 * MAINTAINERS (Misc): Update my email address.
4853
5cd63fda
PA
48542017-10-04 Pedro Alves <palves@redhat.com>
4855
4856 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
4857 it instead of target_gdbarch.
4858 (get_remote_state, get_remote_packet_size): Adjust
4859 get_remote_arch_state calls, passing down target_gdbarch
4860 explicitly.
4861 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
4862 'gdbarch' and use it instead of target_gdbarch.
4863 (get_memory_packet_size): Adjust get_remote_arch_state calls,
4864 passing down target_gdbarch explicitly.
4865 (struct stop_reply) <arch>: New field.
4866 (remote_parse_stop_reply): Use the stopped thread's architecture,
4867 not the current inferior's. Save the architecture in the
4868 stop_reply.
4869 (process_stop_reply): Use the stop reply's architecture.
4870 (process_g_packet, remote_fetch_registers)
4871 (remote_prepare_to_store, store_registers_using_G)
4872 (remote_store_registers): Adjust get_remote_arch_state calls,
4873 using the regcache's architecture.
4874 (remote_get_trace_status): Adjust get_remote_arch_state calls,
4875 passing down target_gdbarch explicitly.
4876 * spu-multiarch.c (spu_thread_architecture): Defer to the target
4877 beneath instead of calling target_gdbarch.
4878 * target.c (default_thread_architecture): Use the specified
4879 inferior's architecture, instead of the current inferior's
4880 architecture (via target_gdbarch).
4881
ed4227b7
PA
48822017-10-04 Pedro Alves <palves@redhat.com>
4883
4884 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
4885 case.
4886 (regcache_print): Handle !target_has_registers here instead.
4887
55b11ddf
PA
48882017-10-04 Pedro Alves <palves@redhat.com>
4889
4890 * frame.c (create_test_frame): Delete.
4891 * frame.h (create_test_frame): Delete.
4892 * gdbarch-selftests.c: Include gdbthread.h and target.h.
4893 (class regcache_test): Delete.
4894 (test_target_has_registers, test_target_has_stack)
4895 (test_target_has_memory, test_target_prepare_to_store)
4896 (test_target_store_registers): New functions.
4897 (test_target_ops): New class.
4898 (register_to_value_test): Error out if there's already a
4899 process_stratum (or higher) target pushed. Create a fuller mock
4900 environment, with mock target_ops, inferior, address space, thread
4901 and inferior_ptid.
4902 * progspace.c (struct address_space): Move to ...
4903 * progspace.h (struct address_space): ... here.
4904 * regcache.h (regcache::~regcache, regcache::raw_write)
4905 [GDB_SELF_TEST]: No longer virtual.
4906
4c71c105
SM
49072017-10-04 Simon Marchi <simon.marchi@ericsson.com>
4908
4909 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
4910
73dcd72d
PA
49112017-10-04 Pedro Alves <palves@redhat.com>
4912
4913 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
4914 out of 'between TRY and CATCH'.
4915
44704526
PA
49162017-10-04 Pedro Alves <palves@redhat.com>
4917
4918 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
4919 * common/common-exceptions.h (TRY): Open an outermost scope.
4920 Expand intro comment.
4921 (CATCH): Reindent.
4922 (END_CATCH): Close the outermost scope.
4923 * completer.c (complete_line_internal): Add missing END_CATCH.
4924
bc3b087d
SDJ
49252017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4926
4927 * NEWS (Changes since GDB 8.0): Add entry about new
4928 'set-cwd-on-gdbserver' feature.
4929 (New remote packets): Add entry for QSetWorkingDir.
4930 * common/common-inferior.h (set_inferior_cwd): New prototype.
4931 * infcmd.c (set_inferior_cwd): Remove "static".
4932 (show_cwd_command): Expand text to include remote debugging.
4933 * remote.c: Add PACKET_QSetWorkingDir.
4934 (remote_protocol_features) <QSetWorkingDir>: New entry for
4935 PACKET_QSetWorkingDir.
4936 (extended_remote_set_inferior_cwd): New function.
4937 (extended_remote_create_inferior): Call
4938 "extended_remote_set_inferior_cwd".
4939 (_initialize_remote): Call "add_packet_config_cmd" for
4940 QSetWorkingDir.
4941
d092c5a2
SDJ
49422017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4943
4944 * NEWS (New commands): Mention "set/show cwd".
4945 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
4946 "cd" command's help text.
4947 * common/common-inferior.h (get_inferior_cwd): New prototype.
4948 * infcmd.c (inferior_cwd_scratch): New global variable.
4949 (set_inferior_cwd): New function.
4950 (get_inferior_cwd): Likewise.
4951 (set_cwd_command): Likewise.
4952 (show_cwd_command): Likewise.
4953 (_initialize_infcmd): Add "set/show cwd" commands.
4954 * inferior.h (class inferior) <cwd>: New field.
4955 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
4956 (fork_inferior): Change inferior's cwd before its execution.
4957 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
4958 to CreateProcess.
4959
7da0a886
SDJ
49602017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4961
4962 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
4963 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
4964 (COMMON_OBS): Add gdb_tilde_expand.o.
4965 * common/gdb_tilde_expand.c: New file.
4966 * common/gdb_tilde_expand.h: Likewise.
4967
db8dd160
MR
49682017-10-03 Maciej W. Rozycki <macro@imgtec.com>
4969
4970 * gdbarch.sh (objfile): Remove duplicate declaration.
4971 * gdbarch.h: Regenerate.
4972
f8bfbf22
TT
49732017-10-03 Tom Tromey <tom@tromey.com>
4974
4975 * utils.c (internal_vproblem): Use string_vprintf.
4976
5178ed48
TT
49772017-10-03 Tom Tromey <tom@tromey.com>
4978
4979 * printcmd.c (info_symbol_command): Use std::string.
4980
8cff8730
TT
49812017-10-03 Tom Tromey <tom@tromey.com>
4982
4983 * top.c (gdb_safe_append_history): Use std::string.
4984
895b8f30
TT
49852017-10-03 Tom Tromey <tom@tromey.com>
4986
4987 * event-top.c (stdin_event_handler): Update.
4988 * main.c (captured_main_1): Update.
4989 * top.h (make_delete_ui_cleanup): Remove.
4990 (struct ui): Add constructor and destructor.
4991 (new_ui, delete_ui): Remove.
4992 * top.c (make_delete_ui_cleanup): Remove.
4993 (new_ui_command): Use std::unique_ptr.
4994 (delete_ui_cleanup): Remove.
4995 (ui::ui): Rename from new_ui. Update.
4996 (free_ui): Remove.
4997 (ui::~ui): Rename from delete_ui. Update.
4998
0efef640
TT
49992017-10-03 Tom Tromey <tom@tromey.com>
5000
5001 * symfile.c (load_progress): Use gdb::byte_vector.
5002
245ad7d3
TT
50032017-10-03 Tom Tromey <tom@tromey.com>
5004
5005 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
5006 declaration.
5007 * printcmd.c (x_command): Remove unused declaration.
5008 * symfile.c (symbol_file_command): Remove unused declaration.
5009
e05550d7
TT
50102017-10-03 Tom Tromey <tom@tromey.com>
5011
5012 * utils.c (internal_vproblem): Use std::string.
5013 (defaulted_query): Likewise.
5014
b95de2b7
TT
50152017-10-03 Tom Tromey <tom@tromey.com>
5016
5017 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
5018 * top.c (execute_command_to_string): Update.
5019 * utils.c (make_cleanup_restore_page_info): Remove.
5020 (do_restore_page_info_cleanup): Remove.
5021 (set_batch_flag_and_restore_page_info):
5022 New.
5023 (make_cleanup_restore_page_info): Remove.
5024 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
5025 (~set_batch_flag_and_restore_page_info): New
5026 (make_cleanup_restore_uinteger): Remove.
5027 (make_cleanup_restore_integer): Remove.
5028 (struct restore_integer_closure): Remove.
5029 (restore_integer): Remove.
5030 * utils.h (struct set_batch_flag_and_restore_page_info): New
5031 class.
5032 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
5033 (make_cleanup_restore_page_info): Remove.
5034 (make_cleanup_restore_uinteger) Remove.
5035 (make_cleanup_restore_integer) Remove.
5036
07036511
TT
50372017-10-03 Tom Tromey <tom@tromey.com>
5038
5039 * record-full.h (record_full_gdb_operation_disable_set): Return
5040 scoped_restore_tmpl<int>.
5041 * infrun.c (adjust_pc_after_break): Update.
5042 (handle_signal_stop): Update.
5043 * record-full.c (record_full_gdb_operation_disable_set): Return
5044 scoped_restore_tmpl<int>.
5045 (record_full_wait_1, record_full_insert_breakpoint)
5046 (record_full_remove_breakpoint, record_full_save)
5047 (record_full_goto_insn): Update.
5048
45320ffa
TT
50492017-10-02 Tom Tromey <tom@tromey.com>
5050
5051 PR rust/22236:
5052 * rust-lang.c (rust_val_print_str): New function.
5053 (val_print_struct): Call it.
5054 (rust_subscript): Preserve name of slice type.
5055
b3e3859b
TT
50562017-10-02 Tom Tromey <tom@tromey.com>
5057
5058 * rust-lang.c (rust_subscript): Handle slices in
5059 EVAL_AVOID_SIDE_EFFECTS case.
5060
01af5e0d
TT
50612017-10-02 Tom Tromey <tom@tromey.com>
5062
5063 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
5064
888e3ddb
TT
50652017-10-02 Tom Tromey <tom@tromey.com>
5066
5067 * rust-lang.h (rust_slice_type): Add "extern".
5068
cc536b21
PA
50692017-10-02 Tom Tromey <tom@tromey.com>
5070 Pedro Alves <palves@redhat.com>
5071
5072 * ada-lang.h (ada_exc_info::operator<): Make const.
5073 (ada_exc_info::operator==): Make const.
5074 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
5075 Make const.
5076
386c8614
TT
50772017-09-29 Tom Tromey <tom@tromey.com>
5078
5079 * target.c (read_whatever_is_readable): Change type of "result".
5080 Update.
5081 (free_memory_read_result_vector): Remove.
5082 (read_memory_robust): Change return type. Update.
5083 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
5084 bin2hex, std::string.
5085 * target.h (memory_read_result_s): Remove typedef.
5086 (free_memory_read_result_vector): Remove.
5087 (read_memory_robust): Return std::vector.
5088
789c4b5e
TT
50892017-09-29 Tom Tromey <tom@tromey.com>
5090
5091 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
5092
ab816a27
TT
50932017-09-29 Tom Tromey <tom@tromey.com>
5094
5095 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
5096 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
5097 operator< and operator==.
5098 (ada_exceptions_list): Return a std::vector.
5099 * ada-lang.c (ada_exc_info::operator<): Rename from
5100 compare_ada_exception_info.
5101 (ada_exc_info::operator==): New.
5102 (sort_remove_dups_ada_exceptions_list): Change type of
5103 "exceptions".
5104 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
5105 (ada_add_global_exceptions): Likewise.
5106 (ada_exceptions_list_1): Return a std::vector.
5107 (ada_exceptions_list): Likewise.
5108
52f9abe4
TT
51092017-09-29 Tom Tromey <tom@tromey.com>
5110
5111 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
5112 'std::set *'.
5113 (print_one_inferior): Update.
5114 (free_vector_of_ints): Remove.
5115 (list_available_thread_groups): Change "ids" to std::set.
5116 (mi_cmd_list_thread_groups): Update.
5117 (struct collect_cores_data) <core>: Now a std::set.
5118 (collect_cores): Update.
5119 (unique): Remove.
5120 (print_one_inferior): Update.
5121
dcd5ddcc
TT
51222017-09-29 Tom Tromey <tom@tromey.com>
5123
5124 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
5125 (mi_execute_async_cli_command): Likewise.
5126 (mi_cmd_trace_frame_collected): Use field_fmt.
5127
45d288cc
TT
51282017-09-29 Tom Tromey <tom@tromey.com>
5129
5130 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
5131 gdb::byte_vector.
5132
6afe2f4a
TT
51332017-09-29 Tom Tromey <tom@tromey.com>
5134
5135 * mi/mi-parse.c (mi_parse): Remove unused declaration.
5136
9813429a
TT
51372017-09-29 Tom Tromey <tom@tromey.com>
5138
5139 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
5140
2d6960b4
TT
51412017-09-29 Tom Tromey <tom@tromey.com>
5142
5143 * varobj.h (varobj_gen_name): Return std::string.
5144 * varobj.c (varobj_gen_name): Return std::string.
5145 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
5146 (mi_cmd_var_delete): Don't copy "name".
5147
784c453a
TT
51482017-09-29 Tom Tromey <tom@tromey.com>
5149
5150 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
5151 (mi_cmd_break_insert_1): Update.
5152
a9bc57b9
TT
51532017-09-29 Tom Tromey <tom@tromey.com>
5154
5155 * target.h (make_scoped_defer_target_commit_resume): Update.
5156 * target.c (make_scoped_defer_target_commit_resume): Rename from
5157 make_cleanup_defer_target_commit_resume. Return a
5158 scoped_restore.
5159 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
5160
9754d8c4
TT
51612017-09-29 Tom Tromey <tom@tromey.com>
5162
5163 * main.c (captured_main_1): Remove unused declaration.
5164 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
5165
99ef965c
TT
51662017-09-29 Tom Tromey <tom@tromey.com>
5167
5168 * symtab.c (search_symbols): Remove unused outer cleanup.
5169 (make_source_files_completion_list): Remove unused declaration.
5170
42518ba7
TT
51712017-09-29 Tom Tromey <tom@tromey.com>
5172
5173 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
5174
726b2169
TT
51752017-09-29 Tom Tromey <tom@tromey.com>
5176
5177 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
5178 gdb::byte_vector.
5179
55b06432
TT
51802017-09-29 Tom Tromey <tom@tromey.com>
5181
5182 * complaints.c (vcomplaint): Use std::string.
5183
8abcee91
TT
51842017-09-29 Tom Tromey <tom@tromey.com>
5185
5186 * tracepoint.c (trace_variable_command): Use std::string.
5187 (encode_actions_1): Remove unused declarations.
5188 (create_tsv_from_upload): Use std::string.
5189
6ad94bc7
TT
51902017-09-29 Tom Tromey <tom@tromey.com>
5191
5192 * cp-support.c (gdb_demangle): Use std::string.
5193
2003f3d8
TT
51942017-09-29 Tom Tromey <tom@tromey.com>
5195
5196 * stack.c (parse_frame_specification): Use std::string
5197 (info_frame_command): Use gdb::unique_xmalloc_ptr.
5198
8f8accb5
TT
51992017-09-29 Tom Tromey <tom@tromey.com>
5200
5201 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
5202
200aa7b1
TT
52032017-09-29 Tom Tromey <tom@tromey.com>
5204
5205 * utils.c (vfprintf_maybe_filtered): Use std::string.
5206 (vfprintf_unfiltered): Likewise.
5207
606aae8a
TT
52082017-09-29 Tom Tromey <tom@tromey.com>
5209
5210 * event-top.c (top_level_prompt): Return std::string.
5211 (display_gdb_prompt): Update.
5212
bd413795
TT
52132017-09-29 Tom Tromey <tom@tromey.com>
5214
5215 * unittests/common-utils-selftests.c (format): New function.
5216 (string_vprintf_tests): New function.
5217 (_initialize_common_utils_selftests): Register new tests.
5218 * common/common-utils.c (string_vprintf): New function.
5219 * common/common-utils.h (string_vprintf): Declare.
5220
256642e8
PA
52212017-09-29 Pedro Alves <palves@redhat.com>
5222
5223 * common/rsp-low.c (unpack_varlen_hex): Constify.
5224 * common/rsp-low.h (unpack_varlen_hex): Constify.
5225 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
5226 Constify.
5227 * remote.c (remote_set_permissions, read_ptid)
5228 (remote_current_thread, remote_get_threads_with_qthreadinfo)
5229 (remote_static_tracepoint_marker_at)
5230 (remote_static_tracepoint_markers_by_strid)
5231 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
5232 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
5233 (parse_tracepoint_definition, parse_tsv_definition)
5234 (parse_static_tracepoint_marker_definition): Constify.
5235 * tracepoint.h (parse_static_tracepoint_marker_definition)
5236 (parse_trace_status, parse_tracepoint_status)
5237 (parse_tracepoint_definition, parse_tsv_definition): Constify.
5238
b6bb3468
PA
52392017-09-29 Pedro Alves <palves@redhat.com>
5240
5241 * remote.c (target_buf, target_buf_size): Delete.
5242 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
5243 Use the connection's packet buffer instead.
5244 All callers adjusted.
5245 (_initialize_remote): Remove references to target_buf and
5246 target_buf_size.
5247
b2f8eb7a
PA
52482017-09-28 Pedro Alves <palves@redhat.com>
5249
5250 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5251 unittests/common-utils-selftests.c.
5252 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
5253 (COMMON_OBS): Remove utils-selftests.o.
5254 * utils-selftests.c: Move to ...
5255 * unittests/common-utils-selftests.c: ... here and rename self
5256 test to "string_printf".
5257
08302ed2
DE
52582017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
5259
5260 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
5261 having NULL cus or tus.
5262
96a5a1d3
UW
52632017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5264
5265 * arm-tdep.c: (convert_from_extended): Remove.
5266 (convert_to_extended): Likewise.
5267 (arm_extract_return_value): Use convert_typed_floating.
5268 (arm_store_return_value): Likewise.
5269
5270 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5271 * sh-tdep.c: Do not include "floatformat.h".
5272 (sh_littlebyte_bigword_type): New function.
5273 (sh_register_convert_to_virtual): Use convert_typed_floating.
5274 (sh_register_convert_to_raw): Likewise.
5275 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5276 (sh64_littlebyte_bigword_type): New function.
5277 (sh64_extract_return_value): Use convert_typed_floating.
5278 (sh64_register_convert_to_virtual): Likewise.
5279 (sh64_register_convert_to_raw): Likewise.
5280
0db7851f
UW
52812017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5282
5283 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
5284 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
5285
5286 * gdbtypes.h (union type_specific): Make field floatformat hold
5287 just a single struct floatformat, not an array.
5288 (floatformat_from_type): Move here.
5289 * gdbtypes.c (floatformat_from_type): Move here. Update to
5290 changed TYPE_FLOATFORMAT definition.
5291 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
5292 (recursive_dump_type): Likewise.
5293 (init_float_type): Install correct floatformat for byte order.
5294 (arch_float_type): Likewise.
5295
77b7c781
UW
52962017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5297
5298 * gdbtypes.c (init_type): Change incoming argument from
5299 length-in-bytes to length-in-bits. Assert length is a
5300 multiple of TARGET_CHAR_BITS.
5301 (arch_type, arch_flags_type): Likewise.
5302 (init_integer_type): Update call to init_type.
5303 (init_character_type): Likewise.
5304 (init_boolean_type): Likewise.
5305 (init_float_type): Likewise.
5306 (init_decfloat_type): Likewise.
5307 (init_complex_type): Likewise.
5308 (init_pointer_type): Likewise.
5309 (objfile_type): Likewise.
5310 (arch_integer_type): Update call to arch_type.
5311 (arch_character_type): Likewise.
5312 (arch_boolean_type): Likewise.
5313 (arch_float_type): Likewise.
5314 (arch_decfloat_type): Likewise.
5315 (arch_complex_type): Likewise.
5316 (arch_pointer_type): Likewise.
5317 (gdbtypes_post_init): Likewise.
5318
5319 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
5320 (read_base_type): Likewise.
5321 * mdebugread.c (basic_type): Likewise.
5322 * stabsread.c (dbx_init_float_type): Likewise.
5323 (rs6000_builtin_type): Likewise.
5324 (read_range_type): Likewise. Also, fix call to init_integer_type
5325 with erroneous length argument.
5326
5327 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
5328 * d-lang.c (build_d_types): Likewise.
5329 * f-lang.c (build_fortran_types): Likewise.
5330 * go-lang.c (build_go_types): Likewise.
5331 * opencl-lang.c (build_opencl_types): Likewise.
5332 * jit.c (finalize_symtab): Likewise.
5333 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
5334 (build_std_type_info_type): Likewise.
5335 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
5336 update call to arch_flags_type.
5337
5338 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
5339 arch_type.
5340 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
5341 * windows-tdep.c (windows_get_tlb_type): Likewise.
5342
5343 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
5344 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
5345 * m32c-tdep.c (make_types): Likewise.
5346 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
5347 (rl78_psw_type): Update call to arch_flags_type.
5348 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
5349 * rx-tdep.c (rx_psw_type): Likewise.
5350 (rx_fpsw_type): Likewise.
5351 * sparc-tdep.c (sparc_psr_type): Likewise.
5352 (sparc_fsr_type): Likewise.
5353 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
5354 (sparc64_ccr_type): Likewise.
5355 (sparc64_fsr_type): Likewise.
5356 (sparc64_fprs_type): Likewise.
5357
f21b4d5c
TT
53582017-09-27 Tom Tromey <tom@tromey.com>
5359
5360 * findcmd.c (find_command): Constify.
5361
643c2ffa
TT
53622017-09-27 Tom Tromey <tom@tromey.com>
5363
5364 * ada-tasks.c (task_command_1, task_command): Constify.
5365
510e5e56
TT
53662017-09-27 Tom Tromey <tom@tromey.com>
5367
5368 * symtab.c (maintenance_print_symbol_cache)
5369 (maintenance_flush_symbol_cache)
5370 (maintenance_print_symbol_cache_statistics): Constify.
5371
e503b191
TT
53722017-09-27 Tom Tromey <tom@tromey.com>
5373
5374 * inferior.c (detach_inferior_command, kill_inferior_command)
5375 (inferior_command): Constify.
5376
4e001312
TT
53772017-09-27 Tom Tromey <tom@tromey.com>
5378
5379 * regcache.c (regcache_print, maintenance_print_registers)
5380 (maintenance_print_raw_registers)
5381 (maintenance_print_cooked_registers)
5382 (maintenance_print_register_groups)
5383 (maintenance_print_remote_registers): Constify.
5384
77763700
TT
53852017-09-27 Tom Tromey <tom@tromey.com>
5386
5387 * printcmd.c (map_display_numbers, undisplay_command)
5388 (enable_disable_display_command, enable_display_command)
5389 (disable_display_command): Constify.
5390
4495129a
TT
53912017-09-27 Tom Tromey <tom@tromey.com>
5392
5393 * breakpoint.h (delete_command): Don't declare.
5394 * breakpoint.c (delete_command, enable_once_command)
5395 (enable_count_command, enable_delete_command, breakpoint_1)
5396 (maintenance_info_breakpoints, stopin_command, stopat_command)
5397 (delete_command, delete_trace_command, save_breakpoints)
5398 (save_breakpoints_command, save_tracepoints_command): Constify.
5399
3088cf40
TT
54002017-09-27 Tom Tromey <tom@tromey.com>
5401
5402 * macrocmd.c (macro_expand_command, macro_expand_once_command)
5403 (skip_ws, extract_identifier, macro_define_command)
5404 (macro_undef_command, macro_list_command): Constify.
5405
69f476a3
TT
54062017-09-27 Tom Tromey <tom@tromey.com>
5407
5408 * infcmd.c (environment_info, set_environment_command)
5409 (unset_environment_command, path_info, info_proc_cmd_1)
5410 (info_proc_cmd_mappings, info_proc_cmd_stat)
5411 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
5412 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
5413
c4a3e68e
TT
54142017-09-27 Tom Tromey <tom@tromey.com>
5415
5416 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
5417 Constify.
5418
c9d31bd6
TT
54192017-09-27 Tom Tromey <tom@tromey.com>
5420
5421 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
5422
1f3f85eb
TT
54232017-09-27 Tom Tromey <tom@tromey.com>
5424
5425 * demangle.c (demangle_command): Constify.
5426
9c504b5d
TT
54272017-09-27 Tom Tromey <tom@tromey.com>
5428
5429 * progspace.c (maintenance_info_program_spaces_command):
5430 Constify.
5431
6663cf91
TT
54322017-09-27 Tom Tromey <tom@tromey.com>
5433
5434 * compile/compile.c (check_raw_argument, compile_file_command)
5435 (compile_code_command, compile_print_command): Constify.
5436
34e5fa26
TT
54372017-09-27 Tom Tromey <tom@tromey.com>
5438
5439 * reggroups.c (maintenance_print_reggroups): Constify.
5440
8384c356
TT
54412017-09-27 Tom Tromey <tom@tromey.com>
5442
5443 * dwarf2read.c (save_gdb_index_command): Constify.
5444
884beb0c
TT
54452017-09-27 Tom Tromey <tom@tromey.com>
5446
5447 * stap-probe.c (info_probes_stap_command): Constify.
5448
e0b2930c
TT
54492017-09-27 Tom Tromey <tom@tromey.com>
5450
5451 * fork-child.c (unset_exec_wrapper_command): Constify.
5452
f938677d
TT
54532017-09-27 Tom Tromey <tom@tromey.com>
5454
5455 * btrace.c (get_uint, get_context_size, no_chunk)
5456 (maint_btrace_packet_history_cmd)
5457 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
5458 (maint_info_btrace_cmd): Constify.
5459
8949cb87
TT
54602017-09-27 Tom Tromey <tom@tromey.com>
5461
5462 * reverse.c (delete_bookmark_command): Constify.
5463
ac88e2de
TT
54642017-09-27 Tom Tromey <tom@tromey.com>
5465
5466 * remote.c (set_memory_packet_size)
5467 (set_memory_write_packet_size, show_memory_write_packet_size)
5468 (set_memory_read_packet_size, show_memory_read_packet_size)
5469 (compare_sections_command, packet_command, remote_put_command)
5470 (remote_get_command, remote_delete_command): Constify.
5471
bd4c9dfe
TT
54722017-09-27 Tom Tromey <tom@tromey.com>
5473
5474 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
5475 (set_mipsfpu_double_command, set_mipsfpu_none_command)
5476 (set_mipsfpu_auto_command): Constify.
5477
5e93d4c6
TT
54782017-09-27 Tom Tromey <tom@tromey.com>
5479
5480 * cli/cli-cmds.h (cd_command): Constify.
5481 * cli/cli-cmds.c (cd_command): Constify.
5482
fc41a75b
TT
54832017-09-27 Tom Tromey <tom@tromey.com>
5484
5485 * thread.c (thread_name_command, thread_find_command): Constify.
5486
67810076
TT
54872017-09-27 Tom Tromey <tom@tromey.com>
5488
5489 * probe.c (enable_probes_command, disable_probes_command):
5490 Constify.
5491
1d8b34a7
TT
54922017-09-27 Tom Tromey <tom@tromey.com>
5493
5494 * symfile.c (symbol_file_command): Constify.
5495 * gdbcore.h (deprecated_file_changed_hook): Constify.
5496 * exec.c (deprecated_file_changed_hook, exec_file_command)
5497 (file_command): Constify.
5498 * defs.h (symbol_file_command): Constify.
5499
442019e1
TT
55002017-09-27 Tom Tromey <tom@tromey.com>
5501
5502 * remote-fileio.c (set_system_call_allowed)
5503 (show_system_call_allowed): Constify.
5504
2983f7cb
TT
55052017-09-27 Tom Tromey <tom@tromey.com>
5506
5507 * tracepoint.c (delete_trace_variable_command)
5508 (tfind_end_command, tfind_start_command, tfind_pc_command)
5509 (tfind_tracepoint_command, tfind_line_command)
5510 (tfind_range_command, tfind_outside_command): Constify.
5511
4fd41b24
TT
55122017-09-27 Tom Tromey <tom@tromey.com>
5513
5514 * ax-gdb.c (maint_agent_printf_command, agent_command)
5515 (agent_eval_command): Constify.
5516
f2fc3015
TT
55172017-09-27 Tom Tromey <tom@tromey.com>
5518
5519 * tracepoint.c (info_scope_command): Constify.
5520 * python/python.c (gdbpy_decode_line): Constify.
5521 * python/py-breakpoint.c (bppy_init): Constify.
5522 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
5523 * location.h: (new_linespec_location)
5524 (string_to_event_location_basic, string_to_event_location):
5525 Constify.
5526 * location.c (new_linespec_location)
5527 (string_to_event_location_basic, string_to_event_location):
5528 Constify.
5529 * linespec.h (decode_line_with_current_source)
5530 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
5531 * linespec.c (linespec_lex_to_end)
5532 (decode_line_with_current_source)
5533 (decode_line_with_last_displayed): Constify.
5534 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
5535 Constify.
5536 * cli/cli-cmds.c (edit_command, list_command): Constify.
5537 * breakpoint.h (until_break_command, watch_command_wrapper)
5538 (awatch_command_wrapper, rwatch_command_wrapper)
5539 (init_ada_exception_breakpoint): Constify.
5540 * breakpoint.c (break_command_1, dprintf_command)
5541 (break_range_command, watch_command_wrapper)
5542 (rwatch_command_wrapper, awatch_command_wrapper)
5543 (until_break_command, init_ada_exception_breakpoint)
5544 (strace_marker_create_sals_from_location, trace_command)
5545 (ftrace_command, strace_command, struct tracepoint): Constify.
5546 * ax-gdb.c (agent_command_1): Constify.
5547 * ada-lang.c (ada_exception_sal): Constify.
5548
8c2f95f4
TT
55492017-09-27 Tom Tromey <tom@tromey.com>
5550
5551 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
5552 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
5553 (get_context_size, no_chunk, get_insn_history_modifiers)
5554 (cmd_record_insn_history, get_call_history_modifiers)
5555 (cmd_record_call_history): Constify.
5556
a0d65762
TT
55572017-09-27 Tom Tromey <tom@tromey.com>
5558
5559 * source.c (show_substitute_path_command)
5560 (unset_substitute_path_command, set_substitute_path_command):
5561 Constify.
5562
58971144
TT
55632017-09-27 Tom Tromey <tom@tromey.com>
5564
5565 * typeprint.c (maintenance_print_type): Constify.
5566 * maint.c (maintenance_dump_me, maintenance_demangle)
5567 (maintenance_time_display, maintenance_info_sections)
5568 (maintenance_print_statistics, maintenance_deprecate)
5569 (maintenance_undeprecate): Constify.
5570 (maintenance_do_deprecate): Constify. Use std::string.
5571 (maintenance_selftest): Constify.
5572 * gdbtypes.h (maintenance_print_type): Constify.
5573
c482f52c
TT
55742017-09-27 Tom Tromey <tom@tromey.com>
5575
5576 * hppa-tdep.c (unwind_command): Constify.
5577
e100df1a
TT
55782017-09-27 Tom Tromey <tom@tromey.com>
5579
5580 * target-descriptions.c (unset_tdesc_filename_cmd)
5581 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
5582 Constify.
5583
31d56ade
TT
55842017-09-27 Tom Tromey <tom@tromey.com>
5585
5586 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
5587
b961da0b
TT
55882017-09-27 Tom Tromey <tom@tromey.com>
5589
5590 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
5591
e2d8ae16
TT
55922017-09-27 Tom Tromey <tom@tromey.com>
5593
5594 * tui/tui-regs.c (tui_reg_command): Constify.
5595
863779b0
TT
55962017-09-27 Tom Tromey <tom@tromey.com>
5597
5598 * skip.c (skip_file_command, skip_function_command)
5599 (skip_enable_command, skip_disable_command, skip_delete_command):
5600 Constify.
5601
cdb34d4a
TT
56022017-09-27 Tom Tromey <tom@tromey.com>
5603
5604 * record-btrace.c (cmd_record_btrace_bts_start)
5605 (cmd_record_btrace_pt_start): Constify.
5606
e99c83e7
TT
56072017-09-27 Tom Tromey <tom@tromey.com>
5608
5609 * symmisc.c (maintenance_print_symbols)
5610 (maintenance_print_msymbols, maintenance_print_objfiles)
5611 (maintenance_info_symtabs, maintenance_check_symtabs)
5612 (maintenance_expand_symtabs, maintenance_info_line_tables):
5613 Constify.
5614
32faf971
TT
56152017-09-27 Tom Tromey <tom@tromey.com>
5616
5617 * top.c (new_ui_command): Constify.
5618
2cf311eb
TT
56192017-09-27 Tom Tromey <tom@tromey.com>
5620
5621 * symfile.c (add_symbol_file_command)
5622 (remove_symbol_file_command, list_overlays_command)
5623 (map_overlay_command, unmap_overlay_command)
5624 (overlay_auto_command, overlay_manual_command)
5625 (overlay_off_command, overlay_load_command): Constify.
5626
e6738699
TT
56272017-09-27 Tom Tromey <tom@tromey.com>
5628
5629 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
5630 (info_spu_mailbox_command, info_spu_dma_command)
5631 (info_spu_proxydma_command): Constify.
5632
aa360cd5
TT
56332017-09-27 Tom Tromey <tom@tromey.com>
5634
5635 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
5636
898241a5
TT
56372017-09-27 Tom Tromey <tom@tromey.com>
5638
5639 * cli/cli-script.c (user_defined_command): Constify.
5640
2d0ac106
TT
56412017-09-27 Tom Tromey <tom@tromey.com>
5642
5643 * cli/cli-dump.c (dump_memory_command, dump_value_command)
5644 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
5645 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
5646 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
5647 (dump_binary_value, append_binary_memory, append_binary_value):
5648 Constify.
5649 (struct dump_context) <func>: Constify.
5650 (add_dump_command): Update.
5651
dede02ce
TT
56522017-09-27 Tom Tromey <tom@tromey.com>
5653
5654 * cli/cli-cmds.c (show_version, show_configuration)
5655 (source_command, show_user): Constify.
5656
d3cb6b99
TT
56572017-09-27 Tom Tromey <tom@tromey.com>
5658
5659 * target.c (maintenance_print_target_stack): Constify.
5660
1970a12f
TT
56612017-09-27 Tom Tromey <tom@tromey.com>
5662
5663 * interps.c (interpreter_exec_cmd): Constify.
5664
41243651
TT
56652017-09-27 Tom Tromey <tom@tromey.com>
5666
5667 * record-full.c (cmd_record_full_restore): Constify.
5668
4465d9db
TT
56692017-09-27 Tom Tromey <tom@tromey.com>
5670
5671 * memattr.c (enable_mem_command, disable_mem_command)
5672 (delete_mem_command): Constify.
5673
ad25e423
TT
56742017-09-27 Tom Tromey <tom@tromey.com>
5675
5676 * value.c (show_convenience): Constify.
5677
d64097b1
TT
56782017-09-27 Tom Tromey <tom@tromey.com>
5679
5680 * gdbcore.h (core_file_command): Update.
5681 * corefile.c (core_file_command): Constify.
5682
4d4589ef
TT
56832017-09-27 Tom Tromey <tom@tromey.com>
5684
5685 * user-regs.c (maintenance_print_user_registers): Constify.
5686
32a7bf17
TT
56872017-09-27 Tom Tromey <tom@tromey.com>
5688
5689 * cp-namespace.c (maintenance_cplus_namespace): Constify.
5690
4a475551
TT
56912017-09-27 Tom Tromey <tom@tromey.com>
5692
5693 * cp-support.c (first_component_command): Constify.
5694
990b9f9f
TT
56952017-09-27 Tom Tromey <tom@tromey.com>
5696
5697 * psymtab.c (maintenance_print_psymbols)
5698 (maintenance_info_psymtabs, maintenance_check_psymtabs):
5699 Constify.
5700
c281872e
TT
57012017-09-27 Tom Tromey <tom@tromey.com>
5702
5703 * windows-tdep.c (display_tib): Constify.
5704
5b64bf74
TT
57052017-09-27 Tom Tromey <tom@tromey.com>
5706
5707 * linux-fork.c (delete_checkpoint_command)
5708 (detach_checkpoint_command): Constify.
5709
4ada038f
TT
57102017-09-27 Tom Tromey <tom@tromey.com>
5711
5712 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
5713
57f5a81b
TT
57142017-09-27 Tom Tromey <tom@tromey.com>
5715
5716 * arc-tdep.c (dump_arc_instruction_command): Constify.
5717
b0a8e6c4
TT
57182017-09-27 Tom Tromey <tom@tromey.com>
5719
5720 * valprint.c (set_radix, show_radix): Constify.
5721
8d97dc1c
TT
57222017-09-27 Tom Tromey <tom@tromey.com>
5723
5724 * dtrace-probe.c (info_probes_dtrace_command): Constify.
5725
eb7c454d
TT
57262017-09-27 Tom Tromey <tom@tromey.com>
5727
5728 * command.h (not_just_help_class_command): Update.
5729 * cli/cli-decode.h (not_just_help_class_command): Update.
5730 * cli/cli-decode.c (not_just_help_class_command): Constify.
5731
e4e33335
TT
57322017-09-27 Tom Tromey <tom@tromey.com>
5733
5734 * gdb_bfd.c (maintenance_info_bfds): Constify.
5735
0450cc4c
TT
57362017-09-27 Tom Tromey <tom@tromey.com>
5737
5738 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
5739 overloads.
5740 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
5741 (do_const_cfunc): New function.
5742 (cmd_cfunc_eq): New overload.
5743 (cli_user_command_p): Check do_const_cfunc.
5744 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
5745 const_cfunc.
5746 * command.h (add_cmd): Add const overload and no-function
5747 overload.
5748 (set_cmd_cfunc): Add const overload.
5749 (cmd_const_cfunc_ftype): Declare.
5750 (cmd_cfunc_eq): Add const overload.
5751 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
5752 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
5753 overload.
5754
a9bbfbd8
TT
57552017-09-27 Tom Tromey <tom@tromey.com>
5756
5757 * macroexp.c (get_next_token_for_substitution): New function.
5758 (substitute_args): Call it. Check for __VA_OPT__.
5759
5230b05a
WT
57602017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
5761 Pedro Alves <palves@redhat.com>
5762
5763 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
5764 producer_is_icc_lt_14.
5765 (producer_is_icc_lt_14): New function.
5766 (check_producer): Add code for checking version of ICC.
5767 (producer_is_icc): Move to producer.c.
5768 (read_structure_type): Restrict ICC workaround to ICC<14.
5769 * producer.c: Include selftest.h.
5770 (producer_is_icc, producer_parsing_tests, _initialize_producer):
5771 New functions.
5772 * producer.h (producer_is_icc): New declaration.
5773
b32b108a
WT
57742017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
5775
5776 * Makefile.in (SFILES): Add producer.c.
5777 (COMMON_OBS): Add producer.o
5778 * amd64-tdep.c (producer.h): Add new include.
5779 * dwarf2read.c (producer.h): Add new include.
5780 * producer.c: New file.
5781 * producer.h: New file.
5782 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
5783 producer.c.
5784 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
5785 producer.h.
5786
5007d765
MK
57872017-09-26 Matthias Klose <doko@ubuntu.com>
5788
5789 * configure.ac: Search ncursesw before ncurses.
5790 Check ncursesw/ncurses.h before ncurses/ncurses.h.
5791 * gdb_curses.h: Include <ncursesw/ncurses.h>
5792 * config.in, configure: Regenerate.
5793
281c4447
RO
57942017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5795
5796 PR gdb/22185
5797 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
5798 obsolete.
5799 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
5800 Remove i386sol2 support.
5801 * configure.nat <i386sol2>: Remove.
5802 <sol2-64>: Fold into ...
5803 <sol2>: ... this.
5804 Move common settings to default section.
5805 Add sol-thread.o.
5806 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
5807 x86_64-*-solaris2.1[0-9]*>: Rename to ...
5808 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
5809 <i[34567]86-*-solaris*>: Remove.
5810 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
5811
5812 * configure.ac: Remove wctype in libw check.
5813 (_MSE_INT_H): Don't define on Solaris 7-9.
5814 <solaris*>: Remove libthread_db.so.1 check.
5815 * configure: Regenerate.
5816 * config.in: Regenerate.
5817
5818 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
5819 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
5820 (gdb_ps_size_t): Remove.
5821 Use base types in users.
5822 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
5823
5824 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
5825
39b06c20
RO
58262017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5827
5828 PR build/22206
5829 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
5830 (adi_is_addr_mapped): Likewise.
5831 (PSR_ICC): Don't redefine.
5832 (PSR_IMPL): Likewise.
5833
6c3e20f1
TT
58342017-09-25 Tom Tromey <tom@tromey.com>
5835
5836 * regcache.c (regcache::dump): Use string_printf.
5837
b292235f
TT
58382017-09-25 Tom Tromey <tom@tromey.com>
5839
5840 * regcache.c (class regcache_invalidator): New.
5841 (struct register_to_invalidate): Remove.
5842 (make_cleanup_regcache_invalidate): Remove.
5843 (regcache::raw_write): Use regcache_invalidator.
5844
9ac86b52
TT
58452017-09-25 Tom Tromey <tom@tromey.com>
5846
5847 * spu-tdep.c (spu2ppu_sniffer): Update.
5848 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
5849 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
5850 Remove.
5851 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
5852 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
5853 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
5854 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
5855 (frame_pop): Update.
5856
c0e383c6
TT
58572017-09-25 Tom Tromey <tom@tromey.com>
5858
5859 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
5860 * regcache.h (regcache_xfree): Don't declare.
5861 * regcache.c (regcache_xfree): Remove.
5862 (do_regcache_xfree): Use delete.
5863 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
5864 * linux-fork.c (free_fork): Use delete.
5865 (fork_save_infrun_state): Likewise.
5866 * jit.c (jit_dealloc_cache): Use delete.
5867 * infrun.c (discard_infcall_suspend_state): Use delete.
5868
791199cc
TT
58692017-09-25 Tom Tromey <tom@tromey.com>
5870
5871 * regcache.h (regcache_xmalloc): Don't declare.
5872 (regcache_raw_set_cached_value): Update comment.
5873 * regcache.c (regcache_xmalloc): Remove.
5874 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
5875 * jit.c (jit_frame_sniffer): Use new.
5876 * frame.c (frame_save_as_regcache): Use new.
5877
289e23aa
AA
58782017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5879
5880 * NEWS: Advertise support for guarded-storage registers on IBM z.
5881
1b63490c
AA
58822017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5883
5884 * s390-linux-nat.c (have_regset_gs): New static variable.
5885 (s390_linux_fetch_inferior_registers): Handle guarded-storage
5886 control block and guarded-storage broadcast control regsets.
5887 (s390_read_description): Detect whether the target has
5888 guarded-storage support, return appropriate tdesc.
5889 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
5890 (features/s390x-gs-linux64.c): Likewise.
5891 (struct gdbarch_tdep) <have_gs>: New field.
5892 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
5893 (s390_gsbc_regset): New variables.
5894 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
5895 and s390_gsbc_regset, if applicable.
5896 (s390_core_read_description): Check whether core file was from a
5897 target with guarded-storage support; include appropriate regsets.
5898 (s390_gdbarch_init): Add registers for guarded-storage support.
5899 (_initialize_s390_tdep): Initialize new target descriptions that
5900 include registers for guarded-storage support.
5901 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
5902 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
5903 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
5904 (S390_NUM_REGS): Adjust macro definition.
5905 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
5906 (tdesc_s390x_gs_linux64): New declarations.
5907
96235dc1
AA
59082017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5909
5910 * features/s390-gs-linux64.xml: New file.
5911 * features/s390-gs.xml: New file.
5912 * features/s390-gsbc.xml: New file.
5913 * features/s390x-gs-linux64.xml: New file.
5914 * features/Makefile (WHICH): Add s390-gs-linux64 and
5915 s390x-gs-linux64.
5916 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
5917 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
5918 * features/s390-gs-linux64.c: New generated file.
5919 * features/s390x-gs-linux64.c: New file.
5920 * regformats/s390-gs-linux64.dat: New file.
5921 * regformats/s390x-gs-linux64.dat: New file.
5922
b4a7c699
TT
59232017-09-23 Tom Tromey <tom@tromey.com>
5924
5925 * defs.h (make_cleanup_override_quit_handler): Don't declare.
5926
c2f97536
TT
59272017-09-22 Tom Tromey <tom@tromey.com>
5928
5929 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
5930 type to scoped_restore_tmpl.
5931 <scoped_input_handler>: Initialize m_quit_handler directly.
5932
43573013
SDJ
59332017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
5934
5935 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
5936 (cd_command): Likewise. Free "current_directory" before
5937 assigning to it.
5938 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
5939 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
5940 * top.c (gdb_dirbuf): Remove global declaration.
5941 * top.h (gdb_dirbuf): Likewise.
5942
6ec2e0f5
SDJ
59432017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
5944
5945 * gnulib/aclocal.m4: Regenerate.
5946 * gnulib/config.in: Regenerate.
5947 * gnulib/configure: Regenerate.
5948 * gnulib/import/Makefile.am: Regenerate.
5949 * gnulib/import/Makefile.in: Regenerate.
5950 * gnulib/import/assure.h: New file.
5951 * gnulib/import/at-func.c: Likewise
5952 * gnulib/import/chdir-long.c: New file.
5953 * gnulib/import/chdir-long.h: New file.
5954 * gnulib/import/cloexec.c: New file.
5955 * gnulib/import/cloexec.h: New file.
5956 * gnulib/import/close.c: New file.
5957 * gnulib/import/closedir.c: New file.
5958 * gnulib/import/dirent-private.h: New file.
5959 * gnulib/import/dup-safer.c: New file.
5960 * gnulib/import/dup.c: New file.
5961 * gnulib/import/dup2.c: New file.
5962 * gnulib/import/error.c: New file.
5963 * gnulib/import/error.h: New file.
5964 * gnulib/import/exitfail.c: New file.
5965 * gnulib/import/exitfail.h: New file.
5966 * gnulib/import/fchdir.c: New file.
5967 * gnulib/import/fcntl.c: New file.
5968 * gnulib/import/fcntl.in.h: New file.
5969 * gnulib/import/fd-hook.c: New file.
5970 * gnulib/import/fd-hook.h: New file.
5971 * gnulib/import/fd-safer.c: New file.
5972 * gnulib/import/fdopendir.c: New file.
5973 * gnulib/import/filename.h: New file.
5974 * gnulib/import/filenamecat-lgpl.c: New file.
5975 * gnulib/import/filenamecat.h: New file.
5976 * gnulib/import/fstat.c: New file.
5977 * gnulib/import/fstatat.c: New file.
5978 * gnulib/import/getcwd-lgpl.c: New file.
5979 * gnulib/import/getcwd.c: New file.
5980 * gnulib/import/getdtablesize.c: New file.
5981 * gnulib/import/getlogin_r.c: New file.
5982 * gnulib/import/getprogname.c: New file.
5983 * gnulib/import/getprogname.h: New file.
5984 * gnulib/import/gettext.h: New file.
5985 * gnulib/import/glob-libc.h: New file.
5986 * gnulib/import/glob.c: New file.
5987 * gnulib/import/glob.in.h: New file.
5988 * gnulib/import/intprops.h: New file.
5989 * gnulib/import/m4/chdir-long.m4: New file.
5990 * gnulib/import/m4/close.m4: New file.
5991 * gnulib/import/m4/closedir.m4: New file.
5992 * gnulib/import/m4/d-ino.m4: New file.
5993 * gnulib/import/m4/d-type.m4: New file.
5994 * gnulib/import/m4/dup.m4: New file.
5995 * gnulib/import/m4/dup2.m4: New file.
5996 * gnulib/import/m4/error.m4: New file.
5997 * gnulib/import/m4/fchdir.m4: New file.
5998 * gnulib/import/m4/fcntl.m4: New file.
5999 * gnulib/import/m4/fcntl_h.m4: New file.
6000 * gnulib/import/m4/fdopendir.m4: New file.
6001 * gnulib/import/m4/filenamecat.m4: New file.
6002 * gnulib/import/m4/fstat.m4: New file.
6003 * gnulib/import/m4/fstatat.m4: New file.
6004 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
6005 * gnulib/import/m4/getcwd-path-max.m4: New file.
6006 * gnulib/import/m4/getcwd.m4: New file.
6007 * gnulib/import/m4/getdtablesize.m4: New file.
6008 * gnulib/import/m4/getlogin_r.m4: New file.
6009 * gnulib/import/m4/getprogname.m4: New file.
6010 * gnulib/import/m4/glob.m4: New file.
6011 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
6012 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
6013 * gnulib/import/m4/mempcpy.m4: New file.
6014 * gnulib/import/m4/memrchr.m4: New file.
6015 * gnulib/import/m4/mode_t.m4: New file.
6016 * gnulib/import/m4/msvc-inval.m4: New file.
6017 * gnulib/import/m4/msvc-nothrow.m4: New file.
6018 * gnulib/import/m4/open.m4: New file.
6019 * gnulib/import/m4/openat.m4: New file.
6020 * gnulib/import/m4/opendir.m4: New file.
6021 * gnulib/import/m4/readdir.m4: New file.
6022 * gnulib/import/m4/realloc.m4: New file.
6023 * gnulib/import/m4/rewinddir.m4: New file.
6024 * gnulib/import/m4/save-cwd.m4: New file.
6025 * gnulib/import/m4/strdup.m4: New file.
6026 * gnulib/import/m4/strerror.m4: New file.
6027 * gnulib/import/m4/unistd-safer.m4: New file.
6028 * gnulib/import/mempcpy.c: New file.
6029 * gnulib/import/memrchr.c: New file.
6030 * gnulib/import/msvc-inval.c: New file.
6031 * gnulib/import/msvc-inval.h: New file.
6032 * gnulib/import/msvc-nothrow.c: New file.
6033 * gnulib/import/msvc-nothrow.h: New file.
6034 * gnulib/import/open.c: New file.
6035 * gnulib/import/openat-die.c: New file.
6036 * gnulib/import/openat-priv.h: New file.
6037 * gnulib/import/openat-proc.c: New file.
6038 * gnulib/import/openat.c: New file.
6039 * gnulib/import/openat.h: New file.
6040 * gnulib/import/opendir.c: New file.
6041 * gnulib/import/pipe-safer.c: New file.
6042 * gnulib/import/readdir.c: New file.
6043 * gnulib/import/realloc.c: New file.
6044 * gnulib/import/rewinddir.c: New file.
6045 * gnulib/import/save-cwd.c: New file.
6046 * gnulib/import/save-cwd.h: New file.
6047 * gnulib/import/strdup.c: New file.
6048 * gnulib/import/strerror-override.c: New file.
6049 * gnulib/import/strerror-override.h: New file.
6050 * gnulib/import/strerror.c: New file.
6051 * gnulib/import/unistd--.h: New file.
6052 * gnulib/import/unistd-safer.h: New file.
6053 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
6054 "getcwd" and "glob".
6055 * ser-tcp.c: Undefine "close" before redefining it.
6056
432ae719
SM
60572017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6058
6059 * guile/scm-value.c (gdbscm_value_address): Initialize address,
6060 get rid of res_val.
6061
4fa7574e
RO
60622017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6063
6064 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
6065 <sol2,sparc>: Likewise.
6066 <sol2-64,i386>: Likewise.
6067
6068 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
6069 -Wdeprecated-declarations on *-*-solaris*.
6070 * configure: Regenerate.
6071
6072 * procfs.c: Include "nat/inferior.h".
6073 (procfs_info_proc): Fix typo.
6074
f6327dcb
KB
60752017-09-21 Kevin Buettner <kevinb@redhat.com>
6076
6077 * remote.c (vector): Include.
6078 (struct private_thread_info): Add field, thread_handle.
6079 (free_private_thread_info): Deallocate storage associated with
6080 thread handle.
6081 (get_private_info_thread): Initialize `thread_handle' field.
6082 (struct thread_item): Add field, thread_handle.
6083 (clear_threads_listing_context): Deallocate storage associated
6084 with thread handle.
6085 (start_thread): Add support for "handle" attribute.
6086 (thread_attributes): Add "handle".
6087 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
6088 field.
6089 (remote_update_thread_list): Update thread_handle.
6090 (remote_thread_handle_to_thread_info): New function.
6091 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
6092
fbbe5337
KB
60932017-09-21 Kevin Buettner <kevinb@redhat.com>
6094
6095 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
6096 function.
6097 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
6098 * python/python-internal.h (thread_object_type): Declare.
6099
e04ee09e
KB
61002017-09-21 Kevin Buettner <kevinb@redhat.com>
6101
6102 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
6103 (target_thread_handle_to_thread_info): Declare.
6104 * target.c (target_thread_handle_to_thread_info): New function.
6105 * target-delegates.c: Regenerate.
6106 * gdbthread.h (find_thread_by_handle): Declare.
6107 * thread.c (find_thread_by_handle): New function.
6108 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
6109 function.
6110 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
6111
1e5b66ed
SM
61122017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6113
6114 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
6115
ebe48ba0
SM
61162017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6117
6118 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
6119
0a0bf5dc
YQ
61202017-09-21 Yao Qi <yao.qi@linaro.org>
6121
6122 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
6123 to gdb_target_obs.
6124
d1b0a7bf
TT
61252017-09-20 Tom Tromey <tom@tromey.com>
6126
6127 * breakpoint.c (struct counted_command_line): Remove.
6128 (breakpoint_commands): Update.
6129 (alloc_counted_command_line, incref_counted_command_line)
6130 (decref_counted_command_line, do_cleanup_counted_command_line)
6131 (make_cleanup_decref_counted_command_line): Remove.
6132 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
6133 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
6134 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
6135 (save_breakpoints): Update.
6136 * breakpoint.h (counted_command_line): Now a typedef to
6137 shared_ptr.
6138 (struct breakpoint) <commands>: Now a counted_command_line.
6139 (struct bpstats) <command>: Likewise.
6140
48649e1b
TT
61412017-09-20 Tom Tromey <tom@tromey.com>
6142
6143 * breakpoint.c (struct commands_info, do_map_commands_command):
6144 Remove.
6145 (commands_command_1): Update.
6146 (iterate_over_related_breakpoints): Take a function_view.
6147 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
6148 (delete_command): Update.
6149 (map_breakpoint_numbers): Take a function_view.
6150 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
6151 (disable_command): Update.
6152 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
6153 (enable_command): Update.
6154 (struct disp_data, do_enable_breakpoint_disp)
6155 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
6156 (do_map_enable_delete_breakpoint): Remove.
6157 (enable_once_command, enable_count_command, enable_delete_command)
6158 (delete_trace_variable_command): Update.
6159
04afa70c
TT
61602017-09-20 Tom Tromey <tom@tromey.com>
6161
6162 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
6163 (bpstat_clear): Use delete.
6164 (bpstats): New constructors.
6165 (bpstat_copy, bpstat_stop_status): Use new.
6166 (dprintf_after_condition_true): Update.
6167 * breakpoint.h (bpstats::bpstats): Add constructors.
6168 (bpstats::~bpstats): Add destructor.
6169
c83833f4
PA
61702017-09-20 Pedro Alves <palves@redhat.com>
6171
6172 * eval.c (make_params): Delete, refactored as ...
6173 (class fake_method): ... this new type's ctor.
6174 (fake_method::~fake_method): New.
6175 (evaluate_subexp_standard): Use 'fake_method'.
6176
223ffa71
TT
61772017-09-20 Tom Tromey <tom@tromey.com>
6178
6179 * windows-nat.c (get_windows_debug_event, windows_wait)
6180 (do_initial_windows_stuff, windows_attach): Update.
6181 * utils.c (vwarning, internal_vproblem): Update.
6182 (ui_unregister_input_event_handler_cleanup)
6183 (prepare_to_handle_input): Remove.
6184 (class scoped_input_handler): New.
6185 (defaulted_query, prompt_for_continue): Update.
6186 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
6187 Update.
6188 * top.c (undo_terminal_modifications_before_exit): Update.
6189 * target/target.h (target_terminal_init, target_terminal_inferior)
6190 (target_terminal_ours): Don't declare.
6191 (class target_terminal): New.
6192 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
6193 (target_terminal_ours_for_output)
6194 (make_cleanup_restore_target_terminal): Don't declare.
6195 (target_terminal_info): Remove.
6196 * target.c (enum terminal_state, terminal_state): Remove.
6197 (target_terminal::terminal_state): Define.
6198 (target_terminal::init): Rename from target_terminal_init.
6199 (target_terminal::inferior): Rename from
6200 target_terminal_inferior.
6201 (target_terminal::ours): Rename from target_terminal_ours.
6202 (target_terminal::ours_for_output): Rename from
6203 target_terminal_ours_for_output.
6204 (target_terminal::info): New method.
6205 (cleanup_restore_target_terminal)
6206 (make_cleanup_restore_target_terminal): Remove.
6207 * solib.c (handle_solib_event): Update.
6208 * remote.c (remote_serial_quit_handler): Update.
6209 (remote_terminal_inferior, remote_wait_as): Update.
6210 * record-full.c (record_full_wait_1): Update.
6211 * nto-procfs.c (procfs_create_inferior): Update.
6212 * nat/fork-inferior.c (startup_inferior): Update.
6213 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
6214 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
6215 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
6216 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
6217 (mi_breakpoint_created, mi_breakpoint_deleted)
6218 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
6219 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6220 (mi_user_selected_context_changed, report_initial_inferior):
6221 Update.
6222 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
6223 (linux_nat_terminal_inferior): Update.
6224 * infrun.c (follow_fork_inferior)
6225 (handle_vfork_child_exec_or_exit, do_target_resume)
6226 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
6227 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
6228 Update.
6229 * inflow.c (child_terminal_init, info_terminal_command): Update.
6230 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
6231 (attach_command): Update.
6232 * infcall.c (call_thread_fsm_should_stop): Update.
6233 * gnu-nat.c (gnu_attach): Update.
6234 * extension.c (struct active_ext_lang_state)
6235 (restore_active_ext_lang): Update.
6236 * exceptions.c (print_flush): Update.
6237 * event-top.c (async_enable_stdin, default_quit_handler): Update.
6238 (struct quit_handler_cleanup_data, restore_quit_handler)
6239 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
6240 Remove.
6241 * cp-support.c (gdb_demangle): Update.
6242 * breakpoint.c (update_inserted_breakpoint_locations)
6243 (insert_breakpoint_locations, handle_jit_event)
6244 (disable_breakpoints_in_unloaded_shlib): Update.
6245 * annotate.c (annotate_breakpoints_invalid)
6246 (annotate_frames_invalid): Update.
6247
013af3fc
TT
62482017-09-20 Tom Tromey <tom@tromey.com>
6249
6250 * main.c (catch_command_errors): Rename from
6251 catch_command_errors_const.
6252 (captured_main_1): Update.
6253
06871ae8
PA
62542017-09-20 Pedro Alves <palves@redhat.com>
6255
6256 * cli/cli-cmds.c (list_command): Use print_sal_location.
6257 (print_sal_location): New function.
6258 (ambiguous_line_spec): Use print_sal_location.
6259 * linespec.c (symbol_to_sal): Record the symbol in the sal.
6260 * symtab.c (find_function_start_sal): Likewise.
6261 * symtab.h (symtab_and_line::symbol): New field.
6262
e5f25bc5
PA
62632017-09-20 Pedro Alves <palves@redhat.com>
6264
6265 * linespec.c (minsym_found): Handle non-text minsyms.
6266 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
6267
1b7fa39e
WT
62682017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6269
6270 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
6271 backslash.
6272
37dd0825
WT
62732017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6274
6275 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
6276 vmovups instead vmovaps.
6277 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
6278
4e5a4f58
JB
62792017-09-19 John Baldwin <jhb@FreeBSD.org>
6280
6281 * NEWS (Changes since GDB 8.0): Add starti.
6282 * infcmd.c (enum run_break): New.
6283 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
6284 case.
6285 (run_command): Use enum run_how.
6286 (start_command): Likewise.
6287 (starti_command): New function.
6288 (RUN_ARGS_HELP): New macro.
6289 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
6290 commands. Add starti command.
6291
aa70c9f1
YQ
62922017-09-19 Yao Qi <yao.qi@linaro.org>
6293
6294 * Makefile.in (monitor.o): Remove the rule.
6295
d6541620
YQ
62962017-09-19 Yao Qi <yao.qi@linaro.org>
6297
6298 * annotate.h (struct annotate_arg_emitter): Use
6299 DISABLE_COPY_AND_ASSIGN.
6300 * common/refcounted-object.h (refcounted_object): Likewise.
6301 * completer.h (struct completion_result): Likewise.
6302 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
6303 * filename-seen-cache.h (filename_seen_cache): Likewise.
6304 * gdbcore.h (thread_section_name): Likewise.
6305 * gdb_regex.h (compiled_regex): Likewise.
6306 * gdbthread.h (scoped_restore_current_thread): Likewise.
6307 * inferior.h (scoped_restore_current_inferior): Likewise.
6308 * jit.c (jit_reader): Likewise.
6309 * linespec.h (struct linespec_result): Likewise.
6310 * mi/mi-parse.h (struct mi_parse): Likewise.
6311 * nat/fork-inferior.c (execv_argv): Likewise.
6312 * progspace.h (scoped_restore_current_program_space): Likewise.
6313 * python/python-internal.h (class gdbpy_enter): Likewise.
6314 * regcache.h (regcache): Likewise.
6315 * target-descriptions.c (struct tdesc_reg): Likewise.
6316 (struct tdesc_type): Likewise.
6317 (struct tdesc_feature): Likewise.
6318 * ui-out.h (ui_out_emit_type): Likewise.
6319
0615127c
SM
63202017-09-18 Simon Marchi <simon.marchi@ericsson.com>
6321
6322 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
6323 label abort_expression.
6324
5e187554
SM
63252017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6326
6327 * common/buffer.c (buffer_xml_printf): Adjust.
6328 * common/xml-utils.c (xml_escape_text): Change return type to
6329 std::string, update code accordingly.
6330 * common/xml-utils.h (xml_escape_text): Change return type to
6331 std::string.
6332 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
6333 * windows-tdep.c (windows_xfer_shared_library): Adjust.
6334 * unittests/xml-utils-selftests.c (test_xml_escape_text):
6335 Adjust.
6336
c3d7b541
SM
63372017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6338
6339 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
6340 (SUBDIR_UNITTESTS_OBS): Add new object file.
6341 * unittests/xml-utils-selftests.c: New file.
6342
1526853e
SM
63432017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6344
6345 * common/selftest.h (selftest): New struct/interface.
6346 (register_test): Add name parameter, add new overload.
6347 (run_tests): Add filter parameter.
6348 (for_each_selftest_ftype): New typedef.
6349 (for_each_selftest): New declaration.
6350 * common/selftest.c (tests): Change type to
6351 map<string, unique_ptr<selftest>>.
6352 (simple_selftest): New struct.
6353 (register_test): New function.
6354 (register_test): Add name parameter and use it.
6355 (run_tests): Add filter parameter and use it. Add prints.
6356 Adjust to vector -> map change.
6357 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
6358 registering selftests.
6359 * arm-tdep.c (_initialize_arm_tdep): Likewise.
6360 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
6361 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
6362 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
6363 * findvar.c (_initialize_findvar): Likewise.
6364 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
6365 * maint.c (maintenance_selftest): Update call to run_tests.
6366 (maintenance_info_selftests): New function.
6367 (_initialize_maint_cmds): Register "maintenance info selftests"
6368 command. Update "maintenance selftest" doc.
6369 * regcache.c (_initialize_regcache): Add names when registering
6370 selftests.
6371 * rust-exp.y (_initialize_rust_exp): Likewise.
6372 * selftest-arch.c (gdbarch_selftest): New struct.
6373 (gdbarch_tests): Remove.
6374 (register_test_foreach_arch): Add name parameter. Call
6375 register_test.
6376 (tests_with_arch): Remove, move most content to
6377 gdbarch_selftest::operator().
6378 (_initialize_selftests_foreach_arch): Remove.
6379 * selftest-arch.h (register_test_foreach_arch): Add name
6380 parameter.
6381 (run_tests_with_arch): New declaration.
6382 * utils-selftests.c (_initialize_utils_selftests): Add names
6383 when registering selftests.
6384 * utils.c (_initialize_utils): Likewise.
6385 * unittests/array-view-selftests.c
6386 (_initialize_array_view_selftests): Likewise.
6387 * unittests/environ-selftests.c (_initialize_environ_selftests):
6388 Likewise.
6389 * unittests/function-view-selftests.c
6390 (_initialize_function_view_selftests): Likewise.
6391 * unittests/offset-type-selftests.c
6392 (_initialize_offset_type_selftests): Likewise.
6393 * unittests/optional-selftests.c
6394 (_initialize_optional_selftests): Likewise.
6395 * unittests/scoped_restore-selftests.c
6396 (_initialize_scoped_restore_selftests): Likewise.
6397 * NEWS: Document "maintenance selftest" and "maint info
6398 selftests".
6399
5846367a
SM
64002017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6401
6402 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
6403 scoped_restore.
6404
bd77e8ff
SM
64052017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6406
6407 * mi/mi-main.c (mi_load_progress): Make uiout variable
6408 a unique_ptr.
6409
26a67918
PA
64102017-09-15 Pedro Alves <palves@redhat.com>
6411
6412 * compile/compile-c-types.c (convert_enum, convert_int)
6413 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
6414
3f8a7804
SM
64152017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6416
6417 * dwarf2read.c (copy_string): Remove.
6418 (parse_macro_definition): Replace copy_string with savestring.
6419
8d200706
YQ
64202017-09-15 Yao Qi <yao.qi@linaro.org>
6421
6422 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
6423 gdb_target_obs.
6424 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
6425 Likewise.
6426 (i[34567]86-*-linux*): Likewise.
6427
d185219d
SM
64282017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6429
6430 * dwarf2expr.h (dwarf_stack_value): Add constructor.
6431 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
6432 <stack>: Change type to std::vector.
6433 <stack_len, stack_allocated>: Remove.
6434 <grow_stack>: Remove.
6435 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
6436 (dwarf_expr_context::~dwarf_expr_context): Remove.
6437 (dwarf_expr_context::grow_stack): Remove.
6438 (dwarf_expr_context::push): Adjust.
6439 (dwarf_expr_context::pop): Adjust.
6440 (dwarf_expr_context::fetch): Adjust.
6441 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
6442 (dwarf_expr_context::stack_empty_p): Adjust.
6443 (dwarf_expr_context::execute_stack_op): Adjust.
6444
eccd80d6
SM
64452017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6446
6447 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
6448 return type to bool.
6449 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
6450
69009882
SM
64512017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6452
6453 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
6454 Change type to bool.
6455 (dwarf_stack_value) <in_stack_memory>: Likewise.
6456 (dwarf_expr_context) <push_address>: Change parameter type to
6457 bool.
6458 <fetch_in_stack_memory>: Change return type to bool.
6459 <push>: Change parameter type to bool.
6460 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
6461 to bool.
6462 (dwarf_expr_context::push_address): Likewise.
6463 (dwarf_expr_context::fetch_in_stack_memory): Change return type
6464 to bool.
6465 (dwarf_expr_context::execute_stack_op): Adjust.
6466 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
6467
1e467161
SM
64682017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6469
6470 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
6471 (struct dwarf_expr_context) <n_pieces>: Remove.
6472 <pieces>: Change type to std::vector.
6473 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
6474 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
6475 pieces.
6476 (dwarf_expr_context::add_piece): Adjust.
6477 * dwarf2loc.c (struct piece_closure): Initialize fields.
6478 <n_pieces>: Remove.
6479 <pieces>: Change type to std::vector.
6480 (allocate_piece_closure): Adjust, change parameter to
6481 std::vector rvalue and std::move it to piece_closure.
6482 (rw_pieced_value): Adjust.
6483 (check_pieced_synthetic_pointer): Adjust.
6484 (indirect_synthetic_pointer): Adjust.
6485 (coerce_pieced_ref): Adjust.
6486 (free_pieced_value_closure): Adjust. Use delete to free
6487 piece_closure.
6488 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
6489 to allocate_piece_closure.
6490 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
6491
0782db84
SM
64922017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6493
6494 * probe.h (probe_ops_cp): Remove typedef.
6495 (DEF_VEC_P (probe_ops_cp)): Remove.
6496 (all_probe_ops): Change type to std::vector.
6497 * probe.c (info_probes_for_ops): Adjust to vector change.
6498 (probe_linespec_to_ops): Likewise.
6499 (all_probe_ops): Change type to std::vector.
6500 (_initialize_probe): Adjust to vector change.
6501 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
6502 * elfread.c (elf_get_probes): Likewise.
6503 * stap-probe.c (_initialize_stap_probe): Likewise.
6504
1eac6bea
SM
65052017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6506
6507 * probe.h (struct bound_probe): Define constructors.
6508 * probe.c (bound_probe_s): Remove typedef.
6509 (DEF_VEC_O (bound_probe_s)): Remove VEC.
6510 (collect_probes): Change return type to std::vector, remove
6511 cleanup.
6512 (compare_probes): Return bool, change parameter type. Change
6513 semantic to "less than".
6514 (gen_ui_out_table_header_info): Change parameter to std::vector
6515 and update.
6516 (exists_probe_with_pops): Likewise.
6517 (info_probes_for_ops): Update to std::vector change.
6518 (enable_probes_command): Likewise.
6519 (disable_probes_command): Likewise.
6520
aaa63a31
SM
65212017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6522
6523 * probe.h (struct probe_ops) <get_probes>: Change parameter from
6524 vec to std::vector.
6525 * probe.c (parse_probes_in_pspace): Update.
6526 (find_probes_in_objfile): Update.
6527 (find_probe_by_pc): Update.
6528 (collect_probes): Update.
6529 (probe_any_get_probes): Update.
6530 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
6531 return type to reference to std::vector.
6532 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
6533 std::vector and update.
6534 (dtrace_process_dof): Likewise.
6535 (dtrace_get_probes): Likewise.
6536 * elfread.c (elf_get_probes): Change return type to std::vector,
6537 store an std::vector in bfd_data.
6538 (probe_key_free): Update to std::vector.
6539 * stap-probe.c (handle_stap_probe): Change parameter to
6540 std::vector and update.
6541 (stap_get_probes): Likewise.
6542 * symfile-debug.c (debug_sym_get_probes): Change return type to
6543 std::vector and update.
6544
cb85b21b
TT
65452017-09-11 Tom Tromey <tom@tromey.com>
6546
6547 * breakpoint.c (program_breakpoint_here_p): Update.
6548 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
6549 from make_show_memory_breakpoints_cleanup. Return a
6550 scoped_restore_tmpl<int>.
6551 (restore_show_memory_breakpoints): Remove.
6552 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
6553 * mem-break.c (memory_validate_breakpoint): Update.
6554 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
6555 (ia64_memory_remove_breakpoint): Update.
6556 (ia64_breakpoint_from_pc): Update.
6557 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
6558 from make_show_memory_breakpoints_cleanup.
6559
8fbc99ef
TT
65602017-09-11 Tom Tromey <tom@tromey.com>
6561
6562 * d-namespace.c (d_lookup_symbol): Use std::string.
6563 (find_symbol_in_baseclass): Likewise.
6564
50feb4bd
TT
65652017-09-11 Tom Tromey <tom@tromey.com>
6566
6567 * ctf.c (ctf_start): Use std::string.
6568
c6dc63a1
TT
65692017-09-11 Tom Tromey <tom@tromey.com>
6570
6571 * ada-lang.c (is_known_support_routine): Update.
6572 (ada_unhandled_exception_name_addr_from_raise): Update.
6573 * guile/scm-frame.c (gdbscm_frame_name): Update.
6574 * python/py-frame.c (frapy_name): Update.
6575 (frapy_function): Update.
6576 * stack.h (find_frame_funname): Update.
6577 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
6578 (print_frame): Update.
6579
d6b9b80f
TT
65802017-09-11 Tom Tromey <tom@tromey.com>
6581
6582 * findcmd.c (put_bits): Take a gdb::byte_vector.
6583 (parse_find_args): Return gdb::byte_vector. "args" now const.
6584 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
6585 cleanups.
6586 (find_command): Update.
6587
a9921622
TT
65882017-09-11 Tom Tromey <tom@tromey.com>
6589
6590 * cli/cli-script.c (class scoped_restore_hook_in): New.
6591 (clear_hook_in_cleanup): Remove.
6592 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
6593 scoped_restore_hook_in.
6594
be0d7abb
TT
65952017-09-11 Tom Tromey <tom@tromey.com>
6596
6597 * cli/cli-script.c (restore_interp): Remove.
6598 (read_command_lines): Use scoped_restore_interp.
6599 * interps.c (scoped_restore_interp::set_temp): Rename from
6600 interp_set_temp.
6601 * interps.h (class scoped_restore_interp): New.
6602 (interp_set_temp): Remove.
6603
00f675ff
TT
66042017-09-11 Tom Tromey <tom@tromey.com>
6605
6606 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6607 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
6608 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
6609 scoped_restore.
6610 (mi_cmd_break_insert_1): Update.
6611 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
6612 scoped_restore.
6613
cb791d59
TT
66142017-09-11 Tom Tromey <tom@tromey.com>
6615
6616 * demangle.c (demangle_command): Update.
6617 * breakpoint.c (disable_command): Update.
6618 (enable_command): Update.
6619 (find_location_by_number): Make "number" const. Use
6620 get_number_trailer.
6621 * cli/cli-utils.c (extract_arg): Return std::string.
6622 * probe.c (parse_probe_linespec): Update. Change types.
6623 (collect_probes): Take string arguments.
6624 (parse_probe_linespec): Likewise.
6625 (info_probes_for_ops): Update.
6626 (enable_probes_command): Update.
6627 (disable_probes_command): Update.
6628 * break-catch-sig.c (catch_signal_split_args): Update.
6629 * mi/mi-parse.c (mi_parse): Update.
6630
2039bd9f
TT
66312017-09-11 Tom Tromey <tom@tromey.com>
6632
6633 * language.h (language_enum): Make argument const.
6634 * language.c (language_enum): Make argument const.
6635
f1735a53
TT
66362017-09-11 Tom Tromey <tom@tromey.com>
6637
6638 * common/common-utils.h (skip_to_space): Remove macro, redeclare
6639 as function.
6640 (skip_to_space): Rename from skip_to_space_const.
6641 * common/common-utils.c (skip_to_space): New function.
6642 (skip_to_space): Rename from skip_to_space_const.
6643 * cli/cli-utils.h (get_number): Rename from get_number_const.
6644 (extract_arg): Rename from extract_arg_const.
6645 * cli/cli-utils.c (get_number): Rename from get_number_const.
6646 (extract_arg): Rename from extract_arg_const.
6647 (number_or_range_parser::get_number): Use ::get_number.
6648 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
6649 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
6650 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
6651 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
6652 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
6653 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
6654 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
6655 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
6656
7d221d74
TT
66572017-09-11 Tom Tromey <tom@tromey.com>
6658
6659 * python/python.c (do_start_initialization): Use
6660 py-event-types.def to initialize types.
6661 Define all object type structures.
6662 * python/python-internal.h: Don't declare event initialization
6663 functions.
6664 * python/py-threadevent.c (thread_event_object_type): Don't
6665 define.
6666 * python/py-stopevent.c (stop_event_object_type): Don't define.
6667 * python/py-signalevent.c (signal_event_object_type): Don't
6668 declare or define.
6669 * python/py-newobjfileevent.c (new_objfile_event_object_type)
6670 (clear_objfiles_event_object_type): Don't declare or define.
6671 * python/py-infevents.c (inferior_call_pre_event_object_type)
6672 (inferior_call_post_event_object_type)
6673 (register_changed_event_object_type)
6674 (memory_changed_event_object_type): Don't declare or define.
6675 * python/py-inferior.c (new_thread_event_object_type)
6676 (new_inferior_event_object_type)
6677 (inferior_deleted_event_object_type): Don't declare or define.
6678 * python/py-exitedevent.c (exited_event_object_type): Don't
6679 declare or define.
6680 * python/py-evts.c (gdbpy_initialize_py_events): Use
6681 py-all-events.def.
6682 * python/py-events.h (thread_event_object_type): Don't declare.
6683 (events_object): Use py-all-events.def.
6684 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
6685 py-event-types.def.
6686 * python/py-event-types.def: New file.
6687 * python/py-continueevent.c (create_continue_event_object): Don't
6688 declare or define.
6689 * python/py-bpevent.c (breakpoint_event_object_type): Don't
6690 declare or define.
6691 * python/py-all-events.def: New file.
6692
35c61a1d
TT
66932017-09-11 Tom Tromey <tom@tromey.com>
6694
6695 * python/py-threadevent.c (create_thread_event_object): Return
6696 gdbpy_ref.
6697 * python/py-stopevent.h (create_stop_event_object)
6698 (create_breakpoint_event_object, create_signal_event_object):
6699 Update.
6700 * python/py-stopevent.c (create_stop_event_object): Return
6701 gdbpy_ref.
6702 (emit_stop_event): Update.
6703 * python/py-signalevent.c (create_signal_event_object): Return
6704 gdbpy_ref.
6705 * python/py-infevents.c (create_inferior_call_event_object):
6706 Update.
6707 * python/py-event.h (create_event_object)
6708 (create_thread_event_object): Update.
6709 * python/py-event.c (create_event_object): Return gdbpy_ref.
6710 * python/py-continueevent.c: Return gdbpy_ref.
6711 * python/py-bpevent.c (create_breakpoint_event_object): Return
6712 gdbpy_ref.
6713
7c96f8c1
TT
67142017-09-11 Tom Tromey <tom@tromey.com>
6715
6716 PR python/15622:
6717 * NEWS: Add entry.
6718 * python/python.c (do_start_initialization): Initialize new event
6719 types.
6720 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
6721 (gdbpy_initialize_inferior_deleted_event)
6722 (gdbpy_initialize_new_thread_event): Declare.
6723 * python/py-threadevent.c (create_thread_event_object): Add option
6724 "thread" parameter.
6725 * python/py-inferior.c (new_thread_event_object_type)
6726 (new_inferior_event_object_type)
6727 (inferior_deleted_event_object_type): Declare.
6728 (python_new_inferior, python_inferior_deleted): New functions.
6729 (add_thread_object): Emit new_thread event.
6730 (gdbpy_initialize_inferior): Attach new functions to corresponding
6731 observers.
6732 (new_thread, new_inferior, inferior_deleted): Define new event
6733 types.
6734 * python/py-evts.c (gdbpy_initialize_py_events): Add new
6735 registries.
6736 * python/py-events.h (events_object) <new_inferior,
6737 inferior_deleted, new_thread>: New fields.
6738 * python/py-event.h (create_thread_event_breakpoint): Add optional
6739 "thread" parameter.
6740
72542b8e
AB
67412017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
6742
6743 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
6744 check current_ui instead.
6745 (internal_vproblem): Likewise.
6746
0d64823e
SM
67472017-09-09 Simon Marchi <simon.marchi@ericsson.com>
6748
6749 * thread.c (print_thread_info_1): Remove unnecessary calls to
6750 uiout->is_mi_like_p.
6751
eb1e02fd
TT
67522017-09-09 Tom Tromey <tom@tromey.com>
6753
6754 * namespace.h (add_using_directive): Update.
6755 * namespace.c (add_using_directive): Change type of excludes to
6756 std::vector.
6757 * dwarf2read.c (read_import_statement): Use std::vector.
6758 (read_namespace): Update.
6759 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
6760
0fc21fd8
TT
67612017-09-09 Tom Tromey <tom@tromey.com>
6762
6763 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
6764
49663d05
TT
67652017-09-09 Tom Tromey <tom@tromey.com>
6766
6767 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
6768
0b868b60
TT
67692017-09-09 Tom Tromey <tom@tromey.com>
6770
6771 * stack.c (func_command): Use gdb::def_vector.
6772
c0470d48
TT
67732017-09-09 Tom Tromey <tom@tromey.com>
6774
6775 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
6776 ui_out_emit_list, ui_out_emit_tuple.
6777 (mi_cmd_var_update): Likewise.
6778
ca5909c7
TT
67792017-09-09 Tom Tromey <tom@tromey.com>
6780
6781 * mi/mi-interp.c (mi_user_selected_context_changed): Use
6782 ui_out_redirect_pop.
6783 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
6784 ui_out_redirect_pop.
6785 * utils.c (do_ui_out_redirect_pop)
6786 (make_cleanup_ui_out_redirect_pop): Remove.
6787 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
6788 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
6789 * ui-out.h (ui_out_redirect_pop): New class.
6790
e6a2252a
TT
67912017-09-09 Tom Tromey <tom@tromey.com>
6792
6793 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
6794 (list_available_thread_groups, mi_cmd_list_thread_groups)
6795 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
6796 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
6797 Likewise.
6798
393702cd
TT
67992017-09-09 Tom Tromey <tom@tromey.com>
6800
6801 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
6802 ui_out_emit_tuple.
6803
76f9c9cf
TT
68042017-09-09 Tom Tromey <tom@tromey.com>
6805
6806 * target.c (flash_erase_command): Use ui_out_emit_tuple.
6807 * stack.c (print_frame): Use ui_out_emit_tuple.
6808 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
6809 (info_spu_mailbox_command, info_spu_dma_command)
6810 (info_spu_proxydma_command): Likewise.
6811 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
6812 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
6813 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
6814 ui_out_emit_tuple.
6815 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
6816
dc9fe180
TT
68172017-09-09 Tom Tromey <tom@tromey.com>
6818
6819 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
6820 (class ui_out_emit_table): Update comment.
6821 * ui-out.c (do_cleanup_table_end)
6822 (make_cleanup_ui_out_table_begin_end): Remove.
6823 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
6824 (info_spu_dma_cmdlist): Likewise.
6825 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
6826 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
6827 ui_out_emit_table.
6828
f8cc3da6
TT
68292017-09-09 Tom Tromey <tom@tromey.com>
6830
6831 * thread.c (print_thread_info_1): Use ui_out_emit_table,
6832 ui_out_emit_list, gdb::optional.
6833
481695ed
JB
68342017-09-09 John Baldwin <jhb@FreeBSD.org>
6835
6836 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
6837 prototype.
6838 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
6839 prototype.
6840 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
6841 prototype.
6842 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
6843 * ada-exp.y: Remove _initialize_ada_exp prototype.
6844 * ada-lang.c: Remove _initialize_ada_language prototype.
6845 * ada-tasks.c: Remove _initialize_tasks prototype.
6846 * addrmap.c: Remove _initialize_addrmap prototype.
6847 * agent.c: Remove _initialize_agent prototype.
6848 * aix-thread.c: Remove _initialize_aix_thread prototype.
6849 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
6850 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
6851 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
6852 prototype.
6853 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
6854 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
6855 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
6856 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
6857 prototype.
6858 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
6859 prototype.
6860 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
6861 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
6862 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
6863 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
6864 prototype.
6865 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
6866 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
6867 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
6868 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
6869 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
6870 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
6871 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
6872 prototype.
6873 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
6874 prototype.
6875 * annotate.c: Remove _initialize_annotate prototype.
6876 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
6877 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
6878 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
6879 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
6880 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
6881 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
6882 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
6883 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
6884 prototype.
6885 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
6886 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
6887 * auto-load.c: Remove _initialize_auto_load prototype.
6888 * auxv.c: Remove _initialize_auxv prototype.
6889 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
6890 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
6891 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
6892 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
6893 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
6894 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
6895 prototype.
6896 * break-catch-throw.c: Remove _initialize_break_catch_throw
6897 prototype.
6898 * breakpoint.c: Remove _initialize_breakpoint prototype.
6899 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
6900 * btrace.c: Remove _initialize_btrace prototype.
6901 * charset.c: Remove _initialize_charset prototype.
6902 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
6903 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
6904 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
6905 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
6906 * cli/cli-script.c: Remove _initialize_cli_script prototype.
6907 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
6908 * coffread.c: Remove _initialize_coffread prototype.
6909 * compile/compile.c: Remove _initialize_compile prototype.
6910 * complaints.c: Remove _initialize_complaints prototype.
6911 * completer.c: Remove _initialize_completer prototype.
6912 * copying.awk: Remove _initialize_copying prototype.
6913 * copying.c: Regenerate.
6914 * core-regset.c: Remove _initialize_core_regset prototype.
6915 * corefile.c: Remove _initialize_core prototype.
6916 * corelow.c: Remove _initialize_corelow prototype.
6917 * cp-abi.c: Remove _initialize_cp_abi prototype.
6918 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
6919 * cp-support.c: Remove _initialize_cp_support prototype.
6920 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
6921 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
6922 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
6923 * ctf.c: Remove _initialize_ctf prototype.
6924 * d-lang.c: Remove _initialize_d_language prototype.
6925 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
6926 prototype.
6927 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
6928 * dbxread.c: Remove _initialize_dbxread prototype.
6929 * dcache.c: Remove _initialize_dcache prototype.
6930 * demangle.c: Remove _initialize_demangler prototype.
6931 * disasm-selftests.c: Remove _initialize_disasm_selftests
6932 prototype.
6933 * disasm.c: Remove _initialize_disasm prototype.
6934 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
6935 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
6936 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
6937 prototype.
6938 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
6939 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
6940 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
6941 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
6942 * elfread.c: Remove _initialize_elfread prototype.
6943 * exec.c: Remove _initialize_exec prototype.
6944 * extension.c: Remove _initialize_extension prototype.
6945 * f-lang.c: Remove _initialize_f_language prototype.
6946 * f-valprint.c: Remove _initialize_f_valprint prototype.
6947 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
6948 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
6949 * filesystem.c: Remove _initialize_filesystem prototype.
6950 * findcmd.c: Remove _initialize_mem_search prototype.
6951 * fork-child.c: Remove _initialize_fork_child prototype.
6952 * frame-base.c: Remove _initialize_frame_base prototype.
6953 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
6954 * frame.c: Remove _initialize_frame prototype.
6955 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
6956 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
6957 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
6958 * gcore.c: Remove _initialize_gcore prototype.
6959 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
6960 * gdbarch.c: Regenerate.
6961 * gdbarch.sh: Remove _initialize_gdbarch prototype.
6962 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
6963 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
6964 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
6965 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
6966 * go-lang.c: Remove _initialize_go_language prototype.
6967 * go32-nat.c: Remove _initialize_go32_nat prototype.
6968 * guile/guile.c: Remove _initialize_guile prototype.
6969 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
6970 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
6971 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
6972 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
6973 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
6974 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
6975 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
6976 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
6977 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
6978 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
6979 prototype.
6980 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
6981 prototype.
6982 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
6983 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
6984 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
6985 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
6986 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
6987 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
6988 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
6989 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
6990 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
6991 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
6992 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
6993 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
6994 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
6995 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
6996 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
6997 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
6998 prototype.
6999 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
7000 prototype.
7001 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
7002 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
7003 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
7004 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
7005 * infcall.c: Remove _initialize_infcall prototype.
7006 * infcmd.c: Remove _initialize_infcmd prototype.
7007 * inferior.c: Remove _initialize_inferiors prototype.
7008 * inflow.c: Remove _initialize_inflow prototype.
7009 * infrun.c: Remove _initialize_infrun prototype.
7010 * interps.c: Remove _initialize_interpreter prototype.
7011 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
7012 * jit.c: Remove _initialize_jit prototype.
7013 * language.c: Remove _initialize_language prototype.
7014 * linux-fork.c: Remove _initialize_linux_fork prototype.
7015 * linux-nat.c: Remove _initialize_linux_nat prototype.
7016 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
7017 * linux-thread-db.c: Remove _initialize_thread_db prototype.
7018 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
7019 * m2-lang.c: Remove _initialize_m2_language prototype.
7020 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
7021 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
7022 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
7023 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
7024 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
7025 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
7026 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
7027 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
7028 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
7029 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
7030 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
7031 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
7032 * machoread.c: Remove _initialize_machoread prototype.
7033 * macrocmd.c: Remove _initialize_macrocmd prototype.
7034 * macroscope.c: Remove _initialize_macroscope prototype.
7035 * maint.c: Remove _initialize_maint_cmds prototype.
7036 * mdebugread.c: Remove _initialize_mdebugread prototype.
7037 * memattr.c: Remove _initialize_mem prototype.
7038 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
7039 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
7040 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
7041 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
7042 * mi/mi-main.c: Remove _initialize_mi_main prototype.
7043 * microblaze-linux-tdep.c: Remove
7044 _initialize_microblaze_linux_tdep prototype.
7045 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
7046 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
7047 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
7048 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
7049 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
7050 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
7051 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
7052 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
7053 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
7054 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
7055 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
7056 prototype.
7057 * mipsread.c: Remove _initialize_mipsread prototype.
7058 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
7059 prototype.
7060 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
7061 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
7062 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
7063 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
7064 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
7065 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
7066 prototype.
7067 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
7068 * nto-procfs.c: Remove _initialize_procfs prototype.
7069 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
7070 * objc-lang.c: Remove _initialize_objc_language prototype.
7071 * objfiles.c: Remove _initialize_objfiles prototype.
7072 * observer.c: Remove observer_test_first_notification_function,
7073 observer_test_second_notification_function,
7074 observer_test_third_notification_function, and
7075 _initialize_observer prototypes.
7076 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
7077 * osabi.c: Remove _initialize_gdb_osabi prototype.
7078 * osdata.c: Remove _initialize_osdata prototype.
7079 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
7080 * parse.c: Remove _initialize_parse prototype.
7081 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
7082 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
7083 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
7084 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
7085 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
7086 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
7087 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
7088 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
7089 * printcmd.c: Remove _initialize_printcmd prototype.
7090 * probe.c: Remove _initialize_probe prototype.
7091 * proc-api.c: Remove _initialize_proc_api prototype.
7092 * proc-events.c: Remove _initialize_proc_events prototype.
7093 * proc-service.c: Remove _initialize_proc_service prototype.
7094 * procfs.c: Remove _initialize_procfs prototype.
7095 * psymtab.c: Remove _initialize_psymtab prototype.
7096 * python/python.c: Remove _initialize_python prototype.
7097 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
7098 * record-btrace.c: Remove _initialize_record_btrace prototype.
7099 * record-full.c: Remove _initialize_record_full prototype.
7100 * record.c: Remove _initialize_record prototype.
7101 * regcache.c: Remove _initialize_regcache prototype.
7102 * reggroups.c: Remove _initialize_reggroup prototype.
7103 * remote-notif.c: Remove _initialize_notif prototype.
7104 * remote-sim.c: Remove _initialize_remote_sim prototype.
7105 * remote.c: Remove _initialize_remote prototype.
7106 * reverse.c: Remove _initialize_reverse prototype.
7107 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
7108 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
7109 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
7110 prototype.
7111 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
7112 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
7113 * rust-exp.y: Remove _initialize_rust_exp prototype.
7114 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
7115 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
7116 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
7117 * score-tdep.c: Remove _initialize_score_tdep prototype.
7118 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
7119 prototype.
7120 * ser-go32.c: Remove _initialize_ser_dos prototype.
7121 * ser-mingw.c: Remove _initialize_ser_windows prototype.
7122 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
7123 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
7124 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
7125 * serial.c: Remove _initialize_serial prototype.
7126 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
7127 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
7128 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
7129 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
7130 * skip.c: Remove _initialize_step_skip prototype.
7131 * sol-thread.c: Remove _initialize_sol_thread prototype.
7132 * solib-aix.c: Remove _initialize_solib_aix prototype.
7133 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
7134 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
7135 * solib-frv.c: Remove _initialize_frv_solib prototype.
7136 * solib-spu.c: Remove _initialize_spu_solib prototype.
7137 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
7138 * solib-target.c: Remove _initialize_solib_target prototype.
7139 * solib.c: Remove _initialize_solib prototype.
7140 * source.c: Remove _initialize_source prototype.
7141 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
7142 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
7143 prototype.
7144 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
7145 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
7146 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
7147 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
7148 prototype.
7149 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
7150 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
7151 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
7152 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
7153 prototype.
7154 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
7155 prototype.
7156 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
7157 prototype.
7158 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
7159 prototype.
7160 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
7161 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
7162 prototype.
7163 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
7164 prototype.
7165 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
7166 prototype.
7167 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
7168 prototype.
7169 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
7170 prototype.
7171 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
7172 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
7173 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
7174 * stabsread.c: Remove _initialize_stabsread prototype.
7175 * stack.c: Remove _initialize_stack prototype.
7176 * stap-probe.c: Remove _initialize_stap_probe prototype.
7177 * std-regs.c: Remove _initialize_frame_reg prototype.
7178 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
7179 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
7180 * symfile.c: Remove _initialize_symfile prototype.
7181 * symmisc.c: Remove _initialize_symmisc prototype.
7182 * symtab.c: Remove _initialize_symtab prototype.
7183 * target-dcache.c: Remove _initialize_target_dcache prototype.
7184 * target-descriptions.c: Remove _initialize_target_descriptions
7185 prototype.
7186 * thread.c: Remove _initialize_thread prototype.
7187 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
7188 prototype.
7189 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
7190 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
7191 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
7192 prototype.
7193 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
7194 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
7195 * tracefile.c: Remove _initialize_tracefile prototype.
7196 * tracepoint.c: Remove _initialize_tracepoint prototype.
7197 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
7198 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
7199 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
7200 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
7201 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
7202 * tui/tui-win.c: Remove _initialize_tui_win prototype.
7203 * tui/tui.c: Remove _initialize_tui prototype.
7204 * typeprint.c: Remove _initialize_typeprint prototype.
7205 * user-regs.c: Remove _initialize_user_regs prototype.
7206 * utils.c: Remove _initialize_utils prototype.
7207 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
7208 * valarith.c: Remove _initialize_valarith prototype.
7209 * valops.c: Remove _initialize_valops prototype.
7210 * valprint.c: Remove _initialize_valprint prototype.
7211 * value.c: Remove _initialize_values prototype.
7212 * varobj.c: Remove _initialize_varobj prototype.
7213 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
7214 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
7215 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
7216 * windows-nat.c: Remove _initialize_windows_nat,
7217 _initialize_check_for_gdb_ini, and _initialize_loadable
7218 prototypes.
7219 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
7220 * xcoffread.c: Remove _initialize_xcoffread prototype.
7221 * xml-support.c: Remove _initialize_xml_support prototype.
7222 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
7223 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
7224 prototype.
7225 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
7226 prototype.
7227 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
7228
a611b5cb
KS
72292017-09-08 Keith Seitz <keiths@redhat.com>
7230
7231 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
7232 field.
7233
469412dd
CW
72342017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
7235
7236 * f-valprint.c (f_val_print): Remove check for one byte
7237 sized integers. Remove printing of character type.
7238
a5ad232b
FP
72392017-09-08 Frank Penczek <frank.penczek@intel.com>
7240 Christoph Weinmann <christoph.t.weinmann@intel.com>
7241 Bernhard Heckel <bernhard.heckel@intel.com>
7242
7243 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
7244 to maintain proper indentation when printing pointers/refs.
7245
e5014227
JB
72462017-09-07 Joel Brobecker <brobecker@adacore.com>
7247
7248 GDB 8.0.1 released.
7249
63c99141
JB
72502017-09-07 Joel Brobecker <brobecker@adacore.com>
7251
7252 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
7253
69c1e056
TT
72542017-09-05 Tom Tromey <tom@tromey.com>
7255
7256 * parse.c (funcall_chain): Now a std::vector.
7257 (start_arglist, end_arglist): Simplify.
7258 (free_funcalls): Remove.
7259 (parse_exp_in_context_1): Remove cleanup.
7260
fef704bf
TT
72612017-09-05 Tom Tromey <tom@tromey.com>
7262
7263 * go-exp.y (go_parse): Don't create a cleanup.
7264
5613c585
TT
72652017-09-05 Tom Tromey <tom@tromey.com>
7266
7267 * d-exp.y (PrimaryExpression): Use std::string.
7268 (d_parse): Don't create a cleanup.
7269
eae49211
TT
72702017-09-05 Tom Tromey <tom@tromey.com>
7271
7272 * utils.c (do_clear_parser_state): Remove.
7273 (make_cleanup_clear_parser_state): Remove.
7274 * p-exp.y (pascal_parse): Use scoped_restore.
7275 * m2-exp.y (m2_parse): Use scoped_restore.
7276 * f-exp.y (f_parse): Use scoped_restore.
7277 * d-exp.y (d_parse): Use scoped_restore.
7278 * c-exp.y (c_parse): Use scoped_restore.
7279 * ada-exp.y (ada_parse): Use scoped_restore.
7280 * utils.h (make_cleanup_clear_parser_state): Remove.
7281
73b9be8b
KS
72822017-09-06 Keith Seitz <keiths@redhat.com>
7283
7284 * dwarf2read.c (dw2_linkage_name_attr): New function.
7285 (dw2_linkage_name): New function.
7286 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
7287 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
7288 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
7289
a102602b
KR
72902017-09-06 Kamil Rytarowski <n54@gmx.com>
7291
7292 * config/djgpp/djconfig.sh: Correct shell portability issue.
7293
28ad437d
KR
72942017-09-06 Kamil Rytarowski <n54@gmx.com>
7295
7296 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
7297
351787dd
JB
72982017-09-06 John Baldwin <jhb@FreeBSD.org>
7299
7300 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
7301 * NEWS: Mention new FreeBSD/mips native configuration.
7302 * configure.host: Add aarch64*-*-freebsd*.
7303 * configure.nat: Likewise.
7304 * aarch64-fbsd-nat.c: New file.
7305
c0f84956
JB
73062017-09-06 John Baldwin <jhb@FreeBSD.org>
7307
7308 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
7309 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
7310 * NEWS: Mention new FreeBSD/aarch64 target.
7311 * configure.tgt: Add aarch64*-*-freebsd*.
7312 * aarch64-fbsd-tdep.c: New file.
7313 * aarch64-fbsd-tdep.h: New file.
7314
7610297a
KR
73152017-09-06 Kamil Rytarowski <n54@gmx.com>
7316
7317 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
7318
fbd1b771
JK
73192017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
7320
7321 * parse.c (find_minsym_type_and_address): Don't relocate addresses
7322 of TLS symbols.
7323
5ca79eae
PW
73242017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7325
7326 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
7327 call.
7328
bf93d7ba
SM
73292017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7330
7331 * infrun.c (follow_exec): Call add_thread after
7332 target_find_description.
7333
1bb7c059
SM
73342017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7335
7336 * infrun.c (handle_inferior_event_1): When exec'ing, read
7337 stop_pc after follow_exec.
7338
fc809827
SM
73392017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7340
7341 * remote.c (process_g_packet): Update error message.
7342
d2fcdd85
YQ
73432017-09-05 Yao Qi <yao.qi@linaro.org>
7344
7345 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
7346 targets.
7347
e69570ee
PA
73482017-09-05 Pedro Alves <palves@redhat.com>
7349
7350 * eval.c (eval_call, evaluate_funcall): New functions, factored
7351 out from ...
7352 (evaluate_subexp_standard): ... this.
7353
22916b07
YQ
73542017-09-05 Yao Qi <yao.qi@linaro.org>
7355
7356 * amd64-tdep.c (amd64_target_description): Create target
7357 descriptions.
7358 (_initialize_amd64_tdep): Don't call functions
7359 initialize_tdesc_amd64_*. Add self tests.
7360 * arch/amd64.c (amd64_create_target_description): Add parameter
7361 is_linux. Call set_tdesc_osabi if is_linux is true.
7362 * arch/amd64.h (amd64_create_target_description): Update the
7363 declaration.
7364 * arch/i386.c (i386_create_target_description): Add parameter
7365 is_linux. Call set_tdesc_osabi if is_linux is true.
7366 * arch/i386.h (i386_create_target_description): Update
7367 declaration.
7368 * configure.tgt: Add i386.o to gdb_target_obs.
7369 * features/Makefile (XMLTOC): Remove i386/*.xml.
7370 * features/i386/amd64-avx-avx512.c: Remove.
7371 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
7372 * features/i386/amd64-avx-mpx.c: Remove.
7373 * features/i386/amd64-avx.c: Remove.
7374 * features/i386/amd64-mpx.c: Remove.
7375 * features/i386/amd64.c: Remove.
7376 * features/i386/i386-avx-avx512.c: Remove.
7377 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
7378 * features/i386/i386-avx-mpx.c: Remove.
7379 * features/i386/i386-avx.c: Remove.
7380 * features/i386/i386-mmx.c: Remove.
7381 * features/i386/i386-mpx.c: Remove.
7382 * features/i386/i386.c: Remove.
7383 * i386-tdep.c: Don't include features/i386/i386*.c., include
7384 target-descriptions.h and arch/i386.h.
7385 (i386_target_description): Create target descriptions.
7386 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
7387 functions. Do self tests.
7388
0854b7b1
YQ
73892017-09-05 Yao Qi <yao.qi@linaro.org>
7390
7391 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
7392 * features/i386/amd64-avx-avx512-linux.c: Removed.
7393 * features/i386/amd64-avx-linux.c: Removed.
7394 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
7395 * features/i386/amd64-avx-mpx-linux.c: Removed.
7396 * features/i386/amd64-linux.c: Removed.
7397 * features/i386/amd64-mpx-linux.c: Removed.
7398 * features/i386/x32-avx-avx512-linux.c: Removed.
7399 * features/i386/x32-avx-linux.c: Removed.
7400 * features/i386/x32-linux.c: Removed.
7401
b4570e4b
YQ
74022017-09-05 Yao Qi <yao.qi@linaro.org>
7403
7404 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
7405 features/i386/*.c.
7406 (amd64_linux_read_description): Call
7407 amd64_create_target_description.
7408 * arch/amd64.c: New file.
7409 * arch/amd64.h: New file.
7410 * configure.tgt (x86_64-*-linux*): Append amd64.o.
7411 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
7412
6c73f67f
YQ
74132017-09-05 Yao Qi <yao.qi@linaro.org>
7414
7415 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
7416 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
7417 (amd64_linux_read_description): Create target descriptions.
7418 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
7419 functions. Add unit tests.
7420 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
7421 x32-core.xml.
7422 * features/i386/64bit-avx.c: Generated.
7423 * features/i386/64bit-avx512.c: Generated.
7424 * features/i386/64bit-core.c: Generated.
7425 * features/i386/64bit-linux.c: Generated.
7426 * features/i386/64bit-mpx.c: Generated.
7427 * features/i386/64bit-pkeys.c: Generated.
7428 * features/i386/64bit-segments.c: Generated.
7429 * features/i386/64bit-sse.c: Generated.
7430 * features/i386/x32-core.c: Generated.
7431 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
7432 c files for amd64-linux and x32-linux.
7433
9d3d478b
YQ
74342017-09-05 Yao Qi <yao.qi@linaro.org>
7435
7436 * amd64-linux-tdep.c (amd64_linux_read_description): New
7437 function.
7438 (amd64_linux_core_read_description): Call
7439 amd64_linux_read_description.
7440 (amd64_linux_init_abi): Likewise.
7441 (amd64_x32_linux_init_abi): Likewise.
7442 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
7443 * x86-linux-nat.c (x86_linux_read_description): Call
7444 amd64_linux_read_description.
7445
b9f1d50f
YQ
74462017-09-05 Yao Qi <yao.qi@linaro.org>
7447
7448 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
7449 comments.
7450
188c9e6d
YQ
74512017-09-05 Yao Qi <yao.qi@linaro.org>
7452
7453 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
7454 * features/i386/i386-avx-avx512-linux.c: Remove.
7455 * features/i386/i386-avx-linux.c: Remove.
7456 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
7457 * features/i386/i386-avx-mpx-linux.c: Remove.
7458 * features/i386/i386-linux.c: Remove.
7459 * features/i386/i386-mmx-linux.c: Remove.
7460 * features/i386/i386-mpx-linux.c: Remove.
7461
5f035c07
YQ
74622017-09-05 Yao Qi <yao.qi@linaro.org>
7463
7464 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
7465 (SFILES): Add arch/i386.c.
7466 (HFILES_NO_SRCDIR): Add arch/i386.h.
7467 * arch/i386.c: New file.
7468 * arch/i386.h: New file.
7469 * arch/tdesc.h (allocate_target_description): Declare.
7470 (set_tdesc_architecture): Declare.
7471 (set_tdesc_osabi): Declare.
7472 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
7473 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
7474 include arch/i386.h.
7475 (i386_linux_read_description): Remove code and call
7476 i386_create_target_description.
7477 (set_tdesc_architecture): New function.
7478 (set_tdesc_osabi): New function.
7479 * target-descriptions.h (allocate_target_description): Remove.
7480
0abe8a89
YQ
74812017-09-05 Yao Qi <yao.qi@linaro.org>
7482
7483 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
7484 * target-descriptions.c (tdesc_create_feature): Likewise, and
7485 adjust code.
7486 * features/i386/32bit-avx.c: Re-generated.
7487 * features/i386/32bit-avx512.c: Re-generated.
7488 * features/i386/32bit-core.c: Re-generated.
7489 * features/i386/32bit-linux.c: Re-generated.
7490 * features/i386/32bit-mpx.c: Re-generated.
7491 * features/i386/32bit-pkeys.c: Re-generated.
7492 * features/i386/32bit-sse.c: Re-generated.
7493
0a188386
YQ
74942017-09-05 Yao Qi <yao.qi@linaro.org>
7495
7496 * regformats/regdef.h (struct reg): Override operator == and !=.
7497
f49ff000
YQ
74982017-09-05 Yao Qi <yao.qi@linaro.org>
7499
7500 * arch/tdesc.h: New file.
7501 * regformats/regdat.sh: Generate code using tdesc_create_reg.
7502 * target-descriptions.c: Update comments.
7503 * target-descriptions.h: Include "arch/tdesc.h". Remove the
7504 declarations.
7505 * features/i386/32bit-avx.c: Re-generated.
7506 * features/i386/32bit-avx512.c: Re-generated.
7507 * features/i386/32bit-core.c: Re-generated.
7508 * features/i386/32bit-linux.c: Re-generated.
7509 * features/i386/32bit-mpx.c: Re-generated.
7510 * features/i386/32bit-pkeys.c: Re-generated.
7511 * features/i386/32bit-sse.c: Re-generated.
7512
f7000548
YQ
75132017-09-05 Yao Qi <yao.qi@linaro.org>
7514
7515 * regformats/regdat.sh: Update generated code.
7516
c9a5e2a5
YQ
75172017-09-05 Yao Qi <yao.qi@linaro.org>
7518
7519 * regformats/regdat.sh: Adjust code order.
7520
d6b687ac
SM
75212017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7522
7523 * expprint.c (dump_subexp_body_standard): Use constant format
7524 string in fprintf_filtered call.
7525
a379bfd0
JB
75262017-09-04 John Baldwin <jhb@FreeBSD.org>
7527
7528 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
7529 NetBSD/i386.
7530 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
7531
f7efc967
JB
75322017-09-04 John Baldwin <jhb@FreeBSD.org>
7533
7534 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
7535
c49fbc6c
JB
75362017-09-04 John Baldwin <jhb@FreeBSD.org>
7537
7538 * bsd-kvm.o: Define _KMEMUSER.
7539 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
7540 * configure: Regenerate.
7541
26562e73
JB
75422017-09-04 John Baldwin <jhb@FreeBSD.org>
7543
7544 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
7545 * i386-fbsd-nat.c: Likewise.
7546
31cf1487
JB
75472017-09-04 John Baldwin <jhb@FreeBSD.org>
7548
7549 * unittests/array-view-selftests.c: Add include of <array>.
7550
5b9f8a7c
JB
75512017-09-04 John Baldwin <jhb@FreeBSD.org>
7552
7553 * spu-tdep.c (flush_ea_cache): Add missing argument to
7554 call_function_by_hand.
7555
d69cf9b2
PA
75562017-09-04 Pedro Alves <palves@redhat.com>
7557
7558 * NEWS (Safer support for debugging with no debug info): New.
7559
3693fdb3
PA
75602017-09-04 Pedro Alves <palves@redhat.com>
7561
7562 * c-exp.y (function_method, function_method_void): Add current
7563 instance flags to TYPE_INSTANCE.
7564 * dwarf2read.c (check_modifier): New.
7565 (compute_delayed_physnames): Assert that only C++ adds delayed
7566 physnames. Mark fn_fields as const/volatile depending on
7567 physname.
7568 * eval.c (make_params): New type_instance_flags parameter. Use
7569 it as the new type's instance flags.
7570 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
7571 flags element and pass it to make_params.
7572 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
7573 instance flags element.
7574 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
7575 * gdbtypes.h: Include "enum-flags.h".
7576 (type_instance_flags): New enum-flags type.
7577 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
7578 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
7579 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
7580 (follow_type_instance_flags): New function.
7581 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
7582 * parser-defs.h (follow_type_instance_flags): Declare.
7583 * valops.c (value_struct_elt_for_reference): const/volatile must
7584 match too.
7585
e68cb8e0
PA
75862017-09-04 Pedro Alves <palves@redhat.com>
7587
7588 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
7589 function/method scopes; lookup the nested name as a function local
7590 static variable.
7591
858be34c
PA
75922017-09-04 Pedro Alves <palves@redhat.com>
7593
7594 (%type <voidval>): Add function_method.
7595 * c-exp.y (exp): New production for calls with no arguments.
7596 (function_method, function_method_void_or_typelist): New
7597 productions.
7598 (exp): New production for "method()::static_var".
7599 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
7600 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7601 Handle OP_FUNC_STATIC_VAR.
7602 * parse.c (operator_length_standard):
7603 Handle OP_FUNC_STATIC_VAR.
7604
dd5901a6
PA
76052017-09-04 Pedro Alves <palves@redhat.com>
7606
7607 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
7608 handling.
7609 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7610 Ditto.
7611 * parse.c (operator_length_standard, operator_check_standard):
7612 Ditto.
7613 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
7614
46a4882b
PA
76152017-09-04 Pedro Alves <palves@redhat.com>
7616
7617 * ax-gdb.c: Include "typeprint.h".
7618 (gen_expr_for_cast): New function.
7619 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
7620 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
7621 type is unknown.
7622 * dwarf2read.c (new_symbol_full): Fallback to int instead of
7623 nodebug_data_symbol.
7624 * eval.c: Include "typeprint.h".
7625 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
7626 Error out if symbol has unknown type.
7627 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
7628 evaluate_subexp_for_cast.
7629 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
7630 OP_VAR_MSYM_VALUE.
7631 (evaluate_subexp_for_cast): New function.
7632 * gdbtypes.c (init_nodebug_var_type): New function.
7633 (objfile_type): Use it to initialize types of variables with no
7634 debug info.
7635 * typeprint.c (error_unknown_type): New.
7636 * typeprint.h (error_unknown_type): New declaration.
7637 * compile/compile-c-types.c (convert_type_basic): Handle
7638 TYPE_CODE_ERROR; warn and fallback to int for variables with
7639 unknown type.
7640
fe13dfec
PA
76412017-09-04 Pedro Alves <palves@redhat.com>
7642
7643 * eval.c (evaluate_var_value): New function, factored out from ...
7644 (evaluate_subexp_standard): ... here.
7645
d008ee21
PA
76462017-09-04 Pedro Alves <palves@redhat.com>
7647
7648 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
7649 Remove useless assignments to 'op'.
7650
827d0c51
PA
76512017-09-04 Pedro Alves <palves@redhat.com>
7652
7653 * eval.c (eval_skip_value): New function.
7654 (evaluate_subexp_standard): Use it.
7655
2c5a2be1
PA
76562017-09-04 Pedro Alves <palves@redhat.com>
7657
7658 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
7659 function name from symbol/minsym and pass it to
7660 error_call_unknown_return_type.
7661
74ea4be4
PA
76622017-09-04 Pedro Alves <palves@redhat.com>
7663
7664 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
7665 * ax-gdb.c (gen_msym_var_ref): New function.
7666 (gen_expr): Handle OP_VAR_MSYM_VALUE.
7667 * eval.c (evaluate_var_msym_value): New function.
7668 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
7669 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
7670 to call_function_by_hand.
7671 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7672 Handle OP_VAR_MSYM_VALUE.
7673 (union exp_element) <msymbol>: New field.
7674 * minsyms.h (struct type): Forward declare.
7675 (find_minsym_type_and_address): Declare.
7676 * parse.c (write_exp_elt_msym): New function.
7677 (write_exp_msymbol): Delete, refactored as ...
7678 (find_minsym_type_and_address): ... this new function.
7679 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
7680 (operator_length_standard, operator_check_standard): Handle
7681 OP_VAR_MSYM_VALUE.
7682 * std-operator.def (OP_VAR_MSYM_VALUE): New.
7683
7022349d
PA
76842017-09-04 Pedro Alves <palves@redhat.com>
7685
7686 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
7687 TYPE_GNU_IFUNC specially here. Throw error if return type is
7688 unknown.
7689 * ada-typeprint.c (print_func_type): Handle functions with unknown
7690 return type.
7691 * c-typeprint.c (c_type_print_base): Handle functions and methods
7692 with unknown return type.
7693 * compile/compile-c-symbols.c (convert_symbol_bmsym)
7694 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
7695 * compile/compile-c-types.c: Include "objfiles.h".
7696 (convert_func): For functions with unknown return type, warn and
7697 default to int.
7698 * compile/compile-object-run.c (compile_object_run): Adjust call
7699 to call_function_by_hand_dummy.
7700 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
7701 call_function_by_hand.
7702 * eval.c (evaluate_subexp_standard): Adjust calls to
7703 call_function_by_hand. Handle functions and methods with unknown
7704 return type. Pass expect_type to call_function_by_hand.
7705 * f-typeprint.c (f_type_print_base): Handle functions with unknown
7706 return type.
7707 * gcore.c (call_target_sbrk): Adjust call to
7708 call_function_by_hand.
7709 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
7710 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
7711 an integer address type instead of nodebug.
7712 * guile/scm-value.c (gdbscm_value_call): Adjust call to
7713 call_function_by_hand.
7714 * infcall.c (error_call_unknown_return_type): New function.
7715 (call_function_by_hand): New "default_return_type" parameter.
7716 Pass it down.
7717 (call_function_by_hand_dummy): New "default_return_type"
7718 parameter. Use it instead of defaulting to int. If there's no
7719 default and the return type is unknown, throw an error. If
7720 there's a default return type, and the called function has no
7721 debug info, then assume the function is prototyped.
7722 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
7723 New "default_return_type" parameter.
7724 (error_call_unknown_return_type): New declaration.
7725 * linux-fork.c (call_lseek): Cast return type of lseek.
7726 (inferior_call_waitpid, checkpoint_command): Adjust calls to
7727 call_function_by_hand.
7728 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
7729 calls to call_function_by_hand.
7730 * m2-typeprint.c (m2_procedure): Handle functions with unknown
7731 return type.
7732 * objc-lang.c (lookup_objc_class, lookup_child_selector)
7733 (value_nsstring, print_object_command): Adjust calls to
7734 call_function_by_hand.
7735 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
7736 functions with unknown return type.
7737 (pascal_type_print_func_varspec_suffix): New function.
7738 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
7739 TYPE_CODE_METHOD>: Use it.
7740 * python/py-value.c (valpy_call): Adjust call to
7741 call_function_by_hand.
7742 * rust-lang.c (rust_evaluate_funcall): Adjust call to
7743 call_function_by_hand.
7744 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
7745 call_function_by_hand.
7746 * valops.c (value_allocate_space_in_inferior): Adjust call to
7747 call_function_by_hand.
7748 * typeprint.c (type_print_unknown_return_type): New function.
7749 * typeprint.h (type_print_unknown_return_type): New declaration.
7750
54990598
PA
77512017-09-04 Pedro Alves <palves@redhat.com>
7752
7753 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
7754 types with more than one parameter as prototyped.
7755
9a24775b
PA
77562017-09-04 Pedro Alves <palves@redhat.com>
7757
7758 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
7759 (disassemble_command): Use gdb_disassembly_flags instead of bare
7760 int.
7761 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
7762 (dump_insns, do_mixed_source_and_assembly_deprecated)
7763 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
7764 Use gdb_disassembly_flags instead of bare int.
7765 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
7766 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
7767 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
7768 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
7769 (enum gdb_disassembly_flag): ... values of this new enumeration.
7770 (gdb_disassembly_flags): Define.
7771 (gdb_disassembly)
7772 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
7773 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
7774 gdb_disassembly_flags instead of bare int.
7775 * record-btrace.c (btrace_insn_history)
7776 (record_btrace_insn_history, record_btrace_insn_history_range)
7777 (record_btrace_insn_history_from): Use gdb_disassembly_flags
7778 instead of bare int.
7779 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
7780 Use gdb_disassembly_flags instead of bare int.
7781 * target-debug.h (target_debug_print_gdb_disassembly_flags):
7782 Define.
7783 * target-delegates.c: Regenerate.
7784 * target.c (target_insn_history, target_insn_history_from)
7785 (target_insn_history_range): Use gdb_disassembly_flags instead of
7786 bare int.
7787 * target.h: Include "disasm.h".
7788 (struct target_ops) <to_insn_history, to_insn_history_from,
7789 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
7790 int.
7791 (target_insn_history, target_insn_history_from)
7792 (target_insn_history_range): Use gdb_disassembly_flags instead of
7793 bare int.
7794
80a65e9b
SM
77952017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7796
7797 * cli/cli-script.c (build_command_line): For if/while commands,
7798 check whether args is empty.
7799
6b66338c
SM
78002017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7801
7802 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
7803 (enum command_control_type): Likewise.
7804 (struct command_line): Likewise.
7805 (free_command_lines): Likewise.
7806 (struct command_lines_deleter): Likewise.
7807 (command_line_up): Likewise.
7808 (read_command_lines): Likewise.
7809 (read_command_lines_1): Likewise.
7810 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
7811 (enum command_control_type): Likewise.
7812 (struct command_line): Likewise.
7813 (free_command_lines): Likewise.
7814 (struct command_lines_deleter): Likewise.
7815 (command_line_up): Likewise.
7816 (read_command_lines): Likewise.
7817 (read_command_lines_1): Likewise.
7818 * breakpoint.h: Include cli/cli-script.h.
7819 * extension-priv.h: Likewise.
7820 * gdbcmd.h: Likewise.
7821
51abb421
PA
78222017-09-04 Pedro Alves <palves@redhat.com>
7823
7824 * ada-lang.c (is_known_support_routine): Move sal declaration to
7825 where it is initialized.
7826 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
7827 (parse_breakpoint_sals, decode_static_tracepoint_spec)
7828 (clear_command, update_static_tracepoint): Remove init_sal
7829 references. Move declarations closer to initializations.
7830 * cli/cli-cmds.c (list_command): Move sal declarations closer to
7831 initializations.
7832 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
7833 references. Move sal declarations closer to initializations.
7834 * frame.c (find_frame_sal): Return a symtab_and_line via function
7835 return instead of output parameter. Remove init_sal references.
7836 * frame.h (find_frame_sal): Return a symtab_and_line via function
7837 return instead of output parameter.
7838 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
7839 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
7840 instead of memset.
7841 (gdbscm_find_pc_line): Remove init_sal reference.
7842 * infcall.c (call_function_by_hand_dummy): Remove init_sal
7843 references. Move declarations closer to initializations.
7844 * infcmd.c (set_step_frame): Update. Move declarations closer to
7845 initializations.
7846 (finish_backward): Remove init_sal references. Move declarations
7847 closer to initializations.
7848 * infrun.c (process_event_stop_test, handle_step_into_function)
7849 (insert_hp_step_resume_breakpoint_at_frame)
7850 (insert_step_resume_breakpoint_at_caller): Likewise.
7851 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
7852 (symbol_to_sal): Likewise.
7853 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
7854 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
7855 to its initialization.
7856 * reverse.c (save_bookmark_command): Use new/delete. Remove
7857 init_sal references. Move declarations closer to initializations.
7858 * source.c (get_current_source_symtab_and_line): Remove brace
7859 initialization.
7860 (set_current_source_symtab_and_line): Now takes the sal by const
7861 reference. Remove brace initialization.
7862 (line_info): Remove init_sal reference.
7863 * source.h (set_current_source_symtab_and_line): Now takes a
7864 symtab_and_line via const reference.
7865 * stack.c (set_current_sal_from_frame): Adjust.
7866 (print_frame_info): Adjust.
7867 (get_last_displayed_sal): Return the sal via function return
7868 instead of via output parameter. Simplify.
7869 (frame_info): Adjust.
7870 * stack.h (get_last_displayed_sal): Return the sal via function
7871 return instead of via output parameter.
7872 * symtab.c (init_sal): Delete.
7873 (find_pc_sect_line): Remove init_sal references. Move
7874 declarations closer to initializations.
7875 (find_function_start_sal): Remove init_sal references. Move
7876 declarations closer to initializations.
7877 * symtab.h (struct symtab_and_line): In-class initialize all
7878 fields.
7879 * tracepoint.c (set_traceframe_context)
7880 (print_one_static_tracepoint_marker): Remove init_sal references.
7881 Move declarations closer to initializations.
7882 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
7883 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
7884 declarations closer to initializations.
7885 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
7886 init_sal references. Adjust.
7887
6c5b2ebe
PA
78882017-09-04 Pedro Alves <palves@redhat.com>
7889
7890 * ax-gdb.c (agent_command_1): Use range-for.
7891 * break-catch-throw.c (re_set_exception_catchpoint): Update.
7892 * breakpoint.c: Include "common/array-view.h".
7893 (init_breakpoint_sal, create_breakpoint_sal): Change sals
7894 parameter from struct symtabs_and_lines to
7895 array_view<symtab_and_line>. Adjust. Use range-for. Update.
7896 (breakpoint_sals_to_pc): Change sals parameter from struct
7897 symtabs_and_lines to std::vector reference.
7898 (check_fast_tracepoint_sals): Change sals parameter from struct
7899 symtabs_and_lines to std::array_view. Use range-for.
7900 (decode_static_tracepoint_spec): Return a std::vector instead of
7901 symtabs_and_lines. Update.
7902 (create_breakpoint): Update.
7903 (break_range_command, until_break_command, clear_command): Update.
7904 (base_breakpoint_decode_location, bkpt_decode_location)
7905 (bkpt_probe_create_sals_from_location)
7906 (bkpt_probe_decode_location, tracepoint_decode_location)
7907 (tracepoint_probe_decode_location)
7908 (strace_marker_create_sals_from_location): Return a std::vector
7909 instead of symtabs_and_lines.
7910 (strace_marker_create_breakpoints_sal): Update.
7911 (strace_marker_decode_location): Return a std::vector instead of
7912 symtabs_and_lines. Update.
7913 (update_breakpoint_locations): Change struct symtabs_and_lines
7914 parameters to gdb::array_view. Adjust.
7915 (location_to_sals): Return a std::vector instead of
7916 symtabs_and_lines. Update.
7917 (breakpoint_re_set_default): Use std::vector instead of struct
7918 symtabs_and_lines.
7919 (decode_location_default): Return a std::vector instead of
7920 symtabs_and_lines. Update.
7921 * breakpoint.h: Include "common/array-view.h".
7922 (struct breakpoint_ops) <decode_location>: Now returns a
7923 std::vector instead of returning a symtabs_and_lines via output
7924 parameter.
7925 (update_breakpoint_locations): Change sals parameters to use
7926 gdb::array_view.
7927 * cli/cli-cmds.c (edit_command, list_command): Update to use
7928 std::vector and gdb::array_view.
7929 (ambiguous_line_spec): Adjust to use gdb::array_view and
7930 range-for.
7931 (compare_symtabs): Rename to ...
7932 (cmp_symtabs): ... this. Change parameters to symtab_and_line
7933 const reference and adjust.
7934 (filter_sals): Rewrite using std::vector and standard algorithms.
7935 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
7936 (jump_command): Update to use std::vector.
7937 * linespec.c (struct linespec_state) <canonical_names>: Update
7938 comment.
7939 (add_sal_to_sals_basic): Delete.
7940 (add_sal_to_sals, filter_results, convert_results_to_lsals)
7941 (decode_line_2, create_sals_line_offset)
7942 (convert_address_location_to_sals, convert_linespec_to_sals)
7943 (convert_explicit_location_to_sals, parse_linespec)
7944 (event_location_to_sals, decode_line_full, decode_line_1)
7945 (decode_line_with_current_source)
7946 (decode_line_with_last_displayed, decode_objc)
7947 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
7948 (linespec_result::~linespec_result): Adjust to use std::vector
7949 instead of symtabs_and_lines.
7950 * linespec.h (linespec_sals::sals): Now a std::vector.
7951 (struct linespec_result): Use std::vector, bool, and in-class
7952 initialization.
7953 (decode_line_1, decode_line_with_current_source)
7954 (decode_line_with_last_displayed): Return std::vector.
7955 * macrocmd.c (info_macros_command): Use std::vector.
7956 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
7957 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
7958 std::vector.
7959 * probe.h (parse_probes): Return a std::vector.
7960 * python/python.c (gdbpy_decode_line): Use std::vector and
7961 gdb::array_view.
7962 * source.c (select_source_symtab, line_info): Use std::vector.
7963 * stack.c (func_command): Use std::vector.
7964 * symtab.h (struct symtabs_and_lines): Delete.
7965 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
7966
7c44b49c
PA
79672017-09-04 Pedro Alves <palves@redhat.com>
7968
7969 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7970 unittests/array-view-selftests.c.
7971 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
7972 * common/array-view.h: New file.
7973 * unittests/array-view-selftests.c: New file.
7974
e439fa14
PA
79752017-09-04 Pedro Alves <palves@redhat.com>
7976
7977 * cli/cli-cmds.c (edit_command): Pass message to
7978 ambiguous_line_spec.
7979 (list_command): Pass message to ambiguous_line_spec. Say
7980 "first"/"last" instead of "start" and "end" to be consistent with
7981 the manual.
7982 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
7983 them to print formatted message.
7984
7525b645
PA
79852017-09-04 Pedro Alves <palves@redhat.com>
7986
7987 * btrace.c (ftrace_add_pt): Pass btrace_insn to
7988 ftrace_update_insns by reference instead of pointer.
7989
badc0020
YQ
79902017-09-04 Yao Qi <yao.qi@linaro.org>
7991
7992 * i386-go32-tdep.c: Include x86-xstate.h.
7993 (i386_go32_init_abi): Call i386_target_description.
7994 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
7995 if xcr0 is X86_XSTATE_X87_MASK.
7996 * i386-tdep.h (tdesc_i386): Remove the declaration.
7997 (tdesc_i386_mmx): Likewise.
7998
d78bdb54
YQ
79992017-09-04 Yao Qi <yao.qi@linaro.org>
8000
8001 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
8002 X86_XSTATE_SSE_MASK instead of 0.
8003
ca1fa5ee
YQ
80042017-09-04 Yao Qi <yao.qi@linaro.org>
8005
8006 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
8007 i386_target_description.
8008 * i386-fbsd-nat.c (i386fbsd_read_description): Call
8009 i386_target_description.
8010 * i386-tdep.c (i386_gdbarch_init): Likewise.
8011
2434b019
YQ
80122017-09-04 Yao Qi <yao.qi@linaro.org>
8013
8014 * amd64-darwin-tdep.c: Include "x86-xstate.h".
8015 (x86_darwin_init_abi_64): Call amd64_target_description.
8016 * amd64-dicos-tdep.c: Likewise.
8017 * amd64-fbsd-nat.c: Likewise.
8018 * amd64-fbsd-tdep.c: Likewise.
8019 * amd64-nbsd-tdep.c: Likewise.
8020 * amd64-obsd-tdep.c: Likewise.
8021 * amd64-sol2-tdep.c: Likewise.
8022 * amd64-windows-tdep.c: Likewise.
8023 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
8024
0860c437
SM
80252017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8026
8027 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
8028 (btrace_function) <insn>: Change type to use std::vector.
8029 * btrace.c (ftrace_debug, ftrace_call_num_insn,
8030 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
8031 ftrace_update_insns, ftrace_compute_global_level_offset,
8032 btrace_stitch_bts, btrace_clear, btrace_insn_get,
8033 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
8034 change to std::vector.
8035 (ftrace_update_insns): Adjust to change to std::vector, change
8036 type of INSN parameter.
8037 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
8038 * record-btrace.c (btrace_call_history_insn_range,
8039 btrace_compute_src_line_range,
8040 record_btrace_frame_prev_register): Adjust to change to
8041 std::vector.
8042 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
8043 to change to std::vector.
8044
0638b7f9
TT
80452017-09-03 Tom Tromey <tom@tromey.com>
8046
8047 * corefile.c (reopen_exec_file): Use std::string.
8048
8f84fb0e
TT
80492017-09-03 Tom Tromey <tom@tromey.com>
8050
8051 * compile/compile.c (compile_register_name_mangled): Return
8052 std::string.
8053 * compile/compile-loc2c.c (pushf_register_address): Update.
8054 (pushf_register): Update.
8055 * compile/compile-c-types.c (convert_array): Update.
8056 * compile/compile-c-symbols.c (generate_vla_size): Update.
8057 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
8058 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
8059 (convert_one_symbol): Update.
8060 (generate_c_for_for_one_variable): Update.
8061 * compile/compile-c-support.c (c_get_range_decl_name): Return a
8062 std::string.
8063 (generate_register_struct): Update.
8064 * compile/compile-internal.h (c_get_range_decl_name): Return a
8065 std::string.
8066 (compile_register_name_mangled): Return std::string.
8067
18e9961f
TT
80682017-09-03 Tom Tromey <tom@tromey.com>
8069
8070 * utils.c (perror_string): Return a std::string.
8071 (throw_perror_with_name, perror_warning_with_name): Update.
8072
45343786
TT
80732017-09-03 Tom Tromey <tom@tromey.com>
8074
8075 * demangle.c (demangle_command): Use std::string,
8076 unique_xmalloc_ptr.
8077
b57af503
TT
80782017-09-03 Tom Tromey <tom@tromey.com>
8079
8080 * cli/cli-setshow.c (do_set_command): Use std::string.
8081
6eecf35f
TT
80822017-09-03 Tom Tromey <tom@tromey.com>
8083
8084 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
8085
56496dd4
TT
80862017-09-03 Tom Tromey <tom@tromey.com>
8087
8088 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
8089
e91a1fa7
TT
80902017-09-03 Tom Tromey <tom@tromey.com>
8091
8092 * mi/mi-cmd-env.c (env_execute_cli_command): Use
8093 gdb::unique_xmalloc_ptr.
8094
7ffd83d7
TT
80952017-09-03 Tom Tromey <tom@tromey.com>
8096
8097 * thread.c (print_thread_info_1): Use string_printf.
8098 (thread_apply_command, thread_apply_all_command): Use
8099 std::string.
8100
1ccbe998
TT
81012017-09-03 Tom Tromey <tom@tromey.com>
8102
8103 * valprint.c (val_print_string): Update.
8104 * gdbcore.h (memory_error_message): Return std::string.
8105 * corefile.c (memory_error_message): Return std::string.
8106 (memory_error): Update.
8107 * breakpoint.c (insert_bp_location): Update.
8108
23fdd69e
SM
81092017-09-03 Simon Marchi <simon.marchi@ericsson.com>
8110
8111 * target/waitstatus.h (target_waitstatus_to_string): Change
8112 return type to std::string.
8113 * target/waitstatus.c (target_waitstatus_to_string): Return
8114 std::string.
8115 * target.h (target_waitstatus_to_string): Remove declaration.
8116 * infrun.c (resume, clear_proceed_status_thread,
8117 print_target_wait_results, do_target_wait, save_waitstatus,
8118 stop_all_threads): Adjust.
8119 * record-btrace.c (record_btrace_wait): Adjust.
8120 * target-debug.h
8121 (target_debug_print_struct_target_waitstatus_p): Adjust.
8122
5c811d30
JK
81232017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
8124
8125 PR gdb/22046
8126 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
8127 detection.
8128
0a2dde4a
SDJ
81292017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
8130
8131 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
8132 for setting/unsetting environment variables on the remote target.
8133 (New remote packets): Add entries for QEnvironmentHexEncoded,
8134 QEnvironmentUnset and QEnvironmentReset.
8135 * common/environ.c (gdb_environ::operator=): Extend method to
8136 handle m_user_set_env_list and m_user_unset_env_list.
8137 (gdb_environ::clear): Likewise.
8138 (match_var_in_string): Change type of first parameter from 'char
8139 *' to 'const char *'.
8140 (gdb_environ::set): Extend method to handle
8141 m_user_set_env_list and m_user_unset_env_list.
8142 (gdb_environ::unset): Likewise.
8143 (gdb_environ::clear_user_set_env): New method.
8144 (gdb_environ::user_set_envp): Likewise.
8145 (gdb_environ::user_unset_envp): Likewise.
8146 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
8147 m_user_unset_env_list on move constructor/assignment.
8148 (unset): Add new default parameter 'update_unset_list = true'.
8149 (clear_user_set_env): New method.
8150 (user_set_envp): Likewise.
8151 (user_unset_envp): Likewise.
8152 (m_user_set_env_list): New std::set.
8153 (m_user_unset_env_list): Likewise.
8154 * common/rsp-low.c (hex2str): New function.
8155 (bin2hex): New overload for bin2hex function.
8156 * common/rsp-low.c (hex2str): New prototype.
8157 (str2hex): New overload prototype.
8158 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
8159 QEnvironmentUnset and QEnvironmentReset.
8160 (remote_protocol_features): Add QEnvironmentHexEncoded,
8161 QEnvironmentUnset and QEnvironmentReset packets.
8162 (send_environment_packet): New function.
8163 (extended_remote_environment_support): Likewise.
8164 (extended_remote_create_inferior): Call
8165 extended_remote_environment_support.
8166 (_initialize_remote): Add QEnvironmentHexEncoded,
8167 QEnvironmentUnset and QEnvironmentReset packet configs.
8168 * unittests/environ-selftests.c (gdb_selftest_env_var):
8169 New variable.
8170 (test_vector_initialization): New function.
8171 (test_init_from_host_environ): Likewise.
8172 (test_reinit_from_host_environ): Likewise.
8173 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
8174 Likewise.
8175 (test_unset_set_empty_vector): Likewise.
8176 (test_vector_clear): Likewise.
8177 (test_std_move): Likewise.
8178 (test_move_constructor):
8179 (test_self_move): Likewise.
8180 (test_set_unset_reset): Likewise.
8181 (run_tests): Rewrite in terms of the functions above.
8182
654670a4
WP
81832017-08-31 Weimin Pan <weimin.pan@oracle.com>
8184
8185 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
8186 (adi_available): Use a temp variable of type CORE_ADDR as argument
8187 3 when calling target_auxv_search.
8188 (adi_normalize_address): Use masks and xor operators to calculate
8189 normalized address.
8190 (adi_read_versions, adi_write_versions, adi_print_versions)
8191 (do_examine, do_assign): Use paddress.
8192
7755ddb7
JB
81932017-08-29 John Baldwin <jhb@FreeBSD.org>
8194
8195 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
8196 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
8197 out of loop and add supply of FIR.
8198 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
8199 add collect of FIR.
8200
fd437cbc
SM
82012017-08-28 Simon Marchi <simon.marchi@ericsson.com>
8202
3804a343 8203 PR gdb/21827
fd437cbc
SM
8204 * cli/cli-script.c (define_command): Don't convert command name
8205 to lower case.
8206
988f6b3d
JB
82072017-08-25 Joel Brobecker <brobecker@adacore.com>
8208
8209 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
8210 Update all callers accordingly. Remove all code blocks handling
8211 the case where DISPP is not NULL.
8212
663c44ac
JK
82132017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8214
8215 PR symtab/22003
8216 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
8217 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
8218 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
8219
f1902523
JK
82202017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8221
8222 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
8223 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
8224 (read_comp_units_from_section): New parameter abbrev_section, use
8225 read_and_check_comp_unit_head, allocate signatured_type if needed.
8226 (create_all_comp_units): Update read_comp_units_from_section caller.
8227
87215ad1
SDJ
82282017-08-23 Pedro Alves <palves@redhat.com>
8229
8230 PR remote/21852
8231 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
8232 to null_ptid and switch to thread without reading the registers
8233 after adding the inferior.
8234
6e41ddec
JK
82352017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
8236
8237 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
8238 compile-gcc.
8239 * compile/compile.c (compile_gcc, show_compile_gcc): New.
8240 (compile_to_object): Implement compile_gcc.
8241 (_initialize_compile): Install "set compile-gcc". Initialize
8242 compile_gcc.
8243
e68c32d5
JK
82442017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
8245
8246 * compile/compile.c (compile_to_object): Conditionally call
8247 set_verbose. Conditionally call compile or compile_v0.
8248
58afddc6
WP
82492017-08-07 Weimin Pan <weimin.pan@oracle.com>
8250
8251 * sparc64-tdep.h: (adi_normalize_address): New export.
8252 * sparc-nat.h: (open_adi_tag_fd): New export.
8253 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
8254 * sparc64-linux-tdep.c:
8255 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
8256 (sparc64_linux_handle_segmentation_fault): New function.
8257 (sparc64_linux_init_abi): Register
8258 sparc64_linux_handle_segmentation_fault
8259 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
8260 (sparc64_addr_bits_remove): New function.
8261 (sparc64_init_abi): Register sparc64_addr_bits_remove.
8262 (MAX_PROC_NAME_SIZE): New macro.
8263 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
8264 (sparc64adilist): New variable.
8265 (adi_proc_list): New variable.
8266 (find_adi_info): New function.
8267 (add_adi_info): New function.
8268 (get_adi_info_proc): New function.
8269 (get_adi_info): New function.
8270 (info_adi_command): New function.
8271 (read_maps_entry): New function.
8272 (adi_available): New function.
8273 (adi_normalize_address): New function.
8274 (adi_align_address): New function.
8275 (adi_convert_byte_count): New function.
8276 (adi_tag_fd): New function.
8277 (adi_is_addr_mapped): New function.
8278 (adi_read_versions): New function.
8279 (adi_write_versions): New function.
8280 (adi_print_versions): New function.
8281 (do_examine): New function.
8282 (do_assign): New function.
8283 (adi_examine_command): New function.
8284 (adi_assign_command): New function.
8285 (_initialize_sparc64_adi_tdep): New function.
8286
11db9430
SM
82872017-08-22 Simon Marchi <simon.marchi@ericsson.com>
8288
8289 * breakpoint.c (breakpoints_info): Rename to ...
8290 (info_breakpoints_command): ... this.
8291 (watchpoints_info): Rename to ...
8292 (info_watchpoints_command): ... this.
8293 (tracepoints_info): Rename to ...
8294 (info_tracepoints_command): ... this.
8295 (_initialize_breakpoint): Adjust.
8296 * dcache.c (dcache_info): Rename to ...
8297 (info_display_command): ... this.
8298 (_initialize_dcache): Adjust.
8299 * frame.h (args_info): Rename to ...
8300 (info_args_command): ... this.
8301 (locals_info): Rename to ...
8302 (info_locals_command): ... this.
8303 * infcmd.c (nofp_registers_info): Rename to ...
8304 (info_registers_command): ... this.
8305 (float_info): Rename to ...
8306 (info_float_command): ... this.
8307 (program_info): Rename to ...
8308 (info_program_command): ... this.
8309 (all_registers_info): Rename to ...
8310 (info_all_registers_command): ... this.
8311 (vector_info): Rename to ...
8312 (info_vector_command): ... this.
8313 (float_info): Rename to ...
8314 (info_float_command): ... this.
8315 (_initialize_infcmd): Adjust.
8316 * inferior.h (term_info): Rename to ...
8317 (info_terminal_command): ... this.
8318 * inflow.c (term_info): Rename to ...
8319 (info_terminal_command): ... this.
8320 (_initialize_inflow): Adjust.
8321 * infrun.c (signals_info): Rename to ...
8322 (info_signals_command): ... this.
8323 (_initialize_infrun): Adjust.
8324 * objc-lang.c (classes_info): Rename to ...
8325 (info_classes_command): ... this.
8326 (selectors_info): Rename to ...
8327 (info_selectors_command): ... this.
8328 (_initialize_objc_language): Adjust.
8329 * printcmd.c (sym_info): Rename to ...
8330 (info_symbol_command): ... this.
8331 (address_info): Rename to ...
8332 (info_address_command): ... this.
8333 (display_info): Rename to ...
8334 (info_display_command): ... this.
8335 (_initialize_printcmd): Adjust.
8336 * reverse.c (bookmarks_info): Rename to ...
8337 (info_breakpoints_command): ... this.
8338 (_initialize_reverse): Adjust.
8339 * ser-go32.c (dos_info): Rename to ...
8340 (info_serial_command): ... this.
8341 (_initialize_ser_dos): Adjust.
8342 * skip.c (skip_info): Rename to ...
8343 (info_skip_command): ... this.
8344 (_initialize_step_skip): Adjust.
8345 * source.c (line_info): Rename to ...
8346 (info_line_command): ... this.
8347 (source_info): Rename to ...
8348 (info_source_command)
8349 * stack.c (frame_info): Rename to ...
8350 (info_frame_command): ... this.
8351 (locals_info): Rename to ...
8352 (info_locals_command): ... this.
8353 (args_info): Rename to ...
8354 (info_args_command): ... this.
8355 (_initialize_stack): Adjust.
8356 * symtab.c (sources_info): Rename to ...
8357 (info_sources_command): ... this.
8358 (variables_info): Rename to ...
8359 (info_variables_command): ... this.
8360 (functions_info): Rename to ...
8361 (info_functions_command): ... this.
8362 (types_info): Rename to ...
8363 (info_types_command): ... this.
8364 (_initialize_symtab): Adjust.
8365 * target.c (target_info): Rename to ...
8366 (info_target_command): ... this.
8367 (initialize_targets): Adjust.
8368 * tracepoint.c (tvariables_info): Rename to ...
8369 (info_tvariables_command): ... this.
8370 (scope_info): Rename to ...
8371 (info_scope_command): ... this.
8372 (trace_dump_actions): Adjust.
8373 (_initialize_tracepoint): Adjust.
8374
b270e6f9
TT
83752017-08-22 Tom Tromey <tom@tromey.com>
8376
8377 * breakpoint.h (install_breakpoint): Update.
8378 * breakpoint.c (add_solib_catchpoint): Update.
8379 (install_breakpoint): Change argument to a std::unique_ptr.
8380 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
8381 (create_breakpoint_sal, create_breakpoint): Update.
8382 (watch_command_1, catch_exec_command_1)
8383 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
8384 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
8385 Return the breakpoint.
8386 (set_raw_breakpoint_without_location, set_raw_breakpoint)
8387 (new_single_step_breakpoint): Update.
8388 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
8389 std::unique_ptr.
8390 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
8391 std::unique_ptr.
8392 * break-catch-sig.c (create_signal_catchpoint): Use
8393 std::unique_ptr.
8394 * ada-lang.c (create_ada_exception_catchpoint): Use
8395 std::unique_ptr.
8396
36bd8eaa
TT
83972017-08-22 Tom Tromey <tom@tromey.com>
8398
8399 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
8400
56f37645
TT
84012017-08-22 Tom Tromey <tom@tromey.com>
8402
8403 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
8404 (lookup_partial_symbol): Update.
8405
0b581c69
TT
84062017-08-22 Tom Tromey <tom@tromey.com>
8407
8408 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
8409 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
8410 (find_and_open_source, symtab_to_fullname): Update.
8411 * psymtab.c (psymtab_to_fullname): Update.
8412
14278e1f
TT
84132017-08-22 Tom Tromey <tom@tromey.com>
8414
8415 * exec.c (exec_file_attach): Update.
8416 * linux-thread-db.c (try_thread_db_load): Update.
8417 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
8418 * utils.c (gdb_realpath): Change return type.
8419 (gdb_realpath_keepfile): Update.
8420 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
8421 (_initialize_utils): Register the new self test.
8422 * source.c (openp): Update.
8423 (find_and_open_source): Update.
8424 * nto-tdep.c (nto_find_and_open_solib): Update.
8425 * main.c (set_gdb_data_directory): Update.
8426 (captured_main_1): Update.
8427 * dwarf2read.c (dwarf2_get_dwz_file): Update
8428 (dw2_map_symbol_filenames): Update.
8429 * auto-load.c (auto_load_safe_path_vec_update): Update.
8430 (filename_is_in_auto_load_safe_path_vec): Change type of
8431 "filename_realp".
8432 (auto_load_objfile_script): Update.
8433 (file_is_auto_load_safe): Update. Use std::string.
8434 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
8435
4971c9a7
TT
84362017-08-22 Tom Tromey <tom@tromey.com>
8437
8438 * utils.c (gdb_realpath_keepfile): Return a
8439 gdb::unique_xmalloc_ptr.
8440 * exec.c (exec_file_attach): Update.
8441 * utils.h (gdb_realpath_keepfile): Return a
8442 gdb::unique_xmalloc_ptr.
8443
e3e41d58
TT
84442017-08-22 Tom Tromey <tom@tromey.com>
8445
8446 * compile/compile.c (compile_file_command): Use
8447 gdb::unique_xmalloc_ptr, std::string.
8448 * utils.c (gdb_abspath): Change return type.
8449 * source.c (openp): Update.
8450 * objfiles.c (allocate_objfile): Update.
8451 * main.c (set_gdb_data_directory): Update.
8452 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
8453
0d999a6e
ZZ
84542017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
8455
8456 * cli-cmds.c (list_commands): List actual code around more than
8457 one location.
8458
329d5e7e
JB
84592017-08-21 John Baldwin <jhb@FreeBSD.org>
8460
8461 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
8462
bf223d3e
PA
84632017-08-21 Pedro Alves <palves@redhat.com>
8464
8465 PR gdb/19487
8466 * c-exp.y (variable production): Handle function aliases.
8467 * minsyms.c (msymbol_is_text): New function.
8468 * minsyms.h (msymbol_is_text): Declare.
8469 * symtab.c (find_function_alias_target): New function.
8470 * symtab.h (find_function_alias_target): Declare.
8471
c973d0aa
PA
84722017-08-21 Pedro Alves <palves@redhat.com>
8473
8474 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
8475 typedefs.
8476 * typeprint.c (whatis_exp): If handling "whatis", and expression
8477 is OP_TYPE, strip one typedef level. Otherwise don't strip
8478 typedefs here.
8479 * valops.c (value_cast): Save "to" type before resolving
8480 stubs/typedefs. Use that type as resulting value's type.
8481
2989a365
TT
84822017-08-18 Tom Tromey <tom@tromey.com>
8483 Pedro Alves <palves@redhat.com>
8484
8485 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
8486 * sol-thread.c (sol_thread_resume, sol_thread_wait)
8487 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
8488 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
8489 * proc-service.c (ps_xfer_memory): Use scoped_restore.
8490 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
8491 (linux_get_siginfo_data): Add "thread" argument. Use
8492 scoped_restore.
8493 * linux-nat.c (linux_child_follow_fork)
8494 (check_stopped_by_watchpoint): Use scoped_restore.
8495 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
8496 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
8497 (restore_inferior_ptid, save_inferior_ptid): Remove.
8498 * btrace.c (btrace_fetch): Use scoped_restore.
8499 * bsd-uthread.c (bsd_uthread_fetch_registers)
8500 (bsd_uthread_store_registers): Use scoped_restore.
8501 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
8502 scoped_restore.
8503 * aix-thread.c (aix_thread_resume, aix_thread_wait)
8504 (aix_thread_xfer_partial): Use scoped_restore.
8505 * inferior.h (save_inferior_ptid): Remove.
8506
e60eb288
YQ
85072017-08-18 Yao Qi <yao.qi@linaro.org>
8508
8509 PR tdep/21818
8510 * arm-tdep.c (gdb_print_insn_arm): Mark
8511 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
8512
6d580b63
YQ
85132017-08-18 Yao Qi <yao.qi@linaro.org>
8514
8515 * NEWS: Mention GDBserver's new option "--selftest".
8516 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
8517 * selftest.c: Move it to common/selftest.c.
8518 * selftest.h: Move it to common/selftest.h.
8519 * selftest-arch.c (reset): New function.
8520 (tests_with_arch): Call reset.
8521
86dcbf50
YQ
85222017-08-18 Yao Qi <yao.qi@linaro.org>
8523
8524 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
8525 instead of exception_fprintf and printf_filtered.
8526
7649770c
YQ
85272017-08-18 Yao Qi <yao.qi@linaro.org>
8528
8529 * selftest.c (register_self_test): Rename it to
8530 selftests::register_test.
8531 (run_self_tests): selftest::run_tests.
8532 * selftest.h: Update declarations.
8533 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
8534 selftests::register_test_foreach_arch.
8535 * selftest-arch.h: Update declaration.
8536 * aarch64-tdep.c: Update.
8537 * arm-tdep.c: Likewise.
8538 * disasm-selftests.c: Likewise.
8539 * dwarf2loc.c: Likewise.
8540 * dwarf2-frame.c: Likewise.
8541 * findvar.c: Likewise.
8542 * gdbarch-selftests.c: Likewise.
8543 * maint.c (maintenance_selftest): Likewise.
8544 * regcache.c: Likewise.
8545 * rust-exp.y: Likewise.
8546 * selftest-arch.c: Likewise.
8547 * unittests/environ-selftests.c: Likewise.
8548 * unittests/function-view-selftests.c: Likewise.
8549 * unittests/offset-type-selftests.c: Likewise.
8550 * unittests/optional-selftests.c: Likewise.
8551 * unittests/scoped_restore-selftests.c: Likewise.
8552 * utils-selftests.c: Likewise.
8553
b0cba12e
PA
85542017-08-17 Pedro Alves <palves@redhat.com>
8555
8556 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
8557 local.
8558
4c8aa72d
PA
85592017-08-17 Pedro Alves <palves@redhat.com>
8560
8561 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
8562 field.
8563 (reset_die_in_process): Delete, replaced by ...
8564 (process_die_scope): ... this new class. Make it responsible for
8565 freeing cu->line_header too.
8566 (process_die): Use process_die_scope.
8567 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
8568 cu->line_header_die_owner. Don't release the line header if it's
8569 owned by the CU.
8570 (setup_type_unit_groups): Make the CU/DIE own the line header.
8571 Don't release the line header here.
8572
ba713918
AL
85732017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
8574
8575 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
8576
44d0fb3a
RK
85772017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
8578
8579 * NEWS: Mention new shortcuts for nexti and stepi in TUI
8580 Single-Key mode
8581
a5afdb16
RK
85822017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
8583
8584 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
8585 mode command list.
8586
47613aeb
SH
85872017-08-15 Stafford Horne <shorne@gmail.com>
8588
8589 * MAINTAINERS (Write After Approval): Add Stafford Horne.
8590
9c3cc999
SH
85912017-08-15 Stafford Horne <shorne@gmail.com>
8592
8593 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
8594
206726fb
SDJ
85952017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
8596
8597 PR gdb/21954
8598 * infcmd.c (unset_environment_command): Use the 'clear' method on
8599 the environment instead of resetting it.
8600
0335ac6d
JB
86012017-08-15 John Baldwin <jhb@FreeBSD.org>
8602
8603 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
8604 platforms.
8605
d3abe1c8
TT
86062017-08-14 Tom Tromey <tom@tromey.com>
8607
8608 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
8609 (print_binary_chars): Likewise.
8610 (BITS_IN_BYTES): Remove.
8611
d6382fff
TT
86122017-08-14 Tom Tromey <tom@tromey.com>
8613
8614 PR gdb/21675
8615 * valprint.c (LOW_ZERO): Change value to 034.
8616 (print_octal_chars): Add static_asserts for octal constants.
8617 * printcmd.c (print_scalar_formatted): Add 'd' case.
8618
f978cb06
TT
86192017-08-11 Tom Tromey <tom@tromey.com>
8620
8621 * symfile.c (add_symbol_file_command): Use std::vector.
8622
2f5404b3
TT
86232017-08-14 Tom Tromey <tom@tromey.com>
8624
8625 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
8626 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
8627 std::move.
8628 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
8629
de7985c3
PA
86302017-08-11 Pedro Alves <palves@redhat.com>
8631
8632 * infrun.c (process_event_stop_test): Adjust
8633 function_name_is_marked_for_skip call.
8634 * skip.c: Include <list>.
8635 (skiplist_entry): Make it a class with private fields, and
8636 getters/setters.
8637 (skiplist_entry_chain): Delete.
8638 (skiplist_entries): New.
8639 (skiplist_entry_count): Delete.
8640 (highest_skiplist_entry_num): New.
8641 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
8642 (add_skiplist_entry): Delete.
8643 (skiplist_entry::skiplist_entry): New.
8644 (skiplist_entry::add_entry): New.
8645 (skip_file_command, skip_function): Adjust.
8646 (compile_skip_regexp): Delete.
8647 (skip_command): Don't compile regexp here. Adjust to use
8648 skiplist_entry::add_entry.
8649 (skip_info): Adjust to use range-for and getters.
8650 (skip_enable_command, skip_disable_command): Adjust to use
8651 range-for and setters.
8652 (skip_delete_command): Adjust to use std::list.
8653 (add_skiplist_entry): Delete.
8654 (skip_file_p): Delete, refactored as ...
8655 (skiplist_entry::do_skip_file_p): ... this new method.
8656 (skip_gfile_p): Delete, refactored as ...
8657 (skiplist_entry::do_gskip_file_p): ... this new method.
8658 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
8659 (skiplist_entry::skip_function_p): ... this new method.
8660 (function_name_is_marked_for_skip): Now returns bool, and takes
8661 the function sal by const reference. Adjust to use range-for and
8662 skiplist_entry methods.
8663 (_initialize_step_skip): Remove references to
8664 skiplist_entry_chain, skiplist_entry_count.
8665 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
8666 takes the function sal by const reference.
8667
be7d3cd5
YQ
86682017-08-11 Yao Qi <yao.qi@linaro.org>
8669
8670 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
8671 (dwarf2_frame_cache): Remove reset_cache_cleanup.
8672 (dwarf2_frame_cache):
8673 * frame-unwind.c (frame_unwind_try_unwinder): Catch
8674 RETURN_MASK_ALL and set *this_case to NULL.
8675 * frame-unwind.h: Update comments.
8676
1c90d9f0
YQ
86772017-08-11 Yao Qi <yao.qi@linaro.org>
8678
8679 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
8680 (dwarf2_frame_state_copy_regs): Remove.
8681 (dwarf2_frame_state_free_regs): Remove.
8682 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
8683 (dwarf2_restore_rule): Call method .alloc_regs instead of
8684 dwarf2_frame_state_alloc_regs.
8685 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
8686 constructor. Call std::move.
8687 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
8688 (dwarf2_frame_cache): Likewise.
8689
8690 [GDB_SELF_TEST]: Include selftest.h and
8691 selftest-arch.h.
8692 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
8693 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
8694 execute_cfa_program_test.
8695
8696 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
8697 copy ctor, assignment operator, move assignment.
8698 <alloc_regs>: New method.
8699 <swap>: New method.
8700 (struct dwarf2_frame_state): Delete dtor.
8701 (dwarf2_frame_state_alloc_regs): Remove declaration.
8702 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
8703 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
8704
afe37d6b
YQ
87052017-08-11 Yao Qi <yao.qi@linaro.org>
8706
8707 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
8708 (dwarf2_frame_state::dwarf2_frame_state): New.
8709 (dwarf2_frame_state::~dwarf2_frame_state): New.
8710 (dwarf2_fetch_cfa_info): Update.
8711 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
8712 rather than a pointer. Update code.
8713 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
8714 dtor.
8715 <data_align, code_align, retaddr_column>: Change them to const.
8716 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
8717 to bool.
8718
b348037f
YQ
87192017-08-11 Yao Qi <yao.qi@linaro.org>
8720
8721 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
8722 <loc.exp>: New field.
8723 * dwarf2-frame.c (execute_cfa_program): Update.
8724 (dwarf2_frame_prev_register): Update.
8725
e7c9de26
PA
87262017-08-10 Pedro Alves <palves@redhat.com>
8727
8728 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
8729
e8c6b620
JB
87302017-08-09 John Baldwin <jhb@FreeBSD.org>
8731
8732 * fbsd-nat.c (struct fbsd_fork_info): Remove.
8733 (fbsd_pending_children): Use std::list.
8734 (fbsd_remember_child): Likewise.
8735 (fbsd_is_child_pending): Likewise.
8736 (fbsd_pending_vfork_done): Use std::forward_list.
8737 (fbsd_add_vfork_done): Likewise.
8738 (fbsd_is_vfork_done_pending): Likewise.
8739 (fbsd_next_vfork_done): Likewise.
8740
e4a26669
JB
87412017-08-09 John Baldwin <jhb@FreeBSD.org>
8742
8743 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
8744 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
8745 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
8746 for `mapfilename'.
8747 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 8748 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 8749
142311d3
JB
87502017-08-09 John Baldwin <jhb@FreeBSD.org>
8751
8752 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
8753 "filestuff.h".
8754 (fbsd_find_memory_regions): Fix `mapfile' initialization.
8755
42fa2e0e
TT
87562017-08-09 Tom Tromey <tom@tromey.com>
8757
8758 * skip.c (skiplist_entry): New constructor.
8759 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
8760 (skiplist_entry::file_is_glob): Now bool.
8761 (skiplist_entry::file, skiplist_entry::function): Now
8762 std::string.
8763 (make_skip_entry): Return a unique_ptr. Use new.
8764 (free_skiplist_entry, free_skiplist_entry_cleanup)
8765 (make_free_skiplist_entry_cleanup): Remove.
8766 (skip_command, skip_disable_command, add_skiplist_entry)
8767 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
8768 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
8769 (function_name_is_marked_for_skip): Update.
8770 (skip_delete_command): Update. Use delete.
8771
cd3af38d
JW
87722017-08-09 Jiong Wang <jiong.wang@arm.com>
8773
8774 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
8775 (aarch64_linux_core_read_description): New function.
8776 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
8777
29592bde
PA
87782017-08-09 Pedro Alves <palves@redhat.com>
8779
8780 * cp-name-parser.y (cp_comp_to_string): Return a
8781 gdb::unique_xmalloc_ptr<char>.
8782 * cp-support.c (replace_typedefs_qualified_name)
8783 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
8784 (cp_canonicalize_string_full): Use op= instead of explicit
8785 convertion.
8786 (cp_class_name_from_physname, method_name_from_physname)
8787 (cp_func_name, cp_remove_params): Adjust to use
8788 gdb::unique_xmalloc_ptr<char>.
8789 * cp-support.h (cp_comp_to_string): Return a
8790 gdb::unique_xmalloc_ptr<char>.
8791 * python/py-type.c (typy_lookup_type): Adjust to use
8792 gdb::unique_xmalloc_ptr<char>.
8793
b3340438
L
87942017-08-09 H.J. Lu <hongjiu.lu@intel.com>
8795
8796 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
8797
e88e8651
YQ
87982017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
8799 Yao Qi <yao.qi@linaro.org>
8800
8801 * cp-support.c (cp_canonicalize_string_full): Use
8802 gdb::unique_xmalloc_ptr<char>.
8803 (cp_canonicalize_string): Likewise.
8804
f5a29eb0
YQ
88052017-08-09 Yao Qi <yao.qi@linaro.org>
8806
8807 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
8808 * regformats/i386/amd64-avx-avx512.dat: Remove.
8809 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
8810 * regformats/i386/amd64-avx-mpx.dat:Remove.
8811 * regformats/i386/amd64-avx.dat: Remove.
8812 * regformats/i386/amd64-mpx.dat: Remove.
8813 * regformats/i386/i386-avx-avx512.dat: Remove.
8814 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
8815 * regformats/i386/i386-avx-mpx.dat: Remove.
8816 * regformats/i386/i386-mmx.dat: Remove.
8817 * regformats/i386/i386-mpx.dat: Remove.
8818
57757c2f
YQ
88192017-08-09 Yao Qi <yao.qi@linaro.org>
8820
8821 * amd64-tdep.h (tdesc_x32): Remove the declaration.
8822 * amd64-tdep.c: Don't include features/i386/x32*.c.
8823 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
8824 functions.
8825 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
8826 and i386/x32-avx-avx512.
8827 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
8828 and i386/x32.xml.
8829 * features/i386/x32-avx-avx512.c: Removed.
8830 * features/i386/x32-avx-avx512.xml: Removed.
8831 * features/i386/x32-avx.c: Removed.
8832 * features/i386/x32-avx.xml: Removed.
8833 * features/i386/x32.c: Removed.
8834 * features/i386/x32.xml: Removed.
8835 * regformats/i386/x32-avx-avx512.dat: Removed.
8836 * regformats/i386/x32-avx.dat: Removed.
8837 * regformats/i386/x32.dat: Removed.
8838
ba7b109b
MR
88392017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8840
8841 PR breakpoints/21886
8842 * mem-break.c (default_memory_insert_breakpoint): Use
8843 `->placed_address' rather than `->reqstd_address' for the
8844 breakpoint location.
8845
e347efc3
MR
88462017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8847
8848 * arch-utils.c (default_print_insn): Remove arch/mach/endian
8849 assertions.
8850
0dba2a6c
MR
88512017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8852
8853 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
8854 a union of `tdep_info', `tdesc_data' and `id'.
8855 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
8856 rather than `info.tdep_info'.
8857 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
8858 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
8859 * i386-tdep.c (i386_gdbarch_init): Likewise.
8860 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
8861 * mips-tdep.c (mips_gdbarch_init): Likewise.
8862 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8863 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
8864 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
8865 `info.tdep_info'.
8866 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
8867 `info.tdep_info'.
8868 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8869 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
8870 `info.tdep_info'.
8871 * spu-tdep.c (spu_gdbarch_init): Likewise.
8872 * gdbarch.h: Regenerate.
8873
16eb6b2d
LS
88742017-08-07 Leszek Swirski <leszeks@google.com>
8875
7b005726 8876 PR symtab/20899
16eb6b2d
LS
8877 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
8878
74cbb09e
SM
88792017-08-07 Simon Marchi <simon.marchi@ericsson.com>
8880
8881 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
8882 (gdbsim_open): Rename gdb_argv args object to argv.
8883
ee0c3293
TT
88842017-08-05 Tom Tromey <tom@tromey.com>
8885
8886 * compile/compile-object-load.c (compile_object_load): Use
8887 gdb::unique_xmalloc_ptr.
8888 * cli/cli-dump.c (scan_filename): Rename from
8889 scan_filename_with_cleanup. Change return type.
8890 (scan_expression): Rename from scan_expression_with_cleanup.
8891 Change return type.
8892 (dump_memory_to_file, dump_value_to_file, restore_command):
8893 Use gdb::unique_xmalloc_ptr. Update.
8894 * cli/cli-cmds.c (find_and_open_script): Use
8895 gdb::unique_xmalloc_ptr.
8896 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
8897 * symmisc.c (maintenance_print_symbols)
8898 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
8899 * symfile.c (symfile_bfd_open, generic_load)
8900 (add_symbol_file_command, remove_symbol_file_command): Use
8901 gdb::unique_xmalloc_ptr.
8902 * source.c (openp): Use gdb::unique_xmalloc_ptr.
8903 * psymtab.c (maintenance_print_psymbols): Use
8904 gdb::unique_xmalloc_ptr.
8905 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
8906 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
8907 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
8908 (reload_shared_libraries_1): Likewise.
8909
3232fabd
TT
89102017-08-05 Tom Tromey <tom@tromey.com>
8911
8912 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
8913 (rust_op_vector, rust_set_vector): New typedefs.
8914 (current_parser): New global.
8915 (work_obstack): Change to pointer type. Update all users.
8916 (rust_ast, pstate): Remove globals.
8917 (struct rust_parser): New.
8918 (%union) <params, field_inits>: Change type.
8919 (start, tuple_expr, unit_expr, struct_expr_list, literal)
8920 (field_expr, expr_list, maybe_expr_list, type_list): Update.
8921 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
8922 (convert_params_to_types, convert_params_to_expression): Change
8923 type of "params".
8924 (ast_string): Change type of "fields".
8925 (rust_parse): Make a rust_parser. Remove cleanups.
8926 (rust_lex_tests): Make and install an auto_obstack.
8927
f02fd774
YQ
89282017-08-04 Yao Qi <yao.qi@linaro.org>
8929
8930 * configure.srv (ipa_x32_linux_regobj): New.
8931 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
8932 instead of X86_TDESC_AVX512.
8933 (initialize_low_tracepoint): Call
8934 init_registers_x32_avx_avx512_linux.
8935
91975afd
YQ
89362017-08-04 Yao Qi <yao.qi@linaro.org>
8937
8938 * utils.h (gdb_argv): Add namespace std for nullptr_t.
8939
2331fa3a
RK
89402017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
8941
8942 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
8943
744e4fe1
TT
89442017-08-03 Tom Tromey <tom@tromey.com>
8945
8946 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
8947 Remove.
8948 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
8949
1c034b67
TT
89502017-08-03 Tom Tromey <tom@tromey.com>
8951
8952 * python/py-param.c (compute_enum_values): Use gdb_argv.
8953
773a1edc
TT
89542017-08-03 Tom Tromey <tom@tromey.com>
8955
8956 * utils.h (struct gdb_argv_deleter): New.
8957 (gdb_argv): New class.
8958 * utils.c (gdb_argv::reset): New method.
8959 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
8960 * tracefile.c (tsave_command): Use gdb_argv.
8961 * top.c (new_ui_command): Use gdb_argv.
8962 * symmisc.c (maintenance_print_symbols)
8963 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
8964 * symfile.c (symbol_file_command, generic_load)
8965 (remove_symbol_file_command): Use gdb_argv.
8966 * stack.c (backtrace_command): Use gdb_argv.
8967 * source.c (add_path, show_substitute_path_command)
8968 (unset_substitute_path_command, set_substitute_path_command):
8969 Use gdb_argv.
8970 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
8971 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
8972 * remote.c (extended_remote_run, remote_put_command)
8973 (remote_get_command, remote_delete_command): Use gdb_argv.
8974 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
8975 (gdbsim_open): Use gdb_argv.
8976 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
8977 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
8978 * procfs.c (procfs_info_proc): Use gdb_argv.
8979 * interps.c (interpreter_exec_cmd): Use gdb_argv.
8980 * infrun.c (handle_command): Use gdb_argv.
8981 * inferior.c (add_inferior_command, clone_inferior_command):
8982 Use gdb_argv.
8983 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
8984 * exec.c (exec_file_command): Use gdb_argv.
8985 * cli/cli-cmds.c (alias_command): Use gdb_argv.
8986 * compile/compile.c (build_argc_argv): Use gdb_argv.
8987
0d50bde3
TT
89882017-08-03 Tom Tromey <tom@tromey.com>
8989
8990 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
8991
7f968c89
TT
89922017-08-03 Tom Tromey <tom@tromey.com>
8993
8994 * python/python.c (compute_python_string): Return std::string.
8995 (gdbpy_eval_from_control_command): Update.
8996 (do_start_initialization): Use std::string.
8997 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
8998 xstrprintf.
8999 * python/py-breakpoint.c (local_setattro): Use string_printf, not
9000 xstrprintf.
9001
3c9ebddd
TT
90022017-08-03 Tom Tromey <tom@tromey.com>
9003
9004 * top.h (do_restore_instream_cleanup): Remove.
9005 * top.c (do_restore_instream_cleanup): Remove.
9006 (read_command_file): Use scoped_restore.
9007 * cli/cli-script.c (execute_user_command): Use scoped_restore.
9008
b51b225e
TT
90092017-08-03 Tom Tromey <tom@tromey.com>
9010
9011 * cli/cli-script.c (execute_user_command)
9012 (execute_control_command): Use scoped_restore.
9013
ac991630
TT
90142017-08-03 Tom Tromey <tom@tromey.com>
9015
9016 * cli/cli-script.c (do_restore_user_call_depth): Remove.
9017 (execute_user_command): Remove user_call_depth; use
9018 user_args_stack's size instead.
9019
898e0c8e
TT
90202017-08-03 Tom Tromey <tom@tromey.com>
9021
9022 * top.h (in_user_command): Remove.
9023 * top.c (in_user_command): Remove.
9024 * cli/cli-script.c (do_restore_user_call_depth)
9025 (execute_user_command): Update.
9026
26fcd5d7
TT
90272017-08-03 Tom Tromey <tom@tromey.com>
9028
9029 * valops.c (search_struct_method): Use gdb::byte_vector.
9030 * valarith.c (value_concat): Use std::vector.
9031 * target.c (memory_xfer_partial): Use gdb::byte_vector.
9032 (simple_search_memory): Likewise.
9033 * printcmd.c (find_string_backward): Use gdb::byte_vector.
9034 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
9035 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
9036 * elfread.c (elf_rel_plt_read): Use std::string.
9037 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
9038 * cli/cli-dump.c (restore_section_callback): Use
9039 gdb::byte_vector.
9040
7c218e6c
TT
90412017-08-03 Tom Tromey <tom@tromey.com>
9042
9043 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
9044
31b68d4a
TT
90452017-08-03 Tom Tromey <tom@tromey.com>
9046
9047 * tui/tui-regs.c (tui_restore_gdbout): Remove.
9048 (tui_register_format): Use scoped_restore.
9049
2ec845e7
TT
90502017-08-03 Tom Tromey <tom@tromey.com>
9051
9052 * reverse.c (exec_direction_default): Remove.
9053 (exec_reverse_once): Use scoped_restore.
9054 * remote.c (restore_remote_timeout): Remove.
9055 (remote_flash_erase, remote_flash_write, remote_flash_done)
9056 (readchar, remote_serial_write): Use scoped_restore.
9057 * cli/cli-script.c (struct source_cleanup_lines_args)
9058 (source_cleanup_lines): Remove.
9059 (script_from_file): Use scoped_restore.
9060 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
9061 (source_command): Use scoped_restore.
9062
b3bc8453
TT
90632017-08-03 Tom Tromey <tom@tromey.com>
9064
9065 * utils.h (make_cleanup_free_so): Remove.
9066 * utils.c (do_free_so, make_cleanup_free_so): Remove.
9067 * solist.h (struct so_deleter): New.
9068 (so_list_up): New typedef.
9069 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
9070
e3ad2841
TT
90712017-08-03 Tom Tromey <tom@tromey.com>
9072
9073 * utils.h (make_cleanup_restore_current_language): Remove.
9074 * utils.c (do_restore_current_language)
9075 (make_cleanup_restore_current_language): Remove.
9076 * parse.c (parse_exp_in_context_1)
9077 (parse_expression_with_language): Use
9078 scoped_restore_current_language.
9079 * mi/mi-main.c (mi_cmd_execute): Use
9080 scoped_restore_current_language.
9081 * language.h (scoped_restore_current_language): New class.
9082
b80cf838
TT
90832017-08-03 Tom Tromey <tom@tromey.com>
9084
9085 * compile/compile.c (cleanup_unlink_file): Remove.
9086 (compile_to_object): Use gdb::unlinker.
9087 (eval_compile_command): Likewise.
9088
fad0444a
TT
90892017-08-03 Tom Tromey <tom@tromey.com>
9090
9091 * utils.h (make_cleanup_fclose): Remove.
9092 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
9093
6e7bc05c
TT
90942017-08-03 Tom Tromey <tom@tromey.com>
9095
9096 * top.c (open_terminal_stream): Return gdb_file_up.
9097 (new_ui_command): Update.
9098
4a45905b
TT
90992017-08-03 Tom Tromey <tom@tromey.com>
9100
9101 * source.c (print_source_lines_base, forward_search_command)
9102 (reverse_search_command): Use gdb_file_up.
9103
7cd06d6e
TT
91042017-08-03 Tom Tromey <tom@tromey.com>
9105
9106 * fbsd-nat.c (fbsd_find_memory_regions): Update.
9107
ed166945
TT
91082017-08-03 Tom Tromey <tom@tromey.com>
9109
9110 * cli/cli-cmds.c (find_and_open_script): Change return type.
9111 Remove "streamp" and "full_path" parameters.
9112 (source_script_with_search): Update.
9113 * auto-load.c (source_script_file): Update.
9114 * cli/cli-cmds.h (find_and_open_script): Change type.
9115 (open_script): New struct.
9116
d419f42d
TT
91172017-08-03 Tom Tromey <tom@tromey.com>
9118
9119 * xml-support.c (xml_fetch_content_from_file): Update.
9120 * ui-file.c (stdio_file::open): Update.
9121 * tracefile-tfile.c (tfile_start): Update.
9122 * remote.c (remote_file_put, remote_file_get): Update.
9123 * nat/linux-procfs.c (linux_proc_get_int)
9124 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
9125 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
9126 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
9127 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
9128 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
9129 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
9130 * linux-nat.c (linux_proc_pending_signals): Update.
9131 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
9132 (file_closer): Remove.
9133 * compile/compile.c (compile_to_object): Update.
9134 * common/filestuff.h (struct gdb_file_deleter): New.
9135 (gdb_file_up): New typedef.
9136 (gdb_fopen_cloexec): Change return type.
9137 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
9138 * cli/cli-dump.c (fopen_with_cleanup): Remove.
9139 (dump_binary_file, restore_binary_file): Update.
9140 * auto-load.c (auto_load_objfile_script_1): Update.
9141
4a2b031d
TT
91422017-08-03 Tom Tromey <tom@tromey.com>
9143
9144 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
9145 (info_static_tracepoint_markers_command): Likewise.
9146 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
9147 * skip.c (skip_info): Use ui_out_emit_table.
9148 * progspace.c (print_program_space): Use ui_out_emit_table.
9149 * osdata.c (info_osdata): Use ui_out_emit_table.
9150 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
9151 ui_out_emit_table.
9152 * linux-thread-db.c (info_auto_load_libthread_db): Use
9153 ui_out_emit_table.
9154 * inferior.c (print_inferior): Use ui_out_emit_table.
9155 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
9156 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
9157 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
9158 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
9159 * ui-out.h (class ui_out_emit_table): New.
9160
a4f320fd
MR
91612017-08-02 Maciej W. Rozycki <macro@imgtec.com>
9162
9163 * mips-tdep.c (mips_fpu_type_str): New function.
9164 (mips_dump_tdep): Call it.
9165
a2f1f308
MR
91662017-08-01 Maciej W. Rozycki <macro@imgtec.com>
9167
9168 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
9169 `->mips_fpu_type'.
9170
7e5ed83b
XR
91712017-07-31 Xavier Roirand <roirand@adacore.com>
9172
9173 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
9174
4c9dc811
XR
91752017-07-27 Xavier Roirand <roirand@adacore.com>
9176
9177 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
9178
27d41eac
YQ
91792017-07-26 Yao Qi <yao.qi@linaro.org>
9180
9181 * cli/cli-cmds.c (maintenancechecklist): New variable.
9182 * gdbcmd.h (maintenancechecklist): Declare it.
9183 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
9184 Call i386_linux_read_description with different masks.
9185 * maint.c (maintenance_check_command): New function.
9186 (_initialize_maint_cmds): Call add_prefix_cmd.
9187 * target-descriptions.c (tdesc_reg): override operator != and ==.
9188 (tdesc_type): Likewise.
9189 (tdesc_feature): Likewise.
9190 (target_desc): Likewise.
9191 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
9192 (maintenance_check_xml_descriptions): New function.
9193 (_initialize_target_descriptions) Add command "xml-descriptions".
9194 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
9195
ea03d0d3
YQ
91962017-07-26 Yao Qi <yao.qi@linaro.org>
9197
9198 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
9199 Include features/i386/32bit-*.c.
9200 (i386_linux_read_description): Generate target description if it
9201 doesn't exist.
9202 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
9203 functions.
9204 * features/i386/32bit-linux.c: Re-generated.
9205 * features/i386/32bit-sse.c: Likewise.
9206 * target-descriptions.c (print_c_feature::visit): Print code to
9207 set register number if needed.
9208 (print_c_feature) <m_next_regnum>: New field.
9209
25aa13e5
YQ
92102017-07-26 Yao Qi <yao.qi@linaro.org>
9211
9212 * features/Makefile (CFILES): Rename with TDESC_CFILES.
9213 (FEATURE_XMLFILES): New.
9214 (FEATURE_CFILES): New.
9215 New rules.
9216 (clean-cfiles): Remove generated c files.
9217 * features/i386/32bit-avx.c: Generated.
9218 * features/i386/32bit-avx512.c: Generated.
9219 * features/i386/32bit-core.c: Generated.
9220 * features/i386/32bit-linux.c: Generated.
9221 * features/i386/32bit-mpx.c: Generated.
9222 * features/i386/32bit-pkeys.c: Generated.
9223 * features/i386/32bit-sse.c: Generated.
9224 * target-descriptions.c: Include algorithm.
9225 (tdesc_element_visitor): Add method visit_end.
9226 (print_c_tdesc): Implement visit_end.
9227 (print_c_tdesc:: m_filename_after_features): Move it to
9228 protected.
9229 (print_c_feature): New class.
9230 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
9231 name starts with "i386/32bit-".
9232
6eb1e6a8
YQ
92332017-07-26 Yao Qi <yao.qi@linaro.org>
9234
9235 * target-descriptions.c (tdesc_element_visitor): New class.
9236 (tdesc_element): New class.
9237 (tdesc_reg): Inherit from tdesc_element.
9238 (tdesc_reg::accept): New function.
9239 (tdesc_type): Inherit from tdesc_element.
9240 (tdesc_type::accept): New function.
9241 (tdesc_feature): Inherit from tdesc_element.
9242 (tdesc_feature::accept): New function.
9243 (target_desc): Inherit from tdesc_element.
9244 (target_desc::target_desc): New.
9245 (target_desc::~target_desc): New.
9246 (target_desc::accept): New.
9247 (allocate_target_description): Use new.
9248 (free_target_description): Use delete.
9249 (print_c_tdesc): New class.
9250 (maint_print_c_tdesc_cmd): Adjust.
9251
9252 * features/aarch64.c: Re-generated.
9253 * features/arc-arcompact.c: Re-generated.
9254 * features/arc-v2.c: Re-generated.
9255 * features/arm/arm-with-iwmmxt.c: Re-generated.
9256 * features/arm/arm-with-m.c: Re-generated.
9257 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
9258 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
9259 * features/arm/arm-with-neon.c: Re-generated.
9260 * features/arm/arm-with-vfpv2.c: Re-generated.
9261 * features/arm/arm-with-vfpv3.c: Re-generated.
9262 * features/i386/amd64-avx-avx512.c: Re-generated.
9263 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
9264 * features/i386/amd64-avx.c: Re-generated.
9265 * features/i386/amd64-avx-linux.c: Re-generated.
9266 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
9267 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
9268 * features/i386/amd64-avx-mpx.c: Re-generated.
9269 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
9270 * features/i386/amd64.c: Re-generated.
9271 * features/i386/amd64-linux.c: Re-generated.
9272 * features/i386/amd64-mpx.c: Re-generated.
9273 * features/i386/amd64-mpx-linux.c: Re-generated.
9274 * features/i386/i386-avx-avx512.c: Re-generated.
9275 * features/i386/i386-avx-avx512-linux.c: Re-generated.
9276 * features/i386/i386-avx.c: Re-generated.
9277 * features/i386/i386-avx-linux.c: Re-generated.
9278 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
9279 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
9280 * features/i386/i386-avx-mpx.c: Re-generated.
9281 * features/i386/i386-avx-mpx-linux.c: Re-generated.
9282 * features/i386/i386.c: Re-generated.
9283 * features/i386/i386-linux.c: Re-generated.
9284 * features/i386/i386-mmx.c: Re-generated.
9285 * features/i386/i386-mmx-linux.c: Re-generated.
9286 * features/i386/i386-mpx.c: Re-generated.
9287 * features/i386/i386-mpx-linux.c: Re-generated.
9288 * features/i386/x32-avx-avx512.c: Re-generated.
9289 * features/i386/x32-avx-avx512-linux.c: Re-generated.
9290 * features/i386/x32-avx.c: Re-generated.
9291 * features/i386/x32-avx-linux.c: Re-generated.
9292 * features/i386/x32.c: Re-generated.
9293 * features/i386/x32-linux.c: Re-generated.
9294 * features/microblaze.c: Re-generated.
9295 * features/microblaze-with-stack-protect.c: Re-generated.
9296 * features/mips64-dsp-linux.c: Re-generated.
9297 * features/mips64-linux.c: Re-generated.
9298 * features/mips-dsp-linux.c: Re-generated.
9299 * features/mips-linux.c: Re-generated.
9300 * features/nds32.c: Re-generated.
9301 * features/nios2.c: Re-generated.
9302 * features/nios2-linux.c: Re-generated.
9303 * features/rs6000/powerpc-32.c: Re-generated.
9304 * features/rs6000/powerpc-32l.c: Re-generated.
9305 * features/rs6000/powerpc-403.c: Re-generated.
9306 * features/rs6000/powerpc-403gc.c : Re-generated.
9307 * features/rs6000/powerpc-405.c: Re-generated.
9308 * features/rs6000/powerpc-505.c: Re-generated.
9309 * features/rs6000/powerpc-601.c: Re-generated.
9310 * features/rs6000/powerpc-602.c: Re-generated.
9311 * features/rs6000/powerpc-603.c: Re-generated.
9312 * features/rs6000/powerpc-604.c: Re-generated.
9313 * features/rs6000/powerpc-64.c: Re-generated.
9314 * features/rs6000/powerpc-64l.c: Re-generated.
9315 * features/rs6000/powerpc-7400.c: Re-generated.
9316 * features/rs6000/powerpc-750.c: Re-generated.
9317 * features/rs6000/powerpc-860.c: Re-generated.
9318 * features/rs6000/powerpc-altivec32.c: Re-generated.
9319 * features/rs6000/powerpc-altivec32l.c: Re-generated.
9320 * features/rs6000/powerpc-altivec64.c: Re-generated.
9321 * features/rs6000/powerpc-altivec64l.c: Re-generated.
9322 * features/rs6000/powerpc-cell32l.c: Re-generated.
9323 * features/rs6000/powerpc-cell64l.c: Re-generated.
9324 * features/rs6000/powerpc-e500.c: Re-generated.
9325 * features/rs6000/powerpc-e500l.c: Re-generated.
9326 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
9327 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
9328 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
9329 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
9330 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
9331 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
9332 * features/rs6000/powerpc-vsx32.c: Re-generated.
9333 * features/rs6000/powerpc-vsx32l.c: Re-generated.
9334 * features/rs6000/powerpc-vsx64.c: Re-generated.
9335 * features/rs6000/powerpc-vsx64l.c: Re-generated.
9336 * features/rs6000/rs6000.c: Re-generated.
9337 * features/s390-linux32.c: Re-generated.
9338 * features/s390-linux32v1.c: Re-generated.
9339 * features/s390-linux32v2.c: Re-generated.
9340 * features/s390-linux64.c: Re-generated.
9341 * features/s390-linux64v1.c: Re-generated.
9342 * features/s390-linux64v2.c: Re-generated.
9343 * features/s390-te-linux64.c: Re-generated.
9344 * features/s390-tevx-linux64.c: Re-generated.
9345 * features/s390-vx-linux64.c: Re-generated.
9346 * features/s390x-linux64.c: Re-generated.
9347 * features/s390x-linux64v1.c: Re-generated.
9348 * features/s390x-linux64v2.c: Re-generated.
9349 * features/s390x-te-linux64.c: Re-generated.
9350 * features/s390x-tevx-linux64.c: Re-generated.
9351 * features/s390x-vx-linux64.c: Re-generated.
9352 * features/sparc/sparc32-solaris.c: Re-generated.
9353 * features/sparc/sparc64-solaris.c: Re-generated.
9354 * features/tic6x-c62x.c: Re-generated.
9355 * features/tic6x-c62x-linux.c: Re-generated.
9356 * features/tic6x-c64x.c: Re-generated.
9357 * features/tic6x-c64x-linux.c: Re-generated.
9358 * features/tic6x-c64xp.c: Re-generated.
9359 * features/tic6x-c64xp-linux.c: Re-generated.
9360
35b4818d
YQ
93612017-07-26 Yao Qi <yao.qi@linaro.org>
9362
9363 * i386-linux-tdep.c (i386_linux_read_description): New function.
9364 (i386_linux_core_read_description): Call
9365 i386_linux_read_description.
9366 * i386-linux-tdep.h (i386_linux_read_description): Declare.
9367 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
9368 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
9369 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
9370 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
9371 * x86-linux-nat.c (x86_linux_read_description): Call
9372 i386_linux_read_description.
9373
8e2141c6
YQ
93742017-07-26 Yao Qi <yao.qi@linaro.org>
9375
9376 * NEWS: Mention it.
9377 * features/Makefile (%.c: %.xml): Pass the xml file name to
9378 command "maint print c-tdesc".
9379 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
9380 name from 'arg'.
9381
b468ff4c
YQ
93822017-07-26 Yao Qi <yao.qi@linaro.org>
9383
9384 * target-descriptions.c (target_desc): Add ctor and dtor. Do
9385 in-class initialization.
9386 (tdesc_create_feature): Call new instead of XCNEW.
9387 (free_target_description): Ue delete.
9388
b9c0e1b4
JB
93892017-07-25 John Baldwin <jhb@FreeBSD.org>
9390
9391 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
9392
a04b5337
YQ
93932017-07-25 Yao Qi <yao.qi@linaro.org>
9394
9395 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
9396 constant.
9397 (amd64_x32_init_abi): Likewise.
9398 * amd64-tdep.h (amd64_init_abi): Update declaration.
9399 (amd64_x32_init_abi): Likewise.
9400
02ad7fc2
YQ
94012017-07-25 Yao Qi <yao.qi@linaro.org>
9402
9403 PR tdep/21717
9404 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
9405 condition for FPSCR.
9406 (arm_linux_store_inferior_registers): Likewise.
9407
b6f48cb0
TT
94082017-07-22 Tom Tromey <tom@tromey.com>
9409
9410 * break-catch-syscall.c (struct catch_syscall_inferior_data)
9411 <syscalls_counts>: Now a std::vector.
9412 (get_catch_syscall_inferior_data): Use "new".
9413 (catch_syscall_inferior_data_cleanup): Use "delete".
9414 (insert_catch_syscall, remove_catch_syscall)
9415 (clear_syscall_counts): Update.
9416
e12c9b7a
TT
94172017-07-22 Tom Tromey <tom@tromey.com>
9418
9419 * break-catch-syscall.c (syscall_catchpoint)
9420 <syscalls_to_be_caught>: Now a std::vector<int>
9421 (~syscall_catchpoint): Remove.
9422 (insert_catch_syscall, remove_catch_syscall)
9423 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
9424 (print_mention_catch_syscall, print_recreate_catch_syscall):
9425 Update.
9426 (create_syscall_event_catchpoint): Change type of "filter"
9427 parameter.
9428 (catch_syscall_split_args): Return a std::vector.
9429 (catch_syscall_command_1, catching_syscall_number_1): Update.
9430
4fa8aeac
TT
94312017-07-22 Tom Tromey <tom@tromey.com>
9432
9433 * break-catch-throw.c (struct exception_catchpoint)
9434 <exception_rx>: Now a std::string.
9435 (~exception_catchpoint): Remove.
9436 (print_one_detail_exception_catchpoint): Update.
9437 (handle_gnu_v3_exceptions): Change type of except_rx.
9438 (extract_exception_regexp): Return a std::string.
9439 (catch_exception_command_1): Update.
9440
f746a154
TT
94412017-07-22 Tom Tromey <tom@tromey.com>
9442
9443 * break-catch-sig.c (gdb_signal_type): Remove typedef.
9444 (struct signal_catchpoint) <signals_to_be_caught>: Now a
9445 std::vector.
9446 <catch_all>: Now a bool.
9447 (~signal_catchpoint): Remove.
9448 (signal_catchpoint_insert_location)
9449 (signal_catchpoint_remove_location)
9450 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
9451 (signal_catchpoint_print_mention)
9452 (signal_catchpoint_print_recreate)
9453 (signal_catchpoint_explains_signal): Update.
9454 (create_signal_catchpoint): Change type of "filter" and
9455 "catch_all".
9456 (catch_signal_split_args): Return a std::vector. Change type of
9457 "catch_all".
9458 (catch_signal_command): Update.
9459
47e77640
PA
94602017-07-20 Pedro Alves <palves@redhat.com>
9461
9462 * ada-lang.c (ada_language_defn): Make extern.
9463 (_initialize_ada_language): Remove add_language call.
9464 * c-lang.c (c_language_defn, cplus_language_defn)
9465 (asm_language_defn, minimal_language_defn): Make extern.
9466 (_initialize_c_language): Delete.
9467 * completer.c (compare_cstrings): Delete, moved to utils.h.
9468 * d-lang.c (d_language_defn): Make extern.
9469 (_initialize_d_language): Remove add_language calls.
9470 * defs.h (enum language): Add comment.
9471 * f-lang.c (f_language_defn): Make extern.
9472 (_initialize_f_language): Remove add_language call.
9473 * go-lang.c (go_language_defn): Make extern.
9474 (_initialize_go_language): Remove add_language call.
9475 * language.c: Include <algorithm>.
9476 (languages): Redefine as const array.
9477 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
9478 (set_language_command): Handle "local". Use for-range loop.
9479 (set_language): Remove loop.
9480 (language_enum): Rewrite.
9481 (language_def, language_str): Remove loops.
9482 (add_language): Delete.
9483 (add_set_language_command): New, based on add_languages.
9484 (skip_language_trampoline): Adjust.
9485 (local_language_defn): Delete.
9486 (language_gdbarch_post_init): Adjust.
9487 (_initialize_language): Remove add_language calls. Call
9488 add_set_language_command.
9489 * language.h (add_language): Delete.
9490 (auto_language_defn)
9491 (unknown_language_defn, minimal_language_defn, ada_language_defn)
9492 (asm_language_defn, c_language_defn, cplus_language_defn)
9493 (d_language_defn, f_language_defn, go_language_defn)
9494 (m2_language_defn, objc_language_defn, opencl_language_defn)
9495 (pascal_language_defn, rust_language_defn): Declare.
9496 * m2-lang.c (m2_language_defn): Make extern.
9497 (_initialize_m2_language): Remove add_language call.
9498 * objc-lang.c (objc_language_defn): Make extern.
9499 (_initialize_objc_language): Remove add_language call.
9500 * opencl-lang.c (opencl_language_defn): Make extern.
9501 (_initialize_opencl_language): Remove add_language call.
9502 * p-lang.c (pascal_language_defn): Make extern.
9503 (_initialize_pascal_language): Delete.
9504 * rust-lang.c (rust_language_defn): Make extern.
9505 (_initialize_rust_language): Delete.
9506 * utils.h (compare_cstrings): New static inline function.
9507
edb0c9cb
PA
95082017-07-20 Pedro Alves <palves@redhat.com>
9509
9510 * ada-lang.c (ada_to_fixed_type_1): Adjust.
9511 (get_var_value): Constify parameters.
9512 (get_int_var_value): Change prototype.
9513 (to_fixed_range_type): Adjust.
9514 * ada-lang.h (get_int_var_value): Change prototype.
9515
a778f165
PA
95162017-07-20 Pedro Alves <palves@redhat.com>
9517
9518 * dwarf2read.c (dw2_lookup_symbol): Use
9519 SYMBOL_MATCHES_SEARCH_NAME.
9520 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
9521
42edd901
PA
95222017-07-20 Pedro Alves <palves@redhat.com>
9523
9524 * block.c (block_iter_name_step, block_iter_name_first)
9525 (block_iter_name_next): Delete.
9526 (block_lookup_symbol_primary): Adjust to use
9527 dict_iter_match_first/dict_iter_match_next.
9528 * block.h (block_iter_name_first, block_iter_name_next): Delete
9529 declarations.
9530 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
9531 dict_iter_match_first/dict_iter_match_next.
9532
cf325299
PA
95332017-07-20 Pedro Alves <palves@redhat.com>
9534
9535 * cp-support.c (cp_find_first_component_aux): Add missing case for
9536 end of string.
9537
c5ed0576
DB
95382017-07-18 David Blaikie <dblaikie@gmail.com>
9539
9540 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
9541 of dwo_cu's dwo_file.
9542
27841e76
YQ
95432017-07-18 Yao Qi <yao.qi@linaro.org>
9544
9545 * remote.c (store_registers_using_G): Remove one line comment.
9546
cfb7e58b
YQ
95472017-07-18 Yao Qi <yao.qi@linaro.org>
9548
9549 * regcache.c (regcache_cpy): Simplify it.
9550 (regcache::cpy_no_passthrough): Remove it.
9551 * regcache.h (cpy_no_passthrough): Remove it.
9552 (regcache_dup, regcache_cpy): Update comments.
9553
386535dd
PA
95542017-07-18 Pedro Alves <palves@redhat.com>
9555
9556 * remote-sim.c (sim_command_completer): Adjust to work with a
9557 completion_tracker instead of a VEC.
9558
c45ec17c
PA
95592017-07-17 Pedro Alves <palves@redhat.com>
9560
9561 * completer.c (complete_source_filenames): New function.
9562 (complete_address_and_linespec_locations): New function.
9563 (location_completer): Use complete_address_and_linespec_locations.
9564 (completion_tracker::build_completion_result): Honor the tracker's
9565 request to suppress append.
9566 * completer.h (completion_tracker::suppress_append_ws)
9567 (completion_tracker::set_suppress_append_ws): New methods.
9568 (completion_tracker::m_suppress_append_ws): New field.
9569 (complete_source_filenames): New declaration.
9570 * linespec.c (linespec_complete_what): New.
9571 (struct ls_parser) <complete_what, completion_word,
9572 completion_quote_char, completion_quote_end, completion_tracker>:
9573 New fields.
9574 (string_find_incomplete_keyword_at_end): New.
9575 (linespec_lexer_lex_string): Record quote char. If in completion
9576 mode, don't throw.
9577 (linespec_lexer_consume_token): Advance the completion word point.
9578 (linespec_lexer_peek_token): Save/restore completion info.
9579 (save_stream_and_consume_token): New.
9580 (set_completion_after_number): New.
9581 (linespec_parse_basic): Set what to complete next depending on
9582 token. Handle function and label completions specially.
9583 (parse_linespec): Disable objc shortcut in completion mode. Set
9584 what to complete next depending on token type. Skip keyword if in
9585 completion mode.
9586 (complete_linespec_component, linespec_complete): New.
9587 * linespec.h (linespec_complete): Declare.
9588
be966d42
PA
95892017-07-17 Pedro Alves <palves@redhat.com>
9590
9591 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
9592 Handle 'operator<' / 'operator<<'.
9593
a2459270
PA
95942017-07-17 Pedro Alves <palves@redhat.com>
9595
9596 * completer.c (collect_explicit_location_matches): Handle
9597 MATCH_LABEL.
9598 (convert_explicit_location_to_linespec): New, factored out from
9599 ...
9600 (convert_explicit_location_to_sals): ... this.
9601 (complete_label): New.
9602 (linespec_complete_label, find_label_symbols_in_block): New.
9603 (find_label_symbols): Add completion_mode parameter and adjust to
9604 call find_label_symbols_in_block.
9605 * linespec.h (linespec_complete_label): Declare.
9606
c6756f62
PA
96072017-07-17 Pedro Alves <palves@redhat.com>
9608
9609 * ada-lang.c (ada_collect_symbol_completion_matches): Add
9610 complete_symbol_mode parameter.
9611 * cli/cli-cmds.c (complete_command): Get the completion result out
9612 of the handle_brkchars tracker if used a custom word point.
9613 * completer.c: Include "linespec.h".
9614 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
9615 (advance_to_expression_complete_word_point): New.
9616 (completion_tracker::completes_to_completion_word): New.
9617 (complete_files_symbols): Pass down
9618 complete_symbol_mode::EXPRESSION.
9619 (explicit_options, probe_options): New.
9620 (collect_explicit_location_matches): Complete on the
9621 explictit_loc->foo instead of word. Use
9622 linespec_complete_function. Handle MATCH_LINE. Handle offering
9623 keyword and options completions.
9624 (backup_text_ptr): Delete.
9625 (skip_keyword): New.
9626 (complete_explicit_location): Remove 'word' parameter. Add
9627 language, quoted_arg_start and quoted_arg_end parameters.
9628 Rewrite, parsing left to right.
9629 (location_completer): Rewrite.
9630 (location_completer_handle_brkchars): New function.
9631 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
9632 (enum complete_line_internal_reason): Adjust comments.
9633 (completion_tracker::discard_completions): New.
9634 (completer_handle_brkchars_func_for_completer): Handle
9635 location_completer.
9636 (gdb_custom_word_point_brkchars)
9637 (gdb_org_rl_basic_quote_characters): New.
9638 (gdb_completion_word_break_characters_throw)
9639 (completion_find_completion_word): Handle trackers that use a
9640 custom word point.
9641 (completion_tracker::advance_custom_word_point_by): New.
9642 (completion_tracker::build_completion_result): Don't rely on
9643 readline appending the quote char.
9644 (gdb_rl_attempted_completion_function_throw): Handle trackers that
9645 use a custom word point.
9646 (gdb_rl_attempted_completion_function): Restore
9647 rl_basic_quote_characters.
9648 * completer.h (class completion_tracker): Extend intro comment.
9649 (completion_tracker::set_quote_char)
9650 (completion_tracker::quote_char)
9651 (completion_tracker::set_use_custom_word_point)
9652 (completion_tracker::use_custom_word_point)
9653 (completion_tracker::custom_word_point)
9654 (completion_tracker::set_custom_word_point)
9655 (completion_tracker::advance_custom_word_point_by)
9656 (completion_tracker::completes_to_completion_word)
9657 (completion_tracker::discard_completions): New methods.
9658 (completion_tracker::m_quote_char)
9659 (completion_tracker::m_use_custom_word_point)
9660 (completion_tracker::m_custom_word_point): New fields.
9661 (advance_to_expression_complete_word_point): Declare.
9662 * f-lang.c (f_collect_symbol_completion_matches): Add
9663 complete_symbol_mode parameter.
9664 * language.h (struct language_defn)
9665 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
9666 parameter.
9667 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
9668 (linespec_complete_function): New function.
9669 (linespec_lexer_lex_keyword): Adjust.
9670 * linespec.h (linespec_keywords, linespec_complete_function): New
9671 declarations.
9672 * location.c (find_end_quote): New function.
9673 (explicit_location_lex_one): Add explicit_completion_info
9674 parameter. Save quoting info. Don't throw if being called for
9675 completion. Don't handle Ada operators here.
9676 (is_cp_operator, skip_op_false_positives, first_of)
9677 (explicit_location_lex_one_function): New function.
9678 (string_to_explicit_location): Replace 'dont_throw' parameter with
9679 an explicit_completion_info pointer parameter. Handle it. Don't
9680 use explicit_location_lex_one to lex function names. Use
9681 explicit_location_lex_one_function instead.
9682 * location.h (struct explicit_completion_info): New.
9683 (string_to_explicit_location): Replace 'dont_throw' parameter with
9684 an explicit_completion_info pointer parameter.
9685 * symtab.c (default_collect_symbol_completion_matches_break_on):
9686 Add complete_symbol_mode parameter. Handle LINESPEC mode.
9687 (default_collect_symbol_completion_matches)
9688 (collect_symbol_completion_matches): Add complete_symbol_mode
9689 parameter.
9690 (collect_symbol_completion_matches_type): Pass down
9691 complete_symbol_mode::EXPRESSION.
9692 (collect_file_symbol_completion_matches): Add complete_symbol_mode
9693 parameter. Handle LINESPEC mode.
9694 * symtab.h (complete_symbol_mode): New.
9695 (default_collect_symbol_completion_matches_break_on)
9696 (default_collect_symbol_completion_matches)
9697 (collect_symbol_completion_matches)
9698 (collect_file_symbol_completion_matches): Add complete_symbol_mode
9699 parameter.
9700
1d550c82
PA
97012017-07-17 Pedro Alves <palves@redhat.com>
9702
9703 * utils.c (enum class strncmp_iw_mode): New.
9704 (strcmp_iw): Rename to ...
9705 (strncmp_iw_with_mode): ... this. Add string2_len and mode
9706 parameters. Handle them.
9707 (strncmp_iw): New.
9708 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
9709 * utils.h (strncmp_iw): Declare.
9710 (strcmp_iw): Move describing comments here.
9711
8090b426
PA
97122017-07-17 Pedro Alves <palves@redhat.com>
9713
9714 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
9715 CP_OPERATOR_STR.
9716 * c-typeprint.c (is_type_conversion_operator): Use
9717 CP_OPERATOR_STR.
9718 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
9719 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
9720 CP_OPERATOR_LEN.
9721 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
9722 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
9723 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
9724 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
9725 CP_OPERATOR_STR.
9726 * location.c: Include "cp-support.h".
9727 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
9728 CP_OPERATOR_STR.
9729 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
9730 CP_OPERATOR_LEN.
9731
6a2c1b87
PA
97322017-07-17 Pedro Alves <palves@redhat.com>
9733
9734 * cli/cli-cmds.c (complete_command): Use a completion tracker
9735 along with completion_find_completion_word for handle_brkchars
9736 phase.
9737 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
9738 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
9739 (struct gdb_rl_completion_word_info): New.
9740 (gdb_rl_find_completion_word): New.
9741 (completion_find_completion_word): New.
9742 * completer.h (completion_find_completion_word): Declare.
9743
eb3ff9a5
PA
97442017-07-17 Pedro Alves <palves@redhat.com>
9745
9746 * ada-lang.c (symbol_completion_match): Adjust comments.
9747 (symbol_completion_add): Replace vector parameter with
9748 completion_tracker parameter. Use it.
9749 (ada_make_symbol_completion_list): Rename to...
9750 (ada_collect_symbol_completion_matches): ... this. Add
9751 completion_tracker parameter and use it.
9752 (ada_language_defn): Adjust.
9753 * break-catch-syscall.c (catch_syscall_completer): Adjust
9754 prototype and work with completion_tracker instead of VEC.
9755 * breakpoint.c (condition_completer): Adjust prototype and work
9756 with completion_tracker instead of VEC.
9757 * c-lang.c (c_language_defn, cplus_language_defn)
9758 (asm_language_defn, minimal_language_defn): Adjust to renames.
9759 * cli/cli-cmds.c (complete_command): Rework using
9760 completion_tracker. Catch exceptions when completing.
9761 * cli/cli-decode.c (integer_unlimited_completer)
9762 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
9763 with completion_tracker instead of VEC.
9764 * command.h (struct completion_tracker): Forward declare.
9765 (completer_ftype, completer_handle_brkchars_ftype): Change
9766 types.
9767 (complete_on_cmdlist, complete_on_enum): Adjust.
9768 * completer.c: Include <algorithm>.
9769 (struct gdb_completer_state): New.
9770 (current_completion): New global.
9771 (readline_line_completion_function): Delete.
9772 (noop_completer, filename_completer)
9773 (filename_completer_handle_brkchars, complete_files_symbols)
9774 (linespec_location_completer): Adjust to work with a
9775 completion_tracker instead of a VEC.
9776 (string_or_empty): New.
9777 (collect_explicit_location_matches): Adjust to work with a
9778 completion_tracker instead of a VEC.
9779 (explicit_location_completer): Rename to ...
9780 (complete_explicit_location): ... this and adjust to work with a
9781 completion_tracker instead of a VEC.
9782 (location_completer): Adjust to work with a completion_tracker
9783 instead of a VEC.
9784 (add_struct_fields): Adjust to work with a completion_list instead
9785 of VEC.
9786 (expression_completer): Rename to ...
9787 (complete_expression): ... this and adjust to work with a
9788 completion_tracker instead of a VEC. Use complete_files_symbols.
9789 (expression_completer): Reimplement on top of complete_expression.
9790 (symbol_completer): Adjust to work with a completion_tracker
9791 instead of a VEC.
9792 (enum complete_line_internal_reason): Add describing comments.
9793 (complete_line_internal_normal_command): Adjust to work with a
9794 completion_tracker instead of a VEC.
9795 (complete_line_internal): Rename to ...
9796 (complete_line_internal_1): ... this and adjust to work with a
9797 completion_tracker instead of a VEC. Assert TEXT is NULL in the
9798 handle_brkchars phase.
9799 (new_completion_tracker): Delete.
9800 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
9801 complete_line_internal_1.
9802 (free_completion_tracker): Delete.
9803 (INITIAL_COMPLETION_HTAB_SIZE): New.
9804 (completion_tracker::completion_tracker)
9805 (completion_tracker::~completion_tracker): New.
9806 (maybe_add_completion): Delete.
9807 (completion_tracker::maybe_add_completion)
9808 (completion_tracker::add_completion)
9809 (completion_tracker::add_completions): New.
9810 (throw_max_completions_reached_error): Delete.
9811 (complete_line): Adjust to work with a completion_tracker instead
9812 of a VEC. Don't create a completion_tracker_t or check for max
9813 completions here.
9814 (command_completer, command_completer_handle_brkchars)
9815 (signal_completer, reg_or_group_completer_1)
9816 (reg_or_group_completer, default_completer_handle_brkchars):
9817 Adjust to work with a completion_tracker.
9818 (gdb_completion_word_break_characters_throw): New.
9819 (gdb_completion_word_break_characters): Reimplement.
9820 (line_completion_function): Delete.
9821 (completion_tracker::recompute_lowest_common_denominator)
9822 (expand_preserving_ws)
9823 (completion_tracker::build_completion_result)
9824 (completion_result::completion_result)
9825 (completion_result::completion_result)
9826 (completion_result::~completion_result)
9827 (completion_result::completion_result)
9828 (completion_result::release_match_list, compare_cstrings)
9829 (completion_result::sort_match_list)
9830 (completion_result::reset_match_list)
9831 (gdb_rl_attempted_completion_function_throw)
9832 (gdb_rl_attempted_completion_function): New.
9833 * completer.h (completion_list, struct completion_result)
9834 (class completion_tracker): New.
9835 (complete_line): Add completion_tracker parameter.
9836 (readline_line_completion_function): Delete.
9837 (gdb_rl_attempted_completion_function): New.
9838 (noop_completer, filename_completer, expression_completer)
9839 (location_completer, symbol_completer, command_completer)
9840 (signal_completer, reg_or_group_completer): Update prototypes.
9841 (completion_tracker_t, new_completion_tracker)
9842 (make_cleanup_free_completion_tracker): Delete.
9843 (enum maybe_add_completion_enum): Delete.
9844 (maybe_add_completion): Delete.
9845 (throw_max_completions_reached_error): Delete.
9846 * corefile.c (complete_set_gnutarget): Adjust to work with a
9847 completion_tracker instead of a VEC.
9848 * cp-abi.c (cp_abi_completer): Adjust to work with a
9849 completion_tracker instead of a VEC.
9850 * d-lang.c (d_language_defn): Adjust.
9851 * disasm.c (disassembler_options_completer): Adjust to work with a
9852 completion_tracker instead of a VEC.
9853 * f-lang.c (f_make_symbol_completion_list): Rename to ...
9854 (f_collect_symbol_completion_matches): ... this. Adjust to work
9855 with a completion_tracker instead of a VEC.
9856 (f_language_defn): Adjust.
9857 * go-lang.c (go_language_defn): Adjust.
9858 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
9859 Adjust to work with a completion_tracker instead of a VEC.
9860 * infrun.c (handle_completer): Likewise.
9861 * interps.c (interpreter_completer): Likewise.
9862 * interps.h (interpreter_completer): Likewise.
9863 * language.c (unknown_language_defn, auto_language_defn)
9864 (local_language_defn): Adjust.
9865 * language.h (language_defn::la_make_symbol_completion_list):
9866 Rename to ...
9867 (language_defn::la_collect_symbol_completion_matches): ... this
9868 and adjust to work with a completion_tracker instead of a VEC.
9869 * m2-lang.c (m2_language_defn): Adjust.
9870 * objc-lang.c (objc_language_defn): Adjust.
9871 * opencl-lang.c (opencl_language_defn): Adjust.
9872 * p-lang.c (pascal_language_defn): Adjust.
9873 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
9874 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
9875 with a completion_tracker.
9876 * rust-lang.c (rust_language_defn): Adjust.
9877 * symtab.c (free_completion_list, do_free_completion_list)
9878 (return_val, completion_tracker): Delete.
9879 (completion_list_add_name, completion_list_add_symbol)
9880 (completion_list_add_msymbol, completion_list_objc_symbol)
9881 (completion_list_add_fields, add_symtab_completions): Add
9882 completion_tracker parameter and use it.
9883 (default_make_symbol_completion_list_break_on_1): Rename to...
9884 (default_collect_symbol_completion_matches_break_on): ... this.
9885 Add completion_tracker parameter and use it instead of allocating
9886 a completion tracker here.
9887 (default_make_symbol_completion_list_break_on): Delete old
9888 implementation.
9889 (default_make_symbol_completion_list): Delete.
9890 (default_collect_symbol_completion_matches): New.
9891 (make_symbol_completion_list): Delete.
9892 (collect_symbol_completion_matches): New.
9893 (make_symbol_completion_type): Rename to ...
9894 (collect_symbol_completion_matches_type): ... this. Add
9895 completion_tracker parameter and use it instead of VEC.
9896 (make_file_symbol_completion_list_1): Rename to...
9897 (collect_file_symbol_completion_matches): ... this. Add
9898 completion_tracker parameter and use it instead of VEC.
9899 (make_file_symbol_completion_list): Delete.
9900 (add_filename_to_list): Use completion_list instead of a VEC.
9901 (add_partial_filename_data::list): Now a completion_list.
9902 (make_source_files_completion_list): Work with a completion_list
9903 instead of a VEC.
9904 * symtab.h: Include "completer.h".
9905 (default_make_symbol_completion_list_break_on)
9906 (default_make_symbol_completion_list, make_symbol_completion_list)
9907 (make_symbol_completion_type, make_file_symbol_completion_list)
9908 (make_source_files_completion_list): Delete.
9909 (default_collect_symbol_completion_matches_break_on)
9910 (default_collect_symbol_completion_matches)
9911 (collect_symbol_completion_matches)
9912 (collect_symbol_completion_matches_type)
9913 (collect_file_symbol_completion_matches)
9914 (make_source_files_completion_list): New.
9915 * top.c (init_main): Don't install a rl_completion_entry_function
9916 hook. Install a rl_attempted_completion_function hook instead.
9917 * tui/tui-layout.c (layout_completer): Adjust to work with a
9918 completion_tracker.
9919 * tui/tui-regs.c (tui_reggroup_completer):
9920 * tui/tui-win.c (window_name_completer, focus_completer)
9921 (winheight_completer): Adjust to work with a completion_tracker.
9922 * value.c: Include "completer.h".
9923 (complete_internalvar): Adjust to work with a completion_tracker.
9924 * value.h (complete_internalvar): Likewise.
9925
6e1dbf8c
PA
99262017-07-17 Pedro Alves <palves@redhat.com>
9927
9928 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
9929 renames.
9930 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
9931 comments to completer_ftype's declaration.
9932 <completer_handle_brkchars>: Change type to
9933 completer_handle_brkchars_ftype.
9934 * command.h (completer_ftype): Add describing comment and give
9935 names to parameters.
9936 (completer_ftype_void): Rename to ...
9937 (completer_handle_brkchars_ftype) ... this. Add describing comment.
9938 (set_cmd_completer_handle_brkchars): Adjust.
9939 * completer.c (filename_completer_handle_brkchars): New function.
9940 (complete_line_internal_normal_command): New function, factored
9941 out from ...
9942 (complete_line_internal): ... here.
9943 (command_completer_handle_brkchars)
9944 (default_completer_handle_brkchars)
9945 (completer_handle_brkchars_func_for_completer): New functions.
9946 * completer.h (set_gdb_completion_word_break_characters): Delete
9947 declaration.
9948 (completer_handle_brkchars_func_for_completer): New declaration.
9949 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
9950 completer_handle_brkchars_func_for_completer.
9951
78b13106
PA
99522017-07-17 Pedro Alves <palves@redhat.com>
9953
9954 * completer.c (symbol_completer): New function, based on
9955 make_symbol_completion_list_fn.
9956 * completer.h (symbol_completer): New declaration.
9957 * guile/scm-cmd.c (cmdscm_completers): Adjust.
9958 * python/py-cmd.c (completers): Adjust.
9959 * symtab.c (make_symbol_completion_list_fn): Delete.
9960 * symtab.h (make_symbol_completion_list_fn): Delete.
9961 * cli/cli-decode.c (add_cmd): Adjust.
9962
bbf2f4df
PA
99632017-07-17 Pedro Alves <palves@redhat.com>
9964
9965 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
9966 * dwarf2read.c: Include "filename-seen-cache.h".
9967 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
9968 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
9969 * filename-seen-cache.c: New file.
9970 * filename-seen-cache.h: New file.
9971 * symtab.c: Include "filename-seen-cache.h".
9972 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
9973 (create_filename_seen_cache, clear_filename_seen_cache)
9974 (delete_filename_seen_cache, filename_seen): Delete, parts moved
9975 to filename-seen-cache.h/filename-seen-cache.c.
9976 (output_source_filename, sources_info)
9977 (maybe_add_partial_symtab_filename)
9978 (make_source_files_completion_list): Adjust to use
9979 filename_seen_cache.
9980
330cdd98
PA
99812017-07-17 Pedro Alves <palves@redhat.com>
9982
9983 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
9984 fields.
9985 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
9986 dwarf2_debug_sections*)): New.
9987 (dwarf2_per_objfile::dwarf2_per_objfile(const
9988 dwarf2_per_objfile&)): Declare as deleted.
9989 (dwarf2_per_objfile::operator=): Declare as deleted.
9990 (dwarf2_per_objfile::dwarf2_per_objfile)
9991 (dwarf2_per_objfile::~dwarf2_per_objfile)
9992 (dwarf2_per_objfile::free_cached_comp_units): New.
9993 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
9994 ctor. Call dwarf2_per_objfile's ctor manually.
9995 (dwarf2_locate_sections): Deleted/refactored as ...
9996 (dwarf2_per_objfile::locate_sections): ... this new method.
9997 (free_cached_comp_units): Defer to
9998 dwarf2_per_objfile::free_cached_comp_units.
9999 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
10000
8880f2a9
TT
100012017-07-14 Tom Tromey <tom@tromey.com>
10002
10003 PR rust/21764:
10004 * rust-exp.y (convert_ast_to_expression): Add "want_type"
10005 parameter.
10006 <UNOP_SIZEOF>: Split into separate case.
10007 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
10008
65547233
TT
100092017-07-14 Tom Tromey <tom@tromey.com>
10010
10011 PR rust/21763:
10012 * symtab.c (symbol_matches_domain): Add language_rust to special
10013 case.
10014 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
10015 treat LOC_TYPEDEF symbols as variables.
10016
8f14146e
PA
100172017-07-14 Pedro Alves <palves@redhat.com>
10018
10019 * symtab.c (make_file_symbol_completion_list_1): Iterate over
10020 symtabs matching all symtabs with SRCFILE as file name instead of
10021 only considering the first hit, with lookup_symtab.
10022
2347965c
SM
100232017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10024
10025 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
10026 operator_name parameters.
10027 (gen_expr): Update function call.
10028
40f4af28
SM
100292017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10030
10031 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
10032 parameter.
10033 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
10034 Likewise.
10035 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
10036 parameter, use agent_expr::gdbarch instead, update function
10037 calls.
10038 (locexpr_tracepoint_var_ref): Likewise.
10039 (loclist_tracepoint_var_ref): Likewise.
10040 * ax-gdb.c (gen_trace_static_fields): Likewise.
10041 (gen_traced_pop): Likewise.
10042 (gen_frame_args_address): Likewise.
10043 (gen_frame_locals_address): Likewise.
10044 (gen_var_ref): Likewise.
10045 (gen_struct_ref_recursive): Likewise.
10046 (gen_static_field): Likewise.
10047 (gen_maybe_namespace_elt): Likewise.
10048 (gen_expr): Likewise.
10049 (gen_trace_for_var): Likewise.
10050 (gen_trace_for_expr): Likewise.
10051 (gen_trace_for_return_address): Likewise.
10052
053f8057
SM
100532017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10054
10055 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
10056 parameter.
10057 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
10058
6661ad48
SM
100592017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10060
10061 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
10062 from ax, update calls.
10063 (gen_usual_arithmetic): Likewise.
10064 (gen_integral_promotions): Likewise.
10065 (gen_bitfield_ref): Likewise.
10066 (gen_primitive_field): Likewise.
10067 (gen_struct_ref_recursive): Likewise.
10068 (gen_struct_ref): Likewise.
10069 (gen_maybe_namespace_elt): Likewise.
10070 (gen_struct_elt_for_reference): Likewise.
10071 (gen_namespace_elt): Likewise.
10072 (gen_aggregate_elt_ref): Likewise.
10073 (gen_expr): Get gdbarch from ax, update calls.
10074 (gen_expr_binop_rest): Likewise.
10075
c55a47e7
PA
100762017-07-13 Pedro Alves <palves@redhat.com>
10077
10078 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
10079 as default tdesc.
10080 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
10081 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
10082 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
10083 tdesc_amd64_linux as default tdesc. Get final tdesc from the
10084 tdep.
10085 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
10086 Get final tdesc from the tdep.
10087 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
10088 default tdesc.
10089 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
10090 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
10091 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
10092 Use it as default tdesc.
10093 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
10094 down to amd_init_abi. No longer handle fallback tdesc here.
10095 * amd64-tdep.h (tdesc_x32): Declare.
10096 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
10097 parameter.
10098 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
10099 as default tdesc.
10100
55efceab
AA
101012017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10102
10103 * s390-linux-tdep.c (s390_process_record): Add support for
10104 instructions new in arch12.
10105
0aa37b65
JB
101062017-07-11 John Baldwin <jhb@FreeBSD.org>
10107
10108 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
10109 PT_GETFSBASE and PT_GETGSBASE.
10110 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
10111 PT_SETGSBASE.
10112
48aeef91
JB
101132017-07-11 John Baldwin <jhb@FreeBSD.org>
10114
10115 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
10116 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
10117 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
10118 those rules.
10119 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
10120 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
10121 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
10122 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
10123 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
10124 * features/i386/amd64.xml: Add 64bit-segments.xml.
10125 * features/i386/amd64-avx-avx512.c: Regenerated.
10126 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
10127 * features/i386/amd64-avx-mpx.c: Regenerated.
10128 * features/i386/amd64-avx.c: Regenerated.
10129 * features/i386/amd64-mpx.c: Regenerated.
10130 * features/i386/amd64.c: Regenerated.
10131 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
10132 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
10133 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
10134 * regformats/i386/amd64-avx.dat: Regenerated.
10135 * regformats/i386/amd64-mpx.dat: Regenerated.
10136 * regformats/i386/amd64.dat: Regenerated.
10137
77c501bc
YQ
101382017-07-10 Yao Qi <yao.qi@linaro.org>
10139
10140 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
10141 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
10142
6dc8d757
AK
101432017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
10144
10145 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
10146 unsetenv.
10147 * gnulib/aclocal.m4: Regenerate.
10148 * gnulib/config.in: Regenerate.
10149 * gnulib/configure: Regenerate.
10150 * gnulib/import/Makefile.am: Regenerate.
10151 * gnulib/import/Makefile.in: Regenerate.
10152 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
10153 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
10154 * gnulib/import/m4/environ.m4: New file.
10155 * gnulib/import/m4/setenv.m4: New file.
10156 * gnulib/import/setenv.c: New file.
10157 * gnulib/import/unsetenv.c: New file.
10158
266934d1
SM
101592017-07-09 Simon Marchi <simon.marchi@ericsson.com>
10160
10161 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
10162 address when op is DW_OP_addr.
10163
03278692
TT
101642017-07-09 Tom Tromey <tom@tromey.com>
10165
10166 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
10167 check and apply to outer type.
10168
4b654465
JB
101692017-07-07 John Baldwin <jhb@FreeBSD.org>
10170
10171 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
10172 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
10173 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
10174 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
10175
2af9fc44
JB
101762017-07-07 John Baldwin <jhb@FreeBSD.org>
10177
10178 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
10179
382b69bb
JB
101802017-07-07 John Baldwin <jhb@FreeBSD.org>
10181
10182 * corelow.c (get_core_siginfo): Remove.
10183 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
10184 instead of get_core_siginfo.
10185 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
10186 * gdbarch.h: Re-generate.
10187 * gdbarch.c: Re-generate.
10188 * linux-tdep.c (linux_core_xfer_siginfo): New.
10189 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
10190
6e5eab33
JB
101912017-07-07 John Baldwin <jhb@FreeBSD.org>
10192
10193 * corelow.c (thread_section_name): Move to ...
10194 * gdbcore.h (thread_section_name): ... here.
10195
929edea9
JB
101962017-07-07 John Baldwin <jhb@FreeBSD.org>
10197
10198 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
10199 (struct siginfo32): New.
10200 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
10201 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
10202 via ptrace(PT_LWPINFO).
10203
762c974a
JB
102042017-07-07 John Baldwin <jhb@FreeBSD.org>
10205
10206 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
10207 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
10208 (fbsd_get_siginfo_type): New.
10209 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
10210 (_initialize_fbsd_tdep): New.
10211
33c5cd75
DB
102122017-07-06 David Blaikie <dblaikie@gmail.com>
10213
10214 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
10215 a singular dwo_unit*) to support multiple CUs in the same way that
10216 multiple TUs are supported.
10217 (create_cus_hash_table): Replace create_dwo_cu with a function for
10218 parsing multiple CUs from a DWO file.
10219 (open_and_init_dwo_file): Use create_cus_hash_table rather than
10220 create_dwo_cu.
10221 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
10222 htab_find, rather than comparing the signature to a singleton CU in
10223 the dwo_file.
10224
8455d262
PA
102252017-07-06 Pedro Alves <palves@redhat.com>
10226
10227 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
10228
4da3eb35
PA
102292017-07-04 Pedro Alves <palves@redhat.com>
10230
10231 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
10232 * gdbtypes.h (TYPE_STATIC): Delete.
10233 (struct fn_field) <is_public, is_abstract, is_static, is_final,
10234 is_synchronized, is_native>: Delete.
10235 <dummy>: Bump.
10236 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
10237 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
10238 (TYPE_FN_FIELD_ABSTRACT): Delete.
10239
5bfd255c
SM
102402017-07-03 Simon Marchi <simon.marchi@ericsson.com>
10241
10242 * buffer.h (buffer_finish): Fix spelling mistakes.
10243
25c54127
EZ
102442017-07-01 Eli Zaretskii <eliz@gnu.org>
10245
10246 * .dir-locals.el: Automatically switch to C-style comments in
10247 versions of Emacs that support the feature.
10248
dc4bde35
SDJ
102492017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10250 Pedro Alves <palves@redhat.com>
10251
10252 PR cli/21688
10253 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
10254 (process_next_line): New variable 'inline_cmd'.
10255 Adjust 'if' clauses for "python", "compile" and "guile" to use
10256 'command_name_equals' and check for '!inline_cmd'.
10257
51ed89aa
SDJ
102582017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10259
10260 PR cli/21688
10261 * cli/cli-script.c (command_name_equals_not_inline): New function.
10262 (process_next_line): Adjust 'if' clauses for "python", "compile"
10263 and "guile" to use command_name_equals_not_inline.
10264
eb17d413
PA
102652017-06-29 Pedro Alves <palves@redhat.com>
10266
10267 * completer.c (expression_completer): Call
10268 linespec_location_completer instead of location_completer.
10269
195bcdd5
PA
102702017-06-29 Pedro Alves <palves@redhat.com>
10271
10272 * completer.c (expression_completer): Remove code that recomputes
10273 'text' from 'word'.
10274
adc764e7
YQ
102752017-06-29 Yao Qi <yao.qi@linaro.org>
10276
10277 * regformats/regdat.sh: Generate code with
10278 "ifndef IN_PROCESS_AGENT".
10279
6e75794e
PA
102802017-06-28 Pedro Alves <palves@redhat.com>
10281
10282 * command.h: Include "common/scoped_restore.h".
10283
bc491f2e
YQ
102842017-06-28 Yao Qi <yao.qi@linaro.org>
10285
10286 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
10287 instead of obstack_grow.
10288
41664b45
DG
102892017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
10290
10291 PR gdb/21337
10292 * symfile.c (reread_symbols): Call objfiles_changed just before
10293 read_symbols.
10294
6da67eb1
PA
102952017-06-27 Pedro Alves <palves@redhat.com>
10296
10297 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
10298 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
10299 (completion_list_add_symbol, completion_list_add_msymbol):
10300 ... these new functions.
10301 (add_symtab_completions)
10302 (default_make_symbol_completion_list_break_on_1): Adjust.
10303
23732b1e
PA
103042017-06-27 Pedro Alves <palves@redhat.com>
10305
10306 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
10307 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
10308 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
10309 dtor.
10310 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
10311 'storage_obstack' field an auto_obstack. In-class initialize all
10312 non-bitfield fields. Make minsyms_read bool.
10313 * symfile.c (read_symbols): Adjust.
10314
a4d1e79a
AH
103152017-06-27 Alan Hayward <alan.hayward@arm.com>
10316
10317 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
10318 (gdbsim_store_register): Likewise.
10319
8268c778
PA
103202017-06-27 Pedro Alves <palves@redhat.com>
10321
10322 * c-exp.y (name_obstack): Now an auto_obstack.
10323 (yylex): Use auto_obstack::clear.
10324 (c_parse): Use auto_obstack::clear instead of reinitializing and
10325 freeing the obstack.
10326 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
10327 * d-exp.y (name_obstack): Now an auto_obstack.
10328 (yylex): Use auto_obstack::clear.
10329 (d_parse): Use auto_obstack::clear instead of reinitializing and
10330 freeing the obstack.
10331 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
10332 auto_obstack.
10333 * dwarf2read.c (create_addrmap_from_index)
10334 (dwarf2_build_psymtabs_hard)
10335 (update_enumeration_type_from_children): Likewise.
10336 * gdb_obstack.h (auto_obstack): New type.
10337 * go-exp.y (name_obstack): Now an auto_obstack.
10338 (build_packaged_name): Use auto_obstack::clear.
10339 (go_parse): Use auto_obstack::clear instead of reinitializing and
10340 freeing the obstack.
10341 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
10342 auto_obstack.
10343 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
10344 * rust-exp.y (work_obstack): Now an auto_obstack.
10345 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
10346 reinitializing and freeing the obstack.
10347 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
10348 (host_char_to_target): Use auto_obstack.
10349 * utils.h (make_cleanup_obstack_free): Delete declaration.
10350 * valprint.c (generic_emit_char, generic_printstr): Use
10351 auto_obstack.
10352
db665f42
SM
103532017-06-27 Simon Marchi <simon.marchi@ericsson.com>
10354
10355 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
10356 thread.
10357 (darwin_init_thread_list): Don't update dummy thread.
10358 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
10359
873c0814
SM
103602017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10361
10362 * record-full.c (netorder16): Remove.
10363
8b5a7a6e
SM
103642017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10365
10366 * common/diagnostics.h: Define macros for GCC.
10367 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
10368 * common/vec.h: Include diagnostics.h.
10369 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
10370 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
10371 warning.
10372
d1435379
SM
103732017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10374
10375 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
10376 New macro.
10377 * ada-lex.l: Ignore deprecated register warnings.
10378
cc75e0fd
SM
103792017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10380
10381 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
10382 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
10383
07809eaf
SM
103842017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10385
10386 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
10387 its own line.
10388
f076f034
SM
103892017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10390
10391 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
10392
0dd5cbc5
AH
103932017-06-23 Alan Hayward <alan.hayward@arm.com>
10394
10395 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
10396 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
10397 (xtensa_register_read_masked): Likewise.
10398
d4c6ce5b
SDJ
103992017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
10400
10401 * common/environ.c (gdb_environ::unset): Update comment.
10402
16892a03
AH
104032017-06-22 Alan Hayward <alan.hayward@arm.com>
10404
10405 * python/py-unwind.c (pyuw_sniffer): Allocate space for
10406 registers.
10407
d7dcbefc
AH
104082017-06-22 Alan Hayward <alan.hayward@arm.com>
10409
10410 * record-full.c (record_full_exec_insn): Use byte_vector.
10411
b30ff123
YQ
104122017-06-22 Yao Qi <yao.qi@linaro.org>
10413
10414 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
10415 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
10416
4fa847d7
AH
104172017-06-22 Alan Hayward <alan.hayward@arm.com>
10418
10419 * remote.c (cached_reg): Move from here...
10420 * regcache.h (cached_reg): ...to here.
10421 * python/py-unwind.c (struct reg_info): Remove.
10422 (cached_frame_info): Use cached_reg_t.
10423 (pyuw_prev_register): Likewise.
10424 (pyuw_sniffer): Use cached_reg_t and allocate registers.
10425 (pyuw_dealloc_cache): Free all registers.
10426
f4906a9a
PA
104272017-06-22 Pedro Alves <palves@redhat.com>
10428 Simon Marchi <simon.marchi@ericsson.com>
10429
10430 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
10431 warning.
10432 * common/diagnostics.h: New file.
10433
b45a1208
PA
104342017-06-22 Pedro Alves <palves@redhat.com>
10435
10436 * common/agent.h: Add include guards.
10437
e4da2c61
SM
104382017-06-21 Simon Marchi <simon.marchi@ericsson.com>
10439
10440 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
10441 talk about addressable units instead of bytes.
10442
96160d60
SDJ
104432017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
10444
10445 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
10446 of '::const_iterator'.
10447
9a6c7d9c
SDJ
104482017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
10449
10450 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10451 'unittests/environ-selftests.c'.
10452 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
10453 * charset.c (find_charset_names): Declare object 'iconv_env'.
10454 Update code to use 'iconv_env' object. Remove call to
10455 'free_environ'.
10456 * common/environ.c: Include <utility>.
10457 (make_environ): Delete function.
10458 (free_environ): Delete function.
10459 (gdb_environ::clear): New function.
10460 (gdb_environ::operator=): New function.
10461 (gdb_environ::get): Likewise.
10462 (environ_vector): Delete function.
10463 (set_in_environ): Delete function.
10464 (gdb_environ::set): New function.
10465 (unset_in_environ): Delete function.
10466 (gdb_environ::unset): New function.
10467 (gdb_environ::envp): Likewise.
10468 * common/environ.h: Include <vector>.
10469 (struct gdb_environ): Delete; transform into...
10470 (class gdb_environ): ... this class.
10471 (free_environ): Delete prototype.
10472 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
10473 environ_vector): Likewise.
10474 * infcmd.c (run_command_1): Update code to call
10475 'envp' from 'gdb_environ' class.
10476 (environment_info): Update code to call methods from 'gdb_environ'
10477 class.
10478 (unset_environment_command): Likewise.
10479 (path_info): Likewise.
10480 (path_command): Likewise.
10481 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
10482 (inferior::inferior): Initialize 'environment' using the host's
10483 information.
10484 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
10485 Include "environ.h".
10486 (class inferior) <environment>: Change type from 'struct
10487 gdb_environ' to 'gdb_environ'.
10488 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
10489 methods from 'gdb_environ' class.
10490 * solib.c (solib_find_1): Likewise
10491 * unittests/environ-selftests.c: New file.
10492
75c554cf
YQ
104932017-06-20 Yao Qi <yao.qi@linaro.org>
10494
10495 * features/i386/i386-linux.xml: Exchange the order of including
10496 32bit-linux.xml and 32bit-sse.xml.
10497 * features/i386/i386-linux.c: Regenerated.
10498
72ddacb7
YQ
104992017-06-20 Yao Qi <yao.qi@linaro.org>
10500
10501 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
10502 Delete copy ctor and assignment operator.
10503 (tdesc_type): Likewise.
10504 (tdesc_feature): Likewise.
10505 (tdesc_free_reg): Remove.
10506 (tdesc_create_reg): Use new.
10507 (tdesc_free_type): Remove.
10508 (tdesc_create_vector): Use new.
10509 (tdesc_create_union): Likewise.
10510 (tdesc_create_flags): Likewise.
10511 (tdesc_create_enum): Likewise.
10512 (tdesc_free_feature): Delete.
10513 (free_target_description): Use delete.
10514
325c9fd4
JB
105152017-06-19 John Baldwin <jhb@FreeBSD.org>
10516
10517 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
10518 registers.
10519
16b7a719
PA
105202017-06-19 Pedro Alves <palves@redhat.com>
10521
10522 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
10523 after gdb::unlinker.
10524
1c8e01c9
SDJ
105252017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
10526
10527 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
10528 gdb_environ to access an environment variable.
10529
ffce45d2
TP
105302017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
10531
10532 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
10533 gdb_byte*.
10534
1d4fbac9
SM
105352017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10536
10537 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
10538
8465943a
SM
105392017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10540
10541 * configure: Re-generate.
10542 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
10543
3e019bdc
SM
105442017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10545
10546 * configure: Re-generate.
10547 * warning.m4: Pass -Werror to compiler when checking for
10548 supported warning flags.
10549
cf0dd6f0
SM
105502017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10551
10552 * Makefile.in (COMPILE.pre): Add "-x c++".
10553
6f98355c
YQ
105542017-06-16 Alan Hayward <alan.hayward@arm.com>
10555 Pedro Alves <palves@redhat.com>
10556 Yao Qi <yao.qi@linaro.org>
10557
10558 * defs.h (RequireLongest): New.
10559 (extract_integer): Declare function template.
10560 (extract_signed_integer): Remove the declaration, but define it
10561 static inline.
10562 (extract_unsigned_integer): Likewise.
10563 (store_integer): Declare function template.
10564 (store_signed_integer): Remove the declaration, but define it
10565 static inline.
10566 (store_unsigned_integer): Likewise.
10567 * findvar.c (extract_integer): New function template.
10568 (extract_signed_integer): Remove.
10569 (extract_unsigned_integer): Remove.
10570 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
10571 instantiations.
10572 (store_integer): New function template.
10573 (store_signed_integer): Remove.
10574 (store_unsigned_integer): Remove.
10575 (store_integer): Explicit instantiations.
10576 * regcache.c (regcache_raw_read_signed): Update.
10577 (regcache::raw_read): New function.
10578 (regcache::raw_read_signed): Remove.
10579 (regcache::raw_read_unsigned): Remove.
10580 (regcache_raw_read_unsigned): Update.
10581 (regcache_raw_write_unsigned): Update.
10582 (regcache::raw_write_signed): Remove.
10583 (regcache::raw_write): New function.
10584 (regcache_cooked_read_signed): Update.
10585 (regcache::raw_write_unsigned): Remove.
10586 (regcache::cooked_read_signed): Remove.
10587 (regcache_cooked_read_unsigned): Update.
10588 (regcache::cooked_read_unsigned): Remove.
10589 (regcache_cooked_write_signed): Update.
10590 (regcache_cooked_write_unsigned): Update.
10591 * regcache.h (regcache) <raw_read_signed>: Remove.
10592 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
10593 <raw_read, raw_write>: New.
10594 <cooked_read_signed, cooked_write_signed>: Remove.
10595 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
10596 <cooked_read, cooked_write>: New.
10597 * sh64-tdep.c (sh64_pseudo_register_read): Update.
10598 (sh64_pseudo_register_write): Update.
10599
a87dc45a
AK
106002017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
10601
10602 * arc-tdep.c (arc_disassembler_options): New variable.
10603 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
10604 of default_print_insn.
10605 (arc_delayed_print_insn): Set info->section when needed,
10606 use default_print_insn to retrieve a disassembler.
10607
45159d6a
SDJ
106082017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
10609
10610 PR gdb/21574
10611 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
10612 to mention $SHELL and startup-with-shell.
10613
b46c4cf0
MF
106142017-06-14 Max Filippov <jcmvbkbc@gmail.com>
10615
10616 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
10617
6394c606
YQ
106182017-06-14 Yao Qi <yao.qi@linaro.org>
10619
10620 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
10621 default_print_insn instead of print_insn_aarch64.
10622 * arm-tdep.c (gdb_print_insn_arm): Call
10623 default_print_insn instead of print_insn_big_arm
10624 and print_insn_little_arm.
10625 * i386-tdep.c (i386_print_insn): Call default_print_insn
10626 instead of print_insn_i386.
10627 * ia64-tdep.c (ia64_print_insn): Call
10628 default_print_insn instead of print_insn_ia64.
10629 * mips-tdep.c (gdb_print_insn_mips): Call
10630 default_print_insn instead of print_insn_big_mips
10631 and print_insn_little_mips.
10632 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
10633 instead of print_insn_spu.
10634
d5722aa2
PA
106352017-06-14 Pedro Alves <palves@redhat.com>
10636
10637 * ada-lang.c: Include "common/byte-vector.h".
10638 (ada_value_primitive_packed_val): Use gdb::byte_vector.
10639 * charset.c (wchar_iterator::iterate): Resize the vector instead
10640 of reserving it.
10641 * common/byte-vector.h: Include "common/def-vector.h".
10642 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
10643 * cli/cli-dump.c: Include "common/byte-vector.h".
10644 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
10645 * common/byte-vector.h: New file.
10646 * common/def-vector.h: New file.
10647 * common/default-init-alloc.h: New file.
10648 * dwarf2loc.c: Include "common/byte-vector.h".
10649 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
10650 instead of reserving it.
10651 * dwarf2read.c: Include "common/byte-vector.h".
10652 (data_buf::m_vec): Now a gdb::byte_vector.
10653 * gdb_regex.c: Include "common/def-vector.h".
10654 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
10655 * mi/mi-main.c: Include "common/byte-vector.h".
10656 (mi_cmd_data_read_memory): Use gdb::byte_vector.
10657 * printcmd.c: Include "common/byte-vector.h".
10658 (print_scalar_formatted): Use gdb::byte_vector.
10659 * valprint.c: Include "common/byte-vector.h".
10660 (maybe_negate_by_bytes, print_decimal_chars): Use
10661 gdb::byte_vector.
10662
01ec7a27
SM
106632017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10664
10665 * darwin-nat.c: Include "nat/fork-inferior.h".
10666
848d9074
SM
106672017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10668
10669 * configure.nat: Factor out Darwin bits that are not
10670 architecture-specific. Add fork-inferior.o.
10671
3b912944
SM
106722017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10673
10674 * configure.nat: Factor out AIX bits that are not
10675 architecture-specific. Add fork-inferior.o.
10676
55acdf22
AA
106772017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10678
10679 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
10680 (read_pieced_value, write_pieced_value): ...here. Reduce to
10681 wrappers that just call rw_pieced_value.
10682
f65e2044
AA
106832017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10684
10685 * dwarf2loc.c (write_pieced_value): When writing the data for a
10686 memory piece, use write_memory_with_notification instead of
10687 write_memory.
10688
23f945bf
AA
106892017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10690
10691 * valops.c (read_value_memory): Change embedded_offset to
10692 represent a bit offset instead of a byte offset.
10693 * value.h (read_value_memory): Adjust comment.
10694
f236533e
AA
106952017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10696
10697 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
10698 dest_offset_bits and source_offset_bits.
10699 (write_pieced_value): Likewise.
10700
65d84b76
AA
107012017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10702
10703 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
10704 given by DW_OP_bit_piece.
10705 (write_pieced_value): Likewise.
10706
242d31ab
AA
107072017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10708
10709 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
10710 some other preparations to the places where sufficient information
10711 is available.
10712 (write_pieced_value): Likewise.
10713
03c8af18
AA
107142017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10715
10716 * dwarf2loc.c (bits_to_bytes): New function.
10717 (read_pieced_value): Fix offset calculations for register pieces
10718 on big-endian targets.
10719 (write_pieced_value): Likewise.
10720
840989c1
AA
107212017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10722
10723 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
10724 (write_pieced_value): Likewise.
10725
359b19bb
AA
107262017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10727
10728 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
10729 transfer the source value's least significant bits, instead of its
10730 lowest-addressed ones. Rename type_len to max_offset.
10731 (read_pieced_value): Mirror above changes to write_pieced_value as
10732 applicable.
10733
07c9ca3b
AA
107342017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10735
10736 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
10737 truncate full bytes from dest_offset_bits before using it as an
10738 offset into the buffer.
10739
f1cc9874
AA
107402017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10741
10742 * dwarf2loc.c (write_pieced_value): Include transfer size in
10743 byte-wise check.
10744
cdaac320
AA
107452017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10746
10747 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
10748 calculation of this_size.
10749
af547a96
AA
107502017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10751
10752 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
10753 when targeting a bit-field.
10754 (write_pieced_value): Likewise.
10755
ddd7882a
AA
107562017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10757
10758 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
10759 (allocate_piece_closure): Drop addr_size parameter.
10760 (dwarf2_evaluate_loc_desc_full): Adjust call to
10761 allocate_piece_closure.
10762
e9352324
AA
107632017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10764
10765 PR gdb/21226
10766 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
10767 the LSB end, independent of endianness.
10768
d5d1163e
AA
107692017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10770
10771 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
10772 size capping.
10773
032bb6ea
YQ
107742017-06-13 Yao Qi <yao.qi@linaro.org>
10775
10776 * mips-linux-nat.c: Move include features/mips*-linux.c to
10777 mips-linux-tdep.c.
10778 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
10779 to mips-linux-tdep.c.
10780 * mips-linux-tdep.c: Include features/mips*-linux.c
10781 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
10782 functions.
10783 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
10784 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
10785 (tdesc_mips64_dsp_linux): Declare.
10786
f12f6bad
TT
107872017-06-12 Tom Tromey <tom@tromey.com>
10788
10789 * valprint.h (val_print_type_code_int): Remove.
10790 * valprint.c (generic_val_print_int): Always call
10791 val_print_scalar_formatted.
10792 (val_print_type_code_int): Remove.
10793 * printcmd.c (print_scalar_formatted): Handle options->format==0.
10794 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
10795 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
10796 * ada-valprint.c (ada_val_print_num): Use
10797 val_print_scalar_formatted.
10798
d9109c80
TT
107992017-06-12 Tom Tromey <tom@tromey.com>
10800
10801 * printcmd.c (print_scalar_formatted): Unify the two switches.
10802 Don't convert scalars to LONGEST.
10803
4ac0cb1c
TT
108042017-06-12 Tom Tromey <tom@tromey.com>
10805
10806 PR exp/16225:
10807 * valprint.h (print_decimal_chars): Update.
10808 * valprint.c (maybe_negate_by_bytes): New function.
10809 (print_decimal_chars): Add "is_signed" argument.
10810 * printcmd.c (print_scalar_formatted): Update.
10811
30a25466
TT
108122017-06-12 Tom Tromey <tom@tromey.com>
10813
10814 PR exp/16225:
10815 * valprint.h (print_binary_chars, print_hex_chars): Update.
10816 * valprint.c (val_print_type_code_int): Update.
10817 (print_binary_chars): Add "zero_pad" argument.
10818 (emit_octal_digit): New function.
10819 (print_octal_chars): Don't zero-pad.
10820 (print_decimal_chars): Likewise.
10821 (print_hex_chars): Add "zero_pad" argument.
10822 * sh64-tdep.c (sh64_do_fp_register): Update.
10823 * regcache.c (regcache::dump): Update.
10824 * printcmd.c (print_scalar_formatted): Update.
10825 * infcmd.c (default_print_one_register_info): Update.
10826
b3464d03
PA
108272017-06-12 Pedro Alves <palves@redhat.com>
10828 Alan Hayward <alan.hayward@arm.com>
10829
10830 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
10831 (mips_eabi_push_dummy_call): Rename local 'regsize' to
10832 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
10833 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
10834 Assert that abi_regsize bytes fit in 'ref_valbuf'.
10835
4b76cda9
PA
108362017-06-12 Pedro Alves <palves@redhat.com>
10837
10838 * dwarf2read.c (mapped_symtab::data): Now a vector of
10839 symtab_index_entry instead of vector of
10840 std::unique_ptr<symtab_index_entry>. All users adjusted to check
10841 whether an element's name is NULL instead of checking whether the
10842 element itself is NULL.
10843 (find_slot): Change return type. Adjust.
10844 (hash_expand, , add_index_entry, uniquify_cu_indices)
10845 (write_hash_table): Adjust.
10846
e8f8bcb3
PA
108472017-06-12 Pedro Alves <palves@redhat.com>
10848
10849 * dwarf2read.c (recursively_count_psymbols): New function.
10850 (write_psymtabs_to_index): Call it to compute number of psyms and
10851 pass estimate size of psyms_seen to unordered_set's ctor.
10852
70a1152b
PA
108532017-06-12 Pedro Alves <palves@redhat.com>
10854
10855 * dwarf2read.c (write_hash_table): Check if key already exists
10856 before emplacing.
10857
c2f134ac
PA
108582017-06-12 Pedro Alves <palves@redhat.com>
10859
10860 * dwarf2read.c (data_buf::append_space): Rename to...
10861 (data_buf::grow): ... this, and make private. Adjust all callers.
10862 (data_buf::append_uint): New method.
10863 (add_address_entry, write_one_signatured_type)
10864 (write_psymtabs_to_index): Use it.
10865
a81e6d4d
PA
108662017-06-12 Pedro Alves <palves@redhat.com>
10867
10868 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
10869 (file_write (FILE *, const std::vector<Elem>&)): Delete.
10870 (data_buf::file_write): Call ::fwrite directly.
10871
6fd931f2
PA
108722017-06-12 Pedro Alves <palves@redhat.com>
10873
10874 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
10875 std::vector::erase.
10876
bc8f2430
JK
108772017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
10878
10879 Code cleanup: C++ify .gdb_index producer.
10880 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
10881 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
10882 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
10883 (create_strtab, add_string): Remove.
10884 (file_write, data_buf): New.
10885 (struct symtab_index_entry): Use std::vector for cu_indices.
10886 (struct mapped_symtab): Use std::vector for data.
10887 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
10888 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
10889 Remove.
10890 (find_slot): Change return type. Update it to the new data structures.
10891 (hash_expand, add_index_entry): Update it to the new data structures.
10892 (offset_type_compare): Remove.
10893 (uniquify_cu_indices): Update it to the new data structures.
10894 (c_str_view, c_str_view_hasher, vector_hasher): New.
10895 (add_indices_to_cpool): Remove.
10896 (write_hash_table): Update it to the new data structures.
10897 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
10898 (eq_psymtab_cu_index): Remove.
10899 (psym_index_map): New typedef.
10900 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
10901 reference and std::unordered_map for cu_index_htab.
10902 (add_address_entry, add_address_entry_worker, write_address_map)
10903 (write_psymbols): Update it to the new data structures.
10904 (write_obstack): Remove.
10905 (struct signatured_type_index_data): Change types_list to a data_buf
10906 reference and psyms_seen to a std::unordered_set reference.
10907 (write_one_signatured_type, recursively_write_psymbols)
10908 (write_psymtabs_to_index): Update it to the new data structures.
10909
c4dcb155
SM
109102017-06-11 Simon Marchi <simon.marchi@ericsson.com>
10911
10912 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
10913 separate-debug-file commands.
10914 * symfile.h (separate_debug_file_debug): New global.
10915 * symfile.c (separate_debug_file_debug): New global.
10916 (separate_debug_file_exists, find_separate_debug_file): Add
10917 debug output.
10918 (_initialize_symfile): Add "set debug separate-debug-file"
10919 command.
10920 * build-id.c (build_id_to_debug_bfd,
10921 find_separate_debug_file_by_buildid): Add debug output.
10922
6d45d4b4
SM
109232017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
10924
10925 * gdbarch.sh (displaced_step_free_closure): Remove.
10926 * gdbarch.h, gdbarch.c: Re-generate.
10927 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
10928 displaced_step_free_closure.
10929 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
10930 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
10931 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
10932 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
10933 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
10934 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
10935 * arch-utils.h (simple_displaced_step_free_closure): Remove.
10936 * arch-utils.c (simple_displaced_step_free_closure): Remove.
10937 * infrun.c (displaced_step_clear): Call xfree instead of
10938 gdbarch_displaced_step_free_closure.
10939
2f91880f
SDJ
109402017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
10941
10942 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
10943 NULL".
10944
b8b6e72f
AH
109452017-06-08 Alan Hayward <alan.hayward@arm.com>
10946
10947 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
10948 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
10949 (mn10300_push_dummy_call): Likewise.
10950
5369082e
AH
109512017-06-08 Alan Hayward <alan.hayward@arm.com>
10952
10953 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
10954
ff4ca5ac
AH
109552017-06-08 Alan Hayward <alan.hayward@arm.com>
10956
10957 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
10958
aefd8b33
SDJ
109592017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10960
10961 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
10962 able to start inferiors using a shell.
10963 (New remote packets): Announce new packet "QStartupWithShell".
10964 * remote.c: Add PACKET_QStartupWithShell.
10965 (extended_remote_create_inferior): Handle new
10966 PACKET_QStartupWithShell.
10967 (remote_protocol_features) <QStartupWithShell>: New entry for
10968 PACKET_QStartupWithShell.
10969 (_initialize_remote): Call "add_packet_config_cmd" for
10970 QStartupShell.
10971
2090129c
SDJ
109722017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10973 Pedro Alves <palves@redhat.com>
10974
10975 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
10976 and "nat/fork-inferior.h".
10977 * common/common-inferior.h: New file, with contents from
10978 "gdb/inferior.h".
10979 * commom/common-utils.c: Include "common-utils.h".
10980 (stringify_argv): New function.
10981 * common/common-utils.h (stringify_argv): New prototype.
10982 * configure.nat: Add "fork-inferior.o" as a dependency for
10983 "*linux*", "fbsd*" and "nbsd*" hosts.
10984 * corefile.c (get_exec_file): Update comment.
10985 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
10986 instead of "startup_inferior".
10987 (darwin_create_inferior): Call "add_thread_silent" after
10988 "fork_inferior".
10989 * fork-child.c: Cleanup unnecessary includes.
10990 (SHELL_FILE): Move to "common/common-fork-child.c".
10991 (environ): Likewise.
10992 (exec_wrapper): Initialize.
10993 (get_exec_wrapper): New function.
10994 (breakup_args): Move to "common/common-fork-child.c"; rename to
10995 "breakup_args_for_exec".
10996 (escape_bang_in_quoted_argument): Move to
10997 "common/common-fork-child.c".
10998 (saved_ui): New variable.
10999 (prefork_hook): New function.
11000 (postfork_hook): Likewise.
11001 (postfork_child_hook): Likewise.
11002 (gdb_startup_inferior): Likewise.
11003 (fork_inferior): Move to "common/common-fork-child.c". Update
11004 function to support gdbserver.
11005 (startup_inferior): Likewise.
11006 * gdbcore.h (get_exec_file): Remove declaration.
11007 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
11008 instead of "startup_inferior". Call "add_thread_silent" after
11009 "fork_inferior".
11010 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
11011 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
11012 instead of "startup_inferior". Call "add_thread_silent" after
11013 "fork_inferior".
11014 * inferior.h: Include "common-inferior.h".
11015 (trace_start_error): Move to "common/common-utils.h".
11016 (trace_start_error_with_name): Likewise.
11017 (fork_inferior): Move prototype to "nat/fork-inferior.h".
11018 (startup_inferior): Likewise.
11019 (gdb_startup_inferior): New prototype.
11020 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
11021 * nat/fork-inferior.h: New file.
11022 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
11023 instead of "startup_inferior". Call "add_thread_silent" after
11024 "fork_inferior".
11025 * target.h (target_terminal_init): Move prototype to
11026 "target/target.h".
11027 (target_terminal_inferior): Likewise.
11028 (target_terminal_ours): Likewise.
11029 * target/target.h (target_terminal_init): New prototype, moved
11030 from "target.h".
11031 (target_terminal_inferior): Likewise.
11032 (target_terminal_ours): Likewise.
11033 * utils.c (gdb_flush_out_err): New function.
11034
043a4934
SDJ
110352017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11036
11037 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
11038 * common/common-gdbthread.h: New file, with parts from
11039 "gdb/gdbthread.h".
11040 * gdbthread.h: Include "common-gdbthread.h".
11041 (switch_to_thread): Moved to "common/common-gdbthread.h".
11042
15652511
SDJ
110432017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11044
11045 * Makefile.in (SFILES): Add "common/job-control.c".
11046 (HFILES_NO_SRCDIR): Add "common/job-control.h".
11047 (COMMON_OBS): Add "job-control.o".
11048 * common/job-control.c: New file, with contents from
11049 "gdb/inflow.c".
11050 * common/job-control.h: New file, with contents from "terminal.h".
11051 * fork-child.c: Include "job-control.h".
11052 * inflow.c: Include "job-control.h".
11053 (gdb_setpgid): Move to "common/common-inflow.c".
11054 (_initialize_inflow): Move setting of "job_control" to
11055 "handle_job_control".
11056 * terminal.h (job_control): Moved to "common/common-terminal.h".
11057 (gdb_setpgid): Likewise.
11058 * top.c: Include "job_control.h".
11059 * utils.c: Likewise.
11060 (job_control): Moved to "job-control.c".
11061
2d7cc5c7
PA
110622017-06-07 Pedro Alves <palves@redhat.com>
11063
11064 * Makefile.in (SFILES): Add gdb_regex.c.
11065 (COMMON_OBS): Add gdb_regex.o.
11066 * ada-lang.c (ada_add_standard_exceptions)
11067 (ada_add_exceptions_from_frame, name_matches_regex)
11068 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
11069 parameter type to compiled_regex. Adjust.
11070 (ada_exceptions_list): Use compiled_regex.
11071 * break-catch-throw.c (exception_catchpoint::pattern): Now a
11072 std::unique_ptr<compiled_regex>.
11073 (exception_catchpoint::~exception_catchpoint): Remove regfree
11074 call.
11075 (check_status_exception_catchpoint): Adjust to use compiled_regex.
11076 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
11077 * breakpoint.c (solib_catchpoint::compiled): Now a
11078 std::unique_ptr<compiled_regex>.
11079 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
11080 (check_status_catch_solib): Adjust to use compiled_regex.
11081 (add_solib_catchpoint): Adjust to use compiled_regex.
11082 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
11083 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
11084 compiled_regex reference. Adjust to use it.
11085 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
11086 declaration. Include "gdb_regex.h".
11087 (apropos_cmd): Change regex parameter to compiled_regex reference.
11088 * gdb_regex.c: New file.
11089 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
11090 declarations.
11091 (class compiled_regex): New.
11092 * linux-tdep.c: Include "common/gdb_optional.h".
11093 (struct mapping_regexes): New, factored out from
11094 mapping_is_anonymous_p, and adjusted to use compiled_regex.
11095 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
11096 gdb::optional and remove cleanups. Adjust to compiled_regex.
11097 * probe.c: Include "common/gdb_optional.h".
11098 (collect_probes): Use compiled_regex and gdb::optional and remove
11099 cleanups.
11100 * skip.c: Include "common/gdb_optional.h".
11101 (skiplist_entry::compiled_function_regexp): Now a
11102 gdb::optional<compiled_regex>.
11103 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
11104 (free_skiplist_entry): Remove regfree call.
11105 (compile_skip_regexp, skip_rfunction_p): Adjust to use
11106 compiled_regex and gdb::optional.
11107 * symtab.c: Include "common/gdb_optional.h".
11108 (search_symbols): Use compiled_regex and gdb::optional.
11109 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
11110 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
11111 to gdb_regex.c.
11112
50d6adef
AH
111132017-06-07 Alan Hayward <alan.hayward@arm.com>
11114
11115 * regcache.c (regcache::save): Avoid buffer use.
11116 (regcache::dump): Likewise.
11117
4a8a33c8
AH
111182017-06-07 Alan Hayward <alan.hayward@arm.com>
11119
11120 * sh-tdep.c (sh_pseudo_register_read): Remove
11121 MAX_REGISTER_SIZE.
11122 (sh_pseudo_register_write): Likewise.
11123 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
11124 (sh64_pseudo_register_write): Likewise
11125
d1be909e
AH
111262017-06-07 Alan Hayward <alan.hayward@arm.com>
11127
11128 * aarch64-tdep.c (aarch64_store_return_value): Use
11129 V_REGISTER_SIZE.
11130 (aarch64_pseudo_read_value): Likewise.
11131 (aarch64_pseudo_write): Likewise.
11132
f4a65042
YQ
111332017-06-06 Yao Qi <yao.qi@linaro.org>
11134
11135 * regformats/regdef.h (set_register_cache): Remove the
11136 declaration.
11137
9f7fb0aa
AH
111382017-06-06 Alan Hayward <alan.hayward@arm.com>
11139
11140 * frame.c (frame_unwind_register_signed): Use
11141 frame_unwind_register_value.
11142
e1e01040
PA
111432017-06-06 Pedro Alves <palves@redhat.com>
11144
11145 PR breakpoints/21553
11146 * breakpoint.c (create_breakpoints_sal_default)
11147 (init_breakpoint_sal, create_breakpoint_sal): Use
11148 gdb::unique_xmalloc_ptr for string parameters.
11149 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11150 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
11151 (base_breakpoint_create_breakpoints_sal)
11152 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
11153 (strace_marker_create_breakpoints_sal)
11154 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
11155 string parameters.
11156 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
11157 gdb::unique_xmalloc_ptr for string parameters.
11158 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11159 parameters.
11160
fbe654c8
AH
111612017-06-06 Alan Hayward <alan.hayward@arm.com>
11162
11163 * alpha-tdep.c (alpha_register_to_value): Use
11164 get_frame_register_value.
11165 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
11166
ae0d01d6
AH
111672017-06-06 Alan Hayward <alan.hayward@arm.com>
11168
11169 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
11170 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
11171 (ia64_value_to_register): Likewise.
11172 (ia64_extract_return_value): Likewise.
11173 (ia64_store_return_value): Likewise.
11174 (ia64_push_dummy_call): Likewise.
11175
49cf576c
JB
111762017-06-04 Joel Brobecker <brobecker@adacore.com>
11177
11178 GDB 8.0 released.
11179
26b6a6ab
SM
111802017-06-03 Simon Marchi <simon.marchi@ericsson.com>
11181
11182 * x86-linux-nat.c (struct arch_lwp_info): Remove.
11183
22827c51
SM
111842017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
11185
11186 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
11187 parameter.
11188 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
11189
0e05cf3a
SM
111902017-06-02 Simon Marchi <simon.marchi@ericsson.com>
11191
11192 * event-loop.c (poll_timers): Unallocate timer using delete
11193 instead of xfree.
11194
c1fc2657
SM
111952017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11196
11197 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
11198 (struct breakpoint) <~breakpoint>: New.
11199 (struct watchpoint): Inherit from breakpoint.
11200 <~watchpoint>: New.
11201 <base>: Remove.
11202 (struct tracepoint): Inherit from breakpoint.
11203 <base>: Remove.
11204 * breakpoint.c (longjmp_breakpoint_ops): Remove.
11205 (struct longjmp_breakpoint): Inherit from breakpoint.
11206 <~longjmp_breakpoint>: New.
11207 <base>: Remove.
11208 (new_breakpoint_from_type): Remove casts.
11209 (watchpoint_in_thread_scope): Remove reference to base field.
11210 (watchpoint_del_at_next_stop): Likewise.
11211 (update_watchpoint): Likewise.
11212 (watchpoint_check): Likewise.
11213 (bpstat_check_watchpoint): Likewise.
11214 (set_longjmp_breakpoint): Likewise.
11215 (struct fork_catchpoint): Inherit from breakpoint.
11216 <base>: Remove.
11217 (struct solib_catchpoint): Inherit from breakpoint.
11218 <~solib_catchpoint>: New.
11219 <base>: Remove.
11220 (dtor_catch_solib): Change to ...
11221 (solib_catchpoint::~solib_catchpoint): ... this.
11222 (breakpoint_hit_catch_solib): Remove reference to base field.
11223 (add_solib_catchpoint): Likewise.
11224 (create_fork_vfork_event_catchpoint): Likewise.
11225 (struct exec_catchpoint): Inherit from breakpoint.
11226 <~exec_catchpoint>: New.
11227 <base>: Remove.
11228 (dtor_catch_exec): Change to ...
11229 (exec_catchpoint::~exec_catchpoint): ... this.
11230 (dtor_watchpoint): Change to ...
11231 (watchpoint::~watchpoint): ... this.
11232 (watch_command_1): Remove reference to base field.
11233 (catch_exec_command_1): Likewise.
11234 (base_breakpoint_dtor): Change to ...
11235 (breakpoint::~breakpoint): ... this.
11236 (base_breakpoint_ops): Remove dtor field value.
11237 (longjmp_bkpt_dtor): Change to ...
11238 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
11239 (strace_marker_create_breakpoints_sal): Remove reference to base
11240 field.
11241 (delete_breakpoint): Don't manually call breakpoint destructor.
11242 (create_tracepoint_from_upload): Remove reference to base field.
11243 (trace_pass_set_count): Likewise.
11244 (initialize_breakpoint_ops): Don't initialize
11245 momentary_breakpoint_ops, don't set dtors.
11246 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
11247 <~ada_catchpoint>: New.
11248 <base>: Remove.
11249 (create_excep_cond_exprs): Remove reference to base field.
11250 (dtor_exception): Change to ...
11251 (ada_catchpoint::~ada_catchpoint): ... this.
11252 (dtor_catch_exception): Remove.
11253 (dtor_catch_exception_unhandled): Remove.
11254 (dtor_catch_assert): Remove.
11255 (create_ada_exception_catchpoint): Remove reference to base
11256 field.
11257 (initialize_ada_catchpoint_ops): Don't set dtors.
11258 * break-catch-sig.c (struct signal_catchpoint): Inherit from
11259 breakpoint.
11260 <~signal_catchpoint>: New.
11261 <base>: Remove.
11262 (signal_catchpoint_dtor): Change to ...
11263 (signal_catchpoint::~signal_catchpoint): ... this.
11264 (create_signal_catchpoint): Remove reference to base field.
11265 (initialize_signal_catchpoint_ops): Don't set dtor.
11266 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
11267 from breakpoint.
11268 <~syscall_catchpoint>: New.
11269 <base>: Remove.
11270 (dtor_catch_syscall): Change to ...
11271 (syscall_catchpoint::~syscall_catchpoint): ... this.
11272 (create_syscall_event_catchpoint): Remove reference to base
11273 field.
11274 (initialize_syscall_catchpoint_ops): Don't set dtor.
11275 * break-catch-throw.c (struct exception_catchpoint): Inherit
11276 from breakpoint.
11277 <~exception_catchpoint>: New.
11278 <base>: Remove.
11279 (dtor_exception_catchpoint): Change to ...
11280 (exception_catchpoint::~exception_catchpoint): ... this.
11281 (handle_gnu_v3_exceptions): Remove reference to base field.
11282 (initialize_throw_catchpoint_ops): Don't set dtor.
11283 * ctf.c (ctf_get_traceframe_address): Remove reference to base
11284 field.
11285 * remote.c (remote_get_tracepoint_status): Likewise.
11286 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
11287 * tracefile.c (tracefile_fetch_registers): Likewise.
11288 * tracepoint.c (actions_command): Likewise.
11289 (validate_actionline): Likewise.
11290 (tfind_1): Likewise.
11291 (get_traceframe_location): Likewise.
11292 (find_matching_tracepoint_location): Likewise.
11293 (parse_tracepoint_status): Likewise.
11294 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
11295
3b0871f4
SM
112962017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11297
11298 * breakpoint.c (struct longjmp_breakpoint): New struct.
11299 (is_tracepoint_type): Change return type to bool.
11300 (is_longjmp_type): New function.
11301 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
11302 (set_raw_breakpoint_without_location): Use
11303 new_breakpoint_from_type.
11304 (set_raw_breakpoint): Likewise.
11305
a5e364af
SM
113062017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11307
11308 * breakpoint.c (new_breakpoint_from_type): New function.
11309 (create_breakpoint_sal): Use new_breakpoint_from_type and
11310 unique_ptr.
11311 (create_breakpoint): Likewise.
11312
ae3b3f34
SM
113132017-05-31 Simon Marchi <simon.marchi@ericsson.com>
11314
11315 * memattr.c (mem_info_command): Rename to ...
11316 (info_mem_command): ... this.
11317 (mem_enable_command): Rename to ...
11318 (enable_mem_command): ... this.
11319 (mem_disable_command): Rename to ...
11320 (disable_mem_command): ... this.
11321 (mem_delete_command): Rename to ...
11322 (delete_mem_command): ... this.
11323 (_initialize_mem): Adjust function names.
11324
13ace077
MM
113252017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11326
11327 * btrace.c (handle_pt_insn_events): New.
11328 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
11329 STATUS. Split into this and ...
11330 (handle_pt_insn_event_flags): ... this.
11331
c56ccc05
MM
113322017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11333
11334 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
11335 and struct pt_insn.resynced.
11336 * configure: Regenerated.
11337 * config.in: Regenerated.
11338
08c3f6d2
TW
113392017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11340
11341 * btrace.c (ftrace_find_call_by_number): New function.
11342 (ftrace_new_function): Store objects, not pointers.
11343 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
11344 ftrace_new_gap, ftrace_update_function,
11345 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
11346 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
11347 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
11348 btrace_ends_with_single_insn, btrace_call_get): Account for
11349 btrace_thread_info::functions now storing objects.
11350 * btrace.h (struct btrace_thread_info): Add constructor.
11351 (struct btrace_thread_info) <functions>: Make std::vector.
11352 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
11353 Initialize with default values.
11354 * record-btrace.c (record_btrace_frame_sniffer): Account for
11355 btrace_thread_info::functions now storing objects.
11356
8ffd39f2
TW
113572017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11358
11359 * btrace.c: Remove typedef bfun_s.
11360 (ftrace_new_gap): Directly add gaps to the list of gaps.
11361 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
11362 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
11363 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
11364 instead of gdb VEC.
11365
4aeb0dfc
TW
113662017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11367
11368 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
11369 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
11370 with btrace_thread_info::next_segment and
11371 btrace_thread_info::prev_segment.
11372 * btrace.h: Remove struct btrace_func_link.
11373 (struct btrace_function): Replace pair of function segment pointers
11374 with pair of indices.
11375 * python/py-record-btrace.c (btpy_call_prev_sibling,
11376 btpy_call_next_sibling): Replace references to
11377 btrace_thread_info::segment with btrace_thread_info::next_segment and
11378 btrace_thread_info::prev_segment.
11379 * record-btrace.c (record_btrace_frame_this_id): Use
11380 btrace_find_call_by_number.
11381
eb8f2b9c
TW
113822017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11383
11384 * btrace.c (ftrace_new_function, ftrace_fixup_level,
11385 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
11386 btrace_insn_next, btrace_insn_prev): Remove references to
11387 btrace_thread_info::flow.
11388 * btrace.h (struct btrace_function): Remove FLOW.
11389
42bfe59e
TW
113902017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11391
11392 * btrace.c (ftrace_find_call_by_number): New function.
11393 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
11394 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
11395 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
11396 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
11397 index.
11398 * btrace.h (struct btrace_function): Turn UP into an index.
11399 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
11400 as an index.
11401 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
11402 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
11403 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
11404
b54b03bd
TW
114052017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11406
11407 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
11408 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
11409 ftrace_update_function, ftrace_compute_global_level_offset,
11410 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
11411 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
11412 btrace_insn_end, btrace_is_empty): Remove references to
11413 btrace_thread_info::begin and btrace_thread_info::end.
11414 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
11415 (struct btrace_thread_info) <functions>: Adjust comment.
11416 * record-btrace.c (record_btrace_start_replaying): Remove reference to
11417 btrace_thread_info::begin.
11418
8286623c
TW
114192017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11420
11421 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
11422 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
11423 ftrace_update_function): Remove arguments that implicitly were always
11424 BTINFO->END.
11425 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
11426 Don't pass BTINFO->END.
11427
a0f1b963
TW
114282017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11429
11430 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
11431 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
11432 btrace_find_insn_by_number): Replace function segment pointer with
11433 index.
11434 (btrace_insn_cmp): Simplify.
11435 * btrace.h: (struct btrace_insn_iterator) Rename index to
11436 insn_index. Replace function segment pointer with index into function
11437 segment vector.
11438 * record-btrace.c (record_btrace_call_history): Replace function
11439 segment pointer use with index.
11440 (record_btrace_frame_sniffer): Retrieve function call segment through
11441 vector.
11442 (record_btrace_set_replay): Remove defunc't safety check.
11443
f158f208
TW
114442017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11445
11446 * btrace.c (btrace_ends_with_single_insn): New function.
11447 (btrace_call_get, btrace_call_number, btrace_call_begin,
11448 btrace_call_end, btrace_call_next, btrace_call_prev,
11449 btrace_find_call_by_number): Use index into call segment vector
11450 instead of pointer.
11451 (btrace_call_cmp): Simplify.
11452 * btrace.h (struct btrace_call_iterator): Replace function call segment
11453 pointer with index into vector.
11454 * record-btrace.c (record_btrace_call_history): Use index instead of
11455 pointer.
11456
521103fd
TW
114572017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11458
11459 * btrace.c (btrace_insn_begin, btrace_insn_end,
11460 btrace_find_insn_by_number): Add btinfo to iterator.
11461 * btrace.h (struct btrace_insn_iterator): Add btinfo.
11462
17b89b34
TW
114632017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11464
11465 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
11466 and save pointers directly.
11467 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
11468 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
11469 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
11470 changed signature of functions.
11471 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
11472 (btrace_fetch): Remove code that adds btrace_function pointers to
11473 vector of btrace_functions.
11474 (btrace_clear): Simplify freeing vector of btrace_functions.
11475
2b51eddc
TW
114762017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11477
11478 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
11479 Replace VEC_* with std::vector functions.
11480 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
11481 (struct btrace_thread_info)<functions>: Change type to std::vector.
11482
db6be0d5
SM
114832017-05-30 Simon Marchi <simon.marchi@ericsson.com>
11484
11485 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
11486 "Removed targets and native configurations" up. Merge duplicate
11487 "New commands" sub-sections. Add "New options" sub-sections.
11488
b057297a
AH
114892017-05-26 Alan Hayward <alan.hayward@arm.com>
11490
11491 * defs.h (copy_integer_to_size): New declaration.
11492 * findvar.c (copy_integer_to_size): New function.
11493 (do_cint_test): New selftest function.
11494 (copy_integer_to_size_test): Likewise.
11495 (_initialize_findvar): Likewise.
11496 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
11497 (mips_fbsd_collect_reg): Use raw_collect_integer.
11498 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
11499 (mips64_fill_gregset): Use raw_collect_integer
11500 (mips64_fill_fpregset): Use raw_supply_integer.
11501 * regcache.c (regcache::raw_supply_integer): New function.
11502 (regcache::raw_collect_integer): Likewise.
11503 * regcache.h: (regcache::raw_supply_integer): New declaration.
11504 (regcache::raw_collect_integer): Likewise.
11505
b77b02a5
YQ
115062017-05-24 Yao Qi <yao.qi@linaro.org>
11507
11508 * Makefile.in (SFILES): Add gdbarch-selftests.c.
11509 (COMMON_OBS): Add gdbarch-selftests.o.
11510 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
11511 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
11512 * gdbarch-selftests.c: New file.
11513 * regcache.h (regcache) <~regcache>: Mark it virtual if
11514 GDB_SELF_TEST.
11515 <raw_write>: Likewise.
11516
e521e87e
YQ
115172017-05-24 Yao Qi <yao.qi@linaro.org>
11518
11519 * regcache.c (current_regcache): Change it to
11520 regcache::current_regcache.
11521 (regcache_observer_target_changed): Update.
11522 (regcache_thread_ptid_changed): Make it a regcache static
11523 method.
11524 (regcache_thread_ptid_changed): Update.
11525 (class regcache_access): New.
11526 (current_regcache_test): Update.
11527 (_initialize_regcache): Update.
11528 * regcache.h: Include forward_list.
11529 (regcache): Declare regcache_thread_ptid_changed and declare
11530 registers_changed_ptid as friend.
11531
d8e07dda
YQ
115322017-05-24 Yao Qi <yao.qi@linaro.org>
11533
11534 * i387-tdep.c (i387_register_to_value): Use register_size
11535 instead of TYPE_LENGTH.
11536 * m68k-tdep.c (m68k_register_to_value): Likewise.
11537
8c8f9122
YQ
115382017-05-24 Yao Qi <yao.qi@linaro.org>
11539
11540 * i387-tdep.c (i387_convert_register_p): Return false if type
11541 code isn't TYPE_CODE_FLT.
11542
68fce50f
YQ
115432017-05-24 Yao Qi <yao.qi@linaro.org>
11544
11545 * alpha-tdep.c (alpha_convert_register_p): Return true if type
11546 length is 4.
11547 (alpha_register_to_value): Remove type length check.
11548 (alpha_value_to_register): Likewise.
11549
88954b49
YQ
115502017-05-24 Yao Qi <yao.qi@linaro.org>
11551
11552 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
11553 TYPE_CODE_FLT.
11554
e3ec9b69
YQ
115552017-05-24 Yao Qi <yao.qi@linaro.org>
11556
11557 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
11558 TYPE_CODE_FLT or not.
11559
cdd238da
YQ
115602017-05-24 Yao Qi <yao.qi@linaro.org>
11561
11562 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
11563 * avr-tdep.c (avr_gdbarch_init): Likewise.
11564 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
11565 * cris-tdep.c (cris_gdbarch_init): Likewise.
11566 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
11567 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
11568 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11569 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
11570 * mep-tdep.c (mep_gdbarch_init): Likewise.
11571 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
11572 * mips-tdep.c (mips_gdbarch_init): Likewise.
11573 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
11574 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11575 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
11576 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
11577 * v850-tdep.c (v850_gdbarch_init): Likewise.
11578
7a3929c4
YQ
115792017-05-24 Yao Qi <yao.qi@linaro.org>
11580
11581 * selftest-arch.c (tests_with_arch): Call registers_changed
11582 and reinit_frame_cache.
11583 * selftest.c (run_self_tests): Likewise.
11584
f4985dba
YQ
115852017-05-24 Yao Qi <yao.qi@linaro.org>
11586
11587 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
11588 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
11589
ab20fa4a
YQ
115902017-05-24 Yao Qi <yao.qi@linaro.org>
11591
11592 * rl78-tdep.c (rl78_gdbarch_init): Don't call
11593 set_gdbarch_print_insn.
11594
f532ab94
YQ
115952017-05-24 Yao Qi <yao.qi@linaro.org>
11596
11597 * h8300-tdep.c (h8300_gdbarch_init): Don't call
11598 set_gdbarch_print_insn.
11599
39503f82
YQ
116002017-05-24 Yao Qi <yao.qi@linaro.org>
11601
11602 * alpha-tdep.c (alpha_gdbarch_init): Don't call
11603 set_gdbarch_print_insn.
11604 * arc-tdep.c (arc_gdbarch_init): Likewise.
11605 * arch-utils.c: include dis-asm.h.
11606 (default_print_insn): New function.
11607 * arch-utils.h (default_print_insn): Declare.
11608 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
11609 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
11610 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
11611 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
11612 * frv-tdep.c (frv_gdbarch_init): Likewise.
11613 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
11614 * gdbarch.sh (print_insn): Use default_print_insn.
11615 * gdbarch.c: Regenerated.
11616 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
11617 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
11618 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
11619 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
11620 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11621 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
11622 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
11623 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
11624 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
11625 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
11626 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
11627 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11628 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
11629 * mt-tdep.c (mt_gdbarch_init): Likewise.
11630 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
11631 * nios2-tdep.c (nios2_print_insn): Remove.
11632 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
11633 * rx-tdep.c (rx_gdbarch_init): Likewise.
11634 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
11635 * score-tdep.c (score_print_insn): Remove.
11636 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
11637 * sh-tdep.c (sh_gdbarch_init): Likewise.
11638 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
11639 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
11640 * tic6x-tdep.c (tic6x_print_insn): Remove.
11641 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
11642 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
11643 * v850-tdep.c (v850_gdbarch_init): Likewise.
11644 * vax-tdep.c (vax_gdbarch_init): Likewise.
11645 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
11646 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
11647
f7241d4f
JB
116482017-05-23 John Baldwin <jhb@FreeBSD.org>
11649
11650 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
11651 (MIPS_FP0_REGNUM): Remove.
11652 (MIPS_FSR_REGNUM): Remove.
11653 (mips_fbsd_supply_fpregs): Use mips_regnum.
11654 (mips_fbsd_supply_gregs): Likewise.
11655 (mips_fbsd_collect_fpregs): Likewise.
11656 (mips_fbsd_collect_gregs): Likewise.
11657
d489d81d
JB
116582017-05-23 John Baldwin <jhb@FreeBSD.org>
11659
11660 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
11661 (getpfpregs_supplies): New function.
11662 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
11663 getfpregs_supplies.
11664 (mips_fbsd_store_inferior_registers): Likewise.
11665
e11b3cdc
PA
116662017-05-22 Pedro Alves <palves@redhat.com>
11667
11668 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
11669 maintainer.
11670
0f068fb5
AH
116712017-05-22 Alan Hayward <alan.hayward@arm.com>
11672
11673 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
11674 (store_register): Likewise.
11675 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
11676 (get_decimal_float_return_value): Likewise.
11677 (do_ppc_sysv_return_value): Likewise.
11678 (ppc64_sysv_abi_push_integer): Likewise.
11679 (ppc64_sysv_abi_push_freg): Likewise.
11680 (ppc64_sysv_abi_return_value_base): Likewise.
11681 (ppc64_sysv_abi_return_value): Likewise.
11682 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
11683 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
11684 * rs6000-nat.c: Likewise.
11685 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
11686 (rs6000_value_to_register): Likewise.
11687 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
11688
e6cf65f2
TT
116892017-05-21 Tom Tromey <tom@tromey.com>
11690
11691 PR rust/21466:
11692 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
11693 arrays as "[T]", not "[T; ]".
11694
43cc5389
TT
116952017-05-19 Tom Tromey <tom@tromey.com>
11696
11697 PR rust/21484:
11698 * rust-lang.c (exp_descriptor_rust): New function.
11699 (rust_language_defn): Use it.
11700 * p-lang.c (pascal_language_defn): Update.
11701 * opencl-lang.c (opencl_language_defn): Update.
11702 * objc-lang.c (objc_language_defn): Update.
11703 * m2-lang.c (m2_language_defn): Update.
11704 * language.h (struct language_defn)
11705 <la_watch_location_expression>: New member.
11706 * language.c (unknown_language_defn, auto_language_defn)
11707 (local_language_defn): Update.
11708 * go-lang.c (go_language_defn): Update.
11709 * f-lang.c (f_language_defn): Update.
11710 * d-lang.c (d_language_defn): Update.
11711 * c-lang.h (c_watch_location_expression): Declare.
11712 * c-lang.c (c_watch_location_expression): New function.
11713 (c_language_defn, cplus_language_defn, asm_language_defn)
11714 (minimal_language_defn): Use it.
11715 * breakpoint.c (watch_command_1): Call
11716 la_watch_location_expression.
11717 * ada-lang.c (ada_language_defn): Update.
11718
7a6e7fcc
RO
117192017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11720
6e7e1744
RO
11721 PR tui/21482
11722 * gdb_curses.h (NOMACROS): Define.
11723 (NCURSES_NOMACROS): Define.
11724
117252017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11726
11727 PR tui/21482
7a6e7fcc
RO
11728 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
11729 arg to char *.
11730 * tui/tui-wingeneral.c (box_win): Likewise.
11731 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
11732 (tui_show_source_line): Likewise.
11733 (tui_show_exec_info_content): Likewise.
11734
1933fd8e
VM
117352017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
11736
11737 * sparc-tdep.c (sparc_structure_return_p)
11738 (sparc_arg_on_registers_p): New functions.
11739 (sparc32_store_arguments): Use them.
11740 * sparc64-tdep.c (sparc64_16_byte_align_p)
11741 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
11742 Handle TYPE_CODE_ARRAY.
11743
21873064
YQ
117442017-05-17 Yao Qi <yao.qi@linaro.org>
11745
11746 * cli/cli-decode.c (add_alias_cmd): New function.
11747 * command.h (add_alias_cmd): Declare.
11748 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
11749 instead call add_alias_cmd.
11750
2b351b19
PA
117512017-05-17 Pedro Alves <palves@redhat.com>
11752
11753 * Makefile.in (nat_extra_makefile_frag): Rename to ...
11754 (nat_makefile_frag): ... this. All references updated.
11755 * configure.ac: Likewise.
11756 * configure.nat: Likewise. Enhance comments.
11757 * configure: Regenerate.
11758
5f2ad7a3
RO
117592017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11760
11761 * procfs.c (procfs_create_inferior): Change prototype to match
11762 definition.
11763
adf3dde5
EZ
117642017-05-13 Eli Zaretskii <eliz@gnu.org>
11765
11766 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
11767 C++ compiler warning.
11768
6830f270
TT
117692017-05-12 Tom Tromey <tom@tromey.com>
11770
11771 PR rust/21483:
11772 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
11773 recurse, just call value_struct_elt directly.
11774
68f2f2e3
TT
117752017-05-12 Tom Tromey <tom@tromey.com>
11776
11777 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
11778 OP_RUST_ARRAY>: Fix.
11779
256afbc2
TT
117802017-05-12 Tom Tromey <tom@tromey.com>
11781
11782 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
11783
94bb8dfe
YQ
117842017-05-09 Yao Qi <yao.qi@linaro.org>
11785
11786 * regcache.c: Include <forward_list>.
11787 (struct regcache_list): Remove.
11788 (current_regcache): Update.
11789 (get_thread_arch_aspace_regcache): Update for std::forward_list.
11790 (regcache_thread_ptid_changed): Likewise.
11791 (registers_changed_ptid): Likewise.
11792 (current_regcache_size): Likewise.
11793
8248946c
YQ
117942017-05-09 Yao Qi <yao.qi@linaro.org>
11795
11796 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
11797 (current_regcache_size): New function.
11798 (current_regcache_test): New function.
11799 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
11800
313c5961
AH
118012017-05-08 Alan Hayward <alan.hayward@arm.com>
11802
11803 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
11804 (print_gp_register_row): Use get_frame_register_value.
11805
27bfc1d1
AH
118062017-05-08 Alan Hayward <alan.hayward@arm.com>
11807
11808 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
11809 (mips_supply_fpregset): Likewise.
11810 (mips64_supply_gregset): Likewise.
11811
146e6c5c
AH
118122017-05-08 Alan Hayward <alan.hayward@arm.com>
11813
11814 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
11815 regcache->raw_supply_zeroed.
11816
e50f25ec
SDJ
118172017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
11818
11819 * configure.nat: Rearrange 'case' statements to match
11820 host before cpu.
11821
21ea5acd
SDJ
118222017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
11823
11824 * Makefile.in: Remove "@host_makefile_frag@". Add variables
11825 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
11826 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
11827 "@nat_extra_makefile_frag@".
11828 (Makefile): Remove dependency on "@frags@".
11829 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
11830 (data-directory/Makefile): Likewise.
11831 * config/aarch64/linux.mh: Deleted; moved contents to
11832 "gdb/configure.nat".
11833 * config/alpha/alpha-linux.mh: Likewise.
11834 * config/alpha/nbsd.mh: Likewise.
11835 * config/arm/linux.mh: Likewise.
11836 * config/arm/nbsdelf.mh: Likewise.
11837 * config/i386/cygwin.mh: Likewise.
11838 * config/i386/cygwin64.mh: Likewise.
11839 * config/i386/darwin.mh: Likewise.
11840 * config/i386/fbsd.mh: Likewise.
11841 * config/i386/fbsd64.mh: Likewise.
11842 * config/i386/go32.mh: Likewise.
11843 * config/i386/i386gnu.mh: Likewise.
11844 * config/i386/i386sol2.mh: Likewise.
11845 * config/i386/linux.mh: Likewise.
11846 * config/i386/linux64.mh: Likewise.
11847 * config/i386/mingw.mh: Likewise.
11848 * config/i386/mingw64.mh: Likewise.
11849 * config/i386/nbsd64.mh: Likewise.
11850 * config/i386/nbsdelf.mh: Likewise.
11851 * config/i386/nto.mh: Likewise.
11852 * config/i386/obsd.mh: Likewise.
11853 * config/i386/obsd64.mh: Likewise.
11854 * config/i386/sol2-64.mh: Likewise.
11855 * config/ia64/linux.mh: Likewise.
11856 * config/m32r/linux.mh: Likewise.
11857 * config/m68k/linux.mh: Likewise.
11858 * config/m68k/nbsdelf.mh: Likewise.
11859 * config/m68k/obsd.mh: Likewise.
11860 * config/m88k/obsd.mh: Likewise.
11861 * config/mips/fbsd.mh: Likewise.
11862 * config/mips/linux.mh: Likewise.
11863 * config/mips/nbsd.mh: Likewise.
11864 * config/mips/obsd64.mh: Likewise.
11865 * config/pa/linux.mh: Likewise.
11866 * config/pa/nbsd.mh: Likewise.
11867 * config/pa/obsd.mh: Likewise.
11868 * config/powerpc/aix.mh: Likewise.
11869 * config/powerpc/fbsd.mh: Likewise.
11870 * config/powerpc/linux.mh: Likewise.
11871 * config/powerpc/nbsd.mh: Likewise.
11872 * config/powerpc/obsd.mh: Likewise.
11873 * config/powerpc/ppc64-linux.mh: Likewise.
11874 * config/powerpc/spu-linux.mh: Likewise.
11875 * config/s390/linux.mh: Likewise.
11876 * config/sh/nbsd.mh: Likewise.
11877 * config/sparc/fbsd.mh: Likewise.
11878 * config/sparc/linux.mh: Likewise.
11879 * config/sparc/linux64.mh: Likewise.
11880 * config/sparc/nbsd64.mh: Likewise.
11881 * config/sparc/nbsdelf.mh: Likewise.
11882 * config/sparc/obsd64.mh: Likewise.
11883 * config/sparc/sol2.mh: Likewise.
11884 * config/tilegx/linux.mh: Likewise.
11885 * config/vax/nbsdelf.mh: Likewise.
11886 * config/vax/obsd.mh: Likewise.
11887 * config/xtensa/linux.mh: Likewise.
11888 * config/i386/i386gnu.mn: New file, with excerpts from
11889 "config/i386/i386gnu.mh".
11890 * configure: Regenerate.
11891 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
11892 *.mh files under "gdb/config".
11893 * configure.nat: New file, with contents from the
11894 "gdb/config/*/*.mh" files.
11895
7ed1acaf
TW
118962017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
11897
11898 * btrace.c (btrace_clear): Free insn vector.
11899
e13cb306
PA
119002017-05-05 Pedro Alves <palves@redhat.com>
11901
11902 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
11903 * configure: Regenerate.
11904
5ed8105e
PA
119052017-05-04 Pedro Alves <palves@redhat.com>
11906
11907 * Makefile.in (SFILES): Add progspace-and-thread.c.
11908 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
11909 (COMMON_OBS): Add progspace-and-thread.o.
11910 * breakpoint.c: Include "progspace-and-thread.h".
11911 (update_inserted_breakpoint_locations)
11912 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
11913 Use scoped_restore_current_pspace_and_thread.
11914 (create_std_terminate_master_breakpoint): Use
11915 scoped_restore_current_program_space.
11916 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
11917 (print_breakpoint_location): Use
11918 scoped_restore_current_program_space.
11919 (bp_loc_is_permanent): Use
11920 scoped_restore_current_pspace_and_thread.
11921 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
11922 (download_tracepoint_locations): Use
11923 scoped_restore_current_pspace_and_thread.
11924 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
11925 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
11926 (enum step_over_calls_kind): Moved from inferior.h.
11927 (class scoped_restore_current_thread): New class.
11928 * gdbthread.h (make_cleanup_restore_current_thread): Delete
11929 declaration.
11930 (scoped_restore_current_thread): New class.
11931 * infcmd.c: Include "common/gdb_optional.h".
11932 (continue_1, proceed_after_attach): Use
11933 scoped_restore_current_thread.
11934 (notice_new_inferior): Use scoped_restore_current_thread.
11935 * inferior.c: Include "progspace-and-thread.h".
11936 (restore_inferior, save_current_inferior): Delete.
11937 (add_inferior_command, clone_inferior_command): Use
11938 scoped_restore_current_pspace_and_thread.
11939 * inferior.h (scoped_restore_current_inferior): New class.
11940 * infrun.c: Include "progspace-and-thread.h" and
11941 "common/gdb_optional.h".
11942 (follow_fork_inferior): Use
11943 scoped_restore_current_pspace_and_thread.
11944 (scoped_restore_exited_inferior): New class.
11945 (handle_vfork_child_exec_or_exit): Use
11946 scoped_restore_exited_inferior,
11947 scoped_restore_current_pspace_and_thread,
11948 scoped_restore_current_thread and scoped_restore.
11949 (fetch_inferior_event): Use scoped_restore_current_thread.
11950 * linespec.c (decode_line_full, decode_line_1): Use
11951 scoped_restore_current_program_space.
11952 * mi/mi-main.c: Include "progspace-and-thread.h".
11953 (exec_continue): Use scoped_restore_current_thread.
11954 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
11955 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
11956 * proc-service.c (ps_pglobal_lookup): Use
11957 scoped_restore_current_program_space.
11958 * progspace-and-thread.c: New file.
11959 * progspace-and-thread.h: New file.
11960 * progspace.c (release_program_space, clone_program_space): Use
11961 scoped_restore_current_program_space.
11962 (restore_program_space, save_current_program_space)
11963 (save_current_space_and_thread): Delete.
11964 (switch_to_program_space_and_thread): Moved to
11965 progspace-and-thread.c.
11966 * progspace.h (save_current_program_space)
11967 (save_current_space_and_thread): Delete declarations.
11968 (scoped_restore_current_program_space): New class.
11969 * remote.c (remote_btrace_maybe_reopen): Use
11970 scoped_restore_current_thread.
11971 * symtab.c: Include "progspace-and-thread.h".
11972 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
11973 * thread.c (print_thread_info_1): Use
11974 scoped_restore_current_thread.
11975 (struct current_thread_cleanup): Delete.
11976 (do_restore_current_thread_cleanup)
11977 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
11978 (scoped_restore_current_thread::~scoped_restore_current_thread):
11979 ... this new dtor.
11980 (make_cleanup_restore_current_thread): Rename/convert to ...
11981 (scoped_restore_current_thread::scoped_restore_current_thread):
11982 ... this new ctor.
11983 (thread_apply_all_command): Use scoped_restore_current_thread.
11984 (thread_apply_command): Use scoped_restore_current_thread.
11985 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
11986 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
11987
f6223dbb
PA
119882017-05-04 Pedro Alves <palves@redhat.com>
11989
11990 * thread.c (make_cleanup_restore_current_thread): Move
11991 find_thread_ptid call before the is_stopped call. Assert that the
11992 thread is found. Replace is_stopped call by checking the thread's
11993 state directly. Remove unnecessary NULL-thread check.
11994
3c3ae77e
PA
119952017-05-04 Pedro Alves <palves@redhat.com>
11996
11997 * corelow.c (thread_section_name): New class.
11998 (get_core_register_section, get_core_siginfo): Use it.
11999
45eba0ab
AA
120002017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
12001
12002 * corelow.c (sniff_core_bfd): Remove extra semicolon.
12003 (get_core_register_section): Remove xfree of NULL pointer.
12004
f81fdd35
AH
120052017-05-03 Alan Hayward <alan.hayward@arm.com>
12006
12007 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
12008 * regcache.c (regcache::raw_supply_zeroed): New function.
12009 * regcache.h (regcache::raw_supply_zeroed): New declaration.
12010
35837774
SM
120112017-05-03 Simon Marchi <simon.marchi@ericsson.com>
12012
12013 * gdbarch.sh: Remove commented out definition of
12014 TARGET_CHAR_BIT.
12015 * gdbarch.h: Re-generate.
12016
c94fee56
SDJ
120172017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
12018
12019 * configure: Regenerate.
12020
d17f7b36
SM
120212017-05-02 Simon Marchi <simon.marchi@ericsson.com>
12022
12023 * solib-target.c (solib_target_relocate_section_addresses):
12024 Remove num_section_bases, num_bases, segment_bases variables.
12025
b560ebd6
SM
120262017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12027
12028 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
12029
f2f46dfc
SM
120302017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12031
12032 * solib-target.c: Include <vector>
12033 (struct lm_info_target) <~lm_info_target>: Remove.
12034 <segment_bases, section_bases>: Change type to
12035 std::vector<CORE_ADDR>.
12036 (library_list_start_segment, library_list_start_section,
12037 library_list_end_library,
12038 solib_target_relocate_section_addresses): Adjust.
12039
a0ff9e1a
SM
120402017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12041
12042 * gdbarch.sh (software_single_step): Change return type to
12043 std::vector<CORE_ADDR>.
12044 * gdbarch.c, gdbarch.h: Re-generate.
12045 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
12046 Adjust.
12047 (arm_deal_with_atomic_sequence_raw): Adjust.
12048 (thumb_get_next_pcs_raw): Adjust.
12049 (arm_get_next_pcs_raw): Adjust.
12050 (arm_get_next_pcs): Adjust.
12051 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
12052 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
12053 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
12054 (alpha_software_single_step): Adjust.
12055 * alpha-tdep.h (alpha_software_single_step): Adjust.
12056 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
12057 * arm-tdep.c (arm_software_single_step): Adjust.
12058 (arm_breakpoint_kind_from_current_state): Adjust.
12059 * arm-tdep.h (arm_software_single_step): Adjust.
12060 * breakpoint.c (insert_single_step_breakpoint): Adjust.
12061 * cris-tdep.c (cris_software_single_step): Adjust.
12062 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
12063 (micromips_deal_with_atomic_sequence): Adjust.
12064 (deal_with_atomic_sequence): Adjust.
12065 (mips_software_single_step): Adjust.
12066 * mips-tdep.h (mips_software_single_step): Adjust.
12067 * moxie-tdep.c (moxie_software_single_step): Adjust.
12068 * nios2-tdep.c (nios2_software_single_step): Adjust.
12069 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
12070 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
12071 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
12072 * s390-linux-tdep.c (s390_software_single_step): Adjust.
12073 * sparc-tdep.c (sparc_software_single_step): Adjust.
12074 * spu-tdep.c (spu_software_single_step): Adjust.
12075 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
12076
ea480a30
SM
120772017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12078
12079 * gdbarch.sh: Use semi-colon as field separator instead of colon.
12080 * gdbarch.h: Re-generate.
12081
d050f7d7
TW
120822017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12083
12084 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
12085 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
12086 * python/py-instruction.c, python/py-instruction.h: New file.
12087 * python/py-record.c: Add py-instruction.h include.
12088 (gdbpy_initialize_record): Make gdb.Instruction a super class of
12089 gdb.RecordInstruction.
12090 * python/python-internal.h: Add gdbpy_initialize_instruction
12091 declaration.
12092 * python/python.c (do_start_initialization): Add
12093 gdbpy_initialize_instruction.
12094
14f819c8
TW
120952017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12096
12097 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
12098 Remove.
12099 (btrace_func_from_recpy_func): New function.
12100 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
12101 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
12102 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
12103 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
12104 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
12105 Also, use new helper functions.
12106 (btpy_list_item): Use new helper functions.
12107 (recpy_bt_function_call_history): Use new type name.
12108 (btpy_call_getset): Remove.
12109 (gdbpy_initialize_btrace): Remove code to initialize
12110 gdb.BtraceFunctionCall.
12111 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
12112 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
12113 recpy_bt_func_prev, recpy_bt_func_next): New export.
12114 * python/py-record.c (recpy_func_type): New static object.
12115 (recpy_func_new, recpy_func_level, recpy_func_symbol,
12116 recpy_func_instructions, recpy_func_up, recpy_func_prev,
12117 recpy_func_next): New function.
12118 (recpy_element_hash, recpy_element_richcompare): Updated comment.
12119 (recpy_func_getset): New static object.
12120 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
12121 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
12122
0ed5da75
TW
121232017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12124
12125 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
12126 (btpy_object, btpy_insn_type, btpy_new): Remove.
12127 (btpy_list_object): Use gdb.RecordInstruction type instead of
12128 gdb.BtraceInstruction type.
12129 (btrace_insn_from_recpy_insn): New function.
12130 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
12131 btpy_new.
12132 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
12133 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
12134 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
12135 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
12136 instead of btpy_object.
12137 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12138 btpy_insn_data, btpy_insn_decode): Rename to ...
12139 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
12140 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
12141 recpy_bt_insn_decode): This. Also, use new helper functions.
12142 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
12143 recpy_insn_type.
12144 (btpy_insn_getset): Remove.
12145 (gdbpy_initialize_btrace): Remove code to initialize
12146 gdb.BtraceInstruction. Use recpy_element_object.
12147 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
12148 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
12149 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
12150 * python/py-record.c (recpy_insn_type): New static object.
12151 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
12152 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
12153 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
12154 New function.
12155 (recpy_insn_getset): New static object.
12156 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
12157 * python/py-record.h (recpy_element_object): New typedef.
12158 (recpy_insn_type, recpy_insn_new): New export.
12159
913aeadd
TW
121602017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12161
12162 * py-record-btrace.c (btpy_insn_new): Removed.
12163 (btpy_insn_or_gap_new): New function.
12164 (btpy_insn_error): Removed.
12165 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12166 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
12167 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
12168 btpy_insn_or_gap_new instead of btpy_insn_new.
12169 (btpy_insn_getset): Remove btpy_insn_error.
12170 * py-record.c (recpy_gap_type): New static object.
12171 (recpy_gap_object): New typedef.
12172 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
12173 recpy_gap_reason_string): New function.
12174 (recpy_gap_getset): New static object.
12175 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
12176 * py-record.h (recpy_gap_new): New export.
12177
a3be24ad
TW
121782017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12179
12180 * python/py-record.c (recpy_ptid): Remove.
12181 (recpy_record_getset): Remove recpy_ptid.
12182
ae20e79a
TW
121832017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12184
12185 * btrace.c (btrace_fetch): Set inferior_ptid.
12186 * python/py-record-btrace.c: Add "py-record.h" include.
12187 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
12188 recpy_bt_end, recpy_bt_instruction_history,
12189 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
12190 in gdb.Record object instead of current ptid.
12191 * python/py-record.c: Include new "py-record.h" file.
12192 (recpy_record_object): Moved to py-record.h.
12193 * python/py-record.h: New file.
12194
8d0050ea
TW
121952017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12196
12197 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
12198 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
12199 indentation.
12200
3f380b50
JB
122012017-05-01 Joel Brobecker <brobecker@adacore.com>
12202
12203 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
12204 the past maintainers section.
12205
07495424
YQ
122062017-04-28 Yao Qi <yao.qi@linaro.org>
12207
12208 * infcmd.c (get_return_value): Use regcache ctor, and remove
12209 cleanup.
12210
deb1fa3e
YQ
122112017-04-28 Yao Qi <yao.qi@linaro.org>
12212 Pedro Alves <palves@redhat.com>
12213
12214 * regcache.c (regcache::regcache): New tag dispatch ctor.
12215 (do_cooked_read): Moved above.
12216 (regcache_dup): Use the tag dispatch ctor..
12217 * regcache.h (regcache): Declare ctor, delete copy ctor and
12218 assignment operator, remove friend regcache_dup.
12219
b421c83c
YQ
122202017-04-28 Yao Qi <yao.qi@linaro.org>
12221
12222 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
12223 call method save instead of regcache_cpy.
12224 * regcache.h (struct regcache): Make regcache_dup a friend.
12225
ef79d9a3
YQ
122262017-04-28 Yao Qi <yao.qi@linaro.org>
12227
12228 * regcache.c (struct regcache): Move to regcache.h
12229 (regcache::arch): New method.
12230 (regcache_get_ptid): Update.
12231 (get_regcache_arch): Call arch method.
12232 (get_regcache_aspace): Call method aspace.
12233 (register_buffer): Change it to method.
12234 (regcache_save): Change it to regcache::save.
12235 (regcache_restore): Likewise.
12236 (regcache_cpy_no_passthrough): Remove the declaration.
12237 (regcache_cpy): Call methods restore and cpy_no_passthrough.
12238 (regcache_cpy_no_passthrough): Change it to method
12239 cpy_no_passthrough.
12240 (regcache_register_status): Change it to method
12241 get_register_status.
12242 (regcache_invalidate): Change it to method invalidate.
12243 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
12244 (regcache_raw_update): Change it to method raw_update.
12245 (regcache_raw_read): Likewise.
12246 (regcache_raw_read_signed): Likewise.
12247 (regcache_raw_read_unsigned): Likewise.
12248 (regcache_raw_write_signed): Likewise.
12249 (regcache_raw_write_unsigned): Likewise.
12250 (regcache_cooked_read): Likewise.
12251 (regcache_cooked_read_value): Likewise.
12252 (regcache_cooked_read_signed): Likewise.
12253 (regcache_cooked_read_unsigned): Likewise.
12254 (regcache_cooked_write_signed): Likewise.
12255 (regcache_cooked_write_unsigned): Likewise.
12256 (regcache_raw_set_cached_value): Likewise.
12257 (regcache_raw_write): Likewise.
12258 (regcache_cooked_write): Likewise.
12259 (regcache_xfer_part): Likewise.
12260 (regcache_raw_read_part): Likewise.
12261 (regcache_raw_write_part): Likewise.
12262 (regcache_cooked_read_part): Likewise.
12263 (regcache_cooked_write_part): Likewise.
12264 (regcache_raw_supply): Likewise.
12265 (regcache_raw_collect): Likewise.
12266 (regcache_transfer_regset): Likewise.
12267 (regcache_supply_regset): Likewise.
12268 (regcache_collect_regset): Likewise.
12269 (regcache_debug_print_register): Likewise.
12270 (enum regcache_dump_what): Move it to regcache.h.
12271 (regcache_dump): Change it to method dump.
12272 * regcache.h (enum regcache_dump_what): New.
12273 (class regcache): New.
12274 * target.c (target_fetch_registers): Call method
12275 debug_print_register.
12276 (target_store_registers): Likewise.
12277
f8fdb78e
SM
122782017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12279
12280 * windows-nat.c (struct lm_info_windows): Initialize field.
12281 (windows_make_so): Allocate lm_info_windows with new.
12282 (windows_free_so): Free lm_info_windows with delete.
12283
9ccbfd7b
SM
122842017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12285
12286 * solib-darwin.c (struct lm_info_darwin): Initialize field.
12287 (darwin_current_sos): Allocate lm_info_darwin with new, remove
12288 cleanup.
12289 (darwin_free_so): Free lm_info_darwin with delete.
12290
76e75227
SM
122912017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12292
12293 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
12294 <l_addr_p>: Change type to bool.
12295 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
12296 (svr4_free_so): Free lm_info_svr4 with delete.
12297 (svr4_copy_library_list): Replace memcpy with call to copy
12298 constructor.
12299 (library_list_start_library, svr4_default_sos): Allocate
12300 lm_info_svr4 with new.
12301
51046d9e
SM
123022017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12303
12304 * solib-target.c (struct lm_info_target): Add destructor,
12305 initialize fields.
12306 <name>: Change type to std::string.
12307 (library_list_start_library): Allocate lm_info_target with new.
12308 (solib_target_free_library_list): Free lm_info_target with
12309 delete.
12310 (solib_target_current_sos): Adapt to std::string.
12311 (solib_target_free_so): Free lm_info_target with delete.
12312
4023ae76
SM
123132017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12314
12315 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
12316 fields.
12317 (frv_current_sos): Allocate lm_info_frv with new.
12318 (frv_relocate_main_executable): Free lm_info_frv with delete,
12319 allocate with new.
12320 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
12321
af43057b
SM
123222017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12323
12324 * solib-frv.c (struct lm_info_frv): Fix indentation.
12325
b0911207
SM
123262017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12327
12328 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
12329 map field.
12330 (dsbt_current_sos): Allocate lm_info_dsbt with new.
12331 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
12332 and allocate with new.
12333 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
12334
6c401f72
SM
123352017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12336
12337 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
12338 <filename, member_name>: Change type to std::string.
12339 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
12340 (library_list_start_library): Allocate lm_info_aix with new.
12341 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
12342 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
12343 with copy constructor.
12344
d0e449a1
SM
123452017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12346
12347 * solist.h (struct lm_info): Remove.
12348 (struct lm_info_base): New class.
12349 (struct so_list) <lm_info>: Change type to lm_info_base *.
12350 * nto-tdep.c (struct lm_info): Remove.
12351 (lm_addr): Adjust.
12352 * solib-aix.c (struct lm_info): Rename to ...
12353 (struct lm_info_aix): ... this. Extend lm_info_base.
12354 (lm_info_p): Rename to ...
12355 (lm_info_aix_p): ... this, and adjust.
12356 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
12357 solib_aix_parse_libraries, library_list_start_library,
12358 solib_aix_free_library_list, solib_aix_parse_libraries,
12359 solib_aix_get_library_list,
12360 solib_aix_relocate_section_addresses, solib_aix_free_so,
12361 solib_aix_get_section_offsets,
12362 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
12363 Adjust.
12364 (struct solib_aix_inferior_data) <library_list>: Adjust.
12365 * solib-darwin.c (struct lm_info): Rename to ...
12366 (struct lm_info_darwin): ... this. Extend lm_info_base.
12367 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
12368 * solib-dsbt.c (struct lm_info): Rename to ...
12369 (struct lm_info_dsbt): ... this. Extend lm_info_base.
12370 (struct dsbt_info) <main_executable_lm_info): Adjust.
12371 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
12372 dsbt_relocate_section_addresses): Adjust.
12373 * solib-frv.c (struct lm_info): Rename to ...
12374 (struct lm_info_frv): ... this. Extend lm_info_base.
12375 (main_executable_lm_info): Adjust.
12376 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
12377 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
12378 find_canonical_descriptor_in_load_object,
12379 frv_fdpic_find_canonical_descriptor): Adjust.
12380 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
12381 to lm_info_svr4.
12382 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
12383 svr4_clear_so, svr4_copy_library_list,
12384 library_list_start_library, svr4_default_sos, svr4_read_so_list,
12385 svr4_current_sos, svr4_fetch_objfile_link_map,
12386 solist_update_incremental): Adjust.
12387 * solib-svr4.h (struct lm_info_svr4): Move here from
12388 solib-svr4.c.
12389 * solib-target.c (struct lm_info): Rename to ...
12390 (struct lm_info_target): ... this. Extend lm_info_base.
12391 (lm_info_p): Rename to ...
12392 (lm_info_target_p): ... this.
12393 (solib_target_parse_libraries, library_list_start_segment,
12394 library_list_start_section, library_list_start_library,
12395 library_list_end_library, solib_target_free_library_list,
12396 solib_target_current_sos, solib_target_free_so,
12397 solib_target_relocate_section_addresses): Adjust.
12398 * windows-nat.c (struct lm_info): Rename to ...
12399 (struct lm_info_windows): ... this. Extend lm_info_base.
12400 (windows_make_so, handle_load_dll, handle_unload_dll,
12401 windows_xfer_shared_libraries): Adjust.
12402
434a4023
SM
124032017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12404
12405 * solib-darwin.c (struct darwin_so_list): Remove.
12406 (darwin_current_sos): Allocate an so_list object instead of a
12407 darwin_so_list, separately allocate an lm_info object.
12408 (darwin_free_so): Free lm_info.
12409
428544e8
JB
124102017-04-28 John Baldwin <jhb@FreeBSD.org>
12411
12412 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
12413 with fprintf_filtered.
12414
4621115f
YQ
124152017-04-28 Yao Qi <yao.qi@linaro.org>
12416
12417 * regcache.c (regcache::regcache): New function.
12418 (regcache::~regcache): New function.
12419 (regcache_xmalloc_1): Remove.
12420 (regcache_xmalloc): Call new regcache.
12421 (regcache_xfree): Call delete regcache.
12422 (get_thread_arch_aspace_regcache): Call new regcache.
12423
339053c2
YQ
124242017-04-28 Yao Qi <yao.qi@linaro.org>
12425
12426 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
12427 lwp instead of ptid_get_lwp.
12428
7974a605
YQ
124292017-04-28 Yao Qi <yao.qi@linaro.org>
12430
12431 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
12432 lwp_info instead of getting from inferior_ptid.
12433
e15c3eb4
KS
124342017-04-27 Keith Seitz <keiths@redhat.com>
12435
12436 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
12437 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
12438 (CV_CONVERSION_BADNESS): Define.
12439 (rank_one_type): Remove overly restrictive rvalue reference
12440 rank checks.
12441 Add cv-qualifier checks and subranks for type equality.
12442 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
12443 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
12444 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
12445
72bc1d24
SM
124462017-04-27 Simon Marchi <simon.marchi@ericsson.com>
12447
12448 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
12449 count when creating the object.
12450
55bcecda
UW
124512017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
12452 Ulrich Weigand <uweigand@de.ibm.com>
12453
12454 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
12455 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
12456 is used in AIX.
12457 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
12458 (process_xcoff_symbol): Likewise.
12459 (scan_xcoff_symtab): Likewise.
12460
5c99fcf8
AH
124612017-04-26 Alan Hayward <alan.hayward@arm.com>
12462
12463 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
12464 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
12465 (ia64_access_reg): Use get_frame_register_unsigned.
12466 (ia64_access_rse_reg): Likewise.
12467 (ia64_libunwind_frame_prev_register): Likewise.
12468
b41c5a85
JW
124692017-04-26 Jiong Wang <jiong.wang@arm.com>
12470
12471 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
12472 * gdbarch.c: Regenerated.
12473 * gdbarch.h: Regenerated.
12474 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
12475 visibility external.
12476 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
12477 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
12478 (enum cfa_how_kind): Move to ...
12479 (struct dwarf2_frame_state_reg_info): Likewise.
12480 (struct dwarf2_frame_state): Likewise.
12481 * dwarf2-frame.h: ... here.
12482 (dwarf2_frame_state_alloc_regs): New declaration.
12483 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
12484 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
12485
c185f580
AH
124862017-04-26 Alan Hayward <alan.hayward@arm.com>
12487
12488 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
12489 regcache_raw_read_unsigned.
12490 (xtensa_pseudo_register_write): Likewise.
12491
19c45594
AH
124922017-04-26 Alan Hayward <alan.hayward@arm.com>
12493
12494 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
12495 (nds32_pseudo_register_write): Likewise.
12496
4658f12e
YQ
124972017-04-25 Yao Qi <yao.qi@linaro.org>
12498
12499 * regcache.c (struct regcache) <readonly_p>: Change its type
12500 to bool.
12501 (regcache_xmalloc_1): Update parameter type and callers update.
12502
d581dda8
YQ
125032017-04-25 Yao Qi <yao.qi@linaro.org>
12504
12505 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
12506 set_gdbarch_wchar_bit.
12507 * arm-tdep.c (arm_gdbarch_init): Likewise.
12508
debed3db
PA
125092017-04-25 Pedro Alves <palves@redhat.com>
12510
12511 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
12512 (BothAreRelocatable, memcopy, memmove): Don't define.
12513 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
12514 macros.
12515
b0b92aeb
PA
125162017-04-25 Pedro Alves <palves@redhat.com>
12517
12518 * common/common-defs.h: Include "common/poison.h".
12519 * common/function-view.h: (Not, Or, Requires): Move to traits.h
12520 and adjust.
12521 * common/poison.h: New file.
12522 * common/traits.h: Include <type_traits>.
12523 (Not, Or, Requires): New, moved from common/function-view.h.
12524
16c4d54a
PA
125252017-04-25 Pedro Alves <palves@redhat.com>
12526
12527 * breakpoint.h (struct breakpoint): In-class initialize all
12528 fields. Make boolean fields "bool".
12529 * breakpoint.c (init_raw_breakpoint_without_location): Remove
12530 memset call and initializations no longer necessary.
12531
b5c36682
PA
125322017-04-25 Pedro Alves <palves@redhat.com>
12533
12534 * btrace.c (pt_btrace_insn_flags): Change parameter type to
12535 reference.
12536 (pt_btrace_insn): New function.
12537 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
12538
5625a286
PA
125392017-04-25 Pedro Alves <palves@redhat.com>
12540
12541 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
12542 "base" field and inherit from "bp_location" instead. Add
12543 non-default ctor.
12544 (allocate_location_exception): Use new non-default ctor.
12545 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
12546 (init_bp_location): Convert to ...
12547 (bp_location::bp_location): ... this new ctor, and remove memset
12548 call.
12549 (base_breakpoint_allocate_location): Use the new non-default ctor.
12550 * breakpoint.h (bp_location): Now a class. Declare default and
12551 non-default ctors. In-class initialize all members.
12552 (init_bp_location): Remove declaration.
12553
23bcc18f
PA
125542017-04-25 Pedro Alves <palves@redhat.com>
12555
12556 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
12557 assignment operator.
12558
e1ba3053
YQ
125592017-04-24 Yao Qi <yao.qi@linaro.org>
12560
12561 * doublest.c (convert_doublest_to_floatformat): Call
12562 floatformat_totalsize_bytes.
12563
10f489e5
TT
125642017-04-22 Tom Tromey <tom@tromey.com>
12565
12566 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
12567 ui_out_emit_list.
12568 * stack.c (print_frame): Use ui_out_emit_list.
12569 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
12570 ui_out_emit_list.
12571 * mi/mi-main.c (print_one_inferior)
12572 (mi_cmd_data_list_register_names)
12573 (mi_cmd_data_list_register_values, mi_cmd_list_features)
12574 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
12575 ui_out_emit_list.
12576 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
12577 (mi_output_solib_attribs): Use ui_out_emit_list,
12578 ui_out_emit_tuple.
12579 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
12580 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
12581 (mi_cmd_stack_list_args, list_args_or_locals): Use
12582 ui_out_emit_list.
12583 * disasm.c (do_assembly_only): Use ui_out_emit_list.
12584 * breakpoint.c (print_solib_event, output_thread_groups): Use
12585 ui_out_emit_list.
12586
0092b74d
TT
125872017-04-22 Tom Tromey <tom@tromey.com>
12588
12589 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
12590 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
12591 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
12592
a14a62dd
TT
125932017-04-22 Tom Tromey <tom@tromey.com>
12594
12595 * tracepoint.c (tvariables_info_1)
12596 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
12597
46b9c129
TT
125982017-04-22 Tom Tromey <tom@tromey.com>
12599
12600 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
12601 annotate_arg_emitter.
12602 * breakpoint.c (print_mention_watchpoint)
12603 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
12604 * annotate.h (struct annotate_arg_emitter): New.
12605
2e783024
TT
126062017-04-22 Tom Tromey <tom@tromey.com>
12607
12608 * record-btrace.c (record_btrace_insn_history)
12609 (record_btrace_insn_history_range, record_btrace_call_history)
12610 (record_btrace_call_history_range): Use ui_out_emit_tuple.
12611 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
12612 ui_out_emit_tuple.
12613 * stack.c (print_frame_info): Use ui_out_emit_tuple.
12614 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
12615 * skip.c (skip_info): Use ui_out_emit_tuple.
12616 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
12617 * progspace.c (print_program_space): Use ui_out_emit_tuple.
12618 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
12619 * osdata.c (info_osdata): Use ui_out_emit_tuple.
12620 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
12621 ui_out_emit_tuple.
12622 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
12623 (output_register, mi_cmd_data_read_memory)
12624 (mi_cmd_data_read_memory_bytes, mi_load_progress)
12625 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
12626 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
12627 Use ui_out_emit_tuple.
12628 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
12629 ui_out_emit_tuple.
12630 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
12631 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
12632 * linux-thread-db.c (info_auto_load_libthread_db): Use
12633 ui_out_emit_tuple.
12634 * inferior.c (print_inferior): Use ui_out_emit_tuple.
12635 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
12636 * disasm.c (do_mixed_source_and_assembly_deprecated)
12637 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
12638 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
12639 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
12640 * breakpoint.c (print_one_breakpoint_location)
12641 (print_one_breakpoint): Use ui_out_emit_tuple.
12642 * auto-load.c (print_script, info_auto_load_cmd): Use
12643 ui_out_emit_tuple.
12644 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
12645
9be21bb4
SM
126462017-04-21 Simon Marchi <simon.marchi@ericsson.com>
12647
12648 * thread.c (print_thread_info_1): Remove dead code.
12649
0d4c07af
JK
126502017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12651
12652 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
12653 GDB_SELF_TEST.
12654 * arm-tdep.c (selftests::arm_record_test): Likewise.
12655
4daf993d
YQ
126562017-04-21 Yao Qi <yao.qi@linaro.org>
12657
12658 * regcache.c (regcache_restore): Remove argument 2. Replace
12659 argument 3 with regcache. Get register status from
12660 src->register_status and get register contents from
12661 register_buffer (src, regnum).
12662 (regcache_cpy): Update.
12663
a6c21d4a
PA
126642017-04-19 Pedro Alves <palves@redhat.com>
12665
12666 * gdbthread.h (thread): Add missing closing parenthesis in
12667 comment.
12668
3a3fd0fd
PA
126692017-04-19 Pedro Alves <palves@redhat.com>
12670
12671 * common/refcounted-object.h: New file.
12672 * gdbthread.h: Include "common/refcounted-object.h".
12673 (thread_info): Inherit from refcounted_object and add comments.
12674 (thread_info::incref, thread_info::decref)
12675 (thread_info::m_refcount): Delete.
12676 (thread_info::deletable): Use the refcounted_object::refcount()
12677 method.
12678 * inferior.c (current_inferior_): Add comment.
12679 (set_current_inferior): Increment/decrement refcounts.
12680 (prune_inferiors, remove_inferior_command): Skip inferiors marked
12681 not-deletable instead of comparing with the current inferior.
12682 (initialize_inferiors): Increment the initial inferior's refcount.
12683 * inferior.h (struct inferior): Forward declare.
12684 Include "common/refcounted-object.h".
12685 (current_inferior, set_current_inferior): Move declaration to
12686 before struct inferior's definition, and fix comment.
12687 (inferior): Inherit from refcounted_object. Add comments.
12688 * thread.c (switch_to_thread_no_regs): Reference the thread's
12689 inferior pointer directly instead of doing a ptid lookup.
12690 (switch_to_no_thread): New function.
12691 (switch_to_thread(thread_info *)): New function, factored out
12692 from ...
12693 (switch_to_thread(ptid_t)): ... this.
12694 (restore_current_thread): Delete.
12695 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
12696 fields, and add 'inf' field.
12697 (do_restore_current_thread_cleanup): Check whether old->inf is
12698 alive instead of looking up an inferior by ptid. Use
12699 switch_to_thread and switch_to_no_thread.
12700 (restore_current_thread_cleanup_dtor): Use old->inf directly
12701 instead of lookup up an inferior by id. Decref the inferior.
12702 Don't restore 'removable'.
12703 (make_cleanup_restore_current_thread): Same the inferior pointer
12704 in old, instead of the inferior number. Incref the inferior.
12705 Don't save/clear 'removable'.
12706
9bcb1f16
PA
127072017-04-19 Pedro Alves <palves@redhat.com>
12708
12709 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12710 unittests/scoped_restore-selftests.c.
12711 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
12712 * common/scoped_restore.h (scoped_restore_base): Make "class".
12713 (scoped_restore_base::release): New public method.
12714 (scoped_restore_base::scoped_restore_base): New protected ctor.
12715 (scoped_restore_base::m_saved_var): New protected field.
12716 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
12717 scoped_restore_base base class instead of m_saved_var directly.
12718 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
12719 (scoped_restore_tmpl::scoped_restore_tmpl(const
12720 scoped_restore_tmpl<T>&)): Likewise.
12721 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
12722 method.
12723 (scoped_restore_tmpl::saved_var): New method.
12724 (scoped_restore_tmpl::m_saved_var): Delete.
12725 * inferior.h (inferior::detaching): Now a bool.
12726 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
12727 cleanup.
12728 * unittests/scoped_restore-selftests.c: New file.
12729
26fcd539
PA
127302017-04-19 Pedro Alves <palves@redhat.com>
12731
12732 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
12733 Re-sort in alphabetic order.
12734
fdd243b0
PA
127352017-04-18 Pedro Alves <palves@redhat.com>
12736
12737 * xml-support.c (obstack_xml_printf): Delete.
12738 * xml-support.h (obstack_xml_printf): Delete.
12739
4895cde2
PA
127402017-04-18 Pedro Alves <palves@redhat.com>
12741
12742 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
12743 vdebug, verror, body_text, start_element, end_element, name,
12744 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
12745 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
12746 is_xinclude>: Make private and add m_ prefix.
12747 (gdb_xml_parser::body_text): New method, based on ...
12748 (gdb_xml_body_text): ... this. Adjust.
12749 (gdb_xml_parser::vdebug): New method, based on ...
12750 (gdb_xml_debug): ... this. Adjust.
12751 (gdb_xml_parser::verror): New method, based on ...
12752 (gdb_xml_error): ... this. Adjust.
12753 (gdb_xml_parser::start_element): New method, based on ...
12754 (gdb_xml_start_element): ... this. Adjust.
12755 (gdb_xml_start_element_wrapper): Defer to
12756 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
12757 (gdb_xml_parser::end_element): New method, based on ...
12758 (gdb_xml_end_element_wrapper): ... this. Adjust.
12759 (gdb_xml_parser::~gdb_xml_parser): Adjust.
12760 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
12761 (gdb_xml_parser::use_dtd): New method, based on ...
12762 (gdb_xml_use_dtd): ... this. Adjust.
12763 (gdb_xml_parser::parse): New method, based on ...
12764 (gdb_xml_parse): ... this. Adjust.
12765 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
12766 (xinclude_start_include): Adjust to call the parser's name method.
12767 (xml_xinclude_default, xml_xinclude_start_doctype)
12768 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
12769 method.
12770 (xml_process_xincludes): Adjust to call parser methods.
12771 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
12772 declarations.
12773
bd8a901f
PA
127742017-04-18 Pedro Alves <palves@redhat.com>
12775
12776 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
12777 gdb::optional<std::string>.
12778 * xml-support.c: Include <string>.
12779 (scope_level::scope_level(scope_level &&))
12780 (scope_level::~scope_level): Delete.
12781 (scope_level::body): Now a std::string.
12782 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
12783 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
12784 parameter.
12785 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
12786 (xinclude_parsing_data::output): Now a std::string reference.
12787 (xinclude_start_include): Adjust.
12788 (xml_xinclude_default): Adjust.
12789 (xml_process_xincludes): Add 'output' parameter, and return bool.
12790 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
12791 and return bool.
12792 * xml-tdesc.c: Include <unordered_map> and <string>.
12793 (tdesc_xml_cache): Delete.
12794 (tdesc_xml_cache_s): Delete.
12795 (xml_cache): Now an std::unordered_map.
12796 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
12797 (target_fetch_description_xml): Change return type to
12798 gdb::optional<std::string>, and adjust.
12799 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
12800 (target_fetch_description_xml): Change return type to
12801 gdb::optional<std::string>.
12802
d35d1958
PA
128032017-04-18 Pedro Alves <palves@redhat.com>
12804
12805 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12806 unittests/optional-selftests.c.
12807 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
12808 * unittests/optional-selftests.c: New file.
12809 * unittests/optional/assignment/1.cc: New file.
12810 * unittests/optional/assignment/2.cc: New file.
12811 * unittests/optional/assignment/3.cc: New file.
12812 * unittests/optional/assignment/4.cc: New file.
12813 * unittests/optional/assignment/5.cc: New file.
12814 * unittests/optional/assignment/6.cc: New file.
12815 * unittests/optional/assignment/7.cc: New file.
12816 * unittests/optional/cons/copy.cc: New file.
12817 * unittests/optional/cons/default.cc: New file.
12818 * unittests/optional/cons/move.cc: New file.
12819 * unittests/optional/cons/value.cc: New file.
12820 * unittests/optional/in_place.cc: New file.
12821 * unittests/optional/observers/1.cc: New file.
12822 * unittests/optional/observers/2.cc: New file.
12823
22796e97
PA
128242017-04-18 Pedro Alves <palves@redhat.com>
12825
12826 * common/gdb_optional.h: Include common/traits.h.
12827 (in_place_t): New type.
12828 (in_place): New constexpr variable.
12829 (optional::optional): Remove member initialization of
12830 m_instantiated.
12831 (optional::optional(in_place_t...)): New constructor.
12832 (optional::~optional): Use reset.
12833 (optional::optional(const optional&)): New.
12834 (optional::optional(const optional&&)): New.
12835 (optional::optional(T &)): New.
12836 (optional::optional(T &&)): New.
12837 (operator::operator=(const optional &)): New.
12838 (operator::operator=(optional &&)): New.
12839 (operator::operator= (const T &))
12840 (operator::operator= (T &&))
12841 (operator::emplace (Args &&... args)): Return a T&. Use reset.
12842 (operator::reset): New.
12843 (operator::m_instantiated):: Add in-class initializer.
12844 * common/traits.h: Include <type_traits>.
12845 (struct And): New types.
12846
a7fc9b61
PA
128472017-04-18 Pedro Alves <palves@redhat.com>
12848
12849 * xml-support.c: Include <vector>.
12850 (scope_level::scope_level(const gdb_xml_element *))
12851 (scope_level::scope_level(scope_level&&)): New.
12852 (scope_level::~scope_level): New.
12853 (scope_level_s): Delete.
12854 (gdb_xml_parser::scopes): Now a std::vector.
12855 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
12856 Use std::vector.
12857 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
12858 scope cleanup code.
12859 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
12860 of the scopes member. Use std::vector::emplace_back.
12861
010151c9
PA
128622017-04-18 Pedro Alves <palves@redhat.com>
12863
12864 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
12865 a bool.
12866 (gdb_xml_end_element): Change type of first parameter.
12867 (gdb_xml_cleanup): Rename to ...
12868 (gdb_xml_parser::~gdb_xml_parser): ... this.
12869 (gdb_xml_create_parser_and_cleanup): Delete with ...
12870 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
12871 to this new ctor.
12872 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
12873 using gdb_xml_create_parser_and_cleanup.
12874 (xinclude_parsing_data): Add ctor/dtor.
12875 (xml_xinclude_cleanup): Delete.
12876 (xml_process_xincludes): Create a local xinclude_parsing_data
12877 instead of heap-allocating one. Create a local gdb_xml_parser
12878 instead of heap-allocating one with
12879 gdb_xml_create_parser_and_cleanup.
12880
d56060f0
JB
128812017-04-18 John Baldwin <jhb@FreeBSD.org>
12882
12883 PR threads/20743
12884 * fbsd-nat.c (resume_one_thread_cb): Remove.
12885 (resume_all_threads_cb): Remove.
12886 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
12887 iterate_over_threads.
12888
305d16a9
JB
128892017-04-17 Joel Brobecker <brobecker@adacore.com>
12890
12891 * NEWS: Create a new section for the next release branch.
12892 Rename the section of the current branch, now that it has
12893 been cut.
12894
8bb57231
JB
128952017-04-17 Joel Brobecker <brobecker@adacore.com>
12896
12897 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
12898 * version.in: Bump version to 8.0.50.DATE-git.
12899
096c92dd
SDJ
129002017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
12901
12902 PR gdb/21385
12903 * windows-nat.c (windows_create_inferior): Declare 'allargs'
12904 independently of the host, and fix build breakage on Cygwin.
12905
0550c955
PA
129062017-04-13 Pedro Alves <palves@redhat.com>
12907
12908 * inferior.c (free_inferior): Convert to ...
12909 (inferior::~inferior): ... this dtor.
12910 (inferior::inferior): New ctor, factored out from ...
12911 (add_inferior_silent): ... here. Allocate the inferior with a new
12912 expression.
12913 (delete_inferior): Call delete instead of free_inferior.
12914 * inferior.h (gdb_environ, continuation): Forward declare.
12915 (inferior): Now a class. Add in-class initialization to all
12916 members. Make boolean fields bool, except 'detaching'.
12917 (inferior::inferior): New explicit ctor.
12918 (inferior::~inferior): New.
12919
e3d60dfc
PA
129202017-04-13 Pedro Alves <palves@redhat.com>
12921
12922 * inferior.c (init_inferior_list): Delete.
12923 * inferior.h (init_inferior_list): Delete.
12924
5fd69d0a
PA
129252017-04-13 Pedro Alves <palves@redhat.com>
12926
12927 PR threads/13217
12928 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
12929 (top level): Call it twice, with different thread sets.
12930
c6609450
PA
129312017-04-13 Pedro Alves <palves@redhat.com>
12932
12933 * thread.c: Include <algorithm>.
12934 (thread_array_cleanup): Delete.
12935 (scoped_inc_dec_ref): New class.
12936 (live_threads_count): New function.
12937 (set_thread_refcount): Delete.
12938 (tp_array_compar_ascending): Now a bool.
12939 (tp_array_compar): Convert to a std::sort comparison function.
12940 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
12941 and live_threads_count.
12942
2a00d7ce
PA
129432017-04-13 Pedro Alves <palves@redhat.com>
12944
12945 * infrun.c (follow_fork_inferior): Also switch the current
12946 inferior.
12947
441d7c93
PA
129482017-04-13 Pedro Alves <palves@redhat.com>
12949
12950 * breakpoint.c (watch_command_1): Save watchpoint-frame info
12951 before calling create_internal_breakpoint.
12952
808480f6
PA
129532017-04-13 Pedro Alves <palves@redhat.com>
12954
12955 * fork-child.c (execv_argv): New class.
12956 (breakup_args): Refactored as ...
12957 (execv_argv::init_for_no_shell): .. this method of execv_argv.
12958 Copy arguments to storage and replace separators with NULL
12959 terminators in place.
12960 (escape_bang_in_quoted_argument): Adjust to return bool.
12961 (execv_argv::execv_argv): New ctor.
12962 (execv_argv::init_for_shell): New method, factored out from
12963 fork_inferior. Don't strdup strings into the vector.
12964 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
12965 Remove free_vector_argv call.
12966
ad3d022a
YQ
129672017-04-13 Yao Qi <yao.qi@linaro.org>
12968
12969 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
12970 tdep->rx_psw_type.
12971
e6ddc3bf
YQ
129722017-04-13 Yao Qi <yao.qi@linaro.org>
12973
12974 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
12975 * rx-tdep.c (rx_gdbarch_init): Likewise.
12976
bfb8cf90
PA
129772017-04-13 Pedro Alves <palves@redhat.com>
12978
12979 * breakpoint.h (struct breakpoint): Reindent.
12980
f5336ca5
PA
129812017-04-13 Pedro Alves <palves@redhat.com>
12982
12983 * breakpoint.c (bp_location): Rename to ...
12984 (bp_locations): ... this. All references updated.
12985 (bp_location_count): Rename to ...
12986 (bp_locations_count): ... this. All references updated.
12987 (bp_location_placed_address_before_address_max): Rename to ...
12988 (bp_locations_placed_address_before_address_max): ... this. All
12989 references updated.
12990 (bp_location_shadow_len_after_address_max): Rename to ...
12991 (bp_locations_shadow_len_after_address_max): ... this. All
12992 references updated.
12993 (bp_location_compare_addrs): Rename to ...
12994 (bp_locations_compare_addrs): ... this. All references updated.
12995 (bp_location_compare):Rename to ...
12996 (bp_locations_compare): ... this. All references updated.
12997 (bp_location_target_extensions_update): Rename to ...
12998 (bp_locations_target_extensions_update): ... this. All references
12999 updated.
13000
be628ab8
SDJ
130012017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13002
13003 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
13004 * common/common.m4: Check headers 'termios.h', 'termio.h' and
13005 'sgtty.h'.
13006 * common/gdb_termios.h: New file, with parts of "terminal.h".
13007 * inflow.c: Include "gdb_termios.h".
13008 * ser-unix.c: Include "gdb_termios.h".
13009 * terminal.h: Move terminal-related defines to
13010 "common/gdb_termios.h".
13011
8e9e35b1
TT
130122017-04-12 Tom Tromey <tom@tromey.com>
13013
13014 * probe.c (parse_probes): Update.
13015 * location.h (delete_event_location): Don't declare.
13016 (event_location_deleter::operator()): Update.
13017 * location.c (event_location_deleter::operator()): Rename from
13018 delete_event_location.
13019 * linespec.h (linespec_result) <location>: Change type to
13020 event_location_up.
13021 * linespec.c (canonicalize_linespec, event_location_to_sals)
13022 (decode_objc): Update.
13023 (linespec_result): Don't call delete_event_location.
13024 * breakpoint.c (create_breakpoints_sal)
13025 (bkpt_probe_create_sals_from_location)
13026 (strace_marker_create_sals_from_location): Update.
13027
16e802b9
TT
130282017-04-12 Tom Tromey <tom@tromey.com>
13029
13030 * linespec.h (struct linespec_result): Add constructor and
13031 destructor.
13032 (init_linespec_result, destroy_linespec_result)
13033 (make_cleanup_destroy_linespec_result): Don't declare.
13034 * linespec.c (init_linespec_result): Remove.
13035 (linespec_result::~linespec_result): Rename from
13036 destroy_linespec_result. Update.
13037 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
13038 Remove.
13039 * breakpoint.c (create_breakpoint, break_range_command)
13040 (decode_location_default): Update.
13041 * ax-gdb.c (agent_command_1): Update.
13042
d28cd78a
TT
130432017-04-12 Tom Tromey <tom@tromey.com>
13044
13045 * remote.c (remote_download_tracepoint): Update.
13046 * python/py-breakpoint.c (bppy_get_location): Update.
13047 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
13048 (gdbscm_breakpoint_location): Update.
13049 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
13050 * breakpoint.h (struct breakpoint) <location, location_range_end>:
13051 Change type to event_location_up.
13052 * breakpoint.c (create_overlay_event_breakpoint)
13053 (create_longjmp_master_breakpoint)
13054 (create_std_terminate_master_breakpoint)
13055 (create_exception_master_breakpoint)
13056 (breakpoint_event_location_empty_p, print_breakpoint_location)
13057 (print_one_breakpoint_location, create_thread_event_breakpoint)
13058 (init_breakpoint_sal, create_breakpoint)
13059 (print_recreate_ranged_breakpoint, break_range_command)
13060 (init_ada_exception_breakpoint, say_where): Update.
13061 (base_breakpoint_dtor): Don't call delete_event_location.
13062 (bkpt_print_recreate, tracepoint_print_recreate)
13063 (dprintf_print_recreate, update_static_tracepoint)
13064 (breakpoint_re_set_default): Update.
13065
711799d5
TT
130662017-04-12 Tom Tromey <tom@tromey.com>
13067
13068 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
13069 type of "to_do". Update.
13070 (compute_stack_depth): Use std::vector.
13071
52d214d3
TT
130722017-04-12 Tom Tromey <tom@tromey.com>
13073
13074 * printcmd.c (find_instruction_backward): Use std::vector.
13075
4c404b8b
TT
130762017-04-12 Tom Tromey <tom@tromey.com>
13077
13078 * symfile.c (objfilep): Remove typedef.
13079 (reread_symbols): Use a std::vector.
13080
156d9eab
TT
130812017-04-12 Tom Tromey <tom@tromey.com>
13082
13083 * mi/mi-main.c (exec_direction_forward): Remove.
13084 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
13085 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
13086 scoped_restore.
13087 * guile/guile.c (guile_repl_command, guile_command)
13088 (gdbscm_execute_gdb_command): Use scoped_restore.
13089 * go-exp.y (go_parse): Use scoped_restore.
13090 * d-exp.y (d_parse): Use scoped_restore.
13091 * cli/cli-decode.c (cmd_func): Use scoped_restore.
13092 * c-exp.y (c_parse): Use scoped_restore.
13093
4d89769a
TT
130942017-04-12 Tom Tromey <tom@tromey.com>
13095
13096 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
13097 (mi_parse): Update return type.
13098 (mi_parse_free): Remove.
13099 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
13100 (mi_parse::~mi_parse): Rename from mi_parse_free.
13101 (mi_parse_cleanup): Remove.
13102 (mi_parse): Return a unique_ptr. Use new.
13103 * mi/mi-main.c (mi_execute_command): Update.
13104
4b217cc7
TT
131052017-04-12 Tom Tromey <tom@tromey.com>
13106
13107 * location.c (explicit_location_lex_one): Return a
13108 unique_xmalloc_ptr.
13109 (string_to_explicit_location): Update. Remove cleanups.
13110
59d3651b
TT
131112017-04-12 Tom Tromey <tom@tromey.com>
13112
13113 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
13114 (compare_value_and_voffset): Change type. Update.
13115 (compute_vtable_size): Change type of "offset_vec".
13116 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
13117 (gnuv3_get_typeid): Remove extraneous declaration.
13118
b24b0d6c
TT
131192017-04-12 Tom Tromey <tom@tromey.com>
13120
13121 * charset.h (wchar_iterator): Fix comment.
13122
80a3b8c5
TT
131232017-04-12 Tom Tromey <tom@tromey.com>
13124
13125 * charset.c (iconv_wrapper): New class.
13126 (cleanup_iconv): Remove.
13127 (convert_between_encodings): Use it.
13128
c83dd867
TT
131292017-04-12 Tom Tromey <tom@tromey.com>
13130
13131 * symfile.h (increment_reading_symtab): Update type.
13132 * symfile.c (decrement_reading_symtab): Remove.
13133 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
13134 * psymtab.c (psymtab_to_symtab): Update.
13135 * dwarf2read.c (dw2_instantiate_symtab): Update.
13136
0e8621a0
TT
131372017-04-12 Tom Tromey <tom@tromey.com>
13138
13139 * jit.c (struct jit_reader): Declare separately. Add constructor
13140 and destructor. Change type of "handle".
13141 (loaded_jit_reader): Define separately.
13142 (jit_reader_load): Update. New "new".
13143 (jit_reader_unload_command): Use "delete".
13144 * gdb-dlfcn.h (struct dlclose_deleter): New.
13145 (gdb_dlhandle_up): New typedef.
13146 (gdb_dlopen, gdb_dlsym): Update types.
13147 (gdb_dlclose): Remove.
13148 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
13149 (gdb_dlsym): Change type of "handle".
13150 (make_cleanup_dlclose): Remove.
13151 (dlclose_deleter::operator()): Rename from gdb_dlclose.
13152 * compile/compile-c-support.c (load_libcc): Update.
13153
67d89901
TT
131542017-04-12 Tom Tromey <tom@tromey.com>
13155
13156 * symtab.h (find_pcs_for_symtab_line): Change return type.
13157 * symtab.c (find_pcs_for_symtab_line): Change return type.
13158 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
13159 type of "vec". Update.
13160 (ltpy_get_pcs_for_line): Update.
13161 * linespec.c (decode_digits_ordinary): Update.
13162
93921405
TT
131632017-04-12 Tom Tromey <tom@tromey.com>
13164
13165 * tracepoint.c (actions_command): Update.
13166 * python/python.c (python_command, python_interactive_command):
13167 Update.
13168 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
13169 * guile/guile.c (guile_command): Update.
13170 * defs.h (read_command_lines, read_command_lines_1): Return
13171 command_line_up.
13172 (command_lines_deleter): New struct.
13173 (command_line_up): New typedef.
13174 * compile/compile.c (compile_code_command)
13175 (compile_print_command): Update.
13176 * cli/cli-script.h (get_command_line, copy_command_lines): Return
13177 command_line_up.
13178 (make_cleanup_free_command_lines): Remove.
13179 * cli/cli-script.c (get_command_line, read_command_lines_1)
13180 (copy_command_lines): Return command_line_up.
13181 (while_command, if_command, read_command_lines, define_command)
13182 (document_command): Update.
13183 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
13184 Remove.
13185 * breakpoint.h (breakpoint_set_commands): Change type of
13186 "commands".
13187 * breakpoint.c (breakpoint_set_commands): Change type of
13188 "commands". Update.
13189 (do_map_commands_command, update_dprintf_command_list)
13190 (create_tracepoint_from_upload): Update.
13191
ffc2605c
TT
131922017-04-12 Tom Tromey <tom@tromey.com>
13193
13194 * tracepoint.c (scope_info): Update.
13195 * spu-tdep.c (spu_catch_start): Update.
13196 * python/python.c (gdbpy_decode_line): Update.
13197 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
13198 * python/py-breakpoint.c (bppy_init): Update.
13199 * probe.c (parse_probes): Update.
13200 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
13201 * location.h (event_location_deleter): New struct.
13202 (event_location_up): New typedef.
13203 (new_linespec_location, new_address_location, new_probe_location)
13204 (new_explicit_location, copy_event_location)
13205 (string_to_event_location, string_to_event_location_basic)
13206 (string_to_explicit_location): Update return type.
13207 (make_cleanup_delete_event_location): Remove.
13208 * location.c (new_linespec_location, new_address_location)
13209 (new_probe_location, new_explicit_location, copy_event_location):
13210 Return event_location_up.
13211 (delete_event_location_cleanup)
13212 (make_cleanup_delete_event_location): Remove.
13213 (string_to_explicit_location, string_to_event_location_basic)
13214 (string_to_event_location): Return event_location_up.
13215 * linespec.c (canonicalize_linespec, event_location_to_sals)
13216 (decode_line_with_current_source)
13217 (decode_line_with_last_displayed, decode_objc): Update.
13218 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
13219 * completer.c (location_completer): Update.
13220 * cli/cli-cmds.c (edit_command, list_command): Update.
13221 * breakpoint.c (create_overlay_event_breakpoint)
13222 (create_longjmp_master_breakpoint)
13223 (create_std_terminate_master_breakpoint)
13224 (create_exception_master_breakpoint)
13225 (create_thread_event_breakpoint): Update.
13226 (init_breakpoint_sal): Update. Remove some dead code.
13227 (create_breakpoint_sal): Change type of "location". Update.
13228 (create_breakpoints_sal, create_breakpoint, break_command_1)
13229 (dprintf_command, break_range_command, until_break_command)
13230 (init_ada_exception_breakpoint)
13231 (strace_marker_create_sals_from_location)
13232 (update_static_tracepoint, trace_command, ftrace_command)
13233 (strace_command, create_tracepoint_from_upload): Update.
13234 * break-catch-throw.c (re_set_exception_catchpoint): Update.
13235 * ax-gdb.c (agent_command_1): Update.
13236
8f10c932
PA
132372017-04-12 Pedro Alves <palves@redhat.com>
13238
13239 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
13240 * configure.tgt: Handle i[34567]86-*-go32* and
13241 i[34567]86-*-msdosdjgpp*.
13242 * i386-tdep.c (i386_svr4_reg_to_regnum):
13243 Make extern.
13244 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
13245 i386-go32-tdep.c.
13246 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
13247 * i386-go32-tdep.c: New file.
13248 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
13249 declarations.
13250
0a31ccfb
SM
132512017-04-12 Simon Marchi <simon.marchi@ericsson.com>
13252
13253 * aix-thread.c (pd_status2str): Change return type to const char *.
13254
e9bb3fbb
PA
132552017-04-12 Pedro Alves <palves@redhat.com>
13256
13257 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
13258 calls to set_gdbarch_gnu_triplet_regexp.
13259
53375380
PA
132602017-04-12 Pedro Alves <palves@redhat.com>
13261
13262 PR gdb/21323
13263 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
13264 New enum value.
13265 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
13266 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
13267 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
13268 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
13269 * gdbarch.h, gdbarch.c: Regenerate.
13270 * aarch64-tdep.c (aarch64_gdbarch_init): Override
13271 gdbarch_wchar_bit and gdbarch_wchar_signed.
13272 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
13273 * arm-tdep.c (arm_gdbarch_init): Likewise.
13274 * avr-tdep.c (avr_gdbarch_init): Likewise.
13275 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
13276 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
13277 * i386-tdep.c (i386_go32_init_abi): Likewise.
13278 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
13279 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
13280 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
13281 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
13282 * sh-tdep.c (sh_gdbarch_init): Likewise.
13283 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
13284 * sparc64-tdep.c (sparc64_init_abi): Likewise.
13285 * windows-tdep.c (windows_init_abi): Likewise.
13286 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
13287
53e710ac
PA
132882017-04-12 Pedro Alves <palves@redhat.com>
13289
13290 PR c++/21323
13291 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
13292 cplus_primitive_type_char32_t>: New enum values.
13293 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
13294 and cplus_primitive_type_char32_t.
13295 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
13296 32, use the archtecture's built-in type for char16_t and char32_t,
13297 respectively. Otherwise, fallback to init_integer_type as before,
13298 but make the type unsigned, and issue a complaint.
13299 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
13300
ab0538b8
AH
133012017-04-12 Alan Hayward <alan.hayward@arm.com>
13302
5e0e0422 13303 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
13304 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
13305
5430098f
SDJ
133062017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13307
13308 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
13309 'const char *'.
13310
7c5ded6a
SDJ
133112017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13312
13313 * common/common-utils.c (free_vector_argv): New function.
13314 * common/common-utils.h: Include <vector>.
13315 (free_vector_argv): New prototype.
13316 * darwin-nat.c (darwin_create_inferior): Rewrite function
13317 prototype in order to constify "exec_file" and accept a
13318 "std::string" for "allargs".
13319 * fork-child.c: Include <vector>.
13320 (breakup_args): Rewrite function, using C++.
13321 (fork_inferior): Rewrite function header, constify "exec_file_arg"
13322 and accept "std::string" for "allargs". Update the code to
13323 calculate "argv" based on "allargs". Update calls to "exec_fun"
13324 and "execvp".
13325 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
13326 order to constify "exec_file" and accept a "std::string" for
13327 "allargs".
13328 * go32-nat.c (go32_create_inferior): Likewise.
13329 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
13330 * infcmd.c (run_command_1): Constify "exec_file". Use
13331 "std::string" for inferior arguments.
13332 * inferior.h (fork_inferior): Update prototype.
13333 * linux-nat.c (linux_nat_create_inferior): Rewrite function
13334 prototype in order to constify "exec_file" and accept a
13335 "std::string" for "allargs".
13336 * nto-procfs.c (procfs_create_inferior): Likewise.
13337 * procfs.c (procfs_create_inferior): Likewise.
13338 * remote-sim.c (gdbsim_create_inferior): Likewise.
13339 * remote.c (extended_remote_run): Update code to accept
13340 "std::string" as argument.
13341 (extended_remote_create_inferior): Rewrite function prototype in
13342 order to constify "exec_file" and accept a "std::string" for
13343 "allargs".
13344 * rs6000-nat.c (super_create_inferior): Likewise.
13345 (rs6000_create_inferior): Likewise.
13346 * target.h (struct target_ops) <to_create_inferior>: Likewise.
13347 * windows-nat.c (windows_create_inferior): Likewise.
13348
ae0eee42
PA
133492017-04-11 Pedro Alves <palves@redhat.com>
13350
13351 * thread.c: Fix whitespace throughout.
13352
a6acac06
PR
133532017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
13354
13355 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
13356
64403bd1
AH
133572017-04-11 Alan Hayward <alan.hayward@arm.com>
13358
13359 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
13360
a5bef50f
SDJ
133612017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
13362
13363 PR gdb/21364
13364 * osdata.c (info_osdata): Check if 'type' is an empty string
13365 instead of NULL.
13366
9295a5a9
PA
133672017-04-10 Pedro Alves <palves@redhat.com>
13368
13369 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
13370 (ptid_to_global_thread_id, in_thread_list)
13371 (do_captured_list_thread_ids, set_resumed, set_running)
13372 (set_executing, set_stop_requested, finish_thread_state)
13373 (validate_registers_access, can_access_registers_ptid)
13374 (print_thread_info_1, switch_to_thread)
13375 (do_restore_current_thread_cleanup)
13376 (make_cleanup_restore_current_thread, thread_command)
13377 (thread_name_command): Use operator== instead of ptid_equal.
13378
996812e3
PA
133792017-04-10 Pedro Alves <palves@redhat.com>
13380
13381 * thread.c (struct current_thread_cleanup) <next>: Delete field.
13382 (current_thread_cleanup_chain): Delete.
13383 (restore_current_thread_cleanup_dtor)
13384 (make_cleanup_restore_current_thread): Remove references to
13385 current_thread_cleanup_chain.
13386
845b344f
AH
133872017-04-10 Alan Hayward <alan.hayward@arm.com>
13388
13389 * msp430-tdep.c (msp430_pseudo_register_read): Never return
13390 REG_UNKNOWN.
13391
803bdfe4
YQ
133922017-04-10 Yao Qi <yao.qi@linaro.org>
13393
13394 PR gdb/19942
13395 * gdbthread.h (thread_info::deletable): New method.
13396 (thread_info::incref): New method.
13397 (thread_info::decref): New method.
13398 (thread_info::refcount): Move it to private.
13399 * infrun.c (save_stop_context): Call inc_refcount.
13400 (release_stop_context_cleanup): Likewise.
13401 * thread.c (set_thread_exited): New function.
13402 (init_thread_list): Delete "tp" only it is deletable, otherwise
13403 call set_thread_exited.
13404 (delete_thread_1): Call set_thread_exited.
13405 (current_thread_cleanup) <inferior_pid>: Remove.
13406 <thread>: New field.
13407 (restore_current_thread_ptid_changed): Removed.
13408 (do_restore_current_thread_cleanup): Adjust.
13409 (restore_current_thread_cleanup_dtor): Don't call
13410 find_thread_ptid.
13411 (set_thread_refcount): Use dec_refcount.
13412 (make_cleanup_restore_current_thread): Adjust.
13413 (thread_apply_all_command): Call inc_refcount.
13414 (_initialize_thread): Don't call
13415 observer_attach_thread_ptid_changed.
13416
8c25b497
YQ
134172017-04-10 Yao Qi <yao.qi@linaro.org>
13418
13419 * thread.c (delete_thread_1): Hoist code on marking thread as
13420 exited.
13421
8473b447
SM
134222017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13423
13424 * windows-nat.c (windows_detach): Initialize ptid with
13425 minus_one_ptid.
13426
6670ec13
SM
134272017-04-07 Simon Marchi <simon.marchi@ericsson.com>
13428
13429 * unittests/ptid-selftests.c: Fix erroneous assert messages.
13430
ba2f91bb
AH
134312017-04-07 Alan Hayward <alan.hayward@arm.com>
13432
13433 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
13434 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
13435 (bfin_pseudo_register_write): Likewise
13436
436252de
SM
134372017-04-06 Simon Marchi <simon.marchi@ericsson.com>
13438
13439 * common/ptid.h (struct ptid): Change to...
13440 (class ptid_t): ... this.
13441 <ptid_t>: New constructors.
13442 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
13443 matches>: New methods.
13444 <make_null, make_minus_one>: New static methods.
13445 <pid>: Rename to...
13446 <m_pid>: ...this.
13447 <lwp>: Rename to...
13448 <m_lwp>: ...this.
13449 <tid>: Rename to...
13450 <m_tid>: ...this.
13451 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
13452 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
13453 as references, move comment to class ptid_t.
13454 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
13455 ptid_t static methods.
13456 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
13457 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
13458 Take ptid arguments as references, implement using ptid_t methods.
13459 * unittests/ptid-selftests.c: New file.
13460 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13461 unittests/ptid-selftests.c.
13462 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
13463
0dedf377
TP
134642017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
13465
13466 * python/python.c (python_run_simple_file): Cast mode literal to
13467 non-const char pointer as expected by PyFile_FromString.
13468
4e9868d4
SM
134692017-04-05 Simon Marchi <simon.marchi@ericsson.com>
13470
13471 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
13472 minus_one_ptid and null_ptid.
13473
9bf2a700
PA
134742017-04-05 Pedro Alves <palves@redhat.com>
13475
13476 * warning.m4 (build_warnings): Remove -Wno-write-strings.
13477 * configure: Regenerate.
13478
a121b7c1
PA
134792017-04-05 Pedro Alves <palves@redhat.com>
13480
13481 * ada-exp.y (yyerror): Constify.
13482 * ada-lang.c (bound_name, get_selections)
13483 (ada_variant_discrim_type)
13484 (ada_variant_discrim_name, ada_value_struct_elt)
13485 (ada_lookup_struct_elt_type, is_unchecked_variant)
13486 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
13487 (catch_ada_exception_command_split)
13488 (catch_ada_assert_command_split, catch_assert_command)
13489 (ada_op_name): Constify.
13490 * ada-lang.h (ada_yyerror, get_selections)
13491 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
13492 * arc-tdep.c (arc_print_frame_cache): Constify.
13493 * arm-tdep.c (arm_skip_stub): Constify.
13494 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
13495 (gen_aggregate_elt_ref): Constify.
13496 * bcache.c (print_bcache_statistics): Constify.
13497 * bcache.h (print_bcache_statistics): Constify.
13498 * break-catch-throw.c (catch_exception_command_1):
13499 * breakpoint.c (struct ep_type_description::description):
13500 Constify.
13501 (add_solib_catchpoint): Constify.
13502 (catch_fork_command_1): Add cast.
13503 (add_catch_command): Constify.
13504 * breakpoint.h (add_catch_command, add_solib_catchpoint):
13505 Constify.
13506 * bsd-uthread.c (bsd_uthread_state): Constify.
13507 * buildsym.c (patch_subfile_names): Constify.
13508 * buildsym.h (next_symbol_text_func, patch_subfile_names):
13509 Constify.
13510 * c-exp.y (yyerror): Constify.
13511 (token::oper): Constify.
13512 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
13513 * c-varobj.c (cplus_describe_child): Constify.
13514 * charset.c (find_charset_names): Add cast.
13515 (find_charset_names): Constify array and add const_cast.
13516 * cli/cli-cmds.c (complete_command, cd_command): Constify.
13517 (edit_command): Constify.
13518 * cli/cli-decode.c (lookup_cmd): Constify.
13519 * cli/cli-dump.c (dump_memory_command, dump_value_command):
13520 Constify.
13521 (struct dump_context): Constify.
13522 (add_dump_command, restore_command): Constify.
13523 * cli/cli-script.c (get_command_line): Constify.
13524 * cli/cli-script.h (get_command_line): Constify.
13525 * cli/cli-utils.c (check_for_argument): Constify.
13526 * cli/cli-utils.h (check_for_argument): Constify.
13527 * coff-pe-read.c (struct read_pe_section_data): Constify.
13528 * command.h (lookup_cmd): Constify.
13529 * common/print-utils.c (decimal2str): Constify.
13530 * completer.c (gdb_print_filename): Constify.
13531 * corefile.c (set_gnutarget): Constify.
13532 * cp-name-parser.y (yyerror): Constify.
13533 * cp-valprint.c (cp_print_class_member): Constify.
13534 * cris-tdep.c (cris_register_name, crisv32_register_name):
13535 Constify.
13536 * d-exp.y (yyerror): Constify.
13537 (struct token::oper): Constify.
13538 * d-lang.h (d_yyerror): Constify.
13539 * dbxread.c (struct header_file_location::name): Constify.
13540 (add_old_header_file, add_new_header_file, last_function_name)
13541 (dbx_next_symbol_text, add_bincl_to_list)
13542 (find_corresponding_bincl_psymtab, set_namestring)
13543 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
13544 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
13545 * defs.h (command_line_input, print_address_symbolic)
13546 (deprecated_readline_begin_hook): Constify.
13547 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
13548 Constify.
13549 * event-top.c (handle_line_of_input): Constify and add cast.
13550 * exceptions.c (catch_errors): Constify.
13551 * exceptions.h (catch_errors): Constify.
13552 * expprint.c (print_subexp_standard, op_string, op_name)
13553 (op_name_standard, dump_raw_expression, dump_raw_expression):
13554 * expression.h (op_name, op_string, dump_raw_expression):
13555 Constify.
13556 * f-exp.y (yyerror): Constify.
13557 (struct token::oper): Constify.
13558 (struct f77_boolean_val::name): Constify.
13559 * f-lang.c (f_word_break_characters): Constify.
13560 * f-lang.h (f_yyerror): Constify.
13561 * fork-child.c (fork_inferior): Add cast.
13562 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
13563 (new_variant): Constify.
13564 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
13565 * gdbarch.c: Regenerate.
13566 * gdbcore.h (set_gnutarget): Constify.
13567 * go-exp.y (yyerror): Constify.
13568 (token::oper): Constify.
13569 * go-lang.h (go_yyerror): Constify.
13570 * go32-nat.c (go32_sysinfo): Constify.
13571 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
13572 * guile/scm-cmd.c (cmdscm_function): Constify.
13573 * guile/scm-param.c (pascm_param_value): Constify.
13574 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
13575 (h8300sx_register_name): Constify.
13576 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
13577 Constify.
13578 * ia64-tdep.c (ia64_register_names): Constify.
13579 * infcmd.c (construct_inferior_arguments): Constify.
13580 (path_command, attach_post_wait): Constify.
13581 * language.c (show_range_command, show_case_command)
13582 (unk_lang_error): Constify.
13583 * language.h (language_defn::la_error)
13584 (language_defn::la_name_of_this): Constify.
13585 * linespec.c (decode_line_2): Constify.
13586 * linux-thread-db.c (thread_db_err_str): Constify.
13587 * lm32-tdep.c (lm32_register_name): Constify.
13588 * m2-exp.y (yyerror): Constify.
13589 * m2-lang.h (m2_yyerror): Constify.
13590 * m32r-tdep.c (m32r_register_names): Constify and make static.
13591 * m68hc11-tdep.c (m68hc11_register_names): Constify.
13592 * m88k-tdep.c (m88k_register_name): Constify.
13593 * macroexp.c (appendmem): Constify.
13594 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
13595 (upgrade_type, parse_external, parse_partial_symbols)
13596 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
13597 (new_symbol): Constify.
13598 * memattr.c (mem_info_command): Constify.
13599 * mep-tdep.c (register_name_from_keyword): Constify.
13600 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
13601 Constify.
13602 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
13603 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
13604 * mi/mi-main.c (captured_mi_execute_command): Constify and add
13605 cast.
13606 (mi_execute_async_cli_command): Constify.
13607 * mips-tdep.c (mips_register_name): Constify.
13608 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
13609 (am33_register_name, am33_2_register_name)
13610 * moxie-tdep.c (moxie_register_names): Constify.
13611 * nat/linux-osdata.c (osdata_type): Constify fields.
13612 * nto-tdep.c (nto_parse_redirection): Constify.
13613 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
13614 (lookup_child_selector): Constify.
13615 (objc_methcall::name): Constify.
13616 * objc-lang.h (lookup_objc_class, lookup_child_selector)
13617 (lookup_struct_typedef): Constify.
13618 * objfiles.c (pc_in_section): Constify.
13619 * objfiles.h (pc_in_section): Constify.
13620 * p-exp.y (struct token::oper): Constify.
13621 (yyerror): Constify.
13622 * p-lang.h (pascal_yyerror): Constify.
13623 * parser-defs.h (op_name_standard): Constify.
13624 (op_print::string): Constify.
13625 (exp_descriptor::op_name): Constify.
13626 * printcmd.c (print_address_symbolic): Constify.
13627 * psymtab.c (print_partial_symbols): Constify.
13628 * python/py-breakpoint.c (stop_func): Constify.
13629 (bppy_get_expression): Constify.
13630 * python/py-cmd.c (cmdpy_completer::name): Constify.
13631 (cmdpy_function): Constify.
13632 * python/py-event.c (evpy_add_attribute)
13633 (gdbpy_initialize_event_generic): Constify.
13634 * python/py-event.h (evpy_add_attribute)
13635 (gdbpy_initialize_event_generic): Constify.
13636 * python/py-evts.c (add_new_registry): Constify.
13637 * python/py-finishbreakpoint.c (outofscope_func): Constify.
13638 * python/py-framefilter.c (get_py_iter_from_func): Constify.
13639 * python/py-inferior.c (get_buffer): Add cast.
13640 * python/py-param.c (parm_constant::name): Constify.
13641 * python/py-unwind.c (fprint_frame_id): Constify.
13642 * python/python.c (gdbpy_parameter_value): Constify.
13643 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
13644 * remote.c (memory_packet_config::name): Constify.
13645 (show_packet_config_cmd, remote_write_bytes)
13646 (remote_buffer_add_string):
13647 * reverse.c (exec_reverse_once): Constify.
13648 * rs6000-tdep.c (variant::name, variant::description): Constify.
13649 * rust-exp.y (rustyyerror): Constify.
13650 * rust-lang.c (rust_op_name): Constify.
13651 * rust-lang.h (rustyyerror): Constify.
13652 * serial.h (serial_ops::name): Constify.
13653 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
13654 (sh_sh3e_register_name, sh_sh2e_register_name)
13655 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
13656 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
13657 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
13658 (sh_sh4al_dsp_register_name): Constify.
13659 * sh64-tdep.c (sh64_register_name): Constify.
13660 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
13661 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
13662 * stabsread.c (patch_block_stabs, read_type_number)
13663 (ref_map::stabs, ref_add, process_reference)
13664 (symbol_reference_defined, define_symbol, define_symbol)
13665 (error_type, read_type, read_member_functions, read_cpp_abbrev)
13666 (read_one_struct_field, read_struct_fields, read_baseclasses)
13667 (read_tilde_fields, read_struct_type, read_array_type)
13668 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
13669 (read_huge_number, read_range_type, read_args, common_block_start)
13670 (find_name_end): Constify.
13671 * stabsread.h (common_block_start, define_symbol)
13672 (process_one_symbol, symbol_reference_defined, ref_add):
13673 * symfile.c (get_section_index, add_symbol_file_command):
13674 * symfile.h (get_section_index): Constify.
13675 * target-descriptions.c (tdesc_type::name): Constify.
13676 (tdesc_free_type): Add cast.
13677 * target.c (find_default_run_target):
13678 (add_deprecated_target_alias, find_default_run_target)
13679 (target_announce_detach): Constify.
13680 (do_option): Constify.
13681 * target.h (add_deprecated_target_alias): Constify.
13682 * thread.c (print_thread_info_1): Constify.
13683 * top.c (deprecated_readline_begin_hook, command_line_input):
13684 Constify.
13685 (init_main): Add casts.
13686 * top.h (handle_line_of_input): Constify.
13687 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
13688 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
13689 (tfind_command): Rename to ...
13690 (tfind_command_1): ... this and constify.
13691 (tfind_command): New function.
13692 (tfind_end_command, tfind_start_command): Adjust.
13693 (encode_source_string): Constify.
13694 * tracepoint.h (encode_source_string): Constify.
13695 * tui/tui-data.c (tui_partial_win_by_name): Constify.
13696 * tui/tui-data.h (tui_partial_win_by_name): Constify.
13697 * tui/tui-source.c (tui_set_source_content_nil): Constify.
13698 * tui/tui-source.h (tui_set_source_content_nil): Constify.
13699 * tui/tui-win.c (parse_scrolling_args): Constify.
13700 * tui/tui-windata.c (tui_erase_data_content): Constify.
13701 * tui/tui-windata.h (tui_erase_data_content): Constify.
13702 * tui/tui-winsource.c (tui_erase_source_content): Constify.
13703 * tui/tui.c (tui_enable): Add cast.
13704 * utils.c (defaulted_query): Constify.
13705 (init_page_info): Add cast.
13706 (puts_debug, subset_compare): Constify.
13707 * utils.h (subset_compare): Constify.
13708 * varobj.c (varobj_format_string): Constify.
13709 * varobj.h (varobj_format_string): Constify.
13710 * vax-tdep.c (vax_register_name): Constify.
13711 * windows-nat.c (windows_detach): Constify.
13712 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
13713 * xml-support.c (gdb_xml_end_element): Constify.
13714 * xml-tdesc.c (tdesc_start_reg): Constify.
13715 * xstormy16-tdep.c (xstormy16_register_name): Constify.
13716 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
13717 * xtensa-tdep.h (xtensa_register_t::name): Constify.
13718
995816ba
PA
137192017-04-05 Pedro Alves <palves@redhat.com>
13720
13721 * proc-api.c (struct trans): Constify.
13722 (procfs_note): Constify.
13723 * proc-events.c (struct trans, syscall_table):
13724 * proc-flags.c (struct trans): Constify.
13725 * proc-utils.h (procfs_note): Constify.
13726 * proc-why.c (struct trans): Constify.
13727 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
13728 (procfs_detach): Constify.
13729 * sol-thread.c (struct string_map): Constify.
13730 (td_err_string, td_state_string): Constify.
13731
3e83a920
PA
137322017-04-05 Pedro Alves <palves@redhat.com>
13733
13734 * proc-api.c (procfs_filename): Don't initialize
13735 procfs_filename.
13736 (prepare_to_trace): Assume procfs_filename is non-NULL.
13737 (_initialize_proc_api): Give procfs_filename a default value here.
13738
63160a43
PA
137392017-04-05 Pedro Alves <palves@redhat.com>
13740
13741 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
13742 'cond_string' parameter.
13743 (extract_exception_regexp): Constify 'string' parameter.
13744 (catch_exception_command_1): Constify.
13745 * breakpoint.c (init_catchpoint)
13746 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
13747 parameter.
13748 (ep_parse_optional_if_clause, catch_fork_command_1)
13749 (catch_exec_command_1): Constify.
13750 * breakpoint.h (init_catchpoint): Constify 'cond_string'
13751 parameter.
13752 (ep_parse_optional_if_clause): Constify.
13753 * cli/cli-utils.c (remove_trailing_whitespace)
13754 (check_for_argument): Constify.
13755 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
13756 non-const overload.
13757 (check_for_argument): Likewise.
13758
9b2eba3d
PA
137592017-04-05 Pedro Alves <palves@redhat.com>
13760
13761 * event-top.c (command_line_handler): Add cast to execute_command
13762 call.
13763 * record-btrace.c (cmd_record_btrace_bts_start)
13764 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
13765 (cmd_record_btrace_start): Add cast to execute_command call.
13766 * record-full.c (record_full_goto_insn):
13767 * record.c (record_start, record_stop): Add cast to
13768 execute_command_to_string calls.
13769 (cmd_record_start): Add cast to execute_command calls.
13770
2adadf51
PA
137712017-04-05 Pedro Alves <palves@redhat.com>
13772
13773 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
13774 static inline function.
13775 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
13776 array and use gdb_PyArg_ParseTupleAndKeywords.
13777 * python/py-cmd.c (cmdpy_init): Likewise.
13778 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
13779 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
13780 (infpy_search_memory): Likewise.
13781 * python/py-objfile.c (objfpy_add_separate_debug_file)
13782 (gdbpy_lookup_objfile): Likewise.
13783 * python/py-symbol.c (gdbpy_lookup_symbol)
13784 (gdbpy_lookup_global_symbol): Likewise.
13785 * python/py-type.c (gdbpy_lookup_type): Likewise.
13786 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
13787 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
13788 Likewise.
13789
0d1f4ceb
PA
137902017-04-05 Pedro Alves <palves@redhat.com>
13791
13792 * python/python-internal.h (gdb_PyGetSetDef): New type.
13793 * python/py-block.c (block_object_getset)
13794 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
13795 * python/py-event.c (event_object_getset)
13796 (finish_breakpoint_object_getset): Likewise.
13797 * python/py-inferior.c (inferior_object_getset): Likewise.
13798 * python/py-infthread.c (thread_object_getset): Likewise.
13799 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
13800 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
13801 * python/py-objfile.c (objfile_getset): Likewise.
13802 * python/py-progspace.c (pspace_getset): Likewise.
13803 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
13804 Likewise.
13805 * python/py-record.c (recpy_record_getset): Likewise.
13806 * python/py-symbol.c (symbol_object_getset): Likewise.
13807 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
13808 Likewise.
13809 * python/py-type.c (type_object_getset, field_object_getset):
13810 Likewise.
13811 * python/py-value.c (value_object_getset): Likewise.
13812
4d759979
PA
138132017-04-05 Pedro Alves <palves@redhat.com>
13814
13815 * python/python-internal.h (gdb_PyObject_CallMethod)
13816 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
13817 New functions.
13818 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
13819 (PySys_GetObject, PySys_SetPath): New macros.
13820
fdf9e36f
PA
138212017-04-05 Pedro Alves <palves@redhat.com>
13822
13823 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
13824 info_osdata_command.
13825 * osdata.c (info_osdata_command): Rename to ...
13826 (info_osdata): ... this. Constify 'type' parameter, and remove
13827 the 'from_tty' parameter. Accept NULL TYPE.
13828 (info_osdata_command): New function.
13829 * osdata.h (info_osdata_command): Remove declaration.
13830 (info_osdata): New declaration.
13831
9f33b8b7
PA
138322017-04-05 Pedro Alves <palves@redhat.com>
13833
13834 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
13835 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
13836 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
13837 parameter.
13838 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
13839 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
13840 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
13841 parameter.
13842 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
13843 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
13844 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
13845 (mi_cmd_file_list_exec_source_files)
13846 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
13847 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13848 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
13849 parameter.
13850 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
13851 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
13852 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
13853 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
13854 (mi_cmd_stack_info_frame): Constify 'command' parameter.
13855 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
13856 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
13857 'command' parameter.
13858 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
13859 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
13860 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
13861 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
13862 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
13863 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
13864 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
13865 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
13866 (mi_cmd_var_set_update_range): Constify 'command' parameter.
13867 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
13868 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
13869 parameter.
13870 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
13871 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
13872 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
13873 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
13874 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
13875 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
13876 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
13877 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
13878 (mi_cmd_data_list_changed_registers)
13879 (mi_cmd_data_write_register_values)
13880 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
13881 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
13882 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
13883 (mi_cmd_list_features, mi_cmd_list_target_features)
13884 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
13885 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
13886 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
13887 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
13888 (mi_cmd_trace_frame_collected): Constify 'command'
13889 parameter.
13890 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
13891 'command' parameter.
13892
67cb5b2d
PA
138932017-04-05 Pedro Alves <palves@redhat.com>
13894
13895 * ada-lang.c (ada_completer_word_break_characters): Now a const
13896 array.
13897 (ada_get_gdb_completer_word_break_characters): Constify.
13898 * completer.c (gdb_completer_command_word_break_characters)
13899 (gdb_completer_file_name_break_characters)
13900 (gdb_completer_quote_characters): Now const arrays.
13901 (get_gdb_completer_quote_characters): Constify.
13902 (set_rl_completer_word_break_characters): New function.
13903 (set_gdb_completion_word_break_characters)
13904 (complete_line_internal): Use it.
13905 * completer.h (get_gdb_completer_quote_characters): Constify.
13906 (set_rl_completer_word_break_characters): Declare.
13907 * f-lang.c (f_word_break_characters): Constify.
13908 * language.c (default_word_break_characters): Constify.
13909 * language.h (language_defn::la_word_break_characters): Constify.
13910 (default_word_break_characters): Constify.
13911 * top.c (init_main): Use set_rl_completer_word_break_characters.
13912
7a114964
PA
139132017-04-05 Pedro Alves <palves@redhat.com>
13914
13915 * aix-thread.c (aix_thread_pid_to_str)
13916 (aix_thread_extra_thread_info): Constify.
13917 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
13918 * bsd-uthread.c (bsd_uthread_extra_thread_info)
13919 (bsd_uthread_pid_to_str): Constify.
13920 * corelow.c (core_pid_to_str): Constify.
13921 * darwin-nat.c (darwin_pid_to_str): Constify.
13922 * fbsd-nat.c (fbsd_pid_to_str): Constify.
13923 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
13924 Constify.
13925 * gnu-nat.c (gnu_pid_to_str): Constify.
13926 * go32-nat.c (go32_pid_to_str): Constify.
13927 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
13928 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
13929 * inferior.c (inferior_pid_to_str): Constify.
13930 * linux-nat.c (linux_nat_pid_to_str): Constify.
13931 * linux-tdep.c (linux_core_pid_to_str): Constify.
13932 * linux-thread-db.c (thread_db_pid_to_str)
13933 (thread_db_extra_thread_info): Constify.
13934 * nto-tdep.c (nto_extra_thread_info): Constify.
13935 * nto-tdep.h (nto_extra_thread_info): Constify.
13936 * obsd-nat.c (obsd_pid_to_str): Constify.
13937 * procfs.c (procfs_pid_to_str): Constify.
13938 * ravenscar-thread.c (ravenscar_extra_thread_info)
13939 (ravenscar_pid_to_str): Constify.
13940 * remote-sim.c (gdbsim_pid_to_str): Constify.
13941 * remote.c (remote_threads_extra_info, remote_pid_to_str):
13942 Constify.
13943 * sol-thread.c (solaris_pid_to_str): Constify.
13944 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
13945 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
13946 * target.c (default_pid_to_str, target_pid_to_str)
13947 (normal_pid_to_str, default_pid_to_str): Constify.
13948 * target.h (target_ops::to_pid_to_str)
13949 (target_ops::to_extra_thread_info): Constify.
13950 (target_pid_to_str, normal_pid_to_str): Constify.
13951 * windows-nat.c (windows_pid_to_str): Constify.
13952 * gdbarch.sh (core_pid_to_str): Constify.
13953 * target-delegates.c: Regenerate.
13954 * gdbarch.h, gdbarch.c: Regenerate.
13955
69bbf465
PA
139562017-04-05 Pedro Alves <palves@redhat.com>
13957
13958 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
13959 the memory of the temporary warning_pre_print override.
13960 * utils.c (warning_pre_print): Constify.
13961 * utils.h (warning_pre_print): Constify.
13962
be47f9e8
PA
139632017-04-05 Pedro Alves <palves@redhat.com>
13964
13965 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
13966 (shell_command): New function.
13967 (make_command): Use std::string.
13968 (init_cli_cmds): Register shell_command instead of shell_escape.
13969
bde6261a
PA
139702017-04-05 Pedro Alves <palves@redhat.com>
13971
13972 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
13973 * tracepoint.c (default_collect): Don't initialize.
13974
b38ef47f
PA
139752017-04-05 Pedro Alves <palves@redhat.com>
13976
13977 * macroexp.c (macro_buffer::shared): Now a bool.
13978 (init_buffer): Update.
13979 (init_shared_buffer): Constify 'addr' parameter.
13980 (substitute_args, expand, macro_expand, macro_expand_next): Remove
13981 casts.
13982
f995bbe8
PA
139832017-04-05 Pedro Alves <palves@redhat.com>
13984
13985 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
13986 * disasm.c (set_disassembler_options): Constify local.
13987 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
13988
4a596fe2
SDJ
139892017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
13990
13991 PR gdb/21352
13992 * tracefile.c (tsave_command): Fix argument parsing for '-r'
13993 option.
13994
2cad08ea
YQ
139952017-04-05 Yao Qi <yao.qi@linaro.org>
13996
13997 * frame.c (frame_unwind_register_unsigned): Call
13998 frame_unwind_register_value.
13999
55a98976
YQ
140002017-04-05 Yao Qi <yao.qi@linaro.org>
14001
14002 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
14003 Use gdb_test_multiple, and don't match anchor.
14004
4ac40124
PA
140052017-04-05 Pedro Alves <palves@redhat.com>
14006
14007 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
14008 (Write After Approval): Remove Simon Marchi.
14009
c053b654
PA
140102017-04-05 Pedro Alves <palves@redhat.com>
14011
14012 * common/gdb_optional.h (optional::optional): Make constexpr and
14013 initialize m_dummy.
14014
4c7bf4f9
JB
140152017-04-04 John Baldwin <jhb@FreeBSD.org>
14016
14017 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
14018 (amd64fbsd_jmp_buf_reg_offset): Remove.
14019 (amd64fbsd_supply_uthread): Remove function.
14020 (amd64fbsd_collect_uthread): Remove function.
14021 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
14022 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
14023 (x86_64-*-freebsd*): Remove bsd-uthread.o.
14024 (fbsd-nat.c): Update comment.
14025 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
14026 (i386fbsd_jmp_buf_reg_offset): Remove.
14027 (i386fbsd_supply_uthread): Remove function.
14028 (i386fbsd_collect_uthread): Remove function.
14029 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
14030
1e1a8bef
JB
140312017-04-04 John Baldwin <jhb@FreeBSD.org>
14032
14033 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
14034 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
14035 * NEWS: Mention that support for FreeBSD/alpha was removed.
14036 * alpha-fbsd-tdep.c: Delete file.
14037 * config/alpha/fbsd.mh: Delete file.
14038 * configure.host: Delete alpha*-*-freebsd* and
14039 alpha*-*-kfreebsd*-gnu.
14040 * configure.tgt: Delete alpha*-*-freebsd* and
14041 alpha*-*-kfreebsd*-gnu.
14042
49907934
JB
140432017-04-04 John Baldwin <jhb@FreeBSD.org>
14044
14045 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
14046 amd64bsd_store_inferior_registers): Use ptid from regcache.
14047
6f77053d
PA
140482017-04-04 Pedro Alves <palves@redhat.com>
14049
14050 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
14051 data fields, make them private and add "m_" prefixes.
14052 (lnp_state_machine::lnp_state_machine): New ctor.
14053 (record_line, check_line_address, handle_set_discriminator)
14054 (handle_set_address, handle_advance_pc, handle_special_opcode)
14055 (handle_advance_line, handle_set_file, handle_negate_stmt)
14056 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
14057 (end_sequence, advance_line): New methods.
14058 (m_gdbarch, m_record_lines_p): New fields.
14059 (lnp_reader_state): Delete.
14060 (dwarf_record_line): Rename to ...
14061 (lnp_state_machine::record_line): ... adjust.
14062 (init_lnp_state_machine): Delete.
14063 (lnp_state_machine::lnp_state_machine): New.
14064 (check_line_address): Rename to ...
14065 (lnp_state_machine::check_line_address): This.
14066 (dwarf_decode_lines_1): Remove reference to "reader_state".
14067 Adjust lnp_state_machine having a non-default ctor. Use bool.
14068 State machine internal state manipulation moved to
14069 lnp_state_machine methods.
14070
9c541725
PA
140712017-04-04 Pedro Alves <palves@redhat.com>
14072
14073 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14074 unittests/offset-type-selftests.c.
14075 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
14076 * common/offset-type.h: New file.
14077 * common/preprocessor.h: New file.
14078 * common/traits.h: New file.
14079 * common/valid-expr.h: New file.
14080 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
14081 sect_offset and cu_offset strong typedefs throughout.
14082 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
14083 typedefs throughout.
14084 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
14085 sect_offset and cu_offset strong typedefs throughout.
14086 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
14087 typedefs throughout.
14088 * gdbtypes.h: Include "common/offset-type.h".
14089 (cu_offset): Now an offset type (strong typedef) instead of a
14090 struct.
14091 (sect_offset): Likewise.
14092 (union call_site_parameter_u): Rename "param_offset" field to
14093 "param_cu_off".
14094 * unittests/offset-type-selftests.c: New file.
14095
ecfb656c
PA
140962017-04-04 Pedro Alves <palves@redhat.com>
14097
14098 * common/underlying.h: New file.
14099 * dwarf2read.c: Include "common/gdb_optional.h" and
14100 "common/underlying.h".
14101 (dir_index, file_name_index): New types.
14102 (file_entry): Use them.
14103 (file_entry::include): Use to_underlying.
14104 (line_header::add_file_name): Use dir_index.
14105 (read_formatted_entries): Use gdb::optional. Read form before
14106 writting to file_entry.
14107 (dwarf_decode_line_header): Use dir_index.
14108 (lnp_state_machine::current_file): Use to_underlying.
14109 (lnp_state_machine::file): Change type to file_name_index.
14110 (dwarf_record_line): Use to_underlying.
14111 (init_lnp_state_machine): Use file_name_index.
14112 (dwarf_decode_lines_1): Use dir_index and file_name_index.
14113
d194f1fe
PA
141142017-04-04 Pedro Alves <palves@redhat.com>
14115
14116 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
14117 operator bool, has_value and get methods.
14118
fff8551c
PA
141192017-04-04 Pedro Alves <palves@redhat.com>
14120
14121 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
14122 fields.
14123 (line_header): Initialize all data fields. Change type of
14124 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
14125 Change type of include_dirs to std::vector<const char *>. Remove
14126 num_include_dirs, include_dirs_size. Change type of file_names to
14127 std::vector<file_entry>. Remove num_file_names, file_names_size.
14128 (line_header::line_header): New.
14129 (line_header::add_include_dir, line_header::add_file_name): New
14130 methods.
14131 (line_header::include_dir_at): Remove NULL check.
14132 (line_header::file_name_at): Add const overload.
14133 (line_header_up): New unique_ptr typedef.
14134 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
14135 std::vector. Remove free_line_header call.
14136 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
14137 free_line_header call.
14138 (free_cu_line_header): Delete.
14139 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
14140 (setup_type_unit_groups): Use line_header_up instead of cleanups.
14141 Adjust to use std::vector.
14142 (free_line_header): Delete.
14143 (free_line_header_voidp): Use delete.
14144 (add_include_dir): Replace with ...
14145 (line_header::add_include_dir): ... this method. Use std::vector.
14146 (add_file_name): Replace with ...
14147 (line_header::add_file_name): ... this method. Use std::vector.
14148 (add_include_dir_stub): Delete.
14149 (read_formatted_entries): Remove memset.
14150 (dwarf_decode_line_header): Return a line_header_up instead of a
14151 raw pointer. Remove cleanup handling. Pass lambdas to
14152 read_formatted_entries. Adjust to use line_header methods.
14153 (dwarf_decode_lines_1): Adjust to use line_header methods.
14154 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
14155 use std::vector.
14156
d62a8ae2
SM
141572017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
14158
14159 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
14160 instead of struct ptid.
14161
db3a1dc7
AH
141622017-05-04 Alan Hayward <alan.hayward@arm.com>
14163
14164 * frame.c (get_frame_register_bytes): Unwind using value.
14165 (put_frame_register_bytes): Likewise.
14166
b1b45502
IB
141672017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
14168
14169 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
14170 aggregate-like.
14171
ec13808e
JK
141722017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
14173
14174 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
14175
12316564
YQ
141762017-03-29 Yao Qi <yao.qi@linaro.org>
14177
14178 * gdbthread.h (struct thread_info): Declare constructor and
14179 destructor. Add some in-class member initializers.
14180 * thread.c (free_thread): Remove.
14181 (init_thread_list): Call delete instead of free_thread.
14182 (new_thread): Call thread_info constructor.
14183 (thread_info::thread_info): New function.
14184 (thread_info::~thread_info): New function.
14185 (delete_thread_1): Call delete instead of free_thread.
14186 (make_cleanup_restore_current_thread): Move tp and frame to
14187 inner block.
14188
fe5f7374
AK
141892017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14190
14191 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
14192 (arc_skip_prologue): Likewise.
14193 (arc_make_frame_cache): Likewise.
14194 (arc_pv_get_operand): New function.
14195 (arc_is_in_prologue): Likewise.
14196 (arc_analyze_prologue): Likewise.
14197 (arc_print_frame_cache): Likewise.
14198 (MAX_PROLOGUE_LENGTH): New constant.
14199
eea78757
AK
142002017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14201
14202 * configure.tgt: Add arc-insn.o.
14203 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
14204 (dump_arc_instruction_command): New function.
14205 (arc_fprintf_disasm): Likewise.
14206 (arc_disassemble_info): Likewise.
14207 (arc_insn_get_operand_value): Likewise.
14208 (arc_insn_get_operand_value_signed): Likewise.
14209 (arc_insn_get_memory_base_reg): Likewise.
14210 (arc_insn_get_memory_offset): Likewise.
14211 (arc_insn_get_branch_target): Likewise.
14212 (arc_insn_dump): Likewise.
14213 (arc_insn_get_linear_next_pc): Likewise.
14214 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
14215 (arc_disassemble_info): Likewise.
14216 (arc_insn_get_branch_target): Likewise.
14217 (arc_insn_get_linear_next_pc): Likewise.
14218 * NEWS: Mention new "maint print arc arc-instruction".
14219
3be78afd
AK
142202017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14221
14222 * arc-tdep (maintenance_print_arc_list): New variable.
14223 (maintenance_print_arc_command): New function.
14224
296ec4fa
AK
142252017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14226
14227 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
14228 Add "limm" and "reserved".
14229 (arc_cannot_fetch_register, arc_cannot_store_register): Add
14230 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
14231 * arc-tdep.h (arc_regnum): Likewise.
14232
f74f865e
MF
142332017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14234
14235 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14236 for THREADPTR register.
14237 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
14238 register.
14239 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
14240 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
14241 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
14242
0d0bf81a
MF
142432017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14244
14245 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
14246 registers above gdbarch_num_regs (gdbarch) as privileged in
14247 call0 ABI.
14248
0ce4291e
MF
142492017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14250
14251 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14252 for a single specified register or for all registers in
14253 a0_base..a0_base + C0_NREGS range.
14254 (supply_gregset_reg): Call regcache_raw_supply for a single
14255 specified register or for all registers in a0_base..a0_base +
14256 C0_NREGS range.
14257
c56054f9
MF
142582017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14259
14260 * arch/xtensa.h (C0_NREGS): Add definition.
14261 * xtensa-tdep.c (C0_NREGS): Remove definition.
14262
a4398628
MF
142632017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14264
14265 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
14266 Drop xtensa_default_isa initialization.
14267 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
14268
8c43009f
PA
142692017-03-27 Pedro Alves <palves@redhat.com>
14270
14271 * dwarf2read.c (file_entry) <dir_index>: Add comment.
14272 (file_entry::include_dir): New method.
14273 (line_header::include_dir_at, line_header::file_name_at): New
14274 methods.
14275 (setup_type_unit_groups, setup_type_unit_groups)
14276 (psymtab_include_file_name): Simplify using the new methods.
14277 (lnp_state_machine) <the_line_header>: New field.
14278 <file>: Add comment.
14279 (lnp_state_machine::current_file): New method.
14280 (dwarf_record_line): Simplify using the new methods.
14281 (init_lnp_state_machine): Initialize the "the_line_header" field.
14282 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
14283 Simplify using the new methods.
14284
a7e80b9e
PA
142852017-03-27 Pedro Alves <palves@redhat.com>
14286
14287 * cp-name-parser.y (make_empty): Delete.
14288 (demangler_special, nested_name, ptr_operator, array_indicator)
14289 (direct_declarator, declarator_1): Use fill_comp instead of
14290 make_empty.
14291
21047726
PA
142922017-03-27 Pedro Alves <palves@redhat.com>
14293
14294 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
14295 to ATTRIBUTE_PRINTF.
14296 * solib-target.c (library_list_start_list): Print "string" not
14297 "version".
14298 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
14299 gdb_xml_error call.
14300
d721ba37
PA
143012017-03-27 Pedro Alves <palves@redhat.com>
14302
14303 * dwarf2read.c (struct file_and_directory): New.
14304 (dwarf2_get_dwz_file): Adjust to use std::string.
14305 (dw2_get_file_names_reader): Adjust to use file_and_directory.
14306 (find_file_and_directory): Adjust to return a file_and_directory
14307 object.
14308 (read_file_scope): Adjust to use file_and_directory. Remove
14309 make_cleanup/do_cleanups calls.
14310 (open_and_init_dwp_file): Adjust to use std::string. Remove
14311 make_cleanup/do_cleanups calls.
14312 * python/python.c (do_start_initialization): Adjust to ldirname
14313 returning a std::string.
14314 * utils.c (ldirname): Now returns a std::string.
14315 * utils.h (ldirname): Change return type to std::string.
14316 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
14317 returning a std::string.
14318 * xml-tdesc.c (file_read_description_xml): Likewise.
14319
ed771251
AH
143202017-03-24 Alan Hayward <alan.hayward@arm.com>
14321
14322 * regcache.c (regcache_debug_print_register): New function.
14323 * regcache.h (regcache_debug_print_register): New declaration.
14324 * target.c (debug_print_register): Remove.
14325 (target_fetch_registers): Call regcache_debug_print_register.
14326 (target_store_registers): Likewise.
14327
568c1b9f
PB
143282017-03-24 Pádraig Brady <pbrady@fb.com>
14329
14330 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
14331 reference beyond the 'lh->include_dirs' array before accessing to
14332 it.
14333 (psymtab_include_file_name): Likewise.
14334 (dwarf_decode_lines_1): Likewise.
14335 (dwarf_decode_lines): Likewise.
14336 (file_file_name): Likewise.
14337
3e00d44f
SM
143382017-03-23 Simon Marchi <simon.marchi@ericsson.com>
14339
14340 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
14341 inferior_ptid.
14342 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14343 ps_lsetfpregs): Likewise.
14344 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
14345 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14346 ps_lsetfpregs): Likewise.
14347 * target.c (target_fetch_registers, target_store_registers):
14348 Remove asserts.
14349
077ae656
AH
143502017-03-23 Alan Hayward <alan.hayward@arm.com>
14351
14352 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
14353
1e2b521d
YQ
143542017-03-23 Yao Qi <yao.qi@linaro.org>
14355
14356 * aarch64-tdep.c (aarch64_process_record_test): Declare.
14357 (_initialize_aarch64_tdep): Register it.
14358 (aarch64_record_load_store): Handle PRFM instruction.
14359 (aarch64_process_record_test): New function.
14360
33877125
YQ
143612017-03-23 Yao Qi <yao.qi@linaro.org>
14362
14363 * aarch64-tdep.c (aarch64_record_load_store): Fix code
14364 indentation.
14365
a0eef940
YQ
143662017-03-23 Yao Qi <yao.qi@linaro.org>
14367
14368 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
14369
3f2a3564
PR
143702017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14371
14372 python/python.c (do_start_initialization): Fix memory leak.
14373
b67aeab0
SM
143742017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
14375
14376 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
14377 using get_ptrace_pid.
14378 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
14379 inferior_ptid.
14380 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
14381 inferior_ptid instead of pid.
14382
ffdbe864
YQ
143832017-03-22 Yao Qi <yao.qi@linaro.org>
14384
14385 * aarch64-tdep.c: Wrap locally used classes in anonymous
14386 namespace.
14387 * arm-tdep.c: Likewise.
14388 * linespec.c: Likewise.
14389 * ui-out.c: Likewise.
14390
9d736fbf
JG
143912017-03-22 Jonah Graham <jonah@kichwacoders.com>
14392
14393 PR gdb/19637
14394 * python/lib/gdb/printer/bound_registers.py: Import sys.
14395
3de88e9a
SM
143962017-03-21 Simon Marchi <simon.marchi@ericsson.com>
14397
14398 * windows-nat.c (do_windows_fetch_inferior_registers): Add
14399 windows_thread_info parameter and use it instead of
14400 current_thread.
14401 (windows_fetch_inferior_registers): Don't set current_thread,
14402 pass the thread to do_windows_fetch_inferior_registers. Use
14403 ptid from regcache instead of inferior_ptid.
14404 (do_windows_store_inferior_registers): Add windows_thread_info
14405 parameter and use it instead of current_thread.
14406 (windows_store_inferior_registers): Don't set current_thread,
14407 pass the thread to do_windows_store_inferior_registers. Use
14408 ptid from regcache instead of inferior_ptid.
14409
0e7b8f61
SM
144102017-03-21 Simon Marchi <simon.marchi@ericsson.com>
14411
14412 * ser-mingw.c (ser_windows_raw): Remove reference to
14413 struct serial::current_timeout.
14414
5badf10a
IR
144152017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
14416
14417 PR tdep/20928
14418 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
14419 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
14420 (sparc64_fsr_type): Fix %fsr decoding.
14421
cee59b3f
TW
144222017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
14423
14424 * python/py-record-btrace.c (btpy_insn_data): Change return type
14425 for Python 2.
14426
639a9038
SM
144272017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
14428
14429 * spu-linux-nat.c (spu_fetch_inferior_registers,
14430 spu_store_inferior_registers): Use ptid from regcache, set and
14431 restore inferior_ptid.
14432 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
14433 Likewise.
14434
bcc0c096
SM
144352017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
14436
14437 * i386-linux-nat.c (fetch_register, store_register,
14438 i386_linux_fetch_inferior_registers,
14439 i386_linux_store_inferior_registers): Use ptid from regcache.
14440 * ia64-linux-nat.c (ia64_linux_fetch_register,
14441 ia64_linux_store_register): Likewise.
14442 * inf-ptrace.c (inf_ptrace_fetch_register,
14443 inf_ptrace_store_register): Likewise.
14444 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
14445 m32r_linux_store_inferior_registers): Likewise.
14446 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
14447 m68kbsd_store_inferior_registers): Likewise.
14448 * m68k-linux-nat.c (fetch_register, store_register,
14449 m68k_linux_fetch_inferior_registers,
14450 m68k_linux_store_inferior_registers): Likewise.
14451 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
14452 m88kbsd_store_inferior_registers): Likewise.
14453 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
14454 mips_fbsd_store_inferior_registers): Likewise.
14455 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
14456 mips64_linux_regsets_store_registers): Likewise.
14457 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
14458 mipsnbsd_store_inferior_registers): Likewise.
14459 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
14460 mips64obsd_store_inferior_registers): Likewise.
14461 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
14462 Likewise.
14463 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
14464 ppcfbsd_store_inferior_registers): Likewise.
14465 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
14466 ppc_linux_store_inferior_registers): Likewise.
14467 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
14468 ppcnbsd_store_inferior_registers): Likewise.
14469 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
14470 ppcobsd_store_registers): Likewise.
14471 * procfs.c (procfs_fetch_registers, procfs_store_registers):
14472 Likewise.
14473 * ravenscar-thread.c (ravenscar_fetch_registers,
14474 ravenscar_store_registers, ravenscar_prepare_to_store):
14475 Likewise.
14476 * record-btrace.c (record_btrace_fetch_registers,
14477 record_btrace_store_registers, record_btrace_prepare_to_store):
14478 Likewise.
14479 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
14480 Lookup inferior using ptid from regcache, instead of
14481 current_inferior.
14482 * remote.c (remote_fetch_registers, remote_store_registers): Use
14483 ptid from regcache.
14484 * rs6000-nat.c (fetch_register, store_register): Likewise.
14485 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
14486 s390_linux_store_inferior_registers): Likewise.
14487 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
14488 shnbsd_store_inferior_registers): Likewise.
14489 * sol-thread.c (sol_thread_fetch_registers,
14490 sol_thread_store_registers): Likewise.
14491 * sparc-nat.c (sparc_fetch_inferior_registers,
14492 sparc_store_inferior_registers): Likewise.
14493 * tilegx-linux-nat.c (fetch_inferior_registers,
14494 store_inferior_registers): Likewise.
14495 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
14496 vaxbsd_store_inferior_registers): Likewise.
14497 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
14498 store_xtregs): Likewise.
14499
c0f55cc6
AV
145002017-03-20 Artemiy Volkov <artemiyv@acm.org>
14501
14502 PR gdb/14441
14503 * NEWS: Mention support for rvalue references in GDB and python.
14504 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
14505 supports both lvalue and rvalue references.
14506
15c0a2a9
AV
145072017-03-20 Artemiy Volkov <artemiyv@acm.org>
14508
14509 PR gdb/14441
14510 * gdbtypes.c (rank_one_type): Implement overloading
14511 resolution rules regarding rvalue references.
14512
aa006118
AV
145132017-03-20 Artemiy Volkov <artemiyv@acm.org>
14514
14515 PR gdb/14441
14516 * aarch64-tdep.c (aarch64_type_align)
14517 (aarch64_extract_return_value, aarch64_store_return_value): Change
14518 lvalue reference type checks to general reference type checks.
14519 * amd64-tdep.c (amd64_classify): Likewise.
14520 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
14521 Likewise.
14522 * arm-tdep.c (arm_type_align, arm_extract_return_value)
14523 (arm_store_return_value): Likewise.
14524 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
14525 * c-typeprint.c (c_print_type): Likewise.
14526 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
14527 (cplus_number_of_children, cplus_describe_child): Likewise.
14528 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
14529 * completer.c (expression_completer): Likewise.
14530 * cp-support.c (make_symbol_overload_list_adl_namespace):
14531 Likewise.
14532 * darwin-nat-info.c (info_mach_region_command): Likewise.
14533 * dwarf2loc.c (entry_data_value_coerce_ref)
14534 (value_of_dwarf_reg_entry): Likewise.
14535 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
14536 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
14537 Likewise.
14538 * findvar.c (extract_typed_address, store_typed_address):
14539 Likewise.
14540 * gdbtypes.c (rank_one_type): Likewise.
14541 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
14542 * infcall.c (value_arg_coerce): Likewise.
14543 * language.c (pointer_type): Likewise.
14544 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
14545 Likewise.
14546 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
14547 * mn10300-tdep.c (mn10300_type_align): Likewise.
14548 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
14549 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
14550 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
14551 Likewise.
14552 * printcmd.c (print_formatted, x_command): Likewise.
14553 * python/py-type.c (typy_get_composite, typy_template_argument):
14554 Likewise.
14555 * python/py-value.c (valpy_referenced_value)
14556 (valpy_get_dynamic_type, value_has_field): Likewise.
14557 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
14558 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
14559 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
14560 * spu-tdep.c (spu_scalar_value_p): Likewise.
14561 * symtab.c (lookup_symbol_aux): Likewise.
14562 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
14563 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
14564 Likewise.
14565 * valops.c (value_cast_pointers, value_cast)
14566 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
14567 (value_struct_elt, value_struct_elt_bitpos)
14568 (value_find_oload_method_list, find_overload_match)
14569 (value_rtti_indirect_type): Likewise.
14570 * valprint.c (val_print_scalar_type_p, generic_val_print):
14571 Likewise.
14572 * value.c (value_actual_type, value_as_address, unpack_long)
14573 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
14574 (coerce_ref): Likewise.
14575 * varobj.c (varobj_get_value_type): Likewise.
14576
3fcf899d
AV
145772017-03-20 Artemiy Volkov <artemiyv@acm.org>
14578
14579 PR gdb/14441
14580 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
14581 table of constants.
14582 * python/lib/gdb/command/explore.py: Support exploring values
14583 of rvalue reference types.
14584 * python/lib/gdb/types.py: Implement get_basic_type() for
14585 rvalue reference types.
14586 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
14587 constant.
14588 * python/py-value.c (valpy_getitem): Add an rvalue reference
14589 check.
14590 (valpy_reference_value): Add new parameter "refcode".
14591 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
14592 New wrappers for valpy_reference_value().
14593 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
14594 (gdbpy_invoke_xmethod): Likewise.
14595
4297a3f0
AV
145962017-03-20 Artemiy Volkov <artemiyv@acm.org>
14597
14598 PR gdb/14441
14599 * dwarf2read.c (process_die, read_type_die_1): Handle the
14600 DW_TAG_rvalue_reference_type DIE.
14601 (read_tag_reference_type): Add new parameter "refcode".
14602
e1cb3213
AV
146032017-03-20 Artemiy Volkov <artemiyv@acm.org>
14604
14605 PR gdb/14441
14606 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
14607 (c_type_print_modifier, c_type_print_varspec_suffix)
14608 (c_type_print_base): Support printing rvalue reference types.
14609 * c-valprint.c (c_val_print, c_value_print): Support printing
14610 rvalue reference values.
14611
e4347c89
AV
146122017-03-20 Artemiy Volkov <artemiyv@acm.org>
14613
14614 PR gdb/14441
14615 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
14616 typename.
14617 * cp-support.c (replace_typedefs): Handle
14618 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
14619 * python/py-type.c (typy_lookup_type): Likewise.
14620
53cc15f5
AV
146212017-03-20 Artemiy Volkov <artemiyv@acm.org>
14622
14623 PR gdb/14441
14624 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
14625 * parse.c (insert_type): Change assert statement.
14626 (follow_types): Handle rvalue reference types.
14627 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
14628 constant.
14629
a65cfae5
AV
146302017-03-20 Artemiy Volkov <artemiyv@acm.org>
14631
14632 PR gdb/14441
14633 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
14634 value_ref() interface.
14635 * c-valprint.c (c_value_print): Likewise.
14636 * infcall.c (value_arg_coerce): Likewise.
14637 * python/py-value.c (valpy_reference_value): Likewise.
14638 * valops.c (value_cast, value_reinterpret_cast)
14639 (value_dynamic_cast, typecmp): Likewise.
14640 (value_ref): Parameterize by kind of return value reference type.
14641 * value.h (value_ref): Add new parameter "refcode".
14642
3b224330
AV
146432017-03-20 Artemiy Volkov <artemiyv@acm.org>
14644
14645 PR gdb/14441
14646 * dwarf2read.c (read_tag_reference_type): Use
14647 lookup_lvalue_reference_type() instead of lookup_reference_type().
14648 * eval.c (evaluate_subexp_standard): Likewise.
14649 * f-exp.y: Likewise.
14650 * gdbtypes.c (make_reference_type, lookup_reference_type):
14651 Generalize with rvalue reference types.
14652 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
14653 convenience wrappers for lookup_reference_type().
14654 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
14655 reference kind parameter.
14656 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
14657 wrappers for lookup_reference_type().
14658 * guile/scm-type.c (gdbscm_type_reference): Use
14659 lookup_lvalue_reference_type() instead of lookup_reference_type().
14660 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
14661 * parse.c (follow_types): Likewise.
14662 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
14663 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
14664 Likewise.
14665 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
14666 (gdbpy_invoke_xmethod): Likewise.
14667 * stabsread.c: Provide extra argument to make_reference_type()
14668 call.
14669 * valops.c (value_ref, value_rtti_indirect_type): Use
14670 lookup_lvalue_reference_type() instead of lookup_reference_type().
14671
f9aeb8d4
AV
146722017-03-20 Artemiy Volkov <artemiyv@acm.org>
14673
14674 PR gdb/14441
14675 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
14676 (TYPE_IS_REFERENCE): New macro.
14677 (struct type): Add rvalue_reference_type field.
14678 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
14679
51457a05
MAL
146802017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
14681
14682 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
14683 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
14684 New function definition.
14685 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
14686 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
14687 New function declaration.
14688 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
14689 * mi/mi-interp.h: New file.
14690 * solib.c (info_sharedlibrary_command): Replace for loop with
14691 ALL_SO_LIBS macro
14692 * solib.h (update_solib_list): New function declaration.
14693 (so_list_head): Move macro.
14694 * solist.h (ALL_SO_LIBS): New macro.
14695
e696b3ad
MAL
146962017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
14697
14698 * infcmd.c (post_create_inferior): Remove unused argument in
14699 call to solib_add.
14700 * remote.c (remote_start_remote): Likewise.
14701 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
14702 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
14703 (enable_break): Likewise.
14704 * solib.c (update_solib_list): Remove unused target argument
14705 and its documentation.
14706 (solib_add): Remove unused target argument. Remove unused
14707 argument in call to update_solib_list.
14708 (info_sharedlibrary_command): Remove unused argument in call
14709 to update_solib_list.
14710 (sharedlibrary_command): Remove unused argument in call to
14711 solib_add.
14712 (handle_solib_event): Likewise.
14713 (reload_shared_libraries): Likewise.
14714 * solib.h (solib_add): Remove unused target argument.
14715
dcb84eda
AA
147162017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
14717
14718 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
14719 (s390_displaced_step_fixup): Cover relative branches with the
14720 default fixup handling. This fixes lack of support for some
14721 relative branch instructions.
14722
d9cb6cdc
SM
147232017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14724
14725 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
14726 ptid from regcache.
14727
1afaf9f4
SM
147282017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14729
14730 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
14731 i386_darwin_store_inferior_registers): Use ptid from regcache.
14732
aac12e24
SM
147332017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14734
14735 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
14736 i386bsd_store_inferior_registers): Use ptid from regcache.
14737
bbe1eef1
SM
147382017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14739
14740 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
14741 hppaobsd_store_registers): Use ptid from regcache.
14742
10799020
SM
147432017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14744
14745 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
14746 hppanbsd_store_registers): Use ptid from regcache.
14747
00204cf7
SM
147482017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14749
14750 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
14751 from regcache. Use get_ptrace_pid.
14752
11a33714
SM
147532017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14754
14755 * corelow.c (get_core_register_section): Use ptid from regcache,
14756 update doc.
14757
317cd492
SM
147582017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14759
14760 * bsd-uthread.c (bsd_uthread_fetch_registers,
14761 bsd_uthread_store_registers): Use ptid from regcache, set and
14762 restore inferior_ptid.
14763
9ac8a7c2
SM
147642017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14765
14766 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
14767 fetch_fp_regs, store_register, store_regs, store_fp_register,
14768 store_fp_regs): Use ptid from regcache.
14769
4ac4bb6a
SM
147702017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14771
14772 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
14773 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
14774 store_vfp_regs): Use ptid from regcache.
14775
9bcbdca8
PA
147762017-03-17 Pedro Alves <palves@redhat.com>
14777
14778 PR remote/21188
14779 * ser-base.c (ser_base_wait_for): Add comment.
14780 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
14781 version.
14782 * ser-unix.c (hardwire_raw): Remove reference to
14783 scb->current_timeout.
14784 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
14785 (hardwire_ops): Install ser_base_readchar instead of
14786 hardwire_readchar.
14787 * serial.h (struct serial) <current_timeout, timeout_remaining>:
14788 Remove fields.
14789
7503099f
JG
147902017-03-17 Jonah Graham <jonah@kichwacoders.com>
14791
14792 PR gdb/19637
14793 * python/lib/gdb/printer/bound_registers.py: Add support for
14794 Python 3.
14795
7942e96e
AA
147962017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
14797
14798 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
14799 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
14800 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
14801 byte_offset to subobj_byte_offset. Fix the handling of
14802 DWARF_VALUE_STACK on big-endian targets when coming via an
14803 implicit pointer.
14804 (dwarf2_evaluate_loc_desc): Adjust call to
14805 dwarf2_evaluate_loc_desc_full.
14806 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
14807 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
14808
ba14f379
YQ
148092017-03-16 Yao Qi <yao.qi@linaro.org>
14810
14811 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
14812 and REVSH instructions.
14813
b121eeb9
YQ
148142017-03-16 Yao Qi <yao.qi@linaro.org>
14815
14816 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
14817 (arm_record_test): Declare.
14818 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
14819 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
14820 align with the manual.
14821 (thumb_record_misc): Adjust the code order to align with the
14822 manual.
14823 (thumb2_record_decode_insn_handler): Fix instruction matching.
14824 (instruction_reader_thumb): New class.
14825 (arm_record_test): New function.
14826
728a7913
YQ
148272017-03-16 Yao Qi <yao.qi@linaro.org>
14828
14829 * arm-tdep.c (abstract_memory_reader): New class.
14830 (instruction_reader): New class.
14831 (extract_arm_insn): Add argument 'reader'. Callers updated.
14832 (decode_insn): Likewise.
14833
34b43320
DE
148342017-03-16 Doug Evans <dje@google.com>
14835
a7c0469f
DE
14836 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
14837 member. Change type of TYPE member to SCM. All uses updated.
14838 (lsscm_make_lazy_string_smob): Add assert.
14839 (lsscm_make_lazy_string): Flag bad length values.
14840 (lsscm_elt_type): New function.
14841 (gdbscm_lazy_string_to_value): Rewrite to use
14842 lsscm_safe_lazy_string_to_value.
14843 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
14844 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
14845 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
14846 in incoming type.
14847 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
14848 * guile/scm-type.c (tyscm_scm_to_type): New function.
14849
148502017-03-15 Doug Evans <dje@google.com>
14851
34b43320
DE
14852 PR python/17728, python/18439, python/18779
14853 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
14854 member. Change type of TYPE member to PyObject *. All uses updated.
14855 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
14856 (gdbpy_create_lazy_string_object): Flag bad length values.
14857 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
14858 Handle typedefs in incoming type.
14859 (stpy_lazy_string_elt_type): New function.
14860 (gdbpy_extract_lazy_string): Call it.
14861 * python/py-value.c (valpy_lazy_string): Flag bad length values.
14862 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
14863 typedefs in incoming type.
14864
a3a5fecc
DE
148652017-03-16 Doug Evans <dje@google.com>
14866
14867 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
14868 * guile/scm-type.c (tyscm_scm_to_type): New function.
14869
28f1c605
JW
148702017-03-16 Jiong Wang <jiong.wang@arm.com>
14871
14872 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
14873 "ULONGEST" for "skip".
14874
87c336f6
AA
148752017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
14876
14877 PR gdb/21220
14878 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
14879 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
14880 (inf_ptrace_peek_poke): ...here. New function. Now also loop
14881 over ptrace peek/poke until end of buffer or error.
14882
cf81cf60
SM
148832017-03-14 Simon Marchi <simon.marchi@ericsson.com>
14884
14885 * parse.c (length_of_subexp): Make static.
14886 * parser-defs.h (length_of_subexp): Remove.
14887
a379284a
AA
148882017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
14889
14890 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
14891 as well.
14892
8a6200ba
PA
148932017-03-14 Pedro Alves <palves@redhat.com>
14894
14895 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
14896 (main): Use std::unique_ptr. Remove calls to
14897 cp_demangled_name_parse_free.
14898
f79ec206
SM
148992017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14900
14901 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
14902 alphabsd_store_inferior_registers): Use regcache->ptid instead
14903 of inferior_ptid.
14904
edb5fb00
SM
149052017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14906
14907 * aix-thread.c (aix_thread_fetch_registers,
14908 aix_thread_store_registers): Use regcache->ptid instead of
14909 inferior_ptid.
14910
55119686
SM
149112017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14912
14913 * aarch64-linux-nat.c (fetch_gregs_from_thread,
14914 store_gregs_to_thread, fetch_fpregs_from_thread,
14915 store_fpregs_to_thread): Use regcache->ptid instead of
14916 inferior_ptid.
14917
6a06fbb7
SM
149182017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14919
14920 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
14921 amd64_linux_fetch_inferior_registers): Use regcache->ptid
14922 instead of inferior_ptid.
14923
c6386875
SM
149242017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14925
14926 * target.c (target_fetch_registers, target_store_registers): Add
14927 assert.
14928
ddaaf0fb
SM
149292017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14930
14931 * regcache.h (regcache_get_ptid): New function.
14932 * regcache.c (regcache_get_ptid): New function.
14933
b9da89d1 149342017-03-13 Mark Wielaard <mark@klomp.org>
14935
14936 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
14937
5f4d1085
KS
149382017-03-10 Keith Seitz <keiths@redhat.com>
14939
14940 PR c++/8218
14941 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
14942
c65d6b55
PA
149432017-03-08 Pedro Alves <palves@redhat.com>
14944
14945 PR gdb/18360
14946 * infrun.c (start_step_over, do_target_resume, resume)
14947 (restart_threads): Assert we're not resuming a thread that is
14948 meant to be stopped.
14949 (infrun_thread_stop_requested_callback): Delete.
14950 (infrun_thread_stop_requested): If the thread is internally
14951 stopped, queue a pending stop event and clear the thread's
14952 inline-frame state.
14953 (handle_stop_requested): New function.
14954 (handle_syscall_event, handle_inferior_event_1): Use
14955 handle_stop_requested.
14956 (handle_stop_requested): New function.
14957 (handle_signal_stop): Set the thread's stop_signal here instead of
14958 at caller.
14959 (finish_step_over): Clear step over info unconditionally.
14960 (handle_signal_stop): If the user had interrupted the event
14961 thread, consider the stop a random signal.
14962 (handle_signal_stop) <signal arrived while stepping over
14963 breakpoint>: Don't restart threads here.
14964 (stop_waiting): Don't clear step-over info here.
14965
15c22686
PA
149662017-03-08 Pedro Alves <palves@redhat.com>
14967
14968 PR 21206
14969 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
14970 goes to argument 2, not 1.
14971
6e5d74e7
PA
149722017-03-08 Pedro Alves <palves@redhat.com>
14973
14974 PR cli/21218
14975 * top.c (gdb_readline_wrapper): Avoid passing NULL to
14976 display_gdb_prompt.
14977 (command_line_input): Add comment.
14978
9753a2f6
PA
149792017-03-08 Pedro Alves <palves@redhat.com>
14980
14981 PR tui/21216
14982 * tui/tui-file.c (tui_file::write): New.
14983 * tui/tui-file.h (tui_file): Override "write".
14984 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
14985 factored out from ...
14986 (tui_puts): ... here.
14987 (tui_putc): Use them.
14988 (tui_write): New function.
14989 * tui/tui-io.h (tui_write): Declare.
14990
1672e0d9
SDJ
149912017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
14992
14993 * Makefile.in (SFILES): Replace "environ.c" with
14994 "common/environ.c".
14995 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
14996 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
14997 to...
14998 * common/environ.c: ... here.
14999 * environ.h: Moved to...
15000 * common/environ.h: ... here.
15001
f7bb4e3a
PB
150022017-03-07 Peter Bergner <bergner@vnet.ibm.com>
15003
15004 * gdbarch.sh (pstring_ptr): New static function.
15005 (gdbarch_disassembler_options): Use it.
15006 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
15007 not valid_disassembler_option->name.
15008 * gdbarch.c: Regenerate.
15009
e45ced6c
PB
150102017-03-07 Peter Bergner <bergner@vnet.ibm.com>
15011
15012 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
15013
5f6fd321
PA
150142017-03-07 Pedro Alves <palves@redhat.com>
15015
15016 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
15017
6dbb839a 150182017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
15019
15020 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
15021 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
15022 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 15023 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 15024
d274ecf4
SM
150252017-03-06 Simon Marchi <simon.marchi@ericsson.com>
15026
15027 * xtensa-linux-nat.c (fetch_gregs): Remove const.
15028
df97be55
SM
150292017-03-03 Simon Marchi <simon.marchi@ericsson.com>
15030
15031 * remote.c (remote_add_target_side_commands): Use range-based
15032 for loop.
15033
7d45f3df
YQ
150342017-03-03 Yao Qi <yao.qi@linaro.org>
15035
15036 PR gdb/21165
15037 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
15038 value is lazy.
15039 * valprint.c (common_val_print): Likewise.
15040
65b48a81
PB
150412017-02-28 Peter Bergner <bergner@vnet.ibm.com>
15042
15043 * NEWS: Mention new set/show disassembler-options commands.
15044 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
15045 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
15046 (prospective_options): New static variable.
15047 (gdb_disassembler::gdb_disassembler): Initialize
15048 m_di.disassembler_options.
15049 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
15050 (get_disassembler_options): New function.
15051 (set_disassembler_options): Likewise.
15052 (set_disassembler_options_sfunc): Likewise.
15053 (show_disassembler_options_sfunc): Likewise.
15054 (disassembler_options_completer): Likewise.
15055 (_initialize_disasm): Likewise.
15056 * disasm.h (get_disassembler_options): New prototype.
15057 (set_disassembler_options): Likewise.
15058 * gdbarch.sh (gdbarch_disassembler_options): New variable.
15059 (gdbarch_verify_disassembler_options): Likewise.
15060 * gdbarch.c: Regenerate.
15061 * gdbarch.h: Likewise.
15062 * arm-tdep.c (num_disassembly_options): Delete.
15063 (set_disassembly_style): Likewise.
15064 (arm_disassembler_options): New static variable.
15065 (set_disassembly_style_sfunc): Convert short style name into long
15066 option name. Call set_disassembler_options.
15067 (show_disassembly_style_sfunc): New function.
15068 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
15069 set_gdbarch_verify_disassembler_options.
15070 (_initialize_arm_tdep): Delete regnames variable and update callers.
15071 (arm_disassembler_options): Initialize.
15072 (disasm_options): New variable.
15073 (num_disassembly_options): Rename from this...
15074 (num_disassembly_styles): ...to this. Compute by scanning through
15075 disasm_options.
15076 (valid_disassembly_styles): Initialize using disasm_options.
15077 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
15078 set_arm_regname_option.
15079 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
15080 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
15081 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
15082 set_gdbarch_verify_disassembler_options.
15083 * s390-tdep.c (s390_disassembler_options): New static variable.
15084 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
15085 set_gdbarch_verify_disassembler_options.
15086
d538e36d
SM
150872017-02-27 Simon Marchi <simon.marchi@ericsson.com>
15088
15089 * remote.c (remote_add_target_side_condition): Remove "struct"
15090 keyword from range-based for loop.
15091
83621223
SM
150922017-02-27 Simon Marchi <simon.marchi@ericsson.com>
15093
15094 * remote.c (remote_add_target_side_condition): Use range-based
15095 for loop. Update comment.
15096
2123df0e
YQ
150972017-02-27 Yao Qi <yao.qi@linaro.org>
15098
15099 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
15100
8e368124
AH
151012017-02-26 Alan Hayward <alan.hayward@arm.com>
15102
15103 * regcache.c (regcache_raw_update): New function.
15104 (regcache_raw_read): Move code to regcache_raw_update.
15105 * regcache.h (regcache_raw_update): New declaration.
15106 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
15107
a49dd8dd
JK
151082017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
15109
15110 * dwarf2read.c (create_debug_type_hash_table): Initialize
15111 header.signature and header.type_offset_in_tu.
15112
34e4bae9
PA
151132017-02-24 Pedro Alves <palves@redhat.com>
15114
15115 * symtab.c (make_file_symbol_completion_list_1): Use
15116 add_symtab_completions.
15117
b0e4b369
AH
151182017-02-24 Alan Hayward <alan.hayward@arm.com>
15119
15120 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
15121
975c21ab
AH
151222017-02-24 Alan Hayward <alan.hayward@arm.com>
15123
15124 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
15125 I386_MAX_REGISTER_SIZE.
15126 (i386_pseudo_register_write): Likewise.
15127 (i386_process_record): Likewise.
15128 * i387-tdep.c (i387_supply_xsave): Likewise.
15129 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
15130 (store_register): Likewise.
15131
14bc53a8
PA
151322017-02-23 Pedro Alves <palves@redhat.com>
15133
15134 * ada-lang.c: Include "common/function-view.h".
15135 (ada_iterate_over_symbols): Adjust to use function_view as
15136 callback type.
15137 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
15138 (ada_make_symbol_completion_list): Use a lambda.
15139 (ada_exc_search_name_matches): Delete.
15140 (name_matches_regex): New.
15141 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
15142 * compile/compile-c-support.c: Include "common/function-view.h".
15143 (print_one_macro): Change prototype to accept a ui_file pointer.
15144 (write_macro_definitions): Use a lambda.
15145 * dwarf2read.c: Include "common/function-view.h".
15146 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
15147 (dw2_expand_symtabs_matching): Adjust to use function_view as
15148 callback type.
15149 * language.h: Include "common/function-view.h".
15150 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
15151 function_view as callback type.
15152 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
15153 * linespec.c: Include "common/function-view.h".
15154 (collect_info::add_symbol): New method.
15155 (struct symbol_and_data_callback, iterate_inline_only, struct
15156 symbol_matcher_data, iterate_name_matcher): Delete.
15157 (iterate_over_all_matching_symtabs): Adjust to use function_view
15158 as callback type and lambdas.
15159 (iterate_over_file_blocks): Adjust to use function_view as
15160 callback type.
15161 (decode_compound_collector): Now a class with private fields.
15162 (decode_compound_collector::release_symbols): New method.
15163 (collect_one_symbol): Rename to...
15164 (decode_compound_collector::operator()): ... this and adjust.
15165 (lookup_prefix_sym): decode_compound_collector construction bits
15166 move to decode_compound_collector ctor. Pass the
15167 decode_compound_collector object directly as callback. Remove
15168 cleanups and use decode_compound_collector::release_symbols
15169 instead.
15170 (symtab_collector): Now a class with private fields.
15171 (symtab_collector::release_symtabs): New method.
15172 (add_symtabs_to_list): Rename to...
15173 (symtab_collector::operator()): ... this and adjust.
15174 (collect_symtabs_from_filename): symtab_collector construction
15175 bits move to symtab_collector ctor. Pass the symtab_collector
15176 object directly as callback. Remove cleanups and use
15177 symtab_collector::release_symtabs instead.
15178 (collect_symbols): Delete.
15179 (add_matching_symbols_to_info): Use lambdas.
15180 * macrocmd.c (print_macro_callback): Delete.
15181 (info_macro_command): Use a lambda.
15182 (info_macros_command): Pass print_macro_definition as callable
15183 directly.
15184 (print_one_macro): Remove 'ignore' parameter.
15185 (macro_list_command): Adjust.
15186 * macrotab.c (macro_for_each_data::fn): Now a function_view.
15187 (macro_for_each_data::user_data): Delete field.
15188 (foreach_macro): Adjust to call the function_view.
15189 (macro_for_each): Adjust to use function_view as callback type.
15190 (foreach_macro_in_scope): Adjust to call the function_view.
15191 (macro_for_each_in_scope): Adjust to use function_view as callback
15192 type.
15193 * macrotab.h: Include "common/function-view.h".
15194 (macro_callback_fn): Declare a prototype instead of a pointer.
15195 Remove "user_data" parameter.
15196 (macro_for_each, macro_for_each_in_scope): Adjust to use
15197 function_view as callback type.
15198 * psymtab.c (partial_map_expand_apply)
15199 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
15200 Adjust to use function_view as callback type and to return bool.
15201 (psym_expand_symtabs_matching): Adjust to use function_view as
15202 callback types.
15203 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
15204 to use function_view as callback type and to return bool.
15205 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
15206 callback types.
15207 * symfile.c (expand_symtabs_matching): Adjust to use function_view
15208 as callback types.
15209 * symfile.h: Include "common/function-view.h".
15210 (expand_symtabs_file_matcher_ftype)
15211 (expand_symtabs_symbol_matcher_ftype)
15212 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
15213 return bool.
15214 (quick_symbol_functions::map_symtabs_matching_filename)
15215 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
15216 function_view as callback type and return bool.
15217 (expand_symtabs_matching): Adjust to use function_view as callback
15218 type.
15219 (maintenance_expand_name_matcher)
15220 (maintenance_expand_file_matcher): Delete.
15221 (maintenance_expand_symtabs): Use lambdas.
15222 * symtab.c (iterate_over_some_symtabs): Adjust to use
15223 function_view as callback types and return bool.
15224 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
15225 of a cleanup.
15226 (lookup_symtab_callback): Delete.
15227 (lookup_symtab): Use a lambda.
15228 (iterate_over_symbols): Adjust to use function_view as callback
15229 type.
15230 (struct search_symbols_data, search_symbols_file_matches)
15231 (search_symbols_name_matches): Delete.
15232 (search_symbols): Use a pair of lambdas.
15233 (struct add_name_data, add_macro_name, symbol_completion_matcher)
15234 (symtab_expansion_callback): Delete.
15235 (default_make_symbol_completion_list_break_on_1): Use lambdas.
15236 * symtab.h: Include "common/function-view.h".
15237 (iterate_over_some_symtabs): Adjust to use function_view as
15238 callback type and return bool.
15239 (iterate_over_symtabs): Adjust to use function_view as callback
15240 type.
15241 (symbol_found_callback_ftype): Remove 'data' parameter and return
15242 bool.
15243 (iterate_over_symbols): Adjust to use function_view as callback
15244 type.
15245
07e253aa
PA
152462017-02-23 Pedro Alves <palves@redhat.com>
15247
15248 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
15249 (%.o) <unittests/%.c>: New pattern.
15250 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
15251 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
15252 * common/function-view.h: New file.
15253 * unittests/function-view-selftests.c: New file.
15254 * configure: Regenerate.
15255
8eaf5320
SM
152562017-02-23 Simon Marchi <simon.marchi@ericsson.com>
15257
15258 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
15259 inferior_ptid.
15260 * go32-nat.c (go32_thread_alive): Likewise.
15261
38768751
YQ
152622017-02-23 Yao Qi <yao.qi@linaro.org>
15263
15264 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
15265 delete.
15266
0a8beaba
YQ
152672017-02-23 Yao Qi <yao.qi@linaro.org>
15268
15269 * varobj.c (varobj_clear_saved_item): Use delete instead of
15270 xfree.
15271 (update_dynamic_varobj_children): Likewise.
15272
58fdfd2c
JK
152732017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15274
15275 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
15276
1b90b139
SM
152772017-02-21 Simon Marchi <simon.marchi@ericsson.com>
15278
15279 * common/enum-flags.h (enum_flags::enum_flags): Initialize
15280 m_enum_value to 0 in default constructor.
15281
2039d74e
EBM
152822017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
15283
15284 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
15285 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
15286 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
15287 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
15288 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
15289 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
15290 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
15291 IS_STORE_CONDITIONAL_INSN.
15292
7814882a
JK
152932017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15294
15295 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
15296
0ae60b63
JK
152972017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15298
15299 * NEWS (Changes since GDB 7.12): Add DWARF-5.
15300
0224619f
JK
153012017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15302
15303 * dwarf2read.c (skip_one_die, read_attribute_value)
15304 (dwarf2_const_value_attr, dump_die_shallow)
15305 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
15306 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
15307
0af92d60
JK
153082017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15309
15310 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
15311 (dwarf_parse_macro_header): Accept DWARF version 5.
15312 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
15313
216f72a1
JK
153142017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15315
15316 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
15317 DW_AT_GNU_*.
15318 * common/common-exceptions.h (enum errors): Likewise.
15319 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
15320 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
15321 (dwarf_expr_context::execute_stack_op): Likewise.
15322 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
15323 Likewise.
15324 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
15325 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
15326 (show_entry_values_debug, call_site_to_target_addr)
15327 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
15328 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
15329 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
15330 (value_of_dwarf_block_entry, indirect_pieced_value)
15331 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
15332 (disassemble_dwarf_expression): Likewise.
15333 * dwarf2read.c (process_die, inherit_abstract_dies)
15334 (read_call_site_scope): Likewise.
15335 * gdbtypes.h (struct func_type, struct call_site_parameter)
15336 (struct call_site): Likewise.
15337 * stack.c (read_frame_arg): Likewise.
15338 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
15339
43988095
JK
153402017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15341
15342 * defs.h (read_unsigned_leb128): New declaration.
15343 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
15344 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
15345 (dwarf2_find_location_expression): Call also
15346 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
15347 * dwarf2loc.h (dwarf2_version): New declaration.
15348 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
15349 rnglists.
15350 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
15351 .debug_rnglists.
15352 (struct dwop_section_names): Add loclists_dwo.
15353 (dwop_section_names): Add .debug_loclists.dwo.
15354 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
15355 (struct dwarf2_per_cu_data): Add dwarf_version.
15356 (struct dwo_sections): Add loclists.
15357 (struct attr_abbrev): Add implicit_const.
15358 (read_indirect_line_string): New declaration.
15359 (read_unsigned_leb128): Delete declaration.
15360 (rcuh_kind): New definition.
15361 (read_and_check_comp_unit_head): Change parameter
15362 is_debug_types_section to section_kind.
15363 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
15364 (read_comp_unit_head): Change parameter abfd to section, add parameter
15365 section_kind. Handle DWARF-5.
15366 (error_check_comp_unit_head): Accept also DWARF version 5.
15367 (read_and_check_comp_unit_head): Change parameter
15368 is_debug_types_section to section_kind.
15369 (read_and_check_type_unit_head): Delete function.
15370 (read_abbrev_offset): Handle DWARF-5.
15371 (create_debug_type_hash_table): Add parameter section_kind. Process
15372 only DW_UT_type. Use signature and type_offset_in_tu from struct
15373 comp_unit_head.
15374 (create_debug_types_hash_table): Update create_debug_type_hash_table
15375 caller.
15376 (create_all_type_units): Call create_debug_type_hash_table.
15377 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
15378 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
15379 caller.
15380 (skip_one_die): Handle DW_FORM_implicit_const.
15381 (dwarf2_rnglists_process): New function.
15382 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
15383 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
15384 (read_attribute_value): Handle DW_FORM_implicit_const,
15385 DW_FORM_line_strp.
15386 (read_attribute): Handle DW_FORM_implicit_const.
15387 (read_indirect_string_at_offset_from): New function from
15388 read_indirect_string_at_offset.
15389 (read_indirect_string_at_offset): Call
15390 read_indirect_string_at_offset_from.
15391 (read_indirect_line_string_at_offset): New function.
15392 (read_indirect_string): New function comment.
15393 (read_indirect_line_string): New function.
15394 (read_unsigned_leb128): Make it global.
15395 (dwarf2_string_attr): Handle DWARF-5.
15396 (add_include_dir_stub, read_formatted_entries): New functions.
15397 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
15398 Handle DWARF-5.
15399 (per_cu_header_read_in): Update read_comp_unit_head caller.
15400 (dwarf2_version): New function.
15401 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
15402 rnglists.
15403 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
15404 fields.
15405
22d2f3ab
JK
154062017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15407
15408 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
15409
5f46c5a5
JK
154102017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15411
15412 * dwarf2read.c (dwarf2_ranges_process): New function from
15413 dwarf2_ranges_read.
15414 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
15415 dwarf2_ranges_process.
15416
78d4d2c5
JK
154172017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15418
15419 * dwarf2read.c (create_debug_type_hash_table): New function from
15420 create_debug_types_hash_table.
15421 (create_debug_types_hash_table): Call create_debug_type_hash_table.
15422 (create_all_type_units, open_and_init_dwo_file): Update
15423 create_debug_types_hash_table callers.
15424
1b076f25
SDJ
154252017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
15426
15427 PR gdb/16188
15428 * fork-child.c (trace_start_error): Fix thinko. va_end should
15429 refer to 'ap', not 'args'.
15430
0db8980c
SDJ
154312017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
15432 Pedro Alves <palves@redhat.com>
15433
15434 PR gdb/16188
15435 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
15436 calls succeeded.
15437 * fork-child.c (trace_start_error): New function.
15438 (trace_start_error_with_name): Likewise.
15439 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
15440 * inf-ptrace.c (inf_ptrace_me): Likewise.
15441 * inferior.h (trace_start_error): New prototype.
15442 (trace_start_error_with_name): Likewise.
15443
99e8a4f9
SDJ
154442017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
15445
15446 PR gdb/21164
15447 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
15448 NULL before using it.
15449 * symmisc.c (maintenance_print_symbols): Likewise.
15450 (maintenance_print_msymbols): Likewise.
15451
4e746bb6
TW
154522017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15453
15454 * NEWS: Add record Python bindings entry.
15455
154562017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15457
15458 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
15459 py-record-full.o.
15460 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
15461 * python/py-record-btrace.c, python/py-record-btrace.h,
15462 python/py-record-full.c, python/py-record-full.h: New file.
15463 * python/py-record.c: Add include for py-record-btrace.h and
15464 py-record-full.h.
15465 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
15466 recpy_instruction_history, recpy_function_call_history, recpy_begin,
15467 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
15468 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
15469 New definition.
15470 (gdbpy_initialize_btrace): New export.
15471 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
15472
154732017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15474
15475 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
15476 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
15477 * python/py-record.c: New file.
15478 * python/python-internal.h (gdbpy_start_recording,
15479 gdbpy_current_recording, gdpy_stop_recording,
15480 gdbpy_initialize_record): New export.
15481 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
15482 (python_GdbMethods): Add gdbpy_start_recording,
15483 gdbpy_current_recording and gdbpy_stop_recording.
15484
154852017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15486
15487 * record-btrace.c (record_btrace_record_method): New function.
15488 (init_record_btrace_ops): Initialize to_record_method.
15489 * record-full.c (record_full_record_method): New function.
15490 (init_record_full_ops, init_record_full_core_ops): Add
15491 record_full_record_method.
15492 * record.h (enum record_method): New enum.
15493 * target-debug.h (target_debug_print_enum_record_method: New define.
15494 * target-delegates.c: Regenerate.
15495 * target.c (target_record_method): New function.
15496 * target.h: Include record.h.
15497 (struct target_ops) <to_record_method>: New field.
15498 (target_record_method): New export.
15499
155002017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15501
15502 * record.h (record_start, record_stop): New export.
15503 * record.c (record_start, record_stop): New function.
15504
155052017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15506
15507 * btrace.c (btrace_fetch): Copy function call segments pointer
15508 into a vector.
15509 (btrace_clear): Clear the vector.
15510 (btrace_find_insn_by_number): Use binary search to find the correct
15511 function call segment.
15512 * btrace.h (brace_fun_p): New typedef.
15513 (struct btrace_thread_info) <functions>: New field.
15514
155152017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15516
15517 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
15518 * btrace.c (btrace_decode_error): ... here. New function.
15519 * btrace.h (btrace_decode_error): New export.
15520
155212017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15522
15523 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
15524 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
15525 btrace_find_insn_by_number): Remove special case for gaps.
15526 * btrace.h (btrace_insn_get_error): New export.
15527 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
15528 * record-btrace.c (btrace_insn_history): Print number for gaps.
15529 (record_btrace_info, record_btrace_goto): Handle gaps.
15530
3f77c769
TT
155312017-02-14 Tom Tromey <tom@tromey.com>
15532
15533 PR python/13598:
15534 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
15535 event.
15536 * python/py-evts.c (gdbpy_initialize_py_events): Add
15537 before_prompt registry.
15538 * python/py-events.h (events_object) <before_prompt>: New field.
15539
4c2c7ac6
MM
155402017-02-14 Markus Metzger <markus.t.metzger@intel.com>
15541
15542 * btrace.c (ftrace_new_switch): Preserve up link and flags.
15543
5cf30ebf
LM
155442017-02-13 Luis Machado <lgustavo@codesourcery.com>
15545
15546 * symfile (_initialize_symfile): Add usage text to the load command's
15547 help text.
15548
26a06916
SM
155492017-02-10 Simon Marchi <simon.marchi@ericsson.com>
15550
15551 * utils.c (defaulted_query): Don't query on secondary UIs.
15552
0b145e37
TT
155532017-02-10 Tom Tromey <tom@tromey.com>
15554
15555 * rust-lang.c (rust_get_disr_info): Remove unused variable.
15556
2d8365c4
TT
155572017-02-10 Tom Tromey <tom@tromey.com>
15558
15559 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
15560 "cleanup" local.
15561 * python/py-type.c (typy_legacy_template_argument): Remove
15562 unnecessary "cleanup" local.
15563
2bb8f231
TT
155642017-02-10 Tom Tromey <tom@tromey.com>
15565
15566 * python/python.c (do_start_initialization): New function, from
15567 _initialize_python.
15568 (_initialize_python): Call do_start_initialization.
15569 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
15570 goto.
15571
1bdfaf42
TT
155722017-02-10 Tom Tromey <tom@tromey.com>
15573
15574 * python/py-prettyprint.c (pretty_print_one_value): Use
15575 gdbpy_ref.
15576
88b6faea
TT
155772017-02-10 Tom Tromey <tom@tromey.com>
15578
15579 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
15580 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
15581 gdbpy_ref.
15582 * python/py-type.c (field_new): Use gdbpy_ref.
15583 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
15584 gdbpy_ref.
15585 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
15586 (py_free_pspace): Likewise.
15587 (pspace_to_pspace_object): Likewise.
15588 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
15589 (py_free_objfile): Likewise.
15590 (objfile_to_objfile_object): Likewise.
15591 * python/py-inferior.c (delete_thread_object): Use
15592 gdbpy_ref.
15593 (infpy_read_memory): Likewise.
15594 (py_free_inferior): Likewise.
15595 * python/py-evtregistry.c (create_eventregistry_object): Use
15596 gdbpy_ref.
15597 * python/py-event.c (create_event_object): Use gdbpy_ref.
15598
7780f186
TT
155992017-02-10 Tom Tromey <tom@tromey.com>
15600
15601 * python/py-ref.h (gdbpy_ref_policy): Now a template.
15602 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
15603 used.
15604 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
15605 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
15606 python/py-exitedevent.c, python/py-finishbreakpoint.c,
15607 python/py-framefilter.c, python/py-function.c,
15608 python/py-inferior.c, python/py-infevents.c,
15609 python/py-linetable.c, python/py-newobjfileevent.c,
15610 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
15611 python/py-signalevent.c, python/py-stopevent.c,
15612 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
15613 python/py-unwind.c, python/py-utils.c, python/py-value.c,
15614 python/py-varobj.c, python/py-xmethods.c, python/python.c,
15615 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
15616
d4b0bb18
TT
156172017-02-10 Tom Tromey <tom@tromey.com>
15618
15619 * ui-out.h (ui_out_emit_type): New class.
15620 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
15621 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
15622 and ui_out_emit_tuple.
15623 (enumerate_locals): Likewise.
15624 (py_mi_print_variables, py_print_locals, py_print_args): Use
15625 ui_out_emit_list.
15626 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
15627 ui_out_emit_list.
15628 * common/gdb_optional.h: New file.
15629
f67f945c
MG
156302017-02-10 Martin Galvan <martingalvan@sourceware.org>
15631
15632 * MAINTAINERS (Write After Approval): Update my e-mail address.
15633
18da0c51
MG
156342017-02-10 Martin Galvan <martingalvan@sourceware.org>
15635
15636 PR gdb/21122
15637 * breakpoint.c (_initialize_breakpoint): Update the help description
15638 of the 'commands' command to indicate that it takes a list argument.
15639
62c14536
SM
156402017-02-09 Simon Marchi <simon.marchi@ericsson.com>
15641
15642 * interps.c (current_interp_set_logging): Remove "return".
15643
ff6fa247
GB
156442017-02-09 Gary Benson <gbenson@redhat.com>
15645
15646 * symtab.c (add_symtab_completions): Prevent NULL pointer
15647 dereference.
15648
a474bd8e
PA
156492017-02-08 Pedro Alves <palves@redhat.com>
15650
15651 * interps.c (interp::interp): Remove reference to quiet_p.
15652 (interp_set): Make static. Remove dead "Switching to" output
15653 code.
15654 (interp_quiet_p, interp_set_quiet): Delete.
15655 (interpreter_exec_cmd): Don't set the interpreter quiet.
15656 * interps.h (interp_quiet_p): Make static.
15657 (class interp) <quiet_p>: Remove field
15658
3d7b173c
JG
156592017-02-08 Jerome Guitton <guitton@adacore.com>
15660
604c4576
JG
15661 * cli/cli-decode.c (find_command_name_length): Make it extern.
15662 * cli/cli-decode.h (find_command_name_length): Declare.
15663 * cli/cli-script.c (command_name_equals, line_first_arg):
15664 New functions.
15665 (process_next_line): Use cli-decode to parse command names.
15666 (build_command_line): Make args a constant pointer.
15667
156682017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 15669
3d7b173c
JG
15670 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
15671 Remove case-insensitive search.
15672
1291063d
JM
156732017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
15674
15675 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
15676 at the end of the line. Avoids an ARI warning.
15677
20b477a7
LM
156782017-02-06 Luis Machado <lgustavo@codesourcery.com>
15679
15680 * NEWS: Mention support for record/replay of Intel 64 rdrand and
15681 rdseed instructions.
15682 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
15683
3f7b46f2
IR
156842017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
15685
15686 PR tdep/20936
15687 Provide and use sparc32 and sparc64 target description XML files.
15688 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
15689 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
15690 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
15691 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
15692 * features/sparc/sparc32-solaris.xml: New file.
15693 * features/sparc/sparc64-solaris.xml: New file.
15694 * features/sparc/sparc32-solaris.c: Generated.
15695 * features/sparc/sparc64-solaris.c: Generated.
15696 * sparc-tdep.h: Account for differences in target descriptions.
15697 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
15698 (sparc32_register_type): Use target provided registers.
15699 (validate_tdesc_registers): New function.
15700 (sparc32_gdbarch_init): Use tdesc_has_registers.
15701 Set pseudoregister functions.
15702 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
15703 (sparc64_register_type): Use target provided registers.
15704 (sparc64_init_abi): Set pseudoregister functions.
15705
f0fd41c1
TT
157062017-02-03 Tom Tromey <tom@tromey.com>
15707
15708 PR rust/21097:
15709 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
15710 with a single member.
15711
d6f9b0fb
PA
157122017-02-03 Pedro Alves <palves@redhat.com>
15713
15714 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
15715 (cli_interp_base::~cli_interp_base): New.
15716 (cli_interp): New struct.
15717 (as_cli_interp): Cast the interp itself to cli_interp.
15718 (cli_interpreter_pre_command_loop): Rename to ...
15719 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
15720 parameter.
15721 (cli_interpreter_init): Rename to ...
15722 (cli_interp::init): ... this. Remove 'self' parameter. Use
15723 boolean. Make extern.
15724 (cli_interpreter_resume): Rename to ...
15725 (cli_interp::resume): ... this. Remove 'data' parameter. Make
15726 extern.
15727 (cli_interpreter_suspend): Rename to ...
15728 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
15729 extern.
15730 (cli_interpreter_exec): Rename to ...
15731 (cli_interp::exec): ... this. Remove 'data' parameter. Make
15732 extern.
15733 (cli_interpreter_supports_command_editing): Rename to ...
15734 (cli_interp_base::supports_command_editing): ... this. Remove
15735 'interp' parameter. Make extern.
15736 (cli_ui_out): Rename to ...
15737 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
15738 Make extern.
15739 (cli_set_logging): Rename to ...
15740 (cli_interp_base::set_logging): ... this. Remove 'interp'
15741 parameter. Make extern.
15742 (cli_interp_procs): Delete.
15743 (cli_interp_factory): Adjust to use "new".
15744 * cli/cli-interp.h: Include "interps.h".
15745 (struct cli_interp_base): New struct.
15746 * interps.c (struct interp): Delete. Fields moved to interps.h.
15747 (interp_new): Delete.
15748 (interp::interp, interp::~interp): New.
15749 (interp_set): Use bool, and return void. Assume the interpreter
15750 has suspend, init and resume methods, and that the all return
15751 void.
15752 (set_top_level_interpreter): interp_set returns void.
15753 (interp_ui_out): Adapt.
15754 (current_interp_set_logging): Adapt.
15755 (interp_data): Delete.
15756 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
15757 (interp_exec): Adapt.
15758 (top_level_interpreter_data): Delete.
15759 * interps.h (interp_init_ftype, interp_resume_ftype)
15760 (interp_suspend_ftype, interp_exec_ftype)
15761 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
15762 (class interp): New.
15763 (interp_new): Delete.
15764 (interp_set): Now returns void. Use bool.
15765 (interp_data, top_level_interpreter_data): Delete.
15766 * mi/mi-common.h: Include interps.h.
15767 (class mi_interp): Inherit from interp. Define a ctor. Declare
15768 init, resume, suspect, exec, interp_ui_out, set_logging and
15769 pre_command_loop methods.
15770 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
15771 (mi_interpreter_init): Rename to ...
15772 (mi_interp::init): ... this. Remove the 'interp' parameter, use
15773 bool, return void and make extern. Adjust.
15774 (mi_interpreter_resume): ... Rename to ...
15775 (mi_interp::resume): ... this. Remove the 'data' parameter,
15776 return void and make extern. Adjust.
15777 (mi_interpreter_suspend): ... Rename to ...
15778 (mi_interp::suspend): ... this. Remove the 'data' parameter,
15779 return void and make extern. Adjust.
15780 (mi_interpreter_exec): ... Rename to ...
15781 (mi_interp::exec): ... this. Remove the 'data' parameter and make
15782 extern. Adjust.
15783 (mi_interpreter_pre_command_loop): ... Rename to ...
15784 (mi_interp::pre_command_loop): ... this. Remove the 'self'
15785 parameter and make extern.
15786 (mi_on_normal_stop_1): Adjust.
15787 (mi_ui_out): Rename to ...
15788 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
15789 parameter and make extern. Adjust.
15790 (mi_set_logging): Rename to ...
15791 (mi_interp::set_logging): ... this. Remove the 'interp'
15792 parameter and make extern. Adjust.
15793 (mi_interp_procs): Delete.
15794 (mi_interp_factory): Adjust to use 'new'.
15795 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
15796 (mi_print_exception, mi_execute_command, mi_load_progress):
15797 Adjust.
15798 * tui/tui-interp.c (tui_interp): New class.
15799 (as_tui_interp): Return a tui_interp pointer.
15800 (tui_on_normal_stop, tui_on_signal_received)
15801 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
15802 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
15803 to use interp::interp_ui_out.
15804 (tui_init): Rename to ...
15805 (tui_interp::init): ... this. Remove the 'self' parameter, use
15806 bool, return void and make extern. Adjust.
15807 (tui_resume): Rename to ...
15808 (tui_interp::resume): ... this. Remove the 'data' parameter,
15809 return void and make extern. Adjust.
15810 (tui_suspend): Rename to ...
15811 (tui_interp::suspend): ... this. Remove the 'data' parameter,
15812 return void and make extern. Adjust.
15813 (tui_ui_out): Rename to ...
15814 (tui_interp::interp_ui_out): ... this. Remove the 'self'
15815 parameter, and make extern. Adjust.
15816 (tui_exec): Rename to ...
15817 (tui_interp::exec): ... this. Remove the 'data' parameter and
15818 make extern.
15819 (tui_interp_procs): Delete.
15820 (tui_interp_factory): Use "new".
15821
65c40c95
TT
158222017-02-02 Tom Tromey <tom@tromey.com>
15823
15824 * rust-exp.y (ends_raw_string, space_then_number)
15825 (rust_identifier_start_p): Return bool.
15826 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
15827 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
15828 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
15829 (rust_chartype_p): Return bool.
15830 (val_print_struct, rust_print_struct_def, rust_print_type):
15831 Update.
15832 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
15833 Return bool.
15834
b50f188d
TT
158352017-02-02 Tom Tromey <tom@tromey.com>
15836
15837 * rust-lang.c: Reindent.
15838
03c85b11
TT
158392017-02-02 Tom Tromey <tom@tromey.com>
15840
15841 * rust-lang.h (rust_crate_for_block): Update.
15842 * rust-lang.c (rust_crate_for_block): Return std::string.
15843 (rust_get_disr_info): Use std:;string, not
15844 gdb::unique_xmalloc_ptr.
15845 * rust-exp.y (crate_name): Update.
15846
9b6da501
PA
158472017-02-02 Pedro Alves <palves@redhat.com>
15848
15849 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
15850 field out of gdb_disassembler_test and make it static.
15851
ec4cb20b
PA
158522017-02-02 Pedro Alves <palves@redhat.com>
15853
15854 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
15855 mi1_interp and mi_interp fields.
15856
5be5dbf0
PA
158572017-02-02 Pedro Alves <palves@redhat.com>
15858
616268b6
PA
15859 * cli/cli-interp.c (struct saved_output_files, saved_output):
15860 Moved from cli/cli-logging.c.
15861 (cli_set_logging): New function.
15862 (cli_interp_procs): Install cli_set_logging.
15863 * cli/cli-interp.h (make_logging_output, cli_set_logging):
15864 Declare.
15865 * cli/cli-logging.c (struct saved_output_files, saved_output):
15866 Moved to cli/cli-interp.c.
15867 (pop_output_files): Don't save outputs here.
15868 (make_logging_output): New function.
15869 (handle_redirections): Don't build tee nor save previous outputs
15870 here.
15871 * interps.c (current_interp_set_logging): Change prototype.
15872 Assume there's always a set_logging_proc method installed.
15873 * interps.h (interp_set_logging_ftype): Change prototype.
15874 (current_interp_set_logging): Change prototype and adjust comment.
15875 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
15876 use make_logging_output.
15877 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
158782017-02-02 Pedro Alves <palves@redhat.com>
15879
5be5dbf0
PA
15880 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
15881 from ...
15882 (set_logging_overwrite): ... here.
15883 (logging_no_redirect_file): Delete.
15884 (set_logging_redirect): Don't handle redirection on the fly.
15885 Instead warn that "logging off" / "logging on" is necessary.
15886 (pop_output_files): Delete references to logging_no_redirect_file.
15887 (show_logging_command): Always speak in terms of what will happen
15888 once logging is reenabled.
15889
c99cc448
PA
158902017-02-02 Pedro Alves <palves@redhat.com>
15891
15892 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
15893
8b172ce7
PA
158942017-02-02 Pedro Alves <palves@redhat.com>
15895
15896 * disasm.c (gdb_pretty_print_insn): Rename to ...
15897 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
15898 Remove gdbarch parameter. Adapt to clear the object's buffers
15899 instead of allocating new buffers, and to print using the object's
15900 gdb_disassembler instead of calling gdb_print_insn.
15901 (dump_insns): Use gdb_pretty_print_disassembler.
15902 * disasm.h (gdb_pretty_print_insn): Delete declaration.
15903 (gdb_pretty_print_disassembler): New class.
15904 * record-btrace.c (btrace_insn_history): Use
15905 gdb_pretty_print_disassembler.
15906
d7e74731
PA
159072017-02-02 Pedro Alves <palves@redhat.com>
15908
15909 * ada-lang.c (type_as_string): Use string_file.
15910 * ada-valprint.c (ada_print_floating): Use string_file.
15911 * ada-varobj.c (ada_varobj_scalar_image)
15912 (ada_varobj_get_value_image): Use string_file.
15913 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
15914 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
15915 * breakpoint.c (update_inserted_breakpoint_locations)
15916 (insert_breakpoint_locations, reattach_breakpoints)
15917 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
15918 (print_it_watchpoint): Use string_file.
15919 (save_breakpoints): Use stdio_file.
15920 * c-exp.y (oper): Use string_file.
15921 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
15922 tee_file.
15923 (pop_output_files): Use delete.
15924 (handle_redirections): Use stdio_file and tee_file.
15925 * cli/cli-setshow.c (do_show_command): Use string_file.
15926 * compile/compile-c-support.c (c_compute_program): Use
15927 string_file.
15928 * compile/compile-c-symbols.c (generate_vla_size): Take a
15929 'string_file &' instead of a 'ui_file *'.
15930 (generate_c_for_for_one_variable): Take a 'string_file &' instead
15931 of a 'ui_file *'. Use string_file.
15932 (generate_c_for_variable_locations): Take a 'string_file &'
15933 instead of a 'ui_file *'.
15934 * compile/compile-internal.h (generate_c_for_for_one_variable):
15935 Take a 'string_file &' instead of a 'ui_file *'.
15936 * compile/compile-loc2c.c (push, pushf, unary, binary)
15937 (print_label, pushf_register_address, pushf_register)
15938 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
15939 'ui_file *'. Adjust.
15940 * compile/compile.c (compile_to_object): Use string_file.
15941 * compile/compile.h (compile_dwarf_expr_to_c)
15942 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
15943 'ui_file *'.
15944 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
15945 (replace_typedefs_qualified_name): Use string_file and
15946 obstack_copy0.
15947 * disasm.c (gdb_pretty_print_insn): Use string_file.
15948 (gdb_disassembly): Adjust reference the null_stream global.
15949 (do_ui_file_delete): Delete.
15950 (gdb_insn_length): Use null_stream.
15951 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
15952 * dwarf2loc.c (dwarf2_compile_property_to_c)
15953 (locexpr_generate_c_location, loclist_generate_c_location): Take a
15954 'string_file &' instead of a 'ui_file *'.
15955 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
15956 * dwarf2read.c (do_ui_file_peek_last): Delete.
15957 (dwarf2_compute_name): Use string_file.
15958 * event-top.c (gdb_setup_readline): Use stdio_file.
15959 * gdbarch.sh (verify_gdbarch): Use string_file.
15960 * gdbtypes.c (safe_parse_type): Use null_stream.
15961 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
15962 string_file.
15963 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
15964 'string_file *' instead of a 'ui_file *'.
15965 (gdbscm_arch_disassemble): Use string_file.
15966 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
15967 * guile/scm-ports.c (class ioscm_file_port): Now a class that
15968 inherits from ui_file.
15969 (ioscm_file_port_delete, ioscm_file_port_rewind)
15970 (ioscm_file_port_put): Delete.
15971 (ioscm_file_port_write): Rename to ...
15972 (ioscm_file_port::write): ... this. Remove file_port_magic
15973 checks.
15974 (ioscm_file_port_new): Delete.
15975 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
15976 ui_file_up.
15977 * guile/scm-type.c (tyscm_type_name): Use string_file.
15978 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
15979 Use string_file.
15980 * infcmd.c (print_return_value_1): Use string_file.
15981 * infrun.c (print_target_wait_results): Use string_file.
15982 * language.c (add_language): Use string_file.
15983 * location.c (explicit_to_string_internal): Use string_file.
15984 * main.c (captured_main_1): Use null_file.
15985 * maint.c (maintenance_print_architecture): Use stdio_file.
15986 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
15987 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
15988 event_channel>: Change type to mi_console_file pointer.
15989 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
15990 (mi_console_file_delete): Delete.
15991 (struct mi_console_file): Delete.
15992 (mi_console_file_magic): Delete.
15993 (mi_console_file_new): Delete.
15994 (mi_console_file::mi_console_file): New.
15995 (mi_console_file_delete): Delete.
15996 (mi_console_file_fputs): Delete.
15997 (mi_console_file::write): New.
15998 (mi_console_raw_packet): Delete.
15999 (mi_console_file::flush): New.
16000 (mi_console_file_flush): Delete.
16001 (mi_console_set_raw): Rename to ...
16002 (mi_console_file::set_raw): ... this.
16003 * mi/mi-console.h (class mi_console_file): New class.
16004 (mi_console_file_new, mi_console_set_raw): Delete.
16005 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
16006 (mi_set_logging): Use delete and tee_file. Adjust.
16007 * mi/mi-main.c (output_register): Use string_file.
16008 (mi_cmd_data_evaluate_expression): Use string_file.
16009 (mi_cmd_data_read_memory): Use string_file.
16010 (mi_cmd_execute, print_variable_or_computed): Use string_file.
16011 * mi/mi-out.c (mi_ui_out::main_stream): New.
16012 (mi_ui_out::rewind): Use main_stream and
16013 string_file.
16014 (mi_ui_out::put): Use main_stream and string_file.
16015 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
16016 Allocate a 'string_file' instead.
16017 (mi_out_new): Don't allocate a mem_fileopen stream here.
16018 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
16019 (mi_ui_out::main_stream): Declare method.
16020 * printcmd.c (eval_command): Use string_file.
16021 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
16022 * python/py-arch.c (archpy_disassemble): Use string_file.
16023 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
16024 * python/py-frame.c (frapy_str): Use string_file.
16025 * python/py-framefilter.c (py_print_type, py_print_single_arg):
16026 Use string_file.
16027 * python/py-type.c (typy_str): Use string_file.
16028 * python/py-unwind.c (unwind_infopy_str): Use string_file.
16029 * python/py-value.c (valpy_str): Use string_file.
16030 * record-btrace.c (btrace_insn_history): Use string_file.
16031 * regcache.c (regcache_print): Use stdio_file.
16032 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
16033 * remote.c (escape_buffer): Use string_file.
16034 * rust-lang.c (rust_get_disr_info): Use string_file.
16035 * serial.c (serial_open_ops_1): Use stdio_file.
16036 (do_serial_close): Use delete.
16037 * stack.c (print_frame_arg): Use string_file.
16038 (print_frame_args): Remove local mem_fileopen stream, not used.
16039 (print_frame): Use string_file.
16040 * symmisc.c (maintenance_print_symbols): Use stdio_file.
16041 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
16042 Take a 'string_file *' instead of a 'ui_file *'.
16043 * top.c (new_ui): Use stdio_file and stderr_file.
16044 (free_ui): Use delete.
16045 (execute_command_to_string): Use string_file.
16046 (quit_confirm): Use string_file.
16047 * tracepoint.c (collection_list::append_exp): Use string_file.
16048 * tui/tui-disasm.c (tui_disassemble): Use string_file.
16049 * tui/tui-file.c: Don't include "ui-file.h".
16050 (enum streamtype, struct tui_stream): Delete.
16051 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
16052 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
16053 (tui_file::tui_file): New method.
16054 (tui_file_fputs): Delete.
16055 (tui_file_get_strbuf): Delete.
16056 (tui_file::puts): New method.
16057 (tui_file_adjust_strbuf): Delete.
16058 (tui_file_flush): Delete.
16059 (tui_file::flush): New method.
16060 * tui/tui-file.h: Tweak intro comment.
16061 Include ui-file.h.
16062 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
16063 (tui_file_adjust_strbuf): Delete declarations.
16064 (class tui_file): New class.
16065 * tui/tui-io.c (tui_initialize_io): Use tui_file.
16066 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
16067 (tui_register_format): Use string_stream.
16068 * tui/tui-stack.c (tui_make_status_line): Use string_file.
16069 (tui_get_function_from_frame): Use string_file.
16070 * typeprint.c (type_to_string): Use string_file.
16071 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
16072 (null_stream): New global.
16073 (ui_file_delete): Delete.
16074 (ui_file::ui_file): New.
16075 (null_file_isatty): Delete.
16076 (ui_file::~ui_file): New.
16077 (null_file_rewind): Delete.
16078 (ui_file::printf): New.
16079 (null_file_put): Delete.
16080 (null_file_flush): Delete.
16081 (ui_file::putstr): New.
16082 (null_file_write): Delete.
16083 (ui_file::putstrn): New.
16084 (null_file_read): Delete.
16085 (ui_file::putc): New.
16086 (null_file_fputs): Delete.
16087 (null_file_write_async_safe): Delete.
16088 (ui_file::vprintf): New.
16089 (null_file_delete): Delete.
16090 (null_file::write): New.
16091 (null_file_fseek): Delete.
16092 (null_file::puts): New.
16093 (ui_file_data): Delete.
16094 (null_file::write_async_safe): New.
16095 (gdb_flush, ui_file_isatty): Adjust.
16096 (ui_file_put, ui_file_rewind): Delete.
16097 (ui_file_write): Adjust.
16098 (ui_file_write_for_put): Delete.
16099 (ui_file_write_async_safe, ui_file_read): Adjust.
16100 (ui_file_fseek): Delete.
16101 (fputs_unfiltered): Adjust.
16102 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
16103 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
16104 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
16105 (set_ui_file_data): Delete.
16106 (string_file::~string_file, string_file::write)
16107 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
16108 (do_ui_file_as_string, ui_file_as_string): Delete.
16109 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
16110 (struct mem_file): Delete.
16111 (mem_file_new): Delete.
16112 (stdio_file::stdio_file): New.
16113 (mem_file_delete): Delete.
16114 (stdio_file::stdio_file): New.
16115 (mem_fileopen): Delete.
16116 (stdio_file::~stdio_file): New.
16117 (mem_file_rewind): Delete.
16118 (stdio_file::set_stream): New.
16119 (mem_file_put): Delete.
16120 (stdio_file::open): New.
16121 (mem_file_write): Delete.
16122 (stdio_file_magic, struct stdio_file): Delete.
16123 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
16124 (stdio_file::flush): New.
16125 (stdio_file_read): Rename to ...
16126 (stdio_file::read): ... this. Adjust.
16127 (stdio_file_write): Rename to ...
16128 (stdio_file::write): ... this. Adjust.
16129 (stdio_file_write_async_safe): Rename to ...
16130 (stdio_file::write_async_safe) ... this. Adjust.
16131 (stdio_file_fputs): Rename to ...
16132 (stdio_file::puts) ... this. Adjust.
16133 (stdio_file_isatty): Delete.
16134 (stdio_file_fseek): Delete.
16135 (stdio_file::isatty): New.
16136 (stderr_file_write): Rename to ...
16137 (stderr_file::write) ... this. Adjust.
16138 (stderr_file_fputs): Rename to ...
16139 (stderr_file::puts) ... this. Adjust.
16140 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
16141 (stderr_file::stderr_file): New.
16142 (tee_file_magic): Delete.
16143 (struct tee_file): Delete.
16144 (tee_file::tee_file): New.
16145 (tee_file_new): Delete.
16146 (tee_file::~tee_file): New.
16147 (tee_file_delete): Delete.
16148 (tee_file_flush): Rename to ...
16149 (tee_file::flush): ... this. Adjust.
16150 (tee_file_write): Rename to ...
16151 (tee_file::write): ... this. Adjust.
16152 (tee_file::write_async_safe): New.
16153 (tee_file_fputs): Rename to ...
16154 (tee_file::puts): ... this. Adjust.
16155 (tee_file_isatty): Rename to ...
16156 (tee_file::isatty): ... this. Adjust.
16157 * ui-file.h (struct obstack, struct ui_file): Don't
16158 forward-declare.
16159 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
16160 (ui_file_write_ftype)
16161 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
16162 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
16163 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
16164 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
16165 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
16166 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
16167 (set_ui_file_fseek): Delete.
16168 (ui_file_data, ui_file_delete, ui_file_rewind)
16169 (struct ui_file): New.
16170 (ui_file_up): New.
16171 (class null_file): New.
16172 (null_stream): Declare.
16173 (ui_file_write_for_put, ui_file_put): Delete.
16174 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
16175 Delete.
16176 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
16177 (gdb_fopen, tee_file_new): Delete.
16178 (struct string_file): New.
16179 (struct stdio_file): New.
16180 (stdio_file_up): New.
16181 (struct stderr_file): New.
16182 (class tee_file): New.
16183 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
16184 of a 'ui_file *'. Adjust.
16185 * ui-out.h (class ui_out) <field_stream>: Likewise.
16186 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
16187 (null_stream): Delete.
16188 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
16189 Adjust.
16190 * utils.h (struct ui_file): Delete forward declaration..
16191 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
16192 (error_stream): Take a 'string_file &' instead of a
16193 'ui_file *'.
16194 * varobj.c (varobj_value_get_print_value): Use string_file.
16195 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
16196 * gdbarch.c: Regenerate.
16197
187808b0
PA
161982017-02-02 Pedro Alves <palves@redhat.com>
16199
16200 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
16201 (gdb_pretty_print_insn): ... this. Now a free function. Add back
16202 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
16203 Adjust to call gdb_print_insn instead of
16204 gdb_disassembler::print_insn.
16205 (dump_insns, do_mixed_source_and_assembly_deprecated)
16206 (do_mixed_source_and_assembly, do_assembly_only): Add back a
16207 'gdbarch' parameter. Remove gdb_disassembler parameter.
16208 (gdb_disassembly): Don't allocate a gdb_disassembler here.
16209 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
16210 declaration.
16211 (gdb_pretty_print_insn): Re-add declaration.
16212 * record-btrace.c (btrace_insn_history): Don't allocate a
16213 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
16214
7a8eb317
SM
162152017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
16216
16217 * disasm.h (gdb_disassembly): Remove file_string parameter.
16218 * disasm.c (gdb_disassembly): Likewise.
16219 * cli/cli-cmds.c (print_disassembly): Adapt.
16220 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
16221 * stack.c (do_gdb_disassembly): Likewise.
16222
7346ef59
AA
162232017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
16224
16225 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
16226 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
16227 targets. And if the implicit value is longer than needed, extract
16228 the first bytes instead of the "least significant" ones.
16229
cd4007e4
MM
162302017-02-01 Markus Metzger <markus.t.metzger@intel.com>
16231
16232 * btrace.c (btrace_enable): Do not call btrace_add_pc for
16233 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
16234 (btrace_fetch): Assert can_access_registers_ptid.
16235 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
16236 validate_registers_access.
16237
cf77c34e
MM
162382017-02-01 Markus Metzger <markus.t.metzger@intel.com>
16239
16240 * gdbthread.h (can_access_registers_ptid): New.
16241 * thread.c (can_access_registers_ptid): New.
16242
be85ce7d
PA
162432017-02-01 Pedro Alves <palves@redhat.com>
16244
16245 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
16246
29b0b251
PA
162472017-01-31 Pedro Alves <palves@redhat.com>
16248
16249 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
16250 Fix typos.
16251
289b5b24
PA
162522017-01-31 Pedro Alves <palves@redhat.com>
16253
16254 * stack.c (print_frame_args): Remove local mem_fileopen stream,
16255 not used.
16256
b47413b4
PA
162572017-01-31 Pedro Alves <palves@redhat.com>
16258
16259 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
16260
60adb36c
PA
162612017-01-31 Pedro Alves <palves@redhat.com>
16262
16263 * common/scoped_restore.h
16264 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
16265 change the value's parameter type to T2.
16266 (make_scoped_restore): Likewise.
16267
2735833d
WT
162682017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16269 Richard Henderson <rth@redhat.com>
16270
16271 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
16272 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
16273 GS_BASE for older kernels.
16274 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
16275 GS_BASE for older kernels.
16276 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
16277 and GS_BASE to the offset table.
16278 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
16279 system register group.
16280 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
16281 for older kernels.
16282 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
16283 amd64 ABI.
16284 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
16285 AMD64_GSBASE_REGNUM.
16286 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
16287 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
16288 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
16289 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
16290 i386/64bit-segments.xml in those rules.
16291 * features/i386/64bit-segments.xml: New file.
16292 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
16293 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
16294 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
16295 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
16296 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
16297 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
16298 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
16299 * features/i386/amd64-avx-linux.c: Regenerated.
16300 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
16301 * features/i386/amd64-avx-mpx.c: Regenerated.
16302 * features/i386/amd64-avx512-linux.c: Regenerated.
16303 * features/i386/amd64-linux.c: Regenerated.
16304 * features/i386/amd64-mpx-linux.c: Regenerated.
16305 * features/i386/i386-avx-mpx-linux.c: Regenerated.
16306 * features/i386/i386-avx-mpx.c: Regenerated.
16307 * features/i386/x32-avx-linux.c: Regenerated.
16308 * features/i386/x32-avx512-linux.c: Regenerated.
16309 * regformats/i386/amd64-avx-linux.dat: Regenerated.
16310 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
16311 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
16312 * regformats/i386/amd64-linux.dat: Regenerated.
16313 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
16314 * regformats/i386/x32-avx-linux.dat: Regenerated.
16315 * regformats/i386/x32-avx512-linux.dat: Regenerated.
16316 * regformats/i386/x32-linux.dat: Regenerated.
16317
8884e97e
WT
163182017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16319
16320 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
16321 Set to AMD64_NUM_REGS.
16322
7005d26a
WT
163232017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16324
16325 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
16326 that checks validity of a register number.
16327
4bd2e1b2
KC
163282017-01-27 Kees Cook <keescook@google.com>
16329
16330 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
16331 fetch_fpregs if target has fpa registers.
16332 (arm_linux_store_inferior_registers): Call store_fpregs if target
16333 has fpa registers.
16334
7cf1de6c
AA
163352017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
16336
16337 * cris-tdep.c (cris_gdbarch_init): Remove check for
16338 info.byte_order and force it to BFD_ENDIAN_LITTLE.
16339
874a1c8c
AT
163402017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
16341
16342 * corelow.c (get_core_register_section): Check for regset
16343 existence before checking for REGSET_VARIABLE_SIZE.
16344
d8b49cf0
YQ
163452017-01-26 Yao Qi <yao.qi@linaro.org>
16346 Pedro Alves <palves@redhat.com>
16347
16348 PR gdb/20939
16349 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
16350 call memory_error, save memaddr instead.
16351 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
16352 negative, cal memory_error.
16353 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
16354
658ca58c
YQ
163552017-01-26 Yao Qi <yao.qi@linaro.org>
16356
16357 * disasm-selftests.c (memory_error_test): New function.
16358 (_initialize_disasm_selftests): Register memory_error_test.
16359
79843d45
YQ
163602017-01-26 Yao Qi <yao.qi@linaro.org>
16361
16362 * Makefile.in (SFILES): Add disasm-selftests.c and
16363 selftest-arch.c.
16364 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
16365 * disasm-selftests.c: New file.
16366 * selftest-arch.c: New file.
16367 * selftest-arch.h: New file.
16368
8cafda32
YQ
163692017-01-26 Yao Qi <yao.qi@linaro.org>
16370
16371 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
16372 to bfd_arch_mep. Don't return 0 if section is not
16373 found. Call print_insn_mep.
16374
e47ad6c0
YQ
163752017-01-26 Pedro Alves <palves@redhat.com>
16376 Yao Qi <yao.qi@linaro.org>
16377
16378 * arm-tdep.c: Include "disasm.h".
16379 (gdb_print_insn_arm): Update code to get gdbarch.
16380 * disasm.c (dis_asm_read_memory): Change it to
16381 gdb_disassembler::dis_asm_read_memory.
16382 (dis_asm_memory_error): Likewise.
16383 (dis_asm_print_address): Likewise.
16384 (gdb_pretty_print_insn): Change it to
16385 gdb_disassembler::pretty_print_insn.
16386 (dump_insns): Add one argument gdb_disassemlber. All
16387 callers updated.
16388 (do_mixed_source_and_assembly_deprecated): Likewise.
16389 (do_mixed_source_and_assembly): Likewise.
16390 (do_assembly_only): Likewise.
16391 (gdb_disassembler::gdb_disassembler): New.
16392 (gdb_disassembler::print_insn): New.
16393 * disasm.h (class gdb_disassembler): New.
16394 (gdb_pretty_print_insn): Remove declaration.
16395 (gdb_disassemble_info): Likewise.
16396 * guile/scm-disasm.c (class gdbscm_disassembler): New.
16397 (gdbscm_disasm_read_memory_worker): Update.
16398 (gdbscm_disasm_read_memory): Update.
16399 (gdbscm_disasm_memory_error): Remove.
16400 (gdbscm_disasm_print_address): Remove.
16401 (gdbscm_disassembler::gdbscm_disassembler): New.
16402 (gdbscm_print_insn_from_port): Update.
16403 * mips-tdep.c: Include disasm.h.
16404 (gdb_print_insn_mips): Update code to get gdbarch.
16405 * record-btrace.c (btrace_insn_history): Update.
16406 * spu-tdep.c: Include disasm.h.
16407 (struct spu_dis_asm_data): Remove.
16408 (struct spu_dis_asm_info): New.
16409 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
16410 SPU id.
16411 (gdb_print_insn_spu): Cast disassemble_info to
16412 spu_dis_asm_info.
16413
80d75874
YQ
164142017-01-26 Yao Qi <yao.qi@linaro.org>
16415
16416 * disasm.c (do_ui_file_delete): Delete.
16417 (gdb_insn_length): Move code creating stream to ...
16418 * utils.c (null_stream): ... here. New function.
16419 * utils.h (null_stream): Declare.
16420
60685cd0
SM
164212017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
16422
16423 * python/py-inferior.c (find_thread_object): Return directly
16424 from the loop. Remove "found" variable.
16425
eb1cdb62
JB
164262017-01-21 Joel Brobecker <brobecker@adacore.com>
16427
16428 GDB 7.12.1 released.
16429
b1ce6568
SM
164302017-01-20 Simon Marchi <simon.marchi@ericsson.com>
16431
16432 * python/py-function.c (fnpy_call): Reorder declarations to have
16433 the gdbpy_enter object declared first.
16434 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
16435
6f8b0407
SM
164362017-01-20 Simon Marchi <simon.marchi@ericsson.com>
16437
fec93fb1 16438 PR python/21068
6f8b0407
SM
16439 * python/python-internal.h (PyMem_RawMalloc): Define for
16440 Python < 3.4.
16441 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
16442 PyMem_RawMalloc instead of PyMem_Malloc.
16443
78cbbba8
LM
164442017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
16445 Luis Machado <lgustavo@codesourcery.com>
16446
16447 * NEWS (New commands): Mention flash-erase.
16448 (New MI commands): Mention target-flash-erase.
16449 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
16450 command.
16451 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
16452 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
16453 * target.c (flash_erase_command): New function.
16454 (initialize_targets): Add new flash-erase command.
16455 * target.h (flash_erase_command): New declaration.
16456
2132fe85
JB
164572017-01-20 Joel Brobecker <brobecker@adacore.com>
16458
16459 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
16460 HAVE_SYS_PROCFS_H is defined.
16461
d1dff226
AH
164622017-01-18 Alan Hayward <alan.hayward@arm.com>
16463
16464 * remote.c (struct cached_reg): Change data into a pointer.
16465 * (stop_reply_dtr): Free data pointers before deleting vector.
16466 (process_stop_reply): Likewise.
16467 (remote_parse_stop_reply): Allocate space for data
16468
9890e433
AH
164692017-01-18 Alan Hayward <alan.hayward@arm.com>
16470
16471 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
16472 MAX_REGISTER_SIZE.
16473 (amd64_pseudo_register_read_value): Likewise.
16474 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
16475 (store_register_using_P): Likewise.
16476 * regcache.c (regcache_xfer_part): Likewise.
16477
7a36499a
IR
164782017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
16479
16480 Split real and pseudo registers.
16481 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
16482 (sparc32_pseudo_regnum): New enum.
16483 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
16484 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
16485 (SPARC32_CP0_REGISTERS): New macro.
16486 (sparc32_pseudo_register_name): New function.
16487 (sparc32_register_name): Use sparc32_pseudo_register_name.
16488 (sparc32_pseudo_register_type): New function.
16489 (sparc32_register_type): Use sparc32_pseudo_register_type.
16490 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
16491 pseudo register numbers.
16492 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
16493 (SPARC64_CP0_REGISTERS): New macro.
16494 (sparc64_pseudo_register_name): New function.
16495 (sparc64_register_name): Use sparc64_pseudo_register_name.
16496 (sparc64_pseudo_register_type): New function.
16497 (sparc64_register_type): Use sparc64_pseudo_register_type.
16498 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
16499 pseudo register numbers.
16500 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
16501 sparc64_store_arguments): Handle pseudo register numbers.
16502
6f8976bf
YQ
165032017-01-13 Yao Qi <yao.qi@linaro.org>
16504
16505 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
16506 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
16507 output.
16508 (getpkt_or_notif_sane_1): Likewise.
16509
e4241ace
YQ
165102017-01-13 Yao Qi <yao.qi@linaro.org>
16511
16512 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
16513 of CC. Pass "-x c++-header" instead of "-x c".
16514
3015c064
SM
165152017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16516
16517 * remote.c (remote_can_async_p): Update comment.
16518
fde1b17d
SM
165192017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16520
16521 * linux-nat.c (linux_nat_can_async_p): Update comment.
16522
ca1ca08b
SM
165232017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16524
16525 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
16526
4ad2da73
SM
165272017-01-11 Simon Marchi <simon.marchi@ericsson.com>
16528
16529 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
16530
c8b23b3f
TT
165312017-01-10 Tom Tromey <tom@tromey.com>
16532
16533 * python/py-type.c (typy_legacy_template_argument): Update.
16534 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
16535 ~demangle_parse_info): Declare new members.
16536 (cp_demangled_name_to_comp): Return unique_ptr.
16537 (cp_demangled_name_parse_free)
16538 (make_cleanup_cp_demangled_name_parse_free)
16539 (cp_new_demangle_parse_info): Remove.
16540 * cp-support.c (do_demangled_name_parse_free_cleanup)
16541 (make_cleanup_cp_demangled_name_parse_free): Remove.
16542 (inspect_type, cp_canonicalize_string_full)
16543 (cp_canonicalize_string): Update.
16544 (mangled_name_to_comp): Change return type.
16545 (cp_class_name_from_physname, method_name_from_physname)
16546 (cp_func_name, cp_remove_params): Update.
16547 * cp-name-parser.y (demangle_parse_info): New constructor, from
16548 cp_new_demangle_parse_info.
16549 (~demangle_parse_info): New destructor, from
16550 cp_demangled_name_parse_free.
16551 (cp_merge_demangle_parse_infos): Update.
16552 (cp_demangled_name_to_comp): Change return type.
16553
1ac32117
TT
165542017-01-10 Tom Tromey <tom@tromey.com>
16555
16556 * top.c (prevent_dont_repeat): Change return type.
16557 * python/python.c (execute_gdb_command): Use std::string.
16558 Update.
16559 * guile/guile.c (gdbscm_execute_gdb_command): Update.
16560 * command.h (prevent_dont_repeat): Change return type.
16561 * breakpoint.c (bpstat_do_actions_1): Update.
16562
0cf08227
TT
165632017-01-10 Tom Tromey <tom@tromey.com>
16564
16565 * value.h (scoped_value_mark::~scoped_value_mark): Call
16566 free_to_mark.
16567 (scoped_value_mark::free_to_mark): New method.
16568 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
16569 scoped_value_mark.
16570
eb115069
TT
165712017-01-10 Tom Tromey <tom@tromey.com>
16572
16573 * python/py-value.c (valpy_dereference, valpy_referenced_value)
16574 (valpy_reference_value, valpy_const_value, valpy_get_address)
16575 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
16576 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
16577 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
16578 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
16579 scoped_value_mark.
16580 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
16581 * value.h (scoped_value_mark): New class.
16582
906768f9
TT
165832017-01-10 Tom Tromey <tom@tromey.com>
16584
16585 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
16586 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
16587 * psymtab.c (discard_psymtabs_upto): Remove.
16588 (make_cleanup_discard_psymtabs): Remove.
16589 (struct psymtab_state): Remove.
16590
bef155c3
TT
165912017-01-10 Tom Tromey <tom@tromey.com>
16592
16593 * record-full.c (record_full_save_cleanups): Remove.
16594 (record_full_save): Use gdb::unlinker.
16595 * gcore.c (do_bfd_delete_cleanup): Remove.
16596 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
16597 cleanups.
16598 * dwarf2read.c (unlink_if_set): Remove.
16599 (write_psymtabs_to_index): Use gdb::unlinker.
16600 * common/gdb_unlinker.h: New file.
16601
192b62ce
TT
166022017-01-10 Tom Tromey <tom@tromey.com>
16603
16604 * windows-tdep.c (windows_xfer_shared_library): Update.
16605 * windows-nat.c (windows_make_so): Update.
16606 * utils.h (make_cleanup_bfd_unref): Remove.
16607 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
16608 * symfile.h (symfile_bfd_open)
16609 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
16610 * symfile.c (read_symbols, symbol_file_add)
16611 (separate_debug_file_exists): Update.
16612 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
16613 (generic_load, reread_symbols): Update.
16614 * symfile-mem.c (symbol_file_add_from_memory): Update.
16615 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
16616 (spu_symbol_file_add_from_memory): Update.
16617 * solist.h (struct target_so_ops) <bfd_open>: Return
16618 gdb_bfd_ref_ptr.
16619 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
16620 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
16621 gdb_bfd_ref_ptr.
16622 (solib_map_sections, reload_shared_libraries_1): Update.
16623 * solib-svr4.c (enable_break): Update.
16624 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
16625 * solib-frv.c (enable_break2): Update.
16626 * solib-dsbt.c (enable_break): Update.
16627 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
16628 gdb_bfd_ref_ptr.
16629 (darwin_solib_get_all_image_info_addr_at_init): Update.
16630 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
16631 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
16632 * record-full.c (record_full_save): Update.
16633 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
16634 * procfs.c (insert_dbx_link_bpt_in_file): Update.
16635 * minidebug.c (find_separate_debug_file_in_section): Return
16636 gdb_bfd_ref_ptr.
16637 * machoread.c (macho_add_oso_symfile): Change abfd to
16638 gdb_bfd_ref_ptr.
16639 (macho_symfile_read_all_oso): Update.
16640 (macho_check_dsym): Return gdb_bfd_ref_ptr.
16641 (macho_symfile_read): Update.
16642 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
16643 (jit_bfd_try_read_symtab): Update.
16644 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
16645 (gdb_bfd_openw, gdb_bfd_openr_iovec)
16646 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
16647 gdb_bfd_ref_ptr.
16648 (gdb_bfd_ref_policy): New struct.
16649 (gdb_bfd_ref_ptr): New typedef.
16650 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
16651 (gdb_bfd_openw, gdb_bfd_openr_iovec)
16652 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
16653 gdb_bfd_ref_ptr.
16654 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
16655 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
16656 (gcore_command): Update.
16657 * exec.c (exec_file_attach): Update.
16658 * elfread.c (elf_symfile_read): Update.
16659 * dwarf2read.c (dwarf2_get_dwz_file): Update.
16660 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
16661 (open_and_init_dwo_file): Update.
16662 (open_dwp_file): Return gdb_bfd_ref_ptr.
16663 (open_and_init_dwp_file): Update.
16664 * corelow.c (core_open): Update.
16665 * compile/compile-object-load.c (compile_object_load): Update.
16666 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
16667 * coffread.c (coff_symfile_read): Update.
16668 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
16669 gdb_bfd_ref_ptr. Rename.
16670 (dump_bfd_file, restore_command): Update.
16671 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
16672 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
16673 (find_separate_debug_file_by_buildid): Update.
16674
50315b21
TT
166752017-01-10 Tom Tromey <tom@tromey.com>
16676
16677 * common/gdb_ref_ptr.h: New file.
16678 * python/py-ref.h (struct gdbpy_ref_policy): New.
16679 (gdbpy_ref): Now a typedef.
16680
fc4007c9
TT
166812017-01-10 Tom Tromey <tom@tromey.com>
16682
16683 * utils.h (make_cleanup_htab_delete): Don't declare.
16684 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
16685 Remove.
16686 * linespec.c (decode_compound_collector): Add constructor,
16687 destructor.
16688 (lookup_prefix_sym): Remove cleanup.
16689 (symtab_collector): Add constructor, destructor.
16690 (collect_symtabs_from_filename): Remove cleanup.
16691 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
16692 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
16693 Use htab_up.
16694 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
16695 * dwarf2read.c (dw2_expand_symtabs_matching)
16696 (dw2_map_symbol_filenames, dwarf_decode_macros)
16697 (write_psymtabs_to_index): Use htab_up.
16698 * dwarf2loc.c (func_verify_no_selftailcall)
16699 (call_site_find_chain_1, func_verify_no_selftailcall)
16700 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
16701 std::vector, gdb::unique_xmalloc_ptr.
16702 (call_sitep): Remove typedef.
16703 (dwarf2_locexpr_baton_eval): Remove unused variable.
16704
8dbcee67
TT
167052017-01-10 Tom Tromey <tom@tromey.com>
16706
16707 * python/python-internal.h (make_cleanup_py_decref)
16708 (make_cleanup_py_xdecref): Don't declare.
16709 * python/py-utils.c (py_decref, make_cleanup_py_decref)
16710 (py_xdecref, make_cleanup_py_xdecref): Remove.
16711
13df46cc
TT
167122017-01-10 Tom Tromey <tom@tromey.com>
16713
16714 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
16715 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
16716
06fc9bf7
TT
167172017-01-10 Tom Tromey <tom@tromey.com>
16718
16719 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
16720
830a4934
TT
167212017-01-10 Tom Tromey <tom@tromey.com>
16722
16723 * python/py-utils.c (unicode_to_encoded_string)
16724 (python_string_to_target_string)
16725 (python_string_to_target_python_string)
16726 (python_string_to_host_string, gdbpy_obj_to_string)
16727 (get_addr_from_python): Use gdbpy_ref.
16728
4586d543
TT
167292017-01-10 Tom Tromey <tom@tromey.com>
16730
16731 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
16732 gdbpy_ref.
16733
59876f8f
TT
167342017-01-10 Tom Tromey <tom@tromey.com>
16735
16736 * python/python.c (eval_python_command, gdbpy_decode_line)
16737 (gdbpy_run_events, gdbpy_start_type_printers)
16738 (gdbpy_apply_type_printers): Use gdbpy_ref.
16739
97d83487
TT
167402017-01-10 Tom Tromey <tom@tromey.com>
16741
16742 * python/py-param.c (get_doc_string, compute_enum_values): Use
16743 gdbpy_ref.
16744
9205649a
TT
167452017-01-10 Tom Tromey <tom@tromey.com>
16746
16747 * python/py-inferior.c (find_thread_object, build_inferior_list):
16748 Use gdbpy_ref.
16749
74c49d45
TT
167502017-01-10 Tom Tromey <tom@tromey.com>
16751
16752 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
16753
16361ffb
TT
167542017-01-10 Tom Tromey <tom@tromey.com>
16755
16756 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
16757 gdbpy_ref.
16758
905f2cca
TT
167592017-01-10 Tom Tromey <tom@tromey.com>
16760
16761 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
16762 extra incref.
16763 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
16764 Use gdbpy_ref.
16765
64081434
TT
167662017-01-10 Tom Tromey <tom@tromey.com>
16767
16768 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
16769 gdbpy_ref.
16770
59e9e831
TT
167712017-01-10 Tom Tromey <tom@tromey.com>
16772
16773 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
16774 decref results of PyArg_ParseTupleAndKeywords.
16775
9de10f6d
TT
167762017-01-10 Tom Tromey <tom@tromey.com>
16777
16778 * python/python.c (python_run_simple_file): Use
16779 unique_xmalloc_ptr, gdbpy_ref.
16780
2bd5759d
TT
167812017-01-10 Tom Tromey <tom@tromey.com>
16782
16783 * python/py-prettyprint.c (print_stack_unless_memory_error)
16784 (print_string_repr, print_children): Use gdbpy_ref.
16785 (dummy_python_frame): New class.
16786 (dummy_python_frame::dummy_python_frame): Rename from
16787 push_dummy_python_frame.
16788 (py_restore_tstate): Remove.
16789
3b4e0e01
TT
167902017-01-10 Tom Tromey <tom@tromey.com>
16791
16792 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
16793
17a22718
TT
167942017-01-10 Tom Tromey <tom@tromey.com>
16795
16796 * python/python.c (ensure_python_env, restore_python_env):
16797 Remove.
16798 * python/python-internal.h (ensure_python_env): Don't declare.
16799 * varobj.h (varobj_ensure_python_env): Don't declare.
16800 * varobj.c (varobj_ensure_python_env): Remove.
16801
68cdc557
TT
168022017-01-10 Tom Tromey <tom@tromey.com>
16803
16804 * varobj.c (varobj_value_get_print_value): Use
16805 gdbpy_enter_varobj.
16806
1eba6383
TT
168072017-01-10 Tom Tromey <tom@tromey.com>
16808
16809 * python/py-prettyprint.c (print_string_repr, print_children):
16810 Update.
16811 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
16812 of "encoding".
16813 * varobj.c (varobj_value_get_print_value): Update.
16814 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
16815
bde7b3e3
TT
168162017-01-10 Tom Tromey <tom@tromey.com>
16817
16818 * varobj.c (varobj_get_display_hint)
16819 (dynamic_varobj_has_child_method, install_new_value_visualizer)
16820 (varobj_set_visualizer, free_variable): Use
16821 gdbpy_enter_varobj.
16822
a7785f8c
TT
168232017-01-10 Tom Tromey <tom@tromey.com>
16824
16825 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
16826 (do_finish_initialization): New function. Use gdbpy_ref.
16827 (gdbpy_finish_initialization): Use gdbpy_enter. Call
16828 do_finish_initialization.
16829
2865bfce
TT
168302017-01-10 Tom Tromey <tom@tromey.com>
16831
16832 * python/py-param.c (get_set_value, get_show_value): Use
16833 gdbpy_enter, gdbpy_ref.
16834
0e9dcc75
TT
168352017-01-10 Tom Tromey <tom@tromey.com>
16836
16837 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
16838
12a5cedd
TT
168392017-01-10 Tom Tromey <tom@tromey.com>
16840
16841 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
16842
788f2586
TT
168432017-01-10 Tom Tromey <tom@tromey.com>
16844
16845 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
16846 Use gdbpy_enter_varobj.
16847
6cd67bea
TT
168482017-01-10 Tom Tromey <tom@tromey.com>
16849
16850 * varobj.c (gdbpy_enter_varobj): New constructor.
16851 * python/python-internal.h (gdbpy_enter_varobj): New class.
16852 * python/py-varobj.c (py_varobj_get_iterator): Use
16853 gdbpy_enter_varobj.
16854
14b122bf
TT
168552017-01-10 Tom Tromey <tom@tromey.com>
16856
16857 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
16858 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
16859 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
16860 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
16861 unique_xmalloc_ptr.
16862 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
16863
bf1ca3b9
TT
168642017-01-10 Tom Tromey <tom@tromey.com>
16865
16866 * python/py-xmethods.c (invoke_match_method): Use
16867 gdbpy_ref.
16868
572a5524
TT
168692017-01-10 Tom Tromey <tom@tromey.com>
16870
16871 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
16872 gdbpy_enter, gdbpy_ref.
16873
396a78b6
TT
168742017-01-10 Tom Tromey <tom@tromey.com>
16875
16876 * python/python.c (python_interactive_command): Use gdbpy_enter.
16877
a88b13c7
TT
168782017-01-10 Tom Tromey <tom@tromey.com>
16879
16880 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
16881 gdbpy_ref.
16882
e9f0c363
TT
168832017-01-10 Tom Tromey <tom@tromey.com>
16884
16885 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
16886 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
16887
6349f452
TT
168882017-01-10 Tom Tromey <tom@tromey.com>
16889
16890 * utils.h (htab_deleter): New struct.
16891 (htab_up): New typedef.
16892 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
16893 gdbpy_enter, gdbpy_ref, htab_up.
16894
c0171de6
TT
168952017-01-10 Tom Tromey <tom@tromey.com>
16896
16897 * python/py-unwind.c (pending_frame_invalidate): Remove.
16898 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
16899
f18e226f
TT
169002017-01-10 Tom Tromey <tom@tromey.com>
16901
16902 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
16903 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
16904
c57af3f1
TT
169052017-01-10 Tom Tromey <tom@tromey.com>
16906
16907 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
16908
60e600ec
TT
169092017-01-10 Tom Tromey <tom@tromey.com>
16910
16911 * python/python.c (gdbpy_eval_from_control_command)
16912 (gdbpy_source_script, gdbpy_run_events)
16913 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
16914 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
16915 gdbpy_enter.
16916
bf7da5b0
TT
169172017-01-10 Tom Tromey <tom@tromey.com>
16918
16919 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
16920
2d38bced
TT
169212017-01-10 Tom Tromey <tom@tromey.com>
16922
16923 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
16924
07bc7329
TT
169252017-01-10 Tom Tromey <tom@tromey.com>
16926
16927 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
16928 (python_on_inferior_call_pre, python_on_inferior_call_post)
16929 (python_on_memory_change, python_on_register_change)
16930 (python_inferior_exit, python_new_objfile, add_thread_object)
16931 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
16932
6e7c365e
TT
169332017-01-10 Tom Tromey <tom@tromey.com>
16934
16935 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
16936 (bpfinishpy_handle_exit): Use gdbpy_enter.
16937
6ba0cd40
TT
169382017-01-10 Tom Tromey <tom@tromey.com>
16939
16940 * python/py-cmd.c (cmdpy_destroyer)
16941 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
16942 gdbpy_enter.
16943
de2dc875
TT
169442017-01-10 Tom Tromey <tom@tromey.com>
16945
16946 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
16947 gdbpy_enter.
16948 (gdbpy_breakpoint_has_cond): Likewise.
16949
4ecee2c4
TT
169502017-01-10 Tom Tromey <tom@tromey.com>
16951
16952 * python/python.c (gdbpy_enter): New constructor.
16953 (~gdbpy_enter): New destructor.
16954 (restore_python_env, ensure_python_env): Rewrite.
16955 * python/python-internal.h (gdbpy_enter): New class.
16956
37fce74f
TT
169572017-01-10 Tom Tromey <tom@tromey.com>
16958
16959 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
16960
53a0cca3
TT
169612017-01-10 Tom Tromey <tom@tromey.com>
16962
16963 * python/py-value.c (value_has_field, get_field_flag)
16964 (get_field_type, valpy_getitem, convert_value_from_python): Use
16965 gdbpy_ref.
16966
ff3724f5
TT
169672017-01-10 Tom Tromey <tom@tromey.com>
16968
16969 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
16970 gdbpy_ref.
16971
0700aea5
TT
169722017-01-10 Tom Tromey <tom@tromey.com>
16973
16974 * python/py-prettyprint.c (search_pp_list)
16975 (find_pretty_printer_from_objfiles)
16976 (find_pretty_printer_from_progspace)
16977 (find_pretty_printer_from_gdb, find_pretty_printer)
16978 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
16979 gdbpy_ref.
16980
1bb44c9f
TT
169812017-01-10 Tom Tromey <tom@tromey.com>
16982
16983 * python/py-param.c (call_doc_function): Use gdbpy_ref.
16984
87ce03fd
TT
169852017-01-10 Tom Tromey <tom@tromey.com>
16986
16987 * python/py-linetable.c (build_line_table_tuple_from_pcs)
16988 (ltpy_get_all_source_lines): Use gdbpy_ref.
16989
ee0a3fb8
TT
169902017-01-10 Tom Tromey <tom@tromey.com>
16991
16992 * python/py-framefilter.c (extract_sym, extract_value)
16993 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
16994 gdbpy_ref.
16995
bf2a52fa
TT
169962017-01-10 Tom Tromey <tom@tromey.com>
16997
16998 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
16999
f59fe7f8
TT
170002017-01-10 Tom Tromey <tom@tromey.com>
17001
17002 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
17003
80bd970a
TT
170042017-01-10 Tom Tromey <tom@tromey.com>
17005
17006 * python/py-function.c (convert_values_to_python, fnpy_init): Use
17007 gdbpy_ref.
17008
d1b3de2e
TT
170092017-01-10 Tom Tromey <tom@tromey.com>
17010
17011 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
17012
3bb43384
TT
170132017-01-10 Tom Tromey <tom@tromey.com>
17014
17015 * python/py-type.c (convert_field, make_fielditem, typy_fields)
17016 (typy_range): Use gdbpy_ref.
17017
abf5651e
TT
170182017-01-10 Tom Tromey <tom@tromey.com>
17019
17020 * python/py-threadevent.c (create_thread_event_object): Use
17021 gdbpy_ref.
17022 * python/py-stopevent.c (create_stop_event_object): Simplify.
17023 (emit_stop_event): Use gdbpy_ref.
17024 * python/py-signalevent.c (create_signal_event_object): Use
17025 gdbpy_ref.
17026 * python/py-newobjfileevent.c (create_new_objfile_event_object)
17027 (emit_new_objfile_event, create_clear_objfiles_event_object)
17028 (emit_clear_objfiles_event): Use gdbpy_ref.
17029 * python/py-infevents.c (create_inferior_call_event_object)
17030 (create_register_changed_event_object)
17031 (create_memory_changed_event_object, emit_inferior_call_event)
17032 (emit_memory_changed_event, emit_register_changed_event): Use
17033 gdbpy_ref.
17034 * python/py-exitedevent.c (create_exited_event_object)
17035 (emit_exited_event): Use gdbpy_ref.
17036 * python/py-event.h (evpy_emit_event): Remove
17037 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
17038 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
17039 * python/py-continueevent.c (emit_continue_event): Use
17040 gdbpy_ref.
17041 * python/py-breakpoint.c (gdbpy_breakpoint_created)
17042 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
17043 gdbpy_ref.
17044 * python/py-bpevent.c (create_breakpoint_event_object): Use
17045 gdbpy_ref.
17046
a68ff33e
TT
170472017-01-10 Tom Tromey <tom@tromey.com>
17048
17049 * python/py-ref.h: New file.
17050
7becfd03
SM
170512017-01-10 Simon Marchi <simon.marchi@ericsson.com>
17052
17053 * cli-out.c (cli_ui_out::do_redirect): Change return type to
17054 void.
17055 * cli-out.h (cli_ui_out::do_redirect): Likewise.
17056 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
17057 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
17058 * ui-out.c (ui_out::redirect): Likewise.
17059 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
17060 * cli/cli-logging.c (set_logging_redirect): Update call site of
17061 ui_out::redirect.
17062 (handle_redirections): Likewise.
17063 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
17064 * top.c (execute_command_to_string): Likewise.
17065 * utils.c (do_ui_out_redirect_pop): Likewise.
17066
df294654
SM
170672017-01-10 Simon Marchi <simon.marchi@ericsson.com>
17068
17069 * stack.c (_initialize_stack): Update "frame" command help message.
17070
f5e6296e
IB
170712017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
17072
17073 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
17074
0e2d6fa6
YQ
170752017-01-06 Yao Qi <yao.qi@linaro.org>
17076
17077 * x86-linux-nat.h: Include gdb_proc_service.h.
17078
44d6d3f9
YQ
170792017-01-06 Yao Qi <yao.qi@linaro.org>
17080
17081 * ser-base.h: Include serial.h.
17082
656731fe
YQ
170832017-01-06 Yao Qi <yao.qi@linaro.org>
17084
17085 * ppc-linux-tdep.h: Include ppc-tdep.h.
17086
1ca8f924
YQ
170872017-01-06 Yao Qi <yao.qi@linaro.org>
17088
17089 * nat/amd64-linux-siginfo.h: Include signal.h.
17090
bc3008c4
YQ
170912017-01-06 Yao Qi <yao.qi@linaro.org>
17092
17093 * nat/aarch64-linux-hw-point.h: Include break-common.h.
17094
66c80d03
YQ
170952017-01-06 Yao Qi <yao.qi@linaro.org>
17096
17097 * mi/mi-parse.h: Include mi-cmds.h.
17098
051d2dda
YQ
170992017-01-06 Yao Qi <yao.qi@linaro.org>
17100
17101 * inf-loop.c: Don't include "target.h".
17102 * inf-loop.h: Include it here.
17103
8018d34f
YQ
171042017-01-06 Yao Qi <yao.qi@linaro.org>
17105
17106 * dfp.h: Include "dboulest.h" and "expression.h".
17107
c0b8369c
YQ
171082017-01-06 Yao Qi <yao.qi@linaro.org>
17109
17110 * ax-gdb.h: Include "ax.h".
17111
ad5cba2a
YQ
171122017-01-06 Yao Qi <yao.qi@linaro.org>
17113
17114 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
17115 with nat/gdb_ptrace.h.
17116
1c33cd7f
YQ
171172017-01-05 Yao Qi <yao.qi@linaro.org>
17118
17119 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
17120 new line.
17121 (mips64_fbsd_sigframe_init): Likewise.
17122
c988ac1d
JB
171232017-01-04 John Baldwin <jhb@FreeBSD.org>
17124
17125 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
17126 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
17127
b268007c
JB
171282017-01-04 John Baldwin <jhb@FreeBSD.org>
17129
17130 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
17131 * NEWS: Mention new FreeBSD/mips native configuration.
17132 * config/mips/fbsd.mh: New file.
17133 * configure.host: Add mips*-*-freebsd*.
17134 * mips-fbsd-nat.c: New file.
17135
387360da
JB
171362017-01-04 John Baldwin <jhb@FreeBSD.org>
17137
17138 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
17139 (ALLDEPFILES): Add mips-fbsd-tdep.c.
17140 * NEWS: Mention new FreeBSD/mips target.
17141 * configure.tgt: Add mips*-*-freebsd*.
17142 * mips-fbsd-tdep.c: New file.
17143 * mips-fbsd-tdep.h: New file.
17144
2aaaf250
YQ
171452017-01-04 Yao Qi <yao.qi@linaro.org>
17146
17147 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
17148 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
17149
61baf725
JB
171502017-01-01 Joel Brobecker <brobecker@adacore.com>
17151
6dbb839a 17152 Update copyright year range in all GDB files.
61baf725 17153
c113e7ff 171542017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 17155
c113e7ff 17156 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 17157
c113e7ff 17158For older changes see ChangeLog-2016.
c906108c
SS
17159\f
17160Local Variables:
17161mode: change-log
17162left-margin: 8
17163fill-column: 74
17164version-control: never
57da7796 17165coding: utf-8
c906108c 17166End: