b55ffdd89fc2809cbd3880a877d17c9f9d58ebcc
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2017-11-16 Pedro Alves <palves@redhat.com>
2
3 * infrun.c (resume_cleanups): Delete.
4 (resume): No longer install a resume_cleanups cleanup nor call
5 QUIT.
6 (proceed): Pass the terminal to the inferior.
7 (keep_going_pass_signal): No longer install a resume_cleanups
8 cleanup.
9
10 2017-11-16 Pedro Alves <palves@redhat.com>
11
12 * inf-loop.c (inferior_event_handler): Don't swallow the exception
13 if the prompt is blocked.
14
15 2017-11-16 Pedro Alves <palves@redhat.com>
16
17 * breakpoint.c (insert_bp_location): Replace bp_err and
18 bp_err_message locals by a gdb_exception local.
19
20 2017-11-16 Pedro Alves <palves@redhat.com>
21
22 * inflow.c (scoped_ignore_sigttou): New class.
23 (child_terminal_ours_1, new_tty): Use it.
24
25 2017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
26
27 * target-float.c (decimal_from_number): Add byte_order argument and
28 call match_endianness. Error if unknown floating-point type.
29 (decimal_to_number): Add byte_order argument and call match_endianness.
30 (decimal_from_longest): Update call. Do not call match_endianness.
31 (decimal_from_ulongest): Likewise.
32 (decimal_binop): Likewise.
33 (decimal_is_zero): Likewise.
34 (decimal_compare): Likewise.
35 (decimal_convert): Likewise.
36
37 2017-11-16 Phil Muldoon <pmuldoon@redhat.com>
38
39 * python/python.c (gdbpy_rbreak): New function.
40 * NEWS: Document Python rbreak feature.
41
42 2017-11-16 Yao Qi <yao.qi@linaro.org>
43
44 * features/tic6x-c62x.xml: Remove.
45 * features/tic6x-c64x.xml: Remove.
46 * features/tic6x-c64xp.xml: Remove.
47
48 2017-11-15 John Baldwin <jhb@FreeBSD.org>
49
50 * symtab.h: Include <array>.
51
52 2017-11-15 John Baldwin <jhb@FreeBSD.org>
53
54 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
55 (bsd_kvm_proc_cmd): Likewise.
56
57 2017-11-15 Simon Marchi <simon.marchi@ericsson.com>
58
59 * tui/tui-win.c (window_name_completer): Replace VEC with
60 std::vector.
61
62 2017-11-15 Andrew Cagney <cagney@gnu.org>
63
64 * MAINTAINERS: Remove no-longer applicable entries.
65
66 2017-11-15 Andrew Cagney <cagney@gnu.org>
67
68 * MAINTAINERS: Move self to Past Maintainers.
69
70 2017-11-15 Yao Qi <yao.qi@linaro.org>
71
72 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
73 * features/nios2-linux.c: Remove.
74 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
75 initialize_tdesc_nios2_linux.
76
77 2017-11-15 Yao Qi <yao.qi@linaro.org>
78
79 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
80 M68HC11_LAST_HARD_REG + 1.
81
82 2017-11-14 Paul Carroll <pcarroll@codesourcery.com>
83
84 PR gdb/22388
85 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
86 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
87 Return TARGET_XFER_EOF if size of returned data is 0.
88
89 2017-11-14 Simon Marchi <simon.marchi@ericsson.com>
90
91 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
92 memory-map-selftests.c.
93 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
94 * memory-map.c (memory_map_start_memory): Fix computation of hi
95 address.
96 * unittests/memory-map-selftests.c: New file.
97
98 2017-11-09 Joel Brobecker <brobecker@adacore.com>
99
100 * ada-lang.c: Fix some typos in the general command documenting
101 how Ada expressions are being evaluated and how their result
102 is printed.
103
104 2017-11-09 Tom Tromey <tom@tromey.com>
105
106 * psymtab.c (psymbol_hash): Do not hash string contents.
107 (psymbol_compare): Add comment.
108
109 2017-11-09 Tom Tromey <tom@tromey.com>
110
111 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
112
113 2017-11-08 Joel Brobecker <brobecker@adacore.com>
114
115 * ada-exp.y (write_var_from_sym): Remove parameter
116 "orig_left_context". Update all callers.
117
118 2017-11-08 Simon Marchi <simon.marchi@ericsson.com>
119
120 * tracepoint.h (class collection_list) <stringify>: Return
121 std::vector<std::string>.
122 (encode_actions_rsp): Change parameters to
123 std::vector<std::string> *.
124 * tracepoint.c (collection_list::stringify): Return
125 std::vector<std::string> and adjust accordingly.
126 (encode_actions_rsp): Changee parameters to
127 std::vector<std::string> and adjust accordingly.
128 * remote.c (free_actions_list),
129 free_actions_list_cleanup_wrapper): Remove.
130 (remote_download_tracepoint): Adjust to std::vector.
131
132 2017-11-08 Tom Tromey <tom@tromey.com>
133
134 * dwarf2read.c (symbolp): Remove typedef.
135 (read_func_scope): Use std::vector.
136 (process_structure_scope): Use std::vector.
137
138 2017-11-08 Pedro Alves <palves@redhat.com>
139
140 * ada-lang.c (ada_make_symbol_completion_list): Use
141 completion_skip_symbol.
142 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
143 (symbol_is_function_or_method(symbol*)): New.
144 (add_symtab_completions): Add complete_symbol_mode parameter. Use
145 completion_skip_symbol.
146 (default_collect_symbol_completion_matches_break_on): Use
147 completion_skip_symbol. Pass down mode.
148 (collect_file_symbol_completion_matches): Pass down mode.
149 * symtab.h (symbol_is_function_or_method): New declarations.
150 (completion_skip_symbol): New template function.
151
152 2017-11-08 Pedro Alves <palves@redhat.com>
153
154 * linespec.c (iterate_over_all_matching_symtabs): Add
155 search_domain parameter. Pass it down to expand_symtabs_matching.
156 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
157 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
158 search_domain.
159 (add_all_symbol_names_from_pspace): Add search_domain parameter.
160 Pass it down.
161 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
162 symbols.
163 (add_matching_symbols_to_info): Add search_domain parameter. Pass
164 it down.
165
166 2017-11-08 Pedro Alves <palves@redhat.com>
167
168 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
169 text_len locals and don't pass them down.
170 * symtab.c (completion_list_add_name): Remove
171 sym_text/sym_text_len parameters and adjust.
172 (completion_list_add_symbol, completion_list_add_msymbol)
173 (completion_list_objc_symbol, completion_list_add_fields)
174 (add_symtab_completions): Likewise.
175 (default_collect_symbol_completion_matches_break_on)
176 (collect_file_symbol_completion_matches): Remove sym_text_len
177 local and don't pass it down.
178 * symtab.h (completion_list_add_name): Remove
179 sym_text/sym_text_len parameters.
180
181 2017-11-08 Pedro Alves <palves@redhat.com>
182
183 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
184 unittests/lookup_name_info-selftests.c.
185 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
186 * cp-support.c: Include "selftest.h".
187 (cp_remove_params_1): Rename from cp_remove_params. Add
188 'require_param' parameter, and handle it.
189 (cp_remove_params): Reimplement.
190 (cp_remove_params_if_any): New.
191 (selftests::quote): New.
192 (selftests::check_remove_params): New.
193 (selftests::test_cp_remove_params): New.
194 (_initialize_cp_support): Install
195 selftests::test_cp_remove_params.
196 * cp-support.h (cp_remove_params_if_any): Declare.
197 * dwarf2read.c :Include "selftest.h".
198 (dw2_expand_symtabs_matching_symbol): Use
199 lookup_name_info::make_ignore_params.
200 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
201 (selftests::dw2_expand_symtabs_matching::string_or_null)
202 (selftests::dw2_expand_symtabs_matching::check_match)
203 (selftests::dw2_expand_symtabs_matching::test_symbols)
204 (selftests::dw2_expand_symtabs_matching::run_test): New.
205 (_initialize_dwarf2_read): Register
206 selftests::dw2_expand_symtabs_matching::run_test.
207 * psymtab.c (psym_expand_symtabs_matching): Use
208 lookup_name_info::make_ignore_params.
209 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
210 If the lookup name wants to ignore parameters, strip them.
211 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
212 code handling '('.
213 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
214 (default_collect_symbol_completion_matches_break_on): Don't try to
215 strip parameters.
216 * symtab.h (lookup_name_info::lookup_name_info): Add
217 'ignore_parameters' parameter.
218 (lookup_name_info::ignore_parameters)
219 (lookup_name_info::make_ignore_params): New methods.
220 (lookup_name_info::m_ignore_parameters): New field.
221 * unittests/lookup_name_info-selftests.c: New file.
222
223 2017-11-08 Pedro Alves <palves@redhat.com>
224
225 * dwarf2read.c (dw2_expand_marked_cus)
226 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
227 (dw2_expand_symtabs_matching): Move further below.
228 (dw2_expand_marked_cus): Reindent.
229
230 2017-11-08 Pedro Alves <palves@redhat.com>
231
232 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
233 (struct name_component): New.
234 (mapped_index::name_components): New field.
235 (mapped_index::symbol_name_at): New method.
236 (dwarf2_read_index): Call mapped_index ctor.
237 (dw2_map_matching_symbols): Add comment about name_components
238 table.
239 (dw2_expand_symtabs_matching): Factor part to...
240 (dw2_expand_symtabs_matching_symbol): ... this new function.
241 Build name components table, and lookup symbols in it before
242 calling the name matcher.
243 (dw2_expand_marked_cus): New, factored out from
244 dw2_expand_symtabs_matching.
245 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
246
247 2017-11-08 Pedro Alves <palves@redhat.com>
248
249 * ada-lang.c (ada_encode): Rename to ..
250 (ada_encode_1): ... this. Add throw_errors parameter and handle
251 it.
252 (ada_encode): Reimplement.
253 (match_name): Delete, folded into full_name.
254 (resolve_subexp): No longer pass the encoded name to
255 ada_lookup_symbol_list.
256 (should_use_wild_match): Delete.
257 (name_match_type_from_name): New.
258 (ada_lookup_simple_minsym): Use lookup_name_info and the
259 language's symbol_name_matcher_ftype.
260 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
261 (ada_add_block_renamings): Adjust to use lookup_name_info.
262 (ada_lookup_name): New.
263 (add_nonlocal_symbols, ada_add_all_symbols)
264 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
265 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
266 (ada_name_for_lookup): Delete.
267 (ada_lookup_encoded_symbol): Construct a verbatim name.
268 (wild_match): Reverse sense of return type. Use bool.
269 (full_match): Reverse sense of return type. Inline bits of old
270 match_name here.
271 (ada_add_block_symbols): Adjust to use lookup_name_info.
272 (symbol_completion_match): Delete, folded into...
273 (ada_lookup_name_info::matches): ... .this new method.
274 (symbol_completion_add): Delete.
275 (ada_collect_symbol_completion_matches): Add name_match_type
276 parameter. Adjust to use lookup_name_info and
277 completion_list_add_name.
278 (get_var_value, ada_add_global_exceptions): Adjust to use
279 lookup_name_info.
280 (ada_get_symbol_name_cmp): Delete.
281 (do_wild_match, do_full_match): New functions.
282 (ada_lookup_name_info::ada_lookup_name_info): New method.
283 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
284 functions.
285 (ada_language_defn): Install ada_get_symbol_name_matcher.
286 * ada-lex.l (processId): If name starts with '<', copy it
287 verbatim.
288 * block.c (block_iter_match_step, block_iter_match_first)
289 (block_iter_match_next, block_lookup_symbol)
290 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
291 lookup_name_info.
292 * block.h (block_iter_match_first, block_iter_match_next)
293 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
294 * c-lang.c (c_language_defn, cplus_language_defn)
295 (asm_language_defn, minimal_language_defn): Adjust comments to
296 refer to la_get_symbol_name_matcher.
297 * completer.c (complete_files_symbols)
298 (collect_explicit_location_matches, symbol_completer): Pass a
299 symbol_name_match_type down.
300 * completer.h (class completion_match, completion_match_result):
301 New classes.
302 (completion_tracker::reset_completion_match_result): New method.
303 (completion_tracker::m_completion_match_result): New field.
304 * cp-support.c (make_symbol_overload_list_block): Adjust to use
305 lookup_name_info.
306 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
307 functions.
308 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
309 * d-lang.c: Adjust comments to refer to
310 la_get_symbol_name_matcher.
311 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
312 Adjust to use lookup_name_info.
313 (dict_iter_match_first, dict_iter_match_next)
314 (iter_match_first_hashed, iter_match_next_hashed)
315 (iter_match_first_linear, iter_match_next_linear): Adjust to work
316 with a lookup_name_info.
317 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
318 Likewise.
319 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
320 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
321 (gdb_index_symbol_name_matcher): New class.
322 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
323 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
324 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
325 with a symbol_name_match_type.
326 (f_language_defn): Adjust comments to refer to
327 la_get_symbol_name_matcher.
328 * go-lang.c (go_language_defn): Adjust comments to refer to
329 la_get_symbol_name_matcher.
330 * language.c (default_symbol_name_matcher)
331 (language_get_symbol_name_matcher): New functions.
332 (unknown_language_defn, auto_language_defn): Adjust comments to
333 refer to la_get_symbol_name_matcher.
334 * language.h (symbol_name_cmp_ftype): Delete.
335 (language_defn) <la_collect_symbol_completion_matches>: Add match
336 type parameter.
337 <la_get_symbol_name_cmp>: Delete field.
338 <la_get_symbol_name_matcher>: New field.
339 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
340 (default_symbol_name_matcher, language_get_symbol_name_matcher):
341 Declare.
342 * linespec.c (iterate_over_all_matching_symtabs)
343 (iterate_over_file_blocks): Adjust to use lookup_name_info.
344 (find_methods): Add language parameter, and use lookup_name_info
345 and the language's symbol_name_matcher_ftype.
346 (linespec_complete_function): Adjust.
347 (lookup_prefix_sym): Use lookup_name_info.
348 (add_all_symbol_names_from_pspace): Adjust.
349 (find_superclass_methods): Add language parameter and pass it
350 down.
351 (find_method): Pass symbol language down.
352 (find_linespec_symbols): Don't demangle or Ada encode here.
353 (search_minsyms_for_name): Add lookup_name_info parameter.
354 (add_matching_symbols_to_info): Add name_match_type parameter.
355 Use lookup_name_info.
356 * m2-lang.c (m2_language_defn): Adjust comments to refer to
357 la_get_symbol_name_matcher.
358 * minsyms.c: Include <algorithm>.
359 (add_minsym_to_demangled_hash_table): Remove table parameter and
360 add objfile parameter. Use search_name_hash, and add language to
361 demangled languages vector.
362 (struct found_minimal_symbols): New struct.
363 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
364 New functions.
365 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
366 input names here. Use lookup_name_info instead. Lookup up
367 demangled names once for each language in the demangled names
368 vector.
369 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
370 demangled names once for each language in the demangled names
371 vector.
372 (build_minimal_symbol_hash_tables): Adjust.
373 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
374 lookup_name_info.
375 * objc-lang.c (objc_language_defn): Adjust comment to refer to
376 la_get_symbol_name_matcher.
377 * objfiles.h: Include <vector>.
378 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
379 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
380 la_get_symbol_name_matcher.
381 * p-lang.c (pascal_language_defn): Adjust comment to refer to
382 la_get_symbol_name_matcher.
383 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
384 (match_partial_symbol): Use symbol_name_match_type,
385 lookup_name_info and psymbol_name_matches.
386 (lookup_partial_symbol): Use lookup_name_info.
387 (map_block): Use symbol_name_match_type and lookup_name_info.
388 (psym_map_matching_symbols): Use symbol_name_match_type.
389 (psymbol_name_matches): New.
390 (recursively_search_psymtabs): Use lookup_name_info and
391 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
392 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
393 'kind' parameter to 'domain'.
394 * rust-lang.c (rust_language_defn): Adjust comment to refer to
395 la_get_symbol_name_matcher.
396 * symfile-debug.c (debug_qf_map_matching_symbols)
397 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
398 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
399 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
400 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
401 Adjust to use symbol_name_match_type.
402 <expand_symtabs_matching>: Adjust to use lookup_name_info.
403 (expand_symtabs_matching): Adjust to use lookup_name_info.
404 * symmisc.c (maintenance_expand_symtabs): Use
405 lookup_name_info::match_any ().
406 * symtab.c (symbol_matches_search_name): New.
407 (eq_symbol_entry): Adjust to use lookup_name_info and the
408 language's matcher.
409 (demangle_for_lookup_info::demangle_for_lookup_info): New.
410 (lookup_name_info::match_any): New.
411 (iterate_over_symbols, search_symbols): Use lookup_name_info.
412 (compare_symbol_name): Add language, lookup_name_info and
413 completion_match_result parameters, and use them.
414 (completion_list_add_name): Make extern. Add language and
415 lookup_name_info parameters. Use them.
416 (completion_list_add_symbol, completion_list_add_msymbol)
417 (completion_list_objc_symbol): Add lookup_name_info parameters and
418 adjust. Pass down language.
419 (completion_list_add_fields): Add lookup_name_info parameters and
420 adjust. Pass down language.
421 (add_symtab_completions): Add lookup_name_info parameters and
422 adjust.
423 (default_collect_symbol_completion_matches_break_on): Add
424 name_match_type parameter, and use it. Use lookup_name_info.
425 (default_collect_symbol_completion_matches)
426 (collect_symbol_completion_matches): Add name_match_type
427 parameter, and pass it down.
428 (collect_symbol_completion_matches_type): Adjust.
429 (collect_file_symbol_completion_matches): Add name_match_type
430 parameter, and use lookup_name_info.
431 * symtab.h: Include <string> and "common/gdb_optional.h".
432 (enum class symbol_name_match_type): New.
433 (class ada_lookup_name_info): New.
434 (struct demangle_for_lookup_info): New.
435 (class lookup_name_info): New.
436 (symbol_name_matcher_ftype): New.
437 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
438 (symbol_matches_search_name): Declare.
439 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
440 (default_collect_symbol_completion_matches)
441 (collect_symbol_completion_matches)
442 (collect_file_symbol_completion_matches): Add name_match_type
443 parameter.
444 (iterate_over_symbols): Use lookup_name_info.
445 (completion_list_add_name): Declare.
446 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
447 (strncmp_iw_with_mode): Now extern.
448 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
449 (strncmp_iw_with_mode): Declare.
450
451 2017-11-08 Keith Seitz <keiths@redhat.com>
452 Pedro Alves <palves@redhat.com>
453
454 * ada-lang.c (ada_language_defn): Install
455 default_search_name_hash.
456 * buildsym.c (struct buildsym_compunit): <language>: New field.
457 (finish_block_internal): Pass language when creating dictionaries.
458 (start_buildsym_compunit, start_symtab): New language parameters.
459 Use them.
460 (restart_symtab): Pass down compilation unit's language.
461 * buildsym.h (enum language): Forward declare.
462 (start_symtab): New 'language' parameter.
463 * c-lang.c (c_language_defn, cplus_language_defn)
464 (asm_language_defn, minimal_language_defn): Install
465 default_search_name_hash.
466 * coffread.c (coff_start_symtab): Adjust.
467 * d-lang.c (d_language_defn): Install default_search_name_hash.
468 * dbxread.c (struct symloc): Add 'pst_language' field.
469 (PST_LANGUAGE): Define.
470 (start_psymtab, read_ofile_symtab): Use it.
471 (process_one_symbol): New 'language' parameter. Pass it down.
472 * dictionary.c (struct dictionary) <language>: New field.
473 (DICT_LANGUAGE): Define.
474 (dict_create_hashed, dict_create_hashed_expandable)
475 (dict_create_linear, dict_create_linear_expandable): New parameter
476 'language'. Set the dictionary's language.
477 (iter_match_first_hashed): Adjust to rename.
478 (insert_symbol_hashed): Assert we don't see mismatching
479 languages. Adjust to rename.
480 (dict_hash): Rename to ...
481 (default_search_name_hash): ... this and make extern.
482 * dictionary.h (struct language_defn): Forward declare.
483 (dict_create_hashed): New parameter 'language'.
484 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
485 * f-lang.c (f_language_defn): Install default_search_name_hash.
486 * go-lang.c (go_language_defn): Install default_search_name_hash.
487 * jit.c (finalize_symtab): Pass compunit's language to dictionary
488 creation.
489 * language.c (unknown_language_defn, auto_language_defn):
490 * language.h (language_defn::la_search_name_hash): New field.
491 (default_search_name_hash): Declare.
492 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
493 * mdebugread.c (new_block): New parameter 'language'.
494 * mdebugread.c (parse_symbol): Pass symbol language to block
495 allocation.
496 (psymtab_to_symtab_1): Pass down language.
497 (new_symtab): Pass compunit's language to block allocation.
498 * objc-lang.c (objc_language_defn): Install
499 default_search_name_hash.
500 * opencl-lang.c (opencl_language_defn):
501 * p-lang.c (pascal_language_defn): Install
502 default_search_name_hash.
503 * rust-lang.c (rust_language_defn): Install
504 default_search_name_hash.
505 * stabsread.h (enum language): Forward declare.
506 (process_one_symbol): Add 'language' parameter.
507 * symtab.c (search_name_hash): New function.
508 * symtab.h (search_name_hash): Declare.
509 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
510
511 2017-11-08 Pedro Alves <palves@redhat.com>
512
513 * cp-name-parser.y (main): Don't initialize extra_chars.
514
515 2017-11-07 Tom Tromey <tom@tromey.com>
516
517 * event-top.h (command_handler): Constify.
518 * record-full.c (cmd_record_full_start): Update.
519 * thread.c (thread_apply_all_command): Update.
520 * printcmd.c (eval_command): Update.
521 * mi/mi-main.c (mi_execute_cli_command): Update.
522 (mi_execute_async_cli_command): Update.
523 * tui/tui-stack.c (tui_update_command): Update.
524 * cli/cli-interp.c (safe_execute_command): Constify.
525 * record.c (record_start): Update.
526 (record_start, record_stop, cmd_record_start): Update.
527 * record-btrace.c (cmd_record_btrace_bts_start): Update.
528 (cmd_record_btrace_pt_start): Update.
529 (cmd_record_btrace_start): Update.
530 (cmd_record_btrace_start): Update.
531 * reverse.c (exec_reverse_once): Update.
532 * python/python.c (execute_gdb_command): Don't copy the command.
533 * event-top.c (command_line_handler): Update.
534 (command_handler): Constify.
535 * defs.h (deprecated_call_command_hook): Constify.
536 * cli/cli-script.h (execute_user_command): Constify.
537 * cli/cli-script.c (execute_user_command): Constify.
538 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
539 (enum command_control_type): Update.
540 * main.c (catch_command_errors): Remove non-const overload.
541 (catch_command_errors_ftype): Remove.
542 * python/py-cmd.c (cmdpy_function): Constify.
543 * guile/scm-cmd.c (cmdscm_function): Constify.
544 * cli/cli-dump.c (call_dump_func): Constify.
545 * cli/cli-decode.c (do_const_cfunc): Constify.
546 (do_sfunc): Constify.
547 (cmd_func): Constify.
548 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
549 * top.h (execute_command): Constify.
550 * top.c (execute_command): Constify.
551 (execute_command_to_string): Constify.
552 (deprecated_call_command_hook): Constify.
553 * command.h (cmd_func): Constify.
554 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
555
556 2017-11-07 Tom Tromey <tom@tromey.com>
557
558 * ada-lang.c (catch_ada_exception_command): Constify.
559 (catch_assert_command): Constify.
560 * break-catch-throw.c (catch_catch_command, catch_throw_command)
561 (catch_rethrow_command): Constify.
562 (catch_exception_command_1): Constify.
563 * breakpoint.h (add_catch_command): Constify.
564 * break-catch-syscall.c (catch_syscall_command_1): Constify.
565 (catch_syscall_split_args): Constify.
566 * break-catch-sig.c (catch_signal_command): Constify.
567 (catch_signal_split_args): Constify.
568 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
569 cmd_const_sfunc_ftype.
570 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
571 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
572 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
573 (add_setshow_string_cmd, struct cmd_list_element)
574 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
575 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
576 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
577 Constify.
578 (set_cmd_sfunc): Constify.
579 (empty_sfunc): Constify.
580 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
581 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
582 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
583 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
584 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
585 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
586 Constify.
587 (set_cmd_sfunc): Constify.
588 (cmd_sfunc_ftype): Remove.
589 * compile/compile.c (set_compile_args): Constify.
590 * infrun.c (set_disable_randomization): Constify.
591 * infcmd.c (set_args_command, set_cwd_command): Constify.
592 * breakpoint.c (set_condition_evaluation_mode): Constify.
593 (add_catch_command): Constify.
594 (catch_fork_command_1, catch_exec_command_1)
595 (catch_load_command_1, catch_unload_command_1): Constify.
596 (catch_load_or_unload): Constify.
597 * guile/scm-param.c (pascm_set_func): Constify.
598 (add_setshow_generic): Constify.
599 * python/py-param.c (get_set_value): Constify.
600 * top.h (set_verbose): Constify.
601 * tui/tui-win.c (tui_set_var_cmd): Constify.
602 * mi/mi-main.c (set_mi_async_command): Constify.
603 * cli/cli-logging.c (set_logging_overwrite)
604 (set_logging_redirect): Constify.
605 * value.c (set_max_value_size): Constify.
606 * valprint.c (set_input_radix, set_output_radix): Constify.
607 * utils.c (set_width_command, set_height_command): Constify.
608 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
609 * tracepoint.c (set_disconnected_tracing)
610 (set_circular_trace_buffer, set_trace_buffer_size)
611 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
612 * top.c (set_history_size_command, set_verbose, set_editing)
613 (set_gdb_datadir, set_history_filename): Constify.
614 * target.c (set_targetdebug, maint_set_target_async_command)
615 (maint_set_target_non_stop_command, set_target_permissions)
616 (set_write_memory_permission): Constify.
617 (open_target): Constify.
618 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
619 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
620 * symtab.c (set_symbol_cache_size_handler): Constify.
621 * symfile.c (set_ext_lang_command): Constify.
622 * symfile-debug.c (set_debug_symfile): Constify.
623 * source.c (set_directories_command): Constify.
624 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
625 * serial.c (set_parity): Constify.
626 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
627 * remote.c (set_remote_exec_file, set_remotebreak)
628 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
629 * record.c (set_record_insn_history_size)
630 (set_record_call_history_size): Constify.
631 * record-full.c (set_record_full_insn_max_num): Constify.
632 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
633 * osabi.c (set_osabi): Constify.
634 * mips-tdep.c (set_mips64_transfers_32bit_regs)
635 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
636 * maint.c (maintenance_set_profile_cmd): Constify.
637 * linux-thread-db.c (set_libthread_db_search_path): Constify.
638 * language.c (set_language_command, set_range_command)
639 (set_case_command): Constify.
640 * infrun.c (set_non_stop, set_observer_mode)
641 (set_stop_on_solib_events, set_schedlock_func)
642 (set_exec_direction_func): Constify.
643 * infcmd.c (set_inferior_tty_command): Constify.
644 * disasm.c (set_disassembler_options_sfunc): Constify.
645 * demangle.c (set_demangling_command): Constify.
646 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
647 * cris-tdep.c (set_cris_version, set_cris_mode)
648 (set_cris_dwarf2_cfi): Constify.
649 * corefile.c (set_gnutarget_command): Constify.
650 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
651 (set_target_wide_charset_sfunc): Constify.
652 * breakpoint.c (update_dprintf_commands): Constify.
653 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
654 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
655 (set_disassembly_style_sfunc): Constify.
656 * arch-utils.c (set_endian, set_architecture): Constify.
657 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
658 * agent.c (set_can_use_agent): Constify.
659
660 2017-11-07 Tom Tromey <tom@tromey.com>
661
662 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
663 (go32_pde, go32_pte, go32_pte_for_address): Constify.
664 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
665 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
666 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
667 (parse_int_arg, show_thread_default_detach_sc_cmd)
668 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
669 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
670 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
671 (show_task_pause_cmd, set_task_detach_sc_cmd)
672 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
673 (set_noninvasive_cmd, set_thread_pause_cmd)
674 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
675 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
676 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
677 * windows-nat.c (display_selectors): Constify.
678 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
679 non-const "cfunc".
680 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
681 (cmd_cfunc_eq): Likewise.
682 (struct cmd_list_element): Likewise.
683 (do_cfunc): Remove.
684 (cli_user_command_p): Update.
685 * command.h (add_cmd): Remove non-const overload.
686 (cmd_cfunc_ftype): Remove typedef.
687 (cmd_cfunc_eq): Remove non-const overload.
688 * value.c (show_values): Constify.
689 * thread.c (thread_apply_all_command): Constify.
690 * symfile.c (load_command): Constify.
691 * source.c (directory_command): Constify.
692 * maint.c (maintenance_internal_error)
693 (maintenance_demangler_warning, maintenance_space_display)
694 (maintenance_print_architecture, maintenance_translate_address)
695 (maintenance_info_selftests, maintenance_internal_warning):
696 Constify.
697 * breakpoint.c (disable_trace_command, enable_trace_command):
698 Constify.
699 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
700 Constify.
701 (add_auto_load_safe_path): Constify.
702 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
703 * top.h (show_commands): Constify.
704 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
705 * sparc64-tdep.c (adi_examine_command): Constify.
706 (adi_assign_command): Constify.
707
708 2017-11-07 Tom Tromey <tom@tromey.com>
709
710 * frame.h (info_locals_command, info_args_command): Constify.
711 * auto-load.h (auto_load_info_scripts): Constify.
712 * inferior.h (registers_info): Constify.
713 * copying.c: Rebuild.
714 * copying.awk: Constify generated commands.
715 * auto-load.c (auto_load_info_scripts)
716 (info_auto_load_gdb_scripts): Constify.
717 * cli/cli-decode.c (struct cmd_list_element): Take a
718 cmd_const_cfunc_ftype.
719 * command.h (add_info): Take a cmd_const_cfunc_ftype.
720 * tui/tui-win.c (tui_all_windows_info): Constify.
721 * python/py-auto-load.c (info_auto_load_python_scripts):
722 Constify.
723 * cli/cli-cmds.c (show_command): Remove non-const overload.
724 * tracepoint.c (info_tvariables_command, info_scope_command):
725 Constify.
726 (info_static_tracepoint_markers_command): Constify.
727 * thread.c (info_threads_command): Constify.
728 (print_thread_info_1): Constify.
729 * target.c (info_target_command): Constify.
730 * symtab.c (info_sources_command, info_functions_command)
731 (info_types_command): Constify.
732 (info_variables_command): Remove non-const overload.
733 * symfile.c (info_ext_lang_command): Constify.
734 * stack.c (info_frame_command, info_locals_command)
735 (info_args_command): Constify.
736 (backtrace_command): Remove non-const overload.
737 * source.c (info_source_command, info_line_command): Constify.
738 * solib.c (info_sharedlibrary_command): Constify.
739 * skip.c (info_skip_command): Constify.
740 * ser-go32.c (info_serial_command): Constify.
741 * reverse.c (info_bookmarks_command): Constify.
742 * printcmd.c (info_symbol_command, info_address_command)
743 (info_display_command): Constify.
744 * osdata.c (info_osdata_command): Constify.
745 * objc-lang.c (info_selectors_command, info_classes_command):
746 Constify.
747 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
748 * memattr.c (info_mem_command): Constify.
749 * macrocmd.c (info_macro_command, info_macros_command): Constify.
750 * linux-fork.c (info_checkpoints_command): Constify.
751 * infrun.c (info_signals_command): Constify.
752 * inflow.c (info_terminal_command): Constify.
753 * inferior.c (info_inferiors_command): Constify.
754 (print_inferior): Constify.
755 * infcmd.c (info_program_command, info_all_registers_command)
756 (info_registers_command, info_vector_command)
757 (info_float_command): Constify.
758 (registers_info): Constify.
759 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
760 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
761 Constify.
762 * f-valprint.c (info_common_command): Constify.
763 * dcache.c (info_dcache_command): Constify.
764 (dcache_info_1): Constify.
765 * darwin-nat-info.c (info_mach_tasks_command)
766 (info_mach_task_command, info_mach_ports_command)
767 (info_mach_port_command, info_mach_threads_command)
768 (info_mach_thread_command, info_mach_regions_command)
769 (info_mach_regions_recurse_command, info_mach_region_command)
770 (info_mach_exceptions_command): Constify.
771 (get_task_from_args): Constify.
772 * cp-support.c (info_vtbl_command): Constify.
773 * breakpoint.c (info_watchpoints_command)
774 (info_tracepoints_command): Constify.
775 (info_breakpoints_command): Remove non-const overload.
776 * avr-tdep.c (avr_io_reg_read_command): Constify.
777 * auxv.c (info_auxv_command): Constify.
778 * ada-tasks.c (info_tasks_command): Constify.
779 (info_task): Constify.
780 * ada-lang.c (info_exceptions_command): Constify.
781
782 2017-11-07 Tom Tromey <tom@tromey.com>
783
784 * solib.h (no_shared_libraries): Constify.
785 * frame.h (return_command): Constify.
786 * cli/cli-cmds.h (quit_command): Constify.
787 * top.h (quit_command, execute_command): Constify.
788 * target.h (flash_erase_command): Constify.
789 * inferior.h (set_inferior_args, attach_command): Constify.
790 * tracepoint.h (start_tracing, stop_tracing): Constify.
791 * breakpoint.h (break_command, tbreak_command)
792 (hbreak_command_wrapper, thbreak_command_wrapper)
793 (rbreak_command_wrapper, watch_command_wrapper)
794 (awatch_command_wrapper, rwatch_command_wrapper)
795 (get_tracepoint_by_number): Constify.
796 * symtab.c (info_variables_command, rbreak_command)
797 (symtab_symbol_info): Constify.
798 (info_variables_command): Add non-const overload.
799 * top.c (dont_repeat_command): Constify.
800 * breakpoint.c (ignore_command, commands_command)
801 (condition_command, tbreak_command, hbreak_command)
802 (thbreak_command, clear_command, break_command)
803 (info_breakpoints_command, watch_command, rwatch_command)
804 (awatch_command, trace_command, ftrace_command, strace_command)
805 (trace_pass_command, break_range_command, dprintf_command)
806 (agent_printf_command, get_tracepoint_by_number)
807 (watch_maybe_just_location, trace_pass_command): Constify.
808 (info_breakpoints_command): Add non-const overload.
809 * tracefile.c (tsave_command): Constify.
810 * infcmd.c (attach_command, disconnect_command, signal_command)
811 (queue_signal_command, stepi_command, nexti_command)
812 (finish_command, next_command, step_command, until_command)
813 (advance_command, jump_command, continue_command, run_command)
814 (start_command, starti_command, interrupt_command)
815 (run_command_1, set_inferior_args, step_1): Constify.
816 * inferior.c (add_inferior_command, remove_inferior_command)
817 (clone_inferior_command): Constify.
818 * linux-fork.c (checkpoint_command, restart_command): Constify.
819 * windows-nat.c (signal_event_command): Constify.
820 * guile/guile.c (guile_repl_command, guile_command): Constify.
821 * printcmd.c (x_command, display_command, printf_command)
822 (output_command, set_command, call_command, print_command)
823 (eval_command): Constify.
824 (non_const_set_command): Remove.
825 (_initialize_printcmd): Update.
826 * source.c (forward_search_command, reverse_search_command):
827 Constify.
828 * jit.c (jit_reader_load_command, jit_reader_unload_command):
829 Constify.
830 * infrun.c (handle_command): Constify.
831 * memattr.c (mem_command): Constify.
832 * stack.c (return_command, up_command, up_silently_command)
833 (down_command, down_silently_command, frame_command)
834 (backtrace_command, func_command, backtrace_command_1): Constify.
835 (backtrace_command): Add non-const overload.
836 * remote-sim.c (simulator_command): Constify.
837 * exec.c (set_section_command): Constify.
838 * tracepoint.c (tdump_command, trace_variable_command)
839 (tstatus_command, tstop_command, tstart_command)
840 (end_actions_pseudocommand, while_stepping_pseudocommand)
841 (collect_pseudocommand, teval_pseudocommand, actions_command)
842 (start_tracing, stop_tracing): Constify.
843 * value.c (init_if_undefined_command): Constify.
844 * tui/tui-stack.c (tui_update_command): Constify.
845 * tui/tui-win.c (tui_refresh_all_command)
846 (tui_set_tab_width_command, tui_set_win_height_command)
847 (tui_set_focus_command, tui_scroll_forward_command)
848 (tui_scroll_backward_command, tui_scroll_left_command)
849 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
850 (tui_set_win_height): Constify.
851 * tui/tui-layout.c (tui_layout_command): Constify.
852 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
853 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
854 (proc_untrace_sysexit_cmd): Constify.
855 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
856 (threadset_test_cmd, threadlist_update_test_cmd)
857 (threadalive_test): Constify.
858 * objc-lang.c (print_object_command): Constify.
859 * command.h (add_com): Constify.
860 * cli/cli-dump.c (restore_command): Constify.
861 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
862 (help_command, complete_command, shell_command, edit_command)
863 (list_command, disassemble_command, make_command)
864 (apropos_command, alias_command): Constify.
865 * cli/cli-script.c (document_command, define_command)
866 (while_command, if_command, validate_comname): Constify.
867 * cli/cli-decode.c (struct cmd_list_element): Change type of
868 "fun".
869 * target.c (do_monitor_command, flash_erase_command): Constify.
870 * regcache.c (reg_flush_command): Constify.
871 * reverse.c (reverse_step, reverse_next, reverse_stepi)
872 (reverse_nexti, reverse_continue, reverse_finish)
873 (save_bookmark_command, goto_bookmark_command)
874 (exec_reverse_once): Constify.
875 * python/python.c (python_interactive_command, python_command):
876 Constify.
877 * typeprint.c (ptype_command, whatis_command, whatis_exp):
878 Constify.
879 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
880 * gcore.c (gcore_command): Constify.
881
882 2017-11-07 Tom Tromey <tom@tromey.com>
883
884 * printcmd.c (x_command): Call set_repeat_arguments.
885 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
886 * top.c (repeat_arguments): New global.
887 (set_repeat_arguments): New function.
888 (execute_command): Handle repeat_arguments.
889 (show_commands): Calls set_repeat_arguments.
890 * command.h (set_repeat_arguments): Declare.
891
892 2017-11-07 Tom Tromey <tom@tromey.com>
893
894 * stack.c (backtrace_command): Use std::string.
895 (backtrace_command_1): Make "count_exp" const.
896
897 2017-11-07 Tom Tromey <tom@tromey.com>
898
899 * source.c (directory_switch, mod_path, add_path): Constify.
900 * defs.h (add_path, mod_path, directory_switch): Constify.
901 * mi/mi-cmd-env.c (env_mod_path): Constify.
902
903 2017-11-07 Tom Tromey <tom@tromey.com>
904
905 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
906 (run_command_1, continue_command, step_1, jump_command)
907 (signal_command, until_command, advance_command, finish_command)
908 (attach_command): Update.
909
910 2017-11-07 Tom Tromey <tom@tromey.com>
911
912 * command.h (set_cmd_cfunc): Don't declare.
913 * cli/cli-decode.c (set_cmd_cfunc): Now static.
914
915 2017-11-07 Tom Tromey <tom@tromey.com>
916
917 * stack.c (select_frame_command): Constify.
918 * cli/cli-decode.c (add_com_suppress_notification): Constify.
919 * command.h (add_com_suppress_notification): Constify.
920
921 2017-11-07 Tom Tromey <tom@tromey.com>
922
923 * breakpoint.c (stop_command): Constify.
924 * cli/cli-decode.c (struct cmd_list_element): Constify.
925 * command.h (add_abbrev_prefix_cmd): Constify.
926
927 2017-11-07 Pedro Alves <palves@redhat.com>
928
929 * breakpoint.c (extract_bp_kind): New enum.
930 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
931 factored out from ...
932 (extract_bp_number_and_location): ... here.
933 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
934
935 2017-11-07 Pedro Alves <palves@redhat.com>
936
937 * breakpoint.c (extract_bp_number_and_location): Change return
938 type to void. Throw error instead of warning.
939 (enable_disable_command): Adjust.
940
941 2017-11-07 Xavier Roirand <roirand@adacore.com>
942 Pedro Alves <palves@redhat.com>
943
944 * breakpoint.c (map_breakpoint_number_range): New, factored out
945 from ...
946 (map_breakpoint_numbers): ... here.
947 (find_location_by_number): Change parameters from string to
948 breakpoint number and location.
949 (extract_bp_number_and_location): New function.
950 (enable_disable_bp_num_loc)
951 (enable_disable_breakpoint_location_range)
952 (enable_disable_command): New functions, factored out ...
953 (enable_command, disable_command): ... these functions, and
954 adjusted to support ranges.
955 * NEWS: Document enable/disable breakpoint location range feature.
956
957 2017-11-06 Luis Machado <luis.machado@linaro.org>
958
959 * MAINTAINERS (Write After Approval): Update my e-mail address.
960
961 2017-11-06 Pedro Alves <palves@redhat.com>
962
963 * gnu-nat.c (gnu_terminal_init): Delete.
964 (gnu_target): Don't install gnu_terminal_init.
965 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
966 (child_terminal_init): ... this function.
967
968 2017-11-06 Pedro Alves <palves@redhat.com>
969
970 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
971 sgtty.h.
972 * config.in, configure: Regenerate.
973
974 2017-11-06 Pedro Alves <palves@redhat.com>
975
976 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
977 (async_init_signals): Adjust.
978 (handle_stop_sig): Rename to ...
979 (handle_sigtstp): ... this.
980 (async_stop_sig): Rename to ...
981 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
982 SIGTSTP path.
983 * event-top.h: Move signal.h include to the top. Check SIGTSTP
984 instead of STOP_SIGNAL thoughout.
985 (handle_stop_sig): Rename to ...
986 (handle_sigtstp): ... this.
987 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
988
989 2017-11-06 Pedro Alves <palves@redhat.com>
990
991 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
992 longer set flags twice in row.
993
994 2017-11-06 Pedro Alves <palves@redhat.com>
995
996 * Makefile.in (SER_HARDWIRE): Update comment.
997 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
998 * common/gdb_termios.h: Delete file.
999 * common/job-control.c: Include termios.h and unistd.h instead of
1000 gdb_termios.h.
1001 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
1002 check.
1003 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
1004 Remove sgtty code.
1005 * configure.ac: No longer check for termio.h and sgtty.h.
1006 * configure: Regenerate.
1007 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
1008 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
1009 Replace PROCESS_GROUP_TYPE references with pid_t references
1010 throughout.
1011 (gdb_getpgrp): Delete.
1012 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
1013 (child_terminal_inferior): Remove comment. Remove sgtty code.
1014 (child_terminal_ours_1): Use tcgetpgrp directly instead of
1015 gdb_getpgrp. Use serial_set_tty_state instead aof
1016 serial_noflush_set_tty_state. Remove sgtty code.
1017 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
1018 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
1019 (inferior_process_group): Now returns pid_t.
1020 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
1021 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
1022 * ser-event.c (serial_event_ops): Update.
1023 * ser-go32.c (dos_noflush_set_tty_state): Delete.
1024 (dos_ops): Update.
1025 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
1026 * ser-pipe.c (pipe_ops): Update.
1027 * ser-tcp.c (tcp_ops): Update.
1028 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
1029 HAVE_TERMIOS checks.
1030 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
1031 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
1032 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
1033 assume termios.
1034 (hardwire_noflush_set_tty_state): Delete.
1035 (hardwire_print_tty_state, hardwire_drain_output)
1036 (hardwire_flush_output, hardwire_flush_input)
1037 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
1038 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
1039 code, and assume termios.
1040 (hardwire_ops): Update.
1041 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
1042 * serial.c (serial_noflush_set_tty_state): Delete.
1043 * serial.h (serial_noflush_set_tty_state): Delete.
1044 (serial_ops::noflush_set_tty_state): Delete.
1045
1046 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1047
1048 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
1049 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
1050 (COMMON_OBS): Remove doublest.o and dfp.o.
1051 Do not build target-float.c (instead of doublest.c)
1052 with -Wformat-nonliteral.
1053
1054 * doublest.c: Remove file.
1055 * doublest.h: Remove file.
1056 * dfp.c: Remove file.
1057 * dfp.h: Remove file.
1058
1059 * target-float.c: Do not include "doublest.h" and "dfp.h".
1060 (DOUBLEST): Move here from doublest.h.
1061 (enum float_kind): Likewise.
1062 (FLOATFORMAT_CHAR_BIT): Likewise.
1063 (FLOATFORMAT_LARGEST_BYTES): Likewise.
1064 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
1065 (floatformat_precision): Likewise.
1066 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
1067 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
1068 Likewise.
1069 (host_float_format, host_double_format, host_long_double_format):
1070 Likewise.
1071 (floatformat_to_string, floatformat_from_string): Likewise.
1072 (floatformat_to_doublest): Likewise. Also, inline the original
1073 convert_floatformat_to_doublest.
1074 (floatformat_from_doublest): Likewise. Also, inline the original
1075 convert_floatformat_from_doublest.
1076
1077 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
1078 (MAX_DECIMAL_STRING): Move here from dfp.c.
1079 (match_endianness): Likewise.
1080 (set_decnumber_context, decimal_check_errors): Likewise.
1081 (decimal_from_number, decimal_to_number): Likewise.
1082 (decimal_to_string, decimal_from_string): Likewise. Make static.
1083 (decimal_from_longest, decimal_from_ulongest): Likewise.
1084 (decimal_to_longest): Likewise.
1085 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
1086 (decimal_convert): Likewise.
1087
1088 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1089
1090 * doublest.c: Do not include "gdbtypes.h".
1091 (extract_typed_floating): Remove.
1092 (store_typed_floating): Remove.
1093 (convert_typed_floating): Remove.
1094 * doublest.h (struct type): Remove.
1095 (DOUBLEST_PRINT_FORMAT): Remove.
1096 (DOUBLEST_SCAN_FORMAT): Remove.
1097 (extract_typed_floating): Remove.
1098 (store_typed_floating): Remove.
1099 (convert_typed_floating): Remove.
1100
1101 * dfp.c (decimal_from_doublest): Remove.
1102 (decimal_to_doublest): Remove.
1103 * dfp.h: Do not include "doublest.h".
1104 (decimal_from_doublest): Remove.
1105 (decimal_to_doublest): Remove.
1106
1107 * value.c: Do not include "doublest.h" and "dfp.h".
1108 (value_as_double): Remove.
1109 (unpack_double): Remove.
1110 (value_from_double): Remove.
1111 (value_from_decfloat): Remove.
1112 * value.h: Do not include "doublest.h".
1113 (value_as_double): Remove.
1114 (unpack_double): Remove.
1115 (value_from_double): Remove.
1116 (value_from_decfloat): Remove.
1117
1118 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1119
1120 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
1121 (i386_extract_return_value): Use target_float_convert.
1122 (i386_store_return_value): Likewise.
1123 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
1124 (i387_value_to_register): Likewise.
1125 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
1126 (ia64_register_to_value): Use target_float_convert.
1127 (ia64_value_to_register): Likewise.
1128 (ia64_extract_return_value): Likewise.
1129 (ia64_store_return_value): Likewise.
1130 (ia64_push_dummy_call): Likewise.
1131 * m68k-tdep.c: Include "target-float.h".
1132 (m68k_register_to_value): Use target_float_convert.
1133 (m68k_value_to_register): Likewise.
1134 (m68k_svr4_extract_return_value): Likewise.
1135 (m68k_svr4_store_return_value): Likewise.
1136 * ppc-sysv-tdep.c: Include "target-float.h".
1137 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
1138 (do_ppc_sysv_return_value): Likewise.
1139 (ppc64_sysv_abi_push_freg): Likewise.
1140 (ppc64_sysv_abi_return_value_base): Likewise.
1141 * rs6000-aix-tdep.c: Include "target-float.h".
1142 (rs6000_push_dummy_call): Use target_float_convert.
1143 (rs6000_return_value): Likewise.
1144 * rs6000-lynx178-tdep.c: Include "target-float.h".
1145 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
1146 (rs6000_lynx178_return_value): Likewise.
1147 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
1148 (rs6000_register_to_value): Use target_float_convert.
1149 (rs6000_value_to_register): Likewise.
1150 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
1151 (arm_extract_return_value): Use target_float_convert.
1152 (arm_store_return_value): Likewise.
1153 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
1154 (sh_register_convert_to_virtual): Use target_float_convert.
1155 (sh_register_convert_to_raw): Likewise.
1156 * sh64-tdep.c: Include "target-float.h".
1157 (sh64_extract_return_value): Use target_float_convert.
1158 (sh64_register_convert_to_virtual): Likewise.
1159 (sh64_register_convert_to_raw): Likewise. Fix argument types.
1160
1161 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1162
1163 * target-float.c (floatformat_to_host_double): New function.
1164 (floatformat_from_host_double): Likewise.
1165 (target_float_to_host_double): Likewise.
1166 (target_float_from_host_double): Likewise.
1167 * target-float.h (target_float_to_host_double): Add prototype.
1168 (target_float_from_host_double): Likewise.
1169
1170 * guile/scm-value.c: Include "target-float.h".
1171 (gdbscm_value_to_real): Use target_float_to_host_double.
1172 Handle integer source values via value_as_long.
1173 * guile/scm-math.c: Include "target-float.h". Do not include
1174 "doublest.h", "dfp.h", and "expression.h".
1175 (vlscm_convert_typed_number): Use target_float_from_host_double.
1176 (vlscm_convert_number): Likewise.
1177
1178 * python/py-value.c (valpy_float): Use target_float_to_host_double.
1179 (convert_value_from_python): Use target_float_from_host_double.
1180
1181 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1182
1183 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
1184 (cast_from_fixed): Likewise.
1185 (ada_scaling_type): New function.
1186 (ada_delta): Return value instead of DOUBLEST. Perform target
1187 arithmetic instead of host arithmetic.
1188 (scaling_factor): Rename to ...
1189 (ada_scaling_factor) ... this. Make non-static. Return value instead
1190 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
1191 (ada_fixed_to_float): Remove.
1192 (ada_float_to_fixed): Remove.
1193 * ada-lang.h (ada_fixed_to_float): Remove.
1194 (ada_float_to_fixed): Remove.
1195 (ada_delta): Return value instead of DOUBLEST.
1196 (ada_scaling_factor): Add prototype.
1197
1198 * ada-typeprint.c: Include "target-float.h".
1199 (print_fixed_point_type): Perform target arithmetic instead of
1200 host arithmetic.
1201 * ada-valprint.c: Include "target-float.h".
1202 (ada_val_print_num): Perform target arithmetic instead of
1203 host arithmetic for fixed-point types.
1204
1205 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1206
1207 * target-float.c: Include <math.h>.
1208 (floatformat_binop): New function.
1209 (floatformat_compare): Likewise.
1210 (target_float_binop): Likewise.
1211 (target_float_compare): Likewise.
1212 * target-float.h: Include "expression.h".
1213 (target_float_binop): Add prototype.
1214 (target_float_compare): Likewise.
1215
1216 * valarith.c: Do not include "doublest.h" and "dfp.h".
1217 Include "common/byte-vector.h".
1218 (value_args_as_decimal): Remove, replace by ...
1219 (value_args_as_target_float): ... this function. Handle both
1220 binary and decimal target floating-point formats.
1221 (scalar_binop): Handle both binary and decimal FP using
1222 value_args_as_target_float and target_float_binop.
1223 (value_equal): Handle both binary and decimal FP using
1224 value_args_as_target_float and target_float_compare.
1225 (value_less): Likewise.
1226 (value_pos): Handle all scalar types as simple copy.
1227 (value_neg): Handle all scalar types via BINOP_SUB from 0.
1228 * dfp.c (decimal_binop): Throw error instead of internal_error
1229 when called with an unsupported operation code.
1230
1231 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1232
1233 * target-float.c (target_float_to_string): New function.
1234 (target_float_from_string): New function.
1235 * target-float.h (target_float_to_string): Add prototype.
1236 (target_float_from_string): Add prototype.
1237
1238 * valprint.c: Include "target-float.h". Do not include
1239 "doublest.h" and "dfp.h".
1240 (print_floating): Use target_float_to_string.
1241 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
1242 (printf_floating): Use target_float_to_string.
1243 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
1244 (print_i387_value): Use target_float_to_string.
1245 * mips-tdep.c: Include "target-float.h".
1246 (mips_print_fp_register): Use target_float_to_string.
1247 * sh64-tdep.c: Include "target-float.h".
1248 (sh64_do_fp_register): Use target_float_to_string.
1249
1250 * parse.c: Include "target-float.h". Do not include
1251 "doublest.h" and "dfp.h".
1252 (parse_float): Use target_float_from_string.
1253 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
1254 (define_symbol): Use target_float_from_string.
1255 * gdbarch-selftests.c: Include "target-float.h".
1256 (register_to_value_test): Use target_float_from_string.
1257
1258 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1259
1260 * Makefile.c (SFILES): Add target-float.c.
1261 (HFILES_NO_SRCDIR): Add target-float.h.
1262 (COMMON_OBS): Add target-float.o.
1263 * target-float.h: New file.
1264 * target-float.c: New file.
1265
1266 * doublest.c (floatformat_classify): Fix detection of float_zero.
1267
1268 * gdbtypes.c (is_floating_type): New function.
1269 * gdbtypes.h (is_floating_type): Add prototype.
1270
1271 * value.c: Do not include "floatformat.h".
1272 (unpack_double): Use target_float_is_valid.
1273 (is_floating_value): New function.
1274 * value.h (is_floating_value): Add prototype-
1275
1276 * valarith.c: Include "target-float.h".
1277 (value_logical_not): Use target_float_is_zero.
1278
1279 * python/py-value.c: Include "target-float.h".
1280 (valpy_nonzero): Use target_float_is_zero.
1281
1282 2017-11-04 Tom Tromey <tom@tromey.com>
1283
1284 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
1285
1286 2017-11-04 Tom Tromey <tom@tromey.com>
1287
1288 * breakpoint.c (set_momentary_breakpoint): Return
1289 breakpoint_up.
1290 (until_break_command): Update.
1291 (new_until_break_fsm): Change argument types to
1292 breakpoint_up.
1293 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
1294 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
1295 Remove.
1296 * infcmd.c (finish_forward): Update.
1297 * breakpoint.h (set_momentary_breakpoint)
1298 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
1299 (make_cleanup_delete_breakpoint): Remove.
1300 (struct breakpoint_deleter): New.
1301 (breakpoint_up): New typedef.
1302 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
1303 (insert_exception_resume_breakpoint): Update.
1304 (insert_exception_resume_from_probe): Update.
1305 (insert_longjmp_resume_breakpoint): Update.
1306 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
1307 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
1308 * infcall.c (call_function_by_hand_dummy): Update
1309
1310 2017-11-04 Tom Tromey <tom@tromey.com>
1311
1312 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
1313
1314 2017-11-04 Tom Tromey <tom@tromey.com>
1315
1316 * linux-tdep.c (linux_core_info_proc_mappings): Use
1317 gdb::def_vector.
1318 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
1319 "size" argument.
1320 (linux_corefile_thread): Update.
1321 (linux_make_corefile_notes): Remove unused variable.
1322
1323 2017-11-04 Tom Tromey <tom@tromey.com>
1324
1325 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
1326 gdb::byte_vector.
1327
1328 2017-11-04 Tom Tromey <tom@tromey.com>
1329
1330 * objfiles.c (do_free_objfile_cleanup): Remove.
1331 * compile/compile-object-load.c (compile_object_load): Update.
1332 * objfiles.h (make_cleanup_free_objfile): Remove.
1333
1334 2017-11-04 Tom Tromey <tom@tromey.com>
1335
1336 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
1337 (adi_read_versions): Change "tags" to "gdb_byte *".
1338 (adi_print_versions): Likewise.
1339
1340 2017-11-04 Tom Tromey <tom@tromey.com>
1341
1342 * breakpoint.c
1343 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
1344 from start_rbreak_breakpoints.
1345 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
1346 * breakpoint.h (class scoped_rbreak_breakpoints): New.
1347 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
1348 * symtab.c (do_end_rbreak_breakpoints): Remove.
1349 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
1350
1351 2017-11-04 Tom Tromey <tom@tromey.com>
1352
1353 * cp-namespace.c (reset_directive_searched): Remove.
1354 (cp_lookup_symbol_via_imports): Use scoped_restore.
1355 * cp-support.c (reset_directive_searched): Remove.
1356 (make_symbol_overload_list_using): Use scoped_restore.
1357 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
1358 (reset_directive_searched): Remove.
1359
1360 2017-11-04 Tom Tromey <tom@tromey.com>
1361
1362 * symfile.c (find_separate_debug_file_by_debuglink): Use
1363 unique_xmalloc_ptr.
1364
1365 2017-11-04 Tom Tromey <tom@tromey.com>
1366
1367 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
1368 type of "info".
1369 (compute_stack_depth): Likewise.
1370 (do_compile_dwarf_expr_to_c): Use std::vector.
1371
1372 2017-11-04 Tom Tromey <tom@tromey.com>
1373
1374 * compile/compile-object-load.c (link_callbacks_einfo): Use
1375 std::string.
1376
1377 2017-11-04 Tom Tromey <tom@tromey.com>
1378
1379 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
1380 Use scoped_free_pendings.
1381 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
1382 scoped_free_pendings.
1383 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
1384 (xcoff_initial_scan): Likewise.
1385 * buildsym.c (reset_symtab_globals): Update comment.
1386 (scoped_free_pendings): Rename from really_free_pendings.
1387 (prepare_for_building): Update comment.
1388 (buildsym_init): Likewise.
1389 * buildsym.h (class scoped_free_pendings): New class.
1390 (really_free_pendings): Don't declare.
1391
1392 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
1393
1394 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
1395 output when converting a zero value to a special byteorder format.
1396
1397 2017-11-02 Yao Qi <yao.qi@linaro.org>
1398
1399 * frame.c (do_frame_register_read): Remove aspace.
1400 * jit.c (jit_frame_sniffer): Likwise.
1401 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
1402 * regcache.c (regcache::regcache): Pass nullptr.
1403 (regcache_print): Caller updated.
1404 * regcache.h (regcache::regcache): Remove one constructor
1405 parameter aspace.
1406
1407 2017-11-02 Yao Qi <yao.qi@linaro.org>
1408
1409 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
1410
1411 2017-11-02 Yao Qi <yao.qi@linaro.org>
1412
1413 * breakpoint.c (insert_single_step_breakpoints): Update.
1414 * frame.c (struct frame_info) <aspace>: Add const.
1415 (frame_save_as_regcache): Add const.
1416 (get_frame_address_space): Return const address_space *.
1417 * frame.h (get_frame_address_space): Update declaration.
1418 * infrun.c (struct step_over_info) <aspace>: Add const.
1419 (set_step_over_info): Make aspace const.
1420 (displaced_step_prepare_throw): Change variable const.
1421 (resume): Likewise.
1422 (proceed): Likewise.
1423 (adjust_pc_after_break): Likewise.
1424 (save_waitstatus): Likewise.
1425 (handle_signal_stop): Likewise.
1426 (keep_going_pass_signal): Likewise.
1427 * jit.c (jit_frame_sniffer): Add const.
1428 * mips-tdep.c (mips_single_step_through_delay): Likewise.
1429 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
1430 * record-full.c (record_full_wait_1): Likewise.
1431 * regcache.c (regcache::regcache): Change parameter to const.
1432 * regcache.h (regcache::regcache): Likewise.
1433 (regcache::aspace): Return const address_space *.
1434 (regcache) <m_aspace>: Add const.
1435
1436 2017-11-02 Yao Qi <yao.qi@linaro.org>
1437
1438 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
1439 * frame.c (create_sentinel_frame): Likewise.
1440 * infrun.c (displaced_step_prepare_throw): Likewise.
1441 (resume): Likewise.
1442 (thread_still_needs_step_over_bp): Likewise.
1443 (proceed): Likewise.
1444 (do_target_wait): Likewise.
1445 (adjust_pc_after_break): Likewise.
1446 (handle_syscall_event): Likewise.
1447 (save_waitstatus): Likewise.
1448 (handle_inferior_event_1): Likewise.
1449 (handle_signal_stop): Likewise.
1450 (keep_going_pass_signal): Likewise.
1451 * linux-nat.c (status_callback): Likewise.
1452 (save_stop_reason): Likewise.
1453 (resume_stopped_resumed_lwps): Likewise.
1454 * record-full.c (record_full_exec_insn): Likewise.
1455 (record_full_wait_1): Likewise.
1456 * regcache.c (get_regcache_aspace): Remove.
1457 * regcache.h (get_regcache_aspace): Remove.
1458
1459 2017-11-02 Yao Qi <yao.qi@linaro.org>
1460
1461 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
1462 (init_regcache_descr): Use gdbarch_num_regs.
1463 (regcache::regcache): Likewise.
1464 (regcache::get_register_status): Likewise.
1465 (regcache::assert_raw_regnum): Likewise.
1466 (regcache::cooked_read): Likewise.
1467 (regcache::cooked_read_value): Likewise.
1468 (regcache::cooked_write): Likewise.
1469 (regcache::dump): Likewise.
1470 (regcache::num_raw_registers): New method.
1471 * regcache.h (class regcache) <num_raw_registers>: New.
1472
1473 2017-11-02 Yao Qi <yao.qi@linaro.org>
1474
1475 * regcache.c (regcache::assert_regnum): New method.
1476 (regcache::invalidate): Call assert_regnum.
1477 (regcache::raw_update): Likewise.
1478 (regcache::raw_write): Likewise.
1479 (regcache::raw_read_part): Likewise.
1480 (regcache::raw_write_part): Likewise.
1481 (regcache::raw_supply): Likewise.
1482 (regcache::raw_supply_integer): Likewise.
1483 (regcache::raw_supply_zeroed): Likewise.
1484 (regcache::raw_collect): Likewise.
1485 (regcache::raw_collect_integer): Likewise.
1486 * regcache.h (regcache::assert_regnum): Declare.
1487
1488 2017-11-02 Yao Qi <yao.qi@linaro.org>
1489
1490 * regcache.c (regcache::dump): Remove code.
1491
1492 2017-11-02 Yao Qi <yao.qi@linaro.org>
1493
1494 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
1495 Remove.
1496 <sizeof_cooked_register_status>: Remove.
1497 (init_regcache_descr): Update.
1498 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
1499 (regcache::save): Likewise.
1500 (regcache::dump): Likewise.
1501
1502 2017-11-01 James Bowman <james.bowman@ftdichip.com>
1503
1504 * ft32-tdep.c (ft32_fetch_instruction): New function.
1505 (ft32_analyze_prologue): Use ft32_fetch_instruction().
1506
1507 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
1508
1509 * cli/cli-script.c (execute_control_command): Rename to ...
1510 (execute_control_command_1): ... this.
1511 (execute_control_command): New function.
1512
1513 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
1514
1515 * tracepoint.c (tfind_command): Remove const_cast.
1516
1517 2017-10-30 Mike Gulick <mgulick@mathworks.com>
1518
1519 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
1520
1521 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
1522
1523 * common/common-utils.h (in_inclusive_range): New function.
1524 * arm-tdep.c (arm_record_extension_space): Use
1525 in_inclusive_range.
1526 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
1527 * cris-tdep.c (cris_spec_reg_applicable): Use
1528 in_inclusive_range.
1529
1530 2017-10-30 Pedro Alves <palves@redhat.com>
1531 Simon Marchi <simon.marchi@ericsson.com>
1532
1533 * remote.c (remote_set_syscall_catchpoint): Build a std::string
1534 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
1535
1536 2017-10-30 Pedro Alves <palves@redhat.com>
1537
1538 * common/common-utils.c (string_appendf, string_vappendf): New
1539 functions.
1540 * common/common-utils.h (string_appendf, string_vappendf): New
1541 declarations.
1542 * unittests/common-utils-selftests.c (string_appendf_func)
1543 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
1544 (string_vappendf_tests): New functions.
1545 (_initialize_common_utils_selftests): Register "string_appendf" and
1546 "string_vappendf tests".
1547
1548 2017-10-30 Pedro Alves <palves@redhat.com>
1549
1550 * unittests/common-utils-selftests.c (format_func): New typedef.
1551 (string_printf_tests, string_vprintf_tests): Tests factored out
1552 and merged to ...
1553 (test_format_func): ... this new function.
1554 (string_printf_tests, string_vprintf_tests): Reimplement on top of
1555 test_format_func.
1556
1557 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1558
1559 * darwin-nat.c: Remove include of gdb.h.
1560
1561 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1562
1563 * xtensa-xtregs.c: Fix formatting issues.
1564
1565 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1566
1567 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
1568
1569 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
1570
1571 PR python/21213
1572 * python/py-infthread.c (thpy_get_inferior): Increment reference
1573 of inferior before returning it.
1574
1575 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1576
1577 * unittests/common-utils-selftests.c (format): Add
1578 ATTRIBUTE_PRINTF.
1579
1580 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
1581
1582 * xml-syscall.c (struct syscall_desc): Add constructor.
1583 <name>: Change type to std::string.
1584 (syscall_desc_up): New typedef.
1585 (syscall_desc_p): Remove typeder.
1586 (DEF_VEC_P(syscall_desc_p)): Remove.
1587 (struct syscall_group_desc): Add constructor.
1588 <name>: Change type to std::string.
1589 <syscalls>: Change type to std::vector.
1590 (syscall_group_desc_up): New typedef.
1591 (syscall_group_desc_p): Remove typedef.
1592 (DEF_VEC_P(syscall_group_desc_p)): Remove.
1593 (struct syscalls_info) <syscalls>: Change type to std::vector of
1594 unique_ptr.
1595 <groups>: Likewise.
1596 <my_gdb_datadir>: Change type to std::string.
1597 (syscalls_info_up): New typedef.
1598 (allocate_syscalls_info): Remove.
1599 (syscalls_info_free_syscalls_desc): Remove.
1600 (syscalls_info_free_syscall_group_desc): Remove.
1601 (free_syscalls_info): Remove.
1602 (make_cleanup_free_syscalls_info): Remove.
1603 (syscall_group_create_syscall_group_desc): Adjust.
1604 (syscall_group_add_syscall): Adjust.
1605 (syscall_create_syscall_desc): Adjust.
1606 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
1607 (init_syscalls_info): Adjust.
1608 (syscall_group_get_group_by_name): Adjust.
1609 (xml_get_syscall_number): Adjust.
1610 (xml_get_syscall_name): Adjust.
1611 (xml_list_of_syscalls): Adjust.
1612 (xml_list_syscalls_by_group): Adjust.
1613 (xml_list_of_groups): Adjust.
1614
1615 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1616
1617 * probe.h: Don't include gdb_vecs.h.
1618 (DEF_VEC_P (probe_p)): Remove.
1619 (find_probes_in_objfile): Return an std::vector.
1620 * probe.c (find_probes_in_objfile): Likewise.
1621 * breakpoint.c (breakpoint_objfile_data)
1622 <longjmp_probes>: Change type to std::vector.
1623 <exception_probes>: Likewise.
1624 (free_breakpoint_probes): Don't manually free vectors.
1625 (create_longjmp_master_breakpoint): Adjust.
1626 (create_exception_master_breakpoint): Adjust.
1627 * solib-svr4.c (svr4_create_probe_breakpoints): Change
1628 parameter type, adjust.
1629 (svr4_create_solib_event_breakpoints): Adjust.
1630
1631 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1632
1633 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
1634 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
1635 with new.
1636 (free_breakpoint_probes): Rename to ...
1637 (free_breakpoint_objfile_data): ... this, and call delete on
1638 bp_objfile_data..
1639
1640 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
1641
1642 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
1643 (loaded_script_ptr): Remove typedef.
1644 (DEF_VEC_P (loaded_script_ptr)): Remove.
1645 (struct collect_matching_scripts_data): Add constructor.
1646 <scripts_p>: Change type to (pointer to) std::vector.
1647 (collect_matching_scripts_data): Adjust.
1648 (sort_scripts_by_name): Make suitable for std::sort.
1649 (print_scripts): Don't sort vector, adjust to std::vector.
1650 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
1651
1652 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1653
1654 * symfile.c (filename_language): Make struct, not typedef. Add
1655 constructor.
1656 <ext>: Change type to std::string.
1657 (DEF_VEC_O (filename_language)): Remove.
1658 (filename_language_table): Change type to std::vector.
1659 (add_filename_language): Adjust.
1660 (set_ext_lang_command): Adjust.
1661 (info_ext_lang_command): Adjust.
1662 (deduce_language_from_filename): Adjust.
1663 (class scoped_restore_filename_language_table): Remove.
1664 (test_filename_language): Use scoped_restore.
1665 (test_set_ext_lang_command): Use scoped_restore, adjust to
1666 std::vector change.
1667
1668 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1669
1670 * symfile.c: Include selftest.h.
1671 (class scoped_restore_filename_language_table): New.
1672 (test_filename_language): New test.
1673 (test_set_ext_lang_command): New test.
1674 (_initialize_symfile): Register tests.
1675
1676 2017-10-27 Keith Seitz <keiths@redhat.com>
1677
1678 * breakpoint.c (print_breakpoint_location): Use the symbol saved
1679 in the bp_location, falling back to find_pc_sect_function when
1680 needed.
1681 (add_location_to_breakpoint): Save sal->symbol.
1682 * breakpoint.h (struct bp_location) <symbol>: New field.
1683 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
1684 * symtab.h (struct symtab_and_line) <symbol>: New field.
1685
1686 2017-10-26 Patrick Frants <osscontribute@gmail.com>
1687
1688 PR gdb/13669
1689 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
1690 to rewind obstack.
1691
1692 2017-10-26 Pedro Alves <palves@redhat.com>
1693
1694 * remote.c (remote_async_terminal_ours_p): Delete.
1695 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
1696 Remove references to 'remote_async_terminal_ours_p'.
1697
1698 2017-10-26 Yao Qi <yao.qi@linaro.org>
1699
1700 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
1701
1702 2017-10-26 Yao Qi <yao.qi@linaro.org>
1703
1704 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
1705 aspace const.
1706 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
1707 Likewise.
1708 * breakpoint.c (bpstat_check_location): Remove cast.
1709 (breakpoint_hit_catch_fork): Make aspce const.
1710 (breakpoint_hit_catch_solib): Likewise.
1711 (breakpoint_hit_catch_exec): Likewise.
1712 (breakpoint_hit_ranged_breakpoint): Likewise.
1713 (breakpoint_hit_watchpoint): Likewise.
1714 (base_breakpoint_breakpoint_hit): Likewise.
1715 (bkpt_breakpoint_hit): Likewise.
1716 (dprintf_breakpoint_hit): Likewise.
1717 (tracepoint_breakpoint_hit): Likewise.
1718 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
1719
1720 2017-10-26 Yao Qi <yao.qi@linaro.org>
1721
1722 * breakpoint.c (breakpoint_location_address_match): Change
1723 "struct address_space *" to "const address_space".
1724 (breakpoint_location_address_range_overlap): Likewise.
1725 (breakpoint_here_p): Likewise.
1726 (breakpoint_in_range_p): Likewise.
1727 (moribund_breakpoint_here_p): Likewise.
1728 (bp_location_inserted_here_p): Likewise.
1729 (software_breakpoint_inserted_here_p): Likewise.
1730 (hardware_breakpoint_inserted_here_p): Likewise.
1731 (hardware_watchpoint_inserted_in_range): Likewise.
1732 (bpstat_check_location): Likewise.
1733 (bpstat_stop_status): Likewise.
1734 (breakpoint_address_match): Likewise.
1735 (breakpoint_address_match_range): Likewise.
1736 (breakpoint_location_address_match): Likewise.
1737 (breakpoint_location_address_range_overlap): Likewise.
1738 (insert_single_step_breakpoint): Likewise.
1739 (breakpoint_has_location_inserted_here): Likewise.
1740 (single_step_breakpoint_inserted_here_p): Likewise.
1741 (pc_at_non_inline_function): Likewise.
1742 * breakpoint.h (bpstat_stop_status): Update declaration.
1743 (breakpoint_here_p): Likewise.
1744 (breakpoint_in_range_p): Likewise.
1745 (moribund_breakpoint_here_p): Likewise.
1746 (breakpoint_inserted_here_p): Likewise.
1747 (software_breakpoint_inserted_here_p): Likewise.
1748 (hardware_breakpoint_inserted_here_p): Likewise.
1749 (breakpoint_has_location_inserted_here): Likewise.
1750 (single_step_breakpoint_inserted_here_p): Likewise.
1751 (hardware_watchpoint_inserted_in_range): Likewise.
1752 (breakpoint_address_match): Likewise.
1753 (insert_single_step_breakpoint): Likewise.
1754 (pc_at_non_inline_function): Likewise.
1755 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
1756 * record.c (record_check_stopped_by_breakpoint): Likewise.
1757 * record.h (record_check_stopped_by_breakpoint): Likewise.
1758 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
1759
1760 2017-10-25 Yao Qi <yao.qi@linaro.org>
1761
1762 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
1763 regcache->arch () instead get_regcache_arch.
1764 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
1765 Likewise.
1766 (aarch64_fbsd_store_inferior_registers): Likewise.
1767 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
1768 (store_gregs_to_thread): Likewise.
1769 (fetch_fpregs_from_thread): Likewise.
1770 (store_fpregs_to_thread): Likewise.
1771 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
1772 (aarch64_store_return_value): Likewise.
1773 (aarch64_software_single_step): Likewise.
1774 * aix-thread.c (aix_thread_wait): Likewise.
1775 (supply_reg32): Likewise.
1776 (supply_sprs64): Likewise.
1777 (supply_sprs32): Likewise.
1778 (fill_gprs64): Likewise.
1779 (fill_gprs32): Likewise.
1780 (fill_sprs64): Likewise.
1781 (fill_sprs32): Likewise.
1782 (store_regs_user_thread): Likewise.
1783 (store_regs_kernel_thread): Likewise.
1784 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
1785 (alphabsd_store_inferior_registers): Likewise.
1786 * alpha-tdep.c (alpha_extract_return_value): Likewise.
1787 (alpha_store_return_value): Likewise.
1788 (alpha_deal_with_atomic_sequence): Likewise.
1789 (alpha_next_pc): Likewise.
1790 (alpha_software_single_step): Likewise.
1791 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
1792 (amd64bsd_store_inferior_registers): Likewise.
1793 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
1794 Likewise.
1795 (amd64_linux_store_inferior_registers): Likewise.
1796 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
1797 (amd64_collect_native_gregset): Likewise.
1798 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
1799 (amd64obsd_collect_uthread): Likewise.
1800 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
1801 (amd64_collect_fpregset): Likewise.
1802 (amd64_supply_fxsave): Likewise.
1803 (amd64_supply_xsave): Likewise.
1804 (amd64_collect_fxsave): Likewise.
1805 (amd64_collect_xsave): Likewise.
1806 * arc-tdep.c (arc_write_pc): Likewise.
1807 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
1808 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
1809 (arm_fbsd_store_inferior_registers): Likewise.
1810 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
1811 (store_vfp_regs): Likewise.
1812 (arm_linux_fetch_inferior_registers): Likewise.
1813 (arm_linux_store_inferior_registers): Likewise.
1814 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
1815 (arm_linux_sigreturn_next_pc): Likewise.
1816 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
1817 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
1818 (fetch_register): Likewise.
1819 (store_register): Likewise.
1820 * arm-tdep.c (arm_is_thumb): Likewise.
1821 (displaced_in_arm_mode): Likewise.
1822 (bx_write_pc): Likewise.
1823 (arm_get_next_pcs_addr_bits_remove): Likewise.
1824 (arm_software_single_step): Likewise.
1825 (arm_extract_return_value): Likewise.
1826 (arm_store_return_value): Likewise.
1827 (arm_write_pc): Likewise.
1828 * bfin-tdep.c (bfin_extract_return_value): Likewise.
1829 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
1830 (bsd_uthread_store_registers): Likewise.
1831 * core-regset.c (fetch_core_registers): Likewise.
1832 * corelow.c (get_core_registers): Likewise.
1833 * cris-tdep.c (cris_store_return_value): Likewise.
1834 (cris_extract_return_value): Likewise.
1835 (find_step_target): Likewise.
1836 (find_step_target): Likewise.
1837 (cris_software_single_step): Likewise.
1838 * ctf.c (ctf_fetch_registers): Likewise.
1839 * darwin-nat.c (cancel_breakpoint): Likewise.
1840 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
1841 * frv-tdep.c (frv_extract_return_value): Likewise.
1842 * ft32-tdep.c (ft32_store_return_value): Likewise.
1843 (ft32_extract_return_value): Likewise.
1844 * go32-nat.c (fetch_register): Likewise.
1845 (go32_fetch_registers): Likewise.
1846 (go32_store_registers): Likewise.
1847 (store_register): Likewise.
1848 * h8300-tdep.c (h8300_extract_return_value): Likewise.
1849 (h8300_store_return_value): Likewise.
1850 * hppa-linux-nat.c (fetch_register): Likewise.
1851 (store_register): Likewise.
1852 (hppa_linux_fetch_inferior_registers): Likewise.
1853 (hppa_linux_store_inferior_registers): Likewise.
1854 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
1855 (i386_darwin_store_inferior_registers): Likewise.
1856 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
1857 (gnu_store_registers): Likewise.
1858 * i386-linux-nat.c (fetch_register): Likewise.
1859 (store_register): Likewise.
1860 (supply_gregset): Likewise.
1861 (fill_gregset): Likewise.
1862 (i386_linux_fetch_inferior_registers): Likewise.
1863 (i386_linux_store_inferior_registers): Likewise.
1864 (i386_linux_resume): Likewise.
1865 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
1866 Likewise.
1867 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
1868 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
1869 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
1870 (i386obsd_collect_uthread): Likewise.
1871 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
1872 (i386_supply_gregset): Likewise.
1873 (i386_collect_gregset): Likewise.
1874 (i386_supply_fpregset): Likewise.
1875 (i386_collect_fpregset): Likewise.
1876 (i386_mpx_bd_base): Likewise.
1877 * i386-v4-nat.c (supply_fpregset): Likewise.
1878 (fill_fpregset): Likewise.
1879 * i387-tdep.c (i387_supply_fsave): Likewise.
1880 (i387_collect_fsave): Likewise.
1881 (i387_supply_fxsave): Likewise.
1882 (i387_collect_fxsave): Likewise.
1883 (i387_supply_xsave): Likewise.
1884 (i387_collect_xsave): Likewise.
1885 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
1886 (ia64_linux_store_registers): Likewise.
1887 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
1888 (ia64_extract_return_value): Likewise.
1889 (ia64_store_return_value): Likewise.
1890 (find_func_descr): Likewise.
1891 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
1892 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
1893 (inf_ptrace_store_registers): Likewise.
1894 * infrun.c (use_displaced_stepping): Likewise.
1895 (displaced_step_prepare_throw): Likewise.
1896 (resume): Likewise.
1897 (proceed): Likewise.
1898 (do_target_wait): Likewise.
1899 (adjust_pc_after_break): Likewise.
1900 (handle_inferior_event_1): Likewise.
1901 (handle_signal_stop): Likewise.
1902 (save_infcall_suspend_state): Likewise.
1903 (restore_infcall_suspend_state): Likewise.
1904 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
1905 * jit.c (jit_frame_prev_register): Likewise.
1906 * linux-nat.c (save_stop_reason): Likewise.
1907 (linux_nat_wait_1): Likewise.
1908 (resume_stopped_resumed_lwps): Likewise.
1909 * linux-record.c (record_linux_sockaddr): Likewise.
1910 (record_linux_msghdr): Likewise.
1911 (record_linux_system_call): Likewise.
1912 * linux-tdep.c (linux_collect_thread_registers): Likewise.
1913 * lm32-tdep.c (lm32_extract_return_value): Likewise.
1914 (lm32_store_return_value): Likewise.
1915 * m32c-tdep.c (m32c_read_flg): Likewise.
1916 (m32c_pseudo_register_read): Likewise.
1917 (m32c_pseudo_register_write): Likewise.
1918 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
1919 (m32r_linux_collect_gregset): Likewise.
1920 * m32r-tdep.c (m32r_store_return_value): Likewise.
1921 (m32r_extract_return_value): Likewise.
1922 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
1923 (m68kbsd_collect_fpregset): Likewise.
1924 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
1925 * m68k-linux-nat.c (fetch_register): Likewise.
1926 (old_fetch_inferior_registers): Likewise.
1927 (old_store_inferior_registers): Likewise.
1928 (store_regs): Likewise.
1929 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
1930 (m68k_svr4_store_return_value): Likewise.
1931 * m88k-tdep.c (m88k_store_arguments): Likewise.
1932 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
1933 (mi_cmd_data_write_register_values): Likewise.
1934 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
1935 (mips_fbsd_store_inferior_registers): Likewise.
1936 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
1937 (mips_fbsd_supply_gregs): Likewise.
1938 (mips_fbsd_collect_fpregs): Likewise.
1939 (mips_fbsd_collect_gregs): Likewise.
1940 (mips_fbsd_supply_fpregset): Likewise.
1941 (mips_fbsd_collect_fpregset): Likewise.
1942 (mips_fbsd_supply_gregset): Likewise.
1943 (mips_fbsd_collect_gregset): Likewise.
1944 * mips-linux-nat.c (supply_gregset): Likewise.
1945 (fill_gregset): Likewise.
1946 (supply_fpregset): Likewise.
1947 (fill_fpregset): Likewise.
1948 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
1949 (mips_fill_gregset): Likewise.
1950 (mips_supply_fpregset): Likewise.
1951 (mips_fill_fpregset): Likewise.
1952 (mips64_supply_gregset): Likewise.
1953 (micromips_linux_sigframe_validate): Likewise.
1954 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
1955 (mipsnbsd_fetch_inferior_registers): Likewise.
1956 (mipsnbsd_store_inferior_registers): Likewise.
1957 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
1958 (mipsnbsd_supply_gregset): Likewise.
1959 (mipsnbsd_iterate_over_regset_sections): Likewise.
1960 (mipsnbsd_supply_reg): Likewise.
1961 (mipsnbsd_supply_fpreg): Likewise.
1962 * mips-tdep.c (mips_in_frame_stub): Likewise.
1963 (mips_dummy_id): Likewise.
1964 (is_octeon_bbit_op): Likewise.
1965 (micromips_bc1_pc): Likewise.
1966 (extended_mips16_next_pc): Likewise.
1967 (mips16_next_pc): Likewise.
1968 (deal_with_atomic_sequence): Likewise.
1969 * moxie-tdep.c (moxie_process_readu): Likewise.
1970 * nios2-tdep.c (nios2_get_next_pc): Likewise.
1971 * nto-procfs.c (procfs_store_registers): Likewise.
1972 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
1973 (ppcfbsd_store_inferior_registers): Likewise.
1974 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
1975 (fetch_altivec_register): Likewise.
1976 (get_spe_registers): Likewise.
1977 (fetch_spe_register): Likewise.
1978 (fetch_altivec_registers): Likewise.
1979 (fetch_all_gp_regs): Likewise.
1980 (fetch_all_fp_regs): Likewise.
1981 (store_vsx_register): Likewise.
1982 (store_altivec_register): Likewise.
1983 (set_spe_registers): Likewise.
1984 (store_spe_register): Likewise.
1985 (store_altivec_registers): Likewise.
1986 (store_all_gp_regs): Likewise.
1987 (store_all_fp_regs): Likewise.
1988 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
1989 (ppc_linux_collect_gregset): Likewise.
1990 (ppc_canonicalize_syscall): Likewise.
1991 (ppc_linux_record_signal): Likewise.
1992 (ppu2spu_prev_register): Likewise.
1993 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
1994 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
1995 (ppcobsd_store_registers): Likewise.
1996 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
1997 Likewise.
1998 (ppc_ravenscar_generic_store_registers): Likewise.
1999 * procfs.c (procfs_fetch_registers): Likewise.
2000 (procfs_store_registers): Likewise.
2001 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
2002 (ravenscar_store_registers): Likewise.
2003 (ravenscar_prepare_to_store): Likewise.
2004 * record-btrace.c (record_btrace_fetch_registers): Likewise.
2005 * record-full.c (record_full_wait_1): Likewise.
2006 (record_full_registers_change): Likewise.
2007 (record_full_store_registers): Likewise.
2008 (record_full_core_fetch_registers): Likewise.
2009 (record_full_save): Likewise.
2010 (record_full_goto_insn): Likewise.
2011 * regcache.c (regcache_register_size): Likewise.
2012 (get_regcache_arch): Remove.
2013 (regcache_read_pc): Likewise.
2014 * regcache.h (get_regcache_arch): Remove.
2015 * remote-sim.c (gdbsim_fetch_register): Likewise.
2016 (gdbsim_store_register): Likewise.
2017 * remote.c (fetch_register_using_p): Likewise.
2018 (send_g_packet): Likewise.
2019 (remote_prepare_to_store): Likewise.
2020 (store_registers_using_G): Likewise.
2021 * reverse.c (save_bookmark_command): Likewise.
2022 (goto_bookmark_command): Likewise.
2023 * rs6000-aix-tdep.c (branch_dest): Likewise.
2024 * rs6000-nat.c (rs6000_ptrace64): Likewise.
2025 (fetch_register): Likewise.
2026 * rs6000-tdep.c (ppc_supply_reg): Likewise.
2027 (ppc_collect_reg): Likewise.
2028 (ppc_collect_gregset): Likewise.
2029 (ppc_collect_fpregset): Likewise.
2030 (ppc_collect_vsxregset): Likewise.
2031 (ppc_collect_vrregset): Likewise.
2032 (ppc_displaced_step_hw_singlestep): Likewise.
2033 (rs6000_pseudo_register_read): Likewise.
2034 (rs6000_pseudo_register_write): Likewise.
2035 * s390-linux-nat.c (supply_gregset): Likewise.
2036 (fill_gregset): Likewise.
2037 (s390_linux_fetch_inferior_registers): Likewise.
2038 * s390-linux-tdep.c (s390_write_pc): Likewise.
2039 (s390_software_single_step): Likewise.
2040 (s390_all_but_pc_registers_record): Likewise.
2041 (s390_linux_syscall_record): Likewise.
2042 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
2043 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
2044 (shnbsd_store_inferior_registers): Likewise.
2045 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
2046 (sh_extract_return_value_fpu): Likewise.
2047 (sh_store_return_value_nofpu): Likewise.
2048 (sh_corefile_supply_regset): Likewise.
2049 (sh_corefile_collect_regset): Likewise.
2050 * sh64-tdep.c (sh64_extract_return_value): Likewise.
2051 (sh64_store_return_value): Likewise.
2052 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
2053 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
2054 (sparc_store_inferior_registers): Likewise.
2055 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
2056 (sparc_ravenscar_prepare_to_store): Likewise.
2057 * sparc-tdep.c (sparc32_store_arguments): Likewise.
2058 (sparc_analyze_control_transfer): Likewise.
2059 (sparc_step_trap): Likewise.
2060 (sparc_software_single_step): Likewise.
2061 (sparc32_gdbarch_init): Likewise.
2062 (sparc_supply_rwindow): Likewise.
2063 (sparc_collect_rwindow): Likewise.
2064 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
2065 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
2066 (sparc64nbsd_collect_gregset): Likewise.
2067 (sparc64nbsd_supply_fpregset): Likewise.
2068 (sparc64nbsd_collect_fpregset): Likewise.
2069 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
2070 (sparc64_supply_gregset): Likewise.
2071 (sparc64_collect_gregset): Likewise.
2072 (sparc64_supply_fpregset): Likewise.
2073 (sparc64_collect_fpregset): Likewise.
2074 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
2075 * spu-tdep.c (spu_unwind_sp): Likewise.
2076 (spu2ppu_prev_register): Likewise.
2077 (spu_memory_remove_breakpoint): Likewise.
2078 * stack.c (return_command): Likewise.
2079 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
2080 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
2081 * tracefile.c (trace_save_ctf): Likewise.
2082 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
2083 (do_windows_store_inferior_registers): Likewise.
2084 (windows_resume): Likewise.
2085 * xtensa-linux-nat.c (fill_gregset): Likewise.
2086 (supply_gregset_reg): Likewise.
2087 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
2088 (xtensa_register_read_masked): Likewise.
2089 (xtensa_supply_gregset): Likewise.
2090 (xtensa_extract_return_value): Likewise.
2091 (xtensa_store_return_value): Likewise.
2092
2093 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
2094
2095 * doublest.c (floatformat_from_string): New function.
2096 * doublest.h (floatformat_from_string): Add prototype.
2097
2098 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
2099 (OP_FLOAT): ... this.
2100 * expression.h: Do not include "doublest.h".
2101 (union exp_element): Replace doubleconst and decfloatconst by
2102 new element floatconst.
2103 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
2104 (ada_evaluate_subexp): Likewise.
2105 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
2106 OP_DOUBLE and OP_DECFLOAT.
2107 * expprint.c (print_subexp_standard): Likewise.
2108 (dump_subexp_body_standard): Likewise.
2109 * breakpoint.c (watchpoint_exp_is_const): Likewise.
2110
2111 * parse.c: Include "dfp.h".
2112 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
2113 (write_exp_elt_floatcst): New function.
2114 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
2115 and OP_DECFLOAT.
2116 (operator_check_standard): Likewise.
2117 (parse_float): Do not accept suffix. Take type as input. Return bool.
2118 Return target format buffer instead of host DOUBLEST.
2119 Use floatformat_from_string and decimal_from_string to parse
2120 either binary or decimal floating-point types.
2121 (parse_c_float): Remove.
2122 * parser-defs.h: Do not include "doublest.h".
2123 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
2124 (write_exp_elt_floatcst): Add prototype.
2125 (parse_float): Update prototype.
2126 (parse_c_float): Remove.
2127
2128 * c-exp.y: Do not include "dfp.h".
2129 (typed_val_float): Use byte buffer instead of DOUBLEST.
2130 (typed_val_decfloat): Remove.
2131 (DECFLOAT): Remove.
2132 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2133 (parse_number): Update to new parse_float interface.
2134 Parse suffixes and determine type before calling parse_float.
2135 Handle decimal and binary FP types the same way.
2136
2137 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2138 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
2139 (parse_number): Update to new parse_float interface.
2140 Parse suffixes and determine type before calling parse_float.
2141
2142 * f-exp.y: Replace dval by typed_val_float.
2143 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2144 (parse_number): Use parse_float instead of atof.
2145
2146 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2147 (parse_go_float): Remove.
2148 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2149 (parse_number): Call parse_float instead of parse_go_float.
2150 Parse suffixes and determine type before calling parse_float.
2151
2152 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2153 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2154 (parse_number): Update to new parse_float interface.
2155 Parse suffixes and determine type before calling parse_float.
2156
2157 * m2-exp.y: Replace dval by byte buffer val.
2158 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2159 (parse_number): Call parse_float instead of atof.
2160
2161 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2162 (lex_number): Call parse_float instead of strtod.
2163 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
2164 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
2165 Use write_exp_elt_floatcst.
2166 (unit_testing): Remove static variable.
2167 (rust_type): Do not check unit_testing.
2168 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
2169
2170 * ada-exp.y (type_float, type_double): Remove.
2171 (typed_val_float): Use byte buffer instead of DOUBLEST.
2172 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2173 * ada-lex.l (processReal): Use parse_float instead of sscanf.
2174
2175 2017-10-25 Alan Hayward <alan.hayward@arm.com>
2176
2177 * aarch64-tdep.h (enum aarch64_regnum): Remove.
2178 * arch/aarch64.h: New file.
2179
2180 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2181
2182 * dfp.h (decimal_from_string): Use const reference for argument.
2183 * dfp.c (decimal_from_string): Likewise.
2184
2185 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2186
2187 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
2188 * sh64-tdep.c (sh64_do_fp_register): Likewise.
2189 * mips-tdep.c (mips_print_fp_register): Likewise.
2190
2191 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2192
2193 * common/format.h (enum argclass): Replace decfloat_arg by
2194 dec32float_arg, dec64float_arg, and dec128float_arg.
2195 * common/format.c (parse_format_string): Update to return
2196 new decimal float argument classes.
2197
2198 * printcmd.c (printf_decfloat): Rename to ...
2199 (printf_floating): ... this. Add argclass argument, and use it
2200 instead of parsing the format string again. Add support for
2201 binary floating-point values, using floatformat_to_string.
2202 Convert value to the target format if it doesn't already match.
2203 (ui_printf): Call printf_floating instead of printf_decfloat,
2204 also for double_arg / long_double_arg. Pass argclass.
2205
2206 * dfp.c (decimal_to_string): Add format string argument.
2207 * dfp.h (decimal_to_string): Likewise.
2208
2209 * doublest.c (floatformat_to_string): Add format string argument.
2210 * doublest.h (floatformat_to_string): Likewise.
2211
2212 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2213
2214 * doublest.c (floatformat_precision): New routine.
2215 (floatformat_to_string): Likewise.
2216 * doublest.c (floatformat_to_string): Add prototype.
2217
2218 * printcmd.c (print_scalar_formatted): Only call print_floating
2219 on floating-point types.
2220 * valprint.c: Do not include "floatformat.h".
2221 (generic_val_print_decfloat): Remove.
2222 (generic_val_print): Call generic_val_print_float for both
2223 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
2224 (print_floating): Use floatformat_to_string. Handle decimal float.
2225 (print_decimal_floating): Remove, merge into floatformat_to_string.
2226 * value.h (print_decimal_floating): Remove.
2227
2228 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
2229
2230 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2231
2232 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
2233
2234 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2235
2236 * memattr.h: Don't include vec.h.
2237 (struct mem_attrib): Initialize fields.
2238 <unknown>: New static method.
2239 (struct mem_region): Add constructors, operator<, initialize
2240 fields.
2241 * memattr.c: Include algorithm.
2242 (default_mem_attrib, unknown_mem_attrib): Remove.
2243 (user_mem_region_list): New global.
2244 (target_mem_region_list, mem_region_list): Change type to
2245 std::vector<mem_region>.
2246 (mem_use_target): Now a function.
2247 (target_mem_regions_valid): Change type to bool.
2248 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
2249 (require_user_regions): Adjust.
2250 (require_target_regions): Adjust.
2251 (create_mem_region): Adjust.
2252 (lookup_mem_region): Adjust.
2253 (invalidate_target_mem_regions): Adjust.
2254 (mem_clear): Rename to...
2255 (user_mem_clear): ... this, and adjust.
2256 (mem_command): Adjust.
2257 (info_mem_command): Adjust.
2258 (mem_enable, enable_mem_command, mem_disable,
2259 disable_mem_command): Adjust.
2260 (mem_delete): Adjust.
2261 (delete_mem_command): Adjust.
2262 * memory-map.h (parse_memory_map): Return an std::vector.
2263 * memory-map.c (parse_memory_map): Likewise.
2264 (struct memory_map_parsing_data): Add constructor.
2265 <memory_map>: Point to std::vector.
2266 (memory_map_start_memory): Adjust.
2267 (memory_map_end_memory): Adjust.
2268 (memory_map_end_property): Adjust.
2269 (clear_result): Remove.
2270 * remote.c (remote_memory_map): Return an std::vector.
2271 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
2272 Remove.
2273 (target_debug_print_mem_region_vector): New.
2274 * target-delegates.c: Regenerate.
2275 * target.h (mem_region_vector): New typedef.
2276 (to_memory_map): Return mem_region_vector.
2277 (target_memory_map): Return an std::vector.
2278 * target.c (target_memory_map): Return an std::vector.
2279 (flash_erase_command): Adjust.
2280
2281 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2282
2283 * memory-map.c (struct memory_map_parsing_data) <property_name>:
2284 Change type to std::string.
2285 (memory_map_start_property): Adjust.
2286 (memory_map_end_property): Adjust.
2287
2288 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2289
2290 * infrun.h: Include common/byte-vector.h.
2291 (struct displaced_step_closure): New struct.
2292 (struct buf_displaced_step_closure): New struct.
2293 * infrun.c (displaced_step_closure::~displaced_step_closure):
2294 Provide default implementation.
2295 (displaced_step_clear): Deallocate step closure with delete.
2296 * aarch64-tdep.c (displaced_step_closure): Rename to ...
2297 (aarch64_displaced_step_closure): ... this, extend
2298 displaced_step_closure.
2299 (aarch64_displaced_step_data) <dsc>: Change type to
2300 aarch64_displaced_step_closure.
2301 (aarch64_displaced_step_copy_insn): Adjust to type change, use
2302 unique_ptr.
2303 (aarch64_displaced_step_fixup): Add cast for displaced step
2304 closure.
2305 * amd64-tdep.c (displaced_step_closure): Rename to ...
2306 (amd64_displaced_step_closure): ... this, extend
2307 displaced_step_closure.
2308 <insn_buf>: Change type to std::vector<gdb_byte>.
2309 <max_len>: Remove.
2310 (fixup_riprel): Change type of DSC parameter, adjust to type
2311 change of insn_buf.
2312 (fixup_displaced_copy): Change type of DSC parameter.
2313 (amd64_displaced_step_copy_insn): Instantiate
2314 amd64_displaced_step_closure.
2315 (amd64_displaced_step_fixup): Add cast for closure type, adjust
2316 to type change of insn_buf.
2317 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
2318 parameter DSC.
2319 (arm_linux_copy_svc): Likewise.
2320 (cleanup_kernel_helper_return): Likewise.
2321 (arm_catch_kernel_helper_return): Likewise.
2322 (arm_linux_displaced_step_copy_insn): Instantiate
2323 arm_displaced_step_closure.
2324 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
2325 (displaced_read_reg): Change type of parameter DSC.
2326 (branch_write_pc): Likewise.
2327 (load_write_pc): Likewise.
2328 (alu_write_pc): Likewise.
2329 (displaced_write_reg): Likewise.
2330 (arm_copy_unmodified): Likewise.
2331 (thumb_copy_unmodified_32bit): Likewise.
2332 (thumb_copy_unmodified_16bit): Likewise.
2333 (cleanup_preload): Likewise.
2334 (install_preload): Likewise.
2335 (arm_copy_preload): Likewise.
2336 (thumb2_copy_preload): Likewise.
2337 (install_preload_reg): Likewise.
2338 (arm_copy_preload_reg): Likewise.
2339 (cleanup_copro_load_store): Likewise.
2340 (install_copro_load_store): Likewise.
2341 (arm_copy_copro_load_store) Likewise.
2342 (thumb2_copy_copro_load_store): Likewise.
2343 (cleanup_branch): Likewise.
2344 (install_b_bl_blx): Likewise.
2345 (arm_copy_b_bl_blx): Likewise.
2346 (thumb2_copy_b_bl_blx): Likewise.
2347 (thumb_copy_b): Likewise.
2348 (install_bx_blx_reg): Likewise.
2349 (arm_copy_bx_blx_reg): Likewise.
2350 (thumb_copy_bx_blx_reg): Likewise.
2351 (cleanup_alu_imm): Likewise.
2352 (arm_copy_alu_imm): Likewise.
2353 (thumb2_copy_alu_imm): Likewise.
2354 (cleanup_alu_reg): Likewise.
2355 (install_alu_reg): Likewise.
2356 (arm_copy_alu_reg): Likewise.
2357 (thumb_copy_alu_reg): Likewise.
2358 (cleanup_alu_shifted_reg): Likewise.
2359 (install_alu_shifted_reg): Likewise.
2360 (arm_copy_alu_shifted_reg): Likewise.
2361 (cleanup_load): Likewise.
2362 (cleanup_store): Likewise.
2363 (arm_copy_extra_ld_st): Likewise.
2364 (install_load_store): Likewise.
2365 (thumb2_copy_load_literal): Likewise.
2366 (thumb2_copy_load_reg_imm): Likewise.
2367 (arm_copy_ldr_str_ldrb_strb): Likewise.
2368 (cleanup_block_load_all): Likewise.
2369 (cleanup_block_store_pc): Likewise.
2370 (cleanup_block_load_pc): Likewise.
2371 (arm_copy_block_xfer): Likewise.
2372 (thumb2_copy_block_xfer): Likewise.
2373 (cleanup_svc): Likewise.
2374 (install_svc): Likewise.
2375 (arm_copy_svc): Likewise.
2376 (thumb_copy_svc): Likewise.
2377 (arm_copy_undef): Likewise.
2378 (thumb_32bit_copy_undef): Likewise.
2379 (arm_copy_unpred): Likewise.
2380 (arm_decode_misc_memhint_neon): Likewise.
2381 (arm_decode_unconditional): Likewise.
2382 (arm_decode_miscellaneous): Likewise.
2383 (arm_decode_dp_misc): Likewise.
2384 (arm_decode_ld_st_word_ubyte): Likewise.
2385 (arm_decode_media): Likewise.
2386 (arm_decode_b_bl_ldmstm): Likewise.
2387 (arm_decode_ext_reg_ld_st): Likewise.
2388 (thumb2_decode_dp_shift_reg): Likewise.
2389 (thumb2_decode_ext_reg_ld_st): Likewise.
2390 (arm_decode_svc_copro): Likewise.
2391 (thumb2_decode_svc_copro): Likewise.
2392 (install_pc_relative): Likewise.
2393 (thumb_copy_pc_relative_16bit): Likewise.
2394 (thumb_decode_pc_relative_16bit): Likewise.
2395 (thumb_copy_pc_relative_32bit): Likewise.
2396 (thumb_copy_16bit_ldr_literal): Likewise.
2397 (thumb_copy_cbnz_cbz): Likewise.
2398 (thumb2_copy_table_branch): Likewise.
2399 (cleanup_pop_pc_16bit_all): Likewise.
2400 (thumb_copy_pop_pc_16bit): Likewise.
2401 (thumb_process_displaced_16bit_insn): Likewise.
2402 (decode_thumb_32bit_ld_mem_hints): Likewise.
2403 (thumb_process_displaced_32bit_insn): Likewise.
2404 (thumb_process_displaced_insn): Likewise.
2405 (arm_process_displaced_insn): Likewise.
2406 (arm_displaced_init_closure): Likewise.
2407 (arm_displaced_step_fixup): Add cast for closure.
2408 * arm-tdep.h: Include infrun.h.
2409 (displaced_step_closure): Rename to ...
2410 (arm_displaced_step_closure): ... this, extend
2411 displaced_step_closure.
2412 <u::svc::copy_svc_os>: Change type of parameter DSC.
2413 <cleanup>: Likewise.
2414 (arm_process_displaced_insn): Likewise.
2415 (arm_displaced_init_closure): Likewise.
2416 (displaced_read_reg): Likewise.
2417 (displaced_write_reg): Likewise.
2418 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
2419 Adjust.
2420 * i386-tdep.h: Include infrun.h.
2421 (i386_displaced_step_closure): New typedef.
2422 * i386-tdep.c (i386_displaced_step_copy_insn): Use
2423 i386_displaced_step_closure.
2424 (i386_displaced_step_fixup): Adjust.
2425 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
2426 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
2427 and unique_ptr.
2428 (ppc_displaced_step_fixup): Adjust.
2429 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
2430 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
2431 and unique_ptr.
2432 (s390_displaced_step_fixup): Adjust.
2433
2434 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2435
2436 * interps.h (interp_resume, interp_suspend, interp_set_temp):
2437 Remove declarations.
2438
2439 2017-10-20 Tom Tromey <tom@tromey.com>
2440
2441 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
2442 std::vector.
2443 (gdb_bfd_record_inclusion): Update.
2444 (bfdp): Remove typedef.
2445
2446 2017-10-20 Tom Tromey <tom@tromey.com>
2447
2448 * gdb_bfd.c (gdb_bfd_ref): Use new.
2449 (struct gdb_bfd_data): Add constructor, destructor, and member
2450 initializers.
2451 (gdb_bfd_unref): Use delete.
2452
2453 2017-10-20 Tom Tromey <tom@tromey.com>
2454
2455 * exec.c (exec_file_attach): Use new_bfd_ref.
2456 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
2457 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
2458 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
2459 new_bfd_ref.
2460 * gdb_bfd.h (new_bfd_ref): New function.
2461
2462 2017-10-20 Pedro Alves <palves@redhat.com>
2463
2464 * main.c (captured_command_loop): Add attribute noinline.
2465
2466 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
2467
2468 * interps.c (struct interp_factory): Add constructor.
2469 (interp_factory_p): Remove typedef.
2470 (DEF_VEC_P(interp_factory_p)): Remove.
2471 (interpreter_factories): Change type to std::vector.
2472 (interp_factory_register): Adjust.
2473 (interp_lookup): Adjust.
2474 (interpreter_completer): Adjust.
2475
2476 2017-10-19 Tom Tromey <tom@tromey.com>
2477
2478 * break-catch-syscall.c (catch_syscall_completer): Use
2479 std::string, gdb::unique_xmalloc_ptr.
2480
2481 2017-10-19 Tom Tromey <tom@tromey.com>
2482
2483 * infcall.c (call_function_by_hand_dummy): Use std::string.
2484
2485 2017-10-19 Tom Tromey <tom@tromey.com>
2486
2487 * mi/mi-main.c (mi_cmd_execute): Update.
2488 * top.h (prepare_execute_command): Return scoped_value_mark.
2489 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
2490 Add move constructor.
2491 * top.c (prepare_execute_command): Return scoped_value_mark.
2492 (execute_command): Update.
2493
2494 2017-10-19 Pedro Alves <palves@redhat.com>
2495
2496 * xml-support.c (xml_fetch_content_from_file): Check fread's
2497 return.
2498
2499 2017-10-19 Pedro Alves <palves@redhat.com>
2500
2501 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
2502 async.
2503 (handle_error_fd): New function.
2504 (ser_base_async): Add/delete an event loop file handler for
2505 error_fd.
2506
2507 2017-10-19 Pedro Alves <palves@redhat.com>
2508
2509 * xml-support.c (xml_fetch_content_from_file): Don't read in
2510 chunks. Instead use fseek to determine the file's size, and read
2511 it in one go.
2512
2513 2017-11-18 Keith Seitz <keiths@redhat.com>
2514
2515 * c-exp.y (oper): Canonicalize conversion operators of user-defined
2516 types.
2517 Add whitespace to front of type name.
2518
2519 2017-10-18 Keith Seitz <keiths@redhat.com>
2520
2521 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
2522 DW_AT_accessibility.
2523
2524 2017-10-18 Yao Qi <yao.qi@linaro.org>
2525
2526 * features/tic6x-c62x-linux.c: Remove.
2527
2528 2017-10-17 Tom Tromey <tom@tromey.com>
2529
2530 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
2531 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
2532 (do_mixed_source_and_assembly): Likewise.
2533
2534 2017-10-17 Tom Tromey <tom@tromey.com>
2535
2536 * regcache.c (regcache::xfer_part): Remove assertion.
2537
2538 2017-10-17 Pedro Alves <palves@redhat.com>
2539
2540 * xml-support.c (xml_fetch_content_from_file): Call
2541 unique_ptr::release() instead unique_ptr::get() when passing
2542 through xrealloc.
2543
2544 2017-10-17 Yao Qi <yao.qi@linaro.org>
2545
2546 * regcache.c (regcache::xfer_part): Remove parameters read and
2547 write, add parameter is_raw. All callers are updated.
2548
2549 2017-10-16 Keith Seitz <keiths@redhat.com>
2550
2551 * c-typeprint.c (enum access_specifier): Moved here from
2552 c_type_print_base.
2553 (output_access_specifier): New function.
2554 (c_type_print_base): Consider typedefs when assessing
2555 whether access labels are needed.
2556 Use output_access_specifier as needed.
2557 Output access specifier for typedefs, if needed.
2558 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
2559 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
2560 fields.
2561 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
2562 accessor macros.
2563
2564 2017-10-16 Tom Tromey <tom@tromey.com>
2565
2566 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
2567 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
2568 * target.c (target_fileio_read_stralloc): Update.
2569 * sparc64-tdep.c (adi_is_addr_mapped): Update.
2570 * target.h (target_fileio_read_stralloc): Return
2571 unique_xmalloc_ptr.
2572
2573 2017-10-16 Tom Tromey <tom@tromey.com>
2574
2575 * xml-syscall.c (xml_init_syscalls_info): Update.
2576 * xml-support.c (xinclude_start_include): Update.
2577 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
2578 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
2579 (xml_fetch_content_from_file): Likewise.
2580 * osdata.c (get_osdata): Update.
2581 * target.h (target_read_stralloc, target_get_osdata): Return
2582 unique_xmalloc_ptr.
2583 * solib-aix.c (solib_aix_get_library_list): Update.
2584 * solib-target.c (solib_target_current_sos): Update.
2585 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
2586 * xml-tdesc.c (fetch_available_features_from_target): Update.
2587 (target_fetch_description_xml): Update.
2588 (file_read_description_xml): Update.
2589 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
2590 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
2591 (remote_pid_to_exec_file): Update.
2592 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
2593 (target_get_osdata): Likewise.
2594
2595 2017-10-16 Tom Tromey <tom@tromey.com>
2596
2597 * remote.c (remote_register_number_and_offset): Use std::vector.
2598 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
2599 (putpkt_binary): Use gdb::def_vector.
2600 (compare_sections_command): Use gdb::byte_vector.
2601
2602 2017-10-16 Tom Tromey <tom@tromey.com>
2603
2604 * ppc-linux-nat.c (hwdebug_insert_point): Use
2605 gdb::unique_xmalloc_ptr, XDUP.
2606
2607 2017-10-16 Tom Tromey <tom@tromey.com>
2608
2609 * probe.c (parse_probes): Use std::string.
2610 (info_probes_for_ops, enable_probes_command)
2611 (disable_probes_command): Remove cleanups.
2612
2613 2017-10-16 Tom Tromey <tom@tromey.com>
2614
2615 * buildsym.c (block_compar): Remove.
2616 (end_symtab_get_static_block): Use std::vector.
2617
2618 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
2619
2620 * memrange.h (struct mem_range): Define operator< and operator==.
2621 (mem_range_s): Remove.
2622 (DEF_VEC_O (mem_range_s)): Remove.
2623 (normalize_mem_ranges): Change parameter type to std::vector.
2624 * memrange.c (compare_mem_ranges): Remove.
2625 (normalize_mem_ranges): Change parameter type to std::vector,
2626 adjust to vector change.
2627 * exec.c (section_table_available_memory): Return vector, remove
2628 parameter.
2629 (section_table_read_available_memory): Adjust to std::vector
2630 change.
2631 * remote.c (remote_read_bytes): Adjust to std::vector
2632 change.
2633 * tracepoint.h (traceframe_available_memory): Change parameter
2634 type to std::vector.
2635 * tracepoint.c (traceframe_available_memory): Change parameter
2636 type to std::vector, adjust.
2637 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
2638 std::vector change.
2639 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2640 unittests/memrange-selftests.c.
2641 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
2642 * gdb/unittests/memrange-selftests.c: New file.
2643
2644 2017-10-16 Pedro Alves <palves@redhat.com>
2645
2646 * elfread.c (probe_key_free): Rename range-for variable.
2647 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
2648 (find_probe_by_pc, collect_probes): Rename range-for variable.
2649
2650 2017-10-16 Yao Qi <yao.qi@linaro.org>
2651
2652 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
2653 * features/tic6x-c62x.c: Remove.
2654 * features/tic6x-c64x-linux.c: Remove.
2655 * features/tic6x-c64x.c: Remove.
2656 * features/tic6x-c64xp-linux.c: Remove.
2657 * features/tic6x-c64xp.c: Remove.
2658 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
2659 initialize_tdesc_tic6x_*_linux functions.
2660 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
2661 initialize_tdesc_tic6x_* functions.
2662
2663 2017-10-16 Yao Qi <yao.qi@linaro.org>
2664
2665 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
2666 tic6x-c62x.
2667 * regformats/tic6x-c62x.dat: Remove.
2668 * regformats/tic6x-c64x.dat: Remove.
2669 * regformats/tic6x-c64xp.dat: Remove.
2670
2671 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
2672
2673 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
2674 (the !HAVE_LIBEXPAT version).
2675
2676 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2677
2678 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
2679 const.
2680
2681 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2682
2683 * target.h: Include tracepoint.h.
2684 (enum trace_find_type): Move to tracepoint.h.
2685 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
2686 * tracepoint.h: Don't include target.h
2687 (enum trace_find_type): Move from target.h.
2688 (parse_traceframe_info): Return a unique ptr.
2689 * tracepoint.c (current_traceframe_info): Change type to unique
2690 ptr.
2691 (free_traceframe_info): Remove.
2692 (clear_traceframe_info): Don't manually free
2693 current_traceframe_info.
2694 (free_result): Remove.
2695 (parse_traceframe_info): Return a unique ptr.
2696 (get_traceframe_info): Adjust to unique ptr.
2697 * ctf.c (ctf_traceframe_info): Return a unique ptr.
2698 * remote.c (remote_traceframe_info): Return a unique ptr.
2699 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
2700 ptr.
2701 * target-debug.h (target_debug_print_traceframe_info_up): New
2702 macro.
2703 * target-delegates.c: Regenerate.
2704
2705 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2706
2707 * memrange.h (struct mem_range): Add constructors.
2708 * tracepoint.h (struct traceframe_info) <memory>: Change type to
2709 std::vector<mem_range>.
2710 * tracepoint.c (free_traceframe_info): Don't manually free
2711 vector.
2712 (traceframe_info_start_memory): Adjust to vector change.
2713 (traceframe_available_memory): Likewise.
2714 * tracefile-tfile.c (build_traceframe_info): Likewise.
2715 * ctf.c (ctf_traceframe_info): Likewise.
2716
2717 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2718
2719 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
2720 std::vector<int>.
2721 * tracepoint.c (free_traceframe_info): Deallocate with delete.
2722 (traceframe_info_start_tvar): Adjust to vector change.
2723 (parse_traceframe_info): Allocate with new.
2724 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
2725 vector change.
2726 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
2727 change.
2728 tfile_traceframe_info): Allocate with new.
2729 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
2730 change.
2731
2732 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2733
2734 * tracepoint.c (traceframe_info): Rename to...
2735 (current_traceframe_info): ...this.
2736 (clear_traceframe_info): Adjust.
2737 (get_traceframe_info): Adjust.
2738
2739 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2740
2741 * nat/linux-osdata.c: Include algorithm.
2742 (compare_processes): Remove.
2743 (struct pid_pgid_entry): New struct.
2744 (linux_xfer_osdata_processgroups): Use std::vector instead of
2745 XNEWVEC.
2746
2747 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2748
2749 * objfiles.h: Don't include symfile.h.
2750 (struct partial_symbol): Remove forward-declaration.
2751 (struct objfile) <global_psymbols, static_psymbols>: Change type
2752 to std::vector<partial_symbol *>.
2753 * objfiles.c (objfile::objfile): Don't memset those fields.
2754 (objfile::~objfile): Don't free those fields.
2755 * psympriv.h (struct psymbol_allocation_list): Remove
2756 forward-declaration.
2757 (add_psymbol_to_list): Change psymbol_allocation_list parameter
2758 to std::vector.
2759 (start_psymtab_common): Change parameters to std::vector.
2760 * psymtab.c: Include algorithm.
2761 (require_partial_symbols): Call shrink_to_fit.
2762 (find_pc_sect_psymbol): Adjust to vector change.
2763 (match_partial_symbol): Likewise.
2764 (lookup_partial_symbol): Likewise.
2765 (psym_relocate): Likewise.
2766 (dump_psymtab): Likewise.
2767 (recursively_search_psymtabs): Likewise.
2768 (compare_psymbols): Remove.
2769 (sort_pst_symbols): Adjust to vector change.
2770 (start_psymtab_common): Likewise.
2771 (end_psymtab_common): Likewise.
2772 (psymbol_bcache_full): De-constify return value.
2773 (add_psymbol_to_bcache): Likewise.
2774 (extend_psymbol_list): Remove.
2775 (append_psymbol_to_list): Adjust to vector change.
2776 (add_psymbol_to_list): Likewise.
2777 (init_psymbol_list): Likewise.
2778 (maintenance_info_psymtabs): Likewise.
2779 (maintenance_check_psymtabs): Likewise.
2780 * symfile.h (struct psymbol_allocation_list): Remove.
2781 * symfile.c (reread_symbols): Adjust to vector change.
2782 * dbxread.c (start_psymtab): Change type of parameters.
2783 (dbx_symfile_read): Adjust to vector change.
2784 (read_dbx_symtab): Likewise.
2785 (start_psymtab): Change type of parameters.
2786 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
2787 (create_partial_symtab): Likewise.
2788 (add_partial_symbol): Likewise.
2789 (write_one_signatured_type): Likewise.
2790 (recursively_write_psymbols): Likewise.
2791 * mdebugread.c (parse_partial_symbols): Likewise.
2792 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
2793 (scan_xcoff_symtab): Adjust to vector change.
2794 (xcoff_initial_scan): Likewise.
2795
2796 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
2797
2798 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
2799
2800 2017-10-13 Yao Qi <yao.qi@linaro.org>
2801
2802 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
2803 Remove s390x-*-expedite, add s390x-expedite.
2804
2805 2017-10-13 Yao Qi <yao.qi@linaro.org>
2806
2807 * features/s390-gs-linux64.c: Regenerated.
2808 * features/s390x-gs-linux64.c: Regenerated.
2809
2810 2017-10-13 Tom Tromey <tom@tromey.com>
2811
2812 * compile/compile-object-run.c (do_module_cleanup): Use delete.
2813 * solib.c (update_solib_list, reload_shared_libraries_1): Use
2814 delete.
2815 * symfile.c (symbol_file_add_with_addrs): Use new.
2816 (symbol_file_add_separate): Update comment.
2817 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
2818 * jit.c (jit_object_close_impl): Use new.
2819 (jit_unregister_code): Use delete.
2820 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
2821 (~objfile): Rename from free_objfile.
2822 (free_objfile_separate_debug, do_free_objfile_cleanup)
2823 (free_all_objfiles, objfile_purge_solibs): Use delete.
2824 * objfiles.h (struct objfile): Add constructor and destructor.
2825 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
2826 (allocate_objfile, free_objfile): Don't declare.
2827 (struct objstats): Add initializers.
2828
2829 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2830
2831 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
2832 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
2833 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
2834 * gdbarch.h: Regenerate.
2835 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
2836 Adjust comment.
2837 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
2838 (i386_displaced_step_fixup): Adjust comment.
2839 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
2840
2841 2017-10-12 Tom Tromey <tom@tromey.com>
2842
2843 * prologue-value.h (pv_area::store_would_trash): Return bool.
2844 (pv_area::find_reg): Likewise.
2845 * prologue-value.c (pv_area::store_would_trash): Return bool.
2846 (pv_area::find_reg): Likewise.
2847
2848 2017-10-12 Tom Tromey <tom@tromey.com>
2849
2850 * s390-linux-tdep.c (s390_store, s390_load)
2851 (s390_check_for_saved, s390_analyze_prologue): Update.
2852 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
2853 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
2854 * prologue-value.h (class pv_area): Move from prologue-value.c.
2855 Change names of members. Add constructor, destructor, member
2856 functions.
2857 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
2858 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
2859 (pv_area_fetch, pv_area_scan): Don't declare.
2860 * prologue-value.c (struct pv_area::area_entry): Now member of
2861 pv_area.
2862 (struct pv_area): Move to prologue-value.h.
2863 (pv_area::pv_area): Rename from make_pv_area.
2864 (pv_area::~pv_area): Rename from free_pv_area.
2865 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
2866 (clear_entries, find_entry, overlaps, store_would_trash, store)
2867 (fetch, find_reg, scan): Now member of pv_area.
2868 Remove "area" argument. Update.
2869 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
2870 Update.
2871 * mn10300-tdep.c (push_reg, check_for_saved)
2872 (mn10300_analyze_prologue): Update.
2873 * mep-tdep.c (is_arg_spill, check_for_saved)
2874 (mep_analyze_prologue): Update.
2875 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
2876 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
2877 (m32c_is_struct_return, m32c_analyze_prologue): Update.
2878 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
2879 Update.
2880 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
2881 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
2882
2883 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2884
2885 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
2886 * linux-nat.c (linux_nat_delete_thread): New variable.
2887 (lwp_free): Invoke linux_nat_delete_thread if set.
2888 (linux_nat_set_delete_thread): New function.
2889 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
2890 thread delete callback.
2891 * arm-linux-nat.c (arm_linux_delete_thread): New function.
2892 (_initialize_arm_linux_nat): Assign thread delete callback.
2893 * s390-linux-nat.c (s390_delete_thread): New function.
2894 (_initialize_s390_nat): Assign thread delete callback.
2895 * x86-linux-nat.c (x86_linux_add_target): Likewise.
2896 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
2897 function.
2898 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
2899 declaration.
2900 * nat/x86-linux.c (x86_linux_delete_thread): New function.
2901 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
2902
2903 2017-10-09 Tom Tromey <tom@tromey.com>
2904
2905 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
2906 std::string.
2907 * tui/tui-layout.c (enum tui_status): Use std::string.
2908
2909 2017-10-11 Tom Tromey <tom@tromey.com>
2910
2911 * gdbthread.h (thread_command): Constify.
2912 * inferior.h (detach_command): Constify.
2913 * top.h (set_history, show_history): Constify.
2914 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
2915 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
2916 * bsd-kvm.c (bsd_kvm_cmd): Constify.
2917 * printcmd.c (set_command): Constify.
2918 (non_const_set_command): New function.
2919 * dcache.c (set_dcache_command, show_dcache_command): Constify.
2920 * breakpoint.c (enable_command, disable_command, delete_command)
2921 (catch_command, tcatch_command, set_breakpoint_cmd)
2922 (show_breakpoint_cmd): Constify.
2923 * macrocmd.c (macro_command): Constify.
2924 * infcmd.c (unset_command, kill_command, detach_command)
2925 (info_proc_cmd): Constify.
2926 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
2927 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
2928 (info_auto_load_cmd): Constify.
2929 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
2930 (unset_tdesc_cmd): Constify.
2931 * ada-lang.c (set_ada_command, show_ada_command)
2932 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
2933 * guile/guile.c (set_guile_command, show_guile_command)
2934 (info_guile_command): Constify.
2935 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
2936 Constify.
2937 * skip.c (skip_command): Constify.
2938 * compile/compile.c (_initialize_compile): Constify.
2939 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
2940 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
2941 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
2942 (maint_btrace_pt_show_cmd): Constify.
2943 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
2944 Constify.
2945 * python/python.c (user_show_python, user_set_python): Constify.
2946 * mips-tdep.c (set_mips_command, show_mips_command)
2947 (set_mipsfpu_command): Constify.
2948 * record-btrace.c (cmd_record_btrace_start)
2949 (cmd_set_record_btrace, cmd_show_record_btrace)
2950 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
2951 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
2952 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
2953 Constify.
2954 * symfile.c (overlay_command): Constify.
2955 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
2956 * cli/cli-logging.c (set_logging_command, show_logging_command):
2957 Constify.
2958 * cli/cli-dump.c (dump_command, append_command)
2959 (srec_dump_command, ihex_dump_command, verilog_dump_command)
2960 (tekhex_dump_command, binary_dump_command)
2961 (binary_append_command): Constify.
2962 * cli/cli-decode.c (struct cmd_list_element): Change type of
2963 "fun".
2964 * cli/cli-cmds.c (info_command, show_command, set_debug)
2965 (show_debug): Constify.
2966 (show_command): Add non-const overload.
2967 * top.c (set_history, show_history): Constify.
2968 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
2969 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
2970 * target.c (target_command): Constify.
2971 * sparc64-tdep.c (info_adi_command): Constify.
2972 * record-full.c (cmd_record_full_start): Constify.
2973 (set_record_full_command): Constify. Fix typo.
2974 (show_record_full_command): Constify.
2975 * thread.c (thread_command, thread_apply_command): Constify.
2976 * memattr.c (dummy_cmd): Constify.
2977 * value.c (function_command): Constify.
2978 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
2979 * probe.c (info_probes_command): Constify.
2980 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
2981 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
2982 (show_thread_cmd, set_thread_default_cmd)
2983 (show_thread_default_cmd): Constify.
2984 (check_empty): Constify.
2985 * tracepoint.c (tfind_command): Constify.
2986 * cp-support.c (maint_cplus_command): Constify.
2987 * windows-tdep.c (info_w32_command): Constify.
2988 * record.c (cmd_record_start, set_record_command)
2989 (show_record_command, info_record_command, cmd_record_goto):
2990 Constify.
2991 * ravenscar-thread.c (set_ravenscar_command)
2992 (show_ravenscar_command): Constify.
2993 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
2994 Constify.
2995 (add_internal_problem_command): Remove casts.
2996 * arc-tdep.c (maintenance_print_arc_command): Constify.
2997 * valprint.c (set_print, show_print, set_print_raw)
2998 (show_print_raw): Constify.
2999 * maint.c (maintenance_command, maintenance_info_command)
3000 (maintenance_print_command, maintenance_set_cmd)
3001 (maintenance_show_cmd, set_per_command_cmd)
3002 (show_per_command_cmd, maintenance_check_command): Constify.
3003 * language.c (set_check, show_check): Constify.
3004 * typeprint.c (show_print_type, set_print_type): Constify.
3005 * go32-nat.c (go32_info_dos_command): Constify.
3006
3007 2017-10-11 Tom Tromey <tom@tromey.com>
3008
3009 * breakpoint.c (prepare_re_set_context): Remove.
3010 (breakpoint_re_set_one): Update. Don't use cleanups.
3011 (breakpoint_re_set): Use scoped_restore, std::string, and
3012 scoped_restore_current_language.
3013
3014 2017-10-11 Tom Tromey <tom@tromey.com>
3015
3016 * breakpoint.c (commands_command_1): Use std::string.
3017 (cleanup_executing_breakpoints): Remove.
3018 (bpstat_do_actions_1): Use scoped_restore.
3019 (bpstat_check_watchpoint): Use std::string.
3020 (decode_static_tracepoint_spec): Likewise.
3021 (break_range_command): Likewise.
3022 (watch_command_1): Likewise.
3023 (compare_breakpoints): Change argument types.
3024 (clear_command): Use std::vector.
3025 (cleanup_executing_breakpoints): Remove.
3026 (update_global_location_list): Use unique_xmalloc_ptr.
3027 (strace_command): Remove unused declaration.
3028
3029 2017-10-11 John Baldwin <jhb@FreeBSD.org>
3030
3031 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
3032 * NEWS: Mention new FreeBSD/arm native configuration.
3033 * configure.host: Add arm*-*-freebsd*.
3034 * configure.nat: Likewise.
3035 * arm-fbsd-nat.c: New file.
3036
3037 2017-10-11 John Baldwin <jhb@FreeBSD.org>
3038
3039 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
3040 (ALLDEPFILES): Add arm-fbsd-tdep.c.
3041 * NEWS: Mention new FreeBSD/arm target.
3042 * configure.tgt: Add arm*-*-freebsd*.
3043 * arm-fbsd-tdep.c: New file.
3044 * arm-fbsd-tdep.h: New file.
3045
3046 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
3047
3048 * linux-tdep.c (linux_make_corefile_notes): Remove call to
3049 `gdbarch_elfcore_write_linux_prpsinfo'.
3050 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
3051 method.
3052 (elf_internal_linux_prpsinfo): Remove declaration.
3053 * gdbarch.h: Regenerate.
3054 * gdbarch.c: Regenerate.
3055
3056 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
3057
3058 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
3059 `set_gdbarch_elfcore_write_linux_prpsinfo'.
3060
3061 2017-10-11 Pedro Alves <palves@redhat.com>
3062
3063 * breakpoint.c (reattach_breakpoints): Delete.
3064 * breakpoint.h (reattach_breakpoints): Delete.
3065
3066 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
3067
3068 * symfile.c (registered_sym_fns): Make struct, not typedef.
3069 (DEF_VEC_O (registered_sym_fns)): Remove.
3070 (symtab_fns): Change type to std::vector.
3071 (add_symtab_fns): Adjust.
3072 (find_sym_fns): Adjust.
3073
3074 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
3075
3076 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
3077 * arc-tdep.h (arc_arch_is_em): New function.
3078 (arc_arch_is_hs): Likewise.
3079
3080 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
3081
3082 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
3083 parentheses in the declaration.
3084 (macro_lookup_inclusion): Likewise.
3085 (macro_lookup_definition): Likewise.
3086 * p-lang.h (pascal_builtin_types): Likewise.
3087 * tui/tui-data.c (tui_win_list): Likewise.
3088 * tui/tui-data.h (tui_win_list): Likewise.
3089 * utils.h (make_cleanup_free_section_addr_info): Likewise.
3090
3091 2017-10-11 Mark Rages <markrages@gmail.com>
3092
3093 * target-memory.c (block_boundaries): Fix for block address not
3094 aligned on block size.
3095
3096 2017-10-10 Pedro Alves <palves@redhat.com>
3097 Tom Tromey <tom@tromey.com>
3098
3099 * breakpoint.c (struct captured_breakpoint_query_args)
3100 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
3101 (print_breakpoint): New.
3102 * breakpoint.h (print_breakpoint): Declare.
3103 * common/common-exceptions.h (enum return_reason): Remove
3104 references to catch_exceptions.
3105 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
3106 Delete.
3107 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
3108 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
3109 * gdb.h: Delete.
3110 * gdbthread.h (thread_select): Declare.
3111 * mi/mi-cmd-break.c: Don't include gdb.h.
3112 (breakpoint_notify): Use print_breakpoint.
3113 * mi/mi-cmd-catch.c: Don't include gdb.h.
3114 * mi/mi-interp.c: Don't include gdb.h.
3115 (mi_print_breakpoint_for_event): New.
3116 (mi_breakpoint_created, mi_breakpoint_modified): Use
3117 mi_print_breakpoint_for_event.
3118 * mi/mi-main.c: Don't include gdb.h.
3119 (mi_cmd_thread_select): Parse the global thread ID here. Use
3120 thread_select instead of gdb_thread_select.
3121 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
3122 of using gdb_list_thread_ids.
3123 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
3124 FILEIO_ENOSYS here.
3125 (remote_fileio_request): Use TRY/CATCH instead of
3126 catch_exceptions.
3127 * symfile-mem.c (struct symbol_file_add_from_memory_args)
3128 (symbol_file_add_from_memory_wrapper): Delete.
3129 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
3130 * thread.c: Don't include gdb.h.
3131 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
3132 (thread_alive): Use thread_select.
3133 (do_captured_thread_select): Delete, parts salvaged as ...
3134 (thread_select): ... this new function.
3135 (gdb_thread_select): Delete.
3136
3137 2017-10-10 Pedro Alves <palves@redhat.com>
3138 Tom Tromey <tom@tromey.com>
3139
3140 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
3141 and reverse logic.
3142 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
3143 No longer macros. Instead ...
3144 (enum wp_check_result): They're now values of this new
3145 enumeration.
3146 (watchpoint_check): Change return type to wp_check_result and
3147 parameter type to bpstat.
3148 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
3149 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
3150 catch_errors. Reverse logic of watchpoint_check call.
3151 (breakpoint_re_set_one): Now returns void and takes a breakpoint
3152 pointer as parameter.
3153 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
3154 * common/common-exceptions.c (throw_exception_sjlj): Update
3155 comments to avoid mentioning catch_errors.
3156 * exceptions.c (catch_errors): Delete.
3157 * exceptions.h: Update comments to avoid mentioning catch_errors.
3158 (catch_errors_ftype, catch_errors): Delete.
3159 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
3160 (hook_stop_stub): Delete.
3161 (restore_selected_frame): Change return type to void, and
3162 parameter type to const frame_id &.
3163 (restore_infcall_control_state): Use TRY/CATCH instead of
3164 catch_errors.
3165 * main.c (captured_command_loop): Return void and remove
3166 parameter. Remove references to catch_errors.
3167 (captured_main): Use TRY/CATCH instead of catch_errors.
3168 * objc-lang.c (objc_submethod_helper_data)
3169 (find_objc_msgcall_submethod_helper): Delete.
3170 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
3171 catch_errors.
3172 * record-full.c (record_full_message): Return void.
3173 (record_full_message_args, record_full_message_wrapper): Delete.
3174 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
3175 instead of catch_errors.
3176 * solib-aix.c (solib_aix_open_symbol_file_object): Change
3177 parameter type to int.
3178 * solib-darwin.c (open_symbol_file_object): Ditto.
3179 * solib-dsbt.c (open_symbol_file_object): Ditto.
3180 * solib-frv.c (open_symbol_file_object): Ditto.
3181 * solib-svr4.c (open_symbol_file_object): Ditto.
3182 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
3183 * solib.c (update_solib_list): Use TRY/CATCH instead of
3184 catch_errors.
3185 * solist.h (struct target_so_ops) <open_symbol_file_object>:
3186 Change type.
3187 * symmisc.c (struct print_symbol_args): Remove.
3188 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
3189 (print_symbol): Change type.
3190 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
3191 and remove parameters.
3192 (catch_errors): New.
3193 (get_windows_debug_event): Adjust.
3194
3195 2017-10-09 Tom Tromey <tom@tromey.com>
3196
3197 * mi/mi-main.c (free_splay_tree): Remove.
3198 (list_available_thread_groups): Use splay_tree_up.
3199 * common/gdb_splay_tree.h: New file.
3200
3201 2017-10-09 Tom Tromey <tom@tromey.com>
3202
3203 * mi/mi-main.c (do_nothing): Remove.
3204 (list_available_thread_groups): Update.
3205
3206 2017-10-09 Pedro Alves <palves@redhat.com>
3207
3208 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
3209 reading registers when switching context.
3210
3211 2017-10-09 John Baldwin <jhb@FreeBSD.org>
3212
3213 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
3214 (fbsd_convert_siginfo): Likewise.
3215 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
3216
3217 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
3218
3219 * configure.ac (try_guile_versions): Remove guile-2.2.
3220 * configure: Regenerate.
3221
3222 2017-10-09 Tom Tromey <tom@tromey.com>
3223
3224 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
3225 (COMPILE.pre): Use $(CXX).
3226
3227 2017-10-09 Pedro Alves <palves@redhat.com>
3228
3229 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
3230 Use bool.
3231 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
3232 * cp-support.h (cp_remove_params): Now returns a
3233 gdb::unique_xmalloc_ptr.
3234 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
3235 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
3236 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
3237 returning a gdb::unique_xmalloc_ptr.
3238 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
3239 * stack.c (find_frame_funname): Adjust to cp_remove_params
3240 returning a gdb::unique_xmalloc_ptr.
3241
3242 2017-10-08 Tom Tromey <tom@tromey.com>
3243
3244 * dwarf2read.c (dwarf2_get_dwz_file): Use
3245 gdb::unique_xmalloc_ptr.
3246 (find_slot_in_mapped_hash): Likewise.
3247 (dwarf2_physname): Likewise.
3248 (create_dwo_unit_in_dwp_v1): Use std::string.
3249 (create_dwo_unit_in_dwp_v2): Likewise.
3250 (lookup_dwo_cutu): Likewise.
3251 (inherit_abstract_dies): Use std::vector.
3252 (read_array_type): Likewise.
3253 (dwarf_decode_macros): Remove unused declaration.
3254 (unsigned_int_compar): Remove.
3255 (dwarf2_build_psymtabs_hard): Use scoped_restore.
3256 (psymtabs_addrmap_cleanup): Remove.
3257
3258 2017-10-08 Tom Tromey <tom@tromey.com>
3259
3260 * frame-unwind.c (frame_unwind_try_unwinder): Update.
3261 * frame.h (frame_cleanup_after_sniffer): Declare.
3262 (frame_prepare_for_sniffer): Return void.
3263 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
3264 type of argument.
3265 (frame_prepare_for_sniffer): Return void.
3266
3267 2017-10-08 Tom Tromey <tom@tromey.com>
3268
3269 * utils.h (make_cleanup_value_free): Remove.
3270 * utils.c (do_value_free, struct cleanup): Remove.
3271 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
3272 Use gdb_value_up.
3273 * value.h (struct value_deleter): New.
3274 (gdb_value_up): New typedef.
3275
3276 2017-10-08 Tom Tromey <tom@tromey.com>
3277
3278 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
3279 (make_cleanup_free_search_symbols): Remove.
3280 (search_symbols): Return std::vector.
3281 (symbol_search::compare_search_syms): Now member of
3282 symbol_search. Change arguments.
3283 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
3284 (symtab_symbol_info, rbreak_command): Update.
3285 * symtab.h (struct symbol_search) <next>: Remove.
3286 Add constructors.
3287 (symbol_search::operator<): New function.
3288 (symbol_search::operator==): New function.
3289 (search_symbols): Remove std::vector.
3290 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
3291 (symbol_search::compare_search_syms): Declare.
3292
3293 2017-10-06 Yao Qi <yao.qi@linaro.org>
3294
3295 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
3296 arch/aarch64-insn.o.
3297 Remove one rule.
3298 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
3299
3300 2017-10-06 Yao Qi <yao.qi@linaro.org>
3301
3302 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
3303 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
3304 arch/arm-linux.o respectively.
3305 * configure.tgt: Likewise.
3306
3307 2017-10-06 Yao Qi <yao.qi@linaro.org>
3308
3309 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
3310 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
3311
3312 2017-10-06 Pedro Alves <palves@redhat.com>
3313
3314 * windows-nat.c: Include <algorithm>.
3315
3316 2017-10-06 Yao Qi <yao.qi@linaro.org>
3317
3318 * configure.tgt (i386_tobjs): New variable.
3319 (amd64_tobjs): New variable.
3320 Set $cpu_obs and $os_obs.
3321
3322 2017-10-06 Yao Qi <yao.qi@linaro.org>
3323
3324 * Makefile.in (CONFIG_SRC_SUBDIR): New.
3325 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
3326 (clean): Remove object files and dependency files.
3327 (distclean): Remove the directory.
3328 * configure.ac: Invoke AC_CONFIG_COMMANDS.
3329 * configure: Re-generated.
3330 * configure.tgt: Replace amd64.o with arch/amd64.o.
3331
3332 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
3333
3334 PR build/22188
3335 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
3336 and SETEND.
3337
3338 2017-10-05 Pedro Alves <palves@redhat.com>
3339
3340 * linux-nat.c (linux_child_follow_fork): When following the parent
3341 and detaching the child, consult the parent thread's architecture
3342 instead of the child's.
3343
3344 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3345
3346 * ax.h: Do not include "doublest.h".
3347 (union agent_val): Remove.
3348
3349 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3350
3351 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
3352 (decimal_to_string): Return std::string object.
3353 (decimal_from_string): Accept std::string object. Return bool.
3354 (decimal_from_integral, decimal_from_doublest): Remove.
3355 (decimal_from_longest): Add prototype.
3356 (decimal_from_ulongest): Likewise.
3357 (decimal_to_longest): Likewise.
3358 (decimal_from_doublest): Likewise.
3359 * dfp.c: Do not include "gdbtypes.h" or "value.h".
3360 (MAX_DECIMAL_STRING): Move here.
3361 (decimal_to_string): Return std::string object.
3362 (decimal_from_string): Accept std::string object. Return bool.
3363 (decimal_from_integral): Remove, replace by ...
3364 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
3365 (decimal_to_longest): New function.
3366 (decimal_from_floating): Remove, replace by ...
3367 (decimal_from_doublest): ... this new function.
3368 (decimal_to_doublest): Update to new decimal_to_string interface.
3369
3370 * value.c (unpack_long): Use decimal_to_longest.
3371 * valops.c (value_cast): Use decimal_from_doublest instead of
3372 decimal_from_floating. Use decimal_from_[u]longest isntead of
3373 decimal_from_integral.
3374 * valarith.c (value_args_as_decimal): Likewise.
3375 * valprint.c (print_decimal_floating): Update to new
3376 decimal_to_string interface.
3377 * printcmd.c (printf_decfloat): Likewise.
3378 * c-exp.y (parse_number): Update to new decimal_from_string interface.
3379
3380 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3381
3382 * doublest.h: Do not include "floatformat.h". Remove stale comments.
3383 * gdbtypes.c: Include "floatformat.h".
3384 * value.c: Likewise.
3385 * m68k-tdep.c: Likewise.
3386
3387 * findvar.c: Do not include "floatformat.h".
3388 * amd64-darwin-tdep.c: Likewise.
3389 * arm-linux-tdep.c: Likewise.
3390 * i386-darwin-tdep.c: Likewise.
3391 * i387-tdep.c: Likewise.
3392 * m68k-linux-tdep.c: Likewise.
3393 * mep-tdep.c: Likewise.
3394 * mips-tdep.c: Likewise.
3395 * nios2-tdep.c: Likewise.
3396 * s390-linux-tdep.c: Likewise.
3397 * sparc-obsd-tdep.c: Likewise.
3398 * sparc-tdep.c: Likewise.
3399 * sparc64-tdep.c: Likewise.
3400 * spu-tdep.c: Likewise.
3401 * tic6x-tdep.c: Likewise.
3402 * tilegx-tdep.c: Likewise.
3403 * vax-tdep.c: Likewise.
3404 * xstormy16-tdep.c: Likewise.
3405 * xtensa-tdep.c: Likewise.
3406
3407 * top.c: Do not include "doublest.h".
3408 * aarch64-tdep.c: Likewise.
3409 * alpha-tdep.c: Likewise.
3410 * arm-linux-tdep.c: Likewise.
3411 * m68k-linux-tdep.c: Likewise.
3412 * tilegx-tdep.c: Likewise.
3413 * xstormy16-tdep.c: Likewise.
3414
3415 2017-10-05 John Baldwin <jhb@FreeBSD.org>
3416
3417 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
3418 (mipsn32_fbsd_sigframe): Define.
3419 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
3420 for FreeBSD/mipsn32.
3421
3422 2017-10-05 John Baldwin <jhb@FreeBSD.org>
3423
3424 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
3425 AT_HWCAP.
3426
3427 2017-10-05 Tristan Gingold <tgingold@free.fr>
3428
3429 * MAINTAINERS (Misc): Update my email address.
3430
3431 2017-10-04 Pedro Alves <palves@redhat.com>
3432
3433 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
3434 it instead of target_gdbarch.
3435 (get_remote_state, get_remote_packet_size): Adjust
3436 get_remote_arch_state calls, passing down target_gdbarch
3437 explicitly.
3438 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
3439 'gdbarch' and use it instead of target_gdbarch.
3440 (get_memory_packet_size): Adjust get_remote_arch_state calls,
3441 passing down target_gdbarch explicitly.
3442 (struct stop_reply) <arch>: New field.
3443 (remote_parse_stop_reply): Use the stopped thread's architecture,
3444 not the current inferior's. Save the architecture in the
3445 stop_reply.
3446 (process_stop_reply): Use the stop reply's architecture.
3447 (process_g_packet, remote_fetch_registers)
3448 (remote_prepare_to_store, store_registers_using_G)
3449 (remote_store_registers): Adjust get_remote_arch_state calls,
3450 using the regcache's architecture.
3451 (remote_get_trace_status): Adjust get_remote_arch_state calls,
3452 passing down target_gdbarch explicitly.
3453 * spu-multiarch.c (spu_thread_architecture): Defer to the target
3454 beneath instead of calling target_gdbarch.
3455 * target.c (default_thread_architecture): Use the specified
3456 inferior's architecture, instead of the current inferior's
3457 architecture (via target_gdbarch).
3458
3459 2017-10-04 Pedro Alves <palves@redhat.com>
3460
3461 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
3462 case.
3463 (regcache_print): Handle !target_has_registers here instead.
3464
3465 2017-10-04 Pedro Alves <palves@redhat.com>
3466
3467 * frame.c (create_test_frame): Delete.
3468 * frame.h (create_test_frame): Delete.
3469 * gdbarch-selftests.c: Include gdbthread.h and target.h.
3470 (class regcache_test): Delete.
3471 (test_target_has_registers, test_target_has_stack)
3472 (test_target_has_memory, test_target_prepare_to_store)
3473 (test_target_store_registers): New functions.
3474 (test_target_ops): New class.
3475 (register_to_value_test): Error out if there's already a
3476 process_stratum (or higher) target pushed. Create a fuller mock
3477 environment, with mock target_ops, inferior, address space, thread
3478 and inferior_ptid.
3479 * progspace.c (struct address_space): Move to ...
3480 * progspace.h (struct address_space): ... here.
3481 * regcache.h (regcache::~regcache, regcache::raw_write)
3482 [GDB_SELF_TEST]: No longer virtual.
3483
3484 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
3485
3486 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
3487
3488 2017-10-04 Pedro Alves <palves@redhat.com>
3489
3490 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
3491 out of 'between TRY and CATCH'.
3492
3493 2017-10-04 Pedro Alves <palves@redhat.com>
3494
3495 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
3496 * common/common-exceptions.h (TRY): Open an outermost scope.
3497 Expand intro comment.
3498 (CATCH): Reindent.
3499 (END_CATCH): Close the outermost scope.
3500 * completer.c (complete_line_internal): Add missing END_CATCH.
3501
3502 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3503
3504 * NEWS (Changes since GDB 8.0): Add entry about new
3505 'set-cwd-on-gdbserver' feature.
3506 (New remote packets): Add entry for QSetWorkingDir.
3507 * common/common-inferior.h (set_inferior_cwd): New prototype.
3508 * infcmd.c (set_inferior_cwd): Remove "static".
3509 (show_cwd_command): Expand text to include remote debugging.
3510 * remote.c: Add PACKET_QSetWorkingDir.
3511 (remote_protocol_features) <QSetWorkingDir>: New entry for
3512 PACKET_QSetWorkingDir.
3513 (extended_remote_set_inferior_cwd): New function.
3514 (extended_remote_create_inferior): Call
3515 "extended_remote_set_inferior_cwd".
3516 (_initialize_remote): Call "add_packet_config_cmd" for
3517 QSetWorkingDir.
3518
3519 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3520
3521 * NEWS (New commands): Mention "set/show cwd".
3522 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
3523 "cd" command's help text.
3524 * common/common-inferior.h (get_inferior_cwd): New prototype.
3525 * infcmd.c (inferior_cwd_scratch): New global variable.
3526 (set_inferior_cwd): New function.
3527 (get_inferior_cwd): Likewise.
3528 (set_cwd_command): Likewise.
3529 (show_cwd_command): Likewise.
3530 (_initialize_infcmd): Add "set/show cwd" commands.
3531 * inferior.h (class inferior) <cwd>: New field.
3532 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
3533 (fork_inferior): Change inferior's cwd before its execution.
3534 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
3535 to CreateProcess.
3536
3537 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3538
3539 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
3540 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
3541 (COMMON_OBS): Add gdb_tilde_expand.o.
3542 * common/gdb_tilde_expand.c: New file.
3543 * common/gdb_tilde_expand.h: Likewise.
3544
3545 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
3546
3547 * gdbarch.sh (objfile): Remove duplicate declaration.
3548 * gdbarch.h: Regenerate.
3549
3550 2017-10-03 Tom Tromey <tom@tromey.com>
3551
3552 * utils.c (internal_vproblem): Use string_vprintf.
3553
3554 2017-10-03 Tom Tromey <tom@tromey.com>
3555
3556 * printcmd.c (info_symbol_command): Use std::string.
3557
3558 2017-10-03 Tom Tromey <tom@tromey.com>
3559
3560 * top.c (gdb_safe_append_history): Use std::string.
3561
3562 2017-10-03 Tom Tromey <tom@tromey.com>
3563
3564 * event-top.c (stdin_event_handler): Update.
3565 * main.c (captured_main_1): Update.
3566 * top.h (make_delete_ui_cleanup): Remove.
3567 (struct ui): Add constructor and destructor.
3568 (new_ui, delete_ui): Remove.
3569 * top.c (make_delete_ui_cleanup): Remove.
3570 (new_ui_command): Use std::unique_ptr.
3571 (delete_ui_cleanup): Remove.
3572 (ui::ui): Rename from new_ui. Update.
3573 (free_ui): Remove.
3574 (ui::~ui): Rename from delete_ui. Update.
3575
3576 2017-10-03 Tom Tromey <tom@tromey.com>
3577
3578 * symfile.c (load_progress): Use gdb::byte_vector.
3579
3580 2017-10-03 Tom Tromey <tom@tromey.com>
3581
3582 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
3583 declaration.
3584 * printcmd.c (x_command): Remove unused declaration.
3585 * symfile.c (symbol_file_command): Remove unused declaration.
3586
3587 2017-10-03 Tom Tromey <tom@tromey.com>
3588
3589 * utils.c (internal_vproblem): Use std::string.
3590 (defaulted_query): Likewise.
3591
3592 2017-10-03 Tom Tromey <tom@tromey.com>
3593
3594 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
3595 * top.c (execute_command_to_string): Update.
3596 * utils.c (make_cleanup_restore_page_info): Remove.
3597 (do_restore_page_info_cleanup): Remove.
3598 (set_batch_flag_and_restore_page_info):
3599 New.
3600 (make_cleanup_restore_page_info): Remove.
3601 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
3602 (~set_batch_flag_and_restore_page_info): New
3603 (make_cleanup_restore_uinteger): Remove.
3604 (make_cleanup_restore_integer): Remove.
3605 (struct restore_integer_closure): Remove.
3606 (restore_integer): Remove.
3607 * utils.h (struct set_batch_flag_and_restore_page_info): New
3608 class.
3609 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
3610 (make_cleanup_restore_page_info): Remove.
3611 (make_cleanup_restore_uinteger) Remove.
3612 (make_cleanup_restore_integer) Remove.
3613
3614 2017-10-03 Tom Tromey <tom@tromey.com>
3615
3616 * record-full.h (record_full_gdb_operation_disable_set): Return
3617 scoped_restore_tmpl<int>.
3618 * infrun.c (adjust_pc_after_break): Update.
3619 (handle_signal_stop): Update.
3620 * record-full.c (record_full_gdb_operation_disable_set): Return
3621 scoped_restore_tmpl<int>.
3622 (record_full_wait_1, record_full_insert_breakpoint)
3623 (record_full_remove_breakpoint, record_full_save)
3624 (record_full_goto_insn): Update.
3625
3626 2017-10-02 Tom Tromey <tom@tromey.com>
3627
3628 PR rust/22236:
3629 * rust-lang.c (rust_val_print_str): New function.
3630 (val_print_struct): Call it.
3631 (rust_subscript): Preserve name of slice type.
3632
3633 2017-10-02 Tom Tromey <tom@tromey.com>
3634
3635 * rust-lang.c (rust_subscript): Handle slices in
3636 EVAL_AVOID_SIDE_EFFECTS case.
3637
3638 2017-10-02 Tom Tromey <tom@tromey.com>
3639
3640 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
3641
3642 2017-10-02 Tom Tromey <tom@tromey.com>
3643
3644 * rust-lang.h (rust_slice_type): Add "extern".
3645
3646 2017-10-02 Tom Tromey <tom@tromey.com>
3647 Pedro Alves <palves@redhat.com>
3648
3649 * ada-lang.h (ada_exc_info::operator<): Make const.
3650 (ada_exc_info::operator==): Make const.
3651 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
3652 Make const.
3653
3654 2017-09-29 Tom Tromey <tom@tromey.com>
3655
3656 * target.c (read_whatever_is_readable): Change type of "result".
3657 Update.
3658 (free_memory_read_result_vector): Remove.
3659 (read_memory_robust): Change return type. Update.
3660 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
3661 bin2hex, std::string.
3662 * target.h (memory_read_result_s): Remove typedef.
3663 (free_memory_read_result_vector): Remove.
3664 (read_memory_robust): Return std::vector.
3665
3666 2017-09-29 Tom Tromey <tom@tromey.com>
3667
3668 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
3669
3670 2017-09-29 Tom Tromey <tom@tromey.com>
3671
3672 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
3673 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
3674 operator< and operator==.
3675 (ada_exceptions_list): Return a std::vector.
3676 * ada-lang.c (ada_exc_info::operator<): Rename from
3677 compare_ada_exception_info.
3678 (ada_exc_info::operator==): New.
3679 (sort_remove_dups_ada_exceptions_list): Change type of
3680 "exceptions".
3681 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
3682 (ada_add_global_exceptions): Likewise.
3683 (ada_exceptions_list_1): Return a std::vector.
3684 (ada_exceptions_list): Likewise.
3685
3686 2017-09-29 Tom Tromey <tom@tromey.com>
3687
3688 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
3689 'std::set *'.
3690 (print_one_inferior): Update.
3691 (free_vector_of_ints): Remove.
3692 (list_available_thread_groups): Change "ids" to std::set.
3693 (mi_cmd_list_thread_groups): Update.
3694 (struct collect_cores_data) <core>: Now a std::set.
3695 (collect_cores): Update.
3696 (unique): Remove.
3697 (print_one_inferior): Update.
3698
3699 2017-09-29 Tom Tromey <tom@tromey.com>
3700
3701 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
3702 (mi_execute_async_cli_command): Likewise.
3703 (mi_cmd_trace_frame_collected): Use field_fmt.
3704
3705 2017-09-29 Tom Tromey <tom@tromey.com>
3706
3707 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
3708 gdb::byte_vector.
3709
3710 2017-09-29 Tom Tromey <tom@tromey.com>
3711
3712 * mi/mi-parse.c (mi_parse): Remove unused declaration.
3713
3714 2017-09-29 Tom Tromey <tom@tromey.com>
3715
3716 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
3717
3718 2017-09-29 Tom Tromey <tom@tromey.com>
3719
3720 * varobj.h (varobj_gen_name): Return std::string.
3721 * varobj.c (varobj_gen_name): Return std::string.
3722 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
3723 (mi_cmd_var_delete): Don't copy "name".
3724
3725 2017-09-29 Tom Tromey <tom@tromey.com>
3726
3727 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
3728 (mi_cmd_break_insert_1): Update.
3729
3730 2017-09-29 Tom Tromey <tom@tromey.com>
3731
3732 * target.h (make_scoped_defer_target_commit_resume): Update.
3733 * target.c (make_scoped_defer_target_commit_resume): Rename from
3734 make_cleanup_defer_target_commit_resume. Return a
3735 scoped_restore.
3736 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
3737
3738 2017-09-29 Tom Tromey <tom@tromey.com>
3739
3740 * main.c (captured_main_1): Remove unused declaration.
3741 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
3742
3743 2017-09-29 Tom Tromey <tom@tromey.com>
3744
3745 * symtab.c (search_symbols): Remove unused outer cleanup.
3746 (make_source_files_completion_list): Remove unused declaration.
3747
3748 2017-09-29 Tom Tromey <tom@tromey.com>
3749
3750 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
3751
3752 2017-09-29 Tom Tromey <tom@tromey.com>
3753
3754 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
3755 gdb::byte_vector.
3756
3757 2017-09-29 Tom Tromey <tom@tromey.com>
3758
3759 * complaints.c (vcomplaint): Use std::string.
3760
3761 2017-09-29 Tom Tromey <tom@tromey.com>
3762
3763 * tracepoint.c (trace_variable_command): Use std::string.
3764 (encode_actions_1): Remove unused declarations.
3765 (create_tsv_from_upload): Use std::string.
3766
3767 2017-09-29 Tom Tromey <tom@tromey.com>
3768
3769 * cp-support.c (gdb_demangle): Use std::string.
3770
3771 2017-09-29 Tom Tromey <tom@tromey.com>
3772
3773 * stack.c (parse_frame_specification): Use std::string
3774 (info_frame_command): Use gdb::unique_xmalloc_ptr.
3775
3776 2017-09-29 Tom Tromey <tom@tromey.com>
3777
3778 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
3779
3780 2017-09-29 Tom Tromey <tom@tromey.com>
3781
3782 * utils.c (vfprintf_maybe_filtered): Use std::string.
3783 (vfprintf_unfiltered): Likewise.
3784
3785 2017-09-29 Tom Tromey <tom@tromey.com>
3786
3787 * event-top.c (top_level_prompt): Return std::string.
3788 (display_gdb_prompt): Update.
3789
3790 2017-09-29 Tom Tromey <tom@tromey.com>
3791
3792 * unittests/common-utils-selftests.c (format): New function.
3793 (string_vprintf_tests): New function.
3794 (_initialize_common_utils_selftests): Register new tests.
3795 * common/common-utils.c (string_vprintf): New function.
3796 * common/common-utils.h (string_vprintf): Declare.
3797
3798 2017-09-29 Pedro Alves <palves@redhat.com>
3799
3800 * common/rsp-low.c (unpack_varlen_hex): Constify.
3801 * common/rsp-low.h (unpack_varlen_hex): Constify.
3802 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
3803 Constify.
3804 * remote.c (remote_set_permissions, read_ptid)
3805 (remote_current_thread, remote_get_threads_with_qthreadinfo)
3806 (remote_static_tracepoint_marker_at)
3807 (remote_static_tracepoint_markers_by_strid)
3808 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
3809 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
3810 (parse_tracepoint_definition, parse_tsv_definition)
3811 (parse_static_tracepoint_marker_definition): Constify.
3812 * tracepoint.h (parse_static_tracepoint_marker_definition)
3813 (parse_trace_status, parse_tracepoint_status)
3814 (parse_tracepoint_definition, parse_tsv_definition): Constify.
3815
3816 2017-09-29 Pedro Alves <palves@redhat.com>
3817
3818 * remote.c (target_buf, target_buf_size): Delete.
3819 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
3820 Use the connection's packet buffer instead.
3821 All callers adjusted.
3822 (_initialize_remote): Remove references to target_buf and
3823 target_buf_size.
3824
3825 2017-09-28 Pedro Alves <palves@redhat.com>
3826
3827 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3828 unittests/common-utils-selftests.c.
3829 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
3830 (COMMON_OBS): Remove utils-selftests.o.
3831 * utils-selftests.c: Move to ...
3832 * unittests/common-utils-selftests.c: ... here and rename self
3833 test to "string_printf".
3834
3835 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
3836
3837 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
3838 having NULL cus or tus.
3839
3840 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3841
3842 * arm-tdep.c: (convert_from_extended): Remove.
3843 (convert_to_extended): Likewise.
3844 (arm_extract_return_value): Use convert_typed_floating.
3845 (arm_store_return_value): Likewise.
3846
3847 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
3848 * sh-tdep.c: Do not include "floatformat.h".
3849 (sh_littlebyte_bigword_type): New function.
3850 (sh_register_convert_to_virtual): Use convert_typed_floating.
3851 (sh_register_convert_to_raw): Likewise.
3852 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
3853 (sh64_littlebyte_bigword_type): New function.
3854 (sh64_extract_return_value): Use convert_typed_floating.
3855 (sh64_register_convert_to_virtual): Likewise.
3856 (sh64_register_convert_to_raw): Likewise.
3857
3858 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3859
3860 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
3861 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
3862
3863 * gdbtypes.h (union type_specific): Make field floatformat hold
3864 just a single struct floatformat, not an array.
3865 (floatformat_from_type): Move here.
3866 * gdbtypes.c (floatformat_from_type): Move here. Update to
3867 changed TYPE_FLOATFORMAT definition.
3868 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
3869 (recursive_dump_type): Likewise.
3870 (init_float_type): Install correct floatformat for byte order.
3871 (arch_float_type): Likewise.
3872
3873 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3874
3875 * gdbtypes.c (init_type): Change incoming argument from
3876 length-in-bytes to length-in-bits. Assert length is a
3877 multiple of TARGET_CHAR_BITS.
3878 (arch_type, arch_flags_type): Likewise.
3879 (init_integer_type): Update call to init_type.
3880 (init_character_type): Likewise.
3881 (init_boolean_type): Likewise.
3882 (init_float_type): Likewise.
3883 (init_decfloat_type): Likewise.
3884 (init_complex_type): Likewise.
3885 (init_pointer_type): Likewise.
3886 (objfile_type): Likewise.
3887 (arch_integer_type): Update call to arch_type.
3888 (arch_character_type): Likewise.
3889 (arch_boolean_type): Likewise.
3890 (arch_float_type): Likewise.
3891 (arch_decfloat_type): Likewise.
3892 (arch_complex_type): Likewise.
3893 (arch_pointer_type): Likewise.
3894 (gdbtypes_post_init): Likewise.
3895
3896 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
3897 (read_base_type): Likewise.
3898 * mdebugread.c (basic_type): Likewise.
3899 * stabsread.c (dbx_init_float_type): Likewise.
3900 (rs6000_builtin_type): Likewise.
3901 (read_range_type): Likewise. Also, fix call to init_integer_type
3902 with erroneous length argument.
3903
3904 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
3905 * d-lang.c (build_d_types): Likewise.
3906 * f-lang.c (build_fortran_types): Likewise.
3907 * go-lang.c (build_go_types): Likewise.
3908 * opencl-lang.c (build_opencl_types): Likewise.
3909 * jit.c (finalize_symtab): Likewise.
3910 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
3911 (build_std_type_info_type): Likewise.
3912 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
3913 update call to arch_flags_type.
3914
3915 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
3916 arch_type.
3917 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
3918 * windows-tdep.c (windows_get_tlb_type): Likewise.
3919
3920 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
3921 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
3922 * m32c-tdep.c (make_types): Likewise.
3923 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
3924 (rl78_psw_type): Update call to arch_flags_type.
3925 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
3926 * rx-tdep.c (rx_psw_type): Likewise.
3927 (rx_fpsw_type): Likewise.
3928 * sparc-tdep.c (sparc_psr_type): Likewise.
3929 (sparc_fsr_type): Likewise.
3930 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
3931 (sparc64_ccr_type): Likewise.
3932 (sparc64_fsr_type): Likewise.
3933 (sparc64_fprs_type): Likewise.
3934
3935 2017-09-27 Tom Tromey <tom@tromey.com>
3936
3937 * findcmd.c (find_command): Constify.
3938
3939 2017-09-27 Tom Tromey <tom@tromey.com>
3940
3941 * ada-tasks.c (task_command_1, task_command): Constify.
3942
3943 2017-09-27 Tom Tromey <tom@tromey.com>
3944
3945 * symtab.c (maintenance_print_symbol_cache)
3946 (maintenance_flush_symbol_cache)
3947 (maintenance_print_symbol_cache_statistics): Constify.
3948
3949 2017-09-27 Tom Tromey <tom@tromey.com>
3950
3951 * inferior.c (detach_inferior_command, kill_inferior_command)
3952 (inferior_command): Constify.
3953
3954 2017-09-27 Tom Tromey <tom@tromey.com>
3955
3956 * regcache.c (regcache_print, maintenance_print_registers)
3957 (maintenance_print_raw_registers)
3958 (maintenance_print_cooked_registers)
3959 (maintenance_print_register_groups)
3960 (maintenance_print_remote_registers): Constify.
3961
3962 2017-09-27 Tom Tromey <tom@tromey.com>
3963
3964 * printcmd.c (map_display_numbers, undisplay_command)
3965 (enable_disable_display_command, enable_display_command)
3966 (disable_display_command): Constify.
3967
3968 2017-09-27 Tom Tromey <tom@tromey.com>
3969
3970 * breakpoint.h (delete_command): Don't declare.
3971 * breakpoint.c (delete_command, enable_once_command)
3972 (enable_count_command, enable_delete_command, breakpoint_1)
3973 (maintenance_info_breakpoints, stopin_command, stopat_command)
3974 (delete_command, delete_trace_command, save_breakpoints)
3975 (save_breakpoints_command, save_tracepoints_command): Constify.
3976
3977 2017-09-27 Tom Tromey <tom@tromey.com>
3978
3979 * macrocmd.c (macro_expand_command, macro_expand_once_command)
3980 (skip_ws, extract_identifier, macro_define_command)
3981 (macro_undef_command, macro_list_command): Constify.
3982
3983 2017-09-27 Tom Tromey <tom@tromey.com>
3984
3985 * infcmd.c (environment_info, set_environment_command)
3986 (unset_environment_command, path_info, info_proc_cmd_1)
3987 (info_proc_cmd_mappings, info_proc_cmd_stat)
3988 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
3989 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
3990
3991 2017-09-27 Tom Tromey <tom@tromey.com>
3992
3993 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
3994 Constify.
3995
3996 2017-09-27 Tom Tromey <tom@tromey.com>
3997
3998 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
3999
4000 2017-09-27 Tom Tromey <tom@tromey.com>
4001
4002 * demangle.c (demangle_command): Constify.
4003
4004 2017-09-27 Tom Tromey <tom@tromey.com>
4005
4006 * progspace.c (maintenance_info_program_spaces_command):
4007 Constify.
4008
4009 2017-09-27 Tom Tromey <tom@tromey.com>
4010
4011 * compile/compile.c (check_raw_argument, compile_file_command)
4012 (compile_code_command, compile_print_command): Constify.
4013
4014 2017-09-27 Tom Tromey <tom@tromey.com>
4015
4016 * reggroups.c (maintenance_print_reggroups): Constify.
4017
4018 2017-09-27 Tom Tromey <tom@tromey.com>
4019
4020 * dwarf2read.c (save_gdb_index_command): Constify.
4021
4022 2017-09-27 Tom Tromey <tom@tromey.com>
4023
4024 * stap-probe.c (info_probes_stap_command): Constify.
4025
4026 2017-09-27 Tom Tromey <tom@tromey.com>
4027
4028 * fork-child.c (unset_exec_wrapper_command): Constify.
4029
4030 2017-09-27 Tom Tromey <tom@tromey.com>
4031
4032 * btrace.c (get_uint, get_context_size, no_chunk)
4033 (maint_btrace_packet_history_cmd)
4034 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
4035 (maint_info_btrace_cmd): Constify.
4036
4037 2017-09-27 Tom Tromey <tom@tromey.com>
4038
4039 * reverse.c (delete_bookmark_command): Constify.
4040
4041 2017-09-27 Tom Tromey <tom@tromey.com>
4042
4043 * remote.c (set_memory_packet_size)
4044 (set_memory_write_packet_size, show_memory_write_packet_size)
4045 (set_memory_read_packet_size, show_memory_read_packet_size)
4046 (compare_sections_command, packet_command, remote_put_command)
4047 (remote_get_command, remote_delete_command): Constify.
4048
4049 2017-09-27 Tom Tromey <tom@tromey.com>
4050
4051 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
4052 (set_mipsfpu_double_command, set_mipsfpu_none_command)
4053 (set_mipsfpu_auto_command): Constify.
4054
4055 2017-09-27 Tom Tromey <tom@tromey.com>
4056
4057 * cli/cli-cmds.h (cd_command): Constify.
4058 * cli/cli-cmds.c (cd_command): Constify.
4059
4060 2017-09-27 Tom Tromey <tom@tromey.com>
4061
4062 * thread.c (thread_name_command, thread_find_command): Constify.
4063
4064 2017-09-27 Tom Tromey <tom@tromey.com>
4065
4066 * probe.c (enable_probes_command, disable_probes_command):
4067 Constify.
4068
4069 2017-09-27 Tom Tromey <tom@tromey.com>
4070
4071 * symfile.c (symbol_file_command): Constify.
4072 * gdbcore.h (deprecated_file_changed_hook): Constify.
4073 * exec.c (deprecated_file_changed_hook, exec_file_command)
4074 (file_command): Constify.
4075 * defs.h (symbol_file_command): Constify.
4076
4077 2017-09-27 Tom Tromey <tom@tromey.com>
4078
4079 * remote-fileio.c (set_system_call_allowed)
4080 (show_system_call_allowed): Constify.
4081
4082 2017-09-27 Tom Tromey <tom@tromey.com>
4083
4084 * tracepoint.c (delete_trace_variable_command)
4085 (tfind_end_command, tfind_start_command, tfind_pc_command)
4086 (tfind_tracepoint_command, tfind_line_command)
4087 (tfind_range_command, tfind_outside_command): Constify.
4088
4089 2017-09-27 Tom Tromey <tom@tromey.com>
4090
4091 * ax-gdb.c (maint_agent_printf_command, agent_command)
4092 (agent_eval_command): Constify.
4093
4094 2017-09-27 Tom Tromey <tom@tromey.com>
4095
4096 * tracepoint.c (info_scope_command): Constify.
4097 * python/python.c (gdbpy_decode_line): Constify.
4098 * python/py-breakpoint.c (bppy_init): Constify.
4099 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
4100 * location.h: (new_linespec_location)
4101 (string_to_event_location_basic, string_to_event_location):
4102 Constify.
4103 * location.c (new_linespec_location)
4104 (string_to_event_location_basic, string_to_event_location):
4105 Constify.
4106 * linespec.h (decode_line_with_current_source)
4107 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
4108 * linespec.c (linespec_lex_to_end)
4109 (decode_line_with_current_source)
4110 (decode_line_with_last_displayed): Constify.
4111 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
4112 Constify.
4113 * cli/cli-cmds.c (edit_command, list_command): Constify.
4114 * breakpoint.h (until_break_command, watch_command_wrapper)
4115 (awatch_command_wrapper, rwatch_command_wrapper)
4116 (init_ada_exception_breakpoint): Constify.
4117 * breakpoint.c (break_command_1, dprintf_command)
4118 (break_range_command, watch_command_wrapper)
4119 (rwatch_command_wrapper, awatch_command_wrapper)
4120 (until_break_command, init_ada_exception_breakpoint)
4121 (strace_marker_create_sals_from_location, trace_command)
4122 (ftrace_command, strace_command, struct tracepoint): Constify.
4123 * ax-gdb.c (agent_command_1): Constify.
4124 * ada-lang.c (ada_exception_sal): Constify.
4125
4126 2017-09-27 Tom Tromey <tom@tromey.com>
4127
4128 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
4129 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
4130 (get_context_size, no_chunk, get_insn_history_modifiers)
4131 (cmd_record_insn_history, get_call_history_modifiers)
4132 (cmd_record_call_history): Constify.
4133
4134 2017-09-27 Tom Tromey <tom@tromey.com>
4135
4136 * source.c (show_substitute_path_command)
4137 (unset_substitute_path_command, set_substitute_path_command):
4138 Constify.
4139
4140 2017-09-27 Tom Tromey <tom@tromey.com>
4141
4142 * typeprint.c (maintenance_print_type): Constify.
4143 * maint.c (maintenance_dump_me, maintenance_demangle)
4144 (maintenance_time_display, maintenance_info_sections)
4145 (maintenance_print_statistics, maintenance_deprecate)
4146 (maintenance_undeprecate): Constify.
4147 (maintenance_do_deprecate): Constify. Use std::string.
4148 (maintenance_selftest): Constify.
4149 * gdbtypes.h (maintenance_print_type): Constify.
4150
4151 2017-09-27 Tom Tromey <tom@tromey.com>
4152
4153 * hppa-tdep.c (unwind_command): Constify.
4154
4155 2017-09-27 Tom Tromey <tom@tromey.com>
4156
4157 * target-descriptions.c (unset_tdesc_filename_cmd)
4158 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
4159 Constify.
4160
4161 2017-09-27 Tom Tromey <tom@tromey.com>
4162
4163 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
4164
4165 2017-09-27 Tom Tromey <tom@tromey.com>
4166
4167 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
4168
4169 2017-09-27 Tom Tromey <tom@tromey.com>
4170
4171 * tui/tui-regs.c (tui_reg_command): Constify.
4172
4173 2017-09-27 Tom Tromey <tom@tromey.com>
4174
4175 * skip.c (skip_file_command, skip_function_command)
4176 (skip_enable_command, skip_disable_command, skip_delete_command):
4177 Constify.
4178
4179 2017-09-27 Tom Tromey <tom@tromey.com>
4180
4181 * record-btrace.c (cmd_record_btrace_bts_start)
4182 (cmd_record_btrace_pt_start): Constify.
4183
4184 2017-09-27 Tom Tromey <tom@tromey.com>
4185
4186 * symmisc.c (maintenance_print_symbols)
4187 (maintenance_print_msymbols, maintenance_print_objfiles)
4188 (maintenance_info_symtabs, maintenance_check_symtabs)
4189 (maintenance_expand_symtabs, maintenance_info_line_tables):
4190 Constify.
4191
4192 2017-09-27 Tom Tromey <tom@tromey.com>
4193
4194 * top.c (new_ui_command): Constify.
4195
4196 2017-09-27 Tom Tromey <tom@tromey.com>
4197
4198 * symfile.c (add_symbol_file_command)
4199 (remove_symbol_file_command, list_overlays_command)
4200 (map_overlay_command, unmap_overlay_command)
4201 (overlay_auto_command, overlay_manual_command)
4202 (overlay_off_command, overlay_load_command): Constify.
4203
4204 2017-09-27 Tom Tromey <tom@tromey.com>
4205
4206 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
4207 (info_spu_mailbox_command, info_spu_dma_command)
4208 (info_spu_proxydma_command): Constify.
4209
4210 2017-09-27 Tom Tromey <tom@tromey.com>
4211
4212 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
4213
4214 2017-09-27 Tom Tromey <tom@tromey.com>
4215
4216 * cli/cli-script.c (user_defined_command): Constify.
4217
4218 2017-09-27 Tom Tromey <tom@tromey.com>
4219
4220 * cli/cli-dump.c (dump_memory_command, dump_value_command)
4221 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
4222 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
4223 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
4224 (dump_binary_value, append_binary_memory, append_binary_value):
4225 Constify.
4226 (struct dump_context) <func>: Constify.
4227 (add_dump_command): Update.
4228
4229 2017-09-27 Tom Tromey <tom@tromey.com>
4230
4231 * cli/cli-cmds.c (show_version, show_configuration)
4232 (source_command, show_user): Constify.
4233
4234 2017-09-27 Tom Tromey <tom@tromey.com>
4235
4236 * target.c (maintenance_print_target_stack): Constify.
4237
4238 2017-09-27 Tom Tromey <tom@tromey.com>
4239
4240 * interps.c (interpreter_exec_cmd): Constify.
4241
4242 2017-09-27 Tom Tromey <tom@tromey.com>
4243
4244 * record-full.c (cmd_record_full_restore): Constify.
4245
4246 2017-09-27 Tom Tromey <tom@tromey.com>
4247
4248 * memattr.c (enable_mem_command, disable_mem_command)
4249 (delete_mem_command): Constify.
4250
4251 2017-09-27 Tom Tromey <tom@tromey.com>
4252
4253 * value.c (show_convenience): Constify.
4254
4255 2017-09-27 Tom Tromey <tom@tromey.com>
4256
4257 * gdbcore.h (core_file_command): Update.
4258 * corefile.c (core_file_command): Constify.
4259
4260 2017-09-27 Tom Tromey <tom@tromey.com>
4261
4262 * user-regs.c (maintenance_print_user_registers): Constify.
4263
4264 2017-09-27 Tom Tromey <tom@tromey.com>
4265
4266 * cp-namespace.c (maintenance_cplus_namespace): Constify.
4267
4268 2017-09-27 Tom Tromey <tom@tromey.com>
4269
4270 * cp-support.c (first_component_command): Constify.
4271
4272 2017-09-27 Tom Tromey <tom@tromey.com>
4273
4274 * psymtab.c (maintenance_print_psymbols)
4275 (maintenance_info_psymtabs, maintenance_check_psymtabs):
4276 Constify.
4277
4278 2017-09-27 Tom Tromey <tom@tromey.com>
4279
4280 * windows-tdep.c (display_tib): Constify.
4281
4282 2017-09-27 Tom Tromey <tom@tromey.com>
4283
4284 * linux-fork.c (delete_checkpoint_command)
4285 (detach_checkpoint_command): Constify.
4286
4287 2017-09-27 Tom Tromey <tom@tromey.com>
4288
4289 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
4290
4291 2017-09-27 Tom Tromey <tom@tromey.com>
4292
4293 * arc-tdep.c (dump_arc_instruction_command): Constify.
4294
4295 2017-09-27 Tom Tromey <tom@tromey.com>
4296
4297 * valprint.c (set_radix, show_radix): Constify.
4298
4299 2017-09-27 Tom Tromey <tom@tromey.com>
4300
4301 * dtrace-probe.c (info_probes_dtrace_command): Constify.
4302
4303 2017-09-27 Tom Tromey <tom@tromey.com>
4304
4305 * command.h (not_just_help_class_command): Update.
4306 * cli/cli-decode.h (not_just_help_class_command): Update.
4307 * cli/cli-decode.c (not_just_help_class_command): Constify.
4308
4309 2017-09-27 Tom Tromey <tom@tromey.com>
4310
4311 * gdb_bfd.c (maintenance_info_bfds): Constify.
4312
4313 2017-09-27 Tom Tromey <tom@tromey.com>
4314
4315 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
4316 overloads.
4317 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
4318 (do_const_cfunc): New function.
4319 (cmd_cfunc_eq): New overload.
4320 (cli_user_command_p): Check do_const_cfunc.
4321 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
4322 const_cfunc.
4323 * command.h (add_cmd): Add const overload and no-function
4324 overload.
4325 (set_cmd_cfunc): Add const overload.
4326 (cmd_const_cfunc_ftype): Declare.
4327 (cmd_cfunc_eq): Add const overload.
4328 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
4329 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
4330 overload.
4331
4332 2017-09-27 Tom Tromey <tom@tromey.com>
4333
4334 * macroexp.c (get_next_token_for_substitution): New function.
4335 (substitute_args): Call it. Check for __VA_OPT__.
4336
4337 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
4338 Pedro Alves <palves@redhat.com>
4339
4340 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
4341 producer_is_icc_lt_14.
4342 (producer_is_icc_lt_14): New function.
4343 (check_producer): Add code for checking version of ICC.
4344 (producer_is_icc): Move to producer.c.
4345 (read_structure_type): Restrict ICC workaround to ICC<14.
4346 * producer.c: Include selftest.h.
4347 (producer_is_icc, producer_parsing_tests, _initialize_producer):
4348 New functions.
4349 * producer.h (producer_is_icc): New declaration.
4350
4351 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
4352
4353 * Makefile.in (SFILES): Add producer.c.
4354 (COMMON_OBS): Add producer.o
4355 * amd64-tdep.c (producer.h): Add new include.
4356 * dwarf2read.c (producer.h): Add new include.
4357 * producer.c: New file.
4358 * producer.h: New file.
4359 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
4360 producer.c.
4361 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
4362 producer.h.
4363
4364 2017-09-26 Matthias Klose <doko@ubuntu.com>
4365
4366 * configure.ac: Search ncursesw before ncurses.
4367 Check ncursesw/ncurses.h before ncurses/ncurses.h.
4368 * gdb_curses.h: Include <ncursesw/ncurses.h>
4369 * config.in, configure: Regenerate.
4370
4371 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4372
4373 PR gdb/22185
4374 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
4375 obsolete.
4376 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
4377 Remove i386sol2 support.
4378 * configure.nat <i386sol2>: Remove.
4379 <sol2-64>: Fold into ...
4380 <sol2>: ... this.
4381 Move common settings to default section.
4382 Add sol-thread.o.
4383 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
4384 x86_64-*-solaris2.1[0-9]*>: Rename to ...
4385 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
4386 <i[34567]86-*-solaris*>: Remove.
4387 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
4388
4389 * configure.ac: Remove wctype in libw check.
4390 (_MSE_INT_H): Don't define on Solaris 7-9.
4391 <solaris*>: Remove libthread_db.so.1 check.
4392 * configure: Regenerate.
4393 * config.in: Regenerate.
4394
4395 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
4396 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
4397 (gdb_ps_size_t): Remove.
4398 Use base types in users.
4399 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
4400
4401 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
4402
4403 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4404
4405 PR build/22206
4406 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
4407 (adi_is_addr_mapped): Likewise.
4408 (PSR_ICC): Don't redefine.
4409 (PSR_IMPL): Likewise.
4410
4411 2017-09-25 Tom Tromey <tom@tromey.com>
4412
4413 * regcache.c (regcache::dump): Use string_printf.
4414
4415 2017-09-25 Tom Tromey <tom@tromey.com>
4416
4417 * regcache.c (class regcache_invalidator): New.
4418 (struct register_to_invalidate): Remove.
4419 (make_cleanup_regcache_invalidate): Remove.
4420 (regcache::raw_write): Use regcache_invalidator.
4421
4422 2017-09-25 Tom Tromey <tom@tromey.com>
4423
4424 * spu-tdep.c (spu2ppu_sniffer): Update.
4425 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
4426 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
4427 Remove.
4428 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
4429 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
4430 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
4431 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
4432 (frame_pop): Update.
4433
4434 2017-09-25 Tom Tromey <tom@tromey.com>
4435
4436 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
4437 * regcache.h (regcache_xfree): Don't declare.
4438 * regcache.c (regcache_xfree): Remove.
4439 (do_regcache_xfree): Use delete.
4440 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
4441 * linux-fork.c (free_fork): Use delete.
4442 (fork_save_infrun_state): Likewise.
4443 * jit.c (jit_dealloc_cache): Use delete.
4444 * infrun.c (discard_infcall_suspend_state): Use delete.
4445
4446 2017-09-25 Tom Tromey <tom@tromey.com>
4447
4448 * regcache.h (regcache_xmalloc): Don't declare.
4449 (regcache_raw_set_cached_value): Update comment.
4450 * regcache.c (regcache_xmalloc): Remove.
4451 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
4452 * jit.c (jit_frame_sniffer): Use new.
4453 * frame.c (frame_save_as_regcache): Use new.
4454
4455 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4456
4457 * NEWS: Advertise support for guarded-storage registers on IBM z.
4458
4459 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4460
4461 * s390-linux-nat.c (have_regset_gs): New static variable.
4462 (s390_linux_fetch_inferior_registers): Handle guarded-storage
4463 control block and guarded-storage broadcast control regsets.
4464 (s390_read_description): Detect whether the target has
4465 guarded-storage support, return appropriate tdesc.
4466 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
4467 (features/s390x-gs-linux64.c): Likewise.
4468 (struct gdbarch_tdep) <have_gs>: New field.
4469 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
4470 (s390_gsbc_regset): New variables.
4471 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
4472 and s390_gsbc_regset, if applicable.
4473 (s390_core_read_description): Check whether core file was from a
4474 target with guarded-storage support; include appropriate regsets.
4475 (s390_gdbarch_init): Add registers for guarded-storage support.
4476 (_initialize_s390_tdep): Initialize new target descriptions that
4477 include registers for guarded-storage support.
4478 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
4479 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
4480 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
4481 (S390_NUM_REGS): Adjust macro definition.
4482 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
4483 (tdesc_s390x_gs_linux64): New declarations.
4484
4485 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4486
4487 * features/s390-gs-linux64.xml: New file.
4488 * features/s390-gs.xml: New file.
4489 * features/s390-gsbc.xml: New file.
4490 * features/s390x-gs-linux64.xml: New file.
4491 * features/Makefile (WHICH): Add s390-gs-linux64 and
4492 s390x-gs-linux64.
4493 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
4494 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
4495 * features/s390-gs-linux64.c: New generated file.
4496 * features/s390x-gs-linux64.c: New file.
4497 * regformats/s390-gs-linux64.dat: New file.
4498 * regformats/s390x-gs-linux64.dat: New file.
4499
4500 2017-09-23 Tom Tromey <tom@tromey.com>
4501
4502 * defs.h (make_cleanup_override_quit_handler): Don't declare.
4503
4504 2017-09-22 Tom Tromey <tom@tromey.com>
4505
4506 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
4507 type to scoped_restore_tmpl.
4508 <scoped_input_handler>: Initialize m_quit_handler directly.
4509
4510 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
4511
4512 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
4513 (cd_command): Likewise. Free "current_directory" before
4514 assigning to it.
4515 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
4516 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
4517 * top.c (gdb_dirbuf): Remove global declaration.
4518 * top.h (gdb_dirbuf): Likewise.
4519
4520 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
4521
4522 * gnulib/aclocal.m4: Regenerate.
4523 * gnulib/config.in: Regenerate.
4524 * gnulib/configure: Regenerate.
4525 * gnulib/import/Makefile.am: Regenerate.
4526 * gnulib/import/Makefile.in: Regenerate.
4527 * gnulib/import/assure.h: New file.
4528 * gnulib/import/at-func.c: Likewise
4529 * gnulib/import/chdir-long.c: New file.
4530 * gnulib/import/chdir-long.h: New file.
4531 * gnulib/import/cloexec.c: New file.
4532 * gnulib/import/cloexec.h: New file.
4533 * gnulib/import/close.c: New file.
4534 * gnulib/import/closedir.c: New file.
4535 * gnulib/import/dirent-private.h: New file.
4536 * gnulib/import/dup-safer.c: New file.
4537 * gnulib/import/dup.c: New file.
4538 * gnulib/import/dup2.c: New file.
4539 * gnulib/import/error.c: New file.
4540 * gnulib/import/error.h: New file.
4541 * gnulib/import/exitfail.c: New file.
4542 * gnulib/import/exitfail.h: New file.
4543 * gnulib/import/fchdir.c: New file.
4544 * gnulib/import/fcntl.c: New file.
4545 * gnulib/import/fcntl.in.h: New file.
4546 * gnulib/import/fd-hook.c: New file.
4547 * gnulib/import/fd-hook.h: New file.
4548 * gnulib/import/fd-safer.c: New file.
4549 * gnulib/import/fdopendir.c: New file.
4550 * gnulib/import/filename.h: New file.
4551 * gnulib/import/filenamecat-lgpl.c: New file.
4552 * gnulib/import/filenamecat.h: New file.
4553 * gnulib/import/fstat.c: New file.
4554 * gnulib/import/fstatat.c: New file.
4555 * gnulib/import/getcwd-lgpl.c: New file.
4556 * gnulib/import/getcwd.c: New file.
4557 * gnulib/import/getdtablesize.c: New file.
4558 * gnulib/import/getlogin_r.c: New file.
4559 * gnulib/import/getprogname.c: New file.
4560 * gnulib/import/getprogname.h: New file.
4561 * gnulib/import/gettext.h: New file.
4562 * gnulib/import/glob-libc.h: New file.
4563 * gnulib/import/glob.c: New file.
4564 * gnulib/import/glob.in.h: New file.
4565 * gnulib/import/intprops.h: New file.
4566 * gnulib/import/m4/chdir-long.m4: New file.
4567 * gnulib/import/m4/close.m4: New file.
4568 * gnulib/import/m4/closedir.m4: New file.
4569 * gnulib/import/m4/d-ino.m4: New file.
4570 * gnulib/import/m4/d-type.m4: New file.
4571 * gnulib/import/m4/dup.m4: New file.
4572 * gnulib/import/m4/dup2.m4: New file.
4573 * gnulib/import/m4/error.m4: New file.
4574 * gnulib/import/m4/fchdir.m4: New file.
4575 * gnulib/import/m4/fcntl.m4: New file.
4576 * gnulib/import/m4/fcntl_h.m4: New file.
4577 * gnulib/import/m4/fdopendir.m4: New file.
4578 * gnulib/import/m4/filenamecat.m4: New file.
4579 * gnulib/import/m4/fstat.m4: New file.
4580 * gnulib/import/m4/fstatat.m4: New file.
4581 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
4582 * gnulib/import/m4/getcwd-path-max.m4: New file.
4583 * gnulib/import/m4/getcwd.m4: New file.
4584 * gnulib/import/m4/getdtablesize.m4: New file.
4585 * gnulib/import/m4/getlogin_r.m4: New file.
4586 * gnulib/import/m4/getprogname.m4: New file.
4587 * gnulib/import/m4/glob.m4: New file.
4588 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
4589 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
4590 * gnulib/import/m4/mempcpy.m4: New file.
4591 * gnulib/import/m4/memrchr.m4: New file.
4592 * gnulib/import/m4/mode_t.m4: New file.
4593 * gnulib/import/m4/msvc-inval.m4: New file.
4594 * gnulib/import/m4/msvc-nothrow.m4: New file.
4595 * gnulib/import/m4/open.m4: New file.
4596 * gnulib/import/m4/openat.m4: New file.
4597 * gnulib/import/m4/opendir.m4: New file.
4598 * gnulib/import/m4/readdir.m4: New file.
4599 * gnulib/import/m4/realloc.m4: New file.
4600 * gnulib/import/m4/rewinddir.m4: New file.
4601 * gnulib/import/m4/save-cwd.m4: New file.
4602 * gnulib/import/m4/strdup.m4: New file.
4603 * gnulib/import/m4/strerror.m4: New file.
4604 * gnulib/import/m4/unistd-safer.m4: New file.
4605 * gnulib/import/mempcpy.c: New file.
4606 * gnulib/import/memrchr.c: New file.
4607 * gnulib/import/msvc-inval.c: New file.
4608 * gnulib/import/msvc-inval.h: New file.
4609 * gnulib/import/msvc-nothrow.c: New file.
4610 * gnulib/import/msvc-nothrow.h: New file.
4611 * gnulib/import/open.c: New file.
4612 * gnulib/import/openat-die.c: New file.
4613 * gnulib/import/openat-priv.h: New file.
4614 * gnulib/import/openat-proc.c: New file.
4615 * gnulib/import/openat.c: New file.
4616 * gnulib/import/openat.h: New file.
4617 * gnulib/import/opendir.c: New file.
4618 * gnulib/import/pipe-safer.c: New file.
4619 * gnulib/import/readdir.c: New file.
4620 * gnulib/import/realloc.c: New file.
4621 * gnulib/import/rewinddir.c: New file.
4622 * gnulib/import/save-cwd.c: New file.
4623 * gnulib/import/save-cwd.h: New file.
4624 * gnulib/import/strdup.c: New file.
4625 * gnulib/import/strerror-override.c: New file.
4626 * gnulib/import/strerror-override.h: New file.
4627 * gnulib/import/strerror.c: New file.
4628 * gnulib/import/unistd--.h: New file.
4629 * gnulib/import/unistd-safer.h: New file.
4630 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
4631 "getcwd" and "glob".
4632 * ser-tcp.c: Undefine "close" before redefining it.
4633
4634 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4635
4636 * guile/scm-value.c (gdbscm_value_address): Initialize address,
4637 get rid of res_val.
4638
4639 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4640
4641 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
4642 <sol2,sparc>: Likewise.
4643 <sol2-64,i386>: Likewise.
4644
4645 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
4646 -Wdeprecated-declarations on *-*-solaris*.
4647 * configure: Regenerate.
4648
4649 * procfs.c: Include "nat/inferior.h".
4650 (procfs_info_proc): Fix typo.
4651
4652 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4653
4654 * remote.c (vector): Include.
4655 (struct private_thread_info): Add field, thread_handle.
4656 (free_private_thread_info): Deallocate storage associated with
4657 thread handle.
4658 (get_private_info_thread): Initialize `thread_handle' field.
4659 (struct thread_item): Add field, thread_handle.
4660 (clear_threads_listing_context): Deallocate storage associated
4661 with thread handle.
4662 (start_thread): Add support for "handle" attribute.
4663 (thread_attributes): Add "handle".
4664 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
4665 field.
4666 (remote_update_thread_list): Update thread_handle.
4667 (remote_thread_handle_to_thread_info): New function.
4668 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
4669
4670 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4671
4672 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
4673 function.
4674 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
4675 * python/python-internal.h (thread_object_type): Declare.
4676
4677 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4678
4679 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
4680 (target_thread_handle_to_thread_info): Declare.
4681 * target.c (target_thread_handle_to_thread_info): New function.
4682 * target-delegates.c: Regenerate.
4683 * gdbthread.h (find_thread_by_handle): Declare.
4684 * thread.c (find_thread_by_handle): New function.
4685 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
4686 function.
4687 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
4688
4689 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4690
4691 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
4692
4693 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4694
4695 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
4696
4697 2017-09-21 Yao Qi <yao.qi@linaro.org>
4698
4699 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
4700 to gdb_target_obs.
4701
4702 2017-09-20 Tom Tromey <tom@tromey.com>
4703
4704 * breakpoint.c (struct counted_command_line): Remove.
4705 (breakpoint_commands): Update.
4706 (alloc_counted_command_line, incref_counted_command_line)
4707 (decref_counted_command_line, do_cleanup_counted_command_line)
4708 (make_cleanup_decref_counted_command_line): Remove.
4709 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
4710 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
4711 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
4712 (save_breakpoints): Update.
4713 * breakpoint.h (counted_command_line): Now a typedef to
4714 shared_ptr.
4715 (struct breakpoint) <commands>: Now a counted_command_line.
4716 (struct bpstats) <command>: Likewise.
4717
4718 2017-09-20 Tom Tromey <tom@tromey.com>
4719
4720 * breakpoint.c (struct commands_info, do_map_commands_command):
4721 Remove.
4722 (commands_command_1): Update.
4723 (iterate_over_related_breakpoints): Take a function_view.
4724 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
4725 (delete_command): Update.
4726 (map_breakpoint_numbers): Take a function_view.
4727 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
4728 (disable_command): Update.
4729 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
4730 (enable_command): Update.
4731 (struct disp_data, do_enable_breakpoint_disp)
4732 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
4733 (do_map_enable_delete_breakpoint): Remove.
4734 (enable_once_command, enable_count_command, enable_delete_command)
4735 (delete_trace_variable_command): Update.
4736
4737 2017-09-20 Tom Tromey <tom@tromey.com>
4738
4739 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
4740 (bpstat_clear): Use delete.
4741 (bpstats): New constructors.
4742 (bpstat_copy, bpstat_stop_status): Use new.
4743 (dprintf_after_condition_true): Update.
4744 * breakpoint.h (bpstats::bpstats): Add constructors.
4745 (bpstats::~bpstats): Add destructor.
4746
4747 2017-09-20 Pedro Alves <palves@redhat.com>
4748
4749 * eval.c (make_params): Delete, refactored as ...
4750 (class fake_method): ... this new type's ctor.
4751 (fake_method::~fake_method): New.
4752 (evaluate_subexp_standard): Use 'fake_method'.
4753
4754 2017-09-20 Tom Tromey <tom@tromey.com>
4755
4756 * windows-nat.c (get_windows_debug_event, windows_wait)
4757 (do_initial_windows_stuff, windows_attach): Update.
4758 * utils.c (vwarning, internal_vproblem): Update.
4759 (ui_unregister_input_event_handler_cleanup)
4760 (prepare_to_handle_input): Remove.
4761 (class scoped_input_handler): New.
4762 (defaulted_query, prompt_for_continue): Update.
4763 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
4764 Update.
4765 * top.c (undo_terminal_modifications_before_exit): Update.
4766 * target/target.h (target_terminal_init, target_terminal_inferior)
4767 (target_terminal_ours): Don't declare.
4768 (class target_terminal): New.
4769 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
4770 (target_terminal_ours_for_output)
4771 (make_cleanup_restore_target_terminal): Don't declare.
4772 (target_terminal_info): Remove.
4773 * target.c (enum terminal_state, terminal_state): Remove.
4774 (target_terminal::terminal_state): Define.
4775 (target_terminal::init): Rename from target_terminal_init.
4776 (target_terminal::inferior): Rename from
4777 target_terminal_inferior.
4778 (target_terminal::ours): Rename from target_terminal_ours.
4779 (target_terminal::ours_for_output): Rename from
4780 target_terminal_ours_for_output.
4781 (target_terminal::info): New method.
4782 (cleanup_restore_target_terminal)
4783 (make_cleanup_restore_target_terminal): Remove.
4784 * solib.c (handle_solib_event): Update.
4785 * remote.c (remote_serial_quit_handler): Update.
4786 (remote_terminal_inferior, remote_wait_as): Update.
4787 * record-full.c (record_full_wait_1): Update.
4788 * nto-procfs.c (procfs_create_inferior): Update.
4789 * nat/fork-inferior.c (startup_inferior): Update.
4790 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
4791 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
4792 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
4793 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
4794 (mi_breakpoint_created, mi_breakpoint_deleted)
4795 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
4796 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
4797 (mi_user_selected_context_changed, report_initial_inferior):
4798 Update.
4799 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
4800 (linux_nat_terminal_inferior): Update.
4801 * infrun.c (follow_fork_inferior)
4802 (handle_vfork_child_exec_or_exit, do_target_resume)
4803 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
4804 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
4805 Update.
4806 * inflow.c (child_terminal_init, info_terminal_command): Update.
4807 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
4808 (attach_command): Update.
4809 * infcall.c (call_thread_fsm_should_stop): Update.
4810 * gnu-nat.c (gnu_attach): Update.
4811 * extension.c (struct active_ext_lang_state)
4812 (restore_active_ext_lang): Update.
4813 * exceptions.c (print_flush): Update.
4814 * event-top.c (async_enable_stdin, default_quit_handler): Update.
4815 (struct quit_handler_cleanup_data, restore_quit_handler)
4816 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
4817 Remove.
4818 * cp-support.c (gdb_demangle): Update.
4819 * breakpoint.c (update_inserted_breakpoint_locations)
4820 (insert_breakpoint_locations, handle_jit_event)
4821 (disable_breakpoints_in_unloaded_shlib): Update.
4822 * annotate.c (annotate_breakpoints_invalid)
4823 (annotate_frames_invalid): Update.
4824
4825 2017-09-20 Tom Tromey <tom@tromey.com>
4826
4827 * main.c (catch_command_errors): Rename from
4828 catch_command_errors_const.
4829 (captured_main_1): Update.
4830
4831 2017-09-20 Pedro Alves <palves@redhat.com>
4832
4833 * cli/cli-cmds.c (list_command): Use print_sal_location.
4834 (print_sal_location): New function.
4835 (ambiguous_line_spec): Use print_sal_location.
4836 * linespec.c (symbol_to_sal): Record the symbol in the sal.
4837 * symtab.c (find_function_start_sal): Likewise.
4838 * symtab.h (symtab_and_line::symbol): New field.
4839
4840 2017-09-20 Pedro Alves <palves@redhat.com>
4841
4842 * linespec.c (minsym_found): Handle non-text minsyms.
4843 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
4844
4845 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
4846
4847 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
4848 backslash.
4849
4850 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
4851
4852 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
4853 vmovups instead vmovaps.
4854 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
4855
4856 2017-09-19 John Baldwin <jhb@FreeBSD.org>
4857
4858 * NEWS (Changes since GDB 8.0): Add starti.
4859 * infcmd.c (enum run_break): New.
4860 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
4861 case.
4862 (run_command): Use enum run_how.
4863 (start_command): Likewise.
4864 (starti_command): New function.
4865 (RUN_ARGS_HELP): New macro.
4866 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
4867 commands. Add starti command.
4868
4869 2017-09-19 Yao Qi <yao.qi@linaro.org>
4870
4871 * Makefile.in (monitor.o): Remove the rule.
4872
4873 2017-09-19 Yao Qi <yao.qi@linaro.org>
4874
4875 * annotate.h (struct annotate_arg_emitter): Use
4876 DISABLE_COPY_AND_ASSIGN.
4877 * common/refcounted-object.h (refcounted_object): Likewise.
4878 * completer.h (struct completion_result): Likewise.
4879 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
4880 * filename-seen-cache.h (filename_seen_cache): Likewise.
4881 * gdbcore.h (thread_section_name): Likewise.
4882 * gdb_regex.h (compiled_regex): Likewise.
4883 * gdbthread.h (scoped_restore_current_thread): Likewise.
4884 * inferior.h (scoped_restore_current_inferior): Likewise.
4885 * jit.c (jit_reader): Likewise.
4886 * linespec.h (struct linespec_result): Likewise.
4887 * mi/mi-parse.h (struct mi_parse): Likewise.
4888 * nat/fork-inferior.c (execv_argv): Likewise.
4889 * progspace.h (scoped_restore_current_program_space): Likewise.
4890 * python/python-internal.h (class gdbpy_enter): Likewise.
4891 * regcache.h (regcache): Likewise.
4892 * target-descriptions.c (struct tdesc_reg): Likewise.
4893 (struct tdesc_type): Likewise.
4894 (struct tdesc_feature): Likewise.
4895 * ui-out.h (ui_out_emit_type): Likewise.
4896
4897 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
4898
4899 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
4900 label abort_expression.
4901
4902 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4903
4904 * common/buffer.c (buffer_xml_printf): Adjust.
4905 * common/xml-utils.c (xml_escape_text): Change return type to
4906 std::string, update code accordingly.
4907 * common/xml-utils.h (xml_escape_text): Change return type to
4908 std::string.
4909 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
4910 * windows-tdep.c (windows_xfer_shared_library): Adjust.
4911 * unittests/xml-utils-selftests.c (test_xml_escape_text):
4912 Adjust.
4913
4914 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4915
4916 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
4917 (SUBDIR_UNITTESTS_OBS): Add new object file.
4918 * unittests/xml-utils-selftests.c: New file.
4919
4920 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4921
4922 * common/selftest.h (selftest): New struct/interface.
4923 (register_test): Add name parameter, add new overload.
4924 (run_tests): Add filter parameter.
4925 (for_each_selftest_ftype): New typedef.
4926 (for_each_selftest): New declaration.
4927 * common/selftest.c (tests): Change type to
4928 map<string, unique_ptr<selftest>>.
4929 (simple_selftest): New struct.
4930 (register_test): New function.
4931 (register_test): Add name parameter and use it.
4932 (run_tests): Add filter parameter and use it. Add prints.
4933 Adjust to vector -> map change.
4934 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
4935 registering selftests.
4936 * arm-tdep.c (_initialize_arm_tdep): Likewise.
4937 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
4938 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
4939 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
4940 * findvar.c (_initialize_findvar): Likewise.
4941 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
4942 * maint.c (maintenance_selftest): Update call to run_tests.
4943 (maintenance_info_selftests): New function.
4944 (_initialize_maint_cmds): Register "maintenance info selftests"
4945 command. Update "maintenance selftest" doc.
4946 * regcache.c (_initialize_regcache): Add names when registering
4947 selftests.
4948 * rust-exp.y (_initialize_rust_exp): Likewise.
4949 * selftest-arch.c (gdbarch_selftest): New struct.
4950 (gdbarch_tests): Remove.
4951 (register_test_foreach_arch): Add name parameter. Call
4952 register_test.
4953 (tests_with_arch): Remove, move most content to
4954 gdbarch_selftest::operator().
4955 (_initialize_selftests_foreach_arch): Remove.
4956 * selftest-arch.h (register_test_foreach_arch): Add name
4957 parameter.
4958 (run_tests_with_arch): New declaration.
4959 * utils-selftests.c (_initialize_utils_selftests): Add names
4960 when registering selftests.
4961 * utils.c (_initialize_utils): Likewise.
4962 * unittests/array-view-selftests.c
4963 (_initialize_array_view_selftests): Likewise.
4964 * unittests/environ-selftests.c (_initialize_environ_selftests):
4965 Likewise.
4966 * unittests/function-view-selftests.c
4967 (_initialize_function_view_selftests): Likewise.
4968 * unittests/offset-type-selftests.c
4969 (_initialize_offset_type_selftests): Likewise.
4970 * unittests/optional-selftests.c
4971 (_initialize_optional_selftests): Likewise.
4972 * unittests/scoped_restore-selftests.c
4973 (_initialize_scoped_restore_selftests): Likewise.
4974 * NEWS: Document "maintenance selftest" and "maint info
4975 selftests".
4976
4977 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4978
4979 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
4980 scoped_restore.
4981
4982 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4983
4984 * mi/mi-main.c (mi_load_progress): Make uiout variable
4985 a unique_ptr.
4986
4987 2017-09-15 Pedro Alves <palves@redhat.com>
4988
4989 * compile/compile-c-types.c (convert_enum, convert_int)
4990 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
4991
4992 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4993
4994 * dwarf2read.c (copy_string): Remove.
4995 (parse_macro_definition): Replace copy_string with savestring.
4996
4997 2017-09-15 Yao Qi <yao.qi@linaro.org>
4998
4999 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
5000 gdb_target_obs.
5001 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
5002 Likewise.
5003 (i[34567]86-*-linux*): Likewise.
5004
5005 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5006
5007 * dwarf2expr.h (dwarf_stack_value): Add constructor.
5008 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
5009 <stack>: Change type to std::vector.
5010 <stack_len, stack_allocated>: Remove.
5011 <grow_stack>: Remove.
5012 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
5013 (dwarf_expr_context::~dwarf_expr_context): Remove.
5014 (dwarf_expr_context::grow_stack): Remove.
5015 (dwarf_expr_context::push): Adjust.
5016 (dwarf_expr_context::pop): Adjust.
5017 (dwarf_expr_context::fetch): Adjust.
5018 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
5019 (dwarf_expr_context::stack_empty_p): Adjust.
5020 (dwarf_expr_context::execute_stack_op): Adjust.
5021
5022 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5023
5024 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
5025 return type to bool.
5026 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
5027
5028 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5029
5030 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
5031 Change type to bool.
5032 (dwarf_stack_value) <in_stack_memory>: Likewise.
5033 (dwarf_expr_context) <push_address>: Change parameter type to
5034 bool.
5035 <fetch_in_stack_memory>: Change return type to bool.
5036 <push>: Change parameter type to bool.
5037 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
5038 to bool.
5039 (dwarf_expr_context::push_address): Likewise.
5040 (dwarf_expr_context::fetch_in_stack_memory): Change return type
5041 to bool.
5042 (dwarf_expr_context::execute_stack_op): Adjust.
5043 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
5044
5045 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5046
5047 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
5048 (struct dwarf_expr_context) <n_pieces>: Remove.
5049 <pieces>: Change type to std::vector.
5050 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
5051 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
5052 pieces.
5053 (dwarf_expr_context::add_piece): Adjust.
5054 * dwarf2loc.c (struct piece_closure): Initialize fields.
5055 <n_pieces>: Remove.
5056 <pieces>: Change type to std::vector.
5057 (allocate_piece_closure): Adjust, change parameter to
5058 std::vector rvalue and std::move it to piece_closure.
5059 (rw_pieced_value): Adjust.
5060 (check_pieced_synthetic_pointer): Adjust.
5061 (indirect_synthetic_pointer): Adjust.
5062 (coerce_pieced_ref): Adjust.
5063 (free_pieced_value_closure): Adjust. Use delete to free
5064 piece_closure.
5065 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
5066 to allocate_piece_closure.
5067 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
5068
5069 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5070
5071 * probe.h (probe_ops_cp): Remove typedef.
5072 (DEF_VEC_P (probe_ops_cp)): Remove.
5073 (all_probe_ops): Change type to std::vector.
5074 * probe.c (info_probes_for_ops): Adjust to vector change.
5075 (probe_linespec_to_ops): Likewise.
5076 (all_probe_ops): Change type to std::vector.
5077 (_initialize_probe): Adjust to vector change.
5078 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
5079 * elfread.c (elf_get_probes): Likewise.
5080 * stap-probe.c (_initialize_stap_probe): Likewise.
5081
5082 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5083
5084 * probe.h (struct bound_probe): Define constructors.
5085 * probe.c (bound_probe_s): Remove typedef.
5086 (DEF_VEC_O (bound_probe_s)): Remove VEC.
5087 (collect_probes): Change return type to std::vector, remove
5088 cleanup.
5089 (compare_probes): Return bool, change parameter type. Change
5090 semantic to "less than".
5091 (gen_ui_out_table_header_info): Change parameter to std::vector
5092 and update.
5093 (exists_probe_with_pops): Likewise.
5094 (info_probes_for_ops): Update to std::vector change.
5095 (enable_probes_command): Likewise.
5096 (disable_probes_command): Likewise.
5097
5098 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5099
5100 * probe.h (struct probe_ops) <get_probes>: Change parameter from
5101 vec to std::vector.
5102 * probe.c (parse_probes_in_pspace): Update.
5103 (find_probes_in_objfile): Update.
5104 (find_probe_by_pc): Update.
5105 (collect_probes): Update.
5106 (probe_any_get_probes): Update.
5107 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
5108 return type to reference to std::vector.
5109 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
5110 std::vector and update.
5111 (dtrace_process_dof): Likewise.
5112 (dtrace_get_probes): Likewise.
5113 * elfread.c (elf_get_probes): Change return type to std::vector,
5114 store an std::vector in bfd_data.
5115 (probe_key_free): Update to std::vector.
5116 * stap-probe.c (handle_stap_probe): Change parameter to
5117 std::vector and update.
5118 (stap_get_probes): Likewise.
5119 * symfile-debug.c (debug_sym_get_probes): Change return type to
5120 std::vector and update.
5121
5122 2017-09-11 Tom Tromey <tom@tromey.com>
5123
5124 * breakpoint.c (program_breakpoint_here_p): Update.
5125 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
5126 from make_show_memory_breakpoints_cleanup. Return a
5127 scoped_restore_tmpl<int>.
5128 (restore_show_memory_breakpoints): Remove.
5129 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
5130 * mem-break.c (memory_validate_breakpoint): Update.
5131 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
5132 (ia64_memory_remove_breakpoint): Update.
5133 (ia64_breakpoint_from_pc): Update.
5134 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
5135 from make_show_memory_breakpoints_cleanup.
5136
5137 2017-09-11 Tom Tromey <tom@tromey.com>
5138
5139 * d-namespace.c (d_lookup_symbol): Use std::string.
5140 (find_symbol_in_baseclass): Likewise.
5141
5142 2017-09-11 Tom Tromey <tom@tromey.com>
5143
5144 * ctf.c (ctf_start): Use std::string.
5145
5146 2017-09-11 Tom Tromey <tom@tromey.com>
5147
5148 * ada-lang.c (is_known_support_routine): Update.
5149 (ada_unhandled_exception_name_addr_from_raise): Update.
5150 * guile/scm-frame.c (gdbscm_frame_name): Update.
5151 * python/py-frame.c (frapy_name): Update.
5152 (frapy_function): Update.
5153 * stack.h (find_frame_funname): Update.
5154 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
5155 (print_frame): Update.
5156
5157 2017-09-11 Tom Tromey <tom@tromey.com>
5158
5159 * findcmd.c (put_bits): Take a gdb::byte_vector.
5160 (parse_find_args): Return gdb::byte_vector. "args" now const.
5161 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
5162 cleanups.
5163 (find_command): Update.
5164
5165 2017-09-11 Tom Tromey <tom@tromey.com>
5166
5167 * cli/cli-script.c (class scoped_restore_hook_in): New.
5168 (clear_hook_in_cleanup): Remove.
5169 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
5170 scoped_restore_hook_in.
5171
5172 2017-09-11 Tom Tromey <tom@tromey.com>
5173
5174 * cli/cli-script.c (restore_interp): Remove.
5175 (read_command_lines): Use scoped_restore_interp.
5176 * interps.c (scoped_restore_interp::set_temp): Rename from
5177 interp_set_temp.
5178 * interps.h (class scoped_restore_interp): New.
5179 (interp_set_temp): Remove.
5180
5181 2017-09-11 Tom Tromey <tom@tromey.com>
5182
5183 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
5184 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
5185 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
5186 scoped_restore.
5187 (mi_cmd_break_insert_1): Update.
5188 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
5189 scoped_restore.
5190
5191 2017-09-11 Tom Tromey <tom@tromey.com>
5192
5193 * demangle.c (demangle_command): Update.
5194 * breakpoint.c (disable_command): Update.
5195 (enable_command): Update.
5196 (find_location_by_number): Make "number" const. Use
5197 get_number_trailer.
5198 * cli/cli-utils.c (extract_arg): Return std::string.
5199 * probe.c (parse_probe_linespec): Update. Change types.
5200 (collect_probes): Take string arguments.
5201 (parse_probe_linespec): Likewise.
5202 (info_probes_for_ops): Update.
5203 (enable_probes_command): Update.
5204 (disable_probes_command): Update.
5205 * break-catch-sig.c (catch_signal_split_args): Update.
5206 * mi/mi-parse.c (mi_parse): Update.
5207
5208 2017-09-11 Tom Tromey <tom@tromey.com>
5209
5210 * language.h (language_enum): Make argument const.
5211 * language.c (language_enum): Make argument const.
5212
5213 2017-09-11 Tom Tromey <tom@tromey.com>
5214
5215 * common/common-utils.h (skip_to_space): Remove macro, redeclare
5216 as function.
5217 (skip_to_space): Rename from skip_to_space_const.
5218 * common/common-utils.c (skip_to_space): New function.
5219 (skip_to_space): Rename from skip_to_space_const.
5220 * cli/cli-utils.h (get_number): Rename from get_number_const.
5221 (extract_arg): Rename from extract_arg_const.
5222 * cli/cli-utils.c (get_number): Rename from get_number_const.
5223 (extract_arg): Rename from extract_arg_const.
5224 (number_or_range_parser::get_number): Use ::get_number.
5225 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
5226 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
5227 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
5228 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
5229 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
5230 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
5231 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
5232 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
5233
5234 2017-09-11 Tom Tromey <tom@tromey.com>
5235
5236 * python/python.c (do_start_initialization): Use
5237 py-event-types.def to initialize types.
5238 Define all object type structures.
5239 * python/python-internal.h: Don't declare event initialization
5240 functions.
5241 * python/py-threadevent.c (thread_event_object_type): Don't
5242 define.
5243 * python/py-stopevent.c (stop_event_object_type): Don't define.
5244 * python/py-signalevent.c (signal_event_object_type): Don't
5245 declare or define.
5246 * python/py-newobjfileevent.c (new_objfile_event_object_type)
5247 (clear_objfiles_event_object_type): Don't declare or define.
5248 * python/py-infevents.c (inferior_call_pre_event_object_type)
5249 (inferior_call_post_event_object_type)
5250 (register_changed_event_object_type)
5251 (memory_changed_event_object_type): Don't declare or define.
5252 * python/py-inferior.c (new_thread_event_object_type)
5253 (new_inferior_event_object_type)
5254 (inferior_deleted_event_object_type): Don't declare or define.
5255 * python/py-exitedevent.c (exited_event_object_type): Don't
5256 declare or define.
5257 * python/py-evts.c (gdbpy_initialize_py_events): Use
5258 py-all-events.def.
5259 * python/py-events.h (thread_event_object_type): Don't declare.
5260 (events_object): Use py-all-events.def.
5261 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
5262 py-event-types.def.
5263 * python/py-event-types.def: New file.
5264 * python/py-continueevent.c (create_continue_event_object): Don't
5265 declare or define.
5266 * python/py-bpevent.c (breakpoint_event_object_type): Don't
5267 declare or define.
5268 * python/py-all-events.def: New file.
5269
5270 2017-09-11 Tom Tromey <tom@tromey.com>
5271
5272 * python/py-threadevent.c (create_thread_event_object): Return
5273 gdbpy_ref.
5274 * python/py-stopevent.h (create_stop_event_object)
5275 (create_breakpoint_event_object, create_signal_event_object):
5276 Update.
5277 * python/py-stopevent.c (create_stop_event_object): Return
5278 gdbpy_ref.
5279 (emit_stop_event): Update.
5280 * python/py-signalevent.c (create_signal_event_object): Return
5281 gdbpy_ref.
5282 * python/py-infevents.c (create_inferior_call_event_object):
5283 Update.
5284 * python/py-event.h (create_event_object)
5285 (create_thread_event_object): Update.
5286 * python/py-event.c (create_event_object): Return gdbpy_ref.
5287 * python/py-continueevent.c: Return gdbpy_ref.
5288 * python/py-bpevent.c (create_breakpoint_event_object): Return
5289 gdbpy_ref.
5290
5291 2017-09-11 Tom Tromey <tom@tromey.com>
5292
5293 PR python/15622:
5294 * NEWS: Add entry.
5295 * python/python.c (do_start_initialization): Initialize new event
5296 types.
5297 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
5298 (gdbpy_initialize_inferior_deleted_event)
5299 (gdbpy_initialize_new_thread_event): Declare.
5300 * python/py-threadevent.c (create_thread_event_object): Add option
5301 "thread" parameter.
5302 * python/py-inferior.c (new_thread_event_object_type)
5303 (new_inferior_event_object_type)
5304 (inferior_deleted_event_object_type): Declare.
5305 (python_new_inferior, python_inferior_deleted): New functions.
5306 (add_thread_object): Emit new_thread event.
5307 (gdbpy_initialize_inferior): Attach new functions to corresponding
5308 observers.
5309 (new_thread, new_inferior, inferior_deleted): Define new event
5310 types.
5311 * python/py-evts.c (gdbpy_initialize_py_events): Add new
5312 registries.
5313 * python/py-events.h (events_object) <new_inferior,
5314 inferior_deleted, new_thread>: New fields.
5315 * python/py-event.h (create_thread_event_breakpoint): Add optional
5316 "thread" parameter.
5317
5318 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
5319
5320 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
5321 check current_ui instead.
5322 (internal_vproblem): Likewise.
5323
5324 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
5325
5326 * thread.c (print_thread_info_1): Remove unnecessary calls to
5327 uiout->is_mi_like_p.
5328
5329 2017-09-09 Tom Tromey <tom@tromey.com>
5330
5331 * namespace.h (add_using_directive): Update.
5332 * namespace.c (add_using_directive): Change type of excludes to
5333 std::vector.
5334 * dwarf2read.c (read_import_statement): Use std::vector.
5335 (read_namespace): Update.
5336 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
5337
5338 2017-09-09 Tom Tromey <tom@tromey.com>
5339
5340 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
5341
5342 2017-09-09 Tom Tromey <tom@tromey.com>
5343
5344 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
5345
5346 2017-09-09 Tom Tromey <tom@tromey.com>
5347
5348 * stack.c (func_command): Use gdb::def_vector.
5349
5350 2017-09-09 Tom Tromey <tom@tromey.com>
5351
5352 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
5353 ui_out_emit_list, ui_out_emit_tuple.
5354 (mi_cmd_var_update): Likewise.
5355
5356 2017-09-09 Tom Tromey <tom@tromey.com>
5357
5358 * mi/mi-interp.c (mi_user_selected_context_changed): Use
5359 ui_out_redirect_pop.
5360 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
5361 ui_out_redirect_pop.
5362 * utils.c (do_ui_out_redirect_pop)
5363 (make_cleanup_ui_out_redirect_pop): Remove.
5364 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
5365 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
5366 * ui-out.h (ui_out_redirect_pop): New class.
5367
5368 2017-09-09 Tom Tromey <tom@tromey.com>
5369
5370 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
5371 (list_available_thread_groups, mi_cmd_list_thread_groups)
5372 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
5373 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
5374 Likewise.
5375
5376 2017-09-09 Tom Tromey <tom@tromey.com>
5377
5378 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
5379 ui_out_emit_tuple.
5380
5381 2017-09-09 Tom Tromey <tom@tromey.com>
5382
5383 * target.c (flash_erase_command): Use ui_out_emit_tuple.
5384 * stack.c (print_frame): Use ui_out_emit_tuple.
5385 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
5386 (info_spu_mailbox_command, info_spu_dma_command)
5387 (info_spu_proxydma_command): Likewise.
5388 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
5389 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
5390 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
5391 ui_out_emit_tuple.
5392 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
5393
5394 2017-09-09 Tom Tromey <tom@tromey.com>
5395
5396 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
5397 (class ui_out_emit_table): Update comment.
5398 * ui-out.c (do_cleanup_table_end)
5399 (make_cleanup_ui_out_table_begin_end): Remove.
5400 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
5401 (info_spu_dma_cmdlist): Likewise.
5402 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
5403 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
5404 ui_out_emit_table.
5405
5406 2017-09-09 Tom Tromey <tom@tromey.com>
5407
5408 * thread.c (print_thread_info_1): Use ui_out_emit_table,
5409 ui_out_emit_list, gdb::optional.
5410
5411 2017-09-09 John Baldwin <jhb@FreeBSD.org>
5412
5413 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
5414 prototype.
5415 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
5416 prototype.
5417 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
5418 prototype.
5419 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
5420 * ada-exp.y: Remove _initialize_ada_exp prototype.
5421 * ada-lang.c: Remove _initialize_ada_language prototype.
5422 * ada-tasks.c: Remove _initialize_tasks prototype.
5423 * addrmap.c: Remove _initialize_addrmap prototype.
5424 * agent.c: Remove _initialize_agent prototype.
5425 * aix-thread.c: Remove _initialize_aix_thread prototype.
5426 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
5427 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
5428 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
5429 prototype.
5430 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
5431 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
5432 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
5433 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
5434 prototype.
5435 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
5436 prototype.
5437 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
5438 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
5439 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
5440 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
5441 prototype.
5442 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
5443 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
5444 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
5445 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
5446 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
5447 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
5448 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
5449 prototype.
5450 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
5451 prototype.
5452 * annotate.c: Remove _initialize_annotate prototype.
5453 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
5454 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
5455 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
5456 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
5457 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
5458 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
5459 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
5460 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
5461 prototype.
5462 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
5463 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
5464 * auto-load.c: Remove _initialize_auto_load prototype.
5465 * auxv.c: Remove _initialize_auxv prototype.
5466 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
5467 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
5468 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
5469 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
5470 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
5471 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
5472 prototype.
5473 * break-catch-throw.c: Remove _initialize_break_catch_throw
5474 prototype.
5475 * breakpoint.c: Remove _initialize_breakpoint prototype.
5476 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
5477 * btrace.c: Remove _initialize_btrace prototype.
5478 * charset.c: Remove _initialize_charset prototype.
5479 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
5480 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
5481 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
5482 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
5483 * cli/cli-script.c: Remove _initialize_cli_script prototype.
5484 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
5485 * coffread.c: Remove _initialize_coffread prototype.
5486 * compile/compile.c: Remove _initialize_compile prototype.
5487 * complaints.c: Remove _initialize_complaints prototype.
5488 * completer.c: Remove _initialize_completer prototype.
5489 * copying.awk: Remove _initialize_copying prototype.
5490 * copying.c: Regenerate.
5491 * core-regset.c: Remove _initialize_core_regset prototype.
5492 * corefile.c: Remove _initialize_core prototype.
5493 * corelow.c: Remove _initialize_corelow prototype.
5494 * cp-abi.c: Remove _initialize_cp_abi prototype.
5495 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
5496 * cp-support.c: Remove _initialize_cp_support prototype.
5497 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
5498 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
5499 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
5500 * ctf.c: Remove _initialize_ctf prototype.
5501 * d-lang.c: Remove _initialize_d_language prototype.
5502 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
5503 prototype.
5504 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
5505 * dbxread.c: Remove _initialize_dbxread prototype.
5506 * dcache.c: Remove _initialize_dcache prototype.
5507 * demangle.c: Remove _initialize_demangler prototype.
5508 * disasm-selftests.c: Remove _initialize_disasm_selftests
5509 prototype.
5510 * disasm.c: Remove _initialize_disasm prototype.
5511 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
5512 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
5513 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
5514 prototype.
5515 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
5516 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
5517 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
5518 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
5519 * elfread.c: Remove _initialize_elfread prototype.
5520 * exec.c: Remove _initialize_exec prototype.
5521 * extension.c: Remove _initialize_extension prototype.
5522 * f-lang.c: Remove _initialize_f_language prototype.
5523 * f-valprint.c: Remove _initialize_f_valprint prototype.
5524 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
5525 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
5526 * filesystem.c: Remove _initialize_filesystem prototype.
5527 * findcmd.c: Remove _initialize_mem_search prototype.
5528 * fork-child.c: Remove _initialize_fork_child prototype.
5529 * frame-base.c: Remove _initialize_frame_base prototype.
5530 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
5531 * frame.c: Remove _initialize_frame prototype.
5532 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
5533 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
5534 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
5535 * gcore.c: Remove _initialize_gcore prototype.
5536 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
5537 * gdbarch.c: Regenerate.
5538 * gdbarch.sh: Remove _initialize_gdbarch prototype.
5539 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
5540 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
5541 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
5542 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
5543 * go-lang.c: Remove _initialize_go_language prototype.
5544 * go32-nat.c: Remove _initialize_go32_nat prototype.
5545 * guile/guile.c: Remove _initialize_guile prototype.
5546 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
5547 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
5548 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
5549 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
5550 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
5551 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
5552 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
5553 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
5554 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
5555 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
5556 prototype.
5557 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
5558 prototype.
5559 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
5560 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
5561 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
5562 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
5563 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
5564 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
5565 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
5566 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
5567 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
5568 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
5569 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
5570 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
5571 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
5572 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
5573 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
5574 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
5575 prototype.
5576 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
5577 prototype.
5578 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
5579 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
5580 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
5581 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
5582 * infcall.c: Remove _initialize_infcall prototype.
5583 * infcmd.c: Remove _initialize_infcmd prototype.
5584 * inferior.c: Remove _initialize_inferiors prototype.
5585 * inflow.c: Remove _initialize_inflow prototype.
5586 * infrun.c: Remove _initialize_infrun prototype.
5587 * interps.c: Remove _initialize_interpreter prototype.
5588 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
5589 * jit.c: Remove _initialize_jit prototype.
5590 * language.c: Remove _initialize_language prototype.
5591 * linux-fork.c: Remove _initialize_linux_fork prototype.
5592 * linux-nat.c: Remove _initialize_linux_nat prototype.
5593 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
5594 * linux-thread-db.c: Remove _initialize_thread_db prototype.
5595 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
5596 * m2-lang.c: Remove _initialize_m2_language prototype.
5597 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
5598 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
5599 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
5600 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
5601 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
5602 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
5603 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
5604 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
5605 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
5606 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
5607 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
5608 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
5609 * machoread.c: Remove _initialize_machoread prototype.
5610 * macrocmd.c: Remove _initialize_macrocmd prototype.
5611 * macroscope.c: Remove _initialize_macroscope prototype.
5612 * maint.c: Remove _initialize_maint_cmds prototype.
5613 * mdebugread.c: Remove _initialize_mdebugread prototype.
5614 * memattr.c: Remove _initialize_mem prototype.
5615 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
5616 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
5617 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
5618 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
5619 * mi/mi-main.c: Remove _initialize_mi_main prototype.
5620 * microblaze-linux-tdep.c: Remove
5621 _initialize_microblaze_linux_tdep prototype.
5622 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
5623 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
5624 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
5625 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
5626 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
5627 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
5628 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
5629 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
5630 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
5631 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
5632 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
5633 prototype.
5634 * mipsread.c: Remove _initialize_mipsread prototype.
5635 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
5636 prototype.
5637 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
5638 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
5639 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
5640 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
5641 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
5642 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
5643 prototype.
5644 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
5645 * nto-procfs.c: Remove _initialize_procfs prototype.
5646 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
5647 * objc-lang.c: Remove _initialize_objc_language prototype.
5648 * objfiles.c: Remove _initialize_objfiles prototype.
5649 * observer.c: Remove observer_test_first_notification_function,
5650 observer_test_second_notification_function,
5651 observer_test_third_notification_function, and
5652 _initialize_observer prototypes.
5653 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
5654 * osabi.c: Remove _initialize_gdb_osabi prototype.
5655 * osdata.c: Remove _initialize_osdata prototype.
5656 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
5657 * parse.c: Remove _initialize_parse prototype.
5658 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
5659 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
5660 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
5661 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
5662 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
5663 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
5664 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
5665 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
5666 * printcmd.c: Remove _initialize_printcmd prototype.
5667 * probe.c: Remove _initialize_probe prototype.
5668 * proc-api.c: Remove _initialize_proc_api prototype.
5669 * proc-events.c: Remove _initialize_proc_events prototype.
5670 * proc-service.c: Remove _initialize_proc_service prototype.
5671 * procfs.c: Remove _initialize_procfs prototype.
5672 * psymtab.c: Remove _initialize_psymtab prototype.
5673 * python/python.c: Remove _initialize_python prototype.
5674 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
5675 * record-btrace.c: Remove _initialize_record_btrace prototype.
5676 * record-full.c: Remove _initialize_record_full prototype.
5677 * record.c: Remove _initialize_record prototype.
5678 * regcache.c: Remove _initialize_regcache prototype.
5679 * reggroups.c: Remove _initialize_reggroup prototype.
5680 * remote-notif.c: Remove _initialize_notif prototype.
5681 * remote-sim.c: Remove _initialize_remote_sim prototype.
5682 * remote.c: Remove _initialize_remote prototype.
5683 * reverse.c: Remove _initialize_reverse prototype.
5684 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
5685 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
5686 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
5687 prototype.
5688 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
5689 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
5690 * rust-exp.y: Remove _initialize_rust_exp prototype.
5691 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
5692 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
5693 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
5694 * score-tdep.c: Remove _initialize_score_tdep prototype.
5695 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
5696 prototype.
5697 * ser-go32.c: Remove _initialize_ser_dos prototype.
5698 * ser-mingw.c: Remove _initialize_ser_windows prototype.
5699 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
5700 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
5701 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
5702 * serial.c: Remove _initialize_serial prototype.
5703 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
5704 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
5705 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
5706 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
5707 * skip.c: Remove _initialize_step_skip prototype.
5708 * sol-thread.c: Remove _initialize_sol_thread prototype.
5709 * solib-aix.c: Remove _initialize_solib_aix prototype.
5710 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
5711 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
5712 * solib-frv.c: Remove _initialize_frv_solib prototype.
5713 * solib-spu.c: Remove _initialize_spu_solib prototype.
5714 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
5715 * solib-target.c: Remove _initialize_solib_target prototype.
5716 * solib.c: Remove _initialize_solib prototype.
5717 * source.c: Remove _initialize_source prototype.
5718 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
5719 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
5720 prototype.
5721 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
5722 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
5723 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
5724 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
5725 prototype.
5726 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
5727 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
5728 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
5729 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
5730 prototype.
5731 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
5732 prototype.
5733 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
5734 prototype.
5735 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
5736 prototype.
5737 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
5738 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
5739 prototype.
5740 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
5741 prototype.
5742 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
5743 prototype.
5744 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
5745 prototype.
5746 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
5747 prototype.
5748 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
5749 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
5750 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
5751 * stabsread.c: Remove _initialize_stabsread prototype.
5752 * stack.c: Remove _initialize_stack prototype.
5753 * stap-probe.c: Remove _initialize_stap_probe prototype.
5754 * std-regs.c: Remove _initialize_frame_reg prototype.
5755 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
5756 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
5757 * symfile.c: Remove _initialize_symfile prototype.
5758 * symmisc.c: Remove _initialize_symmisc prototype.
5759 * symtab.c: Remove _initialize_symtab prototype.
5760 * target-dcache.c: Remove _initialize_target_dcache prototype.
5761 * target-descriptions.c: Remove _initialize_target_descriptions
5762 prototype.
5763 * thread.c: Remove _initialize_thread prototype.
5764 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
5765 prototype.
5766 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
5767 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
5768 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
5769 prototype.
5770 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
5771 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
5772 * tracefile.c: Remove _initialize_tracefile prototype.
5773 * tracepoint.c: Remove _initialize_tracepoint prototype.
5774 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
5775 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
5776 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
5777 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
5778 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
5779 * tui/tui-win.c: Remove _initialize_tui_win prototype.
5780 * tui/tui.c: Remove _initialize_tui prototype.
5781 * typeprint.c: Remove _initialize_typeprint prototype.
5782 * user-regs.c: Remove _initialize_user_regs prototype.
5783 * utils.c: Remove _initialize_utils prototype.
5784 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
5785 * valarith.c: Remove _initialize_valarith prototype.
5786 * valops.c: Remove _initialize_valops prototype.
5787 * valprint.c: Remove _initialize_valprint prototype.
5788 * value.c: Remove _initialize_values prototype.
5789 * varobj.c: Remove _initialize_varobj prototype.
5790 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
5791 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
5792 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
5793 * windows-nat.c: Remove _initialize_windows_nat,
5794 _initialize_check_for_gdb_ini, and _initialize_loadable
5795 prototypes.
5796 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
5797 * xcoffread.c: Remove _initialize_xcoffread prototype.
5798 * xml-support.c: Remove _initialize_xml_support prototype.
5799 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
5800 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
5801 prototype.
5802 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
5803 prototype.
5804 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
5805
5806 2017-09-08 Keith Seitz <keiths@redhat.com>
5807
5808 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
5809 field.
5810
5811 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
5812
5813 * f-valprint.c (f_val_print): Remove check for one byte
5814 sized integers. Remove printing of character type.
5815
5816 2017-09-08 Frank Penczek <frank.penczek@intel.com>
5817 Christoph Weinmann <christoph.t.weinmann@intel.com>
5818 Bernhard Heckel <bernhard.heckel@intel.com>
5819
5820 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
5821 to maintain proper indentation when printing pointers/refs.
5822
5823 2017-09-07 Joel Brobecker <brobecker@adacore.com>
5824
5825 GDB 8.0.1 released.
5826
5827 2017-09-07 Joel Brobecker <brobecker@adacore.com>
5828
5829 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
5830
5831 2017-09-05 Tom Tromey <tom@tromey.com>
5832
5833 * parse.c (funcall_chain): Now a std::vector.
5834 (start_arglist, end_arglist): Simplify.
5835 (free_funcalls): Remove.
5836 (parse_exp_in_context_1): Remove cleanup.
5837
5838 2017-09-05 Tom Tromey <tom@tromey.com>
5839
5840 * go-exp.y (go_parse): Don't create a cleanup.
5841
5842 2017-09-05 Tom Tromey <tom@tromey.com>
5843
5844 * d-exp.y (PrimaryExpression): Use std::string.
5845 (d_parse): Don't create a cleanup.
5846
5847 2017-09-05 Tom Tromey <tom@tromey.com>
5848
5849 * utils.c (do_clear_parser_state): Remove.
5850 (make_cleanup_clear_parser_state): Remove.
5851 * p-exp.y (pascal_parse): Use scoped_restore.
5852 * m2-exp.y (m2_parse): Use scoped_restore.
5853 * f-exp.y (f_parse): Use scoped_restore.
5854 * d-exp.y (d_parse): Use scoped_restore.
5855 * c-exp.y (c_parse): Use scoped_restore.
5856 * ada-exp.y (ada_parse): Use scoped_restore.
5857 * utils.h (make_cleanup_clear_parser_state): Remove.
5858
5859 2017-09-06 Keith Seitz <keiths@redhat.com>
5860
5861 * dwarf2read.c (dw2_linkage_name_attr): New function.
5862 (dw2_linkage_name): New function.
5863 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
5864 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
5865 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
5866
5867 2017-09-06 Kamil Rytarowski <n54@gmx.com>
5868
5869 * config/djgpp/djconfig.sh: Correct shell portability issue.
5870
5871 2017-09-06 Kamil Rytarowski <n54@gmx.com>
5872
5873 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
5874
5875 2017-09-06 John Baldwin <jhb@FreeBSD.org>
5876
5877 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
5878 * NEWS: Mention new FreeBSD/mips native configuration.
5879 * configure.host: Add aarch64*-*-freebsd*.
5880 * configure.nat: Likewise.
5881 * aarch64-fbsd-nat.c: New file.
5882
5883 2017-09-06 John Baldwin <jhb@FreeBSD.org>
5884
5885 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
5886 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
5887 * NEWS: Mention new FreeBSD/aarch64 target.
5888 * configure.tgt: Add aarch64*-*-freebsd*.
5889 * aarch64-fbsd-tdep.c: New file.
5890 * aarch64-fbsd-tdep.h: New file.
5891
5892 2017-09-06 Kamil Rytarowski <n54@gmx.com>
5893
5894 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
5895
5896 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
5897
5898 * parse.c (find_minsym_type_and_address): Don't relocate addresses
5899 of TLS symbols.
5900
5901 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5902
5903 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
5904 call.
5905
5906 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5907
5908 * infrun.c (follow_exec): Call add_thread after
5909 target_find_description.
5910
5911 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5912
5913 * infrun.c (handle_inferior_event_1): When exec'ing, read
5914 stop_pc after follow_exec.
5915
5916 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5917
5918 * remote.c (process_g_packet): Update error message.
5919
5920 2017-09-05 Yao Qi <yao.qi@linaro.org>
5921
5922 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
5923 targets.
5924
5925 2017-09-05 Pedro Alves <palves@redhat.com>
5926
5927 * eval.c (eval_call, evaluate_funcall): New functions, factored
5928 out from ...
5929 (evaluate_subexp_standard): ... this.
5930
5931 2017-09-05 Yao Qi <yao.qi@linaro.org>
5932
5933 * amd64-tdep.c (amd64_target_description): Create target
5934 descriptions.
5935 (_initialize_amd64_tdep): Don't call functions
5936 initialize_tdesc_amd64_*. Add self tests.
5937 * arch/amd64.c (amd64_create_target_description): Add parameter
5938 is_linux. Call set_tdesc_osabi if is_linux is true.
5939 * arch/amd64.h (amd64_create_target_description): Update the
5940 declaration.
5941 * arch/i386.c (i386_create_target_description): Add parameter
5942 is_linux. Call set_tdesc_osabi if is_linux is true.
5943 * arch/i386.h (i386_create_target_description): Update
5944 declaration.
5945 * configure.tgt: Add i386.o to gdb_target_obs.
5946 * features/Makefile (XMLTOC): Remove i386/*.xml.
5947 * features/i386/amd64-avx-avx512.c: Remove.
5948 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
5949 * features/i386/amd64-avx-mpx.c: Remove.
5950 * features/i386/amd64-avx.c: Remove.
5951 * features/i386/amd64-mpx.c: Remove.
5952 * features/i386/amd64.c: Remove.
5953 * features/i386/i386-avx-avx512.c: Remove.
5954 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
5955 * features/i386/i386-avx-mpx.c: Remove.
5956 * features/i386/i386-avx.c: Remove.
5957 * features/i386/i386-mmx.c: Remove.
5958 * features/i386/i386-mpx.c: Remove.
5959 * features/i386/i386.c: Remove.
5960 * i386-tdep.c: Don't include features/i386/i386*.c., include
5961 target-descriptions.h and arch/i386.h.
5962 (i386_target_description): Create target descriptions.
5963 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
5964 functions. Do self tests.
5965
5966 2017-09-05 Yao Qi <yao.qi@linaro.org>
5967
5968 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
5969 * features/i386/amd64-avx-avx512-linux.c: Removed.
5970 * features/i386/amd64-avx-linux.c: Removed.
5971 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
5972 * features/i386/amd64-avx-mpx-linux.c: Removed.
5973 * features/i386/amd64-linux.c: Removed.
5974 * features/i386/amd64-mpx-linux.c: Removed.
5975 * features/i386/x32-avx-avx512-linux.c: Removed.
5976 * features/i386/x32-avx-linux.c: Removed.
5977 * features/i386/x32-linux.c: Removed.
5978
5979 2017-09-05 Yao Qi <yao.qi@linaro.org>
5980
5981 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
5982 features/i386/*.c.
5983 (amd64_linux_read_description): Call
5984 amd64_create_target_description.
5985 * arch/amd64.c: New file.
5986 * arch/amd64.h: New file.
5987 * configure.tgt (x86_64-*-linux*): Append amd64.o.
5988 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
5989
5990 2017-09-05 Yao Qi <yao.qi@linaro.org>
5991
5992 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
5993 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
5994 (amd64_linux_read_description): Create target descriptions.
5995 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
5996 functions. Add unit tests.
5997 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
5998 x32-core.xml.
5999 * features/i386/64bit-avx.c: Generated.
6000 * features/i386/64bit-avx512.c: Generated.
6001 * features/i386/64bit-core.c: Generated.
6002 * features/i386/64bit-linux.c: Generated.
6003 * features/i386/64bit-mpx.c: Generated.
6004 * features/i386/64bit-pkeys.c: Generated.
6005 * features/i386/64bit-segments.c: Generated.
6006 * features/i386/64bit-sse.c: Generated.
6007 * features/i386/x32-core.c: Generated.
6008 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
6009 c files for amd64-linux and x32-linux.
6010
6011 2017-09-05 Yao Qi <yao.qi@linaro.org>
6012
6013 * amd64-linux-tdep.c (amd64_linux_read_description): New
6014 function.
6015 (amd64_linux_core_read_description): Call
6016 amd64_linux_read_description.
6017 (amd64_linux_init_abi): Likewise.
6018 (amd64_x32_linux_init_abi): Likewise.
6019 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
6020 * x86-linux-nat.c (x86_linux_read_description): Call
6021 amd64_linux_read_description.
6022
6023 2017-09-05 Yao Qi <yao.qi@linaro.org>
6024
6025 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
6026 comments.
6027
6028 2017-09-05 Yao Qi <yao.qi@linaro.org>
6029
6030 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
6031 * features/i386/i386-avx-avx512-linux.c: Remove.
6032 * features/i386/i386-avx-linux.c: Remove.
6033 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
6034 * features/i386/i386-avx-mpx-linux.c: Remove.
6035 * features/i386/i386-linux.c: Remove.
6036 * features/i386/i386-mmx-linux.c: Remove.
6037 * features/i386/i386-mpx-linux.c: Remove.
6038
6039 2017-09-05 Yao Qi <yao.qi@linaro.org>
6040
6041 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
6042 (SFILES): Add arch/i386.c.
6043 (HFILES_NO_SRCDIR): Add arch/i386.h.
6044 * arch/i386.c: New file.
6045 * arch/i386.h: New file.
6046 * arch/tdesc.h (allocate_target_description): Declare.
6047 (set_tdesc_architecture): Declare.
6048 (set_tdesc_osabi): Declare.
6049 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
6050 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
6051 include arch/i386.h.
6052 (i386_linux_read_description): Remove code and call
6053 i386_create_target_description.
6054 (set_tdesc_architecture): New function.
6055 (set_tdesc_osabi): New function.
6056 * target-descriptions.h (allocate_target_description): Remove.
6057
6058 2017-09-05 Yao Qi <yao.qi@linaro.org>
6059
6060 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
6061 * target-descriptions.c (tdesc_create_feature): Likewise, and
6062 adjust code.
6063 * features/i386/32bit-avx.c: Re-generated.
6064 * features/i386/32bit-avx512.c: Re-generated.
6065 * features/i386/32bit-core.c: Re-generated.
6066 * features/i386/32bit-linux.c: Re-generated.
6067 * features/i386/32bit-mpx.c: Re-generated.
6068 * features/i386/32bit-pkeys.c: Re-generated.
6069 * features/i386/32bit-sse.c: Re-generated.
6070
6071 2017-09-05 Yao Qi <yao.qi@linaro.org>
6072
6073 * regformats/regdef.h (struct reg): Override operator == and !=.
6074
6075 2017-09-05 Yao Qi <yao.qi@linaro.org>
6076
6077 * arch/tdesc.h: New file.
6078 * regformats/regdat.sh: Generate code using tdesc_create_reg.
6079 * target-descriptions.c: Update comments.
6080 * target-descriptions.h: Include "arch/tdesc.h". Remove the
6081 declarations.
6082 * features/i386/32bit-avx.c: Re-generated.
6083 * features/i386/32bit-avx512.c: Re-generated.
6084 * features/i386/32bit-core.c: Re-generated.
6085 * features/i386/32bit-linux.c: Re-generated.
6086 * features/i386/32bit-mpx.c: Re-generated.
6087 * features/i386/32bit-pkeys.c: Re-generated.
6088 * features/i386/32bit-sse.c: Re-generated.
6089
6090 2017-09-05 Yao Qi <yao.qi@linaro.org>
6091
6092 * regformats/regdat.sh: Update generated code.
6093
6094 2017-09-05 Yao Qi <yao.qi@linaro.org>
6095
6096 * regformats/regdat.sh: Adjust code order.
6097
6098 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6099
6100 * expprint.c (dump_subexp_body_standard): Use constant format
6101 string in fprintf_filtered call.
6102
6103 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6104
6105 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
6106 NetBSD/i386.
6107 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
6108
6109 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6110
6111 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
6112
6113 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6114
6115 * bsd-kvm.o: Define _KMEMUSER.
6116 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
6117 * configure: Regenerate.
6118
6119 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6120
6121 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
6122 * i386-fbsd-nat.c: Likewise.
6123
6124 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6125
6126 * unittests/array-view-selftests.c: Add include of <array>.
6127
6128 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6129
6130 * spu-tdep.c (flush_ea_cache): Add missing argument to
6131 call_function_by_hand.
6132
6133 2017-09-04 Pedro Alves <palves@redhat.com>
6134
6135 * NEWS (Safer support for debugging with no debug info): New.
6136
6137 2017-09-04 Pedro Alves <palves@redhat.com>
6138
6139 * c-exp.y (function_method, function_method_void): Add current
6140 instance flags to TYPE_INSTANCE.
6141 * dwarf2read.c (check_modifier): New.
6142 (compute_delayed_physnames): Assert that only C++ adds delayed
6143 physnames. Mark fn_fields as const/volatile depending on
6144 physname.
6145 * eval.c (make_params): New type_instance_flags parameter. Use
6146 it as the new type's instance flags.
6147 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
6148 flags element and pass it to make_params.
6149 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
6150 instance flags element.
6151 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
6152 * gdbtypes.h: Include "enum-flags.h".
6153 (type_instance_flags): New enum-flags type.
6154 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
6155 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
6156 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
6157 (follow_type_instance_flags): New function.
6158 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
6159 * parser-defs.h (follow_type_instance_flags): Declare.
6160 * valops.c (value_struct_elt_for_reference): const/volatile must
6161 match too.
6162
6163 2017-09-04 Pedro Alves <palves@redhat.com>
6164
6165 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
6166 function/method scopes; lookup the nested name as a function local
6167 static variable.
6168
6169 2017-09-04 Pedro Alves <palves@redhat.com>
6170
6171 (%type <voidval>): Add function_method.
6172 * c-exp.y (exp): New production for calls with no arguments.
6173 (function_method, function_method_void_or_typelist): New
6174 productions.
6175 (exp): New production for "method()::static_var".
6176 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
6177 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6178 Handle OP_FUNC_STATIC_VAR.
6179 * parse.c (operator_length_standard):
6180 Handle OP_FUNC_STATIC_VAR.
6181
6182 2017-09-04 Pedro Alves <palves@redhat.com>
6183
6184 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
6185 handling.
6186 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6187 Ditto.
6188 * parse.c (operator_length_standard, operator_check_standard):
6189 Ditto.
6190 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
6191
6192 2017-09-04 Pedro Alves <palves@redhat.com>
6193
6194 * ax-gdb.c: Include "typeprint.h".
6195 (gen_expr_for_cast): New function.
6196 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
6197 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
6198 type is unknown.
6199 * dwarf2read.c (new_symbol_full): Fallback to int instead of
6200 nodebug_data_symbol.
6201 * eval.c: Include "typeprint.h".
6202 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
6203 Error out if symbol has unknown type.
6204 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
6205 evaluate_subexp_for_cast.
6206 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
6207 OP_VAR_MSYM_VALUE.
6208 (evaluate_subexp_for_cast): New function.
6209 * gdbtypes.c (init_nodebug_var_type): New function.
6210 (objfile_type): Use it to initialize types of variables with no
6211 debug info.
6212 * typeprint.c (error_unknown_type): New.
6213 * typeprint.h (error_unknown_type): New declaration.
6214 * compile/compile-c-types.c (convert_type_basic): Handle
6215 TYPE_CODE_ERROR; warn and fallback to int for variables with
6216 unknown type.
6217
6218 2017-09-04 Pedro Alves <palves@redhat.com>
6219
6220 * eval.c (evaluate_var_value): New function, factored out from ...
6221 (evaluate_subexp_standard): ... here.
6222
6223 2017-09-04 Pedro Alves <palves@redhat.com>
6224
6225 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
6226 Remove useless assignments to 'op'.
6227
6228 2017-09-04 Pedro Alves <palves@redhat.com>
6229
6230 * eval.c (eval_skip_value): New function.
6231 (evaluate_subexp_standard): Use it.
6232
6233 2017-09-04 Pedro Alves <palves@redhat.com>
6234
6235 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
6236 function name from symbol/minsym and pass it to
6237 error_call_unknown_return_type.
6238
6239 2017-09-04 Pedro Alves <palves@redhat.com>
6240
6241 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
6242 * ax-gdb.c (gen_msym_var_ref): New function.
6243 (gen_expr): Handle OP_VAR_MSYM_VALUE.
6244 * eval.c (evaluate_var_msym_value): New function.
6245 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
6246 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
6247 to call_function_by_hand.
6248 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6249 Handle OP_VAR_MSYM_VALUE.
6250 (union exp_element) <msymbol>: New field.
6251 * minsyms.h (struct type): Forward declare.
6252 (find_minsym_type_and_address): Declare.
6253 * parse.c (write_exp_elt_msym): New function.
6254 (write_exp_msymbol): Delete, refactored as ...
6255 (find_minsym_type_and_address): ... this new function.
6256 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
6257 (operator_length_standard, operator_check_standard): Handle
6258 OP_VAR_MSYM_VALUE.
6259 * std-operator.def (OP_VAR_MSYM_VALUE): New.
6260
6261 2017-09-04 Pedro Alves <palves@redhat.com>
6262
6263 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
6264 TYPE_GNU_IFUNC specially here. Throw error if return type is
6265 unknown.
6266 * ada-typeprint.c (print_func_type): Handle functions with unknown
6267 return type.
6268 * c-typeprint.c (c_type_print_base): Handle functions and methods
6269 with unknown return type.
6270 * compile/compile-c-symbols.c (convert_symbol_bmsym)
6271 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
6272 * compile/compile-c-types.c: Include "objfiles.h".
6273 (convert_func): For functions with unknown return type, warn and
6274 default to int.
6275 * compile/compile-object-run.c (compile_object_run): Adjust call
6276 to call_function_by_hand_dummy.
6277 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
6278 call_function_by_hand.
6279 * eval.c (evaluate_subexp_standard): Adjust calls to
6280 call_function_by_hand. Handle functions and methods with unknown
6281 return type. Pass expect_type to call_function_by_hand.
6282 * f-typeprint.c (f_type_print_base): Handle functions with unknown
6283 return type.
6284 * gcore.c (call_target_sbrk): Adjust call to
6285 call_function_by_hand.
6286 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
6287 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
6288 an integer address type instead of nodebug.
6289 * guile/scm-value.c (gdbscm_value_call): Adjust call to
6290 call_function_by_hand.
6291 * infcall.c (error_call_unknown_return_type): New function.
6292 (call_function_by_hand): New "default_return_type" parameter.
6293 Pass it down.
6294 (call_function_by_hand_dummy): New "default_return_type"
6295 parameter. Use it instead of defaulting to int. If there's no
6296 default and the return type is unknown, throw an error. If
6297 there's a default return type, and the called function has no
6298 debug info, then assume the function is prototyped.
6299 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
6300 New "default_return_type" parameter.
6301 (error_call_unknown_return_type): New declaration.
6302 * linux-fork.c (call_lseek): Cast return type of lseek.
6303 (inferior_call_waitpid, checkpoint_command): Adjust calls to
6304 call_function_by_hand.
6305 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
6306 calls to call_function_by_hand.
6307 * m2-typeprint.c (m2_procedure): Handle functions with unknown
6308 return type.
6309 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6310 (value_nsstring, print_object_command): Adjust calls to
6311 call_function_by_hand.
6312 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
6313 functions with unknown return type.
6314 (pascal_type_print_func_varspec_suffix): New function.
6315 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
6316 TYPE_CODE_METHOD>: Use it.
6317 * python/py-value.c (valpy_call): Adjust call to
6318 call_function_by_hand.
6319 * rust-lang.c (rust_evaluate_funcall): Adjust call to
6320 call_function_by_hand.
6321 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
6322 call_function_by_hand.
6323 * valops.c (value_allocate_space_in_inferior): Adjust call to
6324 call_function_by_hand.
6325 * typeprint.c (type_print_unknown_return_type): New function.
6326 * typeprint.h (type_print_unknown_return_type): New declaration.
6327
6328 2017-09-04 Pedro Alves <palves@redhat.com>
6329
6330 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
6331 types with more than one parameter as prototyped.
6332
6333 2017-09-04 Pedro Alves <palves@redhat.com>
6334
6335 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
6336 (disassemble_command): Use gdb_disassembly_flags instead of bare
6337 int.
6338 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
6339 (dump_insns, do_mixed_source_and_assembly_deprecated)
6340 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
6341 Use gdb_disassembly_flags instead of bare int.
6342 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
6343 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
6344 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
6345 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
6346 (enum gdb_disassembly_flag): ... values of this new enumeration.
6347 (gdb_disassembly_flags): Define.
6348 (gdb_disassembly)
6349 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
6350 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
6351 gdb_disassembly_flags instead of bare int.
6352 * record-btrace.c (btrace_insn_history)
6353 (record_btrace_insn_history, record_btrace_insn_history_range)
6354 (record_btrace_insn_history_from): Use gdb_disassembly_flags
6355 instead of bare int.
6356 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
6357 Use gdb_disassembly_flags instead of bare int.
6358 * target-debug.h (target_debug_print_gdb_disassembly_flags):
6359 Define.
6360 * target-delegates.c: Regenerate.
6361 * target.c (target_insn_history, target_insn_history_from)
6362 (target_insn_history_range): Use gdb_disassembly_flags instead of
6363 bare int.
6364 * target.h: Include "disasm.h".
6365 (struct target_ops) <to_insn_history, to_insn_history_from,
6366 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
6367 int.
6368 (target_insn_history, target_insn_history_from)
6369 (target_insn_history_range): Use gdb_disassembly_flags instead of
6370 bare int.
6371
6372 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6373
6374 * cli/cli-script.c (build_command_line): For if/while commands,
6375 check whether args is empty.
6376
6377 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6378
6379 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
6380 (enum command_control_type): Likewise.
6381 (struct command_line): Likewise.
6382 (free_command_lines): Likewise.
6383 (struct command_lines_deleter): Likewise.
6384 (command_line_up): Likewise.
6385 (read_command_lines): Likewise.
6386 (read_command_lines_1): Likewise.
6387 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
6388 (enum command_control_type): Likewise.
6389 (struct command_line): Likewise.
6390 (free_command_lines): Likewise.
6391 (struct command_lines_deleter): Likewise.
6392 (command_line_up): Likewise.
6393 (read_command_lines): Likewise.
6394 (read_command_lines_1): Likewise.
6395 * breakpoint.h: Include cli/cli-script.h.
6396 * extension-priv.h: Likewise.
6397 * gdbcmd.h: Likewise.
6398
6399 2017-09-04 Pedro Alves <palves@redhat.com>
6400
6401 * ada-lang.c (is_known_support_routine): Move sal declaration to
6402 where it is initialized.
6403 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
6404 (parse_breakpoint_sals, decode_static_tracepoint_spec)
6405 (clear_command, update_static_tracepoint): Remove init_sal
6406 references. Move declarations closer to initializations.
6407 * cli/cli-cmds.c (list_command): Move sal declarations closer to
6408 initializations.
6409 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
6410 references. Move sal declarations closer to initializations.
6411 * frame.c (find_frame_sal): Return a symtab_and_line via function
6412 return instead of output parameter. Remove init_sal references.
6413 * frame.h (find_frame_sal): Return a symtab_and_line via function
6414 return instead of output parameter.
6415 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
6416 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
6417 instead of memset.
6418 (gdbscm_find_pc_line): Remove init_sal reference.
6419 * infcall.c (call_function_by_hand_dummy): Remove init_sal
6420 references. Move declarations closer to initializations.
6421 * infcmd.c (set_step_frame): Update. Move declarations closer to
6422 initializations.
6423 (finish_backward): Remove init_sal references. Move declarations
6424 closer to initializations.
6425 * infrun.c (process_event_stop_test, handle_step_into_function)
6426 (insert_hp_step_resume_breakpoint_at_frame)
6427 (insert_step_resume_breakpoint_at_caller): Likewise.
6428 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
6429 (symbol_to_sal): Likewise.
6430 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
6431 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
6432 to its initialization.
6433 * reverse.c (save_bookmark_command): Use new/delete. Remove
6434 init_sal references. Move declarations closer to initializations.
6435 * source.c (get_current_source_symtab_and_line): Remove brace
6436 initialization.
6437 (set_current_source_symtab_and_line): Now takes the sal by const
6438 reference. Remove brace initialization.
6439 (line_info): Remove init_sal reference.
6440 * source.h (set_current_source_symtab_and_line): Now takes a
6441 symtab_and_line via const reference.
6442 * stack.c (set_current_sal_from_frame): Adjust.
6443 (print_frame_info): Adjust.
6444 (get_last_displayed_sal): Return the sal via function return
6445 instead of via output parameter. Simplify.
6446 (frame_info): Adjust.
6447 * stack.h (get_last_displayed_sal): Return the sal via function
6448 return instead of via output parameter.
6449 * symtab.c (init_sal): Delete.
6450 (find_pc_sect_line): Remove init_sal references. Move
6451 declarations closer to initializations.
6452 (find_function_start_sal): Remove init_sal references. Move
6453 declarations closer to initializations.
6454 * symtab.h (struct symtab_and_line): In-class initialize all
6455 fields.
6456 * tracepoint.c (set_traceframe_context)
6457 (print_one_static_tracepoint_marker): Remove init_sal references.
6458 Move declarations closer to initializations.
6459 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
6460 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
6461 declarations closer to initializations.
6462 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
6463 init_sal references. Adjust.
6464
6465 2017-09-04 Pedro Alves <palves@redhat.com>
6466
6467 * ax-gdb.c (agent_command_1): Use range-for.
6468 * break-catch-throw.c (re_set_exception_catchpoint): Update.
6469 * breakpoint.c: Include "common/array-view.h".
6470 (init_breakpoint_sal, create_breakpoint_sal): Change sals
6471 parameter from struct symtabs_and_lines to
6472 array_view<symtab_and_line>. Adjust. Use range-for. Update.
6473 (breakpoint_sals_to_pc): Change sals parameter from struct
6474 symtabs_and_lines to std::vector reference.
6475 (check_fast_tracepoint_sals): Change sals parameter from struct
6476 symtabs_and_lines to std::array_view. Use range-for.
6477 (decode_static_tracepoint_spec): Return a std::vector instead of
6478 symtabs_and_lines. Update.
6479 (create_breakpoint): Update.
6480 (break_range_command, until_break_command, clear_command): Update.
6481 (base_breakpoint_decode_location, bkpt_decode_location)
6482 (bkpt_probe_create_sals_from_location)
6483 (bkpt_probe_decode_location, tracepoint_decode_location)
6484 (tracepoint_probe_decode_location)
6485 (strace_marker_create_sals_from_location): Return a std::vector
6486 instead of symtabs_and_lines.
6487 (strace_marker_create_breakpoints_sal): Update.
6488 (strace_marker_decode_location): Return a std::vector instead of
6489 symtabs_and_lines. Update.
6490 (update_breakpoint_locations): Change struct symtabs_and_lines
6491 parameters to gdb::array_view. Adjust.
6492 (location_to_sals): Return a std::vector instead of
6493 symtabs_and_lines. Update.
6494 (breakpoint_re_set_default): Use std::vector instead of struct
6495 symtabs_and_lines.
6496 (decode_location_default): Return a std::vector instead of
6497 symtabs_and_lines. Update.
6498 * breakpoint.h: Include "common/array-view.h".
6499 (struct breakpoint_ops) <decode_location>: Now returns a
6500 std::vector instead of returning a symtabs_and_lines via output
6501 parameter.
6502 (update_breakpoint_locations): Change sals parameters to use
6503 gdb::array_view.
6504 * cli/cli-cmds.c (edit_command, list_command): Update to use
6505 std::vector and gdb::array_view.
6506 (ambiguous_line_spec): Adjust to use gdb::array_view and
6507 range-for.
6508 (compare_symtabs): Rename to ...
6509 (cmp_symtabs): ... this. Change parameters to symtab_and_line
6510 const reference and adjust.
6511 (filter_sals): Rewrite using std::vector and standard algorithms.
6512 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
6513 (jump_command): Update to use std::vector.
6514 * linespec.c (struct linespec_state) <canonical_names>: Update
6515 comment.
6516 (add_sal_to_sals_basic): Delete.
6517 (add_sal_to_sals, filter_results, convert_results_to_lsals)
6518 (decode_line_2, create_sals_line_offset)
6519 (convert_address_location_to_sals, convert_linespec_to_sals)
6520 (convert_explicit_location_to_sals, parse_linespec)
6521 (event_location_to_sals, decode_line_full, decode_line_1)
6522 (decode_line_with_current_source)
6523 (decode_line_with_last_displayed, decode_objc)
6524 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
6525 (linespec_result::~linespec_result): Adjust to use std::vector
6526 instead of symtabs_and_lines.
6527 * linespec.h (linespec_sals::sals): Now a std::vector.
6528 (struct linespec_result): Use std::vector, bool, and in-class
6529 initialization.
6530 (decode_line_1, decode_line_with_current_source)
6531 (decode_line_with_last_displayed): Return std::vector.
6532 * macrocmd.c (info_macros_command): Use std::vector.
6533 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
6534 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
6535 std::vector.
6536 * probe.h (parse_probes): Return a std::vector.
6537 * python/python.c (gdbpy_decode_line): Use std::vector and
6538 gdb::array_view.
6539 * source.c (select_source_symtab, line_info): Use std::vector.
6540 * stack.c (func_command): Use std::vector.
6541 * symtab.h (struct symtabs_and_lines): Delete.
6542 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
6543
6544 2017-09-04 Pedro Alves <palves@redhat.com>
6545
6546 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6547 unittests/array-view-selftests.c.
6548 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
6549 * common/array-view.h: New file.
6550 * unittests/array-view-selftests.c: New file.
6551
6552 2017-09-04 Pedro Alves <palves@redhat.com>
6553
6554 * cli/cli-cmds.c (edit_command): Pass message to
6555 ambiguous_line_spec.
6556 (list_command): Pass message to ambiguous_line_spec. Say
6557 "first"/"last" instead of "start" and "end" to be consistent with
6558 the manual.
6559 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
6560 them to print formatted message.
6561
6562 2017-09-04 Pedro Alves <palves@redhat.com>
6563
6564 * btrace.c (ftrace_add_pt): Pass btrace_insn to
6565 ftrace_update_insns by reference instead of pointer.
6566
6567 2017-09-04 Yao Qi <yao.qi@linaro.org>
6568
6569 * i386-go32-tdep.c: Include x86-xstate.h.
6570 (i386_go32_init_abi): Call i386_target_description.
6571 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
6572 if xcr0 is X86_XSTATE_X87_MASK.
6573 * i386-tdep.h (tdesc_i386): Remove the declaration.
6574 (tdesc_i386_mmx): Likewise.
6575
6576 2017-09-04 Yao Qi <yao.qi@linaro.org>
6577
6578 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
6579 X86_XSTATE_SSE_MASK instead of 0.
6580
6581 2017-09-04 Yao Qi <yao.qi@linaro.org>
6582
6583 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
6584 i386_target_description.
6585 * i386-fbsd-nat.c (i386fbsd_read_description): Call
6586 i386_target_description.
6587 * i386-tdep.c (i386_gdbarch_init): Likewise.
6588
6589 2017-09-04 Yao Qi <yao.qi@linaro.org>
6590
6591 * amd64-darwin-tdep.c: Include "x86-xstate.h".
6592 (x86_darwin_init_abi_64): Call amd64_target_description.
6593 * amd64-dicos-tdep.c: Likewise.
6594 * amd64-fbsd-nat.c: Likewise.
6595 * amd64-fbsd-tdep.c: Likewise.
6596 * amd64-nbsd-tdep.c: Likewise.
6597 * amd64-obsd-tdep.c: Likewise.
6598 * amd64-sol2-tdep.c: Likewise.
6599 * amd64-windows-tdep.c: Likewise.
6600 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
6601
6602 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6603
6604 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
6605 (btrace_function) <insn>: Change type to use std::vector.
6606 * btrace.c (ftrace_debug, ftrace_call_num_insn,
6607 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
6608 ftrace_update_insns, ftrace_compute_global_level_offset,
6609 btrace_stitch_bts, btrace_clear, btrace_insn_get,
6610 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
6611 change to std::vector.
6612 (ftrace_update_insns): Adjust to change to std::vector, change
6613 type of INSN parameter.
6614 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
6615 * record-btrace.c (btrace_call_history_insn_range,
6616 btrace_compute_src_line_range,
6617 record_btrace_frame_prev_register): Adjust to change to
6618 std::vector.
6619 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
6620 to change to std::vector.
6621
6622 2017-09-03 Tom Tromey <tom@tromey.com>
6623
6624 * corefile.c (reopen_exec_file): Use std::string.
6625
6626 2017-09-03 Tom Tromey <tom@tromey.com>
6627
6628 * compile/compile.c (compile_register_name_mangled): Return
6629 std::string.
6630 * compile/compile-loc2c.c (pushf_register_address): Update.
6631 (pushf_register): Update.
6632 * compile/compile-c-types.c (convert_array): Update.
6633 * compile/compile-c-symbols.c (generate_vla_size): Update.
6634 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
6635 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
6636 (convert_one_symbol): Update.
6637 (generate_c_for_for_one_variable): Update.
6638 * compile/compile-c-support.c (c_get_range_decl_name): Return a
6639 std::string.
6640 (generate_register_struct): Update.
6641 * compile/compile-internal.h (c_get_range_decl_name): Return a
6642 std::string.
6643 (compile_register_name_mangled): Return std::string.
6644
6645 2017-09-03 Tom Tromey <tom@tromey.com>
6646
6647 * utils.c (perror_string): Return a std::string.
6648 (throw_perror_with_name, perror_warning_with_name): Update.
6649
6650 2017-09-03 Tom Tromey <tom@tromey.com>
6651
6652 * demangle.c (demangle_command): Use std::string,
6653 unique_xmalloc_ptr.
6654
6655 2017-09-03 Tom Tromey <tom@tromey.com>
6656
6657 * cli/cli-setshow.c (do_set_command): Use std::string.
6658
6659 2017-09-03 Tom Tromey <tom@tromey.com>
6660
6661 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
6662
6663 2017-09-03 Tom Tromey <tom@tromey.com>
6664
6665 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
6666
6667 2017-09-03 Tom Tromey <tom@tromey.com>
6668
6669 * mi/mi-cmd-env.c (env_execute_cli_command): Use
6670 gdb::unique_xmalloc_ptr.
6671
6672 2017-09-03 Tom Tromey <tom@tromey.com>
6673
6674 * thread.c (print_thread_info_1): Use string_printf.
6675 (thread_apply_command, thread_apply_all_command): Use
6676 std::string.
6677
6678 2017-09-03 Tom Tromey <tom@tromey.com>
6679
6680 * valprint.c (val_print_string): Update.
6681 * gdbcore.h (memory_error_message): Return std::string.
6682 * corefile.c (memory_error_message): Return std::string.
6683 (memory_error): Update.
6684 * breakpoint.c (insert_bp_location): Update.
6685
6686 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6687
6688 * target/waitstatus.h (target_waitstatus_to_string): Change
6689 return type to std::string.
6690 * target/waitstatus.c (target_waitstatus_to_string): Return
6691 std::string.
6692 * target.h (target_waitstatus_to_string): Remove declaration.
6693 * infrun.c (resume, clear_proceed_status_thread,
6694 print_target_wait_results, do_target_wait, save_waitstatus,
6695 stop_all_threads): Adjust.
6696 * record-btrace.c (record_btrace_wait): Adjust.
6697 * target-debug.h
6698 (target_debug_print_struct_target_waitstatus_p): Adjust.
6699
6700 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
6701
6702 PR gdb/22046
6703 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
6704 detection.
6705
6706 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6707
6708 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
6709 for setting/unsetting environment variables on the remote target.
6710 (New remote packets): Add entries for QEnvironmentHexEncoded,
6711 QEnvironmentUnset and QEnvironmentReset.
6712 * common/environ.c (gdb_environ::operator=): Extend method to
6713 handle m_user_set_env_list and m_user_unset_env_list.
6714 (gdb_environ::clear): Likewise.
6715 (match_var_in_string): Change type of first parameter from 'char
6716 *' to 'const char *'.
6717 (gdb_environ::set): Extend method to handle
6718 m_user_set_env_list and m_user_unset_env_list.
6719 (gdb_environ::unset): Likewise.
6720 (gdb_environ::clear_user_set_env): New method.
6721 (gdb_environ::user_set_envp): Likewise.
6722 (gdb_environ::user_unset_envp): Likewise.
6723 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
6724 m_user_unset_env_list on move constructor/assignment.
6725 (unset): Add new default parameter 'update_unset_list = true'.
6726 (clear_user_set_env): New method.
6727 (user_set_envp): Likewise.
6728 (user_unset_envp): Likewise.
6729 (m_user_set_env_list): New std::set.
6730 (m_user_unset_env_list): Likewise.
6731 * common/rsp-low.c (hex2str): New function.
6732 (bin2hex): New overload for bin2hex function.
6733 * common/rsp-low.c (hex2str): New prototype.
6734 (str2hex): New overload prototype.
6735 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
6736 QEnvironmentUnset and QEnvironmentReset.
6737 (remote_protocol_features): Add QEnvironmentHexEncoded,
6738 QEnvironmentUnset and QEnvironmentReset packets.
6739 (send_environment_packet): New function.
6740 (extended_remote_environment_support): Likewise.
6741 (extended_remote_create_inferior): Call
6742 extended_remote_environment_support.
6743 (_initialize_remote): Add QEnvironmentHexEncoded,
6744 QEnvironmentUnset and QEnvironmentReset packet configs.
6745 * unittests/environ-selftests.c (gdb_selftest_env_var):
6746 New variable.
6747 (test_vector_initialization): New function.
6748 (test_init_from_host_environ): Likewise.
6749 (test_reinit_from_host_environ): Likewise.
6750 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
6751 Likewise.
6752 (test_unset_set_empty_vector): Likewise.
6753 (test_vector_clear): Likewise.
6754 (test_std_move): Likewise.
6755 (test_move_constructor):
6756 (test_self_move): Likewise.
6757 (test_set_unset_reset): Likewise.
6758 (run_tests): Rewrite in terms of the functions above.
6759
6760 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
6761
6762 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
6763 (adi_available): Use a temp variable of type CORE_ADDR as argument
6764 3 when calling target_auxv_search.
6765 (adi_normalize_address): Use masks and xor operators to calculate
6766 normalized address.
6767 (adi_read_versions, adi_write_versions, adi_print_versions)
6768 (do_examine, do_assign): Use paddress.
6769
6770 2017-08-29 John Baldwin <jhb@FreeBSD.org>
6771
6772 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
6773 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
6774 out of loop and add supply of FIR.
6775 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
6776 add collect of FIR.
6777
6778 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
6779
6780 PR gdb/21827
6781 * cli/cli-script.c (define_command): Don't convert command name
6782 to lower case.
6783
6784 2017-08-25 Joel Brobecker <brobecker@adacore.com>
6785
6786 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
6787 Update all callers accordingly. Remove all code blocks handling
6788 the case where DISPP is not NULL.
6789
6790 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6791
6792 PR symtab/22003
6793 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
6794 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6795 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
6796
6797 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6798
6799 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
6800 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
6801 (read_comp_units_from_section): New parameter abbrev_section, use
6802 read_and_check_comp_unit_head, allocate signatured_type if needed.
6803 (create_all_comp_units): Update read_comp_units_from_section caller.
6804
6805 2017-08-23 Pedro Alves <palves@redhat.com>
6806
6807 PR remote/21852
6808 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
6809 to null_ptid and switch to thread without reading the registers
6810 after adding the inferior.
6811
6812 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
6813
6814 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
6815 compile-gcc.
6816 * compile/compile.c (compile_gcc, show_compile_gcc): New.
6817 (compile_to_object): Implement compile_gcc.
6818 (_initialize_compile): Install "set compile-gcc". Initialize
6819 compile_gcc.
6820
6821 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
6822
6823 * compile/compile.c (compile_to_object): Conditionally call
6824 set_verbose. Conditionally call compile or compile_v0.
6825
6826 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
6827
6828 * sparc64-tdep.h: (adi_normalize_address): New export.
6829 * sparc-nat.h: (open_adi_tag_fd): New export.
6830 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
6831 * sparc64-linux-tdep.c:
6832 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
6833 (sparc64_linux_handle_segmentation_fault): New function.
6834 (sparc64_linux_init_abi): Register
6835 sparc64_linux_handle_segmentation_fault
6836 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
6837 (sparc64_addr_bits_remove): New function.
6838 (sparc64_init_abi): Register sparc64_addr_bits_remove.
6839 (MAX_PROC_NAME_SIZE): New macro.
6840 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
6841 (sparc64adilist): New variable.
6842 (adi_proc_list): New variable.
6843 (find_adi_info): New function.
6844 (add_adi_info): New function.
6845 (get_adi_info_proc): New function.
6846 (get_adi_info): New function.
6847 (info_adi_command): New function.
6848 (read_maps_entry): New function.
6849 (adi_available): New function.
6850 (adi_normalize_address): New function.
6851 (adi_align_address): New function.
6852 (adi_convert_byte_count): New function.
6853 (adi_tag_fd): New function.
6854 (adi_is_addr_mapped): New function.
6855 (adi_read_versions): New function.
6856 (adi_write_versions): New function.
6857 (adi_print_versions): New function.
6858 (do_examine): New function.
6859 (do_assign): New function.
6860 (adi_examine_command): New function.
6861 (adi_assign_command): New function.
6862 (_initialize_sparc64_adi_tdep): New function.
6863
6864 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
6865
6866 * breakpoint.c (breakpoints_info): Rename to ...
6867 (info_breakpoints_command): ... this.
6868 (watchpoints_info): Rename to ...
6869 (info_watchpoints_command): ... this.
6870 (tracepoints_info): Rename to ...
6871 (info_tracepoints_command): ... this.
6872 (_initialize_breakpoint): Adjust.
6873 * dcache.c (dcache_info): Rename to ...
6874 (info_display_command): ... this.
6875 (_initialize_dcache): Adjust.
6876 * frame.h (args_info): Rename to ...
6877 (info_args_command): ... this.
6878 (locals_info): Rename to ...
6879 (info_locals_command): ... this.
6880 * infcmd.c (nofp_registers_info): Rename to ...
6881 (info_registers_command): ... this.
6882 (float_info): Rename to ...
6883 (info_float_command): ... this.
6884 (program_info): Rename to ...
6885 (info_program_command): ... this.
6886 (all_registers_info): Rename to ...
6887 (info_all_registers_command): ... this.
6888 (vector_info): Rename to ...
6889 (info_vector_command): ... this.
6890 (float_info): Rename to ...
6891 (info_float_command): ... this.
6892 (_initialize_infcmd): Adjust.
6893 * inferior.h (term_info): Rename to ...
6894 (info_terminal_command): ... this.
6895 * inflow.c (term_info): Rename to ...
6896 (info_terminal_command): ... this.
6897 (_initialize_inflow): Adjust.
6898 * infrun.c (signals_info): Rename to ...
6899 (info_signals_command): ... this.
6900 (_initialize_infrun): Adjust.
6901 * objc-lang.c (classes_info): Rename to ...
6902 (info_classes_command): ... this.
6903 (selectors_info): Rename to ...
6904 (info_selectors_command): ... this.
6905 (_initialize_objc_language): Adjust.
6906 * printcmd.c (sym_info): Rename to ...
6907 (info_symbol_command): ... this.
6908 (address_info): Rename to ...
6909 (info_address_command): ... this.
6910 (display_info): Rename to ...
6911 (info_display_command): ... this.
6912 (_initialize_printcmd): Adjust.
6913 * reverse.c (bookmarks_info): Rename to ...
6914 (info_breakpoints_command): ... this.
6915 (_initialize_reverse): Adjust.
6916 * ser-go32.c (dos_info): Rename to ...
6917 (info_serial_command): ... this.
6918 (_initialize_ser_dos): Adjust.
6919 * skip.c (skip_info): Rename to ...
6920 (info_skip_command): ... this.
6921 (_initialize_step_skip): Adjust.
6922 * source.c (line_info): Rename to ...
6923 (info_line_command): ... this.
6924 (source_info): Rename to ...
6925 (info_source_command)
6926 * stack.c (frame_info): Rename to ...
6927 (info_frame_command): ... this.
6928 (locals_info): Rename to ...
6929 (info_locals_command): ... this.
6930 (args_info): Rename to ...
6931 (info_args_command): ... this.
6932 (_initialize_stack): Adjust.
6933 * symtab.c (sources_info): Rename to ...
6934 (info_sources_command): ... this.
6935 (variables_info): Rename to ...
6936 (info_variables_command): ... this.
6937 (functions_info): Rename to ...
6938 (info_functions_command): ... this.
6939 (types_info): Rename to ...
6940 (info_types_command): ... this.
6941 (_initialize_symtab): Adjust.
6942 * target.c (target_info): Rename to ...
6943 (info_target_command): ... this.
6944 (initialize_targets): Adjust.
6945 * tracepoint.c (tvariables_info): Rename to ...
6946 (info_tvariables_command): ... this.
6947 (scope_info): Rename to ...
6948 (info_scope_command): ... this.
6949 (trace_dump_actions): Adjust.
6950 (_initialize_tracepoint): Adjust.
6951
6952 2017-08-22 Tom Tromey <tom@tromey.com>
6953
6954 * breakpoint.h (install_breakpoint): Update.
6955 * breakpoint.c (add_solib_catchpoint): Update.
6956 (install_breakpoint): Change argument to a std::unique_ptr.
6957 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
6958 (create_breakpoint_sal, create_breakpoint): Update.
6959 (watch_command_1, catch_exec_command_1)
6960 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
6961 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
6962 Return the breakpoint.
6963 (set_raw_breakpoint_without_location, set_raw_breakpoint)
6964 (new_single_step_breakpoint): Update.
6965 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
6966 std::unique_ptr.
6967 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
6968 std::unique_ptr.
6969 * break-catch-sig.c (create_signal_catchpoint): Use
6970 std::unique_ptr.
6971 * ada-lang.c (create_ada_exception_catchpoint): Use
6972 std::unique_ptr.
6973
6974 2017-08-22 Tom Tromey <tom@tromey.com>
6975
6976 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
6977
6978 2017-08-22 Tom Tromey <tom@tromey.com>
6979
6980 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
6981 (lookup_partial_symbol): Update.
6982
6983 2017-08-22 Tom Tromey <tom@tromey.com>
6984
6985 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
6986 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
6987 (find_and_open_source, symtab_to_fullname): Update.
6988 * psymtab.c (psymtab_to_fullname): Update.
6989
6990 2017-08-22 Tom Tromey <tom@tromey.com>
6991
6992 * exec.c (exec_file_attach): Update.
6993 * linux-thread-db.c (try_thread_db_load): Update.
6994 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
6995 * utils.c (gdb_realpath): Change return type.
6996 (gdb_realpath_keepfile): Update.
6997 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
6998 (_initialize_utils): Register the new self test.
6999 * source.c (openp): Update.
7000 (find_and_open_source): Update.
7001 * nto-tdep.c (nto_find_and_open_solib): Update.
7002 * main.c (set_gdb_data_directory): Update.
7003 (captured_main_1): Update.
7004 * dwarf2read.c (dwarf2_get_dwz_file): Update
7005 (dw2_map_symbol_filenames): Update.
7006 * auto-load.c (auto_load_safe_path_vec_update): Update.
7007 (filename_is_in_auto_load_safe_path_vec): Change type of
7008 "filename_realp".
7009 (auto_load_objfile_script): Update.
7010 (file_is_auto_load_safe): Update. Use std::string.
7011 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
7012
7013 2017-08-22 Tom Tromey <tom@tromey.com>
7014
7015 * utils.c (gdb_realpath_keepfile): Return a
7016 gdb::unique_xmalloc_ptr.
7017 * exec.c (exec_file_attach): Update.
7018 * utils.h (gdb_realpath_keepfile): Return a
7019 gdb::unique_xmalloc_ptr.
7020
7021 2017-08-22 Tom Tromey <tom@tromey.com>
7022
7023 * compile/compile.c (compile_file_command): Use
7024 gdb::unique_xmalloc_ptr, std::string.
7025 * utils.c (gdb_abspath): Change return type.
7026 * source.c (openp): Update.
7027 * objfiles.c (allocate_objfile): Update.
7028 * main.c (set_gdb_data_directory): Update.
7029 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
7030
7031 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
7032
7033 * cli-cmds.c (list_commands): List actual code around more than
7034 one location.
7035
7036 2017-08-21 John Baldwin <jhb@FreeBSD.org>
7037
7038 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
7039
7040 2017-08-21 Pedro Alves <palves@redhat.com>
7041
7042 PR gdb/19487
7043 * c-exp.y (variable production): Handle function aliases.
7044 * minsyms.c (msymbol_is_text): New function.
7045 * minsyms.h (msymbol_is_text): Declare.
7046 * symtab.c (find_function_alias_target): New function.
7047 * symtab.h (find_function_alias_target): Declare.
7048
7049 2017-08-21 Pedro Alves <palves@redhat.com>
7050
7051 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
7052 typedefs.
7053 * typeprint.c (whatis_exp): If handling "whatis", and expression
7054 is OP_TYPE, strip one typedef level. Otherwise don't strip
7055 typedefs here.
7056 * valops.c (value_cast): Save "to" type before resolving
7057 stubs/typedefs. Use that type as resulting value's type.
7058
7059 2017-08-18 Tom Tromey <tom@tromey.com>
7060 Pedro Alves <palves@redhat.com>
7061
7062 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
7063 * sol-thread.c (sol_thread_resume, sol_thread_wait)
7064 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
7065 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
7066 * proc-service.c (ps_xfer_memory): Use scoped_restore.
7067 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
7068 (linux_get_siginfo_data): Add "thread" argument. Use
7069 scoped_restore.
7070 * linux-nat.c (linux_child_follow_fork)
7071 (check_stopped_by_watchpoint): Use scoped_restore.
7072 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
7073 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
7074 (restore_inferior_ptid, save_inferior_ptid): Remove.
7075 * btrace.c (btrace_fetch): Use scoped_restore.
7076 * bsd-uthread.c (bsd_uthread_fetch_registers)
7077 (bsd_uthread_store_registers): Use scoped_restore.
7078 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
7079 scoped_restore.
7080 * aix-thread.c (aix_thread_resume, aix_thread_wait)
7081 (aix_thread_xfer_partial): Use scoped_restore.
7082 * inferior.h (save_inferior_ptid): Remove.
7083
7084 2017-08-18 Yao Qi <yao.qi@linaro.org>
7085
7086 PR tdep/21818
7087 * arm-tdep.c (gdb_print_insn_arm): Mark
7088 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
7089
7090 2017-08-18 Yao Qi <yao.qi@linaro.org>
7091
7092 * NEWS: Mention GDBserver's new option "--selftest".
7093 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
7094 * selftest.c: Move it to common/selftest.c.
7095 * selftest.h: Move it to common/selftest.h.
7096 * selftest-arch.c (reset): New function.
7097 (tests_with_arch): Call reset.
7098
7099 2017-08-18 Yao Qi <yao.qi@linaro.org>
7100
7101 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
7102 instead of exception_fprintf and printf_filtered.
7103
7104 2017-08-18 Yao Qi <yao.qi@linaro.org>
7105
7106 * selftest.c (register_self_test): Rename it to
7107 selftests::register_test.
7108 (run_self_tests): selftest::run_tests.
7109 * selftest.h: Update declarations.
7110 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
7111 selftests::register_test_foreach_arch.
7112 * selftest-arch.h: Update declaration.
7113 * aarch64-tdep.c: Update.
7114 * arm-tdep.c: Likewise.
7115 * disasm-selftests.c: Likewise.
7116 * dwarf2loc.c: Likewise.
7117 * dwarf2-frame.c: Likewise.
7118 * findvar.c: Likewise.
7119 * gdbarch-selftests.c: Likewise.
7120 * maint.c (maintenance_selftest): Likewise.
7121 * regcache.c: Likewise.
7122 * rust-exp.y: Likewise.
7123 * selftest-arch.c: Likewise.
7124 * unittests/environ-selftests.c: Likewise.
7125 * unittests/function-view-selftests.c: Likewise.
7126 * unittests/offset-type-selftests.c: Likewise.
7127 * unittests/optional-selftests.c: Likewise.
7128 * unittests/scoped_restore-selftests.c: Likewise.
7129 * utils-selftests.c: Likewise.
7130
7131 2017-08-17 Pedro Alves <palves@redhat.com>
7132
7133 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
7134 local.
7135
7136 2017-08-17 Pedro Alves <palves@redhat.com>
7137
7138 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
7139 field.
7140 (reset_die_in_process): Delete, replaced by ...
7141 (process_die_scope): ... this new class. Make it responsible for
7142 freeing cu->line_header too.
7143 (process_die): Use process_die_scope.
7144 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
7145 cu->line_header_die_owner. Don't release the line header if it's
7146 owned by the CU.
7147 (setup_type_unit_groups): Make the CU/DIE own the line header.
7148 Don't release the line header here.
7149
7150 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
7151
7152 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
7153
7154 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
7155
7156 * NEWS: Mention new shortcuts for nexti and stepi in TUI
7157 Single-Key mode
7158
7159 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
7160
7161 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
7162 mode command list.
7163
7164 2017-08-15 Stafford Horne <shorne@gmail.com>
7165
7166 * MAINTAINERS (Write After Approval): Add Stafford Horne.
7167
7168 2017-08-15 Stafford Horne <shorne@gmail.com>
7169
7170 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
7171
7172 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
7173
7174 PR gdb/21954
7175 * infcmd.c (unset_environment_command): Use the 'clear' method on
7176 the environment instead of resetting it.
7177
7178 2017-08-15 John Baldwin <jhb@FreeBSD.org>
7179
7180 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
7181 platforms.
7182
7183 2017-08-14 Tom Tromey <tom@tromey.com>
7184
7185 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
7186 (print_binary_chars): Likewise.
7187 (BITS_IN_BYTES): Remove.
7188
7189 2017-08-14 Tom Tromey <tom@tromey.com>
7190
7191 PR gdb/21675
7192 * valprint.c (LOW_ZERO): Change value to 034.
7193 (print_octal_chars): Add static_asserts for octal constants.
7194 * printcmd.c (print_scalar_formatted): Add 'd' case.
7195
7196 2017-08-11 Tom Tromey <tom@tromey.com>
7197
7198 * symfile.c (add_symbol_file_command): Use std::vector.
7199
7200 2017-08-14 Tom Tromey <tom@tromey.com>
7201
7202 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
7203 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
7204 std::move.
7205 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
7206
7207 2017-08-11 Pedro Alves <palves@redhat.com>
7208
7209 * infrun.c (process_event_stop_test): Adjust
7210 function_name_is_marked_for_skip call.
7211 * skip.c: Include <list>.
7212 (skiplist_entry): Make it a class with private fields, and
7213 getters/setters.
7214 (skiplist_entry_chain): Delete.
7215 (skiplist_entries): New.
7216 (skiplist_entry_count): Delete.
7217 (highest_skiplist_entry_num): New.
7218 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
7219 (add_skiplist_entry): Delete.
7220 (skiplist_entry::skiplist_entry): New.
7221 (skiplist_entry::add_entry): New.
7222 (skip_file_command, skip_function): Adjust.
7223 (compile_skip_regexp): Delete.
7224 (skip_command): Don't compile regexp here. Adjust to use
7225 skiplist_entry::add_entry.
7226 (skip_info): Adjust to use range-for and getters.
7227 (skip_enable_command, skip_disable_command): Adjust to use
7228 range-for and setters.
7229 (skip_delete_command): Adjust to use std::list.
7230 (add_skiplist_entry): Delete.
7231 (skip_file_p): Delete, refactored as ...
7232 (skiplist_entry::do_skip_file_p): ... this new method.
7233 (skip_gfile_p): Delete, refactored as ...
7234 (skiplist_entry::do_gskip_file_p): ... this new method.
7235 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
7236 (skiplist_entry::skip_function_p): ... this new method.
7237 (function_name_is_marked_for_skip): Now returns bool, and takes
7238 the function sal by const reference. Adjust to use range-for and
7239 skiplist_entry methods.
7240 (_initialize_step_skip): Remove references to
7241 skiplist_entry_chain, skiplist_entry_count.
7242 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
7243 takes the function sal by const reference.
7244
7245 2017-08-11 Yao Qi <yao.qi@linaro.org>
7246
7247 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
7248 (dwarf2_frame_cache): Remove reset_cache_cleanup.
7249 (dwarf2_frame_cache):
7250 * frame-unwind.c (frame_unwind_try_unwinder): Catch
7251 RETURN_MASK_ALL and set *this_case to NULL.
7252 * frame-unwind.h: Update comments.
7253
7254 2017-08-11 Yao Qi <yao.qi@linaro.org>
7255
7256 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
7257 (dwarf2_frame_state_copy_regs): Remove.
7258 (dwarf2_frame_state_free_regs): Remove.
7259 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
7260 (dwarf2_restore_rule): Call method .alloc_regs instead of
7261 dwarf2_frame_state_alloc_regs.
7262 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
7263 constructor. Call std::move.
7264 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
7265 (dwarf2_frame_cache): Likewise.
7266
7267 [GDB_SELF_TEST]: Include selftest.h and
7268 selftest-arch.h.
7269 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
7270 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
7271 execute_cfa_program_test.
7272
7273 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
7274 copy ctor, assignment operator, move assignment.
7275 <alloc_regs>: New method.
7276 <swap>: New method.
7277 (struct dwarf2_frame_state): Delete dtor.
7278 (dwarf2_frame_state_alloc_regs): Remove declaration.
7279 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
7280 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
7281
7282 2017-08-11 Yao Qi <yao.qi@linaro.org>
7283
7284 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
7285 (dwarf2_frame_state::dwarf2_frame_state): New.
7286 (dwarf2_frame_state::~dwarf2_frame_state): New.
7287 (dwarf2_fetch_cfa_info): Update.
7288 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
7289 rather than a pointer. Update code.
7290 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
7291 dtor.
7292 <data_align, code_align, retaddr_column>: Change them to const.
7293 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
7294 to bool.
7295
7296 2017-08-11 Yao Qi <yao.qi@linaro.org>
7297
7298 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
7299 <loc.exp>: New field.
7300 * dwarf2-frame.c (execute_cfa_program): Update.
7301 (dwarf2_frame_prev_register): Update.
7302
7303 2017-08-10 Pedro Alves <palves@redhat.com>
7304
7305 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
7306
7307 2017-08-09 John Baldwin <jhb@FreeBSD.org>
7308
7309 * fbsd-nat.c (struct fbsd_fork_info): Remove.
7310 (fbsd_pending_children): Use std::list.
7311 (fbsd_remember_child): Likewise.
7312 (fbsd_is_child_pending): Likewise.
7313 (fbsd_pending_vfork_done): Use std::forward_list.
7314 (fbsd_add_vfork_done): Likewise.
7315 (fbsd_is_vfork_done_pending): Likewise.
7316 (fbsd_next_vfork_done): Likewise.
7317
7318 2017-08-09 John Baldwin <jhb@FreeBSD.org>
7319
7320 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
7321 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
7322 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
7323 for `mapfilename'.
7324 (fbsd_xfer_partial): Use gdb::byte_vector.
7325 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
7326
7327 2017-08-09 John Baldwin <jhb@FreeBSD.org>
7328
7329 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
7330 "filestuff.h".
7331 (fbsd_find_memory_regions): Fix `mapfile' initialization.
7332
7333 2017-08-09 Tom Tromey <tom@tromey.com>
7334
7335 * skip.c (skiplist_entry): New constructor.
7336 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
7337 (skiplist_entry::file_is_glob): Now bool.
7338 (skiplist_entry::file, skiplist_entry::function): Now
7339 std::string.
7340 (make_skip_entry): Return a unique_ptr. Use new.
7341 (free_skiplist_entry, free_skiplist_entry_cleanup)
7342 (make_free_skiplist_entry_cleanup): Remove.
7343 (skip_command, skip_disable_command, add_skiplist_entry)
7344 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
7345 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
7346 (function_name_is_marked_for_skip): Update.
7347 (skip_delete_command): Update. Use delete.
7348
7349 2017-08-09 Jiong Wang <jiong.wang@arm.com>
7350
7351 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
7352 (aarch64_linux_core_read_description): New function.
7353 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
7354
7355 2017-08-09 Pedro Alves <palves@redhat.com>
7356
7357 * cp-name-parser.y (cp_comp_to_string): Return a
7358 gdb::unique_xmalloc_ptr<char>.
7359 * cp-support.c (replace_typedefs_qualified_name)
7360 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
7361 (cp_canonicalize_string_full): Use op= instead of explicit
7362 convertion.
7363 (cp_class_name_from_physname, method_name_from_physname)
7364 (cp_func_name, cp_remove_params): Adjust to use
7365 gdb::unique_xmalloc_ptr<char>.
7366 * cp-support.h (cp_comp_to_string): Return a
7367 gdb::unique_xmalloc_ptr<char>.
7368 * python/py-type.c (typy_lookup_type): Adjust to use
7369 gdb::unique_xmalloc_ptr<char>.
7370
7371 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
7372
7373 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
7374
7375 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
7376 Yao Qi <yao.qi@linaro.org>
7377
7378 * cp-support.c (cp_canonicalize_string_full): Use
7379 gdb::unique_xmalloc_ptr<char>.
7380 (cp_canonicalize_string): Likewise.
7381
7382 2017-08-09 Yao Qi <yao.qi@linaro.org>
7383
7384 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
7385 * regformats/i386/amd64-avx-avx512.dat: Remove.
7386 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
7387 * regformats/i386/amd64-avx-mpx.dat:Remove.
7388 * regformats/i386/amd64-avx.dat: Remove.
7389 * regformats/i386/amd64-mpx.dat: Remove.
7390 * regformats/i386/i386-avx-avx512.dat: Remove.
7391 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
7392 * regformats/i386/i386-avx-mpx.dat: Remove.
7393 * regformats/i386/i386-mmx.dat: Remove.
7394 * regformats/i386/i386-mpx.dat: Remove.
7395
7396 2017-08-09 Yao Qi <yao.qi@linaro.org>
7397
7398 * amd64-tdep.h (tdesc_x32): Remove the declaration.
7399 * amd64-tdep.c: Don't include features/i386/x32*.c.
7400 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
7401 functions.
7402 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
7403 and i386/x32-avx-avx512.
7404 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
7405 and i386/x32.xml.
7406 * features/i386/x32-avx-avx512.c: Removed.
7407 * features/i386/x32-avx-avx512.xml: Removed.
7408 * features/i386/x32-avx.c: Removed.
7409 * features/i386/x32-avx.xml: Removed.
7410 * features/i386/x32.c: Removed.
7411 * features/i386/x32.xml: Removed.
7412 * regformats/i386/x32-avx-avx512.dat: Removed.
7413 * regformats/i386/x32-avx.dat: Removed.
7414 * regformats/i386/x32.dat: Removed.
7415
7416 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7417
7418 PR breakpoints/21886
7419 * mem-break.c (default_memory_insert_breakpoint): Use
7420 `->placed_address' rather than `->reqstd_address' for the
7421 breakpoint location.
7422
7423 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7424
7425 * arch-utils.c (default_print_insn): Remove arch/mach/endian
7426 assertions.
7427
7428 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7429
7430 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
7431 a union of `tdep_info', `tdesc_data' and `id'.
7432 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
7433 rather than `info.tdep_info'.
7434 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
7435 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
7436 * i386-tdep.c (i386_gdbarch_init): Likewise.
7437 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
7438 * mips-tdep.c (mips_gdbarch_init): Likewise.
7439 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
7440 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
7441 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
7442 `info.tdep_info'.
7443 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
7444 `info.tdep_info'.
7445 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
7446 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
7447 `info.tdep_info'.
7448 * spu-tdep.c (spu_gdbarch_init): Likewise.
7449 * gdbarch.h: Regenerate.
7450
7451 2017-08-07 Leszek Swirski <leszeks@google.com>
7452
7453 PR symtab/20899
7454 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
7455
7456 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
7457
7458 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
7459 (gdbsim_open): Rename gdb_argv args object to argv.
7460
7461 2017-08-05 Tom Tromey <tom@tromey.com>
7462
7463 * compile/compile-object-load.c (compile_object_load): Use
7464 gdb::unique_xmalloc_ptr.
7465 * cli/cli-dump.c (scan_filename): Rename from
7466 scan_filename_with_cleanup. Change return type.
7467 (scan_expression): Rename from scan_expression_with_cleanup.
7468 Change return type.
7469 (dump_memory_to_file, dump_value_to_file, restore_command):
7470 Use gdb::unique_xmalloc_ptr. Update.
7471 * cli/cli-cmds.c (find_and_open_script): Use
7472 gdb::unique_xmalloc_ptr.
7473 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
7474 * symmisc.c (maintenance_print_symbols)
7475 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
7476 * symfile.c (symfile_bfd_open, generic_load)
7477 (add_symbol_file_command, remove_symbol_file_command): Use
7478 gdb::unique_xmalloc_ptr.
7479 * source.c (openp): Use gdb::unique_xmalloc_ptr.
7480 * psymtab.c (maintenance_print_psymbols): Use
7481 gdb::unique_xmalloc_ptr.
7482 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
7483 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
7484 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
7485 (reload_shared_libraries_1): Likewise.
7486
7487 2017-08-05 Tom Tromey <tom@tromey.com>
7488
7489 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
7490 (rust_op_vector, rust_set_vector): New typedefs.
7491 (current_parser): New global.
7492 (work_obstack): Change to pointer type. Update all users.
7493 (rust_ast, pstate): Remove globals.
7494 (struct rust_parser): New.
7495 (%union) <params, field_inits>: Change type.
7496 (start, tuple_expr, unit_expr, struct_expr_list, literal)
7497 (field_expr, expr_list, maybe_expr_list, type_list): Update.
7498 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
7499 (convert_params_to_types, convert_params_to_expression): Change
7500 type of "params".
7501 (ast_string): Change type of "fields".
7502 (rust_parse): Make a rust_parser. Remove cleanups.
7503 (rust_lex_tests): Make and install an auto_obstack.
7504
7505 2017-08-04 Yao Qi <yao.qi@linaro.org>
7506
7507 * configure.srv (ipa_x32_linux_regobj): New.
7508 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
7509 instead of X86_TDESC_AVX512.
7510 (initialize_low_tracepoint): Call
7511 init_registers_x32_avx_avx512_linux.
7512
7513 2017-08-04 Yao Qi <yao.qi@linaro.org>
7514
7515 * utils.h (gdb_argv): Add namespace std for nullptr_t.
7516
7517 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
7518
7519 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
7520
7521 2017-08-03 Tom Tromey <tom@tromey.com>
7522
7523 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
7524 Remove.
7525 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
7526
7527 2017-08-03 Tom Tromey <tom@tromey.com>
7528
7529 * python/py-param.c (compute_enum_values): Use gdb_argv.
7530
7531 2017-08-03 Tom Tromey <tom@tromey.com>
7532
7533 * utils.h (struct gdb_argv_deleter): New.
7534 (gdb_argv): New class.
7535 * utils.c (gdb_argv::reset): New method.
7536 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
7537 * tracefile.c (tsave_command): Use gdb_argv.
7538 * top.c (new_ui_command): Use gdb_argv.
7539 * symmisc.c (maintenance_print_symbols)
7540 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
7541 * symfile.c (symbol_file_command, generic_load)
7542 (remove_symbol_file_command): Use gdb_argv.
7543 * stack.c (backtrace_command): Use gdb_argv.
7544 * source.c (add_path, show_substitute_path_command)
7545 (unset_substitute_path_command, set_substitute_path_command):
7546 Use gdb_argv.
7547 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
7548 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
7549 * remote.c (extended_remote_run, remote_put_command)
7550 (remote_get_command, remote_delete_command): Use gdb_argv.
7551 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
7552 (gdbsim_open): Use gdb_argv.
7553 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
7554 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
7555 * procfs.c (procfs_info_proc): Use gdb_argv.
7556 * interps.c (interpreter_exec_cmd): Use gdb_argv.
7557 * infrun.c (handle_command): Use gdb_argv.
7558 * inferior.c (add_inferior_command, clone_inferior_command):
7559 Use gdb_argv.
7560 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
7561 * exec.c (exec_file_command): Use gdb_argv.
7562 * cli/cli-cmds.c (alias_command): Use gdb_argv.
7563 * compile/compile.c (build_argc_argv): Use gdb_argv.
7564
7565 2017-08-03 Tom Tromey <tom@tromey.com>
7566
7567 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
7568
7569 2017-08-03 Tom Tromey <tom@tromey.com>
7570
7571 * python/python.c (compute_python_string): Return std::string.
7572 (gdbpy_eval_from_control_command): Update.
7573 (do_start_initialization): Use std::string.
7574 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
7575 xstrprintf.
7576 * python/py-breakpoint.c (local_setattro): Use string_printf, not
7577 xstrprintf.
7578
7579 2017-08-03 Tom Tromey <tom@tromey.com>
7580
7581 * top.h (do_restore_instream_cleanup): Remove.
7582 * top.c (do_restore_instream_cleanup): Remove.
7583 (read_command_file): Use scoped_restore.
7584 * cli/cli-script.c (execute_user_command): Use scoped_restore.
7585
7586 2017-08-03 Tom Tromey <tom@tromey.com>
7587
7588 * cli/cli-script.c (execute_user_command)
7589 (execute_control_command): Use scoped_restore.
7590
7591 2017-08-03 Tom Tromey <tom@tromey.com>
7592
7593 * cli/cli-script.c (do_restore_user_call_depth): Remove.
7594 (execute_user_command): Remove user_call_depth; use
7595 user_args_stack's size instead.
7596
7597 2017-08-03 Tom Tromey <tom@tromey.com>
7598
7599 * top.h (in_user_command): Remove.
7600 * top.c (in_user_command): Remove.
7601 * cli/cli-script.c (do_restore_user_call_depth)
7602 (execute_user_command): Update.
7603
7604 2017-08-03 Tom Tromey <tom@tromey.com>
7605
7606 * valops.c (search_struct_method): Use gdb::byte_vector.
7607 * valarith.c (value_concat): Use std::vector.
7608 * target.c (memory_xfer_partial): Use gdb::byte_vector.
7609 (simple_search_memory): Likewise.
7610 * printcmd.c (find_string_backward): Use gdb::byte_vector.
7611 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
7612 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
7613 * elfread.c (elf_rel_plt_read): Use std::string.
7614 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
7615 * cli/cli-dump.c (restore_section_callback): Use
7616 gdb::byte_vector.
7617
7618 2017-08-03 Tom Tromey <tom@tromey.com>
7619
7620 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
7621
7622 2017-08-03 Tom Tromey <tom@tromey.com>
7623
7624 * tui/tui-regs.c (tui_restore_gdbout): Remove.
7625 (tui_register_format): Use scoped_restore.
7626
7627 2017-08-03 Tom Tromey <tom@tromey.com>
7628
7629 * reverse.c (exec_direction_default): Remove.
7630 (exec_reverse_once): Use scoped_restore.
7631 * remote.c (restore_remote_timeout): Remove.
7632 (remote_flash_erase, remote_flash_write, remote_flash_done)
7633 (readchar, remote_serial_write): Use scoped_restore.
7634 * cli/cli-script.c (struct source_cleanup_lines_args)
7635 (source_cleanup_lines): Remove.
7636 (script_from_file): Use scoped_restore.
7637 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
7638 (source_command): Use scoped_restore.
7639
7640 2017-08-03 Tom Tromey <tom@tromey.com>
7641
7642 * utils.h (make_cleanup_free_so): Remove.
7643 * utils.c (do_free_so, make_cleanup_free_so): Remove.
7644 * solist.h (struct so_deleter): New.
7645 (so_list_up): New typedef.
7646 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
7647
7648 2017-08-03 Tom Tromey <tom@tromey.com>
7649
7650 * utils.h (make_cleanup_restore_current_language): Remove.
7651 * utils.c (do_restore_current_language)
7652 (make_cleanup_restore_current_language): Remove.
7653 * parse.c (parse_exp_in_context_1)
7654 (parse_expression_with_language): Use
7655 scoped_restore_current_language.
7656 * mi/mi-main.c (mi_cmd_execute): Use
7657 scoped_restore_current_language.
7658 * language.h (scoped_restore_current_language): New class.
7659
7660 2017-08-03 Tom Tromey <tom@tromey.com>
7661
7662 * compile/compile.c (cleanup_unlink_file): Remove.
7663 (compile_to_object): Use gdb::unlinker.
7664 (eval_compile_command): Likewise.
7665
7666 2017-08-03 Tom Tromey <tom@tromey.com>
7667
7668 * utils.h (make_cleanup_fclose): Remove.
7669 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
7670
7671 2017-08-03 Tom Tromey <tom@tromey.com>
7672
7673 * top.c (open_terminal_stream): Return gdb_file_up.
7674 (new_ui_command): Update.
7675
7676 2017-08-03 Tom Tromey <tom@tromey.com>
7677
7678 * source.c (print_source_lines_base, forward_search_command)
7679 (reverse_search_command): Use gdb_file_up.
7680
7681 2017-08-03 Tom Tromey <tom@tromey.com>
7682
7683 * fbsd-nat.c (fbsd_find_memory_regions): Update.
7684
7685 2017-08-03 Tom Tromey <tom@tromey.com>
7686
7687 * cli/cli-cmds.c (find_and_open_script): Change return type.
7688 Remove "streamp" and "full_path" parameters.
7689 (source_script_with_search): Update.
7690 * auto-load.c (source_script_file): Update.
7691 * cli/cli-cmds.h (find_and_open_script): Change type.
7692 (open_script): New struct.
7693
7694 2017-08-03 Tom Tromey <tom@tromey.com>
7695
7696 * xml-support.c (xml_fetch_content_from_file): Update.
7697 * ui-file.c (stdio_file::open): Update.
7698 * tracefile-tfile.c (tfile_start): Update.
7699 * remote.c (remote_file_put, remote_file_get): Update.
7700 * nat/linux-procfs.c (linux_proc_get_int)
7701 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
7702 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
7703 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
7704 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
7705 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
7706 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
7707 * linux-nat.c (linux_proc_pending_signals): Update.
7708 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
7709 (file_closer): Remove.
7710 * compile/compile.c (compile_to_object): Update.
7711 * common/filestuff.h (struct gdb_file_deleter): New.
7712 (gdb_file_up): New typedef.
7713 (gdb_fopen_cloexec): Change return type.
7714 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
7715 * cli/cli-dump.c (fopen_with_cleanup): Remove.
7716 (dump_binary_file, restore_binary_file): Update.
7717 * auto-load.c (auto_load_objfile_script_1): Update.
7718
7719 2017-08-03 Tom Tromey <tom@tromey.com>
7720
7721 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
7722 (info_static_tracepoint_markers_command): Likewise.
7723 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
7724 * skip.c (skip_info): Use ui_out_emit_table.
7725 * progspace.c (print_program_space): Use ui_out_emit_table.
7726 * osdata.c (info_osdata): Use ui_out_emit_table.
7727 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
7728 ui_out_emit_table.
7729 * linux-thread-db.c (info_auto_load_libthread_db): Use
7730 ui_out_emit_table.
7731 * inferior.c (print_inferior): Use ui_out_emit_table.
7732 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
7733 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
7734 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
7735 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
7736 * ui-out.h (class ui_out_emit_table): New.
7737
7738 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
7739
7740 * mips-tdep.c (mips_fpu_type_str): New function.
7741 (mips_dump_tdep): Call it.
7742
7743 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
7744
7745 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
7746 `->mips_fpu_type'.
7747
7748 2017-07-31 Xavier Roirand <roirand@adacore.com>
7749
7750 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
7751
7752 2017-07-27 Xavier Roirand <roirand@adacore.com>
7753
7754 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
7755
7756 2017-07-26 Yao Qi <yao.qi@linaro.org>
7757
7758 * cli/cli-cmds.c (maintenancechecklist): New variable.
7759 * gdbcmd.h (maintenancechecklist): Declare it.
7760 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
7761 Call i386_linux_read_description with different masks.
7762 * maint.c (maintenance_check_command): New function.
7763 (_initialize_maint_cmds): Call add_prefix_cmd.
7764 * target-descriptions.c (tdesc_reg): override operator != and ==.
7765 (tdesc_type): Likewise.
7766 (tdesc_feature): Likewise.
7767 (target_desc): Likewise.
7768 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
7769 (maintenance_check_xml_descriptions): New function.
7770 (_initialize_target_descriptions) Add command "xml-descriptions".
7771 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
7772
7773 2017-07-26 Yao Qi <yao.qi@linaro.org>
7774
7775 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
7776 Include features/i386/32bit-*.c.
7777 (i386_linux_read_description): Generate target description if it
7778 doesn't exist.
7779 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
7780 functions.
7781 * features/i386/32bit-linux.c: Re-generated.
7782 * features/i386/32bit-sse.c: Likewise.
7783 * target-descriptions.c (print_c_feature::visit): Print code to
7784 set register number if needed.
7785 (print_c_feature) <m_next_regnum>: New field.
7786
7787 2017-07-26 Yao Qi <yao.qi@linaro.org>
7788
7789 * features/Makefile (CFILES): Rename with TDESC_CFILES.
7790 (FEATURE_XMLFILES): New.
7791 (FEATURE_CFILES): New.
7792 New rules.
7793 (clean-cfiles): Remove generated c files.
7794 * features/i386/32bit-avx.c: Generated.
7795 * features/i386/32bit-avx512.c: Generated.
7796 * features/i386/32bit-core.c: Generated.
7797 * features/i386/32bit-linux.c: Generated.
7798 * features/i386/32bit-mpx.c: Generated.
7799 * features/i386/32bit-pkeys.c: Generated.
7800 * features/i386/32bit-sse.c: Generated.
7801 * target-descriptions.c: Include algorithm.
7802 (tdesc_element_visitor): Add method visit_end.
7803 (print_c_tdesc): Implement visit_end.
7804 (print_c_tdesc:: m_filename_after_features): Move it to
7805 protected.
7806 (print_c_feature): New class.
7807 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
7808 name starts with "i386/32bit-".
7809
7810 2017-07-26 Yao Qi <yao.qi@linaro.org>
7811
7812 * target-descriptions.c (tdesc_element_visitor): New class.
7813 (tdesc_element): New class.
7814 (tdesc_reg): Inherit from tdesc_element.
7815 (tdesc_reg::accept): New function.
7816 (tdesc_type): Inherit from tdesc_element.
7817 (tdesc_type::accept): New function.
7818 (tdesc_feature): Inherit from tdesc_element.
7819 (tdesc_feature::accept): New function.
7820 (target_desc): Inherit from tdesc_element.
7821 (target_desc::target_desc): New.
7822 (target_desc::~target_desc): New.
7823 (target_desc::accept): New.
7824 (allocate_target_description): Use new.
7825 (free_target_description): Use delete.
7826 (print_c_tdesc): New class.
7827 (maint_print_c_tdesc_cmd): Adjust.
7828
7829 * features/aarch64.c: Re-generated.
7830 * features/arc-arcompact.c: Re-generated.
7831 * features/arc-v2.c: Re-generated.
7832 * features/arm/arm-with-iwmmxt.c: Re-generated.
7833 * features/arm/arm-with-m.c: Re-generated.
7834 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
7835 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
7836 * features/arm/arm-with-neon.c: Re-generated.
7837 * features/arm/arm-with-vfpv2.c: Re-generated.
7838 * features/arm/arm-with-vfpv3.c: Re-generated.
7839 * features/i386/amd64-avx-avx512.c: Re-generated.
7840 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
7841 * features/i386/amd64-avx.c: Re-generated.
7842 * features/i386/amd64-avx-linux.c: Re-generated.
7843 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
7844 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
7845 * features/i386/amd64-avx-mpx.c: Re-generated.
7846 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
7847 * features/i386/amd64.c: Re-generated.
7848 * features/i386/amd64-linux.c: Re-generated.
7849 * features/i386/amd64-mpx.c: Re-generated.
7850 * features/i386/amd64-mpx-linux.c: Re-generated.
7851 * features/i386/i386-avx-avx512.c: Re-generated.
7852 * features/i386/i386-avx-avx512-linux.c: Re-generated.
7853 * features/i386/i386-avx.c: Re-generated.
7854 * features/i386/i386-avx-linux.c: Re-generated.
7855 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
7856 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
7857 * features/i386/i386-avx-mpx.c: Re-generated.
7858 * features/i386/i386-avx-mpx-linux.c: Re-generated.
7859 * features/i386/i386.c: Re-generated.
7860 * features/i386/i386-linux.c: Re-generated.
7861 * features/i386/i386-mmx.c: Re-generated.
7862 * features/i386/i386-mmx-linux.c: Re-generated.
7863 * features/i386/i386-mpx.c: Re-generated.
7864 * features/i386/i386-mpx-linux.c: Re-generated.
7865 * features/i386/x32-avx-avx512.c: Re-generated.
7866 * features/i386/x32-avx-avx512-linux.c: Re-generated.
7867 * features/i386/x32-avx.c: Re-generated.
7868 * features/i386/x32-avx-linux.c: Re-generated.
7869 * features/i386/x32.c: Re-generated.
7870 * features/i386/x32-linux.c: Re-generated.
7871 * features/microblaze.c: Re-generated.
7872 * features/microblaze-with-stack-protect.c: Re-generated.
7873 * features/mips64-dsp-linux.c: Re-generated.
7874 * features/mips64-linux.c: Re-generated.
7875 * features/mips-dsp-linux.c: Re-generated.
7876 * features/mips-linux.c: Re-generated.
7877 * features/nds32.c: Re-generated.
7878 * features/nios2.c: Re-generated.
7879 * features/nios2-linux.c: Re-generated.
7880 * features/rs6000/powerpc-32.c: Re-generated.
7881 * features/rs6000/powerpc-32l.c: Re-generated.
7882 * features/rs6000/powerpc-403.c: Re-generated.
7883 * features/rs6000/powerpc-403gc.c : Re-generated.
7884 * features/rs6000/powerpc-405.c: Re-generated.
7885 * features/rs6000/powerpc-505.c: Re-generated.
7886 * features/rs6000/powerpc-601.c: Re-generated.
7887 * features/rs6000/powerpc-602.c: Re-generated.
7888 * features/rs6000/powerpc-603.c: Re-generated.
7889 * features/rs6000/powerpc-604.c: Re-generated.
7890 * features/rs6000/powerpc-64.c: Re-generated.
7891 * features/rs6000/powerpc-64l.c: Re-generated.
7892 * features/rs6000/powerpc-7400.c: Re-generated.
7893 * features/rs6000/powerpc-750.c: Re-generated.
7894 * features/rs6000/powerpc-860.c: Re-generated.
7895 * features/rs6000/powerpc-altivec32.c: Re-generated.
7896 * features/rs6000/powerpc-altivec32l.c: Re-generated.
7897 * features/rs6000/powerpc-altivec64.c: Re-generated.
7898 * features/rs6000/powerpc-altivec64l.c: Re-generated.
7899 * features/rs6000/powerpc-cell32l.c: Re-generated.
7900 * features/rs6000/powerpc-cell64l.c: Re-generated.
7901 * features/rs6000/powerpc-e500.c: Re-generated.
7902 * features/rs6000/powerpc-e500l.c: Re-generated.
7903 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
7904 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
7905 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
7906 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
7907 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
7908 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
7909 * features/rs6000/powerpc-vsx32.c: Re-generated.
7910 * features/rs6000/powerpc-vsx32l.c: Re-generated.
7911 * features/rs6000/powerpc-vsx64.c: Re-generated.
7912 * features/rs6000/powerpc-vsx64l.c: Re-generated.
7913 * features/rs6000/rs6000.c: Re-generated.
7914 * features/s390-linux32.c: Re-generated.
7915 * features/s390-linux32v1.c: Re-generated.
7916 * features/s390-linux32v2.c: Re-generated.
7917 * features/s390-linux64.c: Re-generated.
7918 * features/s390-linux64v1.c: Re-generated.
7919 * features/s390-linux64v2.c: Re-generated.
7920 * features/s390-te-linux64.c: Re-generated.
7921 * features/s390-tevx-linux64.c: Re-generated.
7922 * features/s390-vx-linux64.c: Re-generated.
7923 * features/s390x-linux64.c: Re-generated.
7924 * features/s390x-linux64v1.c: Re-generated.
7925 * features/s390x-linux64v2.c: Re-generated.
7926 * features/s390x-te-linux64.c: Re-generated.
7927 * features/s390x-tevx-linux64.c: Re-generated.
7928 * features/s390x-vx-linux64.c: Re-generated.
7929 * features/sparc/sparc32-solaris.c: Re-generated.
7930 * features/sparc/sparc64-solaris.c: Re-generated.
7931 * features/tic6x-c62x.c: Re-generated.
7932 * features/tic6x-c62x-linux.c: Re-generated.
7933 * features/tic6x-c64x.c: Re-generated.
7934 * features/tic6x-c64x-linux.c: Re-generated.
7935 * features/tic6x-c64xp.c: Re-generated.
7936 * features/tic6x-c64xp-linux.c: Re-generated.
7937
7938 2017-07-26 Yao Qi <yao.qi@linaro.org>
7939
7940 * i386-linux-tdep.c (i386_linux_read_description): New function.
7941 (i386_linux_core_read_description): Call
7942 i386_linux_read_description.
7943 * i386-linux-tdep.h (i386_linux_read_description): Declare.
7944 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
7945 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
7946 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
7947 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
7948 * x86-linux-nat.c (x86_linux_read_description): Call
7949 i386_linux_read_description.
7950
7951 2017-07-26 Yao Qi <yao.qi@linaro.org>
7952
7953 * NEWS: Mention it.
7954 * features/Makefile (%.c: %.xml): Pass the xml file name to
7955 command "maint print c-tdesc".
7956 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
7957 name from 'arg'.
7958
7959 2017-07-26 Yao Qi <yao.qi@linaro.org>
7960
7961 * target-descriptions.c (target_desc): Add ctor and dtor. Do
7962 in-class initialization.
7963 (tdesc_create_feature): Call new instead of XCNEW.
7964 (free_target_description): Ue delete.
7965
7966 2017-07-25 John Baldwin <jhb@FreeBSD.org>
7967
7968 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
7969
7970 2017-07-25 Yao Qi <yao.qi@linaro.org>
7971
7972 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
7973 constant.
7974 (amd64_x32_init_abi): Likewise.
7975 * amd64-tdep.h (amd64_init_abi): Update declaration.
7976 (amd64_x32_init_abi): Likewise.
7977
7978 2017-07-25 Yao Qi <yao.qi@linaro.org>
7979
7980 PR tdep/21717
7981 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
7982 condition for FPSCR.
7983 (arm_linux_store_inferior_registers): Likewise.
7984
7985 2017-07-22 Tom Tromey <tom@tromey.com>
7986
7987 * break-catch-syscall.c (struct catch_syscall_inferior_data)
7988 <syscalls_counts>: Now a std::vector.
7989 (get_catch_syscall_inferior_data): Use "new".
7990 (catch_syscall_inferior_data_cleanup): Use "delete".
7991 (insert_catch_syscall, remove_catch_syscall)
7992 (clear_syscall_counts): Update.
7993
7994 2017-07-22 Tom Tromey <tom@tromey.com>
7995
7996 * break-catch-syscall.c (syscall_catchpoint)
7997 <syscalls_to_be_caught>: Now a std::vector<int>
7998 (~syscall_catchpoint): Remove.
7999 (insert_catch_syscall, remove_catch_syscall)
8000 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
8001 (print_mention_catch_syscall, print_recreate_catch_syscall):
8002 Update.
8003 (create_syscall_event_catchpoint): Change type of "filter"
8004 parameter.
8005 (catch_syscall_split_args): Return a std::vector.
8006 (catch_syscall_command_1, catching_syscall_number_1): Update.
8007
8008 2017-07-22 Tom Tromey <tom@tromey.com>
8009
8010 * break-catch-throw.c (struct exception_catchpoint)
8011 <exception_rx>: Now a std::string.
8012 (~exception_catchpoint): Remove.
8013 (print_one_detail_exception_catchpoint): Update.
8014 (handle_gnu_v3_exceptions): Change type of except_rx.
8015 (extract_exception_regexp): Return a std::string.
8016 (catch_exception_command_1): Update.
8017
8018 2017-07-22 Tom Tromey <tom@tromey.com>
8019
8020 * break-catch-sig.c (gdb_signal_type): Remove typedef.
8021 (struct signal_catchpoint) <signals_to_be_caught>: Now a
8022 std::vector.
8023 <catch_all>: Now a bool.
8024 (~signal_catchpoint): Remove.
8025 (signal_catchpoint_insert_location)
8026 (signal_catchpoint_remove_location)
8027 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
8028 (signal_catchpoint_print_mention)
8029 (signal_catchpoint_print_recreate)
8030 (signal_catchpoint_explains_signal): Update.
8031 (create_signal_catchpoint): Change type of "filter" and
8032 "catch_all".
8033 (catch_signal_split_args): Return a std::vector. Change type of
8034 "catch_all".
8035 (catch_signal_command): Update.
8036
8037 2017-07-20 Pedro Alves <palves@redhat.com>
8038
8039 * ada-lang.c (ada_language_defn): Make extern.
8040 (_initialize_ada_language): Remove add_language call.
8041 * c-lang.c (c_language_defn, cplus_language_defn)
8042 (asm_language_defn, minimal_language_defn): Make extern.
8043 (_initialize_c_language): Delete.
8044 * completer.c (compare_cstrings): Delete, moved to utils.h.
8045 * d-lang.c (d_language_defn): Make extern.
8046 (_initialize_d_language): Remove add_language calls.
8047 * defs.h (enum language): Add comment.
8048 * f-lang.c (f_language_defn): Make extern.
8049 (_initialize_f_language): Remove add_language call.
8050 * go-lang.c (go_language_defn): Make extern.
8051 (_initialize_go_language): Remove add_language call.
8052 * language.c: Include <algorithm>.
8053 (languages): Redefine as const array.
8054 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
8055 (set_language_command): Handle "local". Use for-range loop.
8056 (set_language): Remove loop.
8057 (language_enum): Rewrite.
8058 (language_def, language_str): Remove loops.
8059 (add_language): Delete.
8060 (add_set_language_command): New, based on add_languages.
8061 (skip_language_trampoline): Adjust.
8062 (local_language_defn): Delete.
8063 (language_gdbarch_post_init): Adjust.
8064 (_initialize_language): Remove add_language calls. Call
8065 add_set_language_command.
8066 * language.h (add_language): Delete.
8067 (auto_language_defn)
8068 (unknown_language_defn, minimal_language_defn, ada_language_defn)
8069 (asm_language_defn, c_language_defn, cplus_language_defn)
8070 (d_language_defn, f_language_defn, go_language_defn)
8071 (m2_language_defn, objc_language_defn, opencl_language_defn)
8072 (pascal_language_defn, rust_language_defn): Declare.
8073 * m2-lang.c (m2_language_defn): Make extern.
8074 (_initialize_m2_language): Remove add_language call.
8075 * objc-lang.c (objc_language_defn): Make extern.
8076 (_initialize_objc_language): Remove add_language call.
8077 * opencl-lang.c (opencl_language_defn): Make extern.
8078 (_initialize_opencl_language): Remove add_language call.
8079 * p-lang.c (pascal_language_defn): Make extern.
8080 (_initialize_pascal_language): Delete.
8081 * rust-lang.c (rust_language_defn): Make extern.
8082 (_initialize_rust_language): Delete.
8083 * utils.h (compare_cstrings): New static inline function.
8084
8085 2017-07-20 Pedro Alves <palves@redhat.com>
8086
8087 * ada-lang.c (ada_to_fixed_type_1): Adjust.
8088 (get_var_value): Constify parameters.
8089 (get_int_var_value): Change prototype.
8090 (to_fixed_range_type): Adjust.
8091 * ada-lang.h (get_int_var_value): Change prototype.
8092
8093 2017-07-20 Pedro Alves <palves@redhat.com>
8094
8095 * dwarf2read.c (dw2_lookup_symbol): Use
8096 SYMBOL_MATCHES_SEARCH_NAME.
8097 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
8098
8099 2017-07-20 Pedro Alves <palves@redhat.com>
8100
8101 * block.c (block_iter_name_step, block_iter_name_first)
8102 (block_iter_name_next): Delete.
8103 (block_lookup_symbol_primary): Adjust to use
8104 dict_iter_match_first/dict_iter_match_next.
8105 * block.h (block_iter_name_first, block_iter_name_next): Delete
8106 declarations.
8107 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
8108 dict_iter_match_first/dict_iter_match_next.
8109
8110 2017-07-20 Pedro Alves <palves@redhat.com>
8111
8112 * cp-support.c (cp_find_first_component_aux): Add missing case for
8113 end of string.
8114
8115 2017-07-18 David Blaikie <dblaikie@gmail.com>
8116
8117 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
8118 of dwo_cu's dwo_file.
8119
8120 2017-07-18 Yao Qi <yao.qi@linaro.org>
8121
8122 * remote.c (store_registers_using_G): Remove one line comment.
8123
8124 2017-07-18 Yao Qi <yao.qi@linaro.org>
8125
8126 * regcache.c (regcache_cpy): Simplify it.
8127 (regcache::cpy_no_passthrough): Remove it.
8128 * regcache.h (cpy_no_passthrough): Remove it.
8129 (regcache_dup, regcache_cpy): Update comments.
8130
8131 2017-07-18 Pedro Alves <palves@redhat.com>
8132
8133 * remote-sim.c (sim_command_completer): Adjust to work with a
8134 completion_tracker instead of a VEC.
8135
8136 2017-07-17 Pedro Alves <palves@redhat.com>
8137
8138 * completer.c (complete_source_filenames): New function.
8139 (complete_address_and_linespec_locations): New function.
8140 (location_completer): Use complete_address_and_linespec_locations.
8141 (completion_tracker::build_completion_result): Honor the tracker's
8142 request to suppress append.
8143 * completer.h (completion_tracker::suppress_append_ws)
8144 (completion_tracker::set_suppress_append_ws): New methods.
8145 (completion_tracker::m_suppress_append_ws): New field.
8146 (complete_source_filenames): New declaration.
8147 * linespec.c (linespec_complete_what): New.
8148 (struct ls_parser) <complete_what, completion_word,
8149 completion_quote_char, completion_quote_end, completion_tracker>:
8150 New fields.
8151 (string_find_incomplete_keyword_at_end): New.
8152 (linespec_lexer_lex_string): Record quote char. If in completion
8153 mode, don't throw.
8154 (linespec_lexer_consume_token): Advance the completion word point.
8155 (linespec_lexer_peek_token): Save/restore completion info.
8156 (save_stream_and_consume_token): New.
8157 (set_completion_after_number): New.
8158 (linespec_parse_basic): Set what to complete next depending on
8159 token. Handle function and label completions specially.
8160 (parse_linespec): Disable objc shortcut in completion mode. Set
8161 what to complete next depending on token type. Skip keyword if in
8162 completion mode.
8163 (complete_linespec_component, linespec_complete): New.
8164 * linespec.h (linespec_complete): Declare.
8165
8166 2017-07-17 Pedro Alves <palves@redhat.com>
8167
8168 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
8169 Handle 'operator<' / 'operator<<'.
8170
8171 2017-07-17 Pedro Alves <palves@redhat.com>
8172
8173 * completer.c (collect_explicit_location_matches): Handle
8174 MATCH_LABEL.
8175 (convert_explicit_location_to_linespec): New, factored out from
8176 ...
8177 (convert_explicit_location_to_sals): ... this.
8178 (complete_label): New.
8179 (linespec_complete_label, find_label_symbols_in_block): New.
8180 (find_label_symbols): Add completion_mode parameter and adjust to
8181 call find_label_symbols_in_block.
8182 * linespec.h (linespec_complete_label): Declare.
8183
8184 2017-07-17 Pedro Alves <palves@redhat.com>
8185
8186 * ada-lang.c (ada_collect_symbol_completion_matches): Add
8187 complete_symbol_mode parameter.
8188 * cli/cli-cmds.c (complete_command): Get the completion result out
8189 of the handle_brkchars tracker if used a custom word point.
8190 * completer.c: Include "linespec.h".
8191 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
8192 (advance_to_expression_complete_word_point): New.
8193 (completion_tracker::completes_to_completion_word): New.
8194 (complete_files_symbols): Pass down
8195 complete_symbol_mode::EXPRESSION.
8196 (explicit_options, probe_options): New.
8197 (collect_explicit_location_matches): Complete on the
8198 explictit_loc->foo instead of word. Use
8199 linespec_complete_function. Handle MATCH_LINE. Handle offering
8200 keyword and options completions.
8201 (backup_text_ptr): Delete.
8202 (skip_keyword): New.
8203 (complete_explicit_location): Remove 'word' parameter. Add
8204 language, quoted_arg_start and quoted_arg_end parameters.
8205 Rewrite, parsing left to right.
8206 (location_completer): Rewrite.
8207 (location_completer_handle_brkchars): New function.
8208 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
8209 (enum complete_line_internal_reason): Adjust comments.
8210 (completion_tracker::discard_completions): New.
8211 (completer_handle_brkchars_func_for_completer): Handle
8212 location_completer.
8213 (gdb_custom_word_point_brkchars)
8214 (gdb_org_rl_basic_quote_characters): New.
8215 (gdb_completion_word_break_characters_throw)
8216 (completion_find_completion_word): Handle trackers that use a
8217 custom word point.
8218 (completion_tracker::advance_custom_word_point_by): New.
8219 (completion_tracker::build_completion_result): Don't rely on
8220 readline appending the quote char.
8221 (gdb_rl_attempted_completion_function_throw): Handle trackers that
8222 use a custom word point.
8223 (gdb_rl_attempted_completion_function): Restore
8224 rl_basic_quote_characters.
8225 * completer.h (class completion_tracker): Extend intro comment.
8226 (completion_tracker::set_quote_char)
8227 (completion_tracker::quote_char)
8228 (completion_tracker::set_use_custom_word_point)
8229 (completion_tracker::use_custom_word_point)
8230 (completion_tracker::custom_word_point)
8231 (completion_tracker::set_custom_word_point)
8232 (completion_tracker::advance_custom_word_point_by)
8233 (completion_tracker::completes_to_completion_word)
8234 (completion_tracker::discard_completions): New methods.
8235 (completion_tracker::m_quote_char)
8236 (completion_tracker::m_use_custom_word_point)
8237 (completion_tracker::m_custom_word_point): New fields.
8238 (advance_to_expression_complete_word_point): Declare.
8239 * f-lang.c (f_collect_symbol_completion_matches): Add
8240 complete_symbol_mode parameter.
8241 * language.h (struct language_defn)
8242 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
8243 parameter.
8244 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
8245 (linespec_complete_function): New function.
8246 (linespec_lexer_lex_keyword): Adjust.
8247 * linespec.h (linespec_keywords, linespec_complete_function): New
8248 declarations.
8249 * location.c (find_end_quote): New function.
8250 (explicit_location_lex_one): Add explicit_completion_info
8251 parameter. Save quoting info. Don't throw if being called for
8252 completion. Don't handle Ada operators here.
8253 (is_cp_operator, skip_op_false_positives, first_of)
8254 (explicit_location_lex_one_function): New function.
8255 (string_to_explicit_location): Replace 'dont_throw' parameter with
8256 an explicit_completion_info pointer parameter. Handle it. Don't
8257 use explicit_location_lex_one to lex function names. Use
8258 explicit_location_lex_one_function instead.
8259 * location.h (struct explicit_completion_info): New.
8260 (string_to_explicit_location): Replace 'dont_throw' parameter with
8261 an explicit_completion_info pointer parameter.
8262 * symtab.c (default_collect_symbol_completion_matches_break_on):
8263 Add complete_symbol_mode parameter. Handle LINESPEC mode.
8264 (default_collect_symbol_completion_matches)
8265 (collect_symbol_completion_matches): Add complete_symbol_mode
8266 parameter.
8267 (collect_symbol_completion_matches_type): Pass down
8268 complete_symbol_mode::EXPRESSION.
8269 (collect_file_symbol_completion_matches): Add complete_symbol_mode
8270 parameter. Handle LINESPEC mode.
8271 * symtab.h (complete_symbol_mode): New.
8272 (default_collect_symbol_completion_matches_break_on)
8273 (default_collect_symbol_completion_matches)
8274 (collect_symbol_completion_matches)
8275 (collect_file_symbol_completion_matches): Add complete_symbol_mode
8276 parameter.
8277
8278 2017-07-17 Pedro Alves <palves@redhat.com>
8279
8280 * utils.c (enum class strncmp_iw_mode): New.
8281 (strcmp_iw): Rename to ...
8282 (strncmp_iw_with_mode): ... this. Add string2_len and mode
8283 parameters. Handle them.
8284 (strncmp_iw): New.
8285 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
8286 * utils.h (strncmp_iw): Declare.
8287 (strcmp_iw): Move describing comments here.
8288
8289 2017-07-17 Pedro Alves <palves@redhat.com>
8290
8291 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
8292 CP_OPERATOR_STR.
8293 * c-typeprint.c (is_type_conversion_operator): Use
8294 CP_OPERATOR_STR.
8295 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
8296 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
8297 CP_OPERATOR_LEN.
8298 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
8299 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
8300 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
8301 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
8302 CP_OPERATOR_STR.
8303 * location.c: Include "cp-support.h".
8304 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
8305 CP_OPERATOR_STR.
8306 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
8307 CP_OPERATOR_LEN.
8308
8309 2017-07-17 Pedro Alves <palves@redhat.com>
8310
8311 * cli/cli-cmds.c (complete_command): Use a completion tracker
8312 along with completion_find_completion_word for handle_brkchars
8313 phase.
8314 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
8315 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
8316 (struct gdb_rl_completion_word_info): New.
8317 (gdb_rl_find_completion_word): New.
8318 (completion_find_completion_word): New.
8319 * completer.h (completion_find_completion_word): Declare.
8320
8321 2017-07-17 Pedro Alves <palves@redhat.com>
8322
8323 * ada-lang.c (symbol_completion_match): Adjust comments.
8324 (symbol_completion_add): Replace vector parameter with
8325 completion_tracker parameter. Use it.
8326 (ada_make_symbol_completion_list): Rename to...
8327 (ada_collect_symbol_completion_matches): ... this. Add
8328 completion_tracker parameter and use it.
8329 (ada_language_defn): Adjust.
8330 * break-catch-syscall.c (catch_syscall_completer): Adjust
8331 prototype and work with completion_tracker instead of VEC.
8332 * breakpoint.c (condition_completer): Adjust prototype and work
8333 with completion_tracker instead of VEC.
8334 * c-lang.c (c_language_defn, cplus_language_defn)
8335 (asm_language_defn, minimal_language_defn): Adjust to renames.
8336 * cli/cli-cmds.c (complete_command): Rework using
8337 completion_tracker. Catch exceptions when completing.
8338 * cli/cli-decode.c (integer_unlimited_completer)
8339 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
8340 with completion_tracker instead of VEC.
8341 * command.h (struct completion_tracker): Forward declare.
8342 (completer_ftype, completer_handle_brkchars_ftype): Change
8343 types.
8344 (complete_on_cmdlist, complete_on_enum): Adjust.
8345 * completer.c: Include <algorithm>.
8346 (struct gdb_completer_state): New.
8347 (current_completion): New global.
8348 (readline_line_completion_function): Delete.
8349 (noop_completer, filename_completer)
8350 (filename_completer_handle_brkchars, complete_files_symbols)
8351 (linespec_location_completer): Adjust to work with a
8352 completion_tracker instead of a VEC.
8353 (string_or_empty): New.
8354 (collect_explicit_location_matches): Adjust to work with a
8355 completion_tracker instead of a VEC.
8356 (explicit_location_completer): Rename to ...
8357 (complete_explicit_location): ... this and adjust to work with a
8358 completion_tracker instead of a VEC.
8359 (location_completer): Adjust to work with a completion_tracker
8360 instead of a VEC.
8361 (add_struct_fields): Adjust to work with a completion_list instead
8362 of VEC.
8363 (expression_completer): Rename to ...
8364 (complete_expression): ... this and adjust to work with a
8365 completion_tracker instead of a VEC. Use complete_files_symbols.
8366 (expression_completer): Reimplement on top of complete_expression.
8367 (symbol_completer): Adjust to work with a completion_tracker
8368 instead of a VEC.
8369 (enum complete_line_internal_reason): Add describing comments.
8370 (complete_line_internal_normal_command): Adjust to work with a
8371 completion_tracker instead of a VEC.
8372 (complete_line_internal): Rename to ...
8373 (complete_line_internal_1): ... this and adjust to work with a
8374 completion_tracker instead of a VEC. Assert TEXT is NULL in the
8375 handle_brkchars phase.
8376 (new_completion_tracker): Delete.
8377 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
8378 complete_line_internal_1.
8379 (free_completion_tracker): Delete.
8380 (INITIAL_COMPLETION_HTAB_SIZE): New.
8381 (completion_tracker::completion_tracker)
8382 (completion_tracker::~completion_tracker): New.
8383 (maybe_add_completion): Delete.
8384 (completion_tracker::maybe_add_completion)
8385 (completion_tracker::add_completion)
8386 (completion_tracker::add_completions): New.
8387 (throw_max_completions_reached_error): Delete.
8388 (complete_line): Adjust to work with a completion_tracker instead
8389 of a VEC. Don't create a completion_tracker_t or check for max
8390 completions here.
8391 (command_completer, command_completer_handle_brkchars)
8392 (signal_completer, reg_or_group_completer_1)
8393 (reg_or_group_completer, default_completer_handle_brkchars):
8394 Adjust to work with a completion_tracker.
8395 (gdb_completion_word_break_characters_throw): New.
8396 (gdb_completion_word_break_characters): Reimplement.
8397 (line_completion_function): Delete.
8398 (completion_tracker::recompute_lowest_common_denominator)
8399 (expand_preserving_ws)
8400 (completion_tracker::build_completion_result)
8401 (completion_result::completion_result)
8402 (completion_result::completion_result)
8403 (completion_result::~completion_result)
8404 (completion_result::completion_result)
8405 (completion_result::release_match_list, compare_cstrings)
8406 (completion_result::sort_match_list)
8407 (completion_result::reset_match_list)
8408 (gdb_rl_attempted_completion_function_throw)
8409 (gdb_rl_attempted_completion_function): New.
8410 * completer.h (completion_list, struct completion_result)
8411 (class completion_tracker): New.
8412 (complete_line): Add completion_tracker parameter.
8413 (readline_line_completion_function): Delete.
8414 (gdb_rl_attempted_completion_function): New.
8415 (noop_completer, filename_completer, expression_completer)
8416 (location_completer, symbol_completer, command_completer)
8417 (signal_completer, reg_or_group_completer): Update prototypes.
8418 (completion_tracker_t, new_completion_tracker)
8419 (make_cleanup_free_completion_tracker): Delete.
8420 (enum maybe_add_completion_enum): Delete.
8421 (maybe_add_completion): Delete.
8422 (throw_max_completions_reached_error): Delete.
8423 * corefile.c (complete_set_gnutarget): Adjust to work with a
8424 completion_tracker instead of a VEC.
8425 * cp-abi.c (cp_abi_completer): Adjust to work with a
8426 completion_tracker instead of a VEC.
8427 * d-lang.c (d_language_defn): Adjust.
8428 * disasm.c (disassembler_options_completer): Adjust to work with a
8429 completion_tracker instead of a VEC.
8430 * f-lang.c (f_make_symbol_completion_list): Rename to ...
8431 (f_collect_symbol_completion_matches): ... this. Adjust to work
8432 with a completion_tracker instead of a VEC.
8433 (f_language_defn): Adjust.
8434 * go-lang.c (go_language_defn): Adjust.
8435 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
8436 Adjust to work with a completion_tracker instead of a VEC.
8437 * infrun.c (handle_completer): Likewise.
8438 * interps.c (interpreter_completer): Likewise.
8439 * interps.h (interpreter_completer): Likewise.
8440 * language.c (unknown_language_defn, auto_language_defn)
8441 (local_language_defn): Adjust.
8442 * language.h (language_defn::la_make_symbol_completion_list):
8443 Rename to ...
8444 (language_defn::la_collect_symbol_completion_matches): ... this
8445 and adjust to work with a completion_tracker instead of a VEC.
8446 * m2-lang.c (m2_language_defn): Adjust.
8447 * objc-lang.c (objc_language_defn): Adjust.
8448 * opencl-lang.c (opencl_language_defn): Adjust.
8449 * p-lang.c (pascal_language_defn): Adjust.
8450 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
8451 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
8452 with a completion_tracker.
8453 * rust-lang.c (rust_language_defn): Adjust.
8454 * symtab.c (free_completion_list, do_free_completion_list)
8455 (return_val, completion_tracker): Delete.
8456 (completion_list_add_name, completion_list_add_symbol)
8457 (completion_list_add_msymbol, completion_list_objc_symbol)
8458 (completion_list_add_fields, add_symtab_completions): Add
8459 completion_tracker parameter and use it.
8460 (default_make_symbol_completion_list_break_on_1): Rename to...
8461 (default_collect_symbol_completion_matches_break_on): ... this.
8462 Add completion_tracker parameter and use it instead of allocating
8463 a completion tracker here.
8464 (default_make_symbol_completion_list_break_on): Delete old
8465 implementation.
8466 (default_make_symbol_completion_list): Delete.
8467 (default_collect_symbol_completion_matches): New.
8468 (make_symbol_completion_list): Delete.
8469 (collect_symbol_completion_matches): New.
8470 (make_symbol_completion_type): Rename to ...
8471 (collect_symbol_completion_matches_type): ... this. Add
8472 completion_tracker parameter and use it instead of VEC.
8473 (make_file_symbol_completion_list_1): Rename to...
8474 (collect_file_symbol_completion_matches): ... this. Add
8475 completion_tracker parameter and use it instead of VEC.
8476 (make_file_symbol_completion_list): Delete.
8477 (add_filename_to_list): Use completion_list instead of a VEC.
8478 (add_partial_filename_data::list): Now a completion_list.
8479 (make_source_files_completion_list): Work with a completion_list
8480 instead of a VEC.
8481 * symtab.h: Include "completer.h".
8482 (default_make_symbol_completion_list_break_on)
8483 (default_make_symbol_completion_list, make_symbol_completion_list)
8484 (make_symbol_completion_type, make_file_symbol_completion_list)
8485 (make_source_files_completion_list): Delete.
8486 (default_collect_symbol_completion_matches_break_on)
8487 (default_collect_symbol_completion_matches)
8488 (collect_symbol_completion_matches)
8489 (collect_symbol_completion_matches_type)
8490 (collect_file_symbol_completion_matches)
8491 (make_source_files_completion_list): New.
8492 * top.c (init_main): Don't install a rl_completion_entry_function
8493 hook. Install a rl_attempted_completion_function hook instead.
8494 * tui/tui-layout.c (layout_completer): Adjust to work with a
8495 completion_tracker.
8496 * tui/tui-regs.c (tui_reggroup_completer):
8497 * tui/tui-win.c (window_name_completer, focus_completer)
8498 (winheight_completer): Adjust to work with a completion_tracker.
8499 * value.c: Include "completer.h".
8500 (complete_internalvar): Adjust to work with a completion_tracker.
8501 * value.h (complete_internalvar): Likewise.
8502
8503 2017-07-17 Pedro Alves <palves@redhat.com>
8504
8505 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
8506 renames.
8507 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
8508 comments to completer_ftype's declaration.
8509 <completer_handle_brkchars>: Change type to
8510 completer_handle_brkchars_ftype.
8511 * command.h (completer_ftype): Add describing comment and give
8512 names to parameters.
8513 (completer_ftype_void): Rename to ...
8514 (completer_handle_brkchars_ftype) ... this. Add describing comment.
8515 (set_cmd_completer_handle_brkchars): Adjust.
8516 * completer.c (filename_completer_handle_brkchars): New function.
8517 (complete_line_internal_normal_command): New function, factored
8518 out from ...
8519 (complete_line_internal): ... here.
8520 (command_completer_handle_brkchars)
8521 (default_completer_handle_brkchars)
8522 (completer_handle_brkchars_func_for_completer): New functions.
8523 * completer.h (set_gdb_completion_word_break_characters): Delete
8524 declaration.
8525 (completer_handle_brkchars_func_for_completer): New declaration.
8526 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
8527 completer_handle_brkchars_func_for_completer.
8528
8529 2017-07-17 Pedro Alves <palves@redhat.com>
8530
8531 * completer.c (symbol_completer): New function, based on
8532 make_symbol_completion_list_fn.
8533 * completer.h (symbol_completer): New declaration.
8534 * guile/scm-cmd.c (cmdscm_completers): Adjust.
8535 * python/py-cmd.c (completers): Adjust.
8536 * symtab.c (make_symbol_completion_list_fn): Delete.
8537 * symtab.h (make_symbol_completion_list_fn): Delete.
8538 * cli/cli-decode.c (add_cmd): Adjust.
8539
8540 2017-07-17 Pedro Alves <palves@redhat.com>
8541
8542 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
8543 * dwarf2read.c: Include "filename-seen-cache.h".
8544 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
8545 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
8546 * filename-seen-cache.c: New file.
8547 * filename-seen-cache.h: New file.
8548 * symtab.c: Include "filename-seen-cache.h".
8549 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
8550 (create_filename_seen_cache, clear_filename_seen_cache)
8551 (delete_filename_seen_cache, filename_seen): Delete, parts moved
8552 to filename-seen-cache.h/filename-seen-cache.c.
8553 (output_source_filename, sources_info)
8554 (maybe_add_partial_symtab_filename)
8555 (make_source_files_completion_list): Adjust to use
8556 filename_seen_cache.
8557
8558 2017-07-17 Pedro Alves <palves@redhat.com>
8559
8560 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
8561 fields.
8562 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
8563 dwarf2_debug_sections*)): New.
8564 (dwarf2_per_objfile::dwarf2_per_objfile(const
8565 dwarf2_per_objfile&)): Declare as deleted.
8566 (dwarf2_per_objfile::operator=): Declare as deleted.
8567 (dwarf2_per_objfile::dwarf2_per_objfile)
8568 (dwarf2_per_objfile::~dwarf2_per_objfile)
8569 (dwarf2_per_objfile::free_cached_comp_units): New.
8570 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
8571 ctor. Call dwarf2_per_objfile's ctor manually.
8572 (dwarf2_locate_sections): Deleted/refactored as ...
8573 (dwarf2_per_objfile::locate_sections): ... this new method.
8574 (free_cached_comp_units): Defer to
8575 dwarf2_per_objfile::free_cached_comp_units.
8576 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
8577
8578 2017-07-14 Tom Tromey <tom@tromey.com>
8579
8580 PR rust/21764:
8581 * rust-exp.y (convert_ast_to_expression): Add "want_type"
8582 parameter.
8583 <UNOP_SIZEOF>: Split into separate case.
8584 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
8585
8586 2017-07-14 Tom Tromey <tom@tromey.com>
8587
8588 PR rust/21763:
8589 * symtab.c (symbol_matches_domain): Add language_rust to special
8590 case.
8591 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
8592 treat LOC_TYPEDEF symbols as variables.
8593
8594 2017-07-14 Pedro Alves <palves@redhat.com>
8595
8596 * symtab.c (make_file_symbol_completion_list_1): Iterate over
8597 symtabs matching all symtabs with SRCFILE as file name instead of
8598 only considering the first hit, with lookup_symtab.
8599
8600 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8601
8602 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
8603 operator_name parameters.
8604 (gen_expr): Update function call.
8605
8606 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8607
8608 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
8609 parameter.
8610 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
8611 Likewise.
8612 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
8613 parameter, use agent_expr::gdbarch instead, update function
8614 calls.
8615 (locexpr_tracepoint_var_ref): Likewise.
8616 (loclist_tracepoint_var_ref): Likewise.
8617 * ax-gdb.c (gen_trace_static_fields): Likewise.
8618 (gen_traced_pop): Likewise.
8619 (gen_frame_args_address): Likewise.
8620 (gen_frame_locals_address): Likewise.
8621 (gen_var_ref): Likewise.
8622 (gen_struct_ref_recursive): Likewise.
8623 (gen_static_field): Likewise.
8624 (gen_maybe_namespace_elt): Likewise.
8625 (gen_expr): Likewise.
8626 (gen_trace_for_var): Likewise.
8627 (gen_trace_for_expr): Likewise.
8628 (gen_trace_for_return_address): Likewise.
8629
8630 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8631
8632 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
8633 parameter.
8634 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
8635
8636 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8637
8638 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
8639 from ax, update calls.
8640 (gen_usual_arithmetic): Likewise.
8641 (gen_integral_promotions): Likewise.
8642 (gen_bitfield_ref): Likewise.
8643 (gen_primitive_field): Likewise.
8644 (gen_struct_ref_recursive): Likewise.
8645 (gen_struct_ref): Likewise.
8646 (gen_maybe_namespace_elt): Likewise.
8647 (gen_struct_elt_for_reference): Likewise.
8648 (gen_namespace_elt): Likewise.
8649 (gen_aggregate_elt_ref): Likewise.
8650 (gen_expr): Get gdbarch from ax, update calls.
8651 (gen_expr_binop_rest): Likewise.
8652
8653 2017-07-13 Pedro Alves <palves@redhat.com>
8654
8655 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
8656 as default tdesc.
8657 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
8658 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
8659 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
8660 tdesc_amd64_linux as default tdesc. Get final tdesc from the
8661 tdep.
8662 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
8663 Get final tdesc from the tdep.
8664 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
8665 default tdesc.
8666 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
8667 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
8668 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
8669 Use it as default tdesc.
8670 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
8671 down to amd_init_abi. No longer handle fallback tdesc here.
8672 * amd64-tdep.h (tdesc_x32): Declare.
8673 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
8674 parameter.
8675 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
8676 as default tdesc.
8677
8678 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8679
8680 * s390-linux-tdep.c (s390_process_record): Add support for
8681 instructions new in arch12.
8682
8683 2017-07-11 John Baldwin <jhb@FreeBSD.org>
8684
8685 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
8686 PT_GETFSBASE and PT_GETGSBASE.
8687 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
8688 PT_SETGSBASE.
8689
8690 2017-07-11 John Baldwin <jhb@FreeBSD.org>
8691
8692 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
8693 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
8694 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
8695 those rules.
8696 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
8697 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
8698 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
8699 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
8700 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
8701 * features/i386/amd64.xml: Add 64bit-segments.xml.
8702 * features/i386/amd64-avx-avx512.c: Regenerated.
8703 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
8704 * features/i386/amd64-avx-mpx.c: Regenerated.
8705 * features/i386/amd64-avx.c: Regenerated.
8706 * features/i386/amd64-mpx.c: Regenerated.
8707 * features/i386/amd64.c: Regenerated.
8708 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
8709 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
8710 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
8711 * regformats/i386/amd64-avx.dat: Regenerated.
8712 * regformats/i386/amd64-mpx.dat: Regenerated.
8713 * regformats/i386/amd64.dat: Regenerated.
8714
8715 2017-07-10 Yao Qi <yao.qi@linaro.org>
8716
8717 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
8718 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
8719
8720 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
8721
8722 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
8723 unsetenv.
8724 * gnulib/aclocal.m4: Regenerate.
8725 * gnulib/config.in: Regenerate.
8726 * gnulib/configure: Regenerate.
8727 * gnulib/import/Makefile.am: Regenerate.
8728 * gnulib/import/Makefile.in: Regenerate.
8729 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
8730 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
8731 * gnulib/import/m4/environ.m4: New file.
8732 * gnulib/import/m4/setenv.m4: New file.
8733 * gnulib/import/setenv.c: New file.
8734 * gnulib/import/unsetenv.c: New file.
8735
8736 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
8737
8738 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
8739 address when op is DW_OP_addr.
8740
8741 2017-07-09 Tom Tromey <tom@tromey.com>
8742
8743 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
8744 check and apply to outer type.
8745
8746 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8747
8748 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
8749 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
8750 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
8751 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
8752
8753 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8754
8755 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
8756
8757 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8758
8759 * corelow.c (get_core_siginfo): Remove.
8760 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
8761 instead of get_core_siginfo.
8762 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
8763 * gdbarch.h: Re-generate.
8764 * gdbarch.c: Re-generate.
8765 * linux-tdep.c (linux_core_xfer_siginfo): New.
8766 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
8767
8768 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8769
8770 * corelow.c (thread_section_name): Move to ...
8771 * gdbcore.h (thread_section_name): ... here.
8772
8773 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8774
8775 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
8776 (struct siginfo32): New.
8777 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
8778 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
8779 via ptrace(PT_LWPINFO).
8780
8781 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8782
8783 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
8784 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
8785 (fbsd_get_siginfo_type): New.
8786 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
8787 (_initialize_fbsd_tdep): New.
8788
8789 2017-07-06 David Blaikie <dblaikie@gmail.com>
8790
8791 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
8792 a singular dwo_unit*) to support multiple CUs in the same way that
8793 multiple TUs are supported.
8794 (create_cus_hash_table): Replace create_dwo_cu with a function for
8795 parsing multiple CUs from a DWO file.
8796 (open_and_init_dwo_file): Use create_cus_hash_table rather than
8797 create_dwo_cu.
8798 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
8799 htab_find, rather than comparing the signature to a singleton CU in
8800 the dwo_file.
8801
8802 2017-07-06 Pedro Alves <palves@redhat.com>
8803
8804 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
8805
8806 2017-07-04 Pedro Alves <palves@redhat.com>
8807
8808 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
8809 * gdbtypes.h (TYPE_STATIC): Delete.
8810 (struct fn_field) <is_public, is_abstract, is_static, is_final,
8811 is_synchronized, is_native>: Delete.
8812 <dummy>: Bump.
8813 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
8814 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
8815 (TYPE_FN_FIELD_ABSTRACT): Delete.
8816
8817 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
8818
8819 * buffer.h (buffer_finish): Fix spelling mistakes.
8820
8821 2017-07-01 Eli Zaretskii <eliz@gnu.org>
8822
8823 * .dir-locals.el: Automatically switch to C-style comments in
8824 versions of Emacs that support the feature.
8825
8826 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
8827 Pedro Alves <palves@redhat.com>
8828
8829 PR cli/21688
8830 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
8831 (process_next_line): New variable 'inline_cmd'.
8832 Adjust 'if' clauses for "python", "compile" and "guile" to use
8833 'command_name_equals' and check for '!inline_cmd'.
8834
8835 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
8836
8837 PR cli/21688
8838 * cli/cli-script.c (command_name_equals_not_inline): New function.
8839 (process_next_line): Adjust 'if' clauses for "python", "compile"
8840 and "guile" to use command_name_equals_not_inline.
8841
8842 2017-06-29 Pedro Alves <palves@redhat.com>
8843
8844 * completer.c (expression_completer): Call
8845 linespec_location_completer instead of location_completer.
8846
8847 2017-06-29 Pedro Alves <palves@redhat.com>
8848
8849 * completer.c (expression_completer): Remove code that recomputes
8850 'text' from 'word'.
8851
8852 2017-06-29 Yao Qi <yao.qi@linaro.org>
8853
8854 * regformats/regdat.sh: Generate code with
8855 "ifndef IN_PROCESS_AGENT".
8856
8857 2017-06-28 Pedro Alves <palves@redhat.com>
8858
8859 * command.h: Include "common/scoped_restore.h".
8860
8861 2017-06-28 Yao Qi <yao.qi@linaro.org>
8862
8863 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
8864 instead of obstack_grow.
8865
8866 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
8867
8868 PR gdb/21337
8869 * symfile.c (reread_symbols): Call objfiles_changed just before
8870 read_symbols.
8871
8872 2017-06-27 Pedro Alves <palves@redhat.com>
8873
8874 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
8875 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
8876 (completion_list_add_symbol, completion_list_add_msymbol):
8877 ... these new functions.
8878 (add_symtab_completions)
8879 (default_make_symbol_completion_list_break_on_1): Adjust.
8880
8881 2017-06-27 Pedro Alves <palves@redhat.com>
8882
8883 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
8884 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
8885 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
8886 dtor.
8887 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
8888 'storage_obstack' field an auto_obstack. In-class initialize all
8889 non-bitfield fields. Make minsyms_read bool.
8890 * symfile.c (read_symbols): Adjust.
8891
8892 2017-06-27 Alan Hayward <alan.hayward@arm.com>
8893
8894 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
8895 (gdbsim_store_register): Likewise.
8896
8897 2017-06-27 Pedro Alves <palves@redhat.com>
8898
8899 * c-exp.y (name_obstack): Now an auto_obstack.
8900 (yylex): Use auto_obstack::clear.
8901 (c_parse): Use auto_obstack::clear instead of reinitializing and
8902 freeing the obstack.
8903 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
8904 * d-exp.y (name_obstack): Now an auto_obstack.
8905 (yylex): Use auto_obstack::clear.
8906 (d_parse): Use auto_obstack::clear instead of reinitializing and
8907 freeing the obstack.
8908 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
8909 auto_obstack.
8910 * dwarf2read.c (create_addrmap_from_index)
8911 (dwarf2_build_psymtabs_hard)
8912 (update_enumeration_type_from_children): Likewise.
8913 * gdb_obstack.h (auto_obstack): New type.
8914 * go-exp.y (name_obstack): Now an auto_obstack.
8915 (build_packaged_name): Use auto_obstack::clear.
8916 (go_parse): Use auto_obstack::clear instead of reinitializing and
8917 freeing the obstack.
8918 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
8919 auto_obstack.
8920 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
8921 * rust-exp.y (work_obstack): Now an auto_obstack.
8922 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
8923 reinitializing and freeing the obstack.
8924 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
8925 (host_char_to_target): Use auto_obstack.
8926 * utils.h (make_cleanup_obstack_free): Delete declaration.
8927 * valprint.c (generic_emit_char, generic_printstr): Use
8928 auto_obstack.
8929
8930 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
8931
8932 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
8933 thread.
8934 (darwin_init_thread_list): Don't update dummy thread.
8935 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
8936
8937 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8938
8939 * record-full.c (netorder16): Remove.
8940
8941 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8942
8943 * common/diagnostics.h: Define macros for GCC.
8944 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
8945 * common/vec.h: Include diagnostics.h.
8946 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
8947 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
8948 warning.
8949
8950 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8951
8952 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
8953 New macro.
8954 * ada-lex.l: Ignore deprecated register warnings.
8955
8956 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8957
8958 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
8959 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
8960
8961 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8962
8963 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
8964 its own line.
8965
8966 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8967
8968 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
8969
8970 2017-06-23 Alan Hayward <alan.hayward@arm.com>
8971
8972 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
8973 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
8974 (xtensa_register_read_masked): Likewise.
8975
8976 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
8977
8978 * common/environ.c (gdb_environ::unset): Update comment.
8979
8980 2017-06-22 Alan Hayward <alan.hayward@arm.com>
8981
8982 * python/py-unwind.c (pyuw_sniffer): Allocate space for
8983 registers.
8984
8985 2017-06-22 Alan Hayward <alan.hayward@arm.com>
8986
8987 * record-full.c (record_full_exec_insn): Use byte_vector.
8988
8989 2017-06-22 Yao Qi <yao.qi@linaro.org>
8990
8991 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
8992 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
8993
8994 2017-06-22 Alan Hayward <alan.hayward@arm.com>
8995
8996 * remote.c (cached_reg): Move from here...
8997 * regcache.h (cached_reg): ...to here.
8998 * python/py-unwind.c (struct reg_info): Remove.
8999 (cached_frame_info): Use cached_reg_t.
9000 (pyuw_prev_register): Likewise.
9001 (pyuw_sniffer): Use cached_reg_t and allocate registers.
9002 (pyuw_dealloc_cache): Free all registers.
9003
9004 2017-06-22 Pedro Alves <palves@redhat.com>
9005 Simon Marchi <simon.marchi@ericsson.com>
9006
9007 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
9008 warning.
9009 * common/diagnostics.h: New file.
9010
9011 2017-06-22 Pedro Alves <palves@redhat.com>
9012
9013 * common/agent.h: Add include guards.
9014
9015 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
9016
9017 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
9018 talk about addressable units instead of bytes.
9019
9020 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
9021
9022 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
9023 of '::const_iterator'.
9024
9025 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
9026
9027 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9028 'unittests/environ-selftests.c'.
9029 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
9030 * charset.c (find_charset_names): Declare object 'iconv_env'.
9031 Update code to use 'iconv_env' object. Remove call to
9032 'free_environ'.
9033 * common/environ.c: Include <utility>.
9034 (make_environ): Delete function.
9035 (free_environ): Delete function.
9036 (gdb_environ::clear): New function.
9037 (gdb_environ::operator=): New function.
9038 (gdb_environ::get): Likewise.
9039 (environ_vector): Delete function.
9040 (set_in_environ): Delete function.
9041 (gdb_environ::set): New function.
9042 (unset_in_environ): Delete function.
9043 (gdb_environ::unset): New function.
9044 (gdb_environ::envp): Likewise.
9045 * common/environ.h: Include <vector>.
9046 (struct gdb_environ): Delete; transform into...
9047 (class gdb_environ): ... this class.
9048 (free_environ): Delete prototype.
9049 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
9050 environ_vector): Likewise.
9051 * infcmd.c (run_command_1): Update code to call
9052 'envp' from 'gdb_environ' class.
9053 (environment_info): Update code to call methods from 'gdb_environ'
9054 class.
9055 (unset_environment_command): Likewise.
9056 (path_info): Likewise.
9057 (path_command): Likewise.
9058 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
9059 (inferior::inferior): Initialize 'environment' using the host's
9060 information.
9061 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
9062 Include "environ.h".
9063 (class inferior) <environment>: Change type from 'struct
9064 gdb_environ' to 'gdb_environ'.
9065 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
9066 methods from 'gdb_environ' class.
9067 * solib.c (solib_find_1): Likewise
9068 * unittests/environ-selftests.c: New file.
9069
9070 2017-06-20 Yao Qi <yao.qi@linaro.org>
9071
9072 * features/i386/i386-linux.xml: Exchange the order of including
9073 32bit-linux.xml and 32bit-sse.xml.
9074 * features/i386/i386-linux.c: Regenerated.
9075
9076 2017-06-20 Yao Qi <yao.qi@linaro.org>
9077
9078 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
9079 Delete copy ctor and assignment operator.
9080 (tdesc_type): Likewise.
9081 (tdesc_feature): Likewise.
9082 (tdesc_free_reg): Remove.
9083 (tdesc_create_reg): Use new.
9084 (tdesc_free_type): Remove.
9085 (tdesc_create_vector): Use new.
9086 (tdesc_create_union): Likewise.
9087 (tdesc_create_flags): Likewise.
9088 (tdesc_create_enum): Likewise.
9089 (tdesc_free_feature): Delete.
9090 (free_target_description): Use delete.
9091
9092 2017-06-19 John Baldwin <jhb@FreeBSD.org>
9093
9094 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
9095 registers.
9096
9097 2017-06-19 Pedro Alves <palves@redhat.com>
9098
9099 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
9100 after gdb::unlinker.
9101
9102 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
9103
9104 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
9105 gdb_environ to access an environment variable.
9106
9107 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
9108
9109 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
9110 gdb_byte*.
9111
9112 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9113
9114 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
9115
9116 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9117
9118 * configure: Re-generate.
9119 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
9120
9121 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9122
9123 * configure: Re-generate.
9124 * warning.m4: Pass -Werror to compiler when checking for
9125 supported warning flags.
9126
9127 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9128
9129 * Makefile.in (COMPILE.pre): Add "-x c++".
9130
9131 2017-06-16 Alan Hayward <alan.hayward@arm.com>
9132 Pedro Alves <palves@redhat.com>
9133 Yao Qi <yao.qi@linaro.org>
9134
9135 * defs.h (RequireLongest): New.
9136 (extract_integer): Declare function template.
9137 (extract_signed_integer): Remove the declaration, but define it
9138 static inline.
9139 (extract_unsigned_integer): Likewise.
9140 (store_integer): Declare function template.
9141 (store_signed_integer): Remove the declaration, but define it
9142 static inline.
9143 (store_unsigned_integer): Likewise.
9144 * findvar.c (extract_integer): New function template.
9145 (extract_signed_integer): Remove.
9146 (extract_unsigned_integer): Remove.
9147 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
9148 instantiations.
9149 (store_integer): New function template.
9150 (store_signed_integer): Remove.
9151 (store_unsigned_integer): Remove.
9152 (store_integer): Explicit instantiations.
9153 * regcache.c (regcache_raw_read_signed): Update.
9154 (regcache::raw_read): New function.
9155 (regcache::raw_read_signed): Remove.
9156 (regcache::raw_read_unsigned): Remove.
9157 (regcache_raw_read_unsigned): Update.
9158 (regcache_raw_write_unsigned): Update.
9159 (regcache::raw_write_signed): Remove.
9160 (regcache::raw_write): New function.
9161 (regcache_cooked_read_signed): Update.
9162 (regcache::raw_write_unsigned): Remove.
9163 (regcache::cooked_read_signed): Remove.
9164 (regcache_cooked_read_unsigned): Update.
9165 (regcache::cooked_read_unsigned): Remove.
9166 (regcache_cooked_write_signed): Update.
9167 (regcache_cooked_write_unsigned): Update.
9168 * regcache.h (regcache) <raw_read_signed>: Remove.
9169 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
9170 <raw_read, raw_write>: New.
9171 <cooked_read_signed, cooked_write_signed>: Remove.
9172 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
9173 <cooked_read, cooked_write>: New.
9174 * sh64-tdep.c (sh64_pseudo_register_read): Update.
9175 (sh64_pseudo_register_write): Update.
9176
9177 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
9178
9179 * arc-tdep.c (arc_disassembler_options): New variable.
9180 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
9181 of default_print_insn.
9182 (arc_delayed_print_insn): Set info->section when needed,
9183 use default_print_insn to retrieve a disassembler.
9184
9185 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
9186
9187 PR gdb/21574
9188 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
9189 to mention $SHELL and startup-with-shell.
9190
9191 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
9192
9193 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
9194
9195 2017-06-14 Yao Qi <yao.qi@linaro.org>
9196
9197 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
9198 default_print_insn instead of print_insn_aarch64.
9199 * arm-tdep.c (gdb_print_insn_arm): Call
9200 default_print_insn instead of print_insn_big_arm
9201 and print_insn_little_arm.
9202 * i386-tdep.c (i386_print_insn): Call default_print_insn
9203 instead of print_insn_i386.
9204 * ia64-tdep.c (ia64_print_insn): Call
9205 default_print_insn instead of print_insn_ia64.
9206 * mips-tdep.c (gdb_print_insn_mips): Call
9207 default_print_insn instead of print_insn_big_mips
9208 and print_insn_little_mips.
9209 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
9210 instead of print_insn_spu.
9211
9212 2017-06-14 Pedro Alves <palves@redhat.com>
9213
9214 * ada-lang.c: Include "common/byte-vector.h".
9215 (ada_value_primitive_packed_val): Use gdb::byte_vector.
9216 * charset.c (wchar_iterator::iterate): Resize the vector instead
9217 of reserving it.
9218 * common/byte-vector.h: Include "common/def-vector.h".
9219 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
9220 * cli/cli-dump.c: Include "common/byte-vector.h".
9221 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
9222 * common/byte-vector.h: New file.
9223 * common/def-vector.h: New file.
9224 * common/default-init-alloc.h: New file.
9225 * dwarf2loc.c: Include "common/byte-vector.h".
9226 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
9227 instead of reserving it.
9228 * dwarf2read.c: Include "common/byte-vector.h".
9229 (data_buf::m_vec): Now a gdb::byte_vector.
9230 * gdb_regex.c: Include "common/def-vector.h".
9231 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
9232 * mi/mi-main.c: Include "common/byte-vector.h".
9233 (mi_cmd_data_read_memory): Use gdb::byte_vector.
9234 * printcmd.c: Include "common/byte-vector.h".
9235 (print_scalar_formatted): Use gdb::byte_vector.
9236 * valprint.c: Include "common/byte-vector.h".
9237 (maybe_negate_by_bytes, print_decimal_chars): Use
9238 gdb::byte_vector.
9239
9240 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9241
9242 * darwin-nat.c: Include "nat/fork-inferior.h".
9243
9244 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9245
9246 * configure.nat: Factor out Darwin bits that are not
9247 architecture-specific. Add fork-inferior.o.
9248
9249 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9250
9251 * configure.nat: Factor out AIX bits that are not
9252 architecture-specific. Add fork-inferior.o.
9253
9254 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9255
9256 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
9257 (read_pieced_value, write_pieced_value): ...here. Reduce to
9258 wrappers that just call rw_pieced_value.
9259
9260 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9261
9262 * dwarf2loc.c (write_pieced_value): When writing the data for a
9263 memory piece, use write_memory_with_notification instead of
9264 write_memory.
9265
9266 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9267
9268 * valops.c (read_value_memory): Change embedded_offset to
9269 represent a bit offset instead of a byte offset.
9270 * value.h (read_value_memory): Adjust comment.
9271
9272 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9273
9274 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
9275 dest_offset_bits and source_offset_bits.
9276 (write_pieced_value): Likewise.
9277
9278 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9279
9280 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
9281 given by DW_OP_bit_piece.
9282 (write_pieced_value): Likewise.
9283
9284 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9285
9286 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
9287 some other preparations to the places where sufficient information
9288 is available.
9289 (write_pieced_value): Likewise.
9290
9291 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9292
9293 * dwarf2loc.c (bits_to_bytes): New function.
9294 (read_pieced_value): Fix offset calculations for register pieces
9295 on big-endian targets.
9296 (write_pieced_value): Likewise.
9297
9298 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9299
9300 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
9301 (write_pieced_value): Likewise.
9302
9303 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9304
9305 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
9306 transfer the source value's least significant bits, instead of its
9307 lowest-addressed ones. Rename type_len to max_offset.
9308 (read_pieced_value): Mirror above changes to write_pieced_value as
9309 applicable.
9310
9311 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9312
9313 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
9314 truncate full bytes from dest_offset_bits before using it as an
9315 offset into the buffer.
9316
9317 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9318
9319 * dwarf2loc.c (write_pieced_value): Include transfer size in
9320 byte-wise check.
9321
9322 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9323
9324 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
9325 calculation of this_size.
9326
9327 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9328
9329 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
9330 when targeting a bit-field.
9331 (write_pieced_value): Likewise.
9332
9333 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9334
9335 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
9336 (allocate_piece_closure): Drop addr_size parameter.
9337 (dwarf2_evaluate_loc_desc_full): Adjust call to
9338 allocate_piece_closure.
9339
9340 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9341
9342 PR gdb/21226
9343 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
9344 the LSB end, independent of endianness.
9345
9346 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9347
9348 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
9349 size capping.
9350
9351 2017-06-13 Yao Qi <yao.qi@linaro.org>
9352
9353 * mips-linux-nat.c: Move include features/mips*-linux.c to
9354 mips-linux-tdep.c.
9355 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
9356 to mips-linux-tdep.c.
9357 * mips-linux-tdep.c: Include features/mips*-linux.c
9358 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
9359 functions.
9360 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
9361 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
9362 (tdesc_mips64_dsp_linux): Declare.
9363
9364 2017-06-12 Tom Tromey <tom@tromey.com>
9365
9366 * valprint.h (val_print_type_code_int): Remove.
9367 * valprint.c (generic_val_print_int): Always call
9368 val_print_scalar_formatted.
9369 (val_print_type_code_int): Remove.
9370 * printcmd.c (print_scalar_formatted): Handle options->format==0.
9371 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
9372 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
9373 * ada-valprint.c (ada_val_print_num): Use
9374 val_print_scalar_formatted.
9375
9376 2017-06-12 Tom Tromey <tom@tromey.com>
9377
9378 * printcmd.c (print_scalar_formatted): Unify the two switches.
9379 Don't convert scalars to LONGEST.
9380
9381 2017-06-12 Tom Tromey <tom@tromey.com>
9382
9383 PR exp/16225:
9384 * valprint.h (print_decimal_chars): Update.
9385 * valprint.c (maybe_negate_by_bytes): New function.
9386 (print_decimal_chars): Add "is_signed" argument.
9387 * printcmd.c (print_scalar_formatted): Update.
9388
9389 2017-06-12 Tom Tromey <tom@tromey.com>
9390
9391 PR exp/16225:
9392 * valprint.h (print_binary_chars, print_hex_chars): Update.
9393 * valprint.c (val_print_type_code_int): Update.
9394 (print_binary_chars): Add "zero_pad" argument.
9395 (emit_octal_digit): New function.
9396 (print_octal_chars): Don't zero-pad.
9397 (print_decimal_chars): Likewise.
9398 (print_hex_chars): Add "zero_pad" argument.
9399 * sh64-tdep.c (sh64_do_fp_register): Update.
9400 * regcache.c (regcache::dump): Update.
9401 * printcmd.c (print_scalar_formatted): Update.
9402 * infcmd.c (default_print_one_register_info): Update.
9403
9404 2017-06-12 Pedro Alves <palves@redhat.com>
9405 Alan Hayward <alan.hayward@arm.com>
9406
9407 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
9408 (mips_eabi_push_dummy_call): Rename local 'regsize' to
9409 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
9410 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
9411 Assert that abi_regsize bytes fit in 'ref_valbuf'.
9412
9413 2017-06-12 Pedro Alves <palves@redhat.com>
9414
9415 * dwarf2read.c (mapped_symtab::data): Now a vector of
9416 symtab_index_entry instead of vector of
9417 std::unique_ptr<symtab_index_entry>. All users adjusted to check
9418 whether an element's name is NULL instead of checking whether the
9419 element itself is NULL.
9420 (find_slot): Change return type. Adjust.
9421 (hash_expand, , add_index_entry, uniquify_cu_indices)
9422 (write_hash_table): Adjust.
9423
9424 2017-06-12 Pedro Alves <palves@redhat.com>
9425
9426 * dwarf2read.c (recursively_count_psymbols): New function.
9427 (write_psymtabs_to_index): Call it to compute number of psyms and
9428 pass estimate size of psyms_seen to unordered_set's ctor.
9429
9430 2017-06-12 Pedro Alves <palves@redhat.com>
9431
9432 * dwarf2read.c (write_hash_table): Check if key already exists
9433 before emplacing.
9434
9435 2017-06-12 Pedro Alves <palves@redhat.com>
9436
9437 * dwarf2read.c (data_buf::append_space): Rename to...
9438 (data_buf::grow): ... this, and make private. Adjust all callers.
9439 (data_buf::append_uint): New method.
9440 (add_address_entry, write_one_signatured_type)
9441 (write_psymtabs_to_index): Use it.
9442
9443 2017-06-12 Pedro Alves <palves@redhat.com>
9444
9445 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
9446 (file_write (FILE *, const std::vector<Elem>&)): Delete.
9447 (data_buf::file_write): Call ::fwrite directly.
9448
9449 2017-06-12 Pedro Alves <palves@redhat.com>
9450
9451 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
9452 std::vector::erase.
9453
9454 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9455
9456 Code cleanup: C++ify .gdb_index producer.
9457 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
9458 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
9459 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
9460 (create_strtab, add_string): Remove.
9461 (file_write, data_buf): New.
9462 (struct symtab_index_entry): Use std::vector for cu_indices.
9463 (struct mapped_symtab): Use std::vector for data.
9464 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
9465 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
9466 Remove.
9467 (find_slot): Change return type. Update it to the new data structures.
9468 (hash_expand, add_index_entry): Update it to the new data structures.
9469 (offset_type_compare): Remove.
9470 (uniquify_cu_indices): Update it to the new data structures.
9471 (c_str_view, c_str_view_hasher, vector_hasher): New.
9472 (add_indices_to_cpool): Remove.
9473 (write_hash_table): Update it to the new data structures.
9474 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
9475 (eq_psymtab_cu_index): Remove.
9476 (psym_index_map): New typedef.
9477 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
9478 reference and std::unordered_map for cu_index_htab.
9479 (add_address_entry, add_address_entry_worker, write_address_map)
9480 (write_psymbols): Update it to the new data structures.
9481 (write_obstack): Remove.
9482 (struct signatured_type_index_data): Change types_list to a data_buf
9483 reference and psyms_seen to a std::unordered_set reference.
9484 (write_one_signatured_type, recursively_write_psymbols)
9485 (write_psymtabs_to_index): Update it to the new data structures.
9486
9487 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
9488
9489 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
9490 separate-debug-file commands.
9491 * symfile.h (separate_debug_file_debug): New global.
9492 * symfile.c (separate_debug_file_debug): New global.
9493 (separate_debug_file_exists, find_separate_debug_file): Add
9494 debug output.
9495 (_initialize_symfile): Add "set debug separate-debug-file"
9496 command.
9497 * build-id.c (build_id_to_debug_bfd,
9498 find_separate_debug_file_by_buildid): Add debug output.
9499
9500 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
9501
9502 * gdbarch.sh (displaced_step_free_closure): Remove.
9503 * gdbarch.h, gdbarch.c: Re-generate.
9504 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
9505 displaced_step_free_closure.
9506 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
9507 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
9508 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9509 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
9510 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9511 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
9512 * arch-utils.h (simple_displaced_step_free_closure): Remove.
9513 * arch-utils.c (simple_displaced_step_free_closure): Remove.
9514 * infrun.c (displaced_step_clear): Call xfree instead of
9515 gdbarch_displaced_step_free_closure.
9516
9517 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
9518
9519 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
9520 NULL".
9521
9522 2017-06-08 Alan Hayward <alan.hayward@arm.com>
9523
9524 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
9525 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
9526 (mn10300_push_dummy_call): Likewise.
9527
9528 2017-06-08 Alan Hayward <alan.hayward@arm.com>
9529
9530 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
9531
9532 2017-06-08 Alan Hayward <alan.hayward@arm.com>
9533
9534 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
9535
9536 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9537
9538 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
9539 able to start inferiors using a shell.
9540 (New remote packets): Announce new packet "QStartupWithShell".
9541 * remote.c: Add PACKET_QStartupWithShell.
9542 (extended_remote_create_inferior): Handle new
9543 PACKET_QStartupWithShell.
9544 (remote_protocol_features) <QStartupWithShell>: New entry for
9545 PACKET_QStartupWithShell.
9546 (_initialize_remote): Call "add_packet_config_cmd" for
9547 QStartupShell.
9548
9549 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9550 Pedro Alves <palves@redhat.com>
9551
9552 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
9553 and "nat/fork-inferior.h".
9554 * common/common-inferior.h: New file, with contents from
9555 "gdb/inferior.h".
9556 * commom/common-utils.c: Include "common-utils.h".
9557 (stringify_argv): New function.
9558 * common/common-utils.h (stringify_argv): New prototype.
9559 * configure.nat: Add "fork-inferior.o" as a dependency for
9560 "*linux*", "fbsd*" and "nbsd*" hosts.
9561 * corefile.c (get_exec_file): Update comment.
9562 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
9563 instead of "startup_inferior".
9564 (darwin_create_inferior): Call "add_thread_silent" after
9565 "fork_inferior".
9566 * fork-child.c: Cleanup unnecessary includes.
9567 (SHELL_FILE): Move to "common/common-fork-child.c".
9568 (environ): Likewise.
9569 (exec_wrapper): Initialize.
9570 (get_exec_wrapper): New function.
9571 (breakup_args): Move to "common/common-fork-child.c"; rename to
9572 "breakup_args_for_exec".
9573 (escape_bang_in_quoted_argument): Move to
9574 "common/common-fork-child.c".
9575 (saved_ui): New variable.
9576 (prefork_hook): New function.
9577 (postfork_hook): Likewise.
9578 (postfork_child_hook): Likewise.
9579 (gdb_startup_inferior): Likewise.
9580 (fork_inferior): Move to "common/common-fork-child.c". Update
9581 function to support gdbserver.
9582 (startup_inferior): Likewise.
9583 * gdbcore.h (get_exec_file): Remove declaration.
9584 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
9585 instead of "startup_inferior". Call "add_thread_silent" after
9586 "fork_inferior".
9587 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
9588 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
9589 instead of "startup_inferior". Call "add_thread_silent" after
9590 "fork_inferior".
9591 * inferior.h: Include "common-inferior.h".
9592 (trace_start_error): Move to "common/common-utils.h".
9593 (trace_start_error_with_name): Likewise.
9594 (fork_inferior): Move prototype to "nat/fork-inferior.h".
9595 (startup_inferior): Likewise.
9596 (gdb_startup_inferior): New prototype.
9597 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
9598 * nat/fork-inferior.h: New file.
9599 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
9600 instead of "startup_inferior". Call "add_thread_silent" after
9601 "fork_inferior".
9602 * target.h (target_terminal_init): Move prototype to
9603 "target/target.h".
9604 (target_terminal_inferior): Likewise.
9605 (target_terminal_ours): Likewise.
9606 * target/target.h (target_terminal_init): New prototype, moved
9607 from "target.h".
9608 (target_terminal_inferior): Likewise.
9609 (target_terminal_ours): Likewise.
9610 * utils.c (gdb_flush_out_err): New function.
9611
9612 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9613
9614 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
9615 * common/common-gdbthread.h: New file, with parts from
9616 "gdb/gdbthread.h".
9617 * gdbthread.h: Include "common-gdbthread.h".
9618 (switch_to_thread): Moved to "common/common-gdbthread.h".
9619
9620 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9621
9622 * Makefile.in (SFILES): Add "common/job-control.c".
9623 (HFILES_NO_SRCDIR): Add "common/job-control.h".
9624 (COMMON_OBS): Add "job-control.o".
9625 * common/job-control.c: New file, with contents from
9626 "gdb/inflow.c".
9627 * common/job-control.h: New file, with contents from "terminal.h".
9628 * fork-child.c: Include "job-control.h".
9629 * inflow.c: Include "job-control.h".
9630 (gdb_setpgid): Move to "common/common-inflow.c".
9631 (_initialize_inflow): Move setting of "job_control" to
9632 "handle_job_control".
9633 * terminal.h (job_control): Moved to "common/common-terminal.h".
9634 (gdb_setpgid): Likewise.
9635 * top.c: Include "job_control.h".
9636 * utils.c: Likewise.
9637 (job_control): Moved to "job-control.c".
9638
9639 2017-06-07 Pedro Alves <palves@redhat.com>
9640
9641 * Makefile.in (SFILES): Add gdb_regex.c.
9642 (COMMON_OBS): Add gdb_regex.o.
9643 * ada-lang.c (ada_add_standard_exceptions)
9644 (ada_add_exceptions_from_frame, name_matches_regex)
9645 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
9646 parameter type to compiled_regex. Adjust.
9647 (ada_exceptions_list): Use compiled_regex.
9648 * break-catch-throw.c (exception_catchpoint::pattern): Now a
9649 std::unique_ptr<compiled_regex>.
9650 (exception_catchpoint::~exception_catchpoint): Remove regfree
9651 call.
9652 (check_status_exception_catchpoint): Adjust to use compiled_regex.
9653 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
9654 * breakpoint.c (solib_catchpoint::compiled): Now a
9655 std::unique_ptr<compiled_regex>.
9656 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
9657 (check_status_catch_solib): Adjust to use compiled_regex.
9658 (add_solib_catchpoint): Adjust to use compiled_regex.
9659 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
9660 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
9661 compiled_regex reference. Adjust to use it.
9662 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
9663 declaration. Include "gdb_regex.h".
9664 (apropos_cmd): Change regex parameter to compiled_regex reference.
9665 * gdb_regex.c: New file.
9666 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
9667 declarations.
9668 (class compiled_regex): New.
9669 * linux-tdep.c: Include "common/gdb_optional.h".
9670 (struct mapping_regexes): New, factored out from
9671 mapping_is_anonymous_p, and adjusted to use compiled_regex.
9672 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
9673 gdb::optional and remove cleanups. Adjust to compiled_regex.
9674 * probe.c: Include "common/gdb_optional.h".
9675 (collect_probes): Use compiled_regex and gdb::optional and remove
9676 cleanups.
9677 * skip.c: Include "common/gdb_optional.h".
9678 (skiplist_entry::compiled_function_regexp): Now a
9679 gdb::optional<compiled_regex>.
9680 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
9681 (free_skiplist_entry): Remove regfree call.
9682 (compile_skip_regexp, skip_rfunction_p): Adjust to use
9683 compiled_regex and gdb::optional.
9684 * symtab.c: Include "common/gdb_optional.h".
9685 (search_symbols): Use compiled_regex and gdb::optional.
9686 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
9687 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
9688 to gdb_regex.c.
9689
9690 2017-06-07 Alan Hayward <alan.hayward@arm.com>
9691
9692 * regcache.c (regcache::save): Avoid buffer use.
9693 (regcache::dump): Likewise.
9694
9695 2017-06-07 Alan Hayward <alan.hayward@arm.com>
9696
9697 * sh-tdep.c (sh_pseudo_register_read): Remove
9698 MAX_REGISTER_SIZE.
9699 (sh_pseudo_register_write): Likewise.
9700 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
9701 (sh64_pseudo_register_write): Likewise
9702
9703 2017-06-07 Alan Hayward <alan.hayward@arm.com>
9704
9705 * aarch64-tdep.c (aarch64_store_return_value): Use
9706 V_REGISTER_SIZE.
9707 (aarch64_pseudo_read_value): Likewise.
9708 (aarch64_pseudo_write): Likewise.
9709
9710 2017-06-06 Yao Qi <yao.qi@linaro.org>
9711
9712 * regformats/regdef.h (set_register_cache): Remove the
9713 declaration.
9714
9715 2017-06-06 Alan Hayward <alan.hayward@arm.com>
9716
9717 * frame.c (frame_unwind_register_signed): Use
9718 frame_unwind_register_value.
9719
9720 2017-06-06 Pedro Alves <palves@redhat.com>
9721
9722 PR breakpoints/21553
9723 * breakpoint.c (create_breakpoints_sal_default)
9724 (init_breakpoint_sal, create_breakpoint_sal): Use
9725 gdb::unique_xmalloc_ptr for string parameters.
9726 (create_breakpoint): Constify 'extra_string' and 'cond_string'
9727 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
9728 (base_breakpoint_create_breakpoints_sal)
9729 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
9730 (strace_marker_create_breakpoints_sal)
9731 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
9732 string parameters.
9733 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
9734 gdb::unique_xmalloc_ptr for string parameters.
9735 (create_breakpoint): Constify 'extra_string' and 'cond_string'
9736 parameters.
9737
9738 2017-06-06 Alan Hayward <alan.hayward@arm.com>
9739
9740 * alpha-tdep.c (alpha_register_to_value): Use
9741 get_frame_register_value.
9742 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
9743
9744 2017-06-06 Alan Hayward <alan.hayward@arm.com>
9745
9746 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
9747 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
9748 (ia64_value_to_register): Likewise.
9749 (ia64_extract_return_value): Likewise.
9750 (ia64_store_return_value): Likewise.
9751 (ia64_push_dummy_call): Likewise.
9752
9753 2017-06-04 Joel Brobecker <brobecker@adacore.com>
9754
9755 GDB 8.0 released.
9756
9757 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
9758
9759 * x86-linux-nat.c (struct arch_lwp_info): Remove.
9760
9761 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
9762
9763 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
9764 parameter.
9765 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
9766
9767 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
9768
9769 * event-loop.c (poll_timers): Unallocate timer using delete
9770 instead of xfree.
9771
9772 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9773
9774 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
9775 (struct breakpoint) <~breakpoint>: New.
9776 (struct watchpoint): Inherit from breakpoint.
9777 <~watchpoint>: New.
9778 <base>: Remove.
9779 (struct tracepoint): Inherit from breakpoint.
9780 <base>: Remove.
9781 * breakpoint.c (longjmp_breakpoint_ops): Remove.
9782 (struct longjmp_breakpoint): Inherit from breakpoint.
9783 <~longjmp_breakpoint>: New.
9784 <base>: Remove.
9785 (new_breakpoint_from_type): Remove casts.
9786 (watchpoint_in_thread_scope): Remove reference to base field.
9787 (watchpoint_del_at_next_stop): Likewise.
9788 (update_watchpoint): Likewise.
9789 (watchpoint_check): Likewise.
9790 (bpstat_check_watchpoint): Likewise.
9791 (set_longjmp_breakpoint): Likewise.
9792 (struct fork_catchpoint): Inherit from breakpoint.
9793 <base>: Remove.
9794 (struct solib_catchpoint): Inherit from breakpoint.
9795 <~solib_catchpoint>: New.
9796 <base>: Remove.
9797 (dtor_catch_solib): Change to ...
9798 (solib_catchpoint::~solib_catchpoint): ... this.
9799 (breakpoint_hit_catch_solib): Remove reference to base field.
9800 (add_solib_catchpoint): Likewise.
9801 (create_fork_vfork_event_catchpoint): Likewise.
9802 (struct exec_catchpoint): Inherit from breakpoint.
9803 <~exec_catchpoint>: New.
9804 <base>: Remove.
9805 (dtor_catch_exec): Change to ...
9806 (exec_catchpoint::~exec_catchpoint): ... this.
9807 (dtor_watchpoint): Change to ...
9808 (watchpoint::~watchpoint): ... this.
9809 (watch_command_1): Remove reference to base field.
9810 (catch_exec_command_1): Likewise.
9811 (base_breakpoint_dtor): Change to ...
9812 (breakpoint::~breakpoint): ... this.
9813 (base_breakpoint_ops): Remove dtor field value.
9814 (longjmp_bkpt_dtor): Change to ...
9815 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
9816 (strace_marker_create_breakpoints_sal): Remove reference to base
9817 field.
9818 (delete_breakpoint): Don't manually call breakpoint destructor.
9819 (create_tracepoint_from_upload): Remove reference to base field.
9820 (trace_pass_set_count): Likewise.
9821 (initialize_breakpoint_ops): Don't initialize
9822 momentary_breakpoint_ops, don't set dtors.
9823 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
9824 <~ada_catchpoint>: New.
9825 <base>: Remove.
9826 (create_excep_cond_exprs): Remove reference to base field.
9827 (dtor_exception): Change to ...
9828 (ada_catchpoint::~ada_catchpoint): ... this.
9829 (dtor_catch_exception): Remove.
9830 (dtor_catch_exception_unhandled): Remove.
9831 (dtor_catch_assert): Remove.
9832 (create_ada_exception_catchpoint): Remove reference to base
9833 field.
9834 (initialize_ada_catchpoint_ops): Don't set dtors.
9835 * break-catch-sig.c (struct signal_catchpoint): Inherit from
9836 breakpoint.
9837 <~signal_catchpoint>: New.
9838 <base>: Remove.
9839 (signal_catchpoint_dtor): Change to ...
9840 (signal_catchpoint::~signal_catchpoint): ... this.
9841 (create_signal_catchpoint): Remove reference to base field.
9842 (initialize_signal_catchpoint_ops): Don't set dtor.
9843 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
9844 from breakpoint.
9845 <~syscall_catchpoint>: New.
9846 <base>: Remove.
9847 (dtor_catch_syscall): Change to ...
9848 (syscall_catchpoint::~syscall_catchpoint): ... this.
9849 (create_syscall_event_catchpoint): Remove reference to base
9850 field.
9851 (initialize_syscall_catchpoint_ops): Don't set dtor.
9852 * break-catch-throw.c (struct exception_catchpoint): Inherit
9853 from breakpoint.
9854 <~exception_catchpoint>: New.
9855 <base>: Remove.
9856 (dtor_exception_catchpoint): Change to ...
9857 (exception_catchpoint::~exception_catchpoint): ... this.
9858 (handle_gnu_v3_exceptions): Remove reference to base field.
9859 (initialize_throw_catchpoint_ops): Don't set dtor.
9860 * ctf.c (ctf_get_traceframe_address): Remove reference to base
9861 field.
9862 * remote.c (remote_get_tracepoint_status): Likewise.
9863 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
9864 * tracefile.c (tracefile_fetch_registers): Likewise.
9865 * tracepoint.c (actions_command): Likewise.
9866 (validate_actionline): Likewise.
9867 (tfind_1): Likewise.
9868 (get_traceframe_location): Likewise.
9869 (find_matching_tracepoint_location): Likewise.
9870 (parse_tracepoint_status): Likewise.
9871 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
9872
9873 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9874
9875 * breakpoint.c (struct longjmp_breakpoint): New struct.
9876 (is_tracepoint_type): Change return type to bool.
9877 (is_longjmp_type): New function.
9878 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
9879 (set_raw_breakpoint_without_location): Use
9880 new_breakpoint_from_type.
9881 (set_raw_breakpoint): Likewise.
9882
9883 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9884
9885 * breakpoint.c (new_breakpoint_from_type): New function.
9886 (create_breakpoint_sal): Use new_breakpoint_from_type and
9887 unique_ptr.
9888 (create_breakpoint): Likewise.
9889
9890 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
9891
9892 * memattr.c (mem_info_command): Rename to ...
9893 (info_mem_command): ... this.
9894 (mem_enable_command): Rename to ...
9895 (enable_mem_command): ... this.
9896 (mem_disable_command): Rename to ...
9897 (disable_mem_command): ... this.
9898 (mem_delete_command): Rename to ...
9899 (delete_mem_command): ... this.
9900 (_initialize_mem): Adjust function names.
9901
9902 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
9903
9904 * btrace.c (handle_pt_insn_events): New.
9905 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
9906 STATUS. Split into this and ...
9907 (handle_pt_insn_event_flags): ... this.
9908
9909 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
9910
9911 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
9912 and struct pt_insn.resynced.
9913 * configure: Regenerated.
9914 * config.in: Regenerated.
9915
9916 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9917
9918 * btrace.c (ftrace_find_call_by_number): New function.
9919 (ftrace_new_function): Store objects, not pointers.
9920 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
9921 ftrace_new_gap, ftrace_update_function,
9922 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
9923 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
9924 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
9925 btrace_ends_with_single_insn, btrace_call_get): Account for
9926 btrace_thread_info::functions now storing objects.
9927 * btrace.h (struct btrace_thread_info): Add constructor.
9928 (struct btrace_thread_info) <functions>: Make std::vector.
9929 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
9930 Initialize with default values.
9931 * record-btrace.c (record_btrace_frame_sniffer): Account for
9932 btrace_thread_info::functions now storing objects.
9933
9934 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9935
9936 * btrace.c: Remove typedef bfun_s.
9937 (ftrace_new_gap): Directly add gaps to the list of gaps.
9938 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
9939 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
9940 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
9941 instead of gdb VEC.
9942
9943 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9944
9945 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
9946 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
9947 with btrace_thread_info::next_segment and
9948 btrace_thread_info::prev_segment.
9949 * btrace.h: Remove struct btrace_func_link.
9950 (struct btrace_function): Replace pair of function segment pointers
9951 with pair of indices.
9952 * python/py-record-btrace.c (btpy_call_prev_sibling,
9953 btpy_call_next_sibling): Replace references to
9954 btrace_thread_info::segment with btrace_thread_info::next_segment and
9955 btrace_thread_info::prev_segment.
9956 * record-btrace.c (record_btrace_frame_this_id): Use
9957 btrace_find_call_by_number.
9958
9959 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9960
9961 * btrace.c (ftrace_new_function, ftrace_fixup_level,
9962 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
9963 btrace_insn_next, btrace_insn_prev): Remove references to
9964 btrace_thread_info::flow.
9965 * btrace.h (struct btrace_function): Remove FLOW.
9966
9967 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9968
9969 * btrace.c (ftrace_find_call_by_number): New function.
9970 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
9971 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
9972 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
9973 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
9974 index.
9975 * btrace.h (struct btrace_function): Turn UP into an index.
9976 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
9977 as an index.
9978 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
9979 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
9980 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
9981
9982 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9983
9984 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
9985 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
9986 ftrace_update_function, ftrace_compute_global_level_offset,
9987 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
9988 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
9989 btrace_insn_end, btrace_is_empty): Remove references to
9990 btrace_thread_info::begin and btrace_thread_info::end.
9991 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
9992 (struct btrace_thread_info) <functions>: Adjust comment.
9993 * record-btrace.c (record_btrace_start_replaying): Remove reference to
9994 btrace_thread_info::begin.
9995
9996 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9997
9998 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
9999 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
10000 ftrace_update_function): Remove arguments that implicitly were always
10001 BTINFO->END.
10002 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
10003 Don't pass BTINFO->END.
10004
10005 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10006
10007 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
10008 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
10009 btrace_find_insn_by_number): Replace function segment pointer with
10010 index.
10011 (btrace_insn_cmp): Simplify.
10012 * btrace.h: (struct btrace_insn_iterator) Rename index to
10013 insn_index. Replace function segment pointer with index into function
10014 segment vector.
10015 * record-btrace.c (record_btrace_call_history): Replace function
10016 segment pointer use with index.
10017 (record_btrace_frame_sniffer): Retrieve function call segment through
10018 vector.
10019 (record_btrace_set_replay): Remove defunc't safety check.
10020
10021 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10022
10023 * btrace.c (btrace_ends_with_single_insn): New function.
10024 (btrace_call_get, btrace_call_number, btrace_call_begin,
10025 btrace_call_end, btrace_call_next, btrace_call_prev,
10026 btrace_find_call_by_number): Use index into call segment vector
10027 instead of pointer.
10028 (btrace_call_cmp): Simplify.
10029 * btrace.h (struct btrace_call_iterator): Replace function call segment
10030 pointer with index into vector.
10031 * record-btrace.c (record_btrace_call_history): Use index instead of
10032 pointer.
10033
10034 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10035
10036 * btrace.c (btrace_insn_begin, btrace_insn_end,
10037 btrace_find_insn_by_number): Add btinfo to iterator.
10038 * btrace.h (struct btrace_insn_iterator): Add btinfo.
10039
10040 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10041
10042 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
10043 and save pointers directly.
10044 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
10045 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
10046 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
10047 changed signature of functions.
10048 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
10049 (btrace_fetch): Remove code that adds btrace_function pointers to
10050 vector of btrace_functions.
10051 (btrace_clear): Simplify freeing vector of btrace_functions.
10052
10053 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10054
10055 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
10056 Replace VEC_* with std::vector functions.
10057 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
10058 (struct btrace_thread_info)<functions>: Change type to std::vector.
10059
10060 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
10061
10062 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
10063 "Removed targets and native configurations" up. Merge duplicate
10064 "New commands" sub-sections. Add "New options" sub-sections.
10065
10066 2017-05-26 Alan Hayward <alan.hayward@arm.com>
10067
10068 * defs.h (copy_integer_to_size): New declaration.
10069 * findvar.c (copy_integer_to_size): New function.
10070 (do_cint_test): New selftest function.
10071 (copy_integer_to_size_test): Likewise.
10072 (_initialize_findvar): Likewise.
10073 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
10074 (mips_fbsd_collect_reg): Use raw_collect_integer.
10075 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
10076 (mips64_fill_gregset): Use raw_collect_integer
10077 (mips64_fill_fpregset): Use raw_supply_integer.
10078 * regcache.c (regcache::raw_supply_integer): New function.
10079 (regcache::raw_collect_integer): Likewise.
10080 * regcache.h: (regcache::raw_supply_integer): New declaration.
10081 (regcache::raw_collect_integer): Likewise.
10082
10083 2017-05-24 Yao Qi <yao.qi@linaro.org>
10084
10085 * Makefile.in (SFILES): Add gdbarch-selftests.c.
10086 (COMMON_OBS): Add gdbarch-selftests.o.
10087 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
10088 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
10089 * gdbarch-selftests.c: New file.
10090 * regcache.h (regcache) <~regcache>: Mark it virtual if
10091 GDB_SELF_TEST.
10092 <raw_write>: Likewise.
10093
10094 2017-05-24 Yao Qi <yao.qi@linaro.org>
10095
10096 * regcache.c (current_regcache): Change it to
10097 regcache::current_regcache.
10098 (regcache_observer_target_changed): Update.
10099 (regcache_thread_ptid_changed): Make it a regcache static
10100 method.
10101 (regcache_thread_ptid_changed): Update.
10102 (class regcache_access): New.
10103 (current_regcache_test): Update.
10104 (_initialize_regcache): Update.
10105 * regcache.h: Include forward_list.
10106 (regcache): Declare regcache_thread_ptid_changed and declare
10107 registers_changed_ptid as friend.
10108
10109 2017-05-24 Yao Qi <yao.qi@linaro.org>
10110
10111 * i387-tdep.c (i387_register_to_value): Use register_size
10112 instead of TYPE_LENGTH.
10113 * m68k-tdep.c (m68k_register_to_value): Likewise.
10114
10115 2017-05-24 Yao Qi <yao.qi@linaro.org>
10116
10117 * i387-tdep.c (i387_convert_register_p): Return false if type
10118 code isn't TYPE_CODE_FLT.
10119
10120 2017-05-24 Yao Qi <yao.qi@linaro.org>
10121
10122 * alpha-tdep.c (alpha_convert_register_p): Return true if type
10123 length is 4.
10124 (alpha_register_to_value): Remove type length check.
10125 (alpha_value_to_register): Likewise.
10126
10127 2017-05-24 Yao Qi <yao.qi@linaro.org>
10128
10129 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
10130 TYPE_CODE_FLT.
10131
10132 2017-05-24 Yao Qi <yao.qi@linaro.org>
10133
10134 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
10135 TYPE_CODE_FLT or not.
10136
10137 2017-05-24 Yao Qi <yao.qi@linaro.org>
10138
10139 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
10140 * avr-tdep.c (avr_gdbarch_init): Likewise.
10141 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
10142 * cris-tdep.c (cris_gdbarch_init): Likewise.
10143 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
10144 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
10145 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10146 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
10147 * mep-tdep.c (mep_gdbarch_init): Likewise.
10148 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
10149 * mips-tdep.c (mips_gdbarch_init): Likewise.
10150 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
10151 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10152 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
10153 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
10154 * v850-tdep.c (v850_gdbarch_init): Likewise.
10155
10156 2017-05-24 Yao Qi <yao.qi@linaro.org>
10157
10158 * selftest-arch.c (tests_with_arch): Call registers_changed
10159 and reinit_frame_cache.
10160 * selftest.c (run_self_tests): Likewise.
10161
10162 2017-05-24 Yao Qi <yao.qi@linaro.org>
10163
10164 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
10165 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
10166
10167 2017-05-24 Yao Qi <yao.qi@linaro.org>
10168
10169 * rl78-tdep.c (rl78_gdbarch_init): Don't call
10170 set_gdbarch_print_insn.
10171
10172 2017-05-24 Yao Qi <yao.qi@linaro.org>
10173
10174 * h8300-tdep.c (h8300_gdbarch_init): Don't call
10175 set_gdbarch_print_insn.
10176
10177 2017-05-24 Yao Qi <yao.qi@linaro.org>
10178
10179 * alpha-tdep.c (alpha_gdbarch_init): Don't call
10180 set_gdbarch_print_insn.
10181 * arc-tdep.c (arc_gdbarch_init): Likewise.
10182 * arch-utils.c: include dis-asm.h.
10183 (default_print_insn): New function.
10184 * arch-utils.h (default_print_insn): Declare.
10185 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
10186 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
10187 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
10188 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
10189 * frv-tdep.c (frv_gdbarch_init): Likewise.
10190 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
10191 * gdbarch.sh (print_insn): Use default_print_insn.
10192 * gdbarch.c: Regenerated.
10193 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
10194 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
10195 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
10196 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
10197 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10198 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
10199 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
10200 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
10201 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
10202 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
10203 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
10204 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10205 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
10206 * mt-tdep.c (mt_gdbarch_init): Likewise.
10207 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10208 * nios2-tdep.c (nios2_print_insn): Remove.
10209 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
10210 * rx-tdep.c (rx_gdbarch_init): Likewise.
10211 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
10212 * score-tdep.c (score_print_insn): Remove.
10213 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
10214 * sh-tdep.c (sh_gdbarch_init): Likewise.
10215 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
10216 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10217 * tic6x-tdep.c (tic6x_print_insn): Remove.
10218 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
10219 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
10220 * v850-tdep.c (v850_gdbarch_init): Likewise.
10221 * vax-tdep.c (vax_gdbarch_init): Likewise.
10222 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
10223 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
10224
10225 2017-05-23 John Baldwin <jhb@FreeBSD.org>
10226
10227 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
10228 (MIPS_FP0_REGNUM): Remove.
10229 (MIPS_FSR_REGNUM): Remove.
10230 (mips_fbsd_supply_fpregs): Use mips_regnum.
10231 (mips_fbsd_supply_gregs): Likewise.
10232 (mips_fbsd_collect_fpregs): Likewise.
10233 (mips_fbsd_collect_gregs): Likewise.
10234
10235 2017-05-23 John Baldwin <jhb@FreeBSD.org>
10236
10237 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
10238 (getpfpregs_supplies): New function.
10239 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
10240 getfpregs_supplies.
10241 (mips_fbsd_store_inferior_registers): Likewise.
10242
10243 2017-05-22 Pedro Alves <palves@redhat.com>
10244
10245 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
10246 maintainer.
10247
10248 2017-05-22 Alan Hayward <alan.hayward@arm.com>
10249
10250 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
10251 (store_register): Likewise.
10252 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
10253 (get_decimal_float_return_value): Likewise.
10254 (do_ppc_sysv_return_value): Likewise.
10255 (ppc64_sysv_abi_push_integer): Likewise.
10256 (ppc64_sysv_abi_push_freg): Likewise.
10257 (ppc64_sysv_abi_return_value_base): Likewise.
10258 (ppc64_sysv_abi_return_value): Likewise.
10259 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
10260 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
10261 * rs6000-nat.c: Likewise.
10262 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
10263 (rs6000_value_to_register): Likewise.
10264 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
10265
10266 2017-05-21 Tom Tromey <tom@tromey.com>
10267
10268 PR rust/21466:
10269 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
10270 arrays as "[T]", not "[T; ]".
10271
10272 2017-05-19 Tom Tromey <tom@tromey.com>
10273
10274 PR rust/21484:
10275 * rust-lang.c (exp_descriptor_rust): New function.
10276 (rust_language_defn): Use it.
10277 * p-lang.c (pascal_language_defn): Update.
10278 * opencl-lang.c (opencl_language_defn): Update.
10279 * objc-lang.c (objc_language_defn): Update.
10280 * m2-lang.c (m2_language_defn): Update.
10281 * language.h (struct language_defn)
10282 <la_watch_location_expression>: New member.
10283 * language.c (unknown_language_defn, auto_language_defn)
10284 (local_language_defn): Update.
10285 * go-lang.c (go_language_defn): Update.
10286 * f-lang.c (f_language_defn): Update.
10287 * d-lang.c (d_language_defn): Update.
10288 * c-lang.h (c_watch_location_expression): Declare.
10289 * c-lang.c (c_watch_location_expression): New function.
10290 (c_language_defn, cplus_language_defn, asm_language_defn)
10291 (minimal_language_defn): Use it.
10292 * breakpoint.c (watch_command_1): Call
10293 la_watch_location_expression.
10294 * ada-lang.c (ada_language_defn): Update.
10295
10296 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10297
10298 PR tui/21482
10299 * gdb_curses.h (NOMACROS): Define.
10300 (NCURSES_NOMACROS): Define.
10301
10302 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10303
10304 PR tui/21482
10305 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
10306 arg to char *.
10307 * tui/tui-wingeneral.c (box_win): Likewise.
10308 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
10309 (tui_show_source_line): Likewise.
10310 (tui_show_exec_info_content): Likewise.
10311
10312 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
10313
10314 * sparc-tdep.c (sparc_structure_return_p)
10315 (sparc_arg_on_registers_p): New functions.
10316 (sparc32_store_arguments): Use them.
10317 * sparc64-tdep.c (sparc64_16_byte_align_p)
10318 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
10319 Handle TYPE_CODE_ARRAY.
10320
10321 2017-05-17 Yao Qi <yao.qi@linaro.org>
10322
10323 * cli/cli-decode.c (add_alias_cmd): New function.
10324 * command.h (add_alias_cmd): Declare.
10325 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
10326 instead call add_alias_cmd.
10327
10328 2017-05-17 Pedro Alves <palves@redhat.com>
10329
10330 * Makefile.in (nat_extra_makefile_frag): Rename to ...
10331 (nat_makefile_frag): ... this. All references updated.
10332 * configure.ac: Likewise.
10333 * configure.nat: Likewise. Enhance comments.
10334 * configure: Regenerate.
10335
10336 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10337
10338 * procfs.c (procfs_create_inferior): Change prototype to match
10339 definition.
10340
10341 2017-05-13 Eli Zaretskii <eliz@gnu.org>
10342
10343 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
10344 C++ compiler warning.
10345
10346 2017-05-12 Tom Tromey <tom@tromey.com>
10347
10348 PR rust/21483:
10349 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
10350 recurse, just call value_struct_elt directly.
10351
10352 2017-05-12 Tom Tromey <tom@tromey.com>
10353
10354 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
10355 OP_RUST_ARRAY>: Fix.
10356
10357 2017-05-12 Tom Tromey <tom@tromey.com>
10358
10359 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
10360
10361 2017-05-09 Yao Qi <yao.qi@linaro.org>
10362
10363 * regcache.c: Include <forward_list>.
10364 (struct regcache_list): Remove.
10365 (current_regcache): Update.
10366 (get_thread_arch_aspace_regcache): Update for std::forward_list.
10367 (regcache_thread_ptid_changed): Likewise.
10368 (registers_changed_ptid): Likewise.
10369 (current_regcache_size): Likewise.
10370
10371 2017-05-09 Yao Qi <yao.qi@linaro.org>
10372
10373 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
10374 (current_regcache_size): New function.
10375 (current_regcache_test): New function.
10376 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
10377
10378 2017-05-08 Alan Hayward <alan.hayward@arm.com>
10379
10380 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
10381 (print_gp_register_row): Use get_frame_register_value.
10382
10383 2017-05-08 Alan Hayward <alan.hayward@arm.com>
10384
10385 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
10386 (mips_supply_fpregset): Likewise.
10387 (mips64_supply_gregset): Likewise.
10388
10389 2017-05-08 Alan Hayward <alan.hayward@arm.com>
10390
10391 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
10392 regcache->raw_supply_zeroed.
10393
10394 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
10395
10396 * configure.nat: Rearrange 'case' statements to match
10397 host before cpu.
10398
10399 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
10400
10401 * Makefile.in: Remove "@host_makefile_frag@". Add variables
10402 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
10403 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
10404 "@nat_extra_makefile_frag@".
10405 (Makefile): Remove dependency on "@frags@".
10406 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
10407 (data-directory/Makefile): Likewise.
10408 * config/aarch64/linux.mh: Deleted; moved contents to
10409 "gdb/configure.nat".
10410 * config/alpha/alpha-linux.mh: Likewise.
10411 * config/alpha/nbsd.mh: Likewise.
10412 * config/arm/linux.mh: Likewise.
10413 * config/arm/nbsdelf.mh: Likewise.
10414 * config/i386/cygwin.mh: Likewise.
10415 * config/i386/cygwin64.mh: Likewise.
10416 * config/i386/darwin.mh: Likewise.
10417 * config/i386/fbsd.mh: Likewise.
10418 * config/i386/fbsd64.mh: Likewise.
10419 * config/i386/go32.mh: Likewise.
10420 * config/i386/i386gnu.mh: Likewise.
10421 * config/i386/i386sol2.mh: Likewise.
10422 * config/i386/linux.mh: Likewise.
10423 * config/i386/linux64.mh: Likewise.
10424 * config/i386/mingw.mh: Likewise.
10425 * config/i386/mingw64.mh: Likewise.
10426 * config/i386/nbsd64.mh: Likewise.
10427 * config/i386/nbsdelf.mh: Likewise.
10428 * config/i386/nto.mh: Likewise.
10429 * config/i386/obsd.mh: Likewise.
10430 * config/i386/obsd64.mh: Likewise.
10431 * config/i386/sol2-64.mh: Likewise.
10432 * config/ia64/linux.mh: Likewise.
10433 * config/m32r/linux.mh: Likewise.
10434 * config/m68k/linux.mh: Likewise.
10435 * config/m68k/nbsdelf.mh: Likewise.
10436 * config/m68k/obsd.mh: Likewise.
10437 * config/m88k/obsd.mh: Likewise.
10438 * config/mips/fbsd.mh: Likewise.
10439 * config/mips/linux.mh: Likewise.
10440 * config/mips/nbsd.mh: Likewise.
10441 * config/mips/obsd64.mh: Likewise.
10442 * config/pa/linux.mh: Likewise.
10443 * config/pa/nbsd.mh: Likewise.
10444 * config/pa/obsd.mh: Likewise.
10445 * config/powerpc/aix.mh: Likewise.
10446 * config/powerpc/fbsd.mh: Likewise.
10447 * config/powerpc/linux.mh: Likewise.
10448 * config/powerpc/nbsd.mh: Likewise.
10449 * config/powerpc/obsd.mh: Likewise.
10450 * config/powerpc/ppc64-linux.mh: Likewise.
10451 * config/powerpc/spu-linux.mh: Likewise.
10452 * config/s390/linux.mh: Likewise.
10453 * config/sh/nbsd.mh: Likewise.
10454 * config/sparc/fbsd.mh: Likewise.
10455 * config/sparc/linux.mh: Likewise.
10456 * config/sparc/linux64.mh: Likewise.
10457 * config/sparc/nbsd64.mh: Likewise.
10458 * config/sparc/nbsdelf.mh: Likewise.
10459 * config/sparc/obsd64.mh: Likewise.
10460 * config/sparc/sol2.mh: Likewise.
10461 * config/tilegx/linux.mh: Likewise.
10462 * config/vax/nbsdelf.mh: Likewise.
10463 * config/vax/obsd.mh: Likewise.
10464 * config/xtensa/linux.mh: Likewise.
10465 * config/i386/i386gnu.mn: New file, with excerpts from
10466 "config/i386/i386gnu.mh".
10467 * configure: Regenerate.
10468 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
10469 *.mh files under "gdb/config".
10470 * configure.nat: New file, with contents from the
10471 "gdb/config/*/*.mh" files.
10472
10473 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
10474
10475 * btrace.c (btrace_clear): Free insn vector.
10476
10477 2017-05-05 Pedro Alves <palves@redhat.com>
10478
10479 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
10480 * configure: Regenerate.
10481
10482 2017-05-04 Pedro Alves <palves@redhat.com>
10483
10484 * Makefile.in (SFILES): Add progspace-and-thread.c.
10485 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
10486 (COMMON_OBS): Add progspace-and-thread.o.
10487 * breakpoint.c: Include "progspace-and-thread.h".
10488 (update_inserted_breakpoint_locations)
10489 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
10490 Use scoped_restore_current_pspace_and_thread.
10491 (create_std_terminate_master_breakpoint): Use
10492 scoped_restore_current_program_space.
10493 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
10494 (print_breakpoint_location): Use
10495 scoped_restore_current_program_space.
10496 (bp_loc_is_permanent): Use
10497 scoped_restore_current_pspace_and_thread.
10498 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
10499 (download_tracepoint_locations): Use
10500 scoped_restore_current_pspace_and_thread.
10501 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
10502 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
10503 (enum step_over_calls_kind): Moved from inferior.h.
10504 (class scoped_restore_current_thread): New class.
10505 * gdbthread.h (make_cleanup_restore_current_thread): Delete
10506 declaration.
10507 (scoped_restore_current_thread): New class.
10508 * infcmd.c: Include "common/gdb_optional.h".
10509 (continue_1, proceed_after_attach): Use
10510 scoped_restore_current_thread.
10511 (notice_new_inferior): Use scoped_restore_current_thread.
10512 * inferior.c: Include "progspace-and-thread.h".
10513 (restore_inferior, save_current_inferior): Delete.
10514 (add_inferior_command, clone_inferior_command): Use
10515 scoped_restore_current_pspace_and_thread.
10516 * inferior.h (scoped_restore_current_inferior): New class.
10517 * infrun.c: Include "progspace-and-thread.h" and
10518 "common/gdb_optional.h".
10519 (follow_fork_inferior): Use
10520 scoped_restore_current_pspace_and_thread.
10521 (scoped_restore_exited_inferior): New class.
10522 (handle_vfork_child_exec_or_exit): Use
10523 scoped_restore_exited_inferior,
10524 scoped_restore_current_pspace_and_thread,
10525 scoped_restore_current_thread and scoped_restore.
10526 (fetch_inferior_event): Use scoped_restore_current_thread.
10527 * linespec.c (decode_line_full, decode_line_1): Use
10528 scoped_restore_current_program_space.
10529 * mi/mi-main.c: Include "progspace-and-thread.h".
10530 (exec_continue): Use scoped_restore_current_thread.
10531 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
10532 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
10533 * proc-service.c (ps_pglobal_lookup): Use
10534 scoped_restore_current_program_space.
10535 * progspace-and-thread.c: New file.
10536 * progspace-and-thread.h: New file.
10537 * progspace.c (release_program_space, clone_program_space): Use
10538 scoped_restore_current_program_space.
10539 (restore_program_space, save_current_program_space)
10540 (save_current_space_and_thread): Delete.
10541 (switch_to_program_space_and_thread): Moved to
10542 progspace-and-thread.c.
10543 * progspace.h (save_current_program_space)
10544 (save_current_space_and_thread): Delete declarations.
10545 (scoped_restore_current_program_space): New class.
10546 * remote.c (remote_btrace_maybe_reopen): Use
10547 scoped_restore_current_thread.
10548 * symtab.c: Include "progspace-and-thread.h".
10549 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
10550 * thread.c (print_thread_info_1): Use
10551 scoped_restore_current_thread.
10552 (struct current_thread_cleanup): Delete.
10553 (do_restore_current_thread_cleanup)
10554 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
10555 (scoped_restore_current_thread::~scoped_restore_current_thread):
10556 ... this new dtor.
10557 (make_cleanup_restore_current_thread): Rename/convert to ...
10558 (scoped_restore_current_thread::scoped_restore_current_thread):
10559 ... this new ctor.
10560 (thread_apply_all_command): Use scoped_restore_current_thread.
10561 (thread_apply_command): Use scoped_restore_current_thread.
10562 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
10563 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
10564
10565 2017-05-04 Pedro Alves <palves@redhat.com>
10566
10567 * thread.c (make_cleanup_restore_current_thread): Move
10568 find_thread_ptid call before the is_stopped call. Assert that the
10569 thread is found. Replace is_stopped call by checking the thread's
10570 state directly. Remove unnecessary NULL-thread check.
10571
10572 2017-05-04 Pedro Alves <palves@redhat.com>
10573
10574 * corelow.c (thread_section_name): New class.
10575 (get_core_register_section, get_core_siginfo): Use it.
10576
10577 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
10578
10579 * corelow.c (sniff_core_bfd): Remove extra semicolon.
10580 (get_core_register_section): Remove xfree of NULL pointer.
10581
10582 2017-05-03 Alan Hayward <alan.hayward@arm.com>
10583
10584 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
10585 * regcache.c (regcache::raw_supply_zeroed): New function.
10586 * regcache.h (regcache::raw_supply_zeroed): New declaration.
10587
10588 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
10589
10590 * gdbarch.sh: Remove commented out definition of
10591 TARGET_CHAR_BIT.
10592 * gdbarch.h: Re-generate.
10593
10594 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
10595
10596 * configure: Regenerate.
10597
10598 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
10599
10600 * solib-target.c (solib_target_relocate_section_addresses):
10601 Remove num_section_bases, num_bases, segment_bases variables.
10602
10603 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10604
10605 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
10606
10607 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10608
10609 * solib-target.c: Include <vector>
10610 (struct lm_info_target) <~lm_info_target>: Remove.
10611 <segment_bases, section_bases>: Change type to
10612 std::vector<CORE_ADDR>.
10613 (library_list_start_segment, library_list_start_section,
10614 library_list_end_library,
10615 solib_target_relocate_section_addresses): Adjust.
10616
10617 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10618
10619 * gdbarch.sh (software_single_step): Change return type to
10620 std::vector<CORE_ADDR>.
10621 * gdbarch.c, gdbarch.h: Re-generate.
10622 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
10623 Adjust.
10624 (arm_deal_with_atomic_sequence_raw): Adjust.
10625 (thumb_get_next_pcs_raw): Adjust.
10626 (arm_get_next_pcs_raw): Adjust.
10627 (arm_get_next_pcs): Adjust.
10628 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
10629 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
10630 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
10631 (alpha_software_single_step): Adjust.
10632 * alpha-tdep.h (alpha_software_single_step): Adjust.
10633 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
10634 * arm-tdep.c (arm_software_single_step): Adjust.
10635 (arm_breakpoint_kind_from_current_state): Adjust.
10636 * arm-tdep.h (arm_software_single_step): Adjust.
10637 * breakpoint.c (insert_single_step_breakpoint): Adjust.
10638 * cris-tdep.c (cris_software_single_step): Adjust.
10639 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
10640 (micromips_deal_with_atomic_sequence): Adjust.
10641 (deal_with_atomic_sequence): Adjust.
10642 (mips_software_single_step): Adjust.
10643 * mips-tdep.h (mips_software_single_step): Adjust.
10644 * moxie-tdep.c (moxie_software_single_step): Adjust.
10645 * nios2-tdep.c (nios2_software_single_step): Adjust.
10646 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
10647 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
10648 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
10649 * s390-linux-tdep.c (s390_software_single_step): Adjust.
10650 * sparc-tdep.c (sparc_software_single_step): Adjust.
10651 * spu-tdep.c (spu_software_single_step): Adjust.
10652 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
10653
10654 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10655
10656 * gdbarch.sh: Use semi-colon as field separator instead of colon.
10657 * gdbarch.h: Re-generate.
10658
10659 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10660
10661 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
10662 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
10663 * python/py-instruction.c, python/py-instruction.h: New file.
10664 * python/py-record.c: Add py-instruction.h include.
10665 (gdbpy_initialize_record): Make gdb.Instruction a super class of
10666 gdb.RecordInstruction.
10667 * python/python-internal.h: Add gdbpy_initialize_instruction
10668 declaration.
10669 * python/python.c (do_start_initialization): Add
10670 gdbpy_initialize_instruction.
10671
10672 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10673
10674 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
10675 Remove.
10676 (btrace_func_from_recpy_func): New function.
10677 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
10678 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
10679 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
10680 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
10681 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
10682 Also, use new helper functions.
10683 (btpy_list_item): Use new helper functions.
10684 (recpy_bt_function_call_history): Use new type name.
10685 (btpy_call_getset): Remove.
10686 (gdbpy_initialize_btrace): Remove code to initialize
10687 gdb.BtraceFunctionCall.
10688 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
10689 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
10690 recpy_bt_func_prev, recpy_bt_func_next): New export.
10691 * python/py-record.c (recpy_func_type): New static object.
10692 (recpy_func_new, recpy_func_level, recpy_func_symbol,
10693 recpy_func_instructions, recpy_func_up, recpy_func_prev,
10694 recpy_func_next): New function.
10695 (recpy_element_hash, recpy_element_richcompare): Updated comment.
10696 (recpy_func_getset): New static object.
10697 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
10698 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
10699
10700 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10701
10702 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
10703 (btpy_object, btpy_insn_type, btpy_new): Remove.
10704 (btpy_list_object): Use gdb.RecordInstruction type instead of
10705 gdb.BtraceInstruction type.
10706 (btrace_insn_from_recpy_insn): New function.
10707 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
10708 btpy_new.
10709 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
10710 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
10711 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
10712 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
10713 instead of btpy_object.
10714 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
10715 btpy_insn_data, btpy_insn_decode): Rename to ...
10716 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
10717 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
10718 recpy_bt_insn_decode): This. Also, use new helper functions.
10719 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
10720 recpy_insn_type.
10721 (btpy_insn_getset): Remove.
10722 (gdbpy_initialize_btrace): Remove code to initialize
10723 gdb.BtraceInstruction. Use recpy_element_object.
10724 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
10725 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
10726 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
10727 * python/py-record.c (recpy_insn_type): New static object.
10728 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
10729 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
10730 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
10731 New function.
10732 (recpy_insn_getset): New static object.
10733 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
10734 * python/py-record.h (recpy_element_object): New typedef.
10735 (recpy_insn_type, recpy_insn_new): New export.
10736
10737 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10738
10739 * py-record-btrace.c (btpy_insn_new): Removed.
10740 (btpy_insn_or_gap_new): New function.
10741 (btpy_insn_error): Removed.
10742 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
10743 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
10744 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
10745 btpy_insn_or_gap_new instead of btpy_insn_new.
10746 (btpy_insn_getset): Remove btpy_insn_error.
10747 * py-record.c (recpy_gap_type): New static object.
10748 (recpy_gap_object): New typedef.
10749 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
10750 recpy_gap_reason_string): New function.
10751 (recpy_gap_getset): New static object.
10752 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
10753 * py-record.h (recpy_gap_new): New export.
10754
10755 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10756
10757 * python/py-record.c (recpy_ptid): Remove.
10758 (recpy_record_getset): Remove recpy_ptid.
10759
10760 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10761
10762 * btrace.c (btrace_fetch): Set inferior_ptid.
10763 * python/py-record-btrace.c: Add "py-record.h" include.
10764 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
10765 recpy_bt_end, recpy_bt_instruction_history,
10766 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
10767 in gdb.Record object instead of current ptid.
10768 * python/py-record.c: Include new "py-record.h" file.
10769 (recpy_record_object): Moved to py-record.h.
10770 * python/py-record.h: New file.
10771
10772 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10773
10774 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
10775 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
10776 indentation.
10777
10778 2017-05-01 Joel Brobecker <brobecker@adacore.com>
10779
10780 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
10781 the past maintainers section.
10782
10783 2017-04-28 Yao Qi <yao.qi@linaro.org>
10784
10785 * infcmd.c (get_return_value): Use regcache ctor, and remove
10786 cleanup.
10787
10788 2017-04-28 Yao Qi <yao.qi@linaro.org>
10789 Pedro Alves <palves@redhat.com>
10790
10791 * regcache.c (regcache::regcache): New tag dispatch ctor.
10792 (do_cooked_read): Moved above.
10793 (regcache_dup): Use the tag dispatch ctor..
10794 * regcache.h (regcache): Declare ctor, delete copy ctor and
10795 assignment operator, remove friend regcache_dup.
10796
10797 2017-04-28 Yao Qi <yao.qi@linaro.org>
10798
10799 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
10800 call method save instead of regcache_cpy.
10801 * regcache.h (struct regcache): Make regcache_dup a friend.
10802
10803 2017-04-28 Yao Qi <yao.qi@linaro.org>
10804
10805 * regcache.c (struct regcache): Move to regcache.h
10806 (regcache::arch): New method.
10807 (regcache_get_ptid): Update.
10808 (get_regcache_arch): Call arch method.
10809 (get_regcache_aspace): Call method aspace.
10810 (register_buffer): Change it to method.
10811 (regcache_save): Change it to regcache::save.
10812 (regcache_restore): Likewise.
10813 (regcache_cpy_no_passthrough): Remove the declaration.
10814 (regcache_cpy): Call methods restore and cpy_no_passthrough.
10815 (regcache_cpy_no_passthrough): Change it to method
10816 cpy_no_passthrough.
10817 (regcache_register_status): Change it to method
10818 get_register_status.
10819 (regcache_invalidate): Change it to method invalidate.
10820 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
10821 (regcache_raw_update): Change it to method raw_update.
10822 (regcache_raw_read): Likewise.
10823 (regcache_raw_read_signed): Likewise.
10824 (regcache_raw_read_unsigned): Likewise.
10825 (regcache_raw_write_signed): Likewise.
10826 (regcache_raw_write_unsigned): Likewise.
10827 (regcache_cooked_read): Likewise.
10828 (regcache_cooked_read_value): Likewise.
10829 (regcache_cooked_read_signed): Likewise.
10830 (regcache_cooked_read_unsigned): Likewise.
10831 (regcache_cooked_write_signed): Likewise.
10832 (regcache_cooked_write_unsigned): Likewise.
10833 (regcache_raw_set_cached_value): Likewise.
10834 (regcache_raw_write): Likewise.
10835 (regcache_cooked_write): Likewise.
10836 (regcache_xfer_part): Likewise.
10837 (regcache_raw_read_part): Likewise.
10838 (regcache_raw_write_part): Likewise.
10839 (regcache_cooked_read_part): Likewise.
10840 (regcache_cooked_write_part): Likewise.
10841 (regcache_raw_supply): Likewise.
10842 (regcache_raw_collect): Likewise.
10843 (regcache_transfer_regset): Likewise.
10844 (regcache_supply_regset): Likewise.
10845 (regcache_collect_regset): Likewise.
10846 (regcache_debug_print_register): Likewise.
10847 (enum regcache_dump_what): Move it to regcache.h.
10848 (regcache_dump): Change it to method dump.
10849 * regcache.h (enum regcache_dump_what): New.
10850 (class regcache): New.
10851 * target.c (target_fetch_registers): Call method
10852 debug_print_register.
10853 (target_store_registers): Likewise.
10854
10855 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10856
10857 * windows-nat.c (struct lm_info_windows): Initialize field.
10858 (windows_make_so): Allocate lm_info_windows with new.
10859 (windows_free_so): Free lm_info_windows with delete.
10860
10861 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10862
10863 * solib-darwin.c (struct lm_info_darwin): Initialize field.
10864 (darwin_current_sos): Allocate lm_info_darwin with new, remove
10865 cleanup.
10866 (darwin_free_so): Free lm_info_darwin with delete.
10867
10868 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10869
10870 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
10871 <l_addr_p>: Change type to bool.
10872 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
10873 (svr4_free_so): Free lm_info_svr4 with delete.
10874 (svr4_copy_library_list): Replace memcpy with call to copy
10875 constructor.
10876 (library_list_start_library, svr4_default_sos): Allocate
10877 lm_info_svr4 with new.
10878
10879 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10880
10881 * solib-target.c (struct lm_info_target): Add destructor,
10882 initialize fields.
10883 <name>: Change type to std::string.
10884 (library_list_start_library): Allocate lm_info_target with new.
10885 (solib_target_free_library_list): Free lm_info_target with
10886 delete.
10887 (solib_target_current_sos): Adapt to std::string.
10888 (solib_target_free_so): Free lm_info_target with delete.
10889
10890 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10891
10892 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
10893 fields.
10894 (frv_current_sos): Allocate lm_info_frv with new.
10895 (frv_relocate_main_executable): Free lm_info_frv with delete,
10896 allocate with new.
10897 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
10898
10899 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10900
10901 * solib-frv.c (struct lm_info_frv): Fix indentation.
10902
10903 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10904
10905 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
10906 map field.
10907 (dsbt_current_sos): Allocate lm_info_dsbt with new.
10908 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
10909 and allocate with new.
10910 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
10911
10912 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10913
10914 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
10915 <filename, member_name>: Change type to std::string.
10916 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
10917 (library_list_start_library): Allocate lm_info_aix with new.
10918 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
10919 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
10920 with copy constructor.
10921
10922 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10923
10924 * solist.h (struct lm_info): Remove.
10925 (struct lm_info_base): New class.
10926 (struct so_list) <lm_info>: Change type to lm_info_base *.
10927 * nto-tdep.c (struct lm_info): Remove.
10928 (lm_addr): Adjust.
10929 * solib-aix.c (struct lm_info): Rename to ...
10930 (struct lm_info_aix): ... this. Extend lm_info_base.
10931 (lm_info_p): Rename to ...
10932 (lm_info_aix_p): ... this, and adjust.
10933 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
10934 solib_aix_parse_libraries, library_list_start_library,
10935 solib_aix_free_library_list, solib_aix_parse_libraries,
10936 solib_aix_get_library_list,
10937 solib_aix_relocate_section_addresses, solib_aix_free_so,
10938 solib_aix_get_section_offsets,
10939 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
10940 Adjust.
10941 (struct solib_aix_inferior_data) <library_list>: Adjust.
10942 * solib-darwin.c (struct lm_info): Rename to ...
10943 (struct lm_info_darwin): ... this. Extend lm_info_base.
10944 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
10945 * solib-dsbt.c (struct lm_info): Rename to ...
10946 (struct lm_info_dsbt): ... this. Extend lm_info_base.
10947 (struct dsbt_info) <main_executable_lm_info): Adjust.
10948 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
10949 dsbt_relocate_section_addresses): Adjust.
10950 * solib-frv.c (struct lm_info): Rename to ...
10951 (struct lm_info_frv): ... this. Extend lm_info_base.
10952 (main_executable_lm_info): Adjust.
10953 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
10954 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
10955 find_canonical_descriptor_in_load_object,
10956 frv_fdpic_find_canonical_descriptor): Adjust.
10957 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
10958 to lm_info_svr4.
10959 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
10960 svr4_clear_so, svr4_copy_library_list,
10961 library_list_start_library, svr4_default_sos, svr4_read_so_list,
10962 svr4_current_sos, svr4_fetch_objfile_link_map,
10963 solist_update_incremental): Adjust.
10964 * solib-svr4.h (struct lm_info_svr4): Move here from
10965 solib-svr4.c.
10966 * solib-target.c (struct lm_info): Rename to ...
10967 (struct lm_info_target): ... this. Extend lm_info_base.
10968 (lm_info_p): Rename to ...
10969 (lm_info_target_p): ... this.
10970 (solib_target_parse_libraries, library_list_start_segment,
10971 library_list_start_section, library_list_start_library,
10972 library_list_end_library, solib_target_free_library_list,
10973 solib_target_current_sos, solib_target_free_so,
10974 solib_target_relocate_section_addresses): Adjust.
10975 * windows-nat.c (struct lm_info): Rename to ...
10976 (struct lm_info_windows): ... this. Extend lm_info_base.
10977 (windows_make_so, handle_load_dll, handle_unload_dll,
10978 windows_xfer_shared_libraries): Adjust.
10979
10980 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10981
10982 * solib-darwin.c (struct darwin_so_list): Remove.
10983 (darwin_current_sos): Allocate an so_list object instead of a
10984 darwin_so_list, separately allocate an lm_info object.
10985 (darwin_free_so): Free lm_info.
10986
10987 2017-04-28 John Baldwin <jhb@FreeBSD.org>
10988
10989 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
10990 with fprintf_filtered.
10991
10992 2017-04-28 Yao Qi <yao.qi@linaro.org>
10993
10994 * regcache.c (regcache::regcache): New function.
10995 (regcache::~regcache): New function.
10996 (regcache_xmalloc_1): Remove.
10997 (regcache_xmalloc): Call new regcache.
10998 (regcache_xfree): Call delete regcache.
10999 (get_thread_arch_aspace_regcache): Call new regcache.
11000
11001 2017-04-28 Yao Qi <yao.qi@linaro.org>
11002
11003 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
11004 lwp instead of ptid_get_lwp.
11005
11006 2017-04-28 Yao Qi <yao.qi@linaro.org>
11007
11008 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
11009 lwp_info instead of getting from inferior_ptid.
11010
11011 2017-04-27 Keith Seitz <keiths@redhat.com>
11012
11013 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
11014 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
11015 (CV_CONVERSION_BADNESS): Define.
11016 (rank_one_type): Remove overly restrictive rvalue reference
11017 rank checks.
11018 Add cv-qualifier checks and subranks for type equality.
11019 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
11020 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
11021 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
11022
11023 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
11024
11025 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
11026 count when creating the object.
11027
11028 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
11029 Ulrich Weigand <uweigand@de.ibm.com>
11030
11031 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
11032 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
11033 is used in AIX.
11034 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
11035 (process_xcoff_symbol): Likewise.
11036 (scan_xcoff_symtab): Likewise.
11037
11038 2017-04-26 Alan Hayward <alan.hayward@arm.com>
11039
11040 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
11041 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
11042 (ia64_access_reg): Use get_frame_register_unsigned.
11043 (ia64_access_rse_reg): Likewise.
11044 (ia64_libunwind_frame_prev_register): Likewise.
11045
11046 2017-04-26 Jiong Wang <jiong.wang@arm.com>
11047
11048 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
11049 * gdbarch.c: Regenerated.
11050 * gdbarch.h: Regenerated.
11051 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
11052 visibility external.
11053 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
11054 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
11055 (enum cfa_how_kind): Move to ...
11056 (struct dwarf2_frame_state_reg_info): Likewise.
11057 (struct dwarf2_frame_state): Likewise.
11058 * dwarf2-frame.h: ... here.
11059 (dwarf2_frame_state_alloc_regs): New declaration.
11060 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
11061 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
11062
11063 2017-04-26 Alan Hayward <alan.hayward@arm.com>
11064
11065 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
11066 regcache_raw_read_unsigned.
11067 (xtensa_pseudo_register_write): Likewise.
11068
11069 2017-04-26 Alan Hayward <alan.hayward@arm.com>
11070
11071 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
11072 (nds32_pseudo_register_write): Likewise.
11073
11074 2017-04-25 Yao Qi <yao.qi@linaro.org>
11075
11076 * regcache.c (struct regcache) <readonly_p>: Change its type
11077 to bool.
11078 (regcache_xmalloc_1): Update parameter type and callers update.
11079
11080 2017-04-25 Yao Qi <yao.qi@linaro.org>
11081
11082 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
11083 set_gdbarch_wchar_bit.
11084 * arm-tdep.c (arm_gdbarch_init): Likewise.
11085
11086 2017-04-25 Pedro Alves <palves@redhat.com>
11087
11088 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
11089 (BothAreRelocatable, memcopy, memmove): Don't define.
11090 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
11091 macros.
11092
11093 2017-04-25 Pedro Alves <palves@redhat.com>
11094
11095 * common/common-defs.h: Include "common/poison.h".
11096 * common/function-view.h: (Not, Or, Requires): Move to traits.h
11097 and adjust.
11098 * common/poison.h: New file.
11099 * common/traits.h: Include <type_traits>.
11100 (Not, Or, Requires): New, moved from common/function-view.h.
11101
11102 2017-04-25 Pedro Alves <palves@redhat.com>
11103
11104 * breakpoint.h (struct breakpoint): In-class initialize all
11105 fields. Make boolean fields "bool".
11106 * breakpoint.c (init_raw_breakpoint_without_location): Remove
11107 memset call and initializations no longer necessary.
11108
11109 2017-04-25 Pedro Alves <palves@redhat.com>
11110
11111 * btrace.c (pt_btrace_insn_flags): Change parameter type to
11112 reference.
11113 (pt_btrace_insn): New function.
11114 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
11115
11116 2017-04-25 Pedro Alves <palves@redhat.com>
11117
11118 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
11119 "base" field and inherit from "bp_location" instead. Add
11120 non-default ctor.
11121 (allocate_location_exception): Use new non-default ctor.
11122 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
11123 (init_bp_location): Convert to ...
11124 (bp_location::bp_location): ... this new ctor, and remove memset
11125 call.
11126 (base_breakpoint_allocate_location): Use the new non-default ctor.
11127 * breakpoint.h (bp_location): Now a class. Declare default and
11128 non-default ctors. In-class initialize all members.
11129 (init_bp_location): Remove declaration.
11130
11131 2017-04-25 Pedro Alves <palves@redhat.com>
11132
11133 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
11134 assignment operator.
11135
11136 2017-04-24 Yao Qi <yao.qi@linaro.org>
11137
11138 * doublest.c (convert_doublest_to_floatformat): Call
11139 floatformat_totalsize_bytes.
11140
11141 2017-04-22 Tom Tromey <tom@tromey.com>
11142
11143 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
11144 ui_out_emit_list.
11145 * stack.c (print_frame): Use ui_out_emit_list.
11146 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
11147 ui_out_emit_list.
11148 * mi/mi-main.c (print_one_inferior)
11149 (mi_cmd_data_list_register_names)
11150 (mi_cmd_data_list_register_values, mi_cmd_list_features)
11151 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
11152 ui_out_emit_list.
11153 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
11154 (mi_output_solib_attribs): Use ui_out_emit_list,
11155 ui_out_emit_tuple.
11156 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
11157 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
11158 (mi_cmd_stack_list_args, list_args_or_locals): Use
11159 ui_out_emit_list.
11160 * disasm.c (do_assembly_only): Use ui_out_emit_list.
11161 * breakpoint.c (print_solib_event, output_thread_groups): Use
11162 ui_out_emit_list.
11163
11164 2017-04-22 Tom Tromey <tom@tromey.com>
11165
11166 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
11167 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
11168 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
11169
11170 2017-04-22 Tom Tromey <tom@tromey.com>
11171
11172 * tracepoint.c (tvariables_info_1)
11173 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
11174
11175 2017-04-22 Tom Tromey <tom@tromey.com>
11176
11177 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
11178 annotate_arg_emitter.
11179 * breakpoint.c (print_mention_watchpoint)
11180 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
11181 * annotate.h (struct annotate_arg_emitter): New.
11182
11183 2017-04-22 Tom Tromey <tom@tromey.com>
11184
11185 * record-btrace.c (record_btrace_insn_history)
11186 (record_btrace_insn_history_range, record_btrace_call_history)
11187 (record_btrace_call_history_range): Use ui_out_emit_tuple.
11188 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
11189 ui_out_emit_tuple.
11190 * stack.c (print_frame_info): Use ui_out_emit_tuple.
11191 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
11192 * skip.c (skip_info): Use ui_out_emit_tuple.
11193 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
11194 * progspace.c (print_program_space): Use ui_out_emit_tuple.
11195 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
11196 * osdata.c (info_osdata): Use ui_out_emit_tuple.
11197 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
11198 ui_out_emit_tuple.
11199 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
11200 (output_register, mi_cmd_data_read_memory)
11201 (mi_cmd_data_read_memory_bytes, mi_load_progress)
11202 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
11203 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
11204 Use ui_out_emit_tuple.
11205 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
11206 ui_out_emit_tuple.
11207 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
11208 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
11209 * linux-thread-db.c (info_auto_load_libthread_db): Use
11210 ui_out_emit_tuple.
11211 * inferior.c (print_inferior): Use ui_out_emit_tuple.
11212 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
11213 * disasm.c (do_mixed_source_and_assembly_deprecated)
11214 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
11215 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
11216 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
11217 * breakpoint.c (print_one_breakpoint_location)
11218 (print_one_breakpoint): Use ui_out_emit_tuple.
11219 * auto-load.c (print_script, info_auto_load_cmd): Use
11220 ui_out_emit_tuple.
11221 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
11222
11223 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
11224
11225 * thread.c (print_thread_info_1): Remove dead code.
11226
11227 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11228
11229 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
11230 GDB_SELF_TEST.
11231 * arm-tdep.c (selftests::arm_record_test): Likewise.
11232
11233 2017-04-21 Yao Qi <yao.qi@linaro.org>
11234
11235 * regcache.c (regcache_restore): Remove argument 2. Replace
11236 argument 3 with regcache. Get register status from
11237 src->register_status and get register contents from
11238 register_buffer (src, regnum).
11239 (regcache_cpy): Update.
11240
11241 2017-04-19 Pedro Alves <palves@redhat.com>
11242
11243 * gdbthread.h (thread): Add missing closing parenthesis in
11244 comment.
11245
11246 2017-04-19 Pedro Alves <palves@redhat.com>
11247
11248 * common/refcounted-object.h: New file.
11249 * gdbthread.h: Include "common/refcounted-object.h".
11250 (thread_info): Inherit from refcounted_object and add comments.
11251 (thread_info::incref, thread_info::decref)
11252 (thread_info::m_refcount): Delete.
11253 (thread_info::deletable): Use the refcounted_object::refcount()
11254 method.
11255 * inferior.c (current_inferior_): Add comment.
11256 (set_current_inferior): Increment/decrement refcounts.
11257 (prune_inferiors, remove_inferior_command): Skip inferiors marked
11258 not-deletable instead of comparing with the current inferior.
11259 (initialize_inferiors): Increment the initial inferior's refcount.
11260 * inferior.h (struct inferior): Forward declare.
11261 Include "common/refcounted-object.h".
11262 (current_inferior, set_current_inferior): Move declaration to
11263 before struct inferior's definition, and fix comment.
11264 (inferior): Inherit from refcounted_object. Add comments.
11265 * thread.c (switch_to_thread_no_regs): Reference the thread's
11266 inferior pointer directly instead of doing a ptid lookup.
11267 (switch_to_no_thread): New function.
11268 (switch_to_thread(thread_info *)): New function, factored out
11269 from ...
11270 (switch_to_thread(ptid_t)): ... this.
11271 (restore_current_thread): Delete.
11272 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
11273 fields, and add 'inf' field.
11274 (do_restore_current_thread_cleanup): Check whether old->inf is
11275 alive instead of looking up an inferior by ptid. Use
11276 switch_to_thread and switch_to_no_thread.
11277 (restore_current_thread_cleanup_dtor): Use old->inf directly
11278 instead of lookup up an inferior by id. Decref the inferior.
11279 Don't restore 'removable'.
11280 (make_cleanup_restore_current_thread): Same the inferior pointer
11281 in old, instead of the inferior number. Incref the inferior.
11282 Don't save/clear 'removable'.
11283
11284 2017-04-19 Pedro Alves <palves@redhat.com>
11285
11286 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11287 unittests/scoped_restore-selftests.c.
11288 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
11289 * common/scoped_restore.h (scoped_restore_base): Make "class".
11290 (scoped_restore_base::release): New public method.
11291 (scoped_restore_base::scoped_restore_base): New protected ctor.
11292 (scoped_restore_base::m_saved_var): New protected field.
11293 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
11294 scoped_restore_base base class instead of m_saved_var directly.
11295 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
11296 (scoped_restore_tmpl::scoped_restore_tmpl(const
11297 scoped_restore_tmpl<T>&)): Likewise.
11298 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
11299 method.
11300 (scoped_restore_tmpl::saved_var): New method.
11301 (scoped_restore_tmpl::m_saved_var): Delete.
11302 * inferior.h (inferior::detaching): Now a bool.
11303 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
11304 cleanup.
11305 * unittests/scoped_restore-selftests.c: New file.
11306
11307 2017-04-19 Pedro Alves <palves@redhat.com>
11308
11309 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
11310 Re-sort in alphabetic order.
11311
11312 2017-04-18 Pedro Alves <palves@redhat.com>
11313
11314 * xml-support.c (obstack_xml_printf): Delete.
11315 * xml-support.h (obstack_xml_printf): Delete.
11316
11317 2017-04-18 Pedro Alves <palves@redhat.com>
11318
11319 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
11320 vdebug, verror, body_text, start_element, end_element, name,
11321 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
11322 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
11323 is_xinclude>: Make private and add m_ prefix.
11324 (gdb_xml_parser::body_text): New method, based on ...
11325 (gdb_xml_body_text): ... this. Adjust.
11326 (gdb_xml_parser::vdebug): New method, based on ...
11327 (gdb_xml_debug): ... this. Adjust.
11328 (gdb_xml_parser::verror): New method, based on ...
11329 (gdb_xml_error): ... this. Adjust.
11330 (gdb_xml_parser::start_element): New method, based on ...
11331 (gdb_xml_start_element): ... this. Adjust.
11332 (gdb_xml_start_element_wrapper): Defer to
11333 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
11334 (gdb_xml_parser::end_element): New method, based on ...
11335 (gdb_xml_end_element_wrapper): ... this. Adjust.
11336 (gdb_xml_parser::~gdb_xml_parser): Adjust.
11337 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
11338 (gdb_xml_parser::use_dtd): New method, based on ...
11339 (gdb_xml_use_dtd): ... this. Adjust.
11340 (gdb_xml_parser::parse): New method, based on ...
11341 (gdb_xml_parse): ... this. Adjust.
11342 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
11343 (xinclude_start_include): Adjust to call the parser's name method.
11344 (xml_xinclude_default, xml_xinclude_start_doctype)
11345 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
11346 method.
11347 (xml_process_xincludes): Adjust to call parser methods.
11348 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
11349 declarations.
11350
11351 2017-04-18 Pedro Alves <palves@redhat.com>
11352
11353 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
11354 gdb::optional<std::string>.
11355 * xml-support.c: Include <string>.
11356 (scope_level::scope_level(scope_level &&))
11357 (scope_level::~scope_level): Delete.
11358 (scope_level::body): Now a std::string.
11359 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
11360 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
11361 parameter.
11362 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
11363 (xinclude_parsing_data::output): Now a std::string reference.
11364 (xinclude_start_include): Adjust.
11365 (xml_xinclude_default): Adjust.
11366 (xml_process_xincludes): Add 'output' parameter, and return bool.
11367 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
11368 and return bool.
11369 * xml-tdesc.c: Include <unordered_map> and <string>.
11370 (tdesc_xml_cache): Delete.
11371 (tdesc_xml_cache_s): Delete.
11372 (xml_cache): Now an std::unordered_map.
11373 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
11374 (target_fetch_description_xml): Change return type to
11375 gdb::optional<std::string>, and adjust.
11376 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
11377 (target_fetch_description_xml): Change return type to
11378 gdb::optional<std::string>.
11379
11380 2017-04-18 Pedro Alves <palves@redhat.com>
11381
11382 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11383 unittests/optional-selftests.c.
11384 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
11385 * unittests/optional-selftests.c: New file.
11386 * unittests/optional/assignment/1.cc: New file.
11387 * unittests/optional/assignment/2.cc: New file.
11388 * unittests/optional/assignment/3.cc: New file.
11389 * unittests/optional/assignment/4.cc: New file.
11390 * unittests/optional/assignment/5.cc: New file.
11391 * unittests/optional/assignment/6.cc: New file.
11392 * unittests/optional/assignment/7.cc: New file.
11393 * unittests/optional/cons/copy.cc: New file.
11394 * unittests/optional/cons/default.cc: New file.
11395 * unittests/optional/cons/move.cc: New file.
11396 * unittests/optional/cons/value.cc: New file.
11397 * unittests/optional/in_place.cc: New file.
11398 * unittests/optional/observers/1.cc: New file.
11399 * unittests/optional/observers/2.cc: New file.
11400
11401 2017-04-18 Pedro Alves <palves@redhat.com>
11402
11403 * common/gdb_optional.h: Include common/traits.h.
11404 (in_place_t): New type.
11405 (in_place): New constexpr variable.
11406 (optional::optional): Remove member initialization of
11407 m_instantiated.
11408 (optional::optional(in_place_t...)): New constructor.
11409 (optional::~optional): Use reset.
11410 (optional::optional(const optional&)): New.
11411 (optional::optional(const optional&&)): New.
11412 (optional::optional(T &)): New.
11413 (optional::optional(T &&)): New.
11414 (operator::operator=(const optional &)): New.
11415 (operator::operator=(optional &&)): New.
11416 (operator::operator= (const T &))
11417 (operator::operator= (T &&))
11418 (operator::emplace (Args &&... args)): Return a T&. Use reset.
11419 (operator::reset): New.
11420 (operator::m_instantiated):: Add in-class initializer.
11421 * common/traits.h: Include <type_traits>.
11422 (struct And): New types.
11423
11424 2017-04-18 Pedro Alves <palves@redhat.com>
11425
11426 * xml-support.c: Include <vector>.
11427 (scope_level::scope_level(const gdb_xml_element *))
11428 (scope_level::scope_level(scope_level&&)): New.
11429 (scope_level::~scope_level): New.
11430 (scope_level_s): Delete.
11431 (gdb_xml_parser::scopes): Now a std::vector.
11432 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
11433 Use std::vector.
11434 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
11435 scope cleanup code.
11436 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
11437 of the scopes member. Use std::vector::emplace_back.
11438
11439 2017-04-18 Pedro Alves <palves@redhat.com>
11440
11441 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
11442 a bool.
11443 (gdb_xml_end_element): Change type of first parameter.
11444 (gdb_xml_cleanup): Rename to ...
11445 (gdb_xml_parser::~gdb_xml_parser): ... this.
11446 (gdb_xml_create_parser_and_cleanup): Delete with ...
11447 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
11448 to this new ctor.
11449 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
11450 using gdb_xml_create_parser_and_cleanup.
11451 (xinclude_parsing_data): Add ctor/dtor.
11452 (xml_xinclude_cleanup): Delete.
11453 (xml_process_xincludes): Create a local xinclude_parsing_data
11454 instead of heap-allocating one. Create a local gdb_xml_parser
11455 instead of heap-allocating one with
11456 gdb_xml_create_parser_and_cleanup.
11457
11458 2017-04-18 John Baldwin <jhb@FreeBSD.org>
11459
11460 PR threads/20743
11461 * fbsd-nat.c (resume_one_thread_cb): Remove.
11462 (resume_all_threads_cb): Remove.
11463 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
11464 iterate_over_threads.
11465
11466 2017-04-17 Joel Brobecker <brobecker@adacore.com>
11467
11468 * NEWS: Create a new section for the next release branch.
11469 Rename the section of the current branch, now that it has
11470 been cut.
11471
11472 2017-04-17 Joel Brobecker <brobecker@adacore.com>
11473
11474 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
11475 * version.in: Bump version to 8.0.50.DATE-git.
11476
11477 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
11478
11479 PR gdb/21385
11480 * windows-nat.c (windows_create_inferior): Declare 'allargs'
11481 independently of the host, and fix build breakage on Cygwin.
11482
11483 2017-04-13 Pedro Alves <palves@redhat.com>
11484
11485 * inferior.c (free_inferior): Convert to ...
11486 (inferior::~inferior): ... this dtor.
11487 (inferior::inferior): New ctor, factored out from ...
11488 (add_inferior_silent): ... here. Allocate the inferior with a new
11489 expression.
11490 (delete_inferior): Call delete instead of free_inferior.
11491 * inferior.h (gdb_environ, continuation): Forward declare.
11492 (inferior): Now a class. Add in-class initialization to all
11493 members. Make boolean fields bool, except 'detaching'.
11494 (inferior::inferior): New explicit ctor.
11495 (inferior::~inferior): New.
11496
11497 2017-04-13 Pedro Alves <palves@redhat.com>
11498
11499 * inferior.c (init_inferior_list): Delete.
11500 * inferior.h (init_inferior_list): Delete.
11501
11502 2017-04-13 Pedro Alves <palves@redhat.com>
11503
11504 PR threads/13217
11505 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
11506 (top level): Call it twice, with different thread sets.
11507
11508 2017-04-13 Pedro Alves <palves@redhat.com>
11509
11510 * thread.c: Include <algorithm>.
11511 (thread_array_cleanup): Delete.
11512 (scoped_inc_dec_ref): New class.
11513 (live_threads_count): New function.
11514 (set_thread_refcount): Delete.
11515 (tp_array_compar_ascending): Now a bool.
11516 (tp_array_compar): Convert to a std::sort comparison function.
11517 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
11518 and live_threads_count.
11519
11520 2017-04-13 Pedro Alves <palves@redhat.com>
11521
11522 * infrun.c (follow_fork_inferior): Also switch the current
11523 inferior.
11524
11525 2017-04-13 Pedro Alves <palves@redhat.com>
11526
11527 * breakpoint.c (watch_command_1): Save watchpoint-frame info
11528 before calling create_internal_breakpoint.
11529
11530 2017-04-13 Pedro Alves <palves@redhat.com>
11531
11532 * fork-child.c (execv_argv): New class.
11533 (breakup_args): Refactored as ...
11534 (execv_argv::init_for_no_shell): .. this method of execv_argv.
11535 Copy arguments to storage and replace separators with NULL
11536 terminators in place.
11537 (escape_bang_in_quoted_argument): Adjust to return bool.
11538 (execv_argv::execv_argv): New ctor.
11539 (execv_argv::init_for_shell): New method, factored out from
11540 fork_inferior. Don't strdup strings into the vector.
11541 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
11542 Remove free_vector_argv call.
11543
11544 2017-04-13 Yao Qi <yao.qi@linaro.org>
11545
11546 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
11547 tdep->rx_psw_type.
11548
11549 2017-04-13 Yao Qi <yao.qi@linaro.org>
11550
11551 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
11552 * rx-tdep.c (rx_gdbarch_init): Likewise.
11553
11554 2017-04-13 Pedro Alves <palves@redhat.com>
11555
11556 * breakpoint.h (struct breakpoint): Reindent.
11557
11558 2017-04-13 Pedro Alves <palves@redhat.com>
11559
11560 * breakpoint.c (bp_location): Rename to ...
11561 (bp_locations): ... this. All references updated.
11562 (bp_location_count): Rename to ...
11563 (bp_locations_count): ... this. All references updated.
11564 (bp_location_placed_address_before_address_max): Rename to ...
11565 (bp_locations_placed_address_before_address_max): ... this. All
11566 references updated.
11567 (bp_location_shadow_len_after_address_max): Rename to ...
11568 (bp_locations_shadow_len_after_address_max): ... this. All
11569 references updated.
11570 (bp_location_compare_addrs): Rename to ...
11571 (bp_locations_compare_addrs): ... this. All references updated.
11572 (bp_location_compare):Rename to ...
11573 (bp_locations_compare): ... this. All references updated.
11574 (bp_location_target_extensions_update): Rename to ...
11575 (bp_locations_target_extensions_update): ... this. All references
11576 updated.
11577
11578 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11579
11580 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
11581 * common/common.m4: Check headers 'termios.h', 'termio.h' and
11582 'sgtty.h'.
11583 * common/gdb_termios.h: New file, with parts of "terminal.h".
11584 * inflow.c: Include "gdb_termios.h".
11585 * ser-unix.c: Include "gdb_termios.h".
11586 * terminal.h: Move terminal-related defines to
11587 "common/gdb_termios.h".
11588
11589 2017-04-12 Tom Tromey <tom@tromey.com>
11590
11591 * probe.c (parse_probes): Update.
11592 * location.h (delete_event_location): Don't declare.
11593 (event_location_deleter::operator()): Update.
11594 * location.c (event_location_deleter::operator()): Rename from
11595 delete_event_location.
11596 * linespec.h (linespec_result) <location>: Change type to
11597 event_location_up.
11598 * linespec.c (canonicalize_linespec, event_location_to_sals)
11599 (decode_objc): Update.
11600 (linespec_result): Don't call delete_event_location.
11601 * breakpoint.c (create_breakpoints_sal)
11602 (bkpt_probe_create_sals_from_location)
11603 (strace_marker_create_sals_from_location): Update.
11604
11605 2017-04-12 Tom Tromey <tom@tromey.com>
11606
11607 * linespec.h (struct linespec_result): Add constructor and
11608 destructor.
11609 (init_linespec_result, destroy_linespec_result)
11610 (make_cleanup_destroy_linespec_result): Don't declare.
11611 * linespec.c (init_linespec_result): Remove.
11612 (linespec_result::~linespec_result): Rename from
11613 destroy_linespec_result. Update.
11614 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
11615 Remove.
11616 * breakpoint.c (create_breakpoint, break_range_command)
11617 (decode_location_default): Update.
11618 * ax-gdb.c (agent_command_1): Update.
11619
11620 2017-04-12 Tom Tromey <tom@tromey.com>
11621
11622 * remote.c (remote_download_tracepoint): Update.
11623 * python/py-breakpoint.c (bppy_get_location): Update.
11624 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
11625 (gdbscm_breakpoint_location): Update.
11626 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
11627 * breakpoint.h (struct breakpoint) <location, location_range_end>:
11628 Change type to event_location_up.
11629 * breakpoint.c (create_overlay_event_breakpoint)
11630 (create_longjmp_master_breakpoint)
11631 (create_std_terminate_master_breakpoint)
11632 (create_exception_master_breakpoint)
11633 (breakpoint_event_location_empty_p, print_breakpoint_location)
11634 (print_one_breakpoint_location, create_thread_event_breakpoint)
11635 (init_breakpoint_sal, create_breakpoint)
11636 (print_recreate_ranged_breakpoint, break_range_command)
11637 (init_ada_exception_breakpoint, say_where): Update.
11638 (base_breakpoint_dtor): Don't call delete_event_location.
11639 (bkpt_print_recreate, tracepoint_print_recreate)
11640 (dprintf_print_recreate, update_static_tracepoint)
11641 (breakpoint_re_set_default): Update.
11642
11643 2017-04-12 Tom Tromey <tom@tromey.com>
11644
11645 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
11646 type of "to_do". Update.
11647 (compute_stack_depth): Use std::vector.
11648
11649 2017-04-12 Tom Tromey <tom@tromey.com>
11650
11651 * printcmd.c (find_instruction_backward): Use std::vector.
11652
11653 2017-04-12 Tom Tromey <tom@tromey.com>
11654
11655 * symfile.c (objfilep): Remove typedef.
11656 (reread_symbols): Use a std::vector.
11657
11658 2017-04-12 Tom Tromey <tom@tromey.com>
11659
11660 * mi/mi-main.c (exec_direction_forward): Remove.
11661 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
11662 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
11663 scoped_restore.
11664 * guile/guile.c (guile_repl_command, guile_command)
11665 (gdbscm_execute_gdb_command): Use scoped_restore.
11666 * go-exp.y (go_parse): Use scoped_restore.
11667 * d-exp.y (d_parse): Use scoped_restore.
11668 * cli/cli-decode.c (cmd_func): Use scoped_restore.
11669 * c-exp.y (c_parse): Use scoped_restore.
11670
11671 2017-04-12 Tom Tromey <tom@tromey.com>
11672
11673 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
11674 (mi_parse): Update return type.
11675 (mi_parse_free): Remove.
11676 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
11677 (mi_parse::~mi_parse): Rename from mi_parse_free.
11678 (mi_parse_cleanup): Remove.
11679 (mi_parse): Return a unique_ptr. Use new.
11680 * mi/mi-main.c (mi_execute_command): Update.
11681
11682 2017-04-12 Tom Tromey <tom@tromey.com>
11683
11684 * location.c (explicit_location_lex_one): Return a
11685 unique_xmalloc_ptr.
11686 (string_to_explicit_location): Update. Remove cleanups.
11687
11688 2017-04-12 Tom Tromey <tom@tromey.com>
11689
11690 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
11691 (compare_value_and_voffset): Change type. Update.
11692 (compute_vtable_size): Change type of "offset_vec".
11693 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
11694 (gnuv3_get_typeid): Remove extraneous declaration.
11695
11696 2017-04-12 Tom Tromey <tom@tromey.com>
11697
11698 * charset.h (wchar_iterator): Fix comment.
11699
11700 2017-04-12 Tom Tromey <tom@tromey.com>
11701
11702 * charset.c (iconv_wrapper): New class.
11703 (cleanup_iconv): Remove.
11704 (convert_between_encodings): Use it.
11705
11706 2017-04-12 Tom Tromey <tom@tromey.com>
11707
11708 * symfile.h (increment_reading_symtab): Update type.
11709 * symfile.c (decrement_reading_symtab): Remove.
11710 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
11711 * psymtab.c (psymtab_to_symtab): Update.
11712 * dwarf2read.c (dw2_instantiate_symtab): Update.
11713
11714 2017-04-12 Tom Tromey <tom@tromey.com>
11715
11716 * jit.c (struct jit_reader): Declare separately. Add constructor
11717 and destructor. Change type of "handle".
11718 (loaded_jit_reader): Define separately.
11719 (jit_reader_load): Update. New "new".
11720 (jit_reader_unload_command): Use "delete".
11721 * gdb-dlfcn.h (struct dlclose_deleter): New.
11722 (gdb_dlhandle_up): New typedef.
11723 (gdb_dlopen, gdb_dlsym): Update types.
11724 (gdb_dlclose): Remove.
11725 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
11726 (gdb_dlsym): Change type of "handle".
11727 (make_cleanup_dlclose): Remove.
11728 (dlclose_deleter::operator()): Rename from gdb_dlclose.
11729 * compile/compile-c-support.c (load_libcc): Update.
11730
11731 2017-04-12 Tom Tromey <tom@tromey.com>
11732
11733 * symtab.h (find_pcs_for_symtab_line): Change return type.
11734 * symtab.c (find_pcs_for_symtab_line): Change return type.
11735 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
11736 type of "vec". Update.
11737 (ltpy_get_pcs_for_line): Update.
11738 * linespec.c (decode_digits_ordinary): Update.
11739
11740 2017-04-12 Tom Tromey <tom@tromey.com>
11741
11742 * tracepoint.c (actions_command): Update.
11743 * python/python.c (python_command, python_interactive_command):
11744 Update.
11745 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
11746 * guile/guile.c (guile_command): Update.
11747 * defs.h (read_command_lines, read_command_lines_1): Return
11748 command_line_up.
11749 (command_lines_deleter): New struct.
11750 (command_line_up): New typedef.
11751 * compile/compile.c (compile_code_command)
11752 (compile_print_command): Update.
11753 * cli/cli-script.h (get_command_line, copy_command_lines): Return
11754 command_line_up.
11755 (make_cleanup_free_command_lines): Remove.
11756 * cli/cli-script.c (get_command_line, read_command_lines_1)
11757 (copy_command_lines): Return command_line_up.
11758 (while_command, if_command, read_command_lines, define_command)
11759 (document_command): Update.
11760 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
11761 Remove.
11762 * breakpoint.h (breakpoint_set_commands): Change type of
11763 "commands".
11764 * breakpoint.c (breakpoint_set_commands): Change type of
11765 "commands". Update.
11766 (do_map_commands_command, update_dprintf_command_list)
11767 (create_tracepoint_from_upload): Update.
11768
11769 2017-04-12 Tom Tromey <tom@tromey.com>
11770
11771 * tracepoint.c (scope_info): Update.
11772 * spu-tdep.c (spu_catch_start): Update.
11773 * python/python.c (gdbpy_decode_line): Update.
11774 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
11775 * python/py-breakpoint.c (bppy_init): Update.
11776 * probe.c (parse_probes): Update.
11777 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
11778 * location.h (event_location_deleter): New struct.
11779 (event_location_up): New typedef.
11780 (new_linespec_location, new_address_location, new_probe_location)
11781 (new_explicit_location, copy_event_location)
11782 (string_to_event_location, string_to_event_location_basic)
11783 (string_to_explicit_location): Update return type.
11784 (make_cleanup_delete_event_location): Remove.
11785 * location.c (new_linespec_location, new_address_location)
11786 (new_probe_location, new_explicit_location, copy_event_location):
11787 Return event_location_up.
11788 (delete_event_location_cleanup)
11789 (make_cleanup_delete_event_location): Remove.
11790 (string_to_explicit_location, string_to_event_location_basic)
11791 (string_to_event_location): Return event_location_up.
11792 * linespec.c (canonicalize_linespec, event_location_to_sals)
11793 (decode_line_with_current_source)
11794 (decode_line_with_last_displayed, decode_objc): Update.
11795 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
11796 * completer.c (location_completer): Update.
11797 * cli/cli-cmds.c (edit_command, list_command): Update.
11798 * breakpoint.c (create_overlay_event_breakpoint)
11799 (create_longjmp_master_breakpoint)
11800 (create_std_terminate_master_breakpoint)
11801 (create_exception_master_breakpoint)
11802 (create_thread_event_breakpoint): Update.
11803 (init_breakpoint_sal): Update. Remove some dead code.
11804 (create_breakpoint_sal): Change type of "location". Update.
11805 (create_breakpoints_sal, create_breakpoint, break_command_1)
11806 (dprintf_command, break_range_command, until_break_command)
11807 (init_ada_exception_breakpoint)
11808 (strace_marker_create_sals_from_location)
11809 (update_static_tracepoint, trace_command, ftrace_command)
11810 (strace_command, create_tracepoint_from_upload): Update.
11811 * break-catch-throw.c (re_set_exception_catchpoint): Update.
11812 * ax-gdb.c (agent_command_1): Update.
11813
11814 2017-04-12 Pedro Alves <palves@redhat.com>
11815
11816 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
11817 * configure.tgt: Handle i[34567]86-*-go32* and
11818 i[34567]86-*-msdosdjgpp*.
11819 * i386-tdep.c (i386_svr4_reg_to_regnum):
11820 Make extern.
11821 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
11822 i386-go32-tdep.c.
11823 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
11824 * i386-go32-tdep.c: New file.
11825 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
11826 declarations.
11827
11828 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
11829
11830 * aix-thread.c (pd_status2str): Change return type to const char *.
11831
11832 2017-04-12 Pedro Alves <palves@redhat.com>
11833
11834 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
11835 calls to set_gdbarch_gnu_triplet_regexp.
11836
11837 2017-04-12 Pedro Alves <palves@redhat.com>
11838
11839 PR gdb/21323
11840 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
11841 New enum value.
11842 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
11843 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
11844 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
11845 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
11846 * gdbarch.h, gdbarch.c: Regenerate.
11847 * aarch64-tdep.c (aarch64_gdbarch_init): Override
11848 gdbarch_wchar_bit and gdbarch_wchar_signed.
11849 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
11850 * arm-tdep.c (arm_gdbarch_init): Likewise.
11851 * avr-tdep.c (avr_gdbarch_init): Likewise.
11852 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
11853 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
11854 * i386-tdep.c (i386_go32_init_abi): Likewise.
11855 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11856 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11857 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
11858 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
11859 * sh-tdep.c (sh_gdbarch_init): Likewise.
11860 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
11861 * sparc64-tdep.c (sparc64_init_abi): Likewise.
11862 * windows-tdep.c (windows_init_abi): Likewise.
11863 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
11864
11865 2017-04-12 Pedro Alves <palves@redhat.com>
11866
11867 PR c++/21323
11868 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
11869 cplus_primitive_type_char32_t>: New enum values.
11870 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
11871 and cplus_primitive_type_char32_t.
11872 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
11873 32, use the archtecture's built-in type for char16_t and char32_t,
11874 respectively. Otherwise, fallback to init_integer_type as before,
11875 but make the type unsigned, and issue a complaint.
11876 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
11877
11878 2017-04-12 Alan Hayward <alan.hayward@arm.com>
11879
11880 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
11881 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
11882
11883 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11884
11885 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
11886 'const char *'.
11887
11888 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11889
11890 * common/common-utils.c (free_vector_argv): New function.
11891 * common/common-utils.h: Include <vector>.
11892 (free_vector_argv): New prototype.
11893 * darwin-nat.c (darwin_create_inferior): Rewrite function
11894 prototype in order to constify "exec_file" and accept a
11895 "std::string" for "allargs".
11896 * fork-child.c: Include <vector>.
11897 (breakup_args): Rewrite function, using C++.
11898 (fork_inferior): Rewrite function header, constify "exec_file_arg"
11899 and accept "std::string" for "allargs". Update the code to
11900 calculate "argv" based on "allargs". Update calls to "exec_fun"
11901 and "execvp".
11902 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
11903 order to constify "exec_file" and accept a "std::string" for
11904 "allargs".
11905 * go32-nat.c (go32_create_inferior): Likewise.
11906 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
11907 * infcmd.c (run_command_1): Constify "exec_file". Use
11908 "std::string" for inferior arguments.
11909 * inferior.h (fork_inferior): Update prototype.
11910 * linux-nat.c (linux_nat_create_inferior): Rewrite function
11911 prototype in order to constify "exec_file" and accept a
11912 "std::string" for "allargs".
11913 * nto-procfs.c (procfs_create_inferior): Likewise.
11914 * procfs.c (procfs_create_inferior): Likewise.
11915 * remote-sim.c (gdbsim_create_inferior): Likewise.
11916 * remote.c (extended_remote_run): Update code to accept
11917 "std::string" as argument.
11918 (extended_remote_create_inferior): Rewrite function prototype in
11919 order to constify "exec_file" and accept a "std::string" for
11920 "allargs".
11921 * rs6000-nat.c (super_create_inferior): Likewise.
11922 (rs6000_create_inferior): Likewise.
11923 * target.h (struct target_ops) <to_create_inferior>: Likewise.
11924 * windows-nat.c (windows_create_inferior): Likewise.
11925
11926 2017-04-11 Pedro Alves <palves@redhat.com>
11927
11928 * thread.c: Fix whitespace throughout.
11929
11930 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
11931
11932 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
11933
11934 2017-04-11 Alan Hayward <alan.hayward@arm.com>
11935
11936 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
11937
11938 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
11939
11940 PR gdb/21364
11941 * osdata.c (info_osdata): Check if 'type' is an empty string
11942 instead of NULL.
11943
11944 2017-04-10 Pedro Alves <palves@redhat.com>
11945
11946 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
11947 (ptid_to_global_thread_id, in_thread_list)
11948 (do_captured_list_thread_ids, set_resumed, set_running)
11949 (set_executing, set_stop_requested, finish_thread_state)
11950 (validate_registers_access, can_access_registers_ptid)
11951 (print_thread_info_1, switch_to_thread)
11952 (do_restore_current_thread_cleanup)
11953 (make_cleanup_restore_current_thread, thread_command)
11954 (thread_name_command): Use operator== instead of ptid_equal.
11955
11956 2017-04-10 Pedro Alves <palves@redhat.com>
11957
11958 * thread.c (struct current_thread_cleanup) <next>: Delete field.
11959 (current_thread_cleanup_chain): Delete.
11960 (restore_current_thread_cleanup_dtor)
11961 (make_cleanup_restore_current_thread): Remove references to
11962 current_thread_cleanup_chain.
11963
11964 2017-04-10 Alan Hayward <alan.hayward@arm.com>
11965
11966 * msp430-tdep.c (msp430_pseudo_register_read): Never return
11967 REG_UNKNOWN.
11968
11969 2017-04-10 Yao Qi <yao.qi@linaro.org>
11970
11971 PR gdb/19942
11972 * gdbthread.h (thread_info::deletable): New method.
11973 (thread_info::incref): New method.
11974 (thread_info::decref): New method.
11975 (thread_info::refcount): Move it to private.
11976 * infrun.c (save_stop_context): Call inc_refcount.
11977 (release_stop_context_cleanup): Likewise.
11978 * thread.c (set_thread_exited): New function.
11979 (init_thread_list): Delete "tp" only it is deletable, otherwise
11980 call set_thread_exited.
11981 (delete_thread_1): Call set_thread_exited.
11982 (current_thread_cleanup) <inferior_pid>: Remove.
11983 <thread>: New field.
11984 (restore_current_thread_ptid_changed): Removed.
11985 (do_restore_current_thread_cleanup): Adjust.
11986 (restore_current_thread_cleanup_dtor): Don't call
11987 find_thread_ptid.
11988 (set_thread_refcount): Use dec_refcount.
11989 (make_cleanup_restore_current_thread): Adjust.
11990 (thread_apply_all_command): Call inc_refcount.
11991 (_initialize_thread): Don't call
11992 observer_attach_thread_ptid_changed.
11993
11994 2017-04-10 Yao Qi <yao.qi@linaro.org>
11995
11996 * thread.c (delete_thread_1): Hoist code on marking thread as
11997 exited.
11998
11999 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12000
12001 * windows-nat.c (windows_detach): Initialize ptid with
12002 minus_one_ptid.
12003
12004 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
12005
12006 * unittests/ptid-selftests.c: Fix erroneous assert messages.
12007
12008 2017-04-07 Alan Hayward <alan.hayward@arm.com>
12009
12010 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
12011 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
12012 (bfin_pseudo_register_write): Likewise
12013
12014 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
12015
12016 * common/ptid.h (struct ptid): Change to...
12017 (class ptid_t): ... this.
12018 <ptid_t>: New constructors.
12019 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
12020 matches>: New methods.
12021 <make_null, make_minus_one>: New static methods.
12022 <pid>: Rename to...
12023 <m_pid>: ...this.
12024 <lwp>: Rename to...
12025 <m_lwp>: ...this.
12026 <tid>: Rename to...
12027 <m_tid>: ...this.
12028 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
12029 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
12030 as references, move comment to class ptid_t.
12031 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
12032 ptid_t static methods.
12033 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
12034 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
12035 Take ptid arguments as references, implement using ptid_t methods.
12036 * unittests/ptid-selftests.c: New file.
12037 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12038 unittests/ptid-selftests.c.
12039 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
12040
12041 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
12042
12043 * python/python.c (python_run_simple_file): Cast mode literal to
12044 non-const char pointer as expected by PyFile_FromString.
12045
12046 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
12047
12048 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
12049 minus_one_ptid and null_ptid.
12050
12051 2017-04-05 Pedro Alves <palves@redhat.com>
12052
12053 * warning.m4 (build_warnings): Remove -Wno-write-strings.
12054 * configure: Regenerate.
12055
12056 2017-04-05 Pedro Alves <palves@redhat.com>
12057
12058 * ada-exp.y (yyerror): Constify.
12059 * ada-lang.c (bound_name, get_selections)
12060 (ada_variant_discrim_type)
12061 (ada_variant_discrim_name, ada_value_struct_elt)
12062 (ada_lookup_struct_elt_type, is_unchecked_variant)
12063 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
12064 (catch_ada_exception_command_split)
12065 (catch_ada_assert_command_split, catch_assert_command)
12066 (ada_op_name): Constify.
12067 * ada-lang.h (ada_yyerror, get_selections)
12068 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
12069 * arc-tdep.c (arc_print_frame_cache): Constify.
12070 * arm-tdep.c (arm_skip_stub): Constify.
12071 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
12072 (gen_aggregate_elt_ref): Constify.
12073 * bcache.c (print_bcache_statistics): Constify.
12074 * bcache.h (print_bcache_statistics): Constify.
12075 * break-catch-throw.c (catch_exception_command_1):
12076 * breakpoint.c (struct ep_type_description::description):
12077 Constify.
12078 (add_solib_catchpoint): Constify.
12079 (catch_fork_command_1): Add cast.
12080 (add_catch_command): Constify.
12081 * breakpoint.h (add_catch_command, add_solib_catchpoint):
12082 Constify.
12083 * bsd-uthread.c (bsd_uthread_state): Constify.
12084 * buildsym.c (patch_subfile_names): Constify.
12085 * buildsym.h (next_symbol_text_func, patch_subfile_names):
12086 Constify.
12087 * c-exp.y (yyerror): Constify.
12088 (token::oper): Constify.
12089 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
12090 * c-varobj.c (cplus_describe_child): Constify.
12091 * charset.c (find_charset_names): Add cast.
12092 (find_charset_names): Constify array and add const_cast.
12093 * cli/cli-cmds.c (complete_command, cd_command): Constify.
12094 (edit_command): Constify.
12095 * cli/cli-decode.c (lookup_cmd): Constify.
12096 * cli/cli-dump.c (dump_memory_command, dump_value_command):
12097 Constify.
12098 (struct dump_context): Constify.
12099 (add_dump_command, restore_command): Constify.
12100 * cli/cli-script.c (get_command_line): Constify.
12101 * cli/cli-script.h (get_command_line): Constify.
12102 * cli/cli-utils.c (check_for_argument): Constify.
12103 * cli/cli-utils.h (check_for_argument): Constify.
12104 * coff-pe-read.c (struct read_pe_section_data): Constify.
12105 * command.h (lookup_cmd): Constify.
12106 * common/print-utils.c (decimal2str): Constify.
12107 * completer.c (gdb_print_filename): Constify.
12108 * corefile.c (set_gnutarget): Constify.
12109 * cp-name-parser.y (yyerror): Constify.
12110 * cp-valprint.c (cp_print_class_member): Constify.
12111 * cris-tdep.c (cris_register_name, crisv32_register_name):
12112 Constify.
12113 * d-exp.y (yyerror): Constify.
12114 (struct token::oper): Constify.
12115 * d-lang.h (d_yyerror): Constify.
12116 * dbxread.c (struct header_file_location::name): Constify.
12117 (add_old_header_file, add_new_header_file, last_function_name)
12118 (dbx_next_symbol_text, add_bincl_to_list)
12119 (find_corresponding_bincl_psymtab, set_namestring)
12120 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
12121 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
12122 * defs.h (command_line_input, print_address_symbolic)
12123 (deprecated_readline_begin_hook): Constify.
12124 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
12125 Constify.
12126 * event-top.c (handle_line_of_input): Constify and add cast.
12127 * exceptions.c (catch_errors): Constify.
12128 * exceptions.h (catch_errors): Constify.
12129 * expprint.c (print_subexp_standard, op_string, op_name)
12130 (op_name_standard, dump_raw_expression, dump_raw_expression):
12131 * expression.h (op_name, op_string, dump_raw_expression):
12132 Constify.
12133 * f-exp.y (yyerror): Constify.
12134 (struct token::oper): Constify.
12135 (struct f77_boolean_val::name): Constify.
12136 * f-lang.c (f_word_break_characters): Constify.
12137 * f-lang.h (f_yyerror): Constify.
12138 * fork-child.c (fork_inferior): Add cast.
12139 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
12140 (new_variant): Constify.
12141 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
12142 * gdbarch.c: Regenerate.
12143 * gdbcore.h (set_gnutarget): Constify.
12144 * go-exp.y (yyerror): Constify.
12145 (token::oper): Constify.
12146 * go-lang.h (go_yyerror): Constify.
12147 * go32-nat.c (go32_sysinfo): Constify.
12148 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
12149 * guile/scm-cmd.c (cmdscm_function): Constify.
12150 * guile/scm-param.c (pascm_param_value): Constify.
12151 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
12152 (h8300sx_register_name): Constify.
12153 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
12154 Constify.
12155 * ia64-tdep.c (ia64_register_names): Constify.
12156 * infcmd.c (construct_inferior_arguments): Constify.
12157 (path_command, attach_post_wait): Constify.
12158 * language.c (show_range_command, show_case_command)
12159 (unk_lang_error): Constify.
12160 * language.h (language_defn::la_error)
12161 (language_defn::la_name_of_this): Constify.
12162 * linespec.c (decode_line_2): Constify.
12163 * linux-thread-db.c (thread_db_err_str): Constify.
12164 * lm32-tdep.c (lm32_register_name): Constify.
12165 * m2-exp.y (yyerror): Constify.
12166 * m2-lang.h (m2_yyerror): Constify.
12167 * m32r-tdep.c (m32r_register_names): Constify and make static.
12168 * m68hc11-tdep.c (m68hc11_register_names): Constify.
12169 * m88k-tdep.c (m88k_register_name): Constify.
12170 * macroexp.c (appendmem): Constify.
12171 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
12172 (upgrade_type, parse_external, parse_partial_symbols)
12173 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
12174 (new_symbol): Constify.
12175 * memattr.c (mem_info_command): Constify.
12176 * mep-tdep.c (register_name_from_keyword): Constify.
12177 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
12178 Constify.
12179 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
12180 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
12181 * mi/mi-main.c (captured_mi_execute_command): Constify and add
12182 cast.
12183 (mi_execute_async_cli_command): Constify.
12184 * mips-tdep.c (mips_register_name): Constify.
12185 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
12186 (am33_register_name, am33_2_register_name)
12187 * moxie-tdep.c (moxie_register_names): Constify.
12188 * nat/linux-osdata.c (osdata_type): Constify fields.
12189 * nto-tdep.c (nto_parse_redirection): Constify.
12190 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
12191 (lookup_child_selector): Constify.
12192 (objc_methcall::name): Constify.
12193 * objc-lang.h (lookup_objc_class, lookup_child_selector)
12194 (lookup_struct_typedef): Constify.
12195 * objfiles.c (pc_in_section): Constify.
12196 * objfiles.h (pc_in_section): Constify.
12197 * p-exp.y (struct token::oper): Constify.
12198 (yyerror): Constify.
12199 * p-lang.h (pascal_yyerror): Constify.
12200 * parser-defs.h (op_name_standard): Constify.
12201 (op_print::string): Constify.
12202 (exp_descriptor::op_name): Constify.
12203 * printcmd.c (print_address_symbolic): Constify.
12204 * psymtab.c (print_partial_symbols): Constify.
12205 * python/py-breakpoint.c (stop_func): Constify.
12206 (bppy_get_expression): Constify.
12207 * python/py-cmd.c (cmdpy_completer::name): Constify.
12208 (cmdpy_function): Constify.
12209 * python/py-event.c (evpy_add_attribute)
12210 (gdbpy_initialize_event_generic): Constify.
12211 * python/py-event.h (evpy_add_attribute)
12212 (gdbpy_initialize_event_generic): Constify.
12213 * python/py-evts.c (add_new_registry): Constify.
12214 * python/py-finishbreakpoint.c (outofscope_func): Constify.
12215 * python/py-framefilter.c (get_py_iter_from_func): Constify.
12216 * python/py-inferior.c (get_buffer): Add cast.
12217 * python/py-param.c (parm_constant::name): Constify.
12218 * python/py-unwind.c (fprint_frame_id): Constify.
12219 * python/python.c (gdbpy_parameter_value): Constify.
12220 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
12221 * remote.c (memory_packet_config::name): Constify.
12222 (show_packet_config_cmd, remote_write_bytes)
12223 (remote_buffer_add_string):
12224 * reverse.c (exec_reverse_once): Constify.
12225 * rs6000-tdep.c (variant::name, variant::description): Constify.
12226 * rust-exp.y (rustyyerror): Constify.
12227 * rust-lang.c (rust_op_name): Constify.
12228 * rust-lang.h (rustyyerror): Constify.
12229 * serial.h (serial_ops::name): Constify.
12230 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
12231 (sh_sh3e_register_name, sh_sh2e_register_name)
12232 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
12233 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
12234 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
12235 (sh_sh4al_dsp_register_name): Constify.
12236 * sh64-tdep.c (sh64_register_name): Constify.
12237 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
12238 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
12239 * stabsread.c (patch_block_stabs, read_type_number)
12240 (ref_map::stabs, ref_add, process_reference)
12241 (symbol_reference_defined, define_symbol, define_symbol)
12242 (error_type, read_type, read_member_functions, read_cpp_abbrev)
12243 (read_one_struct_field, read_struct_fields, read_baseclasses)
12244 (read_tilde_fields, read_struct_type, read_array_type)
12245 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
12246 (read_huge_number, read_range_type, read_args, common_block_start)
12247 (find_name_end): Constify.
12248 * stabsread.h (common_block_start, define_symbol)
12249 (process_one_symbol, symbol_reference_defined, ref_add):
12250 * symfile.c (get_section_index, add_symbol_file_command):
12251 * symfile.h (get_section_index): Constify.
12252 * target-descriptions.c (tdesc_type::name): Constify.
12253 (tdesc_free_type): Add cast.
12254 * target.c (find_default_run_target):
12255 (add_deprecated_target_alias, find_default_run_target)
12256 (target_announce_detach): Constify.
12257 (do_option): Constify.
12258 * target.h (add_deprecated_target_alias): Constify.
12259 * thread.c (print_thread_info_1): Constify.
12260 * top.c (deprecated_readline_begin_hook, command_line_input):
12261 Constify.
12262 (init_main): Add casts.
12263 * top.h (handle_line_of_input): Constify.
12264 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
12265 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
12266 (tfind_command): Rename to ...
12267 (tfind_command_1): ... this and constify.
12268 (tfind_command): New function.
12269 (tfind_end_command, tfind_start_command): Adjust.
12270 (encode_source_string): Constify.
12271 * tracepoint.h (encode_source_string): Constify.
12272 * tui/tui-data.c (tui_partial_win_by_name): Constify.
12273 * tui/tui-data.h (tui_partial_win_by_name): Constify.
12274 * tui/tui-source.c (tui_set_source_content_nil): Constify.
12275 * tui/tui-source.h (tui_set_source_content_nil): Constify.
12276 * tui/tui-win.c (parse_scrolling_args): Constify.
12277 * tui/tui-windata.c (tui_erase_data_content): Constify.
12278 * tui/tui-windata.h (tui_erase_data_content): Constify.
12279 * tui/tui-winsource.c (tui_erase_source_content): Constify.
12280 * tui/tui.c (tui_enable): Add cast.
12281 * utils.c (defaulted_query): Constify.
12282 (init_page_info): Add cast.
12283 (puts_debug, subset_compare): Constify.
12284 * utils.h (subset_compare): Constify.
12285 * varobj.c (varobj_format_string): Constify.
12286 * varobj.h (varobj_format_string): Constify.
12287 * vax-tdep.c (vax_register_name): Constify.
12288 * windows-nat.c (windows_detach): Constify.
12289 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
12290 * xml-support.c (gdb_xml_end_element): Constify.
12291 * xml-tdesc.c (tdesc_start_reg): Constify.
12292 * xstormy16-tdep.c (xstormy16_register_name): Constify.
12293 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
12294 * xtensa-tdep.h (xtensa_register_t::name): Constify.
12295
12296 2017-04-05 Pedro Alves <palves@redhat.com>
12297
12298 * proc-api.c (struct trans): Constify.
12299 (procfs_note): Constify.
12300 * proc-events.c (struct trans, syscall_table):
12301 * proc-flags.c (struct trans): Constify.
12302 * proc-utils.h (procfs_note): Constify.
12303 * proc-why.c (struct trans): Constify.
12304 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
12305 (procfs_detach): Constify.
12306 * sol-thread.c (struct string_map): Constify.
12307 (td_err_string, td_state_string): Constify.
12308
12309 2017-04-05 Pedro Alves <palves@redhat.com>
12310
12311 * proc-api.c (procfs_filename): Don't initialize
12312 procfs_filename.
12313 (prepare_to_trace): Assume procfs_filename is non-NULL.
12314 (_initialize_proc_api): Give procfs_filename a default value here.
12315
12316 2017-04-05 Pedro Alves <palves@redhat.com>
12317
12318 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
12319 'cond_string' parameter.
12320 (extract_exception_regexp): Constify 'string' parameter.
12321 (catch_exception_command_1): Constify.
12322 * breakpoint.c (init_catchpoint)
12323 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
12324 parameter.
12325 (ep_parse_optional_if_clause, catch_fork_command_1)
12326 (catch_exec_command_1): Constify.
12327 * breakpoint.h (init_catchpoint): Constify 'cond_string'
12328 parameter.
12329 (ep_parse_optional_if_clause): Constify.
12330 * cli/cli-utils.c (remove_trailing_whitespace)
12331 (check_for_argument): Constify.
12332 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
12333 non-const overload.
12334 (check_for_argument): Likewise.
12335
12336 2017-04-05 Pedro Alves <palves@redhat.com>
12337
12338 * event-top.c (command_line_handler): Add cast to execute_command
12339 call.
12340 * record-btrace.c (cmd_record_btrace_bts_start)
12341 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
12342 (cmd_record_btrace_start): Add cast to execute_command call.
12343 * record-full.c (record_full_goto_insn):
12344 * record.c (record_start, record_stop): Add cast to
12345 execute_command_to_string calls.
12346 (cmd_record_start): Add cast to execute_command calls.
12347
12348 2017-04-05 Pedro Alves <palves@redhat.com>
12349
12350 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
12351 static inline function.
12352 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
12353 array and use gdb_PyArg_ParseTupleAndKeywords.
12354 * python/py-cmd.c (cmdpy_init): Likewise.
12355 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
12356 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
12357 (infpy_search_memory): Likewise.
12358 * python/py-objfile.c (objfpy_add_separate_debug_file)
12359 (gdbpy_lookup_objfile): Likewise.
12360 * python/py-symbol.c (gdbpy_lookup_symbol)
12361 (gdbpy_lookup_global_symbol): Likewise.
12362 * python/py-type.c (gdbpy_lookup_type): Likewise.
12363 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
12364 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
12365 Likewise.
12366
12367 2017-04-05 Pedro Alves <palves@redhat.com>
12368
12369 * python/python-internal.h (gdb_PyGetSetDef): New type.
12370 * python/py-block.c (block_object_getset)
12371 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
12372 * python/py-event.c (event_object_getset)
12373 (finish_breakpoint_object_getset): Likewise.
12374 * python/py-inferior.c (inferior_object_getset): Likewise.
12375 * python/py-infthread.c (thread_object_getset): Likewise.
12376 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
12377 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
12378 * python/py-objfile.c (objfile_getset): Likewise.
12379 * python/py-progspace.c (pspace_getset): Likewise.
12380 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
12381 Likewise.
12382 * python/py-record.c (recpy_record_getset): Likewise.
12383 * python/py-symbol.c (symbol_object_getset): Likewise.
12384 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
12385 Likewise.
12386 * python/py-type.c (type_object_getset, field_object_getset):
12387 Likewise.
12388 * python/py-value.c (value_object_getset): Likewise.
12389
12390 2017-04-05 Pedro Alves <palves@redhat.com>
12391
12392 * python/python-internal.h (gdb_PyObject_CallMethod)
12393 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
12394 New functions.
12395 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
12396 (PySys_GetObject, PySys_SetPath): New macros.
12397
12398 2017-04-05 Pedro Alves <palves@redhat.com>
12399
12400 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
12401 info_osdata_command.
12402 * osdata.c (info_osdata_command): Rename to ...
12403 (info_osdata): ... this. Constify 'type' parameter, and remove
12404 the 'from_tty' parameter. Accept NULL TYPE.
12405 (info_osdata_command): New function.
12406 * osdata.h (info_osdata_command): Remove declaration.
12407 (info_osdata): New declaration.
12408
12409 2017-04-05 Pedro Alves <palves@redhat.com>
12410
12411 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
12412 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
12413 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
12414 parameter.
12415 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
12416 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
12417 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
12418 parameter.
12419 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
12420 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
12421 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
12422 (mi_cmd_file_list_exec_source_files)
12423 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
12424 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
12425 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
12426 parameter.
12427 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
12428 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
12429 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
12430 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
12431 (mi_cmd_stack_info_frame): Constify 'command' parameter.
12432 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
12433 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
12434 'command' parameter.
12435 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
12436 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
12437 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
12438 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
12439 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
12440 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
12441 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
12442 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
12443 (mi_cmd_var_set_update_range): Constify 'command' parameter.
12444 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
12445 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
12446 parameter.
12447 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
12448 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
12449 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
12450 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
12451 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
12452 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
12453 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
12454 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
12455 (mi_cmd_data_list_changed_registers)
12456 (mi_cmd_data_write_register_values)
12457 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
12458 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
12459 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
12460 (mi_cmd_list_features, mi_cmd_list_target_features)
12461 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
12462 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
12463 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
12464 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
12465 (mi_cmd_trace_frame_collected): Constify 'command'
12466 parameter.
12467 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
12468 'command' parameter.
12469
12470 2017-04-05 Pedro Alves <palves@redhat.com>
12471
12472 * ada-lang.c (ada_completer_word_break_characters): Now a const
12473 array.
12474 (ada_get_gdb_completer_word_break_characters): Constify.
12475 * completer.c (gdb_completer_command_word_break_characters)
12476 (gdb_completer_file_name_break_characters)
12477 (gdb_completer_quote_characters): Now const arrays.
12478 (get_gdb_completer_quote_characters): Constify.
12479 (set_rl_completer_word_break_characters): New function.
12480 (set_gdb_completion_word_break_characters)
12481 (complete_line_internal): Use it.
12482 * completer.h (get_gdb_completer_quote_characters): Constify.
12483 (set_rl_completer_word_break_characters): Declare.
12484 * f-lang.c (f_word_break_characters): Constify.
12485 * language.c (default_word_break_characters): Constify.
12486 * language.h (language_defn::la_word_break_characters): Constify.
12487 (default_word_break_characters): Constify.
12488 * top.c (init_main): Use set_rl_completer_word_break_characters.
12489
12490 2017-04-05 Pedro Alves <palves@redhat.com>
12491
12492 * aix-thread.c (aix_thread_pid_to_str)
12493 (aix_thread_extra_thread_info): Constify.
12494 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
12495 * bsd-uthread.c (bsd_uthread_extra_thread_info)
12496 (bsd_uthread_pid_to_str): Constify.
12497 * corelow.c (core_pid_to_str): Constify.
12498 * darwin-nat.c (darwin_pid_to_str): Constify.
12499 * fbsd-nat.c (fbsd_pid_to_str): Constify.
12500 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
12501 Constify.
12502 * gnu-nat.c (gnu_pid_to_str): Constify.
12503 * go32-nat.c (go32_pid_to_str): Constify.
12504 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
12505 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
12506 * inferior.c (inferior_pid_to_str): Constify.
12507 * linux-nat.c (linux_nat_pid_to_str): Constify.
12508 * linux-tdep.c (linux_core_pid_to_str): Constify.
12509 * linux-thread-db.c (thread_db_pid_to_str)
12510 (thread_db_extra_thread_info): Constify.
12511 * nto-tdep.c (nto_extra_thread_info): Constify.
12512 * nto-tdep.h (nto_extra_thread_info): Constify.
12513 * obsd-nat.c (obsd_pid_to_str): Constify.
12514 * procfs.c (procfs_pid_to_str): Constify.
12515 * ravenscar-thread.c (ravenscar_extra_thread_info)
12516 (ravenscar_pid_to_str): Constify.
12517 * remote-sim.c (gdbsim_pid_to_str): Constify.
12518 * remote.c (remote_threads_extra_info, remote_pid_to_str):
12519 Constify.
12520 * sol-thread.c (solaris_pid_to_str): Constify.
12521 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
12522 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
12523 * target.c (default_pid_to_str, target_pid_to_str)
12524 (normal_pid_to_str, default_pid_to_str): Constify.
12525 * target.h (target_ops::to_pid_to_str)
12526 (target_ops::to_extra_thread_info): Constify.
12527 (target_pid_to_str, normal_pid_to_str): Constify.
12528 * windows-nat.c (windows_pid_to_str): Constify.
12529 * gdbarch.sh (core_pid_to_str): Constify.
12530 * target-delegates.c: Regenerate.
12531 * gdbarch.h, gdbarch.c: Regenerate.
12532
12533 2017-04-05 Pedro Alves <palves@redhat.com>
12534
12535 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
12536 the memory of the temporary warning_pre_print override.
12537 * utils.c (warning_pre_print): Constify.
12538 * utils.h (warning_pre_print): Constify.
12539
12540 2017-04-05 Pedro Alves <palves@redhat.com>
12541
12542 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
12543 (shell_command): New function.
12544 (make_command): Use std::string.
12545 (init_cli_cmds): Register shell_command instead of shell_escape.
12546
12547 2017-04-05 Pedro Alves <palves@redhat.com>
12548
12549 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
12550 * tracepoint.c (default_collect): Don't initialize.
12551
12552 2017-04-05 Pedro Alves <palves@redhat.com>
12553
12554 * macroexp.c (macro_buffer::shared): Now a bool.
12555 (init_buffer): Update.
12556 (init_shared_buffer): Constify 'addr' parameter.
12557 (substitute_args, expand, macro_expand, macro_expand_next): Remove
12558 casts.
12559
12560 2017-04-05 Pedro Alves <palves@redhat.com>
12561
12562 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
12563 * disasm.c (set_disassembler_options): Constify local.
12564 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
12565
12566 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
12567
12568 PR gdb/21352
12569 * tracefile.c (tsave_command): Fix argument parsing for '-r'
12570 option.
12571
12572 2017-04-05 Yao Qi <yao.qi@linaro.org>
12573
12574 * frame.c (frame_unwind_register_unsigned): Call
12575 frame_unwind_register_value.
12576
12577 2017-04-05 Yao Qi <yao.qi@linaro.org>
12578
12579 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
12580 Use gdb_test_multiple, and don't match anchor.
12581
12582 2017-04-05 Pedro Alves <palves@redhat.com>
12583
12584 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
12585 (Write After Approval): Remove Simon Marchi.
12586
12587 2017-04-05 Pedro Alves <palves@redhat.com>
12588
12589 * common/gdb_optional.h (optional::optional): Make constexpr and
12590 initialize m_dummy.
12591
12592 2017-04-04 John Baldwin <jhb@FreeBSD.org>
12593
12594 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
12595 (amd64fbsd_jmp_buf_reg_offset): Remove.
12596 (amd64fbsd_supply_uthread): Remove function.
12597 (amd64fbsd_collect_uthread): Remove function.
12598 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
12599 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
12600 (x86_64-*-freebsd*): Remove bsd-uthread.o.
12601 (fbsd-nat.c): Update comment.
12602 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
12603 (i386fbsd_jmp_buf_reg_offset): Remove.
12604 (i386fbsd_supply_uthread): Remove function.
12605 (i386fbsd_collect_uthread): Remove function.
12606 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
12607
12608 2017-04-04 John Baldwin <jhb@FreeBSD.org>
12609
12610 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
12611 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
12612 * NEWS: Mention that support for FreeBSD/alpha was removed.
12613 * alpha-fbsd-tdep.c: Delete file.
12614 * config/alpha/fbsd.mh: Delete file.
12615 * configure.host: Delete alpha*-*-freebsd* and
12616 alpha*-*-kfreebsd*-gnu.
12617 * configure.tgt: Delete alpha*-*-freebsd* and
12618 alpha*-*-kfreebsd*-gnu.
12619
12620 2017-04-04 John Baldwin <jhb@FreeBSD.org>
12621
12622 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
12623 amd64bsd_store_inferior_registers): Use ptid from regcache.
12624
12625 2017-04-04 Pedro Alves <palves@redhat.com>
12626
12627 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
12628 data fields, make them private and add "m_" prefixes.
12629 (lnp_state_machine::lnp_state_machine): New ctor.
12630 (record_line, check_line_address, handle_set_discriminator)
12631 (handle_set_address, handle_advance_pc, handle_special_opcode)
12632 (handle_advance_line, handle_set_file, handle_negate_stmt)
12633 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
12634 (end_sequence, advance_line): New methods.
12635 (m_gdbarch, m_record_lines_p): New fields.
12636 (lnp_reader_state): Delete.
12637 (dwarf_record_line): Rename to ...
12638 (lnp_state_machine::record_line): ... adjust.
12639 (init_lnp_state_machine): Delete.
12640 (lnp_state_machine::lnp_state_machine): New.
12641 (check_line_address): Rename to ...
12642 (lnp_state_machine::check_line_address): This.
12643 (dwarf_decode_lines_1): Remove reference to "reader_state".
12644 Adjust lnp_state_machine having a non-default ctor. Use bool.
12645 State machine internal state manipulation moved to
12646 lnp_state_machine methods.
12647
12648 2017-04-04 Pedro Alves <palves@redhat.com>
12649
12650 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12651 unittests/offset-type-selftests.c.
12652 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
12653 * common/offset-type.h: New file.
12654 * common/preprocessor.h: New file.
12655 * common/traits.h: New file.
12656 * common/valid-expr.h: New file.
12657 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
12658 sect_offset and cu_offset strong typedefs throughout.
12659 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
12660 typedefs throughout.
12661 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
12662 sect_offset and cu_offset strong typedefs throughout.
12663 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
12664 typedefs throughout.
12665 * gdbtypes.h: Include "common/offset-type.h".
12666 (cu_offset): Now an offset type (strong typedef) instead of a
12667 struct.
12668 (sect_offset): Likewise.
12669 (union call_site_parameter_u): Rename "param_offset" field to
12670 "param_cu_off".
12671 * unittests/offset-type-selftests.c: New file.
12672
12673 2017-04-04 Pedro Alves <palves@redhat.com>
12674
12675 * common/underlying.h: New file.
12676 * dwarf2read.c: Include "common/gdb_optional.h" and
12677 "common/underlying.h".
12678 (dir_index, file_name_index): New types.
12679 (file_entry): Use them.
12680 (file_entry::include): Use to_underlying.
12681 (line_header::add_file_name): Use dir_index.
12682 (read_formatted_entries): Use gdb::optional. Read form before
12683 writting to file_entry.
12684 (dwarf_decode_line_header): Use dir_index.
12685 (lnp_state_machine::current_file): Use to_underlying.
12686 (lnp_state_machine::file): Change type to file_name_index.
12687 (dwarf_record_line): Use to_underlying.
12688 (init_lnp_state_machine): Use file_name_index.
12689 (dwarf_decode_lines_1): Use dir_index and file_name_index.
12690
12691 2017-04-04 Pedro Alves <palves@redhat.com>
12692
12693 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
12694 operator bool, has_value and get methods.
12695
12696 2017-04-04 Pedro Alves <palves@redhat.com>
12697
12698 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
12699 fields.
12700 (line_header): Initialize all data fields. Change type of
12701 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
12702 Change type of include_dirs to std::vector<const char *>. Remove
12703 num_include_dirs, include_dirs_size. Change type of file_names to
12704 std::vector<file_entry>. Remove num_file_names, file_names_size.
12705 (line_header::line_header): New.
12706 (line_header::add_include_dir, line_header::add_file_name): New
12707 methods.
12708 (line_header::include_dir_at): Remove NULL check.
12709 (line_header::file_name_at): Add const overload.
12710 (line_header_up): New unique_ptr typedef.
12711 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
12712 std::vector. Remove free_line_header call.
12713 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
12714 free_line_header call.
12715 (free_cu_line_header): Delete.
12716 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
12717 (setup_type_unit_groups): Use line_header_up instead of cleanups.
12718 Adjust to use std::vector.
12719 (free_line_header): Delete.
12720 (free_line_header_voidp): Use delete.
12721 (add_include_dir): Replace with ...
12722 (line_header::add_include_dir): ... this method. Use std::vector.
12723 (add_file_name): Replace with ...
12724 (line_header::add_file_name): ... this method. Use std::vector.
12725 (add_include_dir_stub): Delete.
12726 (read_formatted_entries): Remove memset.
12727 (dwarf_decode_line_header): Return a line_header_up instead of a
12728 raw pointer. Remove cleanup handling. Pass lambdas to
12729 read_formatted_entries. Adjust to use line_header methods.
12730 (dwarf_decode_lines_1): Adjust to use line_header methods.
12731 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
12732 use std::vector.
12733
12734 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
12735
12736 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
12737 instead of struct ptid.
12738
12739 2017-05-04 Alan Hayward <alan.hayward@arm.com>
12740
12741 * frame.c (get_frame_register_bytes): Unwind using value.
12742 (put_frame_register_bytes): Likewise.
12743
12744 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
12745
12746 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
12747 aggregate-like.
12748
12749 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
12750
12751 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
12752
12753 2017-03-29 Yao Qi <yao.qi@linaro.org>
12754
12755 * gdbthread.h (struct thread_info): Declare constructor and
12756 destructor. Add some in-class member initializers.
12757 * thread.c (free_thread): Remove.
12758 (init_thread_list): Call delete instead of free_thread.
12759 (new_thread): Call thread_info constructor.
12760 (thread_info::thread_info): New function.
12761 (thread_info::~thread_info): New function.
12762 (delete_thread_1): Call delete instead of free_thread.
12763 (make_cleanup_restore_current_thread): Move tp and frame to
12764 inner block.
12765
12766 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12767
12768 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
12769 (arc_skip_prologue): Likewise.
12770 (arc_make_frame_cache): Likewise.
12771 (arc_pv_get_operand): New function.
12772 (arc_is_in_prologue): Likewise.
12773 (arc_analyze_prologue): Likewise.
12774 (arc_print_frame_cache): Likewise.
12775 (MAX_PROLOGUE_LENGTH): New constant.
12776
12777 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12778
12779 * configure.tgt: Add arc-insn.o.
12780 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
12781 (dump_arc_instruction_command): New function.
12782 (arc_fprintf_disasm): Likewise.
12783 (arc_disassemble_info): Likewise.
12784 (arc_insn_get_operand_value): Likewise.
12785 (arc_insn_get_operand_value_signed): Likewise.
12786 (arc_insn_get_memory_base_reg): Likewise.
12787 (arc_insn_get_memory_offset): Likewise.
12788 (arc_insn_get_branch_target): Likewise.
12789 (arc_insn_dump): Likewise.
12790 (arc_insn_get_linear_next_pc): Likewise.
12791 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
12792 (arc_disassemble_info): Likewise.
12793 (arc_insn_get_branch_target): Likewise.
12794 (arc_insn_get_linear_next_pc): Likewise.
12795 * NEWS: Mention new "maint print arc arc-instruction".
12796
12797 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12798
12799 * arc-tdep (maintenance_print_arc_list): New variable.
12800 (maintenance_print_arc_command): New function.
12801
12802 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12803
12804 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
12805 Add "limm" and "reserved".
12806 (arc_cannot_fetch_register, arc_cannot_store_register): Add
12807 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
12808 * arc-tdep.h (arc_regnum): Likewise.
12809
12810 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12811
12812 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
12813 for THREADPTR register.
12814 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
12815 register.
12816 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
12817 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
12818 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
12819
12820 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12821
12822 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
12823 registers above gdbarch_num_regs (gdbarch) as privileged in
12824 call0 ABI.
12825
12826 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12827
12828 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
12829 for a single specified register or for all registers in
12830 a0_base..a0_base + C0_NREGS range.
12831 (supply_gregset_reg): Call regcache_raw_supply for a single
12832 specified register or for all registers in a0_base..a0_base +
12833 C0_NREGS range.
12834
12835 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12836
12837 * arch/xtensa.h (C0_NREGS): Add definition.
12838 * xtensa-tdep.c (C0_NREGS): Remove definition.
12839
12840 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12841
12842 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
12843 Drop xtensa_default_isa initialization.
12844 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
12845
12846 2017-03-27 Pedro Alves <palves@redhat.com>
12847
12848 * dwarf2read.c (file_entry) <dir_index>: Add comment.
12849 (file_entry::include_dir): New method.
12850 (line_header::include_dir_at, line_header::file_name_at): New
12851 methods.
12852 (setup_type_unit_groups, setup_type_unit_groups)
12853 (psymtab_include_file_name): Simplify using the new methods.
12854 (lnp_state_machine) <the_line_header>: New field.
12855 <file>: Add comment.
12856 (lnp_state_machine::current_file): New method.
12857 (dwarf_record_line): Simplify using the new methods.
12858 (init_lnp_state_machine): Initialize the "the_line_header" field.
12859 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
12860 Simplify using the new methods.
12861
12862 2017-03-27 Pedro Alves <palves@redhat.com>
12863
12864 * cp-name-parser.y (make_empty): Delete.
12865 (demangler_special, nested_name, ptr_operator, array_indicator)
12866 (direct_declarator, declarator_1): Use fill_comp instead of
12867 make_empty.
12868
12869 2017-03-27 Pedro Alves <palves@redhat.com>
12870
12871 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
12872 to ATTRIBUTE_PRINTF.
12873 * solib-target.c (library_list_start_list): Print "string" not
12874 "version".
12875 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
12876 gdb_xml_error call.
12877
12878 2017-03-27 Pedro Alves <palves@redhat.com>
12879
12880 * dwarf2read.c (struct file_and_directory): New.
12881 (dwarf2_get_dwz_file): Adjust to use std::string.
12882 (dw2_get_file_names_reader): Adjust to use file_and_directory.
12883 (find_file_and_directory): Adjust to return a file_and_directory
12884 object.
12885 (read_file_scope): Adjust to use file_and_directory. Remove
12886 make_cleanup/do_cleanups calls.
12887 (open_and_init_dwp_file): Adjust to use std::string. Remove
12888 make_cleanup/do_cleanups calls.
12889 * python/python.c (do_start_initialization): Adjust to ldirname
12890 returning a std::string.
12891 * utils.c (ldirname): Now returns a std::string.
12892 * utils.h (ldirname): Change return type to std::string.
12893 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
12894 returning a std::string.
12895 * xml-tdesc.c (file_read_description_xml): Likewise.
12896
12897 2017-03-24 Alan Hayward <alan.hayward@arm.com>
12898
12899 * regcache.c (regcache_debug_print_register): New function.
12900 * regcache.h (regcache_debug_print_register): New declaration.
12901 * target.c (debug_print_register): Remove.
12902 (target_fetch_registers): Call regcache_debug_print_register.
12903 (target_store_registers): Likewise.
12904
12905 2017-03-24 Pádraig Brady <pbrady@fb.com>
12906
12907 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
12908 reference beyond the 'lh->include_dirs' array before accessing to
12909 it.
12910 (psymtab_include_file_name): Likewise.
12911 (dwarf_decode_lines_1): Likewise.
12912 (dwarf_decode_lines): Likewise.
12913 (file_file_name): Likewise.
12914
12915 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
12916
12917 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
12918 inferior_ptid.
12919 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
12920 ps_lsetfpregs): Likewise.
12921 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
12922 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
12923 ps_lsetfpregs): Likewise.
12924 * target.c (target_fetch_registers, target_store_registers):
12925 Remove asserts.
12926
12927 2017-03-23 Alan Hayward <alan.hayward@arm.com>
12928
12929 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
12930
12931 2017-03-23 Yao Qi <yao.qi@linaro.org>
12932
12933 * aarch64-tdep.c (aarch64_process_record_test): Declare.
12934 (_initialize_aarch64_tdep): Register it.
12935 (aarch64_record_load_store): Handle PRFM instruction.
12936 (aarch64_process_record_test): New function.
12937
12938 2017-03-23 Yao Qi <yao.qi@linaro.org>
12939
12940 * aarch64-tdep.c (aarch64_record_load_store): Fix code
12941 indentation.
12942
12943 2017-03-23 Yao Qi <yao.qi@linaro.org>
12944
12945 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
12946
12947 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12948
12949 python/python.c (do_start_initialization): Fix memory leak.
12950
12951 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
12952
12953 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
12954 using get_ptrace_pid.
12955 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
12956 inferior_ptid.
12957 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
12958 inferior_ptid instead of pid.
12959
12960 2017-03-22 Yao Qi <yao.qi@linaro.org>
12961
12962 * aarch64-tdep.c: Wrap locally used classes in anonymous
12963 namespace.
12964 * arm-tdep.c: Likewise.
12965 * linespec.c: Likewise.
12966 * ui-out.c: Likewise.
12967
12968 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
12969
12970 PR gdb/19637
12971 * python/lib/gdb/printer/bound_registers.py: Import sys.
12972
12973 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
12974
12975 * windows-nat.c (do_windows_fetch_inferior_registers): Add
12976 windows_thread_info parameter and use it instead of
12977 current_thread.
12978 (windows_fetch_inferior_registers): Don't set current_thread,
12979 pass the thread to do_windows_fetch_inferior_registers. Use
12980 ptid from regcache instead of inferior_ptid.
12981 (do_windows_store_inferior_registers): Add windows_thread_info
12982 parameter and use it instead of current_thread.
12983 (windows_store_inferior_registers): Don't set current_thread,
12984 pass the thread to do_windows_store_inferior_registers. Use
12985 ptid from regcache instead of inferior_ptid.
12986
12987 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
12988
12989 * ser-mingw.c (ser_windows_raw): Remove reference to
12990 struct serial::current_timeout.
12991
12992 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
12993
12994 PR tdep/20928
12995 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
12996 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
12997 (sparc64_fsr_type): Fix %fsr decoding.
12998
12999 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
13000
13001 * python/py-record-btrace.c (btpy_insn_data): Change return type
13002 for Python 2.
13003
13004 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
13005
13006 * spu-linux-nat.c (spu_fetch_inferior_registers,
13007 spu_store_inferior_registers): Use ptid from regcache, set and
13008 restore inferior_ptid.
13009 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
13010 Likewise.
13011
13012 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
13013
13014 * i386-linux-nat.c (fetch_register, store_register,
13015 i386_linux_fetch_inferior_registers,
13016 i386_linux_store_inferior_registers): Use ptid from regcache.
13017 * ia64-linux-nat.c (ia64_linux_fetch_register,
13018 ia64_linux_store_register): Likewise.
13019 * inf-ptrace.c (inf_ptrace_fetch_register,
13020 inf_ptrace_store_register): Likewise.
13021 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
13022 m32r_linux_store_inferior_registers): Likewise.
13023 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
13024 m68kbsd_store_inferior_registers): Likewise.
13025 * m68k-linux-nat.c (fetch_register, store_register,
13026 m68k_linux_fetch_inferior_registers,
13027 m68k_linux_store_inferior_registers): Likewise.
13028 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
13029 m88kbsd_store_inferior_registers): Likewise.
13030 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
13031 mips_fbsd_store_inferior_registers): Likewise.
13032 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
13033 mips64_linux_regsets_store_registers): Likewise.
13034 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
13035 mipsnbsd_store_inferior_registers): Likewise.
13036 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
13037 mips64obsd_store_inferior_registers): Likewise.
13038 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
13039 Likewise.
13040 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
13041 ppcfbsd_store_inferior_registers): Likewise.
13042 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
13043 ppc_linux_store_inferior_registers): Likewise.
13044 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
13045 ppcnbsd_store_inferior_registers): Likewise.
13046 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
13047 ppcobsd_store_registers): Likewise.
13048 * procfs.c (procfs_fetch_registers, procfs_store_registers):
13049 Likewise.
13050 * ravenscar-thread.c (ravenscar_fetch_registers,
13051 ravenscar_store_registers, ravenscar_prepare_to_store):
13052 Likewise.
13053 * record-btrace.c (record_btrace_fetch_registers,
13054 record_btrace_store_registers, record_btrace_prepare_to_store):
13055 Likewise.
13056 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
13057 Lookup inferior using ptid from regcache, instead of
13058 current_inferior.
13059 * remote.c (remote_fetch_registers, remote_store_registers): Use
13060 ptid from regcache.
13061 * rs6000-nat.c (fetch_register, store_register): Likewise.
13062 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
13063 s390_linux_store_inferior_registers): Likewise.
13064 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
13065 shnbsd_store_inferior_registers): Likewise.
13066 * sol-thread.c (sol_thread_fetch_registers,
13067 sol_thread_store_registers): Likewise.
13068 * sparc-nat.c (sparc_fetch_inferior_registers,
13069 sparc_store_inferior_registers): Likewise.
13070 * tilegx-linux-nat.c (fetch_inferior_registers,
13071 store_inferior_registers): Likewise.
13072 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
13073 vaxbsd_store_inferior_registers): Likewise.
13074 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
13075 store_xtregs): Likewise.
13076
13077 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13078
13079 PR gdb/14441
13080 * NEWS: Mention support for rvalue references in GDB and python.
13081 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
13082 supports both lvalue and rvalue references.
13083
13084 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13085
13086 PR gdb/14441
13087 * gdbtypes.c (rank_one_type): Implement overloading
13088 resolution rules regarding rvalue references.
13089
13090 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13091
13092 PR gdb/14441
13093 * aarch64-tdep.c (aarch64_type_align)
13094 (aarch64_extract_return_value, aarch64_store_return_value): Change
13095 lvalue reference type checks to general reference type checks.
13096 * amd64-tdep.c (amd64_classify): Likewise.
13097 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
13098 Likewise.
13099 * arm-tdep.c (arm_type_align, arm_extract_return_value)
13100 (arm_store_return_value): Likewise.
13101 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
13102 * c-typeprint.c (c_print_type): Likewise.
13103 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
13104 (cplus_number_of_children, cplus_describe_child): Likewise.
13105 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
13106 * completer.c (expression_completer): Likewise.
13107 * cp-support.c (make_symbol_overload_list_adl_namespace):
13108 Likewise.
13109 * darwin-nat-info.c (info_mach_region_command): Likewise.
13110 * dwarf2loc.c (entry_data_value_coerce_ref)
13111 (value_of_dwarf_reg_entry): Likewise.
13112 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
13113 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
13114 Likewise.
13115 * findvar.c (extract_typed_address, store_typed_address):
13116 Likewise.
13117 * gdbtypes.c (rank_one_type): Likewise.
13118 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
13119 * infcall.c (value_arg_coerce): Likewise.
13120 * language.c (pointer_type): Likewise.
13121 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
13122 Likewise.
13123 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
13124 * mn10300-tdep.c (mn10300_type_align): Likewise.
13125 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
13126 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
13127 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
13128 Likewise.
13129 * printcmd.c (print_formatted, x_command): Likewise.
13130 * python/py-type.c (typy_get_composite, typy_template_argument):
13131 Likewise.
13132 * python/py-value.c (valpy_referenced_value)
13133 (valpy_get_dynamic_type, value_has_field): Likewise.
13134 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
13135 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
13136 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
13137 * spu-tdep.c (spu_scalar_value_p): Likewise.
13138 * symtab.c (lookup_symbol_aux): Likewise.
13139 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
13140 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
13141 Likewise.
13142 * valops.c (value_cast_pointers, value_cast)
13143 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
13144 (value_struct_elt, value_struct_elt_bitpos)
13145 (value_find_oload_method_list, find_overload_match)
13146 (value_rtti_indirect_type): Likewise.
13147 * valprint.c (val_print_scalar_type_p, generic_val_print):
13148 Likewise.
13149 * value.c (value_actual_type, value_as_address, unpack_long)
13150 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
13151 (coerce_ref): Likewise.
13152 * varobj.c (varobj_get_value_type): Likewise.
13153
13154 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13155
13156 PR gdb/14441
13157 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
13158 table of constants.
13159 * python/lib/gdb/command/explore.py: Support exploring values
13160 of rvalue reference types.
13161 * python/lib/gdb/types.py: Implement get_basic_type() for
13162 rvalue reference types.
13163 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
13164 constant.
13165 * python/py-value.c (valpy_getitem): Add an rvalue reference
13166 check.
13167 (valpy_reference_value): Add new parameter "refcode".
13168 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
13169 New wrappers for valpy_reference_value().
13170 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
13171 (gdbpy_invoke_xmethod): Likewise.
13172
13173 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13174
13175 PR gdb/14441
13176 * dwarf2read.c (process_die, read_type_die_1): Handle the
13177 DW_TAG_rvalue_reference_type DIE.
13178 (read_tag_reference_type): Add new parameter "refcode".
13179
13180 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13181
13182 PR gdb/14441
13183 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
13184 (c_type_print_modifier, c_type_print_varspec_suffix)
13185 (c_type_print_base): Support printing rvalue reference types.
13186 * c-valprint.c (c_val_print, c_value_print): Support printing
13187 rvalue reference values.
13188
13189 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13190
13191 PR gdb/14441
13192 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
13193 typename.
13194 * cp-support.c (replace_typedefs): Handle
13195 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
13196 * python/py-type.c (typy_lookup_type): Likewise.
13197
13198 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13199
13200 PR gdb/14441
13201 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
13202 * parse.c (insert_type): Change assert statement.
13203 (follow_types): Handle rvalue reference types.
13204 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
13205 constant.
13206
13207 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13208
13209 PR gdb/14441
13210 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
13211 value_ref() interface.
13212 * c-valprint.c (c_value_print): Likewise.
13213 * infcall.c (value_arg_coerce): Likewise.
13214 * python/py-value.c (valpy_reference_value): Likewise.
13215 * valops.c (value_cast, value_reinterpret_cast)
13216 (value_dynamic_cast, typecmp): Likewise.
13217 (value_ref): Parameterize by kind of return value reference type.
13218 * value.h (value_ref): Add new parameter "refcode".
13219
13220 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13221
13222 PR gdb/14441
13223 * dwarf2read.c (read_tag_reference_type): Use
13224 lookup_lvalue_reference_type() instead of lookup_reference_type().
13225 * eval.c (evaluate_subexp_standard): Likewise.
13226 * f-exp.y: Likewise.
13227 * gdbtypes.c (make_reference_type, lookup_reference_type):
13228 Generalize with rvalue reference types.
13229 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
13230 convenience wrappers for lookup_reference_type().
13231 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
13232 reference kind parameter.
13233 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
13234 wrappers for lookup_reference_type().
13235 * guile/scm-type.c (gdbscm_type_reference): Use
13236 lookup_lvalue_reference_type() instead of lookup_reference_type().
13237 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
13238 * parse.c (follow_types): Likewise.
13239 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
13240 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
13241 Likewise.
13242 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
13243 (gdbpy_invoke_xmethod): Likewise.
13244 * stabsread.c: Provide extra argument to make_reference_type()
13245 call.
13246 * valops.c (value_ref, value_rtti_indirect_type): Use
13247 lookup_lvalue_reference_type() instead of lookup_reference_type().
13248
13249 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13250
13251 PR gdb/14441
13252 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
13253 (TYPE_IS_REFERENCE): New macro.
13254 (struct type): Add rvalue_reference_type field.
13255 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
13256
13257 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
13258
13259 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
13260 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
13261 New function definition.
13262 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
13263 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
13264 New function declaration.
13265 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
13266 * mi/mi-interp.h: New file.
13267 * solib.c (info_sharedlibrary_command): Replace for loop with
13268 ALL_SO_LIBS macro
13269 * solib.h (update_solib_list): New function declaration.
13270 (so_list_head): Move macro.
13271 * solist.h (ALL_SO_LIBS): New macro.
13272
13273 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
13274
13275 * infcmd.c (post_create_inferior): Remove unused argument in
13276 call to solib_add.
13277 * remote.c (remote_start_remote): Likewise.
13278 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
13279 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
13280 (enable_break): Likewise.
13281 * solib.c (update_solib_list): Remove unused target argument
13282 and its documentation.
13283 (solib_add): Remove unused target argument. Remove unused
13284 argument in call to update_solib_list.
13285 (info_sharedlibrary_command): Remove unused argument in call
13286 to update_solib_list.
13287 (sharedlibrary_command): Remove unused argument in call to
13288 solib_add.
13289 (handle_solib_event): Likewise.
13290 (reload_shared_libraries): Likewise.
13291 * solib.h (solib_add): Remove unused target argument.
13292
13293 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
13294
13295 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
13296 (s390_displaced_step_fixup): Cover relative branches with the
13297 default fixup handling. This fixes lack of support for some
13298 relative branch instructions.
13299
13300 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13301
13302 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
13303 ptid from regcache.
13304
13305 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13306
13307 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
13308 i386_darwin_store_inferior_registers): Use ptid from regcache.
13309
13310 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13311
13312 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
13313 i386bsd_store_inferior_registers): Use ptid from regcache.
13314
13315 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13316
13317 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
13318 hppaobsd_store_registers): Use ptid from regcache.
13319
13320 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13321
13322 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
13323 hppanbsd_store_registers): Use ptid from regcache.
13324
13325 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13326
13327 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
13328 from regcache. Use get_ptrace_pid.
13329
13330 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13331
13332 * corelow.c (get_core_register_section): Use ptid from regcache,
13333 update doc.
13334
13335 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13336
13337 * bsd-uthread.c (bsd_uthread_fetch_registers,
13338 bsd_uthread_store_registers): Use ptid from regcache, set and
13339 restore inferior_ptid.
13340
13341 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13342
13343 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
13344 fetch_fp_regs, store_register, store_regs, store_fp_register,
13345 store_fp_regs): Use ptid from regcache.
13346
13347 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13348
13349 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
13350 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
13351 store_vfp_regs): Use ptid from regcache.
13352
13353 2017-03-17 Pedro Alves <palves@redhat.com>
13354
13355 PR remote/21188
13356 * ser-base.c (ser_base_wait_for): Add comment.
13357 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
13358 version.
13359 * ser-unix.c (hardwire_raw): Remove reference to
13360 scb->current_timeout.
13361 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
13362 (hardwire_ops): Install ser_base_readchar instead of
13363 hardwire_readchar.
13364 * serial.h (struct serial) <current_timeout, timeout_remaining>:
13365 Remove fields.
13366
13367 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
13368
13369 PR gdb/19637
13370 * python/lib/gdb/printer/bound_registers.py: Add support for
13371 Python 3.
13372
13373 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
13374
13375 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
13376 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
13377 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
13378 byte_offset to subobj_byte_offset. Fix the handling of
13379 DWARF_VALUE_STACK on big-endian targets when coming via an
13380 implicit pointer.
13381 (dwarf2_evaluate_loc_desc): Adjust call to
13382 dwarf2_evaluate_loc_desc_full.
13383 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
13384 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
13385
13386 2017-03-16 Yao Qi <yao.qi@linaro.org>
13387
13388 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
13389 and REVSH instructions.
13390
13391 2017-03-16 Yao Qi <yao.qi@linaro.org>
13392
13393 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
13394 (arm_record_test): Declare.
13395 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
13396 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
13397 align with the manual.
13398 (thumb_record_misc): Adjust the code order to align with the
13399 manual.
13400 (thumb2_record_decode_insn_handler): Fix instruction matching.
13401 (instruction_reader_thumb): New class.
13402 (arm_record_test): New function.
13403
13404 2017-03-16 Yao Qi <yao.qi@linaro.org>
13405
13406 * arm-tdep.c (abstract_memory_reader): New class.
13407 (instruction_reader): New class.
13408 (extract_arm_insn): Add argument 'reader'. Callers updated.
13409 (decode_insn): Likewise.
13410
13411 2017-03-16 Doug Evans <dje@google.com>
13412
13413 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
13414 member. Change type of TYPE member to SCM. All uses updated.
13415 (lsscm_make_lazy_string_smob): Add assert.
13416 (lsscm_make_lazy_string): Flag bad length values.
13417 (lsscm_elt_type): New function.
13418 (gdbscm_lazy_string_to_value): Rewrite to use
13419 lsscm_safe_lazy_string_to_value.
13420 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
13421 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
13422 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
13423 in incoming type.
13424 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
13425 * guile/scm-type.c (tyscm_scm_to_type): New function.
13426
13427 2017-03-15 Doug Evans <dje@google.com>
13428
13429 PR python/17728, python/18439, python/18779
13430 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
13431 member. Change type of TYPE member to PyObject *. All uses updated.
13432 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
13433 (gdbpy_create_lazy_string_object): Flag bad length values.
13434 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
13435 Handle typedefs in incoming type.
13436 (stpy_lazy_string_elt_type): New function.
13437 (gdbpy_extract_lazy_string): Call it.
13438 * python/py-value.c (valpy_lazy_string): Flag bad length values.
13439 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
13440 typedefs in incoming type.
13441
13442 2017-03-16 Doug Evans <dje@google.com>
13443
13444 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
13445 * guile/scm-type.c (tyscm_scm_to_type): New function.
13446
13447 2017-03-16 Jiong Wang <jiong.wang@arm.com>
13448
13449 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
13450 "ULONGEST" for "skip".
13451
13452 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
13453
13454 PR gdb/21220
13455 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
13456 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
13457 (inf_ptrace_peek_poke): ...here. New function. Now also loop
13458 over ptrace peek/poke until end of buffer or error.
13459
13460 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
13461
13462 * parse.c (length_of_subexp): Make static.
13463 * parser-defs.h (length_of_subexp): Remove.
13464
13465 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
13466
13467 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
13468 as well.
13469
13470 2017-03-14 Pedro Alves <palves@redhat.com>
13471
13472 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
13473 (main): Use std::unique_ptr. Remove calls to
13474 cp_demangled_name_parse_free.
13475
13476 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13477
13478 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
13479 alphabsd_store_inferior_registers): Use regcache->ptid instead
13480 of inferior_ptid.
13481
13482 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13483
13484 * aix-thread.c (aix_thread_fetch_registers,
13485 aix_thread_store_registers): Use regcache->ptid instead of
13486 inferior_ptid.
13487
13488 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13489
13490 * aarch64-linux-nat.c (fetch_gregs_from_thread,
13491 store_gregs_to_thread, fetch_fpregs_from_thread,
13492 store_fpregs_to_thread): Use regcache->ptid instead of
13493 inferior_ptid.
13494
13495 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13496
13497 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
13498 amd64_linux_fetch_inferior_registers): Use regcache->ptid
13499 instead of inferior_ptid.
13500
13501 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13502
13503 * target.c (target_fetch_registers, target_store_registers): Add
13504 assert.
13505
13506 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13507
13508 * regcache.h (regcache_get_ptid): New function.
13509 * regcache.c (regcache_get_ptid): New function.
13510
13511 2017-03-13 Mark Wielaard <mark@klomp.org>
13512
13513 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
13514
13515 2017-03-10 Keith Seitz <keiths@redhat.com>
13516
13517 PR c++/8218
13518 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
13519
13520 2017-03-08 Pedro Alves <palves@redhat.com>
13521
13522 PR gdb/18360
13523 * infrun.c (start_step_over, do_target_resume, resume)
13524 (restart_threads): Assert we're not resuming a thread that is
13525 meant to be stopped.
13526 (infrun_thread_stop_requested_callback): Delete.
13527 (infrun_thread_stop_requested): If the thread is internally
13528 stopped, queue a pending stop event and clear the thread's
13529 inline-frame state.
13530 (handle_stop_requested): New function.
13531 (handle_syscall_event, handle_inferior_event_1): Use
13532 handle_stop_requested.
13533 (handle_stop_requested): New function.
13534 (handle_signal_stop): Set the thread's stop_signal here instead of
13535 at caller.
13536 (finish_step_over): Clear step over info unconditionally.
13537 (handle_signal_stop): If the user had interrupted the event
13538 thread, consider the stop a random signal.
13539 (handle_signal_stop) <signal arrived while stepping over
13540 breakpoint>: Don't restart threads here.
13541 (stop_waiting): Don't clear step-over info here.
13542
13543 2017-03-08 Pedro Alves <palves@redhat.com>
13544
13545 PR 21206
13546 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
13547 goes to argument 2, not 1.
13548
13549 2017-03-08 Pedro Alves <palves@redhat.com>
13550
13551 PR cli/21218
13552 * top.c (gdb_readline_wrapper): Avoid passing NULL to
13553 display_gdb_prompt.
13554 (command_line_input): Add comment.
13555
13556 2017-03-08 Pedro Alves <palves@redhat.com>
13557
13558 PR tui/21216
13559 * tui/tui-file.c (tui_file::write): New.
13560 * tui/tui-file.h (tui_file): Override "write".
13561 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
13562 factored out from ...
13563 (tui_puts): ... here.
13564 (tui_putc): Use them.
13565 (tui_write): New function.
13566 * tui/tui-io.h (tui_write): Declare.
13567
13568 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
13569
13570 * Makefile.in (SFILES): Replace "environ.c" with
13571 "common/environ.c".
13572 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
13573 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
13574 to...
13575 * common/environ.c: ... here.
13576 * environ.h: Moved to...
13577 * common/environ.h: ... here.
13578
13579 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
13580
13581 * gdbarch.sh (pstring_ptr): New static function.
13582 (gdbarch_disassembler_options): Use it.
13583 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
13584 not valid_disassembler_option->name.
13585 * gdbarch.c: Regenerate.
13586
13587 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
13588
13589 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
13590
13591 2017-03-07 Pedro Alves <palves@redhat.com>
13592
13593 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
13594
13595 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
13596
13597 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
13598 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
13599 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
13600 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
13601
13602 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
13603
13604 * xtensa-linux-nat.c (fetch_gregs): Remove const.
13605
13606 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
13607
13608 * remote.c (remote_add_target_side_commands): Use range-based
13609 for loop.
13610
13611 2017-03-03 Yao Qi <yao.qi@linaro.org>
13612
13613 PR gdb/21165
13614 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
13615 value is lazy.
13616 * valprint.c (common_val_print): Likewise.
13617
13618 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
13619
13620 * NEWS: Mention new set/show disassembler-options commands.
13621 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
13622 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
13623 (prospective_options): New static variable.
13624 (gdb_disassembler::gdb_disassembler): Initialize
13625 m_di.disassembler_options.
13626 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
13627 (get_disassembler_options): New function.
13628 (set_disassembler_options): Likewise.
13629 (set_disassembler_options_sfunc): Likewise.
13630 (show_disassembler_options_sfunc): Likewise.
13631 (disassembler_options_completer): Likewise.
13632 (_initialize_disasm): Likewise.
13633 * disasm.h (get_disassembler_options): New prototype.
13634 (set_disassembler_options): Likewise.
13635 * gdbarch.sh (gdbarch_disassembler_options): New variable.
13636 (gdbarch_verify_disassembler_options): Likewise.
13637 * gdbarch.c: Regenerate.
13638 * gdbarch.h: Likewise.
13639 * arm-tdep.c (num_disassembly_options): Delete.
13640 (set_disassembly_style): Likewise.
13641 (arm_disassembler_options): New static variable.
13642 (set_disassembly_style_sfunc): Convert short style name into long
13643 option name. Call set_disassembler_options.
13644 (show_disassembly_style_sfunc): New function.
13645 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
13646 set_gdbarch_verify_disassembler_options.
13647 (_initialize_arm_tdep): Delete regnames variable and update callers.
13648 (arm_disassembler_options): Initialize.
13649 (disasm_options): New variable.
13650 (num_disassembly_options): Rename from this...
13651 (num_disassembly_styles): ...to this. Compute by scanning through
13652 disasm_options.
13653 (valid_disassembly_styles): Initialize using disasm_options.
13654 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
13655 set_arm_regname_option.
13656 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
13657 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
13658 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
13659 set_gdbarch_verify_disassembler_options.
13660 * s390-tdep.c (s390_disassembler_options): New static variable.
13661 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
13662 set_gdbarch_verify_disassembler_options.
13663
13664 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
13665
13666 * remote.c (remote_add_target_side_condition): Remove "struct"
13667 keyword from range-based for loop.
13668
13669 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
13670
13671 * remote.c (remote_add_target_side_condition): Use range-based
13672 for loop. Update comment.
13673
13674 2017-02-27 Yao Qi <yao.qi@linaro.org>
13675
13676 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
13677
13678 2017-02-26 Alan Hayward <alan.hayward@arm.com>
13679
13680 * regcache.c (regcache_raw_update): New function.
13681 (regcache_raw_read): Move code to regcache_raw_update.
13682 * regcache.h (regcache_raw_update): New declaration.
13683 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
13684
13685 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
13686
13687 * dwarf2read.c (create_debug_type_hash_table): Initialize
13688 header.signature and header.type_offset_in_tu.
13689
13690 2017-02-24 Pedro Alves <palves@redhat.com>
13691
13692 * symtab.c (make_file_symbol_completion_list_1): Use
13693 add_symtab_completions.
13694
13695 2017-02-24 Alan Hayward <alan.hayward@arm.com>
13696
13697 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
13698
13699 2017-02-24 Alan Hayward <alan.hayward@arm.com>
13700
13701 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
13702 I386_MAX_REGISTER_SIZE.
13703 (i386_pseudo_register_write): Likewise.
13704 (i386_process_record): Likewise.
13705 * i387-tdep.c (i387_supply_xsave): Likewise.
13706 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
13707 (store_register): Likewise.
13708
13709 2017-02-23 Pedro Alves <palves@redhat.com>
13710
13711 * ada-lang.c: Include "common/function-view.h".
13712 (ada_iterate_over_symbols): Adjust to use function_view as
13713 callback type.
13714 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
13715 (ada_make_symbol_completion_list): Use a lambda.
13716 (ada_exc_search_name_matches): Delete.
13717 (name_matches_regex): New.
13718 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
13719 * compile/compile-c-support.c: Include "common/function-view.h".
13720 (print_one_macro): Change prototype to accept a ui_file pointer.
13721 (write_macro_definitions): Use a lambda.
13722 * dwarf2read.c: Include "common/function-view.h".
13723 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
13724 (dw2_expand_symtabs_matching): Adjust to use function_view as
13725 callback type.
13726 * language.h: Include "common/function-view.h".
13727 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
13728 function_view as callback type.
13729 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
13730 * linespec.c: Include "common/function-view.h".
13731 (collect_info::add_symbol): New method.
13732 (struct symbol_and_data_callback, iterate_inline_only, struct
13733 symbol_matcher_data, iterate_name_matcher): Delete.
13734 (iterate_over_all_matching_symtabs): Adjust to use function_view
13735 as callback type and lambdas.
13736 (iterate_over_file_blocks): Adjust to use function_view as
13737 callback type.
13738 (decode_compound_collector): Now a class with private fields.
13739 (decode_compound_collector::release_symbols): New method.
13740 (collect_one_symbol): Rename to...
13741 (decode_compound_collector::operator()): ... this and adjust.
13742 (lookup_prefix_sym): decode_compound_collector construction bits
13743 move to decode_compound_collector ctor. Pass the
13744 decode_compound_collector object directly as callback. Remove
13745 cleanups and use decode_compound_collector::release_symbols
13746 instead.
13747 (symtab_collector): Now a class with private fields.
13748 (symtab_collector::release_symtabs): New method.
13749 (add_symtabs_to_list): Rename to...
13750 (symtab_collector::operator()): ... this and adjust.
13751 (collect_symtabs_from_filename): symtab_collector construction
13752 bits move to symtab_collector ctor. Pass the symtab_collector
13753 object directly as callback. Remove cleanups and use
13754 symtab_collector::release_symtabs instead.
13755 (collect_symbols): Delete.
13756 (add_matching_symbols_to_info): Use lambdas.
13757 * macrocmd.c (print_macro_callback): Delete.
13758 (info_macro_command): Use a lambda.
13759 (info_macros_command): Pass print_macro_definition as callable
13760 directly.
13761 (print_one_macro): Remove 'ignore' parameter.
13762 (macro_list_command): Adjust.
13763 * macrotab.c (macro_for_each_data::fn): Now a function_view.
13764 (macro_for_each_data::user_data): Delete field.
13765 (foreach_macro): Adjust to call the function_view.
13766 (macro_for_each): Adjust to use function_view as callback type.
13767 (foreach_macro_in_scope): Adjust to call the function_view.
13768 (macro_for_each_in_scope): Adjust to use function_view as callback
13769 type.
13770 * macrotab.h: Include "common/function-view.h".
13771 (macro_callback_fn): Declare a prototype instead of a pointer.
13772 Remove "user_data" parameter.
13773 (macro_for_each, macro_for_each_in_scope): Adjust to use
13774 function_view as callback type.
13775 * psymtab.c (partial_map_expand_apply)
13776 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
13777 Adjust to use function_view as callback type and to return bool.
13778 (psym_expand_symtabs_matching): Adjust to use function_view as
13779 callback types.
13780 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
13781 to use function_view as callback type and to return bool.
13782 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
13783 callback types.
13784 * symfile.c (expand_symtabs_matching): Adjust to use function_view
13785 as callback types.
13786 * symfile.h: Include "common/function-view.h".
13787 (expand_symtabs_file_matcher_ftype)
13788 (expand_symtabs_symbol_matcher_ftype)
13789 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
13790 return bool.
13791 (quick_symbol_functions::map_symtabs_matching_filename)
13792 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
13793 function_view as callback type and return bool.
13794 (expand_symtabs_matching): Adjust to use function_view as callback
13795 type.
13796 (maintenance_expand_name_matcher)
13797 (maintenance_expand_file_matcher): Delete.
13798 (maintenance_expand_symtabs): Use lambdas.
13799 * symtab.c (iterate_over_some_symtabs): Adjust to use
13800 function_view as callback types and return bool.
13801 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
13802 of a cleanup.
13803 (lookup_symtab_callback): Delete.
13804 (lookup_symtab): Use a lambda.
13805 (iterate_over_symbols): Adjust to use function_view as callback
13806 type.
13807 (struct search_symbols_data, search_symbols_file_matches)
13808 (search_symbols_name_matches): Delete.
13809 (search_symbols): Use a pair of lambdas.
13810 (struct add_name_data, add_macro_name, symbol_completion_matcher)
13811 (symtab_expansion_callback): Delete.
13812 (default_make_symbol_completion_list_break_on_1): Use lambdas.
13813 * symtab.h: Include "common/function-view.h".
13814 (iterate_over_some_symtabs): Adjust to use function_view as
13815 callback type and return bool.
13816 (iterate_over_symtabs): Adjust to use function_view as callback
13817 type.
13818 (symbol_found_callback_ftype): Remove 'data' parameter and return
13819 bool.
13820 (iterate_over_symbols): Adjust to use function_view as callback
13821 type.
13822
13823 2017-02-23 Pedro Alves <palves@redhat.com>
13824
13825 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
13826 (%.o) <unittests/%.c>: New pattern.
13827 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
13828 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
13829 * common/function-view.h: New file.
13830 * unittests/function-view-selftests.c: New file.
13831 * configure: Regenerate.
13832
13833 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
13834
13835 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
13836 inferior_ptid.
13837 * go32-nat.c (go32_thread_alive): Likewise.
13838
13839 2017-02-23 Yao Qi <yao.qi@linaro.org>
13840
13841 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
13842 delete.
13843
13844 2017-02-23 Yao Qi <yao.qi@linaro.org>
13845
13846 * varobj.c (varobj_clear_saved_item): Use delete instead of
13847 xfree.
13848 (update_dynamic_varobj_children): Likewise.
13849
13850 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13851
13852 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
13853
13854 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
13855
13856 * common/enum-flags.h (enum_flags::enum_flags): Initialize
13857 m_enum_value to 0 in default constructor.
13858
13859 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
13860
13861 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
13862 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
13863 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
13864 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
13865 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
13866 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
13867 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
13868 IS_STORE_CONDITIONAL_INSN.
13869
13870 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13871
13872 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
13873
13874 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13875
13876 * NEWS (Changes since GDB 7.12): Add DWARF-5.
13877
13878 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13879
13880 * dwarf2read.c (skip_one_die, read_attribute_value)
13881 (dwarf2_const_value_attr, dump_die_shallow)
13882 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
13883 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
13884
13885 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13886
13887 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
13888 (dwarf_parse_macro_header): Accept DWARF version 5.
13889 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
13890
13891 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13892
13893 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
13894 DW_AT_GNU_*.
13895 * common/common-exceptions.h (enum errors): Likewise.
13896 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
13897 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
13898 (dwarf_expr_context::execute_stack_op): Likewise.
13899 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
13900 Likewise.
13901 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
13902 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
13903 (show_entry_values_debug, call_site_to_target_addr)
13904 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
13905 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
13906 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
13907 (value_of_dwarf_block_entry, indirect_pieced_value)
13908 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
13909 (disassemble_dwarf_expression): Likewise.
13910 * dwarf2read.c (process_die, inherit_abstract_dies)
13911 (read_call_site_scope): Likewise.
13912 * gdbtypes.h (struct func_type, struct call_site_parameter)
13913 (struct call_site): Likewise.
13914 * stack.c (read_frame_arg): Likewise.
13915 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
13916
13917 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13918
13919 * defs.h (read_unsigned_leb128): New declaration.
13920 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
13921 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
13922 (dwarf2_find_location_expression): Call also
13923 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
13924 * dwarf2loc.h (dwarf2_version): New declaration.
13925 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
13926 rnglists.
13927 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
13928 .debug_rnglists.
13929 (struct dwop_section_names): Add loclists_dwo.
13930 (dwop_section_names): Add .debug_loclists.dwo.
13931 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
13932 (struct dwarf2_per_cu_data): Add dwarf_version.
13933 (struct dwo_sections): Add loclists.
13934 (struct attr_abbrev): Add implicit_const.
13935 (read_indirect_line_string): New declaration.
13936 (read_unsigned_leb128): Delete declaration.
13937 (rcuh_kind): New definition.
13938 (read_and_check_comp_unit_head): Change parameter
13939 is_debug_types_section to section_kind.
13940 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
13941 (read_comp_unit_head): Change parameter abfd to section, add parameter
13942 section_kind. Handle DWARF-5.
13943 (error_check_comp_unit_head): Accept also DWARF version 5.
13944 (read_and_check_comp_unit_head): Change parameter
13945 is_debug_types_section to section_kind.
13946 (read_and_check_type_unit_head): Delete function.
13947 (read_abbrev_offset): Handle DWARF-5.
13948 (create_debug_type_hash_table): Add parameter section_kind. Process
13949 only DW_UT_type. Use signature and type_offset_in_tu from struct
13950 comp_unit_head.
13951 (create_debug_types_hash_table): Update create_debug_type_hash_table
13952 caller.
13953 (create_all_type_units): Call create_debug_type_hash_table.
13954 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
13955 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
13956 caller.
13957 (skip_one_die): Handle DW_FORM_implicit_const.
13958 (dwarf2_rnglists_process): New function.
13959 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
13960 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
13961 (read_attribute_value): Handle DW_FORM_implicit_const,
13962 DW_FORM_line_strp.
13963 (read_attribute): Handle DW_FORM_implicit_const.
13964 (read_indirect_string_at_offset_from): New function from
13965 read_indirect_string_at_offset.
13966 (read_indirect_string_at_offset): Call
13967 read_indirect_string_at_offset_from.
13968 (read_indirect_line_string_at_offset): New function.
13969 (read_indirect_string): New function comment.
13970 (read_indirect_line_string): New function.
13971 (read_unsigned_leb128): Make it global.
13972 (dwarf2_string_attr): Handle DWARF-5.
13973 (add_include_dir_stub, read_formatted_entries): New functions.
13974 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
13975 Handle DWARF-5.
13976 (per_cu_header_read_in): Update read_comp_unit_head caller.
13977 (dwarf2_version): New function.
13978 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
13979 rnglists.
13980 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
13981 fields.
13982
13983 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13984
13985 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
13986
13987 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13988
13989 * dwarf2read.c (dwarf2_ranges_process): New function from
13990 dwarf2_ranges_read.
13991 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
13992 dwarf2_ranges_process.
13993
13994 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13995
13996 * dwarf2read.c (create_debug_type_hash_table): New function from
13997 create_debug_types_hash_table.
13998 (create_debug_types_hash_table): Call create_debug_type_hash_table.
13999 (create_all_type_units, open_and_init_dwo_file): Update
14000 create_debug_types_hash_table callers.
14001
14002 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
14003
14004 PR gdb/16188
14005 * fork-child.c (trace_start_error): Fix thinko. va_end should
14006 refer to 'ap', not 'args'.
14007
14008 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
14009 Pedro Alves <palves@redhat.com>
14010
14011 PR gdb/16188
14012 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
14013 calls succeeded.
14014 * fork-child.c (trace_start_error): New function.
14015 (trace_start_error_with_name): Likewise.
14016 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
14017 * inf-ptrace.c (inf_ptrace_me): Likewise.
14018 * inferior.h (trace_start_error): New prototype.
14019 (trace_start_error_with_name): Likewise.
14020
14021 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
14022
14023 PR gdb/21164
14024 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
14025 NULL before using it.
14026 * symmisc.c (maintenance_print_symbols): Likewise.
14027 (maintenance_print_msymbols): Likewise.
14028
14029 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14030
14031 * NEWS: Add record Python bindings entry.
14032
14033 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14034
14035 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
14036 py-record-full.o.
14037 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
14038 * python/py-record-btrace.c, python/py-record-btrace.h,
14039 python/py-record-full.c, python/py-record-full.h: New file.
14040 * python/py-record.c: Add include for py-record-btrace.h and
14041 py-record-full.h.
14042 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
14043 recpy_instruction_history, recpy_function_call_history, recpy_begin,
14044 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
14045 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
14046 New definition.
14047 (gdbpy_initialize_btrace): New export.
14048 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
14049
14050 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14051
14052 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
14053 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
14054 * python/py-record.c: New file.
14055 * python/python-internal.h (gdbpy_start_recording,
14056 gdbpy_current_recording, gdpy_stop_recording,
14057 gdbpy_initialize_record): New export.
14058 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
14059 (python_GdbMethods): Add gdbpy_start_recording,
14060 gdbpy_current_recording and gdbpy_stop_recording.
14061
14062 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14063
14064 * record-btrace.c (record_btrace_record_method): New function.
14065 (init_record_btrace_ops): Initialize to_record_method.
14066 * record-full.c (record_full_record_method): New function.
14067 (init_record_full_ops, init_record_full_core_ops): Add
14068 record_full_record_method.
14069 * record.h (enum record_method): New enum.
14070 * target-debug.h (target_debug_print_enum_record_method: New define.
14071 * target-delegates.c: Regenerate.
14072 * target.c (target_record_method): New function.
14073 * target.h: Include record.h.
14074 (struct target_ops) <to_record_method>: New field.
14075 (target_record_method): New export.
14076
14077 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14078
14079 * record.h (record_start, record_stop): New export.
14080 * record.c (record_start, record_stop): New function.
14081
14082 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14083
14084 * btrace.c (btrace_fetch): Copy function call segments pointer
14085 into a vector.
14086 (btrace_clear): Clear the vector.
14087 (btrace_find_insn_by_number): Use binary search to find the correct
14088 function call segment.
14089 * btrace.h (brace_fun_p): New typedef.
14090 (struct btrace_thread_info) <functions>: New field.
14091
14092 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14093
14094 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
14095 * btrace.c (btrace_decode_error): ... here. New function.
14096 * btrace.h (btrace_decode_error): New export.
14097
14098 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14099
14100 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
14101 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
14102 btrace_find_insn_by_number): Remove special case for gaps.
14103 * btrace.h (btrace_insn_get_error): New export.
14104 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
14105 * record-btrace.c (btrace_insn_history): Print number for gaps.
14106 (record_btrace_info, record_btrace_goto): Handle gaps.
14107
14108 2017-02-14 Tom Tromey <tom@tromey.com>
14109
14110 PR python/13598:
14111 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
14112 event.
14113 * python/py-evts.c (gdbpy_initialize_py_events): Add
14114 before_prompt registry.
14115 * python/py-events.h (events_object) <before_prompt>: New field.
14116
14117 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
14118
14119 * btrace.c (ftrace_new_switch): Preserve up link and flags.
14120
14121 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
14122
14123 * symfile (_initialize_symfile): Add usage text to the load command's
14124 help text.
14125
14126 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
14127
14128 * utils.c (defaulted_query): Don't query on secondary UIs.
14129
14130 2017-02-10 Tom Tromey <tom@tromey.com>
14131
14132 * rust-lang.c (rust_get_disr_info): Remove unused variable.
14133
14134 2017-02-10 Tom Tromey <tom@tromey.com>
14135
14136 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
14137 "cleanup" local.
14138 * python/py-type.c (typy_legacy_template_argument): Remove
14139 unnecessary "cleanup" local.
14140
14141 2017-02-10 Tom Tromey <tom@tromey.com>
14142
14143 * python/python.c (do_start_initialization): New function, from
14144 _initialize_python.
14145 (_initialize_python): Call do_start_initialization.
14146 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
14147 goto.
14148
14149 2017-02-10 Tom Tromey <tom@tromey.com>
14150
14151 * python/py-prettyprint.c (pretty_print_one_value): Use
14152 gdbpy_ref.
14153
14154 2017-02-10 Tom Tromey <tom@tromey.com>
14155
14156 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
14157 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
14158 gdbpy_ref.
14159 * python/py-type.c (field_new): Use gdbpy_ref.
14160 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
14161 gdbpy_ref.
14162 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
14163 (py_free_pspace): Likewise.
14164 (pspace_to_pspace_object): Likewise.
14165 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
14166 (py_free_objfile): Likewise.
14167 (objfile_to_objfile_object): Likewise.
14168 * python/py-inferior.c (delete_thread_object): Use
14169 gdbpy_ref.
14170 (infpy_read_memory): Likewise.
14171 (py_free_inferior): Likewise.
14172 * python/py-evtregistry.c (create_eventregistry_object): Use
14173 gdbpy_ref.
14174 * python/py-event.c (create_event_object): Use gdbpy_ref.
14175
14176 2017-02-10 Tom Tromey <tom@tromey.com>
14177
14178 * python/py-ref.h (gdbpy_ref_policy): Now a template.
14179 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
14180 used.
14181 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
14182 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
14183 python/py-exitedevent.c, python/py-finishbreakpoint.c,
14184 python/py-framefilter.c, python/py-function.c,
14185 python/py-inferior.c, python/py-infevents.c,
14186 python/py-linetable.c, python/py-newobjfileevent.c,
14187 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
14188 python/py-signalevent.c, python/py-stopevent.c,
14189 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
14190 python/py-unwind.c, python/py-utils.c, python/py-value.c,
14191 python/py-varobj.c, python/py-xmethods.c, python/python.c,
14192 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
14193
14194 2017-02-10 Tom Tromey <tom@tromey.com>
14195
14196 * ui-out.h (ui_out_emit_type): New class.
14197 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
14198 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
14199 and ui_out_emit_tuple.
14200 (enumerate_locals): Likewise.
14201 (py_mi_print_variables, py_print_locals, py_print_args): Use
14202 ui_out_emit_list.
14203 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
14204 ui_out_emit_list.
14205 * common/gdb_optional.h: New file.
14206
14207 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
14208
14209 * MAINTAINERS (Write After Approval): Update my e-mail address.
14210
14211 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
14212
14213 PR gdb/21122
14214 * breakpoint.c (_initialize_breakpoint): Update the help description
14215 of the 'commands' command to indicate that it takes a list argument.
14216
14217 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
14218
14219 * interps.c (current_interp_set_logging): Remove "return".
14220
14221 2017-02-09 Gary Benson <gbenson@redhat.com>
14222
14223 * symtab.c (add_symtab_completions): Prevent NULL pointer
14224 dereference.
14225
14226 2017-02-08 Pedro Alves <palves@redhat.com>
14227
14228 * interps.c (interp::interp): Remove reference to quiet_p.
14229 (interp_set): Make static. Remove dead "Switching to" output
14230 code.
14231 (interp_quiet_p, interp_set_quiet): Delete.
14232 (interpreter_exec_cmd): Don't set the interpreter quiet.
14233 * interps.h (interp_quiet_p): Make static.
14234 (class interp) <quiet_p>: Remove field
14235
14236 2017-02-08 Jerome Guitton <guitton@adacore.com>
14237
14238 * cli/cli-decode.c (find_command_name_length): Make it extern.
14239 * cli/cli-decode.h (find_command_name_length): Declare.
14240 * cli/cli-script.c (command_name_equals, line_first_arg):
14241 New functions.
14242 (process_next_line): Use cli-decode to parse command names.
14243 (build_command_line): Make args a constant pointer.
14244
14245 2017-02-08 Jerome Guitton <guitton@adacore.com>
14246
14247 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
14248 Remove case-insensitive search.
14249
14250 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
14251
14252 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
14253 at the end of the line. Avoids an ARI warning.
14254
14255 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
14256
14257 * NEWS: Mention support for record/replay of Intel 64 rdrand and
14258 rdseed instructions.
14259 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
14260
14261 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
14262
14263 PR tdep/20936
14264 Provide and use sparc32 and sparc64 target description XML files.
14265 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
14266 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
14267 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
14268 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
14269 * features/sparc/sparc32-solaris.xml: New file.
14270 * features/sparc/sparc64-solaris.xml: New file.
14271 * features/sparc/sparc32-solaris.c: Generated.
14272 * features/sparc/sparc64-solaris.c: Generated.
14273 * sparc-tdep.h: Account for differences in target descriptions.
14274 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
14275 (sparc32_register_type): Use target provided registers.
14276 (validate_tdesc_registers): New function.
14277 (sparc32_gdbarch_init): Use tdesc_has_registers.
14278 Set pseudoregister functions.
14279 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
14280 (sparc64_register_type): Use target provided registers.
14281 (sparc64_init_abi): Set pseudoregister functions.
14282
14283 2017-02-03 Tom Tromey <tom@tromey.com>
14284
14285 PR rust/21097:
14286 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
14287 with a single member.
14288
14289 2017-02-03 Pedro Alves <palves@redhat.com>
14290
14291 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
14292 (cli_interp_base::~cli_interp_base): New.
14293 (cli_interp): New struct.
14294 (as_cli_interp): Cast the interp itself to cli_interp.
14295 (cli_interpreter_pre_command_loop): Rename to ...
14296 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
14297 parameter.
14298 (cli_interpreter_init): Rename to ...
14299 (cli_interp::init): ... this. Remove 'self' parameter. Use
14300 boolean. Make extern.
14301 (cli_interpreter_resume): Rename to ...
14302 (cli_interp::resume): ... this. Remove 'data' parameter. Make
14303 extern.
14304 (cli_interpreter_suspend): Rename to ...
14305 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
14306 extern.
14307 (cli_interpreter_exec): Rename to ...
14308 (cli_interp::exec): ... this. Remove 'data' parameter. Make
14309 extern.
14310 (cli_interpreter_supports_command_editing): Rename to ...
14311 (cli_interp_base::supports_command_editing): ... this. Remove
14312 'interp' parameter. Make extern.
14313 (cli_ui_out): Rename to ...
14314 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
14315 Make extern.
14316 (cli_set_logging): Rename to ...
14317 (cli_interp_base::set_logging): ... this. Remove 'interp'
14318 parameter. Make extern.
14319 (cli_interp_procs): Delete.
14320 (cli_interp_factory): Adjust to use "new".
14321 * cli/cli-interp.h: Include "interps.h".
14322 (struct cli_interp_base): New struct.
14323 * interps.c (struct interp): Delete. Fields moved to interps.h.
14324 (interp_new): Delete.
14325 (interp::interp, interp::~interp): New.
14326 (interp_set): Use bool, and return void. Assume the interpreter
14327 has suspend, init and resume methods, and that the all return
14328 void.
14329 (set_top_level_interpreter): interp_set returns void.
14330 (interp_ui_out): Adapt.
14331 (current_interp_set_logging): Adapt.
14332 (interp_data): Delete.
14333 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
14334 (interp_exec): Adapt.
14335 (top_level_interpreter_data): Delete.
14336 * interps.h (interp_init_ftype, interp_resume_ftype)
14337 (interp_suspend_ftype, interp_exec_ftype)
14338 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
14339 (class interp): New.
14340 (interp_new): Delete.
14341 (interp_set): Now returns void. Use bool.
14342 (interp_data, top_level_interpreter_data): Delete.
14343 * mi/mi-common.h: Include interps.h.
14344 (class mi_interp): Inherit from interp. Define a ctor. Declare
14345 init, resume, suspect, exec, interp_ui_out, set_logging and
14346 pre_command_loop methods.
14347 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
14348 (mi_interpreter_init): Rename to ...
14349 (mi_interp::init): ... this. Remove the 'interp' parameter, use
14350 bool, return void and make extern. Adjust.
14351 (mi_interpreter_resume): ... Rename to ...
14352 (mi_interp::resume): ... this. Remove the 'data' parameter,
14353 return void and make extern. Adjust.
14354 (mi_interpreter_suspend): ... Rename to ...
14355 (mi_interp::suspend): ... this. Remove the 'data' parameter,
14356 return void and make extern. Adjust.
14357 (mi_interpreter_exec): ... Rename to ...
14358 (mi_interp::exec): ... this. Remove the 'data' parameter and make
14359 extern. Adjust.
14360 (mi_interpreter_pre_command_loop): ... Rename to ...
14361 (mi_interp::pre_command_loop): ... this. Remove the 'self'
14362 parameter and make extern.
14363 (mi_on_normal_stop_1): Adjust.
14364 (mi_ui_out): Rename to ...
14365 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
14366 parameter and make extern. Adjust.
14367 (mi_set_logging): Rename to ...
14368 (mi_interp::set_logging): ... this. Remove the 'interp'
14369 parameter and make extern. Adjust.
14370 (mi_interp_procs): Delete.
14371 (mi_interp_factory): Adjust to use 'new'.
14372 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
14373 (mi_print_exception, mi_execute_command, mi_load_progress):
14374 Adjust.
14375 * tui/tui-interp.c (tui_interp): New class.
14376 (as_tui_interp): Return a tui_interp pointer.
14377 (tui_on_normal_stop, tui_on_signal_received)
14378 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
14379 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
14380 to use interp::interp_ui_out.
14381 (tui_init): Rename to ...
14382 (tui_interp::init): ... this. Remove the 'self' parameter, use
14383 bool, return void and make extern. Adjust.
14384 (tui_resume): Rename to ...
14385 (tui_interp::resume): ... this. Remove the 'data' parameter,
14386 return void and make extern. Adjust.
14387 (tui_suspend): Rename to ...
14388 (tui_interp::suspend): ... this. Remove the 'data' parameter,
14389 return void and make extern. Adjust.
14390 (tui_ui_out): Rename to ...
14391 (tui_interp::interp_ui_out): ... this. Remove the 'self'
14392 parameter, and make extern. Adjust.
14393 (tui_exec): Rename to ...
14394 (tui_interp::exec): ... this. Remove the 'data' parameter and
14395 make extern.
14396 (tui_interp_procs): Delete.
14397 (tui_interp_factory): Use "new".
14398
14399 2017-02-02 Tom Tromey <tom@tromey.com>
14400
14401 * rust-exp.y (ends_raw_string, space_then_number)
14402 (rust_identifier_start_p): Return bool.
14403 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
14404 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
14405 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
14406 (rust_chartype_p): Return bool.
14407 (val_print_struct, rust_print_struct_def, rust_print_type):
14408 Update.
14409 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
14410 Return bool.
14411
14412 2017-02-02 Tom Tromey <tom@tromey.com>
14413
14414 * rust-lang.c: Reindent.
14415
14416 2017-02-02 Tom Tromey <tom@tromey.com>
14417
14418 * rust-lang.h (rust_crate_for_block): Update.
14419 * rust-lang.c (rust_crate_for_block): Return std::string.
14420 (rust_get_disr_info): Use std:;string, not
14421 gdb::unique_xmalloc_ptr.
14422 * rust-exp.y (crate_name): Update.
14423
14424 2017-02-02 Pedro Alves <palves@redhat.com>
14425
14426 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
14427 field out of gdb_disassembler_test and make it static.
14428
14429 2017-02-02 Pedro Alves <palves@redhat.com>
14430
14431 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
14432 mi1_interp and mi_interp fields.
14433
14434 2017-02-02 Pedro Alves <palves@redhat.com>
14435
14436 * cli/cli-interp.c (struct saved_output_files, saved_output):
14437 Moved from cli/cli-logging.c.
14438 (cli_set_logging): New function.
14439 (cli_interp_procs): Install cli_set_logging.
14440 * cli/cli-interp.h (make_logging_output, cli_set_logging):
14441 Declare.
14442 * cli/cli-logging.c (struct saved_output_files, saved_output):
14443 Moved to cli/cli-interp.c.
14444 (pop_output_files): Don't save outputs here.
14445 (make_logging_output): New function.
14446 (handle_redirections): Don't build tee nor save previous outputs
14447 here.
14448 * interps.c (current_interp_set_logging): Change prototype.
14449 Assume there's always a set_logging_proc method installed.
14450 * interps.h (interp_set_logging_ftype): Change prototype.
14451 (current_interp_set_logging): Change prototype and adjust comment.
14452 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
14453 use make_logging_output.
14454 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
14455 2017-02-02 Pedro Alves <palves@redhat.com>
14456
14457 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
14458 from ...
14459 (set_logging_overwrite): ... here.
14460 (logging_no_redirect_file): Delete.
14461 (set_logging_redirect): Don't handle redirection on the fly.
14462 Instead warn that "logging off" / "logging on" is necessary.
14463 (pop_output_files): Delete references to logging_no_redirect_file.
14464 (show_logging_command): Always speak in terms of what will happen
14465 once logging is reenabled.
14466
14467 2017-02-02 Pedro Alves <palves@redhat.com>
14468
14469 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
14470
14471 2017-02-02 Pedro Alves <palves@redhat.com>
14472
14473 * disasm.c (gdb_pretty_print_insn): Rename to ...
14474 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
14475 Remove gdbarch parameter. Adapt to clear the object's buffers
14476 instead of allocating new buffers, and to print using the object's
14477 gdb_disassembler instead of calling gdb_print_insn.
14478 (dump_insns): Use gdb_pretty_print_disassembler.
14479 * disasm.h (gdb_pretty_print_insn): Delete declaration.
14480 (gdb_pretty_print_disassembler): New class.
14481 * record-btrace.c (btrace_insn_history): Use
14482 gdb_pretty_print_disassembler.
14483
14484 2017-02-02 Pedro Alves <palves@redhat.com>
14485
14486 * ada-lang.c (type_as_string): Use string_file.
14487 * ada-valprint.c (ada_print_floating): Use string_file.
14488 * ada-varobj.c (ada_varobj_scalar_image)
14489 (ada_varobj_get_value_image): Use string_file.
14490 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
14491 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
14492 * breakpoint.c (update_inserted_breakpoint_locations)
14493 (insert_breakpoint_locations, reattach_breakpoints)
14494 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
14495 (print_it_watchpoint): Use string_file.
14496 (save_breakpoints): Use stdio_file.
14497 * c-exp.y (oper): Use string_file.
14498 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
14499 tee_file.
14500 (pop_output_files): Use delete.
14501 (handle_redirections): Use stdio_file and tee_file.
14502 * cli/cli-setshow.c (do_show_command): Use string_file.
14503 * compile/compile-c-support.c (c_compute_program): Use
14504 string_file.
14505 * compile/compile-c-symbols.c (generate_vla_size): Take a
14506 'string_file &' instead of a 'ui_file *'.
14507 (generate_c_for_for_one_variable): Take a 'string_file &' instead
14508 of a 'ui_file *'. Use string_file.
14509 (generate_c_for_variable_locations): Take a 'string_file &'
14510 instead of a 'ui_file *'.
14511 * compile/compile-internal.h (generate_c_for_for_one_variable):
14512 Take a 'string_file &' instead of a 'ui_file *'.
14513 * compile/compile-loc2c.c (push, pushf, unary, binary)
14514 (print_label, pushf_register_address, pushf_register)
14515 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
14516 'ui_file *'. Adjust.
14517 * compile/compile.c (compile_to_object): Use string_file.
14518 * compile/compile.h (compile_dwarf_expr_to_c)
14519 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
14520 'ui_file *'.
14521 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
14522 (replace_typedefs_qualified_name): Use string_file and
14523 obstack_copy0.
14524 * disasm.c (gdb_pretty_print_insn): Use string_file.
14525 (gdb_disassembly): Adjust reference the null_stream global.
14526 (do_ui_file_delete): Delete.
14527 (gdb_insn_length): Use null_stream.
14528 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
14529 * dwarf2loc.c (dwarf2_compile_property_to_c)
14530 (locexpr_generate_c_location, loclist_generate_c_location): Take a
14531 'string_file &' instead of a 'ui_file *'.
14532 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
14533 * dwarf2read.c (do_ui_file_peek_last): Delete.
14534 (dwarf2_compute_name): Use string_file.
14535 * event-top.c (gdb_setup_readline): Use stdio_file.
14536 * gdbarch.sh (verify_gdbarch): Use string_file.
14537 * gdbtypes.c (safe_parse_type): Use null_stream.
14538 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
14539 string_file.
14540 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
14541 'string_file *' instead of a 'ui_file *'.
14542 (gdbscm_arch_disassemble): Use string_file.
14543 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
14544 * guile/scm-ports.c (class ioscm_file_port): Now a class that
14545 inherits from ui_file.
14546 (ioscm_file_port_delete, ioscm_file_port_rewind)
14547 (ioscm_file_port_put): Delete.
14548 (ioscm_file_port_write): Rename to ...
14549 (ioscm_file_port::write): ... this. Remove file_port_magic
14550 checks.
14551 (ioscm_file_port_new): Delete.
14552 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
14553 ui_file_up.
14554 * guile/scm-type.c (tyscm_type_name): Use string_file.
14555 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
14556 Use string_file.
14557 * infcmd.c (print_return_value_1): Use string_file.
14558 * infrun.c (print_target_wait_results): Use string_file.
14559 * language.c (add_language): Use string_file.
14560 * location.c (explicit_to_string_internal): Use string_file.
14561 * main.c (captured_main_1): Use null_file.
14562 * maint.c (maintenance_print_architecture): Use stdio_file.
14563 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
14564 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
14565 event_channel>: Change type to mi_console_file pointer.
14566 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
14567 (mi_console_file_delete): Delete.
14568 (struct mi_console_file): Delete.
14569 (mi_console_file_magic): Delete.
14570 (mi_console_file_new): Delete.
14571 (mi_console_file::mi_console_file): New.
14572 (mi_console_file_delete): Delete.
14573 (mi_console_file_fputs): Delete.
14574 (mi_console_file::write): New.
14575 (mi_console_raw_packet): Delete.
14576 (mi_console_file::flush): New.
14577 (mi_console_file_flush): Delete.
14578 (mi_console_set_raw): Rename to ...
14579 (mi_console_file::set_raw): ... this.
14580 * mi/mi-console.h (class mi_console_file): New class.
14581 (mi_console_file_new, mi_console_set_raw): Delete.
14582 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
14583 (mi_set_logging): Use delete and tee_file. Adjust.
14584 * mi/mi-main.c (output_register): Use string_file.
14585 (mi_cmd_data_evaluate_expression): Use string_file.
14586 (mi_cmd_data_read_memory): Use string_file.
14587 (mi_cmd_execute, print_variable_or_computed): Use string_file.
14588 * mi/mi-out.c (mi_ui_out::main_stream): New.
14589 (mi_ui_out::rewind): Use main_stream and
14590 string_file.
14591 (mi_ui_out::put): Use main_stream and string_file.
14592 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
14593 Allocate a 'string_file' instead.
14594 (mi_out_new): Don't allocate a mem_fileopen stream here.
14595 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
14596 (mi_ui_out::main_stream): Declare method.
14597 * printcmd.c (eval_command): Use string_file.
14598 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
14599 * python/py-arch.c (archpy_disassemble): Use string_file.
14600 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
14601 * python/py-frame.c (frapy_str): Use string_file.
14602 * python/py-framefilter.c (py_print_type, py_print_single_arg):
14603 Use string_file.
14604 * python/py-type.c (typy_str): Use string_file.
14605 * python/py-unwind.c (unwind_infopy_str): Use string_file.
14606 * python/py-value.c (valpy_str): Use string_file.
14607 * record-btrace.c (btrace_insn_history): Use string_file.
14608 * regcache.c (regcache_print): Use stdio_file.
14609 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
14610 * remote.c (escape_buffer): Use string_file.
14611 * rust-lang.c (rust_get_disr_info): Use string_file.
14612 * serial.c (serial_open_ops_1): Use stdio_file.
14613 (do_serial_close): Use delete.
14614 * stack.c (print_frame_arg): Use string_file.
14615 (print_frame_args): Remove local mem_fileopen stream, not used.
14616 (print_frame): Use string_file.
14617 * symmisc.c (maintenance_print_symbols): Use stdio_file.
14618 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
14619 Take a 'string_file *' instead of a 'ui_file *'.
14620 * top.c (new_ui): Use stdio_file and stderr_file.
14621 (free_ui): Use delete.
14622 (execute_command_to_string): Use string_file.
14623 (quit_confirm): Use string_file.
14624 * tracepoint.c (collection_list::append_exp): Use string_file.
14625 * tui/tui-disasm.c (tui_disassemble): Use string_file.
14626 * tui/tui-file.c: Don't include "ui-file.h".
14627 (enum streamtype, struct tui_stream): Delete.
14628 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
14629 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
14630 (tui_file::tui_file): New method.
14631 (tui_file_fputs): Delete.
14632 (tui_file_get_strbuf): Delete.
14633 (tui_file::puts): New method.
14634 (tui_file_adjust_strbuf): Delete.
14635 (tui_file_flush): Delete.
14636 (tui_file::flush): New method.
14637 * tui/tui-file.h: Tweak intro comment.
14638 Include ui-file.h.
14639 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
14640 (tui_file_adjust_strbuf): Delete declarations.
14641 (class tui_file): New class.
14642 * tui/tui-io.c (tui_initialize_io): Use tui_file.
14643 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
14644 (tui_register_format): Use string_stream.
14645 * tui/tui-stack.c (tui_make_status_line): Use string_file.
14646 (tui_get_function_from_frame): Use string_file.
14647 * typeprint.c (type_to_string): Use string_file.
14648 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
14649 (null_stream): New global.
14650 (ui_file_delete): Delete.
14651 (ui_file::ui_file): New.
14652 (null_file_isatty): Delete.
14653 (ui_file::~ui_file): New.
14654 (null_file_rewind): Delete.
14655 (ui_file::printf): New.
14656 (null_file_put): Delete.
14657 (null_file_flush): Delete.
14658 (ui_file::putstr): New.
14659 (null_file_write): Delete.
14660 (ui_file::putstrn): New.
14661 (null_file_read): Delete.
14662 (ui_file::putc): New.
14663 (null_file_fputs): Delete.
14664 (null_file_write_async_safe): Delete.
14665 (ui_file::vprintf): New.
14666 (null_file_delete): Delete.
14667 (null_file::write): New.
14668 (null_file_fseek): Delete.
14669 (null_file::puts): New.
14670 (ui_file_data): Delete.
14671 (null_file::write_async_safe): New.
14672 (gdb_flush, ui_file_isatty): Adjust.
14673 (ui_file_put, ui_file_rewind): Delete.
14674 (ui_file_write): Adjust.
14675 (ui_file_write_for_put): Delete.
14676 (ui_file_write_async_safe, ui_file_read): Adjust.
14677 (ui_file_fseek): Delete.
14678 (fputs_unfiltered): Adjust.
14679 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
14680 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
14681 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
14682 (set_ui_file_data): Delete.
14683 (string_file::~string_file, string_file::write)
14684 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
14685 (do_ui_file_as_string, ui_file_as_string): Delete.
14686 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
14687 (struct mem_file): Delete.
14688 (mem_file_new): Delete.
14689 (stdio_file::stdio_file): New.
14690 (mem_file_delete): Delete.
14691 (stdio_file::stdio_file): New.
14692 (mem_fileopen): Delete.
14693 (stdio_file::~stdio_file): New.
14694 (mem_file_rewind): Delete.
14695 (stdio_file::set_stream): New.
14696 (mem_file_put): Delete.
14697 (stdio_file::open): New.
14698 (mem_file_write): Delete.
14699 (stdio_file_magic, struct stdio_file): Delete.
14700 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
14701 (stdio_file::flush): New.
14702 (stdio_file_read): Rename to ...
14703 (stdio_file::read): ... this. Adjust.
14704 (stdio_file_write): Rename to ...
14705 (stdio_file::write): ... this. Adjust.
14706 (stdio_file_write_async_safe): Rename to ...
14707 (stdio_file::write_async_safe) ... this. Adjust.
14708 (stdio_file_fputs): Rename to ...
14709 (stdio_file::puts) ... this. Adjust.
14710 (stdio_file_isatty): Delete.
14711 (stdio_file_fseek): Delete.
14712 (stdio_file::isatty): New.
14713 (stderr_file_write): Rename to ...
14714 (stderr_file::write) ... this. Adjust.
14715 (stderr_file_fputs): Rename to ...
14716 (stderr_file::puts) ... this. Adjust.
14717 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
14718 (stderr_file::stderr_file): New.
14719 (tee_file_magic): Delete.
14720 (struct tee_file): Delete.
14721 (tee_file::tee_file): New.
14722 (tee_file_new): Delete.
14723 (tee_file::~tee_file): New.
14724 (tee_file_delete): Delete.
14725 (tee_file_flush): Rename to ...
14726 (tee_file::flush): ... this. Adjust.
14727 (tee_file_write): Rename to ...
14728 (tee_file::write): ... this. Adjust.
14729 (tee_file::write_async_safe): New.
14730 (tee_file_fputs): Rename to ...
14731 (tee_file::puts): ... this. Adjust.
14732 (tee_file_isatty): Rename to ...
14733 (tee_file::isatty): ... this. Adjust.
14734 * ui-file.h (struct obstack, struct ui_file): Don't
14735 forward-declare.
14736 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
14737 (ui_file_write_ftype)
14738 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
14739 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
14740 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
14741 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
14742 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
14743 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
14744 (set_ui_file_fseek): Delete.
14745 (ui_file_data, ui_file_delete, ui_file_rewind)
14746 (struct ui_file): New.
14747 (ui_file_up): New.
14748 (class null_file): New.
14749 (null_stream): Declare.
14750 (ui_file_write_for_put, ui_file_put): Delete.
14751 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
14752 Delete.
14753 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
14754 (gdb_fopen, tee_file_new): Delete.
14755 (struct string_file): New.
14756 (struct stdio_file): New.
14757 (stdio_file_up): New.
14758 (struct stderr_file): New.
14759 (class tee_file): New.
14760 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
14761 of a 'ui_file *'. Adjust.
14762 * ui-out.h (class ui_out) <field_stream>: Likewise.
14763 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
14764 (null_stream): Delete.
14765 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
14766 Adjust.
14767 * utils.h (struct ui_file): Delete forward declaration..
14768 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
14769 (error_stream): Take a 'string_file &' instead of a
14770 'ui_file *'.
14771 * varobj.c (varobj_value_get_print_value): Use string_file.
14772 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
14773 * gdbarch.c: Regenerate.
14774
14775 2017-02-02 Pedro Alves <palves@redhat.com>
14776
14777 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
14778 (gdb_pretty_print_insn): ... this. Now a free function. Add back
14779 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
14780 Adjust to call gdb_print_insn instead of
14781 gdb_disassembler::print_insn.
14782 (dump_insns, do_mixed_source_and_assembly_deprecated)
14783 (do_mixed_source_and_assembly, do_assembly_only): Add back a
14784 'gdbarch' parameter. Remove gdb_disassembler parameter.
14785 (gdb_disassembly): Don't allocate a gdb_disassembler here.
14786 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
14787 declaration.
14788 (gdb_pretty_print_insn): Re-add declaration.
14789 * record-btrace.c (btrace_insn_history): Don't allocate a
14790 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
14791
14792 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
14793
14794 * disasm.h (gdb_disassembly): Remove file_string parameter.
14795 * disasm.c (gdb_disassembly): Likewise.
14796 * cli/cli-cmds.c (print_disassembly): Adapt.
14797 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
14798 * stack.c (do_gdb_disassembly): Likewise.
14799
14800 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
14801
14802 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
14803 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
14804 targets. And if the implicit value is longer than needed, extract
14805 the first bytes instead of the "least significant" ones.
14806
14807 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
14808
14809 * btrace.c (btrace_enable): Do not call btrace_add_pc for
14810 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
14811 (btrace_fetch): Assert can_access_registers_ptid.
14812 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
14813 validate_registers_access.
14814
14815 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
14816
14817 * gdbthread.h (can_access_registers_ptid): New.
14818 * thread.c (can_access_registers_ptid): New.
14819
14820 2017-02-01 Pedro Alves <palves@redhat.com>
14821
14822 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
14823
14824 2017-01-31 Pedro Alves <palves@redhat.com>
14825
14826 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
14827 Fix typos.
14828
14829 2017-01-31 Pedro Alves <palves@redhat.com>
14830
14831 * stack.c (print_frame_args): Remove local mem_fileopen stream,
14832 not used.
14833
14834 2017-01-31 Pedro Alves <palves@redhat.com>
14835
14836 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
14837
14838 2017-01-31 Pedro Alves <palves@redhat.com>
14839
14840 * common/scoped_restore.h
14841 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
14842 change the value's parameter type to T2.
14843 (make_scoped_restore): Likewise.
14844
14845 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14846 Richard Henderson <rth@redhat.com>
14847
14848 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
14849 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
14850 GS_BASE for older kernels.
14851 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
14852 GS_BASE for older kernels.
14853 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
14854 and GS_BASE to the offset table.
14855 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
14856 system register group.
14857 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
14858 for older kernels.
14859 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
14860 amd64 ABI.
14861 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
14862 AMD64_GSBASE_REGNUM.
14863 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
14864 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
14865 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
14866 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
14867 i386/64bit-segments.xml in those rules.
14868 * features/i386/64bit-segments.xml: New file.
14869 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
14870 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
14871 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
14872 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
14873 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
14874 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
14875 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
14876 * features/i386/amd64-avx-linux.c: Regenerated.
14877 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
14878 * features/i386/amd64-avx-mpx.c: Regenerated.
14879 * features/i386/amd64-avx512-linux.c: Regenerated.
14880 * features/i386/amd64-linux.c: Regenerated.
14881 * features/i386/amd64-mpx-linux.c: Regenerated.
14882 * features/i386/i386-avx-mpx-linux.c: Regenerated.
14883 * features/i386/i386-avx-mpx.c: Regenerated.
14884 * features/i386/x32-avx-linux.c: Regenerated.
14885 * features/i386/x32-avx512-linux.c: Regenerated.
14886 * regformats/i386/amd64-avx-linux.dat: Regenerated.
14887 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
14888 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
14889 * regformats/i386/amd64-linux.dat: Regenerated.
14890 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
14891 * regformats/i386/x32-avx-linux.dat: Regenerated.
14892 * regformats/i386/x32-avx512-linux.dat: Regenerated.
14893 * regformats/i386/x32-linux.dat: Regenerated.
14894
14895 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14896
14897 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
14898 Set to AMD64_NUM_REGS.
14899
14900 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14901
14902 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
14903 that checks validity of a register number.
14904
14905 2017-01-27 Kees Cook <keescook@google.com>
14906
14907 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
14908 fetch_fpregs if target has fpa registers.
14909 (arm_linux_store_inferior_registers): Call store_fpregs if target
14910 has fpa registers.
14911
14912 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
14913
14914 * cris-tdep.c (cris_gdbarch_init): Remove check for
14915 info.byte_order and force it to BFD_ENDIAN_LITTLE.
14916
14917 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
14918
14919 * corelow.c (get_core_register_section): Check for regset
14920 existence before checking for REGSET_VARIABLE_SIZE.
14921
14922 2017-01-26 Yao Qi <yao.qi@linaro.org>
14923 Pedro Alves <palves@redhat.com>
14924
14925 PR gdb/20939
14926 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
14927 call memory_error, save memaddr instead.
14928 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
14929 negative, cal memory_error.
14930 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
14931
14932 2017-01-26 Yao Qi <yao.qi@linaro.org>
14933
14934 * disasm-selftests.c (memory_error_test): New function.
14935 (_initialize_disasm_selftests): Register memory_error_test.
14936
14937 2017-01-26 Yao Qi <yao.qi@linaro.org>
14938
14939 * Makefile.in (SFILES): Add disasm-selftests.c and
14940 selftest-arch.c.
14941 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
14942 * disasm-selftests.c: New file.
14943 * selftest-arch.c: New file.
14944 * selftest-arch.h: New file.
14945
14946 2017-01-26 Yao Qi <yao.qi@linaro.org>
14947
14948 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
14949 to bfd_arch_mep. Don't return 0 if section is not
14950 found. Call print_insn_mep.
14951
14952 2017-01-26 Pedro Alves <palves@redhat.com>
14953 Yao Qi <yao.qi@linaro.org>
14954
14955 * arm-tdep.c: Include "disasm.h".
14956 (gdb_print_insn_arm): Update code to get gdbarch.
14957 * disasm.c (dis_asm_read_memory): Change it to
14958 gdb_disassembler::dis_asm_read_memory.
14959 (dis_asm_memory_error): Likewise.
14960 (dis_asm_print_address): Likewise.
14961 (gdb_pretty_print_insn): Change it to
14962 gdb_disassembler::pretty_print_insn.
14963 (dump_insns): Add one argument gdb_disassemlber. All
14964 callers updated.
14965 (do_mixed_source_and_assembly_deprecated): Likewise.
14966 (do_mixed_source_and_assembly): Likewise.
14967 (do_assembly_only): Likewise.
14968 (gdb_disassembler::gdb_disassembler): New.
14969 (gdb_disassembler::print_insn): New.
14970 * disasm.h (class gdb_disassembler): New.
14971 (gdb_pretty_print_insn): Remove declaration.
14972 (gdb_disassemble_info): Likewise.
14973 * guile/scm-disasm.c (class gdbscm_disassembler): New.
14974 (gdbscm_disasm_read_memory_worker): Update.
14975 (gdbscm_disasm_read_memory): Update.
14976 (gdbscm_disasm_memory_error): Remove.
14977 (gdbscm_disasm_print_address): Remove.
14978 (gdbscm_disassembler::gdbscm_disassembler): New.
14979 (gdbscm_print_insn_from_port): Update.
14980 * mips-tdep.c: Include disasm.h.
14981 (gdb_print_insn_mips): Update code to get gdbarch.
14982 * record-btrace.c (btrace_insn_history): Update.
14983 * spu-tdep.c: Include disasm.h.
14984 (struct spu_dis_asm_data): Remove.
14985 (struct spu_dis_asm_info): New.
14986 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
14987 SPU id.
14988 (gdb_print_insn_spu): Cast disassemble_info to
14989 spu_dis_asm_info.
14990
14991 2017-01-26 Yao Qi <yao.qi@linaro.org>
14992
14993 * disasm.c (do_ui_file_delete): Delete.
14994 (gdb_insn_length): Move code creating stream to ...
14995 * utils.c (null_stream): ... here. New function.
14996 * utils.h (null_stream): Declare.
14997
14998 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
14999
15000 * python/py-inferior.c (find_thread_object): Return directly
15001 from the loop. Remove "found" variable.
15002
15003 2017-01-21 Joel Brobecker <brobecker@adacore.com>
15004
15005 GDB 7.12.1 released.
15006
15007 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
15008
15009 * python/py-function.c (fnpy_call): Reorder declarations to have
15010 the gdbpy_enter object declared first.
15011 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
15012
15013 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
15014
15015 PR python/21068
15016 * python/python-internal.h (PyMem_RawMalloc): Define for
15017 Python < 3.4.
15018 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
15019 PyMem_RawMalloc instead of PyMem_Malloc.
15020
15021 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
15022 Luis Machado <lgustavo@codesourcery.com>
15023
15024 * NEWS (New commands): Mention flash-erase.
15025 (New MI commands): Mention target-flash-erase.
15026 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
15027 command.
15028 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
15029 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
15030 * target.c (flash_erase_command): New function.
15031 (initialize_targets): Add new flash-erase command.
15032 * target.h (flash_erase_command): New declaration.
15033
15034 2017-01-20 Joel Brobecker <brobecker@adacore.com>
15035
15036 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
15037 HAVE_SYS_PROCFS_H is defined.
15038
15039 2017-01-18 Alan Hayward <alan.hayward@arm.com>
15040
15041 * remote.c (struct cached_reg): Change data into a pointer.
15042 * (stop_reply_dtr): Free data pointers before deleting vector.
15043 (process_stop_reply): Likewise.
15044 (remote_parse_stop_reply): Allocate space for data
15045
15046 2017-01-18 Alan Hayward <alan.hayward@arm.com>
15047
15048 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
15049 MAX_REGISTER_SIZE.
15050 (amd64_pseudo_register_read_value): Likewise.
15051 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
15052 (store_register_using_P): Likewise.
15053 * regcache.c (regcache_xfer_part): Likewise.
15054
15055 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
15056
15057 Split real and pseudo registers.
15058 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
15059 (sparc32_pseudo_regnum): New enum.
15060 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
15061 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
15062 (SPARC32_CP0_REGISTERS): New macro.
15063 (sparc32_pseudo_register_name): New function.
15064 (sparc32_register_name): Use sparc32_pseudo_register_name.
15065 (sparc32_pseudo_register_type): New function.
15066 (sparc32_register_type): Use sparc32_pseudo_register_type.
15067 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
15068 pseudo register numbers.
15069 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
15070 (SPARC64_CP0_REGISTERS): New macro.
15071 (sparc64_pseudo_register_name): New function.
15072 (sparc64_register_name): Use sparc64_pseudo_register_name.
15073 (sparc64_pseudo_register_type): New function.
15074 (sparc64_register_type): Use sparc64_pseudo_register_type.
15075 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
15076 pseudo register numbers.
15077 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
15078 sparc64_store_arguments): Handle pseudo register numbers.
15079
15080 2017-01-13 Yao Qi <yao.qi@linaro.org>
15081
15082 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
15083 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
15084 output.
15085 (getpkt_or_notif_sane_1): Likewise.
15086
15087 2017-01-13 Yao Qi <yao.qi@linaro.org>
15088
15089 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
15090 of CC. Pass "-x c++-header" instead of "-x c".
15091
15092 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15093
15094 * remote.c (remote_can_async_p): Update comment.
15095
15096 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15097
15098 * linux-nat.c (linux_nat_can_async_p): Update comment.
15099
15100 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15101
15102 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
15103
15104 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
15105
15106 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
15107
15108 2017-01-10 Tom Tromey <tom@tromey.com>
15109
15110 * python/py-type.c (typy_legacy_template_argument): Update.
15111 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
15112 ~demangle_parse_info): Declare new members.
15113 (cp_demangled_name_to_comp): Return unique_ptr.
15114 (cp_demangled_name_parse_free)
15115 (make_cleanup_cp_demangled_name_parse_free)
15116 (cp_new_demangle_parse_info): Remove.
15117 * cp-support.c (do_demangled_name_parse_free_cleanup)
15118 (make_cleanup_cp_demangled_name_parse_free): Remove.
15119 (inspect_type, cp_canonicalize_string_full)
15120 (cp_canonicalize_string): Update.
15121 (mangled_name_to_comp): Change return type.
15122 (cp_class_name_from_physname, method_name_from_physname)
15123 (cp_func_name, cp_remove_params): Update.
15124 * cp-name-parser.y (demangle_parse_info): New constructor, from
15125 cp_new_demangle_parse_info.
15126 (~demangle_parse_info): New destructor, from
15127 cp_demangled_name_parse_free.
15128 (cp_merge_demangle_parse_infos): Update.
15129 (cp_demangled_name_to_comp): Change return type.
15130
15131 2017-01-10 Tom Tromey <tom@tromey.com>
15132
15133 * top.c (prevent_dont_repeat): Change return type.
15134 * python/python.c (execute_gdb_command): Use std::string.
15135 Update.
15136 * guile/guile.c (gdbscm_execute_gdb_command): Update.
15137 * command.h (prevent_dont_repeat): Change return type.
15138 * breakpoint.c (bpstat_do_actions_1): Update.
15139
15140 2017-01-10 Tom Tromey <tom@tromey.com>
15141
15142 * value.h (scoped_value_mark::~scoped_value_mark): Call
15143 free_to_mark.
15144 (scoped_value_mark::free_to_mark): New method.
15145 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
15146 scoped_value_mark.
15147
15148 2017-01-10 Tom Tromey <tom@tromey.com>
15149
15150 * python/py-value.c (valpy_dereference, valpy_referenced_value)
15151 (valpy_reference_value, valpy_const_value, valpy_get_address)
15152 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
15153 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
15154 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
15155 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
15156 scoped_value_mark.
15157 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
15158 * value.h (scoped_value_mark): New class.
15159
15160 2017-01-10 Tom Tromey <tom@tromey.com>
15161
15162 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
15163 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
15164 * psymtab.c (discard_psymtabs_upto): Remove.
15165 (make_cleanup_discard_psymtabs): Remove.
15166 (struct psymtab_state): Remove.
15167
15168 2017-01-10 Tom Tromey <tom@tromey.com>
15169
15170 * record-full.c (record_full_save_cleanups): Remove.
15171 (record_full_save): Use gdb::unlinker.
15172 * gcore.c (do_bfd_delete_cleanup): Remove.
15173 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
15174 cleanups.
15175 * dwarf2read.c (unlink_if_set): Remove.
15176 (write_psymtabs_to_index): Use gdb::unlinker.
15177 * common/gdb_unlinker.h: New file.
15178
15179 2017-01-10 Tom Tromey <tom@tromey.com>
15180
15181 * windows-tdep.c (windows_xfer_shared_library): Update.
15182 * windows-nat.c (windows_make_so): Update.
15183 * utils.h (make_cleanup_bfd_unref): Remove.
15184 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
15185 * symfile.h (symfile_bfd_open)
15186 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
15187 * symfile.c (read_symbols, symbol_file_add)
15188 (separate_debug_file_exists): Update.
15189 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
15190 (generic_load, reread_symbols): Update.
15191 * symfile-mem.c (symbol_file_add_from_memory): Update.
15192 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
15193 (spu_symbol_file_add_from_memory): Update.
15194 * solist.h (struct target_so_ops) <bfd_open>: Return
15195 gdb_bfd_ref_ptr.
15196 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
15197 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
15198 gdb_bfd_ref_ptr.
15199 (solib_map_sections, reload_shared_libraries_1): Update.
15200 * solib-svr4.c (enable_break): Update.
15201 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
15202 * solib-frv.c (enable_break2): Update.
15203 * solib-dsbt.c (enable_break): Update.
15204 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
15205 gdb_bfd_ref_ptr.
15206 (darwin_solib_get_all_image_info_addr_at_init): Update.
15207 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
15208 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
15209 * record-full.c (record_full_save): Update.
15210 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
15211 * procfs.c (insert_dbx_link_bpt_in_file): Update.
15212 * minidebug.c (find_separate_debug_file_in_section): Return
15213 gdb_bfd_ref_ptr.
15214 * machoread.c (macho_add_oso_symfile): Change abfd to
15215 gdb_bfd_ref_ptr.
15216 (macho_symfile_read_all_oso): Update.
15217 (macho_check_dsym): Return gdb_bfd_ref_ptr.
15218 (macho_symfile_read): Update.
15219 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
15220 (jit_bfd_try_read_symtab): Update.
15221 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
15222 (gdb_bfd_openw, gdb_bfd_openr_iovec)
15223 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
15224 gdb_bfd_ref_ptr.
15225 (gdb_bfd_ref_policy): New struct.
15226 (gdb_bfd_ref_ptr): New typedef.
15227 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
15228 (gdb_bfd_openw, gdb_bfd_openr_iovec)
15229 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
15230 gdb_bfd_ref_ptr.
15231 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
15232 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
15233 (gcore_command): Update.
15234 * exec.c (exec_file_attach): Update.
15235 * elfread.c (elf_symfile_read): Update.
15236 * dwarf2read.c (dwarf2_get_dwz_file): Update.
15237 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
15238 (open_and_init_dwo_file): Update.
15239 (open_dwp_file): Return gdb_bfd_ref_ptr.
15240 (open_and_init_dwp_file): Update.
15241 * corelow.c (core_open): Update.
15242 * compile/compile-object-load.c (compile_object_load): Update.
15243 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
15244 * coffread.c (coff_symfile_read): Update.
15245 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
15246 gdb_bfd_ref_ptr. Rename.
15247 (dump_bfd_file, restore_command): Update.
15248 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
15249 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
15250 (find_separate_debug_file_by_buildid): Update.
15251
15252 2017-01-10 Tom Tromey <tom@tromey.com>
15253
15254 * common/gdb_ref_ptr.h: New file.
15255 * python/py-ref.h (struct gdbpy_ref_policy): New.
15256 (gdbpy_ref): Now a typedef.
15257
15258 2017-01-10 Tom Tromey <tom@tromey.com>
15259
15260 * utils.h (make_cleanup_htab_delete): Don't declare.
15261 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
15262 Remove.
15263 * linespec.c (decode_compound_collector): Add constructor,
15264 destructor.
15265 (lookup_prefix_sym): Remove cleanup.
15266 (symtab_collector): Add constructor, destructor.
15267 (collect_symtabs_from_filename): Remove cleanup.
15268 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
15269 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
15270 Use htab_up.
15271 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
15272 * dwarf2read.c (dw2_expand_symtabs_matching)
15273 (dw2_map_symbol_filenames, dwarf_decode_macros)
15274 (write_psymtabs_to_index): Use htab_up.
15275 * dwarf2loc.c (func_verify_no_selftailcall)
15276 (call_site_find_chain_1, func_verify_no_selftailcall)
15277 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
15278 std::vector, gdb::unique_xmalloc_ptr.
15279 (call_sitep): Remove typedef.
15280 (dwarf2_locexpr_baton_eval): Remove unused variable.
15281
15282 2017-01-10 Tom Tromey <tom@tromey.com>
15283
15284 * python/python-internal.h (make_cleanup_py_decref)
15285 (make_cleanup_py_xdecref): Don't declare.
15286 * python/py-utils.c (py_decref, make_cleanup_py_decref)
15287 (py_xdecref, make_cleanup_py_xdecref): Remove.
15288
15289 2017-01-10 Tom Tromey <tom@tromey.com>
15290
15291 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
15292 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
15293
15294 2017-01-10 Tom Tromey <tom@tromey.com>
15295
15296 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
15297
15298 2017-01-10 Tom Tromey <tom@tromey.com>
15299
15300 * python/py-utils.c (unicode_to_encoded_string)
15301 (python_string_to_target_string)
15302 (python_string_to_target_python_string)
15303 (python_string_to_host_string, gdbpy_obj_to_string)
15304 (get_addr_from_python): Use gdbpy_ref.
15305
15306 2017-01-10 Tom Tromey <tom@tromey.com>
15307
15308 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
15309 gdbpy_ref.
15310
15311 2017-01-10 Tom Tromey <tom@tromey.com>
15312
15313 * python/python.c (eval_python_command, gdbpy_decode_line)
15314 (gdbpy_run_events, gdbpy_start_type_printers)
15315 (gdbpy_apply_type_printers): Use gdbpy_ref.
15316
15317 2017-01-10 Tom Tromey <tom@tromey.com>
15318
15319 * python/py-param.c (get_doc_string, compute_enum_values): Use
15320 gdbpy_ref.
15321
15322 2017-01-10 Tom Tromey <tom@tromey.com>
15323
15324 * python/py-inferior.c (find_thread_object, build_inferior_list):
15325 Use gdbpy_ref.
15326
15327 2017-01-10 Tom Tromey <tom@tromey.com>
15328
15329 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
15330
15331 2017-01-10 Tom Tromey <tom@tromey.com>
15332
15333 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
15334 gdbpy_ref.
15335
15336 2017-01-10 Tom Tromey <tom@tromey.com>
15337
15338 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
15339 extra incref.
15340 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
15341 Use gdbpy_ref.
15342
15343 2017-01-10 Tom Tromey <tom@tromey.com>
15344
15345 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
15346 gdbpy_ref.
15347
15348 2017-01-10 Tom Tromey <tom@tromey.com>
15349
15350 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
15351 decref results of PyArg_ParseTupleAndKeywords.
15352
15353 2017-01-10 Tom Tromey <tom@tromey.com>
15354
15355 * python/python.c (python_run_simple_file): Use
15356 unique_xmalloc_ptr, gdbpy_ref.
15357
15358 2017-01-10 Tom Tromey <tom@tromey.com>
15359
15360 * python/py-prettyprint.c (print_stack_unless_memory_error)
15361 (print_string_repr, print_children): Use gdbpy_ref.
15362 (dummy_python_frame): New class.
15363 (dummy_python_frame::dummy_python_frame): Rename from
15364 push_dummy_python_frame.
15365 (py_restore_tstate): Remove.
15366
15367 2017-01-10 Tom Tromey <tom@tromey.com>
15368
15369 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
15370
15371 2017-01-10 Tom Tromey <tom@tromey.com>
15372
15373 * python/python.c (ensure_python_env, restore_python_env):
15374 Remove.
15375 * python/python-internal.h (ensure_python_env): Don't declare.
15376 * varobj.h (varobj_ensure_python_env): Don't declare.
15377 * varobj.c (varobj_ensure_python_env): Remove.
15378
15379 2017-01-10 Tom Tromey <tom@tromey.com>
15380
15381 * varobj.c (varobj_value_get_print_value): Use
15382 gdbpy_enter_varobj.
15383
15384 2017-01-10 Tom Tromey <tom@tromey.com>
15385
15386 * python/py-prettyprint.c (print_string_repr, print_children):
15387 Update.
15388 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
15389 of "encoding".
15390 * varobj.c (varobj_value_get_print_value): Update.
15391 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
15392
15393 2017-01-10 Tom Tromey <tom@tromey.com>
15394
15395 * varobj.c (varobj_get_display_hint)
15396 (dynamic_varobj_has_child_method, install_new_value_visualizer)
15397 (varobj_set_visualizer, free_variable): Use
15398 gdbpy_enter_varobj.
15399
15400 2017-01-10 Tom Tromey <tom@tromey.com>
15401
15402 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
15403 (do_finish_initialization): New function. Use gdbpy_ref.
15404 (gdbpy_finish_initialization): Use gdbpy_enter. Call
15405 do_finish_initialization.
15406
15407 2017-01-10 Tom Tromey <tom@tromey.com>
15408
15409 * python/py-param.c (get_set_value, get_show_value): Use
15410 gdbpy_enter, gdbpy_ref.
15411
15412 2017-01-10 Tom Tromey <tom@tromey.com>
15413
15414 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
15415
15416 2017-01-10 Tom Tromey <tom@tromey.com>
15417
15418 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
15419
15420 2017-01-10 Tom Tromey <tom@tromey.com>
15421
15422 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
15423 Use gdbpy_enter_varobj.
15424
15425 2017-01-10 Tom Tromey <tom@tromey.com>
15426
15427 * varobj.c (gdbpy_enter_varobj): New constructor.
15428 * python/python-internal.h (gdbpy_enter_varobj): New class.
15429 * python/py-varobj.c (py_varobj_get_iterator): Use
15430 gdbpy_enter_varobj.
15431
15432 2017-01-10 Tom Tromey <tom@tromey.com>
15433
15434 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
15435 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
15436 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
15437 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
15438 unique_xmalloc_ptr.
15439 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
15440
15441 2017-01-10 Tom Tromey <tom@tromey.com>
15442
15443 * python/py-xmethods.c (invoke_match_method): Use
15444 gdbpy_ref.
15445
15446 2017-01-10 Tom Tromey <tom@tromey.com>
15447
15448 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
15449 gdbpy_enter, gdbpy_ref.
15450
15451 2017-01-10 Tom Tromey <tom@tromey.com>
15452
15453 * python/python.c (python_interactive_command): Use gdbpy_enter.
15454
15455 2017-01-10 Tom Tromey <tom@tromey.com>
15456
15457 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
15458 gdbpy_ref.
15459
15460 2017-01-10 Tom Tromey <tom@tromey.com>
15461
15462 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
15463 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
15464
15465 2017-01-10 Tom Tromey <tom@tromey.com>
15466
15467 * utils.h (htab_deleter): New struct.
15468 (htab_up): New typedef.
15469 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
15470 gdbpy_enter, gdbpy_ref, htab_up.
15471
15472 2017-01-10 Tom Tromey <tom@tromey.com>
15473
15474 * python/py-unwind.c (pending_frame_invalidate): Remove.
15475 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
15476
15477 2017-01-10 Tom Tromey <tom@tromey.com>
15478
15479 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
15480 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
15481
15482 2017-01-10 Tom Tromey <tom@tromey.com>
15483
15484 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
15485
15486 2017-01-10 Tom Tromey <tom@tromey.com>
15487
15488 * python/python.c (gdbpy_eval_from_control_command)
15489 (gdbpy_source_script, gdbpy_run_events)
15490 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
15491 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
15492 gdbpy_enter.
15493
15494 2017-01-10 Tom Tromey <tom@tromey.com>
15495
15496 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
15497
15498 2017-01-10 Tom Tromey <tom@tromey.com>
15499
15500 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
15501
15502 2017-01-10 Tom Tromey <tom@tromey.com>
15503
15504 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
15505 (python_on_inferior_call_pre, python_on_inferior_call_post)
15506 (python_on_memory_change, python_on_register_change)
15507 (python_inferior_exit, python_new_objfile, add_thread_object)
15508 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
15509
15510 2017-01-10 Tom Tromey <tom@tromey.com>
15511
15512 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
15513 (bpfinishpy_handle_exit): Use gdbpy_enter.
15514
15515 2017-01-10 Tom Tromey <tom@tromey.com>
15516
15517 * python/py-cmd.c (cmdpy_destroyer)
15518 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
15519 gdbpy_enter.
15520
15521 2017-01-10 Tom Tromey <tom@tromey.com>
15522
15523 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
15524 gdbpy_enter.
15525 (gdbpy_breakpoint_has_cond): Likewise.
15526
15527 2017-01-10 Tom Tromey <tom@tromey.com>
15528
15529 * python/python.c (gdbpy_enter): New constructor.
15530 (~gdbpy_enter): New destructor.
15531 (restore_python_env, ensure_python_env): Rewrite.
15532 * python/python-internal.h (gdbpy_enter): New class.
15533
15534 2017-01-10 Tom Tromey <tom@tromey.com>
15535
15536 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
15537
15538 2017-01-10 Tom Tromey <tom@tromey.com>
15539
15540 * python/py-value.c (value_has_field, get_field_flag)
15541 (get_field_type, valpy_getitem, convert_value_from_python): Use
15542 gdbpy_ref.
15543
15544 2017-01-10 Tom Tromey <tom@tromey.com>
15545
15546 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
15547 gdbpy_ref.
15548
15549 2017-01-10 Tom Tromey <tom@tromey.com>
15550
15551 * python/py-prettyprint.c (search_pp_list)
15552 (find_pretty_printer_from_objfiles)
15553 (find_pretty_printer_from_progspace)
15554 (find_pretty_printer_from_gdb, find_pretty_printer)
15555 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
15556 gdbpy_ref.
15557
15558 2017-01-10 Tom Tromey <tom@tromey.com>
15559
15560 * python/py-param.c (call_doc_function): Use gdbpy_ref.
15561
15562 2017-01-10 Tom Tromey <tom@tromey.com>
15563
15564 * python/py-linetable.c (build_line_table_tuple_from_pcs)
15565 (ltpy_get_all_source_lines): Use gdbpy_ref.
15566
15567 2017-01-10 Tom Tromey <tom@tromey.com>
15568
15569 * python/py-framefilter.c (extract_sym, extract_value)
15570 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
15571 gdbpy_ref.
15572
15573 2017-01-10 Tom Tromey <tom@tromey.com>
15574
15575 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
15576
15577 2017-01-10 Tom Tromey <tom@tromey.com>
15578
15579 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
15580
15581 2017-01-10 Tom Tromey <tom@tromey.com>
15582
15583 * python/py-function.c (convert_values_to_python, fnpy_init): Use
15584 gdbpy_ref.
15585
15586 2017-01-10 Tom Tromey <tom@tromey.com>
15587
15588 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
15589
15590 2017-01-10 Tom Tromey <tom@tromey.com>
15591
15592 * python/py-type.c (convert_field, make_fielditem, typy_fields)
15593 (typy_range): Use gdbpy_ref.
15594
15595 2017-01-10 Tom Tromey <tom@tromey.com>
15596
15597 * python/py-threadevent.c (create_thread_event_object): Use
15598 gdbpy_ref.
15599 * python/py-stopevent.c (create_stop_event_object): Simplify.
15600 (emit_stop_event): Use gdbpy_ref.
15601 * python/py-signalevent.c (create_signal_event_object): Use
15602 gdbpy_ref.
15603 * python/py-newobjfileevent.c (create_new_objfile_event_object)
15604 (emit_new_objfile_event, create_clear_objfiles_event_object)
15605 (emit_clear_objfiles_event): Use gdbpy_ref.
15606 * python/py-infevents.c (create_inferior_call_event_object)
15607 (create_register_changed_event_object)
15608 (create_memory_changed_event_object, emit_inferior_call_event)
15609 (emit_memory_changed_event, emit_register_changed_event): Use
15610 gdbpy_ref.
15611 * python/py-exitedevent.c (create_exited_event_object)
15612 (emit_exited_event): Use gdbpy_ref.
15613 * python/py-event.h (evpy_emit_event): Remove
15614 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
15615 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
15616 * python/py-continueevent.c (emit_continue_event): Use
15617 gdbpy_ref.
15618 * python/py-breakpoint.c (gdbpy_breakpoint_created)
15619 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
15620 gdbpy_ref.
15621 * python/py-bpevent.c (create_breakpoint_event_object): Use
15622 gdbpy_ref.
15623
15624 2017-01-10 Tom Tromey <tom@tromey.com>
15625
15626 * python/py-ref.h: New file.
15627
15628 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
15629
15630 * cli-out.c (cli_ui_out::do_redirect): Change return type to
15631 void.
15632 * cli-out.h (cli_ui_out::do_redirect): Likewise.
15633 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
15634 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
15635 * ui-out.c (ui_out::redirect): Likewise.
15636 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
15637 * cli/cli-logging.c (set_logging_redirect): Update call site of
15638 ui_out::redirect.
15639 (handle_redirections): Likewise.
15640 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
15641 * top.c (execute_command_to_string): Likewise.
15642 * utils.c (do_ui_out_redirect_pop): Likewise.
15643
15644 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
15645
15646 * stack.c (_initialize_stack): Update "frame" command help message.
15647
15648 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
15649
15650 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
15651
15652 2017-01-06 Yao Qi <yao.qi@linaro.org>
15653
15654 * x86-linux-nat.h: Include gdb_proc_service.h.
15655
15656 2017-01-06 Yao Qi <yao.qi@linaro.org>
15657
15658 * ser-base.h: Include serial.h.
15659
15660 2017-01-06 Yao Qi <yao.qi@linaro.org>
15661
15662 * ppc-linux-tdep.h: Include ppc-tdep.h.
15663
15664 2017-01-06 Yao Qi <yao.qi@linaro.org>
15665
15666 * nat/amd64-linux-siginfo.h: Include signal.h.
15667
15668 2017-01-06 Yao Qi <yao.qi@linaro.org>
15669
15670 * nat/aarch64-linux-hw-point.h: Include break-common.h.
15671
15672 2017-01-06 Yao Qi <yao.qi@linaro.org>
15673
15674 * mi/mi-parse.h: Include mi-cmds.h.
15675
15676 2017-01-06 Yao Qi <yao.qi@linaro.org>
15677
15678 * inf-loop.c: Don't include "target.h".
15679 * inf-loop.h: Include it here.
15680
15681 2017-01-06 Yao Qi <yao.qi@linaro.org>
15682
15683 * dfp.h: Include "dboulest.h" and "expression.h".
15684
15685 2017-01-06 Yao Qi <yao.qi@linaro.org>
15686
15687 * ax-gdb.h: Include "ax.h".
15688
15689 2017-01-06 Yao Qi <yao.qi@linaro.org>
15690
15691 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
15692 with nat/gdb_ptrace.h.
15693
15694 2017-01-05 Yao Qi <yao.qi@linaro.org>
15695
15696 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
15697 new line.
15698 (mips64_fbsd_sigframe_init): Likewise.
15699
15700 2017-01-04 John Baldwin <jhb@FreeBSD.org>
15701
15702 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
15703 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
15704
15705 2017-01-04 John Baldwin <jhb@FreeBSD.org>
15706
15707 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
15708 * NEWS: Mention new FreeBSD/mips native configuration.
15709 * config/mips/fbsd.mh: New file.
15710 * configure.host: Add mips*-*-freebsd*.
15711 * mips-fbsd-nat.c: New file.
15712
15713 2017-01-04 John Baldwin <jhb@FreeBSD.org>
15714
15715 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
15716 (ALLDEPFILES): Add mips-fbsd-tdep.c.
15717 * NEWS: Mention new FreeBSD/mips target.
15718 * configure.tgt: Add mips*-*-freebsd*.
15719 * mips-fbsd-tdep.c: New file.
15720 * mips-fbsd-tdep.h: New file.
15721
15722 2017-01-04 Yao Qi <yao.qi@linaro.org>
15723
15724 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
15725 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
15726
15727 2017-01-01 Joel Brobecker <brobecker@adacore.com>
15728
15729 Update copyright year range in all GDB files.
15730
15731 2017-01-01 Joel Brobecker <brobecker@adacore.com>
15732
15733 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
15734
15735 For older changes see ChangeLog-2016.
15736 \f
15737 Local Variables:
15738 mode: change-log
15739 left-margin: 8
15740 fill-column: 74
15741 version-control: never
15742 coding: utf-8
15743 End:
This page took 0.387063 seconds and 4 git commands to generate.