]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/ChangeLog
Use std::string in reread_symbols
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
c0c9f665
TT
12018-05-21 Tom Tromey <tom@tromey.com>
2
3 * symfile.c (reread_symbols): Use std::string for original_name.
4
22ca247e
TT
52018-05-21 Tom Tromey <tom@tromey.com>
6
7 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
8 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
9 constructor.
10
184cde75
SM
112018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
12
13 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
14 instance to...
15 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
16 * objfiles.c (get_objfile_bfd_data): Allocate
17 objfile_per_bfd_storage with obstack_new when allocating on
18 obstack.
19
e39db4db
SM
202018-05-20 Simon Marchi <simon.marchi@ericsson.com>
21
22 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
23 OBSTACK_ZALLOC.
24 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
25 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
26 * mdebugread.c (mdebug_build_psymtabs): Likewise.
27 (add_pending): Likewise.
28 (parse_symbol): Likewise.
29 (parse_partial_symbols): Likewise.
30 (psymtab_to_symtab_1): Likewise.
31 (new_psymtab): Likewise.
32 (elfmdebug_build_psymtabs): Likewise.
33 * minsyms.c (terminate_minimal_symbol_table): Likewise.
34 * objfiles.c (get_objfile_bfd_data): Likewise.
35 (objfile_register_static_link): Likewise.
36 * psymtab.c (allocate_psymtab): Likewise.
37 * stabsread.c (read_member_functions): Likewise.
38 * xcoffread.c (xcoff_end_psymtab): Likewise.
39
284a0e3c
SM
402018-05-20 Simon Marchi <simon.marchi@ericsson.com>
41
42 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
43 compiler supports std::is_trivially_constructible.
44 * common/poison.h: Include obstack.h.
45 (IsMallocable): Define to is_trivially_constructible if the
46 compiler supports it, define to true_type otherwise.
47 (xobnew): New.
48 (XOBNEW): Redefine.
49 (xobnewvec): New.
50 (XOBNEWVEC): Redefine.
51 * gdb_obstack.h (obstack_zalloc): New.
52 (OBSTACK_ZALLOC): Redefine.
53 (obstack_calloc): New.
54 (OBSTACK_CALLOC): Redefine.
55 (obstack_new): New.
56 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
57 (gdbarch_obstack): New declaration in gdbarch.h, definition in
58 gdbarch.c.
59 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
60 obstack_calloc/obstack_zalloc.
61 (gdbarch_obstack_zalloc): Remove.
62 * target-descriptions.c (tdesc_data_init): Use obstack_new.
63
59f66be3
PW
642018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
65
66 * stack.c (backtrace_command_1): Remove useless variable int i.
67
50c65c2d
PW
682018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
69
70 * stack.c (print_frame_info): Fix comment.
71
7ff8cb8c
TT
722018-05-18 Tom Tromey <tom@tromey.com>
73
74 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
75 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
76 (~dwarf2_per_objfile): Update
77 (dwarf2_get_dwz_file): Use new.
78 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
79 unique_ptr.
80
400174b1
TT
812018-05-18 Tom Tromey <tom@tromey.com>
82
83 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
84 unique_ptr.
85 * dwarf2read.c (struct dwp_file): Add constructor and
86 initializers.
87 (open_and_init_dwp_file): Return a unique_ptr.
88 (dwarf2_per_objfile, create_dwp_hash_table)
89 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
90 (lookup_dwo_unit_in_dwp): Update.
91 (open_and_init_dwp_file, get_dwp_file): Update.
92
3063847f
TT
932018-05-18 Tom Tromey <tom@tromey.com>
94
95 * dwarf2read.c (dwarf2_per_objfile): Update.
96 (struct mapped_index): Add initializers.
97 (dwarf2_read_index): Use new.
98 (dw2_symtab_iter_init): Update.
99 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
100 unique_ptr.
101
d3d02dee
SM
1022018-05-18 Simon Marchi <simon.marchi@ericsson.com>
103
104 * dwarf2read.c (mapped_index) <total_size>: Remove.
105
1d143c36
SM
1062018-05-18 Simon Marchi <simon.marchi@ericsson.com>
107
108 * unittests/format_pieces-selftests.c (test_format_specifier):
109 Add ARI comments.
110
ce1e8424
TT
1112018-05-18 Tom Tromey <tom@tromey.com>
112
113 * c-typeprint.c (maybe_print_hole): New function.
114 (c_print_type_struct_field_offset): Update.
115 (c_type_print_base_struct_union): Call maybe_print_hole.
116
ddfe970e
KS
1172018-05-17 Keith Seitz <keiths@redhat.com>
118
119 * breakpoint.c (build_bpstat_chain): New function, moved from
120 bpstat_stop_status.
121 (bpstat_stop_status): Add optional parameter, `stop_chain'.
122 If no stop chain is passed, call build_bpstat_chain to build it.
123 * breakpoint.h (build_bpstat_chain): Declare.
124 (bpstat_stop_status): Move documentation here from breakpoint.c.
125 * infrun.c (handle_signal_stop): Before eliding inlined frames,
126 build the stop chain and pass it to skip_inline_frames.
127 Pass this stop chain to bpstat_stop_status.
128 * inline-frame.c: Include breakpoint.h.
129 (stopped_by_user_bp_inline_frame): New function.
130 (skip_inline_frames): Add parameter `stop_chain'.
131 Move documention to inline-frame.h.
132 If non-NULL, use stopped_by_user_bp_inline_frame to determine
133 whether the frame should be elided.
134 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
135 Add moved documentation and update for new parameter.
136
b17992c1
SM
1372018-05-17 Simon Marchi <simon.marchi@ericsson.com>
138
139 PR cli/14975
140 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
141 unittests/format_pieces-selftests.c.
142 * common/format.h (format_piece) <operator==>: New.
143 (format_pieces) <operator[]>: Remove.
144 * common/format.c (format_pieces::format_pieces): Handle \e.
145 * unittests/format_pieces-selftests.c: New.
146
58f0c718
TT
1472018-05-17 Tom Tromey <tom@tromey.com>
148
149 PR symtab/23010:
150 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
151 (dw2_instantiate_symtab): Add skip_partial parameter.
152 (dw2_find_last_source_symtab, dw2_map_expand_apply)
153 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
154 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
155 (dw2_expand_symtabs_matching_one)
156 (dw2_find_pc_sect_compunit_symtab)
157 (dw2_debug_names_lookup_symbol)
158 (dw2_debug_names_expand_symtabs_for_function): Update.
159 (init_cutu_and_read_dies): Add skip_partial parameter.
160 (process_psymtab_comp_unit, build_type_psymtabs_1)
161 (process_skeletonless_type_unit, load_partial_comp_unit)
162 (psymtab_to_symtab_1): Update.
163 (load_full_comp_unit): Add skip_partial parameter.
164 (process_imported_unit_die, dwarf2_read_addr_index)
165 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
166 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
167 (read_signatured_type): Update.
168
3e618834
SM
1692018-05-17 Simon Marchi <simon.marchi@ericsson.com>
170
171 * value.c (release_value): Remove unused variable.
172 (record_latest_value): Likewise.
173 (access_value_history): Likewise.
174 (preserve_values): Likewise.
175
fe10fe31
TT
1762018-05-17 Tom Tromey <tom@tromey.com>
177
178 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
179 Initialize.
180
1d761124
MR
1812018-05-16 Maciej W. Rozycki <macro@mips.com>
182
183 PR gdb/22286
184 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
185 Also handle registers whose width is not a multiple of
186 PTRACE_TYPE_RET.
187 (linux_nat_trad_target::store_register): Likewise.
188
06333fea
TT
1892018-05-16 Tom Tromey <tom@tromey.com>
190
191 * gdbcore.h (core_bfd): Redefine.
192 * corelow.c (core_target::close): Update.
193 (core_target_open): Update.
194 * progspace.h (struct program_space) <cbfd>: Now a
195 gdb_bfd_ref_ptr.
196
921222e2
TT
1972018-05-16 Tom Tromey <tom@tromey.com>
198
199 PR cli/19551:
200 * symfile-add-flags.h (enum symfile_add_flags)
201 <SYMFILE_NOT_FILENAME>: New constant.
202 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
203 objfile name from BFD.
204 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
205 * minidebug.c (find_separate_debug_file_in_section): Put
206 ".gnu_debugdata" into BFD's file name.
207
3acb7083
SM
2082018-05-16 Simon Marchi <simon.marchi@ericsson.com>
209
210 * regcache.c (regcache_read_ftype, regcache_write_ftype):
211 Remove.
212
561a72d4
TC
2132018-05-15 Tamar Christina <tamar.christina@arm.com>
214
215 PR binutils/21446
216 * aarch64-tdep.c (aarch64_analyze_prologue,
217 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
218 Indicate not interested in errors.
219
4e6ff0e1
MR
2202018-05-15 Maciej W. Rozycki <macro@mips.com>
221
222 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
223 Supply the MIPS_ZERO_REGNUM register.
224
ea33cd92
MR
2252018-05-15 Maciej W. Rozycki <macro@mips.com>
226
227 * mips-tdep.c (mask_address_var): Make variable static.
228
2d79090e
TT
2292018-05-14 Tom Tromey <tom@tromey.com>
230
231 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
232
cf4912ae
AB
2332018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
234
235 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
236 FXSAVE_ADDR for the mxcsr register.
237
67e6f569
MF
2382018-05-11 Max Filippov <jcmvbkbc@gmail.com>
239
240 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
241
15244507
PA
2422018-05-11 Pedro Alves <palves@redhat.com>
243
244 * corelow.c (core_target) <core_target>: No longer inline.
245 Initialize m_core_gdbarch, m_core_vec and build the section table
246 here.
247 <~core_target>: New.
248 <core_gdbarch, get_core_register_section>: New methods.
249 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
250 factored out from ...
251 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
252 (core_ops): Delete.
253 (sniff_core_bfd): Add gdbarch parameter.
254 (core_close): Delete, merged into ...
255 (core_target::close): ... here. Delete self.
256 (core_close_cleanup): Delete.
257 (core_target_open): Allocate a core_target on the heap. Use a
258 unique_ptr instead of a cleanup. Bits moved into the core_target
259 ctor. Adjust to use core_target methods instead of globals.
260 (get_core_register_section): Rename to ...
261 (core_target::get_core_register_section): ... this and adjust.
262 (struct get_core_registers_cb_data): New.
263 (get_core_registers_cb): Use it. Use bool.
264 (core_target::fetch_registers, core_target::files_info)
265 (core_target::xfer_partial, core_target::read_description)
266 (core_target::pid_to, core_target::thread_name): Adjust to
267 reference class fields instead of globals.
268 * target.h (struct target_ops_deleter, target_ops_up): New.
269
451953fa
PA
2702018-05-11 Pedro Alves <palves@redhat.com>
271
272 * corefile.c (core_file_command): Move to corelow.c.
273 * corelow.c (the_core_target): Delete.
274 (core_file_command): Moved from corefile.c. Check exec_bfd
275 instead of the_core_target. Use target_detach instead of calling
276 into the_core_target directly.
277 (maybe_say_no_core_file_now): New.
278 (core_target::detach): Use it.
279 (_initialize_corelow): Remove references to the_core_target.
280 * gdbcore.h (the_core_target): Delete.
281
e540a5a2 2822018-05-11 Tom Tromey <tromey@redhat.com>
3afc23a6 283 Pedro Alves <palves@redhat.com>
e540a5a2
TT
284
285 * corefile.c (core_bfd): Remove.
286 * gdbcore.h (core_bfd): Now a macro.
287 * progspace.h (struct program_space) <cbfd>: New field.
288
633cf254
TT
2892018-05-11 Tom Tromey <tom@tromey.com>
290
291 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
292 gdb::def_vector.
293
1a34f210
TT
2942018-05-10 Tom Tromey <tom@tromey.com>
295
296 * configure: Rebuild.
297 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
298
190852c8
JB
2992018-05-10 Joel Brobecker <brobecker@adacore.com>
300
301 PR server/23158:
302 * regformats/regdat.sh: Adjust script, following the addition
303 of the new expedite_regs parameter to init_target_desc.
304
8727de56
OJ
3052018-05-10 Omair Javaid <omair.javaid@linaro.org>
306
307 PR gdb/23127
308 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
309 set_gdbarch_significant_addr_bit.
310 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
311 set_gdbarch_significant_addr_bit.
312 * utils.c (address_significant): Update to sign extend addr.
313
37d9e062
MF
3142018-05-09 Max Filippov <jcmvbkbc@gmail.com>
315
316 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
317 (xtensa_linux_init_abi): Limit tdep->num_regs by
318 tdep->num_nopriv_regs.
319 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
320 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
321 not initialized.
322
7402fbca
SM
3232018-05-08 Simon Marchi <simon.marchi@ericsson.com>
324
325 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
326
8ee22052
AB
3272018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
328
329 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
330 (I387_MXCSR_INIT_VAL): New constant.
331 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
332 buffer if it was supplied by the inferior.
333 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
334 (i387_xsave_get_clear_bv): New function.
335 (i387_supply_xsave): Only read x87 control registers from the
336 xsave buffer if the feature is enabled, and the state will have
337 been written, otherwise, provide a suitable default.
338 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
339 including x87 control registers. Update control registers if they
340 have changed from the default value, and mark features as enabled
341 as required.
342 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
343
968ae51b
UW
3442018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
345
346 * spu-tdep.c (info_spu_event_command): Fix output formatting.
347
aff689d3
TT
3482018-05-07 Tom Tromey <tom@tromey.com>
349
350 * configure: Rebuild.
351 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
352
ce887586
TT
3532018-05-07 Tom Tromey <tom@tromey.com>
354
355 PR tdep/20362:
356 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
357 bit. Use correct value for VDIV.
358
85e26832
TT
3592018-05-04 Tom Tromey <tom@tromey.com>
360
361 * configure: Rebuild.
362 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
363
449b1ac7
TT
3642018-05-04 Tom Tromey <tom@tromey.com>
365
366 * linux-record.c (record_linux_system_call) <case
367 RECORD_SYS_RECVFROM>: Add "break".
368
15c9ffd6
TT
3692018-05-04 Tom Tromey <tom@tromey.com>
370
371 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
372 Add missing "break".
373 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
374 Add missing "break".
375
e3829d13
TT
3762018-05-04 Tom Tromey <tom@tromey.com>
377
378 * rs6000-tdep.c (ppc_process_record_op4)
379 (ppc_process_record_op63): Add fall-through comment.
380
da0e1563
TT
3812018-05-04 Tom Tromey <tom@tromey.com>
382
383 * i386-tdep.c (i386_process_record): Add fall-through comment.
384
0019cd49
TT
3852018-05-04 Tom Tromey <tom@tromey.com>
386
387 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
388 comment.
389
565e0eda
TT
3902018-05-04 Tom Tromey <tom@tromey.com>
391
392 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
393 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
394 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
395 comment.
396 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
397 comment.
398 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
399 comment.
400
621846f4
TT
4012018-05-04 Tom Tromey <tom@tromey.com>
402
403 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
404
86a73007
TT
4052018-05-04 Tom Tromey <tom@tromey.com>
406
407 * s390-tdep.c (s390_process_record): Fix fall-through comments.
408 * xcoffread.c (scan_xcoff_symtab): Move comment later.
409 * symfile.c (section_is_mapped): Fix fall-through comment.
410 * stabsread.c (define_symbol, read_member_functions): Fix
411 fall-through comment.
412 * s390-linux-tdep.c (s390_process_record): Fix fall-through
413 comment.
414 * remote.c (remote_wait_as): Fix fall-through comment.
415 * p-exp.y (yylex): Fix fall-through comment.
416 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
417 comment.
418 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
419 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
420 * jv-exp.y (yylex): Fix fall-through comment.
421 * go-exp.y (lex_one_token): Fix fall-through comment.
422 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
423 fall-through comment.
424 * f-exp.y (yylex): Fix fall-through comment.
425 * dwarf2read.c (process_die): Fix fall-through comments.
426 * dbxread.c (process_one_symbol): Fix fall-through comment.
427 * d-exp.y (lex_one_token): Fix fall-through comment.
428 * cp-name-parser.y (yylex): Fix fall-through comment.
429 * coffread.c (coff_symtab_read): Fix fall-through comment.
430 * c-exp.y (lex_one_token): Fix fall-through comment.
431 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
432 comment.
433 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
434 comment.
435
56bcdbea
TT
4362018-05-04 Tom Tromey <tom@tromey.com>
437
438 PR python/22730:
439 * NEWS: Mention gdb.execute change.
440 * gdbcmd.h (execute_control_command): Don't declare.
441 * python/python.c (execute_gdb_command): Use read_command_lines_1,
442 execute_control_commands, execute_control_commands_to_string.
443 * cli/cli-script.h (execute_control_commands)
444 (execute_control_commands_to_string): Declare.
445 (execute_control_command): Add from_tty parameter.
446 * cli/cli-script.c (execute_control_commands)
447 (execute_control_commands_to_string): New functions.
448 (execute_user_command): Use execute_control_commands.
449 (execute_control_command_1): Add "from_tty" parameter. Update.
450 (execute_control_command): Likewise.
451
a913fffb
TT
4522018-05-04 Tom Tromey <tom@tromey.com>
453
454 PR python/22731:
455 * NEWS: Mention that breakpoint commands are writable.
456 * python/py-breakpoint.c (bppy_set_commands): New function.
457 (breakpoint_object_getset) <"commands">: Use it.
458
60b3cef2
TT
4592018-05-04 Tom Tromey <tom@tromey.com>
460
461 * tracepoint.c (actions_command): Update.
462 * mi/mi-cmd-break.c (mi_command_line_array)
463 (mi_command_line_array_cnt, mi_command_line_array_ptr)
464 (mi_read_next_line): Remove.
465 (mi_cmd_break_commands): Update.
466 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
467 function_view.
468 * cli/cli-script.c (get_command_line): Update.
469 (process_next_line): Use function_view. Constify.
470 (recurse_read_control_structure, read_command_lines)
471 (read_command_lines_1): Change argument types to function_view.
472 (do_define_command, document_command): Update.
473 * breakpoint.h (check_tracepoint_command): Don't declare.
474 * breakpoint.c (check_tracepoint_command): Remove.
475 (commands_command_1, create_tracepoint_from_upload): Update.
476
7a2c85f2
TT
4772018-05-04 Tom Tromey <tom@tromey.com>
478
479 PR gdb/11750:
480 * cli/cli-script.h (enum command_control_type) <define_control>:
481 New constant.
482 * cli/cli-script.c (multi_line_command_p): Handle define_control.
483 (build_command_line, execute_control_command_1)
484 (process_next_line): Likewise.
485 (do_define_command): New function, extracted from define_command.
486 (define_command): Use it.
487
295dc222
TT
4882018-05-04 Tom Tromey <tom@tromey.com>
489
490 * tracepoint.c (actions_command): Update.
491 * cli/cli-script.h (read_command_lines): Update.
492 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
493 (MAX_TMPBUF): Remove define.
494 (define_command): Use string_printf.
495 (document_command): Likewise.
496 * breakpoint.c (commands_command_1): Update.
497
1263a9d5
TT
4982018-05-04 Tom Tromey <tom@tromey.com>
499
500 * top.c (execute_command): Update.
501 * cli/cli-script.h (print_command_lines): Now varargs.
502 * cli/cli-script.c (print_command_lines): Now varargs.
503 (execute_control_command_1) <case while_control, case if_control>:
504 Update.
505
12973681
TT
5062018-05-04 Tom Tromey <tom@tromey.com>
507
508 * tracepoint.c (all_tracepoint_actions): Rename from
509 all_tracepoint_actions_and_cleanup. Change return type.
510 (actions_command, encode_actions_1, encode_actions)
511 (trace_dump_actions, tdump_command): Update.
512 * remote.c (remote_download_command_source): Update.
513 * python/python.c (gdbpy_eval_from_control_command)
514 (python_command, python_interactive_command): Update.
515 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
516 * guile/guile.c (guile_command)
517 (gdbscm_eval_from_control_command, guile_command): Update.
518 * compile/compile.c (compile_code_command)
519 (compile_print_command, compile_to_object): Update.
520 * cli/cli-script.h (struct command_lines_deleter): New.
521 (counted_command_line): New typedef.
522 (struct command_line): Add constructor, destructor.
523 <body_list>: Remove.
524 <body_list_0, body_list_1>: New members.
525 (command_line_up): Remove typedef.
526 (read_command_lines, read_command_lines_1, get_command_line):
527 Update.
528 (copy_command_lines): Don't declare.
529 * cli/cli-script.c (build_command_line): Use "new".
530 (get_command_line): Return counted_command_line.
531 (print_command_lines, execute_user_command)
532 (execute_control_command_1, while_command, if_command): Update.
533 (realloc_body_list): Remove.
534 (process_next_line, recurse_read_control_structure): Update.
535 (read_command_lines, read_command_lines_1): Return counted_command_line.
536 (free_command_lines): Use "delete".
537 (copy_command_lines): Remove.
538 (define_command, document_command, show_user_1): Update.
539 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
540 a counted_command_line.
541 * breakpoint.h (counted_command_line): Remove typedef.
542 (breakpoint_set_commands): Update.
543 * breakpoint.c (check_no_tracepoint_commands)
544 (validate_commands_for_breakpoint): Update.
545 (breakpoint_set_commands): Change commands to be a
546 counted_command_line.
547 (commands_command_1, update_dprintf_command_list)
548 (create_tracepoint_from_upload): Update.
549
e2fc72e2
TT
5502018-05-04 Tom Tromey <tom@tromey.com>
551
552 * cli/cli-decode.h (cmd_list_element): New constructor.
553 (~cmd_list_element): New destructor.
554 (struct cmd_list_element): Add initializers.
555 * cli/cli-decode.c (do_add_cmd): Use "new".
556 (delete_cmd): Use "delete".
557
a3b60e45
JK
5582018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
559 Pedro Alves <palves@redhat.com>
560
561 PR breakpoints/19806 and support for PR external/20207.
562 * NEWS: Mention Aarch64 watchpoint improvements.
563 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
564 watchpoints and PR external/20207 watchpoints.
565 * nat/aarch64-linux-hw-point.c
566 (kernel_supports_any_contiguous_range): New.
567 (aarch64_watchpoint_offset): New.
568 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
569 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
570 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
571 (aarch64_align_watchpoint): New parameters aligned_offset_p and
572 next_addr_orig_p. Support PR external/20207 watchpoints.
573 (aarch64_downgrade_regs): New.
574 (aarch64_dr_state_insert_one_point): New parameters offset and
575 addr_orig.
576 (aarch64_dr_state_remove_one_point): Likewise.
577 (aarch64_handle_breakpoint): Update caller.
578 (aarch64_handle_aligned_watchpoint): Likewise.
579 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
580 aligned_offset.
581 (aarch64_linux_set_debug_regs): Remove const from state. Call
582 aarch64_downgrade_regs.
583 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
584 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
585 (DR_CONTROL_MASK): ... this.
586 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
587 (unsigned int aarch64_watchpoint_offset): New prototype.
588 (aarch64_linux_set_debug_regs): Remove const from state.
589 * utils.c (align_up, align_down): Move to ...
590 * common/common-utils.c (align_up, align_down): ... here.
591 * utils.h (align_up, align_down): Move to ...
592 * common/common-utils.h (align_up, align_down): ... here.
593
05bc7456
JB
5942018-05-04 Joel Brobecker <brobecker@adacore.com>
595
596 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
597 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
598 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
599 Re-implement to match the ABI as summarized in GCC's
600 gcc/config/sparc/sparc.c. All callers updated.
601 (sparc32_store_arguments): Remove assertion.
602
2f433492
TT
6032018-05-04 Tom Tromey <tom@tromey.com>
604
605 * printcmd.c: Don't include tui.h.
606 (decode_format): Use skip_spaces.
607
9be2ae8f
TT
6082018-05-04 Tom Tromey <tom@tromey.com>
609
610 PR gdb/22619:
611 * printcmd.c (last_count): New global.
612 (x_command): Use saved count when repeating.
613
f0b3976b
TT
6142018-05-04 Tom Tromey <tom@tromey.com>
615
616 * nto-procfs.c (do_closedir_cleanup): Remove.
617 (procfs_pidlist): Use gdb_dir_up.
618 * procfs.c (do_closedir_cleanup): Remove.
619 (proc_update_threads): Use gdb_dir_up.
620 * common/filestuff.h (struct gdb_dir_deleter): New.
621 (gdb_dir_up): New typedef.
622
862d101a
TT
6232018-05-04 Tom Tromey <tom@tromey.com>
624
625 * ada-lang.c (print_mention_exception): Use std::string.
626
cb7de75e
TT
6272018-05-04 Tom Tromey <tom@tromey.com>
628
629 * ada-lang.c (create_excep_cond_exprs): Update.
630 (ada_exception_catchpoint_cond_string): Use std::string.
631
49d83361
TT
6322018-05-04 Tom Tromey <tom@tromey.com>
633
634 * ada-lang.c (xget_renaming_scope): Return std::string.
635 (old_renaming_is_invisible): Update.
636
ade72a34
TT
6372018-05-04 Tom Tromey <tom@tromey.com>
638
639 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
640 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
641
2be4d7f0
UW
6422018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
643
644 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
645
69b6ecb0
TT
6462018-05-04 Tom Tromey <tom@tromey.com>
647
648 * remote.c (remote_query_supported_append): Change type.
649 (remote_check_symbols): Update.
650
bf27f0e2
PP
6512018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
652
653 PR gdb/11420
654 * configure.ac: Prepend libpython.
655 * python/python-config.py: Likewise.
656 * configure: Regenerate.
657
4ea17de8
SM
6582018-05-03 Simon Marchi <simon.marchi@ericsson.com>
659
660 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
661
bd732259
PA
6622018-05-03 Pedro Alves <palves@redhat.com>
663
664 * s390-linux-nat.c
665 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
666 override. Write 'true' instead of '1'.
667 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
668 declaration.
669
d9f719f1
PA
6702018-05-02 Pedro Alves <palves@redhat.com>
671
672 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
673 add_inf_child_target.
674 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
675 add_inf_child_target.
676 * aix-thread.c (aix_thread_target_info): New.
677 (aix_thread_target) <shortname, longname, doc>: Delete.
678 <info>: New.
679 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
680 add_inf_child_target.
681 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
682 add_inf_child_target.
683 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
684 add_inf_child_target.
685 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
686 add_inf_child_target.
687 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
688 add_inf_child_target.
689 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
690 add_inf_child_target.
691 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
692 add_inf_child_target.
693 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
694 add_inf_child_target.
695 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
696 add_inf_child_target.
697 * bfd-target.c (target_bfd_target_info): New.
698 (target_bfd) <shortname, longname, doc>: Delete.
699 <info>: New.
700 * bsd-kvm.c (bsd_kvm_target_info): New.
701 (bsd_kvm_target) <shortname, longname, doc>: Delete.
702 <info>: New.
703 (bsd_kvm_target::open): Rename to ...
704 (bsd_kvm_target_open): ... this. Adjust.
705 * bsd-uthread.c (bsd_uthread_target_info): New.
706 (bsd_uthread_target) <shortname, longname, doc>: Delete.
707 <info>: New.
708 * corefile.c (core_file_command): Adjust.
709 * corelow.c (core_target_info): New.
710 (core_target) <shortname, longname, doc>: Delete.
711 <info>: New.
712 (core_target::open): Rename to ...
713 (core_target_open): ... this. Adjust.
714 * ctf.c (ctf_target_info): New.
715 (ctf_target) <shortname, longname, doc>: Delete.
716 <info>: New.
717 (ctf_target::open): Rename to ...
718 (ctf_target_open): ... this.
719 (_initialize_ctf): Adjust.
720 * exec.c (exec_target_info): New.
721 (exec_target) <shortname, longname, doc>: Delete.
722 <info>: New.
723 (exec_target::open): Rename to ...
724 (exec_target_open): ... this.
725 * gdbcore.h (core_target_open): Declare.
726 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
727 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
728 add_inf_child_target.
729 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
730 add_inf_child_target.
731 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
732 add_inf_child_target.
733 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
734 add_inf_child_target.
735 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
736 add_inf_child_target.
737 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
738 add_inf_child_target.
739 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
740 add_inf_child_target.
741 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
742 add_inf_child_target.
743 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
744 add_inf_child_target.
745 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
746 add_inf_child_target.
747 * inf-child.c (inf_child_target_info): New.
748 (inf_child_target::info): New.
749 (inf_child_open_target): Remove 'target' parameter. Use
750 get_native_target instead.
751 (inf_child_target::open): Delete.
752 (add_inf_child_target): New.
753 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
754 Delete.
755 <info>: New.
756 (add_inf_child_target): Declare.
757 (inf_child_open_target): Declare.
758 * linux-thread-db.c (thread_db_target_info): New.
759 (thread_db_target) <shortname, longname, doc>: Delete.
760 <info>: New.
761 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
762 add_inf_child_target.
763 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
764 add_inf_child_target.
765 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
766 add_inf_child_target.
767 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
768 add_inf_child_target.
769 * make-target-delegates (print_class): Adjust.
770 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
771 add_inf_child_target.
772 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
773 add_inf_child_target.
774 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
775 add_inf_child_target.
776 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
777 add_inf_child_target.
778 * nto-procfs.c (nto_native_target_info): New.
779 (nto_procfs_target_native) <shortname, longname, doc>:
780 Delete.
781 <info>: New.
782 (nto_procfs_target_info): New.
783 (nto_procfs_target_procfs) <shortname, longname, doc>:
784 Delete.
785 <info>: New.
786 (init_procfs_targets): Adjust.
787 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
788 add_inf_child_target.
789 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
790 add_inf_child_target.
791 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
792 add_inf_child_target.
793 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
794 add_inf_child_target.
795 * ravenscar-thread.c (ravenscar_target_info): New.
796 (ravenscar_thread_target) <shortname, longname, doc>:
797 Delete.
798 <info>: New.
799 * record-btrace.c (record_btrace_target_info):
800 (record_btrace_target) <shortname, longname, doc>: Delete.
801 <info>: New.
802 (record_btrace_target::open): Rename to ...
803 (record_btrace_target_open): ... this. Adjust.
804 * record-full.c (record_longname, record_doc): New.
805 (record_full_base_target) <shortname, longname, doc>: Delete.
806 <info>: New.
807 (record_full_target_info): New.
808 (record_full_target): <shortname>: Delete.
809 <info>: New.
810 (record_full_core_open_1, record_full_open_1): Update comments.
811 (record_full_base_target::open): Rename to ...
812 (record_full_open): ... this.
813 (cmd_record_full_restore): Update.
814 (_initialize_record_full): Update.
815 * remote-sim.c (remote_sim_target_info): New.
816 (gdbsim_target) <shortname, longname, doc>: Delete.
817 <info>: New.
818 (gdbsim_target::open): Rename to ...
819 (gdbsim_target_open): ... this.
820 (_initialize_remote_sim): Adjust.
821 * remote.c (remote_doc): New.
822 (remote_target_info): New.
823 (remote_target) <shortname, longname, doc>: Delete.
824 <info>: New.
825 (extended_remote_target_info): New.
826 (extended_remote_target) <shortname, longname, doc>: Delete.
827 <info>: New.
828 (remote_target::open_1): Make static. Adjust.
829 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
830 * s390-linux-nat.c (_initialize_s390_nat): Use
831 add_inf_child_target.
832 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
833 add_inf_child_target.
834 * sol-thread.c (thread_db_target_info): New.
835 (sol_thread_target) <shortname, longname, doc>: Delete.
836 <info>: New.
837 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
838 add_inf_child_target.
839 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
840 add_inf_child_target.
841 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
842 add_inf_child_target.
843 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
844 add_inf_child_target.
845 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
846 add_inf_child_target.
847 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
848 add_inf_child_target.
849 * spu-linux-nat.c (_initialize_spu_nat): Use
850 add_inf_child_target.
851 * spu-multiarch.c (spu_multiarch_target_info): New.
852 (spu_multiarch_target) <shortname, longname, doc>: Delete.
853 <info>: New.
854 * target-delegates.c: Regenerate.
855 * target.c: Include <unordered_map>.
856 (target_ops_p): Delete.
857 (DEF_VEC_P(target_ops_p)): Delete.
858 (target_factories): New.
859 (test_target_info): New.
860 (test_target_ops::info): New.
861 (open_target): Adjust to use target_factories.
862 (add_target_with_completer): Rename to ...
863 (add_target): ... this. Change prototype. Register target_info
864 and open callback in target_factories. Register target_info in
865 command context instead of target_ops.
866 (add_target): Delete old implementation.
867 (add_deprecated_target_alias): Change prototype. Adjust.
868 (the_native_target): New.
869 (set_native_target, get_native_target): New.
870 (find_default_run_target): Use the_native_target.
871 (find_attach_target, find_run_target): Simplify.
872 (target_ops::open): Delete.
873 (dummy_target_info): New.
874 (dummy_target::shortname, dummy_target::longname)
875 (dummy_target::doc): Delete.
876 (dummy_target::info): New.
877 (debug_target::shortname, debug_target::longname)
878 (debug_target::doc): Delete.
879 (debug_target::info): New.
880 * target.h (struct target_info): New.
881 (target_ops::~target_ops): Add comment.
882 (target_ops::info): New.
883 (target_ops::shortname, target_ops::longname, target_ops::doc): No
884 longer virtual. Implement in terms of target_info.
885 (set_native_target, get_native_target): Declare.
886 (target_open_ftype): New.
887 (add_target, add_target_with_completer)
888 (add_deprecated_target_alias): Change prototype.
889 (test_target) <shortname, longname, doc>: Delete.
890 <info>: New.
891 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
892 add_inf_child_target.
893 * tracefile-tfile.c (tfile_target_info): New.
894 (tfile_target) <shortname, longname, doc>: Delete.
895 <info>: New.
896 (tfile_target::open): Rename to ...
897 (tfile_target_open): ... this.
898 (_initialize_tracefile_tfile): Adjust.
899 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
900 add_inf_child_target.
901 * windows-nat.c (_initialize_windows_nat): Use
902 add_inf_child_target.
903 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
904 add_inf_child_target.
905
135340af
PA
9062018-05-02 Pedro Alves <palves@redhat.com>
907
908 * linux-nat.h (linux_nat_target) <low_new_thread,
909 low_delete_thread, low_new_fork, low_forget_process,
910 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
911 New virtual methods.
912 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
913 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
914 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
915 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
916 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
917 Delete.
918 * linux-fork.c (delete_fork): Adjust to call low method.
919 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
920 (linux_nat_new_fork, linux_nat_forget_process_hook)
921 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
922 (linux_nat_status_is_event):
923 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
924 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
925 to call low method.
926 (sigtrap_is_event): Rename to ...
927 (linux_nat_target::low_status_is_event): ... this.
928 (linux_nat_set_status_is_event): Delete.
929 (save_stop_reason, linux_nat_wait_1)
930 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
931 low methods.
932 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
933 (linux_nat_set_new_fork, linux_nat_set_forget_process)
934 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
935 (linux_nat_set_prepare_to_resume): Delete.
936 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
937 low virtual methods.
938 * amd64-linux-nat.c: Likewise.
939 * arm-linux-nat.c: Likewise.
940 * i386-linux-nat.c: Likewise.
941 * ia64-linux-nat.c: Likewise.
942 * mips-linux-nat.c: Likewise.
943 * ppc-linux-nat.c: Likewise.
944 * s390-linux-nat.c: Likewise.
945 * sparc64-linux-nat.c: Likewise.
946 * x86-linux-nat.c: Likewise.
947 * x86-linux-nat.h: Include "nat/x86-linux.h".
948 (x86_linux_nat_target) <low_new_fork, low_forget_process,
949 low_prepare_to_resume, low_new_thread, low_delete_thread>:
950 Override methods.
951
57810aa7
PA
9522018-05-02 Pedro Alves <palves@redhat.com>
953
954 * target.h (target_ops)
955 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
956 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
957 stopped_by_watchpoint, have_continuable_watchpoint,
958 stopped_data_address, watchpoint_addr_within_range,
959 can_accel_watchpoint_condition, can_run, thread_alive,
960 has_all_memory, has_memory, has_stack, has_registers,
961 has_execution, can_async_p, is_async_p, supports_non_stop,
962 always_non_stop_p, can_execute_reverse, supports_multi_process,
963 supports_enable_disable_tracepoint,
964 supports_disable_randomization, supports_string_tracing,
965 supports_evaluation_of_breakpoint_conditions,
966 can_run_breakpoint_commands, filesystem_is_local,
967 can_download_tracepoint, get_trace_state_variable_value,
968 set_trace_notes, get_tib_address, use_agent, can_use_agent,
969 record_is_replaying, record_will_replay,
970 augmented_libraries_svr4_read>: Adjust to return bool.
971 * aarch64-linux-nat.c: All implementations adjusted.
972 * aix-thread.c: All implementations adjusted.
973 * arm-linux-nat.c: All implementations adjusted.
974 * breakpoint.c: All implementations adjusted.
975 * bsd-kvm.c: All implementations adjusted.
976 * bsd-uthread.c: All implementations adjusted.
977 * corelow.c: All implementations adjusted.
978 * ctf.c: All implementations adjusted.
979 * darwin-nat.c: All implementations adjusted.
980 * darwin-nat.h: All implementations adjusted.
981 * exec.c: All implementations adjusted.
982 * fbsd-nat.c: All implementations adjusted.
983 * fbsd-nat.h: All implementations adjusted.
984 * gnu-nat.c: All implementations adjusted.
985 * gnu-nat.h: All implementations adjusted.
986 * go32-nat.c: All implementations adjusted.
987 * ia64-linux-nat.c: All implementations adjusted.
988 * inf-child.c: All implementations adjusted.
989 * inf-child.h: All implementations adjusted.
990 * inf-ptrace.c: All implementations adjusted.
991 * inf-ptrace.h: All implementations adjusted.
992 * linux-nat.c: All implementations adjusted.
993 * linux-nat.h: All implementations adjusted.
994 * mips-linux-nat.c: All implementations adjusted.
995 * nto-procfs.c: All implementations adjusted.
996 * ppc-linux-nat.c: All implementations adjusted.
997 * procfs.c: All implementations adjusted.
998 * ravenscar-thread.c: All implementations adjusted.
999 * record-btrace.c: All implementations adjusted.
1000 * record-full.c: All implementations adjusted.
1001 * remote-sim.c: All implementations adjusted.
1002 * remote.c: All implementations adjusted.
1003 * s390-linux-nat.c: All implementations adjusted.
1004 * sol-thread.c: All implementations adjusted.
1005 * spu-multiarch.c: All implementations adjusted.
1006 * target-delegates.c: All implementations adjusted.
1007 * target.c: All implementations adjusted.
1008 * target.h: All implementations adjusted.
1009 * tracefile-tfile.c: All implementations adjusted.
1010 * tracefile.c: All implementations adjusted.
1011 * tracefile.h: All implementations adjusted.
1012 * windows-nat.c: All implementations adjusted.
1013 * x86-linux-nat.h: All implementations adjusted.
1014 * x86-nat.h: All implementations adjusted.
1015
ad6a4e2d
PA
10162018-05-02 Pedro Alves <palves@redhat.com>
1017
1018 * make-target-delegates (scan_target_h): Don't trim lines here.
1019 Replace sequences of tabs and/or whitespace with a single
1020 whitespace.
1021 (top level, parsing methods): Trim each line before processing it
1022 here.
1023
f6ac5f3d
PA
10242018-05-02 Pedro Alves <palves@redhat.com>
1025 John Baldwin <jhb@freebsd.org>
1026
1027 * target.h (enum strata) <debug_stratum>: New.
1028 (struct target_ops) <all delegation methods>: Replace by C++
1029 virtual methods, and drop "to_" prefix. All references updated
1030 throughout.
1031 <to_shortname, to_longname, to_doc, to_data,
1032 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
1033 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
1034 virtual methods. All references updated throughout.
1035 <can_attach, supports_terminal_ours, can_create_inferior,
1036 get_thread_control_capabilities, attach_no_wait>: New
1037 virtual methods.
1038 <insert_breakpoint, remove_breakpoint>: Now
1039 TARGET_DEFAULT_NORETURN methods.
1040 <info_proc>: Now returns bool.
1041 <to_magic>: Delete.
1042 (OPS_MAGIC): Delete.
1043 (current_target): Delete. All references replaced by references
1044 to ...
1045 (target_stack): ... this. New.
1046 (target_shortname, target_longname): Adjust.
1047 (target_can_run): Now a function declaration.
1048 (default_child_has_all_memory, default_child_has_memory)
1049 (default_child_has_stack, default_child_has_registers)
1050 (default_child_has_execution): Remove target_ops parameter.
1051 (complete_target_initialization): Delete.
1052 (memory_breakpoint_target): New template class.
1053 (test_target_ops): Refactor as a C++ class with virtual methods.
1054 * make-target-delegates (NAME_PART): Tighten.
1055 (POINTER_PART, CP_SYMBOL): New.
1056 (SIMPLE_RETURN_PART): Reimplement.
1057 (VEC_RETURN_PART): Expect less.
1058 (RETURN_PART, VIRTUAL_PART): New.
1059 (METHOD): Adjust to C++ virtual methods.
1060 (scan_target_h): Remove reference to C99.
1061 (dname): Output "target_ops::" prefix.
1062 (write_function_header): Adjust to output a C++ class method.
1063 (write_declaration): New.
1064 (write_delegator): Adjust to output a C++ class method.
1065 (tdname): Output "dummy_target::" prefix.
1066 (write_tdefault, write_debugmethod): Adjust to output a C++ class
1067 method.
1068 (tdefault_names, debug_names): Delete.
1069 (return_types, tdefaults, styles, argtypes_array): New.
1070 (top level): All methods are delegators.
1071 (print_class): New.
1072 (top level): Print dummy_target and debug_target classes.
1073 * target-delegates.c: Regenerate.
1074 * target-debug.h (target_debug_print_enum_info_proc_what)
1075 (target_debug_print_thread_control_capabilities)
1076 (target_debug_print_thread_info_p): New.
1077 * target.c (dummy_target): Delete.
1078 (the_dummy_target, the_debug_target): New.
1079 (target_stack): Now extern.
1080 (set_targetdebug): Push/unpush debug target.
1081 (default_child_has_all_memory, default_child_has_memory)
1082 (default_child_has_stack, default_child_has_registers)
1083 (default_child_has_execution): Remove target_ops parameter.
1084 (complete_target_initialization): Delete.
1085 (add_target_with_completer): No longer call
1086 complete_target_initialization.
1087 (target_supports_terminal_ours): Use regular delegation.
1088 (update_current_target): Delete.
1089 (push_target): No longer check magic number. Don't call
1090 update_current_target.
1091 (unpush_target): Don't call update_current_target.
1092 (target_is_pushed): No longer check magic number.
1093 (target_require_runnable): Skip for all stratums over
1094 process_stratum.
1095 (target_ops::info_proc): New.
1096 (target_info_proc): Use find_target_at and
1097 find_default_run_target.
1098 (target_supports_disable_randomization): Use regular delegation.
1099 (target_get_osdata): Use find_target_at.
1100 (target_ops::open, target_ops::close, target_ops::can_attach)
1101 (target_ops::attach, target_ops::can_create_inferior)
1102 (target_ops::create_inferior, target_ops::can_run)
1103 (target_can_run): New.
1104 (default_fileio_target): Use regular delegation.
1105 (target_ops::fileio_open, target_ops::fileio_pwrite)
1106 (target_ops::fileio_pread, target_ops::fileio_fstat)
1107 (target_ops::fileio_close, target_ops::fileio_unlink)
1108 (target_ops::fileio_readlink): New.
1109 (target_fileio_open_1, target_fileio_unlink)
1110 (target_fileio_readlink): Always call the target method. Handle
1111 FILEIO_ENOSYS.
1112 (return_zero, return_zero_has_execution): Delete.
1113 (init_dummy_target): Delete.
1114 (dummy_target::dummy_target, dummy_target::shortname)
1115 (dummy_target::longname, dummy_target::doc)
1116 (debug_target::debug_target, debug_target::shortname)
1117 (debug_target::longname, debug_target::doc): New.
1118 (target_supports_delete_record): Use regular delegation.
1119 (setup_target_debug): Delete.
1120 (maintenance_print_target_stack): Skip debug_stratum.
1121 (initialize_targets): Instantiate the_dummy_target and
1122 the_debug_target.
1123 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
1124 use target_stack.
1125 (target_auxv_search, fprint_target_auxv): Adjust.
1126 (info_auxv_command): Adjust to use target_stack.
1127 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
1128 * exceptions.c (print_flush): Handle a NULL target_stack.
1129 * regcache.c (target_ops_no_register): Refactor as class with
1130 virtual methods.
1131
1132 * exec.c (exec_target): New class.
1133 (exec_ops): Now an exec_target.
1134 (exec_open, exec_close_1, exec_get_section_table)
1135 (exec_xfer_partial, exec_files_info, exec_has_memory)
1136 (exec_make_note_section): Refactor as exec_target methods.
1137 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
1138 Delete.
1139 (exec_target::find_memory_regions): New.
1140 (_initialize_exec): Don't call init_exec_ops.
1141 * gdbcore.h (exec_file_clear): Delete.
1142
1143 * corefile.c (core_target): Delete.
1144 (core_file_command): Adjust.
1145 * corelow.c (core_target): New class.
1146 (the_core_target): New.
1147 (core_close): Remove target_ops parameter.
1148 (core_close_cleanup): Adjust.
1149 (core_target::close): New.
1150 (core_open, core_detach, get_core_registers, core_files_info)
1151 (core_xfer_partial, core_thread_alive, core_read_description)
1152 (core_pid_to_str, core_thread_name, core_has_memory)
1153 (core_has_stack, core_has_registers, core_info_proc): Rework as
1154 core_target methods.
1155 (ignore, core_remove_breakpoint, init_core_ops): Delete.
1156 (_initialize_corelow): Initialize the_core_target.
1157 * gdbcore.h (core_target): Delete.
1158 (the_core_target): New.
1159
1160 * ctf.c: (ctf_target): New class.
1161 (ctf_ops): Now a ctf_target.
1162 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
1163 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
1164 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
1165 methods.
1166 (init_ctf_ops): Delete.
1167 (_initialize_ctf): Don't call it.
1168 * tracefile-tfile.c (tfile_target): New class.
1169 (tfile_ops): Now a tfile_target.
1170 (tfile_open, tfile_close, tfile_files_info)
1171 (tfile_get_tracepoint_status, tfile_trace_find)
1172 (tfile_fetch_registers, tfile_xfer_partial)
1173 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
1174 Refactor as tfile_target methods.
1175 (tfile_xfer_partial_features): Remove target_ops parameter.
1176 (init_tfile_ops): Delete.
1177 (_initialize_tracefile_tfile): Don't call it.
1178 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
1179 (tracefile_has_stack, tracefile_has_registers)
1180 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
1181 tracefile_target methods.
1182 (init_tracefile_ops): Delete.
1183 (tracefile_target::tracefile_target): New.
1184 * tracefile.h: Include "target.h".
1185 (tracefile_target): New class.
1186 (init_tracefile_ops): Delete.
1187
1188 * spu-multiarch.c (spu_multiarch_target): New class.
1189 (spu_ops): Now a spu_multiarch_target.
1190 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
1191 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
1192 (spu_search_memory, spu_mourn_inferior): Refactor as
1193 spu_multiarch_target methods.
1194 (init_spu_ops): Delete.
1195 (_initialize_spu_multiarch): Remove references to init_spu_ops,
1196 complete_target_initialization.
1197
1198 * ravenscar-thread.c (ravenscar_thread_target): New class.
1199 (ravenscar_ops): Now a ravenscar_thread_target.
1200 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
1201 (ravenscar_thread_alive, ravenscar_pid_to_str)
1202 (ravenscar_fetch_registers, ravenscar_store_registers)
1203 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
1204 (ravenscar_stopped_by_hw_breakpoint)
1205 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
1206 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
1207 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
1208 methods.
1209 (init_ravenscar_thread_ops): Delete.
1210 (_initialize_ravenscar): Remove references to
1211 init_ravenscar_thread_ops and complete_target_initialization.
1212
1213 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
1214 (bsd_uthread_target): New class.
1215 (bsd_uthread_ops): Now a bsd_uthread_target.
1216 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
1217 (bsd_uthread_close, bsd_uthread_mourn_inferior)
1218 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
1219 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
1220 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
1221 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
1222 (bsd_uthread_target): Delete function.
1223 (_initialize_bsd_uthread): Remove reference to
1224 complete_target_initialization.
1225
1226 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
1227 (target_bfd): ... this new class.
1228 (target_bfd_xfer_partial, target_bfd_get_section_table)
1229 (target_bfd_close): Refactor as target_bfd methods.
1230 (target_bfd::~target_bfd): New.
1231 (target_bfd_reopen): Adjust.
1232 (target_bfd::close): New.
1233
1234 * record-btrace.c (record_btrace_target): New class.
1235 (record_btrace_ops): Now a record_btrace_target.
1236 (record_btrace_open, record_btrace_stop_recording)
1237 (record_btrace_disconnect, record_btrace_close)
1238 (record_btrace_async, record_btrace_info)
1239 (record_btrace_insn_history, record_btrace_insn_history_range)
1240 (record_btrace_insn_history_from, record_btrace_call_history)
1241 (record_btrace_call_history_range)
1242 (record_btrace_call_history_from, record_btrace_record_method)
1243 (record_btrace_is_replaying, record_btrace_will_replay)
1244 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
1245 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
1246 (record_btrace_store_registers, record_btrace_prepare_to_store)
1247 (record_btrace_to_get_unwinder)
1248 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
1249 (record_btrace_commit_resume, record_btrace_wait)
1250 (record_btrace_stop, record_btrace_can_execute_reverse)
1251 (record_btrace_stopped_by_sw_breakpoint)
1252 (record_btrace_supports_stopped_by_sw_breakpoint)
1253 (record_btrace_stopped_by_hw_breakpoint)
1254 (record_btrace_supports_stopped_by_hw_breakpoint)
1255 (record_btrace_update_thread_list, record_btrace_thread_alive)
1256 (record_btrace_goto_begin, record_btrace_goto_end)
1257 (record_btrace_goto, record_btrace_stop_replaying_all)
1258 (record_btrace_execution_direction)
1259 (record_btrace_prepare_to_generate_core)
1260 (record_btrace_done_generating_core): Refactor as
1261 record_btrace_target methods.
1262 (init_record_btrace_ops): Delete.
1263 (_initialize_record_btrace): Remove reference to
1264 init_record_btrace_ops.
1265 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
1266 the execution_direction global.
1267 (record_full_base_target, record_full_target)
1268 (record_full_core_target): New classes.
1269 (record_full_ops): Now a record_full_target.
1270 (record_full_core_ops): Now a record_full_core_target.
1271 (record_full_target::detach, record_full_target::disconnect)
1272 (record_full_core_target::disconnect)
1273 (record_full_target::mourn_inferior, record_full_target::kill):
1274 New.
1275 (record_full_open, record_full_close, record_full_async): Refactor
1276 as methods of the record_full_base_target class.
1277 (record_full_resume, record_full_commit_resume): Refactor
1278 as methods of the record_full_target class.
1279 (record_full_wait, record_full_stopped_by_watchpoint)
1280 (record_full_stopped_data_address)
1281 (record_full_stopped_by_sw_breakpoint)
1282 (record_full_supports_stopped_by_sw_breakpoint)
1283 (record_full_stopped_by_hw_breakpoint)
1284 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
1285 methods of the record_full_base_target class.
1286 (record_full_store_registers, record_full_xfer_partial)
1287 (record_full_insert_breakpoint, record_full_remove_breakpoint):
1288 Refactor as methods of the record_full_target class.
1289 (record_full_can_execute_reverse, record_full_get_bookmark)
1290 (record_full_goto_bookmark, record_full_execution_direction)
1291 (record_full_record_method, record_full_info, record_full_delete)
1292 (record_full_is_replaying, record_full_will_replay)
1293 (record_full_goto_begin, record_full_goto_end, record_full_goto)
1294 (record_full_stop_replaying): Refactor as methods of the
1295 record_full_base_target class.
1296 (record_full_core_resume, record_full_core_kill)
1297 (record_full_core_fetch_registers)
1298 (record_full_core_prepare_to_store)
1299 (record_full_core_store_registers, record_full_core_xfer_partial)
1300 (record_full_core_insert_breakpoint)
1301 (record_full_core_remove_breakpoint)
1302 (record_full_core_has_execution): Refactor
1303 as methods of the record_full_core_target class.
1304 (record_full_base_target::supports_delete_record): New.
1305 (init_record_full_ops): Delete.
1306 (init_record_full_core_ops): Delete.
1307 (record_full_save): Refactor as method of the
1308 record_full_base_target class.
1309 (_initialize_record_full): Remove references to
1310 init_record_full_ops and init_record_full_core_ops.
1311
1312 * remote.c (remote_target, extended_remote_target): New classes.
1313 (remote_ops): Now a remote_target.
1314 (extended_remote_ops): Now an extended_remote_target.
1315 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
1316 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
1317 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
1318 (remote_pass_signals, remote_set_syscall_catchpoint)
1319 (remote_program_signals, )
1320 (remote_thread_always_alive): Remove target_ops parameter.
1321 (remote_thread_alive, remote_thread_name)
1322 (remote_update_thread_list, remote_threads_extra_info)
1323 (remote_static_tracepoint_marker_at)
1324 (remote_static_tracepoint_markers_by_strid)
1325 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
1326 (remote_open): Refactor as methods of remote_target.
1327 (extended_remote_open, extended_remote_detach)
1328 (extended_remote_attach, extended_remote_post_attach):
1329 (extended_remote_supports_disable_randomization)
1330 (extended_remote_create_inferior): : Refactor as method of
1331 extended_remote_target.
1332 (remote_set_permissions, remote_open_1, remote_detach)
1333 (remote_follow_fork, remote_follow_exec, remote_disconnect)
1334 (remote_resume, remote_commit_resume, remote_stop)
1335 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
1336 (remote_terminal_ours, remote_wait, remote_fetch_registers)
1337 (remote_prepare_to_store, remote_store_registers)
1338 (remote_flash_erase, remote_flash_done, remote_files_info)
1339 (remote_kill, remote_mourn, remote_insert_breakpoint)
1340 (remote_remove_breakpoint, remote_insert_watchpoint)
1341 (remote_watchpoint_addr_within_range)
1342 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
1343 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
1344 (remote_supports_stopped_by_sw_breakpoint)
1345 (remote_stopped_by_hw_breakpoint)
1346 (remote_supports_stopped_by_hw_breakpoint)
1347 (remote_stopped_by_watchpoint, remote_stopped_data_address)
1348 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
1349 (remote_verify_memory): Refactor as methods of remote_target.
1350 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
1351 parameter.
1352 (remote_xfer_partial, remote_get_memory_xfer_limit)
1353 (remote_search_memory, remote_rcmd, remote_memory_map)
1354 (remote_pid_to_str, remote_get_thread_local_address)
1355 (remote_get_tib_address, remote_read_description): Refactor as
1356 methods of remote_target.
1357 (remote_target::fileio_open, remote_target::fileio_pwrite)
1358 (remote_target::fileio_pread, remote_target::fileio_close): New.
1359 (remote_hostio_readlink, remote_hostio_fstat)
1360 (remote_filesystem_is_local, remote_can_execute_reverse)
1361 (remote_supports_non_stop, remote_supports_disable_randomization)
1362 (remote_supports_multi_process, remote_supports_cond_breakpoints)
1363 (remote_supports_enable_disable_tracepoint)
1364 (remote_supports_string_tracing)
1365 (remote_can_run_breakpoint_commands, remote_trace_init)
1366 (remote_download_tracepoint, remote_can_download_tracepoint)
1367 (remote_download_trace_state_variable, remote_enable_tracepoint)
1368 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
1369 (remote_trace_start, remote_get_trace_status)
1370 (remote_get_tracepoint_status, remote_trace_stop)
1371 (remote_trace_find, remote_get_trace_state_variable_value)
1372 (remote_save_trace_data, remote_get_raw_trace_data)
1373 (remote_set_disconnected_tracing, remote_core_of_thread)
1374 (remote_set_circular_trace_buffer, remote_traceframe_info)
1375 (remote_get_min_fast_tracepoint_insn_len)
1376 (remote_set_trace_buffer_size, remote_set_trace_notes)
1377 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
1378 (remote_disable_btrace, remote_teardown_btrace)
1379 (remote_read_btrace, remote_btrace_conf)
1380 (remote_augmented_libraries_svr4_read, remote_load)
1381 (remote_pid_to_exec_file, remote_can_do_single_step)
1382 (remote_execution_direction, remote_thread_handle_to_thread_info):
1383 Refactor as methods of remote_target.
1384 (init_remote_ops, init_extended_remote_ops): Delete.
1385 (remote_can_async_p, remote_is_async_p, remote_async)
1386 (remote_thread_events, remote_upload_tracepoints)
1387 (remote_upload_trace_state_variables): Refactor as methods of
1388 remote_target.
1389 (_initialize_remote): Remove references to init_remote_ops and
1390 init_extended_remote_ops.
1391
1392 * remote-sim.c (gdbsim_target): New class.
1393 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
1394 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
1395 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
1396 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
1397 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
1398 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
1399 Refactor as methods of gdbsim_target.
1400 (gdbsim_ops): Now a gdbsim_target.
1401 (init_gdbsim_ops): Delete.
1402 (gdbsim_cntrl_c): Adjust.
1403 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
1404
1405 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
1406 (the_amd64_linux_nat_target): New.
1407 (amd64_linux_fetch_inferior_registers)
1408 (amd64_linux_store_inferior_registers): Refactor as methods of
1409 amd64_linux_nat_target.
1410 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
1411 * i386-linux-nat.c: Don't include "linux-nat.h".
1412 (i386_linux_nat_target): New class.
1413 (the_i386_linux_nat_target): New.
1414 (i386_linux_fetch_inferior_registers)
1415 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
1416 as methods of i386_linux_nat_target.
1417 (_initialize_i386_linux_nat): Adjust. Set linux_target.
1418 * inf-child.c (inf_child_ops): Delete.
1419 (inf_child_fetch_inferior_registers)
1420 (inf_child_store_inferior_registers): Delete.
1421 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
1422 methods of inf_child_target.
1423 (inf_child_target::supports_terminal_ours)
1424 (inf_child_target::terminal_init)
1425 (inf_child_target::terminal_inferior)
1426 (inf_child_target::terminal_ours_for_output)
1427 (inf_child_target::terminal_ours, inf_child_target::interrupt)
1428 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
1429 New.
1430 (inf_child_open, inf_child_disconnect, inf_child_close)
1431 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
1432 (inf_child_post_startup_inferior, inf_child_can_run)
1433 (inf_child_pid_to_exec_file): Refactor as methods of
1434 inf_child_target.
1435 (inf_child_follow_fork): Delete.
1436 (inf_child_target::can_create_inferior)
1437 (inf_child_target::can_attach): New.
1438 (inf_child_target::has_all_memory, inf_child_target::has_memory)
1439 (inf_child_target::has_stack, inf_child_target::has_registers)
1440 (inf_child_target::has_execution): New.
1441 (inf_child_fileio_open, inf_child_fileio_pwrite)
1442 (inf_child_fileio_pread, inf_child_fileio_fstat)
1443 (inf_child_fileio_close, inf_child_fileio_unlink)
1444 (inf_child_fileio_readlink, inf_child_use_agent)
1445 (inf_child_can_use_agent): Refactor as methods of
1446 inf_child_target.
1447 (return_zero, inf_child_target): Delete.
1448 (inf_child_target::inf_child_target): New.
1449 * inf-child.h: Include "target.h".
1450 (inf_child_target): Delete function prototype.
1451 (inf_child_target): New class.
1452 (inf_child_open_target, inf_child_mourn_inferior)
1453 (inf_child_maybe_unpush_target): Delete.
1454 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
1455 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
1456 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
1457 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
1458 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
1459 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
1460 (inf_ptrace_wait, inf_ptrace_xfer_partial)
1461 (inf_ptrace_thread_alive, inf_ptrace_files_info)
1462 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
1463 methods of inf_ptrace_target.
1464 (inf_ptrace_target): Delete function.
1465 * inf-ptrace.h: Include "inf-child.h".
1466 (inf_ptrace_target): Delete function declaration.
1467 (inf_ptrace_target): New class.
1468 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
1469 * linux-nat.c (linux_target): New.
1470 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
1471 (linux_nat_target::~linux_nat_target): New.
1472 (linux_child_post_attach, linux_child_post_startup_inferior)
1473 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
1474 (linux_child_remove_fork_catchpoint)
1475 (linux_child_insert_vfork_catchpoint)
1476 (linux_child_remove_vfork_catchpoint)
1477 (linux_child_insert_exec_catchpoint)
1478 (linux_child_remove_exec_catchpoint)
1479 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
1480 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
1481 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
1482 (linux_nat_stopped_data_address)
1483 (linux_nat_stopped_by_sw_breakpoint)
1484 (linux_nat_supports_stopped_by_sw_breakpoint)
1485 (linux_nat_stopped_by_hw_breakpoint)
1486 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
1487 (linux_nat_kill, linux_nat_mourn_inferior)
1488 (linux_nat_xfer_partial, linux_nat_thread_alive)
1489 (linux_nat_update_thread_list, linux_nat_pid_to_str)
1490 (linux_nat_thread_name, linux_child_pid_to_exec_file)
1491 (linux_child_static_tracepoint_markers_by_strid)
1492 (linux_nat_is_async_p, linux_nat_can_async_p)
1493 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
1494 (linux_nat_supports_multi_process)
1495 (linux_nat_supports_disable_randomization, linux_nat_async)
1496 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
1497 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
1498 (linux_nat_fileio_open, linux_nat_fileio_readlink)
1499 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
1500 methods of linux_nat_target.
1501 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
1502 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
1503 parameter.
1504 (check_stopped_by_watchpoint): Adjust.
1505 (linux_xfer_partial): Delete.
1506 (linux_target_install_ops, linux_target, linux_nat_add_target):
1507 Delete.
1508 (linux_nat_target::linux_nat_target): New.
1509 * linux-nat.h: Include "inf-ptrace.h".
1510 (linux_nat_target): New.
1511 (linux_target, linux_target_install_ops, linux_nat_add_target):
1512 Delete function declarations.
1513 (linux_target): Declare global.
1514 * linux-thread-db.c (thread_db_target): New.
1515 (thread_db_target::thread_db_target): New.
1516 (thread_db_ops): Delete.
1517 (the_thread_db_target): New.
1518 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
1519 (thread_db_update_thread_list, thread_db_pid_to_str)
1520 (thread_db_extra_thread_info)
1521 (thread_db_thread_handle_to_thread_info)
1522 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
1523 (thread_db_resume): Refactor as methods of thread_db_target.
1524 (init_thread_db_ops): Delete.
1525 (_initialize_thread_db): Remove reference to init_thread_db_ops.
1526 * x86-linux-nat.c: Don't include "linux-nat.h".
1527 (super_post_startup_inferior): Delete.
1528 (x86_linux_nat_target::~x86_linux_nat_target): New.
1529 (x86_linux_child_post_startup_inferior)
1530 (x86_linux_read_description, x86_linux_enable_btrace)
1531 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
1532 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
1533 methods of x86_linux_nat_target.
1534 (x86_linux_create_target): Delete. Bits folded ...
1535 (x86_linux_add_target): ... here. Now takes a linux_nat_target
1536 pointer.
1537 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
1538 (x86_linux_nat_target): New class.
1539 (x86_linux_create_target): Delete.
1540 (x86_linux_add_target): Now takes a linux_nat_target pointer.
1541 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
1542 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
1543 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
1544 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
1545 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
1546 make extern.
1547 (x86_use_watchpoints): Delete.
1548 * x86-nat.h: Include "breakpoint.h" and "target.h".
1549 (x86_use_watchpoints): Delete.
1550 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
1551 (x86_stopped_by_watchpoint, x86_stopped_data_address)
1552 (x86_insert_watchpoint, x86_remove_watchpoint)
1553 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
1554 (x86_stopped_by_hw_breakpoint): New declarations.
1555 (x86_nat_target): New template class.
1556
1557 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
1558 (the_ppc_linux_nat_target): New.
1559 (ppc_linux_fetch_inferior_registers)
1560 (ppc_linux_can_use_hw_breakpoint)
1561 (ppc_linux_region_ok_for_hw_watchpoint)
1562 (ppc_linux_ranged_break_num_registers)
1563 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
1564 (ppc_linux_insert_mask_watchpoint)
1565 (ppc_linux_remove_mask_watchpoint)
1566 (ppc_linux_can_accel_watchpoint_condition)
1567 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
1568 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
1569 (ppc_linux_watchpoint_addr_within_range)
1570 (ppc_linux_masked_watch_num_registers)
1571 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
1572 (ppc_linux_read_description): Refactor as methods of
1573 ppc_linux_nat_target.
1574 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
1575
1576 * procfs.c (procfs_xfer_partial): Delete forward declaration.
1577 (procfs_target): New class.
1578 (the_procfs_target): New.
1579 (procfs_target): Delete function.
1580 (procfs_auxv_parse, procfs_attach, procfs_detach)
1581 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
1582 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
1583 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
1584 (procfs_create_inferior, procfs_update_thread_list)
1585 (procfs_thread_alive, procfs_pid_to_str)
1586 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
1587 (procfs_stopped_data_address, procfs_insert_watchpoint)
1588 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
1589 (proc_find_memory_regions, procfs_info_proc)
1590 (procfs_make_note_section): Refactor as methods of procfs_target.
1591 (_initialize_procfs): Adjust.
1592 * sol-thread.c (sol_thread_target): New class.
1593 (sol_thread_ops): Now a sol_thread_target.
1594 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
1595 (sol_thread_fetch_registers, sol_thread_store_registers)
1596 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
1597 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
1598 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
1599 (init_sol_thread_ops): Delete.
1600 (_initialize_sol_thread): Adjust. Remove references to
1601 init_sol_thread_ops and complete_target_initialization.
1602
1603 * windows-nat.c (windows_nat_target): New class.
1604 (windows_fetch_inferior_registers)
1605 (windows_store_inferior_registers, windows_resume, windows_wait)
1606 (windows_attach, windows_detach, windows_pid_to_exec_file)
1607 (windows_files_info, windows_create_inferior)
1608 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
1609 (windows_close, windows_pid_to_str, windows_xfer_partial)
1610 (windows_get_tib_address, windows_get_ada_task_ptid)
1611 (windows_thread_name, windows_thread_alive): Refactor as
1612 windows_nat_target methods.
1613 (do_initial_windows_stuff): Adjust.
1614 (windows_target): Delete function.
1615 (_initialize_windows_nat): Adjust.
1616
1617 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
1618 (darwin_mourn_inferior, darwin_kill_inferior)
1619 (darwin_create_inferior, darwin_attach, darwin_detach)
1620 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
1621 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
1622 (darwin_supports_multi_process): Refactor as darwin_nat_target
1623 methods.
1624 (darwin_resume_to, darwin_files_info): Delete.
1625 (_initialize_darwin_inferior): Rename to ...
1626 (_initialize_darwin_nat): ... this. Adjust to C++ification.
1627 * darwin-nat.h: Include "inf-child.h".
1628 (darwin_nat_target): New class.
1629 (darwin_complete_target): Delete.
1630 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
1631 (darwin_target): New.
1632 (i386_darwin_fetch_inferior_registers)
1633 (i386_darwin_store_inferior_registers): Refactor as methods of
1634 darwin_nat_target.
1635 (darwin_complete_target): Delete, with ...
1636 (_initialize_i386_darwin_nat): ... bits factored out here.
1637
1638 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
1639 (the_alpha_linux_nat_target): New.
1640 (alpha_linux_register_u_offset): Refactor as
1641 alpha_linux_nat_target method.
1642 (_initialize_alpha_linux_nat): Adjust.
1643 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
1644 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
1645 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
1646 methods of linux_nat_trad_target.
1647 (linux_trad_target): Delete.
1648 * linux-nat-trad.h (linux_trad_target): Delete function.
1649 (linux_nat_trad_target): New class.
1650 * mips-linux-nat.c (mips_linux_nat_target): New class.
1651 (super_fetch_registers, super_store_registers, super_close):
1652 Delete.
1653 (the_mips_linux_nat_target): New.
1654 (mips64_linux_regsets_fetch_registers)
1655 (mips64_linux_regsets_store_registers)
1656 (mips64_linux_fetch_registers, mips64_linux_store_registers)
1657 (mips_linux_register_u_offset, mips_linux_read_description)
1658 (mips_linux_can_use_hw_breakpoint)
1659 (mips_linux_stopped_by_watchpoint)
1660 (mips_linux_stopped_data_address)
1661 (mips_linux_region_ok_for_hw_watchpoint)
1662 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
1663 (mips_linux_close): Refactor as methods of mips_linux_nat.
1664 (_initialize_mips_linux_nat): Adjust to C++ification.
1665
1666 * aix-thread.c (aix_thread_target): New class.
1667 (aix_thread_ops): Now an aix_thread_target.
1668 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
1669 (aix_thread_fetch_registers, aix_thread_store_registers)
1670 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
1671 (aix_thread_thread_alive, aix_thread_pid_to_str)
1672 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
1673 Refactor as methods of aix_thread_target.
1674 (init_aix_thread_ops): Delete.
1675 (_initialize_aix_thread): Remove references to init_aix_thread_ops
1676 and complete_target_initialization.
1677 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
1678 (rs6000_nat_target): New class.
1679 (the_rs6000_nat_target): New.
1680 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
1681 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
1682 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
1683 (super_create_inferior): Delete.
1684 (_initialize_rs6000_nat): Adjust to C++ification.
1685
1686 * arm-linux-nat.c (arm_linux_nat_target): New class.
1687 (the_arm_linux_nat_target): New.
1688 (arm_linux_fetch_inferior_registers)
1689 (arm_linux_store_inferior_registers, arm_linux_read_description)
1690 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
1691 (arm_linux_remove_hw_breakpoint)
1692 (arm_linux_region_ok_for_hw_watchpoint)
1693 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
1694 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
1695 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
1696 arm_linux_nat_target.
1697 (_initialize_arm_linux_nat): Adjust to C++ification.
1698
1699 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
1700 (the_aarch64_linux_nat_target): New.
1701 (aarch64_linux_fetch_inferior_registers)
1702 (aarch64_linux_store_inferior_registers)
1703 (aarch64_linux_child_post_startup_inferior)
1704 (aarch64_linux_read_description)
1705 (aarch64_linux_can_use_hw_breakpoint)
1706 (aarch64_linux_insert_hw_breakpoint)
1707 (aarch64_linux_remove_hw_breakpoint)
1708 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
1709 (aarch64_linux_region_ok_for_hw_watchpoint)
1710 (aarch64_linux_stopped_data_address)
1711 (aarch64_linux_stopped_by_watchpoint)
1712 (aarch64_linux_watchpoint_addr_within_range)
1713 (aarch64_linux_can_do_single_step): Refactor as methods of
1714 aarch64_linux_nat_target.
1715 (super_post_startup_inferior): Delete.
1716 (_initialize_aarch64_linux_nat): Adjust to C++ification.
1717
1718 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
1719 (the_hppa_linux_nat_target): New.
1720 (hppa_linux_fetch_inferior_registers)
1721 (hppa_linux_store_inferior_registers): Refactor as methods of
1722 hppa_linux_nat_target.
1723 (_initialize_hppa_linux_nat): Adjust to C++ification.
1724
1725 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
1726 (the_ia64_linux_nat_target): New.
1727 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
1728 (ia64_linux_stopped_data_address)
1729 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
1730 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
1731 ia64_linux_nat_target methods.
1732 (super_xfer_partial): Delete.
1733 (_initialize_ia64_linux_nat): Adjust to C++ification.
1734
1735 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
1736 (the_m32r_linux_nat_target): New.
1737 (m32r_linux_fetch_inferior_registers)
1738 (m32r_linux_store_inferior_registers): Refactor as
1739 m32r_linux_nat_target methods.
1740 (_initialize_m32r_linux_nat): Adjust to C++ification.
1741
1742 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
1743 (the_m68k_linux_nat_target): New.
1744 (m68k_linux_fetch_inferior_registers)
1745 (m68k_linux_store_inferior_registers): Refactor as
1746 m68k_linux_nat_target methods.
1747 (_initialize_m68k_linux_nat): Adjust to C++ification.
1748
1749 * s390-linux-nat.c (s390_linux_nat_target): New class.
1750 (the_s390_linux_nat_target): New.
1751 (s390_linux_fetch_inferior_registers)
1752 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
1753 (s390_insert_watchpoint, s390_remove_watchpoint)
1754 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
1755 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
1756 (s390_auxv_parse, s390_read_description): Refactor as methods of
1757 s390_linux_nat_target.
1758 (_initialize_s390_nat): Adjust to C++ification.
1759
1760 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
1761 (the_sparc_linux_nat_target): New.
1762 (_initialize_sparc_linux_nat): Adjust to C++ification.
1763 * sparc-nat.c (sparc_fetch_inferior_registers)
1764 (sparc_store_inferior_registers): Remove target_ops parameter.
1765 * sparc-nat.h (sparc_fetch_inferior_registers)
1766 (sparc_store_inferior_registers): Remove target_ops parameter.
1767 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
1768 (the_sparc64_linux_nat_target): New.
1769 (_initialize_sparc64_linux_nat): Adjust to C++ification.
1770
1771 * spu-linux-nat.c (spu_linux_nat_target): New class.
1772 (the_spu_linux_nat_target): New.
1773 (spu_child_post_startup_inferior, spu_child_post_attach)
1774 (spu_child_wait, spu_fetch_inferior_registers)
1775 (spu_store_inferior_registers, spu_xfer_partial)
1776 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
1777 methods.
1778 (_initialize_spu_nat): Adjust to C++ification.
1779
1780 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
1781 (the_tilegx_linux_nat_target): New.
1782 (fetch_inferior_registers, store_inferior_registers):
1783 Refactor as methods.
1784 (_initialize_tile_linux_nat): Adjust to C++ification.
1785
1786 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
1787 (the_xtensa_linux_nat_target): New.
1788 (xtensa_linux_fetch_inferior_registers)
1789 (xtensa_linux_store_inferior_registers): Refactor as
1790 xtensa_linux_nat_target methods.
1791 (_initialize_xtensa_linux_nat): Adjust to C++ification.
1792
1793 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
1794 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
1795 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
1796 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
1797 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
1798 (fbsd_stopped_by_sw_breakpoint)
1799 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
1800 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
1801 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
1802 (fbsd_post_startup_inferior, fbsd_post_attach)
1803 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
1804 (fbsd_set_syscall_catchpoint)
1805 (super_xfer_partial, super_resume, super_wait)
1806 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
1807 (fbsd_handle_debug_trap): Remove target_ops parameter.
1808 (fbsd_nat_add_target): Delete.
1809 * fbsd-nat.h: Include "inf-ptrace.h".
1810 (fbsd_nat_add_target): Delete.
1811 (USE_SIGTRAP_SIGINFO): Define.
1812 (fbsd_nat_target): New class.
1813
1814 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
1815 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
1816 (amd64bsd_target): Delete.
1817 * amd64-bsd-nat.h: New file.
1818 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
1819 "x86-bsd-nat.h".
1820 (amd64_fbsd_nat_target): New class.
1821 (the_amd64_fbsd_nat_target): New.
1822 (amd64fbsd_read_description): Refactor as method of
1823 amd64_fbsd_nat_target.
1824 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
1825 (_initialize_amd64fbsd_nat): Adjust to C++ification.
1826 * amd64-nat.h (amd64bsd_target): Delete function declaration.
1827 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
1828 (i386bsd_store_inferior_registers): Remove target_ops parameter.
1829 (i386bsd_target): Delete.
1830 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
1831 (i386bsd_fetch_inferior_registers)
1832 (i386bsd_store_inferior_registers): Declare.
1833 (i386_bsd_nat_target): New class.
1834 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
1835 (the_i386_fbsd_nat_target): New.
1836 (i386fbsd_resume, i386fbsd_read_description): Refactor as
1837 i386_fbsd_nat_target methods.
1838 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
1839 (_initialize_i386fbsd_nat): Adjust to C++ification.
1840 * x86-bsd-nat.c (super_mourn_inferior): Delete.
1841 (x86bsd_mourn_inferior, x86bsd_target): Delete.
1842 (_initialize_x86_bsd_nat): Adjust to C++ification.
1843 * x86-bsd-nat.h: Include "x86-nat.h".
1844 (x86bsd_target): Delete declaration.
1845 (x86bsd_nat_target): New class.
1846
1847 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
1848 (the_aarch64_fbsd_nat_target): New.
1849 (aarch64_fbsd_fetch_inferior_registers)
1850 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
1851 aarch64_fbsd_nat_target.
1852 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
1853 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
1854 (the_alpha_bsd_nat_target): New.
1855 (alphabsd_fetch_inferior_registers)
1856 (alphabsd_store_inferior_registers): Refactor as
1857 alpha_bsd_nat_target methods.
1858 (_initialize_alphabsd_nat): Refactor as methods of
1859 alpha_bsd_nat_target.
1860 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
1861 (the_amd64_nbsd_nat_target): New.
1862 (_initialize_amd64nbsd_nat): Adjust to C++ification.
1863 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
1864 (the_amd64_obsd_nat_target): New.
1865 (_initialize_amd64obsd_nat): Adjust to C++ification.
1866 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
1867 (the_arm_fbsd_nat_target): New.
1868 (arm_fbsd_fetch_inferior_registers)
1869 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
1870 (_initialize_arm_fbsd_nat): Refactor as methods of
1871 arm_fbsd_nat_target.
1872 (_initialize_arm_fbsd_nat): Adjust to C++ification.
1873 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
1874 (the_arm_netbsd_nat_target): New.
1875 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
1876 arm_netbsd_nat_target.
1877 (_initialize_arm_netbsd_nat): Adjust to C++ification.
1878 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
1879 (the_hppa_nbsd_nat_target): New.
1880 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
1881 hppa_nbsd_nat_target methods.
1882 (_initialize_hppanbsd_nat): Adjust to C++ification.
1883 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
1884 (the_hppa_obsd_nat_target): New.
1885 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
1886 methods of hppa_obsd_nat_target.
1887 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
1888 add_target.
1889 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
1890 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
1891 add_target.
1892 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
1893 (_initialize_i386obsd_nat): Use add_target.
1894 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
1895 (the_m68k_bsd_nat_target): New.
1896 (m68kbsd_fetch_inferior_registers)
1897 (m68kbsd_store_inferior_registers): Refactor as methods of
1898 m68k_bsd_nat_target.
1899 (_initialize_m68kbsd_nat): Adjust to C++ification.
1900 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
1901 (the_mips_fbsd_nat_target): New.
1902 (mips_fbsd_fetch_inferior_registers)
1903 (mips_fbsd_store_inferior_registers): Refactor as methods of
1904 mips_fbsd_nat_target.
1905 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
1906 add_target.
1907 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
1908 (the_mips_nbsd_nat_target): New.
1909 (mipsnbsd_fetch_inferior_registers)
1910 (mipsnbsd_store_inferior_registers): Refactor as methods of
1911 mips_nbsd_nat_target.
1912 (_initialize_mipsnbsd_nat): Adjust to C++ification.
1913 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
1914 (the_mips64_obsd_nat_target): New.
1915 (mips64obsd_fetch_inferior_registers)
1916 (mips64obsd_store_inferior_registers): Refactor as methods of
1917 mips64_obsd_nat_target.
1918 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
1919 add_target.
1920 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
1921 nbsd_nat_target.
1922 * nbsd-nat.h: Include "inf-ptrace.h".
1923 (nbsd_nat_target): New class.
1924 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
1925 (obsd_wait): Refactor as methods of obsd_nat_target.
1926 (obsd_add_target): Delete.
1927 * obsd-nat.h: Include "inf-ptrace.h".
1928 (obsd_nat_target): New class.
1929 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
1930 (the_ppc_fbsd_nat_target): New.
1931 (ppcfbsd_fetch_inferior_registers)
1932 (ppcfbsd_store_inferior_registers): Refactor as methods of
1933 ppc_fbsd_nat_target.
1934 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
1935 add_target.
1936 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
1937 (the_ppc_nbsd_nat_target): New.
1938 (ppcnbsd_fetch_inferior_registers)
1939 (ppcnbsd_store_inferior_registers): Refactor as methods of
1940 ppc_nbsd_nat_target.
1941 (_initialize_ppcnbsd_nat): Adjust to C++ification.
1942 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
1943 (the_ppc_obsd_nat_target): New.
1944 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
1945 methods of ppc_obsd_nat_target.
1946 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
1947 add_target.
1948 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
1949 (the_sh_nbsd_nat_target): New.
1950 (shnbsd_fetch_inferior_registers)
1951 (shnbsd_store_inferior_registers): Refactor as methods of
1952 sh_nbsd_nat_target.
1953 (_initialize_shnbsd_nat): Adjust to C++ification.
1954 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
1955 (inf_ptrace_xfer_partial): Delete.
1956 (sparc_xfer_partial, sparc_target): Delete.
1957 * sparc-nat.h (sparc_fetch_inferior_registers)
1958 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
1959 (sparc_target): Delete function declaration.
1960 (sparc_target): New template class.
1961 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
1962 (_initialize_sparcnbsd_nat): Adjust to C++ification.
1963 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
1964 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
1965 add_target.
1966 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
1967 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
1968 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
1969 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
1970 add_target.
1971 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
1972 (the_vax_bsd_nat_target): New.
1973 (vaxbsd_fetch_inferior_registers)
1974 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
1975 methods.
1976 (_initialize_vaxbsd_nat): Adjust to C++ification.
1977
1978 * bsd-kvm.c (bsd_kvm_target): New class.
1979 (bsd_kvm_ops): Now a bsd_kvm_target.
1980 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
1981 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
1982 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
1983 bsd_kvm_target.
1984 (bsd_kvm_return_one): Delete.
1985 (bsd_kvm_add_target): Adjust to C++ification.
1986
1987 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
1988 (nto_procfs_target_procfs): New classes.
1989 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
1990 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
1991 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
1992 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
1993 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
1994 (procfs_remove_hw_breakpoint, procfs_resume)
1995 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
1996 (procfs_kill_inferior, procfs_store_registers)
1997 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
1998 as methods of nto_procfs_target.
1999 (nto_procfs_ops): Now an nto_procfs_target_procfs.
2000 (nto_native_ops): Delete.
2001 (procfs_open, procfs_native_open): Delete.
2002 (nto_native_ops): Now an nto_procfs_target_native.
2003 (init_procfs_targets): Adjust to C++ification.
2004 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
2005 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
2006 Refactor as methods of nto_procfs_target.
2007
2008 * go32-nat.c (go32_nat_target): New class.
2009 (the_go32_nat_target): New.
2010 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
2011 (go32_store_registers, go32_xfer_partial, go32_files_info)
2012 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
2013 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
2014 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
2015 (go32_pid_to_str): Refactor as methods of go32_nat_target.
2016 (go32_target): Delete.
2017 (_initialize_go32_nat): Adjust to C++ification.
2018
2019 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
2020 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
2021 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
2022 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
2023 gnu_nat_target.
2024 (gnu_target): Delete.
2025 * gnu-nat.h (gnu_target): Delete.
2026 (gnu_nat_target): New class.
2027 * i386-gnu-nat.c (gnu_base_target): New.
2028 (i386_gnu_nat_target): New class.
2029 (the_i386_gnu_nat_target): New.
2030 (_initialize_i386gnu_nat): Adjust to C++ification.
2031
3fffc070
PA
20322018-05-02 Pedro Alves <palves@redhat.com>
2033
2034 * bfd-target.c (target_bfd_xclose): Rename to ...
2035 (target_bfd_close): ... this.
2036 (target_bfd_reopen): Adjust.
2037 * target.c (target_close): Remove references to to_xclose.
2038 * target.h (target_ops::to_xclose): Delete.
2039 (target_ops::to_close): Update comments.
2040
6798487f
PA
20412018-05-02 Pedro Alves <palves@redhat.com>
2042
2043 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
2044 "linux-nat.h".
2045 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
2046 * inf-ptrace.c (inf_ptrace_register_u_offset)
2047 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
2048 (inf_ptrace_store_register, inf_ptrace_store_registers)
2049 (inf_ptrace_trad_target): Move to ...
2050 * linux-nat-trad.c: ... this new file.
2051 * linux-nat-trad.h: New file.
2052 * linux-nat.c (linux_target_install_ops): Make extern.
2053 (linux_trad_target): Delete.
2054 * linux-nat.h (linux_trad_target): Delete declaration.
2055 (linux_target_install_ops): Declare.
2056 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
2057 "linux-nat.h".
2058
c1955e17
PA
20592018-05-02 Pedro Alves <palves@redhat.com>
2060
2061 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
2062 procfs_target/add_target here.
2063 * procfs.c (procfs_target): Make static.
2064 (_initialize_procfs): Call add_target here.
2065 * procfs.h (struct target_ops): Remove forward declaration.
2066 (procfs_target): Remove declaration.
2067 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
2068
b5c8fcb1
PA
20692018-05-02 Pedro Alves <palves@redhat.com>
2070
2071 * procfs.c (procfs_stopped_by_watchpoint)
2072 (procfs_insert_watchpoint, procfs_remove_watchpoint)
2073 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
2074 Forward declare.
2075 (procfs_use_watchpoints): Delete, move contents...
2076 (procfs_target): ... here.
2077 * procfs.h (procfs_use_watchpoints): Delete declaration.
2078 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
2079 procfs_use_watchpoints.
2080 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
2081 procfs_use_watchpoints.
2082
0489430a
TT
20832018-05-02 Tom Tromey <tom@tromey.com>
2084
2085 PR python/20084:
2086 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
2087 and var_zuinteger_unlimited.
2088 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
2089 and PARAM_ZUINTEGER_UNLIMITED.
2090 (set_parameter_value): Handle var_zuinteger and
2091 var_zuinteger_unlimited.
2092 (add_setshow_generic): Likewise.
2093 (parmpy_init): Likewise.
2094
1632f8ba
DR
20952018-04-28 Dan Robertson <danlrobertson89@gmail.com>
2096
2097 PR rust/23124
2098 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
2099 pointer is not null before dereferencing it.
2100
76761936
TT
21012018-04-30 Tom Tromey <tom@tromey.com>
2102
2103 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
2104 is_mi_like_p.
2105
2d33446d
TT
21062018-04-30 Tom Tromey <tom@tromey.com>
2107
2108 * breakpoint.c (mention): Remove use of is_mi_like_p.
2109 (print_mention_ranged_breakpoint): Likewise.
2110 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
2111 of is_mi_like_p.
2112
f3c6abab
TT
21132018-04-30 Tom Tromey <tom@tromey.com>
2114
2115 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
2116
40c03530
TT
21172018-04-30 Tom Tromey <tom@tromey.com>
2118
2119 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
2120 (info_spu_event_command): Remove some uses of is_mi_like_p.
2121
2038b7fd
TT
21222018-04-30 Tom Tromey <tom@tromey.com>
2123
2124 * python/py-framefilter.c (py_print_single_arg)
2125 (enumerate_locals, py_print_args, py_print_frame): Remove some
2126 uses of is_mi_like_p.
2127
4904c3c6
TT
21282018-04-30 Tom Tromey <tom@tromey.com>
2129
2130 * ui-out.c: Update.
2131 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
2132 * ui-out.h (ui_out::is_mi_like_p): Now const.
2133 (ui_out::do_is_mi_like_p): Now const.
2134 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
2135
7c66fffc
TT
21362018-04-30 Tom Tromey <tom@tromey.com>
2137
2138 * varobj.c (varobj_set_visualizer): Use new_reference.
2139 * python/python.c (gdbpy_decode_line): Use new_reference.
2140 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
2141 new_reference.
2142
bbfa6f00
TT
21432018-04-30 Tom Tromey <tom@tromey.com>
2144
2145 * varobj.c (install_new_value): Use new_reference.
2146 * value.h (value_incref): Return void. Swap intro comment with
2147 value_decref.
2148 * value.c (set_value_parent): Use new_reference.
2149 (value_incref): Return void. Update intro comment.
2150 (release_value): Use new_reference.
2151 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
2152
1831a9f9
TT
21532018-04-30 Tom Tromey <tom@tromey.com>
2154
2155 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
2156 * gdb_bfd.h (new_bfd_ref): Remove.
2157 (gdb_bfd_open): Update comment.
2158 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
2159 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
2160 (gdb_bfd_fdopenr): Use new_reference.
2161 * exec.c (exec_file_attach): Use new_reference.
2162
7c1b5f3d
TT
21632018-04-30 Tom Tromey <tom@tromey.com>
2164
2165 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
2166 method.
2167
e11fb955
TT
21682018-04-30 Tom Tromey <tom@tromey.com>
2169
2170 * jit.c (jit_read_code_entry): Use type_align.
2171 * i386-tdep.c (i386_gdbarch_init): Don't call
2172 set_gdbarch_long_long_align_bit.
2173 * gdbarch.sh: Remove long_long_align_bit.
2174 * gdbarch.c, gdbarch.h: Rebuild.
2175 * arc-tdep.c (arc_type_align): New function.
2176 (arc_gdbarch_init): Use arc_type_align. Don't call
2177 set_gdbarch_long_long_align_bit.
2178
2fff16dd
TT
21792018-04-30 Tom Tromey <tom@tromey.com>
2180
2181 * rust-lang.c (rust_type_alignment): Remove.
2182 (rust_composite_type): Use type_align.
2183
6d7bb824
TT
21842018-04-30 Tom Tromey <tom@tromey.com>
2185
2186 * NEWS: Mention Type.align.
2187 * python/py-type.c (typy_get_alignof): New function.
2188 (type_object_getset): Add "alignof".
2189
007e1530
TT
21902018-04-30 Tom Tromey <tom@tromey.com>
2191
2192 PR exp/17095:
2193 * NEWS: Update.
2194 * std-operator.def (UNOP_ALIGNOF): New operator.
2195 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
2196 New.
2197 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
2198 * c-lang.c (c_op_print_tab): Add alignof.
2199 * c-exp.y (ALIGNOF): New token.
2200 (exp): Add "ALIGNOF" production.
2201 (ident_tokens): Add _Alignof and alignof.
2202
2b4424c3
TT
22032018-04-30 Tom Tromey <tom@tromey.com>
2204
2205 * i386-tdep.c (i386_type_align): New function.
2206 (i386_gdbarch_init): Update.
2207 * gdbarch.sh (type_align): New method.
2208 * gdbarch.c, gdbarch.h: Rebuild.
2209 * arch-utils.h (default_type_align): Declare.
2210 * arch-utils.c (default_type_align): New function.
2211 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
2212 (struct type) <align_log2>: New field.
2213 <instance_flags>: Now a bitfield.
2214 (TYPE_RAW_ALIGN): New macro.
2215 (type_align, type_raw_align, set_type_align): Declare.
2216 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
2217 functions.
2218 * dwarf2read.c (quirk_rust_enum): Set type alignment.
2219 (get_alignment, maybe_set_alignment): New functions.
2220 (read_structure_type, read_enumeration_type, read_array_type)
2221 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
2222 (read_subrange_type, read_base_type): Set type alignment.
2223
d33bc52e
SM
22242018-04-30 Simon Marchi <simon.marchi@ericsson.com>
2225
2226 * dwarf2read.c (read_index_from_section): Use bool.
2227
e28b63a9
FG
22282018-04-29 Fabian Groffen <grobian@gentoo.org>
2229
2230 PR gdb/22950
2231 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
2232 with #ifdef.
2233
cd8c76e4
JR
22342018-04-29 John Reiser <jreiser@BitWagon.com>
2235
2236 PR build/22873
2237 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
2238 last step, and do it atomically.
2239
476d250e
AO
22402018-04-27 Alexandre Oliva <aoliva@redhat.com>
2241
2242 * compile/compile-c-types.c (convert_int, convert_float):
2243 Update for C FE v1.
2244
6873858b
TT
22452018-04-27 Tom Tromey <tom@tromey.com>
2246
2247 PR rust/22545:
2248 * rust-lang.c (rust_inclusive_range_type_p): New function.
2249 (rust_range): Handle inclusive ranges.
2250 (rust_compute_range): Likewise.
2251 * rust-exp.y (struct rust_op) <inclusive>: New field.
2252 (DOTDOTEQ): New constant.
2253 (range_expr): Add "..=" productions.
2254 (operator_tokens): Add "..=" token.
2255 (ast_range): Add "inclusive" parameter.
2256 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
2257 ranges.
2258 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
2259 bounds values.
2260 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
2261 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
2262 Update comments.
2263 * expprint.c (print_subexp_standard): Handle new bounds values.
2264 (dump_subexp_body_standard): Likewise.
2265
632e107b
TT
22662018-04-27 Tom Tromey <tom@tromey.com>
2267
2268 * configure: Rebuild.
2269 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
2270 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
2271 "OVERRIDE".
2272 (class symbol_needs_eval_context): Likewise.
2273 * dwarf2read.c (mock_mapped_index::symbol_name_count)
2274 (mock_mapped_index::symbol_name_at): Use "override". Remove
2275 "virtual".
2276 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
2277 "override".
2278 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
2279 * aarch64-tdep.c (instruction_reader::read): Use "override".
2280 (instruction_reader_test::read): Likewise.
2281 * arm-tdep.c (instruction_reader::read): Use "override".
2282 (instruction_reader_thumb::read): Likewise.
2283
b75abf5b
AK
22842018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
2285
2286 PR remote/9665
2287 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
2288 instead of remote_send.
2289 (remote_send): Remove.
2290
79188d8d
PA
22912018-04-26 Pedro Alves <palves@redhat.com>
2292
2293 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
2294 find_function_start_sal instead of find_pc_line.
2295
f50776aa
PA
22962018-04-26 Pedro Alves <palves@redhat.com>
2297
2298 * breakpoint.c (set_breakpoint_location_function): Handle
2299 mst_data_gnu_ifunc.
2300 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
2301 * elfread.c (elf_symtab_read): Give data symbols with
2302 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
2303 (elf_rel_plt_read): Update comment.
2304 * linespec.c (convert_linespec_to_sals): Handle
2305 mst_data_gnu_ifunc.
2306 (minsym_found): Handle mst_data_gnu_ifunc.
2307 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
2308 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
2309 * parse.c (find_minsym_type_and_address): Handle
2310 mst_data_gnu_ifunc.
2311 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
2312 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
2313 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
2314 comment.
2315 <mst_data_gnu_ifunc>: New enumerator.
2316
20944a6e
PA
23172018-04-26 Pedro Alves <palves@redhat.com>
2318
2319 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
2320 (lookup_minimal_symbol_by_pc_section): ... this. Replace
2321 'want_trampoline' parameter by a lookup_msym_prefer parameter.
2322 Handle it.
2323 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
2324 (lookup_minimal_symbol_by_pc): Adjust.
2325 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
2326 (lookup_solib_trampoline_symbol_by_pc): Adjust.
2327 * minsyms.h (lookup_msym_prefer): New enum.
2328 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
2329 parameter by a lookup_msym_prefer parameter.
2330
1adeb822
PA
23312018-04-26 Pedro Alves <palves@redhat.com>
2332
2333 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
2334 ends in "@plt" instead of looking at the symbol's section.
2335
a0aca7b0
PA
23362018-04-26 Pedro Alves <palves@redhat.com>
2337
2338 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
2339 all references.
2340 (find_pc_partial_function_gnu_ifunc): Rename to ...
2341 (find_pc_partial_function): ... this, and remove references to
2342 'is_gnu_ifunc_p'.
2343 (find_pc_partial_function): Delete old implementation.
2344 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
2345
76af0f26
PA
23462018-04-26 Pedro Alves <palves@redhat.com>
2347
2348 * linespec.c (struct bound_minimal_symbol_search_key): New.
2349 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
2350 skip first line if we found a GNU ifunc minimal symbol by name.
2351 (compare_msymbols): Change parameters to work with a destructured
2352 lhs minsym.
2353 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
2354 functions.
2355
3467ec66
PA
23562018-04-26 Pedro Alves <palves@redhat.com>
2357
2358 * breakpoint.c (set_breakpoint_location_function): Don't resolve
2359 ifunc targets here. Instead, if we have an ifunc minsym, use its
2360 address/name.
2361 (add_location_to_breakpoint): Store the minsym and the objfile in
2362 the breakpoint location.
2363 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
2364 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
2365 Record the minsym in the sal.
2366 * symtab.h (symtab_and_line) <msymbol>: New field.
2367
28f4fa4d
PA
23682018-04-26 Pedro Alves <palves@redhat.com>
2369
2370 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
2371 unless we actually resolved the ifunc.
2372
ca31ab1d
PA
23732018-04-26 Pedro Alves <palves@redhat.com>
2374
2375 * c-exp.y (variable production): Prefer ifunc minsyms over
2376 regular function symbols.
2377 * symtab.c (find_gnu_ifunc): New function.
2378 * minsyms.h (lookup_msym_prefer): New enum.
2379 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
2380 parameter by a lookup_msym_prefer parameter.
2381 * symtab.h (find_gnu_ifunc): New declaration.
2382
8388016d
PA
23832018-04-26 Pedro Alves <palves@redhat.com>
2384
2385 * blockframe.c (find_gnu_ifunc_target_type): New function.
2386 (find_function_type): New.
2387 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
2388 return a value with a memory address.
2389 (eval_call): For calls to GNU ifunc functions, try to find the
2390 type of the target function from the type that the resolver
2391 returns.
2392 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
2393 symbols.
2394 * infcall.c (find_function_return_type): Delete.
2395 (find_function_addr): Add 'function_type' parameter. For calls to
2396 GNU ifunc functions, try to find the type of the target function
2397 from the type that the resolver returns, and return it via
2398 FUNCTION_TYPE.
2399 (call_function_by_hand_dummy): Adjust to use the function type
2400 returned by find_function_addr.
2401 (find_function_addr): Add 'function_type' parameter and move
2402 description here.
2403 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
2404 declarations.
2405
a376e11d
PA
24062018-04-26 Pedro Alves <palves@redhat.com>
2407
2408 * c-exp.y (variable production): Skip finding an alias for ifunc
2409 symbols.
2410
02e169e2
PA
24112018-04-26 Pedro Alves <palves@redhat.com>
2412
2413 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
2414
249b5733
PA
24152018-04-25 Pedro Alves <palves@redhat.com>
2416
2417 * infcmd.c (kill_command): Print the pid as string, not the whole
2418 thread's ptid. Add comment. s/has been killed/killed/ in output
2419 message.
2420 * remote.c (remote_detach_1): Print the pid as string, not the
2421 whole thread's ptid.
2422
f67c0c91
SDJ
24232018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
2424 Sergio Durigan Junior <sergiodj@redhat.com>
2425 Pedro Alves <palves@redhat.com>
2426
2427 * infcmd.c (kill_command): Print message when inferior has
2428 been killed.
2429 * inferior.c (print_inferior_events): Remove 'static'. Set as
2430 '1'.
2431 (add_inferior): Improve message printed when
2432 'print_inferior_events' is on.
2433 (exit_inferior): Remove message printed when
2434 'print_inferior_events' is on.
2435 (detach_inferior): Improve message printed when
2436 'print_inferior_events' is on.
2437 (initialize_inferiors): Use 'add_inferior_silent' to set
2438 'current_inferior_'.
2439 * inferior.h (print_inferior_events): Declare here as
2440 'extern'.
2441 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
2442 '[Detaching...]' messages when 'print_inferior_events' is on.
2443 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
2444 as prefix/suffix for messages. Remove periods. Fix erroneous
2445 'Detaching after fork from child...', replace it by '... from
2446 parent...'.
2447 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
2448 prefix/suffix when printing 'Detaching...' messages. Print
2449 them when 'print_inferior_events' is on.
2450 * remote.c (remote_detach_1): Print message when detaching
2451 from inferior and '!is_fork_parent'.
2452
e427af18
TT
24532018-04-24 Tom Tromey <tom@tromey.com>
2454
2455 * cli-out.h: Reindent.
2456
05b1d8d6
TT
24572018-04-24 Tom Tromey <tom@tromey.com>
2458
2459 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
2460 (cli_ui_out::do_field_string): Use fputs_filtered.
2461 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
2462
a95c7dab
TT
24632018-04-23 Tom Tromey <tom@tromey.com>
2464
2465 * guile/scm-frame.c (gdbscm_frame_read_var): Use
2466 gdb::unique_xmalloc_ptr.
2467
458412c3
TT
24682018-04-23 Tom Tromey <tom@tromey.com>
2469
2470 * configure: Rebuild.
2471
db86b02b
RS
24722018-04-22 Rajendra SY <rajendra.sy@gmail.com>
2473
2474 PR gdb/23095
2475 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
2476 prepare_for_testing. Set normal_bp to r_debug_state if target
2477 is bsd.
2478
00aecdcf
PA
24792018-04-21 Pedro Alves <palves@redhat.com>
2480 Rajendra SY <rajendra.sy@gmail.com>
2481
2482 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
2483 * remote.c (extended_remote_attach): In all-stop mode, mark the
2484 thread as executing.
2485
224608c3
PW
24862018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2487
2488 * thread.c (thread_apply_all_command): Fix comment.
2489 (thread_command): Fix comment.
2490
3b74854b
AH
24912018-04-10 Alan Hayward <alan.hayward@arm.com>
2492
2493 * common/tdesc.h (tdesc_create_feature): Remove xml filename
2494 parameter.
2495 * features/aarch64-core.c (create_feature_aarch64_core):
2496 Regenerate.
2497 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
2498 Likewise.
2499 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
2500 Likewise.
2501 * features/i386/32bit-avx512.c
2502 (create_feature_i386_32bit_avx512): Likewise.
2503 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
2504 Likewise.
2505 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
2506 Likewise.
2507 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
2508 Likewise.
2509 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
2510 Likewise.
2511 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
2512 Likewise.
2513 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
2514 Likewise.
2515 * features/i386/64bit-avx512.c
2516 (create_feature_i386_64bit_avx512): Likewise.
2517 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
2518 Likewise.
2519 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
2520 Likewise.
2521 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
2522 Likewise.
2523 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
2524 Likewise.
2525 * features/i386/64bit-segments.c
2526 (create_feature_i386_64bit_segments): Likewise.
2527 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
2528 Likewise.
2529 * features/i386/x32-core.c
2530 (create_feature_i386_x32_core): Likewise.
2531 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
2532 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
2533 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
2534 * target-descriptions.c: In generated code, don't pass xml
2535 filename.
2536
e98577a9
AH
25372018-04-18 Alan Hayward <alan.hayward@arm.com>
2538
2539 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
2540 (print_xml_feature::visit_post): Likewise.
2541 (print_xml_feature::visit): Likewise.
2542 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
2543 (print_xml_feature): Add new class.
2544 * regformats/regdat.sh: Null xmltarget on feature targets.
2545 * target-descriptions.c (struct target_desc): Add xmltarget.
2546 (maintenance_check_tdesc_xml_convert): Add unittest function.
2547 (tdesc_get_features_xml): Add function to get xml.
2548 (maintenance_check_xml_descriptions): Test xml generation.
2549 * xml-tdesc.c (string_read_description_xml): Add function.
2550 * xml-tdesc.h (string_read_description_xml): Add declaration.
2551
ad7fc756
AH
25522018-04-18 Alan Hayward <alan.hayward@arm.com>
2553
2554 * features/Makefile: Add feature marker to targets with new style
2555 target descriptions.
2556 * regformats/aarch64.dat: Regenerate.
2557 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
2558 * regformats/i386/amd64-avx-linux.dat: Likewise.
2559 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
2560 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
2561 * regformats/i386/amd64-linux.dat: Likewise.
2562 * regformats/i386/amd64-mpx-linux.dat: Likewise.
2563 * regformats/i386/amd64.dat: Likewise.
2564 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
2565 * regformats/i386/i386-avx-linux.dat: Likewise.
2566 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
2567 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
2568 * regformats/i386/i386-linux.dat: Likewise.
2569 * regformats/i386/i386-mmx-linux.dat: Likewise.
2570 * regformats/i386/i386-mpx-linux.dat: Likewise.
2571 * regformats/i386/i386.dat: Likewise.
2572 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
2573 * regformats/i386/x32-avx-linux.dat: Likewise.
2574 * regformats/i386/x32-linux.dat: Likewise.
2575 * regformats/tic6x-c62x-linux.dat: Likewise.
2576 * regformats/tic6x-c64x-linux.dat: Likewise.
2577 * regformats/tic6x-c64xp-linux.dat: Likewise.
2578 * regformats/regdat.sh: Parse feature marker.
2579
d278f585
AH
25802018-04-18 Alan Hayward <alan.hayward@arm.com>
2581
2582 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
2583 (tdesc_osabi_name): Likewise.
2584 * target-descriptions.c (tdesc_architecture_name): Add new
2585 function.
2586 (tdesc_osabi_name): Likewise.
2587
eee8a18d
AH
25882018-04-18 Alan Hayward <alan.hayward@arm.com>
2589
2590 * common/tdesc.c (tdesc_predefined_type): Move to here.
2591 (tdesc_named_type): Likewise.
2592 (tdesc_create_vector): Likewise.
2593 (tdesc_create_struct): Likewise.
2594 (tdesc_set_struct_size): Likewise.
2595 (tdesc_create_union): Likewise.
2596 (tdesc_create_flags): Likewise.
2597 (tdesc_create_enum): Likewise.
2598 (tdesc_add_field): Likewise.
2599 (tdesc_add_typed_bitfield): Likewise.
2600 (tdesc_add_bitfield): Likewise.
2601 (tdesc_add_flag): Likewise.
2602 (tdesc_add_enum_value): Likewise.
2603 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
2604 (struct tdesc_type_vector): Likewise.
2605 (struct tdesc_type_field): Likewise.
2606 (struct tdesc_type_with_fields): Likewise.
2607 (tdesc_create_enum): Add declaration.
2608 (tdesc_add_typed_bitfield): Likewise.
2609 (tdesc_add_enum_value): Likewise.
2610 * target-descriptions.c (tdesc_type_field): Move from here.
2611 (tdesc_type_builtin): Likewise.
2612 (tdesc_type_vector): Likewise.
2613 (tdesc_type_with_fields): Likewise.
2614 (tdesc_predefined_types): Likewise.
2615 (tdesc_named_type): Likewise.
2616 (tdesc_create_vector): Likewise.
2617 (tdesc_create_struct): Likewise.
2618 (tdesc_set_struct_size): Likewise.
2619 (tdesc_create_union): Likewise.
2620 (tdesc_create_flags): Likewise.
2621 (tdesc_create_enum): Likewise.
2622 (tdesc_add_field): Likewise.
2623 (tdesc_add_typed_bitfield): Likewise.
2624 (tdesc_add_bitfield): Likewise.
2625 (tdesc_add_flag): Likewise.
2626 (tdesc_add_enum_value): Likewise.
2627 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
2628 (tdesc_add_typed_bitfield): Likewise.
2629 (tdesc_add_enum_value): Likewise.
2630
82ec9bc7
AH
26312018-04-18 Alan Hayward <alan.hayward@arm.com>
2632
2633 * common/tdesc.c (tdesc_feature::accept): Move to here.
2634 (tdesc_feature::operator==): Likewise.
2635 (tdesc_create_reg): Likewise.
2636 * common/tdesc.h (tdesc_type_kind): Likewise.
2637 (struct tdesc_type): Likewise.
2638 (struct tdesc_feature): Likewise.
2639 * regformats/regdat.sh: Create a feature.
2640 * target-descriptions.c (tdesc_type_kind): Move from here.
2641 (tdesc_type): Likewise.
2642 (tdesc_type_up): Likewise.
2643 (tdesc_feature): Likewise.
2644 (tdesc_create_reg): Likewise.
2645
ea3e7d71
AH
26462018-04-18 Alan Hayward <alan.hayward@arm.com>
2647
2648 * Makefile.in: Add arch/tdesc.c
2649 * common/tdesc.c: New file.
2650 * common/tdesc.h (tdesc_element_visitor): Move to here.
2651 (tdesc_element): Likewise.
2652 (tdesc_reg): Likewise.
2653 (tdesc_reg_up): Likewise.
2654 * regformats/regdef.h (reg): Add offset to constructors.
2655 * target-descriptions.c (tdesc_element_visitor): Move from here.
2656 (tdesc_element): Likewise.
2657 (tdesc_reg): Likewise.
2658 (tdesc_reg_up): Likewise.
2659
bedda9ac
TT
26602018-04-17 Tom Tromey <tom@tromey.com>
2661
2662 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
2663 discriminant field.
2664
a037790e
TT
26652018-04-17 Tom Tromey <tom@tromey.com>
2666
2667 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
2668
c7dcbf88
AA
26692018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
2670
2671 * symtab.c (print_symbol_info): Skip printing filename and line
2672 number when `last' is NULL.
2673 (symtab_symbol_info): Use empty string instead of NULL for first
2674 invocation of print_symbol_info.
2675 (rbreak_command): Pass NULL to `last' parameter of
2676 print_symbol_info.
2677
07d28c77
SM
26782018-04-16 Simon Marchi <simon.marchi@ericsson.com>
2679
2680 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
2681 instead of nullptr.
2682
8a3de5e1
PA
26832018-04-16 Pedro Alves <palves@redhat.com>
2684
2685 * MAINTAINERS (sh): Remove.
2686 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
2687 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
2688 (ALLDEPFILES): Remove sh64-tdep.c.
2689 * NEWS: Mentions that support for SH-5/SH64 is removed.
2690 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
2691 (sh*-*-openbsd*): Ditto.
2692 (sh64-*-elf*): Remove.
2693 (sh*): Remove.
2694 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
2695 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
2696 * sh-tdep.c: No longer include "sh64-tdep.h".
2697 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
2698 * sh64-tdep.c, sh64-tdep.h: Remove files.
2699
a2a79012
PA
27002018-04-16 Pedro Alves <palves@redhat.com>
2701
2702 * MAINTAINERS: Remove m88k.
2703 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
2704 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
2705 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
2706 * NEWS: Mention that support for m88k was removed.
2707 * configure.host (m88*-*-*): Remove support.
2708 * configure.nat (m88k-*-*): Remove support.
2709 * configure.tgt (m88*-*-openbsd*): Remove.
2710 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
2711
eda4efb1
SM
27122018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
2713
2714 * configure.tgt (x86_tobjs): New variable.
2715 (amd64_tobjs, i386_tobjs): Use it.
2716
b744723f
AA
27172018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
2718
2719 * symtab.c (print_symbol_info): Precede the symbol definition by
2720 the line number when available.
2721 * NEWS: Advertise this enhancement.
2722
4a4495d6
MM
27232018-04-13 Markus Metzger <markus.t.metzger@intel.com>
2724
2725 * NEWS (New options): announce set/show record btrace cpu.
2726 * btrace.c: Include record-btrace.h.
2727 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
2728 the vendor is unknown.
2729 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
2730 Maybe overwrite the btrace configuration's cpu.
2731 (btrace_compute_ftrace): Add cpu parameter. Update callers.
2732 (btrace_fetch): Add cpu parameter. Update callers.
2733 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
2734 Maybe overwrite the btrace configuration's cpu. Skip enabling
2735 errata workarounds if the vendor is unknown.
2736 * python/py-record-btrace.c: Include record-btrace.h.
2737 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
2738 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
2739 * record-btrace.c (record_btrace_cpu_state_kind): New.
2740 (record_btrace_cpu): New.
2741 (set_record_btrace_cpu_cmdlist): New.
2742 (record_btrace_get_cpu): New.
2743 (require_btrace_thread, record_btrace_info)
2744 (record_btrace_resume_thread): Call record_btrace_get_cpu.
2745 (cmd_set_record_btrace_cpu_none): New.
2746 (cmd_set_record_btrace_cpu_auto): New.
2747 (cmd_set_record_btrace_cpu): New.
2748 (cmd_show_record_btrace_cpu): New.
2749 (_initialize_record_btrace): Initialize set/show record btrace cpu
2750 commands.
2751 * record-btrace.h (record_btrace_get_cpu): New.
2752
69f90c75
MM
27532018-04-13 Markus Metzger <markus.t.metzger@intel.com>
2754
2755 * record.c (set_record_command): Fix typo in message.
2756
b85310e1
MM
27572018-04-13 Markus Metzger <markus.t.metzger@intel.com>
2758
2759 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
2760
1d509aa6
MM
27612018-04-13 Markus Metzger <markus.t.metzger@intel.com>
2762
2763 * infrun.c (process_event_stop_test): Call
2764 gdbarch_in_indirect_branch_thunk.
2765 * gdbarch.sh (in_indirect_branch_thunk): New.
2766 * gdbarch.c: Regenerated.
2767 * gdbarch.h: Regenerated.
2768 * x86-tdep.h: New.
2769 * x86-tdep.c: New.
2770 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
2771 (HFILES_NO_SRCDIR): Add x86-tdep.h.
2772 (ALLDEPFILES): Add x86-tdep.c.
2773 * arch-utils.h (default_in_indirect_branch_thunk): New.
2774 * arch-utils.c (default_in_indirect_branch_thunk): New.
2775 * i386-tdep: Include x86-tdep.h.
2776 (i386_in_indirect_branch_thunk): New.
2777 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
2778 function.
2779 * amd64-tdep: Include x86-tdep.h.
2780 (amd64_in_indirect_branch_thunk): New.
2781 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
2782
b4be9bfd
JK
27832018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
2784
2785 PR gdb/23053
2786 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
2787 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
2788 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
2789 regression.
2790
53d7df28
TT
27912018-04-12 Tom Tromey <tom@tromey.com>
2792
2793 * rust-lang.c (rust_print_struct_def): Remove univariant code.
2794 (rust_evaluate_subexp): Likewise.
2795
70b33f19
PA
27962018-04-12 Pedro Alves <palves@redhat.com>
2797
2798 * procfs.c (procfs_detach): Make forward declaration's prototype
2799 match definition's protototype.
2800 (proc_get_LDT_entry): Remove stale do_cleanups call.
2801
436411b1
PA
28022018-04-12 Pedro Alves <palves@redhat.com>
2803
2804 * target.h (target_ops::to_has_exited): Delete.
2805 (target_has_exited): Delete.
2806 * target-delegates.c: Regenerate.
2807
20db9c52
PA
28082018-04-11 Pedro Alves <palves@redhat.com>
2809
2810 * target.c (fileio_fh_t::t): Add comment.
2811 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
2812 (target_fileio_close): Handle a NULL target.
2813 (invalidate_fileio_fh): New.
2814 (target_close): Call it.
2815 * remote.c (remote_hostio_send_command): No longer check whether
2816 remote_desc is open.
2817
5ff79300
PA
28182018-04-11 Pedro Alves <palves@redhat.com>
2819
2820 * target.c (fileio_fh_t): Make it a named struct instead of a
2821 typedef.
2822 (fileio_fh_t::is_closed): New method.
2823 (DEF_VEC_O (fileio_fh_t)): Remove.
2824 (fileio_fhandles): Now a std::vector.
2825 (is_closed_fileio_fh): Delete.
2826 (acquire_fileio_fd): Adjust. Rename parameters.
2827 (release_fileio_fd): Adjust.
2828 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
2829 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
2830 (target_fileio_close): Adjust.
2831
6e22e10d
SM
28322018-04-10 Simon Marchi <simon.marchi@ericsson.com>
2833
2834 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
2835 index.
2836
731f534f
PA
28372018-04-10 Pedro Alves <palves@redhat.com>
2838
2839 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
2840 (scoped_finish_thread_state): New class.
2841 * infcmd.c (run_command_1): Use it instead of finish_thread_state
2842 cleanup.
2843 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
2844 (fetch_inferior_event, normal_stop): Likewise.
2845 * thread.c (finish_thread_state_cleanup): Delete.
2846
d5f4488f
SM
28472018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2848 Pedro Alves <palves@redhat.com>
2849
2850 * value.c: Include "selftest.h" and "common/array-view.h".
2851 (struct range) <operator ==>: New.
2852 (test_ranges_contain): New.
2853 (check_ranges_vector): New.
2854 (test_insert_into_bit_range_vector): New.
2855 (_initialize_values): Register selftests.
2856 * common/array-view.h (operator==, operator!=): New.
2857
b24531ed
SM
28582018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2859
2860 * common/gdb_vecs.h (unordered_remove): Add overload that takes
2861 an iterator.
2862 * inline-frame.c: Include <algorithm>.
2863 (struct inline_state): Add constructor.
2864 (inline_state_s): Remove.
2865 (DEF_VEC_O(inline_state_s)): Remove.
2866 (inline_states): Change type to std::vector.
2867 (find_inline_frame_state): Adjust to std::vector.
2868 (allocate_inline_frame_state): Remove.
2869 (clear_inline_frame_state): Adjust to std::vector.
2870 (skip_inline_frames): Adjust to std::vector.
2871
c252925c
SM
28722018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2873
2874 * tracepoint.h (struct trace_state_variable): Add constructor.
2875 <name>: Change type to std::string.
2876 * tracepoint.c (tsv_s): Remove.
2877 (DEF_VEC_O(tsv_s)): Remove.
2878 (tvariables): Change to std::vector.
2879 (create_trace_state_variable): Adjust to std::vector.
2880 (find_trace_state_variable): Likewise.
2881 (find_trace_state_variable_by_number): Likewise.
2882 (delete_trace_state_variable): Likewise.
2883 (trace_variable_command): Adjust to std::string.
2884 (delete_trace_variable_command): Likewise.
2885 (tvariables_info_1): Adjust to std::vector.
2886 (save_trace_state_variables): Likewise.
2887 (start_tracing): Likewise.
2888 (merge_uploaded_trace_state_variables): Adjust to std::vector
2889 and std::string.
2890 * target.h (struct target_ops)
2891 <to_download_trace_state_variable>: Pass reference to
2892 trace_state_variable.
2893 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
2894 * target-delegates.c: Re-generate.
2895 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
2896 (mi_tsv_deleted): Likewise.
2897 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
2898 * remote.c (remote_download_trace_state_variable): Change
2899 pointer to reference and adjust.
2900 * make-target-delegates (parse_argtypes): Handle references.
2901 (write_function_header): Likewise.
2902 (munge_type): Likewise.
2903
c9638d26
SM
29042018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2905
2906 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2907 string_view-selftests.c.
2908 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
2909 testsuite.
2910 * unittests/basic_string_view/cons/char/1.cc: Likewise.
2911 * unittests/basic_string_view/cons/char/2.cc: Likewise.
2912 * unittests/basic_string_view/cons/char/3.cc: Likewise.
2913 * unittests/basic_string_view/element_access/char/1.cc:
2914 Likewise.
2915 * unittests/basic_string_view/element_access/char/empty.cc:
2916 Likewise.
2917 * unittests/basic_string_view/element_access/char/front_back.cc:
2918 Likewise.
2919 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
2920 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
2921 Likewise.
2922 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
2923 Likewise.
2924 * unittests/basic_string_view/modifiers/swap/char/1.cc:
2925 Likewise.
2926 * unittests/basic_string_view/operations/compare/char/1.cc:
2927 Likewise.
2928 * unittests/basic_string_view/operations/compare/char/13650.cc:
2929 Likewise.
2930 * unittests/basic_string_view/operations/copy/char/1.cc:
2931 Likewise.
2932 * unittests/basic_string_view/operations/data/char/1.cc:
2933 Likewise.
2934 * unittests/basic_string_view/operations/find/char/1.cc:
2935 Likewise.
2936 * unittests/basic_string_view/operations/find/char/2.cc:
2937 Likewise.
2938 * unittests/basic_string_view/operations/find/char/3.cc:
2939 Likewise.
2940 * unittests/basic_string_view/operations/find/char/4.cc:
2941 Likewise.
2942 * unittests/basic_string_view/operations/rfind/char/1.cc:
2943 Likewise.
2944 * unittests/basic_string_view/operations/rfind/char/2.cc:
2945 Likewise.
2946 * unittests/basic_string_view/operations/rfind/char/3.cc:
2947 Likewise.
2948 * unittests/basic_string_view/operations/substr/char/1.cc:
2949 Likewise.
2950 * unittests/basic_string_view/operators/char/2.cc: Likewise.
2951 * unittests/string_view-selftests.c: New file.
2952
fdc11678
SM
29532018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2954
2955 * unittests/basic_string_view/capacity/1.cc: New file.
2956 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
2957 * unittests/basic_string_view/cons/char/1.cc: New file.
2958 * unittests/basic_string_view/cons/char/2.cc: New file.
2959 * unittests/basic_string_view/cons/char/3.cc: New file.
2960 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
2961 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
2962 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
2963 * unittests/basic_string_view/element_access/char/1.cc: New file.
2964 * unittests/basic_string_view/element_access/char/2.cc: New file.
2965 * unittests/basic_string_view/element_access/char/empty.cc: New file.
2966 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
2967 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
2968 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
2969 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
2970 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
2971 * unittests/basic_string_view/include.cc: New file.
2972 * unittests/basic_string_view/inserters/char/1.cc: New file.
2973 * unittests/basic_string_view/inserters/char/2.cc: New file.
2974 * unittests/basic_string_view/inserters/char/3.cc: New file.
2975 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
2976 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
2977 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
2978 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
2979 * unittests/basic_string_view/literals/types.cc: New file.
2980 * unittests/basic_string_view/literals/values.cc: New file.
2981 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
2982 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
2983 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
2984 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
2985 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
2986 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
2987 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
2988 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
2989 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
2990 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
2991 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
2992 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
2993 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
2994 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
2995 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
2996 * unittests/basic_string_view/operations/data/char/1.cc: New file.
2997 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
2998 * unittests/basic_string_view/operations/find/char/1.cc: New file.
2999 * unittests/basic_string_view/operations/find/char/2.cc: New file.
3000 * unittests/basic_string_view/operations/find/char/3.cc: New file.
3001 * unittests/basic_string_view/operations/find/char/4.cc: New file.
3002 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
3003 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
3004 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
3005 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
3006 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
3007 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
3008 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
3009 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
3010 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
3011 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
3012 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
3013 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
3014 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
3015 * unittests/basic_string_view/operators/char/2.cc: New file.
3016 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
3017 * unittests/basic_string_view/range_access/char/1.cc: New file.
3018 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
3019 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
3020 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
3021 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
3022 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
3023 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
3024 * unittests/basic_string_view/requirements/typedefs.cc: New file.
3025 * unittests/basic_string_view/typedefs.cc: New file.
3026 * unittests/basic_string_view/types/1.cc: New file.
3027
8345c4a2
SM
30282018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3029
3030 * common/gdb_string_view.h: Remove libstdc++ implementation
3031 details, adjust to gdb reality.
3032 * common/gdb_string_view.tcc: Likewise.
3033 * cli/cli-script.c (struct string_view): Remove.
3034 (user_args) <m_args>: Change element type to gdb::string_view.
3035 (user_args::insert_args): Adjust.
3036
7adcdf08
SM
30372018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3038
3039 * common/gdb_string_view.h: New file.
3040 * common/gdb_string_view.tcc: New file.
3041
41260ac2
SM
30422018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
3043
3044 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
3045 * configure: Re-generate.
3046
0bee6dd4
PA
30472018-04-09 Pedro Alves <palves@redhat.com>
3048
3049 * gdbarch.sh: Include "observable.h" instead of "observer.h".
3050 (set_target_gdbarch): Call
3051 gdb::observers::architecture_changed.notify instead of
3052 observer_notify_architecture_changed.
3053
6f14adc5
SM
30542018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3055
3056 * tracepoint.c (struct current_traceframe_cleanup): Remove.
3057 (do_restore_current_traceframe_cleanup): Remove.
3058 (restore_current_traceframe_cleanup_dtor): Remove.
3059 (make_cleanup_restore_current_traceframe): Remove.
3060 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
3061 New.
3062 * tracepoint.h (struct scoped_restore_current_traceframe): New.
3063 * infrun.c (fetch_inferior_event): Use
3064 scoped_restore_current_traceframe.
3065
b2bdb8cf
SM
30662018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3067
3068 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
3069 Remove.
3070 <n_allocated_type_units>: Remove.
3071 <all_type_units>: Change to std::vector.
3072 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
3073 to std::vector change.
3074 (dwarf2_per_objfile::get_cutu): Likewise.
3075 (dwarf2_per_objfile::get_tu): Likewise.
3076 (create_signatured_type_table_from_index): Likewise.
3077 (create_signatured_type_table_from_debug_names): Likewise.
3078 (dw2_symtab_iter_next): Likewise.
3079 (dw2_print_stats): Likewise.
3080 (dw2_expand_all_symtabs): Likewise.
3081 (dw2_expand_marked_cus): Likewise.
3082 (dw2_debug_names_iterator::next): Likewise.
3083 (dwarf2_initialize_objfile): Likewise.
3084 (add_signatured_type_cu_to_table): Likewise.
3085 (create_all_type_units): Likewise.
3086 (add_type_unit): Likewise.
3087 (struct tu_abbrev_offset): Add constructor.
3088 (build_type_psymtabs_1): Adjust to std::vector change.
3089 (print_tu_stats): Likewise.
3090 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
3091 (write_debug_names): Likewise.
3092
b76e467d
SM
30932018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3094
3095 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
3096 Make an std::vector.
3097 <n_comp_units>: Remove.
3098 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
3099 to std::vector change.
3100 (dwarf2_per_objfile::get_cutu): Likewise.
3101 (dwarf2_per_objfile::get_cu): Likewise.
3102 (create_cus_from_index): Likewise.
3103 (create_addrmap_from_index): Likewise.
3104 (create_addrmap_from_aranges): Likewise.
3105 (dwarf2_read_index): Likewise.
3106 (dw2_find_last_source_symtab): Likewise.
3107 (dw2_map_symtabs_matching_filename): Likewise.
3108 (dw2_symtab_iter_next): Likewise.
3109 (dw2_print_stats): Likewise.
3110 (dw2_expand_all_symtabs): Likewise.
3111 (dw2_expand_symtabs_with_fullname): Likewise.
3112 (dw2_expand_marked_cus): Likewise.
3113 (dw2_map_symbol_filenames): Likewise.
3114 (create_cus_from_debug_names): Likewise.
3115 (dwarf2_read_debug_names): Likewise.
3116 (dw2_debug_names_iterator::next): Likewise.
3117 (dwarf2_initialize_objfile): Likewise.
3118 (set_partial_user): Likewise.
3119 (dwarf2_build_psymtabs_hard): Likewise.
3120 (read_comp_units_from_section): Remove arguments, adjust to
3121 std::vector change.
3122 (create_all_comp_units): Adjust to std::vector and
3123 read_comp_units_from_section changes.
3124 (dwarf2_find_containing_comp_unit): Adjust to std::vector
3125 change.
3126 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
3127 (psyms_seen_size): Likewise.
3128 (write_gdbindex): Likewise.
3129 (write_debug_names): Likewise.
3130
12359b5e
SM
31312018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3132
3133 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
3134 with dwarf2_per_objfile.
3135 (create_cus_from_index): Likewise.
3136 (create_signatured_type_table_from_index): Likewise.
3137 (dwarf2_read_index): Likewise.
3138 (dwarf2_initialize_objfile): Likewise.
3139 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
3140 per_cu rather than get_dwarf2_per_objfile.
3141
ff4c9fec
SM
31422018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3143
3144 * dwarf2read.h (struct signatured_type): Forward declare.
3145 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
3146 New methods.
3147 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
3148 (dw2_get_cutu): ...this.
3149 (dwarf2_per_objfile::get_cu): Rename from...
3150 (dw2_get_cu): ...this.
3151 (dwarf2_per_objfile::get_tu): New.
3152 (create_addrmap_from_index): Adjust.
3153 (create_addrmap_from_aranges): Adjust.
3154 (dw2_find_last_source_symtab): Adjust.
3155 (dw2_map_symtabs_matching_filename): Adjust.
3156 (dw2_symtab_iter_next): Adjust.
3157 (dw2_print_stats): Adjust.
3158 (dw2_expand_all_symtabs): Adjust.
3159 (dw2_expand_symtabs_with_fullname): Adjust.
3160 (dw2_expand_marked_cus): Adjust.
3161 (dw_expand_symtabs_matching_file_matcher): Adjust.
3162 (dw2_map_symbol_filenames): Adjust.
3163 (dw2_debug_names_iterator::next): Adjust.
3164 (dwarf2_initialize_objfile): Adjust.
3165 (set_partial_user): Adjust.
3166 (dwarf2_build_psymtabs_hard): Adjust.
3167
5ca3fcb6
SM
31682018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3169
3170 * dwarf2read.c (create_signatured_type_table_from_debug_names):
3171 Remove unused variables.
3172 (dw2_map_symtabs_matching_filename): Likewise.
3173 (dwarf2_record_block_ranges): Likewise.
3174 (dwarf2_read_addr_index): Likewise.
3175 (follow_die_offset): Likewise.
3176
b2e586e8
SM
31772018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3178
3179 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
3180 to symbol_file_add_main.
3181
7c4e78cf
SM
31822018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3183
3184 PR mi/22299
3185 * mi/mi-console.c (do_fputc_async_safe): New.
3186 (mi_console_file::write_async_safe): New.
3187 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
3188 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
3189 New.
3190 * ui-file.c (ui_file::putstrn): Adjust call to
3191 fputstrn_unfiltered.
3192 * utils.c (printchar): Replace do_fputs and do_fprintf
3193 parameters by do_fputc.
3194 (fputstr_filtered): Adjust call to printchar.
3195 (fputstr_unfiltered): Likewise.
3196 (fputstrn_filtered): Likewise.
3197 (fputstrn_unfiltered): Add do_fputc parameter, pass to
3198 printchar.
3199 * utils.h (do_fputc_ftype): New typedef.
3200 (fputstrn_unfiltered): Add do_fputc parameter.
3201
5dc026d3
SM
32022018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3203
3204 * regformats/i386/i386-avx.dat: Remove.
3205
c912f608
SM
32062018-04-07 Simon Marchi <simon.marchi@ericsson.com>
3207
3208 PR gdb/22979
3209 * amd64-tdep.c (amd64_none_init_abi): New function.
3210 (amd64_x32_none_init_abi): New function.
3211 (_initialize_amd64_tdep): Register handlers for x86-64 and
3212 x64_32 with GDB_OSABI_NONE.
3213 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
3214 GDB_OSABI_NONE osabi.
3215
26540402
SM
32162018-04-07 Simon Marchi <simon.marchi@ericsson.com>
3217
3218 PR gdb/22980
3219 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
3220 GDB_OSABI_NONE.
3221 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
3222 * osabi.c (gdb_osabi_names): Add "unknown" entry.
3223
9018be22
SM
32242018-04-07 Simon Marchi <simon.marchi@ericsson.com>
3225
3226 * common/byte-vector.h (char_vector): New type.
3227 * target.h (target_read_alloc): Return
3228 gdb::optional<byte_vector>.
3229 (target_read_stralloc): Return gdb::optional<char_vector>.
3230 (target_get_osdata): Return gdb::optional<char_vector>.
3231 * target.c (target_read_alloc_1): Templatize. Replacement
3232 manual memory management with vector.
3233 (target_read_alloc): Change return type, adjust.
3234 (target_read_stralloc): Change return type, adjust.
3235 (target_get_osdata): Change return type, adjust.
3236 * auxv.c (struct auxv_info) <length>: Remove.
3237 <data>: Change type to gdb::optional<byte_vector>.
3238 (auxv_inferior_data_cleanup): Free auxv_info with delete.
3239 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
3240 (target_auxv_search): Adjust.
3241 (fprint_target_auxv): Adjust.
3242 * avr-tdep.c (avr_io_reg_read_command): Adjust.
3243 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
3244 (linux_make_corefile_notes): Adjust.
3245 * osdata.c (get_osdata): Adjust.
3246 * remote.c (remote_get_threads_with_qxfer): Adjust.
3247 (remote_memory_map): Adjust.
3248 (remote_traceframe_info): Adjust.
3249 (btrace_read_config): Adjust.
3250 (remote_read_btrace): Adjust.
3251 (remote_pid_to_exec_file): Adjust.
3252 * solib-aix.c (solib_aix_get_library_list): Adjust.
3253 * solib-dsbt.c (decode_loadmap): Don't free buf.
3254 (dsbt_get_initial_loadmaps): Adjust.
3255 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
3256 * solib-target.c (solib_target_current_sos): Adjust.
3257 * tracepoint.c (sdata_make_value): Adjust.
3258 * xml-support.c (xinclude_start_include): Adjust.
3259 (xml_fetch_content_from_file): Adjust.
3260 * xml-support.h (xml_fetch_another): Change return type.
3261 (xml_fetch_content_from_file): Change return type.
3262 * xml-syscall.c (xml_init_syscalls_info): Adjust.
3263 * xml-tdesc.c (file_read_description_xml): Adjust.
3264 (fetch_available_features_from_target): Change return type.
3265 (target_fetch_description_xml): Adjust.
3266 (target_read_description_xml): Adjust.
3267
14c88955
TT
32682018-04-06 Tom Tromey <tom@tromey.com>
3269
3270 * value.c (~value): Update.
3271 (struct value) <contents>: Now unique_xmalloc_ptr.
3272 (value_contents_bits_eq, allocate_value_contents)
3273 (value_contents_raw, value_contents_all_raw)
3274 (value_contents_for_printing, value_contents_for_printing_const)
3275 (set_value_enclosing_type): Update.
3276
0c7e6dd8
TT
32772018-04-06 Tom Tromey <tom@tromey.com>
3278
3279 * value.c (range_s): Remove typedef, VEC.
3280 (struct range): Add operator<.
3281 (range_lessthan): Remove.
3282 (ranges_contain): Change type.
3283 (~value): Update.
3284 (struct value) <unavailable, optimized_out>: Now std::vector.
3285 (value_entirely_available)
3286 (value_entirely_covered_by_range_vector)
3287 (value_entirely_unavailable, value_entirely_optimized_out):
3288 Update.
3289 (insert_into_bit_range_vector): Change argument type.
3290 (find_first_range_overlap): Likewise.
3291 (struct ranges_and_idx, value_contents_bits_eq)
3292 (require_not_optimized_out, require_available): Update.
3293 (ranges_copy_adjusted): Change argument types.
3294 (value_optimized_out, value_copy, value_fetch_lazy): Update.
3295
2c8331b9
TT
32962018-04-06 Tom Tromey <tom@tromey.com>
3297
3298 * value.c (~value): Update.
3299 (struct value) <parent>: Now a value_ref_ptr.
3300 (value_parent, set_value_parent, value_address, value_copy):
3301 Update.
3302
466ce3ae
TT
33032018-04-06 Tom Tromey <tom@tromey.com>
3304
3305 * value.c (struct value): Add constructor, destructor, and member
3306 initializers.
3307 (allocate_value_lazy, value_decref): Update.
3308
062d818d
TT
33092018-04-06 Tom Tromey <tom@tromey.com>
3310
3311 * value.c (struct value) <released, next>: Remove.
3312 (all_values): Now a std::vector.
3313 (allocate_value_lazy): Update.
3314 (value_next): Remove.
3315 (value_mark, value_free_to_mark, release_value)
3316 (value_release_to_mark): Update.
3317
a6535de1
TT
33182018-04-06 Tom Tromey <tom@tromey.com>
3319
3320 * value.h (fetch_subexp_value, value_release_to_mark): Update.
3321 (free_value_chain): Remove.
3322 * value.c (free_value_chain): Remove.
3323 (value_release_to_mark): Return a std::vector.
3324 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
3325 std::vector.
3326 (check_condition): Update.
3327 * eval.c (fetch_subexp_value): Change "val_chain" to a
3328 std::vector.
3329 * breakpoint.c (update_watchpoint): Update.
3330 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
3331
b5621201
TT
33322018-04-06 Tom Tromey <tom@tromey.com>
3333
3334 * value.h (free_all_values): Remove.
3335 * value.c (free_all_values): Remove.
3336
4d0266a0
TT
33372018-04-06 Tom Tromey <tom@tromey.com>
3338
3339 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
3340 (value_history_chain, value_history_count): Remove.
3341 (value_history): New global.
3342 (record_latest_value, access_value_history, show_values)
3343 (preserve_values): Update.
3344
b4d61099
TT
33452018-04-06 Tom Tromey <tom@tromey.com>
3346
3347 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
3348 * varobj.c (varobj_set_display_format, varobj_set_value)
3349 (install_default_visualizer, construct_visualizer)
3350 (install_new_value, ~varobj, varobj_get_value_type)
3351 (my_value_of_variable, varobj_editable_p): Update.
3352 * c-varobj.c (c_describe_child, c_value_of_variable)
3353 (cplus_number_of_children, cplus_describe_child): Update.
3354 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
3355 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
3356 (ada_value_of_variable, ada_value_is_changeable_p): Update.
3357
9b558729
TT
33582018-04-06 Tom Tromey <tom@tromey.com>
3359
3360 * printcmd.c (last_examine_address): Change type to
3361 value_ref_ptr.
3362 (do_examine, x_command): Update.
3363
850645cf
TT
33642018-04-06 Tom Tromey <tom@tromey.com>
3365
3366 * value.c (release_value): Update.
3367 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
3368 (struct bpstats) <val>: Now a value_ref_ptr.
3369 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
3370 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
3371 (~watchpoint, print_it_watchpoint, watch_command_1)
3372 (invalidate_bp_value_on_memory_change): Update.
3373
22bc8444
TT
33742018-04-06 Tom Tromey <tom@tromey.com>
3375
3376 * varobj.c (varobj_clear_saved_item)
3377 (update_dynamic_varobj_children, install_new_value, ~varobj):
3378 Update.
3379 * value.h (value_incref): Move declaration earlier.
3380 (value_decref): Rename from value_free.
3381 (struct value_ref_policy): New.
3382 (value_ref_ptr): New typedef.
3383 (struct value_deleter): Remove.
3384 (gdb_value_up): Remove typedef.
3385 (release_value): Change return type.
3386 (release_value_or_incref): Remove.
3387 * value.c (set_value_parent): Update.
3388 (value_incref): Change return type.
3389 (value_decref): Rename from value_free.
3390 (value_free_to_mark, free_all_values, free_value_chain): Update.
3391 (release_value): Return value_ref_ptr.
3392 (release_value_or_incref): Remove.
3393 (record_latest_value, set_internalvar, clear_internalvar):
3394 Update.
3395 * stack.c (info_frame_command): Don't call value_free.
3396 * python/py-value.c (valpy_dealloc, valpy_new)
3397 (value_to_value_object): Update.
3398 * printcmd.c (do_examine): Update.
3399 * opencl-lang.c (lval_func_free_closure): Update.
3400 * mi/mi-main.c (register_changed_p): Don't call value_free.
3401 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
3402 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
3403 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
3404 value_free.
3405 * guile/scm-value.c (vlscm_free_value_smob)
3406 (vlscm_scm_from_value): Update.
3407 * frame.c (frame_register_unwind, frame_unwind_register_signed)
3408 (frame_unwind_register_unsigned, get_frame_register_bytes)
3409 (put_frame_register_bytes): Don't call value_free.
3410 * findvar.c (address_from_register): Don't call value_free.
3411 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
3412 * dwarf2loc.c (entry_data_value_free_closure)
3413 (value_of_dwarf_reg_entry, free_pieced_value_closure)
3414 (dwarf2_evaluate_loc_desc_full): Update.
3415 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
3416 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
3417 (~watchpoint, watch_command_1)
3418 (invalidate_bp_value_on_memory_change): Update.
3419 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
3420
7f8a5d38
SM
34212018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
3422
3423 PR gdb/23022
3424 * warning.m4: Add -Wno-error=deprecated-register.
3425 * configure: Re-generate.
3426
8a76bd3b
TT
34272018-04-05 Tom Tromey <tom@tromey.com>
3428
3429 * linespec.h: Remove include of "vec.h".
3430
8e8d776e
TT
34312018-04-05 Tom Tromey <tom@tromey.com>
3432
3433 * linespec.c (typep): Remove typedef.
3434 (find_methods, find_superclass_methods): Take a std::vector.
3435 (find_method): Use std::vector.
3436
9b2f8581
TT
34372018-04-05 Tom Tromey <tom@tromey.com>
3438
3439 * utils.c (compare_strings): Remove.
3440 * utils.h (compare_strings): Remove.
3441 * objc-lang.h (find_imps): Update.
3442 * objc-lang.c (find_methods): Take a std::vector.
3443 (uniquify_strings, find_imps): Likewise.
3444 * linespec.c (find_methods): Take a std::vector.
3445 (decode_objc): Use std::vector.
3446 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
3447 a std::vector.
3448 (find_method, find_function_symbols): Use std::vector.
3449
459a2e4c
TT
34502018-04-05 Tom Tromey <tom@tromey.com>
3451
3452 * completer.c (completion_tracker::completion_tracker): Remove
3453 cast.
3454 (completion_tracker::discard_completions): Likewise.
3455 * breakpoint.c (ambiguous_names_p): Remove cast.
3456 * ada-lang.c (_initialize_ada_language): Remove cast.
3457 * utils.h (streq): Update.
3458 (streq_hash): Add new declaration.
3459 * utils.c (streq): Return bool.
3460 (streq_hash): New function.
3461
9be2c17a
TT
34622018-04-05 Tom Tromey <tom@tromey.com>
3463
3464 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
3465 Remove a string copy.
3466
f73c6ece
TT
34672018-04-05 Tom Tromey <tom@tromey.com>
3468
3469 * linespec.c (filter_results): Use std::vector.
3470 (decode_line_2, decode_line_full): Update.
3471
53a0f8a2
TT
34722018-04-05 Tom Tromey <tom@tromey.com>
3473
3474 * linespec.c (canonical_to_fullform): Return std::string.
3475 (filter_results): Update.
3476 (struct decode_line_2_item): Add constructor.
3477 <fullform, displayform>: Now std::string.
3478 (decode_line_2_compare_items): Now a std::sort comparator.
3479 (decode_line_2): Update.
3480
a5b5adf5
TT
34812018-04-05 Tom Tromey <tom@tromey.com>
3482
3483 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
3484 (unexpected_linespec_error): Update.
3485 (linespec_parse_basic, parse_linespec): Update.
3486
6a307fc5
TT
34872018-04-05 Tom Tromey <tom@tromey.com>
3488
3489 * linespec.c (linespec_parse_basic): Reindent.
3490
41c1efc6
TT
34912018-04-05 Tom Tromey <tom@tromey.com>
3492
3493 * minsyms.h (iterate_over_minimal_symbols): Update.
3494 * minsyms.c (iterate_over_minimal_symbols): Take a
3495 gdb::function_view.
3496 * linespec.c (struct collect_minsyms): Remove.
3497 (compare_msyms): Now a std::sort comparator.
3498 (add_minsym): Add parameters.
3499 (search_minsyms_for_name): Update. Use std::vector.
3500
c5edbf3d
TT
35012018-04-03 Tom Tromey <tom@tromey.com>
3502
3503 * mipsread.c (read_alphacoff_dynamic_symtab): Use
3504 gdb::byte_vector.
3505
b39efc48
WP
35062018-04-02 Weimin Pan <weimin.pan@oracle.com>
3507
3508 * MAINTAINERS (Write After Approval): Add Weimin Pan.
3509
121ad66c 35102018-04-02 Weimin Pan <weimin.pan@oracle.com>
79f18731
WP
3511
3512 PR gdb/16959
3513 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
3514 printing static type.
3515
09473be8
TT
35162018-04-01 Tom Tromey <tom@tromey.com>
3517
3518 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
3519 (rs6000_xfer_shared_libraries): Update.
3520
ec1f2d91
SM
35212018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
3522
3523 * common/gdb_vecs.h (char_ptr): Remove.
3524 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
3525
d8611974
SM
35262018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
3527
3528 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
3529 with std::vector.
3530 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
3531
a18ba4e4
SM
35322018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
3533
3534 * tracepoint.h (struct uploaded_tp): Initialize fields.
3535 <actions, step_actions, cmd_strings>: Change type to
3536 std::vector<char *>.
3537 * tracepoint.c (get_uploaded_tp): Allocate with new.
3538 (free_uploaded_tps): Free with delete.
3539 (parse_tracepoint_definition): Adjust to std::vector change.
3540 * breakpoint.c (read_uploaded_action): Likewise.
3541 (create_tracepoint_from_upload): Likewise.
3542 * ctf.c (ctf_write_uploaded_tp): Likewise.
3543 (SET_ARRAY_FIELD): Likewise.
3544 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
3545
a7961323
TT
35462018-03-30 Tom Tromey <tom@tromey.com>
3547
3548 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
3549 std::unique_ptr.
3550 (svr4_keep_data_in_core): Update.
3551 (svr4_read_so_list): Update.
3552
e83e4e24
TT
35532018-03-30 Tom Tromey <tom@tromey.com>
3554
3555 * windows-nat.c (handle_output_debug_string, handle_exception):
3556 Update.
3557 * target.h (target_read_string): Update.
3558 * target.c (target_read_string): Change "string" to
3559 unique_xmalloc_ptr.
3560 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
3561 Update.
3562 * solib-frv.c (frv_current_sos): Update.
3563 * solib-dsbt.c (dsbt_current_sos): Update.
3564 * solib-darwin.c (darwin_current_sos): Update.
3565 * linux-thread-db.c (inferior_has_bug): Update.
3566 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
3567 Update. Remove alloca.
3568 * ada-lang.c (ada_main_name): Update.
3569
263db9a1
TT
35702018-03-30 Tom Tromey <tom@tromey.com>
3571
3572 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
3573 (struct dwo_file_deleter): New.
3574 (dwo_file_up): New typedef.
3575 (open_and_init_dwo_file): Use dwo_file_up.
3576 (free_dwo_file_cleanup): Remove.
3577
5dafb3d1
TT
35782018-03-30 Tom Tromey <tom@tromey.com>
3579
3580 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
3581 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
3582
11ed8cad
TT
35832018-03-30 Tom Tromey <tom@tromey.com>
3584
3585 * dwarf2read.c (class free_cached_comp_units): New class.
3586 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
3587 (free_cached_comp_units): Remove function.
3588
9ae79dac
TT
35892018-03-30 Tom Tromey <tom@tromey.com>
3590
3591 * utils.h (make_cleanup_unpush_target): Remove.
3592 * inf-ptrace.c (struct target_unpusher): New.
3593 (target_unpush_up) New typedef.
3594 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
3595 target_unpush_up.
3596 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
3597
5aa89276
TT
35982018-03-27 Tom Tromey <tom@tromey.com>
3599
3600 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
3601
1dbeed45
TT
36022018-03-27 Pedro Alves <palves@redhat.com>
3603 Tom Tromey <tom@tromey.com>
3604
3605 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
3606 destructor. Now a class.
3607 (gdb_readline_wrapper_cleanup): Remove function.
3608 (gdb_readline_wrapper): Remove cleanups.
3609
c819b2c0
TT
36102018-03-27 Tom Tromey <tom@tromey.com>
3611
3612 * typeprint.h (struct type_print_options) <local_typedefs,
3613 global_typedefs>: Remove "struct" keyword.
3614 (class typedef_hash_table): New class.
3615 (recursively_update_typedef_hash, add_template_parameters)
3616 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
3617 (find_typedef_in_hash): Don't declare.
3618 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
3619 (typedef_hash_table::recursively_update): Rename from
3620 recursively_update_typedef_hash. Now a member.
3621 (typedef_hash_table::add_template_parameters): Rename from
3622 add_template_parameters. Now a member.
3623 (typedef_hash_table::typedef_hash_table): Now a constructor;
3624 rename from create_typedef_hash.
3625 (typedef_hash_table::~typedef_hash_table): Now a destructor;
3626 rename from free_typedef_hash.
3627 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
3628 (do_free_global_table): Remove.
3629 (typedef_hash_table::typedef_hash_table): New constructor; renamed
3630 from copy_type_recursive.
3631 (create_global_typedef_table): Remove.
3632 (typedef_hash_table::find_global_typedef): Now a member of
3633 typedef_hash_table.
3634 (typedef_hash_table::find_typedef): Rename from
3635 find_typedef_in_hash; now a member.
3636 (whatis_exp): Update.
3637 * extension.h (struct ext_lang_type_printers): Add constructor and
3638 destructor.
3639 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
3640 declare.
3641 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
3642 Now a constructor; rename from start_ext_lang_type_printers.
3643 (ext_lang_type_printers): Now a destructor; rename from
3644 free_ext_lang_type_printers.
3645 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
3646 Update.
3647 (c_type_print_base_struct_union): Update. Remove cleanups.
3648
608219fb
TT
36492018-03-27 Tom Tromey <tom@tromey.com>
3650
3651 * dwarf-index-write.c: Include <cmath>.
3652
3fcded8f
JB
36532018-03-27 Joel Brobecker <brobecker@adacore.com>
3654
3655 * NEWS: Add entry describing new "set|show varsize-limit" command.
3656 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
3657 command.
3658 * printcmd.c (_initialize_printcmd): Add "set var" alias of
3659 "set variable".
3660
cd4fb1b2
SM
36612018-03-27 Simon Marchi <simon.marchi@ericsson.com>
3662
3663 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
3664 dwarf-index-write.c
3665 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
3666 * dwarf-index-common.c: New file.
3667 * dwarf-index-common.h: New file.
3668 * dwarf-index-write.c: New file.
3669 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
3670 (struct dwarf2_section_info): Move from here.
3671 (dwarf2_section_info_def): Likewise.
3672 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
3673 (offset_type): Likewise.
3674 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
3675 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
3676 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
3677 (byte_swap): Likewise.
3678 (MAYBE_SWAP): Likewise.
3679 (dwarf2_per_cu_ptr): Likewise.
3680 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
3681 (struct tu_stats): Likewise.
3682 (struct dwarf2_per_objfile): Likewise.
3683 (struct dwarf2_per_cu_data): Likewise.
3684 (struct signatured_type): Likewise.
3685 (sig_type_ptr): Likewise.
3686 (DEF_VEC_P (sig_type_ptr)): Likewise.
3687 (INDEX4_SUFFIX): Likewise.
3688 (INDEX5_SUFFIX): Likewise.
3689 (DEBUG_STR_SUFFIX): Likewise.
3690 (dwarf2_read_section): Make non-static.
3691 (mapped_index_string_hash): Move from here.
3692 (dwarf5_djb_hash): Likewise.
3693 (file_write): Likewise.
3694 (class data_buf): Likewise.
3695 (struct symtab_index_entry): Likewise.
3696 (struct mapped_symtab): Likewise.
3697 (find_slot): Likewise.
3698 (hash_expand): Likewise.
3699 (add_index_entry): Likewise.
3700 (uniquify_cu_indices): Likewise.
3701 (class c_str_view): Likewise.
3702 (class c_str_view_hasher): Likewise.
3703 (class vector_hasher): Likewise.
3704 (write_hash_table): Likewise.
3705 (psym_index_map): Likewise.
3706 (struct addrmap_index_data): Likewise.
3707 (add_address_entry): Likewise.
3708 (add_address_entry_worker): Likewise.
3709 (write_address_map): Likewise.
3710 (symbol_kind): Likewise.
3711 (write_psymbols): Likewise.
3712 (struct signatured_type_index_data): Likewise.
3713 (write_one_signatured_type): Likewise.
3714 (recursively_count_psymbols): Likewise.
3715 (recursively_write_psymbols): Likewise.
3716 (class debug_names): Likewise.
3717 (check_dwarf64_offsets): Likewise.
3718 (psyms_seen_size): Likewise.
3719 (write_gdbindex): Likewise.
3720 (write_debug_names): Likewise.
3721 (assert_file_size): Likewise.
3722 (write_psymtabs_to_index): Likewise.
3723 (save_gdb_index_command): Likewise.
3724 (_initialize_dwarf2_read): Don't register the "save gdb-index"
3725 command.
3726 * dwarf2read.h: New file.
3727
59cc4834
JB
37282018-03-27 Joel Brobecker <brobecker@adacore.com>
3729
3730 PR gdb/22670
3731 * dwarf2read.c (dwarf2_physname): Do not return the demangled
3732 symbol name if the CU's language stores symbol names in linkage
3733 format.
3734 * language.h (struct language_defn)
3735 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
3736 all instances of this struct.
3737
67501539
TT
37382018-03-26 Tom Tromey <tom@tromey.com>
3739
3740 * stack.c (backtrace_command_1): Remove verbose code.
3741
76c939ac
TT
37422018-03-26 Tom Tromey <tom@tromey.com>
3743
3744 * python/py-framefilter.c (py_print_type): Don't catch
3745 exceptions. Return void.
3746 (py_print_value): Likewise.
3747 (py_print_single_arg): Likewise.
3748 (enumerate_args): Don't catch exceptions.
3749 (py_print_args): Likewise.
3750 (py_print_frame): Likewise.
3751 (gdbpy_apply_frame_filter): Catch exceptions here.
3752
9507b29c
TT
37532018-03-26 Tom Tromey <tom@tromey.com>
3754
3755 * stack.c (_initialize_stack): Remove trailing newlines from help
3756 text. Add "Usage" line to "backtrace" help.
3757
eb68e487
TT
37582018-03-26 Tom Tromey <tom@tromey.com>
3759
3760 PR python/16486:
3761 * python/py-framefilter.c (py_print_args): Call wrap_hint.
3762
1f111921
TT
37632018-03-26 Tom Tromey <tom@tromey.com>
3764
3765 * python/py-framefilter.c (py_print_single_arg): Return
3766 EXT_LANG_BT_ERROR from catch.
3767
fb7eb8b5
TT
37682018-03-26 Tom Tromey <tom@tromey.com>
3769
3770 PR backtrace/15584:
3771 * stack.c (backtrace_command_1): Move some code into no-filters
3772 "if".
3773
4ca59a9f
TT
37742018-03-26 Tom Tromey <tom@tromey.com>
3775
3776 * python/py-framefilter.c (throw_quit_or_print_exception): New
3777 function.
3778 (gdbpy_apply_frame_filter): Use it.
3779
92256134
TT
37802018-03-26 Tom Tromey <tom@tromey.com>
3781
3782 PR cli/17716:
3783 * python/py-framefilter.c (py_print_type, py_print_value)
3784 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
3785 RETURN_MASK_ERROR.
3786
7a630bc2
TT
37872018-03-26 Tom Tromey <tom@tromey.com>
3788
3789 * python/py-framefilter.c (enumerate_args): Use
3790 gdb::unique_xmalloc_ptr.
3791
63283d4a
TT
37922018-03-26 Tom Tromey <tom@tromey.com>
3793
3794 * python/py-framefilter.c (py_print_frame): Return
3795 EXT_LANG_BT_OK.
3796 (gdbpy_apply_frame_filter): Update comment.
3797 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
3798 Remove.
3799 <EXT_LANG_BT_NO_FILTERS>: Change value.
3800
978d6c75
TT
38012018-03-26 Tom Tromey <tom@tromey.com>
3802
3803 PR backtrace/15582:
3804 * stack.c (backtrace_command): Parse "hide" argument.
3805 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
3806 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
3807 constant.
3808
1cf7e640
TT
38092018-03-26 Tom Tromey <tom@tromey.com>
3810
3811 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
3812 add "flags".
3813 (backtrace_command): Remove "fulltrace", add "flags".
3814
ea3b0687
TT
38152018-03-26 Tom Tromey <tom@tromey.com>
3816
3817 * stack.c (backtrace_command): Rewrite command line parsing.
3818
9f034d75
SM
38192018-03-26 Simon Marchi <simon.marchi@ericsson.com>
3820
3821 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
3822
ce1459e5
SM
38232018-03-26 Simon Marchi <simon.marchi@ericsson.com>
3824
3825 * filename-seen-cache.h: Add include guard.
3826
4f7ae6f5
KS
38272018-03-26 Keith Seitz <keiths@redhat.com>
3828
3829 * symfile.c (place_section): Remove "struct" from section_addr_info
3830 in comment.
3831 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
3832 "struct" keyword from section_addr_info.
3833
5cd3e386
AH
38342018-03-26 Alan Hayward <alan.hayward@arm.com>
3835
3836 * regformats/regdef.h (reg): Add constructors.
3837
3e5ef9a4
PA
38382018-03-25 Pedro Alves <palves@redhat.com>
3839
3840 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
3841 if then/else bodies in var_func_name extraction.
3842
c88d2fcc 38432018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
3844
3845 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
3846 lookup_minimal_symbol() to find symbol entry.
3847 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
3848
b7fee5a3
KS
38492018-03-23 Keith Seitz <keiths@redhat.com>
3850
3851 PR c++/22968
3852 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
3853 nested type definitions for C++, too.
3854
2cc9b304
TT
38552018-03-23 Tom Tromey <tom@tromey.com>
3856
3857 * machoread.c (struct oso_el): Add a constructor. Don't define as
3858 a typedef.
3859 (macho_register_oso): Remove.
3860 (macho_symtab_read): Take a std::vector.
3861 (oso_el_compare_name): Now a std::sort comparator.
3862 (macho_symfile_read_all_oso): Take a std::vector.
3863 (macho_symfile_read): Use std::vector. Remove cleanups.
3864
a2b2bc12
TT
38652018-03-22 Tom Tromey <tom@tromey.com>
3866
3867 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
3868 (record_full_goto_bookmark): Use std::string.
3869
7a8f494c
PFC
38702018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3871
3872 PR tdep/18295
3873 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
3874 a single mask.
3875
dd6d677f
PFC
38762018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3877
3878 * rs6000-tdep.c (store_insn_p): New function.
3879 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
3880 and cr_reg to their unshifted values. Use store_insn_p to
3881 match LR saves using either R1 or fdata->alloca_reg. Use
3882 store_insn_p to match CR saves. Set alloca_reg_offset
3883 when alloca_reg and framep are set. Remove lr_reg shift
3884 when assigning to fdata->lr_register.
3885
26d6cec4
AA
38862018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
3887
3888 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
3889 command line args instead of emitting a warning.
3890
5d9310c4
SM
38912018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
3892
3893 * tracepoint.h (struct static_tracepoint_marker): Initialize
3894 fields, define default constructor, move constructor and move
3895 assignment, disable the rest.
3896 <str_id, extra>: Make std::string.
3897 (release_static_tracepoint_marker): Remove.
3898 (free_current_marker): Remove.
3899 * tracepoint.c (free_current_marker): Remove.
3900 (parse_static_tracepoint_marker_definition): Adjust to
3901 std::string, use new hex2str overload.
3902 (release_static_tracepoint_marker): Remove.
3903 (print_one_static_tracepoint_marker): Get marker by reference
3904 and adjust to std::string.
3905 (info_static_tracepoint_markers_command): Adjust to std::vector
3906 changes
3907 * target.h (static_tracepoint_marker_p): Remove typedef.
3908 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
3909 (struct target_ops) <to_static_tracepoint_marker_at>: Return
3910 bool.
3911 <to_static_tracepoint_markers_by_strid>: Return std::vector.
3912 * target-debug.h
3913 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
3914 (target_debug_print_std_vector_static_tracepoint_marker): New.
3915 (target_debug_print_struct_static_tracepoint_marker_p): Rename
3916 to...
3917 (target_debug_print_static_tracepoint_marker_p): ... this.
3918 * target-delegates.c: Re-generate.
3919 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
3920 Make std::string.
3921 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
3922 (decode_static_tracepoint_spec): Adjust to std::vector.
3923 (tracepoint_print_one_detail): Adjust to std::string.
3924 (strace_marker_decode_location): Adjust to std::string.
3925 (update_static_tracepoint): Adjust to std::string, remove call
3926 to release_static_tracepoint_marker.
3927 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
3928 Adjust to std::vector.
3929 * remote.c (remote_static_tracepoint_marker_at): Return bool.
3930 (remote_static_tracepoint_markers_by_strid): Adjust to
3931 std::vector.
3932 * common/rsp-low.h (hex2str): New overload with explicit count
3933 of bytes.
3934 * common/rsp-low.c (hex2str): New overload with explicit count
3935 of bytes.
3936 * unittests/rsp-low-selftests.c (test_hex2str): New function.
3937 (_initialize_rsp_low_selftests): Add test_hex2str test.
3938 * unittests/tracepoint-selftests.c
3939 (test_parse_static_tracepoint_marker_definition): Adjust to
3940 std::string.
3941
62c222b6
SM
39422018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
3943
3944 * tracepoint.c (parse_static_tracepoint_marker_definition):
3945 Consider case where the definition is followed by more
3946 definitions.
3947 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3948 tracepoint-selftests.c.
3949 * unittests/tracepoint-selftests.c: New.
3950
7eb2418f
PFC
39512018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3952
3953 * MAINTAINERS (Write After Approval): Add Pedro Franco de
3954 Carvalho.
3955
7cbe16e9
SR
39562018-03-20 Stephen Roberts <stephen.roberts@arm.com>
3957
3d6b3b82 3958 * symtab.c (find_pc_sect_line): fixed indentation.
7cbe16e9 3959
4ee89e90
SR
39602018-03-20 Stephen Roberts <stephen.roberts@arm.com>
3961
3d6b3b82 3962 * symtab.c (find_pc_sect_line): now uses binary search.
4ee89e90 3963
92630041
TT
39642018-03-19 Tom Tromey <tom@tromey.com>
3965
3966 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
3967 "IDENT" production.
3968
76727919
TT
39692018-03-19 Pedro Alves <palves@redhat.com>
3970 Tom Tromey <tom@tromey.com>
3971
3972 * unittests/observable-selftests.c: New file.
3973 * common/observable.h: New file.
3974 * observable.h: New file.
3975 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
3976 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
3977 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
3978 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
3979 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
3980 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
3981 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
3982 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
3983 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
3984 python/py-breakpoint.c, python/py-finishbreakpoint.c,
3985 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
3986 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
3987 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
3988 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
3989 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
3990 tui/tui-interp.c, valops.c: Update all users.
3991 * tui/tui-hooks.c (tui_bp_created_observer)
3992 (tui_bp_deleted_observer, tui_bp_modified_observer)
3993 (tui_inferior_exit_observer, tui_before_prompt_observer)
3994 (tui_normal_stop_observer, tui_register_changed_observer):
3995 Remove.
3996 (tui_observers_token): New global.
3997 (attach_or_detach, tui_attach_detach_observers): New functions.
3998 (tui_install_hooks, tui_remove_hooks): Use
3999 tui_attach_detach_observers.
4000 * record-btrace.c (record_btrace_thread_observer): Remove.
4001 (record_btrace_thread_observer_token): New global.
4002 * observer.sh: Remove.
4003 * observer.c: Rename to observable.c.
4004 * observable.c (namespace gdb_observers): Define new objects.
4005 (observer_debug): Move into gdb_observers namespace.
4006 (struct observer, struct observer_list, xalloc_observer_list_node)
4007 (xfree_observer_list_node, generic_observer_attach)
4008 (generic_observer_detach, generic_observer_notify): Remove.
4009 (_initialize_observer): Update.
4010 Don't include observer.inc.
4011 * Makefile.in (generated_files): Remove observer.h, observer.inc.
4012 (clean mostlyclean): Likewise.
4013 (observer.h, observer.inc): Remove targets.
4014 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
4015 (COMMON_SFILES): Use observable.c, not observer.c.
4016 * .gitignore: Remove observer.h.
4017
1cb1f3da
TT
40182018-03-18 Tom Tromey <tom@tromey.com>
4019
4020 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
4021 gdb::def_vector.
4022 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
4023
a06ab151
TT
40242018-03-17 Tom Tromey <tom@tromey.com>
4025
4026 * auto-load.c (auto_load_objfile_script_1): Use std::string.
4027
770623f7
TT
40282018-03-17 Tom Tromey <tom@tromey.com>
4029
4030 * target.c (class scoped_target_fd): New.
4031 (target_fileio_close_cleanup): Remove.
4032 (target_fileio_read_alloc_1): Use scoped_target_fd.
4033
39be3c7e
SM
40342018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
4035
4036 * silent-rules.mk: New.
4037 * Makefile.in: Include silent-rules.mk
4038 (srcdir, VPATH, top_srcdir): Move up.
4039 (COMPILE): Add ECHO_CXX.
4040 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
4041 (init.c): Add ECHO_INIT_C.
4042 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
4043 (version.c): Add ECHO_GEN.
4044 (printcmd.o): Add ECHO_CXX.
4045 (target-float.o): Add ECHO_CXX.
4046 (ada-exp.o): Add ECHO_CXX.
4047 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
4048 (insight$(EXEEXT)): Add ECHO_CXXLD.
4049 * gnulib/configure.ac: Add AM_SILENT_RULES.
4050 * gnulib/aclocal.m4: Re-generate.
4051 * gnulib/configure: Re-generate.
4052 * gnulib/import/Makefile.in: Re-generate.
4053
37e136b1
TT
40542018-03-16 Tom Tromey <tom@tromey.com>
4055
4056 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
4057 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
4058 * utils.c (do_free_section_addr_info)
4059 (make_cleanup_free_section_addr_info): Remove.
4060 * symfile.h (struct other_sections): Add constructor.
4061 (struct section_addr_info): Remove.
4062 (section_addr_info): New typedef.
4063 (struct sym_fns) <sym_offsets>: Change type of parameter.
4064 (build_section_addr_info_from_objfile)
4065 (relative_addr_info_to_section_offsets, addr_info_make_relative)
4066 (default_symfile_offsets, symbol_file_add)
4067 (symbol_file_add_from_bfd)
4068 (build_section_addr_info_from_section_table): Update.
4069 (alloc_section_addr_info, free_section_addr_info): Don't declare.
4070 * symfile.c (alloc_section_addr_info): Remove.
4071 (build_section_addr_info_from_section_table): Change return type.
4072 Update.
4073 (build_section_addr_info_from_bfd)
4074 (build_section_addr_info_from_objfile): Likewise.
4075 (free_section_addr_info): Remove.
4076 (relative_addr_info_to_section_offsets): Change type of "addrs".
4077 (addrs_section_compar): Now a std::sort comparator.
4078 (addrs_section_sort): Change return type.
4079 (addr_info_make_relative): Change type of "addrs". Update.
4080 (default_symfile_offsets, syms_from_objfile_1)
4081 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
4082 (symbol_file_add_separate): Update.
4083 (symbol_file_add): Change type of "addrs". Update.
4084 (add_symbol_file_command): Update. Remove cleanups.
4085 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
4086 cleanups.
4087 * symfile-debug.c (debug_sym_offsets): Change type of "info".
4088 * solib.c (solib_read_symbols): Update.
4089 * objfiles.c (objfile_relocate): Update. Remove cleanups.
4090 * machoread.c (macho_symfile_offsets): Update.
4091 * jit.c (jit_bfd_try_read_symtab): Update.
4092
03afa6ef
SM
40932018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
4094
4095 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4096 unittests/utils-selftests.c.
4097 * unittests/utils-selftests.c: New file.
4098
3ae9ce5d
TT
40992018-03-14 Tom Tromey <tom@tromey.com>
4100
4101 PR cli/14977:
4102 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
4103 for NULL.
4104
b8c2339b
TT
41052018-03-14 Tom Tromey <tom@tromey.com>
4106
4107 PR cli/19918:
4108 * printcmd.c (printf_pointer): Allow "-" in format.
4109
80ae639d
TT
41102018-03-14 Tom Tromey <tom@tromey.com>
4111
4112 * printcmd.c (_initialize_printcmd): Add usage to printf.
4113
0d671d99
YQ
41142018-03-14 Yao Qi <qiyao@sourceware.org>
4115
4116 * MAINTAINERS: Update my email address.
4117
b577b6af
TT
41182018-03-13 Tom Tromey <tom@tromey.com>
4119
4120 * machoread.c (macho_check_dsym): Change filenamep to a
4121 std::string*.
4122 (macho_symfile_read): Update.
4123 * symfile.c (load_command): Use std::string.
4124
89a3b63e
AB
41252018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
4126
4127 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
4128 to error message string.
4129 (riscv_register_name): Use xsnprintf instead of sprintf.
4130 (riscv_insn::fetch_instruction): Use gdb_assert instead of
4131 internal_error.
4132 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
4133 error.
4134 (riscv_push_dummy_call): Likewise.
4135
984c7238
TT
41362018-03-12 Tom Tromey <tom@tromey.com>
4137
4138 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
4139 Use gdb::byte_vector.
4140 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
4141
933522d1
YQ
41422018-03-12 Yao Qi <yao.qi@linaro.org>
4143
4144 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
4145 parameter type to readable_regcache.
4146 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
4147 the declaration.
4148
be2daae6
TT
41492018-03-11 Tom Tromey <tom@tromey.com>
4150
4151 * dwarf2read.c (struct nextfield): Add initializers.
4152 (struct nextfnfield): Remove.
4153 (struct fnfieldlist): Add initializers. Remove "length" and
4154 "head", use std::vector.
4155 (struct decl_field_list): Remove.
4156 (struct field_info): Add initializers.
4157 <fields, baseclasses>: Now std::vector.
4158 <nbaseclasses, nfnfields, typedef_field_list_count,
4159 nested_types_list_count>: Remove.
4160 (dwarf2_add_field, dwarf2_add_type_defn)
4161 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
4162 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
4163 (process_structure_scope): Update.
4164
484cf504
TT
41652018-03-11 Tom Tromey <tom@tromey.com>
4166
4167 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
4168 for use by std::sort.
4169 (build_type_psymtabs_1): Use std::vector.
4170
9bd8e0b0
EZ
41712018-03-09 Eli Zaretskii <eliz@gnu.org>
4172
4173 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
4174 and LIBMPFR in the printed configuration.
4175
5dc1a704
TT
41762018-03-08 Tom Tromey <tom@tromey.com>
4177
4178 * source.c (get_filename_and_charpos): Use scoped_fd.
4179 * nto-procfs.c (procfs_open_1): Use scoped_fd.
4180 (procfs_pidlist): Likewise.
4181 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
4182 (iterate_over_mappings): Likewise.
4183
fdf07f3a
TT
41842018-03-08 Tom Tromey <tom@tromey.com>
4185
4186 * infcall.c (struct call_return_meta_info)
4187 <stack_temporaries_enabled>: Remove.
4188 (get_call_return_value, call_function_by_hand_dummy): Update.
4189 * thread.c (disable_thread_stack_temporaries): Remove.
4190 (enable_thread_stack_temporaries): Remove.
4191 (thread_stack_temporaries_enabled_p): Return bool.
4192 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
4193 (get_last_thread_stack_temporary): Update.
4194 * eval.c (evaluate_subexp): Update.
4195 * gdbthread.h (class enable_thread_stack_temporaries): Now a
4196 class, not a function.
4197 (value_ptr, value_vec): Remove typedefs.
4198 (class thread_info) <stack_temporaries_enabled>: Now bool.
4199 <stack_temporaries>: Now a std::vector.
4200 (thread_stack_temporaries_enabled_p)
4201 (value_in_thread_stack_temporaries): Return bool.
4202
567a3e54
SM
42032018-03-08 Simon Marchi <simon.marchi@ericsson.com>
4204
4205 * remote.c (putpkt_binary): Fix omitted bytes reporting.
4206 (getpkt_or_notif_sane_1): Likewise.
4207
00b40057
SM
42082018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
4209
4210 * build-id.c (build_id_to_debug_bfd): Use std::string.
4211
a8dbfd58
SM
42122018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
4213
4214 * build-id.c (find_separate_debug_file_by_buildid): Return
4215 std::string.
4216 * build-id.h (find_separate_debug_file_by_buildid): Return
4217 std::string.
4218 * coffread.c (coff_symfile_read): Adjust to std::string.
4219 * elfread.c (elf_symfile_read): Adjust to std::string.
4220 * symfile.c (separate_debug_file_exists): Change parameter to
4221 std::string.
4222 (find_separate_debug_file): Return std::string.
4223 (find_separate_debug_file_by_debuglink): Return std::string.
4224 * symfile.h (find_separate_debug_file_by_debuglink): Return
4225 std::string.
4226
e6a58aa8
SM
42272018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
4228
4229 * common/xml-utils.c (xml_escape_text): Move code to...
4230 (xml_escape_text_append): ... this new function.
4231 * common/xml-utils.h (xml_escape_text_append): New declaration.
4232 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
4233 New function.
4234 (_initialize_xml_utils): register test_xml_escape_text_append as
4235 a selftest.
4236
4ef0bef6
AH
42372018-03-07 Alan Hayward <alan.hayward@arm.com>
4238
4239 * defs.h: Remove MAX_REGISTER_SIZE.
4240 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
4241 asserts.
4242 * python/py-unwind.c (pyuw_sniffer): Likewise.
4243
e0d3522b
TT
42442018-03-07 Tom Tromey <tom@tromey.com>
4245
4246 * linux-tdep.c (linux_info_proc): Update.
4247 * target.h (struct target_ops) <to_fileio_readlink>: Return
4248 optional<string>.
4249 (target_fileio_readlink): Return optional<string>.
4250 * remote.c (remote_hostio_readlink): Return optional<string>.
4251 * inf-child.c (inf_child_fileio_readlink): Return
4252 optional<string>.
4253 * target.c (target_fileio_readlink): Return optional<string>.
4254
ea005f31
AB
42552018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
4256
4257 * regcache.c (cooked_read_test): Add riscv to the list of
4258 architectures that have a save_reggroup.
4259
e95a97d4
AA
42602018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
4261
4262 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
4263 value is not a dynamic class object.
4264
d8344f3d
TT
42652018-03-06 Tom Tromey <tom@tromey.com>
4266
4267 * rust-exp.y: Formatting fixes.
4268
9add17f2
AB
42692018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
4270
4271 * riscv-tdep.c (riscv_register_name): Remove target description
4272 support.
4273 (riscv_gdbarch_init): Remove target description check.
4274
c9486dfe
AB
42752018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
4276
4277 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
4278 comment.
4279 * riscv-tdep.h: Likewise.
4280
d74aff3d
AB
42812018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
4282
4283 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
4284 (riscv_pseudo_register_write): Delete.
4285 (riscv_gdbarch_init): Remove all use of pseudo registers.
4286
7ea78b59
SM
42872018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
4288
4289 * record-btrace.c (btrace_print_lines): Replace cleanup
4290 parameter with RAII equivalents.
4291 (btrace_insn_history): Replace cleanup with RAII equivalents.
4292 * ui-out.h (make_cleanup_ui_out_list_begin_end,
4293 make_cleanup_ui_out_tuple_begin_end): Remove.
4294 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
4295 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
4296 make_cleanup_ui_out_list_begin_end): Remove.
4297
53127008
SM
42982018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
4299
4300 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
4301 parameter types to std::vector. Use bool.
4302 (record_btrace_wait): Replace VEC(tp_t) with
4303 std::vector<thread_info *>.
4304 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
4305
228f1508
SM
43062018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
4307
4308 * record-btrace.c (record_btrace_disable_callback): Remove.
4309 (struct scoped_btrace_disable): New.
4310 (record_btrace_open): Use scoped_btrace_disable.
4311
b2970c23
AB
43122018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
4313
4314 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
4315 reading values from registers.
4316
fb294655
AB
43172018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
4318
4319 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
4320 where appropriate.
4321
cab5bb9d
AB
43222018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
4323
4324 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
4325 change parameter type. Use GDB's print functions, and use
4326 core_addr_to_string where appropriate.
4327 (riscv_push_dummy_call): Use core_addr_to_string where
4328 appropriate, update call to riscv_print_arg_location, and reindent
4329 a few lines.
4330 (riscv_return_value): Update call to riscv_print_arg_location.
4331
dbbb1059
AB
43322018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
4333 Tim Newsome <tim@sifive.com>
4334 Albert Ou <a0u@eecs.berkeley.edu>
4335 Darius Rad <darius@bluespec.com>
4336
4337 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
4338 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
4339 (ALLDEPFILES): Add riscv-tdep.c
4340 * configure.tgt: Add riscv support.
4341 * riscv-tdep.c: New file.
4342 * riscv-tdep.h: New file.
4343 * NEWS: Mention new target.
4344 * MAINTAINERS: Add entry for riscv.
4345
5dc43913
AB
43462018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
4347
4348 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
4349 fields within aggregates.
4350
3dea1ef7
SM
43512018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
4352
4353 * record-btrace.c (btrace_print_lines): Change type of flags to
4354 gdb_disassembly_flags.
4355
7efba073
JB
43562018-03-04 John Baldwin <jhb@FreeBSD.org>
4357
4358 * fbsd-nat.c: Include "inf-ptrace.h".
4359 (USE_SIGTRAP_SIGINFO): Conditionally define.
4360 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
4361 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
4362 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
4363 function.
4364 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
4365 Likewise.
4366 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
4367 Likewise.
4368 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
4369 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
4370 "supports_stopped_by_hw_breakpoint" target methods.
4371
386a8676
JB
43722018-03-04 John Baldwin <jhb@FreeBSD.org>
4373
4374 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
4375 * fbsd-nat.c (debug_fbsd_nat): New variable.
4376 (show_fbsd_nat_debug): New function.
4377 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
4378 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
4379
12279366
JB
43802018-03-04 John Baldwin <jhb@FreeBSD.org>
4381
4382 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
4383 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
4384 prototype.
4385 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
4386 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
4387 method.
4388
54693cf5
SM
43892018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
4390
4391 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
4392 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
4393
ccb2231c
SM
43942018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
4395
4396 * charset.c (struct charset_vector): New.
4397 (charsets): Change type to charset_vector.
4398 (find_charset_names): Adjust.
4399 (add_one): Adjust.
4400 (_initialize_charset): Adjust.
4401
6fb16ce6
SM
44022018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
4403
4404 * progspace.h (struct program_space) <deleted_solibs>: Change
4405 type to std::vector<std::string>.
4406 * progspace.c (clear_program_space_solib_cache): Adjust.
4407 * breakpoint.c (print_solib_event): Adjust.
4408 (check_status_catch_solib): Adjust.
4409 * solib.c (update_solib_list): Adjust.
4410 * ui-out.h (class ui_out) <field_string>: New overload.
4411 * ui-out.c (ui_out::field_string): New overload.
4412
564b1e3f
SM
44132018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
4414
4415 * progspace.h (struct program_space): Add constructor and
4416 destructor, initialize fields.
4417 (add_program_space): Remove.
4418 * progspace.c (add_program_space): Rename to...
4419 (program_space::program_space): ... this.
4420 (release_program_space): Rename to...
4421 (program_space::~program_space): ... this.
4422 (delete_program_space): Use delete to delete program_space.
4423 (initialize_progspace): Use new to allocate program_space.
4424 * inferior.c (add_inferior_with_spaces): Likewise.
4425 (clone_inferior_command): Likewise.
4426 * infrun.c (follow_fork_inferior): Likewise.
4427 (handle_vfork_child_exec_or_exit): Likewise.
4428
e80aaf61
SM
44292018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
4430
4431 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
4432 (delim_string_to_char_ptr_vec): Return std::vector of
4433 gdb::unique_xmalloc_ptr.
4434 (dirnames_to_char_ptr_vec_append): Take std::vector of
4435 gdb::unique_xmalloc_ptr.
4436 (dirnames_to_char_ptr_vec): Return std::vector of
4437 gdb::unique_xmalloc_ptr.
4438 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
4439 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
4440 (delim_string_to_char_ptr_vec): Return an std::vector of
4441 gdb::unique_xmalloc_ptr, adjust the code.
4442 (dirnames_to_char_ptr_vec_append): Take an std::vector of
4443 gdb::unique_xmalloc_ptr, adjust the code.
4444 (dirnames_to_char_ptr_vec): Return an std::vector of
4445 gdb::unique_xmalloc_ptr, adjust the code.
4446 * auto-load.c (auto_load_safe_path_vec): Change type to
4447 std::vector of gdb::unique_xmalloc_ptr.
4448 (auto_load_expand_dir_vars): Return an std::vector of
4449 gdb::unique_xmalloc_ptr, adjust the code.
4450 (auto_load_safe_path_vec_update): Adjust.
4451 (filename_is_in_auto_load_safe_path_vec): Adjust.
4452 (auto_load_objfile_script_1): Adjust.
4453 * build-id.c (build_id_to_debug_bfd): Adjust.
4454 * linux-thread-db.c (thread_db_load_search): Adjust.
4455 * source.c (add_path): Adjust.
4456 (openp): Adjust.
4457 * symfile.c (find_separate_debug_file): Adjust.
4458 * utils.c (do_free_char_ptr_vec): Remove.
4459 (make_cleanup_free_char_ptr_vec): Remove.
4460
ab818ade
SDJ
44612018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
4462
4463 PR gdb/22907
4464 * common/pathstuff.c: Conditionally include "<windows.h>".
4465
e1e6f073
GS
44662018-03-01 Georg Sauthoff <mail@georg.so>
4467
4468 PR gdb/22888
4469 * gcore.in: Quote variables and switch interpreter to bash.
4470
c7b15a66
TT
44712018-03-01 Tom Tromey <tom@tromey.com>
4472
4473 * dwarf2read.c (alloc_discriminant_info): Fix default_index
4474 assertion. Add assertion for discriminant_index.
4475 (quirk_rust_enum): Use correct base type name in univariant case.
4476
0cb7c7b0
SM
44772018-03-01 Simon Marchi <simon.marchi@ericsson.com>
4478
4479 * record.c (get_call_history_modifiers): Return a
4480 record_print_flags.
4481 (cmd_record_call_history): Adjust.
4482 * record-btrace.c (record_btrace_call_history): Adjust.
4483 (record_btrace_call_history_range): Adjust.
4484 (record_btrace_call_history_from): Adjust.
4485 * target-debug.h (target_debug_print_record_print_flags): New.
4486 * target-delegates.c: Re-generate.
4487 * target.c (target_call_history): Change flags type.
4488 (target_call_history_from): Likewise.
4489 (target_call_history_range): Likewise.
4490 * target.h (struct target_ops) <target_call_history>: Likewise.
4491 (target_call_history_from): Likewise.
4492 (target_call_history_range): Likewise.
4493
25e3c82c
SDJ
44942018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4495 Simon Marchi <simon.marchi@polymtl.ca>
4496
4497 * common/common-utils.c: Include "sys/stat.h".
4498 (is_regular_file): Move here from "source.c"; change return
4499 type to "bool".
4500 * common/common-utils.h (is_regular_file): New prototype.
4501 * common/pathstuff.c (contains_dir_separator): New function.
4502 * common/pathstuff.h (contains_dir_separator): New prototype.
4503 * source.c: Don't include "sys/stat.h".
4504 (is_regular_file): Move to "common/common-utils.c".
4505
b4987c95
SDJ
45062018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4507
4508 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
4509 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
4510 * auto-load.c: Include "common/pathstuff.h".
4511 * common/common-def.h (current_directory): Move here.
4512 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
4513 function.
4514 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
4515 prototype.
4516 * common/pathstuff.c: New file.
4517 * common/pathstuff.h: New file.
4518 * compile/compile.c: Include "common/pathstuff.h".
4519 * defs.h (current_directory): Move to "common/common-defs.h".
4520 * dwarf2read.c: Include "common/pathstuff.h".
4521 * exec.c: Likewise.
4522 * guile/scm-safe-call.c: Likewise.
4523 * linux-thread-db.c: Likewise.
4524 * main.c: Likewise.
4525 * nto-tdep.c: Likewise.
4526 * objfiles.c: Likewise.
4527 * source.c: Likewise.
4528 * symtab.c: Likewise.
4529 * utils.c: Include "common/pathstuff.h".
4530 (gdb_realpath): Move to "common/pathstuff.c".
4531 (gdb_realpath_keepfile): Likewise.
4532 (gdb_abspath): Likewise.
4533 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
4534 (gdb_realpath_keepfile): Likewise.
4535 (gdb_abspath): Likewise.
4536
f169cfdc
JB
45372018-02-28 John Baldwin <jhb@FreeBSD.org>
4538
4539 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
4540 wildcard process pid for super_resume for kernels with a
4541 specific bug.
4542
e05cac70
PM
45432018-02-27 Phil Muldoon <pmuldoon@redhat.com>
4544
4545 * compile/compile.c (get_args): Add additional comments
4546 explaining function.
4547
55089490
TT
45482018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
4549 Tom Tromey <tom@tromey.com>
4550
4551 * target.h (memory_write_request_s): Remove typedef. Don't define
4552 VEC.
4553 (target_write_memory_blocks): Change argument to std::vector.
4554 (struct memory_write_request): Add constructor.
4555 * target-memory.c (compare_block_starting_address): Return bool.
4556 Change argument types.
4557 (claim_memory): Change arguments to use std::vector.
4558 (split_regular_and_flash_blocks, blocks_to_erase)
4559 (compute_garbled_blocks): Likewise.
4560 (cleanup_request_data, cleanup_write_requests_vector): Remove.
4561 (target_write_memory_blocks): Change argument to std::vector.
4562 * symfile.c (struct load_section_data): Add constructor and
4563 destructor. Use std::vector for "requests".
4564 (struct load_progress_data): Add initializers.
4565 (load_section_callback): Update. Use "new".
4566 (clear_memory_write_data): Remove.
4567 (generic_load): Update.
4568
0c305b61
AH
45692018-02-27 Alan Hayward <alan.hayward@arm.com>
4570
4571 * arch/aarch64.h: Use common/tdesc.h.
4572
c5196c92
MR
45732018-02-26 Maciej W. Rozycki <macro@mips.com>
4574
4575 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
4576 architecture with a 64-bit ABI.
4577
37c33887
MR
45782018-02-26 Maciej W. Rozycki <macro@mips.com>
4579
4580 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
4581 ahead of target description loading.
4582
d4dd3282
TT
45832018-02-26 Tom Tromey <tom@tromey.com>
4584
4585 * stack.c (backtrace_command_1): Update.
4586 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
4587 of "flags".
4588 * python/py-framefilter.c (py_print_frame)
4589 (gdbpy_apply_frame_filter): Change type of "flags".
4590 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
4591 of "flags".
4592 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
4593 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
4594 * extension.h (enum frame_filter_flag): Rename from
4595 frame_filter_flags.
4596 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
4597 (apply_ext_lang_frame_filter): Change type of "flags".
4598 * extension.c (apply_ext_lang_frame_filter): Change type of
4599 "flags".
4600 * extension-priv.h (struct extension_language_ops)
4601 <apply_frame_filter>: Change type of "flags".
4602
6893c19a
TT
46032018-02-26 Tom Tromey <tom@tromey.com>
4604
4605 PR python/16497:
4606 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
4607 off-by-one in py_end computation.
4608 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
4609 PRINT_MORE_FRAMES.
4610 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
4611 constant.
4612
2ddeaf8a
TT
46132018-02-26 Tom Tromey <tom@tromey.com>
4614
4615 * dwarf2read.c (struct variant_field): New.
4616 (struct nextfield) <variant>: New field.
4617 (dwarf2_add_field): Handle DW_TAG_variant_part.
4618 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
4619 discriminated union.
4620 (read_structure_type): Handle DW_TAG_variant_part.
4621 (handle_struct_member_die): New function, extracted from
4622 process_structure_scope. Handle DW_TAG_variant.
4623 (process_structure_scope): Handle discriminated unions. Call
4624 handle_struct_member_die.
4625
c9317f21
TT
46262018-02-26 Tom Tromey <tom@tromey.com>
4627
4628 * rust-lang.h (rust_last_path_segment): Declare.
4629 * rust-lang.c (rust_last_path_segment): Now public. Change
4630 contract.
4631 (struct disr_info): Remove.
4632 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
4633 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
4634 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
4635 (rust_enum_p, rust_enum_variant): New function.
4636 (rust_underscore_fields): Remove "offset" parameter.
4637 (rust_print_enum): New function.
4638 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
4639 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
4640 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
4641 enums.
4642 (rust_internal_print_type): New function, from rust_print_type.
4643 Remove enum code.
4644 (rust_print_type): Call rust_internal_print_type.
4645 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
4646 Update enum handling.
4647 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
4648 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
4649 (rust_union_quirks): New functions.
4650 (process_full_comp_unit, process_full_type_unit): Call
4651 rust_union_quirks.
4652 (process_structure_scope): Update rust_unions if necessary.
4653
7c22600a
TT
46542018-02-26 Tom Tromey <tom@tromey.com>
4655
4656 * value.h (value_union_variant): Declare.
4657 * valops.c (value_union_variant): New function.
4658 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
4659 (struct discriminant_info): New.
4660 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
4661 enumerator.
4662 (struct main_type) <flag_discriminated_union>: New field.
4663
15ce8941
TT
46642018-02-26 Tom Tromey <tom@tromey.com>
4665
4666 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4667 unittests/unpack-selftests.c.
4668 * unittests/unpack-selftests.c: New file.
4669 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
4670
48fbe735
YQ
46712018-02-26 Yao Qi <yao.qi@linaro.org>
4672
4673 * dwarf2read.c (struct partial_die_info) <read>: New method.
4674 (read_partial_die): Remove the declaration.
4675 (load_partial_dies): Update.
4676 (partial_die_info::partial_die_info):
4677 (read_partial_die): Change it to partial_die_info::read.
4678
52356b79
YQ
46792018-02-26 Yao Qi <yao.qi@linaro.org>
4680
4681 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
4682 (fixup_partial_die): Remove declaration.
4683 (scan_partial_symbols): Update.
4684 (partial_die_parent_scope): Likewise.
4685 (partial_die_full_name): Likewise.
4686 (fixup_partial_die): Change it to partial_die_info::fixup.
4687
35cc7ed7
YQ
46882018-02-26 Yao Qi <yao.qi@linaro.org>
4689
4690 * dwarf2read.c (read_partial_die): Update the declaration.
4691 (load_partial_dies): Caller update.
4692 (read_partial_die): Remove one argument abbrev_len.
4693
6f06d47b
YQ
46942018-02-26 Yao Qi <yao.qi@linaro.org>
4695
4696 * dwarf2read.c (struct partial_die_info): Add ctor, delete
4697 assignment operator.
4698 (load_partial_dies): Use ctor and copy ctor.
4699 (read_partial_die): Update.
4700 (dwarf2_cu::find_partial_die): Use ctor.
4701
d590ff25
YQ
47022018-02-26 Yao Qi <yao.qi@linaro.org>
4703
4704 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
4705 (find_partial_die_in_comp_unit): Change it to
4706 dwarf2_cu::find_partial_die.
4707 (find_partial_die): Update.
4708
fd0a254f
YQ
47092018-02-26 Yao Qi <yao.qi@linaro.org>
4710
4711 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
4712 is NULL.
4713
cd9983dd
YQ
47142018-02-26 Yao Qi <yao.qi@linaro.org>
4715
4716 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
4717
f46cd62a
AH
47182018-02-26 Alan Hayward <alan.hayward@arm.com>
4719
4720 * arch/amd64.h: Use common/tdesc.h.
4721 * arch/i386.c: Likewise.
4722 * arch/i386.h: Likewise.
4723 * arch/tic6x.c: Likewise.
4724 * arch/tdesc.h: Move file from here...
4725 * common/tdesc.h: ...to here.
4726 * features/aarch64-core.c: Regenerate.
4727 * features/aarch64-fpu.c: Regenerate.
4728 * features/i386/32bit-avx.c: Regenerate.
4729 * features/i386/32bit-avx512.c: Regenerate.
4730 * features/i386/32bit-core.c: Regenerate.
4731 * features/i386/32bit-linux.c: Regenerate.
4732 * features/i386/32bit-mpx.c: Regenerate.
4733 * features/i386/32bit-pkeys.c: Regenerate.
4734 * features/i386/32bit-sse.c: Regenerate.
4735 * features/i386/64bit-avx.c: Regenerate.
4736 * features/i386/64bit-avx512.c: Regenerate.
4737 * features/i386/64bit-core.c: Regenerate.
4738 * features/i386/64bit-linux.c: Regenerate.
4739 * features/i386/64bit-mpx.c: Regenerate.
4740 * features/i386/64bit-pkeys.c: Regenerate.
4741 * features/i386/64bit-segments.c: Regenerate.
4742 * features/i386/64bit-sse.c: Regenerate.
4743 * features/i386/x32-core.c: Regenerate.
4744 * features/tic6x-c6xp.c: Regenerate.
4745 * features/tic6x-core.c: Regenerate.
4746 * features/tic6x-gp.c: Regenerate.
4747 * target-descriptions.c: Use common/tdesc.h.
4748 * target-descriptions.h: Likewise.
4749
9b292f68
TT
47502018-02-24 Tom Tromey <tom@tromey.com>
4751
4752 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
4753 (try_thread_db_load_from_dir, thread_db_load_search): Use
4754 std::string.
4755 (info_auto_load_libthread_db_compare): Return bool. Change
4756 argument types.
4757 (info_auto_load_libthread_db): Use std::vector, std::string.
4758 Remove cleanups.
4759
281d762b
TT
47602018-02-24 Tom Tromey <tom@tromey.com>
4761
4762 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
4763 std::string.
4764 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
4765 std::string*.
4766 * gdbarch.c: Rebuild.
4767 * gdbarch.h: Rebuild.
4768 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
4769 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
4770 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
4771 std::string*.
4772
9d8780f0
SM
47732018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
4774
4775 * gdbtypes.h (sect_offset): Change type to uint64_t.
4776 (sect_offset_str): New function.
4777 * dwarf2read.c (create_addrmap_from_aranges): Use
4778 sect_offset_str.
4779 (error_check_comp_unit_head): Likewise.
4780 (create_debug_type_hash_table): Likewise.
4781 (read_cutu_die_from_dwo): Likewise.
4782 (init_cutu_and_read_dies): Likewise.
4783 (init_cutu_and_read_dies_no_follow): Likewise.
4784 (process_psymtab_comp_unit_reader): Likewise.
4785 (partial_die_parent_scope): Likewise.
4786 (peek_die_abbrev): Likewise.
4787 (process_queue): Likewise.
4788 (dwarf2_physname): Likewise.
4789 (read_namespace_alias): Likewise.
4790 (read_import_statement): Likewise.
4791 (create_dwo_cu_reader): Likewise.
4792 (create_cus_hash_table): Likewise.
4793 (lookup_dwo_cutu): Likewise.
4794 (inherit_abstract_dies): Likewise.
4795 (read_func_scope): Likewise.
4796 (read_call_site_scope): Likewise.
4797 (dwarf2_add_member_fn): Likewise.
4798 (read_common_block): Likewise.
4799 (read_module_type): Likewise.
4800 (read_typedef): Likewise.
4801 (read_subrange_type): Likewise.
4802 (load_partial_dies): Likewise.
4803 (read_partial_die): Likewise.
4804 (find_partial_die): Likewise.
4805 (read_str_index): Likewise.
4806 (dwarf2_string_attr): Likewise.
4807 (build_error_marker_type): Likewise.
4808 (lookup_die_type): Likewise.
4809 (dump_die_shallow): Likewise.
4810 (follow_die_ref): Likewise.
4811 (dwarf2_fetch_die_loc_sect_off): Likewise.
4812 (dwarf2_fetch_constant_bytes): Likewise.
4813 (follow_die_sig): Likewise.
4814 (get_signatured_type): Likewise.
4815 (get_DW_AT_signature_type): Likewise.
4816 (dwarf2_find_containing_comp_unit): Likewise.
4817 (set_die_type): Likewise.
4818
8ec57239
JB
48192018-02-21 John Baldwin <jhb@FreeBSD.org>
4820
4821 * arch/aarch64.c: Include "common-defs.h".
4822 * arch/amd64.c: Likewise.
4823 * arch/i386.c: Likewise.
4824
3eac2b65
TT
48252018-02-21 Tom Tromey <tom@tromey.com>
4826
4827 * value.h: (extract_field_op): Update.
4828 * eval.c (extract_field_op): Return a const char *.
4829 * expression.h (parse_expression_for_completion): Update.
4830 * completer.c (complete_expression): Update.
4831 (add_struct_fields): Make fieldname const.
4832 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
4833 (mark_completion_tag, parse_exp_in_context_1): Update.
4834 (parse_expression_for_completion): Change "name" to
4835 unique_xmalloc_ptr*.
4836
6ccb583f
TT
48372018-02-21 Tom Tromey <tom@tromey.com>
4838
4839 * infcall.c (call_function_by_hand_dummy): Use std::vector.
4840
c113ed0c
YQ
48412018-02-21 Yao Qi <yao.qi@linaro.org>
4842
4843 * avr-tdep.c (avr_read_pc): Change parameter type to
4844 readable_regcache.
4845 * gdbarch.sh (read_pc): Likewise.
4846 * gdbarch.c: Re-generated.
4847 * gdbarch.h: Re-generated.
4848 * hppa-tdep.c (hppa_read_pc): Change parameter type to
4849 readable_regcache.
4850 * ia64-tdep.c (ia64_read_pc): Likewise.
4851 * mips-tdep.c (mips_read_pc): Likewise.
4852 * spu-tdep.c (spu_read_pc): Likewise.
4853
4c74fe6b
YQ
48542018-02-21 Yao Qi <yao.qi@linaro.org>
4855
4856 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
4857 * regcache-dump.c: New file.
4858 * regcache.c: Move register_dump to regcache-dump.c.
4859 (maintenance_print_registers): Likewise.
4860 (maintenance_print_raw_registers): Likewise.
4861 (maintenance_print_cooked_registers): Likewise.
4862 (maintenance_print_register_groups): Likewise.
4863 (maintenance_print_remote_registers): Likewise.
4864 (_initialize_regcache): Likewise.
4865 * regcache.h (register_dump): Moved from regcache.c.
4866
796bb026
YQ
48672018-02-21 Yao Qi <yao.qi@linaro.org>
4868
4869 * regcache.c (regcache::regcache): Update.
4870 (regcache::invalidate): Move it to detached_regcache::invalidate.
4871 (get_thread_arch_aspace_regcache): Update.
4872 (regcache::raw_update): Update.
4873 (regcache::cooked_read): Remove some code.
4874 (regcache::cooked_read_value): Likewise.
4875 (regcache::raw_write): Remove assert on m_readonly_p.
4876 (regcache::raw_supply_integer): Move it to
4877 detached_regcache::raw_supply_integer.
4878 (regcache::raw_supply_zeroed): Likewise.
4879 * regcache.h (detached_regcache) <raw_supply_integer>: New
4880 declaration.
4881 <raw_supply_zeroed, invalidate>: Likewise.
4882 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
4883 <invalidate>: Likewise.
4884 <m_readonly_p>: Removed.
4885
215c69dc
YQ
48862018-02-21 Yao Qi <yao.qi@linaro.org>
4887
4888 * infcmd.c (get_return_value): Let stop_regs point to
4889 get_current_regcache.
4890 * regcache.c (regcache::regcache): Remove.
4891 (register_dump_reg_buffer): New class.
4892 (regcache_print): Adjust.
4893 * regcache.h (regcache): Remove constructors.
4894
f3384e66
YQ
48952018-02-21 Yao Qi <yao.qi@linaro.org>
4896
4897 * regcache.c (class register_dump): New class.
4898 (register_dump_regcache, register_dump_none): New class.
4899 (register_dump_remote, register_dump_groups): New class.
4900 (regcache_print): Update.
4901 * regcache.h (regcache_dump_what): Move it to regcache.c.
4902 (regcache) <dump>: Remove.
4903
c8ec2f33
YQ
49042018-02-21 Yao Qi <yao.qi@linaro.org>
4905
4906 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
4907 reg_buffer_rw *.
4908 (jit_unwind_reg_set_impl): Call raw_supply.
4909 (jit_frame_sniffer): Use reg_buffer_rw.
4910 * record-full.c (record_full_core_regbuf): Change its type.
4911 (record_full_core_open_1): Use reg_buffer_rw.
4912 (record_full_close): Likewise.
4913 (record_full_core_fetch_registers): Use regcache->raw_supply.
4914 (record_full_core_store_registers): Likewise.
4915 * regcache.c (regcache::get_register_status): Move it to
4916 reg_buffer.
4917 (regcache_raw_set_cached_value): Remove.
4918 (regcache::raw_set_cached_value): Remove.
4919 (regcache::raw_write): Call raw_supply.
4920 (regcache::raw_supply): Move it to reg_buffer_rw.
4921 * regcache.h (regcache_raw_set_cached_value): Remove.
4922 (reg_buffer_rw): New class.
4923
daf6667d
YQ
49242018-02-21 Yao Qi <yao.qi@linaro.org>
4925
4926 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
4927 readonly_detached_regcache.
4928 (dummy_frame_prev_register): Use regcache->cooked_read.
4929 * frame.c (frame_save_as_regcache): Change return type.
4930 (frame_pop): Update.
4931 * frame.h (frame_save_as_regcache): Update declaration.
4932 * inferior.h (get_infcall_suspend_state_regcache): Update
4933 declaration.
4934 * infrun.c (infcall_suspend_state) <registers>: use
4935 readonly_detached_regcache.
4936 (save_infcall_suspend_state): Don't use regcache_dup.
4937 (get_infcall_suspend_state_regcache): Change return type.
4938 * linux-fork.c (struct fork_info) <savedregs>: Change to
4939 readonly_detached_regcache.
4940 <pc>: New field.
4941 (fork_save_infrun_state): Don't use regcache_dup.
4942 (info_checkpoints_command): Adjust.
4943 * mi/mi-main.c (register_changed_p): Update declaration.
4944 (mi_cmd_data_list_changed_registers): Use
4945 readonly_detached_regcache.
4946 (register_changed_p): Change parameter type to
4947 readonly_detached_regcache.
4948 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
4949 readonly_detached_regcache.
4950 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
4951 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
4952 New.
4953 (regcache::save): Move it to reg_buffer.
4954 (regcache::restore): Change parameter type.
4955 (regcache_dup): Remove.
4956 * regcache.h (reg_buffer) <save>: New method.
4957 (readonly_detached_regcache): New class.
4958 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
4959 readonly_detached_regcache.
4960 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
4961
fc5b8736
YQ
49622018-02-21 Yao Qi <yao.qi@linaro.org>
4963
4964 * frame.c (frame_save_as_regcache): Use regcache method save.
4965 (frame_pop): Use regcache method restore.
4966 * infrun.c (restore_infcall_suspend_state): Likewise.
4967 * linux-fork.c (fork_load_infrun_state): Likewise.
4968 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
4969 save.
4970 * regcache.c (regcache_save): Remove.
4971 (regcache::restore): More asserts.
4972 (regcache_cpy): Remove.
4973 * regcache.h (regcache_save): Remove the declaration.
4974 (regcache::restore): Move from private to public.
4975 Remove the friend declaration of regcache_cpy.
4976 (regcache_cpy): Remove declaration.
4977
849d0ba8
YQ
49782018-02-21 Yao Qi <yao.qi@linaro.org>
4979
4980 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
4981 parameter type to 'readable_regcache *'.
4982 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
4983 * arm-tdep.c (arm_neon_quad_read): Likewise.
4984 (arm_pseudo_read): Likewise.
4985 * avr-tdep.c (avr_pseudo_register_read): Likewise.
4986 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
4987 * frv-tdep.c (frv_pseudo_register_read): Likewise.
4988 * gdbarch.c: Re-generated.
4989 * gdbarch.h: Re-generated.
4990 * gdbarch.sh (pseudo_register_read): Change parameter type to
4991 'readable_regcache *'.
4992 (pseudo_register_read_value): Likewise.
4993 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
4994 (h8300_pseudo_register_read): Likewise.
4995 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
4996 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
4997 (i386_pseudo_register_read_into_value): Likewise.
4998 (i386_pseudo_register_read_value): Likewise.
4999 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
5000 declaration.
5001 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
5002 * m32c-tdep.c (m32c_raw_read): Likewise.
5003 (m32c_read_flg): Likewise.
5004 (m32c_banked_register): Likewise.
5005 (m32c_banked_read): Likewise.
5006 (m32c_sb_read): Likewise.
5007 (m32c_part_read): Likewise.
5008 (m32c_cat_read): Likewise.
5009 (m32c_r3r2r1r0_read): Likewise.
5010 (m32c_pseudo_register_read): Likewise.
5011 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
5012 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
5013 (mep_pseudo_cr64_read): Likewise.
5014 (mep_pseudo_register_read): Likewise.
5015 * mips-tdep.c (mips_pseudo_register_read): Likewise.
5016 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
5017 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
5018 * regcache.c (regcache::raw_read): Move it to readable_regcache.
5019 (regcache::cooked_read): Likewise.
5020 (regcache::cooked_read_value): Likewise.
5021 (regcache_cooked_read_signed):
5022 (regcache::cooked_read): Likewise.
5023 * regcache.h (readable_regcache): New class.
5024 (regcache): Inherit readable_regcache. Move some methods to
5025 readable_regcache.
5026 * rl78-tdep.c (rl78_pseudo_register_read): Change
5027 parameter type to 'readable_regcache *'.
5028 * rs6000-tdep.c (do_regcache_raw_read): Remove.
5029 (e500_pseudo_register_read): Change parameter type to
5030 'readable_regcache *'.
5031 (dfp_pseudo_register_read): Likewise.
5032 (vsx_pseudo_register_read): Likewise.
5033 (efpr_pseudo_register_read): Likewise.
5034 * s390-tdep.c (s390_pseudo_register_read): Likewise.
5035 * sh-tdep.c (sh_pseudo_register_read): Likewise.
5036 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
5037 (sh64_pseudo_register_read): Likewise.
5038 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
5039 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
5040 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
5041 (spu_pseudo_register_read): Likewise.
5042 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
5043 (xtensa_pseudo_register_read): Likewise.
5044
31716595
YQ
50452018-02-21 Yao Qi <yao.qi@linaro.org>
5046
5047 * regcache.c (regcache::regcache): Call reg_buffer ctor.
5048 (regcache::arch): Move it to reg_buffer::arch.
5049 (regcache::register_buffer): Likewise.
5050 (regcache::assert_regnum): Likewise.
5051 (regcache::num_raw_registers): Likewise.
5052 * regcache.h (reg_buffer): New class.
5053 (regcache): Inherit reg_buffer.
5054
7104e59b
SM
50552018-02-20 Simon Marchi <simon.marchi@ericsson.com>
5056
5057 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
5058 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
5059
2d8adcbd
MM
50602018-02-20 Markus Metzger <markus.t.metzger@intel.com>
5061
5062 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
5063
b5884fa7
AH
50642018-02-19 Alan Hayward <alan.hayward@arm.com>
5065
5066 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
5067 (SFILES): Remove common/*.c files.
5068 (COMMON_OBS): Remove some *.o files built from common/*.c files.
5069 * common/common.host: Add common reference.
5070 * configure.ac: Likewise.
5071 * configure: Regenerate.
5072
fd90ace4
YQ
50732018-02-16 Yao Qi <yao.qi@linaro.org>
5074
5075 * block.c (block_namespace_info): Inherit allocate_on_obstack.
5076 (block_initialize_namespace): Use new.
5077 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
5078 (dwarf2_free_objfile): Use delete.
5079 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
5080 (copy_type_recursive): Use new.
5081 * gdb_obstack.h (allocate_on_obstack): New.
5082
85046ae2
YQ
50832018-02-15 Yao Qi <yao.qi@linaro.org>
5084
5085 PR gdb/22849
5086 * inferior.c (exit_inferior_1): Reset inf->control.
5087
355c559b
JB
50882018-02-15 Joel Brobecker <brobecker@adacore.com>
5089
5090 * ada-lang.c (ada_to_fixed_value_create): Delete advance
5091 declaration.
5092
980548fd
PA
50932018-02-14 Pedro Alves <palves@redhat.com>
5094
5095 * frame-unwind.c (frame_unwind_try_unwinder): Always call
5096 frame_cleanup_after_sniffer on exception.
5097
692d6f97
TT
50982018-02-14 Tom Tromey <tom@tromey.com>
5099
5100 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
5101 const.
5102 (solib_bfd_open): Make pathname const.
5103 * solib.c (solib_bfd_open): Make pathname const.
5104 * solib-spu.c (spu_bfd_fopen): Make name const.
5105 (spu_bfd_open): Make pathname const.
5106 * solib-darwin.c (darwin_bfd_open): Make pathname const.
5107 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
5108
e0cc99a6
TT
51092018-02-14 Tom Tromey <tom@tromey.com>
5110
5111 * symfile.c (symfile_bfd_open): Update.
5112 * source.h (openp, source_full_path_of, find_and_open_source):
5113 Change argument type to unique_xmalloc_ptr.
5114 * source.c (openp): Take a unique_xmalloc_ptr.
5115 (source_full_path_of, find_and_open_source): Likewise.
5116 (open_source_file, symtab_to_fullname): Update.
5117 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
5118 unique_xmalloc_ptr.
5119 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
5120 (exec_file_find): Update.
5121 * psymtab.c (psymtab_to_fullname): Update.
5122 * nto-tdep.h (nto_find_and_open_solib): Update.
5123 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
5124 unique_xmalloc_ptr.
5125 * exec.c (exec_file_attach): Update.
5126 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
5127 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
5128
b46a8d7c
TT
51292018-02-14 Tom Tromey <tom@tromey.com>
5130
5131 * solib.c: Include source.h.
5132 * nto-tdep.c: Include source.h.
5133 * mi/mi-cmd-env.c: Include source.h.
5134 * infcmd.c: Include source.h.
5135 * exec.c: Include source.h.
5136 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
5137 (add_path, directory_switch, source_path, init_source_path): Move
5138 declarations...
5139 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
5140 (add_path, directory_switch, source_path, init_source_path):
5141 ...here.
5142
797bc1cb
TT
51432018-02-14 Tom Tromey <tom@tromey.com>
5144
5145 * solist.h (exec_file_find, solib_find): Return
5146 unique_xmalloc_ptr.
5147 (solib_bfd_fopen): Take a const char *.
5148 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
5149 (exec_file_find, solib_find): Likewise.
5150 (solib_bfd_fopen): Do not take ownership of "pathname".
5151 (solib_bfd_open): Use unique_xmalloc_ptr.
5152 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
5153 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
5154 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
5155 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
5156
f98b2e33
JB
51572018-02-14 Joel Brobecker <brobecker@adacore.com>
5158
5159 * ada-lang.c (name_match_type_from_name): Remove reference to
5160 ada_name_for_lookup in function's documentation.
5161 * ada-lang.h (ada_name_for_lookup): Delete declaration.
5162
24b9144d
SM
51632018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
5164
5165 * defs.h (enum openp_flags): New enum.
5166 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
5167 Move to enum openp_flags.
5168 (openp_flags): New enum flags.
5169 (openp): Change parameter type to openp_flags.
5170 * source.c (openp): Change parameter type to openp_flags.
5171 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
5172 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
5173
387cd15b
SM
51742018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
5175
5176 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
5177 per-command.
5178
b303c6f6
AB
51792018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
5180
5181 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
5182 into...
5183 (class dwarf2_queue_guard): ...the destructor of this new class.
5184 (dw2_do_instantiate_symtab): Create instance of the new class
5185 dwarf2_queue_guard, remove cleanup.
5186
9c3630e9
TT
51872018-02-09 Tom Tromey <tom@tromey.com>
5188
5189 * source.c (find_source_lines): Don't reference past the end of
5190 the vector.
5191
c4e12631
MM
51922018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5193
5194 * remote.c (remote_btrace_maybe_reopen): Change error message.
5195 * btrace.c (btrace_enable): Likewise.
5196 (parse_xml_btrace): Likewise.
5197 (parse_xml_btrace_conf): Likewise.
5198
88711fbf
MM
51992018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5200
5201 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
5202 (linux_enable_pt, linux_enable_bts): Call
5203 diagnose_perf_event_open_fail.
5204
17ad2a4f
MM
52052018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5206
5207 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
5208 Remove parameter and change return type. Update callers. Move it.
5209 (linux_enable_bts, linux_enable_pt): Improve error message.
5210 (linux_enable_pt): Remove zero buffer size check.
5211 (linux_enable_btrace): Improve error messages. Remove NULL return
5212 check.
5213
de6242d3
MM
52142018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5215
5216 * btrace.c (btrace_enable): Remove target_supports_btrace call.
5217 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
5218 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
5219 (linux_supports_pt, linux_supports_btrace): Remove.
5220 (linux_enable_bts): Call cpu_supports_bts.
5221 * nat/linux-btrace.h (linux_supports_btrace): Remove.
5222 * remote.c (remote_supports_btrace): Remove.
5223 (init_remote_ops): Remove remote_supports_btrace.
5224 * target-delegates.c: Regenerated.
5225 * target.c (target_supports_btrace): Remove.
5226 * target.h (target_ops) <to_supports_btrace>: Remove
5227 (target_supports_btrace): Remove.
5228 * x86-linux-nat.c (x86_linux_create_target): Remove
5229 linux_supports_btrace.
5230
9ee23a85
MM
52312018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5232
5233 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
5234 btrace failed.
5235 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
5236 exception and use message in own exception.
5237
5c3284c1
MM
52382018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5239
5240 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
5241 (perf_event_pt_event_type): Use gdb_file_up.
5242 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
5243 scoped_fd, and scoped_mmap.
5244
84696f37
MM
52452018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5246
5247 * common/scoped_mmap.h: New.
5248 * unittests/scoped_mmap-selftest.c: New.
5249 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5250 unittests/scoped_mmap-selftest.c.
5251
ea4a0888
MM
52522018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5253
5254 * common/scoped_fd.h: New.
5255 * unittests/scoped_fd-selftest.c: New.
5256 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5257 unittests/scoped_fd-selftest.c.
5258
869e8290
TT
52592018-02-09 Tom Tromey <tom@tromey.com>
5260
5261 * auto-load.c (auto_load_section_scripts): Use
5262 gdb::unique_xmalloc_ptr.
5263
a37a2ae7
TT
52642018-02-09 Tom Tromey <tom@tromey.com>
5265
5266 * auto-load.c (execute_script_contents): Use std::string.
5267
4e725347
JB
52682018-02-09 Joel Brobecker <brobecker@adacore.com>
5269
5270 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
5271 Python function, rather than a new command.
5272
9a897d43
TT
52732018-02-08 Tom Tromey <tom@tromey.com>
5274
5275 * solib.c (solib_find_1): Use std::string.
5276 (solib_bfd_fopen): Use unique_xmalloc_ptr.
5277
58ef3771
TT
52782018-02-08 Tom Tromey <tom@tromey.com>
5279
5280 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
5281
a9abc434
TT
52822018-02-08 Tom Tromey <tom@tromey.com>
5283
5284 * source.c (find_source_lines): Use gdb::def_vector.
5285
84f27c6f
TT
52862018-02-08 Tom Tromey <tom@tromey.com>
5287
5288 * macrocmd.c (struct temporary_macro_definition): New.
5289 (macro_define_command): Use temporary_macro_definition. Remove
5290 cleanups.
5291 (free_macro_definition_ptr): Remove.
5292
0354904b
TT
52932018-02-08 Tom Tromey <tom@tromey.com>
5294
5295 * macroexp.c (maybe_expand): Use std::string.
5296
1739cf24
TT
52972018-02-08 Tom Tromey <tom@tromey.com>
5298
5299 * macroexp.c (struct macro_buffer): Add initializers for some
5300 members.
5301 (init_buffer, init_shared_buffer, free_buffer)
5302 (free_buffer_return_text): Remove.
5303 (macro_buffer): New constructors.
5304 (~macro_buffer): New destructor.
5305 (macro_buffer::set_shared): New method.
5306 (macro_buffer::resize_buffer, macro_buffer::appendc)
5307 (macro_buffer::appendmem): Now methods, not free functions.
5308 (set_token, append_tokens_without_splicing, stringify)
5309 (macro_stringify): Update.
5310 (gather_arguments): Change return type. Remove argc_p argument,
5311 add args_ptr argument. Use std::vector.
5312 (substitute_args): Remove argc argument. Accept std::vector.
5313 (expand): Update. Use std::vector.
5314 (scan, macro_expand, macro_expand_next): Update.
5315
f6c2623e
TT
53162018-02-08 Tom Tromey <tom@tromey.com>
5317
5318 * symtab.c (default_collect_symbol_completion_matches_break_on):
5319 Use unique_xmalloc_ptr.
5320 * macroscope.h: (sal_macro_scope, user_macro_scope)
5321 (default_macro_scope): Return unique_xmalloc_ptr.
5322 * macroscope.c (sal_macro_scope, user_macro_scope)
5323 (default_macro_scope): Return unique_xmalloc_ptr.
5324 * macroexp.h (macro_expand, macro_expand_once): Return
5325 unique_xmalloc_ptr.
5326 * macroexp.c (macro_expand, macro_expand_once): Return
5327 unique_xmalloc_ptr.
5328 * macrocmd.c (macro_expand_command, macro_expand_once_command)
5329 (info_macro_command, info_macros_command): Use
5330 unique_xmalloc_ptr.
5331 * compile/compile-c-support.c (write_macro_definitions): Use
5332 unique_xmalloc_ptr.
5333 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
5334
c2e0e465
SM
53352018-02-07 Simon Marchi <simon.marchi@ericsson.com>
5336
5337 * value.c (value_static_field): Assign field type instead of
5338 containing type when returning an optimized out value.
5339
3f8c94b4
YQ
53402018-02-06 Yao Qi <yao.qi@linaro.org>
5341
5342 * ft32-tdep.c (ft32_read_pc): Remove.
5343 (ft32_write_pc): Remove.
5344 (ft32_gdbarch_init): Update.
5345 * m32r-tdep.c (m32r_read_pc): Remove.
5346 (m32r_gdbarch_init): Update.
5347 * mep-tdep.c (mep_read_pc): Remove.
5348 (mep_gdbarch_init): Update.
5349 * microblaze-tdep.c (microblaze_write_pc): Remove.
5350 (microblaze_gdbarch_init): Update.
5351 * mn10300-tdep.c (mn10300_read_pc): Remove.
5352 (mn10300_write_pc): Remove.
5353 (mn10300_gdbarch_init): Update.
5354 * moxie-tdep.c (moxie_read_pc): Remove.
5355 (moxie_write_pc): Remove.
5356 (moxie_gdbarch_init): Update.
5357
bca65a23
YQ
53582018-02-06 Yao Qi <yao.qi@linaro.org>
5359
5360 * expprint.c (print_subexp_standard): Handle
5361 OP_F77_UNDETERMINED_ARGLIST.
5362 (dump_subexp_body_standard): Likewise.
5363
583e3f90 53642018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 5365
583e3f90
YQ
5366 * target-descriptions.c (tdesc_element_visitor) Add empty
5367 implementations.
b8df6ca7
AH
5368 (tdesc_type): Move make_gdb_type from here.
5369 (tdesc_type_builtin): Likewise.
5370 (tdesc_type_vector): Likewise.
5371 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
5372 (make_gdb_type_struct): Move from tdesc_type_with_fields.
5373 (make_gdb_type_union): Likewise.
5374 (make_gdb_type_flags): Likewise.
5375 (make_gdb_type_enum): Likewise.
5376 (make_gdb_type): New function.
5377 (tdesc_register_type): Use static make_gdb_type.
5378
e813d34a
RK
53792018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
5380
5381 * infcmd.c (default_print_one_register_info): Align natural-format
5382 column values consistently one under another.
5383 (pad_to_column): New function.
5384
0eb876f5
JB
53852018-02-05 Joel Brobecker <brobecker@adacore.com>
5386
5387 * dwarf2read.c (dwarf2_physname): Move commment.
5388
0625771b
LS
53892018-02-01 Leszek Swirski <leszeks@google.com>
5390
5391 * varobj.c (varobj_formatted_print_options): Allow recursive
5392 pretty printing if pretty printing is enabled.
5393
59498c30
LS
53942018-02-01 Leszek Swirski <leszeks@google.com>
5395
5396 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
5397 names after a structop as a filename.
5398
2d9e6acb
YQ
53992018-02-01 Yao Qi <yao.qi@linaro.org>
5400
5401 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
5402 (arm_record_coproc_data_proc): Likewise.
5403
df95a9cf
YQ
54042018-02-01 Yao Qi <yao.qi@linaro.org>
5405
5406 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
5407
07e5f5cf
NP
54082018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
5409
5410 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
5411 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
5412
3045b475
PA
54132018-01-31 Pedro Alves <palves@redhat.com>
5414
5415 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
5416 * inflow.c (child_terminal_save_inferior): Wrap reference to
5417 tcgetpgrp in HAVE_TERMIOS_H.
5418 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
5419 _WIN32.
5420 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
5421 always iterate over all inferiors.
5422 (gdbsim_cntrl_c): Adjust.
5423 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
5424
929b5ad4
JB
54252018-01-31 Joel Brobecker <brobecker@adacore.com>
5426
5427 * gdbtypes.c (lookup_array_range_type): Make sure the array's
5428 index type is objfile-owned if the element type is as well.
5429
29236ca2
JB
54302018-01-31 Joel Brobecker <brobecker@adacore.com>
5431
5432 GDB 8.1 released.
5433
c81e8879
PR
54342018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
5435
5436 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
5437 "features/s390x-linux64.c".
5438 (_initialize_s390_linux_tdep): Remove initialization of tdescs
5439 s390_linux32 and s390x_linux64.
5440 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
5441 default tdesc.
5442 * s390-tdep.c: Include "features/s390-linux32.c" and
5443 "features/s390x-linux64.c".
5444 (s390_tdesc_valid): Add check for tdesc_has_registers.
5445 (s390_gdbarch_init): Make sure there is always a valid tdesc.
5446 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
5447 tdesc_s390x_linux64.
5448 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
5449 tdesc_s390x_linux64 to...
5450 * s390-tdep.h: ...here.
5451
e671cd59
PA
54522018-01-30 Pedro Alves <palves@redhat.com>
5453
5454 PR gdb/13211
5455 * config.in, configure: Regenerate.
5456 * configure.ac: Check for getpgid.
5457 * go32-nat.c (go32_pass_ctrlc): New.
5458 (go32_target): Install it.
5459 * inf-child.c (inf_child_target): Install
5460 child_terminal_save_inferior, child_pass_ctrlc and
5461 child_interrupt.
5462 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
5463 (inf_ptrace_target): No longer install it.
5464 * infcmd.c (interrupt_target_1): Adjust.
5465 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
5466 (child_interrupt): Declare.
5467 (inferior::terminal_state): New.
5468 * inflow.c (struct terminal_info): Update comments.
5469 (inferior_process_group): Delete.
5470 (terminal_is_ours): Delete.
5471 (gdb_tty_state): New.
5472 (child_terminal_init): Adjust.
5473 (is_gdb_terminal, sharing_input_terminal_1)
5474 (sharing_input_terminal): New functions.
5475 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
5476 Set the process's actual process group in the foreground if
5477 possible. Handle is_ours_for_output/is_ours distinction. Don't
5478 mark terminal as the inferior's if not sharing GDB's terminal.
5479 Don't check attach_flag.
5480 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
5481 pass down a target_terminal_state.
5482 (child_terminal_save_inferior): New, factored out from ...
5483 (child_terminal_ours_1): ... this. Handle
5484 target_terminal_state::is_ours_for_output.
5485 (child_interrupt, child_pass_ctrlc): New.
5486 (inflow_inferior_exit): Clear the inferior's terminal_state.
5487 (copy_terminal_info): Copy the inferior's terminal state.
5488 (_initialize_inflow): Remove reference to terminal_is_ours.
5489 * inflow.h (inferior_process_group): Delete.
5490 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
5491 * procfs.c (procfs_target): Don't install procfs_interrupt.
5492 (procfs_interrupt): Delete.
5493 * remote.c (remote_serial_quit_handler): Adjust.
5494 (remote_interrupt): Remove ptid parameter. Adjust.
5495 * target-delegates.c: Regenerate.
5496 * target.c: Include "terminal.h".
5497 (target_terminal::terminal_state): Rename to ...
5498 (target_terminal::m_terminal_state): ... this.
5499 (target_terminal::init): Adjust.
5500 (target_terminal::inferior): Adjust to per-inferior
5501 terminal_state.
5502 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
5503 (target_terminal::ours, target_terminal::ours_for_output): Use
5504 target_terminal_is_ours_kind.
5505 (target_interrupt): Remove ptid parameter. Adjust.
5506 (default_target_pass_ctrlc): Adjust.
5507 * target.h (target_ops::to_terminal_save_inferior): New field.
5508 (target_ops::to_interrupt): Remove ptid_t parameter.
5509 (target_interrupt): Remove ptid_t parameter. Update comment.
5510 (target_pass_ctrlc): Update comment.
5511 * target/target.h (target_terminal_state): New scoped enum,
5512 factored out of ...
5513 (target_terminal::terminal_state): ... here.
5514 (target_terminal::inferior): Update comments.
5515 (target_terminal::restore_inferior): New.
5516 (target_terminal::is_inferior, target_terminal::is_ours)
5517 (target_terminal::is_ours_for_output): Adjust.
5518 (target_terminal::scoped_restore_terminal_state): Adjust to
5519 rename, and call restore_inferior() instead of inferior().
5520 (target_terminal::scoped_restore_terminal_state::m_state): Change
5521 type.
5522 (target_terminal::terminal_state): Rename to ...
5523 (target_terminal::m_terminal_state): ... this and change type.
5524
9c3a5d93
PA
55252018-01-30 Pedro Alves <palves@redhat.com>
5526
5527 * linux-nat.c (wait_for_signal): New function.
5528 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
5529 directly.
5530 (async_terminal_is_ours)
5531 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
5532 (linux_nat_add_target): Don't override
5533 to_terminal_inferior/to_terminal_ours.
5534
69ab5edb
SDJ
55352018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
5536
5537 * remote.c (remote_follow_fork): Don't call "detach_inferior".
5538
fc8e7e75
SM
55392018-01-28 Simon Marchi <simon.marchi@ericsson.com>
5540
5541 * dwarf2read.c (free_dwo_files): Add forward-declaration.
5542 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
5543 dwarf2_per_objfile_free here.
5544 (dwarf2_per_objfile_free): Remove.
5545 (_initialize_dwarf2_read): Don't register
5546 dwarf2_per_objfile_free as a registry cleanup.
5547
b2a426e2
EZ
55482018-01-27 Eli Zaretskii <eliz@gnu.org>
5549
5550 Avoid compilation errors in MinGW native builds
5551
5552 The error is triggered by including python-internal.h, and the
5553 error message is:
5554
5555 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
5556 from build-gnulib/import/math.h:27,
5557 from d:/usr/Python26/include/pyport.h:235,
5558 from d:/usr/Python26/include/Python.h:58,
5559 from python/python-internal.h:94,
5560 from python/py-arch.c:24:
5561 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
5562 using ::hypot;
5563 ^~~~~
5564
5565 This happens because Python headers define 'hypot' to expand t
5566 '_hypot' in the Windows builds.
5567 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
5568 'hypoth'. This avoids a compilation error.
5569
0bdd8eac
AH
55702018-01-26 Alan Hayward <alan.hayward@arm.com>
5571
5572 * MAINTAINERS (Write After Approval): Fix ordering.
5573
56ae9dc3
AH
55742018-01-26 Alan Hayward <alan.hayward@arm.com>
5575
5576 * MAINTAINERS (Write After Approval): Add Alan Hayward.
5577
7433498b
AM
55782018-01-26 Alan Modra <amodra@gmail.com>
5579
5580 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
5581 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
5582 Remove nop. Make const. Comment.
5583 (powerpc32_plt_stub_so_2): New.
5584 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
5585 Correct count. Update uses.
5586 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
5587 Move common code reading PLT entry word. Correct
5588 powerpc32_plt_stub PLT address calculation.
5589 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
5590 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
5591 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
5592 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
5593 (ppc64_standard_linkage8): Likewise.
5594 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
5595 Correct insns description.
5596 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
5597
0f59d5fc
PA
55982018-01-24 Pedro Alves <palves@redhat.com>
5599
5600 GCC PR libstdc++/83906
5601 * gdbtypes.c (operator==(const dynamic_prop &,
5602 const dynamic_prop &)): New.
5603 (operator==(const range_bounds &, const range_bounds &)): New.
5604 (check_types_equal): Use them instead of memcmp.
5605 * gdbtypes.h (operator==(const dynamic_prop &,
5606 const dynamic_prop &)): Declare.
5607 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
5608 (operator==(const range_bounds &, const range_bounds &)): Declare.
5609 (operator!=(const range_bounds &, const range_bounds &)): Declare.
5610
ef8914a4
PR
56112018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5612
5613 * s390-linux-tdep.c (s390_record_address_mask)
5614 (s390_record_calc_disp_common, s390_record_calc_disp)
5615 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
5616 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
5617 (s390_process_record): Move to s390-tdep.c.
5618 (s390_linux_init_abi_any): Adjust.
5619 * s390-tdep.c (s390_record_address_mask)
5620 (s390_record_calc_disp_common, s390_record_calc_disp)
5621 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
5622 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
5623 (s390_process_record): Moved from s390-linux-tdep.c
5624 (s390_gdbarch_init): Adjust.
5625
d6e58945
PR
56262018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5627
5628 * s390-linux-nat.c (s390-tdep.h): New include.
5629 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
5630 (HFILES_NO_SRCDIR): Add s390-tdep.h.
5631 (ALLDEPFILES): Add s390-tdep.c.
5632 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
5633 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
5634 * s390-tdep.h: ...this. New file.
5635 * s390-linux-tdep.c (s390-tdep.h): New include.
5636 (_initialize_s390_tdep): Rename to...
5637 (_initialize_s390_linux_tdep): ...this and adjust.
5638 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
5639 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
5640 s390-tdep.h.
5641 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
5642 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
5643 (s390_is_partial_instruction, s390_software_single_step)
5644 (is_non_branch_ril, s390_displaced_step_copy_insn)
5645 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
5646 (s390_prologue_data, s390_addr, s390_store, s390_load)
5647 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
5648 (s390_register_call_saved, s390_guess_tracepoint_registers)
5649 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
5650 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
5651 (s390_pseudo_register_name, s390_pseudo_register_type)
5652 (s390_pseudo_register_read, s390_pseudo_register_write)
5653 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
5654 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
5655 (s390_addr_bits_remove, s390_address_class_type_flags)
5656 (s390_address_class_type_flags_to_name)
5657 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
5658 (s390_function_arg_float, s390_function_arg_vector)
5659 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
5660 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
5661 (s390_frame_align, s390_register_return_value, s390_return_value)
5662 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
5663 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
5664 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
5665 (s390_trad_frame_prev_register, s390_unwind_cache)
5666 (s390_prologue_frame_unwind_cache)
5667 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
5668 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
5669 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
5670 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
5671 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
5672 (s390_frame_base_address, s390_local_base_address)
5673 (s390_frame_base, s390_gcc_target_options)
5674 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
5675 (s390_validate_reg_range, s390_tdesc_valid)
5676 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
5677 * s390-tdep.c: ...this. New file.
5678
9c0b896e
PR
56792018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5680
5681 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
5682 (s390_process_record, s390_gdbarch_tdep_alloc)
5683 (s390_linux_init_abi_any): Use/set new hook.
5684
7042632b
PR
56852018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5686
5687 * s390-linux-tdep.c (osabi.h): New include.
5688 (s390_linux_init_abi_31, s390_linux_init_abi_64)
5689 (s390_linux_init_abi_any): New functions.
5690 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
5691
650f5e13
PR
56922018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5693
5694 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
5695 tdesc_has_registers check
5696
47c9317e
PR
56972018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5698
5699 * s390-linux-tdep.c (s390_tdesc_valid): New function.
5700 (s390_validate_reg_range): New macro.
5701 (s390_gdbarch_init): Adjust.
5702
095085d8
PR
57032018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5704
5705 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
5706 (s390_gdbarch_tdep_alloc): Adjust.
5707 (s390_gdbarch_init): Adjust.
5708
ab9bcc67
PR
57092018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5710
5711 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
5712 <have_tdb>: Change type to bool.
5713 (s390_gdbarch_tdep_alloc): Adjust.
5714 (s390_gdbarch_init): Adjust.
5715
21f6f5ff
PR
57162018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5717
5718 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
5719 (gdbarch_tdep) <have_upper, have_vx>: New fields.
5720 (s390_gdbarch_tdep_alloc): New function.
5721 (s390_gdbarch_init): Allocate tdep at start and use its fields
5722 instead of separate variables.
5723
0eb97953
PR
57242018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5725
5726 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
5727 when looking for cached gdbarch and add comment for remaining.
5728
5c319bb2
PA
57292018-01-22 Pedro Alves <palves@redhat.com>
5730 Sergio Durigan Junior <sergiodj@redhat.com>
5731
5732 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
5733 case.
5734
d65ce302
MR
57352018-01-22 Maciej W. Rozycki <macro@mips.com>
5736
5737 * MAINTAINERS: Update my company e-mail address.
5738
ec7a5fcb
YQ
57392018-01-22 Yao Qi <yao.qi@linaro.org>
5740
5741 * regcache.c (cooked_write_test): New function.
5742 (_initialize_regcache): Register the test.
5743
11f57cb6
YQ
57442018-01-22 Yao Qi <yao.qi@linaro.org>
5745
5746 * ia64-tdep.c (ia64_pseudo_register_read): Call
5747 regcache->cooked_read instead of regcache_cooked_read_unsigned.
5748 * m32c-tdep.c (m32c_cat_read): Likewise.
5749 (m32c_r3r2r1r0_read): Likewise.
5750 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
5751 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
5752
03f50fc8
YQ
57532018-01-22 Yao Qi <yao.qi@linaro.org>
5754
5755 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
5756 method raw_read instead of regcache_raw_read.
5757 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
5758 * arm-tdep.c (arm_neon_quad_read): Likewise.
5759 * avr-tdep.c (avr_pseudo_register_read): Likewise.
5760 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
5761 * frv-tdep.c (frv_pseudo_register_read): Likewise.
5762 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
5763 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
5764 (i386_pseudo_register_read_into_value): Likewise.
5765 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
5766 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
5767 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
5768 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
5769 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
5770 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
5771 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
5772 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
5773 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
5774
dc711524
YQ
57752018-01-22 Yao Qi <yao.qi@linaro.org>
5776
5777 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
5778 * configure.tgt: Remove target mt.
5779 * mt-tdep.c: Remove.
5780 * regcache.c (cooked_read_test): Remove the check for mt.
5781
3f5a868b
YQ
57822018-01-22 Yao Qi <yao.qi@linaro.org>
5783
5784 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
5785 instead of gdbarch_pseudo_register_read_value.
5786
de4cb04a
JB
57872018-01-22 Joel Brobecker <brobecker@adacore.com>
5788
5789 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
5790 language is Ada.
5791
a9e40818
JB
57922018-01-22 Joel Brobecker <brobecker@adacore.com>
5793
5794 * linespec.c (create_sals_line_offset): Remove code that preserved
5795 the symtab_and_line's line number.
5796
e707fc44
AB
57972018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
5798
5799 * varobj.c (varobj_create): Don't set valid_block when creating a
5800 floating varobj.
5801
03d0bf7b
AB
58022018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
5803
5804 * varobj.c (varobj_create): Remove out of date comment.
5805
ae451627
AB
58062018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
5807
5808 PR mi/20395
5809 * ada-exp.y (write_var_from_sym): Pass extra parameter when
5810 updating innermost block.
5811 * parse.c (innermost_block_tracker::update): Take extra type
5812 parameter, and check types match before updating innermost block.
5813 (write_dollar_variable): Update innermost block for registers.
5814 * parser-defs.h (enum innermost_block_tracker_type): New enum.
5815 (innermost_block_tracker::innermost_block_tracker): Initialise
5816 m_types member.
5817 (innermost_block_tracker::reset): Take type parameter.
5818 (innermost_block_tracker::update): Take type parameter, and pass
5819 type through as needed.
5820 (innermost_block_tracker::m_types): New member.
5821 * varobj.c (varobj_create): Pass type when reseting innermost
5822 block.
5823
aee1fcdf
AB
58242018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
5825
5826 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
5827 * ada-lang.c (resolve_subexp): Likewise.
5828 * breakpoint.c (set_breakpoint_condition) Likewise.
5829 (watch_command_1) Likewise.
5830 * c-exp.y (variable): Likewise.
5831 * d-exp.y (PrimaryExpression): Likewise.
5832 * f-exp.y (variable): Likewise.
5833 * go-exp.y (variable): Likewise.
5834 * m2-exp.y (variable): Likewise.
5835 * objfiles.c (objfile::~objfile): Likewise.
5836 * p-exp.y (variable): Likewise.
5837 * parse.c (innermost_block): Change type.
5838 * parser-defs.h (class innermost_block_tracker): New.
5839 (innermost_block): Change to innermost_block_tracker.
5840 * printcmd.c (display_command): Switch to innermost_block API.
5841 (do_one_display): Likewise.
5842 * rust-exp.y (do_one_display): Likewise.
5843 * symfile.c (clear_symtab_users): Likewise.
5844 * varobj.c (varobj_create): Switch to innermost_block API, replace
5845 use of innermost_block with block stored on varobj object.
5846
396af9a1
AB
58472018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
5848
5849 * expression.h (innermost_block): Remove declaration.
5850 * varobj.c: Add 'parser-defs.h' include.
5851
fcfcc376
TT
58522018-01-19 Tom Tromey <tom@tromey.com>
5853
5854 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
5855 symbols in the static and global blocks.
5856
5a6c3296
JC
58572018-01-19 James Clarke <jrtc27@jrtc27.com>
5858
5859 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
5860 gdb_ptrace.h, and move including gdb_wait.h ...
5861 * nat/linux-ptrace.h: ... to here.
5862
bc09b0c1
SM
58632018-01-19 Simon Marchi <simon.marchi@ericsson.com>
5864
5865 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
5866 inf_ptrace_detach_success.
5867 (inf_ptrace_detach_success): Add inferior parameter, use it
5868 instead of inferior_ptid, pass it to detach_inferior.
5869 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
5870 parameter.
5871 * inferior.c (detach_inferior): Add overload that takes an
5872 inferior object.
5873 * inferior.h (detach_inferior): Likewise.
5874 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
5875 use inferior_ptid, adjust call to inf_ptrace_detach_success.
5876 * linux-thread-db.c (thread_db_detach): Use inf parameter.
5877
6e1e1966
SM
58782018-01-19 Simon Marchi <simon.marchi@ericsson.com>
5879
5880 * target.h (struct target_ops) <to_detach>: Add inferior
5881 parameter.
5882 (target_detach): Likewise.
5883 * target.c (dispose_inferior): Pass inferior down.
5884 (target_detach): Pass inferior down. Assert that it is equal to
5885 the current inferior.
5886 * aix-thread.c (aix_thread_detach): Pass inferior down.
5887 * corefile.c (core_file_command): Pass current_inferior() down.
5888 * corelow.c (core_detach): Add inferior parameter.
5889 * darwin-nat.c (darwin_detach): Likewise.
5890 * gnu-nat.c (gnu_detach): Likewise.
5891 * inf-ptrace.c (inf_ptrace_detach): Likewise.
5892 * infcmd.c (detach_command): Pass current_inferior() down to
5893 target_detach.
5894 * infrun.c (follow_fork_inferior): Pass parent_inf to
5895 target_detach.
5896 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
5897 target_detach.
5898 * linux-nat.c (linux_nat_detach): Add inferior parameter.
5899 * linux-thread-db.c (thread_db_detach): Likewise.
5900 * nto-procfs.c (procfs_detach): Likewise.
5901 * procfs.c (procfs_detach): Likewise.
5902 * record.c (record_detach): Likewise.
5903 * record.h (struct inferior): Forward-declare.
5904 (record_detach): Add inferior parameter.
5905 * remote-sim.c (gdbsim_detach): Likewise.
5906 * remote.c (remote_detach_1): Likewise.
5907 (remote_detach): Likewise.
5908 (extended_remote_detach): Likewise.
5909 * sol-thread.c (sol_thread_detach): Likewise.
5910 * target-debug.h (target_debug_print_inferior_p): New macro.
5911 * target-delegates.c: Re-generate.
5912 * top.c (kill_or_detach): Pass inferior down to target_detach.
5913 * windows-nat.c (windows_detach): Add inferior parameter.
5914
6bd6f3b6
SM
59152018-01-19 Simon Marchi <simon.marchi@ericsson.com>
5916
5917 * target.h (struct target_ops) <to_detach>: Remove args
5918 parameter.
5919 (target_detach): Likewise.
5920 * target.c (dispose_inferior): Adjust.
5921 (target_detach): Remove args parameter, adjust.
5922 * aix-thread.c (aix_thread_detach): Adjust.
5923 * corefile.c (core_file_command): Adjust.
5924 * corelow.c (core_detach): Adjust.
5925 * darwin-nat.c (darwin_detach): Adjust.
5926 * gnu-nat.c (gnu_detach): Adjust.
5927 * inf-ptrace.c (inf_ptrace_detach): Adjust.
5928 * infcmd.c (detach_command): Adjust
5929 * infrun.c (follow_fork_inferior): Adjust.
5930 (handle_vfork_child_exec_or_exit): Adjust.
5931 * linux-fork.c (linux_fork_detach): Remove args parameter.
5932 * linux-fork.h (linux_fork_detach): Likewise.
5933 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
5934 * linux-thread-db.c (thread_db_detach): Likewise.
5935 * nto-procfs.c (procfs_detach): Likewise.
5936 * procfs.c (procfs_detach): Likewise.
5937 (do_detach): Remove signo parameter.
5938 * record.c (record_detach): Remove args parameter.
5939 * record.h (record_detach): Likewise.
5940 * remote-sim.c (gdbsim_detach): Likewise.
5941 * remote.c (remote_detach_1): Likewise.
5942 (remote_detach): Likewise.
5943 (extended_remote_detach): Likewise.
5944 * sol-thread.c (sol_thread_detach): Likewise.
5945 * target-delegates.c: Re-generate.
5946 * top.c (struct qt_args) <args>: Remove field.
5947 (kill_or_detach): Don't pass args.
5948 (quit_force): Don't set args.
5949 * windows-nat.c (windows_detach): Remove args parameter.
5950
88af8ea8
YQ
59512018-01-19 Yao Qi <yao.qi@linaro.org>
5952
5953 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
5954 (arm_linux_init_abi): Install it.
5955
dea445b9
YQ
59562018-01-19 Yao Qi <yao.qi@linaro.org>
5957
5958 * osabi.c (gdb_osabi_names): Extend the regexp for
5959 arm-linux-gnueabihf.
5960
4a17f768
YQ
59612018-01-18 Yao Qi <yao.qi@linaro.org>
5962
5963 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
5964 m_abbrevs.
5965 (abbrev_table::add_abbrev): Update.
5966 (abbrev_table::lookup_abbrev): Update.
5967
d679c21a
YQ
59682018-01-18 Yao Qi <yao.qi@linaro.org>
5969
5970 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
5971
7d937cad
SDJ
59722018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
5973
5974 * compile/compile.c (compile_to_object): Convert "triplet_rx"
5975 to "std::string".
5976
9e14690d
TT
59772018-01-17 Tom Tromey <tom@tromey.com>
5978
5979 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
5980
50a82047
TT
59812018-01-17 Tom Tromey <tom@tromey.com>
5982
5983 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
5984 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
5985 (create_array_type_with_stride): Update.
5986 * dwarf2read.c (set_die_type): Update.
5987
c89b44cd
TT
59882018-01-17 Tom Tromey <tom@tromey.com>
5989
5990 * dwarf2read.c (delayed_method_info): Remove typedef.
5991 (dwarf2_cu::method_info): Now a std::vector.
5992 (add_to_method_list): Update.
5993 (free_delayed_list): Remove.
5994 (compute_delayed_physnames): Update.
5995 (process_full_comp_unit, process_full_type_unit): Clear the method
5996 list. Remove cleanups.
5997 (psymtab_include_file_name): Add name_holder parameter. Use
5998 unique_xmalloc_ptr.
5999 (dwarf_decode_lines): Update.
6000
fcd3b13d
SM
60012018-01-17 Tom Tromey <tom@tromey.com>
6002 Simon Marchi <simon.marchi@ericsson.com>
6003
6004 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
6005 (dwarf2_per_objfile::free_cached_comp_units)
6006 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
6007 (init_cutu_and_read_dies_no_follow): Update.
6008 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
6009 (dwarf2_cu::~dwarf2_cu): New.
6010 (free_heap_comp_unit, free_stack_comp_unit): Remove.
6011 (age_cached_comp_units, free_one_cached_comp_unit): Update.
6012
685af9cd
TT
60132018-01-17 Tom Tromey <tom@tromey.com>
6014 Simon Marchi <simon.marchi@ericsson.com>
6015
6016 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
6017 (struct die_reader_specs) <abbrev_table>: New member.
6018 (struct abbrev_table): Add constructor.
6019 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
6020 <abbrev_obstack>: Now an auto_obstack.
6021 (abbrev_table_up): New typedef.
6022 (init_cu_die_reader): Add abbrev_table parameter.
6023 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
6024 Add result_dwo_abbrev_table.
6025 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
6026 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
6027 Update.
6028 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
6029 parameter.
6030 (skip_children): Update.
6031 (abbrev_table::alloc_abbrev): Rename from
6032 abbrev_table_alloc_abbrev.
6033 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
6034 (abbrev_table::lookup_abbrev): Rename from
6035 abbrev_table_lookup_abbrev.
6036 (abbrev_table_read_table): Return abbrev_table_up.
6037 (abbrev_table_free, abbrev_table_free_cleanup)
6038 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
6039 (load_partial_dies): Update.
6040
5e2db402
TT
60412018-01-17 Tom Tromey <tom@tromey.com>
6042
6043 * dwarf2read.c (dwarf2_compute_name): Update comment.
6044 (read_func_scope, read_variable): Update.
6045 (new_symbol): Remove.
6046 (new_symbol_full): Rename to new_symbol.
6047
ee7f689e 60482018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
6049
6050 PR gdb/16577
6051 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
6052 a warning instead of throwing an error, set section size to 0 and return
6053 NULL.
6054 * gdb_bfd.h (gdb_bfd_map_section): Update description.
6055
4d9b86e1
SM
60562018-01-17 Simon Marchi <simon.marchi@ericsson.com>
6057
6058 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
6059 std::string.
6060 (linux_ptrace_attach_fail_reason_string): Likewise.
6061 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
6062 Likewise.
6063 (linux_ptrace_attach_fail_reason_string): Likewise.
6064 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
6065
a7b2d0fb
SM
60662018-01-17 Simon Marchi <simon.marchi@ericsson.com>
6067
6068 * linux-nat.c (linux_nat_attach): Remove xstrdup.
6069
f517c180
EA
60702018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
6071
6072 PR gdb/21559
6073 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
6074 checking for fs_base/gs_base fields in struct user_regs_struct.
6075 * configure: Regenerate.
6076
7045b1ca
YQ
60772018-01-17 Yao Qi <yao.qi@linaro.org>
6078
6079 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
6080 function.
6081 (aarch64_linux_init_abi): Install it to gdbarch hook
6082 gcc_target_options.
6083
db422fb2
PA
60842018-01-15 Pedro Alves <palves@redhat.com>
6085
6086 * common/signals-state-save-restore.c
6087 (save_original_signals_state): Fix typos.
6088
ba643918
SDJ
60892017-01-12 Tom Tromey <tom@tromey.com>
6090 Sergio Durigan Junior <sergiodj@redhat.com>
6091
6092 * Makefile.in (install-only): Install gdb-add-index.
6093
906b4aac
JB
60942018-01-12 John Baldwin <jhb@FreeBSD.org>
6095
6096 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
6097
bdf2a94a
AA
60982018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6099
6100 * infrun.c (keep_going_pass_signal): Clear step-over info when
6101 insert_breakpoints fails.
6102
71d378ae
PA
61032018-01-11 Pedro Alves <palves@redhat.com>
6104
6105 PR gdb/22583
6106 * infrun.c (resume): Rename to ...
6107 (resume_1): ... this.
6108 (resume): Reimplement as wrapper around resume_1.
6109
3cada740
PA
61102018-01-11 Pedro Alves <palves@redhat.com>
6111
6112 PR remote/22597
6113 * remote.c (remote_parse_stop_reply): Default to the last-set
6114 general thread instead of to 'magic_null_ptid'.
6115
618daa93
PA
61162018-01-10 Pedro Alves <palves@redhat.com>
6117
6118 * language.h (language_get_symbol_name_matcher): Rename ...
6119 (get_symbol_name_matcher): ... this.
6120 * language.c (language_get_symbol_name_matcher): Ditto.
6121 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
6122 callers adjusted.
6123
c63d3e8d
PA
61242018-01-10 Pedro Alves <palves@redhat.com>
6125
6126 PR gdb/22670
6127 * dwarf2read.c
6128 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
6129 Adjust to use language_get_symbol_name_matcher instead of
6130 language_defn::la_get_symbol_name_matcher.
6131 * language.c (language_get_symbol_name_matcher): If in Ada mode
6132 and the lookup name is a verbatim match, return Ada's matcher.
6133 * language.h (language_get_symbol_name_matcher): Adjust comment.
6134 (ada_lookup_name_info::verbatim_p):: New method.
6135
d4c2a405
PA
61362018-01-10 Pedro Alves <palves@redhat.com>
6137
6138 PR gdb/22670
6139 * ada-lang.c (ada_collect_symbol_completion_matches): If the
6140 minsym's language is language_auto or language_cplus, pass down
6141 language_ada instead.
6142 * symtab.c (compare_symbol_name): Don't frob symbol language here.
6143
8825213e
PA
61442018-01-10 Pedro Alves <palves@redhat.com>
6145
6146 PR gdb/22670
6147 * minsyms.c (linkage_name_str): New function.
6148 (iterate_over_minimal_symbols): Use it.
6149
2d97a5d9
JB
61502018-01-09 John Baldwin <jhb@FreeBSD.org>
6151
6152 * NEWS: Document that 'info proc' now works on FreeBSD.
6153
92fce24d
JB
61542018-01-09 John Baldwin <jhb@FreeBSD.org>
6155
6156 * configure.ac: Check for kinfo_getfile in libutil.
6157 * configure: Regenerate.
6158 * config.in: Regenerate.
6159 * fbsd-nat.c: Include "fbsd-tdep.h".
6160 (fbsd_fetch_cmdline): New.
6161 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
6162 rather than calling error.
6163 (fbsd_info_proc): New.
6164 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
6165 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
6166 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
6167
262f62f5
JB
61682018-01-09 John Baldwin <jhb@FreeBSD.org>
6169
6170 * fbsd-nat.c (struct free_deleter): Remove.
6171 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
6172
b999e203
JB
61732018-01-09 John Baldwin <jhb@FreeBSD.org>
6174
6175 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
6176 NULL for an empty pathname.
6177
d2176225
JB
61782018-01-09 John Baldwin <jhb@FreeBSD.org>
6179
6180 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
6181 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
6182 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
6183 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
6184 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
6185 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
6186 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
6187 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
6188 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
6189 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
6190 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
6191 (fbsd_core_fetch_timeval, fbsd_print_sigset)
6192 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
6193 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
6194 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
6195
9c4ac400
ST
61962018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
6197
6198 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
6199 (gnu_xfer_auxv): New function.
6200 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
6201 TARGET_OBJECT_AUXV.
6202
1e5ded6c
YQ
62032018-01-08 Yao Qi <yao.qi@linaro.org>
6204 Simon Marchi <simon.marchi@ericsson.com>
6205
6206 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
6207 common/selftest.c.
6208 (COMMON_OBS): Remove selftest.o.
6209 * configure.ac: Append selftest-arch.c and common/selftest.c to
6210 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
6211 * configure: Re-generated.
6212 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
6213 GDB_SELF_TEST.
6214 (maintenance_info_selftests): Likewise.
6215
04bafb1e
XR
62162018-01-08 Xavier Roirand <roirand@adacore.com>
6217
6218 * ada-valprint.c (val_print_packed_array_elements): Use
6219 proper number of elements when printing an array indexed
6220 by an enumeration type.
6221
518817b3
SM
62222018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6223
6224 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
6225 (dw2_get_file_names_reader): Adjust.
6226 (lookup_dwo_signatured_type): Adjust.
6227 (lookup_dwp_signatured_type): Adjust.
6228 (lookup_signatured_type): Adjust.
6229 (create_type_unit_group): Adjust.
6230 (get_type_unit_group): Adjust.
6231 (process_psymtab_comp_unit_reader): Adjust.
6232 (build_type_psymtabs_reader): Adjust.
6233 (scan_partial_symbols): Adjust.
6234 (add_partial_symbol): Adjust.
6235 (add_partial_subprogram): Adjust.
6236 (peek_die_abbrev): Adjust.
6237 (fixup_go_packaging): Adjust.
6238 (process_imported_unit_die): Adjust.
6239 (dwarf2_compute_name): Adjust.
6240 (dwarf2_physname): Adjust.
6241 (read_import_statement): Adjust.
6242 (handle_DW_AT_stmt_list): Adjust.
6243 (read_file_scope): Adjust.
6244 (read_func_scope): Adjust.
6245 (read_lexical_block_scope): Adjust.
6246 (read_call_site_scope): Adjust.
6247 (read_variable): Adjust.
6248 (dwarf2_rnglists_process): Adjust.
6249 (dwarf2_ranges_process): Adjust.
6250 (dwarf2_ranges_read): Adjust.
6251 (dwarf2_get_pc_bounds): Adjust.
6252 (dwarf2_record_block_ranges): Adjust.
6253 (dwarf2_add_field): Adjust.
6254 (dwarf2_add_member_fn): Adjust.
6255 (read_structure_type): Adjust.
6256 (process_structure_scope): Adjust.
6257 (read_enumeration_type): Adjust.
6258 (read_array_type): Adjust.
6259 (mark_common_block_symbol_computed): Adjust.
6260 (read_common_block): Adjust.
6261 (read_namespace_type): Adjust.
6262 (read_namespace): Adjust.
6263 (read_module_type): Adjust.
6264 (read_tag_pointer_type): Adjust.
6265 (read_tag_ptr_to_member_type): Adjust.
6266 (read_tag_string_type): Adjust.
6267 (read_subroutine_type): Adjust.
6268 (read_typedef): Adjust.
6269 (read_base_type): Adjust.
6270 (attr_to_dynamic_prop): Adjust.
6271 (read_subrange_type): Adjust.
6272 (read_unspecified_type): Adjust.
6273 (dwarf2_read_abbrevs): Adjust.
6274 (load_partial_dies): Adjust.
6275 (read_partial_die): Adjust.
6276 (find_partial_die): Adjust.
6277 (guess_partial_die_structure_name): Adjust.
6278 (fixup_partial_die): Adjust.
6279 (read_attribute_value): Adjust.
6280 (read_addr_index): Adjust.
6281 (read_addr_index_from_leb128): Adjust.
6282 (read_str_index): Adjust.
6283 (dwarf2_string_attr): Adjust.
6284 (get_debug_line_section): Adjust.
6285 (dwarf_decode_line_header): Adjust.
6286 (lnp_state_machine::check_line_address): Adjust.
6287 (dwarf_decode_lines_1): Adjust.
6288 (dwarf_decode_lines): Adjust.
6289 (dwarf2_start_symtab): Adjust.
6290 (var_decode_location): Adjust.
6291 (new_symbol_full): Adjust.
6292 (dwarf2_const_value_data): Adjust.
6293 (dwarf2_const_value_attr): Adjust.
6294 (dwarf2_const_value): Adjust.
6295 (die_type): Adjust.
6296 (die_containing_type): Adjust.
6297 (build_error_marker_type): Adjust.
6298 (lookup_die_type): Adjust.
6299 (guess_full_die_structure_name): Adjust.
6300 (anonymous_struct_prefix): Adjust.
6301 (determine_prefix): Adjust.
6302 (dwarf2_name): Adjust.
6303 (follow_die_ref_or_sig): Adjust.
6304 (follow_die_offset): Adjust.
6305 (follow_die_ref): Adjust.
6306 (follow_die_sig_1): Adjust.
6307 (follow_die_sig): Adjust.
6308 (get_signatured_type): Adjust.
6309 (get_DW_AT_signature_type): Adjust.
6310 (decode_locdesc): Adjust.
6311 (dwarf_decode_macros): Adjust.
6312 (cu_debug_loc_section): Adjust.
6313 (fill_in_loclist_baton): Adjust.
6314 (dwarf2_symbol_mark_computed): Adjust.
6315 (init_one_comp_unit): Don't assign
6316 dwarf2_cu::dwarf2_per_objfile.
6317 (set_die_type): Adjust.
6318
ed2dc618
SM
63192018-01-07 Simon Marchi <simon.marchi@ericsson.com>
6320
6321 * dwarf2read.c (struct mapped_debug_names): Add constructor.
6322 <dwarf2_per_objfile>: New field.
6323 (dwarf2_per_objfile): Remove global.
6324 (get_dwarf2_per_objfile): New function.
6325 (set_dwarf2_per_objfile): New function.
6326 (dwarf2_build_psymtabs_hard): Change objfile parameter to
6327 dwarf2_per_objfile.
6328 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
6329 (read_abbrev_offset): Likewise.
6330 (read_indirect_string): Likewise.
6331 (read_indirect_line_string): Likewise.
6332 (read_indirect_string_at_offset): Likewise.
6333 (read_indirect_string_from_dwz): Likewise.
6334 (dwarf2_find_containing_comp_unit): Change objfile parameter to
6335 dwarf2_per_objfile.
6336 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
6337 (create_all_comp_units): Change objfile parameter to
6338 dwarf2_per_objfile.
6339 (create_all_type_units): Likewise.
6340 (process_queue): Add dwarf2_per_objfile parameter.
6341 (read_and_check_comp_unit_head): Likewise.
6342 (lookup_dwo_unit_in_dwp): Likewise.
6343 (get_dwp_file): Likewise.
6344 (process_cu_includes): Likewise.
6345 (struct free_dwo_file_cleanup_data): New struct.
6346 (dwarf2_has_info): Use get_dwarf2_per_objfile and
6347 set_dwarf2_per_objfile.
6348 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
6349 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
6350 context, adjust calls.
6351 (dw2_instantiate_symtab): Likewise.
6352 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
6353 (dw2_get_cu): Likewise.
6354 (create_cu_from_index_list): Change objfile parameter to
6355 dwarf2_per_objfile.
6356 (create_cus_from_index_list): Get dwarf2_per_objfile from
6357 context, adjust calls.
6358 (create_cus_from_index): Likewise.
6359 (create_signatured_type_table_from_index): Change objfile
6360 parameter to dwarf2_per_objfile.
6361 (create_signatured_type_table_from_debug_names): Change objfile
6362 parameter to dwarf2_per_objfile.
6363 (create_addrmap_from_index): Likewise.
6364 (create_addrmap_from_aranges): Likewise.
6365 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
6366 (dw2_setup): Remove.
6367 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
6368 context.
6369 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
6370 get_dwarf2_per_objfile.
6371 (dw2_forget_cached_source_info): Likewise.
6372 (dw2_map_symtabs_matching_filename): Likewise.
6373 (struct dw2_symtab_iterator) <index>: Remove.
6374 <dwarf2_per_objfile>: New field.
6375 (dw2_symtab_iter_init): Replace index parameter with
6376 dwarf2_per_objfile.
6377 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
6378 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
6379 (dw2_print_stats): Likewise.
6380 (dw2_dump): Likewise.
6381 (dw2_expand_symtabs_for_function): Likewise.
6382 (dw2_expand_all_symtabs): Likewise.
6383 (dw2_expand_symtabs_with_fullname): Likewise.
6384 (dw2_expand_marked_cus): Replace index and objfile parameters
6385 with dwarf2_per_objfile.
6386 (dw_expand_symtabs_matching_file_matcher): Add
6387 dwarf2_per_objfile parameter and adjust calls.
6388 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
6389 adjust calls.
6390 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
6391 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
6392 adjust calls.
6393 (create_cus_from_debug_names_list): Replace objfile parameter
6394 with dwarf2_per_objfile and adjust calls.
6395 (create_cus_from_debug_names): Likewise.
6396 (dwarf2_read_debug_names): Likewise.
6397 (mapped_debug_names::namei_to_name): Adjust call.
6398 (dw2_debug_names_iterator::next): Likewise.
6399 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
6400 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
6401 (dw2_debug_names_dump): Likewise.
6402 (dw2_debug_names_expand_symtabs_for_function): Likewise.
6403 (dw2_debug_names_expand_symtabs_matching): Likewise.
6404 (dwarf2_initialize_objfile): Likewise.
6405 (dwarf2_build_psymtabs): Likewise.
6406 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
6407 this_cu.
6408 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
6409 (read_and_check_comp_unit_head): Likewise.
6410 (read_abbrev_offset): Likewise.
6411 (create_debug_type_hash_table): Likewise.
6412 (create_debug_types_hash_table): Likewise.
6413 (create_all_type_units): Replace objfile parameter with
6414 dwarf2_per_objfile.
6415 (add_type_unit): Add dwarf2_per_objfile parameter.
6416 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
6417 with dwarf2_per_objfile.
6418 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
6419 (lookup_dwp_signatured_type): Likewise.
6420 (lookup_signatured_type): Likewise.
6421 (read_cutu_die_from_dwo): Likewise.
6422 (init_tu_and_read_dwo_dies): Likewise.
6423 (init_cutu_and_read_dies): Likewise.
6424 (init_cutu_and_read_dies_no_follow): Likewise.
6425 (allocate_type_unit_groups_table): Add objfile parameter.
6426 (create_type_unit_group): Use dwarf2_per_objfile from cu.
6427 (get_type_unit_group): Likewise.
6428 (process_psymtab_comp_unit): Update call.
6429 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
6430 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
6431 (print_tu_stats): Likewise.
6432 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
6433 in void* parameter.
6434 (build_type_psymtabs): Change objfile parameter to
6435 dwarf2_per_objfile.
6436 (process_skeletonless_type_unit): Use dwarf2_per_objfile
6437 passed in void* parameter.
6438 (process_skeletonless_type_units): Change objfile parameter to
6439 dwarf2_per_objfile.
6440 (set_partial_user): Likewise.
6441 (dwarf2_build_psymtabs_hard): Likewise.
6442 (read_comp_units_from_section): Likewise.
6443 (create_all_comp_units): Likewise.
6444 (scan_partial_symbols): Update calls.
6445 (add_partial_symbol): Likewise.
6446 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
6447 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
6448 (process_queue): Add dwarf2_per_objfile parameter.
6449 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
6450 (compute_compunit_symtab_includes): Likewise.
6451 (process_cu_includes): Add dwarf2_per_objfile parameter.
6452 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
6453 (process_full_type_unit): Likewise.
6454 (process_imported_unit_die): Update call.
6455 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
6456 (read_file_scope): Likewise.
6457 (allocate_dwo_file_hash_table): Add objfile parameter.
6458 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
6459 (create_cus_hash_table): Likewise.
6460 (create_dwp_hash_table): Likewise.
6461 (create_dwo_unit_in_dwp_v1): Likewise.
6462 (create_dwp_v2_section): Likewise.
6463 (create_dwo_unit_in_dwp_v2): Likewise.
6464 (lookup_dwo_unit_in_dwp): Likewise.
6465 (try_open_dwop_file): Likewise.
6466 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
6467 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
6468 cleanup to include a reference to dwarf2_per_objfile.
6469 (open_dwp_file): Add dwarf2_per_objfile parameter.
6470 (open_and_init_dwp_file): Likewise.
6471 (get_dwp_file): Likewise.
6472 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
6473 (queue_and_load_all_dwo_tus): Update call.
6474 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
6475 data.
6476 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
6477 (dwarf2_ranges_process): Likewise.
6478 (dwarf2_get_pc_bounds): Likewise.
6479 (mark_common_block_symbol_computed): Likewise.
6480 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
6481 (dwarf2_read_abbrevs): Update call.
6482 (read_partial_die): Use dwarf2_per_objfile from cu.
6483 (find_partial_die): Likewise.
6484 (fixup_partial_die): Likewise.
6485 (read_attribute_value): Likewise.
6486 (read_indirect_string_at_offset_from): Add objfile parameter.
6487 (read_indirect_string_at_offset): Add dwarf2_per_objfile
6488 parameter.
6489 (read_indirect_string_from_dwz): Add objfile parameter.
6490 (read_indirect_string): Add objfile parameter.
6491 (read_addr_index_1): Add dwarf2_per_objfile parameter.
6492 (read_addr_index): Use dwarf2_per_objfile from cu.
6493 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
6494 call dw2_setup.
6495 (read_str_index): Use dwarf2_per_objfile from cu.
6496 (get_debug_line_section): Likewise.
6497 (read_formatted_entries): Add dwarf2_per_objfile parameter.
6498 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
6499 (new_symbol_full): Use dwarf2_per_objfile from cu.
6500 (build_error_marker_type): Likewise.
6501 (lookup_die_type): Likewise.
6502 (determine_prefix): Likewise.
6503 (follow_die_offset): Likewise.
6504 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
6505 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
6506 (dwarf2_fetch_die_type_sect_off): Likewise.
6507 (dwarf2_get_die_type): Likewise.
6508 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
6509 (get_signatured_type): Likewise.
6510 (get_DW_AT_signature_type): Likewise.
6511 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
6512 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
6513 (cu_debug_loc_section): Likewise.
6514 (fill_in_loclist_baton): Likewise.
6515 (dwarf2_symbol_mark_computed): Likewise.
6516 (dwarf2_find_containing_comp_unit): Change objfile parameter to
6517 dwarf2_per_objfile.
6518 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
6519 parameter.
6520 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
6521 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
6522 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
6523 (set_die_type): Use dwarf2_free_objfile from cu.
6524 (get_die_type_at_offset): Likewise.
6525 (dwarf2_per_objfile_free): Don't assign global variable.
6526 (debug_names) <constructor>: Add dwarf2_per_objfile
6527 parameter, update m_debugstrlookup construction.
6528 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
6529 parameter.
6530 <m_dwarf2_per_objfile>: New field.
6531 <lookup>: Use m_dwarf2_per_objfile.
6532 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
6533 (psyms_seen_size): Likewise.
6534 (write_gdbindex): Replace objfile parameter with
6535 dwarf2_per_objfile.
6536 (write_debug_names): Likewise.
6537 (write_psymtabs_to_index): Likewise.
6538 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
6539 calls.
6540
e3b94546
SM
65412018-01-07 Simon Marchi <simon.marchi@ericsson.com>
6542
6543 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
6544 <dwarf2_per_objfile>: New field.
6545 (struct dwarf2_per_cu_data) <objfile>: Remove.
6546 <dwarf2_per_objfile>: New field.
6547 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
6548 of objfile.
6549 (create_signatured_type_table_from_index): Likewise.
6550 (create_debug_type_hash_table): Likewise.
6551 (fill_in_sig_entry_from_dwo_entry): Likewise.
6552 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
6553 (create_type_unit_group): Assign dwarf2_per_objfile instead of
6554 objfile.
6555 (create_partial_symtab): Access objfile through
6556 dwarf2_per_objfile.
6557 (process_psymtab_comp_unit_reader): Likewise.
6558 (read_comp_units_from_section): Likewise.
6559 (scan_partial_symbols): Likewise.
6560 (add_partial_symbol): Likewise.
6561 (add_partial_subprogram): Likewise.
6562 (peek_die_abbrev): Likewise.
6563 (fixup_go_packaging): Likewise.
6564 (process_full_comp_unit): Likewise.
6565 (process_full_type_unit): Likewise.
6566 (process_imported_unit_die): Likewise.
6567 (dwarf2_compute_name): Likewise.
6568 (dwarf2_physname): Likewise.
6569 (read_import_statement): Likewise.
6570 (create_cus_hash_table): Assign dwarf2_physname instead of
6571 objfile.
6572 (read_func_scope): Access objfile through dwarf2_per_objfile.
6573 (read_lexical_block_scope): Likewise.
6574 (read_call_site_scope): Likewise.
6575 (read_variable): Likewise.
6576 (dwarf2_rnglists_process): Likewise.
6577 (dwarf2_ranges_process): Likewise.
6578 (dwarf2_ranges_read): Likewise.
6579 (dwarf2_record_block_ranges): Likewise.
6580 (dwarf2_add_field): Likewise.
6581 (dwarf2_add_member_fn): Likewise.
6582 (read_structure_type): Likewise.
6583 (process_structure_scope): Likewise.
6584 (read_enumeration_type): Likewise.
6585 (read_array_type): Likewise.
6586 (read_common_block): Likewise.
6587 (read_namespace_type): Likewise.
6588 (read_namespace): Likewise.
6589 (read_module_type): Likewise.
6590 (read_tag_pointer_type): Likewise.
6591 (read_tag_ptr_to_member_type): Likewise.
6592 (read_tag_string_type): Likewise.
6593 (read_subroutine_type): Likewise.
6594 (read_typedef): Likewise.
6595 (read_base_type): Likewise.
6596 (attr_to_dynamic_prop): Likewise.
6597 (read_subrange_type): Likewise.
6598 (read_unspecified_type): Likewise.
6599 (load_partial_dies): Likewise.
6600 (read_partial_die): Likewise.
6601 (find_partial_die): Likewise.
6602 (guess_partial_die_structure_name): Likewise.
6603 (fixup_partial_die): Likewise.
6604 (read_attribute_value): Likewise.
6605 (read_addr_index_from_leb128): Likewise.
6606 (dwarf2_read_addr_index): Likewise.
6607 (dwarf2_string_attr): Likewise.
6608 (lnp_state_machine::check_line_address): Likewise.
6609 (dwarf_decode_lines_1): Likewise.
6610 (dwarf_decode_lines): Likewise.
6611 (dwarf2_start_symtab): Likewise.
6612 (var_decode_location): Likewise.
6613 (new_symbol_full): Likewise.
6614 (dwarf2_const_value_data): Likewise.
6615 (dwarf2_const_value_attr): Likewise.
6616 (dwarf2_const_value): Likewise.
6617 (die_type): Likewise.
6618 (die_containing_type): Likewise.
6619 (lookup_die_type): Likewise.
6620 (guess_full_die_structure_name): Likewise.
6621 (anonymous_struct_prefix): Likewise.
6622 (dwarf2_name): Likewise.
6623 (follow_die_ref_or_sig): Likewise.
6624 (follow_die_offset): Likewise.
6625 (follow_die_ref): Likewise.
6626 (dwarf2_fetch_die_loc_sect_off): Likewise.
6627 (dwarf2_fetch_constant_bytes): Likewise.
6628 (dwarf2_fetch_die_type_sect_off): Likewise.
6629 (dwarf2_get_die_type): Likewise.
6630 (follow_die_sig): Likewise.
6631 (decode_locdesc): Likewise.
6632 (dwarf2_per_cu_objfile): Likewise.
6633 (dwarf2_per_cu_text_offset): Likewise.
6634 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
6635 objfile.
6636 (set_die_type): Access objfile through
6637 dwarf2_per_objfile.
6638
b01ba14d
SM
66392018-01-07 Simon Marchi <simon.marchi@ericsson.com>
6640
6641 * valprint.c (converted_character_d): Remove typedef.
6642 (DEF_VEC_O (converted_character_d)): Remove.
6643 (count_next_character): Use std::vector.
6644 (print_converted_chars_to_obstack): Likewise.
6645 (generic_printstr): Likewise.
6646
4d0fdd9b
SM
66472018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6648
6649 * xml-support.h (struct gdb_xml_value): Add constructor.
6650 <value>: Change type to unique_xmalloc_ptr.
6651 (gdb_xml_value_s): Remove typedef.
6652 (DEF_VEC_O (gdb_xml_value_s)): Remove.
6653 (gdb_xml_element_start_handler): Change parameter type to
6654 std::vector.
6655 (xml_find_attribute): Likewise.
6656 * xml-support.c (xml_find_attribute): Change parameter type to
6657 std::vector and adjust.
6658 (gdb_xml_values_cleanup): Remove.
6659 (gdb_xml_parser::start_element): Adjust to std::vector.
6660 (xinclude_start_include): Change paraeter type to std::vector
6661 and adjust.
6662 * btrace.c (check_xml_btrace_version): Likewise.
6663 (parse_xml_btrace_block): Likewise.
6664 (parse_xml_btrace_pt_config_cpu): Likewise.
6665 (parse_xml_btrace_pt): Likewise.
6666 (parse_xml_btrace_conf_bts): Likewise.
6667 (parse_xml_btrace_conf_pt): Likewise.
6668 * memory-map.c (memory_map_start_memory): Likewise.
6669 (memory_map_start_property): Likewise.
6670 * osdata.c (osdata_start_osdata): Likewise.
6671 (osdata_start_item): Likewise.
6672 (osdata_start_column): Likewise.
6673 * remote.c (start_thread): Likewise.
6674 * solib-aix.c (library_list_start_library): Likewise.
6675 (library_list_start_list): Likewise.
6676 * solib-svr4.c (library_list_start_library): Likewise.
6677 (svr4_library_list_start_list): Likewise.
6678 * solib-target.c (library_list_start_segment): Likewise.
6679 (library_list_start_section): Likewise.
6680 (library_list_start_library): Likewise.
6681 (library_list_start_list): Likewise.
6682 * tracepoint.c (traceframe_info_start_memory): Likewise.
6683 (traceframe_info_start_tvar): Likewise.
6684 * xml-syscall.c (syscall_start_syscall): Likewise.
6685 * xml-tdesc.c (tdesc_start_target): Likewise.
6686 (tdesc_start_feature): Likewise.
6687 (tdesc_start_reg): Likewise.
6688 (tdesc_start_union): Likewise.
6689 (tdesc_start_struct): Likewise.
6690 (tdesc_start_flags): Likewise.
6691 (tdesc_start_enum): Likewise.
6692 (tdesc_start_field): Likewise.
6693 (tdesc_start_enum_value): Likewise.
6694 (tdesc_start_vector): Likewise.
6695
f979c73f
SM
66962018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6697
6698 * extension.h (struct xmethod_worker) <clone>: Remove.
6699 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
6700 Remove.
6701 (python_xmethod_worker::clone): Remove.
6702 * valops.c (find_overload_match): Use std::move instead of
6703 clone.
6704
ba18742c
SM
67052018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6706
6707 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
6708 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
6709 <free_xmethod_worker_data>: Remove.
6710 <get_matching_xmethod_workers>: Chance VEC to std::vector.
6711 <get_xmethod_arg_types>: Remove.
6712 <get_xmethod_result_type>: Remove.
6713 <invoke_xmethod>: Remove.
6714 * extension.c (new_xmethod_worker): Remove.
6715 (clone_xmethod_worker): Remove.
6716 (get_matching_xmethod_workers): Return void, pass std::vector by
6717 pointer.
6718 (get_xmethod_arg_types): Rename to...
6719 (xmethod_worker::get_arg_types): ... this, and adjust.
6720 (get_xmethod_result_type): Rename to...
6721 (xmethod_worker::get_result_type): ... this, and adjust.
6722 (invoke_xmethod): Remove.
6723 (free_xmethod_worker): Remove.
6724 (free_xmethod_worker_vec): Remove.
6725 * extension.h (enum ext_lang_rc): Move here from
6726 extension-priv.h.
6727 (struct xmethod_worker): Add constructor and destructor.
6728 <data>: Remove.
6729 <value>: Remove.
6730 <invoke, clone, do_get_result_type, do_get_arg_types>: New
6731 virtual pure methods.
6732 <get_arg_types, get_result_type>: New methods.
6733 (xmethod_worker_ptr): Remove typedef.
6734 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
6735 (xmethod_worker_vec): Remove typedef.
6736 (xmethod_worker_up): New typedef.
6737 (invoke_xmethod): Remove.
6738 (clone_xmethod_worker): Remove.
6739 (free_xmethod_worker): Remove.
6740 (free_xmethod_worker_vec): Remove.
6741 (get_xmethod_arg_types): Remove.
6742 (get_xmethod_result_type): Remove.
6743 * valops.c (find_method_list): Use std::vector, don't use
6744 intermediate vector.
6745 (value_find_oload_method_list): Use std::vector.
6746 (find_overload_match): Use std::vector.
6747 (find_oload_champ): Use std::vector.
6748 * value.c (value_free): Use operator delete.
6749 (value_of_xmethod): Rename to...
6750 (value_from_xmethod): ... this. Don't assign
6751 xmethod_worker::value, take rvalue-reference.
6752 (result_type_of_xmethod): Adjust.
6753 (call_xmethod): Adjust.
6754 * value.h: Include extension.h.
6755 (struct xmethod_worker): Don't forward-declare.
6756 (value_of_xmethod): Rename to...
6757 (value_from_xmethod): ... this, take rvalue-reference.
6758 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
6759 (struct python_xmethod_worker): ... this, add constructor and
6760 destructor.
6761 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
6762 (gdbpy_free_xmethod_worker_data): Rename to...
6763 (python_xmethod_worker::~python_xmethod_worker): ... this and
6764 adjust.
6765 (gdbpy_clone_xmethod_worker_data): Rename to...
6766 (python_xmethod_worker::clone): ... this and adjust.
6767 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
6768 temporary vector.
6769 (gdbpy_get_xmethod_arg_types): Rename to...
6770 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
6771 (gdbpy_get_xmethod_result_type): Rename to...
6772 (python_xmethod_worker::do_get_result_type): ... this and
6773 adjust.
6774 (gdbpy_invoke_xmethod): Rename to...
6775 (python_xmethod_worker::invoke): ... this and adjust.
6776 (new_python_xmethod_worker): Rename to...
6777 (python_xmethod_worker::python_xmethod_worker): ... this and
6778 adjust.
6779 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
6780 Remove.
6781 (gdbpy_free_xmethod_worker_data): Remove.
6782 (gdbpy_get_matching_xmethod_workers): Use std::vector.
6783 (gdbpy_get_xmethod_arg_types): Remove.
6784 (gdbpy_get_xmethod_result_type): Remove.
6785 (gdbpy_invoke_xmethod): Remove.
6786 * python/python.c (python_extension_ops): Remove obsolete
6787 callbacks.
6788
e379cee6
PA
67892018-01-05 Pedro Alves <palves@redhat.com>
6790
6791 PR gdb/18653
6792 * common/signals-state-save-restore.c
6793 (save_original_signals_state): New parameter 'quiet'. Warn if we
6794 find a custom handler preinstalled, instead of internal erroring.
6795 But only warn if !quiet.
6796 * common/signals-state-save-restore.h
6797 (save_original_signals_state): New parameter 'quiet'.
6798 * main.c (captured_main_1): Move save_original_signals_state call
6799 after option handling, and pass QUIET.
6800
a655456c
PA
68012018-01-05 Pedro Alves <palves@redhat.com>
6802
6803 * spu-tdep.c (spu_catch_start): Pass
6804 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
6805
de63c46b
PA
68062018-01-05 Pedro Alves <palves@redhat.com>
6807
6808 PR gdb/22670
6809 * ada-lang.c (literal_symbol_name_matcher): New function.
6810 (ada_get_symbol_name_matcher): Use it for
6811 symbol_name_match_type::SEARCH_NAME.
6812 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
6813 it down instead of assuming symbol_name_match_type::FULL.
6814 * block.h (block_lookup_symbol): New parameter 'match_type'.
6815 * c-valprint.c (print_unpacked_pointer): Use
6816 lookup_symbol_search_name instead of lookup_symbol.
6817 * compile/compile-object-load.c (get_out_value_type): Pass down
6818 symbol_name_match_type::SEARCH_NAME.
6819 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
6820 symbol_name_match_type::FULL.
6821 * cp-support.c (cp_get_symbol_name_matcher): Handle
6822 symbol_name_match_type::SEARCH_NAME.
6823 * infrun.c (insert_exception_resume_breakpoint): Use
6824 lookup_symbol_search_name.
6825 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
6826 * psymtab.c (maintenance_check_psymtabs): Use
6827 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
6828 * stack.c (print_frame_args): Use lookup_symbol_search_name and
6829 SYMBOL_SEARCH_NAME.
6830 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
6831 if symbol_name_match_type::SEARCH_NAME.
6832 (lookup_symbol_in_language): Pass down
6833 symbol_name_match_type::FULL.
6834 (lookup_symbol_search_name): New.
6835 (lookup_language_this): Pass down
6836 symbol_name_match_type::SEARCH_NAME.
6837 (lookup_symbol_aux, lookup_local_symbol): New parameter
6838 'match_type'. Pass it down.
6839 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
6840 (lookup_symbol_search_name): New declaration.
6841 (lookup_symbol_in_block): New 'match_type' parameter.
6842
f98fc17b
PA
68432018-01-05 Pedro Alves <palves@redhat.com>
6844
6845 PR gdb/22670
6846 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
6847 ada_lookup_symbol.
6848 (ada_lookup_symbol): Reimplement in terms of
6849 ada_lookup_symbol_list, bits factored out from
6850 ada_lookup_encoded_symbol.
6851
342f8240
JB
68522018-01-05 Joel Brobecker <brobecker@adacore.com>
6853
6854 * ada-exp.y (write_object_renaming): When subscripting an array
6855 using a symbol as the index, pass the block in call to
6856 ada_lookup_encoded_symbol when looking that symbol up.
6857
7150d33c
JG
68582018-01-05 Jerome Guitton <guitton@adacore.com>
6859
6860 * ada-lang.c (ada_array_length): Use ada_index_type instead of
6861 TYPE_INDEX_TYPE.
6862
cc0e770c
JB
68632018-01-05 Joel Brobecker <brobecker@adacore.com>
6864
6865 * ada-lang.c (ada_to_fixed_value_create): Add handling of
6866 the case where VALUE_LVAL (val0) is not lval_memory.
6867
f79da888 68682018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
6869
6870 * ada-valprint.c (print_optional_low_bound): Handle
6871 character-indexed array printing like boolean-indexed array
6872 printing.
6873
cd385f94
JB
68742018-01-05 Joel Brobecker <brobecker@adacore.com>
6875
6876 * NEWS: Create a new section for the next release branch.
6877 Rename the section of the current branch, now that it has
6878 been cut.
6879
09aca949
JB
68802018-01-05 Joel Brobecker <brobecker@adacore.com>
6881
6882 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
6883 * version.in: Bump version to 8.1.50.DATE-git.
6884
9f757bf7
XR
68852018-01-03 Xavier Roirand <roirand@adacore.com>
6886
6887 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
6888 Add field.
6889 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
6890 Add field.
6891 (default_exception_support_info) <catch_handlers_sym>: Add field.
6892 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
6893 (ada_exception_name_addr_1): Add "catch handlers" handling.
6894 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
6895 Update all callers.
6896 (create_excep_cond_exprs) <ex>: Add parameter.
6897 (re_set_exception): Update create_excep_cond_exprs call.
6898 (print_it_exception, print_one_exception, print_mention_exception)
6899 (print_recreate_exception): Add "catch handler" handling.
6900 (allocate_location_catch_handlers, re_set_catch_handlers)
6901 (check_status_catch_handlers, print_it_catch_handlers)
6902 (print_one_catch_handlers, print_mention_catch_handlers)
6903 (print_recreate_catch_handlers): New function.
6904 (catch_handlers_breakpoint_ops): New variable.
6905 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
6906 Add parameter. Add "catch handler" handling.
6907 (ada_exception_sym_name, ada_exception_breakpoint_ops):
6908 Add "catch handler" handling.
6909 (ada_exception_catchpoint_cond_string): Add "catch handler"
6910 handling.
6911 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
6912 call.
6913 (catch_ada_handlers_command): New function.
6914 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
6915 operations structure.
6916 (_initialize_ada_language): Add "catch handlers" command entry.
6917 * NEWS: Document "catch handlers" feature.
6918
9fe561ab
JB
69192018-01-02 Joel Brobecker <brobecker@adacore.com>
6920
6921 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
6922 account when creating the array type of the slice.
6923 (ada_value_slice): Likewise.
6924
a405673c
JB
69252018-01-02 Joel Brobecker <brobecker@adacore.com>
6926
6927 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
6928 New enum value.
6929 (create_array_type_with_stride): Add byte_stride_prop parameter.
6930 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
6931 New parameter. Update all callers in this file.
6932 (array_type_has_dynamic_stride): New function.
6933 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
6934 of arrays with dynamic byte strides.
6935 * dwarf2read.c (read_array_type): Add support for dynamic
6936 DW_AT_byte_stride attributes.
6937
74a2f8ff
JB
69382018-01-02 Joel Brobecker <brobecker@adacore.com>
6939
6940 * dwarf2read.c (read_unspecified_type): Treat
6941 DW_TAG_enumeration_type DIEs from Ada units as stubs.
6942
e2882c85
JB
69432018-01-01 Joel Brobecker <brobecker@adacore.com>
6944
6945 Update copyright year range in all GDB files.
6946
1690bb24
JB
69472018-01-01 Joel Brobecker <brobecker@adacore.com>
6948
6949 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
6950 and gdb/testsuite/gdb.base/step-line.c.
6951
0f0c98a8
JB
69522018-01-01 Joel Brobecker <brobecker@adacore.com>
6953
6954 * copyright.py (main): Dump the contents of
6955 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
6956 even if BY_HAND is empty.
6957
82e1e79a
JB
69582018-01-01 Joel Brobecker <brobecker@adacore.com>
6959
6960 * top.c (print_gdb_version): Update Copyright year in version
6961 message.
6962
053f54e5 69632018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 6964
053f54e5 6965 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 6966
053f54e5 6967For older changes see ChangeLog-2017.
c906108c
SS
6968\f
6969Local Variables:
6970mode: change-log
6971left-margin: 8
6972fill-column: 74
6973version-control: never
57da7796 6974coding: utf-8
c906108c 6975End: