Fix testing gdb.rust/modules.exp against gdbserver
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
d7236961
UW
12017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
2
3 * target-float.c (decimal_from_number): Add byte_order argument and
4 call match_endianness. Error if unknown floating-point type.
5 (decimal_to_number): Add byte_order argument and call match_endianness.
6 (decimal_from_longest): Update call. Do not call match_endianness.
7 (decimal_from_ulongest): Likewise.
8 (decimal_binop): Likewise.
9 (decimal_is_zero): Likewise.
10 (decimal_compare): Likewise.
11 (decimal_convert): Likewise.
12
d8ae99a7
PM
132017-11-16 Phil Muldoon <pmuldoon@redhat.com>
14
15 * python/python.c (gdbpy_rbreak): New function.
16 * NEWS: Document Python rbreak feature.
17
c632b645
YQ
182017-11-16 Yao Qi <yao.qi@linaro.org>
19
20 * features/tic6x-c62x.xml: Remove.
21 * features/tic6x-c64x.xml: Remove.
22 * features/tic6x-c64xp.xml: Remove.
23
a014b87a
JB
242017-11-15 John Baldwin <jhb@FreeBSD.org>
25
26 * symtab.h: Include <array>.
27
94765011
JB
282017-11-15 John Baldwin <jhb@FreeBSD.org>
29
30 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
31 (bsd_kvm_proc_cmd): Likewise.
32
625ad440
SM
332017-11-15 Simon Marchi <simon.marchi@ericsson.com>
34
35 * tui/tui-win.c (window_name_completer): Replace VEC with
36 std::vector.
37
c0c11fa9
AC
382017-11-15 Andrew Cagney <cagney@gnu.org>
39
40 * MAINTAINERS: Remove no-longer applicable entries.
41
34a7ebaf
AC
422017-11-15 Andrew Cagney <cagney@gnu.org>
43
44 * MAINTAINERS: Move self to Past Maintainers.
45
5334ef39
YQ
462017-11-15 Yao Qi <yao.qi@linaro.org>
47
48 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
49 * features/nios2-linux.c: Remove.
50 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
51 initialize_tdesc_nios2_linux.
52
a714b0d6
YQ
532017-11-15 Yao Qi <yao.qi@linaro.org>
54
55 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
56 M68HC11_LAST_HARD_REG + 1.
57
92ffd475
PC
582017-11-14 Paul Carroll <pcarroll@codesourcery.com>
59
60 PR gdb/22388
61 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
62 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
63 Return TARGET_XFER_EOF if size of returned data is 0.
64
07431908
SM
652017-11-14 Simon Marchi <simon.marchi@ericsson.com>
66
67 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
68 memory-map-selftests.c.
69 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
70 * memory-map.c (memory_map_start_memory): Fix computation of hi
71 address.
72 * unittests/memory-map-selftests.c: New file.
73
31432a67
JB
742017-11-09 Joel Brobecker <brobecker@adacore.com>
75
76 * ada-lang.c: Fix some typos in the general command documenting
77 how Ada expressions are being evaluated and how their result
78 is printed.
79
e793c052
TT
802017-11-09 Tom Tromey <tom@tromey.com>
81
82 * psymtab.c (psymbol_hash): Do not hash string contents.
83 (psymbol_compare): Add comment.
84
7e8835c5
TT
852017-11-09 Tom Tromey <tom@tromey.com>
86
87 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
88
286acbb5
JB
892017-11-08 Joel Brobecker <brobecker@adacore.com>
90
91 * ada-exp.y (write_var_from_sym): Remove parameter
92 "orig_left_context". Update all callers.
93
b44ec619
SM
942017-11-08 Simon Marchi <simon.marchi@ericsson.com>
95
96 * tracepoint.h (class collection_list) <stringify>: Return
97 std::vector<std::string>.
98 (encode_actions_rsp): Change parameters to
99 std::vector<std::string> *.
100 * tracepoint.c (collection_list::stringify): Return
101 std::vector<std::string> and adjust accordingly.
102 (encode_actions_rsp): Changee parameters to
103 std::vector<std::string> and adjust accordingly.
104 * remote.c (free_actions_list),
105 free_actions_list_cleanup_wrapper): Remove.
106 (remote_download_tracepoint): Adjust to std::vector.
107
2f4732b0
TT
1082017-11-08 Tom Tromey <tom@tromey.com>
109
110 * dwarf2read.c (symbolp): Remove typedef.
111 (read_func_scope): Use std::vector.
112 (process_structure_scope): Use std::vector.
113
f9d67a22
PA
1142017-11-08 Pedro Alves <palves@redhat.com>
115
116 * ada-lang.c (ada_make_symbol_completion_list): Use
117 completion_skip_symbol.
118 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
119 (symbol_is_function_or_method(symbol*)): New.
120 (add_symtab_completions): Add complete_symbol_mode parameter. Use
121 completion_skip_symbol.
122 (default_collect_symbol_completion_matches_break_on): Use
123 completion_skip_symbol. Pass down mode.
124 (collect_file_symbol_completion_matches): Pass down mode.
125 * symtab.h (symbol_is_function_or_method): New declarations.
126 (completion_skip_symbol): New template function.
127
56d87ef7
PA
1282017-11-08 Pedro Alves <palves@redhat.com>
129
130 * linespec.c (iterate_over_all_matching_symtabs): Add
131 search_domain parameter. Pass it down to expand_symtabs_matching.
132 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
133 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
134 search_domain.
135 (add_all_symbol_names_from_pspace): Add search_domain parameter.
136 Pass it down.
137 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
138 symbols.
139 (add_matching_symbols_to_info): Add search_domain parameter. Pass
140 it down.
141
1b026119
PA
1422017-11-08 Pedro Alves <palves@redhat.com>
143
144 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
145 text_len locals and don't pass them down.
146 * symtab.c (completion_list_add_name): Remove
147 sym_text/sym_text_len parameters and adjust.
148 (completion_list_add_symbol, completion_list_add_msymbol)
149 (completion_list_objc_symbol, completion_list_add_fields)
150 (add_symtab_completions): Likewise.
151 (default_collect_symbol_completion_matches_break_on)
152 (collect_file_symbol_completion_matches): Remove sym_text_len
153 local and don't pass it down.
154 * symtab.h (completion_list_add_name): Remove
155 sym_text/sym_text_len parameters.
156
c62446b1
PA
1572017-11-08 Pedro Alves <palves@redhat.com>
158
159 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
160 unittests/lookup_name_info-selftests.c.
161 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
162 * cp-support.c: Include "selftest.h".
163 (cp_remove_params_1): Rename from cp_remove_params. Add
164 'require_param' parameter, and handle it.
165 (cp_remove_params): Reimplement.
166 (cp_remove_params_if_any): New.
167 (selftests::quote): New.
168 (selftests::check_remove_params): New.
169 (selftests::test_cp_remove_params): New.
170 (_initialize_cp_support): Install
171 selftests::test_cp_remove_params.
172 * cp-support.h (cp_remove_params_if_any): Declare.
173 * dwarf2read.c :Include "selftest.h".
174 (dw2_expand_symtabs_matching_symbol): Use
175 lookup_name_info::make_ignore_params.
176 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
177 (selftests::dw2_expand_symtabs_matching::string_or_null)
178 (selftests::dw2_expand_symtabs_matching::check_match)
179 (selftests::dw2_expand_symtabs_matching::test_symbols)
180 (selftests::dw2_expand_symtabs_matching::run_test): New.
181 (_initialize_dwarf2_read): Register
182 selftests::dw2_expand_symtabs_matching::run_test.
183 * psymtab.c (psym_expand_symtabs_matching): Use
184 lookup_name_info::make_ignore_params.
185 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
186 If the lookup name wants to ignore parameters, strip them.
187 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
188 code handling '('.
189 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
190 (default_collect_symbol_completion_matches_break_on): Don't try to
191 strip parameters.
192 * symtab.h (lookup_name_info::lookup_name_info): Add
193 'ignore_parameters' parameter.
194 (lookup_name_info::ignore_parameters)
195 (lookup_name_info::make_ignore_params): New methods.
196 (lookup_name_info::m_ignore_parameters): New field.
197 * unittests/lookup_name_info-selftests.c: New file.
198
61920122
PA
1992017-11-08 Pedro Alves <palves@redhat.com>
200
201 * dwarf2read.c (dw2_expand_marked_cus)
202 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
203 (dw2_expand_symtabs_matching): Move further below.
204 (dw2_expand_marked_cus): Reindent.
205
3f563c84
PA
2062017-11-08 Pedro Alves <palves@redhat.com>
207
208 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
209 (struct name_component): New.
210 (mapped_index::name_components): New field.
211 (mapped_index::symbol_name_at): New method.
212 (dwarf2_read_index): Call mapped_index ctor.
213 (dw2_map_matching_symbols): Add comment about name_components
214 table.
215 (dw2_expand_symtabs_matching): Factor part to...
216 (dw2_expand_symtabs_matching_symbol): ... this new function.
217 Build name components table, and lookup symbols in it before
218 calling the name matcher.
219 (dw2_expand_marked_cus): New, factored out from
220 dw2_expand_symtabs_matching.
221 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
222
b5ec771e
PA
2232017-11-08 Pedro Alves <palves@redhat.com>
224
225 * ada-lang.c (ada_encode): Rename to ..
226 (ada_encode_1): ... this. Add throw_errors parameter and handle
227 it.
228 (ada_encode): Reimplement.
229 (match_name): Delete, folded into full_name.
230 (resolve_subexp): No longer pass the encoded name to
231 ada_lookup_symbol_list.
232 (should_use_wild_match): Delete.
233 (name_match_type_from_name): New.
234 (ada_lookup_simple_minsym): Use lookup_name_info and the
235 language's symbol_name_matcher_ftype.
236 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
237 (ada_add_block_renamings): Adjust to use lookup_name_info.
238 (ada_lookup_name): New.
239 (add_nonlocal_symbols, ada_add_all_symbols)
240 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
241 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
242 (ada_name_for_lookup): Delete.
243 (ada_lookup_encoded_symbol): Construct a verbatim name.
244 (wild_match): Reverse sense of return type. Use bool.
245 (full_match): Reverse sense of return type. Inline bits of old
246 match_name here.
247 (ada_add_block_symbols): Adjust to use lookup_name_info.
248 (symbol_completion_match): Delete, folded into...
249 (ada_lookup_name_info::matches): ... .this new method.
250 (symbol_completion_add): Delete.
251 (ada_collect_symbol_completion_matches): Add name_match_type
252 parameter. Adjust to use lookup_name_info and
253 completion_list_add_name.
254 (get_var_value, ada_add_global_exceptions): Adjust to use
255 lookup_name_info.
256 (ada_get_symbol_name_cmp): Delete.
257 (do_wild_match, do_full_match): New functions.
258 (ada_lookup_name_info::ada_lookup_name_info): New method.
259 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
260 functions.
261 (ada_language_defn): Install ada_get_symbol_name_matcher.
262 * ada-lex.l (processId): If name starts with '<', copy it
263 verbatim.
264 * block.c (block_iter_match_step, block_iter_match_first)
265 (block_iter_match_next, block_lookup_symbol)
266 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
267 lookup_name_info.
268 * block.h (block_iter_match_first, block_iter_match_next)
269 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
270 * c-lang.c (c_language_defn, cplus_language_defn)
271 (asm_language_defn, minimal_language_defn): Adjust comments to
272 refer to la_get_symbol_name_matcher.
273 * completer.c (complete_files_symbols)
274 (collect_explicit_location_matches, symbol_completer): Pass a
275 symbol_name_match_type down.
276 * completer.h (class completion_match, completion_match_result):
277 New classes.
278 (completion_tracker::reset_completion_match_result): New method.
279 (completion_tracker::m_completion_match_result): New field.
280 * cp-support.c (make_symbol_overload_list_block): Adjust to use
281 lookup_name_info.
282 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
283 functions.
284 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
285 * d-lang.c: Adjust comments to refer to
286 la_get_symbol_name_matcher.
287 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
288 Adjust to use lookup_name_info.
289 (dict_iter_match_first, dict_iter_match_next)
290 (iter_match_first_hashed, iter_match_next_hashed)
291 (iter_match_first_linear, iter_match_next_linear): Adjust to work
292 with a lookup_name_info.
293 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
294 Likewise.
295 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
296 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
297 (gdb_index_symbol_name_matcher): New class.
298 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
299 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
300 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
301 with a symbol_name_match_type.
302 (f_language_defn): Adjust comments to refer to
303 la_get_symbol_name_matcher.
304 * go-lang.c (go_language_defn): Adjust comments to refer to
305 la_get_symbol_name_matcher.
306 * language.c (default_symbol_name_matcher)
307 (language_get_symbol_name_matcher): New functions.
308 (unknown_language_defn, auto_language_defn): Adjust comments to
309 refer to la_get_symbol_name_matcher.
310 * language.h (symbol_name_cmp_ftype): Delete.
311 (language_defn) <la_collect_symbol_completion_matches>: Add match
312 type parameter.
313 <la_get_symbol_name_cmp>: Delete field.
314 <la_get_symbol_name_matcher>: New field.
315 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
316 (default_symbol_name_matcher, language_get_symbol_name_matcher):
317 Declare.
318 * linespec.c (iterate_over_all_matching_symtabs)
319 (iterate_over_file_blocks): Adjust to use lookup_name_info.
320 (find_methods): Add language parameter, and use lookup_name_info
321 and the language's symbol_name_matcher_ftype.
322 (linespec_complete_function): Adjust.
323 (lookup_prefix_sym): Use lookup_name_info.
324 (add_all_symbol_names_from_pspace): Adjust.
325 (find_superclass_methods): Add language parameter and pass it
326 down.
327 (find_method): Pass symbol language down.
328 (find_linespec_symbols): Don't demangle or Ada encode here.
329 (search_minsyms_for_name): Add lookup_name_info parameter.
330 (add_matching_symbols_to_info): Add name_match_type parameter.
331 Use lookup_name_info.
332 * m2-lang.c (m2_language_defn): Adjust comments to refer to
333 la_get_symbol_name_matcher.
334 * minsyms.c: Include <algorithm>.
335 (add_minsym_to_demangled_hash_table): Remove table parameter and
336 add objfile parameter. Use search_name_hash, and add language to
337 demangled languages vector.
338 (struct found_minimal_symbols): New struct.
339 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
340 New functions.
341 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
342 input names here. Use lookup_name_info instead. Lookup up
343 demangled names once for each language in the demangled names
344 vector.
345 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
346 demangled names once for each language in the demangled names
347 vector.
348 (build_minimal_symbol_hash_tables): Adjust.
349 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
350 lookup_name_info.
351 * objc-lang.c (objc_language_defn): Adjust comment to refer to
352 la_get_symbol_name_matcher.
353 * objfiles.h: Include <vector>.
354 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
355 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
356 la_get_symbol_name_matcher.
357 * p-lang.c (pascal_language_defn): Adjust comment to refer to
358 la_get_symbol_name_matcher.
359 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
360 (match_partial_symbol): Use symbol_name_match_type,
361 lookup_name_info and psymbol_name_matches.
362 (lookup_partial_symbol): Use lookup_name_info.
363 (map_block): Use symbol_name_match_type and lookup_name_info.
364 (psym_map_matching_symbols): Use symbol_name_match_type.
365 (psymbol_name_matches): New.
366 (recursively_search_psymtabs): Use lookup_name_info and
367 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
368 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
369 'kind' parameter to 'domain'.
370 * rust-lang.c (rust_language_defn): Adjust comment to refer to
371 la_get_symbol_name_matcher.
372 * symfile-debug.c (debug_qf_map_matching_symbols)
373 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
374 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
375 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
376 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
377 Adjust to use symbol_name_match_type.
378 <expand_symtabs_matching>: Adjust to use lookup_name_info.
379 (expand_symtabs_matching): Adjust to use lookup_name_info.
380 * symmisc.c (maintenance_expand_symtabs): Use
381 lookup_name_info::match_any ().
382 * symtab.c (symbol_matches_search_name): New.
383 (eq_symbol_entry): Adjust to use lookup_name_info and the
384 language's matcher.
385 (demangle_for_lookup_info::demangle_for_lookup_info): New.
386 (lookup_name_info::match_any): New.
387 (iterate_over_symbols, search_symbols): Use lookup_name_info.
388 (compare_symbol_name): Add language, lookup_name_info and
389 completion_match_result parameters, and use them.
390 (completion_list_add_name): Make extern. Add language and
391 lookup_name_info parameters. Use them.
392 (completion_list_add_symbol, completion_list_add_msymbol)
393 (completion_list_objc_symbol): Add lookup_name_info parameters and
394 adjust. Pass down language.
395 (completion_list_add_fields): Add lookup_name_info parameters and
396 adjust. Pass down language.
397 (add_symtab_completions): Add lookup_name_info parameters and
398 adjust.
399 (default_collect_symbol_completion_matches_break_on): Add
400 name_match_type parameter, and use it. Use lookup_name_info.
401 (default_collect_symbol_completion_matches)
402 (collect_symbol_completion_matches): Add name_match_type
403 parameter, and pass it down.
404 (collect_symbol_completion_matches_type): Adjust.
405 (collect_file_symbol_completion_matches): Add name_match_type
406 parameter, and use lookup_name_info.
407 * symtab.h: Include <string> and "common/gdb_optional.h".
408 (enum class symbol_name_match_type): New.
409 (class ada_lookup_name_info): New.
410 (struct demangle_for_lookup_info): New.
411 (class lookup_name_info): New.
412 (symbol_name_matcher_ftype): New.
413 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
414 (symbol_matches_search_name): Declare.
415 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
416 (default_collect_symbol_completion_matches)
417 (collect_symbol_completion_matches)
418 (collect_file_symbol_completion_matches): Add name_match_type
419 parameter.
420 (iterate_over_symbols): Use lookup_name_info.
421 (completion_list_add_name): Declare.
422 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
423 (strncmp_iw_with_mode): Now extern.
424 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
425 (strncmp_iw_with_mode): Declare.
426
5ffa0793
PA
4272017-11-08 Keith Seitz <keiths@redhat.com>
428 Pedro Alves <palves@redhat.com>
429
430 * ada-lang.c (ada_language_defn): Install
431 default_search_name_hash.
432 * buildsym.c (struct buildsym_compunit): <language>: New field.
433 (finish_block_internal): Pass language when creating dictionaries.
434 (start_buildsym_compunit, start_symtab): New language parameters.
435 Use them.
436 (restart_symtab): Pass down compilation unit's language.
437 * buildsym.h (enum language): Forward declare.
438 (start_symtab): New 'language' parameter.
439 * c-lang.c (c_language_defn, cplus_language_defn)
440 (asm_language_defn, minimal_language_defn): Install
441 default_search_name_hash.
442 * coffread.c (coff_start_symtab): Adjust.
443 * d-lang.c (d_language_defn): Install default_search_name_hash.
444 * dbxread.c (struct symloc): Add 'pst_language' field.
445 (PST_LANGUAGE): Define.
446 (start_psymtab, read_ofile_symtab): Use it.
447 (process_one_symbol): New 'language' parameter. Pass it down.
448 * dictionary.c (struct dictionary) <language>: New field.
449 (DICT_LANGUAGE): Define.
450 (dict_create_hashed, dict_create_hashed_expandable)
451 (dict_create_linear, dict_create_linear_expandable): New parameter
452 'language'. Set the dictionary's language.
453 (iter_match_first_hashed): Adjust to rename.
454 (insert_symbol_hashed): Assert we don't see mismatching
455 languages. Adjust to rename.
456 (dict_hash): Rename to ...
457 (default_search_name_hash): ... this and make extern.
458 * dictionary.h (struct language_defn): Forward declare.
459 (dict_create_hashed): New parameter 'language'.
460 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
461 * f-lang.c (f_language_defn): Install default_search_name_hash.
462 * go-lang.c (go_language_defn): Install default_search_name_hash.
463 * jit.c (finalize_symtab): Pass compunit's language to dictionary
464 creation.
465 * language.c (unknown_language_defn, auto_language_defn):
466 * language.h (language_defn::la_search_name_hash): New field.
467 (default_search_name_hash): Declare.
468 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
469 * mdebugread.c (new_block): New parameter 'language'.
470 * mdebugread.c (parse_symbol): Pass symbol language to block
471 allocation.
472 (psymtab_to_symtab_1): Pass down language.
473 (new_symtab): Pass compunit's language to block allocation.
474 * objc-lang.c (objc_language_defn): Install
475 default_search_name_hash.
476 * opencl-lang.c (opencl_language_defn):
477 * p-lang.c (pascal_language_defn): Install
478 default_search_name_hash.
479 * rust-lang.c (rust_language_defn): Install
480 default_search_name_hash.
481 * stabsread.h (enum language): Forward declare.
482 (process_one_symbol): Add 'language' parameter.
483 * symtab.c (search_name_hash): New function.
484 * symtab.h (search_name_hash): Declare.
485 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
486
2a1dde5d
PA
4872017-11-08 Pedro Alves <palves@redhat.com>
488
489 * cp-name-parser.y (main): Don't initialize extra_chars.
490
95a6b0a1
TT
4912017-11-07 Tom Tromey <tom@tromey.com>
492
493 * event-top.h (command_handler): Constify.
494 * record-full.c (cmd_record_full_start): Update.
495 * thread.c (thread_apply_all_command): Update.
496 * printcmd.c (eval_command): Update.
497 * mi/mi-main.c (mi_execute_cli_command): Update.
498 (mi_execute_async_cli_command): Update.
499 * tui/tui-stack.c (tui_update_command): Update.
500 * cli/cli-interp.c (safe_execute_command): Constify.
501 * record.c (record_start): Update.
502 (record_start, record_stop, cmd_record_start): Update.
503 * record-btrace.c (cmd_record_btrace_bts_start): Update.
504 (cmd_record_btrace_pt_start): Update.
505 (cmd_record_btrace_start): Update.
506 (cmd_record_btrace_start): Update.
507 * reverse.c (exec_reverse_once): Update.
508 * python/python.c (execute_gdb_command): Don't copy the command.
509 * event-top.c (command_line_handler): Update.
510 (command_handler): Constify.
511 * defs.h (deprecated_call_command_hook): Constify.
512 * cli/cli-script.h (execute_user_command): Constify.
513 * cli/cli-script.c (execute_user_command): Constify.
514 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
515 (enum command_control_type): Update.
516 * main.c (catch_command_errors): Remove non-const overload.
517 (catch_command_errors_ftype): Remove.
518 * python/py-cmd.c (cmdpy_function): Constify.
519 * guile/scm-cmd.c (cmdscm_function): Constify.
520 * cli/cli-dump.c (call_dump_func): Constify.
521 * cli/cli-decode.c (do_const_cfunc): Constify.
522 (do_sfunc): Constify.
523 (cmd_func): Constify.
524 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
525 * top.h (execute_command): Constify.
526 * top.c (execute_command): Constify.
527 (execute_command_to_string): Constify.
528 (deprecated_call_command_hook): Constify.
529 * command.h (cmd_func): Constify.
530 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
531
eb4c3f4a
TT
5322017-11-07 Tom Tromey <tom@tromey.com>
533
534 * ada-lang.c (catch_ada_exception_command): Constify.
535 (catch_assert_command): Constify.
536 * break-catch-throw.c (catch_catch_command, catch_throw_command)
537 (catch_rethrow_command): Constify.
538 (catch_exception_command_1): Constify.
539 * breakpoint.h (add_catch_command): Constify.
540 * break-catch-syscall.c (catch_syscall_command_1): Constify.
541 (catch_syscall_split_args): Constify.
542 * break-catch-sig.c (catch_signal_command): Constify.
543 (catch_signal_split_args): Constify.
544 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
545 cmd_const_sfunc_ftype.
546 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
547 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
548 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
549 (add_setshow_string_cmd, struct cmd_list_element)
550 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
551 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
552 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
553 Constify.
554 (set_cmd_sfunc): Constify.
555 (empty_sfunc): Constify.
556 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
557 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
558 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
559 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
560 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
561 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
562 Constify.
563 (set_cmd_sfunc): Constify.
564 (cmd_sfunc_ftype): Remove.
565 * compile/compile.c (set_compile_args): Constify.
566 * infrun.c (set_disable_randomization): Constify.
567 * infcmd.c (set_args_command, set_cwd_command): Constify.
568 * breakpoint.c (set_condition_evaluation_mode): Constify.
569 (add_catch_command): Constify.
570 (catch_fork_command_1, catch_exec_command_1)
571 (catch_load_command_1, catch_unload_command_1): Constify.
572 (catch_load_or_unload): Constify.
573 * guile/scm-param.c (pascm_set_func): Constify.
574 (add_setshow_generic): Constify.
575 * python/py-param.c (get_set_value): Constify.
576 * top.h (set_verbose): Constify.
577 * tui/tui-win.c (tui_set_var_cmd): Constify.
578 * mi/mi-main.c (set_mi_async_command): Constify.
579 * cli/cli-logging.c (set_logging_overwrite)
580 (set_logging_redirect): Constify.
581 * value.c (set_max_value_size): Constify.
582 * valprint.c (set_input_radix, set_output_radix): Constify.
583 * utils.c (set_width_command, set_height_command): Constify.
584 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
585 * tracepoint.c (set_disconnected_tracing)
586 (set_circular_trace_buffer, set_trace_buffer_size)
587 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
588 * top.c (set_history_size_command, set_verbose, set_editing)
589 (set_gdb_datadir, set_history_filename): Constify.
590 * target.c (set_targetdebug, maint_set_target_async_command)
591 (maint_set_target_non_stop_command, set_target_permissions)
592 (set_write_memory_permission): Constify.
593 (open_target): Constify.
594 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
595 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
596 * symtab.c (set_symbol_cache_size_handler): Constify.
597 * symfile.c (set_ext_lang_command): Constify.
598 * symfile-debug.c (set_debug_symfile): Constify.
599 * source.c (set_directories_command): Constify.
600 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
601 * serial.c (set_parity): Constify.
602 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
603 * remote.c (set_remote_exec_file, set_remotebreak)
604 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
605 * record.c (set_record_insn_history_size)
606 (set_record_call_history_size): Constify.
607 * record-full.c (set_record_full_insn_max_num): Constify.
608 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
609 * osabi.c (set_osabi): Constify.
610 * mips-tdep.c (set_mips64_transfers_32bit_regs)
611 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
612 * maint.c (maintenance_set_profile_cmd): Constify.
613 * linux-thread-db.c (set_libthread_db_search_path): Constify.
614 * language.c (set_language_command, set_range_command)
615 (set_case_command): Constify.
616 * infrun.c (set_non_stop, set_observer_mode)
617 (set_stop_on_solib_events, set_schedlock_func)
618 (set_exec_direction_func): Constify.
619 * infcmd.c (set_inferior_tty_command): Constify.
620 * disasm.c (set_disassembler_options_sfunc): Constify.
621 * demangle.c (set_demangling_command): Constify.
622 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
623 * cris-tdep.c (set_cris_version, set_cris_mode)
624 (set_cris_dwarf2_cfi): Constify.
625 * corefile.c (set_gnutarget_command): Constify.
626 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
627 (set_target_wide_charset_sfunc): Constify.
628 * breakpoint.c (update_dprintf_commands): Constify.
629 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
630 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
631 (set_disassembly_style_sfunc): Constify.
632 * arch-utils.c (set_endian, set_architecture): Constify.
633 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
634 * agent.c (set_can_use_agent): Constify.
635
5fed81ff
TT
6362017-11-07 Tom Tromey <tom@tromey.com>
637
638 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
639 (go32_pde, go32_pte, go32_pte_for_address): Constify.
640 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
641 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
642 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
643 (parse_int_arg, show_thread_default_detach_sc_cmd)
644 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
645 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
646 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
647 (show_task_pause_cmd, set_task_detach_sc_cmd)
648 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
649 (set_noninvasive_cmd, set_thread_pause_cmd)
650 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
651 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
652 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
653 * windows-nat.c (display_selectors): Constify.
654 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
655 non-const "cfunc".
656 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
657 (cmd_cfunc_eq): Likewise.
658 (struct cmd_list_element): Likewise.
659 (do_cfunc): Remove.
660 (cli_user_command_p): Update.
661 * command.h (add_cmd): Remove non-const overload.
662 (cmd_cfunc_ftype): Remove typedef.
663 (cmd_cfunc_eq): Remove non-const overload.
664 * value.c (show_values): Constify.
665 * thread.c (thread_apply_all_command): Constify.
666 * symfile.c (load_command): Constify.
667 * source.c (directory_command): Constify.
668 * maint.c (maintenance_internal_error)
669 (maintenance_demangler_warning, maintenance_space_display)
670 (maintenance_print_architecture, maintenance_translate_address)
671 (maintenance_info_selftests, maintenance_internal_warning):
672 Constify.
673 * breakpoint.c (disable_trace_command, enable_trace_command):
674 Constify.
675 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
676 Constify.
677 (add_auto_load_safe_path): Constify.
678 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
679 * top.h (show_commands): Constify.
680 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
681 * sparc64-tdep.c (adi_examine_command): Constify.
682 (adi_assign_command): Constify.
683
1d12d88f
TT
6842017-11-07 Tom Tromey <tom@tromey.com>
685
686 * frame.h (info_locals_command, info_args_command): Constify.
687 * auto-load.h (auto_load_info_scripts): Constify.
688 * inferior.h (registers_info): Constify.
689 * copying.c: Rebuild.
690 * copying.awk: Constify generated commands.
691 * auto-load.c (auto_load_info_scripts)
692 (info_auto_load_gdb_scripts): Constify.
693 * cli/cli-decode.c (struct cmd_list_element): Take a
694 cmd_const_cfunc_ftype.
695 * command.h (add_info): Take a cmd_const_cfunc_ftype.
696 * tui/tui-win.c (tui_all_windows_info): Constify.
697 * python/py-auto-load.c (info_auto_load_python_scripts):
698 Constify.
699 * cli/cli-cmds.c (show_command): Remove non-const overload.
700 * tracepoint.c (info_tvariables_command, info_scope_command):
701 Constify.
702 (info_static_tracepoint_markers_command): Constify.
703 * thread.c (info_threads_command): Constify.
704 (print_thread_info_1): Constify.
705 * target.c (info_target_command): Constify.
706 * symtab.c (info_sources_command, info_functions_command)
707 (info_types_command): Constify.
708 (info_variables_command): Remove non-const overload.
709 * symfile.c (info_ext_lang_command): Constify.
710 * stack.c (info_frame_command, info_locals_command)
711 (info_args_command): Constify.
712 (backtrace_command): Remove non-const overload.
713 * source.c (info_source_command, info_line_command): Constify.
714 * solib.c (info_sharedlibrary_command): Constify.
715 * skip.c (info_skip_command): Constify.
716 * ser-go32.c (info_serial_command): Constify.
717 * reverse.c (info_bookmarks_command): Constify.
718 * printcmd.c (info_symbol_command, info_address_command)
719 (info_display_command): Constify.
720 * osdata.c (info_osdata_command): Constify.
721 * objc-lang.c (info_selectors_command, info_classes_command):
722 Constify.
723 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
724 * memattr.c (info_mem_command): Constify.
725 * macrocmd.c (info_macro_command, info_macros_command): Constify.
726 * linux-fork.c (info_checkpoints_command): Constify.
727 * infrun.c (info_signals_command): Constify.
728 * inflow.c (info_terminal_command): Constify.
729 * inferior.c (info_inferiors_command): Constify.
730 (print_inferior): Constify.
731 * infcmd.c (info_program_command, info_all_registers_command)
732 (info_registers_command, info_vector_command)
733 (info_float_command): Constify.
734 (registers_info): Constify.
735 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
736 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
737 Constify.
738 * f-valprint.c (info_common_command): Constify.
739 * dcache.c (info_dcache_command): Constify.
740 (dcache_info_1): Constify.
741 * darwin-nat-info.c (info_mach_tasks_command)
742 (info_mach_task_command, info_mach_ports_command)
743 (info_mach_port_command, info_mach_threads_command)
744 (info_mach_thread_command, info_mach_regions_command)
745 (info_mach_regions_recurse_command, info_mach_region_command)
746 (info_mach_exceptions_command): Constify.
747 (get_task_from_args): Constify.
748 * cp-support.c (info_vtbl_command): Constify.
749 * breakpoint.c (info_watchpoints_command)
750 (info_tracepoints_command): Constify.
751 (info_breakpoints_command): Remove non-const overload.
752 * avr-tdep.c (avr_io_reg_read_command): Constify.
753 * auxv.c (info_auxv_command): Constify.
754 * ada-tasks.c (info_tasks_command): Constify.
755 (info_task): Constify.
756 * ada-lang.c (info_exceptions_command): Constify.
757
0b39b52e
TT
7582017-11-07 Tom Tromey <tom@tromey.com>
759
760 * solib.h (no_shared_libraries): Constify.
761 * frame.h (return_command): Constify.
762 * cli/cli-cmds.h (quit_command): Constify.
763 * top.h (quit_command, execute_command): Constify.
764 * target.h (flash_erase_command): Constify.
765 * inferior.h (set_inferior_args, attach_command): Constify.
766 * tracepoint.h (start_tracing, stop_tracing): Constify.
767 * breakpoint.h (break_command, tbreak_command)
768 (hbreak_command_wrapper, thbreak_command_wrapper)
769 (rbreak_command_wrapper, watch_command_wrapper)
770 (awatch_command_wrapper, rwatch_command_wrapper)
771 (get_tracepoint_by_number): Constify.
772 * symtab.c (info_variables_command, rbreak_command)
773 (symtab_symbol_info): Constify.
774 (info_variables_command): Add non-const overload.
775 * top.c (dont_repeat_command): Constify.
776 * breakpoint.c (ignore_command, commands_command)
777 (condition_command, tbreak_command, hbreak_command)
778 (thbreak_command, clear_command, break_command)
779 (info_breakpoints_command, watch_command, rwatch_command)
780 (awatch_command, trace_command, ftrace_command, strace_command)
781 (trace_pass_command, break_range_command, dprintf_command)
782 (agent_printf_command, get_tracepoint_by_number)
783 (watch_maybe_just_location, trace_pass_command): Constify.
784 (info_breakpoints_command): Add non-const overload.
785 * tracefile.c (tsave_command): Constify.
786 * infcmd.c (attach_command, disconnect_command, signal_command)
787 (queue_signal_command, stepi_command, nexti_command)
788 (finish_command, next_command, step_command, until_command)
789 (advance_command, jump_command, continue_command, run_command)
790 (start_command, starti_command, interrupt_command)
791 (run_command_1, set_inferior_args, step_1): Constify.
792 * inferior.c (add_inferior_command, remove_inferior_command)
793 (clone_inferior_command): Constify.
794 * linux-fork.c (checkpoint_command, restart_command): Constify.
795 * windows-nat.c (signal_event_command): Constify.
796 * guile/guile.c (guile_repl_command, guile_command): Constify.
797 * printcmd.c (x_command, display_command, printf_command)
798 (output_command, set_command, call_command, print_command)
799 (eval_command): Constify.
800 (non_const_set_command): Remove.
801 (_initialize_printcmd): Update.
802 * source.c (forward_search_command, reverse_search_command):
803 Constify.
804 * jit.c (jit_reader_load_command, jit_reader_unload_command):
805 Constify.
806 * infrun.c (handle_command): Constify.
807 * memattr.c (mem_command): Constify.
808 * stack.c (return_command, up_command, up_silently_command)
809 (down_command, down_silently_command, frame_command)
810 (backtrace_command, func_command, backtrace_command_1): Constify.
811 (backtrace_command): Add non-const overload.
812 * remote-sim.c (simulator_command): Constify.
813 * exec.c (set_section_command): Constify.
814 * tracepoint.c (tdump_command, trace_variable_command)
815 (tstatus_command, tstop_command, tstart_command)
816 (end_actions_pseudocommand, while_stepping_pseudocommand)
817 (collect_pseudocommand, teval_pseudocommand, actions_command)
818 (start_tracing, stop_tracing): Constify.
819 * value.c (init_if_undefined_command): Constify.
820 * tui/tui-stack.c (tui_update_command): Constify.
821 * tui/tui-win.c (tui_refresh_all_command)
822 (tui_set_tab_width_command, tui_set_win_height_command)
823 (tui_set_focus_command, tui_scroll_forward_command)
824 (tui_scroll_backward_command, tui_scroll_left_command)
825 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
826 (tui_set_win_height): Constify.
827 * tui/tui-layout.c (tui_layout_command): Constify.
828 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
829 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
830 (proc_untrace_sysexit_cmd): Constify.
831 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
832 (threadset_test_cmd, threadlist_update_test_cmd)
833 (threadalive_test): Constify.
834 * objc-lang.c (print_object_command): Constify.
835 * command.h (add_com): Constify.
836 * cli/cli-dump.c (restore_command): Constify.
837 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
838 (help_command, complete_command, shell_command, edit_command)
839 (list_command, disassemble_command, make_command)
840 (apropos_command, alias_command): Constify.
841 * cli/cli-script.c (document_command, define_command)
842 (while_command, if_command, validate_comname): Constify.
843 * cli/cli-decode.c (struct cmd_list_element): Change type of
844 "fun".
845 * target.c (do_monitor_command, flash_erase_command): Constify.
846 * regcache.c (reg_flush_command): Constify.
847 * reverse.c (reverse_step, reverse_next, reverse_stepi)
848 (reverse_nexti, reverse_continue, reverse_finish)
849 (save_bookmark_command, goto_bookmark_command)
850 (exec_reverse_once): Constify.
851 * python/python.c (python_interactive_command, python_command):
852 Constify.
853 * typeprint.c (ptype_command, whatis_command, whatis_exp):
854 Constify.
855 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
856 * gcore.c (gcore_command): Constify.
857
85c4be7c
TT
8582017-11-07 Tom Tromey <tom@tromey.com>
859
860 * printcmd.c (x_command): Call set_repeat_arguments.
861 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
862 * top.c (repeat_arguments): New global.
863 (set_repeat_arguments): New function.
864 (execute_command): Handle repeat_arguments.
865 (show_commands): Calls set_repeat_arguments.
866 * command.h (set_repeat_arguments): Declare.
867
022643b4
TT
8682017-11-07 Tom Tromey <tom@tromey.com>
869
870 * stack.c (backtrace_command): Use std::string.
871 (backtrace_command_1): Make "count_exp" const.
872
5614fb77
TT
8732017-11-07 Tom Tromey <tom@tromey.com>
874
875 * source.c (directory_switch, mod_path, add_path): Constify.
876 * defs.h (add_path, mod_path, directory_switch): Constify.
877 * mi/mi-cmd-env.c (env_mod_path): Constify.
878
6be9a197
TT
8792017-11-07 Tom Tromey <tom@tromey.com>
880
881 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
882 (run_command_1, continue_command, step_1, jump_command)
883 (signal_command, until_command, advance_command, finish_command)
884 (attach_command): Update.
885
c2252c0d
TT
8862017-11-07 Tom Tromey <tom@tromey.com>
887
888 * command.h (set_cmd_cfunc): Don't declare.
889 * cli/cli-decode.c (set_cmd_cfunc): Now static.
890
1ee870c5
TT
8912017-11-07 Tom Tromey <tom@tromey.com>
892
893 * stack.c (select_frame_command): Constify.
894 * cli/cli-decode.c (add_com_suppress_notification): Constify.
895 * command.h (add_com_suppress_notification): Constify.
896
ee7ddd71
TT
8972017-11-07 Tom Tromey <tom@tromey.com>
898
899 * breakpoint.c (stop_command): Constify.
900 * cli/cli-decode.c (struct cmd_list_element): Constify.
901 * command.h (add_abbrev_prefix_cmd): Constify.
902
95e95a6d
PA
9032017-11-07 Pedro Alves <palves@redhat.com>
904
905 * breakpoint.c (extract_bp_kind): New enum.
906 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
907 factored out from ...
908 (extract_bp_number_and_location): ... here.
909 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
910
cc638e86
PA
9112017-11-07 Pedro Alves <palves@redhat.com>
912
913 * breakpoint.c (extract_bp_number_and_location): Change return
914 type to void. Throw error instead of warning.
915 (enable_disable_command): Adjust.
916
d0fe4701
XR
9172017-11-07 Xavier Roirand <roirand@adacore.com>
918 Pedro Alves <palves@redhat.com>
919
920 * breakpoint.c (map_breakpoint_number_range): New, factored out
921 from ...
922 (map_breakpoint_numbers): ... here.
923 (find_location_by_number): Change parameters from string to
924 breakpoint number and location.
925 (extract_bp_number_and_location): New function.
926 (enable_disable_bp_num_loc)
927 (enable_disable_breakpoint_location_range)
928 (enable_disable_command): New functions, factored out ...
929 (enable_command, disable_command): ... these functions, and
930 adjusted to support ranges.
931 * NEWS: Document enable/disable breakpoint location range feature.
932
635dc5b2
LM
9332017-11-06 Luis Machado <luis.machado@linaro.org>
934
935 * MAINTAINERS (Write After Approval): Update my e-mail address.
936
556e5da5
PA
9372017-11-06 Pedro Alves <palves@redhat.com>
938
939 * gnu-nat.c (gnu_terminal_init): Delete.
940 (gnu_target): Don't install gnu_terminal_init.
941 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
942 (child_terminal_init): ... this function.
943
d1928160
PA
9442017-11-06 Pedro Alves <palves@redhat.com>
945
946 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
947 sgtty.h.
948 * config.in, configure: Regenerate.
949
6aa899ce
PA
9502017-11-06 Pedro Alves <palves@redhat.com>
951
952 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
953 (async_init_signals): Adjust.
954 (handle_stop_sig): Rename to ...
955 (handle_sigtstp): ... this.
956 (async_stop_sig): Rename to ...
957 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
958 SIGTSTP path.
959 * event-top.h: Move signal.h include to the top. Check SIGTSTP
960 instead of STOP_SIGNAL thoughout.
961 (handle_stop_sig): Rename to ...
962 (handle_sigtstp): ... this.
963 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
964
a94799ac
PA
9652017-11-06 Pedro Alves <palves@redhat.com>
966
967 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
968 longer set flags twice in row.
969
726e1356
PA
9702017-11-06 Pedro Alves <palves@redhat.com>
971
972 * Makefile.in (SER_HARDWIRE): Update comment.
973 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
974 * common/gdb_termios.h: Delete file.
975 * common/job-control.c: Include termios.h and unistd.h instead of
976 gdb_termios.h.
977 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
978 check.
979 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
980 Remove sgtty code.
981 * configure.ac: No longer check for termio.h and sgtty.h.
982 * configure: Regenerate.
983 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
984 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
985 Replace PROCESS_GROUP_TYPE references with pid_t references
986 throughout.
987 (gdb_getpgrp): Delete.
988 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
989 (child_terminal_inferior): Remove comment. Remove sgtty code.
990 (child_terminal_ours_1): Use tcgetpgrp directly instead of
991 gdb_getpgrp. Use serial_set_tty_state instead aof
992 serial_noflush_set_tty_state. Remove sgtty code.
993 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
994 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
995 (inferior_process_group): Now returns pid_t.
996 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
997 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
998 * ser-event.c (serial_event_ops): Update.
999 * ser-go32.c (dos_noflush_set_tty_state): Delete.
1000 (dos_ops): Update.
1001 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
1002 * ser-pipe.c (pipe_ops): Update.
1003 * ser-tcp.c (tcp_ops): Update.
1004 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
1005 HAVE_TERMIOS checks.
1006 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
1007 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
1008 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
1009 assume termios.
1010 (hardwire_noflush_set_tty_state): Delete.
1011 (hardwire_print_tty_state, hardwire_drain_output)
1012 (hardwire_flush_output, hardwire_flush_input)
1013 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
1014 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
1015 code, and assume termios.
1016 (hardwire_ops): Update.
1017 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
1018 * serial.c (serial_noflush_set_tty_state): Delete.
1019 * serial.h (serial_noflush_set_tty_state): Delete.
1020 (serial_ops::noflush_set_tty_state): Delete.
1021
1cfb73db
UW
10222017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1023
1024 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
1025 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
1026 (COMMON_OBS): Remove doublest.o and dfp.o.
1027 Do not build target-float.c (instead of doublest.c)
1028 with -Wformat-nonliteral.
1029
1030 * doublest.c: Remove file.
1031 * doublest.h: Remove file.
1032 * dfp.c: Remove file.
1033 * dfp.h: Remove file.
1034
1035 * target-float.c: Do not include "doublest.h" and "dfp.h".
1036 (DOUBLEST): Move here from doublest.h.
1037 (enum float_kind): Likewise.
1038 (FLOATFORMAT_CHAR_BIT): Likewise.
1039 (FLOATFORMAT_LARGEST_BYTES): Likewise.
1040 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
1041 (floatformat_precision): Likewise.
1042 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
1043 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
1044 Likewise.
1045 (host_float_format, host_double_format, host_long_double_format):
1046 Likewise.
1047 (floatformat_to_string, floatformat_from_string): Likewise.
1048 (floatformat_to_doublest): Likewise. Also, inline the original
1049 convert_floatformat_to_doublest.
1050 (floatformat_from_doublest): Likewise. Also, inline the original
1051 convert_floatformat_from_doublest.
1052
1053 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
1054 (MAX_DECIMAL_STRING): Move here from dfp.c.
1055 (match_endianness): Likewise.
1056 (set_decnumber_context, decimal_check_errors): Likewise.
1057 (decimal_from_number, decimal_to_number): Likewise.
1058 (decimal_to_string, decimal_from_string): Likewise. Make static.
1059 (decimal_from_longest, decimal_from_ulongest): Likewise.
1060 (decimal_to_longest): Likewise.
1061 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
1062 (decimal_convert): Likewise.
1063
b07e9c46
UW
10642017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1065
1066 * doublest.c: Do not include "gdbtypes.h".
1067 (extract_typed_floating): Remove.
1068 (store_typed_floating): Remove.
1069 (convert_typed_floating): Remove.
1070 * doublest.h (struct type): Remove.
1071 (DOUBLEST_PRINT_FORMAT): Remove.
1072 (DOUBLEST_SCAN_FORMAT): Remove.
1073 (extract_typed_floating): Remove.
1074 (store_typed_floating): Remove.
1075 (convert_typed_floating): Remove.
1076
1077 * dfp.c (decimal_from_doublest): Remove.
1078 (decimal_to_doublest): Remove.
1079 * dfp.h: Do not include "doublest.h".
1080 (decimal_from_doublest): Remove.
1081 (decimal_to_doublest): Remove.
1082
1083 * value.c: Do not include "doublest.h" and "dfp.h".
1084 (value_as_double): Remove.
1085 (unpack_double): Remove.
1086 (value_from_double): Remove.
1087 (value_from_decfloat): Remove.
1088 * value.h: Do not include "doublest.h".
1089 (value_as_double): Remove.
1090 (unpack_double): Remove.
1091 (value_from_double): Remove.
1092 (value_from_decfloat): Remove.
1093
3b2ca824
UW
10942017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1095
1096 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
1097 (i386_extract_return_value): Use target_float_convert.
1098 (i386_store_return_value): Likewise.
1099 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
1100 (i387_value_to_register): Likewise.
1101 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
1102 (ia64_register_to_value): Use target_float_convert.
1103 (ia64_value_to_register): Likewise.
1104 (ia64_extract_return_value): Likewise.
1105 (ia64_store_return_value): Likewise.
1106 (ia64_push_dummy_call): Likewise.
1107 * m68k-tdep.c: Include "target-float.h".
1108 (m68k_register_to_value): Use target_float_convert.
1109 (m68k_value_to_register): Likewise.
1110 (m68k_svr4_extract_return_value): Likewise.
1111 (m68k_svr4_store_return_value): Likewise.
1112 * ppc-sysv-tdep.c: Include "target-float.h".
1113 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
1114 (do_ppc_sysv_return_value): Likewise.
1115 (ppc64_sysv_abi_push_freg): Likewise.
1116 (ppc64_sysv_abi_return_value_base): Likewise.
1117 * rs6000-aix-tdep.c: Include "target-float.h".
1118 (rs6000_push_dummy_call): Use target_float_convert.
1119 (rs6000_return_value): Likewise.
1120 * rs6000-lynx178-tdep.c: Include "target-float.h".
1121 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
1122 (rs6000_lynx178_return_value): Likewise.
1123 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
1124 (rs6000_register_to_value): Use target_float_convert.
1125 (rs6000_value_to_register): Likewise.
1126 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
1127 (arm_extract_return_value): Use target_float_convert.
1128 (arm_store_return_value): Likewise.
1129 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
1130 (sh_register_convert_to_virtual): Use target_float_convert.
1131 (sh_register_convert_to_raw): Likewise.
1132 * sh64-tdep.c: Include "target-float.h".
1133 (sh64_extract_return_value): Use target_float_convert.
1134 (sh64_register_convert_to_virtual): Likewise.
1135 (sh64_register_convert_to_raw): Likewise. Fix argument types.
1136
14ad9311
UW
11372017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1138
1139 * target-float.c (floatformat_to_host_double): New function.
1140 (floatformat_from_host_double): Likewise.
1141 (target_float_to_host_double): Likewise.
1142 (target_float_from_host_double): Likewise.
1143 * target-float.h (target_float_to_host_double): Add prototype.
1144 (target_float_from_host_double): Likewise.
1145
1146 * guile/scm-value.c: Include "target-float.h".
1147 (gdbscm_value_to_real): Use target_float_to_host_double.
1148 Handle integer source values via value_as_long.
1149 * guile/scm-math.c: Include "target-float.h". Do not include
1150 "doublest.h", "dfp.h", and "expression.h".
1151 (vlscm_convert_typed_number): Use target_float_from_host_double.
1152 (vlscm_convert_number): Likewise.
1153
1154 * python/py-value.c (valpy_float): Use target_float_to_host_double.
1155 (convert_value_from_python): Use target_float_from_host_double.
1156
50eff16b
UW
11572017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1158
1159 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
1160 (cast_from_fixed): Likewise.
1161 (ada_scaling_type): New function.
1162 (ada_delta): Return value instead of DOUBLEST. Perform target
1163 arithmetic instead of host arithmetic.
1164 (scaling_factor): Rename to ...
1165 (ada_scaling_factor) ... this. Make non-static. Return value instead
1166 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
1167 (ada_fixed_to_float): Remove.
1168 (ada_float_to_fixed): Remove.
1169 * ada-lang.h (ada_fixed_to_float): Remove.
1170 (ada_float_to_fixed): Remove.
1171 (ada_delta): Return value instead of DOUBLEST.
1172 (ada_scaling_factor): Add prototype.
1173
1174 * ada-typeprint.c: Include "target-float.h".
1175 (print_fixed_point_type): Perform target arithmetic instead of
1176 host arithmetic.
1177 * ada-valprint.c: Include "target-float.h".
1178 (ada_val_print_num): Perform target arithmetic instead of
1179 host arithmetic for fixed-point types.
1180
66c02b9e
UW
11812017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1182
1183 * target-float.c: Include <math.h>.
1184 (floatformat_binop): New function.
1185 (floatformat_compare): Likewise.
1186 (target_float_binop): Likewise.
1187 (target_float_compare): Likewise.
1188 * target-float.h: Include "expression.h".
1189 (target_float_binop): Add prototype.
1190 (target_float_compare): Likewise.
1191
1192 * valarith.c: Do not include "doublest.h" and "dfp.h".
1193 Include "common/byte-vector.h".
1194 (value_args_as_decimal): Remove, replace by ...
1195 (value_args_as_target_float): ... this function. Handle both
1196 binary and decimal target floating-point formats.
1197 (scalar_binop): Handle both binary and decimal FP using
1198 value_args_as_target_float and target_float_binop.
1199 (value_equal): Handle both binary and decimal FP using
1200 value_args_as_target_float and target_float_compare.
1201 (value_less): Likewise.
1202 (value_pos): Handle all scalar types as simple copy.
1203 (value_neg): Handle all scalar types via BINOP_SUB from 0.
1204 * dfp.c (decimal_binop): Throw error instead of internal_error
1205 when called with an unsupported operation code.
1206
f69fdf9b
UW
12072017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1208
1209 * target-float.c (target_float_to_string): New function.
1210 (target_float_from_string): New function.
1211 * target-float.h (target_float_to_string): Add prototype.
1212 (target_float_from_string): Add prototype.
1213
1214 * valprint.c: Include "target-float.h". Do not include
1215 "doublest.h" and "dfp.h".
1216 (print_floating): Use target_float_to_string.
1217 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
1218 (printf_floating): Use target_float_to_string.
1219 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
1220 (print_i387_value): Use target_float_to_string.
1221 * mips-tdep.c: Include "target-float.h".
1222 (mips_print_fp_register): Use target_float_to_string.
1223 * sh64-tdep.c: Include "target-float.h".
1224 (sh64_do_fp_register): Use target_float_to_string.
1225
1226 * parse.c: Include "target-float.h". Do not include
1227 "doublest.h" and "dfp.h".
1228 (parse_float): Use target_float_from_string.
1229 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
1230 (define_symbol): Use target_float_from_string.
1231 * gdbarch-selftests.c: Include "target-float.h".
1232 (register_to_value_test): Use target_float_from_string.
1233
70100014
UW
12342017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1235
1236 * Makefile.c (SFILES): Add target-float.c.
1237 (HFILES_NO_SRCDIR): Add target-float.h.
1238 (COMMON_OBS): Add target-float.o.
1239 * target-float.h: New file.
1240 * target-float.c: New file.
1241
1242 * doublest.c (floatformat_classify): Fix detection of float_zero.
1243
1244 * gdbtypes.c (is_floating_type): New function.
1245 * gdbtypes.h (is_floating_type): Add prototype.
1246
1247 * value.c: Do not include "floatformat.h".
1248 (unpack_double): Use target_float_is_valid.
1249 (is_floating_value): New function.
1250 * value.h (is_floating_value): Add prototype-
1251
1252 * valarith.c: Include "target-float.h".
1253 (value_logical_not): Use target_float_is_zero.
1254
1255 * python/py-value.c: Include "target-float.h".
1256 (valpy_nonzero): Use target_float_is_zero.
1257
ab4b1c46
TT
12582017-11-04 Tom Tromey <tom@tromey.com>
1259
1260 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
1261
454dafbd
TT
12622017-11-04 Tom Tromey <tom@tromey.com>
1263
1264 * breakpoint.c (set_momentary_breakpoint): Return
1265 breakpoint_up.
1266 (until_break_command): Update.
1267 (new_until_break_fsm): Change argument types to
1268 breakpoint_up.
1269 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
1270 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
1271 Remove.
1272 * infcmd.c (finish_forward): Update.
1273 * breakpoint.h (set_momentary_breakpoint)
1274 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
1275 (make_cleanup_delete_breakpoint): Remove.
1276 (struct breakpoint_deleter): New.
1277 (breakpoint_up): New typedef.
1278 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
1279 (insert_exception_resume_breakpoint): Update.
1280 (insert_exception_resume_from_probe): Update.
1281 (insert_longjmp_resume_breakpoint): Update.
1282 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
1283 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
1284 * infcall.c (call_function_by_hand_dummy): Update
1285
331b71e5
TT
12862017-11-04 Tom Tromey <tom@tromey.com>
1287
1288 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
1289
9f584b37
TT
12902017-11-04 Tom Tromey <tom@tromey.com>
1291
1292 * linux-tdep.c (linux_core_info_proc_mappings): Use
1293 gdb::def_vector.
1294 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
1295 "size" argument.
1296 (linux_corefile_thread): Update.
1297 (linux_make_corefile_notes): Remove unused variable.
1298
779bc38e
TT
12992017-11-04 Tom Tromey <tom@tromey.com>
1300
1301 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
1302 gdb::byte_vector.
1303
ed2b3126
TT
13042017-11-04 Tom Tromey <tom@tromey.com>
1305
1306 * objfiles.c (do_free_objfile_cleanup): Remove.
1307 * compile/compile-object-load.c (compile_object_load): Update.
1308 * objfiles.h (make_cleanup_free_objfile): Remove.
1309
7f6743fd
TT
13102017-11-04 Tom Tromey <tom@tromey.com>
1311
1312 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
1313 (adi_read_versions): Change "tags" to "gdb_byte *".
1314 (adi_print_versions): Likewise.
1315
c80049d3
TT
13162017-11-04 Tom Tromey <tom@tromey.com>
1317
1318 * breakpoint.c
1319 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
1320 from start_rbreak_breakpoints.
1321 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
1322 * breakpoint.h (class scoped_rbreak_breakpoints): New.
1323 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
1324 * symtab.c (do_end_rbreak_breakpoints): Remove.
1325 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
1326
167b0be1
TT
13272017-11-04 Tom Tromey <tom@tromey.com>
1328
1329 * cp-namespace.c (reset_directive_searched): Remove.
1330 (cp_lookup_symbol_via_imports): Use scoped_restore.
1331 * cp-support.c (reset_directive_searched): Remove.
1332 (make_symbol_overload_list_using): Use scoped_restore.
1333 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
1334 (reset_directive_searched): Remove.
1335
5eae7aea
TT
13362017-11-04 Tom Tromey <tom@tromey.com>
1337
1338 * symfile.c (find_separate_debug_file_by_debuglink): Use
1339 unique_xmalloc_ptr.
1340
c6bcad5f
TT
13412017-11-04 Tom Tromey <tom@tromey.com>
1342
1343 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
1344 type of "info".
1345 (compute_stack_depth): Likewise.
1346 (do_compile_dwarf_expr_to_c): Use std::vector.
1347
20dcd8ca
TT
13482017-11-04 Tom Tromey <tom@tromey.com>
1349
1350 * compile/compile-object-load.c (link_callbacks_einfo): Use
1351 std::string.
1352
33c7c59d
TT
13532017-11-04 Tom Tromey <tom@tromey.com>
1354
1355 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
1356 Use scoped_free_pendings.
1357 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
1358 scoped_free_pendings.
1359 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
1360 (xcoff_initial_scan): Likewise.
1361 * buildsym.c (reset_symtab_globals): Update comment.
1362 (scoped_free_pendings): Rename from really_free_pendings.
1363 (prepare_for_building): Update comment.
1364 (buildsym_init): Likewise.
1365 * buildsym.h (class scoped_free_pendings): New class.
1366 (really_free_pendings): Don't declare.
1367
67fa57cf
UW
13682017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
1369
1370 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
1371 output when converting a zero value to a special byteorder format.
1372
f26ae15b
YQ
13732017-11-02 Yao Qi <yao.qi@linaro.org>
1374
1375 * frame.c (do_frame_register_read): Remove aspace.
1376 * jit.c (jit_frame_sniffer): Likwise.
1377 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
1378 * regcache.c (regcache::regcache): Pass nullptr.
1379 (regcache_print): Caller updated.
1380 * regcache.h (regcache::regcache): Remove one constructor
1381 parameter aspace.
1382
6c6e9412
YQ
13832017-11-02 Yao Qi <yao.qi@linaro.org>
1384
1385 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
1386
8b86c959
YQ
13872017-11-02 Yao Qi <yao.qi@linaro.org>
1388
1389 * breakpoint.c (insert_single_step_breakpoints): Update.
1390 * frame.c (struct frame_info) <aspace>: Add const.
1391 (frame_save_as_regcache): Add const.
1392 (get_frame_address_space): Return const address_space *.
1393 * frame.h (get_frame_address_space): Update declaration.
1394 * infrun.c (struct step_over_info) <aspace>: Add const.
1395 (set_step_over_info): Make aspace const.
1396 (displaced_step_prepare_throw): Change variable const.
1397 (resume): Likewise.
1398 (proceed): Likewise.
1399 (adjust_pc_after_break): Likewise.
1400 (save_waitstatus): Likewise.
1401 (handle_signal_stop): Likewise.
1402 (keep_going_pass_signal): Likewise.
1403 * jit.c (jit_frame_sniffer): Add const.
1404 * mips-tdep.c (mips_single_step_through_delay): Likewise.
1405 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
1406 * record-full.c (record_full_wait_1): Likewise.
1407 * regcache.c (regcache::regcache): Change parameter to const.
1408 * regcache.h (regcache::regcache): Likewise.
1409 (regcache::aspace): Return const address_space *.
1410 (regcache) <m_aspace>: Add const.
1411
a01bda52
YQ
14122017-11-02 Yao Qi <yao.qi@linaro.org>
1413
1414 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
1415 * frame.c (create_sentinel_frame): Likewise.
1416 * infrun.c (displaced_step_prepare_throw): Likewise.
1417 (resume): Likewise.
1418 (thread_still_needs_step_over_bp): Likewise.
1419 (proceed): Likewise.
1420 (do_target_wait): Likewise.
1421 (adjust_pc_after_break): Likewise.
1422 (handle_syscall_event): Likewise.
1423 (save_waitstatus): Likewise.
1424 (handle_inferior_event_1): Likewise.
1425 (handle_signal_stop): Likewise.
1426 (keep_going_pass_signal): Likewise.
1427 * linux-nat.c (status_callback): Likewise.
1428 (save_stop_reason): Likewise.
1429 (resume_stopped_resumed_lwps): Likewise.
1430 * record-full.c (record_full_exec_insn): Likewise.
1431 (record_full_wait_1): Likewise.
1432 * regcache.c (get_regcache_aspace): Remove.
1433 * regcache.h (get_regcache_aspace): Remove.
1434
d999647b
YQ
14352017-11-02 Yao Qi <yao.qi@linaro.org>
1436
1437 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
1438 (init_regcache_descr): Use gdbarch_num_regs.
1439 (regcache::regcache): Likewise.
1440 (regcache::get_register_status): Likewise.
1441 (regcache::assert_raw_regnum): Likewise.
1442 (regcache::cooked_read): Likewise.
1443 (regcache::cooked_read_value): Likewise.
1444 (regcache::cooked_write): Likewise.
1445 (regcache::dump): Likewise.
1446 (regcache::num_raw_registers): New method.
1447 * regcache.h (class regcache) <num_raw_registers>: New.
1448
4e888c28
YQ
14492017-11-02 Yao Qi <yao.qi@linaro.org>
1450
1451 * regcache.c (regcache::assert_regnum): New method.
1452 (regcache::invalidate): Call assert_regnum.
1453 (regcache::raw_update): Likewise.
1454 (regcache::raw_write): Likewise.
1455 (regcache::raw_read_part): Likewise.
1456 (regcache::raw_write_part): Likewise.
1457 (regcache::raw_supply): Likewise.
1458 (regcache::raw_supply_integer): Likewise.
1459 (regcache::raw_supply_zeroed): Likewise.
1460 (regcache::raw_collect): Likewise.
1461 (regcache::raw_collect_integer): Likewise.
1462 * regcache.h (regcache::assert_regnum): Declare.
1463
2e1b49b3
YQ
14642017-11-02 Yao Qi <yao.qi@linaro.org>
1465
1466 * regcache.c (regcache::dump): Remove code.
1467
6c5218df
YQ
14682017-11-02 Yao Qi <yao.qi@linaro.org>
1469
1470 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
1471 Remove.
1472 <sizeof_cooked_register_status>: Remove.
1473 (init_regcache_descr): Update.
1474 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
1475 (regcache::save): Likewise.
1476 (regcache::dump): Likewise.
1477
dcc31d28
JB
14782017-11-01 James Bowman <james.bowman@ftdichip.com>
1479
1480 * ft32-tdep.c (ft32_fetch_instruction): New function.
1481 (ft32_analyze_prologue): Use ft32_fetch_instruction().
1482
3a87ae65
SM
14832017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
1484
1485 * cli/cli-script.c (execute_control_command): Rename to ...
1486 (execute_control_command_1): ... this.
1487 (execute_control_command): New function.
1488
09b847f3
SM
14892017-10-31 Simon Marchi <simon.marchi@ericsson.com>
1490
1491 * tracepoint.c (tfind_command): Remove const_cast.
1492
f871c485
MG
14932017-10-30 Mike Gulick <mgulick@mathworks.com>
1494
1495 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
1496
b020ff80
SM
14972017-10-30 Simon Marchi <simon.marchi@ericsson.com>
1498
1499 * common/common-utils.h (in_inclusive_range): New function.
1500 * arm-tdep.c (arm_record_extension_space): Use
1501 in_inclusive_range.
1502 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
1503 * cris-tdep.c (cris_spec_reg_applicable): Use
1504 in_inclusive_range.
1505
1b81856f
PA
15062017-10-30 Pedro Alves <palves@redhat.com>
1507 Simon Marchi <simon.marchi@ericsson.com>
1508
1509 * remote.c (remote_set_syscall_catchpoint): Build a std::string
1510 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
1511
31b833b3
PA
15122017-10-30 Pedro Alves <palves@redhat.com>
1513
1514 * common/common-utils.c (string_appendf, string_vappendf): New
1515 functions.
1516 * common/common-utils.h (string_appendf, string_vappendf): New
1517 declarations.
1518 * unittests/common-utils-selftests.c (string_appendf_func)
1519 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
1520 (string_vappendf_tests): New functions.
1521 (_initialize_common_utils_selftests): Register "string_appendf" and
1522 "string_vappendf tests".
1523
4a250334
PA
15242017-10-30 Pedro Alves <palves@redhat.com>
1525
1526 * unittests/common-utils-selftests.c (format_func): New typedef.
1527 (string_printf_tests, string_vprintf_tests): Tests factored out
1528 and merged to ...
1529 (test_format_func): ... this new function.
1530 (string_printf_tests, string_vprintf_tests): Reimplement on top of
1531 test_format_func.
1532
16c5c17e
SM
15332017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1534
1535 * darwin-nat.c: Remove include of gdb.h.
1536
7ca51576
SM
15372017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1538
1539 * xtensa-xtregs.c: Fix formatting issues.
1540
c1342859
SM
15412017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1542
1543 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
1544
484d8d36
MD
15452017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
1546
1547 PR python/21213
1548 * python/py-infthread.c (thpy_get_inferior): Increment reference
1549 of inferior before returning it.
1550
b5540b5f
SM
15512017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1552
1553 * unittests/common-utils-selftests.c (format): Add
1554 ATTRIBUTE_PRINTF.
1555
5a9dcda1
SM
15562017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
1557
1558 * xml-syscall.c (struct syscall_desc): Add constructor.
1559 <name>: Change type to std::string.
1560 (syscall_desc_up): New typedef.
1561 (syscall_desc_p): Remove typeder.
1562 (DEF_VEC_P(syscall_desc_p)): Remove.
1563 (struct syscall_group_desc): Add constructor.
1564 <name>: Change type to std::string.
1565 <syscalls>: Change type to std::vector.
1566 (syscall_group_desc_up): New typedef.
1567 (syscall_group_desc_p): Remove typedef.
1568 (DEF_VEC_P(syscall_group_desc_p)): Remove.
1569 (struct syscalls_info) <syscalls>: Change type to std::vector of
1570 unique_ptr.
1571 <groups>: Likewise.
1572 <my_gdb_datadir>: Change type to std::string.
1573 (syscalls_info_up): New typedef.
1574 (allocate_syscalls_info): Remove.
1575 (syscalls_info_free_syscalls_desc): Remove.
1576 (syscalls_info_free_syscall_group_desc): Remove.
1577 (free_syscalls_info): Remove.
1578 (make_cleanup_free_syscalls_info): Remove.
1579 (syscall_group_create_syscall_group_desc): Adjust.
1580 (syscall_group_add_syscall): Adjust.
1581 (syscall_create_syscall_desc): Adjust.
1582 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
1583 (init_syscalls_info): Adjust.
1584 (syscall_group_get_group_by_name): Adjust.
1585 (xml_get_syscall_number): Adjust.
1586 (xml_get_syscall_name): Adjust.
1587 (xml_list_of_syscalls): Adjust.
1588 (xml_list_syscalls_by_group): Adjust.
1589 (xml_list_of_groups): Adjust.
1590
45461e0d
SM
15912017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1592
1593 * probe.h: Don't include gdb_vecs.h.
1594 (DEF_VEC_P (probe_p)): Remove.
1595 (find_probes_in_objfile): Return an std::vector.
1596 * probe.c (find_probes_in_objfile): Likewise.
1597 * breakpoint.c (breakpoint_objfile_data)
1598 <longjmp_probes>: Change type to std::vector.
1599 <exception_probes>: Likewise.
1600 (free_breakpoint_probes): Don't manually free vectors.
1601 (create_longjmp_master_breakpoint): Adjust.
1602 (create_exception_master_breakpoint): Adjust.
1603 * solib-svr4.c (svr4_create_probe_breakpoints): Change
1604 parameter type, adjust.
1605 (svr4_create_solib_event_breakpoints): Adjust.
1606
43dce439
SM
16072017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1608
1609 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
1610 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
1611 with new.
1612 (free_breakpoint_probes): Rename to ...
1613 (free_breakpoint_objfile_data): ... this, and call delete on
1614 bp_objfile_data..
1615
6a1b9516
SM
16162017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
1617
1618 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
1619 (loaded_script_ptr): Remove typedef.
1620 (DEF_VEC_P (loaded_script_ptr)): Remove.
1621 (struct collect_matching_scripts_data): Add constructor.
1622 <scripts_p>: Change type to (pointer to) std::vector.
1623 (collect_matching_scripts_data): Adjust.
1624 (sort_scripts_by_name): Make suitable for std::sort.
1625 (print_scripts): Don't sort vector, adjust to std::vector.
1626 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
1627
593e3209
SM
16282017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1629
1630 * symfile.c (filename_language): Make struct, not typedef. Add
1631 constructor.
1632 <ext>: Change type to std::string.
1633 (DEF_VEC_O (filename_language)): Remove.
1634 (filename_language_table): Change type to std::vector.
1635 (add_filename_language): Adjust.
1636 (set_ext_lang_command): Adjust.
1637 (info_ext_lang_command): Adjust.
1638 (deduce_language_from_filename): Adjust.
1639 (class scoped_restore_filename_language_table): Remove.
1640 (test_filename_language): Use scoped_restore.
1641 (test_set_ext_lang_command): Use scoped_restore, adjust to
1642 std::vector change.
1643
32fa66eb
SM
16442017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1645
1646 * symfile.c: Include selftest.h.
1647 (class scoped_restore_filename_language_table): New.
1648 (test_filename_language): New test.
1649 (test_set_ext_lang_command): New test.
1650 (_initialize_symfile): Register tests.
1651
4a27f119
KS
16522017-10-27 Keith Seitz <keiths@redhat.com>
1653
1654 * breakpoint.c (print_breakpoint_location): Use the symbol saved
1655 in the bp_location, falling back to find_pc_sect_function when
1656 needed.
1657 (add_location_to_breakpoint): Save sal->symbol.
1658 * breakpoint.h (struct bp_location) <symbol>: New field.
1659 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
1660 * symtab.h (struct symtab_and_line) <symbol>: New field.
1661
a43f3893
PF
16622017-10-26 Patrick Frants <osscontribute@gmail.com>
1663
7453e6b2 1664 PR gdb/13669
a43f3893
PF
1665 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
1666 to rewind obstack.
1667
23cc4e1b
PA
16682017-10-26 Pedro Alves <palves@redhat.com>
1669
1670 * remote.c (remote_async_terminal_ours_p): Delete.
1671 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
1672 Remove references to 'remote_async_terminal_ours_p'.
1673
6abc18bb
YQ
16742017-10-26 Yao Qi <yao.qi@linaro.org>
1675
1676 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
1677
bd522513
YQ
16782017-10-26 Yao Qi <yao.qi@linaro.org>
1679
1680 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
1681 aspace const.
1682 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
1683 Likewise.
1684 * breakpoint.c (bpstat_check_location): Remove cast.
1685 (breakpoint_hit_catch_fork): Make aspce const.
1686 (breakpoint_hit_catch_solib): Likewise.
1687 (breakpoint_hit_catch_exec): Likewise.
1688 (breakpoint_hit_ranged_breakpoint): Likewise.
1689 (breakpoint_hit_watchpoint): Likewise.
1690 (base_breakpoint_breakpoint_hit): Likewise.
1691 (bkpt_breakpoint_hit): Likewise.
1692 (dprintf_breakpoint_hit): Likewise.
1693 (tracepoint_breakpoint_hit): Likewise.
1694 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
1695
accd0bcd
YQ
16962017-10-26 Yao Qi <yao.qi@linaro.org>
1697
1698 * breakpoint.c (breakpoint_location_address_match): Change
1699 "struct address_space *" to "const address_space".
1700 (breakpoint_location_address_range_overlap): Likewise.
1701 (breakpoint_here_p): Likewise.
1702 (breakpoint_in_range_p): Likewise.
1703 (moribund_breakpoint_here_p): Likewise.
1704 (bp_location_inserted_here_p): Likewise.
1705 (software_breakpoint_inserted_here_p): Likewise.
1706 (hardware_breakpoint_inserted_here_p): Likewise.
1707 (hardware_watchpoint_inserted_in_range): Likewise.
1708 (bpstat_check_location): Likewise.
1709 (bpstat_stop_status): Likewise.
1710 (breakpoint_address_match): Likewise.
1711 (breakpoint_address_match_range): Likewise.
1712 (breakpoint_location_address_match): Likewise.
1713 (breakpoint_location_address_range_overlap): Likewise.
1714 (insert_single_step_breakpoint): Likewise.
1715 (breakpoint_has_location_inserted_here): Likewise.
1716 (single_step_breakpoint_inserted_here_p): Likewise.
1717 (pc_at_non_inline_function): Likewise.
1718 * breakpoint.h (bpstat_stop_status): Update declaration.
1719 (breakpoint_here_p): Likewise.
1720 (breakpoint_in_range_p): Likewise.
1721 (moribund_breakpoint_here_p): Likewise.
1722 (breakpoint_inserted_here_p): Likewise.
1723 (software_breakpoint_inserted_here_p): Likewise.
1724 (hardware_breakpoint_inserted_here_p): Likewise.
1725 (breakpoint_has_location_inserted_here): Likewise.
1726 (single_step_breakpoint_inserted_here_p): Likewise.
1727 (hardware_watchpoint_inserted_in_range): Likewise.
1728 (breakpoint_address_match): Likewise.
1729 (insert_single_step_breakpoint): Likewise.
1730 (pc_at_non_inline_function): Likewise.
1731 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
1732 * record.c (record_check_stopped_by_breakpoint): Likewise.
1733 * record.h (record_check_stopped_by_breakpoint): Likewise.
1734 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
1735
ac7936df
YQ
17362017-10-25 Yao Qi <yao.qi@linaro.org>
1737
1738 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
1739 regcache->arch () instead get_regcache_arch.
1740 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
1741 Likewise.
1742 (aarch64_fbsd_store_inferior_registers): Likewise.
1743 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
1744 (store_gregs_to_thread): Likewise.
1745 (fetch_fpregs_from_thread): Likewise.
1746 (store_fpregs_to_thread): Likewise.
1747 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
1748 (aarch64_store_return_value): Likewise.
1749 (aarch64_software_single_step): Likewise.
1750 * aix-thread.c (aix_thread_wait): Likewise.
1751 (supply_reg32): Likewise.
1752 (supply_sprs64): Likewise.
1753 (supply_sprs32): Likewise.
1754 (fill_gprs64): Likewise.
1755 (fill_gprs32): Likewise.
1756 (fill_sprs64): Likewise.
1757 (fill_sprs32): Likewise.
1758 (store_regs_user_thread): Likewise.
1759 (store_regs_kernel_thread): Likewise.
1760 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
1761 (alphabsd_store_inferior_registers): Likewise.
1762 * alpha-tdep.c (alpha_extract_return_value): Likewise.
1763 (alpha_store_return_value): Likewise.
1764 (alpha_deal_with_atomic_sequence): Likewise.
1765 (alpha_next_pc): Likewise.
1766 (alpha_software_single_step): Likewise.
1767 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
1768 (amd64bsd_store_inferior_registers): Likewise.
1769 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
1770 Likewise.
1771 (amd64_linux_store_inferior_registers): Likewise.
1772 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
1773 (amd64_collect_native_gregset): Likewise.
1774 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
1775 (amd64obsd_collect_uthread): Likewise.
1776 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
1777 (amd64_collect_fpregset): Likewise.
1778 (amd64_supply_fxsave): Likewise.
1779 (amd64_supply_xsave): Likewise.
1780 (amd64_collect_fxsave): Likewise.
1781 (amd64_collect_xsave): Likewise.
1782 * arc-tdep.c (arc_write_pc): Likewise.
1783 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
1784 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
1785 (arm_fbsd_store_inferior_registers): Likewise.
1786 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
1787 (store_vfp_regs): Likewise.
1788 (arm_linux_fetch_inferior_registers): Likewise.
1789 (arm_linux_store_inferior_registers): Likewise.
1790 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
1791 (arm_linux_sigreturn_next_pc): Likewise.
1792 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
1793 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
1794 (fetch_register): Likewise.
1795 (store_register): Likewise.
1796 * arm-tdep.c (arm_is_thumb): Likewise.
1797 (displaced_in_arm_mode): Likewise.
1798 (bx_write_pc): Likewise.
1799 (arm_get_next_pcs_addr_bits_remove): Likewise.
1800 (arm_software_single_step): Likewise.
1801 (arm_extract_return_value): Likewise.
1802 (arm_store_return_value): Likewise.
1803 (arm_write_pc): Likewise.
1804 * bfin-tdep.c (bfin_extract_return_value): Likewise.
1805 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
1806 (bsd_uthread_store_registers): Likewise.
1807 * core-regset.c (fetch_core_registers): Likewise.
1808 * corelow.c (get_core_registers): Likewise.
1809 * cris-tdep.c (cris_store_return_value): Likewise.
1810 (cris_extract_return_value): Likewise.
1811 (find_step_target): Likewise.
1812 (find_step_target): Likewise.
1813 (cris_software_single_step): Likewise.
1814 * ctf.c (ctf_fetch_registers): Likewise.
1815 * darwin-nat.c (cancel_breakpoint): Likewise.
1816 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
1817 * frv-tdep.c (frv_extract_return_value): Likewise.
1818 * ft32-tdep.c (ft32_store_return_value): Likewise.
1819 (ft32_extract_return_value): Likewise.
1820 * go32-nat.c (fetch_register): Likewise.
1821 (go32_fetch_registers): Likewise.
1822 (go32_store_registers): Likewise.
1823 (store_register): Likewise.
1824 * h8300-tdep.c (h8300_extract_return_value): Likewise.
1825 (h8300_store_return_value): Likewise.
1826 * hppa-linux-nat.c (fetch_register): Likewise.
1827 (store_register): Likewise.
1828 (hppa_linux_fetch_inferior_registers): Likewise.
1829 (hppa_linux_store_inferior_registers): Likewise.
1830 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
1831 (i386_darwin_store_inferior_registers): Likewise.
1832 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
1833 (gnu_store_registers): Likewise.
1834 * i386-linux-nat.c (fetch_register): Likewise.
1835 (store_register): Likewise.
1836 (supply_gregset): Likewise.
1837 (fill_gregset): Likewise.
1838 (i386_linux_fetch_inferior_registers): Likewise.
1839 (i386_linux_store_inferior_registers): Likewise.
1840 (i386_linux_resume): Likewise.
1841 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
1842 Likewise.
1843 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
1844 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
1845 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
1846 (i386obsd_collect_uthread): Likewise.
1847 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
1848 (i386_supply_gregset): Likewise.
1849 (i386_collect_gregset): Likewise.
1850 (i386_supply_fpregset): Likewise.
1851 (i386_collect_fpregset): Likewise.
1852 (i386_mpx_bd_base): Likewise.
1853 * i386-v4-nat.c (supply_fpregset): Likewise.
1854 (fill_fpregset): Likewise.
1855 * i387-tdep.c (i387_supply_fsave): Likewise.
1856 (i387_collect_fsave): Likewise.
1857 (i387_supply_fxsave): Likewise.
1858 (i387_collect_fxsave): Likewise.
1859 (i387_supply_xsave): Likewise.
1860 (i387_collect_xsave): Likewise.
1861 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
1862 (ia64_linux_store_registers): Likewise.
1863 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
1864 (ia64_extract_return_value): Likewise.
1865 (ia64_store_return_value): Likewise.
1866 (find_func_descr): Likewise.
1867 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
1868 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
1869 (inf_ptrace_store_registers): Likewise.
1870 * infrun.c (use_displaced_stepping): Likewise.
1871 (displaced_step_prepare_throw): Likewise.
1872 (resume): Likewise.
1873 (proceed): Likewise.
1874 (do_target_wait): Likewise.
1875 (adjust_pc_after_break): Likewise.
1876 (handle_inferior_event_1): Likewise.
1877 (handle_signal_stop): Likewise.
1878 (save_infcall_suspend_state): Likewise.
1879 (restore_infcall_suspend_state): Likewise.
1880 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
1881 * jit.c (jit_frame_prev_register): Likewise.
1882 * linux-nat.c (save_stop_reason): Likewise.
1883 (linux_nat_wait_1): Likewise.
1884 (resume_stopped_resumed_lwps): Likewise.
1885 * linux-record.c (record_linux_sockaddr): Likewise.
1886 (record_linux_msghdr): Likewise.
1887 (record_linux_system_call): Likewise.
1888 * linux-tdep.c (linux_collect_thread_registers): Likewise.
1889 * lm32-tdep.c (lm32_extract_return_value): Likewise.
1890 (lm32_store_return_value): Likewise.
1891 * m32c-tdep.c (m32c_read_flg): Likewise.
1892 (m32c_pseudo_register_read): Likewise.
1893 (m32c_pseudo_register_write): Likewise.
1894 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
1895 (m32r_linux_collect_gregset): Likewise.
1896 * m32r-tdep.c (m32r_store_return_value): Likewise.
1897 (m32r_extract_return_value): Likewise.
1898 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
1899 (m68kbsd_collect_fpregset): Likewise.
1900 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
1901 * m68k-linux-nat.c (fetch_register): Likewise.
1902 (old_fetch_inferior_registers): Likewise.
1903 (old_store_inferior_registers): Likewise.
1904 (store_regs): Likewise.
1905 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
1906 (m68k_svr4_store_return_value): Likewise.
1907 * m88k-tdep.c (m88k_store_arguments): Likewise.
1908 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
1909 (mi_cmd_data_write_register_values): Likewise.
1910 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
1911 (mips_fbsd_store_inferior_registers): Likewise.
1912 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
1913 (mips_fbsd_supply_gregs): Likewise.
1914 (mips_fbsd_collect_fpregs): Likewise.
1915 (mips_fbsd_collect_gregs): Likewise.
1916 (mips_fbsd_supply_fpregset): Likewise.
1917 (mips_fbsd_collect_fpregset): Likewise.
1918 (mips_fbsd_supply_gregset): Likewise.
1919 (mips_fbsd_collect_gregset): Likewise.
1920 * mips-linux-nat.c (supply_gregset): Likewise.
1921 (fill_gregset): Likewise.
1922 (supply_fpregset): Likewise.
1923 (fill_fpregset): Likewise.
1924 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
1925 (mips_fill_gregset): Likewise.
1926 (mips_supply_fpregset): Likewise.
1927 (mips_fill_fpregset): Likewise.
1928 (mips64_supply_gregset): Likewise.
1929 (micromips_linux_sigframe_validate): Likewise.
1930 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
1931 (mipsnbsd_fetch_inferior_registers): Likewise.
1932 (mipsnbsd_store_inferior_registers): Likewise.
1933 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
1934 (mipsnbsd_supply_gregset): Likewise.
1935 (mipsnbsd_iterate_over_regset_sections): Likewise.
1936 (mipsnbsd_supply_reg): Likewise.
1937 (mipsnbsd_supply_fpreg): Likewise.
1938 * mips-tdep.c (mips_in_frame_stub): Likewise.
1939 (mips_dummy_id): Likewise.
1940 (is_octeon_bbit_op): Likewise.
1941 (micromips_bc1_pc): Likewise.
1942 (extended_mips16_next_pc): Likewise.
1943 (mips16_next_pc): Likewise.
1944 (deal_with_atomic_sequence): Likewise.
1945 * moxie-tdep.c (moxie_process_readu): Likewise.
1946 * nios2-tdep.c (nios2_get_next_pc): Likewise.
1947 * nto-procfs.c (procfs_store_registers): Likewise.
1948 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
1949 (ppcfbsd_store_inferior_registers): Likewise.
1950 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
1951 (fetch_altivec_register): Likewise.
1952 (get_spe_registers): Likewise.
1953 (fetch_spe_register): Likewise.
1954 (fetch_altivec_registers): Likewise.
1955 (fetch_all_gp_regs): Likewise.
1956 (fetch_all_fp_regs): Likewise.
1957 (store_vsx_register): Likewise.
1958 (store_altivec_register): Likewise.
1959 (set_spe_registers): Likewise.
1960 (store_spe_register): Likewise.
1961 (store_altivec_registers): Likewise.
1962 (store_all_gp_regs): Likewise.
1963 (store_all_fp_regs): Likewise.
1964 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
1965 (ppc_linux_collect_gregset): Likewise.
1966 (ppc_canonicalize_syscall): Likewise.
1967 (ppc_linux_record_signal): Likewise.
1968 (ppu2spu_prev_register): Likewise.
1969 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
1970 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
1971 (ppcobsd_store_registers): Likewise.
1972 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
1973 Likewise.
1974 (ppc_ravenscar_generic_store_registers): Likewise.
1975 * procfs.c (procfs_fetch_registers): Likewise.
1976 (procfs_store_registers): Likewise.
1977 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
1978 (ravenscar_store_registers): Likewise.
1979 (ravenscar_prepare_to_store): Likewise.
1980 * record-btrace.c (record_btrace_fetch_registers): Likewise.
1981 * record-full.c (record_full_wait_1): Likewise.
1982 (record_full_registers_change): Likewise.
1983 (record_full_store_registers): Likewise.
1984 (record_full_core_fetch_registers): Likewise.
1985 (record_full_save): Likewise.
1986 (record_full_goto_insn): Likewise.
1987 * regcache.c (regcache_register_size): Likewise.
1988 (get_regcache_arch): Remove.
1989 (regcache_read_pc): Likewise.
1990 * regcache.h (get_regcache_arch): Remove.
1991 * remote-sim.c (gdbsim_fetch_register): Likewise.
1992 (gdbsim_store_register): Likewise.
1993 * remote.c (fetch_register_using_p): Likewise.
1994 (send_g_packet): Likewise.
1995 (remote_prepare_to_store): Likewise.
1996 (store_registers_using_G): Likewise.
1997 * reverse.c (save_bookmark_command): Likewise.
1998 (goto_bookmark_command): Likewise.
1999 * rs6000-aix-tdep.c (branch_dest): Likewise.
2000 * rs6000-nat.c (rs6000_ptrace64): Likewise.
2001 (fetch_register): Likewise.
2002 * rs6000-tdep.c (ppc_supply_reg): Likewise.
2003 (ppc_collect_reg): Likewise.
2004 (ppc_collect_gregset): Likewise.
2005 (ppc_collect_fpregset): Likewise.
2006 (ppc_collect_vsxregset): Likewise.
2007 (ppc_collect_vrregset): Likewise.
2008 (ppc_displaced_step_hw_singlestep): Likewise.
2009 (rs6000_pseudo_register_read): Likewise.
2010 (rs6000_pseudo_register_write): Likewise.
2011 * s390-linux-nat.c (supply_gregset): Likewise.
2012 (fill_gregset): Likewise.
2013 (s390_linux_fetch_inferior_registers): Likewise.
2014 * s390-linux-tdep.c (s390_write_pc): Likewise.
2015 (s390_software_single_step): Likewise.
2016 (s390_all_but_pc_registers_record): Likewise.
2017 (s390_linux_syscall_record): Likewise.
2018 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
2019 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
2020 (shnbsd_store_inferior_registers): Likewise.
2021 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
2022 (sh_extract_return_value_fpu): Likewise.
2023 (sh_store_return_value_nofpu): Likewise.
2024 (sh_corefile_supply_regset): Likewise.
2025 (sh_corefile_collect_regset): Likewise.
2026 * sh64-tdep.c (sh64_extract_return_value): Likewise.
2027 (sh64_store_return_value): Likewise.
2028 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
2029 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
2030 (sparc_store_inferior_registers): Likewise.
2031 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
2032 (sparc_ravenscar_prepare_to_store): Likewise.
2033 * sparc-tdep.c (sparc32_store_arguments): Likewise.
2034 (sparc_analyze_control_transfer): Likewise.
2035 (sparc_step_trap): Likewise.
2036 (sparc_software_single_step): Likewise.
2037 (sparc32_gdbarch_init): Likewise.
2038 (sparc_supply_rwindow): Likewise.
2039 (sparc_collect_rwindow): Likewise.
2040 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
2041 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
2042 (sparc64nbsd_collect_gregset): Likewise.
2043 (sparc64nbsd_supply_fpregset): Likewise.
2044 (sparc64nbsd_collect_fpregset): Likewise.
2045 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
2046 (sparc64_supply_gregset): Likewise.
2047 (sparc64_collect_gregset): Likewise.
2048 (sparc64_supply_fpregset): Likewise.
2049 (sparc64_collect_fpregset): Likewise.
2050 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
2051 * spu-tdep.c (spu_unwind_sp): Likewise.
2052 (spu2ppu_prev_register): Likewise.
2053 (spu_memory_remove_breakpoint): Likewise.
2054 * stack.c (return_command): Likewise.
2055 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
2056 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
2057 * tracefile.c (trace_save_ctf): Likewise.
2058 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
2059 (do_windows_store_inferior_registers): Likewise.
2060 (windows_resume): Likewise.
2061 * xtensa-linux-nat.c (fill_gregset): Likewise.
2062 (supply_gregset_reg): Likewise.
2063 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
2064 (xtensa_register_read_masked): Likewise.
2065 (xtensa_supply_gregset): Likewise.
2066 (xtensa_extract_return_value): Likewise.
2067 (xtensa_store_return_value): Likewise.
2068
edd079d9
UW
20692017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
2070
2071 * doublest.c (floatformat_from_string): New function.
2072 * doublest.h (floatformat_from_string): Add prototype.
2073
2074 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
2075 (OP_FLOAT): ... this.
2076 * expression.h: Do not include "doublest.h".
2077 (union exp_element): Replace doubleconst and decfloatconst by
2078 new element floatconst.
2079 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
2080 (ada_evaluate_subexp): Likewise.
2081 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
2082 OP_DOUBLE and OP_DECFLOAT.
2083 * expprint.c (print_subexp_standard): Likewise.
2084 (dump_subexp_body_standard): Likewise.
2085 * breakpoint.c (watchpoint_exp_is_const): Likewise.
2086
2087 * parse.c: Include "dfp.h".
2088 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
2089 (write_exp_elt_floatcst): New function.
2090 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
2091 and OP_DECFLOAT.
2092 (operator_check_standard): Likewise.
2093 (parse_float): Do not accept suffix. Take type as input. Return bool.
2094 Return target format buffer instead of host DOUBLEST.
2095 Use floatformat_from_string and decimal_from_string to parse
2096 either binary or decimal floating-point types.
2097 (parse_c_float): Remove.
2098 * parser-defs.h: Do not include "doublest.h".
2099 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
2100 (write_exp_elt_floatcst): Add prototype.
2101 (parse_float): Update prototype.
2102 (parse_c_float): Remove.
2103
2104 * c-exp.y: Do not include "dfp.h".
2105 (typed_val_float): Use byte buffer instead of DOUBLEST.
2106 (typed_val_decfloat): Remove.
2107 (DECFLOAT): Remove.
2108 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2109 (parse_number): Update to new parse_float interface.
2110 Parse suffixes and determine type before calling parse_float.
2111 Handle decimal and binary FP types the same way.
2112
2113 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2114 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
2115 (parse_number): Update to new parse_float interface.
2116 Parse suffixes and determine type before calling parse_float.
2117
2118 * f-exp.y: Replace dval by typed_val_float.
2119 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2120 (parse_number): Use parse_float instead of atof.
2121
2122 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2123 (parse_go_float): Remove.
2124 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2125 (parse_number): Call parse_float instead of parse_go_float.
2126 Parse suffixes and determine type before calling parse_float.
2127
2128 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2129 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2130 (parse_number): Update to new parse_float interface.
2131 Parse suffixes and determine type before calling parse_float.
2132
2133 * m2-exp.y: Replace dval by byte buffer val.
2134 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2135 (parse_number): Call parse_float instead of atof.
2136
2137 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2138 (lex_number): Call parse_float instead of strtod.
2139 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
2140 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
2141 Use write_exp_elt_floatcst.
2142 (unit_testing): Remove static variable.
2143 (rust_type): Do not check unit_testing.
2144 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
2145
2146 * ada-exp.y (type_float, type_double): Remove.
2147 (typed_val_float): Use byte buffer instead of DOUBLEST.
2148 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2149 * ada-lex.l (processReal): Use parse_float instead of sscanf.
2150
cc628f3d
AH
21512017-10-25 Alan Hayward <alan.hayward@arm.com>
2152
2153 * aarch64-tdep.h (enum aarch64_regnum): Remove.
2154 * arch/aarch64.h: New file.
2155
09a7c6aa
UW
21562017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2157
2158 * dfp.h (decimal_from_string): Use const reference for argument.
2159 * dfp.c (decimal_from_string): Likewise.
2160
8ba0dd51
UW
21612017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2162
2163 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
2164 * sh64-tdep.c (sh64_do_fp_register): Likewise.
2165 * mips-tdep.c (mips_print_fp_register): Likewise.
2166
16e812b2
UW
21672017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2168
2169 * common/format.h (enum argclass): Replace decfloat_arg by
2170 dec32float_arg, dec64float_arg, and dec128float_arg.
2171 * common/format.c (parse_format_string): Update to return
2172 new decimal float argument classes.
2173
2174 * printcmd.c (printf_decfloat): Rename to ...
2175 (printf_floating): ... this. Add argclass argument, and use it
2176 instead of parsing the format string again. Add support for
2177 binary floating-point values, using floatformat_to_string.
2178 Convert value to the target format if it doesn't already match.
2179 (ui_printf): Call printf_floating instead of printf_decfloat,
2180 also for double_arg / long_double_arg. Pass argclass.
2181
2182 * dfp.c (decimal_to_string): Add format string argument.
2183 * dfp.h (decimal_to_string): Likewise.
2184
2185 * doublest.c (floatformat_to_string): Add format string argument.
2186 * doublest.h (floatformat_to_string): Likewise.
2187
fdf0cbc2
UW
21882017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2189
2190 * doublest.c (floatformat_precision): New routine.
2191 (floatformat_to_string): Likewise.
2192 * doublest.c (floatformat_to_string): Add prototype.
2193
2194 * printcmd.c (print_scalar_formatted): Only call print_floating
2195 on floating-point types.
2196 * valprint.c: Do not include "floatformat.h".
2197 (generic_val_print_decfloat): Remove.
2198 (generic_val_print): Call generic_val_print_float for both
2199 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
2200 (print_floating): Use floatformat_to_string. Handle decimal float.
2201 (print_decimal_floating): Remove, merge into floatformat_to_string.
2202 * value.h (print_decimal_floating): Remove.
2203
2204 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
2205
5033013f
UW
22062017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2207
2208 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
2209
a664f67e
SM
22102017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2211
2212 * memattr.h: Don't include vec.h.
2213 (struct mem_attrib): Initialize fields.
2214 <unknown>: New static method.
2215 (struct mem_region): Add constructors, operator<, initialize
2216 fields.
2217 * memattr.c: Include algorithm.
2218 (default_mem_attrib, unknown_mem_attrib): Remove.
2219 (user_mem_region_list): New global.
2220 (target_mem_region_list, mem_region_list): Change type to
2221 std::vector<mem_region>.
2222 (mem_use_target): Now a function.
2223 (target_mem_regions_valid): Change type to bool.
2224 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
2225 (require_user_regions): Adjust.
2226 (require_target_regions): Adjust.
2227 (create_mem_region): Adjust.
2228 (lookup_mem_region): Adjust.
2229 (invalidate_target_mem_regions): Adjust.
2230 (mem_clear): Rename to...
2231 (user_mem_clear): ... this, and adjust.
2232 (mem_command): Adjust.
2233 (info_mem_command): Adjust.
2234 (mem_enable, enable_mem_command, mem_disable,
2235 disable_mem_command): Adjust.
2236 (mem_delete): Adjust.
2237 (delete_mem_command): Adjust.
2238 * memory-map.h (parse_memory_map): Return an std::vector.
2239 * memory-map.c (parse_memory_map): Likewise.
2240 (struct memory_map_parsing_data): Add constructor.
2241 <memory_map>: Point to std::vector.
2242 (memory_map_start_memory): Adjust.
2243 (memory_map_end_memory): Adjust.
2244 (memory_map_end_property): Adjust.
2245 (clear_result): Remove.
2246 * remote.c (remote_memory_map): Return an std::vector.
2247 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
2248 Remove.
2249 (target_debug_print_mem_region_vector): New.
2250 * target-delegates.c: Regenerate.
2251 * target.h (mem_region_vector): New typedef.
2252 (to_memory_map): Return mem_region_vector.
2253 (target_memory_map): Return an std::vector.
2254 * target.c (target_memory_map): Return an std::vector.
2255 (flash_erase_command): Adjust.
2256
6e17c565
SM
22572017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2258
2259 * memory-map.c (struct memory_map_parsing_data) <property_name>:
2260 Change type to std::string.
2261 (memory_map_start_property): Adjust.
2262 (memory_map_end_property): Adjust.
2263
cfba9872
SM
22642017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2265
2266 * infrun.h: Include common/byte-vector.h.
2267 (struct displaced_step_closure): New struct.
2268 (struct buf_displaced_step_closure): New struct.
2269 * infrun.c (displaced_step_closure::~displaced_step_closure):
2270 Provide default implementation.
2271 (displaced_step_clear): Deallocate step closure with delete.
2272 * aarch64-tdep.c (displaced_step_closure): Rename to ...
2273 (aarch64_displaced_step_closure): ... this, extend
2274 displaced_step_closure.
2275 (aarch64_displaced_step_data) <dsc>: Change type to
2276 aarch64_displaced_step_closure.
2277 (aarch64_displaced_step_copy_insn): Adjust to type change, use
2278 unique_ptr.
2279 (aarch64_displaced_step_fixup): Add cast for displaced step
2280 closure.
2281 * amd64-tdep.c (displaced_step_closure): Rename to ...
2282 (amd64_displaced_step_closure): ... this, extend
2283 displaced_step_closure.
2284 <insn_buf>: Change type to std::vector<gdb_byte>.
2285 <max_len>: Remove.
2286 (fixup_riprel): Change type of DSC parameter, adjust to type
2287 change of insn_buf.
2288 (fixup_displaced_copy): Change type of DSC parameter.
2289 (amd64_displaced_step_copy_insn): Instantiate
2290 amd64_displaced_step_closure.
2291 (amd64_displaced_step_fixup): Add cast for closure type, adjust
2292 to type change of insn_buf.
2293 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
2294 parameter DSC.
2295 (arm_linux_copy_svc): Likewise.
2296 (cleanup_kernel_helper_return): Likewise.
2297 (arm_catch_kernel_helper_return): Likewise.
2298 (arm_linux_displaced_step_copy_insn): Instantiate
2299 arm_displaced_step_closure.
2300 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
2301 (displaced_read_reg): Change type of parameter DSC.
2302 (branch_write_pc): Likewise.
2303 (load_write_pc): Likewise.
2304 (alu_write_pc): Likewise.
2305 (displaced_write_reg): Likewise.
2306 (arm_copy_unmodified): Likewise.
2307 (thumb_copy_unmodified_32bit): Likewise.
2308 (thumb_copy_unmodified_16bit): Likewise.
2309 (cleanup_preload): Likewise.
2310 (install_preload): Likewise.
2311 (arm_copy_preload): Likewise.
2312 (thumb2_copy_preload): Likewise.
2313 (install_preload_reg): Likewise.
2314 (arm_copy_preload_reg): Likewise.
2315 (cleanup_copro_load_store): Likewise.
2316 (install_copro_load_store): Likewise.
2317 (arm_copy_copro_load_store) Likewise.
2318 (thumb2_copy_copro_load_store): Likewise.
2319 (cleanup_branch): Likewise.
2320 (install_b_bl_blx): Likewise.
2321 (arm_copy_b_bl_blx): Likewise.
2322 (thumb2_copy_b_bl_blx): Likewise.
2323 (thumb_copy_b): Likewise.
2324 (install_bx_blx_reg): Likewise.
2325 (arm_copy_bx_blx_reg): Likewise.
2326 (thumb_copy_bx_blx_reg): Likewise.
2327 (cleanup_alu_imm): Likewise.
2328 (arm_copy_alu_imm): Likewise.
2329 (thumb2_copy_alu_imm): Likewise.
2330 (cleanup_alu_reg): Likewise.
2331 (install_alu_reg): Likewise.
2332 (arm_copy_alu_reg): Likewise.
2333 (thumb_copy_alu_reg): Likewise.
2334 (cleanup_alu_shifted_reg): Likewise.
2335 (install_alu_shifted_reg): Likewise.
2336 (arm_copy_alu_shifted_reg): Likewise.
2337 (cleanup_load): Likewise.
2338 (cleanup_store): Likewise.
2339 (arm_copy_extra_ld_st): Likewise.
2340 (install_load_store): Likewise.
2341 (thumb2_copy_load_literal): Likewise.
2342 (thumb2_copy_load_reg_imm): Likewise.
2343 (arm_copy_ldr_str_ldrb_strb): Likewise.
2344 (cleanup_block_load_all): Likewise.
2345 (cleanup_block_store_pc): Likewise.
2346 (cleanup_block_load_pc): Likewise.
2347 (arm_copy_block_xfer): Likewise.
2348 (thumb2_copy_block_xfer): Likewise.
2349 (cleanup_svc): Likewise.
2350 (install_svc): Likewise.
2351 (arm_copy_svc): Likewise.
2352 (thumb_copy_svc): Likewise.
2353 (arm_copy_undef): Likewise.
2354 (thumb_32bit_copy_undef): Likewise.
2355 (arm_copy_unpred): Likewise.
2356 (arm_decode_misc_memhint_neon): Likewise.
2357 (arm_decode_unconditional): Likewise.
2358 (arm_decode_miscellaneous): Likewise.
2359 (arm_decode_dp_misc): Likewise.
2360 (arm_decode_ld_st_word_ubyte): Likewise.
2361 (arm_decode_media): Likewise.
2362 (arm_decode_b_bl_ldmstm): Likewise.
2363 (arm_decode_ext_reg_ld_st): Likewise.
2364 (thumb2_decode_dp_shift_reg): Likewise.
2365 (thumb2_decode_ext_reg_ld_st): Likewise.
2366 (arm_decode_svc_copro): Likewise.
2367 (thumb2_decode_svc_copro): Likewise.
2368 (install_pc_relative): Likewise.
2369 (thumb_copy_pc_relative_16bit): Likewise.
2370 (thumb_decode_pc_relative_16bit): Likewise.
2371 (thumb_copy_pc_relative_32bit): Likewise.
2372 (thumb_copy_16bit_ldr_literal): Likewise.
2373 (thumb_copy_cbnz_cbz): Likewise.
2374 (thumb2_copy_table_branch): Likewise.
2375 (cleanup_pop_pc_16bit_all): Likewise.
2376 (thumb_copy_pop_pc_16bit): Likewise.
2377 (thumb_process_displaced_16bit_insn): Likewise.
2378 (decode_thumb_32bit_ld_mem_hints): Likewise.
2379 (thumb_process_displaced_32bit_insn): Likewise.
2380 (thumb_process_displaced_insn): Likewise.
2381 (arm_process_displaced_insn): Likewise.
2382 (arm_displaced_init_closure): Likewise.
2383 (arm_displaced_step_fixup): Add cast for closure.
2384 * arm-tdep.h: Include infrun.h.
2385 (displaced_step_closure): Rename to ...
2386 (arm_displaced_step_closure): ... this, extend
2387 displaced_step_closure.
2388 <u::svc::copy_svc_os>: Change type of parameter DSC.
2389 <cleanup>: Likewise.
2390 (arm_process_displaced_insn): Likewise.
2391 (arm_displaced_init_closure): Likewise.
2392 (displaced_read_reg): Likewise.
2393 (displaced_write_reg): Likewise.
2394 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
2395 Adjust.
2396 * i386-tdep.h: Include infrun.h.
2397 (i386_displaced_step_closure): New typedef.
2398 * i386-tdep.c (i386_displaced_step_copy_insn): Use
2399 i386_displaced_step_closure.
2400 (i386_displaced_step_fixup): Adjust.
2401 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
2402 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
2403 and unique_ptr.
2404 (ppc_displaced_step_fixup): Adjust.
2405 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
2406 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
2407 and unique_ptr.
2408 (s390_displaced_step_fixup): Adjust.
2409
b392b304
SM
24102017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2411
2412 * interps.h (interp_resume, interp_suspend, interp_set_temp):
2413 Remove declarations.
2414
d5833c62
TT
24152017-10-20 Tom Tromey <tom@tromey.com>
2416
2417 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
2418 std::vector.
2419 (gdb_bfd_record_inclusion): Update.
2420 (bfdp): Remove typedef.
2421
06d5bbc8
TT
24222017-10-20 Tom Tromey <tom@tromey.com>
2423
2424 * gdb_bfd.c (gdb_bfd_ref): Use new.
2425 (struct gdb_bfd_data): Add constructor, destructor, and member
2426 initializers.
2427 (gdb_bfd_unref): Use delete.
2428
2712ce2e
TT
24292017-10-20 Tom Tromey <tom@tromey.com>
2430
2431 * exec.c (exec_file_attach): Use new_bfd_ref.
2432 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
2433 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
2434 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
2435 new_bfd_ref.
2436 * gdb_bfd.h (new_bfd_ref): New function.
2437
fcc8fb2f
PA
24382017-10-20 Pedro Alves <palves@redhat.com>
2439
2440 * main.c (captured_command_loop): Add attribute noinline.
2441
4c2287b0
SM
24422017-10-19 Simon Marchi <simon.marchi@ericsson.com>
2443
2444 * interps.c (struct interp_factory): Add constructor.
2445 (interp_factory_p): Remove typedef.
2446 (DEF_VEC_P(interp_factory_p)): Remove.
2447 (interpreter_factories): Change type to std::vector.
2448 (interp_factory_register): Adjust.
2449 (interp_lookup): Adjust.
2450 (interpreter_completer): Adjust.
2451
3d415c26
TT
24522017-10-19 Tom Tromey <tom@tromey.com>
2453
2454 * break-catch-syscall.c (catch_syscall_completer): Use
2455 std::string, gdb::unique_xmalloc_ptr.
2456
395423c4
TT
24572017-10-19 Tom Tromey <tom@tromey.com>
2458
2459 * infcall.c (call_function_by_hand_dummy): Use std::string.
2460
54f70bc1
TT
24612017-10-19 Tom Tromey <tom@tromey.com>
2462
2463 * mi/mi-main.c (mi_cmd_execute): Update.
2464 * top.h (prepare_execute_command): Return scoped_value_mark.
2465 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
2466 Add move constructor.
2467 * top.c (prepare_execute_command): Return scoped_value_mark.
2468 (execute_command): Update.
2469
63929e84
PA
24702017-10-19 Pedro Alves <palves@redhat.com>
2471
2472 * xml-support.c (xml_fetch_content_from_file): Check fread's
2473 return.
2474
a75868f5
PA
24752017-10-19 Pedro Alves <palves@redhat.com>
2476
2477 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
2478 async.
2479 (handle_error_fd): New function.
2480 (ser_base_async): Add/delete an event loop file handler for
2481 error_fd.
2482
2edf834e
PA
24832017-10-19 Pedro Alves <palves@redhat.com>
2484
2485 * xml-support.c (xml_fetch_content_from_file): Don't read in
2486 chunks. Instead use fseek to determine the file's size, and read
2487 it in one go.
2488
c8ba13ad
KS
24892017-11-18 Keith Seitz <keiths@redhat.com>
2490
2491 * c-exp.y (oper): Canonicalize conversion operators of user-defined
2492 types.
2493 Add whitespace to front of type name.
2494
37534686
KS
24952017-10-18 Keith Seitz <keiths@redhat.com>
2496
2497 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
2498 DW_AT_accessibility.
2499
28c7c158
YQ
25002017-10-18 Yao Qi <yao.qi@linaro.org>
2501
2502 * features/tic6x-c62x-linux.c: Remove.
2503
30f0b101
TT
25042017-10-17 Tom Tromey <tom@tromey.com>
2505
2506 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
2507 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
2508 (do_mixed_source_and_assembly): Likewise.
2509
57e12da9
TT
25102017-10-17 Tom Tromey <tom@tromey.com>
2511
2512 * regcache.c (regcache::xfer_part): Remove assertion.
2513
7b700999
PA
25142017-10-17 Pedro Alves <palves@redhat.com>
2515
2516 * xml-support.c (xml_fetch_content_from_file): Call
2517 unique_ptr::release() instead unique_ptr::get() when passing
2518 through xrealloc.
2519
d3037ba6
YQ
25202017-10-17 Yao Qi <yao.qi@linaro.org>
2521
2522 * regcache.c (regcache::xfer_part): Remove parameters read and
2523 write, add parameter is_raw. All callers are updated.
2524
83d5a34d
KS
25252017-10-16 Keith Seitz <keiths@redhat.com>
2526
2527 * c-typeprint.c (enum access_specifier): Moved here from
2528 c_type_print_base.
2529 (output_access_specifier): New function.
2530 (c_type_print_base): Consider typedefs when assessing
2531 whether access labels are needed.
2532 Use output_access_specifier as needed.
2533 Output access specifier for typedefs, if needed.
2534 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
2535 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
2536 fields.
2537 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
2538 accessor macros.
2539
87028b87
TT
25402017-10-16 Tom Tromey <tom@tromey.com>
2541
2542 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
2543 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
2544 * target.c (target_fileio_read_stralloc): Update.
2545 * sparc64-tdep.c (adi_is_addr_mapped): Update.
2546 * target.h (target_fileio_read_stralloc): Return
2547 unique_xmalloc_ptr.
2548
b7b030ad
TT
25492017-10-16 Tom Tromey <tom@tromey.com>
2550
2551 * xml-syscall.c (xml_init_syscalls_info): Update.
2552 * xml-support.c (xinclude_start_include): Update.
2553 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
2554 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
2555 (xml_fetch_content_from_file): Likewise.
2556 * osdata.c (get_osdata): Update.
2557 * target.h (target_read_stralloc, target_get_osdata): Return
2558 unique_xmalloc_ptr.
2559 * solib-aix.c (solib_aix_get_library_list): Update.
2560 * solib-target.c (solib_target_current_sos): Update.
2561 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
2562 * xml-tdesc.c (fetch_available_features_from_target): Update.
2563 (target_fetch_description_xml): Update.
2564 (file_read_description_xml): Update.
2565 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
2566 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
2567 (remote_pid_to_exec_file): Update.
2568 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
2569 (target_get_osdata): Likewise.
2570
b80406ac
TT
25712017-10-16 Tom Tromey <tom@tromey.com>
2572
2573 * remote.c (remote_register_number_and_offset): Use std::vector.
2574 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
2575 (putpkt_binary): Use gdb::def_vector.
2576 (compare_sections_command): Use gdb::byte_vector.
2577
a90ecff8
TT
25782017-10-16 Tom Tromey <tom@tromey.com>
2579
2580 * ppc-linux-nat.c (hwdebug_insert_point): Use
2581 gdb::unique_xmalloc_ptr, XDUP.
2582
2dc0e219
TT
25832017-10-16 Tom Tromey <tom@tromey.com>
2584
2585 * probe.c (parse_probes): Use std::string.
2586 (info_probes_for_ops, enable_probes_command)
2587 (disable_probes_command): Remove cleanups.
2588
b05628f0
TT
25892017-10-16 Tom Tromey <tom@tromey.com>
2590
2591 * buildsym.c (block_compar): Remove.
2592 (end_symtab_get_static_block): Use std::vector.
2593
a79b1bc6
SM
25942017-10-16 Simon Marchi <simon.marchi@ericsson.com>
2595
2596 * memrange.h (struct mem_range): Define operator< and operator==.
2597 (mem_range_s): Remove.
2598 (DEF_VEC_O (mem_range_s)): Remove.
2599 (normalize_mem_ranges): Change parameter type to std::vector.
2600 * memrange.c (compare_mem_ranges): Remove.
2601 (normalize_mem_ranges): Change parameter type to std::vector,
2602 adjust to vector change.
2603 * exec.c (section_table_available_memory): Return vector, remove
2604 parameter.
2605 (section_table_read_available_memory): Adjust to std::vector
2606 change.
2607 * remote.c (remote_read_bytes): Adjust to std::vector
2608 change.
2609 * tracepoint.h (traceframe_available_memory): Change parameter
2610 type to std::vector.
2611 * tracepoint.c (traceframe_available_memory): Change parameter
2612 type to std::vector, adjust.
2613 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
2614 std::vector change.
2615 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2616 unittests/memrange-selftests.c.
2617 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
2618 * gdb/unittests/memrange-selftests.c: New file.
2619
63f0e930
PA
26202017-10-16 Pedro Alves <palves@redhat.com>
2621
2622 * elfread.c (probe_key_free): Rename range-for variable.
2623 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
2624 (find_probe_by_pc, collect_probes): Rename range-for variable.
2625
c40c7bfc
YQ
26262017-10-16 Yao Qi <yao.qi@linaro.org>
2627
2628 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
2629 * features/tic6x-c62x.c: Remove.
2630 * features/tic6x-c64x-linux.c: Remove.
2631 * features/tic6x-c64x.c: Remove.
2632 * features/tic6x-c64xp-linux.c: Remove.
2633 * features/tic6x-c64xp.c: Remove.
2634 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
2635 initialize_tdesc_tic6x_*_linux functions.
2636 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
2637 initialize_tdesc_tic6x_* functions.
2638
df27ae6a
YQ
26392017-10-16 Yao Qi <yao.qi@linaro.org>
2640
2641 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
2642 tic6x-c62x.
2643 * regformats/tic6x-c62x.dat: Remove.
2644 * regformats/tic6x-c64x.dat: Remove.
2645 * regformats/tic6x-c64xp.dat: Remove.
2646
86766165
SM
26472017-10-15 Simon Marchi <simon.marchi@ericsson.com>
2648
2649 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
2650 (the !HAVE_LIBEXPAT version).
2651
824dfcc3
SM
26522017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2653
2654 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
2655 const.
2656
2098b393
SM
26572017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2658
2659 * target.h: Include tracepoint.h.
2660 (enum trace_find_type): Move to tracepoint.h.
2661 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
2662 * tracepoint.h: Don't include target.h
2663 (enum trace_find_type): Move from target.h.
2664 (parse_traceframe_info): Return a unique ptr.
2665 * tracepoint.c (current_traceframe_info): Change type to unique
2666 ptr.
2667 (free_traceframe_info): Remove.
2668 (clear_traceframe_info): Don't manually free
2669 current_traceframe_info.
2670 (free_result): Remove.
2671 (parse_traceframe_info): Return a unique ptr.
2672 (get_traceframe_info): Adjust to unique ptr.
2673 * ctf.c (ctf_traceframe_info): Return a unique ptr.
2674 * remote.c (remote_traceframe_info): Return a unique ptr.
2675 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
2676 ptr.
2677 * target-debug.h (target_debug_print_traceframe_info_up): New
2678 macro.
2679 * target-delegates.c: Regenerate.
2680
4cdd21a8
SM
26812017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2682
2683 * memrange.h (struct mem_range): Add constructors.
2684 * tracepoint.h (struct traceframe_info) <memory>: Change type to
2685 std::vector<mem_range>.
2686 * tracepoint.c (free_traceframe_info): Don't manually free
2687 vector.
2688 (traceframe_info_start_memory): Adjust to vector change.
2689 (traceframe_available_memory): Likewise.
2690 * tracefile-tfile.c (build_traceframe_info): Likewise.
2691 * ctf.c (ctf_traceframe_info): Likewise.
2692
d0d292a2
SM
26932017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2694
2695 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
2696 std::vector<int>.
2697 * tracepoint.c (free_traceframe_info): Deallocate with delete.
2698 (traceframe_info_start_tvar): Adjust to vector change.
2699 (parse_traceframe_info): Allocate with new.
2700 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
2701 vector change.
2702 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
2703 change.
2704 tfile_traceframe_info): Allocate with new.
2705 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
2706 change.
2707
8d3c73ef
SM
27082017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2709
2710 * tracepoint.c (traceframe_info): Rename to...
2711 (current_traceframe_info): ...this.
2712 (clear_traceframe_info): Adjust.
2713 (get_traceframe_info): Adjust.
2714
b129dcac
SM
27152017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2716
2717 * nat/linux-osdata.c: Include algorithm.
2718 (compare_processes): Remove.
2719 (struct pid_pgid_entry): New struct.
2720 (linux_xfer_osdata_processgroups): Use std::vector instead of
2721 XNEWVEC.
2722
af5bf4ad
SM
27232017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2724
2725 * objfiles.h: Don't include symfile.h.
2726 (struct partial_symbol): Remove forward-declaration.
2727 (struct objfile) <global_psymbols, static_psymbols>: Change type
2728 to std::vector<partial_symbol *>.
2729 * objfiles.c (objfile::objfile): Don't memset those fields.
2730 (objfile::~objfile): Don't free those fields.
2731 * psympriv.h (struct psymbol_allocation_list): Remove
2732 forward-declaration.
2733 (add_psymbol_to_list): Change psymbol_allocation_list parameter
2734 to std::vector.
2735 (start_psymtab_common): Change parameters to std::vector.
2736 * psymtab.c: Include algorithm.
2737 (require_partial_symbols): Call shrink_to_fit.
2738 (find_pc_sect_psymbol): Adjust to vector change.
2739 (match_partial_symbol): Likewise.
2740 (lookup_partial_symbol): Likewise.
2741 (psym_relocate): Likewise.
2742 (dump_psymtab): Likewise.
2743 (recursively_search_psymtabs): Likewise.
2744 (compare_psymbols): Remove.
2745 (sort_pst_symbols): Adjust to vector change.
2746 (start_psymtab_common): Likewise.
2747 (end_psymtab_common): Likewise.
2748 (psymbol_bcache_full): De-constify return value.
2749 (add_psymbol_to_bcache): Likewise.
2750 (extend_psymbol_list): Remove.
2751 (append_psymbol_to_list): Adjust to vector change.
2752 (add_psymbol_to_list): Likewise.
2753 (init_psymbol_list): Likewise.
2754 (maintenance_info_psymtabs): Likewise.
2755 (maintenance_check_psymtabs): Likewise.
2756 * symfile.h (struct psymbol_allocation_list): Remove.
2757 * symfile.c (reread_symbols): Adjust to vector change.
2758 * dbxread.c (start_psymtab): Change type of parameters.
2759 (dbx_symfile_read): Adjust to vector change.
2760 (read_dbx_symtab): Likewise.
2761 (start_psymtab): Change type of parameters.
2762 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
2763 (create_partial_symtab): Likewise.
2764 (add_partial_symbol): Likewise.
2765 (write_one_signatured_type): Likewise.
2766 (recursively_write_psymbols): Likewise.
2767 * mdebugread.c (parse_partial_symbols): Likewise.
2768 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
2769 (scan_xcoff_symtab): Adjust to vector change.
2770 (xcoff_initial_scan): Likewise.
2771
3ec5942f
SM
27722017-10-13 Simon Marchi <simon.marchi@ericsson.com>
2773
2774 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
2775
2399fe6a
YQ
27762017-10-13 Yao Qi <yao.qi@linaro.org>
2777
2778 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
2779 Remove s390x-*-expedite, add s390x-expedite.
2780
4bf3f4a8
YQ
27812017-10-13 Yao Qi <yao.qi@linaro.org>
2782
2783 * features/s390-gs-linux64.c: Regenerated.
2784 * features/s390x-gs-linux64.c: Regenerated.
2785
9e86da07
TT
27862017-10-13 Tom Tromey <tom@tromey.com>
2787
2788 * compile/compile-object-run.c (do_module_cleanup): Use delete.
2789 * solib.c (update_solib_list, reload_shared_libraries_1): Use
2790 delete.
2791 * symfile.c (symbol_file_add_with_addrs): Use new.
2792 (symbol_file_add_separate): Update comment.
2793 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
2794 * jit.c (jit_object_close_impl): Use new.
2795 (jit_unregister_code): Use delete.
2796 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
2797 (~objfile): Rename from free_objfile.
2798 (free_objfile_separate_debug, do_free_objfile_cleanup)
2799 (free_all_objfiles, objfile_purge_solibs): Use delete.
2800 * objfiles.h (struct objfile): Add constructor and destructor.
2801 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
2802 (allocate_objfile, free_objfile): Don't declare.
2803 (struct objstats): Add initializers.
2804
c2508e90
SM
28052017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2806
2807 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
2808 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
2809 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
2810 * gdbarch.h: Regenerate.
2811 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
2812 Adjust comment.
2813 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
2814 (i386_displaced_step_fixup): Adjust comment.
2815 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
2816
a900ff72
TT
28172017-10-12 Tom Tromey <tom@tromey.com>
2818
2819 * prologue-value.h (pv_area::store_would_trash): Return bool.
2820 (pv_area::find_reg): Likewise.
2821 * prologue-value.c (pv_area::store_would_trash): Return bool.
2822 (pv_area::find_reg): Likewise.
2823
f7b7ed97
TT
28242017-10-12 Tom Tromey <tom@tromey.com>
2825
2826 * s390-linux-tdep.c (s390_store, s390_load)
2827 (s390_check_for_saved, s390_analyze_prologue): Update.
2828 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
2829 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
2830 * prologue-value.h (class pv_area): Move from prologue-value.c.
2831 Change names of members. Add constructor, destructor, member
2832 functions.
2833 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
2834 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
2835 (pv_area_fetch, pv_area_scan): Don't declare.
2836 * prologue-value.c (struct pv_area::area_entry): Now member of
2837 pv_area.
2838 (struct pv_area): Move to prologue-value.h.
2839 (pv_area::pv_area): Rename from make_pv_area.
2840 (pv_area::~pv_area): Rename from free_pv_area.
2841 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
2842 (clear_entries, find_entry, overlaps, store_would_trash, store)
2843 (fetch, find_reg, scan): Now member of pv_area.
2844 Remove "area" argument. Update.
2845 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
2846 Update.
2847 * mn10300-tdep.c (push_reg, check_for_saved)
2848 (mn10300_analyze_prologue): Update.
2849 * mep-tdep.c (is_arg_spill, check_for_saved)
2850 (mep_analyze_prologue): Update.
2851 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
2852 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
2853 (m32c_is_struct_return, m32c_analyze_prologue): Update.
2854 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
2855 Update.
2856 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
2857 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
2858
466eecee
SM
28592017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2860
2861 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
2862 * linux-nat.c (linux_nat_delete_thread): New variable.
2863 (lwp_free): Invoke linux_nat_delete_thread if set.
2864 (linux_nat_set_delete_thread): New function.
2865 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
2866 thread delete callback.
2867 * arm-linux-nat.c (arm_linux_delete_thread): New function.
2868 (_initialize_arm_linux_nat): Assign thread delete callback.
2869 * s390-linux-nat.c (s390_delete_thread): New function.
2870 (_initialize_s390_nat): Assign thread delete callback.
2871 * x86-linux-nat.c (x86_linux_add_target): Likewise.
2872 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
2873 function.
2874 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
2875 declaration.
2876 * nat/x86-linux.c (x86_linux_delete_thread): New function.
2877 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
2878
f71c8822
TT
28792017-10-09 Tom Tromey <tom@tromey.com>
2880
2881 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
2882 std::string.
2883 * tui/tui-layout.c (enum tui_status): Use std::string.
2884
981a3fb3
TT
28852017-10-11 Tom Tromey <tom@tromey.com>
2886
2887 * gdbthread.h (thread_command): Constify.
2888 * inferior.h (detach_command): Constify.
2889 * top.h (set_history, show_history): Constify.
2890 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
2891 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
2892 * bsd-kvm.c (bsd_kvm_cmd): Constify.
2893 * printcmd.c (set_command): Constify.
2894 (non_const_set_command): New function.
2895 * dcache.c (set_dcache_command, show_dcache_command): Constify.
2896 * breakpoint.c (enable_command, disable_command, delete_command)
2897 (catch_command, tcatch_command, set_breakpoint_cmd)
2898 (show_breakpoint_cmd): Constify.
2899 * macrocmd.c (macro_command): Constify.
2900 * infcmd.c (unset_command, kill_command, detach_command)
2901 (info_proc_cmd): Constify.
2902 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
2903 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
2904 (info_auto_load_cmd): Constify.
2905 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
2906 (unset_tdesc_cmd): Constify.
2907 * ada-lang.c (set_ada_command, show_ada_command)
2908 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
2909 * guile/guile.c (set_guile_command, show_guile_command)
2910 (info_guile_command): Constify.
2911 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
2912 Constify.
2913 * skip.c (skip_command): Constify.
2914 * compile/compile.c (_initialize_compile): Constify.
2915 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
2916 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
2917 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
2918 (maint_btrace_pt_show_cmd): Constify.
2919 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
2920 Constify.
2921 * python/python.c (user_show_python, user_set_python): Constify.
2922 * mips-tdep.c (set_mips_command, show_mips_command)
2923 (set_mipsfpu_command): Constify.
2924 * record-btrace.c (cmd_record_btrace_start)
2925 (cmd_set_record_btrace, cmd_show_record_btrace)
2926 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
2927 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
2928 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
2929 Constify.
2930 * symfile.c (overlay_command): Constify.
2931 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
2932 * cli/cli-logging.c (set_logging_command, show_logging_command):
2933 Constify.
2934 * cli/cli-dump.c (dump_command, append_command)
2935 (srec_dump_command, ihex_dump_command, verilog_dump_command)
2936 (tekhex_dump_command, binary_dump_command)
2937 (binary_append_command): Constify.
2938 * cli/cli-decode.c (struct cmd_list_element): Change type of
2939 "fun".
2940 * cli/cli-cmds.c (info_command, show_command, set_debug)
2941 (show_debug): Constify.
2942 (show_command): Add non-const overload.
2943 * top.c (set_history, show_history): Constify.
2944 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
2945 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
2946 * target.c (target_command): Constify.
2947 * sparc64-tdep.c (info_adi_command): Constify.
2948 * record-full.c (cmd_record_full_start): Constify.
2949 (set_record_full_command): Constify. Fix typo.
2950 (show_record_full_command): Constify.
2951 * thread.c (thread_command, thread_apply_command): Constify.
2952 * memattr.c (dummy_cmd): Constify.
2953 * value.c (function_command): Constify.
2954 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
2955 * probe.c (info_probes_command): Constify.
2956 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
2957 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
2958 (show_thread_cmd, set_thread_default_cmd)
2959 (show_thread_default_cmd): Constify.
2960 (check_empty): Constify.
2961 * tracepoint.c (tfind_command): Constify.
2962 * cp-support.c (maint_cplus_command): Constify.
2963 * windows-tdep.c (info_w32_command): Constify.
2964 * record.c (cmd_record_start, set_record_command)
2965 (show_record_command, info_record_command, cmd_record_goto):
2966 Constify.
2967 * ravenscar-thread.c (set_ravenscar_command)
2968 (show_ravenscar_command): Constify.
2969 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
2970 Constify.
2971 (add_internal_problem_command): Remove casts.
2972 * arc-tdep.c (maintenance_print_arc_command): Constify.
2973 * valprint.c (set_print, show_print, set_print_raw)
2974 (show_print_raw): Constify.
2975 * maint.c (maintenance_command, maintenance_info_command)
2976 (maintenance_print_command, maintenance_set_cmd)
2977 (maintenance_show_cmd, set_per_command_cmd)
2978 (show_per_command_cmd, maintenance_check_command): Constify.
2979 * language.c (set_check, show_check): Constify.
2980 * typeprint.c (show_print_type, set_print_type): Constify.
2981 * go32-nat.c (go32_info_dos_command): Constify.
2982
fdf44873
TT
29832017-10-11 Tom Tromey <tom@tromey.com>
2984
2985 * breakpoint.c (prepare_re_set_context): Remove.
2986 (breakpoint_re_set_one): Update. Don't use cleanups.
2987 (breakpoint_re_set): Use scoped_restore, std::string, and
2988 scoped_restore_current_language.
2989
81b1e71c
TT
29902017-10-11 Tom Tromey <tom@tromey.com>
2991
2992 * breakpoint.c (commands_command_1): Use std::string.
2993 (cleanup_executing_breakpoints): Remove.
2994 (bpstat_do_actions_1): Use scoped_restore.
2995 (bpstat_check_watchpoint): Use std::string.
2996 (decode_static_tracepoint_spec): Likewise.
2997 (break_range_command): Likewise.
2998 (watch_command_1): Likewise.
2999 (compare_breakpoints): Change argument types.
3000 (clear_command): Use std::vector.
3001 (cleanup_executing_breakpoints): Remove.
3002 (update_global_location_list): Use unique_xmalloc_ptr.
3003 (strace_command): Remove unused declaration.
3004
4f9d9906
JB
30052017-10-11 John Baldwin <jhb@FreeBSD.org>
3006
3007 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
3008 * NEWS: Mention new FreeBSD/arm native configuration.
3009 * configure.host: Add arm*-*-freebsd*.
3010 * configure.nat: Likewise.
3011 * arm-fbsd-nat.c: New file.
3012
7176dfd2
JB
30132017-10-11 John Baldwin <jhb@FreeBSD.org>
3014
3015 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
3016 (ALLDEPFILES): Add arm-fbsd-tdep.c.
3017 * NEWS: Mention new FreeBSD/arm target.
3018 * configure.tgt: Add arm*-*-freebsd*.
3019 * arm-fbsd-tdep.c: New file.
3020 * arm-fbsd-tdep.h: New file.
3021
fe220226
MR
30222017-10-11 Maciej W. Rozycki <macro@imgtec.com>
3023
3024 * linux-tdep.c (linux_make_corefile_notes): Remove call to
3025 `gdbarch_elfcore_write_linux_prpsinfo'.
3026 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
3027 method.
3028 (elf_internal_linux_prpsinfo): Remove declaration.
3029 * gdbarch.h: Regenerate.
3030 * gdbarch.c: Regenerate.
3031
a2f63b2e
MR
30322017-10-11 Maciej W. Rozycki <macro@imgtec.com>
3033
3034 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
3035 `set_gdbarch_elfcore_write_linux_prpsinfo'.
3036
458ca1d0
PA
30372017-10-11 Pedro Alves <palves@redhat.com>
3038
3039 * breakpoint.c (reattach_breakpoints): Delete.
3040 * breakpoint.h (reattach_breakpoints): Delete.
3041
905014d7
SM
30422017-10-11 Simon Marchi <simon.marchi@ericsson.com>
3043
3044 * symfile.c (registered_sym_fns): Make struct, not typedef.
3045 (DEF_VEC_O (registered_sym_fns)): Remove.
3046 (symtab_fns): Change type to std::vector.
3047 (add_symtab_fns): Adjust.
3048 (find_sym_fns): Adjust.
3049
56d704da
AK
30502017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
3051
3052 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
3053 * arc-tdep.h (arc_arch_is_em): New function.
3054 (arc_arch_is_hs): Likewise.
3055
7fa29be9
EB
30562017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
3057
3058 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
3059 parentheses in the declaration.
3060 (macro_lookup_inclusion): Likewise.
3061 (macro_lookup_definition): Likewise.
3062 * p-lang.h (pascal_builtin_types): Likewise.
3063 * tui/tui-data.c (tui_win_list): Likewise.
3064 * tui/tui-data.h (tui_win_list): Likewise.
3065 * utils.h (make_cleanup_free_section_addr_info): Likewise.
3066
d9b477e3
KB
30672017-10-11 Mark Rages <markrages@gmail.com>
3068
3069 * target-memory.c (block_boundaries): Fix for block address not
3070 aligned on block size.
3071
65630365
PA
30722017-10-10 Pedro Alves <palves@redhat.com>
3073 Tom Tromey <tom@tromey.com>
3074
3075 * breakpoint.c (struct captured_breakpoint_query_args)
3076 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
3077 (print_breakpoint): New.
3078 * breakpoint.h (print_breakpoint): Declare.
3079 * common/common-exceptions.h (enum return_reason): Remove
3080 references to catch_exceptions.
3081 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
3082 Delete.
3083 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
3084 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
3085 * gdb.h: Delete.
3086 * gdbthread.h (thread_select): Declare.
3087 * mi/mi-cmd-break.c: Don't include gdb.h.
3088 (breakpoint_notify): Use print_breakpoint.
3089 * mi/mi-cmd-catch.c: Don't include gdb.h.
3090 * mi/mi-interp.c: Don't include gdb.h.
3091 (mi_print_breakpoint_for_event): New.
3092 (mi_breakpoint_created, mi_breakpoint_modified): Use
3093 mi_print_breakpoint_for_event.
3094 * mi/mi-main.c: Don't include gdb.h.
3095 (mi_cmd_thread_select): Parse the global thread ID here. Use
3096 thread_select instead of gdb_thread_select.
3097 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
3098 of using gdb_list_thread_ids.
3099 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
3100 FILEIO_ENOSYS here.
3101 (remote_fileio_request): Use TRY/CATCH instead of
3102 catch_exceptions.
3103 * symfile-mem.c (struct symbol_file_add_from_memory_args)
3104 (symbol_file_add_from_memory_wrapper): Delete.
3105 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
3106 * thread.c: Don't include gdb.h.
3107 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
3108 (thread_alive): Use thread_select.
3109 (do_captured_thread_select): Delete, parts salvaged as ...
3110 (thread_select): ... this new function.
3111 (gdb_thread_select): Delete.
3112
bf469271
PA
31132017-10-10 Pedro Alves <palves@redhat.com>
3114 Tom Tromey <tom@tromey.com>
3115
3116 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
3117 and reverse logic.
3118 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
3119 No longer macros. Instead ...
3120 (enum wp_check_result): They're now values of this new
3121 enumeration.
3122 (watchpoint_check): Change return type to wp_check_result and
3123 parameter type to bpstat.
3124 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
3125 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
3126 catch_errors. Reverse logic of watchpoint_check call.
3127 (breakpoint_re_set_one): Now returns void and takes a breakpoint
3128 pointer as parameter.
3129 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
3130 * common/common-exceptions.c (throw_exception_sjlj): Update
3131 comments to avoid mentioning catch_errors.
3132 * exceptions.c (catch_errors): Delete.
3133 * exceptions.h: Update comments to avoid mentioning catch_errors.
3134 (catch_errors_ftype, catch_errors): Delete.
3135 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
3136 (hook_stop_stub): Delete.
3137 (restore_selected_frame): Change return type to void, and
3138 parameter type to const frame_id &.
3139 (restore_infcall_control_state): Use TRY/CATCH instead of
3140 catch_errors.
3141 * main.c (captured_command_loop): Return void and remove
3142 parameter. Remove references to catch_errors.
3143 (captured_main): Use TRY/CATCH instead of catch_errors.
3144 * objc-lang.c (objc_submethod_helper_data)
3145 (find_objc_msgcall_submethod_helper): Delete.
3146 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
3147 catch_errors.
3148 * record-full.c (record_full_message): Return void.
3149 (record_full_message_args, record_full_message_wrapper): Delete.
3150 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
3151 instead of catch_errors.
3152 * solib-aix.c (solib_aix_open_symbol_file_object): Change
3153 parameter type to int.
3154 * solib-darwin.c (open_symbol_file_object): Ditto.
3155 * solib-dsbt.c (open_symbol_file_object): Ditto.
3156 * solib-frv.c (open_symbol_file_object): Ditto.
3157 * solib-svr4.c (open_symbol_file_object): Ditto.
3158 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
3159 * solib.c (update_solib_list): Use TRY/CATCH instead of
3160 catch_errors.
3161 * solist.h (struct target_so_ops) <open_symbol_file_object>:
3162 Change type.
3163 * symmisc.c (struct print_symbol_args): Remove.
3164 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
3165 (print_symbol): Change type.
3166 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
3167 and remove parameters.
3168 (catch_errors): New.
3169 (get_windows_debug_event): Adjust.
3170
1a56bfa5
TT
31712017-10-09 Tom Tromey <tom@tromey.com>
3172
3173 * mi/mi-main.c (free_splay_tree): Remove.
3174 (list_available_thread_groups): Use splay_tree_up.
3175 * common/gdb_splay_tree.h: New file.
3176
0c478e2d
TT
31772017-10-09 Tom Tromey <tom@tromey.com>
3178
3179 * mi/mi-main.c (do_nothing): Remove.
3180 (list_available_thread_groups): Update.
3181
cbd2b4e3
PA
31822017-10-09 Pedro Alves <palves@redhat.com>
3183
3184 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
3185 reading registers when switching context.
3186
a181c0bf
JB
31872017-10-09 John Baldwin <jhb@FreeBSD.org>
3188
3189 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
3190 (fbsd_convert_siginfo): Likewise.
3191 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
3192
6e66f753
SM
31932017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
3194
3195 * configure.ac (try_guile_versions): Remove guile-2.2.
3196 * configure: Regenerate.
3197
890e9790
TT
31982017-10-09 Tom Tromey <tom@tromey.com>
3199
3200 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
3201 (COMPILE.pre): Use $(CXX).
3202
109483d9
PA
32032017-10-09 Pedro Alves <palves@redhat.com>
3204
3205 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
3206 Use bool.
3207 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
3208 * cp-support.h (cp_remove_params): Now returns a
3209 gdb::unique_xmalloc_ptr.
3210 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
3211 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
3212 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
3213 returning a gdb::unique_xmalloc_ptr.
3214 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
3215 * stack.c (find_frame_funname): Adjust to cp_remove_params
3216 returning a gdb::unique_xmalloc_ptr.
3217
791afaa2
TT
32182017-10-08 Tom Tromey <tom@tromey.com>
3219
3220 * dwarf2read.c (dwarf2_get_dwz_file): Use
3221 gdb::unique_xmalloc_ptr.
3222 (find_slot_in_mapped_hash): Likewise.
3223 (dwarf2_physname): Likewise.
3224 (create_dwo_unit_in_dwp_v1): Use std::string.
3225 (create_dwo_unit_in_dwp_v2): Likewise.
3226 (lookup_dwo_cutu): Likewise.
3227 (inherit_abstract_dies): Use std::vector.
3228 (read_array_type): Likewise.
3229 (dwarf_decode_macros): Remove unused declaration.
3230 (unsigned_int_compar): Remove.
3231 (dwarf2_build_psymtabs_hard): Use scoped_restore.
3232 (psymtabs_addrmap_cleanup): Remove.
3233
30a9c02f
TT
32342017-10-08 Tom Tromey <tom@tromey.com>
3235
3236 * frame-unwind.c (frame_unwind_try_unwinder): Update.
3237 * frame.h (frame_cleanup_after_sniffer): Declare.
3238 (frame_prepare_for_sniffer): Return void.
3239 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
3240 type of argument.
3241 (frame_prepare_for_sniffer): Return void.
3242
757325a3
TT
32432017-10-08 Tom Tromey <tom@tromey.com>
3244
3245 * utils.h (make_cleanup_value_free): Remove.
3246 * utils.c (do_value_free, struct cleanup): Remove.
3247 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
3248 Use gdb_value_up.
3249 * value.h (struct value_deleter): New.
3250 (gdb_value_up): New typedef.
3251
b9c04fb2
TT
32522017-10-08 Tom Tromey <tom@tromey.com>
3253
3254 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
3255 (make_cleanup_free_search_symbols): Remove.
3256 (search_symbols): Return std::vector.
3257 (symbol_search::compare_search_syms): Now member of
3258 symbol_search. Change arguments.
3259 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
3260 (symtab_symbol_info, rbreak_command): Update.
3261 * symtab.h (struct symbol_search) <next>: Remove.
3262 Add constructors.
3263 (symbol_search::operator<): New function.
3264 (symbol_search::operator==): New function.
3265 (search_symbols): Remove std::vector.
3266 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
3267 (symbol_search::compare_search_syms): Declare.
3268
0d28b0a5
YQ
32692017-10-06 Yao Qi <yao.qi@linaro.org>
3270
3271 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
3272 arch/aarch64-insn.o.
3273 Remove one rule.
3274 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
3275
71917808
YQ
32762017-10-06 Yao Qi <yao.qi@linaro.org>
3277
3278 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
3279 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
3280 arch/arm-linux.o respectively.
3281 * configure.tgt: Likewise.
3282
2081b2b2
YQ
32832017-10-06 Yao Qi <yao.qi@linaro.org>
3284
3285 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
3286 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
3287
a1b85d28
PA
32882017-10-06 Pedro Alves <palves@redhat.com>
3289
3290 * windows-nat.c: Include <algorithm>.
3291
d97987e2
YQ
32922017-10-06 Yao Qi <yao.qi@linaro.org>
3293
3294 * configure.tgt (i386_tobjs): New variable.
3295 (amd64_tobjs): New variable.
3296 Set $cpu_obs and $os_obs.
3297
f38307f5
YQ
32982017-10-06 Yao Qi <yao.qi@linaro.org>
3299
3300 * Makefile.in (CONFIG_SRC_SUBDIR): New.
3301 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
3302 (clean): Remove object files and dependency files.
3303 (distclean): Remove the directory.
3304 * configure.ac: Invoke AC_CONFIG_COMMANDS.
3305 * configure: Re-generated.
3306 * configure.tgt: Replace amd64.o with arch/amd64.o.
3307
2f924de6
JM
33082017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
3309
3310 PR build/22188
3311 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
3312 and SETEND.
3313
2fd9d7ca
PA
33142017-10-05 Pedro Alves <palves@redhat.com>
3315
3316 * linux-nat.c (linux_child_follow_fork): When following the parent
3317 and detaching the child, consult the parent thread's architecture
3318 instead of the child's.
3319
d13b8493
UW
33202017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3321
3322 * ax.h: Do not include "doublest.h".
3323 (union agent_val): Remove.
3324
3b4b2f16
UW
33252017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3326
3327 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
3328 (decimal_to_string): Return std::string object.
3329 (decimal_from_string): Accept std::string object. Return bool.
3330 (decimal_from_integral, decimal_from_doublest): Remove.
3331 (decimal_from_longest): Add prototype.
3332 (decimal_from_ulongest): Likewise.
3333 (decimal_to_longest): Likewise.
3334 (decimal_from_doublest): Likewise.
3335 * dfp.c: Do not include "gdbtypes.h" or "value.h".
3336 (MAX_DECIMAL_STRING): Move here.
3337 (decimal_to_string): Return std::string object.
3338 (decimal_from_string): Accept std::string object. Return bool.
3339 (decimal_from_integral): Remove, replace by ...
3340 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
3341 (decimal_to_longest): New function.
3342 (decimal_from_floating): Remove, replace by ...
3343 (decimal_from_doublest): ... this new function.
3344 (decimal_to_doublest): Update to new decimal_to_string interface.
3345
3346 * value.c (unpack_long): Use decimal_to_longest.
3347 * valops.c (value_cast): Use decimal_from_doublest instead of
3348 decimal_from_floating. Use decimal_from_[u]longest isntead of
3349 decimal_from_integral.
3350 * valarith.c (value_args_as_decimal): Likewise.
3351 * valprint.c (print_decimal_floating): Update to new
3352 decimal_to_string interface.
3353 * printcmd.c (printf_decfloat): Likewise.
3354 * c-exp.y (parse_number): Update to new decimal_from_string interface.
3355
1841ee5d
UW
33562017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3357
3358 * doublest.h: Do not include "floatformat.h". Remove stale comments.
3359 * gdbtypes.c: Include "floatformat.h".
3360 * value.c: Likewise.
3361 * m68k-tdep.c: Likewise.
3362
3363 * findvar.c: Do not include "floatformat.h".
3364 * amd64-darwin-tdep.c: Likewise.
3365 * arm-linux-tdep.c: Likewise.
3366 * i386-darwin-tdep.c: Likewise.
3367 * i387-tdep.c: Likewise.
3368 * m68k-linux-tdep.c: Likewise.
3369 * mep-tdep.c: Likewise.
3370 * mips-tdep.c: Likewise.
3371 * nios2-tdep.c: Likewise.
3372 * s390-linux-tdep.c: Likewise.
3373 * sparc-obsd-tdep.c: Likewise.
3374 * sparc-tdep.c: Likewise.
3375 * sparc64-tdep.c: Likewise.
3376 * spu-tdep.c: Likewise.
3377 * tic6x-tdep.c: Likewise.
3378 * tilegx-tdep.c: Likewise.
3379 * vax-tdep.c: Likewise.
3380 * xstormy16-tdep.c: Likewise.
3381 * xtensa-tdep.c: Likewise.
3382
3383 * top.c: Do not include "doublest.h".
3384 * aarch64-tdep.c: Likewise.
3385 * alpha-tdep.c: Likewise.
3386 * arm-linux-tdep.c: Likewise.
3387 * m68k-linux-tdep.c: Likewise.
3388 * tilegx-tdep.c: Likewise.
3389 * xstormy16-tdep.c: Likewise.
3390
a80a6471
JB
33912017-10-05 John Baldwin <jhb@FreeBSD.org>
3392
3393 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
3394 (mipsn32_fbsd_sigframe): Define.
3395 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
3396 for FreeBSD/mipsn32.
3397
12c4bd7f
JB
33982017-10-05 John Baldwin <jhb@FreeBSD.org>
3399
3400 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
3401 AT_HWCAP.
3402
c91933e9
TG
34032017-10-05 Tristan Gingold <tgingold@free.fr>
3404
3405 * MAINTAINERS (Misc): Update my email address.
3406
5cd63fda
PA
34072017-10-04 Pedro Alves <palves@redhat.com>
3408
3409 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
3410 it instead of target_gdbarch.
3411 (get_remote_state, get_remote_packet_size): Adjust
3412 get_remote_arch_state calls, passing down target_gdbarch
3413 explicitly.
3414 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
3415 'gdbarch' and use it instead of target_gdbarch.
3416 (get_memory_packet_size): Adjust get_remote_arch_state calls,
3417 passing down target_gdbarch explicitly.
3418 (struct stop_reply) <arch>: New field.
3419 (remote_parse_stop_reply): Use the stopped thread's architecture,
3420 not the current inferior's. Save the architecture in the
3421 stop_reply.
3422 (process_stop_reply): Use the stop reply's architecture.
3423 (process_g_packet, remote_fetch_registers)
3424 (remote_prepare_to_store, store_registers_using_G)
3425 (remote_store_registers): Adjust get_remote_arch_state calls,
3426 using the regcache's architecture.
3427 (remote_get_trace_status): Adjust get_remote_arch_state calls,
3428 passing down target_gdbarch explicitly.
3429 * spu-multiarch.c (spu_thread_architecture): Defer to the target
3430 beneath instead of calling target_gdbarch.
3431 * target.c (default_thread_architecture): Use the specified
3432 inferior's architecture, instead of the current inferior's
3433 architecture (via target_gdbarch).
3434
ed4227b7
PA
34352017-10-04 Pedro Alves <palves@redhat.com>
3436
3437 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
3438 case.
3439 (regcache_print): Handle !target_has_registers here instead.
3440
55b11ddf
PA
34412017-10-04 Pedro Alves <palves@redhat.com>
3442
3443 * frame.c (create_test_frame): Delete.
3444 * frame.h (create_test_frame): Delete.
3445 * gdbarch-selftests.c: Include gdbthread.h and target.h.
3446 (class regcache_test): Delete.
3447 (test_target_has_registers, test_target_has_stack)
3448 (test_target_has_memory, test_target_prepare_to_store)
3449 (test_target_store_registers): New functions.
3450 (test_target_ops): New class.
3451 (register_to_value_test): Error out if there's already a
3452 process_stratum (or higher) target pushed. Create a fuller mock
3453 environment, with mock target_ops, inferior, address space, thread
3454 and inferior_ptid.
3455 * progspace.c (struct address_space): Move to ...
3456 * progspace.h (struct address_space): ... here.
3457 * regcache.h (regcache::~regcache, regcache::raw_write)
3458 [GDB_SELF_TEST]: No longer virtual.
3459
4c71c105
SM
34602017-10-04 Simon Marchi <simon.marchi@ericsson.com>
3461
3462 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
3463
73dcd72d
PA
34642017-10-04 Pedro Alves <palves@redhat.com>
3465
3466 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
3467 out of 'between TRY and CATCH'.
3468
44704526
PA
34692017-10-04 Pedro Alves <palves@redhat.com>
3470
3471 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
3472 * common/common-exceptions.h (TRY): Open an outermost scope.
3473 Expand intro comment.
3474 (CATCH): Reindent.
3475 (END_CATCH): Close the outermost scope.
3476 * completer.c (complete_line_internal): Add missing END_CATCH.
3477
bc3b087d
SDJ
34782017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3479
3480 * NEWS (Changes since GDB 8.0): Add entry about new
3481 'set-cwd-on-gdbserver' feature.
3482 (New remote packets): Add entry for QSetWorkingDir.
3483 * common/common-inferior.h (set_inferior_cwd): New prototype.
3484 * infcmd.c (set_inferior_cwd): Remove "static".
3485 (show_cwd_command): Expand text to include remote debugging.
3486 * remote.c: Add PACKET_QSetWorkingDir.
3487 (remote_protocol_features) <QSetWorkingDir>: New entry for
3488 PACKET_QSetWorkingDir.
3489 (extended_remote_set_inferior_cwd): New function.
3490 (extended_remote_create_inferior): Call
3491 "extended_remote_set_inferior_cwd".
3492 (_initialize_remote): Call "add_packet_config_cmd" for
3493 QSetWorkingDir.
3494
d092c5a2
SDJ
34952017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3496
3497 * NEWS (New commands): Mention "set/show cwd".
3498 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
3499 "cd" command's help text.
3500 * common/common-inferior.h (get_inferior_cwd): New prototype.
3501 * infcmd.c (inferior_cwd_scratch): New global variable.
3502 (set_inferior_cwd): New function.
3503 (get_inferior_cwd): Likewise.
3504 (set_cwd_command): Likewise.
3505 (show_cwd_command): Likewise.
3506 (_initialize_infcmd): Add "set/show cwd" commands.
3507 * inferior.h (class inferior) <cwd>: New field.
3508 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
3509 (fork_inferior): Change inferior's cwd before its execution.
3510 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
3511 to CreateProcess.
3512
7da0a886
SDJ
35132017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3514
3515 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
3516 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
3517 (COMMON_OBS): Add gdb_tilde_expand.o.
3518 * common/gdb_tilde_expand.c: New file.
3519 * common/gdb_tilde_expand.h: Likewise.
3520
db8dd160
MR
35212017-10-03 Maciej W. Rozycki <macro@imgtec.com>
3522
3523 * gdbarch.sh (objfile): Remove duplicate declaration.
3524 * gdbarch.h: Regenerate.
3525
f8bfbf22
TT
35262017-10-03 Tom Tromey <tom@tromey.com>
3527
3528 * utils.c (internal_vproblem): Use string_vprintf.
3529
5178ed48
TT
35302017-10-03 Tom Tromey <tom@tromey.com>
3531
3532 * printcmd.c (info_symbol_command): Use std::string.
3533
8cff8730
TT
35342017-10-03 Tom Tromey <tom@tromey.com>
3535
3536 * top.c (gdb_safe_append_history): Use std::string.
3537
895b8f30
TT
35382017-10-03 Tom Tromey <tom@tromey.com>
3539
3540 * event-top.c (stdin_event_handler): Update.
3541 * main.c (captured_main_1): Update.
3542 * top.h (make_delete_ui_cleanup): Remove.
3543 (struct ui): Add constructor and destructor.
3544 (new_ui, delete_ui): Remove.
3545 * top.c (make_delete_ui_cleanup): Remove.
3546 (new_ui_command): Use std::unique_ptr.
3547 (delete_ui_cleanup): Remove.
3548 (ui::ui): Rename from new_ui. Update.
3549 (free_ui): Remove.
3550 (ui::~ui): Rename from delete_ui. Update.
3551
0efef640
TT
35522017-10-03 Tom Tromey <tom@tromey.com>
3553
3554 * symfile.c (load_progress): Use gdb::byte_vector.
3555
245ad7d3
TT
35562017-10-03 Tom Tromey <tom@tromey.com>
3557
3558 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
3559 declaration.
3560 * printcmd.c (x_command): Remove unused declaration.
3561 * symfile.c (symbol_file_command): Remove unused declaration.
3562
e05550d7
TT
35632017-10-03 Tom Tromey <tom@tromey.com>
3564
3565 * utils.c (internal_vproblem): Use std::string.
3566 (defaulted_query): Likewise.
3567
b95de2b7
TT
35682017-10-03 Tom Tromey <tom@tromey.com>
3569
3570 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
3571 * top.c (execute_command_to_string): Update.
3572 * utils.c (make_cleanup_restore_page_info): Remove.
3573 (do_restore_page_info_cleanup): Remove.
3574 (set_batch_flag_and_restore_page_info):
3575 New.
3576 (make_cleanup_restore_page_info): Remove.
3577 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
3578 (~set_batch_flag_and_restore_page_info): New
3579 (make_cleanup_restore_uinteger): Remove.
3580 (make_cleanup_restore_integer): Remove.
3581 (struct restore_integer_closure): Remove.
3582 (restore_integer): Remove.
3583 * utils.h (struct set_batch_flag_and_restore_page_info): New
3584 class.
3585 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
3586 (make_cleanup_restore_page_info): Remove.
3587 (make_cleanup_restore_uinteger) Remove.
3588 (make_cleanup_restore_integer) Remove.
3589
07036511
TT
35902017-10-03 Tom Tromey <tom@tromey.com>
3591
3592 * record-full.h (record_full_gdb_operation_disable_set): Return
3593 scoped_restore_tmpl<int>.
3594 * infrun.c (adjust_pc_after_break): Update.
3595 (handle_signal_stop): Update.
3596 * record-full.c (record_full_gdb_operation_disable_set): Return
3597 scoped_restore_tmpl<int>.
3598 (record_full_wait_1, record_full_insert_breakpoint)
3599 (record_full_remove_breakpoint, record_full_save)
3600 (record_full_goto_insn): Update.
3601
45320ffa
TT
36022017-10-02 Tom Tromey <tom@tromey.com>
3603
3604 PR rust/22236:
3605 * rust-lang.c (rust_val_print_str): New function.
3606 (val_print_struct): Call it.
3607 (rust_subscript): Preserve name of slice type.
3608
b3e3859b
TT
36092017-10-02 Tom Tromey <tom@tromey.com>
3610
3611 * rust-lang.c (rust_subscript): Handle slices in
3612 EVAL_AVOID_SIDE_EFFECTS case.
3613
01af5e0d
TT
36142017-10-02 Tom Tromey <tom@tromey.com>
3615
3616 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
3617
888e3ddb
TT
36182017-10-02 Tom Tromey <tom@tromey.com>
3619
3620 * rust-lang.h (rust_slice_type): Add "extern".
3621
cc536b21
PA
36222017-10-02 Tom Tromey <tom@tromey.com>
3623 Pedro Alves <palves@redhat.com>
3624
3625 * ada-lang.h (ada_exc_info::operator<): Make const.
3626 (ada_exc_info::operator==): Make const.
3627 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
3628 Make const.
3629
386c8614
TT
36302017-09-29 Tom Tromey <tom@tromey.com>
3631
3632 * target.c (read_whatever_is_readable): Change type of "result".
3633 Update.
3634 (free_memory_read_result_vector): Remove.
3635 (read_memory_robust): Change return type. Update.
3636 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
3637 bin2hex, std::string.
3638 * target.h (memory_read_result_s): Remove typedef.
3639 (free_memory_read_result_vector): Remove.
3640 (read_memory_robust): Return std::vector.
3641
789c4b5e
TT
36422017-09-29 Tom Tromey <tom@tromey.com>
3643
3644 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
3645
ab816a27
TT
36462017-09-29 Tom Tromey <tom@tromey.com>
3647
3648 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
3649 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
3650 operator< and operator==.
3651 (ada_exceptions_list): Return a std::vector.
3652 * ada-lang.c (ada_exc_info::operator<): Rename from
3653 compare_ada_exception_info.
3654 (ada_exc_info::operator==): New.
3655 (sort_remove_dups_ada_exceptions_list): Change type of
3656 "exceptions".
3657 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
3658 (ada_add_global_exceptions): Likewise.
3659 (ada_exceptions_list_1): Return a std::vector.
3660 (ada_exceptions_list): Likewise.
3661
52f9abe4
TT
36622017-09-29 Tom Tromey <tom@tromey.com>
3663
3664 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
3665 'std::set *'.
3666 (print_one_inferior): Update.
3667 (free_vector_of_ints): Remove.
3668 (list_available_thread_groups): Change "ids" to std::set.
3669 (mi_cmd_list_thread_groups): Update.
3670 (struct collect_cores_data) <core>: Now a std::set.
3671 (collect_cores): Update.
3672 (unique): Remove.
3673 (print_one_inferior): Update.
3674
dcd5ddcc
TT
36752017-09-29 Tom Tromey <tom@tromey.com>
3676
3677 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
3678 (mi_execute_async_cli_command): Likewise.
3679 (mi_cmd_trace_frame_collected): Use field_fmt.
3680
45d288cc
TT
36812017-09-29 Tom Tromey <tom@tromey.com>
3682
3683 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
3684 gdb::byte_vector.
3685
6afe2f4a
TT
36862017-09-29 Tom Tromey <tom@tromey.com>
3687
3688 * mi/mi-parse.c (mi_parse): Remove unused declaration.
3689
9813429a
TT
36902017-09-29 Tom Tromey <tom@tromey.com>
3691
3692 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
3693
2d6960b4
TT
36942017-09-29 Tom Tromey <tom@tromey.com>
3695
3696 * varobj.h (varobj_gen_name): Return std::string.
3697 * varobj.c (varobj_gen_name): Return std::string.
3698 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
3699 (mi_cmd_var_delete): Don't copy "name".
3700
784c453a
TT
37012017-09-29 Tom Tromey <tom@tromey.com>
3702
3703 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
3704 (mi_cmd_break_insert_1): Update.
3705
a9bc57b9
TT
37062017-09-29 Tom Tromey <tom@tromey.com>
3707
3708 * target.h (make_scoped_defer_target_commit_resume): Update.
3709 * target.c (make_scoped_defer_target_commit_resume): Rename from
3710 make_cleanup_defer_target_commit_resume. Return a
3711 scoped_restore.
3712 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
3713
9754d8c4
TT
37142017-09-29 Tom Tromey <tom@tromey.com>
3715
3716 * main.c (captured_main_1): Remove unused declaration.
3717 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
3718
99ef965c
TT
37192017-09-29 Tom Tromey <tom@tromey.com>
3720
3721 * symtab.c (search_symbols): Remove unused outer cleanup.
3722 (make_source_files_completion_list): Remove unused declaration.
3723
42518ba7
TT
37242017-09-29 Tom Tromey <tom@tromey.com>
3725
3726 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
3727
726b2169
TT
37282017-09-29 Tom Tromey <tom@tromey.com>
3729
3730 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
3731 gdb::byte_vector.
3732
55b06432
TT
37332017-09-29 Tom Tromey <tom@tromey.com>
3734
3735 * complaints.c (vcomplaint): Use std::string.
3736
8abcee91
TT
37372017-09-29 Tom Tromey <tom@tromey.com>
3738
3739 * tracepoint.c (trace_variable_command): Use std::string.
3740 (encode_actions_1): Remove unused declarations.
3741 (create_tsv_from_upload): Use std::string.
3742
6ad94bc7
TT
37432017-09-29 Tom Tromey <tom@tromey.com>
3744
3745 * cp-support.c (gdb_demangle): Use std::string.
3746
2003f3d8
TT
37472017-09-29 Tom Tromey <tom@tromey.com>
3748
3749 * stack.c (parse_frame_specification): Use std::string
3750 (info_frame_command): Use gdb::unique_xmalloc_ptr.
3751
8f8accb5
TT
37522017-09-29 Tom Tromey <tom@tromey.com>
3753
3754 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
3755
200aa7b1
TT
37562017-09-29 Tom Tromey <tom@tromey.com>
3757
3758 * utils.c (vfprintf_maybe_filtered): Use std::string.
3759 (vfprintf_unfiltered): Likewise.
3760
606aae8a
TT
37612017-09-29 Tom Tromey <tom@tromey.com>
3762
3763 * event-top.c (top_level_prompt): Return std::string.
3764 (display_gdb_prompt): Update.
3765
bd413795
TT
37662017-09-29 Tom Tromey <tom@tromey.com>
3767
3768 * unittests/common-utils-selftests.c (format): New function.
3769 (string_vprintf_tests): New function.
3770 (_initialize_common_utils_selftests): Register new tests.
3771 * common/common-utils.c (string_vprintf): New function.
3772 * common/common-utils.h (string_vprintf): Declare.
3773
256642e8
PA
37742017-09-29 Pedro Alves <palves@redhat.com>
3775
3776 * common/rsp-low.c (unpack_varlen_hex): Constify.
3777 * common/rsp-low.h (unpack_varlen_hex): Constify.
3778 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
3779 Constify.
3780 * remote.c (remote_set_permissions, read_ptid)
3781 (remote_current_thread, remote_get_threads_with_qthreadinfo)
3782 (remote_static_tracepoint_marker_at)
3783 (remote_static_tracepoint_markers_by_strid)
3784 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
3785 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
3786 (parse_tracepoint_definition, parse_tsv_definition)
3787 (parse_static_tracepoint_marker_definition): Constify.
3788 * tracepoint.h (parse_static_tracepoint_marker_definition)
3789 (parse_trace_status, parse_tracepoint_status)
3790 (parse_tracepoint_definition, parse_tsv_definition): Constify.
3791
b6bb3468
PA
37922017-09-29 Pedro Alves <palves@redhat.com>
3793
3794 * remote.c (target_buf, target_buf_size): Delete.
3795 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
3796 Use the connection's packet buffer instead.
3797 All callers adjusted.
3798 (_initialize_remote): Remove references to target_buf and
3799 target_buf_size.
3800
b2f8eb7a
PA
38012017-09-28 Pedro Alves <palves@redhat.com>
3802
3803 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3804 unittests/common-utils-selftests.c.
3805 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
3806 (COMMON_OBS): Remove utils-selftests.o.
3807 * utils-selftests.c: Move to ...
3808 * unittests/common-utils-selftests.c: ... here and rename self
3809 test to "string_printf".
3810
08302ed2
DE
38112017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
3812
3813 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
3814 having NULL cus or tus.
3815
96a5a1d3
UW
38162017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3817
3818 * arm-tdep.c: (convert_from_extended): Remove.
3819 (convert_to_extended): Likewise.
3820 (arm_extract_return_value): Use convert_typed_floating.
3821 (arm_store_return_value): Likewise.
3822
3823 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
3824 * sh-tdep.c: Do not include "floatformat.h".
3825 (sh_littlebyte_bigword_type): New function.
3826 (sh_register_convert_to_virtual): Use convert_typed_floating.
3827 (sh_register_convert_to_raw): Likewise.
3828 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
3829 (sh64_littlebyte_bigword_type): New function.
3830 (sh64_extract_return_value): Use convert_typed_floating.
3831 (sh64_register_convert_to_virtual): Likewise.
3832 (sh64_register_convert_to_raw): Likewise.
3833
0db7851f
UW
38342017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3835
3836 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
3837 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
3838
3839 * gdbtypes.h (union type_specific): Make field floatformat hold
3840 just a single struct floatformat, not an array.
3841 (floatformat_from_type): Move here.
3842 * gdbtypes.c (floatformat_from_type): Move here. Update to
3843 changed TYPE_FLOATFORMAT definition.
3844 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
3845 (recursive_dump_type): Likewise.
3846 (init_float_type): Install correct floatformat for byte order.
3847 (arch_float_type): Likewise.
3848
77b7c781
UW
38492017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3850
3851 * gdbtypes.c (init_type): Change incoming argument from
3852 length-in-bytes to length-in-bits. Assert length is a
3853 multiple of TARGET_CHAR_BITS.
3854 (arch_type, arch_flags_type): Likewise.
3855 (init_integer_type): Update call to init_type.
3856 (init_character_type): Likewise.
3857 (init_boolean_type): Likewise.
3858 (init_float_type): Likewise.
3859 (init_decfloat_type): Likewise.
3860 (init_complex_type): Likewise.
3861 (init_pointer_type): Likewise.
3862 (objfile_type): Likewise.
3863 (arch_integer_type): Update call to arch_type.
3864 (arch_character_type): Likewise.
3865 (arch_boolean_type): Likewise.
3866 (arch_float_type): Likewise.
3867 (arch_decfloat_type): Likewise.
3868 (arch_complex_type): Likewise.
3869 (arch_pointer_type): Likewise.
3870 (gdbtypes_post_init): Likewise.
3871
3872 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
3873 (read_base_type): Likewise.
3874 * mdebugread.c (basic_type): Likewise.
3875 * stabsread.c (dbx_init_float_type): Likewise.
3876 (rs6000_builtin_type): Likewise.
3877 (read_range_type): Likewise. Also, fix call to init_integer_type
3878 with erroneous length argument.
3879
3880 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
3881 * d-lang.c (build_d_types): Likewise.
3882 * f-lang.c (build_fortran_types): Likewise.
3883 * go-lang.c (build_go_types): Likewise.
3884 * opencl-lang.c (build_opencl_types): Likewise.
3885 * jit.c (finalize_symtab): Likewise.
3886 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
3887 (build_std_type_info_type): Likewise.
3888 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
3889 update call to arch_flags_type.
3890
3891 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
3892 arch_type.
3893 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
3894 * windows-tdep.c (windows_get_tlb_type): Likewise.
3895
3896 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
3897 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
3898 * m32c-tdep.c (make_types): Likewise.
3899 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
3900 (rl78_psw_type): Update call to arch_flags_type.
3901 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
3902 * rx-tdep.c (rx_psw_type): Likewise.
3903 (rx_fpsw_type): Likewise.
3904 * sparc-tdep.c (sparc_psr_type): Likewise.
3905 (sparc_fsr_type): Likewise.
3906 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
3907 (sparc64_ccr_type): Likewise.
3908 (sparc64_fsr_type): Likewise.
3909 (sparc64_fprs_type): Likewise.
3910
f21b4d5c
TT
39112017-09-27 Tom Tromey <tom@tromey.com>
3912
3913 * findcmd.c (find_command): Constify.
3914
643c2ffa
TT
39152017-09-27 Tom Tromey <tom@tromey.com>
3916
3917 * ada-tasks.c (task_command_1, task_command): Constify.
3918
510e5e56
TT
39192017-09-27 Tom Tromey <tom@tromey.com>
3920
3921 * symtab.c (maintenance_print_symbol_cache)
3922 (maintenance_flush_symbol_cache)
3923 (maintenance_print_symbol_cache_statistics): Constify.
3924
e503b191
TT
39252017-09-27 Tom Tromey <tom@tromey.com>
3926
3927 * inferior.c (detach_inferior_command, kill_inferior_command)
3928 (inferior_command): Constify.
3929
4e001312
TT
39302017-09-27 Tom Tromey <tom@tromey.com>
3931
3932 * regcache.c (regcache_print, maintenance_print_registers)
3933 (maintenance_print_raw_registers)
3934 (maintenance_print_cooked_registers)
3935 (maintenance_print_register_groups)
3936 (maintenance_print_remote_registers): Constify.
3937
77763700
TT
39382017-09-27 Tom Tromey <tom@tromey.com>
3939
3940 * printcmd.c (map_display_numbers, undisplay_command)
3941 (enable_disable_display_command, enable_display_command)
3942 (disable_display_command): Constify.
3943
4495129a
TT
39442017-09-27 Tom Tromey <tom@tromey.com>
3945
3946 * breakpoint.h (delete_command): Don't declare.
3947 * breakpoint.c (delete_command, enable_once_command)
3948 (enable_count_command, enable_delete_command, breakpoint_1)
3949 (maintenance_info_breakpoints, stopin_command, stopat_command)
3950 (delete_command, delete_trace_command, save_breakpoints)
3951 (save_breakpoints_command, save_tracepoints_command): Constify.
3952
3088cf40
TT
39532017-09-27 Tom Tromey <tom@tromey.com>
3954
3955 * macrocmd.c (macro_expand_command, macro_expand_once_command)
3956 (skip_ws, extract_identifier, macro_define_command)
3957 (macro_undef_command, macro_list_command): Constify.
3958
69f476a3
TT
39592017-09-27 Tom Tromey <tom@tromey.com>
3960
3961 * infcmd.c (environment_info, set_environment_command)
3962 (unset_environment_command, path_info, info_proc_cmd_1)
3963 (info_proc_cmd_mappings, info_proc_cmd_stat)
3964 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
3965 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
3966
c4a3e68e
TT
39672017-09-27 Tom Tromey <tom@tromey.com>
3968
3969 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
3970 Constify.
3971
c9d31bd6
TT
39722017-09-27 Tom Tromey <tom@tromey.com>
3973
3974 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
3975
1f3f85eb
TT
39762017-09-27 Tom Tromey <tom@tromey.com>
3977
3978 * demangle.c (demangle_command): Constify.
3979
9c504b5d
TT
39802017-09-27 Tom Tromey <tom@tromey.com>
3981
3982 * progspace.c (maintenance_info_program_spaces_command):
3983 Constify.
3984
6663cf91
TT
39852017-09-27 Tom Tromey <tom@tromey.com>
3986
3987 * compile/compile.c (check_raw_argument, compile_file_command)
3988 (compile_code_command, compile_print_command): Constify.
3989
34e5fa26
TT
39902017-09-27 Tom Tromey <tom@tromey.com>
3991
3992 * reggroups.c (maintenance_print_reggroups): Constify.
3993
8384c356
TT
39942017-09-27 Tom Tromey <tom@tromey.com>
3995
3996 * dwarf2read.c (save_gdb_index_command): Constify.
3997
884beb0c
TT
39982017-09-27 Tom Tromey <tom@tromey.com>
3999
4000 * stap-probe.c (info_probes_stap_command): Constify.
4001
e0b2930c
TT
40022017-09-27 Tom Tromey <tom@tromey.com>
4003
4004 * fork-child.c (unset_exec_wrapper_command): Constify.
4005
f938677d
TT
40062017-09-27 Tom Tromey <tom@tromey.com>
4007
4008 * btrace.c (get_uint, get_context_size, no_chunk)
4009 (maint_btrace_packet_history_cmd)
4010 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
4011 (maint_info_btrace_cmd): Constify.
4012
8949cb87
TT
40132017-09-27 Tom Tromey <tom@tromey.com>
4014
4015 * reverse.c (delete_bookmark_command): Constify.
4016
ac88e2de
TT
40172017-09-27 Tom Tromey <tom@tromey.com>
4018
4019 * remote.c (set_memory_packet_size)
4020 (set_memory_write_packet_size, show_memory_write_packet_size)
4021 (set_memory_read_packet_size, show_memory_read_packet_size)
4022 (compare_sections_command, packet_command, remote_put_command)
4023 (remote_get_command, remote_delete_command): Constify.
4024
bd4c9dfe
TT
40252017-09-27 Tom Tromey <tom@tromey.com>
4026
4027 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
4028 (set_mipsfpu_double_command, set_mipsfpu_none_command)
4029 (set_mipsfpu_auto_command): Constify.
4030
5e93d4c6
TT
40312017-09-27 Tom Tromey <tom@tromey.com>
4032
4033 * cli/cli-cmds.h (cd_command): Constify.
4034 * cli/cli-cmds.c (cd_command): Constify.
4035
fc41a75b
TT
40362017-09-27 Tom Tromey <tom@tromey.com>
4037
4038 * thread.c (thread_name_command, thread_find_command): Constify.
4039
67810076
TT
40402017-09-27 Tom Tromey <tom@tromey.com>
4041
4042 * probe.c (enable_probes_command, disable_probes_command):
4043 Constify.
4044
1d8b34a7
TT
40452017-09-27 Tom Tromey <tom@tromey.com>
4046
4047 * symfile.c (symbol_file_command): Constify.
4048 * gdbcore.h (deprecated_file_changed_hook): Constify.
4049 * exec.c (deprecated_file_changed_hook, exec_file_command)
4050 (file_command): Constify.
4051 * defs.h (symbol_file_command): Constify.
4052
442019e1
TT
40532017-09-27 Tom Tromey <tom@tromey.com>
4054
4055 * remote-fileio.c (set_system_call_allowed)
4056 (show_system_call_allowed): Constify.
4057
2983f7cb
TT
40582017-09-27 Tom Tromey <tom@tromey.com>
4059
4060 * tracepoint.c (delete_trace_variable_command)
4061 (tfind_end_command, tfind_start_command, tfind_pc_command)
4062 (tfind_tracepoint_command, tfind_line_command)
4063 (tfind_range_command, tfind_outside_command): Constify.
4064
4fd41b24
TT
40652017-09-27 Tom Tromey <tom@tromey.com>
4066
4067 * ax-gdb.c (maint_agent_printf_command, agent_command)
4068 (agent_eval_command): Constify.
4069
f2fc3015
TT
40702017-09-27 Tom Tromey <tom@tromey.com>
4071
4072 * tracepoint.c (info_scope_command): Constify.
4073 * python/python.c (gdbpy_decode_line): Constify.
4074 * python/py-breakpoint.c (bppy_init): Constify.
4075 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
4076 * location.h: (new_linespec_location)
4077 (string_to_event_location_basic, string_to_event_location):
4078 Constify.
4079 * location.c (new_linespec_location)
4080 (string_to_event_location_basic, string_to_event_location):
4081 Constify.
4082 * linespec.h (decode_line_with_current_source)
4083 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
4084 * linespec.c (linespec_lex_to_end)
4085 (decode_line_with_current_source)
4086 (decode_line_with_last_displayed): Constify.
4087 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
4088 Constify.
4089 * cli/cli-cmds.c (edit_command, list_command): Constify.
4090 * breakpoint.h (until_break_command, watch_command_wrapper)
4091 (awatch_command_wrapper, rwatch_command_wrapper)
4092 (init_ada_exception_breakpoint): Constify.
4093 * breakpoint.c (break_command_1, dprintf_command)
4094 (break_range_command, watch_command_wrapper)
4095 (rwatch_command_wrapper, awatch_command_wrapper)
4096 (until_break_command, init_ada_exception_breakpoint)
4097 (strace_marker_create_sals_from_location, trace_command)
4098 (ftrace_command, strace_command, struct tracepoint): Constify.
4099 * ax-gdb.c (agent_command_1): Constify.
4100 * ada-lang.c (ada_exception_sal): Constify.
4101
8c2f95f4
TT
41022017-09-27 Tom Tromey <tom@tromey.com>
4103
4104 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
4105 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
4106 (get_context_size, no_chunk, get_insn_history_modifiers)
4107 (cmd_record_insn_history, get_call_history_modifiers)
4108 (cmd_record_call_history): Constify.
4109
a0d65762
TT
41102017-09-27 Tom Tromey <tom@tromey.com>
4111
4112 * source.c (show_substitute_path_command)
4113 (unset_substitute_path_command, set_substitute_path_command):
4114 Constify.
4115
58971144
TT
41162017-09-27 Tom Tromey <tom@tromey.com>
4117
4118 * typeprint.c (maintenance_print_type): Constify.
4119 * maint.c (maintenance_dump_me, maintenance_demangle)
4120 (maintenance_time_display, maintenance_info_sections)
4121 (maintenance_print_statistics, maintenance_deprecate)
4122 (maintenance_undeprecate): Constify.
4123 (maintenance_do_deprecate): Constify. Use std::string.
4124 (maintenance_selftest): Constify.
4125 * gdbtypes.h (maintenance_print_type): Constify.
4126
c482f52c
TT
41272017-09-27 Tom Tromey <tom@tromey.com>
4128
4129 * hppa-tdep.c (unwind_command): Constify.
4130
e100df1a
TT
41312017-09-27 Tom Tromey <tom@tromey.com>
4132
4133 * target-descriptions.c (unset_tdesc_filename_cmd)
4134 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
4135 Constify.
4136
31d56ade
TT
41372017-09-27 Tom Tromey <tom@tromey.com>
4138
4139 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
4140
b961da0b
TT
41412017-09-27 Tom Tromey <tom@tromey.com>
4142
4143 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
4144
e2d8ae16
TT
41452017-09-27 Tom Tromey <tom@tromey.com>
4146
4147 * tui/tui-regs.c (tui_reg_command): Constify.
4148
863779b0
TT
41492017-09-27 Tom Tromey <tom@tromey.com>
4150
4151 * skip.c (skip_file_command, skip_function_command)
4152 (skip_enable_command, skip_disable_command, skip_delete_command):
4153 Constify.
4154
cdb34d4a
TT
41552017-09-27 Tom Tromey <tom@tromey.com>
4156
4157 * record-btrace.c (cmd_record_btrace_bts_start)
4158 (cmd_record_btrace_pt_start): Constify.
4159
e99c83e7
TT
41602017-09-27 Tom Tromey <tom@tromey.com>
4161
4162 * symmisc.c (maintenance_print_symbols)
4163 (maintenance_print_msymbols, maintenance_print_objfiles)
4164 (maintenance_info_symtabs, maintenance_check_symtabs)
4165 (maintenance_expand_symtabs, maintenance_info_line_tables):
4166 Constify.
4167
32faf971
TT
41682017-09-27 Tom Tromey <tom@tromey.com>
4169
4170 * top.c (new_ui_command): Constify.
4171
2cf311eb
TT
41722017-09-27 Tom Tromey <tom@tromey.com>
4173
4174 * symfile.c (add_symbol_file_command)
4175 (remove_symbol_file_command, list_overlays_command)
4176 (map_overlay_command, unmap_overlay_command)
4177 (overlay_auto_command, overlay_manual_command)
4178 (overlay_off_command, overlay_load_command): Constify.
4179
e6738699
TT
41802017-09-27 Tom Tromey <tom@tromey.com>
4181
4182 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
4183 (info_spu_mailbox_command, info_spu_dma_command)
4184 (info_spu_proxydma_command): Constify.
4185
aa360cd5
TT
41862017-09-27 Tom Tromey <tom@tromey.com>
4187
4188 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
4189
898241a5
TT
41902017-09-27 Tom Tromey <tom@tromey.com>
4191
4192 * cli/cli-script.c (user_defined_command): Constify.
4193
2d0ac106
TT
41942017-09-27 Tom Tromey <tom@tromey.com>
4195
4196 * cli/cli-dump.c (dump_memory_command, dump_value_command)
4197 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
4198 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
4199 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
4200 (dump_binary_value, append_binary_memory, append_binary_value):
4201 Constify.
4202 (struct dump_context) <func>: Constify.
4203 (add_dump_command): Update.
4204
dede02ce
TT
42052017-09-27 Tom Tromey <tom@tromey.com>
4206
4207 * cli/cli-cmds.c (show_version, show_configuration)
4208 (source_command, show_user): Constify.
4209
d3cb6b99
TT
42102017-09-27 Tom Tromey <tom@tromey.com>
4211
4212 * target.c (maintenance_print_target_stack): Constify.
4213
1970a12f
TT
42142017-09-27 Tom Tromey <tom@tromey.com>
4215
4216 * interps.c (interpreter_exec_cmd): Constify.
4217
41243651
TT
42182017-09-27 Tom Tromey <tom@tromey.com>
4219
4220 * record-full.c (cmd_record_full_restore): Constify.
4221
4465d9db
TT
42222017-09-27 Tom Tromey <tom@tromey.com>
4223
4224 * memattr.c (enable_mem_command, disable_mem_command)
4225 (delete_mem_command): Constify.
4226
ad25e423
TT
42272017-09-27 Tom Tromey <tom@tromey.com>
4228
4229 * value.c (show_convenience): Constify.
4230
d64097b1
TT
42312017-09-27 Tom Tromey <tom@tromey.com>
4232
4233 * gdbcore.h (core_file_command): Update.
4234 * corefile.c (core_file_command): Constify.
4235
4d4589ef
TT
42362017-09-27 Tom Tromey <tom@tromey.com>
4237
4238 * user-regs.c (maintenance_print_user_registers): Constify.
4239
32a7bf17
TT
42402017-09-27 Tom Tromey <tom@tromey.com>
4241
4242 * cp-namespace.c (maintenance_cplus_namespace): Constify.
4243
4a475551
TT
42442017-09-27 Tom Tromey <tom@tromey.com>
4245
4246 * cp-support.c (first_component_command): Constify.
4247
990b9f9f
TT
42482017-09-27 Tom Tromey <tom@tromey.com>
4249
4250 * psymtab.c (maintenance_print_psymbols)
4251 (maintenance_info_psymtabs, maintenance_check_psymtabs):
4252 Constify.
4253
c281872e
TT
42542017-09-27 Tom Tromey <tom@tromey.com>
4255
4256 * windows-tdep.c (display_tib): Constify.
4257
5b64bf74
TT
42582017-09-27 Tom Tromey <tom@tromey.com>
4259
4260 * linux-fork.c (delete_checkpoint_command)
4261 (detach_checkpoint_command): Constify.
4262
4ada038f
TT
42632017-09-27 Tom Tromey <tom@tromey.com>
4264
4265 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
4266
57f5a81b
TT
42672017-09-27 Tom Tromey <tom@tromey.com>
4268
4269 * arc-tdep.c (dump_arc_instruction_command): Constify.
4270
b0a8e6c4
TT
42712017-09-27 Tom Tromey <tom@tromey.com>
4272
4273 * valprint.c (set_radix, show_radix): Constify.
4274
8d97dc1c
TT
42752017-09-27 Tom Tromey <tom@tromey.com>
4276
4277 * dtrace-probe.c (info_probes_dtrace_command): Constify.
4278
eb7c454d
TT
42792017-09-27 Tom Tromey <tom@tromey.com>
4280
4281 * command.h (not_just_help_class_command): Update.
4282 * cli/cli-decode.h (not_just_help_class_command): Update.
4283 * cli/cli-decode.c (not_just_help_class_command): Constify.
4284
e4e33335
TT
42852017-09-27 Tom Tromey <tom@tromey.com>
4286
4287 * gdb_bfd.c (maintenance_info_bfds): Constify.
4288
0450cc4c
TT
42892017-09-27 Tom Tromey <tom@tromey.com>
4290
4291 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
4292 overloads.
4293 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
4294 (do_const_cfunc): New function.
4295 (cmd_cfunc_eq): New overload.
4296 (cli_user_command_p): Check do_const_cfunc.
4297 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
4298 const_cfunc.
4299 * command.h (add_cmd): Add const overload and no-function
4300 overload.
4301 (set_cmd_cfunc): Add const overload.
4302 (cmd_const_cfunc_ftype): Declare.
4303 (cmd_cfunc_eq): Add const overload.
4304 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
4305 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
4306 overload.
4307
a9bbfbd8
TT
43082017-09-27 Tom Tromey <tom@tromey.com>
4309
4310 * macroexp.c (get_next_token_for_substitution): New function.
4311 (substitute_args): Call it. Check for __VA_OPT__.
4312
5230b05a
WT
43132017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
4314 Pedro Alves <palves@redhat.com>
4315
4316 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
4317 producer_is_icc_lt_14.
4318 (producer_is_icc_lt_14): New function.
4319 (check_producer): Add code for checking version of ICC.
4320 (producer_is_icc): Move to producer.c.
4321 (read_structure_type): Restrict ICC workaround to ICC<14.
4322 * producer.c: Include selftest.h.
4323 (producer_is_icc, producer_parsing_tests, _initialize_producer):
4324 New functions.
4325 * producer.h (producer_is_icc): New declaration.
4326
b32b108a
WT
43272017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
4328
4329 * Makefile.in (SFILES): Add producer.c.
4330 (COMMON_OBS): Add producer.o
4331 * amd64-tdep.c (producer.h): Add new include.
4332 * dwarf2read.c (producer.h): Add new include.
4333 * producer.c: New file.
4334 * producer.h: New file.
4335 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
4336 producer.c.
4337 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
4338 producer.h.
4339
5007d765
MK
43402017-09-26 Matthias Klose <doko@ubuntu.com>
4341
4342 * configure.ac: Search ncursesw before ncurses.
4343 Check ncursesw/ncurses.h before ncurses/ncurses.h.
4344 * gdb_curses.h: Include <ncursesw/ncurses.h>
4345 * config.in, configure: Regenerate.
4346
281c4447
RO
43472017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4348
4349 PR gdb/22185
4350 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
4351 obsolete.
4352 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
4353 Remove i386sol2 support.
4354 * configure.nat <i386sol2>: Remove.
4355 <sol2-64>: Fold into ...
4356 <sol2>: ... this.
4357 Move common settings to default section.
4358 Add sol-thread.o.
4359 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
4360 x86_64-*-solaris2.1[0-9]*>: Rename to ...
4361 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
4362 <i[34567]86-*-solaris*>: Remove.
4363 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
4364
4365 * configure.ac: Remove wctype in libw check.
4366 (_MSE_INT_H): Don't define on Solaris 7-9.
4367 <solaris*>: Remove libthread_db.so.1 check.
4368 * configure: Regenerate.
4369 * config.in: Regenerate.
4370
4371 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
4372 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
4373 (gdb_ps_size_t): Remove.
4374 Use base types in users.
4375 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
4376
4377 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
4378
39b06c20
RO
43792017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4380
4381 PR build/22206
4382 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
4383 (adi_is_addr_mapped): Likewise.
4384 (PSR_ICC): Don't redefine.
4385 (PSR_IMPL): Likewise.
4386
6c3e20f1
TT
43872017-09-25 Tom Tromey <tom@tromey.com>
4388
4389 * regcache.c (regcache::dump): Use string_printf.
4390
b292235f
TT
43912017-09-25 Tom Tromey <tom@tromey.com>
4392
4393 * regcache.c (class regcache_invalidator): New.
4394 (struct register_to_invalidate): Remove.
4395 (make_cleanup_regcache_invalidate): Remove.
4396 (regcache::raw_write): Use regcache_invalidator.
4397
9ac86b52
TT
43982017-09-25 Tom Tromey <tom@tromey.com>
4399
4400 * spu-tdep.c (spu2ppu_sniffer): Update.
4401 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
4402 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
4403 Remove.
4404 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
4405 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
4406 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
4407 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
4408 (frame_pop): Update.
4409
c0e383c6
TT
44102017-09-25 Tom Tromey <tom@tromey.com>
4411
4412 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
4413 * regcache.h (regcache_xfree): Don't declare.
4414 * regcache.c (regcache_xfree): Remove.
4415 (do_regcache_xfree): Use delete.
4416 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
4417 * linux-fork.c (free_fork): Use delete.
4418 (fork_save_infrun_state): Likewise.
4419 * jit.c (jit_dealloc_cache): Use delete.
4420 * infrun.c (discard_infcall_suspend_state): Use delete.
4421
791199cc
TT
44222017-09-25 Tom Tromey <tom@tromey.com>
4423
4424 * regcache.h (regcache_xmalloc): Don't declare.
4425 (regcache_raw_set_cached_value): Update comment.
4426 * regcache.c (regcache_xmalloc): Remove.
4427 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
4428 * jit.c (jit_frame_sniffer): Use new.
4429 * frame.c (frame_save_as_regcache): Use new.
4430
289e23aa
AA
44312017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4432
4433 * NEWS: Advertise support for guarded-storage registers on IBM z.
4434
1b63490c
AA
44352017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4436
4437 * s390-linux-nat.c (have_regset_gs): New static variable.
4438 (s390_linux_fetch_inferior_registers): Handle guarded-storage
4439 control block and guarded-storage broadcast control regsets.
4440 (s390_read_description): Detect whether the target has
4441 guarded-storage support, return appropriate tdesc.
4442 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
4443 (features/s390x-gs-linux64.c): Likewise.
4444 (struct gdbarch_tdep) <have_gs>: New field.
4445 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
4446 (s390_gsbc_regset): New variables.
4447 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
4448 and s390_gsbc_regset, if applicable.
4449 (s390_core_read_description): Check whether core file was from a
4450 target with guarded-storage support; include appropriate regsets.
4451 (s390_gdbarch_init): Add registers for guarded-storage support.
4452 (_initialize_s390_tdep): Initialize new target descriptions that
4453 include registers for guarded-storage support.
4454 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
4455 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
4456 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
4457 (S390_NUM_REGS): Adjust macro definition.
4458 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
4459 (tdesc_s390x_gs_linux64): New declarations.
4460
96235dc1
AA
44612017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4462
4463 * features/s390-gs-linux64.xml: New file.
4464 * features/s390-gs.xml: New file.
4465 * features/s390-gsbc.xml: New file.
4466 * features/s390x-gs-linux64.xml: New file.
4467 * features/Makefile (WHICH): Add s390-gs-linux64 and
4468 s390x-gs-linux64.
4469 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
4470 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
4471 * features/s390-gs-linux64.c: New generated file.
4472 * features/s390x-gs-linux64.c: New file.
4473 * regformats/s390-gs-linux64.dat: New file.
4474 * regformats/s390x-gs-linux64.dat: New file.
4475
b4a7c699
TT
44762017-09-23 Tom Tromey <tom@tromey.com>
4477
4478 * defs.h (make_cleanup_override_quit_handler): Don't declare.
4479
c2f97536
TT
44802017-09-22 Tom Tromey <tom@tromey.com>
4481
4482 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
4483 type to scoped_restore_tmpl.
4484 <scoped_input_handler>: Initialize m_quit_handler directly.
4485
43573013
SDJ
44862017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
4487
4488 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
4489 (cd_command): Likewise. Free "current_directory" before
4490 assigning to it.
4491 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
4492 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
4493 * top.c (gdb_dirbuf): Remove global declaration.
4494 * top.h (gdb_dirbuf): Likewise.
4495
6ec2e0f5
SDJ
44962017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
4497
4498 * gnulib/aclocal.m4: Regenerate.
4499 * gnulib/config.in: Regenerate.
4500 * gnulib/configure: Regenerate.
4501 * gnulib/import/Makefile.am: Regenerate.
4502 * gnulib/import/Makefile.in: Regenerate.
4503 * gnulib/import/assure.h: New file.
4504 * gnulib/import/at-func.c: Likewise
4505 * gnulib/import/chdir-long.c: New file.
4506 * gnulib/import/chdir-long.h: New file.
4507 * gnulib/import/cloexec.c: New file.
4508 * gnulib/import/cloexec.h: New file.
4509 * gnulib/import/close.c: New file.
4510 * gnulib/import/closedir.c: New file.
4511 * gnulib/import/dirent-private.h: New file.
4512 * gnulib/import/dup-safer.c: New file.
4513 * gnulib/import/dup.c: New file.
4514 * gnulib/import/dup2.c: New file.
4515 * gnulib/import/error.c: New file.
4516 * gnulib/import/error.h: New file.
4517 * gnulib/import/exitfail.c: New file.
4518 * gnulib/import/exitfail.h: New file.
4519 * gnulib/import/fchdir.c: New file.
4520 * gnulib/import/fcntl.c: New file.
4521 * gnulib/import/fcntl.in.h: New file.
4522 * gnulib/import/fd-hook.c: New file.
4523 * gnulib/import/fd-hook.h: New file.
4524 * gnulib/import/fd-safer.c: New file.
4525 * gnulib/import/fdopendir.c: New file.
4526 * gnulib/import/filename.h: New file.
4527 * gnulib/import/filenamecat-lgpl.c: New file.
4528 * gnulib/import/filenamecat.h: New file.
4529 * gnulib/import/fstat.c: New file.
4530 * gnulib/import/fstatat.c: New file.
4531 * gnulib/import/getcwd-lgpl.c: New file.
4532 * gnulib/import/getcwd.c: New file.
4533 * gnulib/import/getdtablesize.c: New file.
4534 * gnulib/import/getlogin_r.c: New file.
4535 * gnulib/import/getprogname.c: New file.
4536 * gnulib/import/getprogname.h: New file.
4537 * gnulib/import/gettext.h: New file.
4538 * gnulib/import/glob-libc.h: New file.
4539 * gnulib/import/glob.c: New file.
4540 * gnulib/import/glob.in.h: New file.
4541 * gnulib/import/intprops.h: New file.
4542 * gnulib/import/m4/chdir-long.m4: New file.
4543 * gnulib/import/m4/close.m4: New file.
4544 * gnulib/import/m4/closedir.m4: New file.
4545 * gnulib/import/m4/d-ino.m4: New file.
4546 * gnulib/import/m4/d-type.m4: New file.
4547 * gnulib/import/m4/dup.m4: New file.
4548 * gnulib/import/m4/dup2.m4: New file.
4549 * gnulib/import/m4/error.m4: New file.
4550 * gnulib/import/m4/fchdir.m4: New file.
4551 * gnulib/import/m4/fcntl.m4: New file.
4552 * gnulib/import/m4/fcntl_h.m4: New file.
4553 * gnulib/import/m4/fdopendir.m4: New file.
4554 * gnulib/import/m4/filenamecat.m4: New file.
4555 * gnulib/import/m4/fstat.m4: New file.
4556 * gnulib/import/m4/fstatat.m4: New file.
4557 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
4558 * gnulib/import/m4/getcwd-path-max.m4: New file.
4559 * gnulib/import/m4/getcwd.m4: New file.
4560 * gnulib/import/m4/getdtablesize.m4: New file.
4561 * gnulib/import/m4/getlogin_r.m4: New file.
4562 * gnulib/import/m4/getprogname.m4: New file.
4563 * gnulib/import/m4/glob.m4: New file.
4564 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
4565 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
4566 * gnulib/import/m4/mempcpy.m4: New file.
4567 * gnulib/import/m4/memrchr.m4: New file.
4568 * gnulib/import/m4/mode_t.m4: New file.
4569 * gnulib/import/m4/msvc-inval.m4: New file.
4570 * gnulib/import/m4/msvc-nothrow.m4: New file.
4571 * gnulib/import/m4/open.m4: New file.
4572 * gnulib/import/m4/openat.m4: New file.
4573 * gnulib/import/m4/opendir.m4: New file.
4574 * gnulib/import/m4/readdir.m4: New file.
4575 * gnulib/import/m4/realloc.m4: New file.
4576 * gnulib/import/m4/rewinddir.m4: New file.
4577 * gnulib/import/m4/save-cwd.m4: New file.
4578 * gnulib/import/m4/strdup.m4: New file.
4579 * gnulib/import/m4/strerror.m4: New file.
4580 * gnulib/import/m4/unistd-safer.m4: New file.
4581 * gnulib/import/mempcpy.c: New file.
4582 * gnulib/import/memrchr.c: New file.
4583 * gnulib/import/msvc-inval.c: New file.
4584 * gnulib/import/msvc-inval.h: New file.
4585 * gnulib/import/msvc-nothrow.c: New file.
4586 * gnulib/import/msvc-nothrow.h: New file.
4587 * gnulib/import/open.c: New file.
4588 * gnulib/import/openat-die.c: New file.
4589 * gnulib/import/openat-priv.h: New file.
4590 * gnulib/import/openat-proc.c: New file.
4591 * gnulib/import/openat.c: New file.
4592 * gnulib/import/openat.h: New file.
4593 * gnulib/import/opendir.c: New file.
4594 * gnulib/import/pipe-safer.c: New file.
4595 * gnulib/import/readdir.c: New file.
4596 * gnulib/import/realloc.c: New file.
4597 * gnulib/import/rewinddir.c: New file.
4598 * gnulib/import/save-cwd.c: New file.
4599 * gnulib/import/save-cwd.h: New file.
4600 * gnulib/import/strdup.c: New file.
4601 * gnulib/import/strerror-override.c: New file.
4602 * gnulib/import/strerror-override.h: New file.
4603 * gnulib/import/strerror.c: New file.
4604 * gnulib/import/unistd--.h: New file.
4605 * gnulib/import/unistd-safer.h: New file.
4606 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
4607 "getcwd" and "glob".
4608 * ser-tcp.c: Undefine "close" before redefining it.
4609
432ae719
SM
46102017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4611
4612 * guile/scm-value.c (gdbscm_value_address): Initialize address,
4613 get rid of res_val.
4614
4fa7574e
RO
46152017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4616
4617 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
4618 <sol2,sparc>: Likewise.
4619 <sol2-64,i386>: Likewise.
4620
4621 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
4622 -Wdeprecated-declarations on *-*-solaris*.
4623 * configure: Regenerate.
4624
4625 * procfs.c: Include "nat/inferior.h".
4626 (procfs_info_proc): Fix typo.
4627
f6327dcb
KB
46282017-09-21 Kevin Buettner <kevinb@redhat.com>
4629
4630 * remote.c (vector): Include.
4631 (struct private_thread_info): Add field, thread_handle.
4632 (free_private_thread_info): Deallocate storage associated with
4633 thread handle.
4634 (get_private_info_thread): Initialize `thread_handle' field.
4635 (struct thread_item): Add field, thread_handle.
4636 (clear_threads_listing_context): Deallocate storage associated
4637 with thread handle.
4638 (start_thread): Add support for "handle" attribute.
4639 (thread_attributes): Add "handle".
4640 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
4641 field.
4642 (remote_update_thread_list): Update thread_handle.
4643 (remote_thread_handle_to_thread_info): New function.
4644 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
4645
fbbe5337
KB
46462017-09-21 Kevin Buettner <kevinb@redhat.com>
4647
4648 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
4649 function.
4650 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
4651 * python/python-internal.h (thread_object_type): Declare.
4652
e04ee09e
KB
46532017-09-21 Kevin Buettner <kevinb@redhat.com>
4654
4655 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
4656 (target_thread_handle_to_thread_info): Declare.
4657 * target.c (target_thread_handle_to_thread_info): New function.
4658 * target-delegates.c: Regenerate.
4659 * gdbthread.h (find_thread_by_handle): Declare.
4660 * thread.c (find_thread_by_handle): New function.
4661 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
4662 function.
4663 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
4664
1e5b66ed
SM
46652017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4666
4667 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
4668
ebe48ba0
SM
46692017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4670
4671 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
4672
0a0bf5dc
YQ
46732017-09-21 Yao Qi <yao.qi@linaro.org>
4674
4675 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
4676 to gdb_target_obs.
4677
d1b0a7bf
TT
46782017-09-20 Tom Tromey <tom@tromey.com>
4679
4680 * breakpoint.c (struct counted_command_line): Remove.
4681 (breakpoint_commands): Update.
4682 (alloc_counted_command_line, incref_counted_command_line)
4683 (decref_counted_command_line, do_cleanup_counted_command_line)
4684 (make_cleanup_decref_counted_command_line): Remove.
4685 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
4686 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
4687 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
4688 (save_breakpoints): Update.
4689 * breakpoint.h (counted_command_line): Now a typedef to
4690 shared_ptr.
4691 (struct breakpoint) <commands>: Now a counted_command_line.
4692 (struct bpstats) <command>: Likewise.
4693
48649e1b
TT
46942017-09-20 Tom Tromey <tom@tromey.com>
4695
4696 * breakpoint.c (struct commands_info, do_map_commands_command):
4697 Remove.
4698 (commands_command_1): Update.
4699 (iterate_over_related_breakpoints): Take a function_view.
4700 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
4701 (delete_command): Update.
4702 (map_breakpoint_numbers): Take a function_view.
4703 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
4704 (disable_command): Update.
4705 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
4706 (enable_command): Update.
4707 (struct disp_data, do_enable_breakpoint_disp)
4708 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
4709 (do_map_enable_delete_breakpoint): Remove.
4710 (enable_once_command, enable_count_command, enable_delete_command)
4711 (delete_trace_variable_command): Update.
4712
04afa70c
TT
47132017-09-20 Tom Tromey <tom@tromey.com>
4714
4715 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
4716 (bpstat_clear): Use delete.
4717 (bpstats): New constructors.
4718 (bpstat_copy, bpstat_stop_status): Use new.
4719 (dprintf_after_condition_true): Update.
4720 * breakpoint.h (bpstats::bpstats): Add constructors.
4721 (bpstats::~bpstats): Add destructor.
4722
c83833f4
PA
47232017-09-20 Pedro Alves <palves@redhat.com>
4724
4725 * eval.c (make_params): Delete, refactored as ...
4726 (class fake_method): ... this new type's ctor.
4727 (fake_method::~fake_method): New.
4728 (evaluate_subexp_standard): Use 'fake_method'.
4729
223ffa71
TT
47302017-09-20 Tom Tromey <tom@tromey.com>
4731
4732 * windows-nat.c (get_windows_debug_event, windows_wait)
4733 (do_initial_windows_stuff, windows_attach): Update.
4734 * utils.c (vwarning, internal_vproblem): Update.
4735 (ui_unregister_input_event_handler_cleanup)
4736 (prepare_to_handle_input): Remove.
4737 (class scoped_input_handler): New.
4738 (defaulted_query, prompt_for_continue): Update.
4739 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
4740 Update.
4741 * top.c (undo_terminal_modifications_before_exit): Update.
4742 * target/target.h (target_terminal_init, target_terminal_inferior)
4743 (target_terminal_ours): Don't declare.
4744 (class target_terminal): New.
4745 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
4746 (target_terminal_ours_for_output)
4747 (make_cleanup_restore_target_terminal): Don't declare.
4748 (target_terminal_info): Remove.
4749 * target.c (enum terminal_state, terminal_state): Remove.
4750 (target_terminal::terminal_state): Define.
4751 (target_terminal::init): Rename from target_terminal_init.
4752 (target_terminal::inferior): Rename from
4753 target_terminal_inferior.
4754 (target_terminal::ours): Rename from target_terminal_ours.
4755 (target_terminal::ours_for_output): Rename from
4756 target_terminal_ours_for_output.
4757 (target_terminal::info): New method.
4758 (cleanup_restore_target_terminal)
4759 (make_cleanup_restore_target_terminal): Remove.
4760 * solib.c (handle_solib_event): Update.
4761 * remote.c (remote_serial_quit_handler): Update.
4762 (remote_terminal_inferior, remote_wait_as): Update.
4763 * record-full.c (record_full_wait_1): Update.
4764 * nto-procfs.c (procfs_create_inferior): Update.
4765 * nat/fork-inferior.c (startup_inferior): Update.
4766 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
4767 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
4768 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
4769 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
4770 (mi_breakpoint_created, mi_breakpoint_deleted)
4771 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
4772 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
4773 (mi_user_selected_context_changed, report_initial_inferior):
4774 Update.
4775 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
4776 (linux_nat_terminal_inferior): Update.
4777 * infrun.c (follow_fork_inferior)
4778 (handle_vfork_child_exec_or_exit, do_target_resume)
4779 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
4780 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
4781 Update.
4782 * inflow.c (child_terminal_init, info_terminal_command): Update.
4783 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
4784 (attach_command): Update.
4785 * infcall.c (call_thread_fsm_should_stop): Update.
4786 * gnu-nat.c (gnu_attach): Update.
4787 * extension.c (struct active_ext_lang_state)
4788 (restore_active_ext_lang): Update.
4789 * exceptions.c (print_flush): Update.
4790 * event-top.c (async_enable_stdin, default_quit_handler): Update.
4791 (struct quit_handler_cleanup_data, restore_quit_handler)
4792 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
4793 Remove.
4794 * cp-support.c (gdb_demangle): Update.
4795 * breakpoint.c (update_inserted_breakpoint_locations)
4796 (insert_breakpoint_locations, handle_jit_event)
4797 (disable_breakpoints_in_unloaded_shlib): Update.
4798 * annotate.c (annotate_breakpoints_invalid)
4799 (annotate_frames_invalid): Update.
4800
013af3fc
TT
48012017-09-20 Tom Tromey <tom@tromey.com>
4802
4803 * main.c (catch_command_errors): Rename from
4804 catch_command_errors_const.
4805 (captured_main_1): Update.
4806
06871ae8
PA
48072017-09-20 Pedro Alves <palves@redhat.com>
4808
4809 * cli/cli-cmds.c (list_command): Use print_sal_location.
4810 (print_sal_location): New function.
4811 (ambiguous_line_spec): Use print_sal_location.
4812 * linespec.c (symbol_to_sal): Record the symbol in the sal.
4813 * symtab.c (find_function_start_sal): Likewise.
4814 * symtab.h (symtab_and_line::symbol): New field.
4815
e5f25bc5
PA
48162017-09-20 Pedro Alves <palves@redhat.com>
4817
4818 * linespec.c (minsym_found): Handle non-text minsyms.
4819 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
4820
1b7fa39e
WT
48212017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
4822
4823 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
4824 backslash.
4825
37dd0825
WT
48262017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
4827
4828 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
4829 vmovups instead vmovaps.
4830 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
4831
4e5a4f58
JB
48322017-09-19 John Baldwin <jhb@FreeBSD.org>
4833
4834 * NEWS (Changes since GDB 8.0): Add starti.
4835 * infcmd.c (enum run_break): New.
4836 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
4837 case.
4838 (run_command): Use enum run_how.
4839 (start_command): Likewise.
4840 (starti_command): New function.
4841 (RUN_ARGS_HELP): New macro.
4842 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
4843 commands. Add starti command.
4844
aa70c9f1
YQ
48452017-09-19 Yao Qi <yao.qi@linaro.org>
4846
4847 * Makefile.in (monitor.o): Remove the rule.
4848
d6541620
YQ
48492017-09-19 Yao Qi <yao.qi@linaro.org>
4850
4851 * annotate.h (struct annotate_arg_emitter): Use
4852 DISABLE_COPY_AND_ASSIGN.
4853 * common/refcounted-object.h (refcounted_object): Likewise.
4854 * completer.h (struct completion_result): Likewise.
4855 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
4856 * filename-seen-cache.h (filename_seen_cache): Likewise.
4857 * gdbcore.h (thread_section_name): Likewise.
4858 * gdb_regex.h (compiled_regex): Likewise.
4859 * gdbthread.h (scoped_restore_current_thread): Likewise.
4860 * inferior.h (scoped_restore_current_inferior): Likewise.
4861 * jit.c (jit_reader): Likewise.
4862 * linespec.h (struct linespec_result): Likewise.
4863 * mi/mi-parse.h (struct mi_parse): Likewise.
4864 * nat/fork-inferior.c (execv_argv): Likewise.
4865 * progspace.h (scoped_restore_current_program_space): Likewise.
4866 * python/python-internal.h (class gdbpy_enter): Likewise.
4867 * regcache.h (regcache): Likewise.
4868 * target-descriptions.c (struct tdesc_reg): Likewise.
4869 (struct tdesc_type): Likewise.
4870 (struct tdesc_feature): Likewise.
4871 * ui-out.h (ui_out_emit_type): Likewise.
4872
0615127c
SM
48732017-09-18 Simon Marchi <simon.marchi@ericsson.com>
4874
4875 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
4876 label abort_expression.
4877
5e187554
SM
48782017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4879
4880 * common/buffer.c (buffer_xml_printf): Adjust.
4881 * common/xml-utils.c (xml_escape_text): Change return type to
4882 std::string, update code accordingly.
4883 * common/xml-utils.h (xml_escape_text): Change return type to
4884 std::string.
4885 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
4886 * windows-tdep.c (windows_xfer_shared_library): Adjust.
4887 * unittests/xml-utils-selftests.c (test_xml_escape_text):
4888 Adjust.
4889
c3d7b541
SM
48902017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4891
4892 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
4893 (SUBDIR_UNITTESTS_OBS): Add new object file.
4894 * unittests/xml-utils-selftests.c: New file.
4895
1526853e
SM
48962017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4897
4898 * common/selftest.h (selftest): New struct/interface.
4899 (register_test): Add name parameter, add new overload.
4900 (run_tests): Add filter parameter.
4901 (for_each_selftest_ftype): New typedef.
4902 (for_each_selftest): New declaration.
4903 * common/selftest.c (tests): Change type to
4904 map<string, unique_ptr<selftest>>.
4905 (simple_selftest): New struct.
4906 (register_test): New function.
4907 (register_test): Add name parameter and use it.
4908 (run_tests): Add filter parameter and use it. Add prints.
4909 Adjust to vector -> map change.
4910 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
4911 registering selftests.
4912 * arm-tdep.c (_initialize_arm_tdep): Likewise.
4913 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
4914 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
4915 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
4916 * findvar.c (_initialize_findvar): Likewise.
4917 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
4918 * maint.c (maintenance_selftest): Update call to run_tests.
4919 (maintenance_info_selftests): New function.
4920 (_initialize_maint_cmds): Register "maintenance info selftests"
4921 command. Update "maintenance selftest" doc.
4922 * regcache.c (_initialize_regcache): Add names when registering
4923 selftests.
4924 * rust-exp.y (_initialize_rust_exp): Likewise.
4925 * selftest-arch.c (gdbarch_selftest): New struct.
4926 (gdbarch_tests): Remove.
4927 (register_test_foreach_arch): Add name parameter. Call
4928 register_test.
4929 (tests_with_arch): Remove, move most content to
4930 gdbarch_selftest::operator().
4931 (_initialize_selftests_foreach_arch): Remove.
4932 * selftest-arch.h (register_test_foreach_arch): Add name
4933 parameter.
4934 (run_tests_with_arch): New declaration.
4935 * utils-selftests.c (_initialize_utils_selftests): Add names
4936 when registering selftests.
4937 * utils.c (_initialize_utils): Likewise.
4938 * unittests/array-view-selftests.c
4939 (_initialize_array_view_selftests): Likewise.
4940 * unittests/environ-selftests.c (_initialize_environ_selftests):
4941 Likewise.
4942 * unittests/function-view-selftests.c
4943 (_initialize_function_view_selftests): Likewise.
4944 * unittests/offset-type-selftests.c
4945 (_initialize_offset_type_selftests): Likewise.
4946 * unittests/optional-selftests.c
4947 (_initialize_optional_selftests): Likewise.
4948 * unittests/scoped_restore-selftests.c
4949 (_initialize_scoped_restore_selftests): Likewise.
4950 * NEWS: Document "maintenance selftest" and "maint info
4951 selftests".
4952
5846367a
SM
49532017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4954
4955 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
4956 scoped_restore.
4957
bd77e8ff
SM
49582017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4959
4960 * mi/mi-main.c (mi_load_progress): Make uiout variable
4961 a unique_ptr.
4962
26a67918
PA
49632017-09-15 Pedro Alves <palves@redhat.com>
4964
4965 * compile/compile-c-types.c (convert_enum, convert_int)
4966 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
4967
3f8a7804
SM
49682017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4969
4970 * dwarf2read.c (copy_string): Remove.
4971 (parse_macro_definition): Replace copy_string with savestring.
4972
8d200706
YQ
49732017-09-15 Yao Qi <yao.qi@linaro.org>
4974
4975 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
4976 gdb_target_obs.
4977 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
4978 Likewise.
4979 (i[34567]86-*-linux*): Likewise.
4980
d185219d
SM
49812017-09-14 Simon Marchi <simon.marchi@ericsson.com>
4982
4983 * dwarf2expr.h (dwarf_stack_value): Add constructor.
4984 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
4985 <stack>: Change type to std::vector.
4986 <stack_len, stack_allocated>: Remove.
4987 <grow_stack>: Remove.
4988 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
4989 (dwarf_expr_context::~dwarf_expr_context): Remove.
4990 (dwarf_expr_context::grow_stack): Remove.
4991 (dwarf_expr_context::push): Adjust.
4992 (dwarf_expr_context::pop): Adjust.
4993 (dwarf_expr_context::fetch): Adjust.
4994 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
4995 (dwarf_expr_context::stack_empty_p): Adjust.
4996 (dwarf_expr_context::execute_stack_op): Adjust.
4997
eccd80d6
SM
49982017-09-14 Simon Marchi <simon.marchi@ericsson.com>
4999
5000 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
5001 return type to bool.
5002 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
5003
69009882
SM
50042017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5005
5006 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
5007 Change type to bool.
5008 (dwarf_stack_value) <in_stack_memory>: Likewise.
5009 (dwarf_expr_context) <push_address>: Change parameter type to
5010 bool.
5011 <fetch_in_stack_memory>: Change return type to bool.
5012 <push>: Change parameter type to bool.
5013 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
5014 to bool.
5015 (dwarf_expr_context::push_address): Likewise.
5016 (dwarf_expr_context::fetch_in_stack_memory): Change return type
5017 to bool.
5018 (dwarf_expr_context::execute_stack_op): Adjust.
5019 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
5020
1e467161
SM
50212017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5022
5023 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
5024 (struct dwarf_expr_context) <n_pieces>: Remove.
5025 <pieces>: Change type to std::vector.
5026 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
5027 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
5028 pieces.
5029 (dwarf_expr_context::add_piece): Adjust.
5030 * dwarf2loc.c (struct piece_closure): Initialize fields.
5031 <n_pieces>: Remove.
5032 <pieces>: Change type to std::vector.
5033 (allocate_piece_closure): Adjust, change parameter to
5034 std::vector rvalue and std::move it to piece_closure.
5035 (rw_pieced_value): Adjust.
5036 (check_pieced_synthetic_pointer): Adjust.
5037 (indirect_synthetic_pointer): Adjust.
5038 (coerce_pieced_ref): Adjust.
5039 (free_pieced_value_closure): Adjust. Use delete to free
5040 piece_closure.
5041 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
5042 to allocate_piece_closure.
5043 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
5044
0782db84
SM
50452017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5046
5047 * probe.h (probe_ops_cp): Remove typedef.
5048 (DEF_VEC_P (probe_ops_cp)): Remove.
5049 (all_probe_ops): Change type to std::vector.
5050 * probe.c (info_probes_for_ops): Adjust to vector change.
5051 (probe_linespec_to_ops): Likewise.
5052 (all_probe_ops): Change type to std::vector.
5053 (_initialize_probe): Adjust to vector change.
5054 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
5055 * elfread.c (elf_get_probes): Likewise.
5056 * stap-probe.c (_initialize_stap_probe): Likewise.
5057
1eac6bea
SM
50582017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5059
5060 * probe.h (struct bound_probe): Define constructors.
5061 * probe.c (bound_probe_s): Remove typedef.
5062 (DEF_VEC_O (bound_probe_s)): Remove VEC.
5063 (collect_probes): Change return type to std::vector, remove
5064 cleanup.
5065 (compare_probes): Return bool, change parameter type. Change
5066 semantic to "less than".
5067 (gen_ui_out_table_header_info): Change parameter to std::vector
5068 and update.
5069 (exists_probe_with_pops): Likewise.
5070 (info_probes_for_ops): Update to std::vector change.
5071 (enable_probes_command): Likewise.
5072 (disable_probes_command): Likewise.
5073
aaa63a31
SM
50742017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5075
5076 * probe.h (struct probe_ops) <get_probes>: Change parameter from
5077 vec to std::vector.
5078 * probe.c (parse_probes_in_pspace): Update.
5079 (find_probes_in_objfile): Update.
5080 (find_probe_by_pc): Update.
5081 (collect_probes): Update.
5082 (probe_any_get_probes): Update.
5083 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
5084 return type to reference to std::vector.
5085 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
5086 std::vector and update.
5087 (dtrace_process_dof): Likewise.
5088 (dtrace_get_probes): Likewise.
5089 * elfread.c (elf_get_probes): Change return type to std::vector,
5090 store an std::vector in bfd_data.
5091 (probe_key_free): Update to std::vector.
5092 * stap-probe.c (handle_stap_probe): Change parameter to
5093 std::vector and update.
5094 (stap_get_probes): Likewise.
5095 * symfile-debug.c (debug_sym_get_probes): Change return type to
5096 std::vector and update.
5097
cb85b21b
TT
50982017-09-11 Tom Tromey <tom@tromey.com>
5099
5100 * breakpoint.c (program_breakpoint_here_p): Update.
5101 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
5102 from make_show_memory_breakpoints_cleanup. Return a
5103 scoped_restore_tmpl<int>.
5104 (restore_show_memory_breakpoints): Remove.
5105 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
5106 * mem-break.c (memory_validate_breakpoint): Update.
5107 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
5108 (ia64_memory_remove_breakpoint): Update.
5109 (ia64_breakpoint_from_pc): Update.
5110 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
5111 from make_show_memory_breakpoints_cleanup.
5112
8fbc99ef
TT
51132017-09-11 Tom Tromey <tom@tromey.com>
5114
5115 * d-namespace.c (d_lookup_symbol): Use std::string.
5116 (find_symbol_in_baseclass): Likewise.
5117
50feb4bd
TT
51182017-09-11 Tom Tromey <tom@tromey.com>
5119
5120 * ctf.c (ctf_start): Use std::string.
5121
c6dc63a1
TT
51222017-09-11 Tom Tromey <tom@tromey.com>
5123
5124 * ada-lang.c (is_known_support_routine): Update.
5125 (ada_unhandled_exception_name_addr_from_raise): Update.
5126 * guile/scm-frame.c (gdbscm_frame_name): Update.
5127 * python/py-frame.c (frapy_name): Update.
5128 (frapy_function): Update.
5129 * stack.h (find_frame_funname): Update.
5130 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
5131 (print_frame): Update.
5132
d6b9b80f
TT
51332017-09-11 Tom Tromey <tom@tromey.com>
5134
5135 * findcmd.c (put_bits): Take a gdb::byte_vector.
5136 (parse_find_args): Return gdb::byte_vector. "args" now const.
5137 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
5138 cleanups.
5139 (find_command): Update.
5140
a9921622
TT
51412017-09-11 Tom Tromey <tom@tromey.com>
5142
5143 * cli/cli-script.c (class scoped_restore_hook_in): New.
5144 (clear_hook_in_cleanup): Remove.
5145 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
5146 scoped_restore_hook_in.
5147
be0d7abb
TT
51482017-09-11 Tom Tromey <tom@tromey.com>
5149
5150 * cli/cli-script.c (restore_interp): Remove.
5151 (read_command_lines): Use scoped_restore_interp.
5152 * interps.c (scoped_restore_interp::set_temp): Rename from
5153 interp_set_temp.
5154 * interps.h (class scoped_restore_interp): New.
5155 (interp_set_temp): Remove.
5156
00f675ff
TT
51572017-09-11 Tom Tromey <tom@tromey.com>
5158
5159 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
5160 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
5161 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
5162 scoped_restore.
5163 (mi_cmd_break_insert_1): Update.
5164 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
5165 scoped_restore.
5166
cb791d59
TT
51672017-09-11 Tom Tromey <tom@tromey.com>
5168
5169 * demangle.c (demangle_command): Update.
5170 * breakpoint.c (disable_command): Update.
5171 (enable_command): Update.
5172 (find_location_by_number): Make "number" const. Use
5173 get_number_trailer.
5174 * cli/cli-utils.c (extract_arg): Return std::string.
5175 * probe.c (parse_probe_linespec): Update. Change types.
5176 (collect_probes): Take string arguments.
5177 (parse_probe_linespec): Likewise.
5178 (info_probes_for_ops): Update.
5179 (enable_probes_command): Update.
5180 (disable_probes_command): Update.
5181 * break-catch-sig.c (catch_signal_split_args): Update.
5182 * mi/mi-parse.c (mi_parse): Update.
5183
2039bd9f
TT
51842017-09-11 Tom Tromey <tom@tromey.com>
5185
5186 * language.h (language_enum): Make argument const.
5187 * language.c (language_enum): Make argument const.
5188
f1735a53
TT
51892017-09-11 Tom Tromey <tom@tromey.com>
5190
5191 * common/common-utils.h (skip_to_space): Remove macro, redeclare
5192 as function.
5193 (skip_to_space): Rename from skip_to_space_const.
5194 * common/common-utils.c (skip_to_space): New function.
5195 (skip_to_space): Rename from skip_to_space_const.
5196 * cli/cli-utils.h (get_number): Rename from get_number_const.
5197 (extract_arg): Rename from extract_arg_const.
5198 * cli/cli-utils.c (get_number): Rename from get_number_const.
5199 (extract_arg): Rename from extract_arg_const.
5200 (number_or_range_parser::get_number): Use ::get_number.
5201 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
5202 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
5203 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
5204 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
5205 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
5206 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
5207 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
5208 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
5209
7d221d74
TT
52102017-09-11 Tom Tromey <tom@tromey.com>
5211
5212 * python/python.c (do_start_initialization): Use
5213 py-event-types.def to initialize types.
5214 Define all object type structures.
5215 * python/python-internal.h: Don't declare event initialization
5216 functions.
5217 * python/py-threadevent.c (thread_event_object_type): Don't
5218 define.
5219 * python/py-stopevent.c (stop_event_object_type): Don't define.
5220 * python/py-signalevent.c (signal_event_object_type): Don't
5221 declare or define.
5222 * python/py-newobjfileevent.c (new_objfile_event_object_type)
5223 (clear_objfiles_event_object_type): Don't declare or define.
5224 * python/py-infevents.c (inferior_call_pre_event_object_type)
5225 (inferior_call_post_event_object_type)
5226 (register_changed_event_object_type)
5227 (memory_changed_event_object_type): Don't declare or define.
5228 * python/py-inferior.c (new_thread_event_object_type)
5229 (new_inferior_event_object_type)
5230 (inferior_deleted_event_object_type): Don't declare or define.
5231 * python/py-exitedevent.c (exited_event_object_type): Don't
5232 declare or define.
5233 * python/py-evts.c (gdbpy_initialize_py_events): Use
5234 py-all-events.def.
5235 * python/py-events.h (thread_event_object_type): Don't declare.
5236 (events_object): Use py-all-events.def.
5237 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
5238 py-event-types.def.
5239 * python/py-event-types.def: New file.
5240 * python/py-continueevent.c (create_continue_event_object): Don't
5241 declare or define.
5242 * python/py-bpevent.c (breakpoint_event_object_type): Don't
5243 declare or define.
5244 * python/py-all-events.def: New file.
5245
35c61a1d
TT
52462017-09-11 Tom Tromey <tom@tromey.com>
5247
5248 * python/py-threadevent.c (create_thread_event_object): Return
5249 gdbpy_ref.
5250 * python/py-stopevent.h (create_stop_event_object)
5251 (create_breakpoint_event_object, create_signal_event_object):
5252 Update.
5253 * python/py-stopevent.c (create_stop_event_object): Return
5254 gdbpy_ref.
5255 (emit_stop_event): Update.
5256 * python/py-signalevent.c (create_signal_event_object): Return
5257 gdbpy_ref.
5258 * python/py-infevents.c (create_inferior_call_event_object):
5259 Update.
5260 * python/py-event.h (create_event_object)
5261 (create_thread_event_object): Update.
5262 * python/py-event.c (create_event_object): Return gdbpy_ref.
5263 * python/py-continueevent.c: Return gdbpy_ref.
5264 * python/py-bpevent.c (create_breakpoint_event_object): Return
5265 gdbpy_ref.
5266
7c96f8c1
TT
52672017-09-11 Tom Tromey <tom@tromey.com>
5268
5269 PR python/15622:
5270 * NEWS: Add entry.
5271 * python/python.c (do_start_initialization): Initialize new event
5272 types.
5273 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
5274 (gdbpy_initialize_inferior_deleted_event)
5275 (gdbpy_initialize_new_thread_event): Declare.
5276 * python/py-threadevent.c (create_thread_event_object): Add option
5277 "thread" parameter.
5278 * python/py-inferior.c (new_thread_event_object_type)
5279 (new_inferior_event_object_type)
5280 (inferior_deleted_event_object_type): Declare.
5281 (python_new_inferior, python_inferior_deleted): New functions.
5282 (add_thread_object): Emit new_thread event.
5283 (gdbpy_initialize_inferior): Attach new functions to corresponding
5284 observers.
5285 (new_thread, new_inferior, inferior_deleted): Define new event
5286 types.
5287 * python/py-evts.c (gdbpy_initialize_py_events): Add new
5288 registries.
5289 * python/py-events.h (events_object) <new_inferior,
5290 inferior_deleted, new_thread>: New fields.
5291 * python/py-event.h (create_thread_event_breakpoint): Add optional
5292 "thread" parameter.
5293
72542b8e
AB
52942017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
5295
5296 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
5297 check current_ui instead.
5298 (internal_vproblem): Likewise.
5299
0d64823e
SM
53002017-09-09 Simon Marchi <simon.marchi@ericsson.com>
5301
5302 * thread.c (print_thread_info_1): Remove unnecessary calls to
5303 uiout->is_mi_like_p.
5304
eb1e02fd
TT
53052017-09-09 Tom Tromey <tom@tromey.com>
5306
5307 * namespace.h (add_using_directive): Update.
5308 * namespace.c (add_using_directive): Change type of excludes to
5309 std::vector.
5310 * dwarf2read.c (read_import_statement): Use std::vector.
5311 (read_namespace): Update.
5312 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
5313
0fc21fd8
TT
53142017-09-09 Tom Tromey <tom@tromey.com>
5315
5316 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
5317
49663d05
TT
53182017-09-09 Tom Tromey <tom@tromey.com>
5319
5320 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
5321
0b868b60
TT
53222017-09-09 Tom Tromey <tom@tromey.com>
5323
5324 * stack.c (func_command): Use gdb::def_vector.
5325
c0470d48
TT
53262017-09-09 Tom Tromey <tom@tromey.com>
5327
5328 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
5329 ui_out_emit_list, ui_out_emit_tuple.
5330 (mi_cmd_var_update): Likewise.
5331
ca5909c7
TT
53322017-09-09 Tom Tromey <tom@tromey.com>
5333
5334 * mi/mi-interp.c (mi_user_selected_context_changed): Use
5335 ui_out_redirect_pop.
5336 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
5337 ui_out_redirect_pop.
5338 * utils.c (do_ui_out_redirect_pop)
5339 (make_cleanup_ui_out_redirect_pop): Remove.
5340 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
5341 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
5342 * ui-out.h (ui_out_redirect_pop): New class.
5343
e6a2252a
TT
53442017-09-09 Tom Tromey <tom@tromey.com>
5345
5346 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
5347 (list_available_thread_groups, mi_cmd_list_thread_groups)
5348 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
5349 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
5350 Likewise.
5351
393702cd
TT
53522017-09-09 Tom Tromey <tom@tromey.com>
5353
5354 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
5355 ui_out_emit_tuple.
5356
76f9c9cf
TT
53572017-09-09 Tom Tromey <tom@tromey.com>
5358
5359 * target.c (flash_erase_command): Use ui_out_emit_tuple.
5360 * stack.c (print_frame): Use ui_out_emit_tuple.
5361 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
5362 (info_spu_mailbox_command, info_spu_dma_command)
5363 (info_spu_proxydma_command): Likewise.
5364 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
5365 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
5366 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
5367 ui_out_emit_tuple.
5368 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
5369
dc9fe180
TT
53702017-09-09 Tom Tromey <tom@tromey.com>
5371
5372 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
5373 (class ui_out_emit_table): Update comment.
5374 * ui-out.c (do_cleanup_table_end)
5375 (make_cleanup_ui_out_table_begin_end): Remove.
5376 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
5377 (info_spu_dma_cmdlist): Likewise.
5378 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
5379 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
5380 ui_out_emit_table.
5381
f8cc3da6
TT
53822017-09-09 Tom Tromey <tom@tromey.com>
5383
5384 * thread.c (print_thread_info_1): Use ui_out_emit_table,
5385 ui_out_emit_list, gdb::optional.
5386
481695ed
JB
53872017-09-09 John Baldwin <jhb@FreeBSD.org>
5388
5389 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
5390 prototype.
5391 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
5392 prototype.
5393 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
5394 prototype.
5395 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
5396 * ada-exp.y: Remove _initialize_ada_exp prototype.
5397 * ada-lang.c: Remove _initialize_ada_language prototype.
5398 * ada-tasks.c: Remove _initialize_tasks prototype.
5399 * addrmap.c: Remove _initialize_addrmap prototype.
5400 * agent.c: Remove _initialize_agent prototype.
5401 * aix-thread.c: Remove _initialize_aix_thread prototype.
5402 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
5403 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
5404 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
5405 prototype.
5406 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
5407 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
5408 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
5409 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
5410 prototype.
5411 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
5412 prototype.
5413 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
5414 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
5415 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
5416 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
5417 prototype.
5418 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
5419 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
5420 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
5421 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
5422 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
5423 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
5424 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
5425 prototype.
5426 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
5427 prototype.
5428 * annotate.c: Remove _initialize_annotate prototype.
5429 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
5430 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
5431 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
5432 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
5433 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
5434 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
5435 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
5436 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
5437 prototype.
5438 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
5439 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
5440 * auto-load.c: Remove _initialize_auto_load prototype.
5441 * auxv.c: Remove _initialize_auxv prototype.
5442 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
5443 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
5444 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
5445 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
5446 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
5447 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
5448 prototype.
5449 * break-catch-throw.c: Remove _initialize_break_catch_throw
5450 prototype.
5451 * breakpoint.c: Remove _initialize_breakpoint prototype.
5452 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
5453 * btrace.c: Remove _initialize_btrace prototype.
5454 * charset.c: Remove _initialize_charset prototype.
5455 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
5456 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
5457 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
5458 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
5459 * cli/cli-script.c: Remove _initialize_cli_script prototype.
5460 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
5461 * coffread.c: Remove _initialize_coffread prototype.
5462 * compile/compile.c: Remove _initialize_compile prototype.
5463 * complaints.c: Remove _initialize_complaints prototype.
5464 * completer.c: Remove _initialize_completer prototype.
5465 * copying.awk: Remove _initialize_copying prototype.
5466 * copying.c: Regenerate.
5467 * core-regset.c: Remove _initialize_core_regset prototype.
5468 * corefile.c: Remove _initialize_core prototype.
5469 * corelow.c: Remove _initialize_corelow prototype.
5470 * cp-abi.c: Remove _initialize_cp_abi prototype.
5471 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
5472 * cp-support.c: Remove _initialize_cp_support prototype.
5473 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
5474 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
5475 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
5476 * ctf.c: Remove _initialize_ctf prototype.
5477 * d-lang.c: Remove _initialize_d_language prototype.
5478 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
5479 prototype.
5480 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
5481 * dbxread.c: Remove _initialize_dbxread prototype.
5482 * dcache.c: Remove _initialize_dcache prototype.
5483 * demangle.c: Remove _initialize_demangler prototype.
5484 * disasm-selftests.c: Remove _initialize_disasm_selftests
5485 prototype.
5486 * disasm.c: Remove _initialize_disasm prototype.
5487 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
5488 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
5489 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
5490 prototype.
5491 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
5492 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
5493 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
5494 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
5495 * elfread.c: Remove _initialize_elfread prototype.
5496 * exec.c: Remove _initialize_exec prototype.
5497 * extension.c: Remove _initialize_extension prototype.
5498 * f-lang.c: Remove _initialize_f_language prototype.
5499 * f-valprint.c: Remove _initialize_f_valprint prototype.
5500 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
5501 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
5502 * filesystem.c: Remove _initialize_filesystem prototype.
5503 * findcmd.c: Remove _initialize_mem_search prototype.
5504 * fork-child.c: Remove _initialize_fork_child prototype.
5505 * frame-base.c: Remove _initialize_frame_base prototype.
5506 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
5507 * frame.c: Remove _initialize_frame prototype.
5508 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
5509 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
5510 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
5511 * gcore.c: Remove _initialize_gcore prototype.
5512 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
5513 * gdbarch.c: Regenerate.
5514 * gdbarch.sh: Remove _initialize_gdbarch prototype.
5515 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
5516 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
5517 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
5518 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
5519 * go-lang.c: Remove _initialize_go_language prototype.
5520 * go32-nat.c: Remove _initialize_go32_nat prototype.
5521 * guile/guile.c: Remove _initialize_guile prototype.
5522 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
5523 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
5524 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
5525 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
5526 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
5527 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
5528 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
5529 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
5530 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
5531 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
5532 prototype.
5533 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
5534 prototype.
5535 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
5536 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
5537 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
5538 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
5539 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
5540 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
5541 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
5542 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
5543 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
5544 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
5545 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
5546 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
5547 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
5548 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
5549 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
5550 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
5551 prototype.
5552 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
5553 prototype.
5554 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
5555 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
5556 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
5557 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
5558 * infcall.c: Remove _initialize_infcall prototype.
5559 * infcmd.c: Remove _initialize_infcmd prototype.
5560 * inferior.c: Remove _initialize_inferiors prototype.
5561 * inflow.c: Remove _initialize_inflow prototype.
5562 * infrun.c: Remove _initialize_infrun prototype.
5563 * interps.c: Remove _initialize_interpreter prototype.
5564 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
5565 * jit.c: Remove _initialize_jit prototype.
5566 * language.c: Remove _initialize_language prototype.
5567 * linux-fork.c: Remove _initialize_linux_fork prototype.
5568 * linux-nat.c: Remove _initialize_linux_nat prototype.
5569 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
5570 * linux-thread-db.c: Remove _initialize_thread_db prototype.
5571 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
5572 * m2-lang.c: Remove _initialize_m2_language prototype.
5573 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
5574 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
5575 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
5576 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
5577 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
5578 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
5579 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
5580 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
5581 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
5582 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
5583 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
5584 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
5585 * machoread.c: Remove _initialize_machoread prototype.
5586 * macrocmd.c: Remove _initialize_macrocmd prototype.
5587 * macroscope.c: Remove _initialize_macroscope prototype.
5588 * maint.c: Remove _initialize_maint_cmds prototype.
5589 * mdebugread.c: Remove _initialize_mdebugread prototype.
5590 * memattr.c: Remove _initialize_mem prototype.
5591 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
5592 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
5593 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
5594 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
5595 * mi/mi-main.c: Remove _initialize_mi_main prototype.
5596 * microblaze-linux-tdep.c: Remove
5597 _initialize_microblaze_linux_tdep prototype.
5598 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
5599 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
5600 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
5601 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
5602 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
5603 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
5604 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
5605 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
5606 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
5607 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
5608 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
5609 prototype.
5610 * mipsread.c: Remove _initialize_mipsread prototype.
5611 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
5612 prototype.
5613 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
5614 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
5615 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
5616 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
5617 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
5618 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
5619 prototype.
5620 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
5621 * nto-procfs.c: Remove _initialize_procfs prototype.
5622 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
5623 * objc-lang.c: Remove _initialize_objc_language prototype.
5624 * objfiles.c: Remove _initialize_objfiles prototype.
5625 * observer.c: Remove observer_test_first_notification_function,
5626 observer_test_second_notification_function,
5627 observer_test_third_notification_function, and
5628 _initialize_observer prototypes.
5629 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
5630 * osabi.c: Remove _initialize_gdb_osabi prototype.
5631 * osdata.c: Remove _initialize_osdata prototype.
5632 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
5633 * parse.c: Remove _initialize_parse prototype.
5634 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
5635 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
5636 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
5637 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
5638 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
5639 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
5640 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
5641 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
5642 * printcmd.c: Remove _initialize_printcmd prototype.
5643 * probe.c: Remove _initialize_probe prototype.
5644 * proc-api.c: Remove _initialize_proc_api prototype.
5645 * proc-events.c: Remove _initialize_proc_events prototype.
5646 * proc-service.c: Remove _initialize_proc_service prototype.
5647 * procfs.c: Remove _initialize_procfs prototype.
5648 * psymtab.c: Remove _initialize_psymtab prototype.
5649 * python/python.c: Remove _initialize_python prototype.
5650 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
5651 * record-btrace.c: Remove _initialize_record_btrace prototype.
5652 * record-full.c: Remove _initialize_record_full prototype.
5653 * record.c: Remove _initialize_record prototype.
5654 * regcache.c: Remove _initialize_regcache prototype.
5655 * reggroups.c: Remove _initialize_reggroup prototype.
5656 * remote-notif.c: Remove _initialize_notif prototype.
5657 * remote-sim.c: Remove _initialize_remote_sim prototype.
5658 * remote.c: Remove _initialize_remote prototype.
5659 * reverse.c: Remove _initialize_reverse prototype.
5660 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
5661 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
5662 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
5663 prototype.
5664 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
5665 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
5666 * rust-exp.y: Remove _initialize_rust_exp prototype.
5667 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
5668 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
5669 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
5670 * score-tdep.c: Remove _initialize_score_tdep prototype.
5671 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
5672 prototype.
5673 * ser-go32.c: Remove _initialize_ser_dos prototype.
5674 * ser-mingw.c: Remove _initialize_ser_windows prototype.
5675 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
5676 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
5677 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
5678 * serial.c: Remove _initialize_serial prototype.
5679 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
5680 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
5681 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
5682 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
5683 * skip.c: Remove _initialize_step_skip prototype.
5684 * sol-thread.c: Remove _initialize_sol_thread prototype.
5685 * solib-aix.c: Remove _initialize_solib_aix prototype.
5686 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
5687 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
5688 * solib-frv.c: Remove _initialize_frv_solib prototype.
5689 * solib-spu.c: Remove _initialize_spu_solib prototype.
5690 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
5691 * solib-target.c: Remove _initialize_solib_target prototype.
5692 * solib.c: Remove _initialize_solib prototype.
5693 * source.c: Remove _initialize_source prototype.
5694 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
5695 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
5696 prototype.
5697 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
5698 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
5699 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
5700 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
5701 prototype.
5702 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
5703 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
5704 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
5705 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
5706 prototype.
5707 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
5708 prototype.
5709 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
5710 prototype.
5711 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
5712 prototype.
5713 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
5714 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
5715 prototype.
5716 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
5717 prototype.
5718 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
5719 prototype.
5720 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
5721 prototype.
5722 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
5723 prototype.
5724 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
5725 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
5726 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
5727 * stabsread.c: Remove _initialize_stabsread prototype.
5728 * stack.c: Remove _initialize_stack prototype.
5729 * stap-probe.c: Remove _initialize_stap_probe prototype.
5730 * std-regs.c: Remove _initialize_frame_reg prototype.
5731 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
5732 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
5733 * symfile.c: Remove _initialize_symfile prototype.
5734 * symmisc.c: Remove _initialize_symmisc prototype.
5735 * symtab.c: Remove _initialize_symtab prototype.
5736 * target-dcache.c: Remove _initialize_target_dcache prototype.
5737 * target-descriptions.c: Remove _initialize_target_descriptions
5738 prototype.
5739 * thread.c: Remove _initialize_thread prototype.
5740 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
5741 prototype.
5742 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
5743 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
5744 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
5745 prototype.
5746 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
5747 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
5748 * tracefile.c: Remove _initialize_tracefile prototype.
5749 * tracepoint.c: Remove _initialize_tracepoint prototype.
5750 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
5751 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
5752 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
5753 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
5754 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
5755 * tui/tui-win.c: Remove _initialize_tui_win prototype.
5756 * tui/tui.c: Remove _initialize_tui prototype.
5757 * typeprint.c: Remove _initialize_typeprint prototype.
5758 * user-regs.c: Remove _initialize_user_regs prototype.
5759 * utils.c: Remove _initialize_utils prototype.
5760 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
5761 * valarith.c: Remove _initialize_valarith prototype.
5762 * valops.c: Remove _initialize_valops prototype.
5763 * valprint.c: Remove _initialize_valprint prototype.
5764 * value.c: Remove _initialize_values prototype.
5765 * varobj.c: Remove _initialize_varobj prototype.
5766 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
5767 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
5768 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
5769 * windows-nat.c: Remove _initialize_windows_nat,
5770 _initialize_check_for_gdb_ini, and _initialize_loadable
5771 prototypes.
5772 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
5773 * xcoffread.c: Remove _initialize_xcoffread prototype.
5774 * xml-support.c: Remove _initialize_xml_support prototype.
5775 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
5776 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
5777 prototype.
5778 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
5779 prototype.
5780 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
5781
a611b5cb
KS
57822017-09-08 Keith Seitz <keiths@redhat.com>
5783
5784 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
5785 field.
5786
469412dd
CW
57872017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
5788
5789 * f-valprint.c (f_val_print): Remove check for one byte
5790 sized integers. Remove printing of character type.
5791
a5ad232b
FP
57922017-09-08 Frank Penczek <frank.penczek@intel.com>
5793 Christoph Weinmann <christoph.t.weinmann@intel.com>
5794 Bernhard Heckel <bernhard.heckel@intel.com>
5795
5796 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
5797 to maintain proper indentation when printing pointers/refs.
5798
e5014227
JB
57992017-09-07 Joel Brobecker <brobecker@adacore.com>
5800
5801 GDB 8.0.1 released.
5802
63c99141
JB
58032017-09-07 Joel Brobecker <brobecker@adacore.com>
5804
5805 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
5806
69c1e056
TT
58072017-09-05 Tom Tromey <tom@tromey.com>
5808
5809 * parse.c (funcall_chain): Now a std::vector.
5810 (start_arglist, end_arglist): Simplify.
5811 (free_funcalls): Remove.
5812 (parse_exp_in_context_1): Remove cleanup.
5813
fef704bf
TT
58142017-09-05 Tom Tromey <tom@tromey.com>
5815
5816 * go-exp.y (go_parse): Don't create a cleanup.
5817
5613c585
TT
58182017-09-05 Tom Tromey <tom@tromey.com>
5819
5820 * d-exp.y (PrimaryExpression): Use std::string.
5821 (d_parse): Don't create a cleanup.
5822
eae49211
TT
58232017-09-05 Tom Tromey <tom@tromey.com>
5824
5825 * utils.c (do_clear_parser_state): Remove.
5826 (make_cleanup_clear_parser_state): Remove.
5827 * p-exp.y (pascal_parse): Use scoped_restore.
5828 * m2-exp.y (m2_parse): Use scoped_restore.
5829 * f-exp.y (f_parse): Use scoped_restore.
5830 * d-exp.y (d_parse): Use scoped_restore.
5831 * c-exp.y (c_parse): Use scoped_restore.
5832 * ada-exp.y (ada_parse): Use scoped_restore.
5833 * utils.h (make_cleanup_clear_parser_state): Remove.
5834
73b9be8b
KS
58352017-09-06 Keith Seitz <keiths@redhat.com>
5836
5837 * dwarf2read.c (dw2_linkage_name_attr): New function.
5838 (dw2_linkage_name): New function.
5839 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
5840 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
5841 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
5842
a102602b
KR
58432017-09-06 Kamil Rytarowski <n54@gmx.com>
5844
5845 * config/djgpp/djconfig.sh: Correct shell portability issue.
5846
28ad437d
KR
58472017-09-06 Kamil Rytarowski <n54@gmx.com>
5848
5849 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
5850
351787dd
JB
58512017-09-06 John Baldwin <jhb@FreeBSD.org>
5852
5853 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
5854 * NEWS: Mention new FreeBSD/mips native configuration.
5855 * configure.host: Add aarch64*-*-freebsd*.
5856 * configure.nat: Likewise.
5857 * aarch64-fbsd-nat.c: New file.
5858
c0f84956
JB
58592017-09-06 John Baldwin <jhb@FreeBSD.org>
5860
5861 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
5862 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
5863 * NEWS: Mention new FreeBSD/aarch64 target.
5864 * configure.tgt: Add aarch64*-*-freebsd*.
5865 * aarch64-fbsd-tdep.c: New file.
5866 * aarch64-fbsd-tdep.h: New file.
5867
7610297a
KR
58682017-09-06 Kamil Rytarowski <n54@gmx.com>
5869
5870 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
5871
fbd1b771
JK
58722017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
5873
5874 * parse.c (find_minsym_type_and_address): Don't relocate addresses
5875 of TLS symbols.
5876
5ca79eae
PW
58772017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5878
5879 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
5880 call.
5881
bf93d7ba
SM
58822017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5883
5884 * infrun.c (follow_exec): Call add_thread after
5885 target_find_description.
5886
1bb7c059
SM
58872017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5888
5889 * infrun.c (handle_inferior_event_1): When exec'ing, read
5890 stop_pc after follow_exec.
5891
fc809827
SM
58922017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5893
5894 * remote.c (process_g_packet): Update error message.
5895
d2fcdd85
YQ
58962017-09-05 Yao Qi <yao.qi@linaro.org>
5897
5898 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
5899 targets.
5900
e69570ee
PA
59012017-09-05 Pedro Alves <palves@redhat.com>
5902
5903 * eval.c (eval_call, evaluate_funcall): New functions, factored
5904 out from ...
5905 (evaluate_subexp_standard): ... this.
5906
22916b07
YQ
59072017-09-05 Yao Qi <yao.qi@linaro.org>
5908
5909 * amd64-tdep.c (amd64_target_description): Create target
5910 descriptions.
5911 (_initialize_amd64_tdep): Don't call functions
5912 initialize_tdesc_amd64_*. Add self tests.
5913 * arch/amd64.c (amd64_create_target_description): Add parameter
5914 is_linux. Call set_tdesc_osabi if is_linux is true.
5915 * arch/amd64.h (amd64_create_target_description): Update the
5916 declaration.
5917 * arch/i386.c (i386_create_target_description): Add parameter
5918 is_linux. Call set_tdesc_osabi if is_linux is true.
5919 * arch/i386.h (i386_create_target_description): Update
5920 declaration.
5921 * configure.tgt: Add i386.o to gdb_target_obs.
5922 * features/Makefile (XMLTOC): Remove i386/*.xml.
5923 * features/i386/amd64-avx-avx512.c: Remove.
5924 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
5925 * features/i386/amd64-avx-mpx.c: Remove.
5926 * features/i386/amd64-avx.c: Remove.
5927 * features/i386/amd64-mpx.c: Remove.
5928 * features/i386/amd64.c: Remove.
5929 * features/i386/i386-avx-avx512.c: Remove.
5930 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
5931 * features/i386/i386-avx-mpx.c: Remove.
5932 * features/i386/i386-avx.c: Remove.
5933 * features/i386/i386-mmx.c: Remove.
5934 * features/i386/i386-mpx.c: Remove.
5935 * features/i386/i386.c: Remove.
5936 * i386-tdep.c: Don't include features/i386/i386*.c., include
5937 target-descriptions.h and arch/i386.h.
5938 (i386_target_description): Create target descriptions.
5939 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
5940 functions. Do self tests.
5941
0854b7b1
YQ
59422017-09-05 Yao Qi <yao.qi@linaro.org>
5943
5944 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
5945 * features/i386/amd64-avx-avx512-linux.c: Removed.
5946 * features/i386/amd64-avx-linux.c: Removed.
5947 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
5948 * features/i386/amd64-avx-mpx-linux.c: Removed.
5949 * features/i386/amd64-linux.c: Removed.
5950 * features/i386/amd64-mpx-linux.c: Removed.
5951 * features/i386/x32-avx-avx512-linux.c: Removed.
5952 * features/i386/x32-avx-linux.c: Removed.
5953 * features/i386/x32-linux.c: Removed.
5954
b4570e4b
YQ
59552017-09-05 Yao Qi <yao.qi@linaro.org>
5956
5957 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
5958 features/i386/*.c.
5959 (amd64_linux_read_description): Call
5960 amd64_create_target_description.
5961 * arch/amd64.c: New file.
5962 * arch/amd64.h: New file.
5963 * configure.tgt (x86_64-*-linux*): Append amd64.o.
5964 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
5965
6c73f67f
YQ
59662017-09-05 Yao Qi <yao.qi@linaro.org>
5967
5968 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
5969 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
5970 (amd64_linux_read_description): Create target descriptions.
5971 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
5972 functions. Add unit tests.
5973 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
5974 x32-core.xml.
5975 * features/i386/64bit-avx.c: Generated.
5976 * features/i386/64bit-avx512.c: Generated.
5977 * features/i386/64bit-core.c: Generated.
5978 * features/i386/64bit-linux.c: Generated.
5979 * features/i386/64bit-mpx.c: Generated.
5980 * features/i386/64bit-pkeys.c: Generated.
5981 * features/i386/64bit-segments.c: Generated.
5982 * features/i386/64bit-sse.c: Generated.
5983 * features/i386/x32-core.c: Generated.
5984 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
5985 c files for amd64-linux and x32-linux.
5986
9d3d478b
YQ
59872017-09-05 Yao Qi <yao.qi@linaro.org>
5988
5989 * amd64-linux-tdep.c (amd64_linux_read_description): New
5990 function.
5991 (amd64_linux_core_read_description): Call
5992 amd64_linux_read_description.
5993 (amd64_linux_init_abi): Likewise.
5994 (amd64_x32_linux_init_abi): Likewise.
5995 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
5996 * x86-linux-nat.c (x86_linux_read_description): Call
5997 amd64_linux_read_description.
5998
b9f1d50f
YQ
59992017-09-05 Yao Qi <yao.qi@linaro.org>
6000
6001 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
6002 comments.
6003
188c9e6d
YQ
60042017-09-05 Yao Qi <yao.qi@linaro.org>
6005
6006 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
6007 * features/i386/i386-avx-avx512-linux.c: Remove.
6008 * features/i386/i386-avx-linux.c: Remove.
6009 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
6010 * features/i386/i386-avx-mpx-linux.c: Remove.
6011 * features/i386/i386-linux.c: Remove.
6012 * features/i386/i386-mmx-linux.c: Remove.
6013 * features/i386/i386-mpx-linux.c: Remove.
6014
5f035c07
YQ
60152017-09-05 Yao Qi <yao.qi@linaro.org>
6016
6017 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
6018 (SFILES): Add arch/i386.c.
6019 (HFILES_NO_SRCDIR): Add arch/i386.h.
6020 * arch/i386.c: New file.
6021 * arch/i386.h: New file.
6022 * arch/tdesc.h (allocate_target_description): Declare.
6023 (set_tdesc_architecture): Declare.
6024 (set_tdesc_osabi): Declare.
6025 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
6026 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
6027 include arch/i386.h.
6028 (i386_linux_read_description): Remove code and call
6029 i386_create_target_description.
6030 (set_tdesc_architecture): New function.
6031 (set_tdesc_osabi): New function.
6032 * target-descriptions.h (allocate_target_description): Remove.
6033
0abe8a89
YQ
60342017-09-05 Yao Qi <yao.qi@linaro.org>
6035
6036 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
6037 * target-descriptions.c (tdesc_create_feature): Likewise, and
6038 adjust code.
6039 * features/i386/32bit-avx.c: Re-generated.
6040 * features/i386/32bit-avx512.c: Re-generated.
6041 * features/i386/32bit-core.c: Re-generated.
6042 * features/i386/32bit-linux.c: Re-generated.
6043 * features/i386/32bit-mpx.c: Re-generated.
6044 * features/i386/32bit-pkeys.c: Re-generated.
6045 * features/i386/32bit-sse.c: Re-generated.
6046
0a188386
YQ
60472017-09-05 Yao Qi <yao.qi@linaro.org>
6048
6049 * regformats/regdef.h (struct reg): Override operator == and !=.
6050
f49ff000
YQ
60512017-09-05 Yao Qi <yao.qi@linaro.org>
6052
6053 * arch/tdesc.h: New file.
6054 * regformats/regdat.sh: Generate code using tdesc_create_reg.
6055 * target-descriptions.c: Update comments.
6056 * target-descriptions.h: Include "arch/tdesc.h". Remove the
6057 declarations.
6058 * features/i386/32bit-avx.c: Re-generated.
6059 * features/i386/32bit-avx512.c: Re-generated.
6060 * features/i386/32bit-core.c: Re-generated.
6061 * features/i386/32bit-linux.c: Re-generated.
6062 * features/i386/32bit-mpx.c: Re-generated.
6063 * features/i386/32bit-pkeys.c: Re-generated.
6064 * features/i386/32bit-sse.c: Re-generated.
6065
f7000548
YQ
60662017-09-05 Yao Qi <yao.qi@linaro.org>
6067
6068 * regformats/regdat.sh: Update generated code.
6069
c9a5e2a5
YQ
60702017-09-05 Yao Qi <yao.qi@linaro.org>
6071
6072 * regformats/regdat.sh: Adjust code order.
6073
d6b687ac
SM
60742017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6075
6076 * expprint.c (dump_subexp_body_standard): Use constant format
6077 string in fprintf_filtered call.
6078
a379bfd0
JB
60792017-09-04 John Baldwin <jhb@FreeBSD.org>
6080
6081 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
6082 NetBSD/i386.
6083 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
6084
f7efc967
JB
60852017-09-04 John Baldwin <jhb@FreeBSD.org>
6086
6087 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
6088
c49fbc6c
JB
60892017-09-04 John Baldwin <jhb@FreeBSD.org>
6090
6091 * bsd-kvm.o: Define _KMEMUSER.
6092 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
6093 * configure: Regenerate.
6094
26562e73
JB
60952017-09-04 John Baldwin <jhb@FreeBSD.org>
6096
6097 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
6098 * i386-fbsd-nat.c: Likewise.
6099
31cf1487
JB
61002017-09-04 John Baldwin <jhb@FreeBSD.org>
6101
6102 * unittests/array-view-selftests.c: Add include of <array>.
6103
5b9f8a7c
JB
61042017-09-04 John Baldwin <jhb@FreeBSD.org>
6105
6106 * spu-tdep.c (flush_ea_cache): Add missing argument to
6107 call_function_by_hand.
6108
d69cf9b2
PA
61092017-09-04 Pedro Alves <palves@redhat.com>
6110
6111 * NEWS (Safer support for debugging with no debug info): New.
6112
3693fdb3
PA
61132017-09-04 Pedro Alves <palves@redhat.com>
6114
6115 * c-exp.y (function_method, function_method_void): Add current
6116 instance flags to TYPE_INSTANCE.
6117 * dwarf2read.c (check_modifier): New.
6118 (compute_delayed_physnames): Assert that only C++ adds delayed
6119 physnames. Mark fn_fields as const/volatile depending on
6120 physname.
6121 * eval.c (make_params): New type_instance_flags parameter. Use
6122 it as the new type's instance flags.
6123 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
6124 flags element and pass it to make_params.
6125 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
6126 instance flags element.
6127 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
6128 * gdbtypes.h: Include "enum-flags.h".
6129 (type_instance_flags): New enum-flags type.
6130 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
6131 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
6132 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
6133 (follow_type_instance_flags): New function.
6134 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
6135 * parser-defs.h (follow_type_instance_flags): Declare.
6136 * valops.c (value_struct_elt_for_reference): const/volatile must
6137 match too.
6138
e68cb8e0
PA
61392017-09-04 Pedro Alves <palves@redhat.com>
6140
6141 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
6142 function/method scopes; lookup the nested name as a function local
6143 static variable.
6144
858be34c
PA
61452017-09-04 Pedro Alves <palves@redhat.com>
6146
6147 (%type <voidval>): Add function_method.
6148 * c-exp.y (exp): New production for calls with no arguments.
6149 (function_method, function_method_void_or_typelist): New
6150 productions.
6151 (exp): New production for "method()::static_var".
6152 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
6153 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6154 Handle OP_FUNC_STATIC_VAR.
6155 * parse.c (operator_length_standard):
6156 Handle OP_FUNC_STATIC_VAR.
6157
dd5901a6
PA
61582017-09-04 Pedro Alves <palves@redhat.com>
6159
6160 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
6161 handling.
6162 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6163 Ditto.
6164 * parse.c (operator_length_standard, operator_check_standard):
6165 Ditto.
6166 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
6167
46a4882b
PA
61682017-09-04 Pedro Alves <palves@redhat.com>
6169
6170 * ax-gdb.c: Include "typeprint.h".
6171 (gen_expr_for_cast): New function.
6172 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
6173 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
6174 type is unknown.
6175 * dwarf2read.c (new_symbol_full): Fallback to int instead of
6176 nodebug_data_symbol.
6177 * eval.c: Include "typeprint.h".
6178 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
6179 Error out if symbol has unknown type.
6180 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
6181 evaluate_subexp_for_cast.
6182 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
6183 OP_VAR_MSYM_VALUE.
6184 (evaluate_subexp_for_cast): New function.
6185 * gdbtypes.c (init_nodebug_var_type): New function.
6186 (objfile_type): Use it to initialize types of variables with no
6187 debug info.
6188 * typeprint.c (error_unknown_type): New.
6189 * typeprint.h (error_unknown_type): New declaration.
6190 * compile/compile-c-types.c (convert_type_basic): Handle
6191 TYPE_CODE_ERROR; warn and fallback to int for variables with
6192 unknown type.
6193
fe13dfec
PA
61942017-09-04 Pedro Alves <palves@redhat.com>
6195
6196 * eval.c (evaluate_var_value): New function, factored out from ...
6197 (evaluate_subexp_standard): ... here.
6198
d008ee21
PA
61992017-09-04 Pedro Alves <palves@redhat.com>
6200
6201 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
6202 Remove useless assignments to 'op'.
6203
827d0c51
PA
62042017-09-04 Pedro Alves <palves@redhat.com>
6205
6206 * eval.c (eval_skip_value): New function.
6207 (evaluate_subexp_standard): Use it.
6208
2c5a2be1
PA
62092017-09-04 Pedro Alves <palves@redhat.com>
6210
6211 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
6212 function name from symbol/minsym and pass it to
6213 error_call_unknown_return_type.
6214
74ea4be4
PA
62152017-09-04 Pedro Alves <palves@redhat.com>
6216
6217 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
6218 * ax-gdb.c (gen_msym_var_ref): New function.
6219 (gen_expr): Handle OP_VAR_MSYM_VALUE.
6220 * eval.c (evaluate_var_msym_value): New function.
6221 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
6222 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
6223 to call_function_by_hand.
6224 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6225 Handle OP_VAR_MSYM_VALUE.
6226 (union exp_element) <msymbol>: New field.
6227 * minsyms.h (struct type): Forward declare.
6228 (find_minsym_type_and_address): Declare.
6229 * parse.c (write_exp_elt_msym): New function.
6230 (write_exp_msymbol): Delete, refactored as ...
6231 (find_minsym_type_and_address): ... this new function.
6232 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
6233 (operator_length_standard, operator_check_standard): Handle
6234 OP_VAR_MSYM_VALUE.
6235 * std-operator.def (OP_VAR_MSYM_VALUE): New.
6236
7022349d
PA
62372017-09-04 Pedro Alves <palves@redhat.com>
6238
6239 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
6240 TYPE_GNU_IFUNC specially here. Throw error if return type is
6241 unknown.
6242 * ada-typeprint.c (print_func_type): Handle functions with unknown
6243 return type.
6244 * c-typeprint.c (c_type_print_base): Handle functions and methods
6245 with unknown return type.
6246 * compile/compile-c-symbols.c (convert_symbol_bmsym)
6247 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
6248 * compile/compile-c-types.c: Include "objfiles.h".
6249 (convert_func): For functions with unknown return type, warn and
6250 default to int.
6251 * compile/compile-object-run.c (compile_object_run): Adjust call
6252 to call_function_by_hand_dummy.
6253 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
6254 call_function_by_hand.
6255 * eval.c (evaluate_subexp_standard): Adjust calls to
6256 call_function_by_hand. Handle functions and methods with unknown
6257 return type. Pass expect_type to call_function_by_hand.
6258 * f-typeprint.c (f_type_print_base): Handle functions with unknown
6259 return type.
6260 * gcore.c (call_target_sbrk): Adjust call to
6261 call_function_by_hand.
6262 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
6263 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
6264 an integer address type instead of nodebug.
6265 * guile/scm-value.c (gdbscm_value_call): Adjust call to
6266 call_function_by_hand.
6267 * infcall.c (error_call_unknown_return_type): New function.
6268 (call_function_by_hand): New "default_return_type" parameter.
6269 Pass it down.
6270 (call_function_by_hand_dummy): New "default_return_type"
6271 parameter. Use it instead of defaulting to int. If there's no
6272 default and the return type is unknown, throw an error. If
6273 there's a default return type, and the called function has no
6274 debug info, then assume the function is prototyped.
6275 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
6276 New "default_return_type" parameter.
6277 (error_call_unknown_return_type): New declaration.
6278 * linux-fork.c (call_lseek): Cast return type of lseek.
6279 (inferior_call_waitpid, checkpoint_command): Adjust calls to
6280 call_function_by_hand.
6281 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
6282 calls to call_function_by_hand.
6283 * m2-typeprint.c (m2_procedure): Handle functions with unknown
6284 return type.
6285 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6286 (value_nsstring, print_object_command): Adjust calls to
6287 call_function_by_hand.
6288 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
6289 functions with unknown return type.
6290 (pascal_type_print_func_varspec_suffix): New function.
6291 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
6292 TYPE_CODE_METHOD>: Use it.
6293 * python/py-value.c (valpy_call): Adjust call to
6294 call_function_by_hand.
6295 * rust-lang.c (rust_evaluate_funcall): Adjust call to
6296 call_function_by_hand.
6297 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
6298 call_function_by_hand.
6299 * valops.c (value_allocate_space_in_inferior): Adjust call to
6300 call_function_by_hand.
6301 * typeprint.c (type_print_unknown_return_type): New function.
6302 * typeprint.h (type_print_unknown_return_type): New declaration.
6303
54990598
PA
63042017-09-04 Pedro Alves <palves@redhat.com>
6305
6306 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
6307 types with more than one parameter as prototyped.
6308
9a24775b
PA
63092017-09-04 Pedro Alves <palves@redhat.com>
6310
6311 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
6312 (disassemble_command): Use gdb_disassembly_flags instead of bare
6313 int.
6314 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
6315 (dump_insns, do_mixed_source_and_assembly_deprecated)
6316 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
6317 Use gdb_disassembly_flags instead of bare int.
6318 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
6319 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
6320 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
6321 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
6322 (enum gdb_disassembly_flag): ... values of this new enumeration.
6323 (gdb_disassembly_flags): Define.
6324 (gdb_disassembly)
6325 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
6326 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
6327 gdb_disassembly_flags instead of bare int.
6328 * record-btrace.c (btrace_insn_history)
6329 (record_btrace_insn_history, record_btrace_insn_history_range)
6330 (record_btrace_insn_history_from): Use gdb_disassembly_flags
6331 instead of bare int.
6332 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
6333 Use gdb_disassembly_flags instead of bare int.
6334 * target-debug.h (target_debug_print_gdb_disassembly_flags):
6335 Define.
6336 * target-delegates.c: Regenerate.
6337 * target.c (target_insn_history, target_insn_history_from)
6338 (target_insn_history_range): Use gdb_disassembly_flags instead of
6339 bare int.
6340 * target.h: Include "disasm.h".
6341 (struct target_ops) <to_insn_history, to_insn_history_from,
6342 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
6343 int.
6344 (target_insn_history, target_insn_history_from)
6345 (target_insn_history_range): Use gdb_disassembly_flags instead of
6346 bare int.
6347
80a65e9b
SM
63482017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6349
6350 * cli/cli-script.c (build_command_line): For if/while commands,
6351 check whether args is empty.
6352
6b66338c
SM
63532017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6354
6355 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
6356 (enum command_control_type): Likewise.
6357 (struct command_line): Likewise.
6358 (free_command_lines): Likewise.
6359 (struct command_lines_deleter): Likewise.
6360 (command_line_up): Likewise.
6361 (read_command_lines): Likewise.
6362 (read_command_lines_1): Likewise.
6363 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
6364 (enum command_control_type): Likewise.
6365 (struct command_line): Likewise.
6366 (free_command_lines): Likewise.
6367 (struct command_lines_deleter): Likewise.
6368 (command_line_up): Likewise.
6369 (read_command_lines): Likewise.
6370 (read_command_lines_1): Likewise.
6371 * breakpoint.h: Include cli/cli-script.h.
6372 * extension-priv.h: Likewise.
6373 * gdbcmd.h: Likewise.
6374
51abb421
PA
63752017-09-04 Pedro Alves <palves@redhat.com>
6376
6377 * ada-lang.c (is_known_support_routine): Move sal declaration to
6378 where it is initialized.
6379 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
6380 (parse_breakpoint_sals, decode_static_tracepoint_spec)
6381 (clear_command, update_static_tracepoint): Remove init_sal
6382 references. Move declarations closer to initializations.
6383 * cli/cli-cmds.c (list_command): Move sal declarations closer to
6384 initializations.
6385 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
6386 references. Move sal declarations closer to initializations.
6387 * frame.c (find_frame_sal): Return a symtab_and_line via function
6388 return instead of output parameter. Remove init_sal references.
6389 * frame.h (find_frame_sal): Return a symtab_and_line via function
6390 return instead of output parameter.
6391 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
6392 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
6393 instead of memset.
6394 (gdbscm_find_pc_line): Remove init_sal reference.
6395 * infcall.c (call_function_by_hand_dummy): Remove init_sal
6396 references. Move declarations closer to initializations.
6397 * infcmd.c (set_step_frame): Update. Move declarations closer to
6398 initializations.
6399 (finish_backward): Remove init_sal references. Move declarations
6400 closer to initializations.
6401 * infrun.c (process_event_stop_test, handle_step_into_function)
6402 (insert_hp_step_resume_breakpoint_at_frame)
6403 (insert_step_resume_breakpoint_at_caller): Likewise.
6404 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
6405 (symbol_to_sal): Likewise.
6406 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
6407 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
6408 to its initialization.
6409 * reverse.c (save_bookmark_command): Use new/delete. Remove
6410 init_sal references. Move declarations closer to initializations.
6411 * source.c (get_current_source_symtab_and_line): Remove brace
6412 initialization.
6413 (set_current_source_symtab_and_line): Now takes the sal by const
6414 reference. Remove brace initialization.
6415 (line_info): Remove init_sal reference.
6416 * source.h (set_current_source_symtab_and_line): Now takes a
6417 symtab_and_line via const reference.
6418 * stack.c (set_current_sal_from_frame): Adjust.
6419 (print_frame_info): Adjust.
6420 (get_last_displayed_sal): Return the sal via function return
6421 instead of via output parameter. Simplify.
6422 (frame_info): Adjust.
6423 * stack.h (get_last_displayed_sal): Return the sal via function
6424 return instead of via output parameter.
6425 * symtab.c (init_sal): Delete.
6426 (find_pc_sect_line): Remove init_sal references. Move
6427 declarations closer to initializations.
6428 (find_function_start_sal): Remove init_sal references. Move
6429 declarations closer to initializations.
6430 * symtab.h (struct symtab_and_line): In-class initialize all
6431 fields.
6432 * tracepoint.c (set_traceframe_context)
6433 (print_one_static_tracepoint_marker): Remove init_sal references.
6434 Move declarations closer to initializations.
6435 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
6436 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
6437 declarations closer to initializations.
6438 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
6439 init_sal references. Adjust.
6440
6c5b2ebe
PA
64412017-09-04 Pedro Alves <palves@redhat.com>
6442
6443 * ax-gdb.c (agent_command_1): Use range-for.
6444 * break-catch-throw.c (re_set_exception_catchpoint): Update.
6445 * breakpoint.c: Include "common/array-view.h".
6446 (init_breakpoint_sal, create_breakpoint_sal): Change sals
6447 parameter from struct symtabs_and_lines to
6448 array_view<symtab_and_line>. Adjust. Use range-for. Update.
6449 (breakpoint_sals_to_pc): Change sals parameter from struct
6450 symtabs_and_lines to std::vector reference.
6451 (check_fast_tracepoint_sals): Change sals parameter from struct
6452 symtabs_and_lines to std::array_view. Use range-for.
6453 (decode_static_tracepoint_spec): Return a std::vector instead of
6454 symtabs_and_lines. Update.
6455 (create_breakpoint): Update.
6456 (break_range_command, until_break_command, clear_command): Update.
6457 (base_breakpoint_decode_location, bkpt_decode_location)
6458 (bkpt_probe_create_sals_from_location)
6459 (bkpt_probe_decode_location, tracepoint_decode_location)
6460 (tracepoint_probe_decode_location)
6461 (strace_marker_create_sals_from_location): Return a std::vector
6462 instead of symtabs_and_lines.
6463 (strace_marker_create_breakpoints_sal): Update.
6464 (strace_marker_decode_location): Return a std::vector instead of
6465 symtabs_and_lines. Update.
6466 (update_breakpoint_locations): Change struct symtabs_and_lines
6467 parameters to gdb::array_view. Adjust.
6468 (location_to_sals): Return a std::vector instead of
6469 symtabs_and_lines. Update.
6470 (breakpoint_re_set_default): Use std::vector instead of struct
6471 symtabs_and_lines.
6472 (decode_location_default): Return a std::vector instead of
6473 symtabs_and_lines. Update.
6474 * breakpoint.h: Include "common/array-view.h".
6475 (struct breakpoint_ops) <decode_location>: Now returns a
6476 std::vector instead of returning a symtabs_and_lines via output
6477 parameter.
6478 (update_breakpoint_locations): Change sals parameters to use
6479 gdb::array_view.
6480 * cli/cli-cmds.c (edit_command, list_command): Update to use
6481 std::vector and gdb::array_view.
6482 (ambiguous_line_spec): Adjust to use gdb::array_view and
6483 range-for.
6484 (compare_symtabs): Rename to ...
6485 (cmp_symtabs): ... this. Change parameters to symtab_and_line
6486 const reference and adjust.
6487 (filter_sals): Rewrite using std::vector and standard algorithms.
6488 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
6489 (jump_command): Update to use std::vector.
6490 * linespec.c (struct linespec_state) <canonical_names>: Update
6491 comment.
6492 (add_sal_to_sals_basic): Delete.
6493 (add_sal_to_sals, filter_results, convert_results_to_lsals)
6494 (decode_line_2, create_sals_line_offset)
6495 (convert_address_location_to_sals, convert_linespec_to_sals)
6496 (convert_explicit_location_to_sals, parse_linespec)
6497 (event_location_to_sals, decode_line_full, decode_line_1)
6498 (decode_line_with_current_source)
6499 (decode_line_with_last_displayed, decode_objc)
6500 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
6501 (linespec_result::~linespec_result): Adjust to use std::vector
6502 instead of symtabs_and_lines.
6503 * linespec.h (linespec_sals::sals): Now a std::vector.
6504 (struct linespec_result): Use std::vector, bool, and in-class
6505 initialization.
6506 (decode_line_1, decode_line_with_current_source)
6507 (decode_line_with_last_displayed): Return std::vector.
6508 * macrocmd.c (info_macros_command): Use std::vector.
6509 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
6510 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
6511 std::vector.
6512 * probe.h (parse_probes): Return a std::vector.
6513 * python/python.c (gdbpy_decode_line): Use std::vector and
6514 gdb::array_view.
6515 * source.c (select_source_symtab, line_info): Use std::vector.
6516 * stack.c (func_command): Use std::vector.
6517 * symtab.h (struct symtabs_and_lines): Delete.
6518 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
6519
7c44b49c
PA
65202017-09-04 Pedro Alves <palves@redhat.com>
6521
6522 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6523 unittests/array-view-selftests.c.
6524 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
6525 * common/array-view.h: New file.
6526 * unittests/array-view-selftests.c: New file.
6527
e439fa14
PA
65282017-09-04 Pedro Alves <palves@redhat.com>
6529
6530 * cli/cli-cmds.c (edit_command): Pass message to
6531 ambiguous_line_spec.
6532 (list_command): Pass message to ambiguous_line_spec. Say
6533 "first"/"last" instead of "start" and "end" to be consistent with
6534 the manual.
6535 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
6536 them to print formatted message.
6537
7525b645
PA
65382017-09-04 Pedro Alves <palves@redhat.com>
6539
6540 * btrace.c (ftrace_add_pt): Pass btrace_insn to
6541 ftrace_update_insns by reference instead of pointer.
6542
badc0020
YQ
65432017-09-04 Yao Qi <yao.qi@linaro.org>
6544
6545 * i386-go32-tdep.c: Include x86-xstate.h.
6546 (i386_go32_init_abi): Call i386_target_description.
6547 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
6548 if xcr0 is X86_XSTATE_X87_MASK.
6549 * i386-tdep.h (tdesc_i386): Remove the declaration.
6550 (tdesc_i386_mmx): Likewise.
6551
d78bdb54
YQ
65522017-09-04 Yao Qi <yao.qi@linaro.org>
6553
6554 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
6555 X86_XSTATE_SSE_MASK instead of 0.
6556
ca1fa5ee
YQ
65572017-09-04 Yao Qi <yao.qi@linaro.org>
6558
6559 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
6560 i386_target_description.
6561 * i386-fbsd-nat.c (i386fbsd_read_description): Call
6562 i386_target_description.
6563 * i386-tdep.c (i386_gdbarch_init): Likewise.
6564
2434b019
YQ
65652017-09-04 Yao Qi <yao.qi@linaro.org>
6566
6567 * amd64-darwin-tdep.c: Include "x86-xstate.h".
6568 (x86_darwin_init_abi_64): Call amd64_target_description.
6569 * amd64-dicos-tdep.c: Likewise.
6570 * amd64-fbsd-nat.c: Likewise.
6571 * amd64-fbsd-tdep.c: Likewise.
6572 * amd64-nbsd-tdep.c: Likewise.
6573 * amd64-obsd-tdep.c: Likewise.
6574 * amd64-sol2-tdep.c: Likewise.
6575 * amd64-windows-tdep.c: Likewise.
6576 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
6577
0860c437
SM
65782017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6579
6580 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
6581 (btrace_function) <insn>: Change type to use std::vector.
6582 * btrace.c (ftrace_debug, ftrace_call_num_insn,
6583 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
6584 ftrace_update_insns, ftrace_compute_global_level_offset,
6585 btrace_stitch_bts, btrace_clear, btrace_insn_get,
6586 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
6587 change to std::vector.
6588 (ftrace_update_insns): Adjust to change to std::vector, change
6589 type of INSN parameter.
6590 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
6591 * record-btrace.c (btrace_call_history_insn_range,
6592 btrace_compute_src_line_range,
6593 record_btrace_frame_prev_register): Adjust to change to
6594 std::vector.
6595 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
6596 to change to std::vector.
6597
0638b7f9
TT
65982017-09-03 Tom Tromey <tom@tromey.com>
6599
6600 * corefile.c (reopen_exec_file): Use std::string.
6601
8f84fb0e
TT
66022017-09-03 Tom Tromey <tom@tromey.com>
6603
6604 * compile/compile.c (compile_register_name_mangled): Return
6605 std::string.
6606 * compile/compile-loc2c.c (pushf_register_address): Update.
6607 (pushf_register): Update.
6608 * compile/compile-c-types.c (convert_array): Update.
6609 * compile/compile-c-symbols.c (generate_vla_size): Update.
6610 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
6611 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
6612 (convert_one_symbol): Update.
6613 (generate_c_for_for_one_variable): Update.
6614 * compile/compile-c-support.c (c_get_range_decl_name): Return a
6615 std::string.
6616 (generate_register_struct): Update.
6617 * compile/compile-internal.h (c_get_range_decl_name): Return a
6618 std::string.
6619 (compile_register_name_mangled): Return std::string.
6620
18e9961f
TT
66212017-09-03 Tom Tromey <tom@tromey.com>
6622
6623 * utils.c (perror_string): Return a std::string.
6624 (throw_perror_with_name, perror_warning_with_name): Update.
6625
45343786
TT
66262017-09-03 Tom Tromey <tom@tromey.com>
6627
6628 * demangle.c (demangle_command): Use std::string,
6629 unique_xmalloc_ptr.
6630
b57af503
TT
66312017-09-03 Tom Tromey <tom@tromey.com>
6632
6633 * cli/cli-setshow.c (do_set_command): Use std::string.
6634
6eecf35f
TT
66352017-09-03 Tom Tromey <tom@tromey.com>
6636
6637 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
6638
56496dd4
TT
66392017-09-03 Tom Tromey <tom@tromey.com>
6640
6641 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
6642
e91a1fa7
TT
66432017-09-03 Tom Tromey <tom@tromey.com>
6644
6645 * mi/mi-cmd-env.c (env_execute_cli_command): Use
6646 gdb::unique_xmalloc_ptr.
6647
7ffd83d7
TT
66482017-09-03 Tom Tromey <tom@tromey.com>
6649
6650 * thread.c (print_thread_info_1): Use string_printf.
6651 (thread_apply_command, thread_apply_all_command): Use
6652 std::string.
6653
1ccbe998
TT
66542017-09-03 Tom Tromey <tom@tromey.com>
6655
6656 * valprint.c (val_print_string): Update.
6657 * gdbcore.h (memory_error_message): Return std::string.
6658 * corefile.c (memory_error_message): Return std::string.
6659 (memory_error): Update.
6660 * breakpoint.c (insert_bp_location): Update.
6661
23fdd69e
SM
66622017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6663
6664 * target/waitstatus.h (target_waitstatus_to_string): Change
6665 return type to std::string.
6666 * target/waitstatus.c (target_waitstatus_to_string): Return
6667 std::string.
6668 * target.h (target_waitstatus_to_string): Remove declaration.
6669 * infrun.c (resume, clear_proceed_status_thread,
6670 print_target_wait_results, do_target_wait, save_waitstatus,
6671 stop_all_threads): Adjust.
6672 * record-btrace.c (record_btrace_wait): Adjust.
6673 * target-debug.h
6674 (target_debug_print_struct_target_waitstatus_p): Adjust.
6675
5c811d30
JK
66762017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
6677
6678 PR gdb/22046
6679 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
6680 detection.
6681
0a2dde4a
SDJ
66822017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6683
6684 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
6685 for setting/unsetting environment variables on the remote target.
6686 (New remote packets): Add entries for QEnvironmentHexEncoded,
6687 QEnvironmentUnset and QEnvironmentReset.
6688 * common/environ.c (gdb_environ::operator=): Extend method to
6689 handle m_user_set_env_list and m_user_unset_env_list.
6690 (gdb_environ::clear): Likewise.
6691 (match_var_in_string): Change type of first parameter from 'char
6692 *' to 'const char *'.
6693 (gdb_environ::set): Extend method to handle
6694 m_user_set_env_list and m_user_unset_env_list.
6695 (gdb_environ::unset): Likewise.
6696 (gdb_environ::clear_user_set_env): New method.
6697 (gdb_environ::user_set_envp): Likewise.
6698 (gdb_environ::user_unset_envp): Likewise.
6699 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
6700 m_user_unset_env_list on move constructor/assignment.
6701 (unset): Add new default parameter 'update_unset_list = true'.
6702 (clear_user_set_env): New method.
6703 (user_set_envp): Likewise.
6704 (user_unset_envp): Likewise.
6705 (m_user_set_env_list): New std::set.
6706 (m_user_unset_env_list): Likewise.
6707 * common/rsp-low.c (hex2str): New function.
6708 (bin2hex): New overload for bin2hex function.
6709 * common/rsp-low.c (hex2str): New prototype.
6710 (str2hex): New overload prototype.
6711 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
6712 QEnvironmentUnset and QEnvironmentReset.
6713 (remote_protocol_features): Add QEnvironmentHexEncoded,
6714 QEnvironmentUnset and QEnvironmentReset packets.
6715 (send_environment_packet): New function.
6716 (extended_remote_environment_support): Likewise.
6717 (extended_remote_create_inferior): Call
6718 extended_remote_environment_support.
6719 (_initialize_remote): Add QEnvironmentHexEncoded,
6720 QEnvironmentUnset and QEnvironmentReset packet configs.
6721 * unittests/environ-selftests.c (gdb_selftest_env_var):
6722 New variable.
6723 (test_vector_initialization): New function.
6724 (test_init_from_host_environ): Likewise.
6725 (test_reinit_from_host_environ): Likewise.
6726 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
6727 Likewise.
6728 (test_unset_set_empty_vector): Likewise.
6729 (test_vector_clear): Likewise.
6730 (test_std_move): Likewise.
6731 (test_move_constructor):
6732 (test_self_move): Likewise.
6733 (test_set_unset_reset): Likewise.
6734 (run_tests): Rewrite in terms of the functions above.
6735
654670a4
WP
67362017-08-31 Weimin Pan <weimin.pan@oracle.com>
6737
6738 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
6739 (adi_available): Use a temp variable of type CORE_ADDR as argument
6740 3 when calling target_auxv_search.
6741 (adi_normalize_address): Use masks and xor operators to calculate
6742 normalized address.
6743 (adi_read_versions, adi_write_versions, adi_print_versions)
6744 (do_examine, do_assign): Use paddress.
6745
7755ddb7
JB
67462017-08-29 John Baldwin <jhb@FreeBSD.org>
6747
6748 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
6749 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
6750 out of loop and add supply of FIR.
6751 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
6752 add collect of FIR.
6753
fd437cbc
SM
67542017-08-28 Simon Marchi <simon.marchi@ericsson.com>
6755
3804a343 6756 PR gdb/21827
fd437cbc
SM
6757 * cli/cli-script.c (define_command): Don't convert command name
6758 to lower case.
6759
988f6b3d
JB
67602017-08-25 Joel Brobecker <brobecker@adacore.com>
6761
6762 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
6763 Update all callers accordingly. Remove all code blocks handling
6764 the case where DISPP is not NULL.
6765
663c44ac
JK
67662017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6767
6768 PR symtab/22003
6769 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
6770 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6771 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
6772
f1902523
JK
67732017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6774
6775 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
6776 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
6777 (read_comp_units_from_section): New parameter abbrev_section, use
6778 read_and_check_comp_unit_head, allocate signatured_type if needed.
6779 (create_all_comp_units): Update read_comp_units_from_section caller.
6780
87215ad1
SDJ
67812017-08-23 Pedro Alves <palves@redhat.com>
6782
6783 PR remote/21852
6784 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
6785 to null_ptid and switch to thread without reading the registers
6786 after adding the inferior.
6787
6e41ddec
JK
67882017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
6789
6790 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
6791 compile-gcc.
6792 * compile/compile.c (compile_gcc, show_compile_gcc): New.
6793 (compile_to_object): Implement compile_gcc.
6794 (_initialize_compile): Install "set compile-gcc". Initialize
6795 compile_gcc.
6796
e68c32d5
JK
67972017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
6798
6799 * compile/compile.c (compile_to_object): Conditionally call
6800 set_verbose. Conditionally call compile or compile_v0.
6801
58afddc6
WP
68022017-08-07 Weimin Pan <weimin.pan@oracle.com>
6803
6804 * sparc64-tdep.h: (adi_normalize_address): New export.
6805 * sparc-nat.h: (open_adi_tag_fd): New export.
6806 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
6807 * sparc64-linux-tdep.c:
6808 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
6809 (sparc64_linux_handle_segmentation_fault): New function.
6810 (sparc64_linux_init_abi): Register
6811 sparc64_linux_handle_segmentation_fault
6812 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
6813 (sparc64_addr_bits_remove): New function.
6814 (sparc64_init_abi): Register sparc64_addr_bits_remove.
6815 (MAX_PROC_NAME_SIZE): New macro.
6816 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
6817 (sparc64adilist): New variable.
6818 (adi_proc_list): New variable.
6819 (find_adi_info): New function.
6820 (add_adi_info): New function.
6821 (get_adi_info_proc): New function.
6822 (get_adi_info): New function.
6823 (info_adi_command): New function.
6824 (read_maps_entry): New function.
6825 (adi_available): New function.
6826 (adi_normalize_address): New function.
6827 (adi_align_address): New function.
6828 (adi_convert_byte_count): New function.
6829 (adi_tag_fd): New function.
6830 (adi_is_addr_mapped): New function.
6831 (adi_read_versions): New function.
6832 (adi_write_versions): New function.
6833 (adi_print_versions): New function.
6834 (do_examine): New function.
6835 (do_assign): New function.
6836 (adi_examine_command): New function.
6837 (adi_assign_command): New function.
6838 (_initialize_sparc64_adi_tdep): New function.
6839
11db9430
SM
68402017-08-22 Simon Marchi <simon.marchi@ericsson.com>
6841
6842 * breakpoint.c (breakpoints_info): Rename to ...
6843 (info_breakpoints_command): ... this.
6844 (watchpoints_info): Rename to ...
6845 (info_watchpoints_command): ... this.
6846 (tracepoints_info): Rename to ...
6847 (info_tracepoints_command): ... this.
6848 (_initialize_breakpoint): Adjust.
6849 * dcache.c (dcache_info): Rename to ...
6850 (info_display_command): ... this.
6851 (_initialize_dcache): Adjust.
6852 * frame.h (args_info): Rename to ...
6853 (info_args_command): ... this.
6854 (locals_info): Rename to ...
6855 (info_locals_command): ... this.
6856 * infcmd.c (nofp_registers_info): Rename to ...
6857 (info_registers_command): ... this.
6858 (float_info): Rename to ...
6859 (info_float_command): ... this.
6860 (program_info): Rename to ...
6861 (info_program_command): ... this.
6862 (all_registers_info): Rename to ...
6863 (info_all_registers_command): ... this.
6864 (vector_info): Rename to ...
6865 (info_vector_command): ... this.
6866 (float_info): Rename to ...
6867 (info_float_command): ... this.
6868 (_initialize_infcmd): Adjust.
6869 * inferior.h (term_info): Rename to ...
6870 (info_terminal_command): ... this.
6871 * inflow.c (term_info): Rename to ...
6872 (info_terminal_command): ... this.
6873 (_initialize_inflow): Adjust.
6874 * infrun.c (signals_info): Rename to ...
6875 (info_signals_command): ... this.
6876 (_initialize_infrun): Adjust.
6877 * objc-lang.c (classes_info): Rename to ...
6878 (info_classes_command): ... this.
6879 (selectors_info): Rename to ...
6880 (info_selectors_command): ... this.
6881 (_initialize_objc_language): Adjust.
6882 * printcmd.c (sym_info): Rename to ...
6883 (info_symbol_command): ... this.
6884 (address_info): Rename to ...
6885 (info_address_command): ... this.
6886 (display_info): Rename to ...
6887 (info_display_command): ... this.
6888 (_initialize_printcmd): Adjust.
6889 * reverse.c (bookmarks_info): Rename to ...
6890 (info_breakpoints_command): ... this.
6891 (_initialize_reverse): Adjust.
6892 * ser-go32.c (dos_info): Rename to ...
6893 (info_serial_command): ... this.
6894 (_initialize_ser_dos): Adjust.
6895 * skip.c (skip_info): Rename to ...
6896 (info_skip_command): ... this.
6897 (_initialize_step_skip): Adjust.
6898 * source.c (line_info): Rename to ...
6899 (info_line_command): ... this.
6900 (source_info): Rename to ...
6901 (info_source_command)
6902 * stack.c (frame_info): Rename to ...
6903 (info_frame_command): ... this.
6904 (locals_info): Rename to ...
6905 (info_locals_command): ... this.
6906 (args_info): Rename to ...
6907 (info_args_command): ... this.
6908 (_initialize_stack): Adjust.
6909 * symtab.c (sources_info): Rename to ...
6910 (info_sources_command): ... this.
6911 (variables_info): Rename to ...
6912 (info_variables_command): ... this.
6913 (functions_info): Rename to ...
6914 (info_functions_command): ... this.
6915 (types_info): Rename to ...
6916 (info_types_command): ... this.
6917 (_initialize_symtab): Adjust.
6918 * target.c (target_info): Rename to ...
6919 (info_target_command): ... this.
6920 (initialize_targets): Adjust.
6921 * tracepoint.c (tvariables_info): Rename to ...
6922 (info_tvariables_command): ... this.
6923 (scope_info): Rename to ...
6924 (info_scope_command): ... this.
6925 (trace_dump_actions): Adjust.
6926 (_initialize_tracepoint): Adjust.
6927
b270e6f9
TT
69282017-08-22 Tom Tromey <tom@tromey.com>
6929
6930 * breakpoint.h (install_breakpoint): Update.
6931 * breakpoint.c (add_solib_catchpoint): Update.
6932 (install_breakpoint): Change argument to a std::unique_ptr.
6933 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
6934 (create_breakpoint_sal, create_breakpoint): Update.
6935 (watch_command_1, catch_exec_command_1)
6936 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
6937 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
6938 Return the breakpoint.
6939 (set_raw_breakpoint_without_location, set_raw_breakpoint)
6940 (new_single_step_breakpoint): Update.
6941 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
6942 std::unique_ptr.
6943 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
6944 std::unique_ptr.
6945 * break-catch-sig.c (create_signal_catchpoint): Use
6946 std::unique_ptr.
6947 * ada-lang.c (create_ada_exception_catchpoint): Use
6948 std::unique_ptr.
6949
36bd8eaa
TT
69502017-08-22 Tom Tromey <tom@tromey.com>
6951
6952 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
6953
56f37645
TT
69542017-08-22 Tom Tromey <tom@tromey.com>
6955
6956 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
6957 (lookup_partial_symbol): Update.
6958
0b581c69
TT
69592017-08-22 Tom Tromey <tom@tromey.com>
6960
6961 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
6962 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
6963 (find_and_open_source, symtab_to_fullname): Update.
6964 * psymtab.c (psymtab_to_fullname): Update.
6965
14278e1f
TT
69662017-08-22 Tom Tromey <tom@tromey.com>
6967
6968 * exec.c (exec_file_attach): Update.
6969 * linux-thread-db.c (try_thread_db_load): Update.
6970 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
6971 * utils.c (gdb_realpath): Change return type.
6972 (gdb_realpath_keepfile): Update.
6973 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
6974 (_initialize_utils): Register the new self test.
6975 * source.c (openp): Update.
6976 (find_and_open_source): Update.
6977 * nto-tdep.c (nto_find_and_open_solib): Update.
6978 * main.c (set_gdb_data_directory): Update.
6979 (captured_main_1): Update.
6980 * dwarf2read.c (dwarf2_get_dwz_file): Update
6981 (dw2_map_symbol_filenames): Update.
6982 * auto-load.c (auto_load_safe_path_vec_update): Update.
6983 (filename_is_in_auto_load_safe_path_vec): Change type of
6984 "filename_realp".
6985 (auto_load_objfile_script): Update.
6986 (file_is_auto_load_safe): Update. Use std::string.
6987 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
6988
4971c9a7
TT
69892017-08-22 Tom Tromey <tom@tromey.com>
6990
6991 * utils.c (gdb_realpath_keepfile): Return a
6992 gdb::unique_xmalloc_ptr.
6993 * exec.c (exec_file_attach): Update.
6994 * utils.h (gdb_realpath_keepfile): Return a
6995 gdb::unique_xmalloc_ptr.
6996
e3e41d58
TT
69972017-08-22 Tom Tromey <tom@tromey.com>
6998
6999 * compile/compile.c (compile_file_command): Use
7000 gdb::unique_xmalloc_ptr, std::string.
7001 * utils.c (gdb_abspath): Change return type.
7002 * source.c (openp): Update.
7003 * objfiles.c (allocate_objfile): Update.
7004 * main.c (set_gdb_data_directory): Update.
7005 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
7006
0d999a6e
ZZ
70072017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
7008
7009 * cli-cmds.c (list_commands): List actual code around more than
7010 one location.
7011
329d5e7e
JB
70122017-08-21 John Baldwin <jhb@FreeBSD.org>
7013
7014 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
7015
bf223d3e
PA
70162017-08-21 Pedro Alves <palves@redhat.com>
7017
7018 PR gdb/19487
7019 * c-exp.y (variable production): Handle function aliases.
7020 * minsyms.c (msymbol_is_text): New function.
7021 * minsyms.h (msymbol_is_text): Declare.
7022 * symtab.c (find_function_alias_target): New function.
7023 * symtab.h (find_function_alias_target): Declare.
7024
c973d0aa
PA
70252017-08-21 Pedro Alves <palves@redhat.com>
7026
7027 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
7028 typedefs.
7029 * typeprint.c (whatis_exp): If handling "whatis", and expression
7030 is OP_TYPE, strip one typedef level. Otherwise don't strip
7031 typedefs here.
7032 * valops.c (value_cast): Save "to" type before resolving
7033 stubs/typedefs. Use that type as resulting value's type.
7034
2989a365
TT
70352017-08-18 Tom Tromey <tom@tromey.com>
7036 Pedro Alves <palves@redhat.com>
7037
7038 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
7039 * sol-thread.c (sol_thread_resume, sol_thread_wait)
7040 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
7041 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
7042 * proc-service.c (ps_xfer_memory): Use scoped_restore.
7043 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
7044 (linux_get_siginfo_data): Add "thread" argument. Use
7045 scoped_restore.
7046 * linux-nat.c (linux_child_follow_fork)
7047 (check_stopped_by_watchpoint): Use scoped_restore.
7048 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
7049 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
7050 (restore_inferior_ptid, save_inferior_ptid): Remove.
7051 * btrace.c (btrace_fetch): Use scoped_restore.
7052 * bsd-uthread.c (bsd_uthread_fetch_registers)
7053 (bsd_uthread_store_registers): Use scoped_restore.
7054 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
7055 scoped_restore.
7056 * aix-thread.c (aix_thread_resume, aix_thread_wait)
7057 (aix_thread_xfer_partial): Use scoped_restore.
7058 * inferior.h (save_inferior_ptid): Remove.
7059
e60eb288
YQ
70602017-08-18 Yao Qi <yao.qi@linaro.org>
7061
7062 PR tdep/21818
7063 * arm-tdep.c (gdb_print_insn_arm): Mark
7064 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
7065
6d580b63
YQ
70662017-08-18 Yao Qi <yao.qi@linaro.org>
7067
7068 * NEWS: Mention GDBserver's new option "--selftest".
7069 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
7070 * selftest.c: Move it to common/selftest.c.
7071 * selftest.h: Move it to common/selftest.h.
7072 * selftest-arch.c (reset): New function.
7073 (tests_with_arch): Call reset.
7074
86dcbf50
YQ
70752017-08-18 Yao Qi <yao.qi@linaro.org>
7076
7077 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
7078 instead of exception_fprintf and printf_filtered.
7079
7649770c
YQ
70802017-08-18 Yao Qi <yao.qi@linaro.org>
7081
7082 * selftest.c (register_self_test): Rename it to
7083 selftests::register_test.
7084 (run_self_tests): selftest::run_tests.
7085 * selftest.h: Update declarations.
7086 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
7087 selftests::register_test_foreach_arch.
7088 * selftest-arch.h: Update declaration.
7089 * aarch64-tdep.c: Update.
7090 * arm-tdep.c: Likewise.
7091 * disasm-selftests.c: Likewise.
7092 * dwarf2loc.c: Likewise.
7093 * dwarf2-frame.c: Likewise.
7094 * findvar.c: Likewise.
7095 * gdbarch-selftests.c: Likewise.
7096 * maint.c (maintenance_selftest): Likewise.
7097 * regcache.c: Likewise.
7098 * rust-exp.y: Likewise.
7099 * selftest-arch.c: Likewise.
7100 * unittests/environ-selftests.c: Likewise.
7101 * unittests/function-view-selftests.c: Likewise.
7102 * unittests/offset-type-selftests.c: Likewise.
7103 * unittests/optional-selftests.c: Likewise.
7104 * unittests/scoped_restore-selftests.c: Likewise.
7105 * utils-selftests.c: Likewise.
7106
b0cba12e
PA
71072017-08-17 Pedro Alves <palves@redhat.com>
7108
7109 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
7110 local.
7111
4c8aa72d
PA
71122017-08-17 Pedro Alves <palves@redhat.com>
7113
7114 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
7115 field.
7116 (reset_die_in_process): Delete, replaced by ...
7117 (process_die_scope): ... this new class. Make it responsible for
7118 freeing cu->line_header too.
7119 (process_die): Use process_die_scope.
7120 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
7121 cu->line_header_die_owner. Don't release the line header if it's
7122 owned by the CU.
7123 (setup_type_unit_groups): Make the CU/DIE own the line header.
7124 Don't release the line header here.
7125
ba713918
AL
71262017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
7127
7128 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
7129
44d0fb3a
RK
71302017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
7131
7132 * NEWS: Mention new shortcuts for nexti and stepi in TUI
7133 Single-Key mode
7134
a5afdb16
RK
71352017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
7136
7137 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
7138 mode command list.
7139
47613aeb
SH
71402017-08-15 Stafford Horne <shorne@gmail.com>
7141
7142 * MAINTAINERS (Write After Approval): Add Stafford Horne.
7143
9c3cc999
SH
71442017-08-15 Stafford Horne <shorne@gmail.com>
7145
7146 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
7147
206726fb
SDJ
71482017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
7149
7150 PR gdb/21954
7151 * infcmd.c (unset_environment_command): Use the 'clear' method on
7152 the environment instead of resetting it.
7153
0335ac6d
JB
71542017-08-15 John Baldwin <jhb@FreeBSD.org>
7155
7156 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
7157 platforms.
7158
d3abe1c8
TT
71592017-08-14 Tom Tromey <tom@tromey.com>
7160
7161 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
7162 (print_binary_chars): Likewise.
7163 (BITS_IN_BYTES): Remove.
7164
d6382fff
TT
71652017-08-14 Tom Tromey <tom@tromey.com>
7166
7167 PR gdb/21675
7168 * valprint.c (LOW_ZERO): Change value to 034.
7169 (print_octal_chars): Add static_asserts for octal constants.
7170 * printcmd.c (print_scalar_formatted): Add 'd' case.
7171
f978cb06
TT
71722017-08-11 Tom Tromey <tom@tromey.com>
7173
7174 * symfile.c (add_symbol_file_command): Use std::vector.
7175
2f5404b3
TT
71762017-08-14 Tom Tromey <tom@tromey.com>
7177
7178 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
7179 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
7180 std::move.
7181 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
7182
de7985c3
PA
71832017-08-11 Pedro Alves <palves@redhat.com>
7184
7185 * infrun.c (process_event_stop_test): Adjust
7186 function_name_is_marked_for_skip call.
7187 * skip.c: Include <list>.
7188 (skiplist_entry): Make it a class with private fields, and
7189 getters/setters.
7190 (skiplist_entry_chain): Delete.
7191 (skiplist_entries): New.
7192 (skiplist_entry_count): Delete.
7193 (highest_skiplist_entry_num): New.
7194 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
7195 (add_skiplist_entry): Delete.
7196 (skiplist_entry::skiplist_entry): New.
7197 (skiplist_entry::add_entry): New.
7198 (skip_file_command, skip_function): Adjust.
7199 (compile_skip_regexp): Delete.
7200 (skip_command): Don't compile regexp here. Adjust to use
7201 skiplist_entry::add_entry.
7202 (skip_info): Adjust to use range-for and getters.
7203 (skip_enable_command, skip_disable_command): Adjust to use
7204 range-for and setters.
7205 (skip_delete_command): Adjust to use std::list.
7206 (add_skiplist_entry): Delete.
7207 (skip_file_p): Delete, refactored as ...
7208 (skiplist_entry::do_skip_file_p): ... this new method.
7209 (skip_gfile_p): Delete, refactored as ...
7210 (skiplist_entry::do_gskip_file_p): ... this new method.
7211 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
7212 (skiplist_entry::skip_function_p): ... this new method.
7213 (function_name_is_marked_for_skip): Now returns bool, and takes
7214 the function sal by const reference. Adjust to use range-for and
7215 skiplist_entry methods.
7216 (_initialize_step_skip): Remove references to
7217 skiplist_entry_chain, skiplist_entry_count.
7218 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
7219 takes the function sal by const reference.
7220
be7d3cd5
YQ
72212017-08-11 Yao Qi <yao.qi@linaro.org>
7222
7223 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
7224 (dwarf2_frame_cache): Remove reset_cache_cleanup.
7225 (dwarf2_frame_cache):
7226 * frame-unwind.c (frame_unwind_try_unwinder): Catch
7227 RETURN_MASK_ALL and set *this_case to NULL.
7228 * frame-unwind.h: Update comments.
7229
1c90d9f0
YQ
72302017-08-11 Yao Qi <yao.qi@linaro.org>
7231
7232 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
7233 (dwarf2_frame_state_copy_regs): Remove.
7234 (dwarf2_frame_state_free_regs): Remove.
7235 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
7236 (dwarf2_restore_rule): Call method .alloc_regs instead of
7237 dwarf2_frame_state_alloc_regs.
7238 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
7239 constructor. Call std::move.
7240 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
7241 (dwarf2_frame_cache): Likewise.
7242
7243 [GDB_SELF_TEST]: Include selftest.h and
7244 selftest-arch.h.
7245 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
7246 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
7247 execute_cfa_program_test.
7248
7249 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
7250 copy ctor, assignment operator, move assignment.
7251 <alloc_regs>: New method.
7252 <swap>: New method.
7253 (struct dwarf2_frame_state): Delete dtor.
7254 (dwarf2_frame_state_alloc_regs): Remove declaration.
7255 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
7256 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
7257
afe37d6b
YQ
72582017-08-11 Yao Qi <yao.qi@linaro.org>
7259
7260 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
7261 (dwarf2_frame_state::dwarf2_frame_state): New.
7262 (dwarf2_frame_state::~dwarf2_frame_state): New.
7263 (dwarf2_fetch_cfa_info): Update.
7264 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
7265 rather than a pointer. Update code.
7266 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
7267 dtor.
7268 <data_align, code_align, retaddr_column>: Change them to const.
7269 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
7270 to bool.
7271
b348037f
YQ
72722017-08-11 Yao Qi <yao.qi@linaro.org>
7273
7274 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
7275 <loc.exp>: New field.
7276 * dwarf2-frame.c (execute_cfa_program): Update.
7277 (dwarf2_frame_prev_register): Update.
7278
e7c9de26
PA
72792017-08-10 Pedro Alves <palves@redhat.com>
7280
7281 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
7282
e8c6b620
JB
72832017-08-09 John Baldwin <jhb@FreeBSD.org>
7284
7285 * fbsd-nat.c (struct fbsd_fork_info): Remove.
7286 (fbsd_pending_children): Use std::list.
7287 (fbsd_remember_child): Likewise.
7288 (fbsd_is_child_pending): Likewise.
7289 (fbsd_pending_vfork_done): Use std::forward_list.
7290 (fbsd_add_vfork_done): Likewise.
7291 (fbsd_is_vfork_done_pending): Likewise.
7292 (fbsd_next_vfork_done): Likewise.
7293
e4a26669
JB
72942017-08-09 John Baldwin <jhb@FreeBSD.org>
7295
7296 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
7297 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
7298 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
7299 for `mapfilename'.
7300 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 7301 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 7302
142311d3
JB
73032017-08-09 John Baldwin <jhb@FreeBSD.org>
7304
7305 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
7306 "filestuff.h".
7307 (fbsd_find_memory_regions): Fix `mapfile' initialization.
7308
42fa2e0e
TT
73092017-08-09 Tom Tromey <tom@tromey.com>
7310
7311 * skip.c (skiplist_entry): New constructor.
7312 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
7313 (skiplist_entry::file_is_glob): Now bool.
7314 (skiplist_entry::file, skiplist_entry::function): Now
7315 std::string.
7316 (make_skip_entry): Return a unique_ptr. Use new.
7317 (free_skiplist_entry, free_skiplist_entry_cleanup)
7318 (make_free_skiplist_entry_cleanup): Remove.
7319 (skip_command, skip_disable_command, add_skiplist_entry)
7320 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
7321 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
7322 (function_name_is_marked_for_skip): Update.
7323 (skip_delete_command): Update. Use delete.
7324
cd3af38d
JW
73252017-08-09 Jiong Wang <jiong.wang@arm.com>
7326
7327 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
7328 (aarch64_linux_core_read_description): New function.
7329 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
7330
29592bde
PA
73312017-08-09 Pedro Alves <palves@redhat.com>
7332
7333 * cp-name-parser.y (cp_comp_to_string): Return a
7334 gdb::unique_xmalloc_ptr<char>.
7335 * cp-support.c (replace_typedefs_qualified_name)
7336 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
7337 (cp_canonicalize_string_full): Use op= instead of explicit
7338 convertion.
7339 (cp_class_name_from_physname, method_name_from_physname)
7340 (cp_func_name, cp_remove_params): Adjust to use
7341 gdb::unique_xmalloc_ptr<char>.
7342 * cp-support.h (cp_comp_to_string): Return a
7343 gdb::unique_xmalloc_ptr<char>.
7344 * python/py-type.c (typy_lookup_type): Adjust to use
7345 gdb::unique_xmalloc_ptr<char>.
7346
b3340438
L
73472017-08-09 H.J. Lu <hongjiu.lu@intel.com>
7348
7349 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
7350
e88e8651
YQ
73512017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
7352 Yao Qi <yao.qi@linaro.org>
7353
7354 * cp-support.c (cp_canonicalize_string_full): Use
7355 gdb::unique_xmalloc_ptr<char>.
7356 (cp_canonicalize_string): Likewise.
7357
f5a29eb0
YQ
73582017-08-09 Yao Qi <yao.qi@linaro.org>
7359
7360 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
7361 * regformats/i386/amd64-avx-avx512.dat: Remove.
7362 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
7363 * regformats/i386/amd64-avx-mpx.dat:Remove.
7364 * regformats/i386/amd64-avx.dat: Remove.
7365 * regformats/i386/amd64-mpx.dat: Remove.
7366 * regformats/i386/i386-avx-avx512.dat: Remove.
7367 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
7368 * regformats/i386/i386-avx-mpx.dat: Remove.
7369 * regformats/i386/i386-mmx.dat: Remove.
7370 * regformats/i386/i386-mpx.dat: Remove.
7371
57757c2f
YQ
73722017-08-09 Yao Qi <yao.qi@linaro.org>
7373
7374 * amd64-tdep.h (tdesc_x32): Remove the declaration.
7375 * amd64-tdep.c: Don't include features/i386/x32*.c.
7376 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
7377 functions.
7378 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
7379 and i386/x32-avx-avx512.
7380 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
7381 and i386/x32.xml.
7382 * features/i386/x32-avx-avx512.c: Removed.
7383 * features/i386/x32-avx-avx512.xml: Removed.
7384 * features/i386/x32-avx.c: Removed.
7385 * features/i386/x32-avx.xml: Removed.
7386 * features/i386/x32.c: Removed.
7387 * features/i386/x32.xml: Removed.
7388 * regformats/i386/x32-avx-avx512.dat: Removed.
7389 * regformats/i386/x32-avx.dat: Removed.
7390 * regformats/i386/x32.dat: Removed.
7391
ba7b109b
MR
73922017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7393
7394 PR breakpoints/21886
7395 * mem-break.c (default_memory_insert_breakpoint): Use
7396 `->placed_address' rather than `->reqstd_address' for the
7397 breakpoint location.
7398
e347efc3
MR
73992017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7400
7401 * arch-utils.c (default_print_insn): Remove arch/mach/endian
7402 assertions.
7403
0dba2a6c
MR
74042017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7405
7406 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
7407 a union of `tdep_info', `tdesc_data' and `id'.
7408 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
7409 rather than `info.tdep_info'.
7410 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
7411 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
7412 * i386-tdep.c (i386_gdbarch_init): Likewise.
7413 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
7414 * mips-tdep.c (mips_gdbarch_init): Likewise.
7415 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
7416 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
7417 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
7418 `info.tdep_info'.
7419 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
7420 `info.tdep_info'.
7421 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
7422 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
7423 `info.tdep_info'.
7424 * spu-tdep.c (spu_gdbarch_init): Likewise.
7425 * gdbarch.h: Regenerate.
7426
16eb6b2d
LS
74272017-08-07 Leszek Swirski <leszeks@google.com>
7428
7b005726 7429 PR symtab/20899
16eb6b2d
LS
7430 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
7431
74cbb09e
SM
74322017-08-07 Simon Marchi <simon.marchi@ericsson.com>
7433
7434 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
7435 (gdbsim_open): Rename gdb_argv args object to argv.
7436
ee0c3293
TT
74372017-08-05 Tom Tromey <tom@tromey.com>
7438
7439 * compile/compile-object-load.c (compile_object_load): Use
7440 gdb::unique_xmalloc_ptr.
7441 * cli/cli-dump.c (scan_filename): Rename from
7442 scan_filename_with_cleanup. Change return type.
7443 (scan_expression): Rename from scan_expression_with_cleanup.
7444 Change return type.
7445 (dump_memory_to_file, dump_value_to_file, restore_command):
7446 Use gdb::unique_xmalloc_ptr. Update.
7447 * cli/cli-cmds.c (find_and_open_script): Use
7448 gdb::unique_xmalloc_ptr.
7449 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
7450 * symmisc.c (maintenance_print_symbols)
7451 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
7452 * symfile.c (symfile_bfd_open, generic_load)
7453 (add_symbol_file_command, remove_symbol_file_command): Use
7454 gdb::unique_xmalloc_ptr.
7455 * source.c (openp): Use gdb::unique_xmalloc_ptr.
7456 * psymtab.c (maintenance_print_psymbols): Use
7457 gdb::unique_xmalloc_ptr.
7458 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
7459 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
7460 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
7461 (reload_shared_libraries_1): Likewise.
7462
3232fabd
TT
74632017-08-05 Tom Tromey <tom@tromey.com>
7464
7465 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
7466 (rust_op_vector, rust_set_vector): New typedefs.
7467 (current_parser): New global.
7468 (work_obstack): Change to pointer type. Update all users.
7469 (rust_ast, pstate): Remove globals.
7470 (struct rust_parser): New.
7471 (%union) <params, field_inits>: Change type.
7472 (start, tuple_expr, unit_expr, struct_expr_list, literal)
7473 (field_expr, expr_list, maybe_expr_list, type_list): Update.
7474 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
7475 (convert_params_to_types, convert_params_to_expression): Change
7476 type of "params".
7477 (ast_string): Change type of "fields".
7478 (rust_parse): Make a rust_parser. Remove cleanups.
7479 (rust_lex_tests): Make and install an auto_obstack.
7480
f02fd774
YQ
74812017-08-04 Yao Qi <yao.qi@linaro.org>
7482
7483 * configure.srv (ipa_x32_linux_regobj): New.
7484 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
7485 instead of X86_TDESC_AVX512.
7486 (initialize_low_tracepoint): Call
7487 init_registers_x32_avx_avx512_linux.
7488
91975afd
YQ
74892017-08-04 Yao Qi <yao.qi@linaro.org>
7490
7491 * utils.h (gdb_argv): Add namespace std for nullptr_t.
7492
2331fa3a
RK
74932017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
7494
7495 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
7496
744e4fe1
TT
74972017-08-03 Tom Tromey <tom@tromey.com>
7498
7499 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
7500 Remove.
7501 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
7502
1c034b67
TT
75032017-08-03 Tom Tromey <tom@tromey.com>
7504
7505 * python/py-param.c (compute_enum_values): Use gdb_argv.
7506
773a1edc
TT
75072017-08-03 Tom Tromey <tom@tromey.com>
7508
7509 * utils.h (struct gdb_argv_deleter): New.
7510 (gdb_argv): New class.
7511 * utils.c (gdb_argv::reset): New method.
7512 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
7513 * tracefile.c (tsave_command): Use gdb_argv.
7514 * top.c (new_ui_command): Use gdb_argv.
7515 * symmisc.c (maintenance_print_symbols)
7516 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
7517 * symfile.c (symbol_file_command, generic_load)
7518 (remove_symbol_file_command): Use gdb_argv.
7519 * stack.c (backtrace_command): Use gdb_argv.
7520 * source.c (add_path, show_substitute_path_command)
7521 (unset_substitute_path_command, set_substitute_path_command):
7522 Use gdb_argv.
7523 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
7524 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
7525 * remote.c (extended_remote_run, remote_put_command)
7526 (remote_get_command, remote_delete_command): Use gdb_argv.
7527 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
7528 (gdbsim_open): Use gdb_argv.
7529 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
7530 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
7531 * procfs.c (procfs_info_proc): Use gdb_argv.
7532 * interps.c (interpreter_exec_cmd): Use gdb_argv.
7533 * infrun.c (handle_command): Use gdb_argv.
7534 * inferior.c (add_inferior_command, clone_inferior_command):
7535 Use gdb_argv.
7536 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
7537 * exec.c (exec_file_command): Use gdb_argv.
7538 * cli/cli-cmds.c (alias_command): Use gdb_argv.
7539 * compile/compile.c (build_argc_argv): Use gdb_argv.
7540
0d50bde3
TT
75412017-08-03 Tom Tromey <tom@tromey.com>
7542
7543 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
7544
7f968c89
TT
75452017-08-03 Tom Tromey <tom@tromey.com>
7546
7547 * python/python.c (compute_python_string): Return std::string.
7548 (gdbpy_eval_from_control_command): Update.
7549 (do_start_initialization): Use std::string.
7550 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
7551 xstrprintf.
7552 * python/py-breakpoint.c (local_setattro): Use string_printf, not
7553 xstrprintf.
7554
3c9ebddd
TT
75552017-08-03 Tom Tromey <tom@tromey.com>
7556
7557 * top.h (do_restore_instream_cleanup): Remove.
7558 * top.c (do_restore_instream_cleanup): Remove.
7559 (read_command_file): Use scoped_restore.
7560 * cli/cli-script.c (execute_user_command): Use scoped_restore.
7561
b51b225e
TT
75622017-08-03 Tom Tromey <tom@tromey.com>
7563
7564 * cli/cli-script.c (execute_user_command)
7565 (execute_control_command): Use scoped_restore.
7566
ac991630
TT
75672017-08-03 Tom Tromey <tom@tromey.com>
7568
7569 * cli/cli-script.c (do_restore_user_call_depth): Remove.
7570 (execute_user_command): Remove user_call_depth; use
7571 user_args_stack's size instead.
7572
898e0c8e
TT
75732017-08-03 Tom Tromey <tom@tromey.com>
7574
7575 * top.h (in_user_command): Remove.
7576 * top.c (in_user_command): Remove.
7577 * cli/cli-script.c (do_restore_user_call_depth)
7578 (execute_user_command): Update.
7579
26fcd5d7
TT
75802017-08-03 Tom Tromey <tom@tromey.com>
7581
7582 * valops.c (search_struct_method): Use gdb::byte_vector.
7583 * valarith.c (value_concat): Use std::vector.
7584 * target.c (memory_xfer_partial): Use gdb::byte_vector.
7585 (simple_search_memory): Likewise.
7586 * printcmd.c (find_string_backward): Use gdb::byte_vector.
7587 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
7588 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
7589 * elfread.c (elf_rel_plt_read): Use std::string.
7590 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
7591 * cli/cli-dump.c (restore_section_callback): Use
7592 gdb::byte_vector.
7593
7c218e6c
TT
75942017-08-03 Tom Tromey <tom@tromey.com>
7595
7596 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
7597
31b68d4a
TT
75982017-08-03 Tom Tromey <tom@tromey.com>
7599
7600 * tui/tui-regs.c (tui_restore_gdbout): Remove.
7601 (tui_register_format): Use scoped_restore.
7602
2ec845e7
TT
76032017-08-03 Tom Tromey <tom@tromey.com>
7604
7605 * reverse.c (exec_direction_default): Remove.
7606 (exec_reverse_once): Use scoped_restore.
7607 * remote.c (restore_remote_timeout): Remove.
7608 (remote_flash_erase, remote_flash_write, remote_flash_done)
7609 (readchar, remote_serial_write): Use scoped_restore.
7610 * cli/cli-script.c (struct source_cleanup_lines_args)
7611 (source_cleanup_lines): Remove.
7612 (script_from_file): Use scoped_restore.
7613 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
7614 (source_command): Use scoped_restore.
7615
b3bc8453
TT
76162017-08-03 Tom Tromey <tom@tromey.com>
7617
7618 * utils.h (make_cleanup_free_so): Remove.
7619 * utils.c (do_free_so, make_cleanup_free_so): Remove.
7620 * solist.h (struct so_deleter): New.
7621 (so_list_up): New typedef.
7622 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
7623
e3ad2841
TT
76242017-08-03 Tom Tromey <tom@tromey.com>
7625
7626 * utils.h (make_cleanup_restore_current_language): Remove.
7627 * utils.c (do_restore_current_language)
7628 (make_cleanup_restore_current_language): Remove.
7629 * parse.c (parse_exp_in_context_1)
7630 (parse_expression_with_language): Use
7631 scoped_restore_current_language.
7632 * mi/mi-main.c (mi_cmd_execute): Use
7633 scoped_restore_current_language.
7634 * language.h (scoped_restore_current_language): New class.
7635
b80cf838
TT
76362017-08-03 Tom Tromey <tom@tromey.com>
7637
7638 * compile/compile.c (cleanup_unlink_file): Remove.
7639 (compile_to_object): Use gdb::unlinker.
7640 (eval_compile_command): Likewise.
7641
fad0444a
TT
76422017-08-03 Tom Tromey <tom@tromey.com>
7643
7644 * utils.h (make_cleanup_fclose): Remove.
7645 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
7646
6e7bc05c
TT
76472017-08-03 Tom Tromey <tom@tromey.com>
7648
7649 * top.c (open_terminal_stream): Return gdb_file_up.
7650 (new_ui_command): Update.
7651
4a45905b
TT
76522017-08-03 Tom Tromey <tom@tromey.com>
7653
7654 * source.c (print_source_lines_base, forward_search_command)
7655 (reverse_search_command): Use gdb_file_up.
7656
7cd06d6e
TT
76572017-08-03 Tom Tromey <tom@tromey.com>
7658
7659 * fbsd-nat.c (fbsd_find_memory_regions): Update.
7660
ed166945
TT
76612017-08-03 Tom Tromey <tom@tromey.com>
7662
7663 * cli/cli-cmds.c (find_and_open_script): Change return type.
7664 Remove "streamp" and "full_path" parameters.
7665 (source_script_with_search): Update.
7666 * auto-load.c (source_script_file): Update.
7667 * cli/cli-cmds.h (find_and_open_script): Change type.
7668 (open_script): New struct.
7669
d419f42d
TT
76702017-08-03 Tom Tromey <tom@tromey.com>
7671
7672 * xml-support.c (xml_fetch_content_from_file): Update.
7673 * ui-file.c (stdio_file::open): Update.
7674 * tracefile-tfile.c (tfile_start): Update.
7675 * remote.c (remote_file_put, remote_file_get): Update.
7676 * nat/linux-procfs.c (linux_proc_get_int)
7677 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
7678 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
7679 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
7680 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
7681 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
7682 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
7683 * linux-nat.c (linux_proc_pending_signals): Update.
7684 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
7685 (file_closer): Remove.
7686 * compile/compile.c (compile_to_object): Update.
7687 * common/filestuff.h (struct gdb_file_deleter): New.
7688 (gdb_file_up): New typedef.
7689 (gdb_fopen_cloexec): Change return type.
7690 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
7691 * cli/cli-dump.c (fopen_with_cleanup): Remove.
7692 (dump_binary_file, restore_binary_file): Update.
7693 * auto-load.c (auto_load_objfile_script_1): Update.
7694
4a2b031d
TT
76952017-08-03 Tom Tromey <tom@tromey.com>
7696
7697 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
7698 (info_static_tracepoint_markers_command): Likewise.
7699 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
7700 * skip.c (skip_info): Use ui_out_emit_table.
7701 * progspace.c (print_program_space): Use ui_out_emit_table.
7702 * osdata.c (info_osdata): Use ui_out_emit_table.
7703 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
7704 ui_out_emit_table.
7705 * linux-thread-db.c (info_auto_load_libthread_db): Use
7706 ui_out_emit_table.
7707 * inferior.c (print_inferior): Use ui_out_emit_table.
7708 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
7709 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
7710 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
7711 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
7712 * ui-out.h (class ui_out_emit_table): New.
7713
a4f320fd
MR
77142017-08-02 Maciej W. Rozycki <macro@imgtec.com>
7715
7716 * mips-tdep.c (mips_fpu_type_str): New function.
7717 (mips_dump_tdep): Call it.
7718
a2f1f308
MR
77192017-08-01 Maciej W. Rozycki <macro@imgtec.com>
7720
7721 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
7722 `->mips_fpu_type'.
7723
7e5ed83b
XR
77242017-07-31 Xavier Roirand <roirand@adacore.com>
7725
7726 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
7727
4c9dc811
XR
77282017-07-27 Xavier Roirand <roirand@adacore.com>
7729
7730 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
7731
27d41eac
YQ
77322017-07-26 Yao Qi <yao.qi@linaro.org>
7733
7734 * cli/cli-cmds.c (maintenancechecklist): New variable.
7735 * gdbcmd.h (maintenancechecklist): Declare it.
7736 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
7737 Call i386_linux_read_description with different masks.
7738 * maint.c (maintenance_check_command): New function.
7739 (_initialize_maint_cmds): Call add_prefix_cmd.
7740 * target-descriptions.c (tdesc_reg): override operator != and ==.
7741 (tdesc_type): Likewise.
7742 (tdesc_feature): Likewise.
7743 (target_desc): Likewise.
7744 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
7745 (maintenance_check_xml_descriptions): New function.
7746 (_initialize_target_descriptions) Add command "xml-descriptions".
7747 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
7748
ea03d0d3
YQ
77492017-07-26 Yao Qi <yao.qi@linaro.org>
7750
7751 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
7752 Include features/i386/32bit-*.c.
7753 (i386_linux_read_description): Generate target description if it
7754 doesn't exist.
7755 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
7756 functions.
7757 * features/i386/32bit-linux.c: Re-generated.
7758 * features/i386/32bit-sse.c: Likewise.
7759 * target-descriptions.c (print_c_feature::visit): Print code to
7760 set register number if needed.
7761 (print_c_feature) <m_next_regnum>: New field.
7762
25aa13e5
YQ
77632017-07-26 Yao Qi <yao.qi@linaro.org>
7764
7765 * features/Makefile (CFILES): Rename with TDESC_CFILES.
7766 (FEATURE_XMLFILES): New.
7767 (FEATURE_CFILES): New.
7768 New rules.
7769 (clean-cfiles): Remove generated c files.
7770 * features/i386/32bit-avx.c: Generated.
7771 * features/i386/32bit-avx512.c: Generated.
7772 * features/i386/32bit-core.c: Generated.
7773 * features/i386/32bit-linux.c: Generated.
7774 * features/i386/32bit-mpx.c: Generated.
7775 * features/i386/32bit-pkeys.c: Generated.
7776 * features/i386/32bit-sse.c: Generated.
7777 * target-descriptions.c: Include algorithm.
7778 (tdesc_element_visitor): Add method visit_end.
7779 (print_c_tdesc): Implement visit_end.
7780 (print_c_tdesc:: m_filename_after_features): Move it to
7781 protected.
7782 (print_c_feature): New class.
7783 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
7784 name starts with "i386/32bit-".
7785
6eb1e6a8
YQ
77862017-07-26 Yao Qi <yao.qi@linaro.org>
7787
7788 * target-descriptions.c (tdesc_element_visitor): New class.
7789 (tdesc_element): New class.
7790 (tdesc_reg): Inherit from tdesc_element.
7791 (tdesc_reg::accept): New function.
7792 (tdesc_type): Inherit from tdesc_element.
7793 (tdesc_type::accept): New function.
7794 (tdesc_feature): Inherit from tdesc_element.
7795 (tdesc_feature::accept): New function.
7796 (target_desc): Inherit from tdesc_element.
7797 (target_desc::target_desc): New.
7798 (target_desc::~target_desc): New.
7799 (target_desc::accept): New.
7800 (allocate_target_description): Use new.
7801 (free_target_description): Use delete.
7802 (print_c_tdesc): New class.
7803 (maint_print_c_tdesc_cmd): Adjust.
7804
7805 * features/aarch64.c: Re-generated.
7806 * features/arc-arcompact.c: Re-generated.
7807 * features/arc-v2.c: Re-generated.
7808 * features/arm/arm-with-iwmmxt.c: Re-generated.
7809 * features/arm/arm-with-m.c: Re-generated.
7810 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
7811 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
7812 * features/arm/arm-with-neon.c: Re-generated.
7813 * features/arm/arm-with-vfpv2.c: Re-generated.
7814 * features/arm/arm-with-vfpv3.c: Re-generated.
7815 * features/i386/amd64-avx-avx512.c: Re-generated.
7816 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
7817 * features/i386/amd64-avx.c: Re-generated.
7818 * features/i386/amd64-avx-linux.c: Re-generated.
7819 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
7820 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
7821 * features/i386/amd64-avx-mpx.c: Re-generated.
7822 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
7823 * features/i386/amd64.c: Re-generated.
7824 * features/i386/amd64-linux.c: Re-generated.
7825 * features/i386/amd64-mpx.c: Re-generated.
7826 * features/i386/amd64-mpx-linux.c: Re-generated.
7827 * features/i386/i386-avx-avx512.c: Re-generated.
7828 * features/i386/i386-avx-avx512-linux.c: Re-generated.
7829 * features/i386/i386-avx.c: Re-generated.
7830 * features/i386/i386-avx-linux.c: Re-generated.
7831 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
7832 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
7833 * features/i386/i386-avx-mpx.c: Re-generated.
7834 * features/i386/i386-avx-mpx-linux.c: Re-generated.
7835 * features/i386/i386.c: Re-generated.
7836 * features/i386/i386-linux.c: Re-generated.
7837 * features/i386/i386-mmx.c: Re-generated.
7838 * features/i386/i386-mmx-linux.c: Re-generated.
7839 * features/i386/i386-mpx.c: Re-generated.
7840 * features/i386/i386-mpx-linux.c: Re-generated.
7841 * features/i386/x32-avx-avx512.c: Re-generated.
7842 * features/i386/x32-avx-avx512-linux.c: Re-generated.
7843 * features/i386/x32-avx.c: Re-generated.
7844 * features/i386/x32-avx-linux.c: Re-generated.
7845 * features/i386/x32.c: Re-generated.
7846 * features/i386/x32-linux.c: Re-generated.
7847 * features/microblaze.c: Re-generated.
7848 * features/microblaze-with-stack-protect.c: Re-generated.
7849 * features/mips64-dsp-linux.c: Re-generated.
7850 * features/mips64-linux.c: Re-generated.
7851 * features/mips-dsp-linux.c: Re-generated.
7852 * features/mips-linux.c: Re-generated.
7853 * features/nds32.c: Re-generated.
7854 * features/nios2.c: Re-generated.
7855 * features/nios2-linux.c: Re-generated.
7856 * features/rs6000/powerpc-32.c: Re-generated.
7857 * features/rs6000/powerpc-32l.c: Re-generated.
7858 * features/rs6000/powerpc-403.c: Re-generated.
7859 * features/rs6000/powerpc-403gc.c : Re-generated.
7860 * features/rs6000/powerpc-405.c: Re-generated.
7861 * features/rs6000/powerpc-505.c: Re-generated.
7862 * features/rs6000/powerpc-601.c: Re-generated.
7863 * features/rs6000/powerpc-602.c: Re-generated.
7864 * features/rs6000/powerpc-603.c: Re-generated.
7865 * features/rs6000/powerpc-604.c: Re-generated.
7866 * features/rs6000/powerpc-64.c: Re-generated.
7867 * features/rs6000/powerpc-64l.c: Re-generated.
7868 * features/rs6000/powerpc-7400.c: Re-generated.
7869 * features/rs6000/powerpc-750.c: Re-generated.
7870 * features/rs6000/powerpc-860.c: Re-generated.
7871 * features/rs6000/powerpc-altivec32.c: Re-generated.
7872 * features/rs6000/powerpc-altivec32l.c: Re-generated.
7873 * features/rs6000/powerpc-altivec64.c: Re-generated.
7874 * features/rs6000/powerpc-altivec64l.c: Re-generated.
7875 * features/rs6000/powerpc-cell32l.c: Re-generated.
7876 * features/rs6000/powerpc-cell64l.c: Re-generated.
7877 * features/rs6000/powerpc-e500.c: Re-generated.
7878 * features/rs6000/powerpc-e500l.c: Re-generated.
7879 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
7880 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
7881 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
7882 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
7883 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
7884 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
7885 * features/rs6000/powerpc-vsx32.c: Re-generated.
7886 * features/rs6000/powerpc-vsx32l.c: Re-generated.
7887 * features/rs6000/powerpc-vsx64.c: Re-generated.
7888 * features/rs6000/powerpc-vsx64l.c: Re-generated.
7889 * features/rs6000/rs6000.c: Re-generated.
7890 * features/s390-linux32.c: Re-generated.
7891 * features/s390-linux32v1.c: Re-generated.
7892 * features/s390-linux32v2.c: Re-generated.
7893 * features/s390-linux64.c: Re-generated.
7894 * features/s390-linux64v1.c: Re-generated.
7895 * features/s390-linux64v2.c: Re-generated.
7896 * features/s390-te-linux64.c: Re-generated.
7897 * features/s390-tevx-linux64.c: Re-generated.
7898 * features/s390-vx-linux64.c: Re-generated.
7899 * features/s390x-linux64.c: Re-generated.
7900 * features/s390x-linux64v1.c: Re-generated.
7901 * features/s390x-linux64v2.c: Re-generated.
7902 * features/s390x-te-linux64.c: Re-generated.
7903 * features/s390x-tevx-linux64.c: Re-generated.
7904 * features/s390x-vx-linux64.c: Re-generated.
7905 * features/sparc/sparc32-solaris.c: Re-generated.
7906 * features/sparc/sparc64-solaris.c: Re-generated.
7907 * features/tic6x-c62x.c: Re-generated.
7908 * features/tic6x-c62x-linux.c: Re-generated.
7909 * features/tic6x-c64x.c: Re-generated.
7910 * features/tic6x-c64x-linux.c: Re-generated.
7911 * features/tic6x-c64xp.c: Re-generated.
7912 * features/tic6x-c64xp-linux.c: Re-generated.
7913
35b4818d
YQ
79142017-07-26 Yao Qi <yao.qi@linaro.org>
7915
7916 * i386-linux-tdep.c (i386_linux_read_description): New function.
7917 (i386_linux_core_read_description): Call
7918 i386_linux_read_description.
7919 * i386-linux-tdep.h (i386_linux_read_description): Declare.
7920 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
7921 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
7922 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
7923 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
7924 * x86-linux-nat.c (x86_linux_read_description): Call
7925 i386_linux_read_description.
7926
8e2141c6
YQ
79272017-07-26 Yao Qi <yao.qi@linaro.org>
7928
7929 * NEWS: Mention it.
7930 * features/Makefile (%.c: %.xml): Pass the xml file name to
7931 command "maint print c-tdesc".
7932 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
7933 name from 'arg'.
7934
b468ff4c
YQ
79352017-07-26 Yao Qi <yao.qi@linaro.org>
7936
7937 * target-descriptions.c (target_desc): Add ctor and dtor. Do
7938 in-class initialization.
7939 (tdesc_create_feature): Call new instead of XCNEW.
7940 (free_target_description): Ue delete.
7941
b9c0e1b4
JB
79422017-07-25 John Baldwin <jhb@FreeBSD.org>
7943
7944 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
7945
a04b5337
YQ
79462017-07-25 Yao Qi <yao.qi@linaro.org>
7947
7948 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
7949 constant.
7950 (amd64_x32_init_abi): Likewise.
7951 * amd64-tdep.h (amd64_init_abi): Update declaration.
7952 (amd64_x32_init_abi): Likewise.
7953
02ad7fc2
YQ
79542017-07-25 Yao Qi <yao.qi@linaro.org>
7955
7956 PR tdep/21717
7957 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
7958 condition for FPSCR.
7959 (arm_linux_store_inferior_registers): Likewise.
7960
b6f48cb0
TT
79612017-07-22 Tom Tromey <tom@tromey.com>
7962
7963 * break-catch-syscall.c (struct catch_syscall_inferior_data)
7964 <syscalls_counts>: Now a std::vector.
7965 (get_catch_syscall_inferior_data): Use "new".
7966 (catch_syscall_inferior_data_cleanup): Use "delete".
7967 (insert_catch_syscall, remove_catch_syscall)
7968 (clear_syscall_counts): Update.
7969
e12c9b7a
TT
79702017-07-22 Tom Tromey <tom@tromey.com>
7971
7972 * break-catch-syscall.c (syscall_catchpoint)
7973 <syscalls_to_be_caught>: Now a std::vector<int>
7974 (~syscall_catchpoint): Remove.
7975 (insert_catch_syscall, remove_catch_syscall)
7976 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
7977 (print_mention_catch_syscall, print_recreate_catch_syscall):
7978 Update.
7979 (create_syscall_event_catchpoint): Change type of "filter"
7980 parameter.
7981 (catch_syscall_split_args): Return a std::vector.
7982 (catch_syscall_command_1, catching_syscall_number_1): Update.
7983
4fa8aeac
TT
79842017-07-22 Tom Tromey <tom@tromey.com>
7985
7986 * break-catch-throw.c (struct exception_catchpoint)
7987 <exception_rx>: Now a std::string.
7988 (~exception_catchpoint): Remove.
7989 (print_one_detail_exception_catchpoint): Update.
7990 (handle_gnu_v3_exceptions): Change type of except_rx.
7991 (extract_exception_regexp): Return a std::string.
7992 (catch_exception_command_1): Update.
7993
f746a154
TT
79942017-07-22 Tom Tromey <tom@tromey.com>
7995
7996 * break-catch-sig.c (gdb_signal_type): Remove typedef.
7997 (struct signal_catchpoint) <signals_to_be_caught>: Now a
7998 std::vector.
7999 <catch_all>: Now a bool.
8000 (~signal_catchpoint): Remove.
8001 (signal_catchpoint_insert_location)
8002 (signal_catchpoint_remove_location)
8003 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
8004 (signal_catchpoint_print_mention)
8005 (signal_catchpoint_print_recreate)
8006 (signal_catchpoint_explains_signal): Update.
8007 (create_signal_catchpoint): Change type of "filter" and
8008 "catch_all".
8009 (catch_signal_split_args): Return a std::vector. Change type of
8010 "catch_all".
8011 (catch_signal_command): Update.
8012
47e77640
PA
80132017-07-20 Pedro Alves <palves@redhat.com>
8014
8015 * ada-lang.c (ada_language_defn): Make extern.
8016 (_initialize_ada_language): Remove add_language call.
8017 * c-lang.c (c_language_defn, cplus_language_defn)
8018 (asm_language_defn, minimal_language_defn): Make extern.
8019 (_initialize_c_language): Delete.
8020 * completer.c (compare_cstrings): Delete, moved to utils.h.
8021 * d-lang.c (d_language_defn): Make extern.
8022 (_initialize_d_language): Remove add_language calls.
8023 * defs.h (enum language): Add comment.
8024 * f-lang.c (f_language_defn): Make extern.
8025 (_initialize_f_language): Remove add_language call.
8026 * go-lang.c (go_language_defn): Make extern.
8027 (_initialize_go_language): Remove add_language call.
8028 * language.c: Include <algorithm>.
8029 (languages): Redefine as const array.
8030 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
8031 (set_language_command): Handle "local". Use for-range loop.
8032 (set_language): Remove loop.
8033 (language_enum): Rewrite.
8034 (language_def, language_str): Remove loops.
8035 (add_language): Delete.
8036 (add_set_language_command): New, based on add_languages.
8037 (skip_language_trampoline): Adjust.
8038 (local_language_defn): Delete.
8039 (language_gdbarch_post_init): Adjust.
8040 (_initialize_language): Remove add_language calls. Call
8041 add_set_language_command.
8042 * language.h (add_language): Delete.
8043 (auto_language_defn)
8044 (unknown_language_defn, minimal_language_defn, ada_language_defn)
8045 (asm_language_defn, c_language_defn, cplus_language_defn)
8046 (d_language_defn, f_language_defn, go_language_defn)
8047 (m2_language_defn, objc_language_defn, opencl_language_defn)
8048 (pascal_language_defn, rust_language_defn): Declare.
8049 * m2-lang.c (m2_language_defn): Make extern.
8050 (_initialize_m2_language): Remove add_language call.
8051 * objc-lang.c (objc_language_defn): Make extern.
8052 (_initialize_objc_language): Remove add_language call.
8053 * opencl-lang.c (opencl_language_defn): Make extern.
8054 (_initialize_opencl_language): Remove add_language call.
8055 * p-lang.c (pascal_language_defn): Make extern.
8056 (_initialize_pascal_language): Delete.
8057 * rust-lang.c (rust_language_defn): Make extern.
8058 (_initialize_rust_language): Delete.
8059 * utils.h (compare_cstrings): New static inline function.
8060
edb0c9cb
PA
80612017-07-20 Pedro Alves <palves@redhat.com>
8062
8063 * ada-lang.c (ada_to_fixed_type_1): Adjust.
8064 (get_var_value): Constify parameters.
8065 (get_int_var_value): Change prototype.
8066 (to_fixed_range_type): Adjust.
8067 * ada-lang.h (get_int_var_value): Change prototype.
8068
a778f165
PA
80692017-07-20 Pedro Alves <palves@redhat.com>
8070
8071 * dwarf2read.c (dw2_lookup_symbol): Use
8072 SYMBOL_MATCHES_SEARCH_NAME.
8073 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
8074
42edd901
PA
80752017-07-20 Pedro Alves <palves@redhat.com>
8076
8077 * block.c (block_iter_name_step, block_iter_name_first)
8078 (block_iter_name_next): Delete.
8079 (block_lookup_symbol_primary): Adjust to use
8080 dict_iter_match_first/dict_iter_match_next.
8081 * block.h (block_iter_name_first, block_iter_name_next): Delete
8082 declarations.
8083 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
8084 dict_iter_match_first/dict_iter_match_next.
8085
cf325299
PA
80862017-07-20 Pedro Alves <palves@redhat.com>
8087
8088 * cp-support.c (cp_find_first_component_aux): Add missing case for
8089 end of string.
8090
c5ed0576
DB
80912017-07-18 David Blaikie <dblaikie@gmail.com>
8092
8093 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
8094 of dwo_cu's dwo_file.
8095
27841e76
YQ
80962017-07-18 Yao Qi <yao.qi@linaro.org>
8097
8098 * remote.c (store_registers_using_G): Remove one line comment.
8099
cfb7e58b
YQ
81002017-07-18 Yao Qi <yao.qi@linaro.org>
8101
8102 * regcache.c (regcache_cpy): Simplify it.
8103 (regcache::cpy_no_passthrough): Remove it.
8104 * regcache.h (cpy_no_passthrough): Remove it.
8105 (regcache_dup, regcache_cpy): Update comments.
8106
386535dd
PA
81072017-07-18 Pedro Alves <palves@redhat.com>
8108
8109 * remote-sim.c (sim_command_completer): Adjust to work with a
8110 completion_tracker instead of a VEC.
8111
c45ec17c
PA
81122017-07-17 Pedro Alves <palves@redhat.com>
8113
8114 * completer.c (complete_source_filenames): New function.
8115 (complete_address_and_linespec_locations): New function.
8116 (location_completer): Use complete_address_and_linespec_locations.
8117 (completion_tracker::build_completion_result): Honor the tracker's
8118 request to suppress append.
8119 * completer.h (completion_tracker::suppress_append_ws)
8120 (completion_tracker::set_suppress_append_ws): New methods.
8121 (completion_tracker::m_suppress_append_ws): New field.
8122 (complete_source_filenames): New declaration.
8123 * linespec.c (linespec_complete_what): New.
8124 (struct ls_parser) <complete_what, completion_word,
8125 completion_quote_char, completion_quote_end, completion_tracker>:
8126 New fields.
8127 (string_find_incomplete_keyword_at_end): New.
8128 (linespec_lexer_lex_string): Record quote char. If in completion
8129 mode, don't throw.
8130 (linespec_lexer_consume_token): Advance the completion word point.
8131 (linespec_lexer_peek_token): Save/restore completion info.
8132 (save_stream_and_consume_token): New.
8133 (set_completion_after_number): New.
8134 (linespec_parse_basic): Set what to complete next depending on
8135 token. Handle function and label completions specially.
8136 (parse_linespec): Disable objc shortcut in completion mode. Set
8137 what to complete next depending on token type. Skip keyword if in
8138 completion mode.
8139 (complete_linespec_component, linespec_complete): New.
8140 * linespec.h (linespec_complete): Declare.
8141
be966d42
PA
81422017-07-17 Pedro Alves <palves@redhat.com>
8143
8144 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
8145 Handle 'operator<' / 'operator<<'.
8146
a2459270
PA
81472017-07-17 Pedro Alves <palves@redhat.com>
8148
8149 * completer.c (collect_explicit_location_matches): Handle
8150 MATCH_LABEL.
8151 (convert_explicit_location_to_linespec): New, factored out from
8152 ...
8153 (convert_explicit_location_to_sals): ... this.
8154 (complete_label): New.
8155 (linespec_complete_label, find_label_symbols_in_block): New.
8156 (find_label_symbols): Add completion_mode parameter and adjust to
8157 call find_label_symbols_in_block.
8158 * linespec.h (linespec_complete_label): Declare.
8159
c6756f62
PA
81602017-07-17 Pedro Alves <palves@redhat.com>
8161
8162 * ada-lang.c (ada_collect_symbol_completion_matches): Add
8163 complete_symbol_mode parameter.
8164 * cli/cli-cmds.c (complete_command): Get the completion result out
8165 of the handle_brkchars tracker if used a custom word point.
8166 * completer.c: Include "linespec.h".
8167 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
8168 (advance_to_expression_complete_word_point): New.
8169 (completion_tracker::completes_to_completion_word): New.
8170 (complete_files_symbols): Pass down
8171 complete_symbol_mode::EXPRESSION.
8172 (explicit_options, probe_options): New.
8173 (collect_explicit_location_matches): Complete on the
8174 explictit_loc->foo instead of word. Use
8175 linespec_complete_function. Handle MATCH_LINE. Handle offering
8176 keyword and options completions.
8177 (backup_text_ptr): Delete.
8178 (skip_keyword): New.
8179 (complete_explicit_location): Remove 'word' parameter. Add
8180 language, quoted_arg_start and quoted_arg_end parameters.
8181 Rewrite, parsing left to right.
8182 (location_completer): Rewrite.
8183 (location_completer_handle_brkchars): New function.
8184 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
8185 (enum complete_line_internal_reason): Adjust comments.
8186 (completion_tracker::discard_completions): New.
8187 (completer_handle_brkchars_func_for_completer): Handle
8188 location_completer.
8189 (gdb_custom_word_point_brkchars)
8190 (gdb_org_rl_basic_quote_characters): New.
8191 (gdb_completion_word_break_characters_throw)
8192 (completion_find_completion_word): Handle trackers that use a
8193 custom word point.
8194 (completion_tracker::advance_custom_word_point_by): New.
8195 (completion_tracker::build_completion_result): Don't rely on
8196 readline appending the quote char.
8197 (gdb_rl_attempted_completion_function_throw): Handle trackers that
8198 use a custom word point.
8199 (gdb_rl_attempted_completion_function): Restore
8200 rl_basic_quote_characters.
8201 * completer.h (class completion_tracker): Extend intro comment.
8202 (completion_tracker::set_quote_char)
8203 (completion_tracker::quote_char)
8204 (completion_tracker::set_use_custom_word_point)
8205 (completion_tracker::use_custom_word_point)
8206 (completion_tracker::custom_word_point)
8207 (completion_tracker::set_custom_word_point)
8208 (completion_tracker::advance_custom_word_point_by)
8209 (completion_tracker::completes_to_completion_word)
8210 (completion_tracker::discard_completions): New methods.
8211 (completion_tracker::m_quote_char)
8212 (completion_tracker::m_use_custom_word_point)
8213 (completion_tracker::m_custom_word_point): New fields.
8214 (advance_to_expression_complete_word_point): Declare.
8215 * f-lang.c (f_collect_symbol_completion_matches): Add
8216 complete_symbol_mode parameter.
8217 * language.h (struct language_defn)
8218 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
8219 parameter.
8220 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
8221 (linespec_complete_function): New function.
8222 (linespec_lexer_lex_keyword): Adjust.
8223 * linespec.h (linespec_keywords, linespec_complete_function): New
8224 declarations.
8225 * location.c (find_end_quote): New function.
8226 (explicit_location_lex_one): Add explicit_completion_info
8227 parameter. Save quoting info. Don't throw if being called for
8228 completion. Don't handle Ada operators here.
8229 (is_cp_operator, skip_op_false_positives, first_of)
8230 (explicit_location_lex_one_function): New function.
8231 (string_to_explicit_location): Replace 'dont_throw' parameter with
8232 an explicit_completion_info pointer parameter. Handle it. Don't
8233 use explicit_location_lex_one to lex function names. Use
8234 explicit_location_lex_one_function instead.
8235 * location.h (struct explicit_completion_info): New.
8236 (string_to_explicit_location): Replace 'dont_throw' parameter with
8237 an explicit_completion_info pointer parameter.
8238 * symtab.c (default_collect_symbol_completion_matches_break_on):
8239 Add complete_symbol_mode parameter. Handle LINESPEC mode.
8240 (default_collect_symbol_completion_matches)
8241 (collect_symbol_completion_matches): Add complete_symbol_mode
8242 parameter.
8243 (collect_symbol_completion_matches_type): Pass down
8244 complete_symbol_mode::EXPRESSION.
8245 (collect_file_symbol_completion_matches): Add complete_symbol_mode
8246 parameter. Handle LINESPEC mode.
8247 * symtab.h (complete_symbol_mode): New.
8248 (default_collect_symbol_completion_matches_break_on)
8249 (default_collect_symbol_completion_matches)
8250 (collect_symbol_completion_matches)
8251 (collect_file_symbol_completion_matches): Add complete_symbol_mode
8252 parameter.
8253
1d550c82
PA
82542017-07-17 Pedro Alves <palves@redhat.com>
8255
8256 * utils.c (enum class strncmp_iw_mode): New.
8257 (strcmp_iw): Rename to ...
8258 (strncmp_iw_with_mode): ... this. Add string2_len and mode
8259 parameters. Handle them.
8260 (strncmp_iw): New.
8261 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
8262 * utils.h (strncmp_iw): Declare.
8263 (strcmp_iw): Move describing comments here.
8264
8090b426
PA
82652017-07-17 Pedro Alves <palves@redhat.com>
8266
8267 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
8268 CP_OPERATOR_STR.
8269 * c-typeprint.c (is_type_conversion_operator): Use
8270 CP_OPERATOR_STR.
8271 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
8272 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
8273 CP_OPERATOR_LEN.
8274 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
8275 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
8276 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
8277 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
8278 CP_OPERATOR_STR.
8279 * location.c: Include "cp-support.h".
8280 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
8281 CP_OPERATOR_STR.
8282 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
8283 CP_OPERATOR_LEN.
8284
6a2c1b87
PA
82852017-07-17 Pedro Alves <palves@redhat.com>
8286
8287 * cli/cli-cmds.c (complete_command): Use a completion tracker
8288 along with completion_find_completion_word for handle_brkchars
8289 phase.
8290 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
8291 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
8292 (struct gdb_rl_completion_word_info): New.
8293 (gdb_rl_find_completion_word): New.
8294 (completion_find_completion_word): New.
8295 * completer.h (completion_find_completion_word): Declare.
8296
eb3ff9a5
PA
82972017-07-17 Pedro Alves <palves@redhat.com>
8298
8299 * ada-lang.c (symbol_completion_match): Adjust comments.
8300 (symbol_completion_add): Replace vector parameter with
8301 completion_tracker parameter. Use it.
8302 (ada_make_symbol_completion_list): Rename to...
8303 (ada_collect_symbol_completion_matches): ... this. Add
8304 completion_tracker parameter and use it.
8305 (ada_language_defn): Adjust.
8306 * break-catch-syscall.c (catch_syscall_completer): Adjust
8307 prototype and work with completion_tracker instead of VEC.
8308 * breakpoint.c (condition_completer): Adjust prototype and work
8309 with completion_tracker instead of VEC.
8310 * c-lang.c (c_language_defn, cplus_language_defn)
8311 (asm_language_defn, minimal_language_defn): Adjust to renames.
8312 * cli/cli-cmds.c (complete_command): Rework using
8313 completion_tracker. Catch exceptions when completing.
8314 * cli/cli-decode.c (integer_unlimited_completer)
8315 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
8316 with completion_tracker instead of VEC.
8317 * command.h (struct completion_tracker): Forward declare.
8318 (completer_ftype, completer_handle_brkchars_ftype): Change
8319 types.
8320 (complete_on_cmdlist, complete_on_enum): Adjust.
8321 * completer.c: Include <algorithm>.
8322 (struct gdb_completer_state): New.
8323 (current_completion): New global.
8324 (readline_line_completion_function): Delete.
8325 (noop_completer, filename_completer)
8326 (filename_completer_handle_brkchars, complete_files_symbols)
8327 (linespec_location_completer): Adjust to work with a
8328 completion_tracker instead of a VEC.
8329 (string_or_empty): New.
8330 (collect_explicit_location_matches): Adjust to work with a
8331 completion_tracker instead of a VEC.
8332 (explicit_location_completer): Rename to ...
8333 (complete_explicit_location): ... this and adjust to work with a
8334 completion_tracker instead of a VEC.
8335 (location_completer): Adjust to work with a completion_tracker
8336 instead of a VEC.
8337 (add_struct_fields): Adjust to work with a completion_list instead
8338 of VEC.
8339 (expression_completer): Rename to ...
8340 (complete_expression): ... this and adjust to work with a
8341 completion_tracker instead of a VEC. Use complete_files_symbols.
8342 (expression_completer): Reimplement on top of complete_expression.
8343 (symbol_completer): Adjust to work with a completion_tracker
8344 instead of a VEC.
8345 (enum complete_line_internal_reason): Add describing comments.
8346 (complete_line_internal_normal_command): Adjust to work with a
8347 completion_tracker instead of a VEC.
8348 (complete_line_internal): Rename to ...
8349 (complete_line_internal_1): ... this and adjust to work with a
8350 completion_tracker instead of a VEC. Assert TEXT is NULL in the
8351 handle_brkchars phase.
8352 (new_completion_tracker): Delete.
8353 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
8354 complete_line_internal_1.
8355 (free_completion_tracker): Delete.
8356 (INITIAL_COMPLETION_HTAB_SIZE): New.
8357 (completion_tracker::completion_tracker)
8358 (completion_tracker::~completion_tracker): New.
8359 (maybe_add_completion): Delete.
8360 (completion_tracker::maybe_add_completion)
8361 (completion_tracker::add_completion)
8362 (completion_tracker::add_completions): New.
8363 (throw_max_completions_reached_error): Delete.
8364 (complete_line): Adjust to work with a completion_tracker instead
8365 of a VEC. Don't create a completion_tracker_t or check for max
8366 completions here.
8367 (command_completer, command_completer_handle_brkchars)
8368 (signal_completer, reg_or_group_completer_1)
8369 (reg_or_group_completer, default_completer_handle_brkchars):
8370 Adjust to work with a completion_tracker.
8371 (gdb_completion_word_break_characters_throw): New.
8372 (gdb_completion_word_break_characters): Reimplement.
8373 (line_completion_function): Delete.
8374 (completion_tracker::recompute_lowest_common_denominator)
8375 (expand_preserving_ws)
8376 (completion_tracker::build_completion_result)
8377 (completion_result::completion_result)
8378 (completion_result::completion_result)
8379 (completion_result::~completion_result)
8380 (completion_result::completion_result)
8381 (completion_result::release_match_list, compare_cstrings)
8382 (completion_result::sort_match_list)
8383 (completion_result::reset_match_list)
8384 (gdb_rl_attempted_completion_function_throw)
8385 (gdb_rl_attempted_completion_function): New.
8386 * completer.h (completion_list, struct completion_result)
8387 (class completion_tracker): New.
8388 (complete_line): Add completion_tracker parameter.
8389 (readline_line_completion_function): Delete.
8390 (gdb_rl_attempted_completion_function): New.
8391 (noop_completer, filename_completer, expression_completer)
8392 (location_completer, symbol_completer, command_completer)
8393 (signal_completer, reg_or_group_completer): Update prototypes.
8394 (completion_tracker_t, new_completion_tracker)
8395 (make_cleanup_free_completion_tracker): Delete.
8396 (enum maybe_add_completion_enum): Delete.
8397 (maybe_add_completion): Delete.
8398 (throw_max_completions_reached_error): Delete.
8399 * corefile.c (complete_set_gnutarget): Adjust to work with a
8400 completion_tracker instead of a VEC.
8401 * cp-abi.c (cp_abi_completer): Adjust to work with a
8402 completion_tracker instead of a VEC.
8403 * d-lang.c (d_language_defn): Adjust.
8404 * disasm.c (disassembler_options_completer): Adjust to work with a
8405 completion_tracker instead of a VEC.
8406 * f-lang.c (f_make_symbol_completion_list): Rename to ...
8407 (f_collect_symbol_completion_matches): ... this. Adjust to work
8408 with a completion_tracker instead of a VEC.
8409 (f_language_defn): Adjust.
8410 * go-lang.c (go_language_defn): Adjust.
8411 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
8412 Adjust to work with a completion_tracker instead of a VEC.
8413 * infrun.c (handle_completer): Likewise.
8414 * interps.c (interpreter_completer): Likewise.
8415 * interps.h (interpreter_completer): Likewise.
8416 * language.c (unknown_language_defn, auto_language_defn)
8417 (local_language_defn): Adjust.
8418 * language.h (language_defn::la_make_symbol_completion_list):
8419 Rename to ...
8420 (language_defn::la_collect_symbol_completion_matches): ... this
8421 and adjust to work with a completion_tracker instead of a VEC.
8422 * m2-lang.c (m2_language_defn): Adjust.
8423 * objc-lang.c (objc_language_defn): Adjust.
8424 * opencl-lang.c (opencl_language_defn): Adjust.
8425 * p-lang.c (pascal_language_defn): Adjust.
8426 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
8427 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
8428 with a completion_tracker.
8429 * rust-lang.c (rust_language_defn): Adjust.
8430 * symtab.c (free_completion_list, do_free_completion_list)
8431 (return_val, completion_tracker): Delete.
8432 (completion_list_add_name, completion_list_add_symbol)
8433 (completion_list_add_msymbol, completion_list_objc_symbol)
8434 (completion_list_add_fields, add_symtab_completions): Add
8435 completion_tracker parameter and use it.
8436 (default_make_symbol_completion_list_break_on_1): Rename to...
8437 (default_collect_symbol_completion_matches_break_on): ... this.
8438 Add completion_tracker parameter and use it instead of allocating
8439 a completion tracker here.
8440 (default_make_symbol_completion_list_break_on): Delete old
8441 implementation.
8442 (default_make_symbol_completion_list): Delete.
8443 (default_collect_symbol_completion_matches): New.
8444 (make_symbol_completion_list): Delete.
8445 (collect_symbol_completion_matches): New.
8446 (make_symbol_completion_type): Rename to ...
8447 (collect_symbol_completion_matches_type): ... this. Add
8448 completion_tracker parameter and use it instead of VEC.
8449 (make_file_symbol_completion_list_1): Rename to...
8450 (collect_file_symbol_completion_matches): ... this. Add
8451 completion_tracker parameter and use it instead of VEC.
8452 (make_file_symbol_completion_list): Delete.
8453 (add_filename_to_list): Use completion_list instead of a VEC.
8454 (add_partial_filename_data::list): Now a completion_list.
8455 (make_source_files_completion_list): Work with a completion_list
8456 instead of a VEC.
8457 * symtab.h: Include "completer.h".
8458 (default_make_symbol_completion_list_break_on)
8459 (default_make_symbol_completion_list, make_symbol_completion_list)
8460 (make_symbol_completion_type, make_file_symbol_completion_list)
8461 (make_source_files_completion_list): Delete.
8462 (default_collect_symbol_completion_matches_break_on)
8463 (default_collect_symbol_completion_matches)
8464 (collect_symbol_completion_matches)
8465 (collect_symbol_completion_matches_type)
8466 (collect_file_symbol_completion_matches)
8467 (make_source_files_completion_list): New.
8468 * top.c (init_main): Don't install a rl_completion_entry_function
8469 hook. Install a rl_attempted_completion_function hook instead.
8470 * tui/tui-layout.c (layout_completer): Adjust to work with a
8471 completion_tracker.
8472 * tui/tui-regs.c (tui_reggroup_completer):
8473 * tui/tui-win.c (window_name_completer, focus_completer)
8474 (winheight_completer): Adjust to work with a completion_tracker.
8475 * value.c: Include "completer.h".
8476 (complete_internalvar): Adjust to work with a completion_tracker.
8477 * value.h (complete_internalvar): Likewise.
8478
6e1dbf8c
PA
84792017-07-17 Pedro Alves <palves@redhat.com>
8480
8481 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
8482 renames.
8483 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
8484 comments to completer_ftype's declaration.
8485 <completer_handle_brkchars>: Change type to
8486 completer_handle_brkchars_ftype.
8487 * command.h (completer_ftype): Add describing comment and give
8488 names to parameters.
8489 (completer_ftype_void): Rename to ...
8490 (completer_handle_brkchars_ftype) ... this. Add describing comment.
8491 (set_cmd_completer_handle_brkchars): Adjust.
8492 * completer.c (filename_completer_handle_brkchars): New function.
8493 (complete_line_internal_normal_command): New function, factored
8494 out from ...
8495 (complete_line_internal): ... here.
8496 (command_completer_handle_brkchars)
8497 (default_completer_handle_brkchars)
8498 (completer_handle_brkchars_func_for_completer): New functions.
8499 * completer.h (set_gdb_completion_word_break_characters): Delete
8500 declaration.
8501 (completer_handle_brkchars_func_for_completer): New declaration.
8502 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
8503 completer_handle_brkchars_func_for_completer.
8504
78b13106
PA
85052017-07-17 Pedro Alves <palves@redhat.com>
8506
8507 * completer.c (symbol_completer): New function, based on
8508 make_symbol_completion_list_fn.
8509 * completer.h (symbol_completer): New declaration.
8510 * guile/scm-cmd.c (cmdscm_completers): Adjust.
8511 * python/py-cmd.c (completers): Adjust.
8512 * symtab.c (make_symbol_completion_list_fn): Delete.
8513 * symtab.h (make_symbol_completion_list_fn): Delete.
8514 * cli/cli-decode.c (add_cmd): Adjust.
8515
bbf2f4df
PA
85162017-07-17 Pedro Alves <palves@redhat.com>
8517
8518 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
8519 * dwarf2read.c: Include "filename-seen-cache.h".
8520 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
8521 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
8522 * filename-seen-cache.c: New file.
8523 * filename-seen-cache.h: New file.
8524 * symtab.c: Include "filename-seen-cache.h".
8525 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
8526 (create_filename_seen_cache, clear_filename_seen_cache)
8527 (delete_filename_seen_cache, filename_seen): Delete, parts moved
8528 to filename-seen-cache.h/filename-seen-cache.c.
8529 (output_source_filename, sources_info)
8530 (maybe_add_partial_symtab_filename)
8531 (make_source_files_completion_list): Adjust to use
8532 filename_seen_cache.
8533
330cdd98
PA
85342017-07-17 Pedro Alves <palves@redhat.com>
8535
8536 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
8537 fields.
8538 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
8539 dwarf2_debug_sections*)): New.
8540 (dwarf2_per_objfile::dwarf2_per_objfile(const
8541 dwarf2_per_objfile&)): Declare as deleted.
8542 (dwarf2_per_objfile::operator=): Declare as deleted.
8543 (dwarf2_per_objfile::dwarf2_per_objfile)
8544 (dwarf2_per_objfile::~dwarf2_per_objfile)
8545 (dwarf2_per_objfile::free_cached_comp_units): New.
8546 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
8547 ctor. Call dwarf2_per_objfile's ctor manually.
8548 (dwarf2_locate_sections): Deleted/refactored as ...
8549 (dwarf2_per_objfile::locate_sections): ... this new method.
8550 (free_cached_comp_units): Defer to
8551 dwarf2_per_objfile::free_cached_comp_units.
8552 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
8553
8880f2a9
TT
85542017-07-14 Tom Tromey <tom@tromey.com>
8555
8556 PR rust/21764:
8557 * rust-exp.y (convert_ast_to_expression): Add "want_type"
8558 parameter.
8559 <UNOP_SIZEOF>: Split into separate case.
8560 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
8561
65547233
TT
85622017-07-14 Tom Tromey <tom@tromey.com>
8563
8564 PR rust/21763:
8565 * symtab.c (symbol_matches_domain): Add language_rust to special
8566 case.
8567 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
8568 treat LOC_TYPEDEF symbols as variables.
8569
8f14146e
PA
85702017-07-14 Pedro Alves <palves@redhat.com>
8571
8572 * symtab.c (make_file_symbol_completion_list_1): Iterate over
8573 symtabs matching all symtabs with SRCFILE as file name instead of
8574 only considering the first hit, with lookup_symtab.
8575
2347965c
SM
85762017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8577
8578 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
8579 operator_name parameters.
8580 (gen_expr): Update function call.
8581
40f4af28
SM
85822017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8583
8584 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
8585 parameter.
8586 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
8587 Likewise.
8588 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
8589 parameter, use agent_expr::gdbarch instead, update function
8590 calls.
8591 (locexpr_tracepoint_var_ref): Likewise.
8592 (loclist_tracepoint_var_ref): Likewise.
8593 * ax-gdb.c (gen_trace_static_fields): Likewise.
8594 (gen_traced_pop): Likewise.
8595 (gen_frame_args_address): Likewise.
8596 (gen_frame_locals_address): Likewise.
8597 (gen_var_ref): Likewise.
8598 (gen_struct_ref_recursive): Likewise.
8599 (gen_static_field): Likewise.
8600 (gen_maybe_namespace_elt): Likewise.
8601 (gen_expr): Likewise.
8602 (gen_trace_for_var): Likewise.
8603 (gen_trace_for_expr): Likewise.
8604 (gen_trace_for_return_address): Likewise.
8605
053f8057
SM
86062017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8607
8608 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
8609 parameter.
8610 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
8611
6661ad48
SM
86122017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8613
8614 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
8615 from ax, update calls.
8616 (gen_usual_arithmetic): Likewise.
8617 (gen_integral_promotions): Likewise.
8618 (gen_bitfield_ref): Likewise.
8619 (gen_primitive_field): Likewise.
8620 (gen_struct_ref_recursive): Likewise.
8621 (gen_struct_ref): Likewise.
8622 (gen_maybe_namespace_elt): Likewise.
8623 (gen_struct_elt_for_reference): Likewise.
8624 (gen_namespace_elt): Likewise.
8625 (gen_aggregate_elt_ref): Likewise.
8626 (gen_expr): Get gdbarch from ax, update calls.
8627 (gen_expr_binop_rest): Likewise.
8628
c55a47e7
PA
86292017-07-13 Pedro Alves <palves@redhat.com>
8630
8631 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
8632 as default tdesc.
8633 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
8634 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
8635 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
8636 tdesc_amd64_linux as default tdesc. Get final tdesc from the
8637 tdep.
8638 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
8639 Get final tdesc from the tdep.
8640 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
8641 default tdesc.
8642 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
8643 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
8644 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
8645 Use it as default tdesc.
8646 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
8647 down to amd_init_abi. No longer handle fallback tdesc here.
8648 * amd64-tdep.h (tdesc_x32): Declare.
8649 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
8650 parameter.
8651 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
8652 as default tdesc.
8653
55efceab
AA
86542017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8655
8656 * s390-linux-tdep.c (s390_process_record): Add support for
8657 instructions new in arch12.
8658
0aa37b65
JB
86592017-07-11 John Baldwin <jhb@FreeBSD.org>
8660
8661 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
8662 PT_GETFSBASE and PT_GETGSBASE.
8663 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
8664 PT_SETGSBASE.
8665
48aeef91
JB
86662017-07-11 John Baldwin <jhb@FreeBSD.org>
8667
8668 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
8669 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
8670 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
8671 those rules.
8672 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
8673 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
8674 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
8675 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
8676 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
8677 * features/i386/amd64.xml: Add 64bit-segments.xml.
8678 * features/i386/amd64-avx-avx512.c: Regenerated.
8679 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
8680 * features/i386/amd64-avx-mpx.c: Regenerated.
8681 * features/i386/amd64-avx.c: Regenerated.
8682 * features/i386/amd64-mpx.c: Regenerated.
8683 * features/i386/amd64.c: Regenerated.
8684 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
8685 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
8686 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
8687 * regformats/i386/amd64-avx.dat: Regenerated.
8688 * regformats/i386/amd64-mpx.dat: Regenerated.
8689 * regformats/i386/amd64.dat: Regenerated.
8690
77c501bc
YQ
86912017-07-10 Yao Qi <yao.qi@linaro.org>
8692
8693 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
8694 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
8695
6dc8d757
AK
86962017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
8697
8698 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
8699 unsetenv.
8700 * gnulib/aclocal.m4: Regenerate.
8701 * gnulib/config.in: Regenerate.
8702 * gnulib/configure: Regenerate.
8703 * gnulib/import/Makefile.am: Regenerate.
8704 * gnulib/import/Makefile.in: Regenerate.
8705 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
8706 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
8707 * gnulib/import/m4/environ.m4: New file.
8708 * gnulib/import/m4/setenv.m4: New file.
8709 * gnulib/import/setenv.c: New file.
8710 * gnulib/import/unsetenv.c: New file.
8711
266934d1
SM
87122017-07-09 Simon Marchi <simon.marchi@ericsson.com>
8713
8714 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
8715 address when op is DW_OP_addr.
8716
03278692
TT
87172017-07-09 Tom Tromey <tom@tromey.com>
8718
8719 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
8720 check and apply to outer type.
8721
4b654465
JB
87222017-07-07 John Baldwin <jhb@FreeBSD.org>
8723
8724 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
8725 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
8726 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
8727 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
8728
2af9fc44
JB
87292017-07-07 John Baldwin <jhb@FreeBSD.org>
8730
8731 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
8732
382b69bb
JB
87332017-07-07 John Baldwin <jhb@FreeBSD.org>
8734
8735 * corelow.c (get_core_siginfo): Remove.
8736 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
8737 instead of get_core_siginfo.
8738 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
8739 * gdbarch.h: Re-generate.
8740 * gdbarch.c: Re-generate.
8741 * linux-tdep.c (linux_core_xfer_siginfo): New.
8742 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
8743
6e5eab33
JB
87442017-07-07 John Baldwin <jhb@FreeBSD.org>
8745
8746 * corelow.c (thread_section_name): Move to ...
8747 * gdbcore.h (thread_section_name): ... here.
8748
929edea9
JB
87492017-07-07 John Baldwin <jhb@FreeBSD.org>
8750
8751 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
8752 (struct siginfo32): New.
8753 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
8754 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
8755 via ptrace(PT_LWPINFO).
8756
762c974a
JB
87572017-07-07 John Baldwin <jhb@FreeBSD.org>
8758
8759 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
8760 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
8761 (fbsd_get_siginfo_type): New.
8762 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
8763 (_initialize_fbsd_tdep): New.
8764
33c5cd75
DB
87652017-07-06 David Blaikie <dblaikie@gmail.com>
8766
8767 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
8768 a singular dwo_unit*) to support multiple CUs in the same way that
8769 multiple TUs are supported.
8770 (create_cus_hash_table): Replace create_dwo_cu with a function for
8771 parsing multiple CUs from a DWO file.
8772 (open_and_init_dwo_file): Use create_cus_hash_table rather than
8773 create_dwo_cu.
8774 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
8775 htab_find, rather than comparing the signature to a singleton CU in
8776 the dwo_file.
8777
8455d262
PA
87782017-07-06 Pedro Alves <palves@redhat.com>
8779
8780 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
8781
4da3eb35
PA
87822017-07-04 Pedro Alves <palves@redhat.com>
8783
8784 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
8785 * gdbtypes.h (TYPE_STATIC): Delete.
8786 (struct fn_field) <is_public, is_abstract, is_static, is_final,
8787 is_synchronized, is_native>: Delete.
8788 <dummy>: Bump.
8789 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
8790 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
8791 (TYPE_FN_FIELD_ABSTRACT): Delete.
8792
5bfd255c
SM
87932017-07-03 Simon Marchi <simon.marchi@ericsson.com>
8794
8795 * buffer.h (buffer_finish): Fix spelling mistakes.
8796
25c54127
EZ
87972017-07-01 Eli Zaretskii <eliz@gnu.org>
8798
8799 * .dir-locals.el: Automatically switch to C-style comments in
8800 versions of Emacs that support the feature.
8801
dc4bde35
SDJ
88022017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
8803 Pedro Alves <palves@redhat.com>
8804
8805 PR cli/21688
8806 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
8807 (process_next_line): New variable 'inline_cmd'.
8808 Adjust 'if' clauses for "python", "compile" and "guile" to use
8809 'command_name_equals' and check for '!inline_cmd'.
8810
51ed89aa
SDJ
88112017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
8812
8813 PR cli/21688
8814 * cli/cli-script.c (command_name_equals_not_inline): New function.
8815 (process_next_line): Adjust 'if' clauses for "python", "compile"
8816 and "guile" to use command_name_equals_not_inline.
8817
eb17d413
PA
88182017-06-29 Pedro Alves <palves@redhat.com>
8819
8820 * completer.c (expression_completer): Call
8821 linespec_location_completer instead of location_completer.
8822
195bcdd5
PA
88232017-06-29 Pedro Alves <palves@redhat.com>
8824
8825 * completer.c (expression_completer): Remove code that recomputes
8826 'text' from 'word'.
8827
adc764e7
YQ
88282017-06-29 Yao Qi <yao.qi@linaro.org>
8829
8830 * regformats/regdat.sh: Generate code with
8831 "ifndef IN_PROCESS_AGENT".
8832
6e75794e
PA
88332017-06-28 Pedro Alves <palves@redhat.com>
8834
8835 * command.h: Include "common/scoped_restore.h".
8836
bc491f2e
YQ
88372017-06-28 Yao Qi <yao.qi@linaro.org>
8838
8839 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
8840 instead of obstack_grow.
8841
41664b45
DG
88422017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
8843
8844 PR gdb/21337
8845 * symfile.c (reread_symbols): Call objfiles_changed just before
8846 read_symbols.
8847
6da67eb1
PA
88482017-06-27 Pedro Alves <palves@redhat.com>
8849
8850 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
8851 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
8852 (completion_list_add_symbol, completion_list_add_msymbol):
8853 ... these new functions.
8854 (add_symtab_completions)
8855 (default_make_symbol_completion_list_break_on_1): Adjust.
8856
23732b1e
PA
88572017-06-27 Pedro Alves <palves@redhat.com>
8858
8859 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
8860 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
8861 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
8862 dtor.
8863 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
8864 'storage_obstack' field an auto_obstack. In-class initialize all
8865 non-bitfield fields. Make minsyms_read bool.
8866 * symfile.c (read_symbols): Adjust.
8867
a4d1e79a
AH
88682017-06-27 Alan Hayward <alan.hayward@arm.com>
8869
8870 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
8871 (gdbsim_store_register): Likewise.
8872
8268c778
PA
88732017-06-27 Pedro Alves <palves@redhat.com>
8874
8875 * c-exp.y (name_obstack): Now an auto_obstack.
8876 (yylex): Use auto_obstack::clear.
8877 (c_parse): Use auto_obstack::clear instead of reinitializing and
8878 freeing the obstack.
8879 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
8880 * d-exp.y (name_obstack): Now an auto_obstack.
8881 (yylex): Use auto_obstack::clear.
8882 (d_parse): Use auto_obstack::clear instead of reinitializing and
8883 freeing the obstack.
8884 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
8885 auto_obstack.
8886 * dwarf2read.c (create_addrmap_from_index)
8887 (dwarf2_build_psymtabs_hard)
8888 (update_enumeration_type_from_children): Likewise.
8889 * gdb_obstack.h (auto_obstack): New type.
8890 * go-exp.y (name_obstack): Now an auto_obstack.
8891 (build_packaged_name): Use auto_obstack::clear.
8892 (go_parse): Use auto_obstack::clear instead of reinitializing and
8893 freeing the obstack.
8894 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
8895 auto_obstack.
8896 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
8897 * rust-exp.y (work_obstack): Now an auto_obstack.
8898 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
8899 reinitializing and freeing the obstack.
8900 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
8901 (host_char_to_target): Use auto_obstack.
8902 * utils.h (make_cleanup_obstack_free): Delete declaration.
8903 * valprint.c (generic_emit_char, generic_printstr): Use
8904 auto_obstack.
8905
db665f42
SM
89062017-06-27 Simon Marchi <simon.marchi@ericsson.com>
8907
8908 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
8909 thread.
8910 (darwin_init_thread_list): Don't update dummy thread.
8911 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
8912
873c0814
SM
89132017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8914
8915 * record-full.c (netorder16): Remove.
8916
8b5a7a6e
SM
89172017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8918
8919 * common/diagnostics.h: Define macros for GCC.
8920 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
8921 * common/vec.h: Include diagnostics.h.
8922 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
8923 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
8924 warning.
8925
d1435379
SM
89262017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8927
8928 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
8929 New macro.
8930 * ada-lex.l: Ignore deprecated register warnings.
8931
cc75e0fd
SM
89322017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8933
8934 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
8935 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
8936
07809eaf
SM
89372017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8938
8939 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
8940 its own line.
8941
f076f034
SM
89422017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8943
8944 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
8945
0dd5cbc5
AH
89462017-06-23 Alan Hayward <alan.hayward@arm.com>
8947
8948 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
8949 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
8950 (xtensa_register_read_masked): Likewise.
8951
d4c6ce5b
SDJ
89522017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
8953
8954 * common/environ.c (gdb_environ::unset): Update comment.
8955
16892a03
AH
89562017-06-22 Alan Hayward <alan.hayward@arm.com>
8957
8958 * python/py-unwind.c (pyuw_sniffer): Allocate space for
8959 registers.
8960
d7dcbefc
AH
89612017-06-22 Alan Hayward <alan.hayward@arm.com>
8962
8963 * record-full.c (record_full_exec_insn): Use byte_vector.
8964
b30ff123
YQ
89652017-06-22 Yao Qi <yao.qi@linaro.org>
8966
8967 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
8968 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
8969
4fa847d7
AH
89702017-06-22 Alan Hayward <alan.hayward@arm.com>
8971
8972 * remote.c (cached_reg): Move from here...
8973 * regcache.h (cached_reg): ...to here.
8974 * python/py-unwind.c (struct reg_info): Remove.
8975 (cached_frame_info): Use cached_reg_t.
8976 (pyuw_prev_register): Likewise.
8977 (pyuw_sniffer): Use cached_reg_t and allocate registers.
8978 (pyuw_dealloc_cache): Free all registers.
8979
f4906a9a
PA
89802017-06-22 Pedro Alves <palves@redhat.com>
8981 Simon Marchi <simon.marchi@ericsson.com>
8982
8983 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
8984 warning.
8985 * common/diagnostics.h: New file.
8986
b45a1208
PA
89872017-06-22 Pedro Alves <palves@redhat.com>
8988
8989 * common/agent.h: Add include guards.
8990
e4da2c61
SM
89912017-06-21 Simon Marchi <simon.marchi@ericsson.com>
8992
8993 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
8994 talk about addressable units instead of bytes.
8995
96160d60
SDJ
89962017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
8997
8998 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
8999 of '::const_iterator'.
9000
9a6c7d9c
SDJ
90012017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
9002
9003 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9004 'unittests/environ-selftests.c'.
9005 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
9006 * charset.c (find_charset_names): Declare object 'iconv_env'.
9007 Update code to use 'iconv_env' object. Remove call to
9008 'free_environ'.
9009 * common/environ.c: Include <utility>.
9010 (make_environ): Delete function.
9011 (free_environ): Delete function.
9012 (gdb_environ::clear): New function.
9013 (gdb_environ::operator=): New function.
9014 (gdb_environ::get): Likewise.
9015 (environ_vector): Delete function.
9016 (set_in_environ): Delete function.
9017 (gdb_environ::set): New function.
9018 (unset_in_environ): Delete function.
9019 (gdb_environ::unset): New function.
9020 (gdb_environ::envp): Likewise.
9021 * common/environ.h: Include <vector>.
9022 (struct gdb_environ): Delete; transform into...
9023 (class gdb_environ): ... this class.
9024 (free_environ): Delete prototype.
9025 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
9026 environ_vector): Likewise.
9027 * infcmd.c (run_command_1): Update code to call
9028 'envp' from 'gdb_environ' class.
9029 (environment_info): Update code to call methods from 'gdb_environ'
9030 class.
9031 (unset_environment_command): Likewise.
9032 (path_info): Likewise.
9033 (path_command): Likewise.
9034 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
9035 (inferior::inferior): Initialize 'environment' using the host's
9036 information.
9037 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
9038 Include "environ.h".
9039 (class inferior) <environment>: Change type from 'struct
9040 gdb_environ' to 'gdb_environ'.
9041 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
9042 methods from 'gdb_environ' class.
9043 * solib.c (solib_find_1): Likewise
9044 * unittests/environ-selftests.c: New file.
9045
75c554cf
YQ
90462017-06-20 Yao Qi <yao.qi@linaro.org>
9047
9048 * features/i386/i386-linux.xml: Exchange the order of including
9049 32bit-linux.xml and 32bit-sse.xml.
9050 * features/i386/i386-linux.c: Regenerated.
9051
72ddacb7
YQ
90522017-06-20 Yao Qi <yao.qi@linaro.org>
9053
9054 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
9055 Delete copy ctor and assignment operator.
9056 (tdesc_type): Likewise.
9057 (tdesc_feature): Likewise.
9058 (tdesc_free_reg): Remove.
9059 (tdesc_create_reg): Use new.
9060 (tdesc_free_type): Remove.
9061 (tdesc_create_vector): Use new.
9062 (tdesc_create_union): Likewise.
9063 (tdesc_create_flags): Likewise.
9064 (tdesc_create_enum): Likewise.
9065 (tdesc_free_feature): Delete.
9066 (free_target_description): Use delete.
9067
325c9fd4
JB
90682017-06-19 John Baldwin <jhb@FreeBSD.org>
9069
9070 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
9071 registers.
9072
16b7a719
PA
90732017-06-19 Pedro Alves <palves@redhat.com>
9074
9075 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
9076 after gdb::unlinker.
9077
1c8e01c9
SDJ
90782017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
9079
9080 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
9081 gdb_environ to access an environment variable.
9082
ffce45d2
TP
90832017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
9084
9085 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
9086 gdb_byte*.
9087
1d4fbac9
SM
90882017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9089
9090 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
9091
8465943a
SM
90922017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9093
9094 * configure: Re-generate.
9095 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
9096
3e019bdc
SM
90972017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9098
9099 * configure: Re-generate.
9100 * warning.m4: Pass -Werror to compiler when checking for
9101 supported warning flags.
9102
cf0dd6f0
SM
91032017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9104
9105 * Makefile.in (COMPILE.pre): Add "-x c++".
9106
6f98355c
YQ
91072017-06-16 Alan Hayward <alan.hayward@arm.com>
9108 Pedro Alves <palves@redhat.com>
9109 Yao Qi <yao.qi@linaro.org>
9110
9111 * defs.h (RequireLongest): New.
9112 (extract_integer): Declare function template.
9113 (extract_signed_integer): Remove the declaration, but define it
9114 static inline.
9115 (extract_unsigned_integer): Likewise.
9116 (store_integer): Declare function template.
9117 (store_signed_integer): Remove the declaration, but define it
9118 static inline.
9119 (store_unsigned_integer): Likewise.
9120 * findvar.c (extract_integer): New function template.
9121 (extract_signed_integer): Remove.
9122 (extract_unsigned_integer): Remove.
9123 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
9124 instantiations.
9125 (store_integer): New function template.
9126 (store_signed_integer): Remove.
9127 (store_unsigned_integer): Remove.
9128 (store_integer): Explicit instantiations.
9129 * regcache.c (regcache_raw_read_signed): Update.
9130 (regcache::raw_read): New function.
9131 (regcache::raw_read_signed): Remove.
9132 (regcache::raw_read_unsigned): Remove.
9133 (regcache_raw_read_unsigned): Update.
9134 (regcache_raw_write_unsigned): Update.
9135 (regcache::raw_write_signed): Remove.
9136 (regcache::raw_write): New function.
9137 (regcache_cooked_read_signed): Update.
9138 (regcache::raw_write_unsigned): Remove.
9139 (regcache::cooked_read_signed): Remove.
9140 (regcache_cooked_read_unsigned): Update.
9141 (regcache::cooked_read_unsigned): Remove.
9142 (regcache_cooked_write_signed): Update.
9143 (regcache_cooked_write_unsigned): Update.
9144 * regcache.h (regcache) <raw_read_signed>: Remove.
9145 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
9146 <raw_read, raw_write>: New.
9147 <cooked_read_signed, cooked_write_signed>: Remove.
9148 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
9149 <cooked_read, cooked_write>: New.
9150 * sh64-tdep.c (sh64_pseudo_register_read): Update.
9151 (sh64_pseudo_register_write): Update.
9152
a87dc45a
AK
91532017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
9154
9155 * arc-tdep.c (arc_disassembler_options): New variable.
9156 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
9157 of default_print_insn.
9158 (arc_delayed_print_insn): Set info->section when needed,
9159 use default_print_insn to retrieve a disassembler.
9160
45159d6a
SDJ
91612017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
9162
9163 PR gdb/21574
9164 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
9165 to mention $SHELL and startup-with-shell.
9166
b46c4cf0
MF
91672017-06-14 Max Filippov <jcmvbkbc@gmail.com>
9168
9169 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
9170
6394c606
YQ
91712017-06-14 Yao Qi <yao.qi@linaro.org>
9172
9173 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
9174 default_print_insn instead of print_insn_aarch64.
9175 * arm-tdep.c (gdb_print_insn_arm): Call
9176 default_print_insn instead of print_insn_big_arm
9177 and print_insn_little_arm.
9178 * i386-tdep.c (i386_print_insn): Call default_print_insn
9179 instead of print_insn_i386.
9180 * ia64-tdep.c (ia64_print_insn): Call
9181 default_print_insn instead of print_insn_ia64.
9182 * mips-tdep.c (gdb_print_insn_mips): Call
9183 default_print_insn instead of print_insn_big_mips
9184 and print_insn_little_mips.
9185 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
9186 instead of print_insn_spu.
9187
d5722aa2
PA
91882017-06-14 Pedro Alves <palves@redhat.com>
9189
9190 * ada-lang.c: Include "common/byte-vector.h".
9191 (ada_value_primitive_packed_val): Use gdb::byte_vector.
9192 * charset.c (wchar_iterator::iterate): Resize the vector instead
9193 of reserving it.
9194 * common/byte-vector.h: Include "common/def-vector.h".
9195 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
9196 * cli/cli-dump.c: Include "common/byte-vector.h".
9197 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
9198 * common/byte-vector.h: New file.
9199 * common/def-vector.h: New file.
9200 * common/default-init-alloc.h: New file.
9201 * dwarf2loc.c: Include "common/byte-vector.h".
9202 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
9203 instead of reserving it.
9204 * dwarf2read.c: Include "common/byte-vector.h".
9205 (data_buf::m_vec): Now a gdb::byte_vector.
9206 * gdb_regex.c: Include "common/def-vector.h".
9207 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
9208 * mi/mi-main.c: Include "common/byte-vector.h".
9209 (mi_cmd_data_read_memory): Use gdb::byte_vector.
9210 * printcmd.c: Include "common/byte-vector.h".
9211 (print_scalar_formatted): Use gdb::byte_vector.
9212 * valprint.c: Include "common/byte-vector.h".
9213 (maybe_negate_by_bytes, print_decimal_chars): Use
9214 gdb::byte_vector.
9215
01ec7a27
SM
92162017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9217
9218 * darwin-nat.c: Include "nat/fork-inferior.h".
9219
848d9074
SM
92202017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9221
9222 * configure.nat: Factor out Darwin bits that are not
9223 architecture-specific. Add fork-inferior.o.
9224
3b912944
SM
92252017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9226
9227 * configure.nat: Factor out AIX bits that are not
9228 architecture-specific. Add fork-inferior.o.
9229
55acdf22
AA
92302017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9231
9232 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
9233 (read_pieced_value, write_pieced_value): ...here. Reduce to
9234 wrappers that just call rw_pieced_value.
9235
f65e2044
AA
92362017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9237
9238 * dwarf2loc.c (write_pieced_value): When writing the data for a
9239 memory piece, use write_memory_with_notification instead of
9240 write_memory.
9241
23f945bf
AA
92422017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9243
9244 * valops.c (read_value_memory): Change embedded_offset to
9245 represent a bit offset instead of a byte offset.
9246 * value.h (read_value_memory): Adjust comment.
9247
f236533e
AA
92482017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9249
9250 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
9251 dest_offset_bits and source_offset_bits.
9252 (write_pieced_value): Likewise.
9253
65d84b76
AA
92542017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9255
9256 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
9257 given by DW_OP_bit_piece.
9258 (write_pieced_value): Likewise.
9259
242d31ab
AA
92602017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9261
9262 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
9263 some other preparations to the places where sufficient information
9264 is available.
9265 (write_pieced_value): Likewise.
9266
03c8af18
AA
92672017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9268
9269 * dwarf2loc.c (bits_to_bytes): New function.
9270 (read_pieced_value): Fix offset calculations for register pieces
9271 on big-endian targets.
9272 (write_pieced_value): Likewise.
9273
840989c1
AA
92742017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9275
9276 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
9277 (write_pieced_value): Likewise.
9278
359b19bb
AA
92792017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9280
9281 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
9282 transfer the source value's least significant bits, instead of its
9283 lowest-addressed ones. Rename type_len to max_offset.
9284 (read_pieced_value): Mirror above changes to write_pieced_value as
9285 applicable.
9286
07c9ca3b
AA
92872017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9288
9289 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
9290 truncate full bytes from dest_offset_bits before using it as an
9291 offset into the buffer.
9292
f1cc9874
AA
92932017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9294
9295 * dwarf2loc.c (write_pieced_value): Include transfer size in
9296 byte-wise check.
9297
cdaac320
AA
92982017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9299
9300 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
9301 calculation of this_size.
9302
af547a96
AA
93032017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9304
9305 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
9306 when targeting a bit-field.
9307 (write_pieced_value): Likewise.
9308
ddd7882a
AA
93092017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9310
9311 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
9312 (allocate_piece_closure): Drop addr_size parameter.
9313 (dwarf2_evaluate_loc_desc_full): Adjust call to
9314 allocate_piece_closure.
9315
e9352324
AA
93162017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9317
9318 PR gdb/21226
9319 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
9320 the LSB end, independent of endianness.
9321
d5d1163e
AA
93222017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9323
9324 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
9325 size capping.
9326
032bb6ea
YQ
93272017-06-13 Yao Qi <yao.qi@linaro.org>
9328
9329 * mips-linux-nat.c: Move include features/mips*-linux.c to
9330 mips-linux-tdep.c.
9331 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
9332 to mips-linux-tdep.c.
9333 * mips-linux-tdep.c: Include features/mips*-linux.c
9334 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
9335 functions.
9336 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
9337 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
9338 (tdesc_mips64_dsp_linux): Declare.
9339
f12f6bad
TT
93402017-06-12 Tom Tromey <tom@tromey.com>
9341
9342 * valprint.h (val_print_type_code_int): Remove.
9343 * valprint.c (generic_val_print_int): Always call
9344 val_print_scalar_formatted.
9345 (val_print_type_code_int): Remove.
9346 * printcmd.c (print_scalar_formatted): Handle options->format==0.
9347 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
9348 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
9349 * ada-valprint.c (ada_val_print_num): Use
9350 val_print_scalar_formatted.
9351
d9109c80
TT
93522017-06-12 Tom Tromey <tom@tromey.com>
9353
9354 * printcmd.c (print_scalar_formatted): Unify the two switches.
9355 Don't convert scalars to LONGEST.
9356
4ac0cb1c
TT
93572017-06-12 Tom Tromey <tom@tromey.com>
9358
9359 PR exp/16225:
9360 * valprint.h (print_decimal_chars): Update.
9361 * valprint.c (maybe_negate_by_bytes): New function.
9362 (print_decimal_chars): Add "is_signed" argument.
9363 * printcmd.c (print_scalar_formatted): Update.
9364
30a25466
TT
93652017-06-12 Tom Tromey <tom@tromey.com>
9366
9367 PR exp/16225:
9368 * valprint.h (print_binary_chars, print_hex_chars): Update.
9369 * valprint.c (val_print_type_code_int): Update.
9370 (print_binary_chars): Add "zero_pad" argument.
9371 (emit_octal_digit): New function.
9372 (print_octal_chars): Don't zero-pad.
9373 (print_decimal_chars): Likewise.
9374 (print_hex_chars): Add "zero_pad" argument.
9375 * sh64-tdep.c (sh64_do_fp_register): Update.
9376 * regcache.c (regcache::dump): Update.
9377 * printcmd.c (print_scalar_formatted): Update.
9378 * infcmd.c (default_print_one_register_info): Update.
9379
b3464d03
PA
93802017-06-12 Pedro Alves <palves@redhat.com>
9381 Alan Hayward <alan.hayward@arm.com>
9382
9383 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
9384 (mips_eabi_push_dummy_call): Rename local 'regsize' to
9385 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
9386 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
9387 Assert that abi_regsize bytes fit in 'ref_valbuf'.
9388
4b76cda9
PA
93892017-06-12 Pedro Alves <palves@redhat.com>
9390
9391 * dwarf2read.c (mapped_symtab::data): Now a vector of
9392 symtab_index_entry instead of vector of
9393 std::unique_ptr<symtab_index_entry>. All users adjusted to check
9394 whether an element's name is NULL instead of checking whether the
9395 element itself is NULL.
9396 (find_slot): Change return type. Adjust.
9397 (hash_expand, , add_index_entry, uniquify_cu_indices)
9398 (write_hash_table): Adjust.
9399
e8f8bcb3
PA
94002017-06-12 Pedro Alves <palves@redhat.com>
9401
9402 * dwarf2read.c (recursively_count_psymbols): New function.
9403 (write_psymtabs_to_index): Call it to compute number of psyms and
9404 pass estimate size of psyms_seen to unordered_set's ctor.
9405
70a1152b
PA
94062017-06-12 Pedro Alves <palves@redhat.com>
9407
9408 * dwarf2read.c (write_hash_table): Check if key already exists
9409 before emplacing.
9410
c2f134ac
PA
94112017-06-12 Pedro Alves <palves@redhat.com>
9412
9413 * dwarf2read.c (data_buf::append_space): Rename to...
9414 (data_buf::grow): ... this, and make private. Adjust all callers.
9415 (data_buf::append_uint): New method.
9416 (add_address_entry, write_one_signatured_type)
9417 (write_psymtabs_to_index): Use it.
9418
a81e6d4d
PA
94192017-06-12 Pedro Alves <palves@redhat.com>
9420
9421 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
9422 (file_write (FILE *, const std::vector<Elem>&)): Delete.
9423 (data_buf::file_write): Call ::fwrite directly.
9424
6fd931f2
PA
94252017-06-12 Pedro Alves <palves@redhat.com>
9426
9427 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
9428 std::vector::erase.
9429
bc8f2430
JK
94302017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9431
9432 Code cleanup: C++ify .gdb_index producer.
9433 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
9434 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
9435 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
9436 (create_strtab, add_string): Remove.
9437 (file_write, data_buf): New.
9438 (struct symtab_index_entry): Use std::vector for cu_indices.
9439 (struct mapped_symtab): Use std::vector for data.
9440 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
9441 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
9442 Remove.
9443 (find_slot): Change return type. Update it to the new data structures.
9444 (hash_expand, add_index_entry): Update it to the new data structures.
9445 (offset_type_compare): Remove.
9446 (uniquify_cu_indices): Update it to the new data structures.
9447 (c_str_view, c_str_view_hasher, vector_hasher): New.
9448 (add_indices_to_cpool): Remove.
9449 (write_hash_table): Update it to the new data structures.
9450 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
9451 (eq_psymtab_cu_index): Remove.
9452 (psym_index_map): New typedef.
9453 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
9454 reference and std::unordered_map for cu_index_htab.
9455 (add_address_entry, add_address_entry_worker, write_address_map)
9456 (write_psymbols): Update it to the new data structures.
9457 (write_obstack): Remove.
9458 (struct signatured_type_index_data): Change types_list to a data_buf
9459 reference and psyms_seen to a std::unordered_set reference.
9460 (write_one_signatured_type, recursively_write_psymbols)
9461 (write_psymtabs_to_index): Update it to the new data structures.
9462
c4dcb155
SM
94632017-06-11 Simon Marchi <simon.marchi@ericsson.com>
9464
9465 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
9466 separate-debug-file commands.
9467 * symfile.h (separate_debug_file_debug): New global.
9468 * symfile.c (separate_debug_file_debug): New global.
9469 (separate_debug_file_exists, find_separate_debug_file): Add
9470 debug output.
9471 (_initialize_symfile): Add "set debug separate-debug-file"
9472 command.
9473 * build-id.c (build_id_to_debug_bfd,
9474 find_separate_debug_file_by_buildid): Add debug output.
9475
6d45d4b4
SM
94762017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
9477
9478 * gdbarch.sh (displaced_step_free_closure): Remove.
9479 * gdbarch.h, gdbarch.c: Re-generate.
9480 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
9481 displaced_step_free_closure.
9482 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
9483 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
9484 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9485 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
9486 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9487 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
9488 * arch-utils.h (simple_displaced_step_free_closure): Remove.
9489 * arch-utils.c (simple_displaced_step_free_closure): Remove.
9490 * infrun.c (displaced_step_clear): Call xfree instead of
9491 gdbarch_displaced_step_free_closure.
9492
2f91880f
SDJ
94932017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
9494
9495 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
9496 NULL".
9497
b8b6e72f
AH
94982017-06-08 Alan Hayward <alan.hayward@arm.com>
9499
9500 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
9501 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
9502 (mn10300_push_dummy_call): Likewise.
9503
5369082e
AH
95042017-06-08 Alan Hayward <alan.hayward@arm.com>
9505
9506 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
9507
ff4ca5ac
AH
95082017-06-08 Alan Hayward <alan.hayward@arm.com>
9509
9510 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
9511
aefd8b33
SDJ
95122017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9513
9514 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
9515 able to start inferiors using a shell.
9516 (New remote packets): Announce new packet "QStartupWithShell".
9517 * remote.c: Add PACKET_QStartupWithShell.
9518 (extended_remote_create_inferior): Handle new
9519 PACKET_QStartupWithShell.
9520 (remote_protocol_features) <QStartupWithShell>: New entry for
9521 PACKET_QStartupWithShell.
9522 (_initialize_remote): Call "add_packet_config_cmd" for
9523 QStartupShell.
9524
2090129c
SDJ
95252017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9526 Pedro Alves <palves@redhat.com>
9527
9528 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
9529 and "nat/fork-inferior.h".
9530 * common/common-inferior.h: New file, with contents from
9531 "gdb/inferior.h".
9532 * commom/common-utils.c: Include "common-utils.h".
9533 (stringify_argv): New function.
9534 * common/common-utils.h (stringify_argv): New prototype.
9535 * configure.nat: Add "fork-inferior.o" as a dependency for
9536 "*linux*", "fbsd*" and "nbsd*" hosts.
9537 * corefile.c (get_exec_file): Update comment.
9538 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
9539 instead of "startup_inferior".
9540 (darwin_create_inferior): Call "add_thread_silent" after
9541 "fork_inferior".
9542 * fork-child.c: Cleanup unnecessary includes.
9543 (SHELL_FILE): Move to "common/common-fork-child.c".
9544 (environ): Likewise.
9545 (exec_wrapper): Initialize.
9546 (get_exec_wrapper): New function.
9547 (breakup_args): Move to "common/common-fork-child.c"; rename to
9548 "breakup_args_for_exec".
9549 (escape_bang_in_quoted_argument): Move to
9550 "common/common-fork-child.c".
9551 (saved_ui): New variable.
9552 (prefork_hook): New function.
9553 (postfork_hook): Likewise.
9554 (postfork_child_hook): Likewise.
9555 (gdb_startup_inferior): Likewise.
9556 (fork_inferior): Move to "common/common-fork-child.c". Update
9557 function to support gdbserver.
9558 (startup_inferior): Likewise.
9559 * gdbcore.h (get_exec_file): Remove declaration.
9560 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
9561 instead of "startup_inferior". Call "add_thread_silent" after
9562 "fork_inferior".
9563 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
9564 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
9565 instead of "startup_inferior". Call "add_thread_silent" after
9566 "fork_inferior".
9567 * inferior.h: Include "common-inferior.h".
9568 (trace_start_error): Move to "common/common-utils.h".
9569 (trace_start_error_with_name): Likewise.
9570 (fork_inferior): Move prototype to "nat/fork-inferior.h".
9571 (startup_inferior): Likewise.
9572 (gdb_startup_inferior): New prototype.
9573 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
9574 * nat/fork-inferior.h: New file.
9575 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
9576 instead of "startup_inferior". Call "add_thread_silent" after
9577 "fork_inferior".
9578 * target.h (target_terminal_init): Move prototype to
9579 "target/target.h".
9580 (target_terminal_inferior): Likewise.
9581 (target_terminal_ours): Likewise.
9582 * target/target.h (target_terminal_init): New prototype, moved
9583 from "target.h".
9584 (target_terminal_inferior): Likewise.
9585 (target_terminal_ours): Likewise.
9586 * utils.c (gdb_flush_out_err): New function.
9587
043a4934
SDJ
95882017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9589
9590 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
9591 * common/common-gdbthread.h: New file, with parts from
9592 "gdb/gdbthread.h".
9593 * gdbthread.h: Include "common-gdbthread.h".
9594 (switch_to_thread): Moved to "common/common-gdbthread.h".
9595
15652511
SDJ
95962017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9597
9598 * Makefile.in (SFILES): Add "common/job-control.c".
9599 (HFILES_NO_SRCDIR): Add "common/job-control.h".
9600 (COMMON_OBS): Add "job-control.o".
9601 * common/job-control.c: New file, with contents from
9602 "gdb/inflow.c".
9603 * common/job-control.h: New file, with contents from "terminal.h".
9604 * fork-child.c: Include "job-control.h".
9605 * inflow.c: Include "job-control.h".
9606 (gdb_setpgid): Move to "common/common-inflow.c".
9607 (_initialize_inflow): Move setting of "job_control" to
9608 "handle_job_control".
9609 * terminal.h (job_control): Moved to "common/common-terminal.h".
9610 (gdb_setpgid): Likewise.
9611 * top.c: Include "job_control.h".
9612 * utils.c: Likewise.
9613 (job_control): Moved to "job-control.c".
9614
2d7cc5c7
PA
96152017-06-07 Pedro Alves <palves@redhat.com>
9616
9617 * Makefile.in (SFILES): Add gdb_regex.c.
9618 (COMMON_OBS): Add gdb_regex.o.
9619 * ada-lang.c (ada_add_standard_exceptions)
9620 (ada_add_exceptions_from_frame, name_matches_regex)
9621 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
9622 parameter type to compiled_regex. Adjust.
9623 (ada_exceptions_list): Use compiled_regex.
9624 * break-catch-throw.c (exception_catchpoint::pattern): Now a
9625 std::unique_ptr<compiled_regex>.
9626 (exception_catchpoint::~exception_catchpoint): Remove regfree
9627 call.
9628 (check_status_exception_catchpoint): Adjust to use compiled_regex.
9629 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
9630 * breakpoint.c (solib_catchpoint::compiled): Now a
9631 std::unique_ptr<compiled_regex>.
9632 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
9633 (check_status_catch_solib): Adjust to use compiled_regex.
9634 (add_solib_catchpoint): Adjust to use compiled_regex.
9635 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
9636 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
9637 compiled_regex reference. Adjust to use it.
9638 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
9639 declaration. Include "gdb_regex.h".
9640 (apropos_cmd): Change regex parameter to compiled_regex reference.
9641 * gdb_regex.c: New file.
9642 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
9643 declarations.
9644 (class compiled_regex): New.
9645 * linux-tdep.c: Include "common/gdb_optional.h".
9646 (struct mapping_regexes): New, factored out from
9647 mapping_is_anonymous_p, and adjusted to use compiled_regex.
9648 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
9649 gdb::optional and remove cleanups. Adjust to compiled_regex.
9650 * probe.c: Include "common/gdb_optional.h".
9651 (collect_probes): Use compiled_regex and gdb::optional and remove
9652 cleanups.
9653 * skip.c: Include "common/gdb_optional.h".
9654 (skiplist_entry::compiled_function_regexp): Now a
9655 gdb::optional<compiled_regex>.
9656 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
9657 (free_skiplist_entry): Remove regfree call.
9658 (compile_skip_regexp, skip_rfunction_p): Adjust to use
9659 compiled_regex and gdb::optional.
9660 * symtab.c: Include "common/gdb_optional.h".
9661 (search_symbols): Use compiled_regex and gdb::optional.
9662 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
9663 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
9664 to gdb_regex.c.
9665
50d6adef
AH
96662017-06-07 Alan Hayward <alan.hayward@arm.com>
9667
9668 * regcache.c (regcache::save): Avoid buffer use.
9669 (regcache::dump): Likewise.
9670
4a8a33c8
AH
96712017-06-07 Alan Hayward <alan.hayward@arm.com>
9672
9673 * sh-tdep.c (sh_pseudo_register_read): Remove
9674 MAX_REGISTER_SIZE.
9675 (sh_pseudo_register_write): Likewise.
9676 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
9677 (sh64_pseudo_register_write): Likewise
9678
d1be909e
AH
96792017-06-07 Alan Hayward <alan.hayward@arm.com>
9680
9681 * aarch64-tdep.c (aarch64_store_return_value): Use
9682 V_REGISTER_SIZE.
9683 (aarch64_pseudo_read_value): Likewise.
9684 (aarch64_pseudo_write): Likewise.
9685
f4a65042
YQ
96862017-06-06 Yao Qi <yao.qi@linaro.org>
9687
9688 * regformats/regdef.h (set_register_cache): Remove the
9689 declaration.
9690
9f7fb0aa
AH
96912017-06-06 Alan Hayward <alan.hayward@arm.com>
9692
9693 * frame.c (frame_unwind_register_signed): Use
9694 frame_unwind_register_value.
9695
e1e01040
PA
96962017-06-06 Pedro Alves <palves@redhat.com>
9697
9698 PR breakpoints/21553
9699 * breakpoint.c (create_breakpoints_sal_default)
9700 (init_breakpoint_sal, create_breakpoint_sal): Use
9701 gdb::unique_xmalloc_ptr for string parameters.
9702 (create_breakpoint): Constify 'extra_string' and 'cond_string'
9703 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
9704 (base_breakpoint_create_breakpoints_sal)
9705 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
9706 (strace_marker_create_breakpoints_sal)
9707 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
9708 string parameters.
9709 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
9710 gdb::unique_xmalloc_ptr for string parameters.
9711 (create_breakpoint): Constify 'extra_string' and 'cond_string'
9712 parameters.
9713
fbe654c8
AH
97142017-06-06 Alan Hayward <alan.hayward@arm.com>
9715
9716 * alpha-tdep.c (alpha_register_to_value): Use
9717 get_frame_register_value.
9718 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
9719
ae0d01d6
AH
97202017-06-06 Alan Hayward <alan.hayward@arm.com>
9721
9722 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
9723 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
9724 (ia64_value_to_register): Likewise.
9725 (ia64_extract_return_value): Likewise.
9726 (ia64_store_return_value): Likewise.
9727 (ia64_push_dummy_call): Likewise.
9728
49cf576c
JB
97292017-06-04 Joel Brobecker <brobecker@adacore.com>
9730
9731 GDB 8.0 released.
9732
26b6a6ab
SM
97332017-06-03 Simon Marchi <simon.marchi@ericsson.com>
9734
9735 * x86-linux-nat.c (struct arch_lwp_info): Remove.
9736
22827c51
SM
97372017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
9738
9739 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
9740 parameter.
9741 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
9742
0e05cf3a
SM
97432017-06-02 Simon Marchi <simon.marchi@ericsson.com>
9744
9745 * event-loop.c (poll_timers): Unallocate timer using delete
9746 instead of xfree.
9747
c1fc2657
SM
97482017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9749
9750 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
9751 (struct breakpoint) <~breakpoint>: New.
9752 (struct watchpoint): Inherit from breakpoint.
9753 <~watchpoint>: New.
9754 <base>: Remove.
9755 (struct tracepoint): Inherit from breakpoint.
9756 <base>: Remove.
9757 * breakpoint.c (longjmp_breakpoint_ops): Remove.
9758 (struct longjmp_breakpoint): Inherit from breakpoint.
9759 <~longjmp_breakpoint>: New.
9760 <base>: Remove.
9761 (new_breakpoint_from_type): Remove casts.
9762 (watchpoint_in_thread_scope): Remove reference to base field.
9763 (watchpoint_del_at_next_stop): Likewise.
9764 (update_watchpoint): Likewise.
9765 (watchpoint_check): Likewise.
9766 (bpstat_check_watchpoint): Likewise.
9767 (set_longjmp_breakpoint): Likewise.
9768 (struct fork_catchpoint): Inherit from breakpoint.
9769 <base>: Remove.
9770 (struct solib_catchpoint): Inherit from breakpoint.
9771 <~solib_catchpoint>: New.
9772 <base>: Remove.
9773 (dtor_catch_solib): Change to ...
9774 (solib_catchpoint::~solib_catchpoint): ... this.
9775 (breakpoint_hit_catch_solib): Remove reference to base field.
9776 (add_solib_catchpoint): Likewise.
9777 (create_fork_vfork_event_catchpoint): Likewise.
9778 (struct exec_catchpoint): Inherit from breakpoint.
9779 <~exec_catchpoint>: New.
9780 <base>: Remove.
9781 (dtor_catch_exec): Change to ...
9782 (exec_catchpoint::~exec_catchpoint): ... this.
9783 (dtor_watchpoint): Change to ...
9784 (watchpoint::~watchpoint): ... this.
9785 (watch_command_1): Remove reference to base field.
9786 (catch_exec_command_1): Likewise.
9787 (base_breakpoint_dtor): Change to ...
9788 (breakpoint::~breakpoint): ... this.
9789 (base_breakpoint_ops): Remove dtor field value.
9790 (longjmp_bkpt_dtor): Change to ...
9791 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
9792 (strace_marker_create_breakpoints_sal): Remove reference to base
9793 field.
9794 (delete_breakpoint): Don't manually call breakpoint destructor.
9795 (create_tracepoint_from_upload): Remove reference to base field.
9796 (trace_pass_set_count): Likewise.
9797 (initialize_breakpoint_ops): Don't initialize
9798 momentary_breakpoint_ops, don't set dtors.
9799 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
9800 <~ada_catchpoint>: New.
9801 <base>: Remove.
9802 (create_excep_cond_exprs): Remove reference to base field.
9803 (dtor_exception): Change to ...
9804 (ada_catchpoint::~ada_catchpoint): ... this.
9805 (dtor_catch_exception): Remove.
9806 (dtor_catch_exception_unhandled): Remove.
9807 (dtor_catch_assert): Remove.
9808 (create_ada_exception_catchpoint): Remove reference to base
9809 field.
9810 (initialize_ada_catchpoint_ops): Don't set dtors.
9811 * break-catch-sig.c (struct signal_catchpoint): Inherit from
9812 breakpoint.
9813 <~signal_catchpoint>: New.
9814 <base>: Remove.
9815 (signal_catchpoint_dtor): Change to ...
9816 (signal_catchpoint::~signal_catchpoint): ... this.
9817 (create_signal_catchpoint): Remove reference to base field.
9818 (initialize_signal_catchpoint_ops): Don't set dtor.
9819 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
9820 from breakpoint.
9821 <~syscall_catchpoint>: New.
9822 <base>: Remove.
9823 (dtor_catch_syscall): Change to ...
9824 (syscall_catchpoint::~syscall_catchpoint): ... this.
9825 (create_syscall_event_catchpoint): Remove reference to base
9826 field.
9827 (initialize_syscall_catchpoint_ops): Don't set dtor.
9828 * break-catch-throw.c (struct exception_catchpoint): Inherit
9829 from breakpoint.
9830 <~exception_catchpoint>: New.
9831 <base>: Remove.
9832 (dtor_exception_catchpoint): Change to ...
9833 (exception_catchpoint::~exception_catchpoint): ... this.
9834 (handle_gnu_v3_exceptions): Remove reference to base field.
9835 (initialize_throw_catchpoint_ops): Don't set dtor.
9836 * ctf.c (ctf_get_traceframe_address): Remove reference to base
9837 field.
9838 * remote.c (remote_get_tracepoint_status): Likewise.
9839 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
9840 * tracefile.c (tracefile_fetch_registers): Likewise.
9841 * tracepoint.c (actions_command): Likewise.
9842 (validate_actionline): Likewise.
9843 (tfind_1): Likewise.
9844 (get_traceframe_location): Likewise.
9845 (find_matching_tracepoint_location): Likewise.
9846 (parse_tracepoint_status): Likewise.
9847 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
9848
3b0871f4
SM
98492017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9850
9851 * breakpoint.c (struct longjmp_breakpoint): New struct.
9852 (is_tracepoint_type): Change return type to bool.
9853 (is_longjmp_type): New function.
9854 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
9855 (set_raw_breakpoint_without_location): Use
9856 new_breakpoint_from_type.
9857 (set_raw_breakpoint): Likewise.
9858
a5e364af
SM
98592017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9860
9861 * breakpoint.c (new_breakpoint_from_type): New function.
9862 (create_breakpoint_sal): Use new_breakpoint_from_type and
9863 unique_ptr.
9864 (create_breakpoint): Likewise.
9865
ae3b3f34
SM
98662017-05-31 Simon Marchi <simon.marchi@ericsson.com>
9867
9868 * memattr.c (mem_info_command): Rename to ...
9869 (info_mem_command): ... this.
9870 (mem_enable_command): Rename to ...
9871 (enable_mem_command): ... this.
9872 (mem_disable_command): Rename to ...
9873 (disable_mem_command): ... this.
9874 (mem_delete_command): Rename to ...
9875 (delete_mem_command): ... this.
9876 (_initialize_mem): Adjust function names.
9877
13ace077
MM
98782017-05-31 Markus Metzger <markus.t.metzger@intel.com>
9879
9880 * btrace.c (handle_pt_insn_events): New.
9881 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
9882 STATUS. Split into this and ...
9883 (handle_pt_insn_event_flags): ... this.
9884
c56ccc05
MM
98852017-05-31 Markus Metzger <markus.t.metzger@intel.com>
9886
9887 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
9888 and struct pt_insn.resynced.
9889 * configure: Regenerated.
9890 * config.in: Regenerated.
9891
08c3f6d2
TW
98922017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9893
9894 * btrace.c (ftrace_find_call_by_number): New function.
9895 (ftrace_new_function): Store objects, not pointers.
9896 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
9897 ftrace_new_gap, ftrace_update_function,
9898 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
9899 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
9900 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
9901 btrace_ends_with_single_insn, btrace_call_get): Account for
9902 btrace_thread_info::functions now storing objects.
9903 * btrace.h (struct btrace_thread_info): Add constructor.
9904 (struct btrace_thread_info) <functions>: Make std::vector.
9905 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
9906 Initialize with default values.
9907 * record-btrace.c (record_btrace_frame_sniffer): Account for
9908 btrace_thread_info::functions now storing objects.
9909
8ffd39f2
TW
99102017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9911
9912 * btrace.c: Remove typedef bfun_s.
9913 (ftrace_new_gap): Directly add gaps to the list of gaps.
9914 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
9915 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
9916 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
9917 instead of gdb VEC.
9918
4aeb0dfc
TW
99192017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9920
9921 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
9922 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
9923 with btrace_thread_info::next_segment and
9924 btrace_thread_info::prev_segment.
9925 * btrace.h: Remove struct btrace_func_link.
9926 (struct btrace_function): Replace pair of function segment pointers
9927 with pair of indices.
9928 * python/py-record-btrace.c (btpy_call_prev_sibling,
9929 btpy_call_next_sibling): Replace references to
9930 btrace_thread_info::segment with btrace_thread_info::next_segment and
9931 btrace_thread_info::prev_segment.
9932 * record-btrace.c (record_btrace_frame_this_id): Use
9933 btrace_find_call_by_number.
9934
eb8f2b9c
TW
99352017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9936
9937 * btrace.c (ftrace_new_function, ftrace_fixup_level,
9938 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
9939 btrace_insn_next, btrace_insn_prev): Remove references to
9940 btrace_thread_info::flow.
9941 * btrace.h (struct btrace_function): Remove FLOW.
9942
42bfe59e
TW
99432017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9944
9945 * btrace.c (ftrace_find_call_by_number): New function.
9946 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
9947 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
9948 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
9949 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
9950 index.
9951 * btrace.h (struct btrace_function): Turn UP into an index.
9952 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
9953 as an index.
9954 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
9955 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
9956 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
9957
b54b03bd
TW
99582017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9959
9960 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
9961 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
9962 ftrace_update_function, ftrace_compute_global_level_offset,
9963 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
9964 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
9965 btrace_insn_end, btrace_is_empty): Remove references to
9966 btrace_thread_info::begin and btrace_thread_info::end.
9967 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
9968 (struct btrace_thread_info) <functions>: Adjust comment.
9969 * record-btrace.c (record_btrace_start_replaying): Remove reference to
9970 btrace_thread_info::begin.
9971
8286623c
TW
99722017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9973
9974 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
9975 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
9976 ftrace_update_function): Remove arguments that implicitly were always
9977 BTINFO->END.
9978 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
9979 Don't pass BTINFO->END.
9980
a0f1b963
TW
99812017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9982
9983 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
9984 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
9985 btrace_find_insn_by_number): Replace function segment pointer with
9986 index.
9987 (btrace_insn_cmp): Simplify.
9988 * btrace.h: (struct btrace_insn_iterator) Rename index to
9989 insn_index. Replace function segment pointer with index into function
9990 segment vector.
9991 * record-btrace.c (record_btrace_call_history): Replace function
9992 segment pointer use with index.
9993 (record_btrace_frame_sniffer): Retrieve function call segment through
9994 vector.
9995 (record_btrace_set_replay): Remove defunc't safety check.
9996
f158f208
TW
99972017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9998
9999 * btrace.c (btrace_ends_with_single_insn): New function.
10000 (btrace_call_get, btrace_call_number, btrace_call_begin,
10001 btrace_call_end, btrace_call_next, btrace_call_prev,
10002 btrace_find_call_by_number): Use index into call segment vector
10003 instead of pointer.
10004 (btrace_call_cmp): Simplify.
10005 * btrace.h (struct btrace_call_iterator): Replace function call segment
10006 pointer with index into vector.
10007 * record-btrace.c (record_btrace_call_history): Use index instead of
10008 pointer.
10009
521103fd
TW
100102017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10011
10012 * btrace.c (btrace_insn_begin, btrace_insn_end,
10013 btrace_find_insn_by_number): Add btinfo to iterator.
10014 * btrace.h (struct btrace_insn_iterator): Add btinfo.
10015
17b89b34
TW
100162017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10017
10018 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
10019 and save pointers directly.
10020 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
10021 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
10022 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
10023 changed signature of functions.
10024 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
10025 (btrace_fetch): Remove code that adds btrace_function pointers to
10026 vector of btrace_functions.
10027 (btrace_clear): Simplify freeing vector of btrace_functions.
10028
2b51eddc
TW
100292017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10030
10031 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
10032 Replace VEC_* with std::vector functions.
10033 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
10034 (struct btrace_thread_info)<functions>: Change type to std::vector.
10035
db6be0d5
SM
100362017-05-30 Simon Marchi <simon.marchi@ericsson.com>
10037
10038 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
10039 "Removed targets and native configurations" up. Merge duplicate
10040 "New commands" sub-sections. Add "New options" sub-sections.
10041
b057297a
AH
100422017-05-26 Alan Hayward <alan.hayward@arm.com>
10043
10044 * defs.h (copy_integer_to_size): New declaration.
10045 * findvar.c (copy_integer_to_size): New function.
10046 (do_cint_test): New selftest function.
10047 (copy_integer_to_size_test): Likewise.
10048 (_initialize_findvar): Likewise.
10049 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
10050 (mips_fbsd_collect_reg): Use raw_collect_integer.
10051 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
10052 (mips64_fill_gregset): Use raw_collect_integer
10053 (mips64_fill_fpregset): Use raw_supply_integer.
10054 * regcache.c (regcache::raw_supply_integer): New function.
10055 (regcache::raw_collect_integer): Likewise.
10056 * regcache.h: (regcache::raw_supply_integer): New declaration.
10057 (regcache::raw_collect_integer): Likewise.
10058
b77b02a5
YQ
100592017-05-24 Yao Qi <yao.qi@linaro.org>
10060
10061 * Makefile.in (SFILES): Add gdbarch-selftests.c.
10062 (COMMON_OBS): Add gdbarch-selftests.o.
10063 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
10064 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
10065 * gdbarch-selftests.c: New file.
10066 * regcache.h (regcache) <~regcache>: Mark it virtual if
10067 GDB_SELF_TEST.
10068 <raw_write>: Likewise.
10069
e521e87e
YQ
100702017-05-24 Yao Qi <yao.qi@linaro.org>
10071
10072 * regcache.c (current_regcache): Change it to
10073 regcache::current_regcache.
10074 (regcache_observer_target_changed): Update.
10075 (regcache_thread_ptid_changed): Make it a regcache static
10076 method.
10077 (regcache_thread_ptid_changed): Update.
10078 (class regcache_access): New.
10079 (current_regcache_test): Update.
10080 (_initialize_regcache): Update.
10081 * regcache.h: Include forward_list.
10082 (regcache): Declare regcache_thread_ptid_changed and declare
10083 registers_changed_ptid as friend.
10084
d8e07dda
YQ
100852017-05-24 Yao Qi <yao.qi@linaro.org>
10086
10087 * i387-tdep.c (i387_register_to_value): Use register_size
10088 instead of TYPE_LENGTH.
10089 * m68k-tdep.c (m68k_register_to_value): Likewise.
10090
8c8f9122
YQ
100912017-05-24 Yao Qi <yao.qi@linaro.org>
10092
10093 * i387-tdep.c (i387_convert_register_p): Return false if type
10094 code isn't TYPE_CODE_FLT.
10095
68fce50f
YQ
100962017-05-24 Yao Qi <yao.qi@linaro.org>
10097
10098 * alpha-tdep.c (alpha_convert_register_p): Return true if type
10099 length is 4.
10100 (alpha_register_to_value): Remove type length check.
10101 (alpha_value_to_register): Likewise.
10102
88954b49
YQ
101032017-05-24 Yao Qi <yao.qi@linaro.org>
10104
10105 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
10106 TYPE_CODE_FLT.
10107
e3ec9b69
YQ
101082017-05-24 Yao Qi <yao.qi@linaro.org>
10109
10110 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
10111 TYPE_CODE_FLT or not.
10112
cdd238da
YQ
101132017-05-24 Yao Qi <yao.qi@linaro.org>
10114
10115 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
10116 * avr-tdep.c (avr_gdbarch_init): Likewise.
10117 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
10118 * cris-tdep.c (cris_gdbarch_init): Likewise.
10119 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
10120 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
10121 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10122 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
10123 * mep-tdep.c (mep_gdbarch_init): Likewise.
10124 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
10125 * mips-tdep.c (mips_gdbarch_init): Likewise.
10126 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
10127 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10128 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
10129 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
10130 * v850-tdep.c (v850_gdbarch_init): Likewise.
10131
7a3929c4
YQ
101322017-05-24 Yao Qi <yao.qi@linaro.org>
10133
10134 * selftest-arch.c (tests_with_arch): Call registers_changed
10135 and reinit_frame_cache.
10136 * selftest.c (run_self_tests): Likewise.
10137
f4985dba
YQ
101382017-05-24 Yao Qi <yao.qi@linaro.org>
10139
10140 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
10141 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
10142
ab20fa4a
YQ
101432017-05-24 Yao Qi <yao.qi@linaro.org>
10144
10145 * rl78-tdep.c (rl78_gdbarch_init): Don't call
10146 set_gdbarch_print_insn.
10147
f532ab94
YQ
101482017-05-24 Yao Qi <yao.qi@linaro.org>
10149
10150 * h8300-tdep.c (h8300_gdbarch_init): Don't call
10151 set_gdbarch_print_insn.
10152
39503f82
YQ
101532017-05-24 Yao Qi <yao.qi@linaro.org>
10154
10155 * alpha-tdep.c (alpha_gdbarch_init): Don't call
10156 set_gdbarch_print_insn.
10157 * arc-tdep.c (arc_gdbarch_init): Likewise.
10158 * arch-utils.c: include dis-asm.h.
10159 (default_print_insn): New function.
10160 * arch-utils.h (default_print_insn): Declare.
10161 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
10162 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
10163 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
10164 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
10165 * frv-tdep.c (frv_gdbarch_init): Likewise.
10166 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
10167 * gdbarch.sh (print_insn): Use default_print_insn.
10168 * gdbarch.c: Regenerated.
10169 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
10170 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
10171 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
10172 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
10173 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10174 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
10175 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
10176 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
10177 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
10178 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
10179 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
10180 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10181 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
10182 * mt-tdep.c (mt_gdbarch_init): Likewise.
10183 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10184 * nios2-tdep.c (nios2_print_insn): Remove.
10185 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
10186 * rx-tdep.c (rx_gdbarch_init): Likewise.
10187 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
10188 * score-tdep.c (score_print_insn): Remove.
10189 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
10190 * sh-tdep.c (sh_gdbarch_init): Likewise.
10191 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
10192 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10193 * tic6x-tdep.c (tic6x_print_insn): Remove.
10194 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
10195 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
10196 * v850-tdep.c (v850_gdbarch_init): Likewise.
10197 * vax-tdep.c (vax_gdbarch_init): Likewise.
10198 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
10199 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
10200
f7241d4f
JB
102012017-05-23 John Baldwin <jhb@FreeBSD.org>
10202
10203 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
10204 (MIPS_FP0_REGNUM): Remove.
10205 (MIPS_FSR_REGNUM): Remove.
10206 (mips_fbsd_supply_fpregs): Use mips_regnum.
10207 (mips_fbsd_supply_gregs): Likewise.
10208 (mips_fbsd_collect_fpregs): Likewise.
10209 (mips_fbsd_collect_gregs): Likewise.
10210
d489d81d
JB
102112017-05-23 John Baldwin <jhb@FreeBSD.org>
10212
10213 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
10214 (getpfpregs_supplies): New function.
10215 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
10216 getfpregs_supplies.
10217 (mips_fbsd_store_inferior_registers): Likewise.
10218
e11b3cdc
PA
102192017-05-22 Pedro Alves <palves@redhat.com>
10220
10221 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
10222 maintainer.
10223
0f068fb5
AH
102242017-05-22 Alan Hayward <alan.hayward@arm.com>
10225
10226 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
10227 (store_register): Likewise.
10228 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
10229 (get_decimal_float_return_value): Likewise.
10230 (do_ppc_sysv_return_value): Likewise.
10231 (ppc64_sysv_abi_push_integer): Likewise.
10232 (ppc64_sysv_abi_push_freg): Likewise.
10233 (ppc64_sysv_abi_return_value_base): Likewise.
10234 (ppc64_sysv_abi_return_value): Likewise.
10235 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
10236 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
10237 * rs6000-nat.c: Likewise.
10238 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
10239 (rs6000_value_to_register): Likewise.
10240 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
10241
e6cf65f2
TT
102422017-05-21 Tom Tromey <tom@tromey.com>
10243
10244 PR rust/21466:
10245 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
10246 arrays as "[T]", not "[T; ]".
10247
43cc5389
TT
102482017-05-19 Tom Tromey <tom@tromey.com>
10249
10250 PR rust/21484:
10251 * rust-lang.c (exp_descriptor_rust): New function.
10252 (rust_language_defn): Use it.
10253 * p-lang.c (pascal_language_defn): Update.
10254 * opencl-lang.c (opencl_language_defn): Update.
10255 * objc-lang.c (objc_language_defn): Update.
10256 * m2-lang.c (m2_language_defn): Update.
10257 * language.h (struct language_defn)
10258 <la_watch_location_expression>: New member.
10259 * language.c (unknown_language_defn, auto_language_defn)
10260 (local_language_defn): Update.
10261 * go-lang.c (go_language_defn): Update.
10262 * f-lang.c (f_language_defn): Update.
10263 * d-lang.c (d_language_defn): Update.
10264 * c-lang.h (c_watch_location_expression): Declare.
10265 * c-lang.c (c_watch_location_expression): New function.
10266 (c_language_defn, cplus_language_defn, asm_language_defn)
10267 (minimal_language_defn): Use it.
10268 * breakpoint.c (watch_command_1): Call
10269 la_watch_location_expression.
10270 * ada-lang.c (ada_language_defn): Update.
10271
7a6e7fcc
RO
102722017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10273
6e7e1744
RO
10274 PR tui/21482
10275 * gdb_curses.h (NOMACROS): Define.
10276 (NCURSES_NOMACROS): Define.
10277
102782017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10279
10280 PR tui/21482
7a6e7fcc
RO
10281 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
10282 arg to char *.
10283 * tui/tui-wingeneral.c (box_win): Likewise.
10284 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
10285 (tui_show_source_line): Likewise.
10286 (tui_show_exec_info_content): Likewise.
10287
1933fd8e
VM
102882017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
10289
10290 * sparc-tdep.c (sparc_structure_return_p)
10291 (sparc_arg_on_registers_p): New functions.
10292 (sparc32_store_arguments): Use them.
10293 * sparc64-tdep.c (sparc64_16_byte_align_p)
10294 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
10295 Handle TYPE_CODE_ARRAY.
10296
21873064
YQ
102972017-05-17 Yao Qi <yao.qi@linaro.org>
10298
10299 * cli/cli-decode.c (add_alias_cmd): New function.
10300 * command.h (add_alias_cmd): Declare.
10301 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
10302 instead call add_alias_cmd.
10303
2b351b19
PA
103042017-05-17 Pedro Alves <palves@redhat.com>
10305
10306 * Makefile.in (nat_extra_makefile_frag): Rename to ...
10307 (nat_makefile_frag): ... this. All references updated.
10308 * configure.ac: Likewise.
10309 * configure.nat: Likewise. Enhance comments.
10310 * configure: Regenerate.
10311
5f2ad7a3
RO
103122017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10313
10314 * procfs.c (procfs_create_inferior): Change prototype to match
10315 definition.
10316
adf3dde5
EZ
103172017-05-13 Eli Zaretskii <eliz@gnu.org>
10318
10319 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
10320 C++ compiler warning.
10321
6830f270
TT
103222017-05-12 Tom Tromey <tom@tromey.com>
10323
10324 PR rust/21483:
10325 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
10326 recurse, just call value_struct_elt directly.
10327
68f2f2e3
TT
103282017-05-12 Tom Tromey <tom@tromey.com>
10329
10330 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
10331 OP_RUST_ARRAY>: Fix.
10332
256afbc2
TT
103332017-05-12 Tom Tromey <tom@tromey.com>
10334
10335 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
10336
94bb8dfe
YQ
103372017-05-09 Yao Qi <yao.qi@linaro.org>
10338
10339 * regcache.c: Include <forward_list>.
10340 (struct regcache_list): Remove.
10341 (current_regcache): Update.
10342 (get_thread_arch_aspace_regcache): Update for std::forward_list.
10343 (regcache_thread_ptid_changed): Likewise.
10344 (registers_changed_ptid): Likewise.
10345 (current_regcache_size): Likewise.
10346
8248946c
YQ
103472017-05-09 Yao Qi <yao.qi@linaro.org>
10348
10349 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
10350 (current_regcache_size): New function.
10351 (current_regcache_test): New function.
10352 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
10353
313c5961
AH
103542017-05-08 Alan Hayward <alan.hayward@arm.com>
10355
10356 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
10357 (print_gp_register_row): Use get_frame_register_value.
10358
27bfc1d1
AH
103592017-05-08 Alan Hayward <alan.hayward@arm.com>
10360
10361 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
10362 (mips_supply_fpregset): Likewise.
10363 (mips64_supply_gregset): Likewise.
10364
146e6c5c
AH
103652017-05-08 Alan Hayward <alan.hayward@arm.com>
10366
10367 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
10368 regcache->raw_supply_zeroed.
10369
e50f25ec
SDJ
103702017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
10371
10372 * configure.nat: Rearrange 'case' statements to match
10373 host before cpu.
10374
21ea5acd
SDJ
103752017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
10376
10377 * Makefile.in: Remove "@host_makefile_frag@". Add variables
10378 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
10379 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
10380 "@nat_extra_makefile_frag@".
10381 (Makefile): Remove dependency on "@frags@".
10382 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
10383 (data-directory/Makefile): Likewise.
10384 * config/aarch64/linux.mh: Deleted; moved contents to
10385 "gdb/configure.nat".
10386 * config/alpha/alpha-linux.mh: Likewise.
10387 * config/alpha/nbsd.mh: Likewise.
10388 * config/arm/linux.mh: Likewise.
10389 * config/arm/nbsdelf.mh: Likewise.
10390 * config/i386/cygwin.mh: Likewise.
10391 * config/i386/cygwin64.mh: Likewise.
10392 * config/i386/darwin.mh: Likewise.
10393 * config/i386/fbsd.mh: Likewise.
10394 * config/i386/fbsd64.mh: Likewise.
10395 * config/i386/go32.mh: Likewise.
10396 * config/i386/i386gnu.mh: Likewise.
10397 * config/i386/i386sol2.mh: Likewise.
10398 * config/i386/linux.mh: Likewise.
10399 * config/i386/linux64.mh: Likewise.
10400 * config/i386/mingw.mh: Likewise.
10401 * config/i386/mingw64.mh: Likewise.
10402 * config/i386/nbsd64.mh: Likewise.
10403 * config/i386/nbsdelf.mh: Likewise.
10404 * config/i386/nto.mh: Likewise.
10405 * config/i386/obsd.mh: Likewise.
10406 * config/i386/obsd64.mh: Likewise.
10407 * config/i386/sol2-64.mh: Likewise.
10408 * config/ia64/linux.mh: Likewise.
10409 * config/m32r/linux.mh: Likewise.
10410 * config/m68k/linux.mh: Likewise.
10411 * config/m68k/nbsdelf.mh: Likewise.
10412 * config/m68k/obsd.mh: Likewise.
10413 * config/m88k/obsd.mh: Likewise.
10414 * config/mips/fbsd.mh: Likewise.
10415 * config/mips/linux.mh: Likewise.
10416 * config/mips/nbsd.mh: Likewise.
10417 * config/mips/obsd64.mh: Likewise.
10418 * config/pa/linux.mh: Likewise.
10419 * config/pa/nbsd.mh: Likewise.
10420 * config/pa/obsd.mh: Likewise.
10421 * config/powerpc/aix.mh: Likewise.
10422 * config/powerpc/fbsd.mh: Likewise.
10423 * config/powerpc/linux.mh: Likewise.
10424 * config/powerpc/nbsd.mh: Likewise.
10425 * config/powerpc/obsd.mh: Likewise.
10426 * config/powerpc/ppc64-linux.mh: Likewise.
10427 * config/powerpc/spu-linux.mh: Likewise.
10428 * config/s390/linux.mh: Likewise.
10429 * config/sh/nbsd.mh: Likewise.
10430 * config/sparc/fbsd.mh: Likewise.
10431 * config/sparc/linux.mh: Likewise.
10432 * config/sparc/linux64.mh: Likewise.
10433 * config/sparc/nbsd64.mh: Likewise.
10434 * config/sparc/nbsdelf.mh: Likewise.
10435 * config/sparc/obsd64.mh: Likewise.
10436 * config/sparc/sol2.mh: Likewise.
10437 * config/tilegx/linux.mh: Likewise.
10438 * config/vax/nbsdelf.mh: Likewise.
10439 * config/vax/obsd.mh: Likewise.
10440 * config/xtensa/linux.mh: Likewise.
10441 * config/i386/i386gnu.mn: New file, with excerpts from
10442 "config/i386/i386gnu.mh".
10443 * configure: Regenerate.
10444 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
10445 *.mh files under "gdb/config".
10446 * configure.nat: New file, with contents from the
10447 "gdb/config/*/*.mh" files.
10448
7ed1acaf
TW
104492017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
10450
10451 * btrace.c (btrace_clear): Free insn vector.
10452
e13cb306
PA
104532017-05-05 Pedro Alves <palves@redhat.com>
10454
10455 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
10456 * configure: Regenerate.
10457
5ed8105e
PA
104582017-05-04 Pedro Alves <palves@redhat.com>
10459
10460 * Makefile.in (SFILES): Add progspace-and-thread.c.
10461 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
10462 (COMMON_OBS): Add progspace-and-thread.o.
10463 * breakpoint.c: Include "progspace-and-thread.h".
10464 (update_inserted_breakpoint_locations)
10465 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
10466 Use scoped_restore_current_pspace_and_thread.
10467 (create_std_terminate_master_breakpoint): Use
10468 scoped_restore_current_program_space.
10469 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
10470 (print_breakpoint_location): Use
10471 scoped_restore_current_program_space.
10472 (bp_loc_is_permanent): Use
10473 scoped_restore_current_pspace_and_thread.
10474 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
10475 (download_tracepoint_locations): Use
10476 scoped_restore_current_pspace_and_thread.
10477 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
10478 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
10479 (enum step_over_calls_kind): Moved from inferior.h.
10480 (class scoped_restore_current_thread): New class.
10481 * gdbthread.h (make_cleanup_restore_current_thread): Delete
10482 declaration.
10483 (scoped_restore_current_thread): New class.
10484 * infcmd.c: Include "common/gdb_optional.h".
10485 (continue_1, proceed_after_attach): Use
10486 scoped_restore_current_thread.
10487 (notice_new_inferior): Use scoped_restore_current_thread.
10488 * inferior.c: Include "progspace-and-thread.h".
10489 (restore_inferior, save_current_inferior): Delete.
10490 (add_inferior_command, clone_inferior_command): Use
10491 scoped_restore_current_pspace_and_thread.
10492 * inferior.h (scoped_restore_current_inferior): New class.
10493 * infrun.c: Include "progspace-and-thread.h" and
10494 "common/gdb_optional.h".
10495 (follow_fork_inferior): Use
10496 scoped_restore_current_pspace_and_thread.
10497 (scoped_restore_exited_inferior): New class.
10498 (handle_vfork_child_exec_or_exit): Use
10499 scoped_restore_exited_inferior,
10500 scoped_restore_current_pspace_and_thread,
10501 scoped_restore_current_thread and scoped_restore.
10502 (fetch_inferior_event): Use scoped_restore_current_thread.
10503 * linespec.c (decode_line_full, decode_line_1): Use
10504 scoped_restore_current_program_space.
10505 * mi/mi-main.c: Include "progspace-and-thread.h".
10506 (exec_continue): Use scoped_restore_current_thread.
10507 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
10508 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
10509 * proc-service.c (ps_pglobal_lookup): Use
10510 scoped_restore_current_program_space.
10511 * progspace-and-thread.c: New file.
10512 * progspace-and-thread.h: New file.
10513 * progspace.c (release_program_space, clone_program_space): Use
10514 scoped_restore_current_program_space.
10515 (restore_program_space, save_current_program_space)
10516 (save_current_space_and_thread): Delete.
10517 (switch_to_program_space_and_thread): Moved to
10518 progspace-and-thread.c.
10519 * progspace.h (save_current_program_space)
10520 (save_current_space_and_thread): Delete declarations.
10521 (scoped_restore_current_program_space): New class.
10522 * remote.c (remote_btrace_maybe_reopen): Use
10523 scoped_restore_current_thread.
10524 * symtab.c: Include "progspace-and-thread.h".
10525 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
10526 * thread.c (print_thread_info_1): Use
10527 scoped_restore_current_thread.
10528 (struct current_thread_cleanup): Delete.
10529 (do_restore_current_thread_cleanup)
10530 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
10531 (scoped_restore_current_thread::~scoped_restore_current_thread):
10532 ... this new dtor.
10533 (make_cleanup_restore_current_thread): Rename/convert to ...
10534 (scoped_restore_current_thread::scoped_restore_current_thread):
10535 ... this new ctor.
10536 (thread_apply_all_command): Use scoped_restore_current_thread.
10537 (thread_apply_command): Use scoped_restore_current_thread.
10538 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
10539 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
10540
f6223dbb
PA
105412017-05-04 Pedro Alves <palves@redhat.com>
10542
10543 * thread.c (make_cleanup_restore_current_thread): Move
10544 find_thread_ptid call before the is_stopped call. Assert that the
10545 thread is found. Replace is_stopped call by checking the thread's
10546 state directly. Remove unnecessary NULL-thread check.
10547
3c3ae77e
PA
105482017-05-04 Pedro Alves <palves@redhat.com>
10549
10550 * corelow.c (thread_section_name): New class.
10551 (get_core_register_section, get_core_siginfo): Use it.
10552
45eba0ab
AA
105532017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
10554
10555 * corelow.c (sniff_core_bfd): Remove extra semicolon.
10556 (get_core_register_section): Remove xfree of NULL pointer.
10557
f81fdd35
AH
105582017-05-03 Alan Hayward <alan.hayward@arm.com>
10559
10560 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
10561 * regcache.c (regcache::raw_supply_zeroed): New function.
10562 * regcache.h (regcache::raw_supply_zeroed): New declaration.
10563
35837774
SM
105642017-05-03 Simon Marchi <simon.marchi@ericsson.com>
10565
10566 * gdbarch.sh: Remove commented out definition of
10567 TARGET_CHAR_BIT.
10568 * gdbarch.h: Re-generate.
10569
c94fee56
SDJ
105702017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
10571
10572 * configure: Regenerate.
10573
d17f7b36
SM
105742017-05-02 Simon Marchi <simon.marchi@ericsson.com>
10575
10576 * solib-target.c (solib_target_relocate_section_addresses):
10577 Remove num_section_bases, num_bases, segment_bases variables.
10578
b560ebd6
SM
105792017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10580
10581 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
10582
f2f46dfc
SM
105832017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10584
10585 * solib-target.c: Include <vector>
10586 (struct lm_info_target) <~lm_info_target>: Remove.
10587 <segment_bases, section_bases>: Change type to
10588 std::vector<CORE_ADDR>.
10589 (library_list_start_segment, library_list_start_section,
10590 library_list_end_library,
10591 solib_target_relocate_section_addresses): Adjust.
10592
a0ff9e1a
SM
105932017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10594
10595 * gdbarch.sh (software_single_step): Change return type to
10596 std::vector<CORE_ADDR>.
10597 * gdbarch.c, gdbarch.h: Re-generate.
10598 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
10599 Adjust.
10600 (arm_deal_with_atomic_sequence_raw): Adjust.
10601 (thumb_get_next_pcs_raw): Adjust.
10602 (arm_get_next_pcs_raw): Adjust.
10603 (arm_get_next_pcs): Adjust.
10604 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
10605 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
10606 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
10607 (alpha_software_single_step): Adjust.
10608 * alpha-tdep.h (alpha_software_single_step): Adjust.
10609 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
10610 * arm-tdep.c (arm_software_single_step): Adjust.
10611 (arm_breakpoint_kind_from_current_state): Adjust.
10612 * arm-tdep.h (arm_software_single_step): Adjust.
10613 * breakpoint.c (insert_single_step_breakpoint): Adjust.
10614 * cris-tdep.c (cris_software_single_step): Adjust.
10615 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
10616 (micromips_deal_with_atomic_sequence): Adjust.
10617 (deal_with_atomic_sequence): Adjust.
10618 (mips_software_single_step): Adjust.
10619 * mips-tdep.h (mips_software_single_step): Adjust.
10620 * moxie-tdep.c (moxie_software_single_step): Adjust.
10621 * nios2-tdep.c (nios2_software_single_step): Adjust.
10622 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
10623 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
10624 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
10625 * s390-linux-tdep.c (s390_software_single_step): Adjust.
10626 * sparc-tdep.c (sparc_software_single_step): Adjust.
10627 * spu-tdep.c (spu_software_single_step): Adjust.
10628 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
10629
ea480a30
SM
106302017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10631
10632 * gdbarch.sh: Use semi-colon as field separator instead of colon.
10633 * gdbarch.h: Re-generate.
10634
d050f7d7
TW
106352017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10636
10637 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
10638 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
10639 * python/py-instruction.c, python/py-instruction.h: New file.
10640 * python/py-record.c: Add py-instruction.h include.
10641 (gdbpy_initialize_record): Make gdb.Instruction a super class of
10642 gdb.RecordInstruction.
10643 * python/python-internal.h: Add gdbpy_initialize_instruction
10644 declaration.
10645 * python/python.c (do_start_initialization): Add
10646 gdbpy_initialize_instruction.
10647
14f819c8
TW
106482017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10649
10650 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
10651 Remove.
10652 (btrace_func_from_recpy_func): New function.
10653 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
10654 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
10655 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
10656 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
10657 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
10658 Also, use new helper functions.
10659 (btpy_list_item): Use new helper functions.
10660 (recpy_bt_function_call_history): Use new type name.
10661 (btpy_call_getset): Remove.
10662 (gdbpy_initialize_btrace): Remove code to initialize
10663 gdb.BtraceFunctionCall.
10664 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
10665 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
10666 recpy_bt_func_prev, recpy_bt_func_next): New export.
10667 * python/py-record.c (recpy_func_type): New static object.
10668 (recpy_func_new, recpy_func_level, recpy_func_symbol,
10669 recpy_func_instructions, recpy_func_up, recpy_func_prev,
10670 recpy_func_next): New function.
10671 (recpy_element_hash, recpy_element_richcompare): Updated comment.
10672 (recpy_func_getset): New static object.
10673 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
10674 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
10675
0ed5da75
TW
106762017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10677
10678 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
10679 (btpy_object, btpy_insn_type, btpy_new): Remove.
10680 (btpy_list_object): Use gdb.RecordInstruction type instead of
10681 gdb.BtraceInstruction type.
10682 (btrace_insn_from_recpy_insn): New function.
10683 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
10684 btpy_new.
10685 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
10686 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
10687 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
10688 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
10689 instead of btpy_object.
10690 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
10691 btpy_insn_data, btpy_insn_decode): Rename to ...
10692 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
10693 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
10694 recpy_bt_insn_decode): This. Also, use new helper functions.
10695 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
10696 recpy_insn_type.
10697 (btpy_insn_getset): Remove.
10698 (gdbpy_initialize_btrace): Remove code to initialize
10699 gdb.BtraceInstruction. Use recpy_element_object.
10700 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
10701 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
10702 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
10703 * python/py-record.c (recpy_insn_type): New static object.
10704 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
10705 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
10706 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
10707 New function.
10708 (recpy_insn_getset): New static object.
10709 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
10710 * python/py-record.h (recpy_element_object): New typedef.
10711 (recpy_insn_type, recpy_insn_new): New export.
10712
913aeadd
TW
107132017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10714
10715 * py-record-btrace.c (btpy_insn_new): Removed.
10716 (btpy_insn_or_gap_new): New function.
10717 (btpy_insn_error): Removed.
10718 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
10719 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
10720 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
10721 btpy_insn_or_gap_new instead of btpy_insn_new.
10722 (btpy_insn_getset): Remove btpy_insn_error.
10723 * py-record.c (recpy_gap_type): New static object.
10724 (recpy_gap_object): New typedef.
10725 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
10726 recpy_gap_reason_string): New function.
10727 (recpy_gap_getset): New static object.
10728 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
10729 * py-record.h (recpy_gap_new): New export.
10730
a3be24ad
TW
107312017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10732
10733 * python/py-record.c (recpy_ptid): Remove.
10734 (recpy_record_getset): Remove recpy_ptid.
10735
ae20e79a
TW
107362017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10737
10738 * btrace.c (btrace_fetch): Set inferior_ptid.
10739 * python/py-record-btrace.c: Add "py-record.h" include.
10740 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
10741 recpy_bt_end, recpy_bt_instruction_history,
10742 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
10743 in gdb.Record object instead of current ptid.
10744 * python/py-record.c: Include new "py-record.h" file.
10745 (recpy_record_object): Moved to py-record.h.
10746 * python/py-record.h: New file.
10747
8d0050ea
TW
107482017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10749
10750 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
10751 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
10752 indentation.
10753
3f380b50
JB
107542017-05-01 Joel Brobecker <brobecker@adacore.com>
10755
10756 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
10757 the past maintainers section.
10758
07495424
YQ
107592017-04-28 Yao Qi <yao.qi@linaro.org>
10760
10761 * infcmd.c (get_return_value): Use regcache ctor, and remove
10762 cleanup.
10763
deb1fa3e
YQ
107642017-04-28 Yao Qi <yao.qi@linaro.org>
10765 Pedro Alves <palves@redhat.com>
10766
10767 * regcache.c (regcache::regcache): New tag dispatch ctor.
10768 (do_cooked_read): Moved above.
10769 (regcache_dup): Use the tag dispatch ctor..
10770 * regcache.h (regcache): Declare ctor, delete copy ctor and
10771 assignment operator, remove friend regcache_dup.
10772
b421c83c
YQ
107732017-04-28 Yao Qi <yao.qi@linaro.org>
10774
10775 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
10776 call method save instead of regcache_cpy.
10777 * regcache.h (struct regcache): Make regcache_dup a friend.
10778
ef79d9a3
YQ
107792017-04-28 Yao Qi <yao.qi@linaro.org>
10780
10781 * regcache.c (struct regcache): Move to regcache.h
10782 (regcache::arch): New method.
10783 (regcache_get_ptid): Update.
10784 (get_regcache_arch): Call arch method.
10785 (get_regcache_aspace): Call method aspace.
10786 (register_buffer): Change it to method.
10787 (regcache_save): Change it to regcache::save.
10788 (regcache_restore): Likewise.
10789 (regcache_cpy_no_passthrough): Remove the declaration.
10790 (regcache_cpy): Call methods restore and cpy_no_passthrough.
10791 (regcache_cpy_no_passthrough): Change it to method
10792 cpy_no_passthrough.
10793 (regcache_register_status): Change it to method
10794 get_register_status.
10795 (regcache_invalidate): Change it to method invalidate.
10796 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
10797 (regcache_raw_update): Change it to method raw_update.
10798 (regcache_raw_read): Likewise.
10799 (regcache_raw_read_signed): Likewise.
10800 (regcache_raw_read_unsigned): Likewise.
10801 (regcache_raw_write_signed): Likewise.
10802 (regcache_raw_write_unsigned): Likewise.
10803 (regcache_cooked_read): Likewise.
10804 (regcache_cooked_read_value): Likewise.
10805 (regcache_cooked_read_signed): Likewise.
10806 (regcache_cooked_read_unsigned): Likewise.
10807 (regcache_cooked_write_signed): Likewise.
10808 (regcache_cooked_write_unsigned): Likewise.
10809 (regcache_raw_set_cached_value): Likewise.
10810 (regcache_raw_write): Likewise.
10811 (regcache_cooked_write): Likewise.
10812 (regcache_xfer_part): Likewise.
10813 (regcache_raw_read_part): Likewise.
10814 (regcache_raw_write_part): Likewise.
10815 (regcache_cooked_read_part): Likewise.
10816 (regcache_cooked_write_part): Likewise.
10817 (regcache_raw_supply): Likewise.
10818 (regcache_raw_collect): Likewise.
10819 (regcache_transfer_regset): Likewise.
10820 (regcache_supply_regset): Likewise.
10821 (regcache_collect_regset): Likewise.
10822 (regcache_debug_print_register): Likewise.
10823 (enum regcache_dump_what): Move it to regcache.h.
10824 (regcache_dump): Change it to method dump.
10825 * regcache.h (enum regcache_dump_what): New.
10826 (class regcache): New.
10827 * target.c (target_fetch_registers): Call method
10828 debug_print_register.
10829 (target_store_registers): Likewise.
10830
f8fdb78e
SM
108312017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10832
10833 * windows-nat.c (struct lm_info_windows): Initialize field.
10834 (windows_make_so): Allocate lm_info_windows with new.
10835 (windows_free_so): Free lm_info_windows with delete.
10836
9ccbfd7b
SM
108372017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10838
10839 * solib-darwin.c (struct lm_info_darwin): Initialize field.
10840 (darwin_current_sos): Allocate lm_info_darwin with new, remove
10841 cleanup.
10842 (darwin_free_so): Free lm_info_darwin with delete.
10843
76e75227
SM
108442017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10845
10846 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
10847 <l_addr_p>: Change type to bool.
10848 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
10849 (svr4_free_so): Free lm_info_svr4 with delete.
10850 (svr4_copy_library_list): Replace memcpy with call to copy
10851 constructor.
10852 (library_list_start_library, svr4_default_sos): Allocate
10853 lm_info_svr4 with new.
10854
51046d9e
SM
108552017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10856
10857 * solib-target.c (struct lm_info_target): Add destructor,
10858 initialize fields.
10859 <name>: Change type to std::string.
10860 (library_list_start_library): Allocate lm_info_target with new.
10861 (solib_target_free_library_list): Free lm_info_target with
10862 delete.
10863 (solib_target_current_sos): Adapt to std::string.
10864 (solib_target_free_so): Free lm_info_target with delete.
10865
4023ae76
SM
108662017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10867
10868 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
10869 fields.
10870 (frv_current_sos): Allocate lm_info_frv with new.
10871 (frv_relocate_main_executable): Free lm_info_frv with delete,
10872 allocate with new.
10873 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
10874
af43057b
SM
108752017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10876
10877 * solib-frv.c (struct lm_info_frv): Fix indentation.
10878
b0911207
SM
108792017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10880
10881 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
10882 map field.
10883 (dsbt_current_sos): Allocate lm_info_dsbt with new.
10884 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
10885 and allocate with new.
10886 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
10887
6c401f72
SM
108882017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10889
10890 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
10891 <filename, member_name>: Change type to std::string.
10892 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
10893 (library_list_start_library): Allocate lm_info_aix with new.
10894 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
10895 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
10896 with copy constructor.
10897
d0e449a1
SM
108982017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10899
10900 * solist.h (struct lm_info): Remove.
10901 (struct lm_info_base): New class.
10902 (struct so_list) <lm_info>: Change type to lm_info_base *.
10903 * nto-tdep.c (struct lm_info): Remove.
10904 (lm_addr): Adjust.
10905 * solib-aix.c (struct lm_info): Rename to ...
10906 (struct lm_info_aix): ... this. Extend lm_info_base.
10907 (lm_info_p): Rename to ...
10908 (lm_info_aix_p): ... this, and adjust.
10909 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
10910 solib_aix_parse_libraries, library_list_start_library,
10911 solib_aix_free_library_list, solib_aix_parse_libraries,
10912 solib_aix_get_library_list,
10913 solib_aix_relocate_section_addresses, solib_aix_free_so,
10914 solib_aix_get_section_offsets,
10915 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
10916 Adjust.
10917 (struct solib_aix_inferior_data) <library_list>: Adjust.
10918 * solib-darwin.c (struct lm_info): Rename to ...
10919 (struct lm_info_darwin): ... this. Extend lm_info_base.
10920 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
10921 * solib-dsbt.c (struct lm_info): Rename to ...
10922 (struct lm_info_dsbt): ... this. Extend lm_info_base.
10923 (struct dsbt_info) <main_executable_lm_info): Adjust.
10924 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
10925 dsbt_relocate_section_addresses): Adjust.
10926 * solib-frv.c (struct lm_info): Rename to ...
10927 (struct lm_info_frv): ... this. Extend lm_info_base.
10928 (main_executable_lm_info): Adjust.
10929 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
10930 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
10931 find_canonical_descriptor_in_load_object,
10932 frv_fdpic_find_canonical_descriptor): Adjust.
10933 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
10934 to lm_info_svr4.
10935 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
10936 svr4_clear_so, svr4_copy_library_list,
10937 library_list_start_library, svr4_default_sos, svr4_read_so_list,
10938 svr4_current_sos, svr4_fetch_objfile_link_map,
10939 solist_update_incremental): Adjust.
10940 * solib-svr4.h (struct lm_info_svr4): Move here from
10941 solib-svr4.c.
10942 * solib-target.c (struct lm_info): Rename to ...
10943 (struct lm_info_target): ... this. Extend lm_info_base.
10944 (lm_info_p): Rename to ...
10945 (lm_info_target_p): ... this.
10946 (solib_target_parse_libraries, library_list_start_segment,
10947 library_list_start_section, library_list_start_library,
10948 library_list_end_library, solib_target_free_library_list,
10949 solib_target_current_sos, solib_target_free_so,
10950 solib_target_relocate_section_addresses): Adjust.
10951 * windows-nat.c (struct lm_info): Rename to ...
10952 (struct lm_info_windows): ... this. Extend lm_info_base.
10953 (windows_make_so, handle_load_dll, handle_unload_dll,
10954 windows_xfer_shared_libraries): Adjust.
10955
434a4023
SM
109562017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10957
10958 * solib-darwin.c (struct darwin_so_list): Remove.
10959 (darwin_current_sos): Allocate an so_list object instead of a
10960 darwin_so_list, separately allocate an lm_info object.
10961 (darwin_free_so): Free lm_info.
10962
428544e8
JB
109632017-04-28 John Baldwin <jhb@FreeBSD.org>
10964
10965 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
10966 with fprintf_filtered.
10967
4621115f
YQ
109682017-04-28 Yao Qi <yao.qi@linaro.org>
10969
10970 * regcache.c (regcache::regcache): New function.
10971 (regcache::~regcache): New function.
10972 (regcache_xmalloc_1): Remove.
10973 (regcache_xmalloc): Call new regcache.
10974 (regcache_xfree): Call delete regcache.
10975 (get_thread_arch_aspace_regcache): Call new regcache.
10976
339053c2
YQ
109772017-04-28 Yao Qi <yao.qi@linaro.org>
10978
10979 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
10980 lwp instead of ptid_get_lwp.
10981
7974a605
YQ
109822017-04-28 Yao Qi <yao.qi@linaro.org>
10983
10984 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
10985 lwp_info instead of getting from inferior_ptid.
10986
e15c3eb4
KS
109872017-04-27 Keith Seitz <keiths@redhat.com>
10988
10989 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
10990 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
10991 (CV_CONVERSION_BADNESS): Define.
10992 (rank_one_type): Remove overly restrictive rvalue reference
10993 rank checks.
10994 Add cv-qualifier checks and subranks for type equality.
10995 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
10996 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
10997 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
10998
72bc1d24
SM
109992017-04-27 Simon Marchi <simon.marchi@ericsson.com>
11000
11001 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
11002 count when creating the object.
11003
55bcecda
UW
110042017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
11005 Ulrich Weigand <uweigand@de.ibm.com>
11006
11007 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
11008 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
11009 is used in AIX.
11010 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
11011 (process_xcoff_symbol): Likewise.
11012 (scan_xcoff_symtab): Likewise.
11013
5c99fcf8
AH
110142017-04-26 Alan Hayward <alan.hayward@arm.com>
11015
11016 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
11017 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
11018 (ia64_access_reg): Use get_frame_register_unsigned.
11019 (ia64_access_rse_reg): Likewise.
11020 (ia64_libunwind_frame_prev_register): Likewise.
11021
b41c5a85
JW
110222017-04-26 Jiong Wang <jiong.wang@arm.com>
11023
11024 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
11025 * gdbarch.c: Regenerated.
11026 * gdbarch.h: Regenerated.
11027 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
11028 visibility external.
11029 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
11030 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
11031 (enum cfa_how_kind): Move to ...
11032 (struct dwarf2_frame_state_reg_info): Likewise.
11033 (struct dwarf2_frame_state): Likewise.
11034 * dwarf2-frame.h: ... here.
11035 (dwarf2_frame_state_alloc_regs): New declaration.
11036 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
11037 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
11038
c185f580
AH
110392017-04-26 Alan Hayward <alan.hayward@arm.com>
11040
11041 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
11042 regcache_raw_read_unsigned.
11043 (xtensa_pseudo_register_write): Likewise.
11044
19c45594
AH
110452017-04-26 Alan Hayward <alan.hayward@arm.com>
11046
11047 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
11048 (nds32_pseudo_register_write): Likewise.
11049
4658f12e
YQ
110502017-04-25 Yao Qi <yao.qi@linaro.org>
11051
11052 * regcache.c (struct regcache) <readonly_p>: Change its type
11053 to bool.
11054 (regcache_xmalloc_1): Update parameter type and callers update.
11055
d581dda8
YQ
110562017-04-25 Yao Qi <yao.qi@linaro.org>
11057
11058 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
11059 set_gdbarch_wchar_bit.
11060 * arm-tdep.c (arm_gdbarch_init): Likewise.
11061
debed3db
PA
110622017-04-25 Pedro Alves <palves@redhat.com>
11063
11064 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
11065 (BothAreRelocatable, memcopy, memmove): Don't define.
11066 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
11067 macros.
11068
b0b92aeb
PA
110692017-04-25 Pedro Alves <palves@redhat.com>
11070
11071 * common/common-defs.h: Include "common/poison.h".
11072 * common/function-view.h: (Not, Or, Requires): Move to traits.h
11073 and adjust.
11074 * common/poison.h: New file.
11075 * common/traits.h: Include <type_traits>.
11076 (Not, Or, Requires): New, moved from common/function-view.h.
11077
16c4d54a
PA
110782017-04-25 Pedro Alves <palves@redhat.com>
11079
11080 * breakpoint.h (struct breakpoint): In-class initialize all
11081 fields. Make boolean fields "bool".
11082 * breakpoint.c (init_raw_breakpoint_without_location): Remove
11083 memset call and initializations no longer necessary.
11084
b5c36682
PA
110852017-04-25 Pedro Alves <palves@redhat.com>
11086
11087 * btrace.c (pt_btrace_insn_flags): Change parameter type to
11088 reference.
11089 (pt_btrace_insn): New function.
11090 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
11091
5625a286
PA
110922017-04-25 Pedro Alves <palves@redhat.com>
11093
11094 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
11095 "base" field and inherit from "bp_location" instead. Add
11096 non-default ctor.
11097 (allocate_location_exception): Use new non-default ctor.
11098 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
11099 (init_bp_location): Convert to ...
11100 (bp_location::bp_location): ... this new ctor, and remove memset
11101 call.
11102 (base_breakpoint_allocate_location): Use the new non-default ctor.
11103 * breakpoint.h (bp_location): Now a class. Declare default and
11104 non-default ctors. In-class initialize all members.
11105 (init_bp_location): Remove declaration.
11106
23bcc18f
PA
111072017-04-25 Pedro Alves <palves@redhat.com>
11108
11109 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
11110 assignment operator.
11111
e1ba3053
YQ
111122017-04-24 Yao Qi <yao.qi@linaro.org>
11113
11114 * doublest.c (convert_doublest_to_floatformat): Call
11115 floatformat_totalsize_bytes.
11116
10f489e5
TT
111172017-04-22 Tom Tromey <tom@tromey.com>
11118
11119 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
11120 ui_out_emit_list.
11121 * stack.c (print_frame): Use ui_out_emit_list.
11122 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
11123 ui_out_emit_list.
11124 * mi/mi-main.c (print_one_inferior)
11125 (mi_cmd_data_list_register_names)
11126 (mi_cmd_data_list_register_values, mi_cmd_list_features)
11127 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
11128 ui_out_emit_list.
11129 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
11130 (mi_output_solib_attribs): Use ui_out_emit_list,
11131 ui_out_emit_tuple.
11132 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
11133 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
11134 (mi_cmd_stack_list_args, list_args_or_locals): Use
11135 ui_out_emit_list.
11136 * disasm.c (do_assembly_only): Use ui_out_emit_list.
11137 * breakpoint.c (print_solib_event, output_thread_groups): Use
11138 ui_out_emit_list.
11139
0092b74d
TT
111402017-04-22 Tom Tromey <tom@tromey.com>
11141
11142 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
11143 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
11144 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
11145
a14a62dd
TT
111462017-04-22 Tom Tromey <tom@tromey.com>
11147
11148 * tracepoint.c (tvariables_info_1)
11149 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
11150
46b9c129
TT
111512017-04-22 Tom Tromey <tom@tromey.com>
11152
11153 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
11154 annotate_arg_emitter.
11155 * breakpoint.c (print_mention_watchpoint)
11156 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
11157 * annotate.h (struct annotate_arg_emitter): New.
11158
2e783024
TT
111592017-04-22 Tom Tromey <tom@tromey.com>
11160
11161 * record-btrace.c (record_btrace_insn_history)
11162 (record_btrace_insn_history_range, record_btrace_call_history)
11163 (record_btrace_call_history_range): Use ui_out_emit_tuple.
11164 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
11165 ui_out_emit_tuple.
11166 * stack.c (print_frame_info): Use ui_out_emit_tuple.
11167 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
11168 * skip.c (skip_info): Use ui_out_emit_tuple.
11169 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
11170 * progspace.c (print_program_space): Use ui_out_emit_tuple.
11171 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
11172 * osdata.c (info_osdata): Use ui_out_emit_tuple.
11173 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
11174 ui_out_emit_tuple.
11175 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
11176 (output_register, mi_cmd_data_read_memory)
11177 (mi_cmd_data_read_memory_bytes, mi_load_progress)
11178 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
11179 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
11180 Use ui_out_emit_tuple.
11181 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
11182 ui_out_emit_tuple.
11183 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
11184 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
11185 * linux-thread-db.c (info_auto_load_libthread_db): Use
11186 ui_out_emit_tuple.
11187 * inferior.c (print_inferior): Use ui_out_emit_tuple.
11188 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
11189 * disasm.c (do_mixed_source_and_assembly_deprecated)
11190 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
11191 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
11192 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
11193 * breakpoint.c (print_one_breakpoint_location)
11194 (print_one_breakpoint): Use ui_out_emit_tuple.
11195 * auto-load.c (print_script, info_auto_load_cmd): Use
11196 ui_out_emit_tuple.
11197 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
11198
9be21bb4
SM
111992017-04-21 Simon Marchi <simon.marchi@ericsson.com>
11200
11201 * thread.c (print_thread_info_1): Remove dead code.
11202
0d4c07af
JK
112032017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11204
11205 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
11206 GDB_SELF_TEST.
11207 * arm-tdep.c (selftests::arm_record_test): Likewise.
11208
4daf993d
YQ
112092017-04-21 Yao Qi <yao.qi@linaro.org>
11210
11211 * regcache.c (regcache_restore): Remove argument 2. Replace
11212 argument 3 with regcache. Get register status from
11213 src->register_status and get register contents from
11214 register_buffer (src, regnum).
11215 (regcache_cpy): Update.
11216
a6c21d4a
PA
112172017-04-19 Pedro Alves <palves@redhat.com>
11218
11219 * gdbthread.h (thread): Add missing closing parenthesis in
11220 comment.
11221
3a3fd0fd
PA
112222017-04-19 Pedro Alves <palves@redhat.com>
11223
11224 * common/refcounted-object.h: New file.
11225 * gdbthread.h: Include "common/refcounted-object.h".
11226 (thread_info): Inherit from refcounted_object and add comments.
11227 (thread_info::incref, thread_info::decref)
11228 (thread_info::m_refcount): Delete.
11229 (thread_info::deletable): Use the refcounted_object::refcount()
11230 method.
11231 * inferior.c (current_inferior_): Add comment.
11232 (set_current_inferior): Increment/decrement refcounts.
11233 (prune_inferiors, remove_inferior_command): Skip inferiors marked
11234 not-deletable instead of comparing with the current inferior.
11235 (initialize_inferiors): Increment the initial inferior's refcount.
11236 * inferior.h (struct inferior): Forward declare.
11237 Include "common/refcounted-object.h".
11238 (current_inferior, set_current_inferior): Move declaration to
11239 before struct inferior's definition, and fix comment.
11240 (inferior): Inherit from refcounted_object. Add comments.
11241 * thread.c (switch_to_thread_no_regs): Reference the thread's
11242 inferior pointer directly instead of doing a ptid lookup.
11243 (switch_to_no_thread): New function.
11244 (switch_to_thread(thread_info *)): New function, factored out
11245 from ...
11246 (switch_to_thread(ptid_t)): ... this.
11247 (restore_current_thread): Delete.
11248 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
11249 fields, and add 'inf' field.
11250 (do_restore_current_thread_cleanup): Check whether old->inf is
11251 alive instead of looking up an inferior by ptid. Use
11252 switch_to_thread and switch_to_no_thread.
11253 (restore_current_thread_cleanup_dtor): Use old->inf directly
11254 instead of lookup up an inferior by id. Decref the inferior.
11255 Don't restore 'removable'.
11256 (make_cleanup_restore_current_thread): Same the inferior pointer
11257 in old, instead of the inferior number. Incref the inferior.
11258 Don't save/clear 'removable'.
11259
9bcb1f16
PA
112602017-04-19 Pedro Alves <palves@redhat.com>
11261
11262 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11263 unittests/scoped_restore-selftests.c.
11264 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
11265 * common/scoped_restore.h (scoped_restore_base): Make "class".
11266 (scoped_restore_base::release): New public method.
11267 (scoped_restore_base::scoped_restore_base): New protected ctor.
11268 (scoped_restore_base::m_saved_var): New protected field.
11269 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
11270 scoped_restore_base base class instead of m_saved_var directly.
11271 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
11272 (scoped_restore_tmpl::scoped_restore_tmpl(const
11273 scoped_restore_tmpl<T>&)): Likewise.
11274 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
11275 method.
11276 (scoped_restore_tmpl::saved_var): New method.
11277 (scoped_restore_tmpl::m_saved_var): Delete.
11278 * inferior.h (inferior::detaching): Now a bool.
11279 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
11280 cleanup.
11281 * unittests/scoped_restore-selftests.c: New file.
11282
26fcd539
PA
112832017-04-19 Pedro Alves <palves@redhat.com>
11284
11285 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
11286 Re-sort in alphabetic order.
11287
fdd243b0
PA
112882017-04-18 Pedro Alves <palves@redhat.com>
11289
11290 * xml-support.c (obstack_xml_printf): Delete.
11291 * xml-support.h (obstack_xml_printf): Delete.
11292
4895cde2
PA
112932017-04-18 Pedro Alves <palves@redhat.com>
11294
11295 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
11296 vdebug, verror, body_text, start_element, end_element, name,
11297 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
11298 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
11299 is_xinclude>: Make private and add m_ prefix.
11300 (gdb_xml_parser::body_text): New method, based on ...
11301 (gdb_xml_body_text): ... this. Adjust.
11302 (gdb_xml_parser::vdebug): New method, based on ...
11303 (gdb_xml_debug): ... this. Adjust.
11304 (gdb_xml_parser::verror): New method, based on ...
11305 (gdb_xml_error): ... this. Adjust.
11306 (gdb_xml_parser::start_element): New method, based on ...
11307 (gdb_xml_start_element): ... this. Adjust.
11308 (gdb_xml_start_element_wrapper): Defer to
11309 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
11310 (gdb_xml_parser::end_element): New method, based on ...
11311 (gdb_xml_end_element_wrapper): ... this. Adjust.
11312 (gdb_xml_parser::~gdb_xml_parser): Adjust.
11313 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
11314 (gdb_xml_parser::use_dtd): New method, based on ...
11315 (gdb_xml_use_dtd): ... this. Adjust.
11316 (gdb_xml_parser::parse): New method, based on ...
11317 (gdb_xml_parse): ... this. Adjust.
11318 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
11319 (xinclude_start_include): Adjust to call the parser's name method.
11320 (xml_xinclude_default, xml_xinclude_start_doctype)
11321 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
11322 method.
11323 (xml_process_xincludes): Adjust to call parser methods.
11324 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
11325 declarations.
11326
bd8a901f
PA
113272017-04-18 Pedro Alves <palves@redhat.com>
11328
11329 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
11330 gdb::optional<std::string>.
11331 * xml-support.c: Include <string>.
11332 (scope_level::scope_level(scope_level &&))
11333 (scope_level::~scope_level): Delete.
11334 (scope_level::body): Now a std::string.
11335 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
11336 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
11337 parameter.
11338 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
11339 (xinclude_parsing_data::output): Now a std::string reference.
11340 (xinclude_start_include): Adjust.
11341 (xml_xinclude_default): Adjust.
11342 (xml_process_xincludes): Add 'output' parameter, and return bool.
11343 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
11344 and return bool.
11345 * xml-tdesc.c: Include <unordered_map> and <string>.
11346 (tdesc_xml_cache): Delete.
11347 (tdesc_xml_cache_s): Delete.
11348 (xml_cache): Now an std::unordered_map.
11349 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
11350 (target_fetch_description_xml): Change return type to
11351 gdb::optional<std::string>, and adjust.
11352 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
11353 (target_fetch_description_xml): Change return type to
11354 gdb::optional<std::string>.
11355
d35d1958
PA
113562017-04-18 Pedro Alves <palves@redhat.com>
11357
11358 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11359 unittests/optional-selftests.c.
11360 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
11361 * unittests/optional-selftests.c: New file.
11362 * unittests/optional/assignment/1.cc: New file.
11363 * unittests/optional/assignment/2.cc: New file.
11364 * unittests/optional/assignment/3.cc: New file.
11365 * unittests/optional/assignment/4.cc: New file.
11366 * unittests/optional/assignment/5.cc: New file.
11367 * unittests/optional/assignment/6.cc: New file.
11368 * unittests/optional/assignment/7.cc: New file.
11369 * unittests/optional/cons/copy.cc: New file.
11370 * unittests/optional/cons/default.cc: New file.
11371 * unittests/optional/cons/move.cc: New file.
11372 * unittests/optional/cons/value.cc: New file.
11373 * unittests/optional/in_place.cc: New file.
11374 * unittests/optional/observers/1.cc: New file.
11375 * unittests/optional/observers/2.cc: New file.
11376
22796e97
PA
113772017-04-18 Pedro Alves <palves@redhat.com>
11378
11379 * common/gdb_optional.h: Include common/traits.h.
11380 (in_place_t): New type.
11381 (in_place): New constexpr variable.
11382 (optional::optional): Remove member initialization of
11383 m_instantiated.
11384 (optional::optional(in_place_t...)): New constructor.
11385 (optional::~optional): Use reset.
11386 (optional::optional(const optional&)): New.
11387 (optional::optional(const optional&&)): New.
11388 (optional::optional(T &)): New.
11389 (optional::optional(T &&)): New.
11390 (operator::operator=(const optional &)): New.
11391 (operator::operator=(optional &&)): New.
11392 (operator::operator= (const T &))
11393 (operator::operator= (T &&))
11394 (operator::emplace (Args &&... args)): Return a T&. Use reset.
11395 (operator::reset): New.
11396 (operator::m_instantiated):: Add in-class initializer.
11397 * common/traits.h: Include <type_traits>.
11398 (struct And): New types.
11399
a7fc9b61
PA
114002017-04-18 Pedro Alves <palves@redhat.com>
11401
11402 * xml-support.c: Include <vector>.
11403 (scope_level::scope_level(const gdb_xml_element *))
11404 (scope_level::scope_level(scope_level&&)): New.
11405 (scope_level::~scope_level): New.
11406 (scope_level_s): Delete.
11407 (gdb_xml_parser::scopes): Now a std::vector.
11408 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
11409 Use std::vector.
11410 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
11411 scope cleanup code.
11412 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
11413 of the scopes member. Use std::vector::emplace_back.
11414
010151c9
PA
114152017-04-18 Pedro Alves <palves@redhat.com>
11416
11417 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
11418 a bool.
11419 (gdb_xml_end_element): Change type of first parameter.
11420 (gdb_xml_cleanup): Rename to ...
11421 (gdb_xml_parser::~gdb_xml_parser): ... this.
11422 (gdb_xml_create_parser_and_cleanup): Delete with ...
11423 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
11424 to this new ctor.
11425 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
11426 using gdb_xml_create_parser_and_cleanup.
11427 (xinclude_parsing_data): Add ctor/dtor.
11428 (xml_xinclude_cleanup): Delete.
11429 (xml_process_xincludes): Create a local xinclude_parsing_data
11430 instead of heap-allocating one. Create a local gdb_xml_parser
11431 instead of heap-allocating one with
11432 gdb_xml_create_parser_and_cleanup.
11433
d56060f0
JB
114342017-04-18 John Baldwin <jhb@FreeBSD.org>
11435
11436 PR threads/20743
11437 * fbsd-nat.c (resume_one_thread_cb): Remove.
11438 (resume_all_threads_cb): Remove.
11439 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
11440 iterate_over_threads.
11441
305d16a9
JB
114422017-04-17 Joel Brobecker <brobecker@adacore.com>
11443
11444 * NEWS: Create a new section for the next release branch.
11445 Rename the section of the current branch, now that it has
11446 been cut.
11447
8bb57231
JB
114482017-04-17 Joel Brobecker <brobecker@adacore.com>
11449
11450 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
11451 * version.in: Bump version to 8.0.50.DATE-git.
11452
096c92dd
SDJ
114532017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
11454
11455 PR gdb/21385
11456 * windows-nat.c (windows_create_inferior): Declare 'allargs'
11457 independently of the host, and fix build breakage on Cygwin.
11458
0550c955
PA
114592017-04-13 Pedro Alves <palves@redhat.com>
11460
11461 * inferior.c (free_inferior): Convert to ...
11462 (inferior::~inferior): ... this dtor.
11463 (inferior::inferior): New ctor, factored out from ...
11464 (add_inferior_silent): ... here. Allocate the inferior with a new
11465 expression.
11466 (delete_inferior): Call delete instead of free_inferior.
11467 * inferior.h (gdb_environ, continuation): Forward declare.
11468 (inferior): Now a class. Add in-class initialization to all
11469 members. Make boolean fields bool, except 'detaching'.
11470 (inferior::inferior): New explicit ctor.
11471 (inferior::~inferior): New.
11472
e3d60dfc
PA
114732017-04-13 Pedro Alves <palves@redhat.com>
11474
11475 * inferior.c (init_inferior_list): Delete.
11476 * inferior.h (init_inferior_list): Delete.
11477
5fd69d0a
PA
114782017-04-13 Pedro Alves <palves@redhat.com>
11479
11480 PR threads/13217
11481 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
11482 (top level): Call it twice, with different thread sets.
11483
c6609450
PA
114842017-04-13 Pedro Alves <palves@redhat.com>
11485
11486 * thread.c: Include <algorithm>.
11487 (thread_array_cleanup): Delete.
11488 (scoped_inc_dec_ref): New class.
11489 (live_threads_count): New function.
11490 (set_thread_refcount): Delete.
11491 (tp_array_compar_ascending): Now a bool.
11492 (tp_array_compar): Convert to a std::sort comparison function.
11493 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
11494 and live_threads_count.
11495
2a00d7ce
PA
114962017-04-13 Pedro Alves <palves@redhat.com>
11497
11498 * infrun.c (follow_fork_inferior): Also switch the current
11499 inferior.
11500
441d7c93
PA
115012017-04-13 Pedro Alves <palves@redhat.com>
11502
11503 * breakpoint.c (watch_command_1): Save watchpoint-frame info
11504 before calling create_internal_breakpoint.
11505
808480f6
PA
115062017-04-13 Pedro Alves <palves@redhat.com>
11507
11508 * fork-child.c (execv_argv): New class.
11509 (breakup_args): Refactored as ...
11510 (execv_argv::init_for_no_shell): .. this method of execv_argv.
11511 Copy arguments to storage and replace separators with NULL
11512 terminators in place.
11513 (escape_bang_in_quoted_argument): Adjust to return bool.
11514 (execv_argv::execv_argv): New ctor.
11515 (execv_argv::init_for_shell): New method, factored out from
11516 fork_inferior. Don't strdup strings into the vector.
11517 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
11518 Remove free_vector_argv call.
11519
ad3d022a
YQ
115202017-04-13 Yao Qi <yao.qi@linaro.org>
11521
11522 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
11523 tdep->rx_psw_type.
11524
e6ddc3bf
YQ
115252017-04-13 Yao Qi <yao.qi@linaro.org>
11526
11527 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
11528 * rx-tdep.c (rx_gdbarch_init): Likewise.
11529
bfb8cf90
PA
115302017-04-13 Pedro Alves <palves@redhat.com>
11531
11532 * breakpoint.h (struct breakpoint): Reindent.
11533
f5336ca5
PA
115342017-04-13 Pedro Alves <palves@redhat.com>
11535
11536 * breakpoint.c (bp_location): Rename to ...
11537 (bp_locations): ... this. All references updated.
11538 (bp_location_count): Rename to ...
11539 (bp_locations_count): ... this. All references updated.
11540 (bp_location_placed_address_before_address_max): Rename to ...
11541 (bp_locations_placed_address_before_address_max): ... this. All
11542 references updated.
11543 (bp_location_shadow_len_after_address_max): Rename to ...
11544 (bp_locations_shadow_len_after_address_max): ... this. All
11545 references updated.
11546 (bp_location_compare_addrs): Rename to ...
11547 (bp_locations_compare_addrs): ... this. All references updated.
11548 (bp_location_compare):Rename to ...
11549 (bp_locations_compare): ... this. All references updated.
11550 (bp_location_target_extensions_update): Rename to ...
11551 (bp_locations_target_extensions_update): ... this. All references
11552 updated.
11553
be628ab8
SDJ
115542017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11555
11556 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
11557 * common/common.m4: Check headers 'termios.h', 'termio.h' and
11558 'sgtty.h'.
11559 * common/gdb_termios.h: New file, with parts of "terminal.h".
11560 * inflow.c: Include "gdb_termios.h".
11561 * ser-unix.c: Include "gdb_termios.h".
11562 * terminal.h: Move terminal-related defines to
11563 "common/gdb_termios.h".
11564
8e9e35b1
TT
115652017-04-12 Tom Tromey <tom@tromey.com>
11566
11567 * probe.c (parse_probes): Update.
11568 * location.h (delete_event_location): Don't declare.
11569 (event_location_deleter::operator()): Update.
11570 * location.c (event_location_deleter::operator()): Rename from
11571 delete_event_location.
11572 * linespec.h (linespec_result) <location>: Change type to
11573 event_location_up.
11574 * linespec.c (canonicalize_linespec, event_location_to_sals)
11575 (decode_objc): Update.
11576 (linespec_result): Don't call delete_event_location.
11577 * breakpoint.c (create_breakpoints_sal)
11578 (bkpt_probe_create_sals_from_location)
11579 (strace_marker_create_sals_from_location): Update.
11580
16e802b9
TT
115812017-04-12 Tom Tromey <tom@tromey.com>
11582
11583 * linespec.h (struct linespec_result): Add constructor and
11584 destructor.
11585 (init_linespec_result, destroy_linespec_result)
11586 (make_cleanup_destroy_linespec_result): Don't declare.
11587 * linespec.c (init_linespec_result): Remove.
11588 (linespec_result::~linespec_result): Rename from
11589 destroy_linespec_result. Update.
11590 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
11591 Remove.
11592 * breakpoint.c (create_breakpoint, break_range_command)
11593 (decode_location_default): Update.
11594 * ax-gdb.c (agent_command_1): Update.
11595
d28cd78a
TT
115962017-04-12 Tom Tromey <tom@tromey.com>
11597
11598 * remote.c (remote_download_tracepoint): Update.
11599 * python/py-breakpoint.c (bppy_get_location): Update.
11600 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
11601 (gdbscm_breakpoint_location): Update.
11602 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
11603 * breakpoint.h (struct breakpoint) <location, location_range_end>:
11604 Change type to event_location_up.
11605 * breakpoint.c (create_overlay_event_breakpoint)
11606 (create_longjmp_master_breakpoint)
11607 (create_std_terminate_master_breakpoint)
11608 (create_exception_master_breakpoint)
11609 (breakpoint_event_location_empty_p, print_breakpoint_location)
11610 (print_one_breakpoint_location, create_thread_event_breakpoint)
11611 (init_breakpoint_sal, create_breakpoint)
11612 (print_recreate_ranged_breakpoint, break_range_command)
11613 (init_ada_exception_breakpoint, say_where): Update.
11614 (base_breakpoint_dtor): Don't call delete_event_location.
11615 (bkpt_print_recreate, tracepoint_print_recreate)
11616 (dprintf_print_recreate, update_static_tracepoint)
11617 (breakpoint_re_set_default): Update.
11618
711799d5
TT
116192017-04-12 Tom Tromey <tom@tromey.com>
11620
11621 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
11622 type of "to_do". Update.
11623 (compute_stack_depth): Use std::vector.
11624
52d214d3
TT
116252017-04-12 Tom Tromey <tom@tromey.com>
11626
11627 * printcmd.c (find_instruction_backward): Use std::vector.
11628
4c404b8b
TT
116292017-04-12 Tom Tromey <tom@tromey.com>
11630
11631 * symfile.c (objfilep): Remove typedef.
11632 (reread_symbols): Use a std::vector.
11633
156d9eab
TT
116342017-04-12 Tom Tromey <tom@tromey.com>
11635
11636 * mi/mi-main.c (exec_direction_forward): Remove.
11637 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
11638 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
11639 scoped_restore.
11640 * guile/guile.c (guile_repl_command, guile_command)
11641 (gdbscm_execute_gdb_command): Use scoped_restore.
11642 * go-exp.y (go_parse): Use scoped_restore.
11643 * d-exp.y (d_parse): Use scoped_restore.
11644 * cli/cli-decode.c (cmd_func): Use scoped_restore.
11645 * c-exp.y (c_parse): Use scoped_restore.
11646
4d89769a
TT
116472017-04-12 Tom Tromey <tom@tromey.com>
11648
11649 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
11650 (mi_parse): Update return type.
11651 (mi_parse_free): Remove.
11652 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
11653 (mi_parse::~mi_parse): Rename from mi_parse_free.
11654 (mi_parse_cleanup): Remove.
11655 (mi_parse): Return a unique_ptr. Use new.
11656 * mi/mi-main.c (mi_execute_command): Update.
11657
4b217cc7
TT
116582017-04-12 Tom Tromey <tom@tromey.com>
11659
11660 * location.c (explicit_location_lex_one): Return a
11661 unique_xmalloc_ptr.
11662 (string_to_explicit_location): Update. Remove cleanups.
11663
59d3651b
TT
116642017-04-12 Tom Tromey <tom@tromey.com>
11665
11666 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
11667 (compare_value_and_voffset): Change type. Update.
11668 (compute_vtable_size): Change type of "offset_vec".
11669 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
11670 (gnuv3_get_typeid): Remove extraneous declaration.
11671
b24b0d6c
TT
116722017-04-12 Tom Tromey <tom@tromey.com>
11673
11674 * charset.h (wchar_iterator): Fix comment.
11675
80a3b8c5
TT
116762017-04-12 Tom Tromey <tom@tromey.com>
11677
11678 * charset.c (iconv_wrapper): New class.
11679 (cleanup_iconv): Remove.
11680 (convert_between_encodings): Use it.
11681
c83dd867
TT
116822017-04-12 Tom Tromey <tom@tromey.com>
11683
11684 * symfile.h (increment_reading_symtab): Update type.
11685 * symfile.c (decrement_reading_symtab): Remove.
11686 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
11687 * psymtab.c (psymtab_to_symtab): Update.
11688 * dwarf2read.c (dw2_instantiate_symtab): Update.
11689
0e8621a0
TT
116902017-04-12 Tom Tromey <tom@tromey.com>
11691
11692 * jit.c (struct jit_reader): Declare separately. Add constructor
11693 and destructor. Change type of "handle".
11694 (loaded_jit_reader): Define separately.
11695 (jit_reader_load): Update. New "new".
11696 (jit_reader_unload_command): Use "delete".
11697 * gdb-dlfcn.h (struct dlclose_deleter): New.
11698 (gdb_dlhandle_up): New typedef.
11699 (gdb_dlopen, gdb_dlsym): Update types.
11700 (gdb_dlclose): Remove.
11701 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
11702 (gdb_dlsym): Change type of "handle".
11703 (make_cleanup_dlclose): Remove.
11704 (dlclose_deleter::operator()): Rename from gdb_dlclose.
11705 * compile/compile-c-support.c (load_libcc): Update.
11706
67d89901
TT
117072017-04-12 Tom Tromey <tom@tromey.com>
11708
11709 * symtab.h (find_pcs_for_symtab_line): Change return type.
11710 * symtab.c (find_pcs_for_symtab_line): Change return type.
11711 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
11712 type of "vec". Update.
11713 (ltpy_get_pcs_for_line): Update.
11714 * linespec.c (decode_digits_ordinary): Update.
11715
93921405
TT
117162017-04-12 Tom Tromey <tom@tromey.com>
11717
11718 * tracepoint.c (actions_command): Update.
11719 * python/python.c (python_command, python_interactive_command):
11720 Update.
11721 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
11722 * guile/guile.c (guile_command): Update.
11723 * defs.h (read_command_lines, read_command_lines_1): Return
11724 command_line_up.
11725 (command_lines_deleter): New struct.
11726 (command_line_up): New typedef.
11727 * compile/compile.c (compile_code_command)
11728 (compile_print_command): Update.
11729 * cli/cli-script.h (get_command_line, copy_command_lines): Return
11730 command_line_up.
11731 (make_cleanup_free_command_lines): Remove.
11732 * cli/cli-script.c (get_command_line, read_command_lines_1)
11733 (copy_command_lines): Return command_line_up.
11734 (while_command, if_command, read_command_lines, define_command)
11735 (document_command): Update.
11736 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
11737 Remove.
11738 * breakpoint.h (breakpoint_set_commands): Change type of
11739 "commands".
11740 * breakpoint.c (breakpoint_set_commands): Change type of
11741 "commands". Update.
11742 (do_map_commands_command, update_dprintf_command_list)
11743 (create_tracepoint_from_upload): Update.
11744
ffc2605c
TT
117452017-04-12 Tom Tromey <tom@tromey.com>
11746
11747 * tracepoint.c (scope_info): Update.
11748 * spu-tdep.c (spu_catch_start): Update.
11749 * python/python.c (gdbpy_decode_line): Update.
11750 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
11751 * python/py-breakpoint.c (bppy_init): Update.
11752 * probe.c (parse_probes): Update.
11753 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
11754 * location.h (event_location_deleter): New struct.
11755 (event_location_up): New typedef.
11756 (new_linespec_location, new_address_location, new_probe_location)
11757 (new_explicit_location, copy_event_location)
11758 (string_to_event_location, string_to_event_location_basic)
11759 (string_to_explicit_location): Update return type.
11760 (make_cleanup_delete_event_location): Remove.
11761 * location.c (new_linespec_location, new_address_location)
11762 (new_probe_location, new_explicit_location, copy_event_location):
11763 Return event_location_up.
11764 (delete_event_location_cleanup)
11765 (make_cleanup_delete_event_location): Remove.
11766 (string_to_explicit_location, string_to_event_location_basic)
11767 (string_to_event_location): Return event_location_up.
11768 * linespec.c (canonicalize_linespec, event_location_to_sals)
11769 (decode_line_with_current_source)
11770 (decode_line_with_last_displayed, decode_objc): Update.
11771 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
11772 * completer.c (location_completer): Update.
11773 * cli/cli-cmds.c (edit_command, list_command): Update.
11774 * breakpoint.c (create_overlay_event_breakpoint)
11775 (create_longjmp_master_breakpoint)
11776 (create_std_terminate_master_breakpoint)
11777 (create_exception_master_breakpoint)
11778 (create_thread_event_breakpoint): Update.
11779 (init_breakpoint_sal): Update. Remove some dead code.
11780 (create_breakpoint_sal): Change type of "location". Update.
11781 (create_breakpoints_sal, create_breakpoint, break_command_1)
11782 (dprintf_command, break_range_command, until_break_command)
11783 (init_ada_exception_breakpoint)
11784 (strace_marker_create_sals_from_location)
11785 (update_static_tracepoint, trace_command, ftrace_command)
11786 (strace_command, create_tracepoint_from_upload): Update.
11787 * break-catch-throw.c (re_set_exception_catchpoint): Update.
11788 * ax-gdb.c (agent_command_1): Update.
11789
8f10c932
PA
117902017-04-12 Pedro Alves <palves@redhat.com>
11791
11792 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
11793 * configure.tgt: Handle i[34567]86-*-go32* and
11794 i[34567]86-*-msdosdjgpp*.
11795 * i386-tdep.c (i386_svr4_reg_to_regnum):
11796 Make extern.
11797 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
11798 i386-go32-tdep.c.
11799 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
11800 * i386-go32-tdep.c: New file.
11801 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
11802 declarations.
11803
0a31ccfb
SM
118042017-04-12 Simon Marchi <simon.marchi@ericsson.com>
11805
11806 * aix-thread.c (pd_status2str): Change return type to const char *.
11807
e9bb3fbb
PA
118082017-04-12 Pedro Alves <palves@redhat.com>
11809
11810 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
11811 calls to set_gdbarch_gnu_triplet_regexp.
11812
53375380
PA
118132017-04-12 Pedro Alves <palves@redhat.com>
11814
11815 PR gdb/21323
11816 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
11817 New enum value.
11818 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
11819 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
11820 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
11821 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
11822 * gdbarch.h, gdbarch.c: Regenerate.
11823 * aarch64-tdep.c (aarch64_gdbarch_init): Override
11824 gdbarch_wchar_bit and gdbarch_wchar_signed.
11825 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
11826 * arm-tdep.c (arm_gdbarch_init): Likewise.
11827 * avr-tdep.c (avr_gdbarch_init): Likewise.
11828 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
11829 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
11830 * i386-tdep.c (i386_go32_init_abi): Likewise.
11831 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11832 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11833 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
11834 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
11835 * sh-tdep.c (sh_gdbarch_init): Likewise.
11836 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
11837 * sparc64-tdep.c (sparc64_init_abi): Likewise.
11838 * windows-tdep.c (windows_init_abi): Likewise.
11839 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
11840
53e710ac
PA
118412017-04-12 Pedro Alves <palves@redhat.com>
11842
11843 PR c++/21323
11844 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
11845 cplus_primitive_type_char32_t>: New enum values.
11846 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
11847 and cplus_primitive_type_char32_t.
11848 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
11849 32, use the archtecture's built-in type for char16_t and char32_t,
11850 respectively. Otherwise, fallback to init_integer_type as before,
11851 but make the type unsigned, and issue a complaint.
11852 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
11853
ab0538b8
AH
118542017-04-12 Alan Hayward <alan.hayward@arm.com>
11855
5e0e0422 11856 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
11857 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
11858
5430098f
SDJ
118592017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11860
11861 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
11862 'const char *'.
11863
7c5ded6a
SDJ
118642017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11865
11866 * common/common-utils.c (free_vector_argv): New function.
11867 * common/common-utils.h: Include <vector>.
11868 (free_vector_argv): New prototype.
11869 * darwin-nat.c (darwin_create_inferior): Rewrite function
11870 prototype in order to constify "exec_file" and accept a
11871 "std::string" for "allargs".
11872 * fork-child.c: Include <vector>.
11873 (breakup_args): Rewrite function, using C++.
11874 (fork_inferior): Rewrite function header, constify "exec_file_arg"
11875 and accept "std::string" for "allargs". Update the code to
11876 calculate "argv" based on "allargs". Update calls to "exec_fun"
11877 and "execvp".
11878 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
11879 order to constify "exec_file" and accept a "std::string" for
11880 "allargs".
11881 * go32-nat.c (go32_create_inferior): Likewise.
11882 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
11883 * infcmd.c (run_command_1): Constify "exec_file". Use
11884 "std::string" for inferior arguments.
11885 * inferior.h (fork_inferior): Update prototype.
11886 * linux-nat.c (linux_nat_create_inferior): Rewrite function
11887 prototype in order to constify "exec_file" and accept a
11888 "std::string" for "allargs".
11889 * nto-procfs.c (procfs_create_inferior): Likewise.
11890 * procfs.c (procfs_create_inferior): Likewise.
11891 * remote-sim.c (gdbsim_create_inferior): Likewise.
11892 * remote.c (extended_remote_run): Update code to accept
11893 "std::string" as argument.
11894 (extended_remote_create_inferior): Rewrite function prototype in
11895 order to constify "exec_file" and accept a "std::string" for
11896 "allargs".
11897 * rs6000-nat.c (super_create_inferior): Likewise.
11898 (rs6000_create_inferior): Likewise.
11899 * target.h (struct target_ops) <to_create_inferior>: Likewise.
11900 * windows-nat.c (windows_create_inferior): Likewise.
11901
ae0eee42
PA
119022017-04-11 Pedro Alves <palves@redhat.com>
11903
11904 * thread.c: Fix whitespace throughout.
11905
a6acac06
PR
119062017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
11907
11908 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
11909
64403bd1
AH
119102017-04-11 Alan Hayward <alan.hayward@arm.com>
11911
11912 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
11913
a5bef50f
SDJ
119142017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
11915
11916 PR gdb/21364
11917 * osdata.c (info_osdata): Check if 'type' is an empty string
11918 instead of NULL.
11919
9295a5a9
PA
119202017-04-10 Pedro Alves <palves@redhat.com>
11921
11922 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
11923 (ptid_to_global_thread_id, in_thread_list)
11924 (do_captured_list_thread_ids, set_resumed, set_running)
11925 (set_executing, set_stop_requested, finish_thread_state)
11926 (validate_registers_access, can_access_registers_ptid)
11927 (print_thread_info_1, switch_to_thread)
11928 (do_restore_current_thread_cleanup)
11929 (make_cleanup_restore_current_thread, thread_command)
11930 (thread_name_command): Use operator== instead of ptid_equal.
11931
996812e3
PA
119322017-04-10 Pedro Alves <palves@redhat.com>
11933
11934 * thread.c (struct current_thread_cleanup) <next>: Delete field.
11935 (current_thread_cleanup_chain): Delete.
11936 (restore_current_thread_cleanup_dtor)
11937 (make_cleanup_restore_current_thread): Remove references to
11938 current_thread_cleanup_chain.
11939
845b344f
AH
119402017-04-10 Alan Hayward <alan.hayward@arm.com>
11941
11942 * msp430-tdep.c (msp430_pseudo_register_read): Never return
11943 REG_UNKNOWN.
11944
803bdfe4
YQ
119452017-04-10 Yao Qi <yao.qi@linaro.org>
11946
11947 PR gdb/19942
11948 * gdbthread.h (thread_info::deletable): New method.
11949 (thread_info::incref): New method.
11950 (thread_info::decref): New method.
11951 (thread_info::refcount): Move it to private.
11952 * infrun.c (save_stop_context): Call inc_refcount.
11953 (release_stop_context_cleanup): Likewise.
11954 * thread.c (set_thread_exited): New function.
11955 (init_thread_list): Delete "tp" only it is deletable, otherwise
11956 call set_thread_exited.
11957 (delete_thread_1): Call set_thread_exited.
11958 (current_thread_cleanup) <inferior_pid>: Remove.
11959 <thread>: New field.
11960 (restore_current_thread_ptid_changed): Removed.
11961 (do_restore_current_thread_cleanup): Adjust.
11962 (restore_current_thread_cleanup_dtor): Don't call
11963 find_thread_ptid.
11964 (set_thread_refcount): Use dec_refcount.
11965 (make_cleanup_restore_current_thread): Adjust.
11966 (thread_apply_all_command): Call inc_refcount.
11967 (_initialize_thread): Don't call
11968 observer_attach_thread_ptid_changed.
11969
8c25b497
YQ
119702017-04-10 Yao Qi <yao.qi@linaro.org>
11971
11972 * thread.c (delete_thread_1): Hoist code on marking thread as
11973 exited.
11974
8473b447
SM
119752017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11976
11977 * windows-nat.c (windows_detach): Initialize ptid with
11978 minus_one_ptid.
11979
6670ec13
SM
119802017-04-07 Simon Marchi <simon.marchi@ericsson.com>
11981
11982 * unittests/ptid-selftests.c: Fix erroneous assert messages.
11983
ba2f91bb
AH
119842017-04-07 Alan Hayward <alan.hayward@arm.com>
11985
11986 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
11987 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
11988 (bfin_pseudo_register_write): Likewise
11989
436252de
SM
119902017-04-06 Simon Marchi <simon.marchi@ericsson.com>
11991
11992 * common/ptid.h (struct ptid): Change to...
11993 (class ptid_t): ... this.
11994 <ptid_t>: New constructors.
11995 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
11996 matches>: New methods.
11997 <make_null, make_minus_one>: New static methods.
11998 <pid>: Rename to...
11999 <m_pid>: ...this.
12000 <lwp>: Rename to...
12001 <m_lwp>: ...this.
12002 <tid>: Rename to...
12003 <m_tid>: ...this.
12004 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
12005 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
12006 as references, move comment to class ptid_t.
12007 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
12008 ptid_t static methods.
12009 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
12010 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
12011 Take ptid arguments as references, implement using ptid_t methods.
12012 * unittests/ptid-selftests.c: New file.
12013 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12014 unittests/ptid-selftests.c.
12015 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
12016
0dedf377
TP
120172017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
12018
12019 * python/python.c (python_run_simple_file): Cast mode literal to
12020 non-const char pointer as expected by PyFile_FromString.
12021
4e9868d4
SM
120222017-04-05 Simon Marchi <simon.marchi@ericsson.com>
12023
12024 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
12025 minus_one_ptid and null_ptid.
12026
9bf2a700
PA
120272017-04-05 Pedro Alves <palves@redhat.com>
12028
12029 * warning.m4 (build_warnings): Remove -Wno-write-strings.
12030 * configure: Regenerate.
12031
a121b7c1
PA
120322017-04-05 Pedro Alves <palves@redhat.com>
12033
12034 * ada-exp.y (yyerror): Constify.
12035 * ada-lang.c (bound_name, get_selections)
12036 (ada_variant_discrim_type)
12037 (ada_variant_discrim_name, ada_value_struct_elt)
12038 (ada_lookup_struct_elt_type, is_unchecked_variant)
12039 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
12040 (catch_ada_exception_command_split)
12041 (catch_ada_assert_command_split, catch_assert_command)
12042 (ada_op_name): Constify.
12043 * ada-lang.h (ada_yyerror, get_selections)
12044 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
12045 * arc-tdep.c (arc_print_frame_cache): Constify.
12046 * arm-tdep.c (arm_skip_stub): Constify.
12047 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
12048 (gen_aggregate_elt_ref): Constify.
12049 * bcache.c (print_bcache_statistics): Constify.
12050 * bcache.h (print_bcache_statistics): Constify.
12051 * break-catch-throw.c (catch_exception_command_1):
12052 * breakpoint.c (struct ep_type_description::description):
12053 Constify.
12054 (add_solib_catchpoint): Constify.
12055 (catch_fork_command_1): Add cast.
12056 (add_catch_command): Constify.
12057 * breakpoint.h (add_catch_command, add_solib_catchpoint):
12058 Constify.
12059 * bsd-uthread.c (bsd_uthread_state): Constify.
12060 * buildsym.c (patch_subfile_names): Constify.
12061 * buildsym.h (next_symbol_text_func, patch_subfile_names):
12062 Constify.
12063 * c-exp.y (yyerror): Constify.
12064 (token::oper): Constify.
12065 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
12066 * c-varobj.c (cplus_describe_child): Constify.
12067 * charset.c (find_charset_names): Add cast.
12068 (find_charset_names): Constify array and add const_cast.
12069 * cli/cli-cmds.c (complete_command, cd_command): Constify.
12070 (edit_command): Constify.
12071 * cli/cli-decode.c (lookup_cmd): Constify.
12072 * cli/cli-dump.c (dump_memory_command, dump_value_command):
12073 Constify.
12074 (struct dump_context): Constify.
12075 (add_dump_command, restore_command): Constify.
12076 * cli/cli-script.c (get_command_line): Constify.
12077 * cli/cli-script.h (get_command_line): Constify.
12078 * cli/cli-utils.c (check_for_argument): Constify.
12079 * cli/cli-utils.h (check_for_argument): Constify.
12080 * coff-pe-read.c (struct read_pe_section_data): Constify.
12081 * command.h (lookup_cmd): Constify.
12082 * common/print-utils.c (decimal2str): Constify.
12083 * completer.c (gdb_print_filename): Constify.
12084 * corefile.c (set_gnutarget): Constify.
12085 * cp-name-parser.y (yyerror): Constify.
12086 * cp-valprint.c (cp_print_class_member): Constify.
12087 * cris-tdep.c (cris_register_name, crisv32_register_name):
12088 Constify.
12089 * d-exp.y (yyerror): Constify.
12090 (struct token::oper): Constify.
12091 * d-lang.h (d_yyerror): Constify.
12092 * dbxread.c (struct header_file_location::name): Constify.
12093 (add_old_header_file, add_new_header_file, last_function_name)
12094 (dbx_next_symbol_text, add_bincl_to_list)
12095 (find_corresponding_bincl_psymtab, set_namestring)
12096 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
12097 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
12098 * defs.h (command_line_input, print_address_symbolic)
12099 (deprecated_readline_begin_hook): Constify.
12100 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
12101 Constify.
12102 * event-top.c (handle_line_of_input): Constify and add cast.
12103 * exceptions.c (catch_errors): Constify.
12104 * exceptions.h (catch_errors): Constify.
12105 * expprint.c (print_subexp_standard, op_string, op_name)
12106 (op_name_standard, dump_raw_expression, dump_raw_expression):
12107 * expression.h (op_name, op_string, dump_raw_expression):
12108 Constify.
12109 * f-exp.y (yyerror): Constify.
12110 (struct token::oper): Constify.
12111 (struct f77_boolean_val::name): Constify.
12112 * f-lang.c (f_word_break_characters): Constify.
12113 * f-lang.h (f_yyerror): Constify.
12114 * fork-child.c (fork_inferior): Add cast.
12115 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
12116 (new_variant): Constify.
12117 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
12118 * gdbarch.c: Regenerate.
12119 * gdbcore.h (set_gnutarget): Constify.
12120 * go-exp.y (yyerror): Constify.
12121 (token::oper): Constify.
12122 * go-lang.h (go_yyerror): Constify.
12123 * go32-nat.c (go32_sysinfo): Constify.
12124 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
12125 * guile/scm-cmd.c (cmdscm_function): Constify.
12126 * guile/scm-param.c (pascm_param_value): Constify.
12127 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
12128 (h8300sx_register_name): Constify.
12129 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
12130 Constify.
12131 * ia64-tdep.c (ia64_register_names): Constify.
12132 * infcmd.c (construct_inferior_arguments): Constify.
12133 (path_command, attach_post_wait): Constify.
12134 * language.c (show_range_command, show_case_command)
12135 (unk_lang_error): Constify.
12136 * language.h (language_defn::la_error)
12137 (language_defn::la_name_of_this): Constify.
12138 * linespec.c (decode_line_2): Constify.
12139 * linux-thread-db.c (thread_db_err_str): Constify.
12140 * lm32-tdep.c (lm32_register_name): Constify.
12141 * m2-exp.y (yyerror): Constify.
12142 * m2-lang.h (m2_yyerror): Constify.
12143 * m32r-tdep.c (m32r_register_names): Constify and make static.
12144 * m68hc11-tdep.c (m68hc11_register_names): Constify.
12145 * m88k-tdep.c (m88k_register_name): Constify.
12146 * macroexp.c (appendmem): Constify.
12147 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
12148 (upgrade_type, parse_external, parse_partial_symbols)
12149 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
12150 (new_symbol): Constify.
12151 * memattr.c (mem_info_command): Constify.
12152 * mep-tdep.c (register_name_from_keyword): Constify.
12153 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
12154 Constify.
12155 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
12156 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
12157 * mi/mi-main.c (captured_mi_execute_command): Constify and add
12158 cast.
12159 (mi_execute_async_cli_command): Constify.
12160 * mips-tdep.c (mips_register_name): Constify.
12161 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
12162 (am33_register_name, am33_2_register_name)
12163 * moxie-tdep.c (moxie_register_names): Constify.
12164 * nat/linux-osdata.c (osdata_type): Constify fields.
12165 * nto-tdep.c (nto_parse_redirection): Constify.
12166 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
12167 (lookup_child_selector): Constify.
12168 (objc_methcall::name): Constify.
12169 * objc-lang.h (lookup_objc_class, lookup_child_selector)
12170 (lookup_struct_typedef): Constify.
12171 * objfiles.c (pc_in_section): Constify.
12172 * objfiles.h (pc_in_section): Constify.
12173 * p-exp.y (struct token::oper): Constify.
12174 (yyerror): Constify.
12175 * p-lang.h (pascal_yyerror): Constify.
12176 * parser-defs.h (op_name_standard): Constify.
12177 (op_print::string): Constify.
12178 (exp_descriptor::op_name): Constify.
12179 * printcmd.c (print_address_symbolic): Constify.
12180 * psymtab.c (print_partial_symbols): Constify.
12181 * python/py-breakpoint.c (stop_func): Constify.
12182 (bppy_get_expression): Constify.
12183 * python/py-cmd.c (cmdpy_completer::name): Constify.
12184 (cmdpy_function): Constify.
12185 * python/py-event.c (evpy_add_attribute)
12186 (gdbpy_initialize_event_generic): Constify.
12187 * python/py-event.h (evpy_add_attribute)
12188 (gdbpy_initialize_event_generic): Constify.
12189 * python/py-evts.c (add_new_registry): Constify.
12190 * python/py-finishbreakpoint.c (outofscope_func): Constify.
12191 * python/py-framefilter.c (get_py_iter_from_func): Constify.
12192 * python/py-inferior.c (get_buffer): Add cast.
12193 * python/py-param.c (parm_constant::name): Constify.
12194 * python/py-unwind.c (fprint_frame_id): Constify.
12195 * python/python.c (gdbpy_parameter_value): Constify.
12196 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
12197 * remote.c (memory_packet_config::name): Constify.
12198 (show_packet_config_cmd, remote_write_bytes)
12199 (remote_buffer_add_string):
12200 * reverse.c (exec_reverse_once): Constify.
12201 * rs6000-tdep.c (variant::name, variant::description): Constify.
12202 * rust-exp.y (rustyyerror): Constify.
12203 * rust-lang.c (rust_op_name): Constify.
12204 * rust-lang.h (rustyyerror): Constify.
12205 * serial.h (serial_ops::name): Constify.
12206 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
12207 (sh_sh3e_register_name, sh_sh2e_register_name)
12208 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
12209 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
12210 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
12211 (sh_sh4al_dsp_register_name): Constify.
12212 * sh64-tdep.c (sh64_register_name): Constify.
12213 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
12214 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
12215 * stabsread.c (patch_block_stabs, read_type_number)
12216 (ref_map::stabs, ref_add, process_reference)
12217 (symbol_reference_defined, define_symbol, define_symbol)
12218 (error_type, read_type, read_member_functions, read_cpp_abbrev)
12219 (read_one_struct_field, read_struct_fields, read_baseclasses)
12220 (read_tilde_fields, read_struct_type, read_array_type)
12221 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
12222 (read_huge_number, read_range_type, read_args, common_block_start)
12223 (find_name_end): Constify.
12224 * stabsread.h (common_block_start, define_symbol)
12225 (process_one_symbol, symbol_reference_defined, ref_add):
12226 * symfile.c (get_section_index, add_symbol_file_command):
12227 * symfile.h (get_section_index): Constify.
12228 * target-descriptions.c (tdesc_type::name): Constify.
12229 (tdesc_free_type): Add cast.
12230 * target.c (find_default_run_target):
12231 (add_deprecated_target_alias, find_default_run_target)
12232 (target_announce_detach): Constify.
12233 (do_option): Constify.
12234 * target.h (add_deprecated_target_alias): Constify.
12235 * thread.c (print_thread_info_1): Constify.
12236 * top.c (deprecated_readline_begin_hook, command_line_input):
12237 Constify.
12238 (init_main): Add casts.
12239 * top.h (handle_line_of_input): Constify.
12240 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
12241 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
12242 (tfind_command): Rename to ...
12243 (tfind_command_1): ... this and constify.
12244 (tfind_command): New function.
12245 (tfind_end_command, tfind_start_command): Adjust.
12246 (encode_source_string): Constify.
12247 * tracepoint.h (encode_source_string): Constify.
12248 * tui/tui-data.c (tui_partial_win_by_name): Constify.
12249 * tui/tui-data.h (tui_partial_win_by_name): Constify.
12250 * tui/tui-source.c (tui_set_source_content_nil): Constify.
12251 * tui/tui-source.h (tui_set_source_content_nil): Constify.
12252 * tui/tui-win.c (parse_scrolling_args): Constify.
12253 * tui/tui-windata.c (tui_erase_data_content): Constify.
12254 * tui/tui-windata.h (tui_erase_data_content): Constify.
12255 * tui/tui-winsource.c (tui_erase_source_content): Constify.
12256 * tui/tui.c (tui_enable): Add cast.
12257 * utils.c (defaulted_query): Constify.
12258 (init_page_info): Add cast.
12259 (puts_debug, subset_compare): Constify.
12260 * utils.h (subset_compare): Constify.
12261 * varobj.c (varobj_format_string): Constify.
12262 * varobj.h (varobj_format_string): Constify.
12263 * vax-tdep.c (vax_register_name): Constify.
12264 * windows-nat.c (windows_detach): Constify.
12265 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
12266 * xml-support.c (gdb_xml_end_element): Constify.
12267 * xml-tdesc.c (tdesc_start_reg): Constify.
12268 * xstormy16-tdep.c (xstormy16_register_name): Constify.
12269 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
12270 * xtensa-tdep.h (xtensa_register_t::name): Constify.
12271
995816ba
PA
122722017-04-05 Pedro Alves <palves@redhat.com>
12273
12274 * proc-api.c (struct trans): Constify.
12275 (procfs_note): Constify.
12276 * proc-events.c (struct trans, syscall_table):
12277 * proc-flags.c (struct trans): Constify.
12278 * proc-utils.h (procfs_note): Constify.
12279 * proc-why.c (struct trans): Constify.
12280 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
12281 (procfs_detach): Constify.
12282 * sol-thread.c (struct string_map): Constify.
12283 (td_err_string, td_state_string): Constify.
12284
3e83a920
PA
122852017-04-05 Pedro Alves <palves@redhat.com>
12286
12287 * proc-api.c (procfs_filename): Don't initialize
12288 procfs_filename.
12289 (prepare_to_trace): Assume procfs_filename is non-NULL.
12290 (_initialize_proc_api): Give procfs_filename a default value here.
12291
63160a43
PA
122922017-04-05 Pedro Alves <palves@redhat.com>
12293
12294 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
12295 'cond_string' parameter.
12296 (extract_exception_regexp): Constify 'string' parameter.
12297 (catch_exception_command_1): Constify.
12298 * breakpoint.c (init_catchpoint)
12299 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
12300 parameter.
12301 (ep_parse_optional_if_clause, catch_fork_command_1)
12302 (catch_exec_command_1): Constify.
12303 * breakpoint.h (init_catchpoint): Constify 'cond_string'
12304 parameter.
12305 (ep_parse_optional_if_clause): Constify.
12306 * cli/cli-utils.c (remove_trailing_whitespace)
12307 (check_for_argument): Constify.
12308 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
12309 non-const overload.
12310 (check_for_argument): Likewise.
12311
9b2eba3d
PA
123122017-04-05 Pedro Alves <palves@redhat.com>
12313
12314 * event-top.c (command_line_handler): Add cast to execute_command
12315 call.
12316 * record-btrace.c (cmd_record_btrace_bts_start)
12317 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
12318 (cmd_record_btrace_start): Add cast to execute_command call.
12319 * record-full.c (record_full_goto_insn):
12320 * record.c (record_start, record_stop): Add cast to
12321 execute_command_to_string calls.
12322 (cmd_record_start): Add cast to execute_command calls.
12323
2adadf51
PA
123242017-04-05 Pedro Alves <palves@redhat.com>
12325
12326 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
12327 static inline function.
12328 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
12329 array and use gdb_PyArg_ParseTupleAndKeywords.
12330 * python/py-cmd.c (cmdpy_init): Likewise.
12331 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
12332 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
12333 (infpy_search_memory): Likewise.
12334 * python/py-objfile.c (objfpy_add_separate_debug_file)
12335 (gdbpy_lookup_objfile): Likewise.
12336 * python/py-symbol.c (gdbpy_lookup_symbol)
12337 (gdbpy_lookup_global_symbol): Likewise.
12338 * python/py-type.c (gdbpy_lookup_type): Likewise.
12339 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
12340 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
12341 Likewise.
12342
0d1f4ceb
PA
123432017-04-05 Pedro Alves <palves@redhat.com>
12344
12345 * python/python-internal.h (gdb_PyGetSetDef): New type.
12346 * python/py-block.c (block_object_getset)
12347 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
12348 * python/py-event.c (event_object_getset)
12349 (finish_breakpoint_object_getset): Likewise.
12350 * python/py-inferior.c (inferior_object_getset): Likewise.
12351 * python/py-infthread.c (thread_object_getset): Likewise.
12352 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
12353 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
12354 * python/py-objfile.c (objfile_getset): Likewise.
12355 * python/py-progspace.c (pspace_getset): Likewise.
12356 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
12357 Likewise.
12358 * python/py-record.c (recpy_record_getset): Likewise.
12359 * python/py-symbol.c (symbol_object_getset): Likewise.
12360 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
12361 Likewise.
12362 * python/py-type.c (type_object_getset, field_object_getset):
12363 Likewise.
12364 * python/py-value.c (value_object_getset): Likewise.
12365
4d759979
PA
123662017-04-05 Pedro Alves <palves@redhat.com>
12367
12368 * python/python-internal.h (gdb_PyObject_CallMethod)
12369 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
12370 New functions.
12371 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
12372 (PySys_GetObject, PySys_SetPath): New macros.
12373
fdf9e36f
PA
123742017-04-05 Pedro Alves <palves@redhat.com>
12375
12376 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
12377 info_osdata_command.
12378 * osdata.c (info_osdata_command): Rename to ...
12379 (info_osdata): ... this. Constify 'type' parameter, and remove
12380 the 'from_tty' parameter. Accept NULL TYPE.
12381 (info_osdata_command): New function.
12382 * osdata.h (info_osdata_command): Remove declaration.
12383 (info_osdata): New declaration.
12384
9f33b8b7
PA
123852017-04-05 Pedro Alves <palves@redhat.com>
12386
12387 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
12388 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
12389 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
12390 parameter.
12391 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
12392 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
12393 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
12394 parameter.
12395 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
12396 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
12397 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
12398 (mi_cmd_file_list_exec_source_files)
12399 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
12400 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
12401 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
12402 parameter.
12403 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
12404 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
12405 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
12406 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
12407 (mi_cmd_stack_info_frame): Constify 'command' parameter.
12408 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
12409 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
12410 'command' parameter.
12411 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
12412 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
12413 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
12414 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
12415 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
12416 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
12417 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
12418 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
12419 (mi_cmd_var_set_update_range): Constify 'command' parameter.
12420 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
12421 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
12422 parameter.
12423 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
12424 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
12425 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
12426 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
12427 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
12428 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
12429 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
12430 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
12431 (mi_cmd_data_list_changed_registers)
12432 (mi_cmd_data_write_register_values)
12433 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
12434 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
12435 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
12436 (mi_cmd_list_features, mi_cmd_list_target_features)
12437 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
12438 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
12439 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
12440 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
12441 (mi_cmd_trace_frame_collected): Constify 'command'
12442 parameter.
12443 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
12444 'command' parameter.
12445
67cb5b2d
PA
124462017-04-05 Pedro Alves <palves@redhat.com>
12447
12448 * ada-lang.c (ada_completer_word_break_characters): Now a const
12449 array.
12450 (ada_get_gdb_completer_word_break_characters): Constify.
12451 * completer.c (gdb_completer_command_word_break_characters)
12452 (gdb_completer_file_name_break_characters)
12453 (gdb_completer_quote_characters): Now const arrays.
12454 (get_gdb_completer_quote_characters): Constify.
12455 (set_rl_completer_word_break_characters): New function.
12456 (set_gdb_completion_word_break_characters)
12457 (complete_line_internal): Use it.
12458 * completer.h (get_gdb_completer_quote_characters): Constify.
12459 (set_rl_completer_word_break_characters): Declare.
12460 * f-lang.c (f_word_break_characters): Constify.
12461 * language.c (default_word_break_characters): Constify.
12462 * language.h (language_defn::la_word_break_characters): Constify.
12463 (default_word_break_characters): Constify.
12464 * top.c (init_main): Use set_rl_completer_word_break_characters.
12465
7a114964
PA
124662017-04-05 Pedro Alves <palves@redhat.com>
12467
12468 * aix-thread.c (aix_thread_pid_to_str)
12469 (aix_thread_extra_thread_info): Constify.
12470 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
12471 * bsd-uthread.c (bsd_uthread_extra_thread_info)
12472 (bsd_uthread_pid_to_str): Constify.
12473 * corelow.c (core_pid_to_str): Constify.
12474 * darwin-nat.c (darwin_pid_to_str): Constify.
12475 * fbsd-nat.c (fbsd_pid_to_str): Constify.
12476 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
12477 Constify.
12478 * gnu-nat.c (gnu_pid_to_str): Constify.
12479 * go32-nat.c (go32_pid_to_str): Constify.
12480 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
12481 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
12482 * inferior.c (inferior_pid_to_str): Constify.
12483 * linux-nat.c (linux_nat_pid_to_str): Constify.
12484 * linux-tdep.c (linux_core_pid_to_str): Constify.
12485 * linux-thread-db.c (thread_db_pid_to_str)
12486 (thread_db_extra_thread_info): Constify.
12487 * nto-tdep.c (nto_extra_thread_info): Constify.
12488 * nto-tdep.h (nto_extra_thread_info): Constify.
12489 * obsd-nat.c (obsd_pid_to_str): Constify.
12490 * procfs.c (procfs_pid_to_str): Constify.
12491 * ravenscar-thread.c (ravenscar_extra_thread_info)
12492 (ravenscar_pid_to_str): Constify.
12493 * remote-sim.c (gdbsim_pid_to_str): Constify.
12494 * remote.c (remote_threads_extra_info, remote_pid_to_str):
12495 Constify.
12496 * sol-thread.c (solaris_pid_to_str): Constify.
12497 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
12498 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
12499 * target.c (default_pid_to_str, target_pid_to_str)
12500 (normal_pid_to_str, default_pid_to_str): Constify.
12501 * target.h (target_ops::to_pid_to_str)
12502 (target_ops::to_extra_thread_info): Constify.
12503 (target_pid_to_str, normal_pid_to_str): Constify.
12504 * windows-nat.c (windows_pid_to_str): Constify.
12505 * gdbarch.sh (core_pid_to_str): Constify.
12506 * target-delegates.c: Regenerate.
12507 * gdbarch.h, gdbarch.c: Regenerate.
12508
69bbf465
PA
125092017-04-05 Pedro Alves <palves@redhat.com>
12510
12511 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
12512 the memory of the temporary warning_pre_print override.
12513 * utils.c (warning_pre_print): Constify.
12514 * utils.h (warning_pre_print): Constify.
12515
be47f9e8
PA
125162017-04-05 Pedro Alves <palves@redhat.com>
12517
12518 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
12519 (shell_command): New function.
12520 (make_command): Use std::string.
12521 (init_cli_cmds): Register shell_command instead of shell_escape.
12522
bde6261a
PA
125232017-04-05 Pedro Alves <palves@redhat.com>
12524
12525 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
12526 * tracepoint.c (default_collect): Don't initialize.
12527
b38ef47f
PA
125282017-04-05 Pedro Alves <palves@redhat.com>
12529
12530 * macroexp.c (macro_buffer::shared): Now a bool.
12531 (init_buffer): Update.
12532 (init_shared_buffer): Constify 'addr' parameter.
12533 (substitute_args, expand, macro_expand, macro_expand_next): Remove
12534 casts.
12535
f995bbe8
PA
125362017-04-05 Pedro Alves <palves@redhat.com>
12537
12538 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
12539 * disasm.c (set_disassembler_options): Constify local.
12540 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
12541
4a596fe2
SDJ
125422017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
12543
12544 PR gdb/21352
12545 * tracefile.c (tsave_command): Fix argument parsing for '-r'
12546 option.
12547
2cad08ea
YQ
125482017-04-05 Yao Qi <yao.qi@linaro.org>
12549
12550 * frame.c (frame_unwind_register_unsigned): Call
12551 frame_unwind_register_value.
12552
55a98976
YQ
125532017-04-05 Yao Qi <yao.qi@linaro.org>
12554
12555 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
12556 Use gdb_test_multiple, and don't match anchor.
12557
4ac40124
PA
125582017-04-05 Pedro Alves <palves@redhat.com>
12559
12560 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
12561 (Write After Approval): Remove Simon Marchi.
12562
c053b654
PA
125632017-04-05 Pedro Alves <palves@redhat.com>
12564
12565 * common/gdb_optional.h (optional::optional): Make constexpr and
12566 initialize m_dummy.
12567
4c7bf4f9
JB
125682017-04-04 John Baldwin <jhb@FreeBSD.org>
12569
12570 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
12571 (amd64fbsd_jmp_buf_reg_offset): Remove.
12572 (amd64fbsd_supply_uthread): Remove function.
12573 (amd64fbsd_collect_uthread): Remove function.
12574 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
12575 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
12576 (x86_64-*-freebsd*): Remove bsd-uthread.o.
12577 (fbsd-nat.c): Update comment.
12578 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
12579 (i386fbsd_jmp_buf_reg_offset): Remove.
12580 (i386fbsd_supply_uthread): Remove function.
12581 (i386fbsd_collect_uthread): Remove function.
12582 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
12583
1e1a8bef
JB
125842017-04-04 John Baldwin <jhb@FreeBSD.org>
12585
12586 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
12587 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
12588 * NEWS: Mention that support for FreeBSD/alpha was removed.
12589 * alpha-fbsd-tdep.c: Delete file.
12590 * config/alpha/fbsd.mh: Delete file.
12591 * configure.host: Delete alpha*-*-freebsd* and
12592 alpha*-*-kfreebsd*-gnu.
12593 * configure.tgt: Delete alpha*-*-freebsd* and
12594 alpha*-*-kfreebsd*-gnu.
12595
49907934
JB
125962017-04-04 John Baldwin <jhb@FreeBSD.org>
12597
12598 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
12599 amd64bsd_store_inferior_registers): Use ptid from regcache.
12600
6f77053d
PA
126012017-04-04 Pedro Alves <palves@redhat.com>
12602
12603 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
12604 data fields, make them private and add "m_" prefixes.
12605 (lnp_state_machine::lnp_state_machine): New ctor.
12606 (record_line, check_line_address, handle_set_discriminator)
12607 (handle_set_address, handle_advance_pc, handle_special_opcode)
12608 (handle_advance_line, handle_set_file, handle_negate_stmt)
12609 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
12610 (end_sequence, advance_line): New methods.
12611 (m_gdbarch, m_record_lines_p): New fields.
12612 (lnp_reader_state): Delete.
12613 (dwarf_record_line): Rename to ...
12614 (lnp_state_machine::record_line): ... adjust.
12615 (init_lnp_state_machine): Delete.
12616 (lnp_state_machine::lnp_state_machine): New.
12617 (check_line_address): Rename to ...
12618 (lnp_state_machine::check_line_address): This.
12619 (dwarf_decode_lines_1): Remove reference to "reader_state".
12620 Adjust lnp_state_machine having a non-default ctor. Use bool.
12621 State machine internal state manipulation moved to
12622 lnp_state_machine methods.
12623
9c541725
PA
126242017-04-04 Pedro Alves <palves@redhat.com>
12625
12626 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12627 unittests/offset-type-selftests.c.
12628 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
12629 * common/offset-type.h: New file.
12630 * common/preprocessor.h: New file.
12631 * common/traits.h: New file.
12632 * common/valid-expr.h: New file.
12633 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
12634 sect_offset and cu_offset strong typedefs throughout.
12635 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
12636 typedefs throughout.
12637 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
12638 sect_offset and cu_offset strong typedefs throughout.
12639 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
12640 typedefs throughout.
12641 * gdbtypes.h: Include "common/offset-type.h".
12642 (cu_offset): Now an offset type (strong typedef) instead of a
12643 struct.
12644 (sect_offset): Likewise.
12645 (union call_site_parameter_u): Rename "param_offset" field to
12646 "param_cu_off".
12647 * unittests/offset-type-selftests.c: New file.
12648
ecfb656c
PA
126492017-04-04 Pedro Alves <palves@redhat.com>
12650
12651 * common/underlying.h: New file.
12652 * dwarf2read.c: Include "common/gdb_optional.h" and
12653 "common/underlying.h".
12654 (dir_index, file_name_index): New types.
12655 (file_entry): Use them.
12656 (file_entry::include): Use to_underlying.
12657 (line_header::add_file_name): Use dir_index.
12658 (read_formatted_entries): Use gdb::optional. Read form before
12659 writting to file_entry.
12660 (dwarf_decode_line_header): Use dir_index.
12661 (lnp_state_machine::current_file): Use to_underlying.
12662 (lnp_state_machine::file): Change type to file_name_index.
12663 (dwarf_record_line): Use to_underlying.
12664 (init_lnp_state_machine): Use file_name_index.
12665 (dwarf_decode_lines_1): Use dir_index and file_name_index.
12666
d194f1fe
PA
126672017-04-04 Pedro Alves <palves@redhat.com>
12668
12669 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
12670 operator bool, has_value and get methods.
12671
fff8551c
PA
126722017-04-04 Pedro Alves <palves@redhat.com>
12673
12674 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
12675 fields.
12676 (line_header): Initialize all data fields. Change type of
12677 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
12678 Change type of include_dirs to std::vector<const char *>. Remove
12679 num_include_dirs, include_dirs_size. Change type of file_names to
12680 std::vector<file_entry>. Remove num_file_names, file_names_size.
12681 (line_header::line_header): New.
12682 (line_header::add_include_dir, line_header::add_file_name): New
12683 methods.
12684 (line_header::include_dir_at): Remove NULL check.
12685 (line_header::file_name_at): Add const overload.
12686 (line_header_up): New unique_ptr typedef.
12687 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
12688 std::vector. Remove free_line_header call.
12689 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
12690 free_line_header call.
12691 (free_cu_line_header): Delete.
12692 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
12693 (setup_type_unit_groups): Use line_header_up instead of cleanups.
12694 Adjust to use std::vector.
12695 (free_line_header): Delete.
12696 (free_line_header_voidp): Use delete.
12697 (add_include_dir): Replace with ...
12698 (line_header::add_include_dir): ... this method. Use std::vector.
12699 (add_file_name): Replace with ...
12700 (line_header::add_file_name): ... this method. Use std::vector.
12701 (add_include_dir_stub): Delete.
12702 (read_formatted_entries): Remove memset.
12703 (dwarf_decode_line_header): Return a line_header_up instead of a
12704 raw pointer. Remove cleanup handling. Pass lambdas to
12705 read_formatted_entries. Adjust to use line_header methods.
12706 (dwarf_decode_lines_1): Adjust to use line_header methods.
12707 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
12708 use std::vector.
12709
d62a8ae2
SM
127102017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
12711
12712 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
12713 instead of struct ptid.
12714
db3a1dc7
AH
127152017-05-04 Alan Hayward <alan.hayward@arm.com>
12716
12717 * frame.c (get_frame_register_bytes): Unwind using value.
12718 (put_frame_register_bytes): Likewise.
12719
b1b45502
IB
127202017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
12721
12722 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
12723 aggregate-like.
12724
ec13808e
JK
127252017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
12726
12727 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
12728
12316564
YQ
127292017-03-29 Yao Qi <yao.qi@linaro.org>
12730
12731 * gdbthread.h (struct thread_info): Declare constructor and
12732 destructor. Add some in-class member initializers.
12733 * thread.c (free_thread): Remove.
12734 (init_thread_list): Call delete instead of free_thread.
12735 (new_thread): Call thread_info constructor.
12736 (thread_info::thread_info): New function.
12737 (thread_info::~thread_info): New function.
12738 (delete_thread_1): Call delete instead of free_thread.
12739 (make_cleanup_restore_current_thread): Move tp and frame to
12740 inner block.
12741
fe5f7374
AK
127422017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12743
12744 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
12745 (arc_skip_prologue): Likewise.
12746 (arc_make_frame_cache): Likewise.
12747 (arc_pv_get_operand): New function.
12748 (arc_is_in_prologue): Likewise.
12749 (arc_analyze_prologue): Likewise.
12750 (arc_print_frame_cache): Likewise.
12751 (MAX_PROLOGUE_LENGTH): New constant.
12752
eea78757
AK
127532017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12754
12755 * configure.tgt: Add arc-insn.o.
12756 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
12757 (dump_arc_instruction_command): New function.
12758 (arc_fprintf_disasm): Likewise.
12759 (arc_disassemble_info): Likewise.
12760 (arc_insn_get_operand_value): Likewise.
12761 (arc_insn_get_operand_value_signed): Likewise.
12762 (arc_insn_get_memory_base_reg): Likewise.
12763 (arc_insn_get_memory_offset): Likewise.
12764 (arc_insn_get_branch_target): Likewise.
12765 (arc_insn_dump): Likewise.
12766 (arc_insn_get_linear_next_pc): Likewise.
12767 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
12768 (arc_disassemble_info): Likewise.
12769 (arc_insn_get_branch_target): Likewise.
12770 (arc_insn_get_linear_next_pc): Likewise.
12771 * NEWS: Mention new "maint print arc arc-instruction".
12772
3be78afd
AK
127732017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12774
12775 * arc-tdep (maintenance_print_arc_list): New variable.
12776 (maintenance_print_arc_command): New function.
12777
296ec4fa
AK
127782017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12779
12780 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
12781 Add "limm" and "reserved".
12782 (arc_cannot_fetch_register, arc_cannot_store_register): Add
12783 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
12784 * arc-tdep.h (arc_regnum): Likewise.
12785
f74f865e
MF
127862017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12787
12788 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
12789 for THREADPTR register.
12790 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
12791 register.
12792 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
12793 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
12794 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
12795
0d0bf81a
MF
127962017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12797
12798 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
12799 registers above gdbarch_num_regs (gdbarch) as privileged in
12800 call0 ABI.
12801
0ce4291e
MF
128022017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12803
12804 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
12805 for a single specified register or for all registers in
12806 a0_base..a0_base + C0_NREGS range.
12807 (supply_gregset_reg): Call regcache_raw_supply for a single
12808 specified register or for all registers in a0_base..a0_base +
12809 C0_NREGS range.
12810
c56054f9
MF
128112017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12812
12813 * arch/xtensa.h (C0_NREGS): Add definition.
12814 * xtensa-tdep.c (C0_NREGS): Remove definition.
12815
a4398628
MF
128162017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12817
12818 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
12819 Drop xtensa_default_isa initialization.
12820 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
12821
8c43009f
PA
128222017-03-27 Pedro Alves <palves@redhat.com>
12823
12824 * dwarf2read.c (file_entry) <dir_index>: Add comment.
12825 (file_entry::include_dir): New method.
12826 (line_header::include_dir_at, line_header::file_name_at): New
12827 methods.
12828 (setup_type_unit_groups, setup_type_unit_groups)
12829 (psymtab_include_file_name): Simplify using the new methods.
12830 (lnp_state_machine) <the_line_header>: New field.
12831 <file>: Add comment.
12832 (lnp_state_machine::current_file): New method.
12833 (dwarf_record_line): Simplify using the new methods.
12834 (init_lnp_state_machine): Initialize the "the_line_header" field.
12835 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
12836 Simplify using the new methods.
12837
a7e80b9e
PA
128382017-03-27 Pedro Alves <palves@redhat.com>
12839
12840 * cp-name-parser.y (make_empty): Delete.
12841 (demangler_special, nested_name, ptr_operator, array_indicator)
12842 (direct_declarator, declarator_1): Use fill_comp instead of
12843 make_empty.
12844
21047726
PA
128452017-03-27 Pedro Alves <palves@redhat.com>
12846
12847 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
12848 to ATTRIBUTE_PRINTF.
12849 * solib-target.c (library_list_start_list): Print "string" not
12850 "version".
12851 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
12852 gdb_xml_error call.
12853
d721ba37
PA
128542017-03-27 Pedro Alves <palves@redhat.com>
12855
12856 * dwarf2read.c (struct file_and_directory): New.
12857 (dwarf2_get_dwz_file): Adjust to use std::string.
12858 (dw2_get_file_names_reader): Adjust to use file_and_directory.
12859 (find_file_and_directory): Adjust to return a file_and_directory
12860 object.
12861 (read_file_scope): Adjust to use file_and_directory. Remove
12862 make_cleanup/do_cleanups calls.
12863 (open_and_init_dwp_file): Adjust to use std::string. Remove
12864 make_cleanup/do_cleanups calls.
12865 * python/python.c (do_start_initialization): Adjust to ldirname
12866 returning a std::string.
12867 * utils.c (ldirname): Now returns a std::string.
12868 * utils.h (ldirname): Change return type to std::string.
12869 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
12870 returning a std::string.
12871 * xml-tdesc.c (file_read_description_xml): Likewise.
12872
ed771251
AH
128732017-03-24 Alan Hayward <alan.hayward@arm.com>
12874
12875 * regcache.c (regcache_debug_print_register): New function.
12876 * regcache.h (regcache_debug_print_register): New declaration.
12877 * target.c (debug_print_register): Remove.
12878 (target_fetch_registers): Call regcache_debug_print_register.
12879 (target_store_registers): Likewise.
12880
568c1b9f
PB
128812017-03-24 Pádraig Brady <pbrady@fb.com>
12882
12883 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
12884 reference beyond the 'lh->include_dirs' array before accessing to
12885 it.
12886 (psymtab_include_file_name): Likewise.
12887 (dwarf_decode_lines_1): Likewise.
12888 (dwarf_decode_lines): Likewise.
12889 (file_file_name): Likewise.
12890
3e00d44f
SM
128912017-03-23 Simon Marchi <simon.marchi@ericsson.com>
12892
12893 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
12894 inferior_ptid.
12895 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
12896 ps_lsetfpregs): Likewise.
12897 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
12898 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
12899 ps_lsetfpregs): Likewise.
12900 * target.c (target_fetch_registers, target_store_registers):
12901 Remove asserts.
12902
077ae656
AH
129032017-03-23 Alan Hayward <alan.hayward@arm.com>
12904
12905 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
12906
1e2b521d
YQ
129072017-03-23 Yao Qi <yao.qi@linaro.org>
12908
12909 * aarch64-tdep.c (aarch64_process_record_test): Declare.
12910 (_initialize_aarch64_tdep): Register it.
12911 (aarch64_record_load_store): Handle PRFM instruction.
12912 (aarch64_process_record_test): New function.
12913
33877125
YQ
129142017-03-23 Yao Qi <yao.qi@linaro.org>
12915
12916 * aarch64-tdep.c (aarch64_record_load_store): Fix code
12917 indentation.
12918
a0eef940
YQ
129192017-03-23 Yao Qi <yao.qi@linaro.org>
12920
12921 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
12922
3f2a3564
PR
129232017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12924
12925 python/python.c (do_start_initialization): Fix memory leak.
12926
b67aeab0
SM
129272017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
12928
12929 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
12930 using get_ptrace_pid.
12931 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
12932 inferior_ptid.
12933 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
12934 inferior_ptid instead of pid.
12935
ffdbe864
YQ
129362017-03-22 Yao Qi <yao.qi@linaro.org>
12937
12938 * aarch64-tdep.c: Wrap locally used classes in anonymous
12939 namespace.
12940 * arm-tdep.c: Likewise.
12941 * linespec.c: Likewise.
12942 * ui-out.c: Likewise.
12943
9d736fbf
JG
129442017-03-22 Jonah Graham <jonah@kichwacoders.com>
12945
12946 PR gdb/19637
12947 * python/lib/gdb/printer/bound_registers.py: Import sys.
12948
3de88e9a
SM
129492017-03-21 Simon Marchi <simon.marchi@ericsson.com>
12950
12951 * windows-nat.c (do_windows_fetch_inferior_registers): Add
12952 windows_thread_info parameter and use it instead of
12953 current_thread.
12954 (windows_fetch_inferior_registers): Don't set current_thread,
12955 pass the thread to do_windows_fetch_inferior_registers. Use
12956 ptid from regcache instead of inferior_ptid.
12957 (do_windows_store_inferior_registers): Add windows_thread_info
12958 parameter and use it instead of current_thread.
12959 (windows_store_inferior_registers): Don't set current_thread,
12960 pass the thread to do_windows_store_inferior_registers. Use
12961 ptid from regcache instead of inferior_ptid.
12962
0e7b8f61
SM
129632017-03-21 Simon Marchi <simon.marchi@ericsson.com>
12964
12965 * ser-mingw.c (ser_windows_raw): Remove reference to
12966 struct serial::current_timeout.
12967
5badf10a
IR
129682017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
12969
12970 PR tdep/20928
12971 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
12972 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
12973 (sparc64_fsr_type): Fix %fsr decoding.
12974
cee59b3f
TW
129752017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
12976
12977 * python/py-record-btrace.c (btpy_insn_data): Change return type
12978 for Python 2.
12979
639a9038
SM
129802017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
12981
12982 * spu-linux-nat.c (spu_fetch_inferior_registers,
12983 spu_store_inferior_registers): Use ptid from regcache, set and
12984 restore inferior_ptid.
12985 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
12986 Likewise.
12987
bcc0c096
SM
129882017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
12989
12990 * i386-linux-nat.c (fetch_register, store_register,
12991 i386_linux_fetch_inferior_registers,
12992 i386_linux_store_inferior_registers): Use ptid from regcache.
12993 * ia64-linux-nat.c (ia64_linux_fetch_register,
12994 ia64_linux_store_register): Likewise.
12995 * inf-ptrace.c (inf_ptrace_fetch_register,
12996 inf_ptrace_store_register): Likewise.
12997 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
12998 m32r_linux_store_inferior_registers): Likewise.
12999 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
13000 m68kbsd_store_inferior_registers): Likewise.
13001 * m68k-linux-nat.c (fetch_register, store_register,
13002 m68k_linux_fetch_inferior_registers,
13003 m68k_linux_store_inferior_registers): Likewise.
13004 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
13005 m88kbsd_store_inferior_registers): Likewise.
13006 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
13007 mips_fbsd_store_inferior_registers): Likewise.
13008 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
13009 mips64_linux_regsets_store_registers): Likewise.
13010 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
13011 mipsnbsd_store_inferior_registers): Likewise.
13012 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
13013 mips64obsd_store_inferior_registers): Likewise.
13014 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
13015 Likewise.
13016 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
13017 ppcfbsd_store_inferior_registers): Likewise.
13018 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
13019 ppc_linux_store_inferior_registers): Likewise.
13020 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
13021 ppcnbsd_store_inferior_registers): Likewise.
13022 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
13023 ppcobsd_store_registers): Likewise.
13024 * procfs.c (procfs_fetch_registers, procfs_store_registers):
13025 Likewise.
13026 * ravenscar-thread.c (ravenscar_fetch_registers,
13027 ravenscar_store_registers, ravenscar_prepare_to_store):
13028 Likewise.
13029 * record-btrace.c (record_btrace_fetch_registers,
13030 record_btrace_store_registers, record_btrace_prepare_to_store):
13031 Likewise.
13032 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
13033 Lookup inferior using ptid from regcache, instead of
13034 current_inferior.
13035 * remote.c (remote_fetch_registers, remote_store_registers): Use
13036 ptid from regcache.
13037 * rs6000-nat.c (fetch_register, store_register): Likewise.
13038 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
13039 s390_linux_store_inferior_registers): Likewise.
13040 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
13041 shnbsd_store_inferior_registers): Likewise.
13042 * sol-thread.c (sol_thread_fetch_registers,
13043 sol_thread_store_registers): Likewise.
13044 * sparc-nat.c (sparc_fetch_inferior_registers,
13045 sparc_store_inferior_registers): Likewise.
13046 * tilegx-linux-nat.c (fetch_inferior_registers,
13047 store_inferior_registers): Likewise.
13048 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
13049 vaxbsd_store_inferior_registers): Likewise.
13050 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
13051 store_xtregs): Likewise.
13052
c0f55cc6
AV
130532017-03-20 Artemiy Volkov <artemiyv@acm.org>
13054
13055 PR gdb/14441
13056 * NEWS: Mention support for rvalue references in GDB and python.
13057 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
13058 supports both lvalue and rvalue references.
13059
15c0a2a9
AV
130602017-03-20 Artemiy Volkov <artemiyv@acm.org>
13061
13062 PR gdb/14441
13063 * gdbtypes.c (rank_one_type): Implement overloading
13064 resolution rules regarding rvalue references.
13065
aa006118
AV
130662017-03-20 Artemiy Volkov <artemiyv@acm.org>
13067
13068 PR gdb/14441
13069 * aarch64-tdep.c (aarch64_type_align)
13070 (aarch64_extract_return_value, aarch64_store_return_value): Change
13071 lvalue reference type checks to general reference type checks.
13072 * amd64-tdep.c (amd64_classify): Likewise.
13073 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
13074 Likewise.
13075 * arm-tdep.c (arm_type_align, arm_extract_return_value)
13076 (arm_store_return_value): Likewise.
13077 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
13078 * c-typeprint.c (c_print_type): Likewise.
13079 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
13080 (cplus_number_of_children, cplus_describe_child): Likewise.
13081 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
13082 * completer.c (expression_completer): Likewise.
13083 * cp-support.c (make_symbol_overload_list_adl_namespace):
13084 Likewise.
13085 * darwin-nat-info.c (info_mach_region_command): Likewise.
13086 * dwarf2loc.c (entry_data_value_coerce_ref)
13087 (value_of_dwarf_reg_entry): Likewise.
13088 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
13089 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
13090 Likewise.
13091 * findvar.c (extract_typed_address, store_typed_address):
13092 Likewise.
13093 * gdbtypes.c (rank_one_type): Likewise.
13094 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
13095 * infcall.c (value_arg_coerce): Likewise.
13096 * language.c (pointer_type): Likewise.
13097 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
13098 Likewise.
13099 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
13100 * mn10300-tdep.c (mn10300_type_align): Likewise.
13101 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
13102 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
13103 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
13104 Likewise.
13105 * printcmd.c (print_formatted, x_command): Likewise.
13106 * python/py-type.c (typy_get_composite, typy_template_argument):
13107 Likewise.
13108 * python/py-value.c (valpy_referenced_value)
13109 (valpy_get_dynamic_type, value_has_field): Likewise.
13110 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
13111 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
13112 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
13113 * spu-tdep.c (spu_scalar_value_p): Likewise.
13114 * symtab.c (lookup_symbol_aux): Likewise.
13115 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
13116 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
13117 Likewise.
13118 * valops.c (value_cast_pointers, value_cast)
13119 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
13120 (value_struct_elt, value_struct_elt_bitpos)
13121 (value_find_oload_method_list, find_overload_match)
13122 (value_rtti_indirect_type): Likewise.
13123 * valprint.c (val_print_scalar_type_p, generic_val_print):
13124 Likewise.
13125 * value.c (value_actual_type, value_as_address, unpack_long)
13126 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
13127 (coerce_ref): Likewise.
13128 * varobj.c (varobj_get_value_type): Likewise.
13129
3fcf899d
AV
131302017-03-20 Artemiy Volkov <artemiyv@acm.org>
13131
13132 PR gdb/14441
13133 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
13134 table of constants.
13135 * python/lib/gdb/command/explore.py: Support exploring values
13136 of rvalue reference types.
13137 * python/lib/gdb/types.py: Implement get_basic_type() for
13138 rvalue reference types.
13139 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
13140 constant.
13141 * python/py-value.c (valpy_getitem): Add an rvalue reference
13142 check.
13143 (valpy_reference_value): Add new parameter "refcode".
13144 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
13145 New wrappers for valpy_reference_value().
13146 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
13147 (gdbpy_invoke_xmethod): Likewise.
13148
4297a3f0
AV
131492017-03-20 Artemiy Volkov <artemiyv@acm.org>
13150
13151 PR gdb/14441
13152 * dwarf2read.c (process_die, read_type_die_1): Handle the
13153 DW_TAG_rvalue_reference_type DIE.
13154 (read_tag_reference_type): Add new parameter "refcode".
13155
e1cb3213
AV
131562017-03-20 Artemiy Volkov <artemiyv@acm.org>
13157
13158 PR gdb/14441
13159 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
13160 (c_type_print_modifier, c_type_print_varspec_suffix)
13161 (c_type_print_base): Support printing rvalue reference types.
13162 * c-valprint.c (c_val_print, c_value_print): Support printing
13163 rvalue reference values.
13164
e4347c89
AV
131652017-03-20 Artemiy Volkov <artemiyv@acm.org>
13166
13167 PR gdb/14441
13168 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
13169 typename.
13170 * cp-support.c (replace_typedefs): Handle
13171 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
13172 * python/py-type.c (typy_lookup_type): Likewise.
13173
53cc15f5
AV
131742017-03-20 Artemiy Volkov <artemiyv@acm.org>
13175
13176 PR gdb/14441
13177 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
13178 * parse.c (insert_type): Change assert statement.
13179 (follow_types): Handle rvalue reference types.
13180 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
13181 constant.
13182
a65cfae5
AV
131832017-03-20 Artemiy Volkov <artemiyv@acm.org>
13184
13185 PR gdb/14441
13186 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
13187 value_ref() interface.
13188 * c-valprint.c (c_value_print): Likewise.
13189 * infcall.c (value_arg_coerce): Likewise.
13190 * python/py-value.c (valpy_reference_value): Likewise.
13191 * valops.c (value_cast, value_reinterpret_cast)
13192 (value_dynamic_cast, typecmp): Likewise.
13193 (value_ref): Parameterize by kind of return value reference type.
13194 * value.h (value_ref): Add new parameter "refcode".
13195
3b224330
AV
131962017-03-20 Artemiy Volkov <artemiyv@acm.org>
13197
13198 PR gdb/14441
13199 * dwarf2read.c (read_tag_reference_type): Use
13200 lookup_lvalue_reference_type() instead of lookup_reference_type().
13201 * eval.c (evaluate_subexp_standard): Likewise.
13202 * f-exp.y: Likewise.
13203 * gdbtypes.c (make_reference_type, lookup_reference_type):
13204 Generalize with rvalue reference types.
13205 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
13206 convenience wrappers for lookup_reference_type().
13207 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
13208 reference kind parameter.
13209 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
13210 wrappers for lookup_reference_type().
13211 * guile/scm-type.c (gdbscm_type_reference): Use
13212 lookup_lvalue_reference_type() instead of lookup_reference_type().
13213 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
13214 * parse.c (follow_types): Likewise.
13215 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
13216 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
13217 Likewise.
13218 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
13219 (gdbpy_invoke_xmethod): Likewise.
13220 * stabsread.c: Provide extra argument to make_reference_type()
13221 call.
13222 * valops.c (value_ref, value_rtti_indirect_type): Use
13223 lookup_lvalue_reference_type() instead of lookup_reference_type().
13224
f9aeb8d4
AV
132252017-03-20 Artemiy Volkov <artemiyv@acm.org>
13226
13227 PR gdb/14441
13228 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
13229 (TYPE_IS_REFERENCE): New macro.
13230 (struct type): Add rvalue_reference_type field.
13231 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
13232
51457a05
MAL
132332017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
13234
13235 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
13236 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
13237 New function definition.
13238 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
13239 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
13240 New function declaration.
13241 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
13242 * mi/mi-interp.h: New file.
13243 * solib.c (info_sharedlibrary_command): Replace for loop with
13244 ALL_SO_LIBS macro
13245 * solib.h (update_solib_list): New function declaration.
13246 (so_list_head): Move macro.
13247 * solist.h (ALL_SO_LIBS): New macro.
13248
e696b3ad
MAL
132492017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
13250
13251 * infcmd.c (post_create_inferior): Remove unused argument in
13252 call to solib_add.
13253 * remote.c (remote_start_remote): Likewise.
13254 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
13255 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
13256 (enable_break): Likewise.
13257 * solib.c (update_solib_list): Remove unused target argument
13258 and its documentation.
13259 (solib_add): Remove unused target argument. Remove unused
13260 argument in call to update_solib_list.
13261 (info_sharedlibrary_command): Remove unused argument in call
13262 to update_solib_list.
13263 (sharedlibrary_command): Remove unused argument in call to
13264 solib_add.
13265 (handle_solib_event): Likewise.
13266 (reload_shared_libraries): Likewise.
13267 * solib.h (solib_add): Remove unused target argument.
13268
dcb84eda
AA
132692017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
13270
13271 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
13272 (s390_displaced_step_fixup): Cover relative branches with the
13273 default fixup handling. This fixes lack of support for some
13274 relative branch instructions.
13275
d9cb6cdc
SM
132762017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13277
13278 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
13279 ptid from regcache.
13280
1afaf9f4
SM
132812017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13282
13283 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
13284 i386_darwin_store_inferior_registers): Use ptid from regcache.
13285
aac12e24
SM
132862017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13287
13288 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
13289 i386bsd_store_inferior_registers): Use ptid from regcache.
13290
bbe1eef1
SM
132912017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13292
13293 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
13294 hppaobsd_store_registers): Use ptid from regcache.
13295
10799020
SM
132962017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13297
13298 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
13299 hppanbsd_store_registers): Use ptid from regcache.
13300
00204cf7
SM
133012017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13302
13303 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
13304 from regcache. Use get_ptrace_pid.
13305
11a33714
SM
133062017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13307
13308 * corelow.c (get_core_register_section): Use ptid from regcache,
13309 update doc.
13310
317cd492
SM
133112017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13312
13313 * bsd-uthread.c (bsd_uthread_fetch_registers,
13314 bsd_uthread_store_registers): Use ptid from regcache, set and
13315 restore inferior_ptid.
13316
9ac8a7c2
SM
133172017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13318
13319 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
13320 fetch_fp_regs, store_register, store_regs, store_fp_register,
13321 store_fp_regs): Use ptid from regcache.
13322
4ac4bb6a
SM
133232017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13324
13325 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
13326 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
13327 store_vfp_regs): Use ptid from regcache.
13328
9bcbdca8
PA
133292017-03-17 Pedro Alves <palves@redhat.com>
13330
13331 PR remote/21188
13332 * ser-base.c (ser_base_wait_for): Add comment.
13333 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
13334 version.
13335 * ser-unix.c (hardwire_raw): Remove reference to
13336 scb->current_timeout.
13337 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
13338 (hardwire_ops): Install ser_base_readchar instead of
13339 hardwire_readchar.
13340 * serial.h (struct serial) <current_timeout, timeout_remaining>:
13341 Remove fields.
13342
7503099f
JG
133432017-03-17 Jonah Graham <jonah@kichwacoders.com>
13344
13345 PR gdb/19637
13346 * python/lib/gdb/printer/bound_registers.py: Add support for
13347 Python 3.
13348
7942e96e
AA
133492017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
13350
13351 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
13352 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
13353 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
13354 byte_offset to subobj_byte_offset. Fix the handling of
13355 DWARF_VALUE_STACK on big-endian targets when coming via an
13356 implicit pointer.
13357 (dwarf2_evaluate_loc_desc): Adjust call to
13358 dwarf2_evaluate_loc_desc_full.
13359 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
13360 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
13361
ba14f379
YQ
133622017-03-16 Yao Qi <yao.qi@linaro.org>
13363
13364 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
13365 and REVSH instructions.
13366
b121eeb9
YQ
133672017-03-16 Yao Qi <yao.qi@linaro.org>
13368
13369 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
13370 (arm_record_test): Declare.
13371 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
13372 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
13373 align with the manual.
13374 (thumb_record_misc): Adjust the code order to align with the
13375 manual.
13376 (thumb2_record_decode_insn_handler): Fix instruction matching.
13377 (instruction_reader_thumb): New class.
13378 (arm_record_test): New function.
13379
728a7913
YQ
133802017-03-16 Yao Qi <yao.qi@linaro.org>
13381
13382 * arm-tdep.c (abstract_memory_reader): New class.
13383 (instruction_reader): New class.
13384 (extract_arm_insn): Add argument 'reader'. Callers updated.
13385 (decode_insn): Likewise.
13386
34b43320
DE
133872017-03-16 Doug Evans <dje@google.com>
13388
a7c0469f
DE
13389 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
13390 member. Change type of TYPE member to SCM. All uses updated.
13391 (lsscm_make_lazy_string_smob): Add assert.
13392 (lsscm_make_lazy_string): Flag bad length values.
13393 (lsscm_elt_type): New function.
13394 (gdbscm_lazy_string_to_value): Rewrite to use
13395 lsscm_safe_lazy_string_to_value.
13396 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
13397 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
13398 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
13399 in incoming type.
13400 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
13401 * guile/scm-type.c (tyscm_scm_to_type): New function.
13402
134032017-03-15 Doug Evans <dje@google.com>
13404
34b43320
DE
13405 PR python/17728, python/18439, python/18779
13406 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
13407 member. Change type of TYPE member to PyObject *. All uses updated.
13408 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
13409 (gdbpy_create_lazy_string_object): Flag bad length values.
13410 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
13411 Handle typedefs in incoming type.
13412 (stpy_lazy_string_elt_type): New function.
13413 (gdbpy_extract_lazy_string): Call it.
13414 * python/py-value.c (valpy_lazy_string): Flag bad length values.
13415 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
13416 typedefs in incoming type.
13417
a3a5fecc
DE
134182017-03-16 Doug Evans <dje@google.com>
13419
13420 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
13421 * guile/scm-type.c (tyscm_scm_to_type): New function.
13422
28f1c605
JW
134232017-03-16 Jiong Wang <jiong.wang@arm.com>
13424
13425 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
13426 "ULONGEST" for "skip".
13427
87c336f6
AA
134282017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
13429
13430 PR gdb/21220
13431 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
13432 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
13433 (inf_ptrace_peek_poke): ...here. New function. Now also loop
13434 over ptrace peek/poke until end of buffer or error.
13435
cf81cf60
SM
134362017-03-14 Simon Marchi <simon.marchi@ericsson.com>
13437
13438 * parse.c (length_of_subexp): Make static.
13439 * parser-defs.h (length_of_subexp): Remove.
13440
a379284a
AA
134412017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
13442
13443 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
13444 as well.
13445
8a6200ba
PA
134462017-03-14 Pedro Alves <palves@redhat.com>
13447
13448 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
13449 (main): Use std::unique_ptr. Remove calls to
13450 cp_demangled_name_parse_free.
13451
f79ec206
SM
134522017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13453
13454 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
13455 alphabsd_store_inferior_registers): Use regcache->ptid instead
13456 of inferior_ptid.
13457
edb5fb00
SM
134582017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13459
13460 * aix-thread.c (aix_thread_fetch_registers,
13461 aix_thread_store_registers): Use regcache->ptid instead of
13462 inferior_ptid.
13463
55119686
SM
134642017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13465
13466 * aarch64-linux-nat.c (fetch_gregs_from_thread,
13467 store_gregs_to_thread, fetch_fpregs_from_thread,
13468 store_fpregs_to_thread): Use regcache->ptid instead of
13469 inferior_ptid.
13470
6a06fbb7
SM
134712017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13472
13473 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
13474 amd64_linux_fetch_inferior_registers): Use regcache->ptid
13475 instead of inferior_ptid.
13476
c6386875
SM
134772017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13478
13479 * target.c (target_fetch_registers, target_store_registers): Add
13480 assert.
13481
ddaaf0fb
SM
134822017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13483
13484 * regcache.h (regcache_get_ptid): New function.
13485 * regcache.c (regcache_get_ptid): New function.
13486
b9da89d1 134872017-03-13 Mark Wielaard <mark@klomp.org>
13488
13489 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
13490
5f4d1085
KS
134912017-03-10 Keith Seitz <keiths@redhat.com>
13492
13493 PR c++/8218
13494 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
13495
c65d6b55
PA
134962017-03-08 Pedro Alves <palves@redhat.com>
13497
13498 PR gdb/18360
13499 * infrun.c (start_step_over, do_target_resume, resume)
13500 (restart_threads): Assert we're not resuming a thread that is
13501 meant to be stopped.
13502 (infrun_thread_stop_requested_callback): Delete.
13503 (infrun_thread_stop_requested): If the thread is internally
13504 stopped, queue a pending stop event and clear the thread's
13505 inline-frame state.
13506 (handle_stop_requested): New function.
13507 (handle_syscall_event, handle_inferior_event_1): Use
13508 handle_stop_requested.
13509 (handle_stop_requested): New function.
13510 (handle_signal_stop): Set the thread's stop_signal here instead of
13511 at caller.
13512 (finish_step_over): Clear step over info unconditionally.
13513 (handle_signal_stop): If the user had interrupted the event
13514 thread, consider the stop a random signal.
13515 (handle_signal_stop) <signal arrived while stepping over
13516 breakpoint>: Don't restart threads here.
13517 (stop_waiting): Don't clear step-over info here.
13518
15c22686
PA
135192017-03-08 Pedro Alves <palves@redhat.com>
13520
13521 PR 21206
13522 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
13523 goes to argument 2, not 1.
13524
6e5d74e7
PA
135252017-03-08 Pedro Alves <palves@redhat.com>
13526
13527 PR cli/21218
13528 * top.c (gdb_readline_wrapper): Avoid passing NULL to
13529 display_gdb_prompt.
13530 (command_line_input): Add comment.
13531
9753a2f6
PA
135322017-03-08 Pedro Alves <palves@redhat.com>
13533
13534 PR tui/21216
13535 * tui/tui-file.c (tui_file::write): New.
13536 * tui/tui-file.h (tui_file): Override "write".
13537 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
13538 factored out from ...
13539 (tui_puts): ... here.
13540 (tui_putc): Use them.
13541 (tui_write): New function.
13542 * tui/tui-io.h (tui_write): Declare.
13543
1672e0d9
SDJ
135442017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
13545
13546 * Makefile.in (SFILES): Replace "environ.c" with
13547 "common/environ.c".
13548 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
13549 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
13550 to...
13551 * common/environ.c: ... here.
13552 * environ.h: Moved to...
13553 * common/environ.h: ... here.
13554
f7bb4e3a
PB
135552017-03-07 Peter Bergner <bergner@vnet.ibm.com>
13556
13557 * gdbarch.sh (pstring_ptr): New static function.
13558 (gdbarch_disassembler_options): Use it.
13559 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
13560 not valid_disassembler_option->name.
13561 * gdbarch.c: Regenerate.
13562
e45ced6c
PB
135632017-03-07 Peter Bergner <bergner@vnet.ibm.com>
13564
13565 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
13566
5f6fd321
PA
135672017-03-07 Pedro Alves <palves@redhat.com>
13568
13569 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
13570
6dbb839a 135712017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
13572
13573 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
13574 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
13575 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 13576 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 13577
d274ecf4
SM
135782017-03-06 Simon Marchi <simon.marchi@ericsson.com>
13579
13580 * xtensa-linux-nat.c (fetch_gregs): Remove const.
13581
df97be55
SM
135822017-03-03 Simon Marchi <simon.marchi@ericsson.com>
13583
13584 * remote.c (remote_add_target_side_commands): Use range-based
13585 for loop.
13586
7d45f3df
YQ
135872017-03-03 Yao Qi <yao.qi@linaro.org>
13588
13589 PR gdb/21165
13590 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
13591 value is lazy.
13592 * valprint.c (common_val_print): Likewise.
13593
65b48a81
PB
135942017-02-28 Peter Bergner <bergner@vnet.ibm.com>
13595
13596 * NEWS: Mention new set/show disassembler-options commands.
13597 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
13598 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
13599 (prospective_options): New static variable.
13600 (gdb_disassembler::gdb_disassembler): Initialize
13601 m_di.disassembler_options.
13602 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
13603 (get_disassembler_options): New function.
13604 (set_disassembler_options): Likewise.
13605 (set_disassembler_options_sfunc): Likewise.
13606 (show_disassembler_options_sfunc): Likewise.
13607 (disassembler_options_completer): Likewise.
13608 (_initialize_disasm): Likewise.
13609 * disasm.h (get_disassembler_options): New prototype.
13610 (set_disassembler_options): Likewise.
13611 * gdbarch.sh (gdbarch_disassembler_options): New variable.
13612 (gdbarch_verify_disassembler_options): Likewise.
13613 * gdbarch.c: Regenerate.
13614 * gdbarch.h: Likewise.
13615 * arm-tdep.c (num_disassembly_options): Delete.
13616 (set_disassembly_style): Likewise.
13617 (arm_disassembler_options): New static variable.
13618 (set_disassembly_style_sfunc): Convert short style name into long
13619 option name. Call set_disassembler_options.
13620 (show_disassembly_style_sfunc): New function.
13621 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
13622 set_gdbarch_verify_disassembler_options.
13623 (_initialize_arm_tdep): Delete regnames variable and update callers.
13624 (arm_disassembler_options): Initialize.
13625 (disasm_options): New variable.
13626 (num_disassembly_options): Rename from this...
13627 (num_disassembly_styles): ...to this. Compute by scanning through
13628 disasm_options.
13629 (valid_disassembly_styles): Initialize using disasm_options.
13630 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
13631 set_arm_regname_option.
13632 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
13633 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
13634 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
13635 set_gdbarch_verify_disassembler_options.
13636 * s390-tdep.c (s390_disassembler_options): New static variable.
13637 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
13638 set_gdbarch_verify_disassembler_options.
13639
d538e36d
SM
136402017-02-27 Simon Marchi <simon.marchi@ericsson.com>
13641
13642 * remote.c (remote_add_target_side_condition): Remove "struct"
13643 keyword from range-based for loop.
13644
83621223
SM
136452017-02-27 Simon Marchi <simon.marchi@ericsson.com>
13646
13647 * remote.c (remote_add_target_side_condition): Use range-based
13648 for loop. Update comment.
13649
2123df0e
YQ
136502017-02-27 Yao Qi <yao.qi@linaro.org>
13651
13652 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
13653
8e368124
AH
136542017-02-26 Alan Hayward <alan.hayward@arm.com>
13655
13656 * regcache.c (regcache_raw_update): New function.
13657 (regcache_raw_read): Move code to regcache_raw_update.
13658 * regcache.h (regcache_raw_update): New declaration.
13659 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
13660
a49dd8dd
JK
136612017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
13662
13663 * dwarf2read.c (create_debug_type_hash_table): Initialize
13664 header.signature and header.type_offset_in_tu.
13665
34e4bae9
PA
136662017-02-24 Pedro Alves <palves@redhat.com>
13667
13668 * symtab.c (make_file_symbol_completion_list_1): Use
13669 add_symtab_completions.
13670
b0e4b369
AH
136712017-02-24 Alan Hayward <alan.hayward@arm.com>
13672
13673 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
13674
975c21ab
AH
136752017-02-24 Alan Hayward <alan.hayward@arm.com>
13676
13677 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
13678 I386_MAX_REGISTER_SIZE.
13679 (i386_pseudo_register_write): Likewise.
13680 (i386_process_record): Likewise.
13681 * i387-tdep.c (i387_supply_xsave): Likewise.
13682 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
13683 (store_register): Likewise.
13684
14bc53a8
PA
136852017-02-23 Pedro Alves <palves@redhat.com>
13686
13687 * ada-lang.c: Include "common/function-view.h".
13688 (ada_iterate_over_symbols): Adjust to use function_view as
13689 callback type.
13690 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
13691 (ada_make_symbol_completion_list): Use a lambda.
13692 (ada_exc_search_name_matches): Delete.
13693 (name_matches_regex): New.
13694 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
13695 * compile/compile-c-support.c: Include "common/function-view.h".
13696 (print_one_macro): Change prototype to accept a ui_file pointer.
13697 (write_macro_definitions): Use a lambda.
13698 * dwarf2read.c: Include "common/function-view.h".
13699 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
13700 (dw2_expand_symtabs_matching): Adjust to use function_view as
13701 callback type.
13702 * language.h: Include "common/function-view.h".
13703 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
13704 function_view as callback type.
13705 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
13706 * linespec.c: Include "common/function-view.h".
13707 (collect_info::add_symbol): New method.
13708 (struct symbol_and_data_callback, iterate_inline_only, struct
13709 symbol_matcher_data, iterate_name_matcher): Delete.
13710 (iterate_over_all_matching_symtabs): Adjust to use function_view
13711 as callback type and lambdas.
13712 (iterate_over_file_blocks): Adjust to use function_view as
13713 callback type.
13714 (decode_compound_collector): Now a class with private fields.
13715 (decode_compound_collector::release_symbols): New method.
13716 (collect_one_symbol): Rename to...
13717 (decode_compound_collector::operator()): ... this and adjust.
13718 (lookup_prefix_sym): decode_compound_collector construction bits
13719 move to decode_compound_collector ctor. Pass the
13720 decode_compound_collector object directly as callback. Remove
13721 cleanups and use decode_compound_collector::release_symbols
13722 instead.
13723 (symtab_collector): Now a class with private fields.
13724 (symtab_collector::release_symtabs): New method.
13725 (add_symtabs_to_list): Rename to...
13726 (symtab_collector::operator()): ... this and adjust.
13727 (collect_symtabs_from_filename): symtab_collector construction
13728 bits move to symtab_collector ctor. Pass the symtab_collector
13729 object directly as callback. Remove cleanups and use
13730 symtab_collector::release_symtabs instead.
13731 (collect_symbols): Delete.
13732 (add_matching_symbols_to_info): Use lambdas.
13733 * macrocmd.c (print_macro_callback): Delete.
13734 (info_macro_command): Use a lambda.
13735 (info_macros_command): Pass print_macro_definition as callable
13736 directly.
13737 (print_one_macro): Remove 'ignore' parameter.
13738 (macro_list_command): Adjust.
13739 * macrotab.c (macro_for_each_data::fn): Now a function_view.
13740 (macro_for_each_data::user_data): Delete field.
13741 (foreach_macro): Adjust to call the function_view.
13742 (macro_for_each): Adjust to use function_view as callback type.
13743 (foreach_macro_in_scope): Adjust to call the function_view.
13744 (macro_for_each_in_scope): Adjust to use function_view as callback
13745 type.
13746 * macrotab.h: Include "common/function-view.h".
13747 (macro_callback_fn): Declare a prototype instead of a pointer.
13748 Remove "user_data" parameter.
13749 (macro_for_each, macro_for_each_in_scope): Adjust to use
13750 function_view as callback type.
13751 * psymtab.c (partial_map_expand_apply)
13752 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
13753 Adjust to use function_view as callback type and to return bool.
13754 (psym_expand_symtabs_matching): Adjust to use function_view as
13755 callback types.
13756 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
13757 to use function_view as callback type and to return bool.
13758 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
13759 callback types.
13760 * symfile.c (expand_symtabs_matching): Adjust to use function_view
13761 as callback types.
13762 * symfile.h: Include "common/function-view.h".
13763 (expand_symtabs_file_matcher_ftype)
13764 (expand_symtabs_symbol_matcher_ftype)
13765 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
13766 return bool.
13767 (quick_symbol_functions::map_symtabs_matching_filename)
13768 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
13769 function_view as callback type and return bool.
13770 (expand_symtabs_matching): Adjust to use function_view as callback
13771 type.
13772 (maintenance_expand_name_matcher)
13773 (maintenance_expand_file_matcher): Delete.
13774 (maintenance_expand_symtabs): Use lambdas.
13775 * symtab.c (iterate_over_some_symtabs): Adjust to use
13776 function_view as callback types and return bool.
13777 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
13778 of a cleanup.
13779 (lookup_symtab_callback): Delete.
13780 (lookup_symtab): Use a lambda.
13781 (iterate_over_symbols): Adjust to use function_view as callback
13782 type.
13783 (struct search_symbols_data, search_symbols_file_matches)
13784 (search_symbols_name_matches): Delete.
13785 (search_symbols): Use a pair of lambdas.
13786 (struct add_name_data, add_macro_name, symbol_completion_matcher)
13787 (symtab_expansion_callback): Delete.
13788 (default_make_symbol_completion_list_break_on_1): Use lambdas.
13789 * symtab.h: Include "common/function-view.h".
13790 (iterate_over_some_symtabs): Adjust to use function_view as
13791 callback type and return bool.
13792 (iterate_over_symtabs): Adjust to use function_view as callback
13793 type.
13794 (symbol_found_callback_ftype): Remove 'data' parameter and return
13795 bool.
13796 (iterate_over_symbols): Adjust to use function_view as callback
13797 type.
13798
07e253aa
PA
137992017-02-23 Pedro Alves <palves@redhat.com>
13800
13801 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
13802 (%.o) <unittests/%.c>: New pattern.
13803 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
13804 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
13805 * common/function-view.h: New file.
13806 * unittests/function-view-selftests.c: New file.
13807 * configure: Regenerate.
13808
8eaf5320
SM
138092017-02-23 Simon Marchi <simon.marchi@ericsson.com>
13810
13811 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
13812 inferior_ptid.
13813 * go32-nat.c (go32_thread_alive): Likewise.
13814
38768751
YQ
138152017-02-23 Yao Qi <yao.qi@linaro.org>
13816
13817 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
13818 delete.
13819
0a8beaba
YQ
138202017-02-23 Yao Qi <yao.qi@linaro.org>
13821
13822 * varobj.c (varobj_clear_saved_item): Use delete instead of
13823 xfree.
13824 (update_dynamic_varobj_children): Likewise.
13825
58fdfd2c
JK
138262017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13827
13828 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
13829
1b90b139
SM
138302017-02-21 Simon Marchi <simon.marchi@ericsson.com>
13831
13832 * common/enum-flags.h (enum_flags::enum_flags): Initialize
13833 m_enum_value to 0 in default constructor.
13834
2039d74e
EBM
138352017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
13836
13837 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
13838 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
13839 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
13840 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
13841 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
13842 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
13843 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
13844 IS_STORE_CONDITIONAL_INSN.
13845
7814882a
JK
138462017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13847
13848 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
13849
0ae60b63
JK
138502017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13851
13852 * NEWS (Changes since GDB 7.12): Add DWARF-5.
13853
0224619f
JK
138542017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13855
13856 * dwarf2read.c (skip_one_die, read_attribute_value)
13857 (dwarf2_const_value_attr, dump_die_shallow)
13858 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
13859 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
13860
0af92d60
JK
138612017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13862
13863 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
13864 (dwarf_parse_macro_header): Accept DWARF version 5.
13865 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
13866
216f72a1
JK
138672017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13868
13869 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
13870 DW_AT_GNU_*.
13871 * common/common-exceptions.h (enum errors): Likewise.
13872 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
13873 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
13874 (dwarf_expr_context::execute_stack_op): Likewise.
13875 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
13876 Likewise.
13877 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
13878 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
13879 (show_entry_values_debug, call_site_to_target_addr)
13880 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
13881 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
13882 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
13883 (value_of_dwarf_block_entry, indirect_pieced_value)
13884 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
13885 (disassemble_dwarf_expression): Likewise.
13886 * dwarf2read.c (process_die, inherit_abstract_dies)
13887 (read_call_site_scope): Likewise.
13888 * gdbtypes.h (struct func_type, struct call_site_parameter)
13889 (struct call_site): Likewise.
13890 * stack.c (read_frame_arg): Likewise.
13891 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
13892
43988095
JK
138932017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13894
13895 * defs.h (read_unsigned_leb128): New declaration.
13896 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
13897 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
13898 (dwarf2_find_location_expression): Call also
13899 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
13900 * dwarf2loc.h (dwarf2_version): New declaration.
13901 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
13902 rnglists.
13903 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
13904 .debug_rnglists.
13905 (struct dwop_section_names): Add loclists_dwo.
13906 (dwop_section_names): Add .debug_loclists.dwo.
13907 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
13908 (struct dwarf2_per_cu_data): Add dwarf_version.
13909 (struct dwo_sections): Add loclists.
13910 (struct attr_abbrev): Add implicit_const.
13911 (read_indirect_line_string): New declaration.
13912 (read_unsigned_leb128): Delete declaration.
13913 (rcuh_kind): New definition.
13914 (read_and_check_comp_unit_head): Change parameter
13915 is_debug_types_section to section_kind.
13916 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
13917 (read_comp_unit_head): Change parameter abfd to section, add parameter
13918 section_kind. Handle DWARF-5.
13919 (error_check_comp_unit_head): Accept also DWARF version 5.
13920 (read_and_check_comp_unit_head): Change parameter
13921 is_debug_types_section to section_kind.
13922 (read_and_check_type_unit_head): Delete function.
13923 (read_abbrev_offset): Handle DWARF-5.
13924 (create_debug_type_hash_table): Add parameter section_kind. Process
13925 only DW_UT_type. Use signature and type_offset_in_tu from struct
13926 comp_unit_head.
13927 (create_debug_types_hash_table): Update create_debug_type_hash_table
13928 caller.
13929 (create_all_type_units): Call create_debug_type_hash_table.
13930 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
13931 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
13932 caller.
13933 (skip_one_die): Handle DW_FORM_implicit_const.
13934 (dwarf2_rnglists_process): New function.
13935 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
13936 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
13937 (read_attribute_value): Handle DW_FORM_implicit_const,
13938 DW_FORM_line_strp.
13939 (read_attribute): Handle DW_FORM_implicit_const.
13940 (read_indirect_string_at_offset_from): New function from
13941 read_indirect_string_at_offset.
13942 (read_indirect_string_at_offset): Call
13943 read_indirect_string_at_offset_from.
13944 (read_indirect_line_string_at_offset): New function.
13945 (read_indirect_string): New function comment.
13946 (read_indirect_line_string): New function.
13947 (read_unsigned_leb128): Make it global.
13948 (dwarf2_string_attr): Handle DWARF-5.
13949 (add_include_dir_stub, read_formatted_entries): New functions.
13950 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
13951 Handle DWARF-5.
13952 (per_cu_header_read_in): Update read_comp_unit_head caller.
13953 (dwarf2_version): New function.
13954 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
13955 rnglists.
13956 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
13957 fields.
13958
22d2f3ab
JK
139592017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13960
13961 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
13962
5f46c5a5
JK
139632017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13964
13965 * dwarf2read.c (dwarf2_ranges_process): New function from
13966 dwarf2_ranges_read.
13967 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
13968 dwarf2_ranges_process.
13969
78d4d2c5
JK
139702017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13971
13972 * dwarf2read.c (create_debug_type_hash_table): New function from
13973 create_debug_types_hash_table.
13974 (create_debug_types_hash_table): Call create_debug_type_hash_table.
13975 (create_all_type_units, open_and_init_dwo_file): Update
13976 create_debug_types_hash_table callers.
13977
1b076f25
SDJ
139782017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
13979
13980 PR gdb/16188
13981 * fork-child.c (trace_start_error): Fix thinko. va_end should
13982 refer to 'ap', not 'args'.
13983
0db8980c
SDJ
139842017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
13985 Pedro Alves <palves@redhat.com>
13986
13987 PR gdb/16188
13988 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
13989 calls succeeded.
13990 * fork-child.c (trace_start_error): New function.
13991 (trace_start_error_with_name): Likewise.
13992 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
13993 * inf-ptrace.c (inf_ptrace_me): Likewise.
13994 * inferior.h (trace_start_error): New prototype.
13995 (trace_start_error_with_name): Likewise.
13996
99e8a4f9
SDJ
139972017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
13998
13999 PR gdb/21164
14000 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
14001 NULL before using it.
14002 * symmisc.c (maintenance_print_symbols): Likewise.
14003 (maintenance_print_msymbols): Likewise.
14004
4e746bb6
TW
140052017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14006
14007 * NEWS: Add record Python bindings entry.
14008
140092017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14010
14011 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
14012 py-record-full.o.
14013 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
14014 * python/py-record-btrace.c, python/py-record-btrace.h,
14015 python/py-record-full.c, python/py-record-full.h: New file.
14016 * python/py-record.c: Add include for py-record-btrace.h and
14017 py-record-full.h.
14018 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
14019 recpy_instruction_history, recpy_function_call_history, recpy_begin,
14020 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
14021 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
14022 New definition.
14023 (gdbpy_initialize_btrace): New export.
14024 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
14025
140262017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14027
14028 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
14029 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
14030 * python/py-record.c: New file.
14031 * python/python-internal.h (gdbpy_start_recording,
14032 gdbpy_current_recording, gdpy_stop_recording,
14033 gdbpy_initialize_record): New export.
14034 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
14035 (python_GdbMethods): Add gdbpy_start_recording,
14036 gdbpy_current_recording and gdbpy_stop_recording.
14037
140382017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14039
14040 * record-btrace.c (record_btrace_record_method): New function.
14041 (init_record_btrace_ops): Initialize to_record_method.
14042 * record-full.c (record_full_record_method): New function.
14043 (init_record_full_ops, init_record_full_core_ops): Add
14044 record_full_record_method.
14045 * record.h (enum record_method): New enum.
14046 * target-debug.h (target_debug_print_enum_record_method: New define.
14047 * target-delegates.c: Regenerate.
14048 * target.c (target_record_method): New function.
14049 * target.h: Include record.h.
14050 (struct target_ops) <to_record_method>: New field.
14051 (target_record_method): New export.
14052
140532017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14054
14055 * record.h (record_start, record_stop): New export.
14056 * record.c (record_start, record_stop): New function.
14057
140582017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14059
14060 * btrace.c (btrace_fetch): Copy function call segments pointer
14061 into a vector.
14062 (btrace_clear): Clear the vector.
14063 (btrace_find_insn_by_number): Use binary search to find the correct
14064 function call segment.
14065 * btrace.h (brace_fun_p): New typedef.
14066 (struct btrace_thread_info) <functions>: New field.
14067
140682017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14069
14070 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
14071 * btrace.c (btrace_decode_error): ... here. New function.
14072 * btrace.h (btrace_decode_error): New export.
14073
140742017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14075
14076 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
14077 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
14078 btrace_find_insn_by_number): Remove special case for gaps.
14079 * btrace.h (btrace_insn_get_error): New export.
14080 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
14081 * record-btrace.c (btrace_insn_history): Print number for gaps.
14082 (record_btrace_info, record_btrace_goto): Handle gaps.
14083
3f77c769
TT
140842017-02-14 Tom Tromey <tom@tromey.com>
14085
14086 PR python/13598:
14087 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
14088 event.
14089 * python/py-evts.c (gdbpy_initialize_py_events): Add
14090 before_prompt registry.
14091 * python/py-events.h (events_object) <before_prompt>: New field.
14092
4c2c7ac6
MM
140932017-02-14 Markus Metzger <markus.t.metzger@intel.com>
14094
14095 * btrace.c (ftrace_new_switch): Preserve up link and flags.
14096
5cf30ebf
LM
140972017-02-13 Luis Machado <lgustavo@codesourcery.com>
14098
14099 * symfile (_initialize_symfile): Add usage text to the load command's
14100 help text.
14101
26a06916
SM
141022017-02-10 Simon Marchi <simon.marchi@ericsson.com>
14103
14104 * utils.c (defaulted_query): Don't query on secondary UIs.
14105
0b145e37
TT
141062017-02-10 Tom Tromey <tom@tromey.com>
14107
14108 * rust-lang.c (rust_get_disr_info): Remove unused variable.
14109
2d8365c4
TT
141102017-02-10 Tom Tromey <tom@tromey.com>
14111
14112 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
14113 "cleanup" local.
14114 * python/py-type.c (typy_legacy_template_argument): Remove
14115 unnecessary "cleanup" local.
14116
2bb8f231
TT
141172017-02-10 Tom Tromey <tom@tromey.com>
14118
14119 * python/python.c (do_start_initialization): New function, from
14120 _initialize_python.
14121 (_initialize_python): Call do_start_initialization.
14122 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
14123 goto.
14124
1bdfaf42
TT
141252017-02-10 Tom Tromey <tom@tromey.com>
14126
14127 * python/py-prettyprint.c (pretty_print_one_value): Use
14128 gdbpy_ref.
14129
88b6faea
TT
141302017-02-10 Tom Tromey <tom@tromey.com>
14131
14132 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
14133 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
14134 gdbpy_ref.
14135 * python/py-type.c (field_new): Use gdbpy_ref.
14136 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
14137 gdbpy_ref.
14138 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
14139 (py_free_pspace): Likewise.
14140 (pspace_to_pspace_object): Likewise.
14141 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
14142 (py_free_objfile): Likewise.
14143 (objfile_to_objfile_object): Likewise.
14144 * python/py-inferior.c (delete_thread_object): Use
14145 gdbpy_ref.
14146 (infpy_read_memory): Likewise.
14147 (py_free_inferior): Likewise.
14148 * python/py-evtregistry.c (create_eventregistry_object): Use
14149 gdbpy_ref.
14150 * python/py-event.c (create_event_object): Use gdbpy_ref.
14151
7780f186
TT
141522017-02-10 Tom Tromey <tom@tromey.com>
14153
14154 * python/py-ref.h (gdbpy_ref_policy): Now a template.
14155 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
14156 used.
14157 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
14158 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
14159 python/py-exitedevent.c, python/py-finishbreakpoint.c,
14160 python/py-framefilter.c, python/py-function.c,
14161 python/py-inferior.c, python/py-infevents.c,
14162 python/py-linetable.c, python/py-newobjfileevent.c,
14163 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
14164 python/py-signalevent.c, python/py-stopevent.c,
14165 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
14166 python/py-unwind.c, python/py-utils.c, python/py-value.c,
14167 python/py-varobj.c, python/py-xmethods.c, python/python.c,
14168 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
14169
d4b0bb18
TT
141702017-02-10 Tom Tromey <tom@tromey.com>
14171
14172 * ui-out.h (ui_out_emit_type): New class.
14173 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
14174 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
14175 and ui_out_emit_tuple.
14176 (enumerate_locals): Likewise.
14177 (py_mi_print_variables, py_print_locals, py_print_args): Use
14178 ui_out_emit_list.
14179 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
14180 ui_out_emit_list.
14181 * common/gdb_optional.h: New file.
14182
f67f945c
MG
141832017-02-10 Martin Galvan <martingalvan@sourceware.org>
14184
14185 * MAINTAINERS (Write After Approval): Update my e-mail address.
14186
18da0c51
MG
141872017-02-10 Martin Galvan <martingalvan@sourceware.org>
14188
14189 PR gdb/21122
14190 * breakpoint.c (_initialize_breakpoint): Update the help description
14191 of the 'commands' command to indicate that it takes a list argument.
14192
62c14536
SM
141932017-02-09 Simon Marchi <simon.marchi@ericsson.com>
14194
14195 * interps.c (current_interp_set_logging): Remove "return".
14196
ff6fa247
GB
141972017-02-09 Gary Benson <gbenson@redhat.com>
14198
14199 * symtab.c (add_symtab_completions): Prevent NULL pointer
14200 dereference.
14201
a474bd8e
PA
142022017-02-08 Pedro Alves <palves@redhat.com>
14203
14204 * interps.c (interp::interp): Remove reference to quiet_p.
14205 (interp_set): Make static. Remove dead "Switching to" output
14206 code.
14207 (interp_quiet_p, interp_set_quiet): Delete.
14208 (interpreter_exec_cmd): Don't set the interpreter quiet.
14209 * interps.h (interp_quiet_p): Make static.
14210 (class interp) <quiet_p>: Remove field
14211
3d7b173c
JG
142122017-02-08 Jerome Guitton <guitton@adacore.com>
14213
604c4576
JG
14214 * cli/cli-decode.c (find_command_name_length): Make it extern.
14215 * cli/cli-decode.h (find_command_name_length): Declare.
14216 * cli/cli-script.c (command_name_equals, line_first_arg):
14217 New functions.
14218 (process_next_line): Use cli-decode to parse command names.
14219 (build_command_line): Make args a constant pointer.
14220
142212017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 14222
3d7b173c
JG
14223 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
14224 Remove case-insensitive search.
14225
1291063d
JM
142262017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
14227
14228 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
14229 at the end of the line. Avoids an ARI warning.
14230
20b477a7
LM
142312017-02-06 Luis Machado <lgustavo@codesourcery.com>
14232
14233 * NEWS: Mention support for record/replay of Intel 64 rdrand and
14234 rdseed instructions.
14235 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
14236
3f7b46f2
IR
142372017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
14238
14239 PR tdep/20936
14240 Provide and use sparc32 and sparc64 target description XML files.
14241 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
14242 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
14243 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
14244 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
14245 * features/sparc/sparc32-solaris.xml: New file.
14246 * features/sparc/sparc64-solaris.xml: New file.
14247 * features/sparc/sparc32-solaris.c: Generated.
14248 * features/sparc/sparc64-solaris.c: Generated.
14249 * sparc-tdep.h: Account for differences in target descriptions.
14250 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
14251 (sparc32_register_type): Use target provided registers.
14252 (validate_tdesc_registers): New function.
14253 (sparc32_gdbarch_init): Use tdesc_has_registers.
14254 Set pseudoregister functions.
14255 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
14256 (sparc64_register_type): Use target provided registers.
14257 (sparc64_init_abi): Set pseudoregister functions.
14258
f0fd41c1
TT
142592017-02-03 Tom Tromey <tom@tromey.com>
14260
14261 PR rust/21097:
14262 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
14263 with a single member.
14264
d6f9b0fb
PA
142652017-02-03 Pedro Alves <palves@redhat.com>
14266
14267 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
14268 (cli_interp_base::~cli_interp_base): New.
14269 (cli_interp): New struct.
14270 (as_cli_interp): Cast the interp itself to cli_interp.
14271 (cli_interpreter_pre_command_loop): Rename to ...
14272 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
14273 parameter.
14274 (cli_interpreter_init): Rename to ...
14275 (cli_interp::init): ... this. Remove 'self' parameter. Use
14276 boolean. Make extern.
14277 (cli_interpreter_resume): Rename to ...
14278 (cli_interp::resume): ... this. Remove 'data' parameter. Make
14279 extern.
14280 (cli_interpreter_suspend): Rename to ...
14281 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
14282 extern.
14283 (cli_interpreter_exec): Rename to ...
14284 (cli_interp::exec): ... this. Remove 'data' parameter. Make
14285 extern.
14286 (cli_interpreter_supports_command_editing): Rename to ...
14287 (cli_interp_base::supports_command_editing): ... this. Remove
14288 'interp' parameter. Make extern.
14289 (cli_ui_out): Rename to ...
14290 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
14291 Make extern.
14292 (cli_set_logging): Rename to ...
14293 (cli_interp_base::set_logging): ... this. Remove 'interp'
14294 parameter. Make extern.
14295 (cli_interp_procs): Delete.
14296 (cli_interp_factory): Adjust to use "new".
14297 * cli/cli-interp.h: Include "interps.h".
14298 (struct cli_interp_base): New struct.
14299 * interps.c (struct interp): Delete. Fields moved to interps.h.
14300 (interp_new): Delete.
14301 (interp::interp, interp::~interp): New.
14302 (interp_set): Use bool, and return void. Assume the interpreter
14303 has suspend, init and resume methods, and that the all return
14304 void.
14305 (set_top_level_interpreter): interp_set returns void.
14306 (interp_ui_out): Adapt.
14307 (current_interp_set_logging): Adapt.
14308 (interp_data): Delete.
14309 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
14310 (interp_exec): Adapt.
14311 (top_level_interpreter_data): Delete.
14312 * interps.h (interp_init_ftype, interp_resume_ftype)
14313 (interp_suspend_ftype, interp_exec_ftype)
14314 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
14315 (class interp): New.
14316 (interp_new): Delete.
14317 (interp_set): Now returns void. Use bool.
14318 (interp_data, top_level_interpreter_data): Delete.
14319 * mi/mi-common.h: Include interps.h.
14320 (class mi_interp): Inherit from interp. Define a ctor. Declare
14321 init, resume, suspect, exec, interp_ui_out, set_logging and
14322 pre_command_loop methods.
14323 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
14324 (mi_interpreter_init): Rename to ...
14325 (mi_interp::init): ... this. Remove the 'interp' parameter, use
14326 bool, return void and make extern. Adjust.
14327 (mi_interpreter_resume): ... Rename to ...
14328 (mi_interp::resume): ... this. Remove the 'data' parameter,
14329 return void and make extern. Adjust.
14330 (mi_interpreter_suspend): ... Rename to ...
14331 (mi_interp::suspend): ... this. Remove the 'data' parameter,
14332 return void and make extern. Adjust.
14333 (mi_interpreter_exec): ... Rename to ...
14334 (mi_interp::exec): ... this. Remove the 'data' parameter and make
14335 extern. Adjust.
14336 (mi_interpreter_pre_command_loop): ... Rename to ...
14337 (mi_interp::pre_command_loop): ... this. Remove the 'self'
14338 parameter and make extern.
14339 (mi_on_normal_stop_1): Adjust.
14340 (mi_ui_out): Rename to ...
14341 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
14342 parameter and make extern. Adjust.
14343 (mi_set_logging): Rename to ...
14344 (mi_interp::set_logging): ... this. Remove the 'interp'
14345 parameter and make extern. Adjust.
14346 (mi_interp_procs): Delete.
14347 (mi_interp_factory): Adjust to use 'new'.
14348 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
14349 (mi_print_exception, mi_execute_command, mi_load_progress):
14350 Adjust.
14351 * tui/tui-interp.c (tui_interp): New class.
14352 (as_tui_interp): Return a tui_interp pointer.
14353 (tui_on_normal_stop, tui_on_signal_received)
14354 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
14355 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
14356 to use interp::interp_ui_out.
14357 (tui_init): Rename to ...
14358 (tui_interp::init): ... this. Remove the 'self' parameter, use
14359 bool, return void and make extern. Adjust.
14360 (tui_resume): Rename to ...
14361 (tui_interp::resume): ... this. Remove the 'data' parameter,
14362 return void and make extern. Adjust.
14363 (tui_suspend): Rename to ...
14364 (tui_interp::suspend): ... this. Remove the 'data' parameter,
14365 return void and make extern. Adjust.
14366 (tui_ui_out): Rename to ...
14367 (tui_interp::interp_ui_out): ... this. Remove the 'self'
14368 parameter, and make extern. Adjust.
14369 (tui_exec): Rename to ...
14370 (tui_interp::exec): ... this. Remove the 'data' parameter and
14371 make extern.
14372 (tui_interp_procs): Delete.
14373 (tui_interp_factory): Use "new".
14374
65c40c95
TT
143752017-02-02 Tom Tromey <tom@tromey.com>
14376
14377 * rust-exp.y (ends_raw_string, space_then_number)
14378 (rust_identifier_start_p): Return bool.
14379 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
14380 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
14381 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
14382 (rust_chartype_p): Return bool.
14383 (val_print_struct, rust_print_struct_def, rust_print_type):
14384 Update.
14385 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
14386 Return bool.
14387
b50f188d
TT
143882017-02-02 Tom Tromey <tom@tromey.com>
14389
14390 * rust-lang.c: Reindent.
14391
03c85b11
TT
143922017-02-02 Tom Tromey <tom@tromey.com>
14393
14394 * rust-lang.h (rust_crate_for_block): Update.
14395 * rust-lang.c (rust_crate_for_block): Return std::string.
14396 (rust_get_disr_info): Use std:;string, not
14397 gdb::unique_xmalloc_ptr.
14398 * rust-exp.y (crate_name): Update.
14399
9b6da501
PA
144002017-02-02 Pedro Alves <palves@redhat.com>
14401
14402 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
14403 field out of gdb_disassembler_test and make it static.
14404
ec4cb20b
PA
144052017-02-02 Pedro Alves <palves@redhat.com>
14406
14407 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
14408 mi1_interp and mi_interp fields.
14409
5be5dbf0
PA
144102017-02-02 Pedro Alves <palves@redhat.com>
14411
616268b6
PA
14412 * cli/cli-interp.c (struct saved_output_files, saved_output):
14413 Moved from cli/cli-logging.c.
14414 (cli_set_logging): New function.
14415 (cli_interp_procs): Install cli_set_logging.
14416 * cli/cli-interp.h (make_logging_output, cli_set_logging):
14417 Declare.
14418 * cli/cli-logging.c (struct saved_output_files, saved_output):
14419 Moved to cli/cli-interp.c.
14420 (pop_output_files): Don't save outputs here.
14421 (make_logging_output): New function.
14422 (handle_redirections): Don't build tee nor save previous outputs
14423 here.
14424 * interps.c (current_interp_set_logging): Change prototype.
14425 Assume there's always a set_logging_proc method installed.
14426 * interps.h (interp_set_logging_ftype): Change prototype.
14427 (current_interp_set_logging): Change prototype and adjust comment.
14428 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
14429 use make_logging_output.
14430 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
144312017-02-02 Pedro Alves <palves@redhat.com>
14432
5be5dbf0
PA
14433 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
14434 from ...
14435 (set_logging_overwrite): ... here.
14436 (logging_no_redirect_file): Delete.
14437 (set_logging_redirect): Don't handle redirection on the fly.
14438 Instead warn that "logging off" / "logging on" is necessary.
14439 (pop_output_files): Delete references to logging_no_redirect_file.
14440 (show_logging_command): Always speak in terms of what will happen
14441 once logging is reenabled.
14442
c99cc448
PA
144432017-02-02 Pedro Alves <palves@redhat.com>
14444
14445 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
14446
8b172ce7
PA
144472017-02-02 Pedro Alves <palves@redhat.com>
14448
14449 * disasm.c (gdb_pretty_print_insn): Rename to ...
14450 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
14451 Remove gdbarch parameter. Adapt to clear the object's buffers
14452 instead of allocating new buffers, and to print using the object's
14453 gdb_disassembler instead of calling gdb_print_insn.
14454 (dump_insns): Use gdb_pretty_print_disassembler.
14455 * disasm.h (gdb_pretty_print_insn): Delete declaration.
14456 (gdb_pretty_print_disassembler): New class.
14457 * record-btrace.c (btrace_insn_history): Use
14458 gdb_pretty_print_disassembler.
14459
d7e74731
PA
144602017-02-02 Pedro Alves <palves@redhat.com>
14461
14462 * ada-lang.c (type_as_string): Use string_file.
14463 * ada-valprint.c (ada_print_floating): Use string_file.
14464 * ada-varobj.c (ada_varobj_scalar_image)
14465 (ada_varobj_get_value_image): Use string_file.
14466 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
14467 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
14468 * breakpoint.c (update_inserted_breakpoint_locations)
14469 (insert_breakpoint_locations, reattach_breakpoints)
14470 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
14471 (print_it_watchpoint): Use string_file.
14472 (save_breakpoints): Use stdio_file.
14473 * c-exp.y (oper): Use string_file.
14474 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
14475 tee_file.
14476 (pop_output_files): Use delete.
14477 (handle_redirections): Use stdio_file and tee_file.
14478 * cli/cli-setshow.c (do_show_command): Use string_file.
14479 * compile/compile-c-support.c (c_compute_program): Use
14480 string_file.
14481 * compile/compile-c-symbols.c (generate_vla_size): Take a
14482 'string_file &' instead of a 'ui_file *'.
14483 (generate_c_for_for_one_variable): Take a 'string_file &' instead
14484 of a 'ui_file *'. Use string_file.
14485 (generate_c_for_variable_locations): Take a 'string_file &'
14486 instead of a 'ui_file *'.
14487 * compile/compile-internal.h (generate_c_for_for_one_variable):
14488 Take a 'string_file &' instead of a 'ui_file *'.
14489 * compile/compile-loc2c.c (push, pushf, unary, binary)
14490 (print_label, pushf_register_address, pushf_register)
14491 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
14492 'ui_file *'. Adjust.
14493 * compile/compile.c (compile_to_object): Use string_file.
14494 * compile/compile.h (compile_dwarf_expr_to_c)
14495 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
14496 'ui_file *'.
14497 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
14498 (replace_typedefs_qualified_name): Use string_file and
14499 obstack_copy0.
14500 * disasm.c (gdb_pretty_print_insn): Use string_file.
14501 (gdb_disassembly): Adjust reference the null_stream global.
14502 (do_ui_file_delete): Delete.
14503 (gdb_insn_length): Use null_stream.
14504 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
14505 * dwarf2loc.c (dwarf2_compile_property_to_c)
14506 (locexpr_generate_c_location, loclist_generate_c_location): Take a
14507 'string_file &' instead of a 'ui_file *'.
14508 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
14509 * dwarf2read.c (do_ui_file_peek_last): Delete.
14510 (dwarf2_compute_name): Use string_file.
14511 * event-top.c (gdb_setup_readline): Use stdio_file.
14512 * gdbarch.sh (verify_gdbarch): Use string_file.
14513 * gdbtypes.c (safe_parse_type): Use null_stream.
14514 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
14515 string_file.
14516 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
14517 'string_file *' instead of a 'ui_file *'.
14518 (gdbscm_arch_disassemble): Use string_file.
14519 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
14520 * guile/scm-ports.c (class ioscm_file_port): Now a class that
14521 inherits from ui_file.
14522 (ioscm_file_port_delete, ioscm_file_port_rewind)
14523 (ioscm_file_port_put): Delete.
14524 (ioscm_file_port_write): Rename to ...
14525 (ioscm_file_port::write): ... this. Remove file_port_magic
14526 checks.
14527 (ioscm_file_port_new): Delete.
14528 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
14529 ui_file_up.
14530 * guile/scm-type.c (tyscm_type_name): Use string_file.
14531 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
14532 Use string_file.
14533 * infcmd.c (print_return_value_1): Use string_file.
14534 * infrun.c (print_target_wait_results): Use string_file.
14535 * language.c (add_language): Use string_file.
14536 * location.c (explicit_to_string_internal): Use string_file.
14537 * main.c (captured_main_1): Use null_file.
14538 * maint.c (maintenance_print_architecture): Use stdio_file.
14539 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
14540 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
14541 event_channel>: Change type to mi_console_file pointer.
14542 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
14543 (mi_console_file_delete): Delete.
14544 (struct mi_console_file): Delete.
14545 (mi_console_file_magic): Delete.
14546 (mi_console_file_new): Delete.
14547 (mi_console_file::mi_console_file): New.
14548 (mi_console_file_delete): Delete.
14549 (mi_console_file_fputs): Delete.
14550 (mi_console_file::write): New.
14551 (mi_console_raw_packet): Delete.
14552 (mi_console_file::flush): New.
14553 (mi_console_file_flush): Delete.
14554 (mi_console_set_raw): Rename to ...
14555 (mi_console_file::set_raw): ... this.
14556 * mi/mi-console.h (class mi_console_file): New class.
14557 (mi_console_file_new, mi_console_set_raw): Delete.
14558 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
14559 (mi_set_logging): Use delete and tee_file. Adjust.
14560 * mi/mi-main.c (output_register): Use string_file.
14561 (mi_cmd_data_evaluate_expression): Use string_file.
14562 (mi_cmd_data_read_memory): Use string_file.
14563 (mi_cmd_execute, print_variable_or_computed): Use string_file.
14564 * mi/mi-out.c (mi_ui_out::main_stream): New.
14565 (mi_ui_out::rewind): Use main_stream and
14566 string_file.
14567 (mi_ui_out::put): Use main_stream and string_file.
14568 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
14569 Allocate a 'string_file' instead.
14570 (mi_out_new): Don't allocate a mem_fileopen stream here.
14571 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
14572 (mi_ui_out::main_stream): Declare method.
14573 * printcmd.c (eval_command): Use string_file.
14574 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
14575 * python/py-arch.c (archpy_disassemble): Use string_file.
14576 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
14577 * python/py-frame.c (frapy_str): Use string_file.
14578 * python/py-framefilter.c (py_print_type, py_print_single_arg):
14579 Use string_file.
14580 * python/py-type.c (typy_str): Use string_file.
14581 * python/py-unwind.c (unwind_infopy_str): Use string_file.
14582 * python/py-value.c (valpy_str): Use string_file.
14583 * record-btrace.c (btrace_insn_history): Use string_file.
14584 * regcache.c (regcache_print): Use stdio_file.
14585 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
14586 * remote.c (escape_buffer): Use string_file.
14587 * rust-lang.c (rust_get_disr_info): Use string_file.
14588 * serial.c (serial_open_ops_1): Use stdio_file.
14589 (do_serial_close): Use delete.
14590 * stack.c (print_frame_arg): Use string_file.
14591 (print_frame_args): Remove local mem_fileopen stream, not used.
14592 (print_frame): Use string_file.
14593 * symmisc.c (maintenance_print_symbols): Use stdio_file.
14594 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
14595 Take a 'string_file *' instead of a 'ui_file *'.
14596 * top.c (new_ui): Use stdio_file and stderr_file.
14597 (free_ui): Use delete.
14598 (execute_command_to_string): Use string_file.
14599 (quit_confirm): Use string_file.
14600 * tracepoint.c (collection_list::append_exp): Use string_file.
14601 * tui/tui-disasm.c (tui_disassemble): Use string_file.
14602 * tui/tui-file.c: Don't include "ui-file.h".
14603 (enum streamtype, struct tui_stream): Delete.
14604 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
14605 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
14606 (tui_file::tui_file): New method.
14607 (tui_file_fputs): Delete.
14608 (tui_file_get_strbuf): Delete.
14609 (tui_file::puts): New method.
14610 (tui_file_adjust_strbuf): Delete.
14611 (tui_file_flush): Delete.
14612 (tui_file::flush): New method.
14613 * tui/tui-file.h: Tweak intro comment.
14614 Include ui-file.h.
14615 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
14616 (tui_file_adjust_strbuf): Delete declarations.
14617 (class tui_file): New class.
14618 * tui/tui-io.c (tui_initialize_io): Use tui_file.
14619 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
14620 (tui_register_format): Use string_stream.
14621 * tui/tui-stack.c (tui_make_status_line): Use string_file.
14622 (tui_get_function_from_frame): Use string_file.
14623 * typeprint.c (type_to_string): Use string_file.
14624 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
14625 (null_stream): New global.
14626 (ui_file_delete): Delete.
14627 (ui_file::ui_file): New.
14628 (null_file_isatty): Delete.
14629 (ui_file::~ui_file): New.
14630 (null_file_rewind): Delete.
14631 (ui_file::printf): New.
14632 (null_file_put): Delete.
14633 (null_file_flush): Delete.
14634 (ui_file::putstr): New.
14635 (null_file_write): Delete.
14636 (ui_file::putstrn): New.
14637 (null_file_read): Delete.
14638 (ui_file::putc): New.
14639 (null_file_fputs): Delete.
14640 (null_file_write_async_safe): Delete.
14641 (ui_file::vprintf): New.
14642 (null_file_delete): Delete.
14643 (null_file::write): New.
14644 (null_file_fseek): Delete.
14645 (null_file::puts): New.
14646 (ui_file_data): Delete.
14647 (null_file::write_async_safe): New.
14648 (gdb_flush, ui_file_isatty): Adjust.
14649 (ui_file_put, ui_file_rewind): Delete.
14650 (ui_file_write): Adjust.
14651 (ui_file_write_for_put): Delete.
14652 (ui_file_write_async_safe, ui_file_read): Adjust.
14653 (ui_file_fseek): Delete.
14654 (fputs_unfiltered): Adjust.
14655 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
14656 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
14657 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
14658 (set_ui_file_data): Delete.
14659 (string_file::~string_file, string_file::write)
14660 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
14661 (do_ui_file_as_string, ui_file_as_string): Delete.
14662 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
14663 (struct mem_file): Delete.
14664 (mem_file_new): Delete.
14665 (stdio_file::stdio_file): New.
14666 (mem_file_delete): Delete.
14667 (stdio_file::stdio_file): New.
14668 (mem_fileopen): Delete.
14669 (stdio_file::~stdio_file): New.
14670 (mem_file_rewind): Delete.
14671 (stdio_file::set_stream): New.
14672 (mem_file_put): Delete.
14673 (stdio_file::open): New.
14674 (mem_file_write): Delete.
14675 (stdio_file_magic, struct stdio_file): Delete.
14676 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
14677 (stdio_file::flush): New.
14678 (stdio_file_read): Rename to ...
14679 (stdio_file::read): ... this. Adjust.
14680 (stdio_file_write): Rename to ...
14681 (stdio_file::write): ... this. Adjust.
14682 (stdio_file_write_async_safe): Rename to ...
14683 (stdio_file::write_async_safe) ... this. Adjust.
14684 (stdio_file_fputs): Rename to ...
14685 (stdio_file::puts) ... this. Adjust.
14686 (stdio_file_isatty): Delete.
14687 (stdio_file_fseek): Delete.
14688 (stdio_file::isatty): New.
14689 (stderr_file_write): Rename to ...
14690 (stderr_file::write) ... this. Adjust.
14691 (stderr_file_fputs): Rename to ...
14692 (stderr_file::puts) ... this. Adjust.
14693 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
14694 (stderr_file::stderr_file): New.
14695 (tee_file_magic): Delete.
14696 (struct tee_file): Delete.
14697 (tee_file::tee_file): New.
14698 (tee_file_new): Delete.
14699 (tee_file::~tee_file): New.
14700 (tee_file_delete): Delete.
14701 (tee_file_flush): Rename to ...
14702 (tee_file::flush): ... this. Adjust.
14703 (tee_file_write): Rename to ...
14704 (tee_file::write): ... this. Adjust.
14705 (tee_file::write_async_safe): New.
14706 (tee_file_fputs): Rename to ...
14707 (tee_file::puts): ... this. Adjust.
14708 (tee_file_isatty): Rename to ...
14709 (tee_file::isatty): ... this. Adjust.
14710 * ui-file.h (struct obstack, struct ui_file): Don't
14711 forward-declare.
14712 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
14713 (ui_file_write_ftype)
14714 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
14715 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
14716 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
14717 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
14718 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
14719 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
14720 (set_ui_file_fseek): Delete.
14721 (ui_file_data, ui_file_delete, ui_file_rewind)
14722 (struct ui_file): New.
14723 (ui_file_up): New.
14724 (class null_file): New.
14725 (null_stream): Declare.
14726 (ui_file_write_for_put, ui_file_put): Delete.
14727 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
14728 Delete.
14729 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
14730 (gdb_fopen, tee_file_new): Delete.
14731 (struct string_file): New.
14732 (struct stdio_file): New.
14733 (stdio_file_up): New.
14734 (struct stderr_file): New.
14735 (class tee_file): New.
14736 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
14737 of a 'ui_file *'. Adjust.
14738 * ui-out.h (class ui_out) <field_stream>: Likewise.
14739 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
14740 (null_stream): Delete.
14741 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
14742 Adjust.
14743 * utils.h (struct ui_file): Delete forward declaration..
14744 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
14745 (error_stream): Take a 'string_file &' instead of a
14746 'ui_file *'.
14747 * varobj.c (varobj_value_get_print_value): Use string_file.
14748 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
14749 * gdbarch.c: Regenerate.
14750
187808b0
PA
147512017-02-02 Pedro Alves <palves@redhat.com>
14752
14753 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
14754 (gdb_pretty_print_insn): ... this. Now a free function. Add back
14755 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
14756 Adjust to call gdb_print_insn instead of
14757 gdb_disassembler::print_insn.
14758 (dump_insns, do_mixed_source_and_assembly_deprecated)
14759 (do_mixed_source_and_assembly, do_assembly_only): Add back a
14760 'gdbarch' parameter. Remove gdb_disassembler parameter.
14761 (gdb_disassembly): Don't allocate a gdb_disassembler here.
14762 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
14763 declaration.
14764 (gdb_pretty_print_insn): Re-add declaration.
14765 * record-btrace.c (btrace_insn_history): Don't allocate a
14766 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
14767
7a8eb317
SM
147682017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
14769
14770 * disasm.h (gdb_disassembly): Remove file_string parameter.
14771 * disasm.c (gdb_disassembly): Likewise.
14772 * cli/cli-cmds.c (print_disassembly): Adapt.
14773 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
14774 * stack.c (do_gdb_disassembly): Likewise.
14775
7346ef59
AA
147762017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
14777
14778 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
14779 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
14780 targets. And if the implicit value is longer than needed, extract
14781 the first bytes instead of the "least significant" ones.
14782
cd4007e4
MM
147832017-02-01 Markus Metzger <markus.t.metzger@intel.com>
14784
14785 * btrace.c (btrace_enable): Do not call btrace_add_pc for
14786 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
14787 (btrace_fetch): Assert can_access_registers_ptid.
14788 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
14789 validate_registers_access.
14790
cf77c34e
MM
147912017-02-01 Markus Metzger <markus.t.metzger@intel.com>
14792
14793 * gdbthread.h (can_access_registers_ptid): New.
14794 * thread.c (can_access_registers_ptid): New.
14795
be85ce7d
PA
147962017-02-01 Pedro Alves <palves@redhat.com>
14797
14798 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
14799
29b0b251
PA
148002017-01-31 Pedro Alves <palves@redhat.com>
14801
14802 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
14803 Fix typos.
14804
289b5b24
PA
148052017-01-31 Pedro Alves <palves@redhat.com>
14806
14807 * stack.c (print_frame_args): Remove local mem_fileopen stream,
14808 not used.
14809
b47413b4
PA
148102017-01-31 Pedro Alves <palves@redhat.com>
14811
14812 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
14813
60adb36c
PA
148142017-01-31 Pedro Alves <palves@redhat.com>
14815
14816 * common/scoped_restore.h
14817 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
14818 change the value's parameter type to T2.
14819 (make_scoped_restore): Likewise.
14820
2735833d
WT
148212017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14822 Richard Henderson <rth@redhat.com>
14823
14824 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
14825 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
14826 GS_BASE for older kernels.
14827 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
14828 GS_BASE for older kernels.
14829 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
14830 and GS_BASE to the offset table.
14831 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
14832 system register group.
14833 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
14834 for older kernels.
14835 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
14836 amd64 ABI.
14837 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
14838 AMD64_GSBASE_REGNUM.
14839 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
14840 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
14841 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
14842 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
14843 i386/64bit-segments.xml in those rules.
14844 * features/i386/64bit-segments.xml: New file.
14845 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
14846 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
14847 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
14848 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
14849 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
14850 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
14851 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
14852 * features/i386/amd64-avx-linux.c: Regenerated.
14853 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
14854 * features/i386/amd64-avx-mpx.c: Regenerated.
14855 * features/i386/amd64-avx512-linux.c: Regenerated.
14856 * features/i386/amd64-linux.c: Regenerated.
14857 * features/i386/amd64-mpx-linux.c: Regenerated.
14858 * features/i386/i386-avx-mpx-linux.c: Regenerated.
14859 * features/i386/i386-avx-mpx.c: Regenerated.
14860 * features/i386/x32-avx-linux.c: Regenerated.
14861 * features/i386/x32-avx512-linux.c: Regenerated.
14862 * regformats/i386/amd64-avx-linux.dat: Regenerated.
14863 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
14864 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
14865 * regformats/i386/amd64-linux.dat: Regenerated.
14866 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
14867 * regformats/i386/x32-avx-linux.dat: Regenerated.
14868 * regformats/i386/x32-avx512-linux.dat: Regenerated.
14869 * regformats/i386/x32-linux.dat: Regenerated.
14870
8884e97e
WT
148712017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14872
14873 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
14874 Set to AMD64_NUM_REGS.
14875
7005d26a
WT
148762017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14877
14878 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
14879 that checks validity of a register number.
14880
4bd2e1b2
KC
148812017-01-27 Kees Cook <keescook@google.com>
14882
14883 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
14884 fetch_fpregs if target has fpa registers.
14885 (arm_linux_store_inferior_registers): Call store_fpregs if target
14886 has fpa registers.
14887
7cf1de6c
AA
148882017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
14889
14890 * cris-tdep.c (cris_gdbarch_init): Remove check for
14891 info.byte_order and force it to BFD_ENDIAN_LITTLE.
14892
874a1c8c
AT
148932017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
14894
14895 * corelow.c (get_core_register_section): Check for regset
14896 existence before checking for REGSET_VARIABLE_SIZE.
14897
d8b49cf0
YQ
148982017-01-26 Yao Qi <yao.qi@linaro.org>
14899 Pedro Alves <palves@redhat.com>
14900
14901 PR gdb/20939
14902 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
14903 call memory_error, save memaddr instead.
14904 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
14905 negative, cal memory_error.
14906 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
14907
658ca58c
YQ
149082017-01-26 Yao Qi <yao.qi@linaro.org>
14909
14910 * disasm-selftests.c (memory_error_test): New function.
14911 (_initialize_disasm_selftests): Register memory_error_test.
14912
79843d45
YQ
149132017-01-26 Yao Qi <yao.qi@linaro.org>
14914
14915 * Makefile.in (SFILES): Add disasm-selftests.c and
14916 selftest-arch.c.
14917 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
14918 * disasm-selftests.c: New file.
14919 * selftest-arch.c: New file.
14920 * selftest-arch.h: New file.
14921
8cafda32
YQ
149222017-01-26 Yao Qi <yao.qi@linaro.org>
14923
14924 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
14925 to bfd_arch_mep. Don't return 0 if section is not
14926 found. Call print_insn_mep.
14927
e47ad6c0
YQ
149282017-01-26 Pedro Alves <palves@redhat.com>
14929 Yao Qi <yao.qi@linaro.org>
14930
14931 * arm-tdep.c: Include "disasm.h".
14932 (gdb_print_insn_arm): Update code to get gdbarch.
14933 * disasm.c (dis_asm_read_memory): Change it to
14934 gdb_disassembler::dis_asm_read_memory.
14935 (dis_asm_memory_error): Likewise.
14936 (dis_asm_print_address): Likewise.
14937 (gdb_pretty_print_insn): Change it to
14938 gdb_disassembler::pretty_print_insn.
14939 (dump_insns): Add one argument gdb_disassemlber. All
14940 callers updated.
14941 (do_mixed_source_and_assembly_deprecated): Likewise.
14942 (do_mixed_source_and_assembly): Likewise.
14943 (do_assembly_only): Likewise.
14944 (gdb_disassembler::gdb_disassembler): New.
14945 (gdb_disassembler::print_insn): New.
14946 * disasm.h (class gdb_disassembler): New.
14947 (gdb_pretty_print_insn): Remove declaration.
14948 (gdb_disassemble_info): Likewise.
14949 * guile/scm-disasm.c (class gdbscm_disassembler): New.
14950 (gdbscm_disasm_read_memory_worker): Update.
14951 (gdbscm_disasm_read_memory): Update.
14952 (gdbscm_disasm_memory_error): Remove.
14953 (gdbscm_disasm_print_address): Remove.
14954 (gdbscm_disassembler::gdbscm_disassembler): New.
14955 (gdbscm_print_insn_from_port): Update.
14956 * mips-tdep.c: Include disasm.h.
14957 (gdb_print_insn_mips): Update code to get gdbarch.
14958 * record-btrace.c (btrace_insn_history): Update.
14959 * spu-tdep.c: Include disasm.h.
14960 (struct spu_dis_asm_data): Remove.
14961 (struct spu_dis_asm_info): New.
14962 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
14963 SPU id.
14964 (gdb_print_insn_spu): Cast disassemble_info to
14965 spu_dis_asm_info.
14966
80d75874
YQ
149672017-01-26 Yao Qi <yao.qi@linaro.org>
14968
14969 * disasm.c (do_ui_file_delete): Delete.
14970 (gdb_insn_length): Move code creating stream to ...
14971 * utils.c (null_stream): ... here. New function.
14972 * utils.h (null_stream): Declare.
14973
60685cd0
SM
149742017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
14975
14976 * python/py-inferior.c (find_thread_object): Return directly
14977 from the loop. Remove "found" variable.
14978
eb1cdb62
JB
149792017-01-21 Joel Brobecker <brobecker@adacore.com>
14980
14981 GDB 7.12.1 released.
14982
b1ce6568
SM
149832017-01-20 Simon Marchi <simon.marchi@ericsson.com>
14984
14985 * python/py-function.c (fnpy_call): Reorder declarations to have
14986 the gdbpy_enter object declared first.
14987 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
14988
6f8b0407
SM
149892017-01-20 Simon Marchi <simon.marchi@ericsson.com>
14990
fec93fb1 14991 PR python/21068
6f8b0407
SM
14992 * python/python-internal.h (PyMem_RawMalloc): Define for
14993 Python < 3.4.
14994 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
14995 PyMem_RawMalloc instead of PyMem_Malloc.
14996
78cbbba8
LM
149972017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
14998 Luis Machado <lgustavo@codesourcery.com>
14999
15000 * NEWS (New commands): Mention flash-erase.
15001 (New MI commands): Mention target-flash-erase.
15002 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
15003 command.
15004 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
15005 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
15006 * target.c (flash_erase_command): New function.
15007 (initialize_targets): Add new flash-erase command.
15008 * target.h (flash_erase_command): New declaration.
15009
2132fe85
JB
150102017-01-20 Joel Brobecker <brobecker@adacore.com>
15011
15012 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
15013 HAVE_SYS_PROCFS_H is defined.
15014
d1dff226
AH
150152017-01-18 Alan Hayward <alan.hayward@arm.com>
15016
15017 * remote.c (struct cached_reg): Change data into a pointer.
15018 * (stop_reply_dtr): Free data pointers before deleting vector.
15019 (process_stop_reply): Likewise.
15020 (remote_parse_stop_reply): Allocate space for data
15021
9890e433
AH
150222017-01-18 Alan Hayward <alan.hayward@arm.com>
15023
15024 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
15025 MAX_REGISTER_SIZE.
15026 (amd64_pseudo_register_read_value): Likewise.
15027 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
15028 (store_register_using_P): Likewise.
15029 * regcache.c (regcache_xfer_part): Likewise.
15030
7a36499a
IR
150312017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
15032
15033 Split real and pseudo registers.
15034 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
15035 (sparc32_pseudo_regnum): New enum.
15036 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
15037 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
15038 (SPARC32_CP0_REGISTERS): New macro.
15039 (sparc32_pseudo_register_name): New function.
15040 (sparc32_register_name): Use sparc32_pseudo_register_name.
15041 (sparc32_pseudo_register_type): New function.
15042 (sparc32_register_type): Use sparc32_pseudo_register_type.
15043 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
15044 pseudo register numbers.
15045 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
15046 (SPARC64_CP0_REGISTERS): New macro.
15047 (sparc64_pseudo_register_name): New function.
15048 (sparc64_register_name): Use sparc64_pseudo_register_name.
15049 (sparc64_pseudo_register_type): New function.
15050 (sparc64_register_type): Use sparc64_pseudo_register_type.
15051 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
15052 pseudo register numbers.
15053 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
15054 sparc64_store_arguments): Handle pseudo register numbers.
15055
6f8976bf
YQ
150562017-01-13 Yao Qi <yao.qi@linaro.org>
15057
15058 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
15059 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
15060 output.
15061 (getpkt_or_notif_sane_1): Likewise.
15062
e4241ace
YQ
150632017-01-13 Yao Qi <yao.qi@linaro.org>
15064
15065 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
15066 of CC. Pass "-x c++-header" instead of "-x c".
15067
3015c064
SM
150682017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15069
15070 * remote.c (remote_can_async_p): Update comment.
15071
fde1b17d
SM
150722017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15073
15074 * linux-nat.c (linux_nat_can_async_p): Update comment.
15075
ca1ca08b
SM
150762017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15077
15078 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
15079
4ad2da73
SM
150802017-01-11 Simon Marchi <simon.marchi@ericsson.com>
15081
15082 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
15083
c8b23b3f
TT
150842017-01-10 Tom Tromey <tom@tromey.com>
15085
15086 * python/py-type.c (typy_legacy_template_argument): Update.
15087 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
15088 ~demangle_parse_info): Declare new members.
15089 (cp_demangled_name_to_comp): Return unique_ptr.
15090 (cp_demangled_name_parse_free)
15091 (make_cleanup_cp_demangled_name_parse_free)
15092 (cp_new_demangle_parse_info): Remove.
15093 * cp-support.c (do_demangled_name_parse_free_cleanup)
15094 (make_cleanup_cp_demangled_name_parse_free): Remove.
15095 (inspect_type, cp_canonicalize_string_full)
15096 (cp_canonicalize_string): Update.
15097 (mangled_name_to_comp): Change return type.
15098 (cp_class_name_from_physname, method_name_from_physname)
15099 (cp_func_name, cp_remove_params): Update.
15100 * cp-name-parser.y (demangle_parse_info): New constructor, from
15101 cp_new_demangle_parse_info.
15102 (~demangle_parse_info): New destructor, from
15103 cp_demangled_name_parse_free.
15104 (cp_merge_demangle_parse_infos): Update.
15105 (cp_demangled_name_to_comp): Change return type.
15106
1ac32117
TT
151072017-01-10 Tom Tromey <tom@tromey.com>
15108
15109 * top.c (prevent_dont_repeat): Change return type.
15110 * python/python.c (execute_gdb_command): Use std::string.
15111 Update.
15112 * guile/guile.c (gdbscm_execute_gdb_command): Update.
15113 * command.h (prevent_dont_repeat): Change return type.
15114 * breakpoint.c (bpstat_do_actions_1): Update.
15115
0cf08227
TT
151162017-01-10 Tom Tromey <tom@tromey.com>
15117
15118 * value.h (scoped_value_mark::~scoped_value_mark): Call
15119 free_to_mark.
15120 (scoped_value_mark::free_to_mark): New method.
15121 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
15122 scoped_value_mark.
15123
eb115069
TT
151242017-01-10 Tom Tromey <tom@tromey.com>
15125
15126 * python/py-value.c (valpy_dereference, valpy_referenced_value)
15127 (valpy_reference_value, valpy_const_value, valpy_get_address)
15128 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
15129 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
15130 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
15131 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
15132 scoped_value_mark.
15133 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
15134 * value.h (scoped_value_mark): New class.
15135
906768f9
TT
151362017-01-10 Tom Tromey <tom@tromey.com>
15137
15138 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
15139 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
15140 * psymtab.c (discard_psymtabs_upto): Remove.
15141 (make_cleanup_discard_psymtabs): Remove.
15142 (struct psymtab_state): Remove.
15143
bef155c3
TT
151442017-01-10 Tom Tromey <tom@tromey.com>
15145
15146 * record-full.c (record_full_save_cleanups): Remove.
15147 (record_full_save): Use gdb::unlinker.
15148 * gcore.c (do_bfd_delete_cleanup): Remove.
15149 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
15150 cleanups.
15151 * dwarf2read.c (unlink_if_set): Remove.
15152 (write_psymtabs_to_index): Use gdb::unlinker.
15153 * common/gdb_unlinker.h: New file.
15154
192b62ce
TT
151552017-01-10 Tom Tromey <tom@tromey.com>
15156
15157 * windows-tdep.c (windows_xfer_shared_library): Update.
15158 * windows-nat.c (windows_make_so): Update.
15159 * utils.h (make_cleanup_bfd_unref): Remove.
15160 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
15161 * symfile.h (symfile_bfd_open)
15162 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
15163 * symfile.c (read_symbols, symbol_file_add)
15164 (separate_debug_file_exists): Update.
15165 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
15166 (generic_load, reread_symbols): Update.
15167 * symfile-mem.c (symbol_file_add_from_memory): Update.
15168 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
15169 (spu_symbol_file_add_from_memory): Update.
15170 * solist.h (struct target_so_ops) <bfd_open>: Return
15171 gdb_bfd_ref_ptr.
15172 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
15173 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
15174 gdb_bfd_ref_ptr.
15175 (solib_map_sections, reload_shared_libraries_1): Update.
15176 * solib-svr4.c (enable_break): Update.
15177 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
15178 * solib-frv.c (enable_break2): Update.
15179 * solib-dsbt.c (enable_break): Update.
15180 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
15181 gdb_bfd_ref_ptr.
15182 (darwin_solib_get_all_image_info_addr_at_init): Update.
15183 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
15184 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
15185 * record-full.c (record_full_save): Update.
15186 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
15187 * procfs.c (insert_dbx_link_bpt_in_file): Update.
15188 * minidebug.c (find_separate_debug_file_in_section): Return
15189 gdb_bfd_ref_ptr.
15190 * machoread.c (macho_add_oso_symfile): Change abfd to
15191 gdb_bfd_ref_ptr.
15192 (macho_symfile_read_all_oso): Update.
15193 (macho_check_dsym): Return gdb_bfd_ref_ptr.
15194 (macho_symfile_read): Update.
15195 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
15196 (jit_bfd_try_read_symtab): Update.
15197 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
15198 (gdb_bfd_openw, gdb_bfd_openr_iovec)
15199 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
15200 gdb_bfd_ref_ptr.
15201 (gdb_bfd_ref_policy): New struct.
15202 (gdb_bfd_ref_ptr): New typedef.
15203 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
15204 (gdb_bfd_openw, gdb_bfd_openr_iovec)
15205 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
15206 gdb_bfd_ref_ptr.
15207 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
15208 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
15209 (gcore_command): Update.
15210 * exec.c (exec_file_attach): Update.
15211 * elfread.c (elf_symfile_read): Update.
15212 * dwarf2read.c (dwarf2_get_dwz_file): Update.
15213 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
15214 (open_and_init_dwo_file): Update.
15215 (open_dwp_file): Return gdb_bfd_ref_ptr.
15216 (open_and_init_dwp_file): Update.
15217 * corelow.c (core_open): Update.
15218 * compile/compile-object-load.c (compile_object_load): Update.
15219 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
15220 * coffread.c (coff_symfile_read): Update.
15221 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
15222 gdb_bfd_ref_ptr. Rename.
15223 (dump_bfd_file, restore_command): Update.
15224 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
15225 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
15226 (find_separate_debug_file_by_buildid): Update.
15227
50315b21
TT
152282017-01-10 Tom Tromey <tom@tromey.com>
15229
15230 * common/gdb_ref_ptr.h: New file.
15231 * python/py-ref.h (struct gdbpy_ref_policy): New.
15232 (gdbpy_ref): Now a typedef.
15233
fc4007c9
TT
152342017-01-10 Tom Tromey <tom@tromey.com>
15235
15236 * utils.h (make_cleanup_htab_delete): Don't declare.
15237 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
15238 Remove.
15239 * linespec.c (decode_compound_collector): Add constructor,
15240 destructor.
15241 (lookup_prefix_sym): Remove cleanup.
15242 (symtab_collector): Add constructor, destructor.
15243 (collect_symtabs_from_filename): Remove cleanup.
15244 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
15245 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
15246 Use htab_up.
15247 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
15248 * dwarf2read.c (dw2_expand_symtabs_matching)
15249 (dw2_map_symbol_filenames, dwarf_decode_macros)
15250 (write_psymtabs_to_index): Use htab_up.
15251 * dwarf2loc.c (func_verify_no_selftailcall)
15252 (call_site_find_chain_1, func_verify_no_selftailcall)
15253 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
15254 std::vector, gdb::unique_xmalloc_ptr.
15255 (call_sitep): Remove typedef.
15256 (dwarf2_locexpr_baton_eval): Remove unused variable.
15257
8dbcee67
TT
152582017-01-10 Tom Tromey <tom@tromey.com>
15259
15260 * python/python-internal.h (make_cleanup_py_decref)
15261 (make_cleanup_py_xdecref): Don't declare.
15262 * python/py-utils.c (py_decref, make_cleanup_py_decref)
15263 (py_xdecref, make_cleanup_py_xdecref): Remove.
15264
13df46cc
TT
152652017-01-10 Tom Tromey <tom@tromey.com>
15266
15267 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
15268 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
15269
06fc9bf7
TT
152702017-01-10 Tom Tromey <tom@tromey.com>
15271
15272 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
15273
830a4934
TT
152742017-01-10 Tom Tromey <tom@tromey.com>
15275
15276 * python/py-utils.c (unicode_to_encoded_string)
15277 (python_string_to_target_string)
15278 (python_string_to_target_python_string)
15279 (python_string_to_host_string, gdbpy_obj_to_string)
15280 (get_addr_from_python): Use gdbpy_ref.
15281
4586d543
TT
152822017-01-10 Tom Tromey <tom@tromey.com>
15283
15284 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
15285 gdbpy_ref.
15286
59876f8f
TT
152872017-01-10 Tom Tromey <tom@tromey.com>
15288
15289 * python/python.c (eval_python_command, gdbpy_decode_line)
15290 (gdbpy_run_events, gdbpy_start_type_printers)
15291 (gdbpy_apply_type_printers): Use gdbpy_ref.
15292
97d83487
TT
152932017-01-10 Tom Tromey <tom@tromey.com>
15294
15295 * python/py-param.c (get_doc_string, compute_enum_values): Use
15296 gdbpy_ref.
15297
9205649a
TT
152982017-01-10 Tom Tromey <tom@tromey.com>
15299
15300 * python/py-inferior.c (find_thread_object, build_inferior_list):
15301 Use gdbpy_ref.
15302
74c49d45
TT
153032017-01-10 Tom Tromey <tom@tromey.com>
15304
15305 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
15306
16361ffb
TT
153072017-01-10 Tom Tromey <tom@tromey.com>
15308
15309 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
15310 gdbpy_ref.
15311
905f2cca
TT
153122017-01-10 Tom Tromey <tom@tromey.com>
15313
15314 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
15315 extra incref.
15316 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
15317 Use gdbpy_ref.
15318
64081434
TT
153192017-01-10 Tom Tromey <tom@tromey.com>
15320
15321 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
15322 gdbpy_ref.
15323
59e9e831
TT
153242017-01-10 Tom Tromey <tom@tromey.com>
15325
15326 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
15327 decref results of PyArg_ParseTupleAndKeywords.
15328
9de10f6d
TT
153292017-01-10 Tom Tromey <tom@tromey.com>
15330
15331 * python/python.c (python_run_simple_file): Use
15332 unique_xmalloc_ptr, gdbpy_ref.
15333
2bd5759d
TT
153342017-01-10 Tom Tromey <tom@tromey.com>
15335
15336 * python/py-prettyprint.c (print_stack_unless_memory_error)
15337 (print_string_repr, print_children): Use gdbpy_ref.
15338 (dummy_python_frame): New class.
15339 (dummy_python_frame::dummy_python_frame): Rename from
15340 push_dummy_python_frame.
15341 (py_restore_tstate): Remove.
15342
3b4e0e01
TT
153432017-01-10 Tom Tromey <tom@tromey.com>
15344
15345 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
15346
17a22718
TT
153472017-01-10 Tom Tromey <tom@tromey.com>
15348
15349 * python/python.c (ensure_python_env, restore_python_env):
15350 Remove.
15351 * python/python-internal.h (ensure_python_env): Don't declare.
15352 * varobj.h (varobj_ensure_python_env): Don't declare.
15353 * varobj.c (varobj_ensure_python_env): Remove.
15354
68cdc557
TT
153552017-01-10 Tom Tromey <tom@tromey.com>
15356
15357 * varobj.c (varobj_value_get_print_value): Use
15358 gdbpy_enter_varobj.
15359
1eba6383
TT
153602017-01-10 Tom Tromey <tom@tromey.com>
15361
15362 * python/py-prettyprint.c (print_string_repr, print_children):
15363 Update.
15364 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
15365 of "encoding".
15366 * varobj.c (varobj_value_get_print_value): Update.
15367 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
15368
bde7b3e3
TT
153692017-01-10 Tom Tromey <tom@tromey.com>
15370
15371 * varobj.c (varobj_get_display_hint)
15372 (dynamic_varobj_has_child_method, install_new_value_visualizer)
15373 (varobj_set_visualizer, free_variable): Use
15374 gdbpy_enter_varobj.
15375
a7785f8c
TT
153762017-01-10 Tom Tromey <tom@tromey.com>
15377
15378 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
15379 (do_finish_initialization): New function. Use gdbpy_ref.
15380 (gdbpy_finish_initialization): Use gdbpy_enter. Call
15381 do_finish_initialization.
15382
2865bfce
TT
153832017-01-10 Tom Tromey <tom@tromey.com>
15384
15385 * python/py-param.c (get_set_value, get_show_value): Use
15386 gdbpy_enter, gdbpy_ref.
15387
0e9dcc75
TT
153882017-01-10 Tom Tromey <tom@tromey.com>
15389
15390 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
15391
12a5cedd
TT
153922017-01-10 Tom Tromey <tom@tromey.com>
15393
15394 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
15395
788f2586
TT
153962017-01-10 Tom Tromey <tom@tromey.com>
15397
15398 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
15399 Use gdbpy_enter_varobj.
15400
6cd67bea
TT
154012017-01-10 Tom Tromey <tom@tromey.com>
15402
15403 * varobj.c (gdbpy_enter_varobj): New constructor.
15404 * python/python-internal.h (gdbpy_enter_varobj): New class.
15405 * python/py-varobj.c (py_varobj_get_iterator): Use
15406 gdbpy_enter_varobj.
15407
14b122bf
TT
154082017-01-10 Tom Tromey <tom@tromey.com>
15409
15410 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
15411 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
15412 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
15413 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
15414 unique_xmalloc_ptr.
15415 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
15416
bf1ca3b9
TT
154172017-01-10 Tom Tromey <tom@tromey.com>
15418
15419 * python/py-xmethods.c (invoke_match_method): Use
15420 gdbpy_ref.
15421
572a5524
TT
154222017-01-10 Tom Tromey <tom@tromey.com>
15423
15424 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
15425 gdbpy_enter, gdbpy_ref.
15426
396a78b6
TT
154272017-01-10 Tom Tromey <tom@tromey.com>
15428
15429 * python/python.c (python_interactive_command): Use gdbpy_enter.
15430
a88b13c7
TT
154312017-01-10 Tom Tromey <tom@tromey.com>
15432
15433 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
15434 gdbpy_ref.
15435
e9f0c363
TT
154362017-01-10 Tom Tromey <tom@tromey.com>
15437
15438 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
15439 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
15440
6349f452
TT
154412017-01-10 Tom Tromey <tom@tromey.com>
15442
15443 * utils.h (htab_deleter): New struct.
15444 (htab_up): New typedef.
15445 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
15446 gdbpy_enter, gdbpy_ref, htab_up.
15447
c0171de6
TT
154482017-01-10 Tom Tromey <tom@tromey.com>
15449
15450 * python/py-unwind.c (pending_frame_invalidate): Remove.
15451 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
15452
f18e226f
TT
154532017-01-10 Tom Tromey <tom@tromey.com>
15454
15455 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
15456 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
15457
c57af3f1
TT
154582017-01-10 Tom Tromey <tom@tromey.com>
15459
15460 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
15461
60e600ec
TT
154622017-01-10 Tom Tromey <tom@tromey.com>
15463
15464 * python/python.c (gdbpy_eval_from_control_command)
15465 (gdbpy_source_script, gdbpy_run_events)
15466 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
15467 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
15468 gdbpy_enter.
15469
bf7da5b0
TT
154702017-01-10 Tom Tromey <tom@tromey.com>
15471
15472 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
15473
2d38bced
TT
154742017-01-10 Tom Tromey <tom@tromey.com>
15475
15476 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
15477
07bc7329
TT
154782017-01-10 Tom Tromey <tom@tromey.com>
15479
15480 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
15481 (python_on_inferior_call_pre, python_on_inferior_call_post)
15482 (python_on_memory_change, python_on_register_change)
15483 (python_inferior_exit, python_new_objfile, add_thread_object)
15484 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
15485
6e7c365e
TT
154862017-01-10 Tom Tromey <tom@tromey.com>
15487
15488 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
15489 (bpfinishpy_handle_exit): Use gdbpy_enter.
15490
6ba0cd40
TT
154912017-01-10 Tom Tromey <tom@tromey.com>
15492
15493 * python/py-cmd.c (cmdpy_destroyer)
15494 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
15495 gdbpy_enter.
15496
de2dc875
TT
154972017-01-10 Tom Tromey <tom@tromey.com>
15498
15499 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
15500 gdbpy_enter.
15501 (gdbpy_breakpoint_has_cond): Likewise.
15502
4ecee2c4
TT
155032017-01-10 Tom Tromey <tom@tromey.com>
15504
15505 * python/python.c (gdbpy_enter): New constructor.
15506 (~gdbpy_enter): New destructor.
15507 (restore_python_env, ensure_python_env): Rewrite.
15508 * python/python-internal.h (gdbpy_enter): New class.
15509
37fce74f
TT
155102017-01-10 Tom Tromey <tom@tromey.com>
15511
15512 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
15513
53a0cca3
TT
155142017-01-10 Tom Tromey <tom@tromey.com>
15515
15516 * python/py-value.c (value_has_field, get_field_flag)
15517 (get_field_type, valpy_getitem, convert_value_from_python): Use
15518 gdbpy_ref.
15519
ff3724f5
TT
155202017-01-10 Tom Tromey <tom@tromey.com>
15521
15522 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
15523 gdbpy_ref.
15524
0700aea5
TT
155252017-01-10 Tom Tromey <tom@tromey.com>
15526
15527 * python/py-prettyprint.c (search_pp_list)
15528 (find_pretty_printer_from_objfiles)
15529 (find_pretty_printer_from_progspace)
15530 (find_pretty_printer_from_gdb, find_pretty_printer)
15531 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
15532 gdbpy_ref.
15533
1bb44c9f
TT
155342017-01-10 Tom Tromey <tom@tromey.com>
15535
15536 * python/py-param.c (call_doc_function): Use gdbpy_ref.
15537
87ce03fd
TT
155382017-01-10 Tom Tromey <tom@tromey.com>
15539
15540 * python/py-linetable.c (build_line_table_tuple_from_pcs)
15541 (ltpy_get_all_source_lines): Use gdbpy_ref.
15542
ee0a3fb8
TT
155432017-01-10 Tom Tromey <tom@tromey.com>
15544
15545 * python/py-framefilter.c (extract_sym, extract_value)
15546 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
15547 gdbpy_ref.
15548
bf2a52fa
TT
155492017-01-10 Tom Tromey <tom@tromey.com>
15550
15551 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
15552
f59fe7f8
TT
155532017-01-10 Tom Tromey <tom@tromey.com>
15554
15555 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
15556
80bd970a
TT
155572017-01-10 Tom Tromey <tom@tromey.com>
15558
15559 * python/py-function.c (convert_values_to_python, fnpy_init): Use
15560 gdbpy_ref.
15561
d1b3de2e
TT
155622017-01-10 Tom Tromey <tom@tromey.com>
15563
15564 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
15565
3bb43384
TT
155662017-01-10 Tom Tromey <tom@tromey.com>
15567
15568 * python/py-type.c (convert_field, make_fielditem, typy_fields)
15569 (typy_range): Use gdbpy_ref.
15570
abf5651e
TT
155712017-01-10 Tom Tromey <tom@tromey.com>
15572
15573 * python/py-threadevent.c (create_thread_event_object): Use
15574 gdbpy_ref.
15575 * python/py-stopevent.c (create_stop_event_object): Simplify.
15576 (emit_stop_event): Use gdbpy_ref.
15577 * python/py-signalevent.c (create_signal_event_object): Use
15578 gdbpy_ref.
15579 * python/py-newobjfileevent.c (create_new_objfile_event_object)
15580 (emit_new_objfile_event, create_clear_objfiles_event_object)
15581 (emit_clear_objfiles_event): Use gdbpy_ref.
15582 * python/py-infevents.c (create_inferior_call_event_object)
15583 (create_register_changed_event_object)
15584 (create_memory_changed_event_object, emit_inferior_call_event)
15585 (emit_memory_changed_event, emit_register_changed_event): Use
15586 gdbpy_ref.
15587 * python/py-exitedevent.c (create_exited_event_object)
15588 (emit_exited_event): Use gdbpy_ref.
15589 * python/py-event.h (evpy_emit_event): Remove
15590 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
15591 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
15592 * python/py-continueevent.c (emit_continue_event): Use
15593 gdbpy_ref.
15594 * python/py-breakpoint.c (gdbpy_breakpoint_created)
15595 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
15596 gdbpy_ref.
15597 * python/py-bpevent.c (create_breakpoint_event_object): Use
15598 gdbpy_ref.
15599
a68ff33e
TT
156002017-01-10 Tom Tromey <tom@tromey.com>
15601
15602 * python/py-ref.h: New file.
15603
7becfd03
SM
156042017-01-10 Simon Marchi <simon.marchi@ericsson.com>
15605
15606 * cli-out.c (cli_ui_out::do_redirect): Change return type to
15607 void.
15608 * cli-out.h (cli_ui_out::do_redirect): Likewise.
15609 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
15610 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
15611 * ui-out.c (ui_out::redirect): Likewise.
15612 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
15613 * cli/cli-logging.c (set_logging_redirect): Update call site of
15614 ui_out::redirect.
15615 (handle_redirections): Likewise.
15616 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
15617 * top.c (execute_command_to_string): Likewise.
15618 * utils.c (do_ui_out_redirect_pop): Likewise.
15619
df294654
SM
156202017-01-10 Simon Marchi <simon.marchi@ericsson.com>
15621
15622 * stack.c (_initialize_stack): Update "frame" command help message.
15623
f5e6296e
IB
156242017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
15625
15626 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
15627
0e2d6fa6
YQ
156282017-01-06 Yao Qi <yao.qi@linaro.org>
15629
15630 * x86-linux-nat.h: Include gdb_proc_service.h.
15631
44d6d3f9
YQ
156322017-01-06 Yao Qi <yao.qi@linaro.org>
15633
15634 * ser-base.h: Include serial.h.
15635
656731fe
YQ
156362017-01-06 Yao Qi <yao.qi@linaro.org>
15637
15638 * ppc-linux-tdep.h: Include ppc-tdep.h.
15639
1ca8f924
YQ
156402017-01-06 Yao Qi <yao.qi@linaro.org>
15641
15642 * nat/amd64-linux-siginfo.h: Include signal.h.
15643
bc3008c4
YQ
156442017-01-06 Yao Qi <yao.qi@linaro.org>
15645
15646 * nat/aarch64-linux-hw-point.h: Include break-common.h.
15647
66c80d03
YQ
156482017-01-06 Yao Qi <yao.qi@linaro.org>
15649
15650 * mi/mi-parse.h: Include mi-cmds.h.
15651
051d2dda
YQ
156522017-01-06 Yao Qi <yao.qi@linaro.org>
15653
15654 * inf-loop.c: Don't include "target.h".
15655 * inf-loop.h: Include it here.
15656
8018d34f
YQ
156572017-01-06 Yao Qi <yao.qi@linaro.org>
15658
15659 * dfp.h: Include "dboulest.h" and "expression.h".
15660
c0b8369c
YQ
156612017-01-06 Yao Qi <yao.qi@linaro.org>
15662
15663 * ax-gdb.h: Include "ax.h".
15664
ad5cba2a
YQ
156652017-01-06 Yao Qi <yao.qi@linaro.org>
15666
15667 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
15668 with nat/gdb_ptrace.h.
15669
1c33cd7f
YQ
156702017-01-05 Yao Qi <yao.qi@linaro.org>
15671
15672 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
15673 new line.
15674 (mips64_fbsd_sigframe_init): Likewise.
15675
c988ac1d
JB
156762017-01-04 John Baldwin <jhb@FreeBSD.org>
15677
15678 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
15679 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
15680
b268007c
JB
156812017-01-04 John Baldwin <jhb@FreeBSD.org>
15682
15683 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
15684 * NEWS: Mention new FreeBSD/mips native configuration.
15685 * config/mips/fbsd.mh: New file.
15686 * configure.host: Add mips*-*-freebsd*.
15687 * mips-fbsd-nat.c: New file.
15688
387360da
JB
156892017-01-04 John Baldwin <jhb@FreeBSD.org>
15690
15691 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
15692 (ALLDEPFILES): Add mips-fbsd-tdep.c.
15693 * NEWS: Mention new FreeBSD/mips target.
15694 * configure.tgt: Add mips*-*-freebsd*.
15695 * mips-fbsd-tdep.c: New file.
15696 * mips-fbsd-tdep.h: New file.
15697
2aaaf250
YQ
156982017-01-04 Yao Qi <yao.qi@linaro.org>
15699
15700 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
15701 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
15702
61baf725
JB
157032017-01-01 Joel Brobecker <brobecker@adacore.com>
15704
6dbb839a 15705 Update copyright year range in all GDB files.
61baf725 15706
c113e7ff 157072017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 15708
c113e7ff 15709 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 15710
c113e7ff 15711For older changes see ChangeLog-2016.
c906108c
SS
15712\f
15713Local Variables:
15714mode: change-log
15715left-margin: 8
15716fill-column: 74
15717version-control: never
57da7796 15718coding: utf-8
c906108c 15719End:
This page took 2.893688 seconds and 4 git commands to generate.