Remove a use of is_mi_like_p from tracepoint.c
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2018-04-30 Tom Tromey <tom@tromey.com>
2
3 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
4
5 2018-04-30 Tom Tromey <tom@tromey.com>
6
7 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
8 (info_spu_event_command): Remove some uses of is_mi_like_p.
9
10 2018-04-30 Tom Tromey <tom@tromey.com>
11
12 * python/py-framefilter.c (py_print_single_arg)
13 (enumerate_locals, py_print_args, py_print_frame): Remove some
14 uses of is_mi_like_p.
15
16 2018-04-30 Tom Tromey <tom@tromey.com>
17
18 * ui-out.c: Update.
19 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
20 * ui-out.h (ui_out::is_mi_like_p): Now const.
21 (ui_out::do_is_mi_like_p): Now const.
22 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
23
24 2018-04-30 Tom Tromey <tom@tromey.com>
25
26 * varobj.c (varobj_set_visualizer): Use new_reference.
27 * python/python.c (gdbpy_decode_line): Use new_reference.
28 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
29 new_reference.
30
31 2018-04-30 Tom Tromey <tom@tromey.com>
32
33 * varobj.c (install_new_value): Use new_reference.
34 * value.h (value_incref): Return void. Swap intro comment with
35 value_decref.
36 * value.c (set_value_parent): Use new_reference.
37 (value_incref): Return void. Update intro comment.
38 (release_value): Use new_reference.
39 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
40
41 2018-04-30 Tom Tromey <tom@tromey.com>
42
43 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
44 * gdb_bfd.h (new_bfd_ref): Remove.
45 (gdb_bfd_open): Update comment.
46 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
47 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
48 (gdb_bfd_fdopenr): Use new_reference.
49 * exec.c (exec_file_attach): Use new_reference.
50
51 2018-04-30 Tom Tromey <tom@tromey.com>
52
53 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
54 method.
55
56 2018-04-30 Tom Tromey <tom@tromey.com>
57
58 * jit.c (jit_read_code_entry): Use type_align.
59 * i386-tdep.c (i386_gdbarch_init): Don't call
60 set_gdbarch_long_long_align_bit.
61 * gdbarch.sh: Remove long_long_align_bit.
62 * gdbarch.c, gdbarch.h: Rebuild.
63 * arc-tdep.c (arc_type_align): New function.
64 (arc_gdbarch_init): Use arc_type_align. Don't call
65 set_gdbarch_long_long_align_bit.
66
67 2018-04-30 Tom Tromey <tom@tromey.com>
68
69 * rust-lang.c (rust_type_alignment): Remove.
70 (rust_composite_type): Use type_align.
71
72 2018-04-30 Tom Tromey <tom@tromey.com>
73
74 * NEWS: Mention Type.align.
75 * python/py-type.c (typy_get_alignof): New function.
76 (type_object_getset): Add "alignof".
77
78 2018-04-30 Tom Tromey <tom@tromey.com>
79
80 PR exp/17095:
81 * NEWS: Update.
82 * std-operator.def (UNOP_ALIGNOF): New operator.
83 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
84 New.
85 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
86 * c-lang.c (c_op_print_tab): Add alignof.
87 * c-exp.y (ALIGNOF): New token.
88 (exp): Add "ALIGNOF" production.
89 (ident_tokens): Add _Alignof and alignof.
90
91 2018-04-30 Tom Tromey <tom@tromey.com>
92
93 * i386-tdep.c (i386_type_align): New function.
94 (i386_gdbarch_init): Update.
95 * gdbarch.sh (type_align): New method.
96 * gdbarch.c, gdbarch.h: Rebuild.
97 * arch-utils.h (default_type_align): Declare.
98 * arch-utils.c (default_type_align): New function.
99 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
100 (struct type) <align_log2>: New field.
101 <instance_flags>: Now a bitfield.
102 (TYPE_RAW_ALIGN): New macro.
103 (type_align, type_raw_align, set_type_align): Declare.
104 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
105 functions.
106 * dwarf2read.c (quirk_rust_enum): Set type alignment.
107 (get_alignment, maybe_set_alignment): New functions.
108 (read_structure_type, read_enumeration_type, read_array_type)
109 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
110 (read_subrange_type, read_base_type): Set type alignment.
111
112 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
113
114 * dwarf2read.c (read_index_from_section): Use bool.
115
116 2018-04-29 Fabian Groffen <grobian@gentoo.org>
117
118 PR gdb/22950
119 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
120 with #ifdef.
121
122 2018-04-29 John Reiser <jreiser@BitWagon.com>
123
124 PR build/22873
125 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
126 last step, and do it atomically.
127
128 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
129
130 * compile/compile-c-types.c (convert_int, convert_float):
131 Update for C FE v1.
132
133 2018-04-27 Tom Tromey <tom@tromey.com>
134
135 PR rust/22545:
136 * rust-lang.c (rust_inclusive_range_type_p): New function.
137 (rust_range): Handle inclusive ranges.
138 (rust_compute_range): Likewise.
139 * rust-exp.y (struct rust_op) <inclusive>: New field.
140 (DOTDOTEQ): New constant.
141 (range_expr): Add "..=" productions.
142 (operator_tokens): Add "..=" token.
143 (ast_range): Add "inclusive" parameter.
144 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
145 ranges.
146 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
147 bounds values.
148 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
149 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
150 Update comments.
151 * expprint.c (print_subexp_standard): Handle new bounds values.
152 (dump_subexp_body_standard): Likewise.
153
154 2018-04-27 Tom Tromey <tom@tromey.com>
155
156 * configure: Rebuild.
157 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
158 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
159 "OVERRIDE".
160 (class symbol_needs_eval_context): Likewise.
161 * dwarf2read.c (mock_mapped_index::symbol_name_count)
162 (mock_mapped_index::symbol_name_at): Use "override". Remove
163 "virtual".
164 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
165 "override".
166 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
167 * aarch64-tdep.c (instruction_reader::read): Use "override".
168 (instruction_reader_test::read): Likewise.
169 * arm-tdep.c (instruction_reader::read): Use "override".
170 (instruction_reader_thumb::read): Likewise.
171
172 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
173
174 PR remote/9665
175 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
176 instead of remote_send.
177 (remote_send): Remove.
178
179 2018-04-26 Pedro Alves <palves@redhat.com>
180
181 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
182 find_function_start_sal instead of find_pc_line.
183
184 2018-04-26 Pedro Alves <palves@redhat.com>
185
186 * breakpoint.c (set_breakpoint_location_function): Handle
187 mst_data_gnu_ifunc.
188 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
189 * elfread.c (elf_symtab_read): Give data symbols with
190 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
191 (elf_rel_plt_read): Update comment.
192 * linespec.c (convert_linespec_to_sals): Handle
193 mst_data_gnu_ifunc.
194 (minsym_found): Handle mst_data_gnu_ifunc.
195 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
196 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
197 * parse.c (find_minsym_type_and_address): Handle
198 mst_data_gnu_ifunc.
199 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
200 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
201 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
202 comment.
203 <mst_data_gnu_ifunc>: New enumerator.
204
205 2018-04-26 Pedro Alves <palves@redhat.com>
206
207 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
208 (lookup_minimal_symbol_by_pc_section): ... this. Replace
209 'want_trampoline' parameter by a lookup_msym_prefer parameter.
210 Handle it.
211 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
212 (lookup_minimal_symbol_by_pc): Adjust.
213 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
214 (lookup_solib_trampoline_symbol_by_pc): Adjust.
215 * minsyms.h (lookup_msym_prefer): New enum.
216 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
217 parameter by a lookup_msym_prefer parameter.
218
219 2018-04-26 Pedro Alves <palves@redhat.com>
220
221 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
222 ends in "@plt" instead of looking at the symbol's section.
223
224 2018-04-26 Pedro Alves <palves@redhat.com>
225
226 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
227 all references.
228 (find_pc_partial_function_gnu_ifunc): Rename to ...
229 (find_pc_partial_function): ... this, and remove references to
230 'is_gnu_ifunc_p'.
231 (find_pc_partial_function): Delete old implementation.
232 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
233
234 2018-04-26 Pedro Alves <palves@redhat.com>
235
236 * linespec.c (struct bound_minimal_symbol_search_key): New.
237 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
238 skip first line if we found a GNU ifunc minimal symbol by name.
239 (compare_msymbols): Change parameters to work with a destructured
240 lhs minsym.
241 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
242 functions.
243
244 2018-04-26 Pedro Alves <palves@redhat.com>
245
246 * breakpoint.c (set_breakpoint_location_function): Don't resolve
247 ifunc targets here. Instead, if we have an ifunc minsym, use its
248 address/name.
249 (add_location_to_breakpoint): Store the minsym and the objfile in
250 the breakpoint location.
251 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
252 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
253 Record the minsym in the sal.
254 * symtab.h (symtab_and_line) <msymbol>: New field.
255
256 2018-04-26 Pedro Alves <palves@redhat.com>
257
258 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
259 unless we actually resolved the ifunc.
260
261 2018-04-26 Pedro Alves <palves@redhat.com>
262
263 * c-exp.y (variable production): Prefer ifunc minsyms over
264 regular function symbols.
265 * symtab.c (find_gnu_ifunc): New function.
266 * minsyms.h (lookup_msym_prefer): New enum.
267 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
268 parameter by a lookup_msym_prefer parameter.
269 * symtab.h (find_gnu_ifunc): New declaration.
270
271 2018-04-26 Pedro Alves <palves@redhat.com>
272
273 * blockframe.c (find_gnu_ifunc_target_type): New function.
274 (find_function_type): New.
275 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
276 return a value with a memory address.
277 (eval_call): For calls to GNU ifunc functions, try to find the
278 type of the target function from the type that the resolver
279 returns.
280 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
281 symbols.
282 * infcall.c (find_function_return_type): Delete.
283 (find_function_addr): Add 'function_type' parameter. For calls to
284 GNU ifunc functions, try to find the type of the target function
285 from the type that the resolver returns, and return it via
286 FUNCTION_TYPE.
287 (call_function_by_hand_dummy): Adjust to use the function type
288 returned by find_function_addr.
289 (find_function_addr): Add 'function_type' parameter and move
290 description here.
291 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
292 declarations.
293
294 2018-04-26 Pedro Alves <palves@redhat.com>
295
296 * c-exp.y (variable production): Skip finding an alias for ifunc
297 symbols.
298
299 2018-04-26 Pedro Alves <palves@redhat.com>
300
301 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
302
303 2018-04-25 Pedro Alves <palves@redhat.com>
304
305 * infcmd.c (kill_command): Print the pid as string, not the whole
306 thread's ptid. Add comment. s/has been killed/killed/ in output
307 message.
308 * remote.c (remote_detach_1): Print the pid as string, not the
309 whole thread's ptid.
310
311 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
312 Sergio Durigan Junior <sergiodj@redhat.com>
313 Pedro Alves <palves@redhat.com>
314
315 * infcmd.c (kill_command): Print message when inferior has
316 been killed.
317 * inferior.c (print_inferior_events): Remove 'static'. Set as
318 '1'.
319 (add_inferior): Improve message printed when
320 'print_inferior_events' is on.
321 (exit_inferior): Remove message printed when
322 'print_inferior_events' is on.
323 (detach_inferior): Improve message printed when
324 'print_inferior_events' is on.
325 (initialize_inferiors): Use 'add_inferior_silent' to set
326 'current_inferior_'.
327 * inferior.h (print_inferior_events): Declare here as
328 'extern'.
329 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
330 '[Detaching...]' messages when 'print_inferior_events' is on.
331 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
332 as prefix/suffix for messages. Remove periods. Fix erroneous
333 'Detaching after fork from child...', replace it by '... from
334 parent...'.
335 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
336 prefix/suffix when printing 'Detaching...' messages. Print
337 them when 'print_inferior_events' is on.
338 * remote.c (remote_detach_1): Print message when detaching
339 from inferior and '!is_fork_parent'.
340
341 2018-04-24 Tom Tromey <tom@tromey.com>
342
343 * cli-out.h: Reindent.
344
345 2018-04-24 Tom Tromey <tom@tromey.com>
346
347 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
348 (cli_ui_out::do_field_string): Use fputs_filtered.
349 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
350
351 2018-04-23 Tom Tromey <tom@tromey.com>
352
353 * guile/scm-frame.c (gdbscm_frame_read_var): Use
354 gdb::unique_xmalloc_ptr.
355
356 2018-04-23 Tom Tromey <tom@tromey.com>
357
358 * configure: Rebuild.
359
360 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
361
362 PR gdb/23095
363 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
364 prepare_for_testing. Set normal_bp to r_debug_state if target
365 is bsd.
366
367 2018-04-21 Pedro Alves <palves@redhat.com>
368 Rajendra SY <rajendra.sy@gmail.com>
369
370 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
371 * remote.c (extended_remote_attach): In all-stop mode, mark the
372 thread as executing.
373
374 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
375
376 * thread.c (thread_apply_all_command): Fix comment.
377 (thread_command): Fix comment.
378
379 2018-04-10 Alan Hayward <alan.hayward@arm.com>
380
381 * common/tdesc.h (tdesc_create_feature): Remove xml filename
382 parameter.
383 * features/aarch64-core.c (create_feature_aarch64_core):
384 Regenerate.
385 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
386 Likewise.
387 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
388 Likewise.
389 * features/i386/32bit-avx512.c
390 (create_feature_i386_32bit_avx512): Likewise.
391 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
392 Likewise.
393 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
394 Likewise.
395 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
396 Likewise.
397 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
398 Likewise.
399 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
400 Likewise.
401 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
402 Likewise.
403 * features/i386/64bit-avx512.c
404 (create_feature_i386_64bit_avx512): Likewise.
405 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
406 Likewise.
407 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
408 Likewise.
409 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
410 Likewise.
411 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
412 Likewise.
413 * features/i386/64bit-segments.c
414 (create_feature_i386_64bit_segments): Likewise.
415 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
416 Likewise.
417 * features/i386/x32-core.c
418 (create_feature_i386_x32_core): Likewise.
419 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
420 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
421 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
422 * target-descriptions.c: In generated code, don't pass xml
423 filename.
424
425 2018-04-18 Alan Hayward <alan.hayward@arm.com>
426
427 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
428 (print_xml_feature::visit_post): Likewise.
429 (print_xml_feature::visit): Likewise.
430 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
431 (print_xml_feature): Add new class.
432 * regformats/regdat.sh: Null xmltarget on feature targets.
433 * target-descriptions.c (struct target_desc): Add xmltarget.
434 (maintenance_check_tdesc_xml_convert): Add unittest function.
435 (tdesc_get_features_xml): Add function to get xml.
436 (maintenance_check_xml_descriptions): Test xml generation.
437 * xml-tdesc.c (string_read_description_xml): Add function.
438 * xml-tdesc.h (string_read_description_xml): Add declaration.
439
440 2018-04-18 Alan Hayward <alan.hayward@arm.com>
441
442 * features/Makefile: Add feature marker to targets with new style
443 target descriptions.
444 * regformats/aarch64.dat: Regenerate.
445 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
446 * regformats/i386/amd64-avx-linux.dat: Likewise.
447 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
448 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
449 * regformats/i386/amd64-linux.dat: Likewise.
450 * regformats/i386/amd64-mpx-linux.dat: Likewise.
451 * regformats/i386/amd64.dat: Likewise.
452 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
453 * regformats/i386/i386-avx-linux.dat: Likewise.
454 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
455 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
456 * regformats/i386/i386-linux.dat: Likewise.
457 * regformats/i386/i386-mmx-linux.dat: Likewise.
458 * regformats/i386/i386-mpx-linux.dat: Likewise.
459 * regformats/i386/i386.dat: Likewise.
460 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
461 * regformats/i386/x32-avx-linux.dat: Likewise.
462 * regformats/i386/x32-linux.dat: Likewise.
463 * regformats/tic6x-c62x-linux.dat: Likewise.
464 * regformats/tic6x-c64x-linux.dat: Likewise.
465 * regformats/tic6x-c64xp-linux.dat: Likewise.
466 * regformats/regdat.sh: Parse feature marker.
467
468 2018-04-18 Alan Hayward <alan.hayward@arm.com>
469
470 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
471 (tdesc_osabi_name): Likewise.
472 * target-descriptions.c (tdesc_architecture_name): Add new
473 function.
474 (tdesc_osabi_name): Likewise.
475
476 2018-04-18 Alan Hayward <alan.hayward@arm.com>
477
478 * common/tdesc.c (tdesc_predefined_type): Move to here.
479 (tdesc_named_type): Likewise.
480 (tdesc_create_vector): Likewise.
481 (tdesc_create_struct): Likewise.
482 (tdesc_set_struct_size): Likewise.
483 (tdesc_create_union): Likewise.
484 (tdesc_create_flags): Likewise.
485 (tdesc_create_enum): Likewise.
486 (tdesc_add_field): Likewise.
487 (tdesc_add_typed_bitfield): Likewise.
488 (tdesc_add_bitfield): Likewise.
489 (tdesc_add_flag): Likewise.
490 (tdesc_add_enum_value): Likewise.
491 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
492 (struct tdesc_type_vector): Likewise.
493 (struct tdesc_type_field): Likewise.
494 (struct tdesc_type_with_fields): Likewise.
495 (tdesc_create_enum): Add declaration.
496 (tdesc_add_typed_bitfield): Likewise.
497 (tdesc_add_enum_value): Likewise.
498 * target-descriptions.c (tdesc_type_field): Move from here.
499 (tdesc_type_builtin): Likewise.
500 (tdesc_type_vector): Likewise.
501 (tdesc_type_with_fields): Likewise.
502 (tdesc_predefined_types): Likewise.
503 (tdesc_named_type): Likewise.
504 (tdesc_create_vector): Likewise.
505 (tdesc_create_struct): Likewise.
506 (tdesc_set_struct_size): Likewise.
507 (tdesc_create_union): Likewise.
508 (tdesc_create_flags): Likewise.
509 (tdesc_create_enum): Likewise.
510 (tdesc_add_field): Likewise.
511 (tdesc_add_typed_bitfield): Likewise.
512 (tdesc_add_bitfield): Likewise.
513 (tdesc_add_flag): Likewise.
514 (tdesc_add_enum_value): Likewise.
515 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
516 (tdesc_add_typed_bitfield): Likewise.
517 (tdesc_add_enum_value): Likewise.
518
519 2018-04-18 Alan Hayward <alan.hayward@arm.com>
520
521 * common/tdesc.c (tdesc_feature::accept): Move to here.
522 (tdesc_feature::operator==): Likewise.
523 (tdesc_create_reg): Likewise.
524 * common/tdesc.h (tdesc_type_kind): Likewise.
525 (struct tdesc_type): Likewise.
526 (struct tdesc_feature): Likewise.
527 * regformats/regdat.sh: Create a feature.
528 * target-descriptions.c (tdesc_type_kind): Move from here.
529 (tdesc_type): Likewise.
530 (tdesc_type_up): Likewise.
531 (tdesc_feature): Likewise.
532 (tdesc_create_reg): Likewise.
533
534 2018-04-18 Alan Hayward <alan.hayward@arm.com>
535
536 * Makefile.in: Add arch/tdesc.c
537 * common/tdesc.c: New file.
538 * common/tdesc.h (tdesc_element_visitor): Move to here.
539 (tdesc_element): Likewise.
540 (tdesc_reg): Likewise.
541 (tdesc_reg_up): Likewise.
542 * regformats/regdef.h (reg): Add offset to constructors.
543 * target-descriptions.c (tdesc_element_visitor): Move from here.
544 (tdesc_element): Likewise.
545 (tdesc_reg): Likewise.
546 (tdesc_reg_up): Likewise.
547
548 2018-04-17 Tom Tromey <tom@tromey.com>
549
550 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
551 discriminant field.
552
553 2018-04-17 Tom Tromey <tom@tromey.com>
554
555 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
556
557 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
558
559 * symtab.c (print_symbol_info): Skip printing filename and line
560 number when `last' is NULL.
561 (symtab_symbol_info): Use empty string instead of NULL for first
562 invocation of print_symbol_info.
563 (rbreak_command): Pass NULL to `last' parameter of
564 print_symbol_info.
565
566 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
567
568 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
569 instead of nullptr.
570
571 2018-04-16 Pedro Alves <palves@redhat.com>
572
573 * MAINTAINERS (sh): Remove.
574 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
575 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
576 (ALLDEPFILES): Remove sh64-tdep.c.
577 * NEWS: Mentions that support for SH-5/SH64 is removed.
578 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
579 (sh*-*-openbsd*): Ditto.
580 (sh64-*-elf*): Remove.
581 (sh*): Remove.
582 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
583 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
584 * sh-tdep.c: No longer include "sh64-tdep.h".
585 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
586 * sh64-tdep.c, sh64-tdep.h: Remove files.
587
588 2018-04-16 Pedro Alves <palves@redhat.com>
589
590 * MAINTAINERS: Remove m88k.
591 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
592 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
593 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
594 * NEWS: Mention that support for m88k was removed.
595 * configure.host (m88*-*-*): Remove support.
596 * configure.nat (m88k-*-*): Remove support.
597 * configure.tgt (m88*-*-openbsd*): Remove.
598 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
599
600 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
601
602 * configure.tgt (x86_tobjs): New variable.
603 (amd64_tobjs, i386_tobjs): Use it.
604
605 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
606
607 * symtab.c (print_symbol_info): Precede the symbol definition by
608 the line number when available.
609 * NEWS: Advertise this enhancement.
610
611 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
612
613 * NEWS (New options): announce set/show record btrace cpu.
614 * btrace.c: Include record-btrace.h.
615 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
616 the vendor is unknown.
617 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
618 Maybe overwrite the btrace configuration's cpu.
619 (btrace_compute_ftrace): Add cpu parameter. Update callers.
620 (btrace_fetch): Add cpu parameter. Update callers.
621 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
622 Maybe overwrite the btrace configuration's cpu. Skip enabling
623 errata workarounds if the vendor is unknown.
624 * python/py-record-btrace.c: Include record-btrace.h.
625 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
626 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
627 * record-btrace.c (record_btrace_cpu_state_kind): New.
628 (record_btrace_cpu): New.
629 (set_record_btrace_cpu_cmdlist): New.
630 (record_btrace_get_cpu): New.
631 (require_btrace_thread, record_btrace_info)
632 (record_btrace_resume_thread): Call record_btrace_get_cpu.
633 (cmd_set_record_btrace_cpu_none): New.
634 (cmd_set_record_btrace_cpu_auto): New.
635 (cmd_set_record_btrace_cpu): New.
636 (cmd_show_record_btrace_cpu): New.
637 (_initialize_record_btrace): Initialize set/show record btrace cpu
638 commands.
639 * record-btrace.h (record_btrace_get_cpu): New.
640
641 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
642
643 * record.c (set_record_command): Fix typo in message.
644
645 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
646
647 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
648
649 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
650
651 * infrun.c (process_event_stop_test): Call
652 gdbarch_in_indirect_branch_thunk.
653 * gdbarch.sh (in_indirect_branch_thunk): New.
654 * gdbarch.c: Regenerated.
655 * gdbarch.h: Regenerated.
656 * x86-tdep.h: New.
657 * x86-tdep.c: New.
658 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
659 (HFILES_NO_SRCDIR): Add x86-tdep.h.
660 (ALLDEPFILES): Add x86-tdep.c.
661 * arch-utils.h (default_in_indirect_branch_thunk): New.
662 * arch-utils.c (default_in_indirect_branch_thunk): New.
663 * i386-tdep: Include x86-tdep.h.
664 (i386_in_indirect_branch_thunk): New.
665 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
666 function.
667 * amd64-tdep: Include x86-tdep.h.
668 (amd64_in_indirect_branch_thunk): New.
669 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
670
671 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
672
673 PR gdb/23053
674 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
675 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
676 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
677 regression.
678
679 2018-04-12 Tom Tromey <tom@tromey.com>
680
681 * rust-lang.c (rust_print_struct_def): Remove univariant code.
682 (rust_evaluate_subexp): Likewise.
683
684 2018-04-12 Pedro Alves <palves@redhat.com>
685
686 * procfs.c (procfs_detach): Make forward declaration's prototype
687 match definition's protototype.
688 (proc_get_LDT_entry): Remove stale do_cleanups call.
689
690 2018-04-12 Pedro Alves <palves@redhat.com>
691
692 * target.h (target_ops::to_has_exited): Delete.
693 (target_has_exited): Delete.
694 * target-delegates.c: Regenerate.
695
696 2018-04-11 Pedro Alves <palves@redhat.com>
697
698 * target.c (fileio_fh_t::t): Add comment.
699 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
700 (target_fileio_close): Handle a NULL target.
701 (invalidate_fileio_fh): New.
702 (target_close): Call it.
703 * remote.c (remote_hostio_send_command): No longer check whether
704 remote_desc is open.
705
706 2018-04-11 Pedro Alves <palves@redhat.com>
707
708 * target.c (fileio_fh_t): Make it a named struct instead of a
709 typedef.
710 (fileio_fh_t::is_closed): New method.
711 (DEF_VEC_O (fileio_fh_t)): Remove.
712 (fileio_fhandles): Now a std::vector.
713 (is_closed_fileio_fh): Delete.
714 (acquire_fileio_fd): Adjust. Rename parameters.
715 (release_fileio_fd): Adjust.
716 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
717 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
718 (target_fileio_close): Adjust.
719
720 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
721
722 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
723 index.
724
725 2018-04-10 Pedro Alves <palves@redhat.com>
726
727 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
728 (scoped_finish_thread_state): New class.
729 * infcmd.c (run_command_1): Use it instead of finish_thread_state
730 cleanup.
731 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
732 (fetch_inferior_event, normal_stop): Likewise.
733 * thread.c (finish_thread_state_cleanup): Delete.
734
735 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
736 Pedro Alves <palves@redhat.com>
737
738 * value.c: Include "selftest.h" and "common/array-view.h".
739 (struct range) <operator ==>: New.
740 (test_ranges_contain): New.
741 (check_ranges_vector): New.
742 (test_insert_into_bit_range_vector): New.
743 (_initialize_values): Register selftests.
744 * common/array-view.h (operator==, operator!=): New.
745
746 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
747
748 * common/gdb_vecs.h (unordered_remove): Add overload that takes
749 an iterator.
750 * inline-frame.c: Include <algorithm>.
751 (struct inline_state): Add constructor.
752 (inline_state_s): Remove.
753 (DEF_VEC_O(inline_state_s)): Remove.
754 (inline_states): Change type to std::vector.
755 (find_inline_frame_state): Adjust to std::vector.
756 (allocate_inline_frame_state): Remove.
757 (clear_inline_frame_state): Adjust to std::vector.
758 (skip_inline_frames): Adjust to std::vector.
759
760 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
761
762 * tracepoint.h (struct trace_state_variable): Add constructor.
763 <name>: Change type to std::string.
764 * tracepoint.c (tsv_s): Remove.
765 (DEF_VEC_O(tsv_s)): Remove.
766 (tvariables): Change to std::vector.
767 (create_trace_state_variable): Adjust to std::vector.
768 (find_trace_state_variable): Likewise.
769 (find_trace_state_variable_by_number): Likewise.
770 (delete_trace_state_variable): Likewise.
771 (trace_variable_command): Adjust to std::string.
772 (delete_trace_variable_command): Likewise.
773 (tvariables_info_1): Adjust to std::vector.
774 (save_trace_state_variables): Likewise.
775 (start_tracing): Likewise.
776 (merge_uploaded_trace_state_variables): Adjust to std::vector
777 and std::string.
778 * target.h (struct target_ops)
779 <to_download_trace_state_variable>: Pass reference to
780 trace_state_variable.
781 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
782 * target-delegates.c: Re-generate.
783 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
784 (mi_tsv_deleted): Likewise.
785 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
786 * remote.c (remote_download_trace_state_variable): Change
787 pointer to reference and adjust.
788 * make-target-delegates (parse_argtypes): Handle references.
789 (write_function_header): Likewise.
790 (munge_type): Likewise.
791
792 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
793
794 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
795 string_view-selftests.c.
796 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
797 testsuite.
798 * unittests/basic_string_view/cons/char/1.cc: Likewise.
799 * unittests/basic_string_view/cons/char/2.cc: Likewise.
800 * unittests/basic_string_view/cons/char/3.cc: Likewise.
801 * unittests/basic_string_view/element_access/char/1.cc:
802 Likewise.
803 * unittests/basic_string_view/element_access/char/empty.cc:
804 Likewise.
805 * unittests/basic_string_view/element_access/char/front_back.cc:
806 Likewise.
807 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
808 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
809 Likewise.
810 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
811 Likewise.
812 * unittests/basic_string_view/modifiers/swap/char/1.cc:
813 Likewise.
814 * unittests/basic_string_view/operations/compare/char/1.cc:
815 Likewise.
816 * unittests/basic_string_view/operations/compare/char/13650.cc:
817 Likewise.
818 * unittests/basic_string_view/operations/copy/char/1.cc:
819 Likewise.
820 * unittests/basic_string_view/operations/data/char/1.cc:
821 Likewise.
822 * unittests/basic_string_view/operations/find/char/1.cc:
823 Likewise.
824 * unittests/basic_string_view/operations/find/char/2.cc:
825 Likewise.
826 * unittests/basic_string_view/operations/find/char/3.cc:
827 Likewise.
828 * unittests/basic_string_view/operations/find/char/4.cc:
829 Likewise.
830 * unittests/basic_string_view/operations/rfind/char/1.cc:
831 Likewise.
832 * unittests/basic_string_view/operations/rfind/char/2.cc:
833 Likewise.
834 * unittests/basic_string_view/operations/rfind/char/3.cc:
835 Likewise.
836 * unittests/basic_string_view/operations/substr/char/1.cc:
837 Likewise.
838 * unittests/basic_string_view/operators/char/2.cc: Likewise.
839 * unittests/string_view-selftests.c: New file.
840
841 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
842
843 * unittests/basic_string_view/capacity/1.cc: New file.
844 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
845 * unittests/basic_string_view/cons/char/1.cc: New file.
846 * unittests/basic_string_view/cons/char/2.cc: New file.
847 * unittests/basic_string_view/cons/char/3.cc: New file.
848 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
849 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
850 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
851 * unittests/basic_string_view/element_access/char/1.cc: New file.
852 * unittests/basic_string_view/element_access/char/2.cc: New file.
853 * unittests/basic_string_view/element_access/char/empty.cc: New file.
854 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
855 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
856 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
857 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
858 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
859 * unittests/basic_string_view/include.cc: New file.
860 * unittests/basic_string_view/inserters/char/1.cc: New file.
861 * unittests/basic_string_view/inserters/char/2.cc: New file.
862 * unittests/basic_string_view/inserters/char/3.cc: New file.
863 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
864 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
865 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
866 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
867 * unittests/basic_string_view/literals/types.cc: New file.
868 * unittests/basic_string_view/literals/values.cc: New file.
869 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
870 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
871 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
872 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
873 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
874 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
875 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
876 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
877 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
878 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
879 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
880 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
881 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
882 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
883 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
884 * unittests/basic_string_view/operations/data/char/1.cc: New file.
885 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
886 * unittests/basic_string_view/operations/find/char/1.cc: New file.
887 * unittests/basic_string_view/operations/find/char/2.cc: New file.
888 * unittests/basic_string_view/operations/find/char/3.cc: New file.
889 * unittests/basic_string_view/operations/find/char/4.cc: New file.
890 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
891 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
892 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
893 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
894 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
895 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
896 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
897 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
898 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
899 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
900 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
901 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
902 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
903 * unittests/basic_string_view/operators/char/2.cc: New file.
904 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
905 * unittests/basic_string_view/range_access/char/1.cc: New file.
906 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
907 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
908 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
909 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
910 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
911 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
912 * unittests/basic_string_view/requirements/typedefs.cc: New file.
913 * unittests/basic_string_view/typedefs.cc: New file.
914 * unittests/basic_string_view/types/1.cc: New file.
915
916 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
917
918 * common/gdb_string_view.h: Remove libstdc++ implementation
919 details, adjust to gdb reality.
920 * common/gdb_string_view.tcc: Likewise.
921 * cli/cli-script.c (struct string_view): Remove.
922 (user_args) <m_args>: Change element type to gdb::string_view.
923 (user_args::insert_args): Adjust.
924
925 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
926
927 * common/gdb_string_view.h: New file.
928 * common/gdb_string_view.tcc: New file.
929
930 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
931
932 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
933 * configure: Re-generate.
934
935 2018-04-09 Pedro Alves <palves@redhat.com>
936
937 * gdbarch.sh: Include "observable.h" instead of "observer.h".
938 (set_target_gdbarch): Call
939 gdb::observers::architecture_changed.notify instead of
940 observer_notify_architecture_changed.
941
942 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
943
944 * tracepoint.c (struct current_traceframe_cleanup): Remove.
945 (do_restore_current_traceframe_cleanup): Remove.
946 (restore_current_traceframe_cleanup_dtor): Remove.
947 (make_cleanup_restore_current_traceframe): Remove.
948 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
949 New.
950 * tracepoint.h (struct scoped_restore_current_traceframe): New.
951 * infrun.c (fetch_inferior_event): Use
952 scoped_restore_current_traceframe.
953
954 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
955
956 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
957 Remove.
958 <n_allocated_type_units>: Remove.
959 <all_type_units>: Change to std::vector.
960 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
961 to std::vector change.
962 (dwarf2_per_objfile::get_cutu): Likewise.
963 (dwarf2_per_objfile::get_tu): Likewise.
964 (create_signatured_type_table_from_index): Likewise.
965 (create_signatured_type_table_from_debug_names): Likewise.
966 (dw2_symtab_iter_next): Likewise.
967 (dw2_print_stats): Likewise.
968 (dw2_expand_all_symtabs): Likewise.
969 (dw2_expand_marked_cus): Likewise.
970 (dw2_debug_names_iterator::next): Likewise.
971 (dwarf2_initialize_objfile): Likewise.
972 (add_signatured_type_cu_to_table): Likewise.
973 (create_all_type_units): Likewise.
974 (add_type_unit): Likewise.
975 (struct tu_abbrev_offset): Add constructor.
976 (build_type_psymtabs_1): Adjust to std::vector change.
977 (print_tu_stats): Likewise.
978 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
979 (write_debug_names): Likewise.
980
981 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
982
983 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
984 Make an std::vector.
985 <n_comp_units>: Remove.
986 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
987 to std::vector change.
988 (dwarf2_per_objfile::get_cutu): Likewise.
989 (dwarf2_per_objfile::get_cu): Likewise.
990 (create_cus_from_index): Likewise.
991 (create_addrmap_from_index): Likewise.
992 (create_addrmap_from_aranges): Likewise.
993 (dwarf2_read_index): Likewise.
994 (dw2_find_last_source_symtab): Likewise.
995 (dw2_map_symtabs_matching_filename): Likewise.
996 (dw2_symtab_iter_next): Likewise.
997 (dw2_print_stats): Likewise.
998 (dw2_expand_all_symtabs): Likewise.
999 (dw2_expand_symtabs_with_fullname): Likewise.
1000 (dw2_expand_marked_cus): Likewise.
1001 (dw2_map_symbol_filenames): Likewise.
1002 (create_cus_from_debug_names): Likewise.
1003 (dwarf2_read_debug_names): Likewise.
1004 (dw2_debug_names_iterator::next): Likewise.
1005 (dwarf2_initialize_objfile): Likewise.
1006 (set_partial_user): Likewise.
1007 (dwarf2_build_psymtabs_hard): Likewise.
1008 (read_comp_units_from_section): Remove arguments, adjust to
1009 std::vector change.
1010 (create_all_comp_units): Adjust to std::vector and
1011 read_comp_units_from_section changes.
1012 (dwarf2_find_containing_comp_unit): Adjust to std::vector
1013 change.
1014 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
1015 (psyms_seen_size): Likewise.
1016 (write_gdbindex): Likewise.
1017 (write_debug_names): Likewise.
1018
1019 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
1020
1021 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
1022 with dwarf2_per_objfile.
1023 (create_cus_from_index): Likewise.
1024 (create_signatured_type_table_from_index): Likewise.
1025 (dwarf2_read_index): Likewise.
1026 (dwarf2_initialize_objfile): Likewise.
1027 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
1028 per_cu rather than get_dwarf2_per_objfile.
1029
1030 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
1031
1032 * dwarf2read.h (struct signatured_type): Forward declare.
1033 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
1034 New methods.
1035 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
1036 (dw2_get_cutu): ...this.
1037 (dwarf2_per_objfile::get_cu): Rename from...
1038 (dw2_get_cu): ...this.
1039 (dwarf2_per_objfile::get_tu): New.
1040 (create_addrmap_from_index): Adjust.
1041 (create_addrmap_from_aranges): Adjust.
1042 (dw2_find_last_source_symtab): Adjust.
1043 (dw2_map_symtabs_matching_filename): Adjust.
1044 (dw2_symtab_iter_next): Adjust.
1045 (dw2_print_stats): Adjust.
1046 (dw2_expand_all_symtabs): Adjust.
1047 (dw2_expand_symtabs_with_fullname): Adjust.
1048 (dw2_expand_marked_cus): Adjust.
1049 (dw_expand_symtabs_matching_file_matcher): Adjust.
1050 (dw2_map_symbol_filenames): Adjust.
1051 (dw2_debug_names_iterator::next): Adjust.
1052 (dwarf2_initialize_objfile): Adjust.
1053 (set_partial_user): Adjust.
1054 (dwarf2_build_psymtabs_hard): Adjust.
1055
1056 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
1057
1058 * dwarf2read.c (create_signatured_type_table_from_debug_names):
1059 Remove unused variables.
1060 (dw2_map_symtabs_matching_filename): Likewise.
1061 (dwarf2_record_block_ranges): Likewise.
1062 (dwarf2_read_addr_index): Likewise.
1063 (follow_die_offset): Likewise.
1064
1065 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
1066
1067 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
1068 to symbol_file_add_main.
1069
1070 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
1071
1072 PR mi/22299
1073 * mi/mi-console.c (do_fputc_async_safe): New.
1074 (mi_console_file::write_async_safe): New.
1075 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
1076 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
1077 New.
1078 * ui-file.c (ui_file::putstrn): Adjust call to
1079 fputstrn_unfiltered.
1080 * utils.c (printchar): Replace do_fputs and do_fprintf
1081 parameters by do_fputc.
1082 (fputstr_filtered): Adjust call to printchar.
1083 (fputstr_unfiltered): Likewise.
1084 (fputstrn_filtered): Likewise.
1085 (fputstrn_unfiltered): Add do_fputc parameter, pass to
1086 printchar.
1087 * utils.h (do_fputc_ftype): New typedef.
1088 (fputstrn_unfiltered): Add do_fputc parameter.
1089
1090 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
1091
1092 * regformats/i386/i386-avx.dat: Remove.
1093
1094 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
1095
1096 PR gdb/22979
1097 * amd64-tdep.c (amd64_none_init_abi): New function.
1098 (amd64_x32_none_init_abi): New function.
1099 (_initialize_amd64_tdep): Register handlers for x86-64 and
1100 x64_32 with GDB_OSABI_NONE.
1101 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
1102 GDB_OSABI_NONE osabi.
1103
1104 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
1105
1106 PR gdb/22980
1107 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
1108 GDB_OSABI_NONE.
1109 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
1110 * osabi.c (gdb_osabi_names): Add "unknown" entry.
1111
1112 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
1113
1114 * common/byte-vector.h (char_vector): New type.
1115 * target.h (target_read_alloc): Return
1116 gdb::optional<byte_vector>.
1117 (target_read_stralloc): Return gdb::optional<char_vector>.
1118 (target_get_osdata): Return gdb::optional<char_vector>.
1119 * target.c (target_read_alloc_1): Templatize. Replacement
1120 manual memory management with vector.
1121 (target_read_alloc): Change return type, adjust.
1122 (target_read_stralloc): Change return type, adjust.
1123 (target_get_osdata): Change return type, adjust.
1124 * auxv.c (struct auxv_info) <length>: Remove.
1125 <data>: Change type to gdb::optional<byte_vector>.
1126 (auxv_inferior_data_cleanup): Free auxv_info with delete.
1127 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
1128 (target_auxv_search): Adjust.
1129 (fprint_target_auxv): Adjust.
1130 * avr-tdep.c (avr_io_reg_read_command): Adjust.
1131 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
1132 (linux_make_corefile_notes): Adjust.
1133 * osdata.c (get_osdata): Adjust.
1134 * remote.c (remote_get_threads_with_qxfer): Adjust.
1135 (remote_memory_map): Adjust.
1136 (remote_traceframe_info): Adjust.
1137 (btrace_read_config): Adjust.
1138 (remote_read_btrace): Adjust.
1139 (remote_pid_to_exec_file): Adjust.
1140 * solib-aix.c (solib_aix_get_library_list): Adjust.
1141 * solib-dsbt.c (decode_loadmap): Don't free buf.
1142 (dsbt_get_initial_loadmaps): Adjust.
1143 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
1144 * solib-target.c (solib_target_current_sos): Adjust.
1145 * tracepoint.c (sdata_make_value): Adjust.
1146 * xml-support.c (xinclude_start_include): Adjust.
1147 (xml_fetch_content_from_file): Adjust.
1148 * xml-support.h (xml_fetch_another): Change return type.
1149 (xml_fetch_content_from_file): Change return type.
1150 * xml-syscall.c (xml_init_syscalls_info): Adjust.
1151 * xml-tdesc.c (file_read_description_xml): Adjust.
1152 (fetch_available_features_from_target): Change return type.
1153 (target_fetch_description_xml): Adjust.
1154 (target_read_description_xml): Adjust.
1155
1156 2018-04-06 Tom Tromey <tom@tromey.com>
1157
1158 * value.c (~value): Update.
1159 (struct value) <contents>: Now unique_xmalloc_ptr.
1160 (value_contents_bits_eq, allocate_value_contents)
1161 (value_contents_raw, value_contents_all_raw)
1162 (value_contents_for_printing, value_contents_for_printing_const)
1163 (set_value_enclosing_type): Update.
1164
1165 2018-04-06 Tom Tromey <tom@tromey.com>
1166
1167 * value.c (range_s): Remove typedef, VEC.
1168 (struct range): Add operator<.
1169 (range_lessthan): Remove.
1170 (ranges_contain): Change type.
1171 (~value): Update.
1172 (struct value) <unavailable, optimized_out>: Now std::vector.
1173 (value_entirely_available)
1174 (value_entirely_covered_by_range_vector)
1175 (value_entirely_unavailable, value_entirely_optimized_out):
1176 Update.
1177 (insert_into_bit_range_vector): Change argument type.
1178 (find_first_range_overlap): Likewise.
1179 (struct ranges_and_idx, value_contents_bits_eq)
1180 (require_not_optimized_out, require_available): Update.
1181 (ranges_copy_adjusted): Change argument types.
1182 (value_optimized_out, value_copy, value_fetch_lazy): Update.
1183
1184 2018-04-06 Tom Tromey <tom@tromey.com>
1185
1186 * value.c (~value): Update.
1187 (struct value) <parent>: Now a value_ref_ptr.
1188 (value_parent, set_value_parent, value_address, value_copy):
1189 Update.
1190
1191 2018-04-06 Tom Tromey <tom@tromey.com>
1192
1193 * value.c (struct value): Add constructor, destructor, and member
1194 initializers.
1195 (allocate_value_lazy, value_decref): Update.
1196
1197 2018-04-06 Tom Tromey <tom@tromey.com>
1198
1199 * value.c (struct value) <released, next>: Remove.
1200 (all_values): Now a std::vector.
1201 (allocate_value_lazy): Update.
1202 (value_next): Remove.
1203 (value_mark, value_free_to_mark, release_value)
1204 (value_release_to_mark): Update.
1205
1206 2018-04-06 Tom Tromey <tom@tromey.com>
1207
1208 * value.h (fetch_subexp_value, value_release_to_mark): Update.
1209 (free_value_chain): Remove.
1210 * value.c (free_value_chain): Remove.
1211 (value_release_to_mark): Return a std::vector.
1212 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
1213 std::vector.
1214 (check_condition): Update.
1215 * eval.c (fetch_subexp_value): Change "val_chain" to a
1216 std::vector.
1217 * breakpoint.c (update_watchpoint): Update.
1218 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
1219
1220 2018-04-06 Tom Tromey <tom@tromey.com>
1221
1222 * value.h (free_all_values): Remove.
1223 * value.c (free_all_values): Remove.
1224
1225 2018-04-06 Tom Tromey <tom@tromey.com>
1226
1227 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
1228 (value_history_chain, value_history_count): Remove.
1229 (value_history): New global.
1230 (record_latest_value, access_value_history, show_values)
1231 (preserve_values): Update.
1232
1233 2018-04-06 Tom Tromey <tom@tromey.com>
1234
1235 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
1236 * varobj.c (varobj_set_display_format, varobj_set_value)
1237 (install_default_visualizer, construct_visualizer)
1238 (install_new_value, ~varobj, varobj_get_value_type)
1239 (my_value_of_variable, varobj_editable_p): Update.
1240 * c-varobj.c (c_describe_child, c_value_of_variable)
1241 (cplus_number_of_children, cplus_describe_child): Update.
1242 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
1243 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
1244 (ada_value_of_variable, ada_value_is_changeable_p): Update.
1245
1246 2018-04-06 Tom Tromey <tom@tromey.com>
1247
1248 * printcmd.c (last_examine_address): Change type to
1249 value_ref_ptr.
1250 (do_examine, x_command): Update.
1251
1252 2018-04-06 Tom Tromey <tom@tromey.com>
1253
1254 * value.c (release_value): Update.
1255 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
1256 (struct bpstats) <val>: Now a value_ref_ptr.
1257 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
1258 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
1259 (~watchpoint, print_it_watchpoint, watch_command_1)
1260 (invalidate_bp_value_on_memory_change): Update.
1261
1262 2018-04-06 Tom Tromey <tom@tromey.com>
1263
1264 * varobj.c (varobj_clear_saved_item)
1265 (update_dynamic_varobj_children, install_new_value, ~varobj):
1266 Update.
1267 * value.h (value_incref): Move declaration earlier.
1268 (value_decref): Rename from value_free.
1269 (struct value_ref_policy): New.
1270 (value_ref_ptr): New typedef.
1271 (struct value_deleter): Remove.
1272 (gdb_value_up): Remove typedef.
1273 (release_value): Change return type.
1274 (release_value_or_incref): Remove.
1275 * value.c (set_value_parent): Update.
1276 (value_incref): Change return type.
1277 (value_decref): Rename from value_free.
1278 (value_free_to_mark, free_all_values, free_value_chain): Update.
1279 (release_value): Return value_ref_ptr.
1280 (release_value_or_incref): Remove.
1281 (record_latest_value, set_internalvar, clear_internalvar):
1282 Update.
1283 * stack.c (info_frame_command): Don't call value_free.
1284 * python/py-value.c (valpy_dealloc, valpy_new)
1285 (value_to_value_object): Update.
1286 * printcmd.c (do_examine): Update.
1287 * opencl-lang.c (lval_func_free_closure): Update.
1288 * mi/mi-main.c (register_changed_p): Don't call value_free.
1289 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
1290 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
1291 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
1292 value_free.
1293 * guile/scm-value.c (vlscm_free_value_smob)
1294 (vlscm_scm_from_value): Update.
1295 * frame.c (frame_register_unwind, frame_unwind_register_signed)
1296 (frame_unwind_register_unsigned, get_frame_register_bytes)
1297 (put_frame_register_bytes): Don't call value_free.
1298 * findvar.c (address_from_register): Don't call value_free.
1299 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
1300 * dwarf2loc.c (entry_data_value_free_closure)
1301 (value_of_dwarf_reg_entry, free_pieced_value_closure)
1302 (dwarf2_evaluate_loc_desc_full): Update.
1303 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
1304 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
1305 (~watchpoint, watch_command_1)
1306 (invalidate_bp_value_on_memory_change): Update.
1307 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
1308
1309 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
1310
1311 PR gdb/23022
1312 * warning.m4: Add -Wno-error=deprecated-register.
1313 * configure: Re-generate.
1314
1315 2018-04-05 Tom Tromey <tom@tromey.com>
1316
1317 * linespec.h: Remove include of "vec.h".
1318
1319 2018-04-05 Tom Tromey <tom@tromey.com>
1320
1321 * linespec.c (typep): Remove typedef.
1322 (find_methods, find_superclass_methods): Take a std::vector.
1323 (find_method): Use std::vector.
1324
1325 2018-04-05 Tom Tromey <tom@tromey.com>
1326
1327 * utils.c (compare_strings): Remove.
1328 * utils.h (compare_strings): Remove.
1329 * objc-lang.h (find_imps): Update.
1330 * objc-lang.c (find_methods): Take a std::vector.
1331 (uniquify_strings, find_imps): Likewise.
1332 * linespec.c (find_methods): Take a std::vector.
1333 (decode_objc): Use std::vector.
1334 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
1335 a std::vector.
1336 (find_method, find_function_symbols): Use std::vector.
1337
1338 2018-04-05 Tom Tromey <tom@tromey.com>
1339
1340 * completer.c (completion_tracker::completion_tracker): Remove
1341 cast.
1342 (completion_tracker::discard_completions): Likewise.
1343 * breakpoint.c (ambiguous_names_p): Remove cast.
1344 * ada-lang.c (_initialize_ada_language): Remove cast.
1345 * utils.h (streq): Update.
1346 (streq_hash): Add new declaration.
1347 * utils.c (streq): Return bool.
1348 (streq_hash): New function.
1349
1350 2018-04-05 Tom Tromey <tom@tromey.com>
1351
1352 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
1353 Remove a string copy.
1354
1355 2018-04-05 Tom Tromey <tom@tromey.com>
1356
1357 * linespec.c (filter_results): Use std::vector.
1358 (decode_line_2, decode_line_full): Update.
1359
1360 2018-04-05 Tom Tromey <tom@tromey.com>
1361
1362 * linespec.c (canonical_to_fullform): Return std::string.
1363 (filter_results): Update.
1364 (struct decode_line_2_item): Add constructor.
1365 <fullform, displayform>: Now std::string.
1366 (decode_line_2_compare_items): Now a std::sort comparator.
1367 (decode_line_2): Update.
1368
1369 2018-04-05 Tom Tromey <tom@tromey.com>
1370
1371 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
1372 (unexpected_linespec_error): Update.
1373 (linespec_parse_basic, parse_linespec): Update.
1374
1375 2018-04-05 Tom Tromey <tom@tromey.com>
1376
1377 * linespec.c (linespec_parse_basic): Reindent.
1378
1379 2018-04-05 Tom Tromey <tom@tromey.com>
1380
1381 * minsyms.h (iterate_over_minimal_symbols): Update.
1382 * minsyms.c (iterate_over_minimal_symbols): Take a
1383 gdb::function_view.
1384 * linespec.c (struct collect_minsyms): Remove.
1385 (compare_msyms): Now a std::sort comparator.
1386 (add_minsym): Add parameters.
1387 (search_minsyms_for_name): Update. Use std::vector.
1388
1389 2018-04-03 Tom Tromey <tom@tromey.com>
1390
1391 * mipsread.c (read_alphacoff_dynamic_symtab): Use
1392 gdb::byte_vector.
1393
1394 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
1395
1396 * MAINTAINERS (Write After Approval): Add Weimin Pan.
1397
1398 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
1399
1400 PR gdb/16959
1401 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
1402 printing static type.
1403
1404 2018-04-01 Tom Tromey <tom@tromey.com>
1405
1406 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
1407 (rs6000_xfer_shared_libraries): Update.
1408
1409 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
1410
1411 * common/gdb_vecs.h (char_ptr): Remove.
1412 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
1413
1414 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
1415
1416 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
1417 with std::vector.
1418 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
1419
1420 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
1421
1422 * tracepoint.h (struct uploaded_tp): Initialize fields.
1423 <actions, step_actions, cmd_strings>: Change type to
1424 std::vector<char *>.
1425 * tracepoint.c (get_uploaded_tp): Allocate with new.
1426 (free_uploaded_tps): Free with delete.
1427 (parse_tracepoint_definition): Adjust to std::vector change.
1428 * breakpoint.c (read_uploaded_action): Likewise.
1429 (create_tracepoint_from_upload): Likewise.
1430 * ctf.c (ctf_write_uploaded_tp): Likewise.
1431 (SET_ARRAY_FIELD): Likewise.
1432 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
1433
1434 2018-03-30 Tom Tromey <tom@tromey.com>
1435
1436 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
1437 std::unique_ptr.
1438 (svr4_keep_data_in_core): Update.
1439 (svr4_read_so_list): Update.
1440
1441 2018-03-30 Tom Tromey <tom@tromey.com>
1442
1443 * windows-nat.c (handle_output_debug_string, handle_exception):
1444 Update.
1445 * target.h (target_read_string): Update.
1446 * target.c (target_read_string): Change "string" to
1447 unique_xmalloc_ptr.
1448 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
1449 Update.
1450 * solib-frv.c (frv_current_sos): Update.
1451 * solib-dsbt.c (dsbt_current_sos): Update.
1452 * solib-darwin.c (darwin_current_sos): Update.
1453 * linux-thread-db.c (inferior_has_bug): Update.
1454 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
1455 Update. Remove alloca.
1456 * ada-lang.c (ada_main_name): Update.
1457
1458 2018-03-30 Tom Tromey <tom@tromey.com>
1459
1460 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
1461 (struct dwo_file_deleter): New.
1462 (dwo_file_up): New typedef.
1463 (open_and_init_dwo_file): Use dwo_file_up.
1464 (free_dwo_file_cleanup): Remove.
1465
1466 2018-03-30 Tom Tromey <tom@tromey.com>
1467
1468 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
1469 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
1470
1471 2018-03-30 Tom Tromey <tom@tromey.com>
1472
1473 * dwarf2read.c (class free_cached_comp_units): New class.
1474 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
1475 (free_cached_comp_units): Remove function.
1476
1477 2018-03-30 Tom Tromey <tom@tromey.com>
1478
1479 * utils.h (make_cleanup_unpush_target): Remove.
1480 * inf-ptrace.c (struct target_unpusher): New.
1481 (target_unpush_up) New typedef.
1482 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
1483 target_unpush_up.
1484 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
1485
1486 2018-03-27 Tom Tromey <tom@tromey.com>
1487
1488 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
1489
1490 2018-03-27 Pedro Alves <palves@redhat.com>
1491 Tom Tromey <tom@tromey.com>
1492
1493 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
1494 destructor. Now a class.
1495 (gdb_readline_wrapper_cleanup): Remove function.
1496 (gdb_readline_wrapper): Remove cleanups.
1497
1498 2018-03-27 Tom Tromey <tom@tromey.com>
1499
1500 * typeprint.h (struct type_print_options) <local_typedefs,
1501 global_typedefs>: Remove "struct" keyword.
1502 (class typedef_hash_table): New class.
1503 (recursively_update_typedef_hash, add_template_parameters)
1504 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
1505 (find_typedef_in_hash): Don't declare.
1506 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
1507 (typedef_hash_table::recursively_update): Rename from
1508 recursively_update_typedef_hash. Now a member.
1509 (typedef_hash_table::add_template_parameters): Rename from
1510 add_template_parameters. Now a member.
1511 (typedef_hash_table::typedef_hash_table): Now a constructor;
1512 rename from create_typedef_hash.
1513 (typedef_hash_table::~typedef_hash_table): Now a destructor;
1514 rename from free_typedef_hash.
1515 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
1516 (do_free_global_table): Remove.
1517 (typedef_hash_table::typedef_hash_table): New constructor; renamed
1518 from copy_type_recursive.
1519 (create_global_typedef_table): Remove.
1520 (typedef_hash_table::find_global_typedef): Now a member of
1521 typedef_hash_table.
1522 (typedef_hash_table::find_typedef): Rename from
1523 find_typedef_in_hash; now a member.
1524 (whatis_exp): Update.
1525 * extension.h (struct ext_lang_type_printers): Add constructor and
1526 destructor.
1527 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
1528 declare.
1529 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
1530 Now a constructor; rename from start_ext_lang_type_printers.
1531 (ext_lang_type_printers): Now a destructor; rename from
1532 free_ext_lang_type_printers.
1533 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
1534 Update.
1535 (c_type_print_base_struct_union): Update. Remove cleanups.
1536
1537 2018-03-27 Tom Tromey <tom@tromey.com>
1538
1539 * dwarf-index-write.c: Include <cmath>.
1540
1541 2018-03-27 Joel Brobecker <brobecker@adacore.com>
1542
1543 * NEWS: Add entry describing new "set|show varsize-limit" command.
1544 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
1545 command.
1546 * printcmd.c (_initialize_printcmd): Add "set var" alias of
1547 "set variable".
1548
1549 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
1550
1551 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
1552 dwarf-index-write.c
1553 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
1554 * dwarf-index-common.c: New file.
1555 * dwarf-index-common.h: New file.
1556 * dwarf-index-write.c: New file.
1557 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
1558 (struct dwarf2_section_info): Move from here.
1559 (dwarf2_section_info_def): Likewise.
1560 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
1561 (offset_type): Likewise.
1562 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
1563 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
1564 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
1565 (byte_swap): Likewise.
1566 (MAYBE_SWAP): Likewise.
1567 (dwarf2_per_cu_ptr): Likewise.
1568 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
1569 (struct tu_stats): Likewise.
1570 (struct dwarf2_per_objfile): Likewise.
1571 (struct dwarf2_per_cu_data): Likewise.
1572 (struct signatured_type): Likewise.
1573 (sig_type_ptr): Likewise.
1574 (DEF_VEC_P (sig_type_ptr)): Likewise.
1575 (INDEX4_SUFFIX): Likewise.
1576 (INDEX5_SUFFIX): Likewise.
1577 (DEBUG_STR_SUFFIX): Likewise.
1578 (dwarf2_read_section): Make non-static.
1579 (mapped_index_string_hash): Move from here.
1580 (dwarf5_djb_hash): Likewise.
1581 (file_write): Likewise.
1582 (class data_buf): Likewise.
1583 (struct symtab_index_entry): Likewise.
1584 (struct mapped_symtab): Likewise.
1585 (find_slot): Likewise.
1586 (hash_expand): Likewise.
1587 (add_index_entry): Likewise.
1588 (uniquify_cu_indices): Likewise.
1589 (class c_str_view): Likewise.
1590 (class c_str_view_hasher): Likewise.
1591 (class vector_hasher): Likewise.
1592 (write_hash_table): Likewise.
1593 (psym_index_map): Likewise.
1594 (struct addrmap_index_data): Likewise.
1595 (add_address_entry): Likewise.
1596 (add_address_entry_worker): Likewise.
1597 (write_address_map): Likewise.
1598 (symbol_kind): Likewise.
1599 (write_psymbols): Likewise.
1600 (struct signatured_type_index_data): Likewise.
1601 (write_one_signatured_type): Likewise.
1602 (recursively_count_psymbols): Likewise.
1603 (recursively_write_psymbols): Likewise.
1604 (class debug_names): Likewise.
1605 (check_dwarf64_offsets): Likewise.
1606 (psyms_seen_size): Likewise.
1607 (write_gdbindex): Likewise.
1608 (write_debug_names): Likewise.
1609 (assert_file_size): Likewise.
1610 (write_psymtabs_to_index): Likewise.
1611 (save_gdb_index_command): Likewise.
1612 (_initialize_dwarf2_read): Don't register the "save gdb-index"
1613 command.
1614 * dwarf2read.h: New file.
1615
1616 2018-03-27 Joel Brobecker <brobecker@adacore.com>
1617
1618 PR gdb/22670
1619 * dwarf2read.c (dwarf2_physname): Do not return the demangled
1620 symbol name if the CU's language stores symbol names in linkage
1621 format.
1622 * language.h (struct language_defn)
1623 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
1624 all instances of this struct.
1625
1626 2018-03-26 Tom Tromey <tom@tromey.com>
1627
1628 * stack.c (backtrace_command_1): Remove verbose code.
1629
1630 2018-03-26 Tom Tromey <tom@tromey.com>
1631
1632 * python/py-framefilter.c (py_print_type): Don't catch
1633 exceptions. Return void.
1634 (py_print_value): Likewise.
1635 (py_print_single_arg): Likewise.
1636 (enumerate_args): Don't catch exceptions.
1637 (py_print_args): Likewise.
1638 (py_print_frame): Likewise.
1639 (gdbpy_apply_frame_filter): Catch exceptions here.
1640
1641 2018-03-26 Tom Tromey <tom@tromey.com>
1642
1643 * stack.c (_initialize_stack): Remove trailing newlines from help
1644 text. Add "Usage" line to "backtrace" help.
1645
1646 2018-03-26 Tom Tromey <tom@tromey.com>
1647
1648 PR python/16486:
1649 * python/py-framefilter.c (py_print_args): Call wrap_hint.
1650
1651 2018-03-26 Tom Tromey <tom@tromey.com>
1652
1653 * python/py-framefilter.c (py_print_single_arg): Return
1654 EXT_LANG_BT_ERROR from catch.
1655
1656 2018-03-26 Tom Tromey <tom@tromey.com>
1657
1658 PR backtrace/15584:
1659 * stack.c (backtrace_command_1): Move some code into no-filters
1660 "if".
1661
1662 2018-03-26 Tom Tromey <tom@tromey.com>
1663
1664 * python/py-framefilter.c (throw_quit_or_print_exception): New
1665 function.
1666 (gdbpy_apply_frame_filter): Use it.
1667
1668 2018-03-26 Tom Tromey <tom@tromey.com>
1669
1670 PR cli/17716:
1671 * python/py-framefilter.c (py_print_type, py_print_value)
1672 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
1673 RETURN_MASK_ERROR.
1674
1675 2018-03-26 Tom Tromey <tom@tromey.com>
1676
1677 * python/py-framefilter.c (enumerate_args): Use
1678 gdb::unique_xmalloc_ptr.
1679
1680 2018-03-26 Tom Tromey <tom@tromey.com>
1681
1682 * python/py-framefilter.c (py_print_frame): Return
1683 EXT_LANG_BT_OK.
1684 (gdbpy_apply_frame_filter): Update comment.
1685 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
1686 Remove.
1687 <EXT_LANG_BT_NO_FILTERS>: Change value.
1688
1689 2018-03-26 Tom Tromey <tom@tromey.com>
1690
1691 PR backtrace/15582:
1692 * stack.c (backtrace_command): Parse "hide" argument.
1693 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
1694 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
1695 constant.
1696
1697 2018-03-26 Tom Tromey <tom@tromey.com>
1698
1699 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
1700 add "flags".
1701 (backtrace_command): Remove "fulltrace", add "flags".
1702
1703 2018-03-26 Tom Tromey <tom@tromey.com>
1704
1705 * stack.c (backtrace_command): Rewrite command line parsing.
1706
1707 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
1708
1709 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
1710
1711 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
1712
1713 * filename-seen-cache.h: Add include guard.
1714
1715 2018-03-26 Keith Seitz <keiths@redhat.com>
1716
1717 * symfile.c (place_section): Remove "struct" from section_addr_info
1718 in comment.
1719 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
1720 "struct" keyword from section_addr_info.
1721
1722 2018-03-26 Alan Hayward <alan.hayward@arm.com>
1723
1724 * regformats/regdef.h (reg): Add constructors.
1725
1726 2018-03-25 Pedro Alves <palves@redhat.com>
1727
1728 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
1729 if then/else bodies in var_func_name extraction.
1730
1731 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
1732
1733 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
1734 lookup_minimal_symbol() to find symbol entry.
1735 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
1736
1737 2018-03-23 Keith Seitz <keiths@redhat.com>
1738
1739 PR c++/22968
1740 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
1741 nested type definitions for C++, too.
1742
1743 2018-03-23 Tom Tromey <tom@tromey.com>
1744
1745 * machoread.c (struct oso_el): Add a constructor. Don't define as
1746 a typedef.
1747 (macho_register_oso): Remove.
1748 (macho_symtab_read): Take a std::vector.
1749 (oso_el_compare_name): Now a std::sort comparator.
1750 (macho_symfile_read_all_oso): Take a std::vector.
1751 (macho_symfile_read): Use std::vector. Remove cleanups.
1752
1753 2018-03-22 Tom Tromey <tom@tromey.com>
1754
1755 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
1756 (record_full_goto_bookmark): Use std::string.
1757
1758 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1759
1760 PR tdep/18295
1761 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
1762 a single mask.
1763
1764 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1765
1766 * rs6000-tdep.c (store_insn_p): New function.
1767 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
1768 and cr_reg to their unshifted values. Use store_insn_p to
1769 match LR saves using either R1 or fdata->alloca_reg. Use
1770 store_insn_p to match CR saves. Set alloca_reg_offset
1771 when alloca_reg and framep are set. Remove lr_reg shift
1772 when assigning to fdata->lr_register.
1773
1774 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
1775
1776 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
1777 command line args instead of emitting a warning.
1778
1779 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
1780
1781 * tracepoint.h (struct static_tracepoint_marker): Initialize
1782 fields, define default constructor, move constructor and move
1783 assignment, disable the rest.
1784 <str_id, extra>: Make std::string.
1785 (release_static_tracepoint_marker): Remove.
1786 (free_current_marker): Remove.
1787 * tracepoint.c (free_current_marker): Remove.
1788 (parse_static_tracepoint_marker_definition): Adjust to
1789 std::string, use new hex2str overload.
1790 (release_static_tracepoint_marker): Remove.
1791 (print_one_static_tracepoint_marker): Get marker by reference
1792 and adjust to std::string.
1793 (info_static_tracepoint_markers_command): Adjust to std::vector
1794 changes
1795 * target.h (static_tracepoint_marker_p): Remove typedef.
1796 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
1797 (struct target_ops) <to_static_tracepoint_marker_at>: Return
1798 bool.
1799 <to_static_tracepoint_markers_by_strid>: Return std::vector.
1800 * target-debug.h
1801 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
1802 (target_debug_print_std_vector_static_tracepoint_marker): New.
1803 (target_debug_print_struct_static_tracepoint_marker_p): Rename
1804 to...
1805 (target_debug_print_static_tracepoint_marker_p): ... this.
1806 * target-delegates.c: Re-generate.
1807 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
1808 Make std::string.
1809 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
1810 (decode_static_tracepoint_spec): Adjust to std::vector.
1811 (tracepoint_print_one_detail): Adjust to std::string.
1812 (strace_marker_decode_location): Adjust to std::string.
1813 (update_static_tracepoint): Adjust to std::string, remove call
1814 to release_static_tracepoint_marker.
1815 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
1816 Adjust to std::vector.
1817 * remote.c (remote_static_tracepoint_marker_at): Return bool.
1818 (remote_static_tracepoint_markers_by_strid): Adjust to
1819 std::vector.
1820 * common/rsp-low.h (hex2str): New overload with explicit count
1821 of bytes.
1822 * common/rsp-low.c (hex2str): New overload with explicit count
1823 of bytes.
1824 * unittests/rsp-low-selftests.c (test_hex2str): New function.
1825 (_initialize_rsp_low_selftests): Add test_hex2str test.
1826 * unittests/tracepoint-selftests.c
1827 (test_parse_static_tracepoint_marker_definition): Adjust to
1828 std::string.
1829
1830 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
1831
1832 * tracepoint.c (parse_static_tracepoint_marker_definition):
1833 Consider case where the definition is followed by more
1834 definitions.
1835 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1836 tracepoint-selftests.c.
1837 * unittests/tracepoint-selftests.c: New.
1838
1839 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1840
1841 * MAINTAINERS (Write After Approval): Add Pedro Franco de
1842 Carvalho.
1843
1844 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
1845
1846 * symtab.c (find_pc_sect_line): fixed indentation.
1847
1848 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
1849
1850 * symtab.c (find_pc_sect_line): now uses binary search.
1851
1852 2018-03-19 Tom Tromey <tom@tromey.com>
1853
1854 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
1855 "IDENT" production.
1856
1857 2018-03-19 Pedro Alves <palves@redhat.com>
1858 Tom Tromey <tom@tromey.com>
1859
1860 * unittests/observable-selftests.c: New file.
1861 * common/observable.h: New file.
1862 * observable.h: New file.
1863 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
1864 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
1865 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
1866 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
1867 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
1868 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
1869 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
1870 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
1871 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
1872 python/py-breakpoint.c, python/py-finishbreakpoint.c,
1873 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
1874 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
1875 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
1876 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
1877 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
1878 tui/tui-interp.c, valops.c: Update all users.
1879 * tui/tui-hooks.c (tui_bp_created_observer)
1880 (tui_bp_deleted_observer, tui_bp_modified_observer)
1881 (tui_inferior_exit_observer, tui_before_prompt_observer)
1882 (tui_normal_stop_observer, tui_register_changed_observer):
1883 Remove.
1884 (tui_observers_token): New global.
1885 (attach_or_detach, tui_attach_detach_observers): New functions.
1886 (tui_install_hooks, tui_remove_hooks): Use
1887 tui_attach_detach_observers.
1888 * record-btrace.c (record_btrace_thread_observer): Remove.
1889 (record_btrace_thread_observer_token): New global.
1890 * observer.sh: Remove.
1891 * observer.c: Rename to observable.c.
1892 * observable.c (namespace gdb_observers): Define new objects.
1893 (observer_debug): Move into gdb_observers namespace.
1894 (struct observer, struct observer_list, xalloc_observer_list_node)
1895 (xfree_observer_list_node, generic_observer_attach)
1896 (generic_observer_detach, generic_observer_notify): Remove.
1897 (_initialize_observer): Update.
1898 Don't include observer.inc.
1899 * Makefile.in (generated_files): Remove observer.h, observer.inc.
1900 (clean mostlyclean): Likewise.
1901 (observer.h, observer.inc): Remove targets.
1902 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
1903 (COMMON_SFILES): Use observable.c, not observer.c.
1904 * .gitignore: Remove observer.h.
1905
1906 2018-03-18 Tom Tromey <tom@tromey.com>
1907
1908 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
1909 gdb::def_vector.
1910 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
1911
1912 2018-03-17 Tom Tromey <tom@tromey.com>
1913
1914 * auto-load.c (auto_load_objfile_script_1): Use std::string.
1915
1916 2018-03-17 Tom Tromey <tom@tromey.com>
1917
1918 * target.c (class scoped_target_fd): New.
1919 (target_fileio_close_cleanup): Remove.
1920 (target_fileio_read_alloc_1): Use scoped_target_fd.
1921
1922 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1923
1924 * silent-rules.mk: New.
1925 * Makefile.in: Include silent-rules.mk
1926 (srcdir, VPATH, top_srcdir): Move up.
1927 (COMPILE): Add ECHO_CXX.
1928 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
1929 (init.c): Add ECHO_INIT_C.
1930 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1931 (version.c): Add ECHO_GEN.
1932 (printcmd.o): Add ECHO_CXX.
1933 (target-float.o): Add ECHO_CXX.
1934 (ada-exp.o): Add ECHO_CXX.
1935 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
1936 (insight$(EXEEXT)): Add ECHO_CXXLD.
1937 * gnulib/configure.ac: Add AM_SILENT_RULES.
1938 * gnulib/aclocal.m4: Re-generate.
1939 * gnulib/configure: Re-generate.
1940 * gnulib/import/Makefile.in: Re-generate.
1941
1942 2018-03-16 Tom Tromey <tom@tromey.com>
1943
1944 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
1945 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
1946 * utils.c (do_free_section_addr_info)
1947 (make_cleanup_free_section_addr_info): Remove.
1948 * symfile.h (struct other_sections): Add constructor.
1949 (struct section_addr_info): Remove.
1950 (section_addr_info): New typedef.
1951 (struct sym_fns) <sym_offsets>: Change type of parameter.
1952 (build_section_addr_info_from_objfile)
1953 (relative_addr_info_to_section_offsets, addr_info_make_relative)
1954 (default_symfile_offsets, symbol_file_add)
1955 (symbol_file_add_from_bfd)
1956 (build_section_addr_info_from_section_table): Update.
1957 (alloc_section_addr_info, free_section_addr_info): Don't declare.
1958 * symfile.c (alloc_section_addr_info): Remove.
1959 (build_section_addr_info_from_section_table): Change return type.
1960 Update.
1961 (build_section_addr_info_from_bfd)
1962 (build_section_addr_info_from_objfile): Likewise.
1963 (free_section_addr_info): Remove.
1964 (relative_addr_info_to_section_offsets): Change type of "addrs".
1965 (addrs_section_compar): Now a std::sort comparator.
1966 (addrs_section_sort): Change return type.
1967 (addr_info_make_relative): Change type of "addrs". Update.
1968 (default_symfile_offsets, syms_from_objfile_1)
1969 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
1970 (symbol_file_add_separate): Update.
1971 (symbol_file_add): Change type of "addrs". Update.
1972 (add_symbol_file_command): Update. Remove cleanups.
1973 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
1974 cleanups.
1975 * symfile-debug.c (debug_sym_offsets): Change type of "info".
1976 * solib.c (solib_read_symbols): Update.
1977 * objfiles.c (objfile_relocate): Update. Remove cleanups.
1978 * machoread.c (macho_symfile_offsets): Update.
1979 * jit.c (jit_bfd_try_read_symtab): Update.
1980
1981 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
1982
1983 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1984 unittests/utils-selftests.c.
1985 * unittests/utils-selftests.c: New file.
1986
1987 2018-03-14 Tom Tromey <tom@tromey.com>
1988
1989 PR cli/14977:
1990 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
1991 for NULL.
1992
1993 2018-03-14 Tom Tromey <tom@tromey.com>
1994
1995 PR cli/19918:
1996 * printcmd.c (printf_pointer): Allow "-" in format.
1997
1998 2018-03-14 Tom Tromey <tom@tromey.com>
1999
2000 * printcmd.c (_initialize_printcmd): Add usage to printf.
2001
2002 2018-03-14 Yao Qi <qiyao@sourceware.org>
2003
2004 * MAINTAINERS: Update my email address.
2005
2006 2018-03-13 Tom Tromey <tom@tromey.com>
2007
2008 * machoread.c (macho_check_dsym): Change filenamep to a
2009 std::string*.
2010 (macho_symfile_read): Update.
2011 * symfile.c (load_command): Use std::string.
2012
2013 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
2014
2015 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
2016 to error message string.
2017 (riscv_register_name): Use xsnprintf instead of sprintf.
2018 (riscv_insn::fetch_instruction): Use gdb_assert instead of
2019 internal_error.
2020 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
2021 error.
2022 (riscv_push_dummy_call): Likewise.
2023
2024 2018-03-12 Tom Tromey <tom@tromey.com>
2025
2026 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
2027 Use gdb::byte_vector.
2028 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
2029
2030 2018-03-12 Yao Qi <yao.qi@linaro.org>
2031
2032 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
2033 parameter type to readable_regcache.
2034 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
2035 the declaration.
2036
2037 2018-03-11 Tom Tromey <tom@tromey.com>
2038
2039 * dwarf2read.c (struct nextfield): Add initializers.
2040 (struct nextfnfield): Remove.
2041 (struct fnfieldlist): Add initializers. Remove "length" and
2042 "head", use std::vector.
2043 (struct decl_field_list): Remove.
2044 (struct field_info): Add initializers.
2045 <fields, baseclasses>: Now std::vector.
2046 <nbaseclasses, nfnfields, typedef_field_list_count,
2047 nested_types_list_count>: Remove.
2048 (dwarf2_add_field, dwarf2_add_type_defn)
2049 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
2050 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
2051 (process_structure_scope): Update.
2052
2053 2018-03-11 Tom Tromey <tom@tromey.com>
2054
2055 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
2056 for use by std::sort.
2057 (build_type_psymtabs_1): Use std::vector.
2058
2059 2018-03-09 Eli Zaretskii <eliz@gnu.org>
2060
2061 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
2062 and LIBMPFR in the printed configuration.
2063
2064 2018-03-08 Tom Tromey <tom@tromey.com>
2065
2066 * source.c (get_filename_and_charpos): Use scoped_fd.
2067 * nto-procfs.c (procfs_open_1): Use scoped_fd.
2068 (procfs_pidlist): Likewise.
2069 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
2070 (iterate_over_mappings): Likewise.
2071
2072 2018-03-08 Tom Tromey <tom@tromey.com>
2073
2074 * infcall.c (struct call_return_meta_info)
2075 <stack_temporaries_enabled>: Remove.
2076 (get_call_return_value, call_function_by_hand_dummy): Update.
2077 * thread.c (disable_thread_stack_temporaries): Remove.
2078 (enable_thread_stack_temporaries): Remove.
2079 (thread_stack_temporaries_enabled_p): Return bool.
2080 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
2081 (get_last_thread_stack_temporary): Update.
2082 * eval.c (evaluate_subexp): Update.
2083 * gdbthread.h (class enable_thread_stack_temporaries): Now a
2084 class, not a function.
2085 (value_ptr, value_vec): Remove typedefs.
2086 (class thread_info) <stack_temporaries_enabled>: Now bool.
2087 <stack_temporaries>: Now a std::vector.
2088 (thread_stack_temporaries_enabled_p)
2089 (value_in_thread_stack_temporaries): Return bool.
2090
2091 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
2092
2093 * remote.c (putpkt_binary): Fix omitted bytes reporting.
2094 (getpkt_or_notif_sane_1): Likewise.
2095
2096 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
2097
2098 * build-id.c (build_id_to_debug_bfd): Use std::string.
2099
2100 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
2101
2102 * build-id.c (find_separate_debug_file_by_buildid): Return
2103 std::string.
2104 * build-id.h (find_separate_debug_file_by_buildid): Return
2105 std::string.
2106 * coffread.c (coff_symfile_read): Adjust to std::string.
2107 * elfread.c (elf_symfile_read): Adjust to std::string.
2108 * symfile.c (separate_debug_file_exists): Change parameter to
2109 std::string.
2110 (find_separate_debug_file): Return std::string.
2111 (find_separate_debug_file_by_debuglink): Return std::string.
2112 * symfile.h (find_separate_debug_file_by_debuglink): Return
2113 std::string.
2114
2115 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
2116
2117 * common/xml-utils.c (xml_escape_text): Move code to...
2118 (xml_escape_text_append): ... this new function.
2119 * common/xml-utils.h (xml_escape_text_append): New declaration.
2120 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
2121 New function.
2122 (_initialize_xml_utils): register test_xml_escape_text_append as
2123 a selftest.
2124
2125 2018-03-07 Alan Hayward <alan.hayward@arm.com>
2126
2127 * defs.h: Remove MAX_REGISTER_SIZE.
2128 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
2129 asserts.
2130 * python/py-unwind.c (pyuw_sniffer): Likewise.
2131
2132 2018-03-07 Tom Tromey <tom@tromey.com>
2133
2134 * linux-tdep.c (linux_info_proc): Update.
2135 * target.h (struct target_ops) <to_fileio_readlink>: Return
2136 optional<string>.
2137 (target_fileio_readlink): Return optional<string>.
2138 * remote.c (remote_hostio_readlink): Return optional<string>.
2139 * inf-child.c (inf_child_fileio_readlink): Return
2140 optional<string>.
2141 * target.c (target_fileio_readlink): Return optional<string>.
2142
2143 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
2144
2145 * regcache.c (cooked_read_test): Add riscv to the list of
2146 architectures that have a save_reggroup.
2147
2148 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
2149
2150 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
2151 value is not a dynamic class object.
2152
2153 2018-03-06 Tom Tromey <tom@tromey.com>
2154
2155 * rust-exp.y: Formatting fixes.
2156
2157 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2158
2159 * riscv-tdep.c (riscv_register_name): Remove target description
2160 support.
2161 (riscv_gdbarch_init): Remove target description check.
2162
2163 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2164
2165 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
2166 comment.
2167 * riscv-tdep.h: Likewise.
2168
2169 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2170
2171 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
2172 (riscv_pseudo_register_write): Delete.
2173 (riscv_gdbarch_init): Remove all use of pseudo registers.
2174
2175 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
2176
2177 * record-btrace.c (btrace_print_lines): Replace cleanup
2178 parameter with RAII equivalents.
2179 (btrace_insn_history): Replace cleanup with RAII equivalents.
2180 * ui-out.h (make_cleanup_ui_out_list_begin_end,
2181 make_cleanup_ui_out_tuple_begin_end): Remove.
2182 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
2183 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
2184 make_cleanup_ui_out_list_begin_end): Remove.
2185
2186 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
2187
2188 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
2189 parameter types to std::vector. Use bool.
2190 (record_btrace_wait): Replace VEC(tp_t) with
2191 std::vector<thread_info *>.
2192 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
2193
2194 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
2195
2196 * record-btrace.c (record_btrace_disable_callback): Remove.
2197 (struct scoped_btrace_disable): New.
2198 (record_btrace_open): Use scoped_btrace_disable.
2199
2200 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2201
2202 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
2203 reading values from registers.
2204
2205 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2206
2207 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
2208 where appropriate.
2209
2210 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2211
2212 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
2213 change parameter type. Use GDB's print functions, and use
2214 core_addr_to_string where appropriate.
2215 (riscv_push_dummy_call): Use core_addr_to_string where
2216 appropriate, update call to riscv_print_arg_location, and reindent
2217 a few lines.
2218 (riscv_return_value): Update call to riscv_print_arg_location.
2219
2220 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2221 Tim Newsome <tim@sifive.com>
2222 Albert Ou <a0u@eecs.berkeley.edu>
2223 Darius Rad <darius@bluespec.com>
2224
2225 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
2226 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
2227 (ALLDEPFILES): Add riscv-tdep.c
2228 * configure.tgt: Add riscv support.
2229 * riscv-tdep.c: New file.
2230 * riscv-tdep.h: New file.
2231 * NEWS: Mention new target.
2232 * MAINTAINERS: Add entry for riscv.
2233
2234 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2235
2236 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
2237 fields within aggregates.
2238
2239 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
2240
2241 * record-btrace.c (btrace_print_lines): Change type of flags to
2242 gdb_disassembly_flags.
2243
2244 2018-03-04 John Baldwin <jhb@FreeBSD.org>
2245
2246 * fbsd-nat.c: Include "inf-ptrace.h".
2247 (USE_SIGTRAP_SIGINFO): Conditionally define.
2248 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
2249 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
2250 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
2251 function.
2252 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
2253 Likewise.
2254 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
2255 Likewise.
2256 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
2257 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
2258 "supports_stopped_by_hw_breakpoint" target methods.
2259
2260 2018-03-04 John Baldwin <jhb@FreeBSD.org>
2261
2262 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
2263 * fbsd-nat.c (debug_fbsd_nat): New variable.
2264 (show_fbsd_nat_debug): New function.
2265 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
2266 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
2267
2268 2018-03-04 John Baldwin <jhb@FreeBSD.org>
2269
2270 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
2271 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
2272 prototype.
2273 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
2274 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
2275 method.
2276
2277 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2278
2279 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
2280 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
2281
2282 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2283
2284 * charset.c (struct charset_vector): New.
2285 (charsets): Change type to charset_vector.
2286 (find_charset_names): Adjust.
2287 (add_one): Adjust.
2288 (_initialize_charset): Adjust.
2289
2290 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2291
2292 * progspace.h (struct program_space) <deleted_solibs>: Change
2293 type to std::vector<std::string>.
2294 * progspace.c (clear_program_space_solib_cache): Adjust.
2295 * breakpoint.c (print_solib_event): Adjust.
2296 (check_status_catch_solib): Adjust.
2297 * solib.c (update_solib_list): Adjust.
2298 * ui-out.h (class ui_out) <field_string>: New overload.
2299 * ui-out.c (ui_out::field_string): New overload.
2300
2301 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2302
2303 * progspace.h (struct program_space): Add constructor and
2304 destructor, initialize fields.
2305 (add_program_space): Remove.
2306 * progspace.c (add_program_space): Rename to...
2307 (program_space::program_space): ... this.
2308 (release_program_space): Rename to...
2309 (program_space::~program_space): ... this.
2310 (delete_program_space): Use delete to delete program_space.
2311 (initialize_progspace): Use new to allocate program_space.
2312 * inferior.c (add_inferior_with_spaces): Likewise.
2313 (clone_inferior_command): Likewise.
2314 * infrun.c (follow_fork_inferior): Likewise.
2315 (handle_vfork_child_exec_or_exit): Likewise.
2316
2317 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2318
2319 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
2320 (delim_string_to_char_ptr_vec): Return std::vector of
2321 gdb::unique_xmalloc_ptr.
2322 (dirnames_to_char_ptr_vec_append): Take std::vector of
2323 gdb::unique_xmalloc_ptr.
2324 (dirnames_to_char_ptr_vec): Return std::vector of
2325 gdb::unique_xmalloc_ptr.
2326 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
2327 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
2328 (delim_string_to_char_ptr_vec): Return an std::vector of
2329 gdb::unique_xmalloc_ptr, adjust the code.
2330 (dirnames_to_char_ptr_vec_append): Take an std::vector of
2331 gdb::unique_xmalloc_ptr, adjust the code.
2332 (dirnames_to_char_ptr_vec): Return an std::vector of
2333 gdb::unique_xmalloc_ptr, adjust the code.
2334 * auto-load.c (auto_load_safe_path_vec): Change type to
2335 std::vector of gdb::unique_xmalloc_ptr.
2336 (auto_load_expand_dir_vars): Return an std::vector of
2337 gdb::unique_xmalloc_ptr, adjust the code.
2338 (auto_load_safe_path_vec_update): Adjust.
2339 (filename_is_in_auto_load_safe_path_vec): Adjust.
2340 (auto_load_objfile_script_1): Adjust.
2341 * build-id.c (build_id_to_debug_bfd): Adjust.
2342 * linux-thread-db.c (thread_db_load_search): Adjust.
2343 * source.c (add_path): Adjust.
2344 (openp): Adjust.
2345 * symfile.c (find_separate_debug_file): Adjust.
2346 * utils.c (do_free_char_ptr_vec): Remove.
2347 (make_cleanup_free_char_ptr_vec): Remove.
2348
2349 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
2350
2351 PR gdb/22907
2352 * common/pathstuff.c: Conditionally include "<windows.h>".
2353
2354 2018-03-01 Georg Sauthoff <mail@georg.so>
2355
2356 PR gdb/22888
2357 * gcore.in: Quote variables and switch interpreter to bash.
2358
2359 2018-03-01 Tom Tromey <tom@tromey.com>
2360
2361 * dwarf2read.c (alloc_discriminant_info): Fix default_index
2362 assertion. Add assertion for discriminant_index.
2363 (quirk_rust_enum): Use correct base type name in univariant case.
2364
2365 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
2366
2367 * record.c (get_call_history_modifiers): Return a
2368 record_print_flags.
2369 (cmd_record_call_history): Adjust.
2370 * record-btrace.c (record_btrace_call_history): Adjust.
2371 (record_btrace_call_history_range): Adjust.
2372 (record_btrace_call_history_from): Adjust.
2373 * target-debug.h (target_debug_print_record_print_flags): New.
2374 * target-delegates.c: Re-generate.
2375 * target.c (target_call_history): Change flags type.
2376 (target_call_history_from): Likewise.
2377 (target_call_history_range): Likewise.
2378 * target.h (struct target_ops) <target_call_history>: Likewise.
2379 (target_call_history_from): Likewise.
2380 (target_call_history_range): Likewise.
2381
2382 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2383 Simon Marchi <simon.marchi@polymtl.ca>
2384
2385 * common/common-utils.c: Include "sys/stat.h".
2386 (is_regular_file): Move here from "source.c"; change return
2387 type to "bool".
2388 * common/common-utils.h (is_regular_file): New prototype.
2389 * common/pathstuff.c (contains_dir_separator): New function.
2390 * common/pathstuff.h (contains_dir_separator): New prototype.
2391 * source.c: Don't include "sys/stat.h".
2392 (is_regular_file): Move to "common/common-utils.c".
2393
2394 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
2395
2396 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
2397 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
2398 * auto-load.c: Include "common/pathstuff.h".
2399 * common/common-def.h (current_directory): Move here.
2400 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
2401 function.
2402 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
2403 prototype.
2404 * common/pathstuff.c: New file.
2405 * common/pathstuff.h: New file.
2406 * compile/compile.c: Include "common/pathstuff.h".
2407 * defs.h (current_directory): Move to "common/common-defs.h".
2408 * dwarf2read.c: Include "common/pathstuff.h".
2409 * exec.c: Likewise.
2410 * guile/scm-safe-call.c: Likewise.
2411 * linux-thread-db.c: Likewise.
2412 * main.c: Likewise.
2413 * nto-tdep.c: Likewise.
2414 * objfiles.c: Likewise.
2415 * source.c: Likewise.
2416 * symtab.c: Likewise.
2417 * utils.c: Include "common/pathstuff.h".
2418 (gdb_realpath): Move to "common/pathstuff.c".
2419 (gdb_realpath_keepfile): Likewise.
2420 (gdb_abspath): Likewise.
2421 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
2422 (gdb_realpath_keepfile): Likewise.
2423 (gdb_abspath): Likewise.
2424
2425 2018-02-28 John Baldwin <jhb@FreeBSD.org>
2426
2427 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
2428 wildcard process pid for super_resume for kernels with a
2429 specific bug.
2430
2431 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
2432
2433 * compile/compile.c (get_args): Add additional comments
2434 explaining function.
2435
2436 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
2437 Tom Tromey <tom@tromey.com>
2438
2439 * target.h (memory_write_request_s): Remove typedef. Don't define
2440 VEC.
2441 (target_write_memory_blocks): Change argument to std::vector.
2442 (struct memory_write_request): Add constructor.
2443 * target-memory.c (compare_block_starting_address): Return bool.
2444 Change argument types.
2445 (claim_memory): Change arguments to use std::vector.
2446 (split_regular_and_flash_blocks, blocks_to_erase)
2447 (compute_garbled_blocks): Likewise.
2448 (cleanup_request_data, cleanup_write_requests_vector): Remove.
2449 (target_write_memory_blocks): Change argument to std::vector.
2450 * symfile.c (struct load_section_data): Add constructor and
2451 destructor. Use std::vector for "requests".
2452 (struct load_progress_data): Add initializers.
2453 (load_section_callback): Update. Use "new".
2454 (clear_memory_write_data): Remove.
2455 (generic_load): Update.
2456
2457 2018-02-27 Alan Hayward <alan.hayward@arm.com>
2458
2459 * arch/aarch64.h: Use common/tdesc.h.
2460
2461 2018-02-26 Maciej W. Rozycki <macro@mips.com>
2462
2463 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
2464 architecture with a 64-bit ABI.
2465
2466 2018-02-26 Maciej W. Rozycki <macro@mips.com>
2467
2468 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
2469 ahead of target description loading.
2470
2471 2018-02-26 Tom Tromey <tom@tromey.com>
2472
2473 * stack.c (backtrace_command_1): Update.
2474 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
2475 of "flags".
2476 * python/py-framefilter.c (py_print_frame)
2477 (gdbpy_apply_frame_filter): Change type of "flags".
2478 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
2479 of "flags".
2480 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
2481 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
2482 * extension.h (enum frame_filter_flag): Rename from
2483 frame_filter_flags.
2484 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
2485 (apply_ext_lang_frame_filter): Change type of "flags".
2486 * extension.c (apply_ext_lang_frame_filter): Change type of
2487 "flags".
2488 * extension-priv.h (struct extension_language_ops)
2489 <apply_frame_filter>: Change type of "flags".
2490
2491 2018-02-26 Tom Tromey <tom@tromey.com>
2492
2493 PR python/16497:
2494 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
2495 off-by-one in py_end computation.
2496 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
2497 PRINT_MORE_FRAMES.
2498 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
2499 constant.
2500
2501 2018-02-26 Tom Tromey <tom@tromey.com>
2502
2503 * dwarf2read.c (struct variant_field): New.
2504 (struct nextfield) <variant>: New field.
2505 (dwarf2_add_field): Handle DW_TAG_variant_part.
2506 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
2507 discriminated union.
2508 (read_structure_type): Handle DW_TAG_variant_part.
2509 (handle_struct_member_die): New function, extracted from
2510 process_structure_scope. Handle DW_TAG_variant.
2511 (process_structure_scope): Handle discriminated unions. Call
2512 handle_struct_member_die.
2513
2514 2018-02-26 Tom Tromey <tom@tromey.com>
2515
2516 * rust-lang.h (rust_last_path_segment): Declare.
2517 * rust-lang.c (rust_last_path_segment): Now public. Change
2518 contract.
2519 (struct disr_info): Remove.
2520 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
2521 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
2522 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
2523 (rust_enum_p, rust_enum_variant): New function.
2524 (rust_underscore_fields): Remove "offset" parameter.
2525 (rust_print_enum): New function.
2526 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
2527 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
2528 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
2529 enums.
2530 (rust_internal_print_type): New function, from rust_print_type.
2531 Remove enum code.
2532 (rust_print_type): Call rust_internal_print_type.
2533 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
2534 Update enum handling.
2535 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
2536 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
2537 (rust_union_quirks): New functions.
2538 (process_full_comp_unit, process_full_type_unit): Call
2539 rust_union_quirks.
2540 (process_structure_scope): Update rust_unions if necessary.
2541
2542 2018-02-26 Tom Tromey <tom@tromey.com>
2543
2544 * value.h (value_union_variant): Declare.
2545 * valops.c (value_union_variant): New function.
2546 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
2547 (struct discriminant_info): New.
2548 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
2549 enumerator.
2550 (struct main_type) <flag_discriminated_union>: New field.
2551
2552 2018-02-26 Tom Tromey <tom@tromey.com>
2553
2554 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2555 unittests/unpack-selftests.c.
2556 * unittests/unpack-selftests.c: New file.
2557 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
2558
2559 2018-02-26 Yao Qi <yao.qi@linaro.org>
2560
2561 * dwarf2read.c (struct partial_die_info) <read>: New method.
2562 (read_partial_die): Remove the declaration.
2563 (load_partial_dies): Update.
2564 (partial_die_info::partial_die_info):
2565 (read_partial_die): Change it to partial_die_info::read.
2566
2567 2018-02-26 Yao Qi <yao.qi@linaro.org>
2568
2569 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
2570 (fixup_partial_die): Remove declaration.
2571 (scan_partial_symbols): Update.
2572 (partial_die_parent_scope): Likewise.
2573 (partial_die_full_name): Likewise.
2574 (fixup_partial_die): Change it to partial_die_info::fixup.
2575
2576 2018-02-26 Yao Qi <yao.qi@linaro.org>
2577
2578 * dwarf2read.c (read_partial_die): Update the declaration.
2579 (load_partial_dies): Caller update.
2580 (read_partial_die): Remove one argument abbrev_len.
2581
2582 2018-02-26 Yao Qi <yao.qi@linaro.org>
2583
2584 * dwarf2read.c (struct partial_die_info): Add ctor, delete
2585 assignment operator.
2586 (load_partial_dies): Use ctor and copy ctor.
2587 (read_partial_die): Update.
2588 (dwarf2_cu::find_partial_die): Use ctor.
2589
2590 2018-02-26 Yao Qi <yao.qi@linaro.org>
2591
2592 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
2593 (find_partial_die_in_comp_unit): Change it to
2594 dwarf2_cu::find_partial_die.
2595 (find_partial_die): Update.
2596
2597 2018-02-26 Yao Qi <yao.qi@linaro.org>
2598
2599 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
2600 is NULL.
2601
2602 2018-02-26 Yao Qi <yao.qi@linaro.org>
2603
2604 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
2605
2606 2018-02-26 Alan Hayward <alan.hayward@arm.com>
2607
2608 * arch/amd64.h: Use common/tdesc.h.
2609 * arch/i386.c: Likewise.
2610 * arch/i386.h: Likewise.
2611 * arch/tic6x.c: Likewise.
2612 * arch/tdesc.h: Move file from here...
2613 * common/tdesc.h: ...to here.
2614 * features/aarch64-core.c: Regenerate.
2615 * features/aarch64-fpu.c: Regenerate.
2616 * features/i386/32bit-avx.c: Regenerate.
2617 * features/i386/32bit-avx512.c: Regenerate.
2618 * features/i386/32bit-core.c: Regenerate.
2619 * features/i386/32bit-linux.c: Regenerate.
2620 * features/i386/32bit-mpx.c: Regenerate.
2621 * features/i386/32bit-pkeys.c: Regenerate.
2622 * features/i386/32bit-sse.c: Regenerate.
2623 * features/i386/64bit-avx.c: Regenerate.
2624 * features/i386/64bit-avx512.c: Regenerate.
2625 * features/i386/64bit-core.c: Regenerate.
2626 * features/i386/64bit-linux.c: Regenerate.
2627 * features/i386/64bit-mpx.c: Regenerate.
2628 * features/i386/64bit-pkeys.c: Regenerate.
2629 * features/i386/64bit-segments.c: Regenerate.
2630 * features/i386/64bit-sse.c: Regenerate.
2631 * features/i386/x32-core.c: Regenerate.
2632 * features/tic6x-c6xp.c: Regenerate.
2633 * features/tic6x-core.c: Regenerate.
2634 * features/tic6x-gp.c: Regenerate.
2635 * target-descriptions.c: Use common/tdesc.h.
2636 * target-descriptions.h: Likewise.
2637
2638 2018-02-24 Tom Tromey <tom@tromey.com>
2639
2640 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
2641 (try_thread_db_load_from_dir, thread_db_load_search): Use
2642 std::string.
2643 (info_auto_load_libthread_db_compare): Return bool. Change
2644 argument types.
2645 (info_auto_load_libthread_db): Use std::vector, std::string.
2646 Remove cleanups.
2647
2648 2018-02-24 Tom Tromey <tom@tromey.com>
2649
2650 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
2651 std::string.
2652 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
2653 std::string*.
2654 * gdbarch.c: Rebuild.
2655 * gdbarch.h: Rebuild.
2656 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
2657 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
2658 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
2659 std::string*.
2660
2661 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
2662
2663 * gdbtypes.h (sect_offset): Change type to uint64_t.
2664 (sect_offset_str): New function.
2665 * dwarf2read.c (create_addrmap_from_aranges): Use
2666 sect_offset_str.
2667 (error_check_comp_unit_head): Likewise.
2668 (create_debug_type_hash_table): Likewise.
2669 (read_cutu_die_from_dwo): Likewise.
2670 (init_cutu_and_read_dies): Likewise.
2671 (init_cutu_and_read_dies_no_follow): Likewise.
2672 (process_psymtab_comp_unit_reader): Likewise.
2673 (partial_die_parent_scope): Likewise.
2674 (peek_die_abbrev): Likewise.
2675 (process_queue): Likewise.
2676 (dwarf2_physname): Likewise.
2677 (read_namespace_alias): Likewise.
2678 (read_import_statement): Likewise.
2679 (create_dwo_cu_reader): Likewise.
2680 (create_cus_hash_table): Likewise.
2681 (lookup_dwo_cutu): Likewise.
2682 (inherit_abstract_dies): Likewise.
2683 (read_func_scope): Likewise.
2684 (read_call_site_scope): Likewise.
2685 (dwarf2_add_member_fn): Likewise.
2686 (read_common_block): Likewise.
2687 (read_module_type): Likewise.
2688 (read_typedef): Likewise.
2689 (read_subrange_type): Likewise.
2690 (load_partial_dies): Likewise.
2691 (read_partial_die): Likewise.
2692 (find_partial_die): Likewise.
2693 (read_str_index): Likewise.
2694 (dwarf2_string_attr): Likewise.
2695 (build_error_marker_type): Likewise.
2696 (lookup_die_type): Likewise.
2697 (dump_die_shallow): Likewise.
2698 (follow_die_ref): Likewise.
2699 (dwarf2_fetch_die_loc_sect_off): Likewise.
2700 (dwarf2_fetch_constant_bytes): Likewise.
2701 (follow_die_sig): Likewise.
2702 (get_signatured_type): Likewise.
2703 (get_DW_AT_signature_type): Likewise.
2704 (dwarf2_find_containing_comp_unit): Likewise.
2705 (set_die_type): Likewise.
2706
2707 2018-02-21 John Baldwin <jhb@FreeBSD.org>
2708
2709 * arch/aarch64.c: Include "common-defs.h".
2710 * arch/amd64.c: Likewise.
2711 * arch/i386.c: Likewise.
2712
2713 2018-02-21 Tom Tromey <tom@tromey.com>
2714
2715 * value.h: (extract_field_op): Update.
2716 * eval.c (extract_field_op): Return a const char *.
2717 * expression.h (parse_expression_for_completion): Update.
2718 * completer.c (complete_expression): Update.
2719 (add_struct_fields): Make fieldname const.
2720 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
2721 (mark_completion_tag, parse_exp_in_context_1): Update.
2722 (parse_expression_for_completion): Change "name" to
2723 unique_xmalloc_ptr*.
2724
2725 2018-02-21 Tom Tromey <tom@tromey.com>
2726
2727 * infcall.c (call_function_by_hand_dummy): Use std::vector.
2728
2729 2018-02-21 Yao Qi <yao.qi@linaro.org>
2730
2731 * avr-tdep.c (avr_read_pc): Change parameter type to
2732 readable_regcache.
2733 * gdbarch.sh (read_pc): Likewise.
2734 * gdbarch.c: Re-generated.
2735 * gdbarch.h: Re-generated.
2736 * hppa-tdep.c (hppa_read_pc): Change parameter type to
2737 readable_regcache.
2738 * ia64-tdep.c (ia64_read_pc): Likewise.
2739 * mips-tdep.c (mips_read_pc): Likewise.
2740 * spu-tdep.c (spu_read_pc): Likewise.
2741
2742 2018-02-21 Yao Qi <yao.qi@linaro.org>
2743
2744 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
2745 * regcache-dump.c: New file.
2746 * regcache.c: Move register_dump to regcache-dump.c.
2747 (maintenance_print_registers): Likewise.
2748 (maintenance_print_raw_registers): Likewise.
2749 (maintenance_print_cooked_registers): Likewise.
2750 (maintenance_print_register_groups): Likewise.
2751 (maintenance_print_remote_registers): Likewise.
2752 (_initialize_regcache): Likewise.
2753 * regcache.h (register_dump): Moved from regcache.c.
2754
2755 2018-02-21 Yao Qi <yao.qi@linaro.org>
2756
2757 * regcache.c (regcache::regcache): Update.
2758 (regcache::invalidate): Move it to detached_regcache::invalidate.
2759 (get_thread_arch_aspace_regcache): Update.
2760 (regcache::raw_update): Update.
2761 (regcache::cooked_read): Remove some code.
2762 (regcache::cooked_read_value): Likewise.
2763 (regcache::raw_write): Remove assert on m_readonly_p.
2764 (regcache::raw_supply_integer): Move it to
2765 detached_regcache::raw_supply_integer.
2766 (regcache::raw_supply_zeroed): Likewise.
2767 * regcache.h (detached_regcache) <raw_supply_integer>: New
2768 declaration.
2769 <raw_supply_zeroed, invalidate>: Likewise.
2770 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
2771 <invalidate>: Likewise.
2772 <m_readonly_p>: Removed.
2773
2774 2018-02-21 Yao Qi <yao.qi@linaro.org>
2775
2776 * infcmd.c (get_return_value): Let stop_regs point to
2777 get_current_regcache.
2778 * regcache.c (regcache::regcache): Remove.
2779 (register_dump_reg_buffer): New class.
2780 (regcache_print): Adjust.
2781 * regcache.h (regcache): Remove constructors.
2782
2783 2018-02-21 Yao Qi <yao.qi@linaro.org>
2784
2785 * regcache.c (class register_dump): New class.
2786 (register_dump_regcache, register_dump_none): New class.
2787 (register_dump_remote, register_dump_groups): New class.
2788 (regcache_print): Update.
2789 * regcache.h (regcache_dump_what): Move it to regcache.c.
2790 (regcache) <dump>: Remove.
2791
2792 2018-02-21 Yao Qi <yao.qi@linaro.org>
2793
2794 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
2795 reg_buffer_rw *.
2796 (jit_unwind_reg_set_impl): Call raw_supply.
2797 (jit_frame_sniffer): Use reg_buffer_rw.
2798 * record-full.c (record_full_core_regbuf): Change its type.
2799 (record_full_core_open_1): Use reg_buffer_rw.
2800 (record_full_close): Likewise.
2801 (record_full_core_fetch_registers): Use regcache->raw_supply.
2802 (record_full_core_store_registers): Likewise.
2803 * regcache.c (regcache::get_register_status): Move it to
2804 reg_buffer.
2805 (regcache_raw_set_cached_value): Remove.
2806 (regcache::raw_set_cached_value): Remove.
2807 (regcache::raw_write): Call raw_supply.
2808 (regcache::raw_supply): Move it to reg_buffer_rw.
2809 * regcache.h (regcache_raw_set_cached_value): Remove.
2810 (reg_buffer_rw): New class.
2811
2812 2018-02-21 Yao Qi <yao.qi@linaro.org>
2813
2814 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
2815 readonly_detached_regcache.
2816 (dummy_frame_prev_register): Use regcache->cooked_read.
2817 * frame.c (frame_save_as_regcache): Change return type.
2818 (frame_pop): Update.
2819 * frame.h (frame_save_as_regcache): Update declaration.
2820 * inferior.h (get_infcall_suspend_state_regcache): Update
2821 declaration.
2822 * infrun.c (infcall_suspend_state) <registers>: use
2823 readonly_detached_regcache.
2824 (save_infcall_suspend_state): Don't use regcache_dup.
2825 (get_infcall_suspend_state_regcache): Change return type.
2826 * linux-fork.c (struct fork_info) <savedregs>: Change to
2827 readonly_detached_regcache.
2828 <pc>: New field.
2829 (fork_save_infrun_state): Don't use regcache_dup.
2830 (info_checkpoints_command): Adjust.
2831 * mi/mi-main.c (register_changed_p): Update declaration.
2832 (mi_cmd_data_list_changed_registers): Use
2833 readonly_detached_regcache.
2834 (register_changed_p): Change parameter type to
2835 readonly_detached_regcache.
2836 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
2837 readonly_detached_regcache.
2838 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
2839 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
2840 New.
2841 (regcache::save): Move it to reg_buffer.
2842 (regcache::restore): Change parameter type.
2843 (regcache_dup): Remove.
2844 * regcache.h (reg_buffer) <save>: New method.
2845 (readonly_detached_regcache): New class.
2846 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
2847 readonly_detached_regcache.
2848 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
2849
2850 2018-02-21 Yao Qi <yao.qi@linaro.org>
2851
2852 * frame.c (frame_save_as_regcache): Use regcache method save.
2853 (frame_pop): Use regcache method restore.
2854 * infrun.c (restore_infcall_suspend_state): Likewise.
2855 * linux-fork.c (fork_load_infrun_state): Likewise.
2856 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
2857 save.
2858 * regcache.c (regcache_save): Remove.
2859 (regcache::restore): More asserts.
2860 (regcache_cpy): Remove.
2861 * regcache.h (regcache_save): Remove the declaration.
2862 (regcache::restore): Move from private to public.
2863 Remove the friend declaration of regcache_cpy.
2864 (regcache_cpy): Remove declaration.
2865
2866 2018-02-21 Yao Qi <yao.qi@linaro.org>
2867
2868 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
2869 parameter type to 'readable_regcache *'.
2870 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
2871 * arm-tdep.c (arm_neon_quad_read): Likewise.
2872 (arm_pseudo_read): Likewise.
2873 * avr-tdep.c (avr_pseudo_register_read): Likewise.
2874 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
2875 * frv-tdep.c (frv_pseudo_register_read): Likewise.
2876 * gdbarch.c: Re-generated.
2877 * gdbarch.h: Re-generated.
2878 * gdbarch.sh (pseudo_register_read): Change parameter type to
2879 'readable_regcache *'.
2880 (pseudo_register_read_value): Likewise.
2881 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
2882 (h8300_pseudo_register_read): Likewise.
2883 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
2884 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
2885 (i386_pseudo_register_read_into_value): Likewise.
2886 (i386_pseudo_register_read_value): Likewise.
2887 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
2888 declaration.
2889 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
2890 * m32c-tdep.c (m32c_raw_read): Likewise.
2891 (m32c_read_flg): Likewise.
2892 (m32c_banked_register): Likewise.
2893 (m32c_banked_read): Likewise.
2894 (m32c_sb_read): Likewise.
2895 (m32c_part_read): Likewise.
2896 (m32c_cat_read): Likewise.
2897 (m32c_r3r2r1r0_read): Likewise.
2898 (m32c_pseudo_register_read): Likewise.
2899 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
2900 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
2901 (mep_pseudo_cr64_read): Likewise.
2902 (mep_pseudo_register_read): Likewise.
2903 * mips-tdep.c (mips_pseudo_register_read): Likewise.
2904 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
2905 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
2906 * regcache.c (regcache::raw_read): Move it to readable_regcache.
2907 (regcache::cooked_read): Likewise.
2908 (regcache::cooked_read_value): Likewise.
2909 (regcache_cooked_read_signed):
2910 (regcache::cooked_read): Likewise.
2911 * regcache.h (readable_regcache): New class.
2912 (regcache): Inherit readable_regcache. Move some methods to
2913 readable_regcache.
2914 * rl78-tdep.c (rl78_pseudo_register_read): Change
2915 parameter type to 'readable_regcache *'.
2916 * rs6000-tdep.c (do_regcache_raw_read): Remove.
2917 (e500_pseudo_register_read): Change parameter type to
2918 'readable_regcache *'.
2919 (dfp_pseudo_register_read): Likewise.
2920 (vsx_pseudo_register_read): Likewise.
2921 (efpr_pseudo_register_read): Likewise.
2922 * s390-tdep.c (s390_pseudo_register_read): Likewise.
2923 * sh-tdep.c (sh_pseudo_register_read): Likewise.
2924 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
2925 (sh64_pseudo_register_read): Likewise.
2926 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
2927 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
2928 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
2929 (spu_pseudo_register_read): Likewise.
2930 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
2931 (xtensa_pseudo_register_read): Likewise.
2932
2933 2018-02-21 Yao Qi <yao.qi@linaro.org>
2934
2935 * regcache.c (regcache::regcache): Call reg_buffer ctor.
2936 (regcache::arch): Move it to reg_buffer::arch.
2937 (regcache::register_buffer): Likewise.
2938 (regcache::assert_regnum): Likewise.
2939 (regcache::num_raw_registers): Likewise.
2940 * regcache.h (reg_buffer): New class.
2941 (regcache): Inherit reg_buffer.
2942
2943 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
2944
2945 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
2946 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
2947
2948 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
2949
2950 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
2951
2952 2018-02-19 Alan Hayward <alan.hayward@arm.com>
2953
2954 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
2955 (SFILES): Remove common/*.c files.
2956 (COMMON_OBS): Remove some *.o files built from common/*.c files.
2957 * common/common.host: Add common reference.
2958 * configure.ac: Likewise.
2959 * configure: Regenerate.
2960
2961 2018-02-16 Yao Qi <yao.qi@linaro.org>
2962
2963 * block.c (block_namespace_info): Inherit allocate_on_obstack.
2964 (block_initialize_namespace): Use new.
2965 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
2966 (dwarf2_free_objfile): Use delete.
2967 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
2968 (copy_type_recursive): Use new.
2969 * gdb_obstack.h (allocate_on_obstack): New.
2970
2971 2018-02-15 Yao Qi <yao.qi@linaro.org>
2972
2973 PR gdb/22849
2974 * inferior.c (exit_inferior_1): Reset inf->control.
2975
2976 2018-02-15 Joel Brobecker <brobecker@adacore.com>
2977
2978 * ada-lang.c (ada_to_fixed_value_create): Delete advance
2979 declaration.
2980
2981 2018-02-14 Pedro Alves <palves@redhat.com>
2982
2983 * frame-unwind.c (frame_unwind_try_unwinder): Always call
2984 frame_cleanup_after_sniffer on exception.
2985
2986 2018-02-14 Tom Tromey <tom@tromey.com>
2987
2988 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
2989 const.
2990 (solib_bfd_open): Make pathname const.
2991 * solib.c (solib_bfd_open): Make pathname const.
2992 * solib-spu.c (spu_bfd_fopen): Make name const.
2993 (spu_bfd_open): Make pathname const.
2994 * solib-darwin.c (darwin_bfd_open): Make pathname const.
2995 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
2996
2997 2018-02-14 Tom Tromey <tom@tromey.com>
2998
2999 * symfile.c (symfile_bfd_open): Update.
3000 * source.h (openp, source_full_path_of, find_and_open_source):
3001 Change argument type to unique_xmalloc_ptr.
3002 * source.c (openp): Take a unique_xmalloc_ptr.
3003 (source_full_path_of, find_and_open_source): Likewise.
3004 (open_source_file, symtab_to_fullname): Update.
3005 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
3006 unique_xmalloc_ptr.
3007 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
3008 (exec_file_find): Update.
3009 * psymtab.c (psymtab_to_fullname): Update.
3010 * nto-tdep.h (nto_find_and_open_solib): Update.
3011 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
3012 unique_xmalloc_ptr.
3013 * exec.c (exec_file_attach): Update.
3014 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
3015 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
3016
3017 2018-02-14 Tom Tromey <tom@tromey.com>
3018
3019 * solib.c: Include source.h.
3020 * nto-tdep.c: Include source.h.
3021 * mi/mi-cmd-env.c: Include source.h.
3022 * infcmd.c: Include source.h.
3023 * exec.c: Include source.h.
3024 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
3025 (add_path, directory_switch, source_path, init_source_path): Move
3026 declarations...
3027 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
3028 (add_path, directory_switch, source_path, init_source_path):
3029 ...here.
3030
3031 2018-02-14 Tom Tromey <tom@tromey.com>
3032
3033 * solist.h (exec_file_find, solib_find): Return
3034 unique_xmalloc_ptr.
3035 (solib_bfd_fopen): Take a const char *.
3036 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
3037 (exec_file_find, solib_find): Likewise.
3038 (solib_bfd_fopen): Do not take ownership of "pathname".
3039 (solib_bfd_open): Use unique_xmalloc_ptr.
3040 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
3041 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
3042 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
3043 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
3044
3045 2018-02-14 Joel Brobecker <brobecker@adacore.com>
3046
3047 * ada-lang.c (name_match_type_from_name): Remove reference to
3048 ada_name_for_lookup in function's documentation.
3049 * ada-lang.h (ada_name_for_lookup): Delete declaration.
3050
3051 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
3052
3053 * defs.h (enum openp_flags): New enum.
3054 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
3055 Move to enum openp_flags.
3056 (openp_flags): New enum flags.
3057 (openp): Change parameter type to openp_flags.
3058 * source.c (openp): Change parameter type to openp_flags.
3059 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
3060 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
3061
3062 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
3063
3064 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
3065 per-command.
3066
3067 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
3068
3069 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
3070 into...
3071 (class dwarf2_queue_guard): ...the destructor of this new class.
3072 (dw2_do_instantiate_symtab): Create instance of the new class
3073 dwarf2_queue_guard, remove cleanup.
3074
3075 2018-02-09 Tom Tromey <tom@tromey.com>
3076
3077 * source.c (find_source_lines): Don't reference past the end of
3078 the vector.
3079
3080 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3081
3082 * remote.c (remote_btrace_maybe_reopen): Change error message.
3083 * btrace.c (btrace_enable): Likewise.
3084 (parse_xml_btrace): Likewise.
3085 (parse_xml_btrace_conf): Likewise.
3086
3087 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3088
3089 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
3090 (linux_enable_pt, linux_enable_bts): Call
3091 diagnose_perf_event_open_fail.
3092
3093 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3094
3095 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
3096 Remove parameter and change return type. Update callers. Move it.
3097 (linux_enable_bts, linux_enable_pt): Improve error message.
3098 (linux_enable_pt): Remove zero buffer size check.
3099 (linux_enable_btrace): Improve error messages. Remove NULL return
3100 check.
3101
3102 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3103
3104 * btrace.c (btrace_enable): Remove target_supports_btrace call.
3105 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
3106 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
3107 (linux_supports_pt, linux_supports_btrace): Remove.
3108 (linux_enable_bts): Call cpu_supports_bts.
3109 * nat/linux-btrace.h (linux_supports_btrace): Remove.
3110 * remote.c (remote_supports_btrace): Remove.
3111 (init_remote_ops): Remove remote_supports_btrace.
3112 * target-delegates.c: Regenerated.
3113 * target.c (target_supports_btrace): Remove.
3114 * target.h (target_ops) <to_supports_btrace>: Remove
3115 (target_supports_btrace): Remove.
3116 * x86-linux-nat.c (x86_linux_create_target): Remove
3117 linux_supports_btrace.
3118
3119 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3120
3121 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
3122 btrace failed.
3123 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
3124 exception and use message in own exception.
3125
3126 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3127
3128 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
3129 (perf_event_pt_event_type): Use gdb_file_up.
3130 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
3131 scoped_fd, and scoped_mmap.
3132
3133 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3134
3135 * common/scoped_mmap.h: New.
3136 * unittests/scoped_mmap-selftest.c: New.
3137 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3138 unittests/scoped_mmap-selftest.c.
3139
3140 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3141
3142 * common/scoped_fd.h: New.
3143 * unittests/scoped_fd-selftest.c: New.
3144 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3145 unittests/scoped_fd-selftest.c.
3146
3147 2018-02-09 Tom Tromey <tom@tromey.com>
3148
3149 * auto-load.c (auto_load_section_scripts): Use
3150 gdb::unique_xmalloc_ptr.
3151
3152 2018-02-09 Tom Tromey <tom@tromey.com>
3153
3154 * auto-load.c (execute_script_contents): Use std::string.
3155
3156 2018-02-09 Joel Brobecker <brobecker@adacore.com>
3157
3158 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
3159 Python function, rather than a new command.
3160
3161 2018-02-08 Tom Tromey <tom@tromey.com>
3162
3163 * solib.c (solib_find_1): Use std::string.
3164 (solib_bfd_fopen): Use unique_xmalloc_ptr.
3165
3166 2018-02-08 Tom Tromey <tom@tromey.com>
3167
3168 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
3169
3170 2018-02-08 Tom Tromey <tom@tromey.com>
3171
3172 * source.c (find_source_lines): Use gdb::def_vector.
3173
3174 2018-02-08 Tom Tromey <tom@tromey.com>
3175
3176 * macrocmd.c (struct temporary_macro_definition): New.
3177 (macro_define_command): Use temporary_macro_definition. Remove
3178 cleanups.
3179 (free_macro_definition_ptr): Remove.
3180
3181 2018-02-08 Tom Tromey <tom@tromey.com>
3182
3183 * macroexp.c (maybe_expand): Use std::string.
3184
3185 2018-02-08 Tom Tromey <tom@tromey.com>
3186
3187 * macroexp.c (struct macro_buffer): Add initializers for some
3188 members.
3189 (init_buffer, init_shared_buffer, free_buffer)
3190 (free_buffer_return_text): Remove.
3191 (macro_buffer): New constructors.
3192 (~macro_buffer): New destructor.
3193 (macro_buffer::set_shared): New method.
3194 (macro_buffer::resize_buffer, macro_buffer::appendc)
3195 (macro_buffer::appendmem): Now methods, not free functions.
3196 (set_token, append_tokens_without_splicing, stringify)
3197 (macro_stringify): Update.
3198 (gather_arguments): Change return type. Remove argc_p argument,
3199 add args_ptr argument. Use std::vector.
3200 (substitute_args): Remove argc argument. Accept std::vector.
3201 (expand): Update. Use std::vector.
3202 (scan, macro_expand, macro_expand_next): Update.
3203
3204 2018-02-08 Tom Tromey <tom@tromey.com>
3205
3206 * symtab.c (default_collect_symbol_completion_matches_break_on):
3207 Use unique_xmalloc_ptr.
3208 * macroscope.h: (sal_macro_scope, user_macro_scope)
3209 (default_macro_scope): Return unique_xmalloc_ptr.
3210 * macroscope.c (sal_macro_scope, user_macro_scope)
3211 (default_macro_scope): Return unique_xmalloc_ptr.
3212 * macroexp.h (macro_expand, macro_expand_once): Return
3213 unique_xmalloc_ptr.
3214 * macroexp.c (macro_expand, macro_expand_once): Return
3215 unique_xmalloc_ptr.
3216 * macrocmd.c (macro_expand_command, macro_expand_once_command)
3217 (info_macro_command, info_macros_command): Use
3218 unique_xmalloc_ptr.
3219 * compile/compile-c-support.c (write_macro_definitions): Use
3220 unique_xmalloc_ptr.
3221 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
3222
3223 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
3224
3225 * value.c (value_static_field): Assign field type instead of
3226 containing type when returning an optimized out value.
3227
3228 2018-02-06 Yao Qi <yao.qi@linaro.org>
3229
3230 * ft32-tdep.c (ft32_read_pc): Remove.
3231 (ft32_write_pc): Remove.
3232 (ft32_gdbarch_init): Update.
3233 * m32r-tdep.c (m32r_read_pc): Remove.
3234 (m32r_gdbarch_init): Update.
3235 * mep-tdep.c (mep_read_pc): Remove.
3236 (mep_gdbarch_init): Update.
3237 * microblaze-tdep.c (microblaze_write_pc): Remove.
3238 (microblaze_gdbarch_init): Update.
3239 * mn10300-tdep.c (mn10300_read_pc): Remove.
3240 (mn10300_write_pc): Remove.
3241 (mn10300_gdbarch_init): Update.
3242 * moxie-tdep.c (moxie_read_pc): Remove.
3243 (moxie_write_pc): Remove.
3244 (moxie_gdbarch_init): Update.
3245
3246 2018-02-06 Yao Qi <yao.qi@linaro.org>
3247
3248 * expprint.c (print_subexp_standard): Handle
3249 OP_F77_UNDETERMINED_ARGLIST.
3250 (dump_subexp_body_standard): Likewise.
3251
3252 2018-02-05 Alan Hayward <alan.hayward@arm.com>
3253
3254 * target-descriptions.c (tdesc_element_visitor) Add empty
3255 implementations.
3256 (tdesc_type): Move make_gdb_type from here.
3257 (tdesc_type_builtin): Likewise.
3258 (tdesc_type_vector): Likewise.
3259 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
3260 (make_gdb_type_struct): Move from tdesc_type_with_fields.
3261 (make_gdb_type_union): Likewise.
3262 (make_gdb_type_flags): Likewise.
3263 (make_gdb_type_enum): Likewise.
3264 (make_gdb_type): New function.
3265 (tdesc_register_type): Use static make_gdb_type.
3266
3267 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
3268
3269 * infcmd.c (default_print_one_register_info): Align natural-format
3270 column values consistently one under another.
3271 (pad_to_column): New function.
3272
3273 2018-02-05 Joel Brobecker <brobecker@adacore.com>
3274
3275 * dwarf2read.c (dwarf2_physname): Move commment.
3276
3277 2018-02-01 Leszek Swirski <leszeks@google.com>
3278
3279 * varobj.c (varobj_formatted_print_options): Allow recursive
3280 pretty printing if pretty printing is enabled.
3281
3282 2018-02-01 Leszek Swirski <leszeks@google.com>
3283
3284 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
3285 names after a structop as a filename.
3286
3287 2018-02-01 Yao Qi <yao.qi@linaro.org>
3288
3289 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
3290 (arm_record_coproc_data_proc): Likewise.
3291
3292 2018-02-01 Yao Qi <yao.qi@linaro.org>
3293
3294 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
3295
3296 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
3297
3298 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
3299 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
3300
3301 2018-01-31 Pedro Alves <palves@redhat.com>
3302
3303 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
3304 * inflow.c (child_terminal_save_inferior): Wrap reference to
3305 tcgetpgrp in HAVE_TERMIOS_H.
3306 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
3307 _WIN32.
3308 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
3309 always iterate over all inferiors.
3310 (gdbsim_cntrl_c): Adjust.
3311 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
3312
3313 2018-01-31 Joel Brobecker <brobecker@adacore.com>
3314
3315 * gdbtypes.c (lookup_array_range_type): Make sure the array's
3316 index type is objfile-owned if the element type is as well.
3317
3318 2018-01-31 Joel Brobecker <brobecker@adacore.com>
3319
3320 GDB 8.1 released.
3321
3322 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
3323
3324 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
3325 "features/s390x-linux64.c".
3326 (_initialize_s390_linux_tdep): Remove initialization of tdescs
3327 s390_linux32 and s390x_linux64.
3328 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
3329 default tdesc.
3330 * s390-tdep.c: Include "features/s390-linux32.c" and
3331 "features/s390x-linux64.c".
3332 (s390_tdesc_valid): Add check for tdesc_has_registers.
3333 (s390_gdbarch_init): Make sure there is always a valid tdesc.
3334 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
3335 tdesc_s390x_linux64.
3336 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
3337 tdesc_s390x_linux64 to...
3338 * s390-tdep.h: ...here.
3339
3340 2018-01-30 Pedro Alves <palves@redhat.com>
3341
3342 PR gdb/13211
3343 * config.in, configure: Regenerate.
3344 * configure.ac: Check for getpgid.
3345 * go32-nat.c (go32_pass_ctrlc): New.
3346 (go32_target): Install it.
3347 * inf-child.c (inf_child_target): Install
3348 child_terminal_save_inferior, child_pass_ctrlc and
3349 child_interrupt.
3350 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
3351 (inf_ptrace_target): No longer install it.
3352 * infcmd.c (interrupt_target_1): Adjust.
3353 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
3354 (child_interrupt): Declare.
3355 (inferior::terminal_state): New.
3356 * inflow.c (struct terminal_info): Update comments.
3357 (inferior_process_group): Delete.
3358 (terminal_is_ours): Delete.
3359 (gdb_tty_state): New.
3360 (child_terminal_init): Adjust.
3361 (is_gdb_terminal, sharing_input_terminal_1)
3362 (sharing_input_terminal): New functions.
3363 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
3364 Set the process's actual process group in the foreground if
3365 possible. Handle is_ours_for_output/is_ours distinction. Don't
3366 mark terminal as the inferior's if not sharing GDB's terminal.
3367 Don't check attach_flag.
3368 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
3369 pass down a target_terminal_state.
3370 (child_terminal_save_inferior): New, factored out from ...
3371 (child_terminal_ours_1): ... this. Handle
3372 target_terminal_state::is_ours_for_output.
3373 (child_interrupt, child_pass_ctrlc): New.
3374 (inflow_inferior_exit): Clear the inferior's terminal_state.
3375 (copy_terminal_info): Copy the inferior's terminal state.
3376 (_initialize_inflow): Remove reference to terminal_is_ours.
3377 * inflow.h (inferior_process_group): Delete.
3378 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
3379 * procfs.c (procfs_target): Don't install procfs_interrupt.
3380 (procfs_interrupt): Delete.
3381 * remote.c (remote_serial_quit_handler): Adjust.
3382 (remote_interrupt): Remove ptid parameter. Adjust.
3383 * target-delegates.c: Regenerate.
3384 * target.c: Include "terminal.h".
3385 (target_terminal::terminal_state): Rename to ...
3386 (target_terminal::m_terminal_state): ... this.
3387 (target_terminal::init): Adjust.
3388 (target_terminal::inferior): Adjust to per-inferior
3389 terminal_state.
3390 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
3391 (target_terminal::ours, target_terminal::ours_for_output): Use
3392 target_terminal_is_ours_kind.
3393 (target_interrupt): Remove ptid parameter. Adjust.
3394 (default_target_pass_ctrlc): Adjust.
3395 * target.h (target_ops::to_terminal_save_inferior): New field.
3396 (target_ops::to_interrupt): Remove ptid_t parameter.
3397 (target_interrupt): Remove ptid_t parameter. Update comment.
3398 (target_pass_ctrlc): Update comment.
3399 * target/target.h (target_terminal_state): New scoped enum,
3400 factored out of ...
3401 (target_terminal::terminal_state): ... here.
3402 (target_terminal::inferior): Update comments.
3403 (target_terminal::restore_inferior): New.
3404 (target_terminal::is_inferior, target_terminal::is_ours)
3405 (target_terminal::is_ours_for_output): Adjust.
3406 (target_terminal::scoped_restore_terminal_state): Adjust to
3407 rename, and call restore_inferior() instead of inferior().
3408 (target_terminal::scoped_restore_terminal_state::m_state): Change
3409 type.
3410 (target_terminal::terminal_state): Rename to ...
3411 (target_terminal::m_terminal_state): ... this and change type.
3412
3413 2018-01-30 Pedro Alves <palves@redhat.com>
3414
3415 * linux-nat.c (wait_for_signal): New function.
3416 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
3417 directly.
3418 (async_terminal_is_ours)
3419 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
3420 (linux_nat_add_target): Don't override
3421 to_terminal_inferior/to_terminal_ours.
3422
3423 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
3424
3425 * remote.c (remote_follow_fork): Don't call "detach_inferior".
3426
3427 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
3428
3429 * dwarf2read.c (free_dwo_files): Add forward-declaration.
3430 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
3431 dwarf2_per_objfile_free here.
3432 (dwarf2_per_objfile_free): Remove.
3433 (_initialize_dwarf2_read): Don't register
3434 dwarf2_per_objfile_free as a registry cleanup.
3435
3436 2018-01-27 Eli Zaretskii <eliz@gnu.org>
3437
3438 Avoid compilation errors in MinGW native builds
3439
3440 The error is triggered by including python-internal.h, and the
3441 error message is:
3442
3443 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
3444 from build-gnulib/import/math.h:27,
3445 from d:/usr/Python26/include/pyport.h:235,
3446 from d:/usr/Python26/include/Python.h:58,
3447 from python/python-internal.h:94,
3448 from python/py-arch.c:24:
3449 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
3450 using ::hypot;
3451 ^~~~~
3452
3453 This happens because Python headers define 'hypot' to expand t
3454 '_hypot' in the Windows builds.
3455 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
3456 'hypoth'. This avoids a compilation error.
3457
3458 2018-01-26 Alan Hayward <alan.hayward@arm.com>
3459
3460 * MAINTAINERS (Write After Approval): Fix ordering.
3461
3462 2018-01-26 Alan Hayward <alan.hayward@arm.com>
3463
3464 * MAINTAINERS (Write After Approval): Add Alan Hayward.
3465
3466 2018-01-26 Alan Modra <amodra@gmail.com>
3467
3468 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
3469 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
3470 Remove nop. Make const. Comment.
3471 (powerpc32_plt_stub_so_2): New.
3472 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
3473 Correct count. Update uses.
3474 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
3475 Move common code reading PLT entry word. Correct
3476 powerpc32_plt_stub PLT address calculation.
3477 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
3478 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
3479 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
3480 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
3481 (ppc64_standard_linkage8): Likewise.
3482 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
3483 Correct insns description.
3484 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
3485
3486 2018-01-24 Pedro Alves <palves@redhat.com>
3487
3488 GCC PR libstdc++/83906
3489 * gdbtypes.c (operator==(const dynamic_prop &,
3490 const dynamic_prop &)): New.
3491 (operator==(const range_bounds &, const range_bounds &)): New.
3492 (check_types_equal): Use them instead of memcmp.
3493 * gdbtypes.h (operator==(const dynamic_prop &,
3494 const dynamic_prop &)): Declare.
3495 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
3496 (operator==(const range_bounds &, const range_bounds &)): Declare.
3497 (operator!=(const range_bounds &, const range_bounds &)): Declare.
3498
3499 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
3500
3501 * s390-linux-tdep.c (s390_record_address_mask)
3502 (s390_record_calc_disp_common, s390_record_calc_disp)
3503 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
3504 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
3505 (s390_process_record): Move to s390-tdep.c.
3506 (s390_linux_init_abi_any): Adjust.
3507 * s390-tdep.c (s390_record_address_mask)
3508 (s390_record_calc_disp_common, s390_record_calc_disp)
3509 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
3510 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
3511 (s390_process_record): Moved from s390-linux-tdep.c
3512 (s390_gdbarch_init): Adjust.
3513
3514 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
3515
3516 * s390-linux-nat.c (s390-tdep.h): New include.
3517 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
3518 (HFILES_NO_SRCDIR): Add s390-tdep.h.
3519 (ALLDEPFILES): Add s390-tdep.c.
3520 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
3521 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
3522 * s390-tdep.h: ...this. New file.
3523 * s390-linux-tdep.c (s390-tdep.h): New include.
3524 (_initialize_s390_tdep): Rename to...
3525 (_initialize_s390_linux_tdep): ...this and adjust.
3526 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
3527 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
3528 s390-tdep.h.
3529 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
3530 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
3531 (s390_is_partial_instruction, s390_software_single_step)
3532 (is_non_branch_ril, s390_displaced_step_copy_insn)
3533 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
3534 (s390_prologue_data, s390_addr, s390_store, s390_load)
3535 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
3536 (s390_register_call_saved, s390_guess_tracepoint_registers)
3537 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
3538 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
3539 (s390_pseudo_register_name, s390_pseudo_register_type)
3540 (s390_pseudo_register_read, s390_pseudo_register_write)
3541 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
3542 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
3543 (s390_addr_bits_remove, s390_address_class_type_flags)
3544 (s390_address_class_type_flags_to_name)
3545 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
3546 (s390_function_arg_float, s390_function_arg_vector)
3547 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
3548 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
3549 (s390_frame_align, s390_register_return_value, s390_return_value)
3550 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
3551 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
3552 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
3553 (s390_trad_frame_prev_register, s390_unwind_cache)
3554 (s390_prologue_frame_unwind_cache)
3555 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
3556 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
3557 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
3558 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
3559 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
3560 (s390_frame_base_address, s390_local_base_address)
3561 (s390_frame_base, s390_gcc_target_options)
3562 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
3563 (s390_validate_reg_range, s390_tdesc_valid)
3564 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
3565 * s390-tdep.c: ...this. New file.
3566
3567 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
3568
3569 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
3570 (s390_process_record, s390_gdbarch_tdep_alloc)
3571 (s390_linux_init_abi_any): Use/set new hook.
3572
3573 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
3574
3575 * s390-linux-tdep.c (osabi.h): New include.
3576 (s390_linux_init_abi_31, s390_linux_init_abi_64)
3577 (s390_linux_init_abi_any): New functions.
3578 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
3579
3580 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
3581
3582 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
3583 tdesc_has_registers check
3584
3585 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
3586
3587 * s390-linux-tdep.c (s390_tdesc_valid): New function.
3588 (s390_validate_reg_range): New macro.
3589 (s390_gdbarch_init): Adjust.
3590
3591 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
3592
3593 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
3594 (s390_gdbarch_tdep_alloc): Adjust.
3595 (s390_gdbarch_init): Adjust.
3596
3597 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
3598
3599 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
3600 <have_tdb>: Change type to bool.
3601 (s390_gdbarch_tdep_alloc): Adjust.
3602 (s390_gdbarch_init): Adjust.
3603
3604 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
3605
3606 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
3607 (gdbarch_tdep) <have_upper, have_vx>: New fields.
3608 (s390_gdbarch_tdep_alloc): New function.
3609 (s390_gdbarch_init): Allocate tdep at start and use its fields
3610 instead of separate variables.
3611
3612 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
3613
3614 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
3615 when looking for cached gdbarch and add comment for remaining.
3616
3617 2018-01-22 Pedro Alves <palves@redhat.com>
3618 Sergio Durigan Junior <sergiodj@redhat.com>
3619
3620 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
3621 case.
3622
3623 2018-01-22 Maciej W. Rozycki <macro@mips.com>
3624
3625 * MAINTAINERS: Update my company e-mail address.
3626
3627 2018-01-22 Yao Qi <yao.qi@linaro.org>
3628
3629 * regcache.c (cooked_write_test): New function.
3630 (_initialize_regcache): Register the test.
3631
3632 2018-01-22 Yao Qi <yao.qi@linaro.org>
3633
3634 * ia64-tdep.c (ia64_pseudo_register_read): Call
3635 regcache->cooked_read instead of regcache_cooked_read_unsigned.
3636 * m32c-tdep.c (m32c_cat_read): Likewise.
3637 (m32c_r3r2r1r0_read): Likewise.
3638 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
3639 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
3640
3641 2018-01-22 Yao Qi <yao.qi@linaro.org>
3642
3643 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
3644 method raw_read instead of regcache_raw_read.
3645 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
3646 * arm-tdep.c (arm_neon_quad_read): Likewise.
3647 * avr-tdep.c (avr_pseudo_register_read): Likewise.
3648 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
3649 * frv-tdep.c (frv_pseudo_register_read): Likewise.
3650 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
3651 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
3652 (i386_pseudo_register_read_into_value): Likewise.
3653 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
3654 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
3655 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
3656 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
3657 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
3658 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
3659 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
3660 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
3661 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
3662
3663 2018-01-22 Yao Qi <yao.qi@linaro.org>
3664
3665 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
3666 * configure.tgt: Remove target mt.
3667 * mt-tdep.c: Remove.
3668 * regcache.c (cooked_read_test): Remove the check for mt.
3669
3670 2018-01-22 Yao Qi <yao.qi@linaro.org>
3671
3672 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
3673 instead of gdbarch_pseudo_register_read_value.
3674
3675 2018-01-22 Joel Brobecker <brobecker@adacore.com>
3676
3677 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
3678 language is Ada.
3679
3680 2018-01-22 Joel Brobecker <brobecker@adacore.com>
3681
3682 * linespec.c (create_sals_line_offset): Remove code that preserved
3683 the symtab_and_line's line number.
3684
3685 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
3686
3687 * varobj.c (varobj_create): Don't set valid_block when creating a
3688 floating varobj.
3689
3690 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
3691
3692 * varobj.c (varobj_create): Remove out of date comment.
3693
3694 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
3695
3696 PR mi/20395
3697 * ada-exp.y (write_var_from_sym): Pass extra parameter when
3698 updating innermost block.
3699 * parse.c (innermost_block_tracker::update): Take extra type
3700 parameter, and check types match before updating innermost block.
3701 (write_dollar_variable): Update innermost block for registers.
3702 * parser-defs.h (enum innermost_block_tracker_type): New enum.
3703 (innermost_block_tracker::innermost_block_tracker): Initialise
3704 m_types member.
3705 (innermost_block_tracker::reset): Take type parameter.
3706 (innermost_block_tracker::update): Take type parameter, and pass
3707 type through as needed.
3708 (innermost_block_tracker::m_types): New member.
3709 * varobj.c (varobj_create): Pass type when reseting innermost
3710 block.
3711
3712 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
3713
3714 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
3715 * ada-lang.c (resolve_subexp): Likewise.
3716 * breakpoint.c (set_breakpoint_condition) Likewise.
3717 (watch_command_1) Likewise.
3718 * c-exp.y (variable): Likewise.
3719 * d-exp.y (PrimaryExpression): Likewise.
3720 * f-exp.y (variable): Likewise.
3721 * go-exp.y (variable): Likewise.
3722 * m2-exp.y (variable): Likewise.
3723 * objfiles.c (objfile::~objfile): Likewise.
3724 * p-exp.y (variable): Likewise.
3725 * parse.c (innermost_block): Change type.
3726 * parser-defs.h (class innermost_block_tracker): New.
3727 (innermost_block): Change to innermost_block_tracker.
3728 * printcmd.c (display_command): Switch to innermost_block API.
3729 (do_one_display): Likewise.
3730 * rust-exp.y (do_one_display): Likewise.
3731 * symfile.c (clear_symtab_users): Likewise.
3732 * varobj.c (varobj_create): Switch to innermost_block API, replace
3733 use of innermost_block with block stored on varobj object.
3734
3735 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
3736
3737 * expression.h (innermost_block): Remove declaration.
3738 * varobj.c: Add 'parser-defs.h' include.
3739
3740 2018-01-19 Tom Tromey <tom@tromey.com>
3741
3742 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
3743 symbols in the static and global blocks.
3744
3745 2018-01-19 James Clarke <jrtc27@jrtc27.com>
3746
3747 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
3748 gdb_ptrace.h, and move including gdb_wait.h ...
3749 * nat/linux-ptrace.h: ... to here.
3750
3751 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
3752
3753 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
3754 inf_ptrace_detach_success.
3755 (inf_ptrace_detach_success): Add inferior parameter, use it
3756 instead of inferior_ptid, pass it to detach_inferior.
3757 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
3758 parameter.
3759 * inferior.c (detach_inferior): Add overload that takes an
3760 inferior object.
3761 * inferior.h (detach_inferior): Likewise.
3762 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
3763 use inferior_ptid, adjust call to inf_ptrace_detach_success.
3764 * linux-thread-db.c (thread_db_detach): Use inf parameter.
3765
3766 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
3767
3768 * target.h (struct target_ops) <to_detach>: Add inferior
3769 parameter.
3770 (target_detach): Likewise.
3771 * target.c (dispose_inferior): Pass inferior down.
3772 (target_detach): Pass inferior down. Assert that it is equal to
3773 the current inferior.
3774 * aix-thread.c (aix_thread_detach): Pass inferior down.
3775 * corefile.c (core_file_command): Pass current_inferior() down.
3776 * corelow.c (core_detach): Add inferior parameter.
3777 * darwin-nat.c (darwin_detach): Likewise.
3778 * gnu-nat.c (gnu_detach): Likewise.
3779 * inf-ptrace.c (inf_ptrace_detach): Likewise.
3780 * infcmd.c (detach_command): Pass current_inferior() down to
3781 target_detach.
3782 * infrun.c (follow_fork_inferior): Pass parent_inf to
3783 target_detach.
3784 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
3785 target_detach.
3786 * linux-nat.c (linux_nat_detach): Add inferior parameter.
3787 * linux-thread-db.c (thread_db_detach): Likewise.
3788 * nto-procfs.c (procfs_detach): Likewise.
3789 * procfs.c (procfs_detach): Likewise.
3790 * record.c (record_detach): Likewise.
3791 * record.h (struct inferior): Forward-declare.
3792 (record_detach): Add inferior parameter.
3793 * remote-sim.c (gdbsim_detach): Likewise.
3794 * remote.c (remote_detach_1): Likewise.
3795 (remote_detach): Likewise.
3796 (extended_remote_detach): Likewise.
3797 * sol-thread.c (sol_thread_detach): Likewise.
3798 * target-debug.h (target_debug_print_inferior_p): New macro.
3799 * target-delegates.c: Re-generate.
3800 * top.c (kill_or_detach): Pass inferior down to target_detach.
3801 * windows-nat.c (windows_detach): Add inferior parameter.
3802
3803 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
3804
3805 * target.h (struct target_ops) <to_detach>: Remove args
3806 parameter.
3807 (target_detach): Likewise.
3808 * target.c (dispose_inferior): Adjust.
3809 (target_detach): Remove args parameter, adjust.
3810 * aix-thread.c (aix_thread_detach): Adjust.
3811 * corefile.c (core_file_command): Adjust.
3812 * corelow.c (core_detach): Adjust.
3813 * darwin-nat.c (darwin_detach): Adjust.
3814 * gnu-nat.c (gnu_detach): Adjust.
3815 * inf-ptrace.c (inf_ptrace_detach): Adjust.
3816 * infcmd.c (detach_command): Adjust
3817 * infrun.c (follow_fork_inferior): Adjust.
3818 (handle_vfork_child_exec_or_exit): Adjust.
3819 * linux-fork.c (linux_fork_detach): Remove args parameter.
3820 * linux-fork.h (linux_fork_detach): Likewise.
3821 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
3822 * linux-thread-db.c (thread_db_detach): Likewise.
3823 * nto-procfs.c (procfs_detach): Likewise.
3824 * procfs.c (procfs_detach): Likewise.
3825 (do_detach): Remove signo parameter.
3826 * record.c (record_detach): Remove args parameter.
3827 * record.h (record_detach): Likewise.
3828 * remote-sim.c (gdbsim_detach): Likewise.
3829 * remote.c (remote_detach_1): Likewise.
3830 (remote_detach): Likewise.
3831 (extended_remote_detach): Likewise.
3832 * sol-thread.c (sol_thread_detach): Likewise.
3833 * target-delegates.c: Re-generate.
3834 * top.c (struct qt_args) <args>: Remove field.
3835 (kill_or_detach): Don't pass args.
3836 (quit_force): Don't set args.
3837 * windows-nat.c (windows_detach): Remove args parameter.
3838
3839 2018-01-19 Yao Qi <yao.qi@linaro.org>
3840
3841 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
3842 (arm_linux_init_abi): Install it.
3843
3844 2018-01-19 Yao Qi <yao.qi@linaro.org>
3845
3846 * osabi.c (gdb_osabi_names): Extend the regexp for
3847 arm-linux-gnueabihf.
3848
3849 2018-01-18 Yao Qi <yao.qi@linaro.org>
3850
3851 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
3852 m_abbrevs.
3853 (abbrev_table::add_abbrev): Update.
3854 (abbrev_table::lookup_abbrev): Update.
3855
3856 2018-01-18 Yao Qi <yao.qi@linaro.org>
3857
3858 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
3859
3860 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
3861
3862 * compile/compile.c (compile_to_object): Convert "triplet_rx"
3863 to "std::string".
3864
3865 2018-01-17 Tom Tromey <tom@tromey.com>
3866
3867 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
3868
3869 2018-01-17 Tom Tromey <tom@tromey.com>
3870
3871 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
3872 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
3873 (create_array_type_with_stride): Update.
3874 * dwarf2read.c (set_die_type): Update.
3875
3876 2018-01-17 Tom Tromey <tom@tromey.com>
3877
3878 * dwarf2read.c (delayed_method_info): Remove typedef.
3879 (dwarf2_cu::method_info): Now a std::vector.
3880 (add_to_method_list): Update.
3881 (free_delayed_list): Remove.
3882 (compute_delayed_physnames): Update.
3883 (process_full_comp_unit, process_full_type_unit): Clear the method
3884 list. Remove cleanups.
3885 (psymtab_include_file_name): Add name_holder parameter. Use
3886 unique_xmalloc_ptr.
3887 (dwarf_decode_lines): Update.
3888
3889 2018-01-17 Tom Tromey <tom@tromey.com>
3890 Simon Marchi <simon.marchi@ericsson.com>
3891
3892 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
3893 (dwarf2_per_objfile::free_cached_comp_units)
3894 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
3895 (init_cutu_and_read_dies_no_follow): Update.
3896 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
3897 (dwarf2_cu::~dwarf2_cu): New.
3898 (free_heap_comp_unit, free_stack_comp_unit): Remove.
3899 (age_cached_comp_units, free_one_cached_comp_unit): Update.
3900
3901 2018-01-17 Tom Tromey <tom@tromey.com>
3902 Simon Marchi <simon.marchi@ericsson.com>
3903
3904 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
3905 (struct die_reader_specs) <abbrev_table>: New member.
3906 (struct abbrev_table): Add constructor.
3907 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
3908 <abbrev_obstack>: Now an auto_obstack.
3909 (abbrev_table_up): New typedef.
3910 (init_cu_die_reader): Add abbrev_table parameter.
3911 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
3912 Add result_dwo_abbrev_table.
3913 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
3914 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
3915 Update.
3916 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
3917 parameter.
3918 (skip_children): Update.
3919 (abbrev_table::alloc_abbrev): Rename from
3920 abbrev_table_alloc_abbrev.
3921 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
3922 (abbrev_table::lookup_abbrev): Rename from
3923 abbrev_table_lookup_abbrev.
3924 (abbrev_table_read_table): Return abbrev_table_up.
3925 (abbrev_table_free, abbrev_table_free_cleanup)
3926 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
3927 (load_partial_dies): Update.
3928
3929 2018-01-17 Tom Tromey <tom@tromey.com>
3930
3931 * dwarf2read.c (dwarf2_compute_name): Update comment.
3932 (read_func_scope, read_variable): Update.
3933 (new_symbol): Remove.
3934 (new_symbol_full): Rename to new_symbol.
3935
3936 2018-01-17 Mike Gulick <mgulick@mathworks.com>
3937
3938 PR gdb/16577
3939 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
3940 a warning instead of throwing an error, set section size to 0 and return
3941 NULL.
3942 * gdb_bfd.h (gdb_bfd_map_section): Update description.
3943
3944 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
3945
3946 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
3947 std::string.
3948 (linux_ptrace_attach_fail_reason_string): Likewise.
3949 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
3950 Likewise.
3951 (linux_ptrace_attach_fail_reason_string): Likewise.
3952 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
3953
3954 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
3955
3956 * linux-nat.c (linux_nat_attach): Remove xstrdup.
3957
3958 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
3959
3960 PR gdb/21559
3961 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
3962 checking for fs_base/gs_base fields in struct user_regs_struct.
3963 * configure: Regenerate.
3964
3965 2018-01-17 Yao Qi <yao.qi@linaro.org>
3966
3967 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
3968 function.
3969 (aarch64_linux_init_abi): Install it to gdbarch hook
3970 gcc_target_options.
3971
3972 2018-01-15 Pedro Alves <palves@redhat.com>
3973
3974 * common/signals-state-save-restore.c
3975 (save_original_signals_state): Fix typos.
3976
3977 2017-01-12 Tom Tromey <tom@tromey.com>
3978 Sergio Durigan Junior <sergiodj@redhat.com>
3979
3980 * Makefile.in (install-only): Install gdb-add-index.
3981
3982 2018-01-12 John Baldwin <jhb@FreeBSD.org>
3983
3984 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
3985
3986 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
3987
3988 * infrun.c (keep_going_pass_signal): Clear step-over info when
3989 insert_breakpoints fails.
3990
3991 2018-01-11 Pedro Alves <palves@redhat.com>
3992
3993 PR gdb/22583
3994 * infrun.c (resume): Rename to ...
3995 (resume_1): ... this.
3996 (resume): Reimplement as wrapper around resume_1.
3997
3998 2018-01-11 Pedro Alves <palves@redhat.com>
3999
4000 PR remote/22597
4001 * remote.c (remote_parse_stop_reply): Default to the last-set
4002 general thread instead of to 'magic_null_ptid'.
4003
4004 2018-01-10 Pedro Alves <palves@redhat.com>
4005
4006 * language.h (language_get_symbol_name_matcher): Rename ...
4007 (get_symbol_name_matcher): ... this.
4008 * language.c (language_get_symbol_name_matcher): Ditto.
4009 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
4010 callers adjusted.
4011
4012 2018-01-10 Pedro Alves <palves@redhat.com>
4013
4014 PR gdb/22670
4015 * dwarf2read.c
4016 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
4017 Adjust to use language_get_symbol_name_matcher instead of
4018 language_defn::la_get_symbol_name_matcher.
4019 * language.c (language_get_symbol_name_matcher): If in Ada mode
4020 and the lookup name is a verbatim match, return Ada's matcher.
4021 * language.h (language_get_symbol_name_matcher): Adjust comment.
4022 (ada_lookup_name_info::verbatim_p):: New method.
4023
4024 2018-01-10 Pedro Alves <palves@redhat.com>
4025
4026 PR gdb/22670
4027 * ada-lang.c (ada_collect_symbol_completion_matches): If the
4028 minsym's language is language_auto or language_cplus, pass down
4029 language_ada instead.
4030 * symtab.c (compare_symbol_name): Don't frob symbol language here.
4031
4032 2018-01-10 Pedro Alves <palves@redhat.com>
4033
4034 PR gdb/22670
4035 * minsyms.c (linkage_name_str): New function.
4036 (iterate_over_minimal_symbols): Use it.
4037
4038 2018-01-09 John Baldwin <jhb@FreeBSD.org>
4039
4040 * NEWS: Document that 'info proc' now works on FreeBSD.
4041
4042 2018-01-09 John Baldwin <jhb@FreeBSD.org>
4043
4044 * configure.ac: Check for kinfo_getfile in libutil.
4045 * configure: Regenerate.
4046 * config.in: Regenerate.
4047 * fbsd-nat.c: Include "fbsd-tdep.h".
4048 (fbsd_fetch_cmdline): New.
4049 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
4050 rather than calling error.
4051 (fbsd_info_proc): New.
4052 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
4053 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
4054 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
4055
4056 2018-01-09 John Baldwin <jhb@FreeBSD.org>
4057
4058 * fbsd-nat.c (struct free_deleter): Remove.
4059 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
4060
4061 2018-01-09 John Baldwin <jhb@FreeBSD.org>
4062
4063 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
4064 NULL for an empty pathname.
4065
4066 2018-01-09 John Baldwin <jhb@FreeBSD.org>
4067
4068 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
4069 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
4070 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
4071 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
4072 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
4073 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
4074 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
4075 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
4076 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
4077 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
4078 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
4079 (fbsd_core_fetch_timeval, fbsd_print_sigset)
4080 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
4081 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
4082 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
4083
4084 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
4085
4086 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
4087 (gnu_xfer_auxv): New function.
4088 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
4089 TARGET_OBJECT_AUXV.
4090
4091 2018-01-08 Yao Qi <yao.qi@linaro.org>
4092 Simon Marchi <simon.marchi@ericsson.com>
4093
4094 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
4095 common/selftest.c.
4096 (COMMON_OBS): Remove selftest.o.
4097 * configure.ac: Append selftest-arch.c and common/selftest.c to
4098 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
4099 * configure: Re-generated.
4100 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
4101 GDB_SELF_TEST.
4102 (maintenance_info_selftests): Likewise.
4103
4104 2018-01-08 Xavier Roirand <roirand@adacore.com>
4105
4106 * ada-valprint.c (val_print_packed_array_elements): Use
4107 proper number of elements when printing an array indexed
4108 by an enumeration type.
4109
4110 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
4111
4112 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
4113 (dw2_get_file_names_reader): Adjust.
4114 (lookup_dwo_signatured_type): Adjust.
4115 (lookup_dwp_signatured_type): Adjust.
4116 (lookup_signatured_type): Adjust.
4117 (create_type_unit_group): Adjust.
4118 (get_type_unit_group): Adjust.
4119 (process_psymtab_comp_unit_reader): Adjust.
4120 (build_type_psymtabs_reader): Adjust.
4121 (scan_partial_symbols): Adjust.
4122 (add_partial_symbol): Adjust.
4123 (add_partial_subprogram): Adjust.
4124 (peek_die_abbrev): Adjust.
4125 (fixup_go_packaging): Adjust.
4126 (process_imported_unit_die): Adjust.
4127 (dwarf2_compute_name): Adjust.
4128 (dwarf2_physname): Adjust.
4129 (read_import_statement): Adjust.
4130 (handle_DW_AT_stmt_list): Adjust.
4131 (read_file_scope): Adjust.
4132 (read_func_scope): Adjust.
4133 (read_lexical_block_scope): Adjust.
4134 (read_call_site_scope): Adjust.
4135 (read_variable): Adjust.
4136 (dwarf2_rnglists_process): Adjust.
4137 (dwarf2_ranges_process): Adjust.
4138 (dwarf2_ranges_read): Adjust.
4139 (dwarf2_get_pc_bounds): Adjust.
4140 (dwarf2_record_block_ranges): Adjust.
4141 (dwarf2_add_field): Adjust.
4142 (dwarf2_add_member_fn): Adjust.
4143 (read_structure_type): Adjust.
4144 (process_structure_scope): Adjust.
4145 (read_enumeration_type): Adjust.
4146 (read_array_type): Adjust.
4147 (mark_common_block_symbol_computed): Adjust.
4148 (read_common_block): Adjust.
4149 (read_namespace_type): Adjust.
4150 (read_namespace): Adjust.
4151 (read_module_type): Adjust.
4152 (read_tag_pointer_type): Adjust.
4153 (read_tag_ptr_to_member_type): Adjust.
4154 (read_tag_string_type): Adjust.
4155 (read_subroutine_type): Adjust.
4156 (read_typedef): Adjust.
4157 (read_base_type): Adjust.
4158 (attr_to_dynamic_prop): Adjust.
4159 (read_subrange_type): Adjust.
4160 (read_unspecified_type): Adjust.
4161 (dwarf2_read_abbrevs): Adjust.
4162 (load_partial_dies): Adjust.
4163 (read_partial_die): Adjust.
4164 (find_partial_die): Adjust.
4165 (guess_partial_die_structure_name): Adjust.
4166 (fixup_partial_die): Adjust.
4167 (read_attribute_value): Adjust.
4168 (read_addr_index): Adjust.
4169 (read_addr_index_from_leb128): Adjust.
4170 (read_str_index): Adjust.
4171 (dwarf2_string_attr): Adjust.
4172 (get_debug_line_section): Adjust.
4173 (dwarf_decode_line_header): Adjust.
4174 (lnp_state_machine::check_line_address): Adjust.
4175 (dwarf_decode_lines_1): Adjust.
4176 (dwarf_decode_lines): Adjust.
4177 (dwarf2_start_symtab): Adjust.
4178 (var_decode_location): Adjust.
4179 (new_symbol_full): Adjust.
4180 (dwarf2_const_value_data): Adjust.
4181 (dwarf2_const_value_attr): Adjust.
4182 (dwarf2_const_value): Adjust.
4183 (die_type): Adjust.
4184 (die_containing_type): Adjust.
4185 (build_error_marker_type): Adjust.
4186 (lookup_die_type): Adjust.
4187 (guess_full_die_structure_name): Adjust.
4188 (anonymous_struct_prefix): Adjust.
4189 (determine_prefix): Adjust.
4190 (dwarf2_name): Adjust.
4191 (follow_die_ref_or_sig): Adjust.
4192 (follow_die_offset): Adjust.
4193 (follow_die_ref): Adjust.
4194 (follow_die_sig_1): Adjust.
4195 (follow_die_sig): Adjust.
4196 (get_signatured_type): Adjust.
4197 (get_DW_AT_signature_type): Adjust.
4198 (decode_locdesc): Adjust.
4199 (dwarf_decode_macros): Adjust.
4200 (cu_debug_loc_section): Adjust.
4201 (fill_in_loclist_baton): Adjust.
4202 (dwarf2_symbol_mark_computed): Adjust.
4203 (init_one_comp_unit): Don't assign
4204 dwarf2_cu::dwarf2_per_objfile.
4205 (set_die_type): Adjust.
4206
4207 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
4208
4209 * dwarf2read.c (struct mapped_debug_names): Add constructor.
4210 <dwarf2_per_objfile>: New field.
4211 (dwarf2_per_objfile): Remove global.
4212 (get_dwarf2_per_objfile): New function.
4213 (set_dwarf2_per_objfile): New function.
4214 (dwarf2_build_psymtabs_hard): Change objfile parameter to
4215 dwarf2_per_objfile.
4216 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
4217 (read_abbrev_offset): Likewise.
4218 (read_indirect_string): Likewise.
4219 (read_indirect_line_string): Likewise.
4220 (read_indirect_string_at_offset): Likewise.
4221 (read_indirect_string_from_dwz): Likewise.
4222 (dwarf2_find_containing_comp_unit): Change objfile parameter to
4223 dwarf2_per_objfile.
4224 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
4225 (create_all_comp_units): Change objfile parameter to
4226 dwarf2_per_objfile.
4227 (create_all_type_units): Likewise.
4228 (process_queue): Add dwarf2_per_objfile parameter.
4229 (read_and_check_comp_unit_head): Likewise.
4230 (lookup_dwo_unit_in_dwp): Likewise.
4231 (get_dwp_file): Likewise.
4232 (process_cu_includes): Likewise.
4233 (struct free_dwo_file_cleanup_data): New struct.
4234 (dwarf2_has_info): Use get_dwarf2_per_objfile and
4235 set_dwarf2_per_objfile.
4236 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
4237 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
4238 context, adjust calls.
4239 (dw2_instantiate_symtab): Likewise.
4240 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
4241 (dw2_get_cu): Likewise.
4242 (create_cu_from_index_list): Change objfile parameter to
4243 dwarf2_per_objfile.
4244 (create_cus_from_index_list): Get dwarf2_per_objfile from
4245 context, adjust calls.
4246 (create_cus_from_index): Likewise.
4247 (create_signatured_type_table_from_index): Change objfile
4248 parameter to dwarf2_per_objfile.
4249 (create_signatured_type_table_from_debug_names): Change objfile
4250 parameter to dwarf2_per_objfile.
4251 (create_addrmap_from_index): Likewise.
4252 (create_addrmap_from_aranges): Likewise.
4253 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
4254 (dw2_setup): Remove.
4255 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
4256 context.
4257 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
4258 get_dwarf2_per_objfile.
4259 (dw2_forget_cached_source_info): Likewise.
4260 (dw2_map_symtabs_matching_filename): Likewise.
4261 (struct dw2_symtab_iterator) <index>: Remove.
4262 <dwarf2_per_objfile>: New field.
4263 (dw2_symtab_iter_init): Replace index parameter with
4264 dwarf2_per_objfile.
4265 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
4266 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
4267 (dw2_print_stats): Likewise.
4268 (dw2_dump): Likewise.
4269 (dw2_expand_symtabs_for_function): Likewise.
4270 (dw2_expand_all_symtabs): Likewise.
4271 (dw2_expand_symtabs_with_fullname): Likewise.
4272 (dw2_expand_marked_cus): Replace index and objfile parameters
4273 with dwarf2_per_objfile.
4274 (dw_expand_symtabs_matching_file_matcher): Add
4275 dwarf2_per_objfile parameter and adjust calls.
4276 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
4277 adjust calls.
4278 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
4279 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
4280 adjust calls.
4281 (create_cus_from_debug_names_list): Replace objfile parameter
4282 with dwarf2_per_objfile and adjust calls.
4283 (create_cus_from_debug_names): Likewise.
4284 (dwarf2_read_debug_names): Likewise.
4285 (mapped_debug_names::namei_to_name): Adjust call.
4286 (dw2_debug_names_iterator::next): Likewise.
4287 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
4288 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
4289 (dw2_debug_names_dump): Likewise.
4290 (dw2_debug_names_expand_symtabs_for_function): Likewise.
4291 (dw2_debug_names_expand_symtabs_matching): Likewise.
4292 (dwarf2_initialize_objfile): Likewise.
4293 (dwarf2_build_psymtabs): Likewise.
4294 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
4295 this_cu.
4296 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
4297 (read_and_check_comp_unit_head): Likewise.
4298 (read_abbrev_offset): Likewise.
4299 (create_debug_type_hash_table): Likewise.
4300 (create_debug_types_hash_table): Likewise.
4301 (create_all_type_units): Replace objfile parameter with
4302 dwarf2_per_objfile.
4303 (add_type_unit): Add dwarf2_per_objfile parameter.
4304 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
4305 with dwarf2_per_objfile.
4306 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
4307 (lookup_dwp_signatured_type): Likewise.
4308 (lookup_signatured_type): Likewise.
4309 (read_cutu_die_from_dwo): Likewise.
4310 (init_tu_and_read_dwo_dies): Likewise.
4311 (init_cutu_and_read_dies): Likewise.
4312 (init_cutu_and_read_dies_no_follow): Likewise.
4313 (allocate_type_unit_groups_table): Add objfile parameter.
4314 (create_type_unit_group): Use dwarf2_per_objfile from cu.
4315 (get_type_unit_group): Likewise.
4316 (process_psymtab_comp_unit): Update call.
4317 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
4318 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
4319 (print_tu_stats): Likewise.
4320 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
4321 in void* parameter.
4322 (build_type_psymtabs): Change objfile parameter to
4323 dwarf2_per_objfile.
4324 (process_skeletonless_type_unit): Use dwarf2_per_objfile
4325 passed in void* parameter.
4326 (process_skeletonless_type_units): Change objfile parameter to
4327 dwarf2_per_objfile.
4328 (set_partial_user): Likewise.
4329 (dwarf2_build_psymtabs_hard): Likewise.
4330 (read_comp_units_from_section): Likewise.
4331 (create_all_comp_units): Likewise.
4332 (scan_partial_symbols): Update calls.
4333 (add_partial_symbol): Likewise.
4334 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
4335 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
4336 (process_queue): Add dwarf2_per_objfile parameter.
4337 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
4338 (compute_compunit_symtab_includes): Likewise.
4339 (process_cu_includes): Add dwarf2_per_objfile parameter.
4340 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
4341 (process_full_type_unit): Likewise.
4342 (process_imported_unit_die): Update call.
4343 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
4344 (read_file_scope): Likewise.
4345 (allocate_dwo_file_hash_table): Add objfile parameter.
4346 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
4347 (create_cus_hash_table): Likewise.
4348 (create_dwp_hash_table): Likewise.
4349 (create_dwo_unit_in_dwp_v1): Likewise.
4350 (create_dwp_v2_section): Likewise.
4351 (create_dwo_unit_in_dwp_v2): Likewise.
4352 (lookup_dwo_unit_in_dwp): Likewise.
4353 (try_open_dwop_file): Likewise.
4354 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
4355 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
4356 cleanup to include a reference to dwarf2_per_objfile.
4357 (open_dwp_file): Add dwarf2_per_objfile parameter.
4358 (open_and_init_dwp_file): Likewise.
4359 (get_dwp_file): Likewise.
4360 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
4361 (queue_and_load_all_dwo_tus): Update call.
4362 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
4363 data.
4364 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
4365 (dwarf2_ranges_process): Likewise.
4366 (dwarf2_get_pc_bounds): Likewise.
4367 (mark_common_block_symbol_computed): Likewise.
4368 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
4369 (dwarf2_read_abbrevs): Update call.
4370 (read_partial_die): Use dwarf2_per_objfile from cu.
4371 (find_partial_die): Likewise.
4372 (fixup_partial_die): Likewise.
4373 (read_attribute_value): Likewise.
4374 (read_indirect_string_at_offset_from): Add objfile parameter.
4375 (read_indirect_string_at_offset): Add dwarf2_per_objfile
4376 parameter.
4377 (read_indirect_string_from_dwz): Add objfile parameter.
4378 (read_indirect_string): Add objfile parameter.
4379 (read_addr_index_1): Add dwarf2_per_objfile parameter.
4380 (read_addr_index): Use dwarf2_per_objfile from cu.
4381 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
4382 call dw2_setup.
4383 (read_str_index): Use dwarf2_per_objfile from cu.
4384 (get_debug_line_section): Likewise.
4385 (read_formatted_entries): Add dwarf2_per_objfile parameter.
4386 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
4387 (new_symbol_full): Use dwarf2_per_objfile from cu.
4388 (build_error_marker_type): Likewise.
4389 (lookup_die_type): Likewise.
4390 (determine_prefix): Likewise.
4391 (follow_die_offset): Likewise.
4392 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
4393 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
4394 (dwarf2_fetch_die_type_sect_off): Likewise.
4395 (dwarf2_get_die_type): Likewise.
4396 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
4397 (get_signatured_type): Likewise.
4398 (get_DW_AT_signature_type): Likewise.
4399 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
4400 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
4401 (cu_debug_loc_section): Likewise.
4402 (fill_in_loclist_baton): Likewise.
4403 (dwarf2_symbol_mark_computed): Likewise.
4404 (dwarf2_find_containing_comp_unit): Change objfile parameter to
4405 dwarf2_per_objfile.
4406 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
4407 parameter.
4408 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
4409 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
4410 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
4411 (set_die_type): Use dwarf2_free_objfile from cu.
4412 (get_die_type_at_offset): Likewise.
4413 (dwarf2_per_objfile_free): Don't assign global variable.
4414 (debug_names) <constructor>: Add dwarf2_per_objfile
4415 parameter, update m_debugstrlookup construction.
4416 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
4417 parameter.
4418 <m_dwarf2_per_objfile>: New field.
4419 <lookup>: Use m_dwarf2_per_objfile.
4420 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
4421 (psyms_seen_size): Likewise.
4422 (write_gdbindex): Replace objfile parameter with
4423 dwarf2_per_objfile.
4424 (write_debug_names): Likewise.
4425 (write_psymtabs_to_index): Likewise.
4426 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
4427 calls.
4428
4429 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
4430
4431 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
4432 <dwarf2_per_objfile>: New field.
4433 (struct dwarf2_per_cu_data) <objfile>: Remove.
4434 <dwarf2_per_objfile>: New field.
4435 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
4436 of objfile.
4437 (create_signatured_type_table_from_index): Likewise.
4438 (create_debug_type_hash_table): Likewise.
4439 (fill_in_sig_entry_from_dwo_entry): Likewise.
4440 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
4441 (create_type_unit_group): Assign dwarf2_per_objfile instead of
4442 objfile.
4443 (create_partial_symtab): Access objfile through
4444 dwarf2_per_objfile.
4445 (process_psymtab_comp_unit_reader): Likewise.
4446 (read_comp_units_from_section): Likewise.
4447 (scan_partial_symbols): Likewise.
4448 (add_partial_symbol): Likewise.
4449 (add_partial_subprogram): Likewise.
4450 (peek_die_abbrev): Likewise.
4451 (fixup_go_packaging): Likewise.
4452 (process_full_comp_unit): Likewise.
4453 (process_full_type_unit): Likewise.
4454 (process_imported_unit_die): Likewise.
4455 (dwarf2_compute_name): Likewise.
4456 (dwarf2_physname): Likewise.
4457 (read_import_statement): Likewise.
4458 (create_cus_hash_table): Assign dwarf2_physname instead of
4459 objfile.
4460 (read_func_scope): Access objfile through dwarf2_per_objfile.
4461 (read_lexical_block_scope): Likewise.
4462 (read_call_site_scope): Likewise.
4463 (read_variable): Likewise.
4464 (dwarf2_rnglists_process): Likewise.
4465 (dwarf2_ranges_process): Likewise.
4466 (dwarf2_ranges_read): Likewise.
4467 (dwarf2_record_block_ranges): Likewise.
4468 (dwarf2_add_field): Likewise.
4469 (dwarf2_add_member_fn): Likewise.
4470 (read_structure_type): Likewise.
4471 (process_structure_scope): Likewise.
4472 (read_enumeration_type): Likewise.
4473 (read_array_type): Likewise.
4474 (read_common_block): Likewise.
4475 (read_namespace_type): Likewise.
4476 (read_namespace): Likewise.
4477 (read_module_type): Likewise.
4478 (read_tag_pointer_type): Likewise.
4479 (read_tag_ptr_to_member_type): Likewise.
4480 (read_tag_string_type): Likewise.
4481 (read_subroutine_type): Likewise.
4482 (read_typedef): Likewise.
4483 (read_base_type): Likewise.
4484 (attr_to_dynamic_prop): Likewise.
4485 (read_subrange_type): Likewise.
4486 (read_unspecified_type): Likewise.
4487 (load_partial_dies): Likewise.
4488 (read_partial_die): Likewise.
4489 (find_partial_die): Likewise.
4490 (guess_partial_die_structure_name): Likewise.
4491 (fixup_partial_die): Likewise.
4492 (read_attribute_value): Likewise.
4493 (read_addr_index_from_leb128): Likewise.
4494 (dwarf2_read_addr_index): Likewise.
4495 (dwarf2_string_attr): Likewise.
4496 (lnp_state_machine::check_line_address): Likewise.
4497 (dwarf_decode_lines_1): Likewise.
4498 (dwarf_decode_lines): Likewise.
4499 (dwarf2_start_symtab): Likewise.
4500 (var_decode_location): Likewise.
4501 (new_symbol_full): Likewise.
4502 (dwarf2_const_value_data): Likewise.
4503 (dwarf2_const_value_attr): Likewise.
4504 (dwarf2_const_value): Likewise.
4505 (die_type): Likewise.
4506 (die_containing_type): Likewise.
4507 (lookup_die_type): Likewise.
4508 (guess_full_die_structure_name): Likewise.
4509 (anonymous_struct_prefix): Likewise.
4510 (dwarf2_name): Likewise.
4511 (follow_die_ref_or_sig): Likewise.
4512 (follow_die_offset): Likewise.
4513 (follow_die_ref): Likewise.
4514 (dwarf2_fetch_die_loc_sect_off): Likewise.
4515 (dwarf2_fetch_constant_bytes): Likewise.
4516 (dwarf2_fetch_die_type_sect_off): Likewise.
4517 (dwarf2_get_die_type): Likewise.
4518 (follow_die_sig): Likewise.
4519 (decode_locdesc): Likewise.
4520 (dwarf2_per_cu_objfile): Likewise.
4521 (dwarf2_per_cu_text_offset): Likewise.
4522 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
4523 objfile.
4524 (set_die_type): Access objfile through
4525 dwarf2_per_objfile.
4526
4527 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
4528
4529 * valprint.c (converted_character_d): Remove typedef.
4530 (DEF_VEC_O (converted_character_d)): Remove.
4531 (count_next_character): Use std::vector.
4532 (print_converted_chars_to_obstack): Likewise.
4533 (generic_printstr): Likewise.
4534
4535 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
4536
4537 * xml-support.h (struct gdb_xml_value): Add constructor.
4538 <value>: Change type to unique_xmalloc_ptr.
4539 (gdb_xml_value_s): Remove typedef.
4540 (DEF_VEC_O (gdb_xml_value_s)): Remove.
4541 (gdb_xml_element_start_handler): Change parameter type to
4542 std::vector.
4543 (xml_find_attribute): Likewise.
4544 * xml-support.c (xml_find_attribute): Change parameter type to
4545 std::vector and adjust.
4546 (gdb_xml_values_cleanup): Remove.
4547 (gdb_xml_parser::start_element): Adjust to std::vector.
4548 (xinclude_start_include): Change paraeter type to std::vector
4549 and adjust.
4550 * btrace.c (check_xml_btrace_version): Likewise.
4551 (parse_xml_btrace_block): Likewise.
4552 (parse_xml_btrace_pt_config_cpu): Likewise.
4553 (parse_xml_btrace_pt): Likewise.
4554 (parse_xml_btrace_conf_bts): Likewise.
4555 (parse_xml_btrace_conf_pt): Likewise.
4556 * memory-map.c (memory_map_start_memory): Likewise.
4557 (memory_map_start_property): Likewise.
4558 * osdata.c (osdata_start_osdata): Likewise.
4559 (osdata_start_item): Likewise.
4560 (osdata_start_column): Likewise.
4561 * remote.c (start_thread): Likewise.
4562 * solib-aix.c (library_list_start_library): Likewise.
4563 (library_list_start_list): Likewise.
4564 * solib-svr4.c (library_list_start_library): Likewise.
4565 (svr4_library_list_start_list): Likewise.
4566 * solib-target.c (library_list_start_segment): Likewise.
4567 (library_list_start_section): Likewise.
4568 (library_list_start_library): Likewise.
4569 (library_list_start_list): Likewise.
4570 * tracepoint.c (traceframe_info_start_memory): Likewise.
4571 (traceframe_info_start_tvar): Likewise.
4572 * xml-syscall.c (syscall_start_syscall): Likewise.
4573 * xml-tdesc.c (tdesc_start_target): Likewise.
4574 (tdesc_start_feature): Likewise.
4575 (tdesc_start_reg): Likewise.
4576 (tdesc_start_union): Likewise.
4577 (tdesc_start_struct): Likewise.
4578 (tdesc_start_flags): Likewise.
4579 (tdesc_start_enum): Likewise.
4580 (tdesc_start_field): Likewise.
4581 (tdesc_start_enum_value): Likewise.
4582 (tdesc_start_vector): Likewise.
4583
4584 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
4585
4586 * extension.h (struct xmethod_worker) <clone>: Remove.
4587 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
4588 Remove.
4589 (python_xmethod_worker::clone): Remove.
4590 * valops.c (find_overload_match): Use std::move instead of
4591 clone.
4592
4593 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
4594
4595 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
4596 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
4597 <free_xmethod_worker_data>: Remove.
4598 <get_matching_xmethod_workers>: Chance VEC to std::vector.
4599 <get_xmethod_arg_types>: Remove.
4600 <get_xmethod_result_type>: Remove.
4601 <invoke_xmethod>: Remove.
4602 * extension.c (new_xmethod_worker): Remove.
4603 (clone_xmethod_worker): Remove.
4604 (get_matching_xmethod_workers): Return void, pass std::vector by
4605 pointer.
4606 (get_xmethod_arg_types): Rename to...
4607 (xmethod_worker::get_arg_types): ... this, and adjust.
4608 (get_xmethod_result_type): Rename to...
4609 (xmethod_worker::get_result_type): ... this, and adjust.
4610 (invoke_xmethod): Remove.
4611 (free_xmethod_worker): Remove.
4612 (free_xmethod_worker_vec): Remove.
4613 * extension.h (enum ext_lang_rc): Move here from
4614 extension-priv.h.
4615 (struct xmethod_worker): Add constructor and destructor.
4616 <data>: Remove.
4617 <value>: Remove.
4618 <invoke, clone, do_get_result_type, do_get_arg_types>: New
4619 virtual pure methods.
4620 <get_arg_types, get_result_type>: New methods.
4621 (xmethod_worker_ptr): Remove typedef.
4622 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
4623 (xmethod_worker_vec): Remove typedef.
4624 (xmethod_worker_up): New typedef.
4625 (invoke_xmethod): Remove.
4626 (clone_xmethod_worker): Remove.
4627 (free_xmethod_worker): Remove.
4628 (free_xmethod_worker_vec): Remove.
4629 (get_xmethod_arg_types): Remove.
4630 (get_xmethod_result_type): Remove.
4631 * valops.c (find_method_list): Use std::vector, don't use
4632 intermediate vector.
4633 (value_find_oload_method_list): Use std::vector.
4634 (find_overload_match): Use std::vector.
4635 (find_oload_champ): Use std::vector.
4636 * value.c (value_free): Use operator delete.
4637 (value_of_xmethod): Rename to...
4638 (value_from_xmethod): ... this. Don't assign
4639 xmethod_worker::value, take rvalue-reference.
4640 (result_type_of_xmethod): Adjust.
4641 (call_xmethod): Adjust.
4642 * value.h: Include extension.h.
4643 (struct xmethod_worker): Don't forward-declare.
4644 (value_of_xmethod): Rename to...
4645 (value_from_xmethod): ... this, take rvalue-reference.
4646 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
4647 (struct python_xmethod_worker): ... this, add constructor and
4648 destructor.
4649 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
4650 (gdbpy_free_xmethod_worker_data): Rename to...
4651 (python_xmethod_worker::~python_xmethod_worker): ... this and
4652 adjust.
4653 (gdbpy_clone_xmethod_worker_data): Rename to...
4654 (python_xmethod_worker::clone): ... this and adjust.
4655 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
4656 temporary vector.
4657 (gdbpy_get_xmethod_arg_types): Rename to...
4658 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
4659 (gdbpy_get_xmethod_result_type): Rename to...
4660 (python_xmethod_worker::do_get_result_type): ... this and
4661 adjust.
4662 (gdbpy_invoke_xmethod): Rename to...
4663 (python_xmethod_worker::invoke): ... this and adjust.
4664 (new_python_xmethod_worker): Rename to...
4665 (python_xmethod_worker::python_xmethod_worker): ... this and
4666 adjust.
4667 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
4668 Remove.
4669 (gdbpy_free_xmethod_worker_data): Remove.
4670 (gdbpy_get_matching_xmethod_workers): Use std::vector.
4671 (gdbpy_get_xmethod_arg_types): Remove.
4672 (gdbpy_get_xmethod_result_type): Remove.
4673 (gdbpy_invoke_xmethod): Remove.
4674 * python/python.c (python_extension_ops): Remove obsolete
4675 callbacks.
4676
4677 2018-01-05 Pedro Alves <palves@redhat.com>
4678
4679 PR gdb/18653
4680 * common/signals-state-save-restore.c
4681 (save_original_signals_state): New parameter 'quiet'. Warn if we
4682 find a custom handler preinstalled, instead of internal erroring.
4683 But only warn if !quiet.
4684 * common/signals-state-save-restore.h
4685 (save_original_signals_state): New parameter 'quiet'.
4686 * main.c (captured_main_1): Move save_original_signals_state call
4687 after option handling, and pass QUIET.
4688
4689 2018-01-05 Pedro Alves <palves@redhat.com>
4690
4691 * spu-tdep.c (spu_catch_start): Pass
4692 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
4693
4694 2018-01-05 Pedro Alves <palves@redhat.com>
4695
4696 PR gdb/22670
4697 * ada-lang.c (literal_symbol_name_matcher): New function.
4698 (ada_get_symbol_name_matcher): Use it for
4699 symbol_name_match_type::SEARCH_NAME.
4700 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
4701 it down instead of assuming symbol_name_match_type::FULL.
4702 * block.h (block_lookup_symbol): New parameter 'match_type'.
4703 * c-valprint.c (print_unpacked_pointer): Use
4704 lookup_symbol_search_name instead of lookup_symbol.
4705 * compile/compile-object-load.c (get_out_value_type): Pass down
4706 symbol_name_match_type::SEARCH_NAME.
4707 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
4708 symbol_name_match_type::FULL.
4709 * cp-support.c (cp_get_symbol_name_matcher): Handle
4710 symbol_name_match_type::SEARCH_NAME.
4711 * infrun.c (insert_exception_resume_breakpoint): Use
4712 lookup_symbol_search_name.
4713 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
4714 * psymtab.c (maintenance_check_psymtabs): Use
4715 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
4716 * stack.c (print_frame_args): Use lookup_symbol_search_name and
4717 SYMBOL_SEARCH_NAME.
4718 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
4719 if symbol_name_match_type::SEARCH_NAME.
4720 (lookup_symbol_in_language): Pass down
4721 symbol_name_match_type::FULL.
4722 (lookup_symbol_search_name): New.
4723 (lookup_language_this): Pass down
4724 symbol_name_match_type::SEARCH_NAME.
4725 (lookup_symbol_aux, lookup_local_symbol): New parameter
4726 'match_type'. Pass it down.
4727 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
4728 (lookup_symbol_search_name): New declaration.
4729 (lookup_symbol_in_block): New 'match_type' parameter.
4730
4731 2018-01-05 Pedro Alves <palves@redhat.com>
4732
4733 PR gdb/22670
4734 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
4735 ada_lookup_symbol.
4736 (ada_lookup_symbol): Reimplement in terms of
4737 ada_lookup_symbol_list, bits factored out from
4738 ada_lookup_encoded_symbol.
4739
4740 2018-01-05 Joel Brobecker <brobecker@adacore.com>
4741
4742 * ada-exp.y (write_object_renaming): When subscripting an array
4743 using a symbol as the index, pass the block in call to
4744 ada_lookup_encoded_symbol when looking that symbol up.
4745
4746 2018-01-05 Jerome Guitton <guitton@adacore.com>
4747
4748 * ada-lang.c (ada_array_length): Use ada_index_type instead of
4749 TYPE_INDEX_TYPE.
4750
4751 2018-01-05 Joel Brobecker <brobecker@adacore.com>
4752
4753 * ada-lang.c (ada_to_fixed_value_create): Add handling of
4754 the case where VALUE_LVAL (val0) is not lval_memory.
4755
4756 2018-01-05 Xavier Roirand <roirand@adacore.com>
4757
4758 * ada-valprint.c (print_optional_low_bound): Handle
4759 character-indexed array printing like boolean-indexed array
4760 printing.
4761
4762 2018-01-05 Joel Brobecker <brobecker@adacore.com>
4763
4764 * NEWS: Create a new section for the next release branch.
4765 Rename the section of the current branch, now that it has
4766 been cut.
4767
4768 2018-01-05 Joel Brobecker <brobecker@adacore.com>
4769
4770 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
4771 * version.in: Bump version to 8.1.50.DATE-git.
4772
4773 2018-01-03 Xavier Roirand <roirand@adacore.com>
4774
4775 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
4776 Add field.
4777 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
4778 Add field.
4779 (default_exception_support_info) <catch_handlers_sym>: Add field.
4780 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
4781 (ada_exception_name_addr_1): Add "catch handlers" handling.
4782 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
4783 Update all callers.
4784 (create_excep_cond_exprs) <ex>: Add parameter.
4785 (re_set_exception): Update create_excep_cond_exprs call.
4786 (print_it_exception, print_one_exception, print_mention_exception)
4787 (print_recreate_exception): Add "catch handler" handling.
4788 (allocate_location_catch_handlers, re_set_catch_handlers)
4789 (check_status_catch_handlers, print_it_catch_handlers)
4790 (print_one_catch_handlers, print_mention_catch_handlers)
4791 (print_recreate_catch_handlers): New function.
4792 (catch_handlers_breakpoint_ops): New variable.
4793 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
4794 Add parameter. Add "catch handler" handling.
4795 (ada_exception_sym_name, ada_exception_breakpoint_ops):
4796 Add "catch handler" handling.
4797 (ada_exception_catchpoint_cond_string): Add "catch handler"
4798 handling.
4799 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
4800 call.
4801 (catch_ada_handlers_command): New function.
4802 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
4803 operations structure.
4804 (_initialize_ada_language): Add "catch handlers" command entry.
4805 * NEWS: Document "catch handlers" feature.
4806
4807 2018-01-02 Joel Brobecker <brobecker@adacore.com>
4808
4809 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
4810 account when creating the array type of the slice.
4811 (ada_value_slice): Likewise.
4812
4813 2018-01-02 Joel Brobecker <brobecker@adacore.com>
4814
4815 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
4816 New enum value.
4817 (create_array_type_with_stride): Add byte_stride_prop parameter.
4818 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
4819 New parameter. Update all callers in this file.
4820 (array_type_has_dynamic_stride): New function.
4821 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
4822 of arrays with dynamic byte strides.
4823 * dwarf2read.c (read_array_type): Add support for dynamic
4824 DW_AT_byte_stride attributes.
4825
4826 2018-01-02 Joel Brobecker <brobecker@adacore.com>
4827
4828 * dwarf2read.c (read_unspecified_type): Treat
4829 DW_TAG_enumeration_type DIEs from Ada units as stubs.
4830
4831 2018-01-01 Joel Brobecker <brobecker@adacore.com>
4832
4833 Update copyright year range in all GDB files.
4834
4835 2018-01-01 Joel Brobecker <brobecker@adacore.com>
4836
4837 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
4838 and gdb/testsuite/gdb.base/step-line.c.
4839
4840 2018-01-01 Joel Brobecker <brobecker@adacore.com>
4841
4842 * copyright.py (main): Dump the contents of
4843 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
4844 even if BY_HAND is empty.
4845
4846 2018-01-01 Joel Brobecker <brobecker@adacore.com>
4847
4848 * top.c (print_gdb_version): Update Copyright year in version
4849 message.
4850
4851 2018-01-01 Joel Brobecker <brobecker@adacore.com>
4852
4853 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
4854
4855 For older changes see ChangeLog-2017.
4856 \f
4857 Local Variables:
4858 mode: change-log
4859 left-margin: 8
4860 fill-column: 74
4861 version-control: never
4862 coding: utf-8
4863 End:
This page took 0.133075 seconds and 4 git commands to generate.