Use CORE_ADDR_MAX in various "breaks" arrays
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
70ab8ccd
TT
12018-08-27 Tom Tromey <tom@tromey.com>
2
3 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
4 CORE_ADDR_MAX.
5 * mips-tdep.c (mips_deal_with_atomic_sequence)
6 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
7 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
8 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
9 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
10 CORE_ADDR_MAX.
11 * aarch64-tdep.c (aarch64_software_single_step): Use
12 CORE_ADDR_MAX.
13
896a7aa6
TT
142018-08-27 Tom Tromey <tom@tromey.com>
15
16 * linespec.c (complete_linespec_component): Add cast to "char".
17 * completer.c (completion_tracker::build_completion_result): Add
18 cast to "char".
19
dd33d41d
SM
202018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
21
22 * solist.h (struct solist, struct target_so_ops): Fix
23 indentation.
24
c645cda4
SM
252018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
26
27 * ada-tasks.c (ada_task_info_s): Remove typedef.
28 (DEF_VEC_O(ada_task_info_s)): Remove.
29 (struct ada_tasks_inferior_data): Initialize fields.
30 <task_list>: Make an std::vector.
31 (get_ada_tasks_inferior_data): Allocate with new.
32 (ada_get_task_number): Adjust.
33 (get_task_number_from_id): Likewise.
34 (valid_task_id): Likewise.
35 (ada_get_task_info_from_ptid): Likewise.
36 (iterate_over_live_ada_tasks): Likewise.
37 (add_ada_task): Likewise.
38 (read_known_tasks): Likewise.
39 (ada_build_task_list): Likewise.
40 (print_ada_task_info): Likewise.
41 (info_task): Likewise.
42 (task_command_1): Likewise.
43
39e7af3e
SM
442018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
45
46 * ada-lang.c (add_angle_brackets): Return std::string.
47
bbbbbcee
SM
482018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
49
50 * python/py-threadevent.c (py_get_event_thread): Initialize
51 pythread.
52
d98fc15b
PA
532018-08-24 Pedro Alves <palves@redhat.com>
54
55 * python/py-bpevent.c (create_breakpoint_event_object): Use
56 copy-initialization.
57 * python/py-continueevent.c (emit_continue_event): Use
58 copy-initialization.
59 * python/py-exitedevent.c (create_exited_event_object): Return a
60 gdbpy_ref<>.
61 (emit_exited_event): Use copy-initialization.
62 * python/py-inferior.c (python_new_inferior)
63 (python_inferior_deleted, add_thread_object): Use
64 copy-initialization.
65 * python/py-infevents.c (create_inferior_call_event_object)
66 (create_register_changed_event_object)
67 (create_memory_changed_event_object): Return a gdbpy_ref<>.
68 (emit_inferior_call_event, emit_memory_changed_event)
69 (emit_register_changed_event): Use copy-initialization.
70 * python/py-newobjfileevent.c (create_new_objfile_event_object):
71 Return a gdbpy_ref<>.
72 (emit_new_objfile_event): Use copy-initialization.
73 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
74 (emit_clear_objfiles_event): Use copy-initialization.
75 * python/py-signalevent.c (create_signal_event_object): Use
76 copy-initialization.
77 * python/py-threadevent.c (create_thread_event_object): Use
78 copy-initialization.
79
da3c8738
PA
802018-08-24 Pedro Alves <palves@redhat.com>
81 Simon Marchi <simon.marchi@ericsson.com>
82
83 PR gdb/23379
84 * python/py-continueevent.c: Include "gdbthread.h".
85 (create_continue_event_object): Add intro comment. Add 'ptid'
86 parameter. Use it to find thread to pass to
87 create_thread_event_object.
88 (emit_continue_event): Pass PTID down to
89 create_continue_event_object.
90 * python/py-event.h (py_get_event_thread): Declare.
91 (create_thread_event_object): Remove default from 'thread'
92 parameter.
93 * python/py-stopevent.c (create_stop_event_object): Use
94 py_get_event_thread.
95 * python/py-threadevent.c (get_event_thread): Rename to ...
96 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
97 and use it to find the thread.
98 (create_thread_event_object): Assert that THREAD isn't null.
99 Don't find the event thread here.
100
26457a9c
KB
1012018-08-23 Kevin Buettner <kevinb@redhat.com>
102
103 * block.h (blockrange, blockranges): New struct declarations.
104 (struct block): Add new field named `ranges'.
105 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
106 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
107 macros for accessing ranges in struct block.
108 (make_blockranges): New declaration.
109 block.c (make_blockranges): New function.
2d5f09ec
KB
110 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
111 for block.
fc811edd
KB
112 * symtab.h (find_pc_partial_function): Add new parameter `block'.
113 * blockframe.c (cache_pc_function_block): New static global.
114 (clear_pc_function_cache): Clear cache_pc_function_block.
115 (find_pc_partial_function): Move comment to symtab.h. Add
116 support for non-contiguous blocks.
e9480230
KB
117 * cli/cli-cmds.c (block.h): Include.
118 (print_disassembly): Handle printing of non-contiguous blocks.
119 (disassemble_current_function): Likewise.
120 (disassemble_command): Likewise.
26457a9c 121
2b1ffcfd
KB
122 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
123 BLOCK_START.
124 * blockframe.c (get_pc_function_start): Likewise.
125 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
126 (gcc_symbol_address): Likewise.
127 * compile/compile-object-run.c (compile_object_run): Likewise.
128 * compile/compile.c (get_expr_block_and_pc): Likewise.
129 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
130 (func_addr_to_tail_call_list): Likewise.
131 * findvar.c (default_read_var_value): Likewise.
132 * inline-frame.c (inline_frame_this_id): Likewise.
133 (skip-inline_frames): Likewise.
134 * infcmd.c (until_next_command): Likewise.
135 * linespec.c (convert_linespec_to_sals): Likewise.
136 * parse.c (parse_exp_in_context_1): Likewise.
137 * printcmd.c (build_address_symbolic): likewise.
138 (info_address_command): Likewise.
139 symtab.c (find_function_start_sal): Likewise.
140 (skip_prologue_sal): Likewise.
141 (find_function_alias_target): Likewise.
142 (find_gnu_ifunc): Likewise.
143 * stack.c (find_frame_funname): Likewise.
144 * symtab.c (fixup_symbol_section): Likewise.
145 (find_function_start_sal): Likewise.
146 (skip_prologue_sal): Likewsie.
147 (find_function_alias_target): Likewise.
148 (find_gnu_ifunc): Likewise.
149 * tracepoint.c (info_scope_command): Likewise.
150 * value.c (value_fn_field): Likewise.
151
9644dc3a
KB
152 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
153 in place of find_pc_partial_function.
154 * blockframe.c (find_function_entry_range_from_pc): New function.
155 * symtab.h (find_function_entry_range_from_pc): Declare and document.
156 * objfiles.c (objfile_relocate1): Relocate start and end addresses
157 for each range in a block.
158
159
12a0d0f6
XR
1602018-08-23 Xavier Roirand <roirand@adacore.com>
161
162 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
163 incrementation.
164
d1012b8e
SM
1652018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
166
167 * solib-svr4.c (read_program_headers_from_bfd): Return
168 gdb::optional<gdb::byte_vector>.
169 (svr4_exec_displacement): Adjust.
170
17658d46
SM
1712018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
172
173 * solib-svr4.c (read_program_header): Return
174 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
175 (find_program_interpreter): Return
176 gdb::optional<gdb::byte_vector>.
177 (scan_dyntag_auxv): Adjust.
178 (enable_break): Adjust.
179 (svr4_exec_displacement): Adjust.
180
ae739fe7
SM
1812018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
182
183 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
184 * inf-child.c (inf_child_target::terminal_save_inferior): New.
185
467dc1e2
SM
1862018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
187
188 * guile/scm-string.c (gdbscm_scm_from_printf): Use
189 string_vprintf.
190 * guile/scm-utils.c (gdbscm_printf): Likewise.
191 * serial.c (serial_printf): Likewise.
192 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
193
6d52907e
JV
1942018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
195
196 * stack.c (print_frame): Print frame architecture when printing on
197 an MI output.
198 * NEWS: Mention new "arch" attribute in frame output.
199
9758a8f8
AH
2002018-08-21 Alan Hayward <alan.hayward@arm.com>
201
202 * arch/aarch64.h (aarch64_regnum): Update comment.
203
1461bdac
AH
2042018-08-21 Alan Hayward <alan.hayward@arm.com>
205
206 * NEWS: Add SVE to 8.2 section.
207
4895f384
PA
2082018-08-21 Pedro Alves <palves@redhat.com>
209
210 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
211 out from gdbscm_parse_function_args.
212 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
213 gdbscm_parse_function_args_1.
214
a4497d2f
SM
2152018-08-21 Simon Marchi <simon.marchi@ericsson.com>
216
217 PR gdb/17816
218 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
219 operator.
220
c44deb73
SM
2212018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
222
223 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
224
be2d111a
MS
2252018-08-19 Michael Spang <spang@google.com>
226
227 PR gdb/11786
228 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
229 for PT_TLS segments.
230
a6b786da
KB
2312018-08-18 Kevin Buettner <kevinb@redhat.com>
232
233 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
234 dwarf_variable_value.
235 * dwarf2-frame.c (class dwarf_expr_executor):
236 Add override for dwarf_variable_value.
237 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
238 (class symbol_needs_eval_context): Likewise.
239 (indirect_synthetic_pointer): Add forward declaration.
240 (sect_variable_value): New function.
241 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
242 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
243 for DW_OP_GNU_variable_value.
244
89fbedf3
TT
2452018-08-16 Tom Tromey <tom@tromey.com>
246
247 * top.c (read_command_file): Update.
248 (command_line_input): Remove "repeat" argument.
249 * ada-lang.c (get_selections): Update.
250 * linespec.c (decode_line_2): Update.
251 * defs.h (command_line_input): Remove argument.
252 * cli/cli-script.c (read_next_line): Update.
253 * python/py-gdb-readline.c: Update.
254
12582533
TT
2552018-08-17 Tom Tromey <tom@tromey.com>
256
257 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
258 command_line_input.
259
49514353
TT
2602018-08-15 Tom Tromey <tom@tromey.com>
261
262 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
263
26fb3983
JV
2642018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
265
266 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
267 If used, use find_pc_partial_function to find address range
268 to disassemble.
269 * mi/mi-main.c (mi_cmd_list_features): Report
270 "data-disassemble-a-option" feature.
271 * NEWS: Mention new -data-disassemble option -a.
272
a97b53dd
TT
2732018-08-13 Tom Tromey <tom@tromey.com>
274
275 * common/common-defs.h (_FORTIFY_SOURCE): Define.
276
0c76e06d
AH
2772018-08-13 Alan Hayward <alan.hayward@arm.com>
278
279 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
280 (aarch64_linux_collect_sve_regset): Likewise.
281 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
282 * regcache.h (regcache_map_entry_size): New function.
283
b7fd65b9
AH
2842018-08-13 Alan Hayward <alan.hayward@arm.com>
285
286 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
287 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
288 (SVE_HEADER_VL_LENGTH): Likewise.
289 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
290 (SVE_HEADER_FLAGS_LENGTH): Likewise.
291 (SVE_HEADER_RESERVED_LENGTH): Likewise.
292 (SVE_HEADER_SIZE_OFFSET): Likewise.
293 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
294 (SVE_HEADER_VL_OFFSET): Likewise.
295 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
296 (SVE_HEADER_FLAGS_OFFSET): Likewise.
297 (SVE_HEADER_RESERVED_OFFSET): Likewise.
298 (SVE_HEADER_SIZE): Likewise.
299 (aarch64_linux_core_read_vq): Add function.
300 (aarch64_linux_core_read_description): Check for SVE section.
301
a616bb94
AH
3022018-08-13 Alan Hayward <alan.hayward@arm.com>
303
304 * aarch64-fbsd-tdep.c
305 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
306 collect_size.
307 * aarch64-linux-tdep.c
308 (aarch64_linux_iterate_over_regset_sections): Likewise.
309 * alpha-linux-tdep.c
310 (alpha_linux_iterate_over_regset_sections):
311 * alpha-nbsd-tdep.c
312 (alphanbsd_iterate_over_regset_sections): Likewise.
313 * amd64-fbsd-tdep.c
314 (amd64fbsd_iterate_over_regset_sections): Likewise.
315 * amd64-linux-tdep.c
316 (amd64_linux_iterate_over_regset_sections): Likewise.
317 * arm-bsd-tdep.c
318 (armbsd_iterate_over_regset_sections): Likewise.
319 * arm-fbsd-tdep.c
320 (arm_fbsd_iterate_over_regset_sections): Likewise.
321 * arm-linux-tdep.c
322 (arm_linux_iterate_over_regset_sections): Likewise.
323 * corelow.c (get_core_registers_cb): Likewise.
324 (core_target::fetch_registers): Likewise.
325 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
326 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
327 * gdbarch.h (void): Regenerate.
328 * gdbarch.sh: Add supply_size and collect_size.
329 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
330 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
331 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
332 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
333 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
334 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
335 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
336 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
337 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
338 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
339 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
340 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
341 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
342 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
343 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
344 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
345 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
346 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
347 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
348 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
349 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
350 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
351 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
352 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
353 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
354 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
355 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
356 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
357 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
358 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
359
a9925d4f
SM
3602018-08-10 Simon Marchi <simon.marchi@ericsson.com>
361
362 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
363 with string_printf.
364
ad3a68e9
KS
3652018-08-10 Keith Seitz <keiths@redhat.com>
366
367 * compile/compile-c-support.c (add_code_header, add_code_footer):
368 Move into policy class.
369 (c_push_user_expression, pop_user_expression_nop)
370 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
371 (compile_program): New host class.
372 (c_compile_program): New typedef.
373 (c_compute_porgram): Use c_compile_program.
374
0cfbf430
KS
3752018-08-10 Keith Seitz <keiths@redhat.com>
376
377 * compile/compile-internal.h (compile_instance::~compile_instance):
378 Remove calls to htab_delete.
379 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
380 * compile.c (compile_instance::compile_instance): Initialize
381 htab unique pointers.
382 (compile_instance::get_cached_type, compile_instance::insert_type)
383 (compile_instance::error_symbol_once): Update for unique_ptr.
384
946d3d10
KS
3852018-08-10 Keith Seitz <keiths@redhat.com>
386
387 * compile/compile-c-symbols.c (struct symbol_error)
388 (hash_symbol_error, eq_symbol_error, del_symbol_error)
389 (compile_instance::insert_symbol_error)
390 (compile_instance::error_symbol_once): Move to ...
391 * compile/compile.c: ... here.
392
9cdfd9a2
KS
3932018-08-10 Keith Seitz <keiths@redhat.com>
394
395 * compile/compile-c-support.c (c_get_compile_context): Use `new'
396 instead of `new_compile_instance'.
397 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
398 Update description.
399 If the symbol error map is not initialized, create it.
400 (generate_c_for_for_one_symbol): Do not check/initialize
401 the symbol error map.
402 * compile/compile-c-types.c (compile_c_instance): Make a class.
403 Update all callers.
404 (compile_instance::compile_instance): Initialize the type cache.
405 (get_cached_type): New function.
406 (insert_type): Update description.
407 (compile_c_instance::m_default_cflags): Define.
408 (convert_type): Update description. Use get_cached_type.
409 (delete_instance): Moved to destructor.
410 (new_compile_instance): Moved to constructor.
411 * compile/compile-c.h (compile_c_instance): Make class inheriting
412 from compile_instance.
413 <base>: Remove field.
414 <type_map, symbol_err_map>: Move to base class.
415 <c_plugin>: Rename to `m_plugin' and remove pointer type.
416 * compile/compile-internal.h (compile_instance): Make class.
417 <type_map_t, symbol_err_map_t>: Define.
418 <fe>: Rename to `m_gcc_fe'.
419 <scope, block, gcc_target_options>: Add `m_' prefix.
420 <m_type_map, m_symbol_err_map>: New fields, moved from
421 compile_c_instance.
422 <destroy>: Remove.
423 (convert_type, new_compile_instance): Remove.
424 * compile/compile.c (cleanup_compile_instance): Remove.
425 (compile_to_object): Use unique_ptr to eliminate cleanups.
426 (compile_instance::set_print_callback, compile_instance::version)
427 (compile_instance::set_verbose)
428 (compile_instance::set_driver_filename)
429 (compile_instance::set_triplet_regexp)
430 (compile_instance::set_arguments)
431 (compile_instance::set_source_file)
432 (compile_instance::compile): Define.
433
18cdc6d8
KS
4342018-08-10 Keith Seitz <keiths@redhat.com>
435
436 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
437 * compile/compile-c-types.c: Define GCC_METHODN macros and include
438 gcc-c-fe.def to define C plugin.
439 (delete_instance): Delete `c_plugin'.
440 (new_compile_instance): Initialize `c_plugin'.
441 * compile/compile-c.h: Include gcc_c_plugin.h.
442 (struct compile_c_instance) <c_plugin>: New member.
443 * gcc-c-plugin.h: New file.
444 Update all callers with API change.
445
b7dc48b4
KS
4462018-08-10 Keith Seitz <keiths@redhat.com>
447
448 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
449 (HFILES_NO_SRCDIR): ... to here.
450 Add compile-internal.h and compile-c.h.
451 * compile/compile-c-support.c: Include compile-c.h.
452 * compile/compile-c-symbols.c: Include compile-c.h.
453 (generate_c_for_variable_locations): Update comment.
454 * compile/compile-c-types.c: Include compile-c.h.
455 * compile/compile-c.h: New file -- moved C language declarations
456 from other files here.
457 * compile/compile-internal.h: Do not include hashtab.h or
458 common/enum-flags.h.
459 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
460 (gcc_convert_symbol, gcc_symbol_address)
461 (generate_c_for_variable_locations, c_get_mode_for_size)
462 (c_get_range_decl_name): Definitions moved to compile-c.h.
463 * compile/compile-loc2c.c: Include compile-c.h.
464
6f36b6d2
KS
4652018-08-10 Keith Seitz <keiths@redhat.com>
466
467 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
468 (c_symbol_substitution_name): ... this.
469 Update all callers.
470
bd923e51
KS
4712018-08-10 Keith Seitz <keiths@redhat.com>
472
473 * compile/compile-c-support.c (c_compute_program): Use
474 unique_xmalloc_ptr to eliminate cleanup.
475 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
476 Return a unique_xmalloc_ptr and eliminate cleanup.
477 * compile/compile-internal.h (generate_c_for_variable_locations):
478 Return unique_xmalloc_ptr and update description.
479
dbd534fe
AH
4802018-08-10 Alan Hayward <alan.hayward@arm.com>
481
482 * corelow.c (core_target::get_core_register_section): Rename
483 min_size to section_min_size.
484
90ad3654
JW
4852018-08-09 Jim Wilson <jimw@sifive.com>
486
52a187f8
JW
487 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
488 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
489 * NEWS: Mention new GNU/Linux RISC-V target.
490 * configure.host: Add riscv*-*-linux*.
491 * configure.nat: Add riscv*.
492 * configure.tgt: Add riscv*-*-linux*.
3c77f97e 493 * riscv-linux-nat.c: New file.
90ad3654
JW
494 * riscv-linux-tdep.c: New file.
495
aff4e175
AB
4962018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
497
498 * infrun.c (resume): Make static, add forward declaration.
499 (proceed): Update header comment.
500 * infrun.h (resume): Delete declaration.
501
06ab9219
TT
5022018-08-09 Tom Tromey <tom@tromey.com>
503
504 * riscv-tdep.h: Minor formatting fixes.
505
83c8d318
SM
5062018-08-09 Simon Marchi <simon.marchi@ericsson.com>
507
508 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
509 * dwarf-index-cache.c (create_dir_and_check): Likewise.
510 (test_mkdir_recursive): Likewise.
511 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
512
5ff2bbae
AB
5132018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
514
515 * valarith.c (value_subscripted_rvalue): If an array is not in
516 memory, and we don't know the upper bound, then we can't know that
517 the requested element exists or not.
518
fdbac7d8
SM
5192018-08-08 Simon Marchi <simon.marchi@ericsson.com>
520
521 * target.c (str_comma_list_concat_elem): Fix typo in comment.
522 (target_options_to_string): Add comment.
523
83202f7a
TT
5242018-08-08 Tom Tromey <tom@tromey.com>
525
526 * unittests/scoped_mmap-selftests.c: Check result of "write".
527
411baa47
JW
5282018-08-08 Jim Wilson <jimw@sifive.com>
529
5c720ed8
JW
530 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
531 (decode_register_index_short): New.
532 (decode_j_type_insn, decode_cj_type_insn): New.
533 (decode_b_type_insn, decode_cb_type_insn): New.
534 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
535 local xlen. Check xlen when decoding ambiguous compressed insns. In
536 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
537 is_c_sw_insn instead of is_sw_insn.
538 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
539 (riscv_software_single_step): New.
540 * riscv-tdep.h (riscv_software_single_step): Declare.
541
411baa47
JW
542 * riscv-tdep.c (riscv_isa_xlen): Drop static.
543 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
544
9d4a934c
AB
5452018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
546
547 PR gdb/18050:
548 * target.c (dispose_inferior): Don't dispose of inferiors that are
549 already killed.
550
ff36536c
SN
5512018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
552
553 * remote.c (remote_target::download_tracepoint): Change char* to
554 const char*.
555
09ce46f2
SM
5562018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
557
558 * target.h (target_options_to_string): Return an std::string.
559 * target.c (str_comma_list_concat_elem): Return void, use
560 std::string.
561 (do_option): Likewise.
562 (target_options_to_string): Return an std::string.
563 * linux-nat.c (linux_nat_target::wait): Adjust.
564 * target-debug.h (target_debug_print_options): Adjust.
565
9c612964
TT
5662018-08-07 Tom Tromey <tom@tromey.com>
567
568 * Makefile.in (CPPFLAGS): New variable.
569 (INTERNAL_CPPFLAGS): Use it.
570
7d11235d
SM
5712018-08-07 Simon Marchi <simon.marchi@ericsson.com>
572
573 * NEWS: Mention the index cache.
574
87d6a7aa
SM
5752018-08-07 Simon Marchi <simon.marchi@ericsson.com>
576
577 * common/pathstuff.h (get_standard_cache_dir): New.
578 * common/pathstuff.c (get_standard_cache_dir): New.
579 * build-id.h (build_id_to_string): New.
580 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
581 DEBUG_STR_SUFFIX): Move to here.
582 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
583 DEBUG_STR_SUFFIX): Move from there.
584 (write_psymtabs_to_index): Make non-static, add basename
585 parameter. Write to temporary files, rename when done.
586 (save_gdb_index_command): Adjust call to
587 write_psymtabs_to_index.
588 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
589 field.
590 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
591 (get_gdb_index_contents_from_cache): New.
592 (get_gdb_index_contents_from_cache_dwz): New.
593 (dwarf2_initialize_objfile): Read index from cache.
594 (dwarf2_build_psymtabs): Save to index.
595 * dwarf-index-cache.h: New file.
596 * dwarf-index-cache.c: New file.
597 * dwarf-index-write.h: New file.
598
8a99096f
SM
5992018-08-07 Simon Marchi <simon.marchi@ericsson.com>
600
601 * gnulib/aclocal.m4: Re-generate.
602 * gnulib/config.in: Re-generate.
603 * gnulib/configure: Re-generate.
604 * gnulib/import/Makefile.am: Re-generate.
605 * gnulib/import/Makefile.in: Re-generate.
606 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
607 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
608 * gnulib/import/m4/mkdir.m4: New file.
609 * gnulib/import/mkdir.c: New file.
610 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
611 module.
612
5c831bb1
SM
6132018-08-07 Simon Marchi <simon.marchi@ericsson.com>
614
615 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
616 * common/scoped_mmap.c: New file.
617 * common/scoped_mmap.h (destroy): New method.
618 (~scoped_mmap, reset): Use destroy.
619 (scoped_mmap): New move constructor.
620 (mmap_file): New declaration.
621 * unittests/scoped_mmap-selftests.c (test_normal,
622 test_invalid_filename, run_tests): New functions.
623 (_initialize_scoped_mmap_selftests): Register selftest.
624
4485a1c1
SM
6252018-08-07 Simon Marchi <simon.marchi@ericsson.com>
626
627 * dwarf2read.c (read_gdb_index_from_section): Rename to...
628 (read_gdb_index_from_buffer): ... this. Remove section
629 parameter, add buffer parameter.
630 (get_gdb_index_contents_ftype,
631 get_gdb_index_contents_dwz_ftype): New typedefs.
632 (dwarf2_read_gdb_index): Add callback parameters to get the
633 index contents.
634 (get_gdb_index_contents_from_section): New.
635 (dwarf2_initialize_objfile): Update call to
636 dwarf2_read_gdb_index.
637
528e1572
SM
6382018-08-07 Simon Marchi <simon.marchi@ericsson.com>
639
640 * common/filestuff.h (gdb_fopen_cloexec): New overload.
641 (gdb_open_cloexec): Likewise.
642 * nat/linux-osdata.c (command_from_pid): Use string_printf.
643 (commandline_from_pid): Likewise.
644 (linux_xfer_osdata_threads): Likewise.
645 (linux_xfer_osdata_fds): Likewise.
646 * ada-lang.c (is_package_name): Likewise.
647 * auxv.c (procfs_xfer_auxv): Likewise.
648 * breakpoint.c (print_one_breakpoint_location): Use
649 uiout::field_fmt.
650 (print_one_catch_solib): Use string_printf.
651 * coff-pe-read.c (add_pe_exported_sym): Likewise.
652 (add_pe_forwarded_sym): Likewise.
653 * dwarf2read.c (create_type_unit_group): Likewise.
654 (build_error_marker_type): Likewise.
655 * infcall.c (get_function_name): Likewise.
656 * valprint.c (print_converted_chars_to_obstack): Likewise.
657 * xtensa-tdep.c (xtensa_register_type): Likewise.
658
a7f25a84
SM
6592018-08-06 Simon Marchi <simon.marchi@ericsson.com>
660
661 * remote.c (remote_target::download_tracepoint): Fix format
662 string errors.
663
296956be
PFC
6642018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
665
666 * tracefile.c: Include common/byte-vector.h.
667 (trace_save): Change type of buf to gdb::byte_vector. Initialize
668 with trace_regblock_size if needed. Update uses of buf.
669
a04b9d62
PFC
6702018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
671
672 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
673 std::vector<unsigned char>.
674 * tracepoint.c (collection_list::collection_list): Remove
675 m_regs_mask initializer from initializer list. Resize
676 m_regs_mask using the largest remote register number.
677 (collection_list::add_remote_register): Remove size check on
678 m_regs_mask. Use at to access element.
679 (collection_list::stringify): Change type of temp_buf to
680 gdb::char_vector. Update uses of temp_buf. Resize if needed to
681 stringify the register mask. Use pack_hex_byte for the register
682 mask.
683
4277c4b8
PFC
6842018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
685
686 * tracepoint.h (class collection_list) <add_register>: Remove.
687 <add_remote_register, add_ax_registers, add_local_register>:
688 Declare.
689 <add_memrange>: Add scope parameter.
690 * tracepoint.c (encode_actions_1): Likewise.
691 (collection_list::add_register): Rename to ...
692 (collection_list::add_remote_register): ... this. Update
693 comment.
694 (collection_list::add_ax_registers, add_local_register): New
695 methods.
696 (collection_list::add_memrange): Add scope parameter. Call
697 add_local_register instead of add_register.
698 (finalize_tracepoint_aexpr): New function.
699 (collection_list::collect_symbol): Update calls to add_memrange.
700 Call add_local_register instead of add_register. Call
701 add_ax_registers. Call finalize_tracepoint_aexpr.
702 (encode_actions_1): Get remote regnos for $reg action. Call
703 add_remote_register, add_ax_registers, and add_local_register.
704 Update call to add_memrange. Call finalize_tracepoint_aexpr.
705 (validate_actionline): Call finalize_tracepoint_aexpr.
706
3df3a985
PFC
7072018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
708
709 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
710 Replace array buf with gdb::char_vector buf, of size
711 get_remote_packet_size (). Replace references to buf and
712 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
713 and xsnprintf with snprintf. Raise errors if the buffer is too
714 small.
715
aa6f3694
PFC
7162018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
717
718 * remote.c (remote_target::download_tracepoint): Fix the has_more
719 predicate in the QTDP action list iteration.
720
05abfc39
PFC
7212018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
722
723 * remote.c (remote_target::download_tracepoint): Fix indentation
724 in for block.
725
821a2682
RO
7262018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
727
728 * proc-api.c (_initialize_proc_api): Remove c, unused.
729 * procfs.c (procfs_init_inferior): Remove signals, unused.
730 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
731 unused.
732
95347337
AB
7332018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
734 Andrew Burgess <andrew.burgess@embecosm.com>
735
736 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
737 'W_STOPCODE (0)' as this could be ambiguous.
738
425699f5
SDJ
7392018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
740
741 * ser-tcp.c (net_open): Fix thinko when deciding whether to
742 disable TCP's Nagle algorithm (use "ai_protocol" instead of
743 "ai_socktype").
744
3e1d3d8c
TT
7452018-08-02 Tom Tromey <tom@tromey.com>
746
747 PR symtab/16842.
748 * dwarf2read.c (read_func_scope): Set symtab on template parameter
749 symbols.
750 (process_structure_scope): Likewise.
751
15843549
XR
7522018-08-02 Xavier Roirand <roirand@adacore.com>
753
754 PR gdb/22629:
755 * darwin-nat.c (darwin_kill_inferior): Fix handling of
756 kill inferior.
757
b5bddbbb
TT
7582018-08-02 Tom Tromey <tom@tromey.com>
759
760 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
761 (darwin_suspend_inferior, darwin_resume_inferior)
762 (darwin_decode_notify_message, darwin_resume_inferior_threads)
763 (darwin_check_new_threads): Check result of get_darwin_inferior.
764
f61cfa07
JB
7652018-07-31 Joel Brobecker <brobecker@adacore.com>
766
767 GDB 8.1.1 released.
768
5abe0f0c
JV
7692018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
770
771 * varobj.c (varobj_get_path_expr_parent): Report an error if
772 parent is a dynamic varobj.
773
472fa5ee
SM
7742018-07-31 Simon Marchi <simon.marchi@ericsson.com>
775
776 * gnulib/aclocal.m4: Re-generate.
777 * gnulib/config.in: Re-generate.
778 * gnulib/configure: Re-generate.
779 * gnulib/import/Makefile.in: Re-generate.
780 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
781 * gnulib/import/m4/onceonly.m4: Re-generate.
782
1c28969e
SM
7832018-07-31 Simon Marchi <simon.marchi@ericsson.com>
784
785 * target-descriptions.c (struct xml_test_tdesc): New.
786 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
787 (record_xml_tdesc): Update.
788 (maintenance_check_xml_descriptions): Update.
789 * target-descriptions.h (record_xml_tdesc): Update comment.
790
c8f2dc0d
AB
7912018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
792
793 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
794 checking array bounds are defined.
795
463c08d1
TT
7962018-07-30 Tom Tromey <tom@tromey.com>
797
798 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
799 irreflexivity violation.
800
dba7455e
TT
8012018-07-30 Tom Tromey <tom@tromey.com>
802
803 * cli/cli-decode.c (lookup_cmd): Remove lint code.
804 * value.c (unpack_long): Remove lint code.
805 * valops.c (value_ind): Remove lint code.
806 * valarith.c (value_x_binop, value_x_unop, value_equal)
807 (value_pos): Remove lint code.
808
37cc0cae
TV
8092018-07-28 Tom de Vries <tdevries@suse.de>
810
811 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
812 with undefined upper bound as <optimized out>.
813
129eb0f1
SDJ
8142018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
815
816 * gcore.in: Rename variable "name" to "prefix". Expand
817 "usage" text.
818
6af79d7b
JT
8192018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
820
821 * windows-nat.c (windows_nat_target::create_inferior): Update to
822 call close() in global namespace.
823
79748972
TT
8242018-07-26 Tom Tromey <tom@tromey.com>
825
826 * dwarf-index-write.c (add_address_entry): Don't add objfile
827 offsets.
828 * dbxread.c (find_stab_function): Rename from
829 find_stab_function_addr. Return a bound_minimal_symbol.
830 (read_dbx_symtab): Use raw_text_low, raw_text_high.
831 Don't add objfile offsets.
832 (end_psymtab): Use raw_text_low, raw_text_high,
833 MSYMBOL_VALUE_RAW_ADDRESS.
834 (read_ofile_symtab): Update.
835 (process_one_symbol): Update.
836 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
837 offsets.
838 (dw2_relocate): Remove.
839 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
840 searching addrmap.
841 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
842 Update.
843 (process_psymtab_comp_unit_reader, add_partial_symbol)
844 (add_partial_subprogram, dwarf2_ranges_read): Update.
845 (load_partial_dies): Update.
846 (add_address_entry): Don't add objfile offsets.
847 (dwarf2_build_include_psymtabs): Update.
848 (create_addrmap_from_aranges): Don't add objfile offsets.
849 (dw2_find_pc_sect_compunit_symtab): Update.
850 * mdebugread.c (parse_symbol): Don't add objfile offsets.
851 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
852 Update.
853 (parse_partial_symbols): Don't add objfile offsets. Use
854 raw_text_low, raw_text_high. Update.
855 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
856 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
857 or call 'relocate' quick function. Clear psymbol_map.
858 * psympriv.h (struct partial_symbol) <address>: Add section
859 offset.
860 <set_unrelocated_address>: Rename from set_address.
861 <raw_text_low, raw_text_high>: New methods.
862 <text_low, text_high>: Add objfile parameter.
863 (add_psymbol_to_bcache): Add 'section' parameter. Call
864 set_unrelocated_address.
865 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
866 (find_pc_psymbol): Update.
867 (fixup_psymbol_section, relocate_psymtabs): Remove.
868 (dump_psymtab, psym_functions): Update.
869 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
870 parameter.
871 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
872 (start_psymtab_common): Update.
873 * symfile-debug.c (debug_qf_relocate): Remove.
874 (debug_sym_quick_functions): Update.
875 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
876 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
877 Update.
878
52948f01
TT
8792018-07-26 Tom Tromey <tromey@redhat.com>
880
881 * dbxread.c (end_psymtab): Use text_high_valid and
882 text_low_valid.
883 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
884 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
885 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
886 Update comment.
887 <text_low_valid, text_high_valid>: New fields.
888 <set_text_low, set_text_high>: Update.
889 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
890
4ae976d1
TT
8912018-07-26 Tom Tromey <tom@tromey.com>
892
893 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
894 Update.
895 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
896 textlow and texthigh fields.
897 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
898 Update.
899 * mdebugread.c (parse_lines, parse_partial_symbols)
900 (psymtab_to_symtab_1): Update.
901 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
902 Rename fields. Update comment. Now private.
903 <text_low, text_high, set_text_low, set_text_high>: New methods.
904 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
905 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
906 (start_psymtab_common, maintenance_info_psymtabs)
907 (maintenance_check_psymtabs): Update.
908 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
909 texthigh fields.
910 (scan_xcoff_symtab): Update.
911
02e9e7f7
TT
9122018-07-26 Tom Tromey <tromey@redhat.com>
913
914 * psympriv.h (struct partial_symbol) <unrelocated_address,
915 address, set_address>: New methods.
916 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
917 (fixup_psymbol_section, relocate_psymtabs): Update.
918 (print_partial_symbols): Add 'objfile' parameter. Update.
919 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
920 Update.
921
8a6d4234
TT
9222018-07-26 Tom Tromey <tom@tromey.com>
923
924 * dwarf-index-write.c (write_psymbols, debug_names::insert)
925 (debug_names::write_psymbols): Update.
926 * psympriv.h (struct partial_symbol): Derive from
927 general_symbol_info.
928 <obj_section>: New method.
929 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
930 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
931 (find_pc_sect_psymbol, fixup_psymbol_section)
932 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
933 (print_partial_symbols, recursively_search_psymtabs)
934 (compare_psymbols, psymbol_hash, psymbol_compare)
935 (add_psymbol_to_bcache, maintenance_check_psymtabs)
936 (psymbol_name_matches, psym_fill_psymbol_map): Update.
937
08994e1d
TT
9382018-07-26 Tom Tromey <tromey@redhat.com>
939
940 * dbxread.c (end_psymtab): Remove dead code.
941
3c3bb058
AB
9422018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
943
944 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
945 DWARF unwinders are disabled.
946 * dwarf2-frame.c: Add dwarf2read.h include.
947 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
948 disabled.
949 (dwarf2_frame_unwinders_enabled_p): Define.
950 (show_dwarf_unwinders_enabled_p): New function.
951 (_initialize_dwarf2_frame): Register switch to control DWARF
952 unwinder use.
953 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
954 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
955 (show_dwarf_cmdlist): Remove static keyword.
956 * dwarf2read.h (set_dwarf_cmdlist): Declare.
957 (show_dwarf_cmdlist): Declare.
958 * NEWS: Document new feature.
959
9e7f3bbb
TV
9602018-07-26 Tom de Vries <tdevries@suse.de>
961
962 PR breakpoints/23366
963 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
964
506f5c41
TV
9652018-07-26 Tom de Vries <tdevries@suse.de>
966
967 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
968 DW_AT_count can't be translated to a dynamic prop.
969
16f808ec
TV
9702018-07-25 Tom de Vries <tdevries@suse.de>
971
972 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
973 try/catch.
974
d7154a8d
JV
9752018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
976
977 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
978
a45389f6
JB
9792018-07-25 Joel Brobecker <brobecker@adacore.com>
980
981 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
982
380618d6
KS
9832018-07-24 Keith Seitz <keiths@redhat.comt
984
985 PR symtab/23010
986 * dwarf2read.c (dw2_add_symbol_to_list): New function.
987 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
988 instead of add_symbol_to_list.
989 (read_file_scope): Call prepare_one_comp_unit before reading
990 any other DIEs.
991
4b17aefe
SM
9922018-07-24 Simon Marchi <simon.marchi@ericsson.com>
993
994 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
995
29d17e47
TT
9962018-07-24 Tom Tromey <tom@tromey.com>
997
998 * utils.c (malloc, realloc, free): Don't declare.
999 * configure, config.in: Rebuild.
1000 * configure.ac: Don't check for declarations of free, malloc, or
1001 realloc.
1002
cf4088a9
SM
10032018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1004
1005 * aarch64-linux-nat.c
1006 (aarch64_linux_nat_target::stopped_data_address): Remove unused
1007 variable.
1008 * arm-linux-nat.c (fetch_regs): Likewise.
1009 (store_regs): Likewise.
1010 (fetch_vfp_regs): Likewise.
1011 (store_vfp_regs): Likewise.
1012 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
1013 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
1014 (arm_linux_nat_target::insert_watchpoint): Likewise.
1015 (arm_linux_nat_target::remove_watchpoint): Likewise.
1016 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
1017 Likewise.
1018 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
1019 Likewise.
1020 * ppc-linux-nat.c (fetch_register): Likewise.
1021 (fetch_all_gp_regs): Likewise.
1022 (fetch_ppc_registers): Likewise.
1023 (store_all_gp_regs): Likewise.
1024 (store_ppc_registers): Likewise.
1025 (hwdebug_insert_point): Likewise.
1026 (can_use_watchpoint_cond_accel): Likewise.
1027 * remote-sim.c (gdb_os_write_stdout): Likewise.
1028
a0de763e
TT
10292018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1030 Tom Tromey <tom@tromey.com>
1031
1032 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
1033 test for it.
1034 * configure: Rebuild.
1035
3b20124b
TT
10362018-07-22 Tom Tromey <tom@tromey.com>
1037
1038 * regformats/regdat.sh: Define xmltarget_${name} inside
1039 #ifndef IN_PROCESS_AGENT.
1040
8c8807f4
TT
10412018-07-22 Tom Tromey <tom@tromey.com>
1042
1043 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
1044
c486b610
TT
10452018-07-22 Tom Tromey <tom@tromey.com>
1046
1047 * symfile.c (reread_symbols): Notify iter, not objfile.
1048
494f80a9
TT
10492018-07-22 Tom Tromey <tom@tromey.com>
1050
1051 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
1052 Use arch_ops.
1053 (ravenscar_thread_target::prepare_to_store): Likewise.
1054
c51f6a54
TT
10552018-07-22 Tom Tromey <tom@tromey.com>
1056
1057 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
1058 unused variable. Call value_fetch_lazy when needed.
1059 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
1060 Remove unused variable. Call value_fetch_lazy when needed.
1061
374fd1fd
TT
10622018-07-22 Tom Tromey <tom@tromey.com>
1063
1064 * m32c-tdep.c (mark_dma): Return void.
1065 (make_regs): Remove unused declarations.
1066
d5e9a511
TT
10672018-07-22 Tom Tromey <tom@tromey.com>
1068
1069 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
1070 cmdscm_get_valid_command_smob_arg_unsafe for effect.
1071 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
1072 bkscm_get_valid_block_smob_arg_unsafe for effect.
1073
996d693a
TT
10742018-07-22 Tom Tromey <tom@tromey.com>
1075
1076 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
1077 value_type.
1078
15766370
TT
10792018-07-22 Tom Tromey <tom@tromey.com>
1080
1081 * windows-nat.c (saved_context): Conditionally define.
1082 * remote.c (remote_target::remote_btrace_maybe_reopen):
1083 Conditionally declare "warned".
1084 * inflow.c (sigquit_ours): Conditionally define.
1085 (new_tty): Move "tty" declaration inside #if.
1086 * guile/guile.c (guile_datadir): Conditionally define.
1087 * charset.c (set_be_le_names): Move some declarations inside #if.
1088 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
1089 #if.
1090 (parse_xml_btrace_conf): Likewise.
1091
f4e80e13
TT
10922018-07-22 Tom Tromey <tom@tromey.com>
1093
1094 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
1095
8d49165d
TT
10962018-07-22 Tom Tromey <tom@tromey.com>
1097
1098 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
1099 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
1100 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
1101 * buildsym-legacy.c (get_macro_table): Remove unused variable.
1102 * stack.c (frame_apply_level_command): Remove unused variable.
1103 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
1104 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
1105 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
1106 unused variable.
1107 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
1108 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
1109 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
1110 variable.
1111 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
1112 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
1113 variable.
1114 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
1115 Remove unused variable.
1116 * cli/cli-script.c (recurse_read_control_structure): Remove unused
1117 variable.
1118 * common/tdesc.c (print_xml_feature::visit): Remove unused
1119 variable.
1120 * compile/compile-object-load.c (store_regs): Remove unused
1121 variables.
1122 * complaints.c (clear_complaints): Remove unused variable.
1123 * corelow.c (core_target_open): Remove unused variable.
1124 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
1125 variable.
1126 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
1127 variable.
1128 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
1129 variable.
1130 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
1131 variable.
1132 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
1133 variable.
1134 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
1135 variable.
1136 * ia64-tdep.c (examine_prologue): Remove unused variable.
1137 * infcall.c (run_inferior_call): Remove unused variable.
1138 * inferior.c (exit_inferior): Remove unused variable.
1139 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
1140 * linespec.c (decode_line_2): Remove unused variable.
1141 * linux-nat.c (super_close): Remove.
1142 * linux-tdep.c (linux_info_proc): Remove unused variable.
1143 * mi/mi-main.c (mi_execute_command): Remove unused variable.
1144 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
1145 Remove unused variable.
1146 * parse.c (find_minsym_type_and_address): Remove unused variable.
1147 * printcmd.c (info_symbol_command, printf_floating): Remove unused
1148 variable.
1149 * python/py-breakpoint.c (bppy_set_commands): Remove unused
1150 variable.
1151 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
1152 variables.
1153 * record-btrace.c (record_btrace_target::store_registers): Remove
1154 unused variable.
1155 (cmd_show_record_btrace_cpu): Remove unused variable.
1156 * riscv-tdep.c (riscv_register_reggroup_p)
1157 (riscv_push_dummy_call, riscv_return_value): Remove unused
1158 variable.
1159 * rust-exp.y (literal): Remove unused variable.
1160 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
1161 unused variable.
1162 <STRUCTOP_ANONYMOUS>: Likewise.
1163 * s390-linux-tdep.c (s390_linux_init_abi_31)
1164 (s390_linux_init_abi_64): Remove unused variable.
1165 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
1166 (file_select_thread, net_windows_open, _initialize_ser_windows):
1167 Remove unused variables.
1168 * symtab.c (find_pc_sect_line): Remove unused variable.
1169 * target-memory.c (compute_garbled_blocks): Remove unused
1170 variable.
1171 (target_write_memory_blocks): Remove unused variable.
1172 * target.c (target_stack::unpush): Remove unused variables.
1173 * tracepoint.c (start_tracing, all_tracepoint_actions)
1174 (merge_uploaded_trace_state_variables)
1175 (print_one_static_tracepoint_marker): Remove unused variable.
1176 * unittests/basic_string_view/element_access/char/1.cc (test01):
1177 Remove unused variable.
1178 * windows-nat.c (windows_continue, windows_add_all_dlls)
1179 (do_initial_windows_stuff, windows_nat_target::create_inferior):
1180 Remove unused variables.
1181
17cbafdb
SM
11822018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
1183
1184 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
1185 attr_profile in HAVE_ELF.
1186 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
1187 HAVE_ELF.
1188
0ee6c332
SM
11892018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
1190
1191 * frame.c (frame_register_unwind): Change parameter name.
1192 (frame_unwind_register): Likewise.
1193 (frame_unwind_register_value): Likewise.
1194 (frame_unwind_register_signed): Likewise.
1195 (frame_unwind_register_unsigned): Likewise.
1196 * frame.h (frame_register_unwind): Likewise.
1197 (frame_unwind_register): Likewise.
1198 (frame_unwind_register_value): Likewise.
1199 (frame_unwind_register_signed): Likewise.
1200 (frame_unwind_register_unsigned): Likewise.
1201 (frame_unwind_arch): Likewise.
1202
e2e31f10
MR
12032018-07-20 Maciej W. Rozycki <macro@mips.com>
1204
1205 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
1206 ISA maintenance.
1207
2d389915
MR
12082018-07-20 Maciej W. Rozycki <macro@mips.com>
1209
1210 * mips-linux-nat.c (mips_linux_nat_target::read_description):
1211 Call `get_ptrace_pid' rather than extracting the ptrace PID by
1212 hand.
1213
cbb09508
KS
12142018-07-20 Keith Seitz <keiths@redhat.com>
1215
1216 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
1217 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
1218 m_compunit_symtab, m_language>: Add "m_" prefix.
1219 Update all uses.
1220 * buildsym.c: Update all uses.
1221
bfe2e011
TT
12222018-07-20 Tom Tromey <tom@tromey.com>
1223
1224 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
1225 * buildsym.h (record_line_ftype): Remove typedef.
1226
0e6f3061
TT
12272018-07-20 Tom Tromey <tom@tromey.com>
1228
1229 * buildsym-legacy.h (augment_type_symtab): Don't declare.
1230 (end_expandable_symtab): Likewise.
1231 (end_symtab_get_static_block): Likewise.
1232 (end_symtab_from_static_block): Likewise.
1233 * buildsym-legacy.c (augment_type_symtab): Remove.
1234 (end_expandable_symtab): Remove.
1235 (end_symtab_get_static_block): Remove.
1236 (end_symtab_from_static_block): Remove.
1237
804d2729
TT
12382018-07-20 Tom Tromey <tom@tromey.com>
1239
1240 * dwarf2read.c: Include buildsym.h.
1241 (struct dwarf2_cu) <builder>: New method.
1242 (fixup_go_packaging): Update.
1243 (process_full_comp_unit, process_full_type_unit): Update. Don't
1244 use scoped_free_pendings.
1245 (using_directives): Add "cu" parameter, remove "language".
1246 (read_import_statement, setup_type_unit_groups, )
1247 (read_func_scope, read_lexical_block_scope)
1248 (dwarf2_record_block_ranges, read_namespace): Update.
1249 (lnp_state_machine::lnp_state_machine): Add cu parameter.
1250 (lnp_state_machine::handle_end_sequence): Update.
1251 (class lnp_state_machine) <m_cu>: New member.
1252 <m_record_line_callback>: Remove.
1253 <m_currently_recording_lines>: New member.
1254 (lnp_state_machine::handle_set_file): Update.
1255 (noop_record_line): Remove.
1256 (dwarf_record_line_p): Add cu parameter.
1257 (dwarf_record_line_1, dwarf_finish_line): Likewise.
1258 (lnp_state_machine::record_line)
1259 (lnp_state_machine::lnp_state_machine)
1260 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
1261 (dwarf_decode_lines): Update.
1262 (dwarf2_start_subfile): Add cu parameter.
1263 (dwarf2_start_symtab, new_symbol): Update.
1264 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
1265 Remove dwarf2_per_objfile parameter.
1266 (dwarf_decode_macros): Update.
1267
80e649fc
TT
12682018-07-20 Tom Tromey <tom@tromey.com>
1269
1270 * stabsread.c (define_symbol): Update.
1271 * buildsym-legacy.h (get_buildsym_compunit): Declare.
1272 * dwarf2read.c (new_symbol): Update.
1273 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
1274 * cp-namespace.c: Include buildsym.h.
1275 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
1276 * buildsym-legacy.c (get_buildsym_compunit): New function.
1277
0baae8db
TT
12782018-07-20 Tom Tromey <tom@tromey.com>
1279
1280 * xcoffread.c: Include buildsym-legacy.h.
1281 * windows-nat.c: Include buildsym-legacy.h.
1282 * stabsread.c: Include buildsym-legacy.h.
1283 * mdebugread.c: Include buildsym-legacy.h.
1284 * buildsym-legacy.h: New file.
1285 * buildsym-legacy.c: New file, from buildsym.c.
1286 * go32-nat.c: Include buildsym-legacy.h.
1287 * dwarf2read.c: Include buildsym-legacy.h.
1288 * dbxread.c: Include buildsym-legacy.h.
1289 * cp-namespace.c: Include buildsym-legacy.h.
1290 * coffread.c: Include buildsym-legacy.h.
1291 * buildsym.h: Move some contents to buildsym-legacy.h.
1292 * buildsym.c: Include buildsym-legacy.h. Move many functions to
1293 buildsym-legacy.c.
1294 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
1295
ab209f6f
TT
12962018-07-20 Tom Tromey <tom@tromey.com>
1297
1298 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
1299 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
1300 (buildsym_compunit::buildsym_compunit)
1301 (buildsym_compunit::~buildsym_compunit)
1302 (buildsym_compunit::get_macro_table): Define.
1303
74c72eac
TT
13042018-07-20 Tom Tromey <tom@tromey.com>
1305
1306 * buildsym.c (reset_symtab_globals): Remove.
1307 (buildsym_compunit::end_symtab_from_static_block): Update.
1308 (buildsym_compunit::augment_type_symtab): Update.
1309 (end_symtab_from_static_block): Call free_buildsym_compunit.
1310 (augment_type_symtab, end_symtab, end_expandable_symtab):
1311 Likewise.
1312
da6580e5
TT
13132018-07-20 Tom Tromey <tom@tromey.com>
1314
1315 * arch-utils.c: Do not include buildsym.h.
1316 * mipsread.c: Do not include buildsym.h.
1317 * machoread.c: Do not include buildsym.h.
1318 * elfread.c: Do not include buildsym.h.
1319
4a2125f5
TT
13202018-07-20 Tom Tromey <tom@tromey.com>
1321
1322 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
1323 initialization.
1324 (buildsym_compunit): Add new constructor.
1325 (struct buildsym_compunit) <get_last_source_file, finish_block,
1326 record_block_range, start_subfile, patch_subfile_names,
1327 push_subfile, pop_subfile, record_line, get_compunit_symtab,
1328 set_last_source_start_addr, get_last_source_start_addr,
1329 get_local_using_directives, set_local_using_directives,
1330 get_global_using_directives, outermost_context_p,
1331 get_current_context_stack, get_context_stack_depth,
1332 get_current_subfile, get_local_symbols, get_file_symbols,
1333 get_global_symbols, record_debugformat, record_producer,
1334 push_context, pop_context, end_symtab_get_static_block,
1335 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
1336 New public methods.
1337 <record_pending_block, finish_block_internal, make_blockvector,
1338 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
1339 private methods.
1340 Update all users.
1341
13422018-05-22 Tom Tromey <tom@tromey.com>
1343
1344 * buildsym.c (record_pending_block): Move earlier. Remove objfile
1345 parameter.
1346 (finish_block_internal): Update.
1347
6b213a47
TT
13482018-07-20 Tom Tromey <tom@tromey.com>
1349
1350 * buildsym.c (record_pending_block): Move earlier. Remove objfile
1351 parameter.
1352 (finish_block_internal): Update.
1353
b80a981d
TT
13542018-07-20 Tom Tromey <tom@tromey.com>
1355
1356 * buildsym.h (EXTERN): Don't define or undef.
1357 * buildsym.c (EXTERN): Don't define.
1358
ddb70602
TT
13592018-07-20 Tom Tromey <tom@tromey.com>
1360
1361 * buildsym.c: Remove TODO comment.
1362
b37dd3bc
TT
13632018-07-20 Tom Tromey <tom@tromey.com>
1364
1365 * coffread.c (coff_symtab_read): Update.
1366 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
1367 (xcoff_new_init): Update.
1368 * mipsread.c (mipscoff_new_init): Update.
1369 * mdebugread.c (mdebug_build_psymtabs): Update.
1370 * elfread.c (elf_new_init): Update.
1371 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
1372 Update.
1373 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
1374 (coffstab_build_psymtabs, elfstab_build_psymtabs)
1375 (stabsect_build_psymtabs): Update.
1376 * buildsym.h (buildsym_init): Don't declare.
1377 * buildsym.c: Update comment.
1378 (prepare_for_building): Remove.
1379 (start_symtab, restart_symtab): Update.
1380 (reset_symtab_globals): Update comment.
1381 (buildsym_init): Remove.
1382
e148f09d
TT
13832018-07-20 Tom Tromey <tom@tromey.com>
1384
1385 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
1386 * stabsread.c (patch_block_stabs, define_symbol, read_type)
1387 (read_enum_type, common_block_start, common_block_end)
1388 (cleanup_undefined_types_1, finish_global_stabs): Update.
1389 * mdebugread.c (psymtab_to_symtab_1): Update.
1390 * dwarf2read.c (fixup_go_packaging, read_func_scope)
1391 (read_lexical_block_scope, new_symbol): Update.
1392 * dbxread.c (process_one_symbol): Update.
1393 * coffread.c (coff_symtab_read, process_coff_symbol)
1394 (coff_read_enum_type): Update.
1395 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
1396 declare.
1397 (get_local_symbols, get_file_symbols, get_global_symbols): New
1398 functions.
1399 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
1400 m_global_symbols.
1401 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
1402 (~scoped_free_pendings): Update.
1403 (finish_block, prepare_for_building, reset_symtab_globals)
1404 (end_symtab_get_static_block, end_symtab_with_blockvector)
1405 (augment_type_symtab, push_context): Update.
1406 (get_local_symbols, get_file_symbols, get_global_symbols): New
1407 functions.
1408 (buildsym_init): Update.
1409
93b8bea4
TT
14102018-07-20 Tom Tromey <tom@tromey.com>
1411
1412 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
1413 (process_full_type_unit): Likewise.
1414 (dwarf2_start_symtab): Set list_in_scope.
1415
f62f6af5
TT
14162018-07-20 Tom Tromey <tom@tromey.com>
1417
1418 * dwarf2read.c (process_psymtab_comp_unit_reader)
1419 (build_type_psymtabs_reader): Do not set list_in_scope.
1420
1d376700
TT
14212018-07-20 Tom Tromey <tom@tromey.com>
1422
1423 * buildsym.c (free_pendings): Remove.
1424 (add_symbol_to_list, scoped_free_pendings)
1425 (finish_block_internal, buildsym_init): Update.
1426
c233e9c6
TT
14272018-07-20 Tom Tromey <tom@tromey.com>
1428
1429 * xcoffread.c (read_xcoff_symtab): Update.
1430 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
1431 Update.
1432 * dbxread.c (process_one_symbol): Update.
1433 * coffread.c (coff_symtab_read): Update.
1434 * buildsym.h (finish_block): Update.
1435 * buildsym.c (finish_block): Remove "listhead" argument.
1436 (end_symtab_get_static_block): Update.
1437
5ac04550
TT
14382018-07-20 Tom Tromey <tom@tromey.com>
1439
1440 * buildsym.h (class scoped_free_pendings): Remove constructor.
1441 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
1442 method.
1443 <m_pending_block_obstack, m_pending_blocks>: New members.
1444 (pending_block_obstack, pending_blocks): Remove.
1445 (scoped_free_pendings::scoped_free_pendings): Default.
1446 (~scoped_free_pendings): Update.
1447 (free_pending_blocks): Remove.
1448 (finish_block_internal, record_pending_block, make_blockvector)
1449 (end_symtab_get_static_block, augment_type_symtab, push_context)
1450 (buildsym_init): Update.
1451
7ea05a7b
TT
14522018-07-20 Tom Tromey <tom@tromey.com>
1453
1454 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
1455 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
1456 members.
1457 (pending_addrmap, pending_addrmap_obstack)
1458 (pending_addrmap_interesting): Remove.
1459 (scoped_free_pendings, record_block_range, make_blockvector)
1460 (prepare_for_building, reset_symtab_globals, buildsym_init):
1461 Update.
1462
3c65e5b3
TT
14632018-07-20 Tom Tromey <tom@tromey.com>
1464
1465 * xcoffread.c (process_linenos): Update.
1466 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
1467 * mdebugread.c (psymtab_to_symtab_1): Update.
1468 * dwarf2read.c (setup_type_unit_groups)
1469 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
1470 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
1471 * dbxread.c (process_one_symbol): Update.
1472 * coffread.c (coff_symtab_read, enter_linenos)
1473 (process_coff_symbol): Update.
1474 * buildsym.h (current_subfile): Don't declare.
1475 (get_current_subfile): Declare.
1476 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
1477 member.
1478 (start_subfile, free_buildsym_compunit, push_subfile)
1479 (prepare_for_building, start_symtab): Update.
1480 (get_current_subfile): New function.
1481
a60f3166
TT
14822018-07-20 Tom Tromey <tom@tromey.com>
1483
1484 * coffread.c (coff_symtab_read): Update.
1485 * xcoffread.c (read_xcoff_symtab): Update.
1486 * dwarf2read.c (new_symbol): Update.
1487 (read_func_scope, read_lexical_block_scope): Update.
1488 * dbxread.c (process_one_symbol): Update.
1489 * buildsym.h (context_stack, context_stack_depth): Don't declare.
1490 (outermost_context_p): Remove macro.
1491 (outermost_context_p, get_current_context_stack)
1492 (get_context_stack_depth): Declare.
1493 (pop_context): Return struct context_stack.
1494 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
1495 member.
1496 (context_stack_size): Remove.
1497 (INITIAL_CONTEXT_STACK_SIZE): Remove.
1498 (prepare_for_building, end_symtab_get_static_block)
1499 (augment_type_symtab, push_context): Update.
1500 (pop_context): Return struct context_stack.
1501 (outermost_context_p, get_current_context_stack)
1502 (get_context_stack_depth): New functions.
1503 (buildsym_init): Update.
1504
56ba65a0
TT
15052018-07-20 Tom Tromey <tom@tromey.com>
1506
1507 * rust-exp.y: Now a pure parser. Update all rules.
1508 (%union): Move earlier.
1509 (current_parser, work_obstack): Remove globals.
1510 (rust_parser, ~rust_parser): Update.
1511 (class rust_parser) <copy_name, concat3, crate_name, super_name,
1512 lex_character, lex_number, lex_string, lex_identifier,
1513 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
1514 convert_name, convert_params_to_expression,
1515 convert_ast_to_expression, ast_basic_type, ast_operation,
1516 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
1517 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
1518 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
1519 ast_array_type, ast_slice_type, ast_reference_type,
1520 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
1521 (rust_parse): Update.
1522 (rustyyerror, rustyylex): Add parser parameter.
1523 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
1524 (rust_lex_stringish_test, rust_lex_test_sequence)
1525 (rust_lex_test_trailing_dot, rust_lex_test_completion)
1526 (rust_lex_test_push_back, rust_lex_tests): Update.
1527
4c693332
PA
15282018-07-19 Pedro Alves <palves@redhat.com>
1529
1530 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
1531 gdb::unique_xmalloc_ptr.
1532 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
1533 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
1534 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
1535 copy-initialization.
1536 * guile/scm-pretty-print.c (ppscm_print_children): Use
1537 gdb::unique_xmalloc_ptr instead of cleanups.
1538 (gdbscm_apply_val_pretty_printer): Remove cleanups.
1539 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
1540 gdb::unique_xmalloc_ptr.
1541 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1542 Adjust to use gdb::unique_xmalloc_ptr.
1543 * guile/scm-utils.c (extract_arg): Adjust.
1544 * guile/scm-value.c (gdbscm_value_field): Adjust to use
1545 gdb::unique_xmalloc_ptr instead of a cleanup.
1546
4581dc82
TT
15472018-07-19 Tom Tromey <tom@tromey.com>
1548
1549 * utils.c (do_value_free_to_mark)
1550 (make_cleanup_value_free_to_mark): Remove.
1551 * utils.h (make_cleanup_value_free_to_mark): Remove.
1552
43cc6c3a
PA
15532018-07-19 Pedro Alves <palves@redhat.com>
1554
1555 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
1556 forwarding reference.
1557
3a5f2a48
PA
15582018-07-18 Pedro Alves <palves@redhat.com>
1559
1560 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
1561 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
1562 cleanup.
1563
557e56be
PA
15642018-07-18 Pedro Alves <palves@redhat.com>
1565
1566 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
1567 exceptions.
1568 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
1569 (gdbscm_wrap): New.
1570 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
1571 directly instead of a cleanup.
1572 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
1573 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
1574 (vlscm_binop_gdbthrow): New, factored out from ...
1575 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
1576 (vlscm_rich_compare): Use gdbscm_wrap.
1577 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
1578 instead of a cleanup.
1579 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
1580 cleanup.
1581 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1582 Use xfree directly instead of a cleanup.
1583 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
1584 Adjust to use gdbscm_wrap and scoped_value_mark.
1585 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
1586 (gdbscm_value_address, gdbscm_value_dereference)
1587 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
1588 scoped_value_mark.
1589 (gdbscm_value_dynamic_type): Use scoped_value_mark.
1590 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
1591 scoped_value_mark.
1592 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
1593 gdbscm_wrap and scoped_value_mark.
1594 (gdbscm_value_to_string): Use xfree directly instead of a
1595 cleanup. Move 'buffer' unique_ptr to TRY scope.
1596 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
1597 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
1598 scoped_value_mark.
1599 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
1600 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
1601 scoped_value_mark.
1602 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
1603 gdbscm_wrap.
1604
42dc7699
TV
16052018-07-18 Tom de Vries <tdevries@suse.de>
1606
1607 * findvar.c (default_read_var_value): Also resolve dynamic type for
1608 LOC_OPTIMIZED_OUT vars.
1609
6592ceed
MR
16102018-07-18 Maciej W. Rozycki <macro@mips.com>
1611
1612 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
1613 decoding.
1614
c6c6149a
TT
16152018-07-17 Tom Tromey <tom@tromey.com>
1616
1617 * guile/scm-param.c (pascm_set_func, pascm_show_func)
1618 (compute_enum_list, pascm_set_param_value_x)
1619 (gdbscm_parameter_value): Update.
1620 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
1621 (gdbscm_scm_to_host_string): Update.
1622 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
1623 Update.
1624 * guile/scm-cmd.c (cmdscm_add_completion): Update.
1625 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
1626 * guile/scm-string.c (gdbscm_scm_to_string): Return
1627 unique_xmalloc_ptr.
1628 (gdbscm_scm_to_host_string): Likewise.
1629
a1a31cb8
TT
16302018-07-17 Tom Tromey <tom@tromey.com>
1631
1632 * guile/guile.c (gdbscm_eval_from_control_command): Update.
1633 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
1634 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
1635 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
1636 unique_xmalloc_ptr.
1637
15bf3002
TT
16382018-07-17 Tom Tromey <tom@tromey.com>
1639
1640 * guile/scm-param.c (pascm_signal_setshow_error): Update.
1641 * guile/guile-internal.h (gdbscm_exception_message_to_string):
1642 Update.
1643 * guile/scm-cmd.c (cmdscm_function): Update.
1644 * guile/scm-pretty-print.c
1645 (ppscm_print_exception_unless_memory_error): Update.
1646 * guile/scm-exception.c (gdbscm_exception_message_to_string):
1647 Return unique_xmalloc_ptr.
1648
7eb1a66c
TT
16492018-07-17 Tom Tromey <tom@tromey.com>
1650
1651 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
1652 Use string_printf.
1653
ce73f310
JW
16542018-07-17 Jim Wilson <jimw@sifive.com>
1655
27724bad
JW
1656 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
1657 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
1658 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
1659 unecessary braces after EF_RISCV_RVC test. Delete call to
1660 set_gdbarch_decr_pc_after_break.
1661
ce73f310
JW
1662 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
1663 RISCV_LAST_FP_REGNUM + 1.
1664 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
1665
056dec39
TT
16662018-07-17 Tom Tromey <tom@tromey.com>
1667
1668 * configure.ac: Remove --disable-gdbcli.
1669 * configure: Rebuild.
1670 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
1671 (SUBDIR_CLI_CFLAGS): Remove.
1672 (SFILES): Use SUBDIR_CLI_SRCS.
1673 (COMMON_OBS): Use SUBDIR_CLI_OBS.
1674
4735f0ed
TT
16752018-07-17 Tom Tromey <tom@tromey.com>
1676
1677 PR gdb/18624:
1678 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
1679
117a0e99
JW
16802018-07-16 Jim Wilson <jimw@sifive.com>
1681
1682 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
1683
8a67aaa8
SM
16842018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1685
1686 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
1687 variable.
1688 (libunwind_frame_sniffer): Likewise.
1689 (libunwind_frame_prev_register): Likewise.
1690 (libunwind_sigtramp_frame_sniffer): Likewise.
1691 * ia64-tdep.c (ia64_access_reg): Likewise.
1692 (ia64_access_rse_reg): Likewise.
1693 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
1694 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
1695
ec74dcd8
SM
16962018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1697
1698 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
1699
a700e753
SM
17002018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1701
1702 * remote-sim.c (gdbsim_target::close,
1703 gdbsim_target::mourn_inferior): Remove unused variables.
1704
8b411ff8
SM
17052018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
1706
1707 * ia64-tdep.c (ktab_buf): New global.
1708 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
1709 (get_kernel_table): Adjust.
1710
edb0470b
TT
17112018-07-16 Tom Tromey <tom@tromey.com>
1712
1713 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
1714 * dwarf2read.c (using_directives, new_symbol): Use
1715 outermost_context_p.
1716 * dbxread.c (process_one_symbol): Use outermost_context_p.
1717 * coffread.c (coff_symtab_read): Use outermost_context_p.
1718
6cccc9a8
TT
17192018-07-16 Tom Tromey <tom@tromey.com>
1720
1721 * dwarf2read.c (using_directives, read_func_scope)
1722 (read_lexical_block_scope): Update.
1723 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1724 * buildsym.h (local_using_directives, global_using_directives):
1725 Don't declare.
1726 (get_local_using_directives, set_local_using_directives)
1727 (get_global_using_directives): Declare.
1728 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
1729 m_global_using_directives>: New members.
1730 (finish_block_internal, prepare_for_building)
1731 (reset_symtab_globals, end_symtab_get_static_block)
1732 (push_context): Update.
1733 (get_local_using_directives, set_local_using_directives)
1734 (get_global_using_directives): New functions.
1735 (buildsym_init): Update.
1736
652788a7
TT
17372018-07-16 Tom Tromey <tom@tromey.com>
1738
1739 * xcoffread.c (xcoff_initial_scan): Don't call
1740 free_pending_blocks.
1741 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
1742 * buildsym.h (class scoped_free_pendings): Add constructor.
1743 (free_pending_blocks): Don't declare.
1744 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
1745 (free_pending_blocks): Now static.
1746
8419ee53
TT
17472018-07-16 Tom Tromey <tom@tromey.com>
1748
1749 * buildsym.h (push_subfile, pop_subfile): Update declarations.
1750 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
1751 member.
1752 (struct subfile_stack): Remove.
1753 (subfile_stack): Remove.
1754 (push_subfile, pop_subfile, buildsym_init): Update.
1755
ccdac490
TT
17562018-07-16 Tom Tromey <tom@tromey.com>
1757
1758 * buildsym.c (push_subfile): Use gdb_assert.
1759 (pop_subfile): Use gdb_assert.
1760
43130d6f
TT
17612018-07-16 Tom Tromey <tom@tromey.com>
1762
1763 * buildsym.h (merge_symbol_lists): Remove.
1764 * buildsym.c (merge_symbol_lists): Remove.
1765
77d6f1aa
TT
17662018-07-16 Tom Tromey <tom@tromey.com>
1767
1768 * stabsread.c (scan_file_globals): Update comment.
1769 * stabsread.h (scan_file_globals): Move from buildsym.h.
1770 * buildsym.h (scan_file_globals): Move to stabsread.h.
1771
2c722d18
TT
17722018-07-16 Tom Tromey <tom@tromey.com>
1773
1774 * xcoffread.c (xcoff_new_init): Update.
1775 * mipsread.c (mipscoff_new_init): Update.
1776 * mdebugread.c (mdebug_build_psymtabs): Update.
1777 * elfread.c (elf_new_init): Update.
1778 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
1779 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
1780 * buildsym.h (buildsym_new_init): Don't declare.
1781 * buildsym.c (buildsym_new_init): Remove.
1782
5985ac61
TT
17832018-07-16 Tom Tromey <tom@tromey.com>
1784
1785 * stabsread.h (within_function): Move from buildsym.h.
1786 * stabsread.c (start_stabs): Clear within_function.
1787 * coffread.c (coff_start_symtab): Clear within_function.
1788 * buildsym.h (within_function): Move to stabsread.h.
1789 * buildsym.c (prepare_for_building): Update.
1790
6b84eeb2
TT
17912018-07-16 Tom Tromey <tom@tromey.com>
1792
1793 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
1794 * dwarf2read.c (dwarf2_start_symtab): Don't set
1795 processing_gcc_compilation.
1796 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
1797
2150c3ef
TT
17982018-07-16 Tom Tromey <tom@tromey.com>
1799
1800 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
1801 (next_symbol_text_func): Move from buildsym.h.
1802 * stabsread.c (hashname): Move from buildsym.c.
1803 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
1804 (next_symbol_text_func, hashname): Move to stabsread.h.
1805 * buildsym.c: Don't include bcache.h
1806 (hashname): Move to stasbread.c.
1807
0ec44fc0
TT
18082018-07-16 Tom Tromey <tom@tromey.com>
1809
1810 * buildsym.h (context_stack_size): Don't declare.
1811 * buildsym.c (context_stack_size): New global.
1812
81cc346d
TT
18132018-07-16 Tom Tromey <tom@tromey.com>
1814
1815 * dbxread.c (processing_acc_compilation): New global.
1816 * buildsym.h (processing_acc_compilation): Don't declare.
1817
2c99ee5c
TT
18182018-07-16 Tom Tromey <tom@tromey.com>
1819
1820 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
1821 * dbxread.c (read_ofile_symtab): Update.
1822 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
1823 * buildsym.h (last_source_start_addr): Remove.
1824 (set_last_source_start_addr, get_last_source_start_addr):
1825 Declare.
1826 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
1827 parameter.
1828 (struct buildsym_compunit) <m_last_source_start_addr>: New
1829 member.
1830 (prepare_for_building): Remove start_addr parameter.
1831 (start_symtab, restart_symtab, end_symtab_get_static_block)
1832 (end_symtab_with_blockvector): Update.
1833 (set_last_source_start_addr, get_last_source_start_addr): New
1834 functions.
1835
530fedbc
TT
18362018-07-16 Tom Tromey <tom@tromey.com>
1837
1838 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
1839 member.
1840 (have_line_numbers): Remove.
1841 (record_line, prepare_for_building, end_symtab_get_static_block)
1842 (augment_type_symtab): Update.
1843
6a976300
TT
18442018-07-16 Tom Tromey <tom@tromey.com>
1845
1846 * buildsym.c (~buildsym_compunit): Free the macro table.
1847 (struct buildsym_compunit) <get_macro_table, release_macros>: New
1848 methods.
1849 <m_pending_macros>: New member.
1850 (pending_macros): Remove.
1851 (~scoped_free_pendings, get_macro_table, prepare_for_building)
1852 (reset_symtab_globals, end_symtab_get_static_block)
1853 (end_symtab_with_blockvector, augment_type_symtab)
1854 (buildsym_init): Update.
1855
c0015d44
TT
18562018-07-16 Tom Tromey <tom@tromey.com>
1857
1858 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
1859 parameter.
1860 (buildsym_compunit::set_last_source_file): New method.
1861 <m_last_source_file>: New member.
1862 (prepare_for_building): Remove "name" parameter.
1863 (start_symtab, restart_symtab, reset_symtab_globals): Update.
1864 (last_source_file): Remove.
1865 (set_last_source_file, get_last_source_file): Update.
1866
e62cca7c
TT
18672018-07-16 Tom Tromey <tom@tromey.com>
1868
1869 * buildsym.c (prepare_for_building): Add assert.
1870
905eb0e2
TT
18712018-07-16 Tom Tromey <tom@tromey.com>
1872
1873 * buildsym.c (~buildsym_compunit): Update.
1874 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
1875 (start_subfile, patch_subfile_names)
1876 (end_symtab_with_blockvector): Update.
1877
b248663f
TT
18782018-07-16 Tom Tromey <tom@tromey.com>
1879
1880 * buildsym.c (struct buildsym_compunit): Add constructor,
1881 destructor, initializers.
1882 (start_buildsym_compunit): Remove.
1883 (free_buildsym_compunit): Use "delete".
1884 (start_symtab, restart_symtab): Use "new".
1885
ff27d073
SM
18862018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
1887
1888 * symfile.c (set_objfile_default_section_offset): Remove struct
1889 keyword.
1890
6a15ecf5
SH
18912018-07-14 Stafford Horne <shorne@gmail.com>
1892
1893 * (Responsible Maintainers): Add myself as or1k maintainer.
1894
027a4c30
TT
18952018-07-13 Tom Tromey <tom@tromey.com>
1896
1897 * symfile.c (set_objfile_default_section_offset): Use extra braces
1898 around initializer.
1899
5c1eda30
AA
19002018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
1901
1902 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
1903 non-branching basr.
1904
bc7b042b
PW
19052018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1906
1907 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1908 unittests/cli-utils-selftests.c
1909 * unittests/cli-utils-selftests.c: New file.
1910
a14c4daa
PW
19112018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1912
1913 * NEWS: Mention new commands. Mention change to 'thread apply'.
1914
1fe75df7
PW
19152018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1916
1917 * thread.c (thr_try_catch_cmd): New function.
1918 (thread_apply_all_command): Handle qcs flags.
1919 (thread_apply_command): Handle qcs flags.
1920 (taas_command): New function.
1921 (tfaas_command): New function.
1922 (_initialize_thread): Update to setup the new commands 'taas
1923 and 'tfaas'. Change doc string for 'thread apply'.
1924
6a70eb7d
PW
19252018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1926
1927 * stack.c: (trailing_outermost_frame): New function, mostly
1928 extracted from backtrace_command_1.
1929 (leading_innermost_frame): New function.
1930 (backtrace_command_1): Update to call trailing_outermost_frame.
1931 (frame_apply_command_count): New function.
1932 (frame_apply_level_command): New function.
1933 (frame_apply_all_command): New function.
1934 (frame_apply_command): New function.
1935 (faas_command): New function.
1936 (frame_cmd_list): New variable.
1937 (_initialize_stack): Update to setup the new commands 'frame apply'
1938 and 'faas'.
1939
529c08b2
PW
19402018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1941
1942 * cli-utils.c (number_or_range_parser::get_number): Only handle
1943 numbers or convenience var as numbers.
1944 (parse_flags): New function.
1945 (parse_flags_qcs): New function.
1946 (number_or_range_parser::finished): Ensure parsing end is detected
1947 before end of string.
1948 * cli-utils.h (parse_flags): New function.
1949 (parse_flags_qcs): New function.
1950 (number_or_range_parser): Remove m_finished bool.
1951 (number_or_range_parser::skip_range): Set m_in_range to false.
1952
64b58472
SDJ
19532018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
1954
1955 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
1956 on Windows.
1957
c7ab0aef
SDJ
19582018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1959 Jan Kratochvil <jan.kratochvil@redhat.com>
1960 Paul Fertser <fercerpav@gmail.com>
1961 Tsutomu Seki <sekiriki@gmail.com>
1962 Pedro Alves <palves@redhat.com>
1963
1964 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1965 'unittests/parse-connection-spec-selftests.c'.
1966 (COMMON_SFILES): Add 'common/netstuff.c'.
1967 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
1968 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
1969 * common/netstuff.c: New file.
1970 * common/netstuff.h: New file.
1971 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
1972 (wait_for_connect): Update comment. New parameter
1973 'gdb::optional<int> sock' instead of 'struct serial *scb'.
1974 Use 'sock' directly instead of 'scb->fd'.
1975 (try_connect): New function, with code from 'net_open'.
1976 (net_open): Rewrite main loop to deal with multiple
1977 sockets/addresses. Handle IPv6-style hostnames; implement
1978 support for IPv6 connections.
1979 * unittests/parse-connection-spec-selftests.c: New file.
1980
4c7333b3
PA
19812018-07-11 Pedro Alves <palves@redhat.com>
1982
1983 PR gdb/23377
1984 * remote.c (remote_target::remote_detach_pid): Call
1985 set_current_process.
1986
a6f88f6e
PA
19872018-07-11 Pedro Alves <palves@redhat.com>
1988
1989 * h8300-tdep.c (h8300_gdbarch_init): Remove
1990 set_gdbarch_ecoff_reg_to_regnum calls.
1991
16ff70dd
SDJ
19922018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1993
1994 PR c++/23373
1995 * c-typeprint.c (c_type_print_base_struct_union): Don't print
1996 offsets/sizes for static members of a class/struct.
1997
12863263
AH
19982018-07-11 Alan Hayward <alan.hayward@arm.com>
1999
2000 * target-descriptions.c (tdesc_register_bitsize): Rename.
2001 * target-descriptions.h (tdesc_register_bitsize): Likewise.
2002 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
2003 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
2004
1123588c
TT
20052018-07-10 Tom Tromey <tom@tromey.com>
2006
2007 * breakpoint.c (moribund_locations): Now static and a
2008 std::vector.
2009 (breakpoint_init_inferior, moribund_breakpoint_here_p)
2010 (build_bpstat_chain, update_global_location_list)
2011 (breakpoint_retire_moribund): Update.
2012 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
2013 VEC.
2014
8c49aa89
AB
20152018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
2016
2017 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
2018 (riscv_register_reggroup_p): Use new function, remove unneeded
2019 parenthesis.
2020 (riscv_push_dummy_call): Extend assert to compare against xlen or
2021 flen based on register type.
2022
42ecac17
AB
20232018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
2024
2025 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
2026
055303e2
AB
20272018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
2028
2029 * remote.c (show_hardware_watchpoint_limit): New function.
2030 (show_hardware_watchpoint_length_limit): New function.
2031 (show_hardware_breakpoint_limit): New function.
2032 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
2033 where appropriate, update help text.
2034
8fd32c1c
TT
20352018-07-09 Tom Tromey <tom@tromey.com>
2036
2037 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
2038 (CLIBS): Don't mention NAT_CLIBS.
2039
31278b51
TT
20402018-07-09 Tom Tromey <tom@tromey.com>
2041
2042 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
2043 (LIBGDB_OBS, clean mostlyclean): Update.
2044 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
2045
e5fd1493
TT
20462018-07-09 Tom Tromey <tom@tromey.com>
2047
2048 * Makefile.in (%.c: %.y): Use ECHO_YACC.
2049 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
2050 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
2051
981e0c0c
TT
20522018-07-09 Tom Tromey <tom@tromey.com>
2053
2054 * Makefile.in (ALLDEPFILES): Remove exec.c.
2055 (COMMON_OBS): Remove exec.o.
2056 (COMMON_SFILES): Add exec.c.
2057
14ccceb2
TT
20582018-07-09 Tom Tromey <tom@tromey.com>
2059
2060 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
2061
5d3c3a68
TT
20622018-07-09 Tom Tromey <tom@tromey.com>
2063
2064 * Makefile.in (clean mostlyclean): Remove stamp-version.
2065 (version.c): Depend on stamp-version.
2066 (stamp-version): New rule, from version.c rule.
2067
1998086d
TT
20682018-07-09 Tom Tromey <tom@tromey.com>
2069
2070 * Makefile.in (init.c): Depend on stamp-init.
2071 (stamp-init): New rule, from init.c rule.
2072 (clean mostlyclean): Remove stamp-init.
2073
4c754949
TT
20742018-07-09 Tom Tromey <tom@tromey.com>
2075
2076 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
2077 SUBDIR_GCC_COMPILE_SRCS.
2078
6497f1dd
TT
20792018-07-09 Tom Tromey <tom@tromey.com>
2080
2081 * Makefile.in (init.c): Remove some unused sed rules.
2082
97a34db9
TT
20832018-07-09 Tom Tromey <tom@tromey.com>
2084
2085 * Makefile.in (TSOBS): Remove.
2086 (INIT_FILES): Update.
2087 (LIBGDB_OBS): Update.
2088 (COMMON_SFILES): Add inflow.c.
2089 (SFILES): Remove inflow.c.
2090
25289ac1
JK
20912018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
2092
2093 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
2094
e83f4d97
SM
20952018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
2096
4869c585
SM
2097 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
2098 get_saveloc_name, is_signal_frame_name, step_name,
2099 init_remote_name, create_addr_space_name,
2100 destroy_addr_space_name, search_unwind_table_name,
2101 find_dyn_list_name): Constify.
e83f4d97 2102
6821842f
SM
21032018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
2104
2105 * darwin-nat.c (darwin_pthread_kill): New function.
2106 (darwin_resume_thread): Use darwin_pthread_kill.
2107
c530603c
TV
21082018-07-05 Tom de Vries <tdevries@suse.de>
2109
2110 * macroexp.c (macro_buffer) <operator=>: New member function.
2111
a7d0f0f0
TT
21122018-07-04 Tom Tromey <tom@tromey.com>
2113
2114 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
2115
6242c6a6
SM
21162018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
2117
2118 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
2119 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
2120 * maint.c: Likewise.
2121 * top.c: Likewise.
2122
4e5b2f89
JB
21232018-07-04 Joel Brobecker <brobecker@adacore.com>
2124
2125 * NEWS: Create a new section for the next release branch.
2126 Rename the section of the current branch, now that it has
2127 been cut.
2128
538ccc4a
JB
21292018-07-04 Joel Brobecker <brobecker@adacore.com>
2130
2131 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
2132 * version.in: Bump version to 8.2.50.DATE-git.
2133
1b919490
VB
21342018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
2135 Pedro Alves <palves@redhat.com>
2136
2137 * linux-nat.c (linux_init_ptrace): Rename to ...
2138 (linux_init_ptrace_procfs): ... this. Call
2139 linux_proc_init_warnings.
2140 (linux_nat_target::post_attach)
2141 (linux_nat_target::post_startup_inferior): Adjust.
2142 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
2143 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
2144
1ea5da02
TV
21452018-07-04 Tom de Vries <tdevries@suse.de>
2146
2147 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
2148 check ...
2149 (read_comp_unit_head): ... here.
2150
f51e0e20
TT
21512018-07-03 Tom Tromey <tom@tromey.com>
2152
2153 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
2154 (stop_tracing, tstatus_command)
2155 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
2156 (print_one_static_tracepoint_marker): Update.
2157 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
2158 std::vector.
2159 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
2160 VEC.
2161 (all_tracepoints, static_tracepoints_here): Return std::vector.
2162
d7e15655
TT
21632018-07-03 Tom Tromey <tom@tromey.com>
2164
2165 * common/ptid.c (ptid_equal): Remove.
2166 * common/ptid.h (ptid_equal): Don't declare.
2167 * ada-tasks.c: Update.
2168 * breakpoint.c: Update.
2169 * common/agent.c: Update.
2170 * corelow.c: Update.
2171 * darwin-nat-info.c: Update.
2172 * darwin-nat.c: Update.
2173 * dcache.c: Update.
2174 * dtrace-probe.c: Update.
2175 * dummy-frame.c: Update.
2176 * fbsd-nat.c: Update.
2177 * frame.c: Update.
2178 * gdbthread.h: Update.
2179 * gnu-nat.c: Update.
2180 * go32-nat.c: Update.
2181 * inf-loop.c: Update.
2182 * inf-ptrace.c: Update.
2183 * infcall.c: Update.
2184 * infcmd.c: Update.
2185 * inflow.c: Update.
2186 * infrun.c: Update.
2187 * linux-fork.c: Update.
2188 * linux-nat.c: Update.
2189 * linux-thread-db.c: Update.
2190 * mi/mi-cmd-var.c: Update.
2191 * mi/mi-interp.c: Update.
2192 * mi/mi-main.c: Update.
2193 * nto-procfs.c: Update.
2194 * ppc-linux-tdep.c: Update.
2195 * procfs.c: Update.
2196 * python/py-inferior.c: Update.
2197 * python/py-record-btrace.c: Update.
2198 * python/py-record.c: Update.
2199 * ravenscar-thread.c: Update.
2200 * regcache.c: Update.
2201 * remote-sim.c: Update.
2202 * remote.c: Update.
2203 * sol-thread.c: Update.
2204 * solib.c: Update.
2205 * target.c: Update.
2206 * tui/tui-stack.c: Update.
2207 * varobj.c: Update.
2208 * windows-nat.c: Update.
2209 * windows-tdep.c: Update.
2210
26a57c92
TT
22112018-07-03 Tom Tromey <tom@tromey.com>
2212
2213 * common/ptid.c (ptid_match): Remove.
2214 * common/ptid.h (ptid_match): Don't declare.
2215 * fbsd-nat.c: Update.
2216 * infcmd.c: Update.
2217 * infrun.c: Update.
2218 * linux-nat.c: Update.
2219 * record-btrace.c: Update.
2220 * regcache.c: Update.
2221 * remote.c: Update.
2222
d2a107e3
TT
22232018-07-03 Tom Tromey <tom@tromey.com>
2224
2225 * common/ptid.c (ptid_tid_p): Remove.
2226 * common/ptid.h (ptid_tid_p): Don't declare.
2227 * sol-thread.c: Update.
2228
15a9e13e
TT
22292018-07-03 Tom Tromey <tom@tromey.com>
2230
2231 * common/ptid.c (ptid_lwp_p): Remove.
2232 * common/ptid.h (ptid_lwp_p): Don't declare.
2233 * fbsd-nat.c: Update.
2234 * linux-nat.c: Update.
2235 * nat/linux-procfs.c: Update.
2236 * nat/x86-linux-dregs.c: Update.
2237 * sol-thread.c: Update.
2238
0e998d96
TT
22392018-07-03 Tom Tromey <tom@tromey.com>
2240
2241 * common/ptid.c (ptid_is_pid): Remove.
2242 * common/ptid.h (ptid_is_pid): Don't declare.
2243 * infrun.c: Update.
2244 * linux-nat.c: Update.
2245 * mi/mi-interp.c: Update.
2246 * remote.c: Update.
2247 * thread.c: Update.
2248
cc6bcb54
TT
22492018-07-03 Tom Tromey <tom@tromey.com>
2250
2251 * common/ptid.c (ptid_get_tid): Remove.
2252 * common/ptid.h (ptid_get_tid): Don't declare.
2253 * ada-tasks.c: Update.
2254 * aix-thread.c: Update.
2255 * bsd-uthread.c: Update.
2256 * darwin-nat.c: Update.
2257 * fbsd-nat.c: Update.
2258 * i386-darwin-nat.c: Update.
2259 * infrun.c: Update.
2260 * linux-tdep.c: Update.
2261 * nto-procfs.c: Update.
2262 * ppc-ravenscar-thread.c: Update.
2263 * python/py-infthread.c: Update.
2264 * ravenscar-thread.c: Update.
2265 * sol-thread.c: Update.
2266 * sparc-ravenscar-thread.c: Update.
2267 * windows-nat.c: Update.
2268
e38504b3
TT
22692018-07-03 Tom Tromey <tom@tromey.com>
2270
2271 * common/ptid.c (ptid_get_lwp): Remove.
2272 * common/ptid.h (ptid_get_lwp): Don't declare.
2273 * aarch64-linux-nat.c: Update.
2274 * ada-tasks.c: Update.
2275 * aix-thread.c: Update.
2276 * amd64-linux-nat.c: Update.
2277 * arm-linux-nat.c: Update.
2278 * corelow.c: Update.
2279 * fbsd-nat.c: Update.
2280 * fbsd-tdep.c: Update.
2281 * gnu-nat.c: Update.
2282 * i386-cygwin-tdep.c: Update.
2283 * i386-gnu-nat.c: Update.
2284 * i386-linux-nat.c: Update.
2285 * ia64-linux-nat.c: Update.
2286 * inf-ptrace.c: Update.
2287 * infrun.c: Update.
2288 * linux-fork.c: Update.
2289 * linux-nat.c: Update.
2290 * linux-tdep.c: Update.
2291 * linux-thread-db.c: Update.
2292 * mips-linux-nat.c: Update.
2293 * nat/aarch64-linux-hw-point.c: Update.
2294 * nat/aarch64-linux.c: Update.
2295 * nat/linux-btrace.c: Update.
2296 * nat/linux-osdata.c: Update.
2297 * nat/linux-procfs.c: Update.
2298 * nat/x86-linux-dregs.c: Update.
2299 * obsd-nat.c: Update.
2300 * ppc-fbsd-nat.c: Update.
2301 * ppc-linux-nat.c: Update.
2302 * procfs.c: Update.
2303 * python/py-infthread.c: Update.
2304 * ravenscar-thread.c: Update.
2305 * remote.c: Update.
2306 * s390-linux-nat.c: Update.
2307 * sol-thread.c: Update.
2308 * sol2-tdep.c: Update.
2309 * spu-linux-nat.c: Update.
2310 * x86-linux-nat.c: Update.
2311 * xtensa-linux-nat.c: Update.
2312
e99b03dc
TT
23132018-07-03 Tom Tromey <tom@tromey.com>
2314
2315 * common/ptid.c (ptid_get_pid): Remove.
2316 * common/ptid.h (ptid_get_pid): Don't declare.
2317 * aarch64-linux-nat.c: Update.
2318 * ada-lang.c: Update.
2319 * aix-thread.c: Update.
2320 * alpha-bsd-nat.c: Update.
2321 * amd64-fbsd-nat.c: Update.
2322 * amd64-linux-nat.c: Update.
2323 * arm-linux-nat.c: Update.
2324 * arm-nbsd-nat.c: Update.
2325 * auxv.c: Update.
2326 * break-catch-syscall.c: Update.
2327 * breakpoint.c: Update.
2328 * bsd-uthread.c: Update.
2329 * corelow.c: Update.
2330 * ctf.c: Update.
2331 * darwin-nat.c: Update.
2332 * fbsd-nat.c: Update.
2333 * fbsd-tdep.c: Update.
2334 * gcore.c: Update.
2335 * gnu-nat.c: Update.
2336 * hppa-nbsd-nat.c: Update.
2337 * hppa-obsd-nat.c: Update.
2338 * i386-fbsd-nat.c: Update.
2339 * ia64-linux-nat.c: Update.
2340 * inf-ptrace.c: Update.
2341 * infcmd.c: Update.
2342 * inferior.c: Update.
2343 * inferior.h: Update.
2344 * inflow.c: Update.
2345 * infrun.c: Update.
2346 * linux-fork.c: Update.
2347 * linux-nat.c: Update.
2348 * linux-tdep.c: Update.
2349 * linux-thread-db.c: Update.
2350 * m68k-bsd-nat.c: Update.
2351 * mi/mi-interp.c: Update.
2352 * mi/mi-main.c: Update.
2353 * mips-linux-nat.c: Update.
2354 * mips-nbsd-nat.c: Update.
2355 * mips64-obsd-nat.c: Update.
2356 * nat/aarch64-linux-hw-point.c: Update.
2357 * nat/aarch64-linux.c: Update.
2358 * nat/linux-btrace.c: Update.
2359 * nat/linux-osdata.c: Update.
2360 * nat/linux-procfs.c: Update.
2361 * nat/x86-linux-dregs.c: Update.
2362 * nto-procfs.c: Update.
2363 * obsd-nat.c: Update.
2364 * ppc-linux-nat.c: Update.
2365 * ppc-nbsd-nat.c: Update.
2366 * ppc-obsd-nat.c: Update.
2367 * proc-service.c: Update.
2368 * procfs.c: Update.
2369 * python/py-inferior.c: Update.
2370 * python/py-infthread.c: Update.
2371 * ravenscar-thread.c: Update.
2372 * record.c: Update.
2373 * remote-sim.c: Update.
2374 * remote.c: Update.
2375 * rs6000-nat.c: Update.
2376 * s390-linux-nat.c: Update.
2377 * sh-nbsd-nat.c: Update.
2378 * sol-thread.c: Update.
2379 * sparc-nat.c: Update.
2380 * sparc64-tdep.c: Update.
2381 * spu-linux-nat.c: Update.
2382 * spu-tdep.c: Update.
2383 * target-debug.h: Update.
2384 * target.c: Update.
2385 * thread.c: Update.
2386 * tid-parse.c: Update.
2387 * tracefile-tfile.c: Update.
2388 * vax-bsd-nat.c: Update.
2389 * windows-nat.c: Update.
2390 * x86-linux-nat.c: Update.
2391 * x86-nat.c: Update.
2392
f2907e49
TT
23932018-07-03 Tom Tromey <tom@tromey.com>
2394
2395 * common/ptid.c (pid_to_ptid): Remove.
2396 * common/ptid.h (pid_to_ptid): Don't declare.
2397 * aix-thread.c: Update.
2398 * arm-linux-nat.c: Update.
2399 * common/ptid.c: Update.
2400 * common/ptid.h: Update.
2401 * corelow.c: Update.
2402 * ctf.c: Update.
2403 * darwin-nat.c: Update.
2404 * fbsd-nat.c: Update.
2405 * fork-child.c: Update.
2406 * gnu-nat.c: Update.
2407 * go32-nat.c: Update.
2408 * inf-ptrace.c: Update.
2409 * infcmd.c: Update.
2410 * inferior.c: Update.
2411 * infrun.c: Update.
2412 * linux-fork.c: Update.
2413 * linux-nat.c: Update.
2414 * nat/aarch64-linux-hw-point.c: Update.
2415 * nat/fork-inferior.c: Update.
2416 * nat/x86-linux-dregs.c: Update.
2417 * nto-procfs.c: Update.
2418 * obsd-nat.c: Update.
2419 * procfs.c: Update.
2420 * progspace.c: Update.
2421 * remote.c: Update.
2422 * rs6000-nat.c: Update.
2423 * s390-linux-nat.c: Update.
2424 * sol-thread.c: Update.
2425 * spu-linux-nat.c: Update.
2426 * target.c: Update.
2427 * top.c: Update.
2428 * tracefile-tfile.c: Update.
2429 * windows-nat.c: Update.
2430
fd79271b
TT
24312018-07-03 Tom Tromey <tom@tromey.com>
2432
2433 * common/ptid.h (ptid_build): Don't declare.
2434 * common/ptid.c (ptid_build): Remove.
2435 * aix-thread.c: Update.
2436 * bsd-kvm.c: Update.
2437 * bsd-uthread.c: Update.
2438 * common/agent.c: Update.
2439 * common/ptid.c: Update.
2440 * common/ptid.h: Update.
2441 * corelow.c: Update.
2442 * darwin-nat.c: Update.
2443 * fbsd-nat.c: Update.
2444 * gnu-nat.c: Update.
2445 * linux-fork.c: Update.
2446 * linux-nat.c: Update.
2447 * linux-thread-db.c: Update.
2448 * nat/linux-osdata.c: Update.
2449 * nat/linux-procfs.c: Update.
2450 * nto-procfs.c: Update.
2451 * obsd-nat.c: Update.
2452 * proc-service.c: Update.
2453 * procfs.c: Update.
2454 * ravenscar-thread.c: Update.
2455 * remote-sim.c: Update.
2456 * remote.c: Update.
2457 * sol-thread.c: Update.
2458 * target.c: Update.
2459 * windows-nat.c: Update.
2460
057302ce
TT
24612018-07-03 Tom Tromey <tom@tromey.com>
2462
2463 * infrun.c (follow_exec): Use exit_inferior_silent.
2464 * inferior.c (exit_inferior_num_silent): Remove.
2465 * inferior.h (exit_inferior_num_silent): Don't declare.
2466
a50c11c6
TT
24672018-07-03 Tom Tromey <tom@tromey.com>
2468
2469 PR cli/23340:
2470 * darwin-nat.c (darwin_attach_pid): Reset inferior and
2471 inferior_ptid on error.
2472
471b9d15
MR
24732018-07-02 Maciej W. Rozycki <macro@mips.com>
2474 Simon Marchi <simon.marchi@polymtl.ca>
2475
2476 PR tdep/8282
2477 * disasm.h (gdb_disassembler): Add
2478 `m_disassembler_options_holder'. member
2479 * disasm.c (get_all_disassembler_options): New function.
2480 (gdb_disassembler::gdb_disassembler): Use it.
2481 (gdb_buffered_insn_length_init_dis): Likewise.
2482 (gdb_buffered_insn_length): Adjust accordingly.
2483 (set_disassembler_options): Handle options with arguments.
2484 (show_disassembler_options_sfunc): Likewise. Add a leading new
2485 line if showing options with descriptions.
2486 (disassembler_options_completer): Adapt to using the
2487 `disasm_options_and_args_t' structure.
2488 * mips-tdep.c (mips_disassembler_options): New variable.
2489 (mips_disassembler_options_o32): Likewise.
2490 (mips_disassembler_options_n32): Likewise.
2491 (mips_disassembler_options_n64): Likewise.
2492 (gdb_print_insn_mips): Don't set `disassembler_options'.
2493 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
2494 functions.
2495 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
2496 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
2497 `gdbarch_disassembler_options_implicit' and
2498 `gdbarch_valid_disassembler_options'.
2499 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
2500 `disasm_options_and_args_t' structure.
2501 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
2502 method.
2503 (valid_disassembler_options): Switch from `disasm_options_t' to
2504 the `disasm_options_and_args_t' structure.
2505 * NEWS: Document `set disassembler-options' support for the MIPS
2506 target.
2507 * gdbarch.h: Regenerate.
2508 * gdbarch.c: Regenerate.
2509
41823f29
SH
25102018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
2511
2512 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
2513
41206e32
JB
25142018-06-29 Joel Brobecker <brobecker@adacore.com>
2515
2516 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
2517 parameter in call to amd64_target_description.
2518 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
2519 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
2520 (amd64fbsd_init_abi): Likewise.
2521 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
2522 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
2523 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
2524 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
2525
de52b960
PA
25262018-06-29 Pedro Alves <palves@redhat.com>
2527
2528 * gdb/amd64-tdep.h (amd64_create_target_description): Add
2529 "segments" parameter.
2530 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
2531 (_initialize_amd64_tdep): Update call to
2532 amd64_create_target_description.
2533 (amd64_target_description): Add "segments" parameter. Adjust
2534 the implementation to use it.
2535 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
2536 call to amd64_create_target_description.
2537 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
2538 * gdb/arch/amd64.h (amd64_create_target_description): Add
2539 "segments" register.
2540 * gdb/arch/amd64.c (amd64_create_target_description): Add
2541 "segments" parameter. Call create_feature_i386_64bit_segments
2542 only if SEGMENTS is true.
2543 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
2544 call to amd64_create_target_description.
2545
75acb486
PA
25462018-06-29 Pedro Alves <palves@redhat.com>
2547
2548 * thread.c (thread_target_id_str): New, factored out from ...
2549 (print_thread_info_1): ... here. Use it to compute the max
2550 "Target Id" column width.
2551
c76a8ea3
PA
25522018-06-29 Pedro Alves <palves@redhat.com>
2553
2554 * remote.c (remote_target::extra_thread_info): Delete
2555 'display_buf' and 'n' locals. from the cache, regardless of
2556 packet mechanims is in use. Use cache for qThreadExtra and qP
2557 methods too.
2558
cd2bb709
PA
25592018-06-29 Pedro Alves <palves@redhat.com>
2560
2561 * blockframe.c (find_pc_sect_containing_function): New function.
2562 * breakpoint.c (print_breakpoint_location): Don't call
2563 find_pc_sect_function.
2564 * linespec.c (create_sals_line_offset): Record the location's
2565 symbol in the sal.
2566 * linespec.c (convert_address_location_to_sals): Fill in sal's
2567 symbol with find_pc_sect_containing_function.
2568 * symtab.c (find_function_start_sal): Rename to ...
2569 (find_function_start_sal_1): ... this.
2570 (find_function_start_sal): Reimplement as wrapper around
2571 find_function_start_sal_1, and use
2572 find_pc_sect_containing_function to fill in the sal's symbol.
2573 (find_function_start_sal(symbol*, bool)): Adjust.
2574 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
2575 comments.
2576 (find_pc_sect_containing_function): Declare.
2577
991ff292
PA
25782018-06-29 Pedro Alves <palves@redhat.com>
2579
2580 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
2581 true if the the location has no symbol.
2582
44cee4fd
TT
25832018-06-28 Tom Tromey <tom@tromey.com>
2584
2585 * NEWS: Mention --enable-codesign.
2586 * silent-rules.mk (ECHO_SIGN): New variable.
2587 * configure.ac: Add --enable-codesign.
2588 * configure: Rebuild.
2589 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
2590 (gdb$(EXEEXT)): Optionally invoke codesign.
2591
f2ffa92b
PA
25922018-06-28 Pedro Alves <palves@redhat.com>
2593
2594 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
2595 comments.
2596 (switch_to_thread_no_regs): Adjust comment.
2597 * infcmd.c (stop_pc): Delete.
2598 (post_create_inferior, info_program_command): Replace references
2599 to stop_pc with references to thread_info->suspend.stop_pc.
2600 * inferior.h (stop_pc): Delete declaration.
2601 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
2602 (handle_inferior_event_1, handle_signal_stop)
2603 (process_event_stop_test, keep_going_stepped_thread)
2604 (handle_step_into_function, handle_step_into_function_backward)
2605 (print_stop_location): Replace references to stop_pc with
2606 references to thread_info->suspend.stop_pc.
2607 (struct infcall_suspend_state) <stop_pc>: Delete field.
2608 (save_infcall_suspend_state, restore_infcall_suspend_state):
2609 Remove references to inf_stat->stop_pc.
2610 * linux-fork.c (fork_load_infrun_state): Likewise.
2611 * record-btrace.c (record_btrace_set_replay): Likewise.
2612 * record-full.c (record_full_goto_entry): Likewise.
2613 * remote.c (print_one_stopped_thread): Likewise.
2614 * target.c (target_resume): Extend comment.
2615 * thread.c (set_executing_thread): New.
2616 (set_executing): Use it.
2617 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
2618 Remove references to stop_pc.
2619
ecdc3a72
PA
26202018-06-28 Pedro Alves <palves@redhat.com>
2621
2622 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
2623 Moving fetching stop_pc until after ecs->event_thread is refreshed.
2624
d95d3aef
TT
26252018-06-28 Tom Tromey <tom@tromey.com>
2626
2627 * coffread.c (coff_symfile_finish): Update.
2628 * xcoffread.c (xcoff_symfile_finish): Update.
2629 * elfread.c (elf_symfile_finish): Update.
2630 * symfile.h (dwarf2_free_objfile): Don't declare.
2631 * dwarf2read.c (_initialize_dwarf2_read): Use
2632 register_objfile_data_with_cleanup.
2633 (dwarf2_free_objfile): Now static. Change signature.
2634
291f9a96
PT
26352018-06-28 Petr Tesarik <ptesarik@suse.cz>
2636
2637 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
2638 option "-o" to add-symbol-file-load to add an offset to each
2639 section's load address.
2640 * symfile.c (set_objfile_default_section_offset): New function.
2641
d81a3eaf
PT
26422018-06-28 Petr Tesarik <ptesarik@suse.cz>
2643
2644 * symfile.c (add_symbol_file_command): Make sure that sections
2645 with the same name are sorted in the same order.
2646
ed6dfe51
PT
26472018-06-28 Petr Tesarik <ptesarik@suse.cz>
2648
2649 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
2650 require the second argument. If omitted, load sections at the
2651 addresses specified in the file.
2652
d4d429d5
PT
26532018-06-28 Petr Tesarik <ptesarik@suse.cz>
2654
2655 * symfile.c (symbol_file_command, symbol_file_add_main_1)
2656 (_initialize_symfile): Add option "-o" to symbol-file to add an
2657 offset to each section of the symbol file.
2658
39b27ab6
PT
26592018-06-28 Petr Tesarik <ptesarik@suse.cz>
2660
2661 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
2662
41827fc3
TT
26632018-06-27 Tom Tromey <tom@tromey.com>
2664
2665 * stack.c (_initialize_stack): Update "func" help text.
2666
0c6aef22
TT
26672018-06-27 Tom Tromey <tom@tromey.com>
2668
2669 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
2670 std::vector.
2671 (unwind_infopy_str, pyuw_create_unwind_info)
2672 (unwind_infopy_add_saved_register, pyuw_sniffer)
2673 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
2674 Update.
2675 (struct saved_reg): Add constructor.
2676 <value>: Now a gdbpy_ref<>.
2677
63177289
TT
26782018-06-27 Tom Tromey <tom@tromey.com>
2679
2680 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
2681
e76f78a0
SM
26822018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2683
2684 * gdb-gdb.py.in: Format using autopep8.
2685
9a14af7b
SM
26862018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2687
2688 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
2689 (type_lookup_function): Recognize CORE_ADDR values.
2690
189366cd
SM
26912018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2692
2693 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
2694 print tag_name.
2695
68ad5fb9
SM
26962018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2697
2698 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
2699 <__lt__>: Add.
2700
141ec9f6
SM
27012018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2702
2703 * gdb-gdb.py: Move to...
2704 * gdb-gdb.py.in: ... here.
2705 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
2706 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
2707 dependencies.
2708 (distclean): Remove gdb-gdb.py when cleaning.
2709 (gdb-gdb.py, gdb-gdb.gdb): New rules.
2710 * configure: Re-generate.
2711
4c4e7ad4
PA
27122018-06-27 Pedro Alves <palves@redhat.com>
2713
2714 * proc-service.c (get_ps_regcache): New.
2715 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
2716 (ps_lsetfpregs): Use it.
2717
7ab6656f
OJ
27182018-06-27 Omair Javaid <omair.javaid@linaro.org>
2719
2720 PR gdb/21695
2721 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
2722 (dwarf_decode_lines_1): Adjust.
2723
bd583225
SM
27242018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2725
2726 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
2727 override.
2728 <info_proc>: Likewise.
2729
9a325b7b
JB
27302018-06-26 Joel Brobecker <brobecker@adacore.com>
2731
2732 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
2733 to windows_fetch_one_register, and only handle the case of
2734 fetching one register. Move the code that reloads the context
2735 and iterates over all registers if R is negative to...
2736 (windows_nat_target::fetch_registers): ... here.
2737 (do_windows_store_inferior_registers): Rename to
2738 windows_store_one_register, and only handle the case of storing
2739 one register. Move the code that handles the case where r is
2740 negative to...
2741 (windows_nat_target::store_registers) ... here.
2742
a33ccfc7
TT
27432018-06-26 Tom Tromey <tom@tromey.com>
2744
2745 PR rust/22574:
2746 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
2747 * rust-lang.c (rust_print_struct_def): Add podata parameter.
2748 Update.
2749 (rust_internal_print_type): Add podata parameter.
2750 (rust_print_type): Update.
2751
e0c547d1
TT
27522018-06-26 Tom Tromey <tom@tromey.com>
2753
2754 * typeprint.h (struct print_offset_data) <update, finish,
2755 maybe_print_hole>: New methods.
2756 <indentation>: New constant.
2757 * typeprint.c (print_offset_data::indentation): Define.
2758 (print_offset_data::maybe_print_hole, print_offset_data::update)
2759 (print_offset_data::finish): Move from c-typeprint.c and rename.
2760 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
2761 (print_spaces_filtered_with_print_options): Update.
2762 (c_print_type_union_field_offset, maybe_print_hole)
2763 (c_print_type_struct_field_offset): Move to typeprint.c and
2764 rename.
2765 (c_type_print_base_struct_union): Update.
2766
75cbc781
PA
27672018-06-25 Pedro Alves <palves@redhat.com>
2768
2769 * gdbthread.h (thread_info_ref, delete_thread)
2770 (delete_thread_silent, first_thread_of_inferior)
2771 (any_thread_of_inferior, switch_to_thread)
2772 (enable_thread_stack_temporaries)
2773 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2774 (get_last_thread_stack_temporary)
2775 (value_in_thread_stack_temporaries, can_access_registers_thread):
2776 Spell out "struct thread_info" instead of just "thread_info".
2777 * inferior.h (notice_new_inferior): Likewise.
2778
b7a08269
PA
27792018-06-25 Pedro Alves <palves@redhat.com>
2780
2781 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2782 pass thread_info pointer to delete_thread.
2783 (windows_nat_target::detach): Pass inferior pointer to
2784 detach_inferior.
2785 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
2786 delete_thread.
2787 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
2788 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
2789 and pass a thread_info pointer to delete_thread.
2790 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
2791 pass thread_info pointer to delete_thread.
2792 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
2793 delete_thread_silent call.
2794 * procfs.c (procfs_target::detach): Pass inferior pointer to
2795 detach_inferior.
2796 (procfs_target::wait): Pass thread_info pointer to delete_thread.
2797 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
2798 delete_thread_silent call.
2799 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2800 pass thread_info pointer to delete_thread.
2801 (windows_nat_target::detach): Pass inferior pointer to
2802 delete_inferior.
2803
8e7767e3
AH
28042018-06-22 Alan Hayward <alan.hayward@arm.com>
2805
2806 * regcache.c (readable_regcache::read_part): Fix asserts.
2807 (reg_buffer::raw_collect_part): New function.
2808 (regcache::write_part): Fix asserts.
2809 (reg_buffer::raw_supply_part): New function.
2810 (regcache::transfer_regset_register): New helper function.
2811 (regcache::transfer_regset): Call new functions.
2812 (regcache_supply_regset): Use gdb_byte*.
2813 (regcache::supply_regset): Likewise.
2814 (regcache_collect_regset): Likewise.
2815 (regcache::collect_regset): Likewise.
2816 * regcache.h (reg_buffer::raw_collect_part): New declaration.
2817 (reg_buffer::raw_supply_part): Likewise.
2818 (regcache::transfer_regset_register): Likewise.
2819 (regcache::transfer_regset): Use gdb_byte*.
2820
bfd60e34
AH
28212018-06-22 Alan Hayward <alan.hayward@arm.com>
2822
2823 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
2824
00431a78
PA
28252018-06-21 Pedro Alves <palves@redhat.com>
2826
2827 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
2828 instead of a ptid_t. All callers adjusted.
2829 * ada-tasks.c (ada_get_task_number): Likewise. All callers
2830 adjusted.
2831 (print_ada_task_info, display_current_task_id, task_command_1):
2832 Adjust.
2833 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
2834 inferior_thread.
2835 (breakpoint_kind): Adjust.
2836 (remove_breakpoints_pid): Rename to ...
2837 (remove_breakpoints_inf): ... this. Adjust to take an inferior
2838 pointer. All callers adjusted.
2839 (bpstat_clear_actions): Use inferior_thread.
2840 (get_bpstat_thread): New.
2841 (bpstat_do_actions): Use it.
2842 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
2843 to take a thread_info pointer. All callers adjusted.
2844 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
2845 (breakpoint_re_set_thread): Use inferior_thread.
2846 * breakpoint.h (struct inferior): Forward declare.
2847 (bpstat_stop_status): Update.
2848 (remove_breakpoints_pid): Delete.
2849 (remove_breakpoints_inf): New.
2850 * bsd-uthread.c (bsd_uthread_target::wait)
2851 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
2852 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
2853 (maint_btrace_packet_history_cmd)
2854 (maint_btrace_clear_packet_history_cmd): Adjust.
2855 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
2856 inferior_thread.
2857 * cli/cli-interp.c: Include "inferior.h".
2858 * common/refcounted-object.h (struct
2859 refcounted_object_ref_policy): New.
2860 * compile/compile-object-load.c: Include gdbthread.h.
2861 (store_regs): Use inferior_thread.
2862 * corelow.c (core_target::close): Use current_inferior.
2863 (core_target_open): Adjust to use first_thread_of_inferior and use
2864 the current inferior.
2865 * ctf.c (ctf_target::close): Adjust to use current_inferior.
2866 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
2867 <thread>: ... this new field. All references adjusted.
2868 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
2869 Take a thread_info pointer instead of a ptid_t.
2870 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
2871 (dummy_frame_discard, register_dummy_frame_dtor): Take a
2872 thread_info pointer instead of a ptid_t.
2873 * elfread.c: Include "inferior.h".
2874 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
2875 Use inferior_thread.
2876 * eval.c (evaluate_subexp): Likewise.
2877 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
2878 inferior_thread.
2879 * gdb_proc_service.h (struct thread_info): Forward declare.
2880 (struct ps_prochandle) <ptid>: Delete, replaced by ...
2881 <thread>: ... this new field. All references adjusted.
2882 * gdbarch.h, gdbarch.c: Regenerate.
2883 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
2884 'thread' parameter. All implementations and callers adjusted.
2885 * gdbthread.h (thread_info) <set_running>: New method.
2886 (delete_thread, delete_thread_silent): Take a thread_info pointer
2887 instead of a ptid.
2888 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
2889 (first_thread_of_process): Delete, replaced by ...
2890 (first_thread_of_inferior): ... this new function. All callers
2891 adjusted.
2892 (any_live_thread_of_process): Delete, replaced by ...
2893 (any_live_thread_of_inferior): ... this new function. All callers
2894 adjusted.
2895 (switch_to_thread, switch_to_no_thread): Declare.
2896 (is_executing): Delete.
2897 (enable_thread_stack_temporaries): Update comment.
2898 <enable_thread_stack_temporaries>: Take a thread_info pointer
2899 instead of a ptid_t. Incref the thread.
2900 <~enable_thread_stack_temporaries>: Decref the thread.
2901 <m_ptid>: Delete
2902 <m_thr>: New.
2903 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2904 (get_last_thread_stack_temporary)
2905 (value_in_thread_stack_temporaries, can_access_registers_thread):
2906 Take a thread_info pointer instead of a ptid_t. All callers
2907 adjusted.
2908 * infcall.c (get_call_return_value): Use inferior_thread.
2909 (run_inferior_call): Work with thread pointers instead of ptid_t.
2910 (call_function_by_hand_dummy): Work with thread pointers instead
2911 of ptid_t. Use thread_info_ref.
2912 * infcmd.c (proceed_thread_callback): Access thread's state
2913 directly.
2914 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
2915 access thread's state directly.
2916 (continue_command): Use inferior_thread.
2917 (info_program_command): Use find_thread_ptid and access thread
2918 state directly.
2919 (proceed_after_attach_callback): Use thread state directly.
2920 (notice_new_inferior): Take a thread_info pointer instead of a
2921 ptid_t. All callers adjusted.
2922 (exit_inferior): Take an inferior pointer instead of a pid. All
2923 callers adjusted.
2924 (exit_inferior_silent): New.
2925 (detach_inferior): Delete.
2926 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
2927 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
2928 (detach_inferior_command, kill_inferior_command): Use
2929 find_inferior_id instead of valid_gdb_inferior_id and
2930 gdb_inferior_id_to_pid.
2931 (inferior_command): Use inferior and thread pointers.
2932 * inferior.h (struct thread_info): Forward declare.
2933 (notice_new_inferior): Take a thread_info pointer instead of a
2934 ptid_t. All callers adjusted.
2935 (detach_inferior): Delete declaration.
2936 (exit_inferior, exit_inferior_silent): Take an inferior pointer
2937 instead of a pid. All callers adjusted.
2938 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
2939 (valid_gdb_inferior_id): Delete.
2940 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
2941 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
2942 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
2943 ...
2944 <inf>: ... this new field.
2945 <step_ptid>: Delete, replaced by ...
2946 <step_thread>: ... this new field.
2947 (get_displaced_stepping_state): Take an inferior pointer instead
2948 of a pid. All callers adjusted.
2949 (displaced_step_in_progress_any_inferior): Adjust.
2950 (displaced_step_in_progress_thread): Take a thread pointer instead
2951 of a ptid_t. All callers adjusted.
2952 (displaced_step_in_progress, add_displaced_stepping_state): Take
2953 an inferior pointer instead of a pid. All callers adjusted.
2954 (get_displaced_step_closure_by_addr): Adjust.
2955 (remove_displaced_stepping_state): Take an inferior pointer
2956 instead of a pid. All callers adjusted.
2957 (displaced_step_prepare_throw, displaced_step_prepare)
2958 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
2959 All callers adjusted.
2960 (start_step_over): Adjust.
2961 (infrun_thread_ptid_changed): Remove bit updating ptids in the
2962 displaced step queue.
2963 (do_target_resume): Adjust.
2964 (fetch_inferior_event): Use inferior_thread.
2965 (context_switch, get_inferior_stop_soon): Take an
2966 execution_control_state pointer instead of a ptid_t. All callers
2967 adjusted.
2968 (switch_to_thread_cleanup): Delete.
2969 (stop_all_threads): Use scoped_restore_current_thread.
2970 * inline-frame.c: Include "gdbthread.h".
2971 (inline_state) <inline_state>: Take a thread pointer instead of a
2972 ptid_t. All callers adjusted.
2973 <ptid>: Delete, replaced by ...
2974 <thread>: ... this new field.
2975 (find_inline_frame_state): Take a thread pointer instead of a
2976 ptid_t. All callers adjusted.
2977 (skip_inline_frames, step_into_inline_frame)
2978 (inline_skipped_frames, inline_skipped_symbol): Take a thread
2979 pointer instead of a ptid_t. All callers adjusted.
2980 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
2981 (inline_skipped_frames, inline_skipped_symbol): Likewise.
2982 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
2983 pointers directly.
2984 * linux-nat.c (get_detach_signal): Likewise.
2985 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
2986 (thread_db_notice_clone): Adjust.
2987 (thread_db_find_new_threads_silently)
2988 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
2989 a thread pointer instead of a ptid_t. All callers adjusted.
2990 * mi/mi-cmd-var.c: Include "inferior.h".
2991 (mi_cmd_var_update_iter): Update to use thread pointers.
2992 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
2993 inferior directly.
2994 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
2995 out to ...
2996 (mi_output_running): ... this new function.
2997 (mi_on_resume_1): Adjust to use it.
2998 (mi_user_selected_context_changed): Adjust to use inferior_thread.
2999 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
3000 directly.
3001 (interrupt_thread_callback): : Adjust to use thread and inferior
3002 pointers.
3003 * proc-service.c: Include "gdbthread.h".
3004 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
3005 * progspace-and-thread.c: Include "inferior.h".
3006 * progspace.c: Include "inferior.h".
3007 * python/py-exitedevent.c (create_exited_event_object): Adjust to
3008 hold a reference to an inferior_object.
3009 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
3010 inferior_thread.
3011 * python/py-inferior.c (struct inferior_object): Give the type a
3012 tag name instead of a typedef.
3013 (python_on_normal_stop): No need to check if the current thread is
3014 listed.
3015 (inferior_to_inferior_object): Change return type to
3016 inferior_object. All callers adjusted.
3017 (find_thread_object): Delete, bits factored out to ...
3018 (thread_to_thread_object): ... this new function.
3019 * python/py-infthread.c (create_thread_object): Use
3020 inferior_to_inferior_object.
3021 (thpy_is_stopped): Use thread pointer directly.
3022 (gdbpy_selected_thread): Use inferior_thread.
3023 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
3024 field, replaced with ...
3025 <thread>: ... this new field. All users adjusted.
3026 (btpy_insn_or_gap_new): Drop const.
3027 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
3028 callers adjusted.
3029 * python/py-record.c: Include "gdbthread.h".
3030 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
3031 a ptid_t. All callers adjusted.
3032 (gdbpy_current_recording): Use inferior_thread.
3033 * python/py-record.h (recpy_record_object) <ptid>: Delete
3034 field, replaced with ...
3035 <thread>: ... this new field. All users adjusted.
3036 (recpy_element_object) <ptid>: Delete
3037 field, replaced with ...
3038 <thread>: ... this new field. All users adjusted.
3039 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
3040 a ptid_t. All callers adjusted.
3041 * python/py-threadevent.c: Include "gdbthread.h".
3042 (get_event_thread): Use thread_to_thread_object.
3043 * python/python-internal.h (struct inferior_object): Forward
3044 declare.
3045 (find_thread_object, find_inferior_object): Delete declarations.
3046 (thread_to_thread_object, inferior_to_inferior_object): New
3047 declarations.
3048 * record-btrace.c: Include "inferior.h".
3049 (require_btrace_thread): Use inferior_thread.
3050 (record_btrace_frame_sniffer)
3051 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
3052 (get_thread_current_frame): Use scoped_restore_current_thread and
3053 switch_to_thread.
3054 (get_thread_current_frame): Use thread pointer directly.
3055 (record_btrace_replay_at_breakpoint): Use thread's inferior
3056 pointer directly.
3057 * record-full.c: Include "inferior.h".
3058 * regcache.c: Include "gdbthread.h".
3059 (get_thread_arch_regcache): Use the inferior's address space
3060 directly.
3061 (get_thread_regcache, registers_changed_thread): New.
3062 * regcache.h (get_thread_regcache(thread_info *thread)): New
3063 overload.
3064 (registers_changed_thread): New.
3065 (remote_target) <remote_detach_1>: Swap order of parameters.
3066 (remote_add_thread): <remote_add_thread>: Return the new thread.
3067 (get_remote_thread_info(ptid_t)): New overload.
3068 (remote_target::remote_notice_new_inferior): Use thread pointers
3069 directly.
3070 (remote_target::process_initial_stop_replies): Use
3071 thread_info::set_running.
3072 (remote_target::remote_detach_1, remote_target::detach)
3073 (extended_remote_target::detach): Adjust.
3074 * stack.c (frame_show_address): Use inferior_thread.
3075 * target-debug.h (target_debug_print_thread_info_pp): New.
3076 * target-delegates.c: Regenerate.
3077 * target.c (default_thread_address_space): Delete.
3078 (memory_xfer_partial_1): Use current_inferior.
3079 (target_detach): Use current_inferior.
3080 (target_thread_address_space): Delete.
3081 (generic_mourn_inferior): Use current_inferior.
3082 * target.h (struct target_ops) <thread_address_space>: Delete.
3083 (target_thread_address_space): Delete.
3084 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
3085 pointers directly.
3086 (delete_thread_1, delete_thread, delete_thread_silent): Take a
3087 thread pointer instead of a ptid_t. Adjust all callers.
3088 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
3089 (first_thread_of_process): Delete, replaced by ...
3090 (first_thread_of_inferior): ... this new function. All callers
3091 adjusted.
3092 (any_thread_of_process): Rename to ...
3093 (any_thread_of_inferior): ... this, and take an inferior pointer.
3094 (any_live_thread_of_process): Rename to ...
3095 (any_live_thread_of_inferior): ... this, and take an inferior
3096 pointer.
3097 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
3098 (value_in_thread_stack_temporaries)
3099 (get_last_thread_stack_temporary): Take a thread pointer instead
3100 of a ptid_t. Adjust all callers.
3101 (thread_info::set_running): New.
3102 (validate_registers_access): Use inferior_thread.
3103 (can_access_registers_ptid): Rename to ...
3104 (can_access_registers_thread): ... this, and take a thread
3105 pointer.
3106 (print_thread_info_1): Adjust to compare thread pointers instead
3107 of ptids.
3108 (switch_to_no_thread, switch_to_thread): Make extern.
3109 (scoped_restore_current_thread::~scoped_restore_current_thread):
3110 Use m_thread pointer directly.
3111 (scoped_restore_current_thread::scoped_restore_current_thread):
3112 Use inferior_thread.
3113 (thread_command): Use thread pointer directly.
3114 (thread_num_make_value_helper): Use inferior_thread.
3115 * top.c (execute_command): Use inferior_thread.
3116 * tui/tui-interp.c: Include "inferior.h".
3117 * varobj.c (varobj_create): Use inferior_thread.
3118 (value_of_root_1): Use find_thread_global_id instead of
3119 global_thread_id_to_ptid.
3120
33bab475
AH
31212018-06-21 Alan Hayward <alan.hayward@arm.com>
3122
3123 * regcache.c (readable_regcache::read_part): Avoid memcpy when
3124 possible.
3125 (regcache::write_part): Likewise.
3126 (readable_regcache::cooked_read_part): Update comment.
3127 (readable_regcache::cooked_write_part): Likewise.
3128 * regcache.h: (readable_regcache::read_part): Likewise.
3129 (regcache::write_part): Likewise.
3130
8363f9d5
RB
31312018-06-21 Richard Bunt <richard.bunt@arm.com>
3132 Dirk Schubert <dirk.schubert@arm.com>
3133
3134 * aarch64-linux-nat.c (post_attach): New.
3135 (aarch64_linux_nat_target::post_attach): Override post_attach to
3136 record the number of hardware debug registers.
3137
0d0b0ea2
TT
31382018-06-20 Tom Tromey <tom@tromey.com>
3139
3140 * python/py-param.c (add_setshow_generic): Make parameters const.
3141 (parmpy_init): Update.
3142
302abd6e
SM
31432018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
3144
3145 * regcache.h (regcache_cooked_read_ftype): Rename to...
3146 (register_read_ftype): ...this, change type to function_view.
3147 (class reg_buffer) <save>: Remove src parameter.
3148 (readonly_detached_regcache) <readonly_detached_regcache>: Make
3149 parameter non-const in first overload. Remove src parameter in
3150 second overload.
3151 * regcache.c (do_cooked_read): Remove.
3152 (readonly_detached_regcache::readonly_detached_regcache): Make
3153 parameter non-const, adjust call to other constructor.
3154 (reg_buffer::save): Remove src parameter.
3155 * frame.c (do_frame_register_read): Remove.
3156 (frame_save_as_regcache): Use lambda function.
3157 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
3158 parameter to ppu2spu_data *.
3159 (ppu2spu_sniffer): Use lambda function.
3160
19f3f25f
SM
31612018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
3162
3163 * record-full.c (record_full_target::insert_breakpoint): Remove
3164 "struct" keyword, add const.
3165
d0ac1c44
SM
31662018-06-19 Simon Marchi <simon.marchi@ericsson.com>
3167
3168 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
3169 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
3170 * configure.ac: Remove AC_PREREQ, add missing quoting.
3171 * gnulib/configure.ac: Modernize usage of
3172 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
3173 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
3174 (AUTOMAKE_VERSION): Bump to 1.15.1.
3175 * configure: Re-generate.
3176 * config.in: Re-generate.
3177 * aclocal.m4: Re-generate.
3178 * gnulib/aclocal.m4: Re-generate.
3179 * gnulib/config.in: Re-generate.
3180 * gnulib/configure: Re-generate.
3181 * gnulib/import/Makefile.in: Re-generate.
3182
6ae50267
PA
31832018-06-19 Pedro Alves <palves@redhat.com>
3184
3185 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
3186 (lookup_minimal_symbol_by_pc_section): ... here with
3187 gdb_assert_not_reached added.
3188
61b04dd0
PA
31892018-06-19 Pedro Alves <palves@redhat.com>
3190
3191 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
3192 parameter with a block parameter. Compare location's block symbol
3193 with the frame's block instead of addresses.
3194 (skip_inline_frames): Pass the current block instead of the
3195 frame's address. Break out as soon as we determine the frame
3196 should not be skipped.
3197
f709fabb
TT
31982018-06-18 Tom Tromey <tom@tromey.com>
3199
3200 * solib-aix.c (solib_aix_get_section_offsets): Return
3201 unique_xmalloc_ptr.
3202 (solib_aix_solib_create_inferior_hook): Update.
3203
668eb2f0
TT
32042018-06-18 Tom Tromey <tom@tromey.com>
3205
3206 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
3207
309822ca
TT
32082018-06-18 Tom Tromey <tom@tromey.com>
3209
3210 * solib-frv.c (frv_relocate_main_executable): Use
3211 unique_xmalloc_ptr.
3212 * solib-dsbt.c (dsbt_relocate_main_executable): Use
3213 unique_xmalloc_ptr.
3214
06424eac
TT
32152018-06-18 Tom Tromey <tom@tromey.com>
3216
3217 * objfiles.h (inhibit_section_map_updates): Update.
3218 (resume_section_map_updates, resume_section_map_updates_cleanup):
3219 Remove.
3220 * solib-svr4.c (svr4_handle_solib_event): Update.
3221 * objfiles.c (inhibit_section_map_updates): Return
3222 scoped_restore_tmpl<int>.
3223 (resume_section_map_updates, resume_section_map_updates_cleanup):
3224 Remove.
3225
b4be9fad
TT
32262018-06-18 Tom Tromey <tom@tromey.com>
3227
3228 * valprint.h (read_string): Update.
3229 * valprint.c (read_string): Change type of "buffer".
3230 (val_print_string): Update.
3231 * python/py-value.c (valpy_string): Update.
3232 * language.h (struct language_defn) <la_get_string>: Change
3233 type of "buffer".
3234 (default_get_string, c_get_string): Update.
3235 * language.c (default_get_string): Change type of "buffer".
3236 * guile/scm-value.c (gdbscm_value_to_string): Update.
3237 * c-lang.c (c_get_string): Change type of "buffer".
3238
3f0dbd67
TT
32392018-06-18 Tom Tromey <tom@tromey.com>
3240
3241 * ser-mingw.c (struct pipe_state_destroyer): New.
3242 (pipe_state_up): New typedef.
3243 (cleanup_pipe_state): Remove.
3244 (pipe_windows_open): Use pipe_state_up. Don't release argv.
3245
69d340c6
TT
32462018-06-18 Tom Tromey <tom@tromey.com>
3247
3248 * rust-lang.h (rust_yyerror): Don't declare.
3249 * rust-lang.c (rust_language_defn): Update.
3250 * rust-exp.y (yyerror): Now static.
3251 * parse.c (parse_exp_in_context_1): Update.
3252 * p-lang.h (p_yyerror): Don't declare.
3253 * p-lang.c (p_language_defn): Update.
3254 * p-exp.y (yyerror): Now static.
3255 * opencl-lang.c (opencl_language_defn): Update.
3256 * objc-lang.c (objc_language_defn): Update.
3257 * m2-lang.h (m2_yyerror): Don't declare.
3258 * m2-lang.c (m2_language_defn): Update.
3259 * m2-exp.y (yyerror): Now static.
3260 * language.h (struct language_defn) <la_error>: Remove.
3261 * language.c (unk_lang_error): Remove.
3262 (unknown_language_defn, auto_language_defn): Remove.
3263 * go-lang.h (go_yyerror): Don't declare.
3264 * go-lang.c (go_language_defn): Update.
3265 * go-exp.y (yyerror): Now static.
3266 * f-lang.h (f_yyerror): Don't declare.
3267 * f-lang.c (f_language_defn): Update.
3268 * f-exp.y (yyerror): Now static.
3269 * d-lang.h (d_yyerror): Don't declare.
3270 * d-lang.c (d_language_defn): Update.
3271 * d-exp.y (yyerror): Now static.
3272 * c-lang.h (c_yyerror): Don't declare.
3273 * c-lang.c (c_language_defn, cplus_language_defn)
3274 (asm_language_defn, minimal_language_defn): Update.
3275 * c-exp.y (yyerror): Now static.
3276 * ada-lang.h (ada_yyerror): Don't declare.
3277 * ada-lang.c (ada_language_defn): Update.
3278 * ada-exp.y (yyerror): Now static.
3279
e9902bfc
AH
32802018-06-18 Alan Hayward <alan.hayward@arm.com>
3281
3282 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
3283 (store_sveregs_to_thread): Likewise.
3284 (aarch64_linux_fetch_inferior_registers): Check for SVE.
3285 (aarch64_linux_store_inferior_registers): Likewise.
3286 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
3287 function.
3288 (aarch64_sve_regs_copy_to_regcache): Likewise.
3289 (aarch64_sve_regs_copy_from_regcache): Likewise.
3290 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
3291 declaration.
3292 (aarch64_sve_regs_copy_to_regcache): Likewise.
3293 (aarch64_sve_regs_copy_from_regcache): Likewise.
3294 (sve_context): Structure from Linux headers.
3295 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
3296 (SVE_SIG_ZREG_SIZE): Likewise.
3297 (SVE_SIG_PREG_SIZE): Likewise.
3298 (SVE_SIG_FFR_SIZE): Likewise.
3299 (SVE_SIG_REGS_OFFSET): Likewise.
3300 (SVE_SIG_ZREGS_OFFSET): Likewise.
3301 (SVE_SIG_ZREG_OFFSET): Likewise.
3302 (SVE_SIG_ZREGS_SIZE): Likewise.
3303 (SVE_SIG_PREGS_OFFSET): Likewise.
3304 (SVE_SIG_PREG_OFFSET): Likewise.
3305 (SVE_SIG_PREGS_SIZE): Likewise.
3306 (SVE_SIG_FFR_OFFSET): Likewise.
3307 (SVE_SIG_REGS_SIZE): Likewise.
3308 (SVE_SIG_CONTEXT_SIZE): Likewise.
3309 (SVE_PT_REGS_MASK): Likewise.
3310 (SVE_PT_REGS_FPSIMD): Likewise.
3311 (SVE_PT_REGS_SVE): Likewise.
3312 (SVE_PT_VL_INHERIT): Likewise.
3313 (SVE_PT_VL_ONEXEC): Likewise.
3314 (SVE_PT_REGS_OFFSET): Likewise.
3315 (SVE_PT_FPSIMD_OFFSET): Likewise.
3316 (SVE_PT_FPSIMD_SIZE): Likewise.
3317 (SVE_PT_SVE_ZREG_SIZE): Likewise.
3318 (SVE_PT_SVE_PREG_SIZE): Likewise.
3319 (SVE_PT_SVE_FFR_SIZE): Likewise.
3320 (SVE_PT_SVE_FPSR_SIZE): Likewise.
3321 (SVE_PT_SVE_FPCR_SIZE): Likewise.
3322 (__SVE_SIG_TO_PT): Likewise.
3323 (SVE_PT_SVE_OFFSET): Likewise.
3324 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
3325 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
3326 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
3327 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
3328 (SVE_PT_SVE_PREG_OFFSET): Likewise.
3329 (SVE_PT_SVE_PREGS_SIZE): Likewise.
3330 (SVE_PT_SVE_FFR_OFFSET): Likewise.
3331 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
3332 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
3333 (SVE_PT_SVE_SIZE): Likewise.
3334 (SVE_PT_SIZE): Likewise.
3335 (HAS_SVE_STATE): New define.
3336
17a1cc89
AH
33372018-06-18 Alan Hayward <alan.hayward@arm.com>
3338
3339 * nat/aarch64-sve-linux-sigcontext.h: New file.
3340 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
3341 new files.
3342 (SVE_VQ_MIN): Likewise.
3343 (SVE_VQ_MAX): Likewise.
3344 (SVE_VL_MIN): Likewise.
3345 (SVE_VL_MAX): Likewise.
3346 (SVE_NUM_ZREGS): Likewise.
3347 (SVE_NUM_PREGS): Likewise.
3348 (sve_vl_valid): Likewise.
3349 (struct user_sve_header): Likewise.
3350
7010835a
AB
33512018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
3352 Richard Bunt <Richard.Bunt@arm.com>
3353
3354 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
3355 was requested by GDB.
3356
479b3ef4
TV
33572018-06-15 Tom de Vries <tdevries@suse.de>
3358
3359 * MAINTAINERS (Write After Approval): Add Tom de Vries.
3360
8199b8f4
SM
33612018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
3362
3363 * gnulib/update-gnulib.sh: Print expected versions of
3364 autoconf/aclocal.
3365
55c748a1
SM
33662018-06-14 Simon Marchi <simon.marchi@ericsson.com>
3367
3368 * arch-utils.c (default_type_align): Use type_length_units.
3369 * gdbtypes.c (type_align): Use type_length_units.
3370
87a8eca7
PW
33712018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3372
3373 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
3374 of 'define' command.
3375
5d9a0608
TV
33762018-06-14 Tom de Vries <tdevries@suse.de>
3377
3378 PR cli/22573
3379 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
3380 get_no_prettyformat_print_options.
3381
ab89b5a5
SM
33822018-06-13 Simon Marchi <simon.marchi@ericsson.com>
3383
3384 * sparc-nat.h: Include target.h.
3385 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
3386 <fetch_registers>: Remove this argument in function call.
3387 <store_registers>: Remove this argument in function call, remove
3388 extra semicolon.
3389 <low_forget_process>: Call sparc64_forget_process instead of
3390 sparc_forget_process.
3391
62c808ae
RO
33922018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3393
3394 * procfs.c (_initialize_procfs): Use add_inf_child_target.
3395 (procfs_target::make_corefile_notes): Adjust to new
3396 target_read_alloc return type.
3397
1840d81a
AB
33982018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3399 Stephen Roberts <stephen.roberts@arm.com>
3400
3401 PR gdb/22882
3402 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
3403 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
3404 Move should_notify_stop local into more inner scope.
3405
9516f85a
AB
34062018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3407 Stephen Roberts <stephen.roberts@arm.com>
3408
3409 PR gdb/22882
3410 * infrun.c (resume_1): Add call to mark_async_event_handler.
3411
defd2172
AB
34122018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3413
3414 * infrun.c (do_target_wait): Change old version of $pc printed.
3415
7b23e087
SM
34162018-06-11 Simon Marchi <simon.marchi@ericsson.com>
3417
3418 * dwarf2read.c (read_index_from_section): Rename to...
3419 (read_gdb_index_from_section): ... this, update all callers.
3420 (dwarf2_read_index): Rename to...
3421 (dwarf2_read_gdb_index): ... this, update all callers.
3422
69c67a0b
JDA
34232018-06-11 John David Anglin <danglin@gcc.gnu.org>
3424
3425 * gdb/hppa-linux-nat.c
3426 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
3427 hppa_linux_nat_target::fetch_registers.
3428
65d4cada
AH
34292018-06-11 Alan Hayward <alan.hayward@arm.com>
3430
3431 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
3432 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
3433 (AARCH64_DWARF_SVE_FFR): Likewise.
3434 (AARCH64_DWARF_SVE_P0): Likewise.
3435 (AARCH64_DWARF_SVE_Z0): Likewise.
3436
f868386e
AH
34372018-06-11 Alan Hayward <alan.hayward@arm.com>
3438
3439 * common/common-regcache.h (raw_compare): New function.
3440 * regcache.c (regcache::raw_compare): Likewise.
3441 * regcache.h (regcache::raw_compare): New declaration.
3442
9c861883
AH
34432018-06-11 Alan Hayward <alan.hayward@arm.com>
3444
3445 * common/common-regcache.h (reg_buffer_common): New structure.
3446 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
3447 (reg_buffer::raw_supply): Likewise.
3448 (reg_buffer::raw_supply_integer): Likewise.
3449 (reg_buffer::raw_supply_zeroed): Likewise.
3450 (reg_buffer::raw_collect): Likewise.
3451 (reg_buffer::raw_collect_integer): Likewise.
3452 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
3453 (reg_buffer::raw_supply): Likewise.
3454 (reg_buffer::raw_supply_integer): Likewise.
3455 (reg_buffer::raw_supply_zeroed): Likewise.
3456 (reg_buffer::raw_collect): Likewise.
3457 (reg_buffer::raw_collect_integer): Likewise.
3458
953edf2b
TT
34592018-06-10 Tom Tromey <tom@tromey.com>
3460
3461 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
3462 (class remote_state) <stop_reply_queue>: Now std::vector.
3463 (remote_state::~remote_state)
3464 (remote_target::stop_reply_queue_length): Update.
3465 (struct queue_iter_param, remove_child_of_pending_fork)
3466 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
3467 (check_pending_event_prevents_wildcard_vcont_callback)
3468 (remove_stop_reply_for_inferior)
3469 (remove_stop_reply_of_remote_state)
3470 (remote_notif_remove_once_on_match)
3471 (stop_reply_match_ptid_and_ws)
3472 (remote_kill_child_of_pending_fork): Remove.
3473 (remote_target::remove_new_fork_children)
3474 (remote_target::check_pending_events_prevent_wildcard_vcont)
3475 (remote_target::discard_pending_stop_replies)
3476 (remote_target::discard_pending_stop_replies_in_queue)
3477 (remote_target::remote_notif_remove_queued_reply)
3478 (remote_target::queued_stop_reply)
3479 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
3480 (remote_target::wait, remote_target::kill_new_fork_children)
3481 (remote_target::async): Update.
3482
1ddbba9d
TT
34832018-06-10 Tom Tromey <tom@tromey.com>
3484
3485 * record-full.c (record_full_arch_list_cleanups): Remove.
3486 (record_full_message): Use try/catch.
3487 (record_full_wait_cleanups): Remove.
3488 (record_full_wait_1): Use try/catch.
3489 (record_full_restore): Likewise.
3490
219605fd
TT
34912018-06-10 Tom Tromey <tom@tromey.com>
3492
3493 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
3494 declare VEC. Add constructor.
3495 <in_target_beneath>: Now bool.
3496 (record_full_breakpoints): Now a std::vector, static.
3497 (record_full_sync_record_breakpoints)
3498 (record_full_init_record_breakpoints)
3499 (record_full_target::insert_breakpoint)
3500 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
3501
71b73764
SM
35022018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
3503
3504 * dwarf2read.c (process_cu_includes): Remove struct keyword.
3505 * serial.c (serial_interface_lookup): Remove struct keyword.
3506
4360561f
TT
35072018-06-10 Tom Tromey <tom@tromey.com>
3508
3509 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
3510 method.
3511 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
3512 a method.
3513 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
3514 method.
3515 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
3516 "beneath" as a method.
3517 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
3518 Use "beneath" as a method.
3519
d14b92bf
TT
35202018-06-10 Tom Tromey <tom@tromey.com>
3521
3522 * tracefile.c (struct trace_file_writer_deleter): New.
3523 <operator()>: Rename from trace_file_writer_xfree.
3524 (trace_file_writer_up): New typedef.
3525 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
3526
835dcf92
SM
35272018-06-09 Simon Marchi <simon.marchi@ericsson.com>
3528
3529 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
3530 <m_registers, m_register_status>: Change type to
3531 std::unique_ptr.
3532 * regcache.c (reg_buffer::reg_buffer): Use new instead of
3533 XCNEWVEC.
3534
aac0d564
SM
35352018-06-09 Simon Marchi <simon.marchi@ericsson.com>
3536
3537 * common/common-regcache.h (enum register_status): Add
3538 underlying type "signed char".
3539 * regcache.h (reg_buffer) <m_register_status>: Change type to
3540 register_status *.
3541 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
3542 register_status instead of signed char.
3543 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
3544 (reg_buffer::get_register_status): Remove cast.
3545 (readable_regcache::raw_read): Remove cast.
3546 (readable_regcache::cooked_read): Remove cast.
3547
77ad7394
TT
35482018-06-09 Tom Tromey <tom@tromey.com>
3549
3550 * source.c (reverse_search_command, forward_search_command): Use
3551 scoped_fd.
3552
191cca63
TT
35532018-06-09 Tom Tromey <tom@tromey.com>
3554
3555 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
3556 (serial_ops_list): Now static, std::vector.
3557 (serial_interface_lookup, serial_add_interface): Update.
3558
c5d0225d
TT
35592018-06-09 Tom Tromey <tom@tromey.com>
3560
3561 * dwarf2read.c (process_cu_includes): Update.
3562 (process_full_comp_unit): Update.
3563 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
3564 std::vector.
3565
aeab5128
PK
35662018-06-08 Paul Koning <paul_koning@dell.com>
3567
3568 PR gdb/23252
3569
3570 * python/python.c (do_start_initialization):
3571 Avoid call to internal Python API.
3572 (init__gdb_module): New function.
3573
5045b3d7
GB
35742018-06-08 Gary Benson <gbenson@redhat.com>
3575
3576 * linux-thread-db.c (valprint.h): New include.
3577 (struct check_thread_db_info): New structure.
3578 (check_thread_db_on_load, tdb_testinfo): New static globals.
3579 (check_thread_db, check_thread_db_callback): New functions.
3580 (try_thread_db_load_1): Run integrity checks if requested.
3581 (maintenance_check_libthread_db): New function.
3582 (_initialize_thread_db): Register "maint check libthread-db"
3583 and "maint set/show check-libthread-db".
3584 * NEWS: Mention the above new commands.
3585
2f4f025f
TT
35862018-06-08 Tom Tromey <tom@tromey.com>
3587
3588 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
3589 now a method.
3590
343b0027
TT
35912018-06-08 Tom Tromey <tom@tromey.com>
3592
3593 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
3594
8dcc53b3
TT
35952018-06-08 Tom Tromey <tom@tromey.com>
3596
3597 * common/btrace-common.h (struct btrace_data): Add constructor,
3598 destructor, move assignment operator.
3599 <empty, clear, fini>: New methods.
3600 <format>: Initialize.
3601 (btrace_data_init, btrace_data_fini, btrace_data_clear)
3602 (btrace_data_empty): Don't declare.
3603 * common/btrace-common.c (btrace_data_init): Remove.
3604 (btrace_data::fini): Rename from btrace_data_fini.
3605 (btrace_data::empty): Rename from btrace_data_empty.
3606 (btrace_data::clear): Rename from btrace_data_clear. Return
3607 bool.
3608 * btrace.h (make_cleanup_btrace_data): Don't declare.
3609 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
3610 (parse_xml_btrace): Update.
3611 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
3612 (maint_btrace_clear_packet_history_cmd): Update.
3613
a1740ee1
PA
36142018-06-07 Pedro Alves <palves@redhat.com>
3615
3616 * target.h (target_ops) <beneath>: Now a method. All references
3617 updated.
3618 (class target_stack): New.
3619 * target.c (g_target_stack): New.
3620 (g_current_top_target): Delete.
3621 (current_top_target): Get the top target out of g_target_stack.
3622 (target_stack::push, target_stack::unpush): New.
3623 (push_target, unpush_target): Reimplement.
3624 (target_is_pushed): Reimplement in terms of g_target_stack.
3625 (target_ops::beneath, target_stack::find_beneath): New.
3626
d6ca69cd
PA
36272018-06-07 Pedro Alves <palves@redhat.com>
3628
3629 * target.h (find_target_beneath): Delete declaration.
3630 * target.c (find_target_beneath): Delete definition.
3631 * aix-thread.c: All callers of find_target_beneath adjusted to
3632 call target_ops::beneath instead.
3633 * bsd-uthread.c: Likewise.
3634 * linux-thread-db.c: Likewise.
3635 * ravenscar-thread.c: Likewise.
3636 * sol-thread.c: Likewise.
3637 * spu-multiarch.c: Likewise.
3638
b6a8c27b
PA
36392018-06-07 Pedro Alves <palves@redhat.com>
3640
3641 * target.h (target_ops) <beneath>: Now a method. All references
3642 updated.
3643 (target_ops) <m_beneath>: New.
3644 * target.c (target_ops::beneath): New.
3645 * corelow.c: Adjust all references to target_ops::beneath.
3646 * linux-thread-db.c: Likewise.
3647 * make-target-delegates: Likewise.
3648 * record-btrace.c: Likewise.
3649 * record-full.c: Likewise.
3650 * remote.c: Likewise.
3651 * target.c: Likewise.
3652 * target-delegates.c: Regenerate.
3653
8b88a78e
PA
36542018-06-07 Pedro Alves <palves@redhat.com>
3655
3656 * target.h (target_stack): Delete.
3657 (current_top_target): Declare function.
3658 * target.c (target_stack): Delete.
3659 (g_current_top_target): New.
3660 (current_top_target): New function.
3661 * auxv.c: Use current_top_target instead of target_stack
3662 throughout.
3663 * avr-tdep.c: Likewise.
3664 * breakpoint.c: Likewise.
3665 * corefile.c: Likewise.
3666 * elfread.c: Likewise.
3667 * eval.c: Likewise.
3668 * exceptions.c: Likewise.
3669 * frame.c: Likewise.
3670 * gdbarch-selftests.c: Likewise.
3671 * gnu-v3-abi.c: Likewise.
3672 * ia64-tdep.c: Likewise.
3673 * ia64-vms-tdep.c: Likewise.
3674 * infcall.c: Likewise.
3675 * infcmd.c: Likewise.
3676 * infrun.c: Likewise.
3677 * linespec.c: Likewise.
3678 * linux-tdep.c: Likewise.
3679 * minsyms.c: Likewise.
3680 * ppc-linux-nat.c: Likewise.
3681 * ppc-linux-tdep.c: Likewise.
3682 * procfs.c: Likewise.
3683 * regcache.c: Likewise.
3684 * remote.c: Likewise.
3685 * rs6000-tdep.c: Likewise.
3686 * s390-linux-nat.c: Likewise.
3687 * s390-tdep.c: Likewise.
3688 * solib-aix.c: Likewise.
3689 * solib-darwin.c: Likewise.
3690 * solib-dsbt.c: Likewise.
3691 * solib-spu.c: Likewise.
3692 * solib-svr4.c: Likewise.
3693 * solib-target.c: Likewise.
3694 * sparc-tdep.c: Likewise.
3695 * sparc64-tdep.c: Likewise.
3696 * spu-tdep.c: Likewise.
3697 * symfile.c: Likewise.
3698 * symtab.c: Likewise.
3699 * target-descriptions.c: Likewise.
3700 * target-memory.c: Likewise.
3701 * target.c: Likewise.
3702 * target.h: Likewise.
3703 * tracefile-tfile.c: Likewise.
3704 * tracepoint.c: Likewise.
3705 * valops.c: Likewise.
3706 * valprint.c: Likewise.
3707 * value.c: Likewise.
3708 * windows-tdep.c: Likewise.
3709 * mi/mi-main.c: Likewise.
3710
c7110220
TT
37112018-06-07 Tom Tromey <tom@tromey.com>
3712
3713 * valprint.h (build_address_symbolic): Declare.
3714 * printcmd.c (print_address_symbolic): Update.
3715 (build_address_symbolic): Change "name" and "filename" to
3716 std::string.
3717 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
3718 Update.
3719 * defs.h (build_address_symbolic): Remove declaration.
3720
63bad7b6
AH
37212018-06-07 Alan Hayward <alan.hayward@arm.com>
3722
3723 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
3724 (aarch64_vnv_type): Add function.
3725 (aarch64_pseudo_register_name): Add V regs for SVE.
3726 (aarch64_pseudo_register_type): Likewise.
3727 (aarch64_pseudo_register_reggroup_p): Likewise.
3728 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
3729 (aarch64_pseudo_read_value): Add V regs for SVE.
3730 (aarch64_pseudo_write_2): Use V0 offset for SVE
3731 (aarch64_pseudo_write): Add V regs for SVE.
3732 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
3733
13e3c608
SDJ
37342018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
3735
3736 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
3737 (sve_vl_from_vq): Likewise.
3738
c61b06a1
TT
37392018-06-05 Tom Tromey <tom@tromey.com>
3740
3741 * cli/cli-cmds.c (show_version): Update.
3742 * top.c (print_gdb_version): Add "interactive" parameter.
3743 Update.
3744 * main.c (captured_main_1): Update.
3745 * top.h (print_gdb_version): Add "interactive" parameter and a
3746 comment.
3747
115f7325
DM
37482018-06-05 David Malcolm <dmalcolm@redhat.com>
3749
3750 * common/enum-flags.h: Add trailing semicolon to example in
3751 comment.
3752
eb6af809
TT
37532018-06-05 Tom Tromey <tom@tromey.com>
3754
3755 PR cli/12326:
3756 * NEWS: Add entry about pager.
3757 * utils.c (pagination_disabled_for_command): New global.
3758 (prompt_for_continue): Allow "c" response to prompt.
3759 (reinitialize_more_filter): Clear
3760 pagination_disabled_for_command.
3761 (fputs_maybe_filtered): Check pagination_disabled_for_command.
3762
54d343a2
TT
37632018-06-04 Tom Tromey <tom@tromey.com>
3764
3765 * ada-lang.h (ada_lookup_symbol_list): Update.
3766 * ada-lang.c (resolve_subexp): Update.
3767 (symbols_are_identical_enums): Change type of syms. Remove nsyms
3768 parameter.
3769 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
3770 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
3771 results parameter to std::vector.
3772 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
3773 Update.
3774 * ada-exp.y (block_lookup): Update.
3775 (select_possible_type_sym): Change type of syms. Remove nsyms
3776 parameter.
3777 (write_var_or_type, write_name_assoc): Update.
3778
178d6a63
JB
37792018-06-04 Joel Brobecker <brobecker@adacore.com>
3780
3781 * windows-nat.c (windows_nat_target::xfer_partial): Return
3782 TARGET_XFER_E_IO if we need to delegate to the target beneath
3783 but BENEATH is NULL.
3784
baf00c2d
SM
37852018-06-04 Simon Marchi <simon.marchi@ericsson.com>
3786
3787 * Makefile.in (config.status): Add configure.nat as a
3788 dependency.
3789
214b073c
TT
37902018-06-04 Tom Tromey <tom@tromey.com>
3791
3792 * cp-name-parser.y (cpname_state): Add method declarations.
3793 (HANDLE_QUAL): Update.
3794 (cpname_state::d_grab, cpname_state::fill_comp)
3795 (cpname_state::make_operator, cpname_state::make_dtor)
3796 (cpname_state::make_builtin_type, cpname_state::make_name)
3797 (cpname_state::d_qualify, cpname_state::d_int_type)
3798 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
3799 (%union): Move earlier.
3800
62b74cb8
AH
38012018-06-04 Alan Hayward <alan.hayward@arm.com>
3802
3803 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
3804
3c5cd5c3
AH
38052018-06-04 Alan Hayward <alan.hayward@arm.com>
3806
3807 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
3808 (aarch64_pseudo_write_1): Likewise.
3809 (aarch64_pseudo_read_value): Use helper.
3810 (aarch64_pseudo_write): Likewise.
3811
59f413d5
PA
38122018-06-04 Pedro Alves <palves@redhat.com>
3813
3814 * darwin-nat.c (darwin_ops): Delete.
3815 (darwin_attach_pid): Use get_native_target.
3816
1332a140
AH
38172018-06-04 Alan Hayward <alan.hayward@arm.com>
3818
3819 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
3820 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
3821
ba2d2bb2
AH
38222018-06-04 Alan Hayward <alan.hayward@arm.com>
3823
3824 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
3825 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
3826 (aarch64_gdbarch_init): Check for SVE.
3827 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
3828
38292018-06-04 Alan Hayward <alan.hayward@arm.com>
39bfb937
AH
3830
3831 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
3832 * aarch64-tdep.h (aarch64_read_description): Likewise.
3833 * arch/aarch64.c (aarch64_create_target_description): Likewise.
3834 * arch/aarch64.h (aarch64_create_target_description): Likewise.
3835 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
3836 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
3837 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
3838
41c60b4b
SM
38392018-06-02 Simon Marchi <simon.marchi@ericsson.com>
3840
3841 * value.c (value_fetch_lazy_bitfield): New.
3842 (value_fetch_lazy_memory): New.
3843 (value_fetch_lazy_register): New.
3844 (value_fetch_lazy): Factor out to smaller functions.
3845
7b640f72
TT
38462018-06-01 Tom Tromey <tom@tromey.com>
3847
3848 * cp-name-parser.y (backslashable, represented): Now const.
3849
98e69eb3
TT
38502018-06-01 Tom Tromey <tom@tromey.com>
3851
3852 * cp-name-parser.y: Include parser-defs.h.
3853 (parser_fprintf): Remove declaration.
3854
49265499
TT
38552018-06-01 Tom Tromey <tom@tromey.com>
3856
3857 * cp-name-parser.y: Use %pure-parser, %lex-param, and
3858 %parse-param.
3859 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
3860 (global_result): Remove globals.
3861 (struct cpname_state): New.
3862 (yyparse): Don't declare.
3863 (yylex, yyerror): Move declarations after %union.
3864 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
3865 (make_name): Add state parameter.
3866 Update all callers.
3867 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
3868 parameter.
3869 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
3870 Update.
3871 (yylex): Add lvalp, state parameters.
3872 (yyerror): Add state parameter.
3873 (cp_demangled_name_to_comp): Update.
3874
55b6c984
TT
38752018-06-01 Tom Tromey <tom@tromey.com>
3876
3877 * cp-name-parser.y (parser_fprintf): Declare.
3878 (GDB_YY_REMAP_PREFIX): Define.
3879 Include yy-remap.h. Don't redefine yy* identifiers.
3880
3513a6bb
TT
38812018-06-01 Tom Tromey <tom@tromey.com>
3882
3883 * python/py-type.c (typy_legacy_template_argument): Update.
3884 * cp-support.h (cp_demangled_name_to_comp): Update.
3885 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
3886 parameter to be a "std::string *".
3887 (main): Update.
3888
e9cb46ab
L
38892018-06-01 H.J. Lu <hongjiu.lu@intel.com>
3890
3891 * ada-lex.l: Include "diagnostics.h" instead of
3892 "common/diagnostics.h".
3893 * unittests/environ-selftests.c: Likewise.
3894 * common/diagnostics.h: Moved to ../include.
3895
8e817061
JB
38962018-06-01 Joel Brobecker <brobecker@adacore.com>
3897
3898 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
3899 to language_mode_manual while calling breakpoint_re_set_one.
3900
a737d952
TT
39012018-06-01 Tom Tromey <tom@tromey.com>
3902
3903 * valops.c (value_cast_structs, destructor_name_p): Update.
3904 * symtab.c (gdb_mangle_name): Update.
3905 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
3906 Update.
3907 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
3908 (pascal_object_print_value_fields, pascal_object_print_value):
3909 Update.
3910 * p-typeprint.c (pascal_type_print_derivation_info): Update.
3911 * linespec.c (find_methods): Update.
3912 * gdbtypes.h (type_name_no_tag): Remove.
3913 (type_name_or_error): Rename from type_name_no_tag_or_error.
3914 * gdbtypes.c (type_name_no_tag): Remove.
3915 (type_name_or_error): Rename from type_name_no_tag_or_error.
3916 (lookup_struct_elt_type, check_typedef): Update.
3917 * expprint.c (print_subexp_standard): Update.
3918 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
3919 * d-namespace.c (d_lookup_nested_symbol): Update.
3920 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
3921 (cp_print_class_member): Update.
3922 * cp-namespace.c (cp_lookup_nested_symbol): Update.
3923 * completer.c (add_struct_fields): Update.
3924 * c-typeprint.c (cp_type_print_derivation_info)
3925 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
3926 Update.
3927 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
3928 (ada_prefer_type, ada_is_exception_sym): Update.
3929
e86ca25f
TT
39302018-06-01 Tom Tromey <tom@tromey.com>
3931
3932 * valops.c (enum_constant_from_type, value_namespace_elt)
3933 (value_maybe_namespace_elt): Update.
3934 * valarith.c (find_size_for_pointer_math): Update.
3935 * target-descriptions.c (make_gdb_type): Update.
3936 * symmisc.c (print_symbol): Update.
3937 * stabsread.c (define_symbol, read_type)
3938 (complain_about_struct_wipeout, add_undefined_type)
3939 (cleanup_undefined_types_1): Update.
3940 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
3941 (rust_range_type_p, val_print_struct, rust_print_struct_def)
3942 (rust_internal_print_type, rust_composite_type)
3943 (rust_evaluate_funcall, rust_evaluate_subexp)
3944 (rust_inclusive_range_type_p): Update.
3945 * python/py-type.c (typy_get_tag): Update.
3946 * p-typeprint.c (pascal_type_print_base): Update.
3947 * mdebugread.c (parse_symbol, parse_type): Update.
3948 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
3949 Update.
3950 * guile/scm-type.c (gdbscm_type_tag): Update.
3951 * go-lang.c (sixg_string_p): Update.
3952 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
3953 Update.
3954 * gdbtypes.h (struct main_type) <tag_name>: Remove.
3955 (TYPE_TAG_NAME): Remove.
3956 * gdbtypes.c (type_name_no_tag): Simplify.
3957 (check_typedef, check_types_equal, recursive_dump_type)
3958 (copy_type_recursive, arch_composite_type): Update.
3959 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
3960 in summary mode when needed.
3961 * eval.c (evaluate_funcall): Update.
3962 * dwarf2read.c (fixup_go_packaging, read_structure_type)
3963 (process_structure_scope, read_enumeration_type)
3964 (read_namespace_type, read_module_type, determine_prefix): Update.
3965 * cp-support.c (inspect_type): Update.
3966 * coffread.c (process_coff_symbol, decode_base_type): Update.
3967 * c-varobj.c (c_is_path_expr_parent): Update.
3968 * c-typeprint.c (c_type_print_base_struct_union): Update.
3969 (c_type_print_base_1): Update. Print struct/class/union/enum in
3970 summary when using C language.
3971 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
3972 (gen_maybe_namespace_elt): Update.
3973 * ada-lang.c (ada_type_name): Simplify.
3974 (empty_record, ada_template_to_fixed_record_type_1)
3975 (template_to_static_fixed_type)
3976 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
3977
c1ec8cea
TT
39782018-06-01 Tom Tromey <tom@tromey.com>
3979
3980 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
3981 c_print_type.
3982 * c-typeprint.c (c_print_type_1): Add "language" parameter.
3983 (c_print_type): Update.
3984 (c_print_type): New overload.
3985 (c_type_print_varspec_prefix, c_type_print_args)
3986 (c_type_print_varspec_suffix, c_print_type_no_offsets)
3987 (c_type_print_base_struct_union, c_type_print_base_1)
3988 (cp_type_print_method_args): Add "language" parameter.
3989 (c_type_print_base): Update.
3990 * c-lang.h (c_print_type): Add new overload.
3991
bc8453a7
TT
39922018-06-01 Tom Tromey <tom@tromey.com>
3993
3994 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
3995 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
3996
739e8682
AH
39972018-06-01 Alan Hayward <alan.hayward@arm.com>
3998
3999 * aarch64-tdep.c (aarch64_sve_register_names): New const
4000 var.
4001 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
4002 (AARCH64_SVE_Z_REGS_NUM): New define.
4003 (AARCH64_SVE_P_REGS_NUM): Likewise.
4004 (AARCH64_SVE_NUM_REGS): Likewise.
4005
8a60efe7
UB
40062018-05-31 Uros Bizjak <ubizjak@gmail.com>
4007
4008 * nat/linux-ptrace.h [__alpha__]
4009 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
4010 definitions.
4011
4b2dfa9d
MR
40122018-05-31 Maciej W. Rozycki <macro@mips.com>
4013
4014 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
4015 the endianness selected.
4016 * NEWS: Document `set endian auto' mode operation update.
4017
122394f1
AH
40182018-05-31 Alan Hayward <alan.hayward@arm.com>
4019
4020 * Makefile.in: Add new header.
4021 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
4022 (sve_vl_from_vg): Likewise.
4023 (sve_vq_from_vl): Likewise.
4024 (sve_vl_from_vq): Likewise.
4025 (sve_vq_from_vg): Likewise.
4026 (sve_vg_from_vq): Likewise.
4027 * configure.nat: Add new c file.
4028 * nat/aarch64-sve-linux-ptrace.c: New file.
4029 * nat/aarch64-sve-linux-ptrace.h: New file.
4030
95228a0d
AH
40312018-05-31 Alan Hayward <alan.hayward@arm.com>
4032
4033 * aarch64-linux-nat.c (aarch64_linux_read_description):
4034 Add parmeter zero.
4035 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
4036 Likewise.
4037 * aarch64-tdep.c (tdesc_aarch64_list): Add.
4038 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
4039 (aarch64_gdbarch_init): Add parmeter zero.
4040 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
4041 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
4042 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
4043 parmeter.
4044 * doc/gdb.texinfo: Describe SVE feature
4045 * features/aarch64-sve.c: New file.
4046
5969f0db
OJ
40472018-05-31 Omair Javaid <omair.javaid@linaro.org>
4048
4049 PR gdb/23210
4050 * gdbarch.sh (significant_addr_bit): Default to zero when
4051 not set by target architecture.
4052 * gdbarch.c: Re-generated.
4053 * utils.c (address_significant): Update.
4054
61367c61
JB
40552018-05-30 Joel Brobecker <brobecker@adacore.com>
4056
4057 * stack.c (func_command): Remove trailing newline in call to error.
4058
34a79281
SM
40592018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4060
4061 * regcache.h (regcache_raw_collect): Remove, update callers to
4062 use regcache::raw_collect.
4063 * regcache.c (regcache_raw_collect): Remove.
4064
73e1c03f
SM
40652018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4066
4067 * regcache.h (regcache_raw_supply): Remove, update callers to
4068 use detached_regcache::raw_supply.
4069 * regcache.c (regcache_raw_supply): Remove.
4070
e4c4a59b
SM
40712018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4072
4073 * regcache.h (regcache_cooked_write_part): Remove, update
4074 callers to use regcache::cooked_write_part.
4075 * regcache.c (regcache_cooked_write_part): Remove.
4076
73bb0000
SM
40772018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4078
4079 * regcache.h (regcache_cooked_read_part): Remove, update callers
4080 to use readable_regcache::cooked_read_part.
4081 * regcache.c (regcache_cooked_read_part): Remove.
4082
46a45e9d
SM
40832018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4084
4085 * regcache.h (regcache_cooked_read_value): Remove, update
4086 callers to use readable_regcache::cooked_read_value.
4087 * regcache.c (regcache_cooked_read_value): Remove.
4088
b66f5587
SM
40892018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4090
4091 * regcache.h (regcache_cooked_write): Remove, update callers to
4092 use regcache::cooked_write.
4093 * regcache.c (regcache_cooked_write): Remove.
4094
6aa7d724
SM
40952018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4096
4097 * regcache.h (regcache_invalidate): Remove, update callers to
4098 use detached_regcache::invalidate instead.
4099 * regcache.c (regcache_invalidate): Remove.
4100
4f0420fd
SM
41012018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4102
4103 * regcache.h (regcache_raw_write_part): Remove, update callers
4104 to use regcache::raw_write_part instead.
4105 * regcache.c (regcache_raw_write_part): Remove.
4106
502fe83e
SM
41072018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4108
4109 * regcache.h (regcache_raw_read_part): Remove, update callers to
4110 use readable_regcache::raw_read_part instead.
4111 * regcache.c (regcache_raw_read_part): Remove.
4112
dca08e1f
SM
41132018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4114
4115 * regcache.h (regcache_cooked_read): Remove, update callers to
4116 use readable_regcache::cooked_read instead.
4117 * regcache.c (regcache_cooked_read): Remove.
4118
10eaee5f
SM
41192018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4120
4121 * regcache.h (regcache_raw_write): Remove, update callers to use
4122 regcache::raw_write instead.
4123 * regcache.c (regcache_raw_write): Remove.
4124
0b883586
SM
41252018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4126
4127 * regcache.h (regcache_raw_read): Remove, update callers to use
4128 readable_regcache::raw_read instead.
4129 * regcache.c (regcache_raw_read): Remove.
4130
0b47d985
SM
41312018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4132
4133 * regcache.h (regcache_raw_update): Remove, update callers to
4134 use readable_regcache::raw_update instead.
4135 * regcache.c (regcache_raw_update): Remove.
4136
0ec9f114
SM
41372018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4138
4139 * regcache.h (regcache_register_status): Remove, update callers
4140 to use reg_buffer::get_register_status directly instead.
4141 * regcache.c (regcache_register_status): Remove.
4142
222312d3
SM
41432018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4144
4145 * regcache.h (regcache_get_ptid): Remove, update all callers to
4146 call regcache::ptid instead.
4147 * regcache.c (regcache_get_ptid): Remove.
4148
fdbe37e3
SM
41492018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4150
4151 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
4152
f7c6f423
PA
41532018-05-30 Pedro Alves <palves@redhat.com>
4154
4155 * common/common-exceptions.h (exception_rethrow): Use
4156 ATTRIBUTE_NORETURN.
4157
52941706
SM
41582018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
4159
4160 * breakpoint.c (print_solib_event, check_status_catch_solib):
4161 Remove struct keyword in range-based for loops.
4162 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
4163 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
4164 Likewise.
4165 * linespec.c (find_superclass_methods, search_minsyms_for_name):
4166 Likewise.
4167 * symfile.c (addr_info_make_relative): Likewise.
4168 * thread.c (value_in_thread_stack_temporaries): Likewise.
4169
bf2977b5
WP
41702018-06-12 Weimin Pan <weimin.pan@oracle.com>
4171
4172 PR gdb/16841
4173 * valops.c (value_struct_elt_for_reference): Call check_typedef on
4174 aggregate type to get its real type before accessing it.
4175
64cc34d8
WP
41762018-05-29 Weimin Pan <weimin.pan@oracle.com>
4177
4178 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
4179 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
4180 * coff-pe-read.c (add_pe_forwarded_sym): Replace
4181 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
4182 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
4183 * jit.c (jit_breakpoint_re_set_internal): Likewise.
4184 * printcmd.c (info_address_command): Likewise.
4185
e7ec8713
TT
41862018-05-29 Tom Tromey <tom@tromey.com>
4187
4188 * windows-nat.c (handle_exception): Update fall-through comment.
4189
bcb430e4
TT
41902018-05-29 Tom Tromey <tom@tromey.com>
4191
4192 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
4193 (struct program_space) <added_solibs>: Now a std::vector.
4194 * breakpoint.c (print_solib_event): Update.
4195 (check_status_catch_solib): Update.
4196 * progspace.c (clear_program_space_solib_cache): Update.
4197 * solib.c (update_solib_list): Update.
4198
894882e3
TT
41992018-05-29 Tom Tromey <tom@tromey.com>
4200
4201 * python/py-type.c (typy_richcompare): Update.
4202 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
4203 * gdbtypes.h (types_deeply_equal): Return bool.
4204 (types_equal): Likewise.
4205 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
4206 declare VEC.
4207 (check_types_equal): Change worklist to std::vector. Return
4208 bool.
4209 (struct type_equality_entry): Add constructor.
4210 (compare_maybe_null_strings): Return bool.
4211 (check_types_worklist): Return bool. Change worklist to
4212 std::vector.
4213 (types_deeply_equal): Use std::vector.
4214 (types_equal): Return bool.
4215 (compare_maybe_null_strings): Simplify.
4216
10b2ded4
TT
42172018-05-29 Tom Tromey <tom@tromey.com>
4218
4219 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
4220
4f7deebe
TT
42212018-05-29 Tom Tromey <tom@tromey.com>
4222
4223 * objc-lang.h: Don't include cp-support.h.
4224 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
4225 declare VEC.
4226
b8283aea
TT
42272018-05-27 Tom Tromey <tom@tromey.com>
4228
4229 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
4230
41a883c8
TT
42312018-05-25 Tom Tromey <tom@tromey.com>
4232
4233 * value.c (value::location): Initialize.
4234
bf259e25
TT
42352018-05-25 Tom Tromey <tom@tromey.com>
4236
4237 * dbxread.c (init_bincl_list): Remove.
4238 (bincl_list): Now a std::vector.
4239 (bincls_allocated, next_bincl): Remove.
4240 (free_bincl_list, do_free_bincl_list_cleanup)
4241 (make_cleanup_free_bincl_list): Remove.
4242 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
4243 unique_xmalloc_ptr.
4244 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
4245 (struct header_file_location): Add constructor.
4246 (add_bincl_to_list): Remove.
4247
d525a99b
TT
42482018-05-25 Tom Tromey <tom@tromey.com>
4249
4250 * tui/tui.c (tui_enable): Update.
4251 * mi/mi-interp.c (mi_interp::init): Update.
4252 * interps.h (class interp) <name>: New method.
4253 <m_name>: Rename from name.
4254 (~scoped_restore_interp): Update.
4255 * interps.c (interp::interp): Update.
4256 (interp_add, interp_set, interp_lookup_existing)
4257 (current_interp_named_p): Update.
4258
da505cff
TT
42592018-05-25 Tom Tromey <tom@tromey.com>
4260
4261 * interps.c (interp_name): Remove.
4262 * mi/mi-interp.c (mi_interp::init): Update.
4263 * interps.h (interp_name): Remove.
4264 (~scoped_restore_interp): Update.
4265 * tui/tui.c (tui_enable): Update.
4266
29f94340
TT
42672018-05-25 Tom Tromey <tom@tromey.com>
4268
4269 * utils.c (fputs_maybe_filtered): Update.
4270 * linespec.c (decode_line_full): Update.
4271 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
4272 (mi_print_breakpoint_for_event, mi_solib_loaded)
4273 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
4274 (mi_user_selected_context_changed): Update.
4275 * mi/mi-main.c (mi_execute_command): Update.
4276 * cli/cli-script.c (execute_control_command): Update.
4277 * python/python.c (execute_gdb_command): Update.
4278 * solib.c (info_sharedlibrary_command): Update.
4279 * interps.c (interp_ui_out): Remove.
4280 * interps.h (interp_ui_out): Remove.
4281
716b8bc5
TT
42822018-05-25 Tom Tromey <tom@tromey.com>
4283
4284 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
4285 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
4286 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
4287
753ff9bd
TT
42882018-05-25 Tom Tromey <tom@tromey.com>
4289
4290 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
4291 * interps.c (interp_exec): Use scoped_restore.
4292
5ca3b260
TT
42932018-05-25 Tom Tromey <tom@tromey.com>
4294
4295 * remote.c (remote_target::remote_file_get): Use
4296 gdb::byte_vector.
4297 (remote_target::remote_file_put): Likewise.
4298
3173aa2f
TT
42992018-05-25 Tom Tromey <tom@tromey.com>
4300
4301 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
4302 a std::string.
4303 (get_pe_section_index, add_pe_exported_sym): Update.
4304 (read_pe_exported_syms): Use gdb::def_vector.
4305
09a5e1b5
TT
43062018-05-25 Tom Tromey <tom@tromey.com>
4307
4308 * frame.c (remove_prev_frame): Remove.
4309 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
4310
d8dab6c3
MR
43112018-05-25 Maciej W. Rozycki <macro@mips.com>
4312
4313 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
4314 Remove prototypes.
4315 * mips-linux-nat.c (supply_fpregset): Always call
4316 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
4317 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
4318 `mips_fill_fpregset'.
4319 * mips-linux-tdep.c (mips_supply_fpregset)
4320 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
4321 (mips_fill_fpregset_wrapper): Remove functions.
4322 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
4323 (mips_linux_fpregset): Remove variable.
4324 (mips_linux_iterate_over_regset_sections): Use
4325 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
4326 (mips_linux_o32_sigframe_init): Remove comment.
4327
3c69da40
PA
43282018-05-25 Pedro Alves <palves@redhat.com>
4329
4330 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
4331 (struct readahead_cache, struct packet_reg, struct
4332 remote_arch_state, class remote_state): Move higher up in the
4333 file.
4334 (remote_target::m_remote_state): Now an object instead of a pointer.
4335 (remote_target::get_remote_state): Adjust.
4336
39f0c204
AB
43372018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
4338
4339 * stack.c (select_and_print_frame): Delete.
4340 (struct function_bounds): Move struct within function.
4341 (func_command): Most content moved into new function
4342 find_frame_for_function, use new function, print result, add
4343 function comment.
4344 (find_frame_for_function): New function, now returns a result.
4345
d392224a
PW
43462018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4347
4348 * stack.c (iterate_over_block_arg_vars): Fix comment.
4349 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
4350
45f25d6c
AB
43512018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
4352
4353 PR gdb/23203
4354 * frame.c
4355 (scoped_restore_selected_frame::scoped_restore_selected_frame):
4356 Define.
4357 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
4358 Define.
4359 * frame.h (class scoped_restore_selected_frame): New class.
4360 * stack.c (print_frame_local_vars): Remove catching and rethrowing
4361 of any exception, use scoped_restore_selected_frame to restore the
4362 frame instead.
4363
da05d921
PA
43642018-05-24 Pedro Alves <palves@redhat.com>
4365
4366 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
4367 override.
4368
a8be540e
TT
43692018-05-23 Tom Tromey <tom@tromey.com>
4370
4371 * complaints.c (struct complaints): Remove.
4372 (symfile_complaint_book): Remove.
4373 (series): New global.
4374 (complaint_internal): Update.
4375 (clear_complaints): Update.
4376
ff1cf532
TT
43772018-05-23 Tom Tromey <tom@tromey.com>
4378
4379 * complaints.c (counters): New global.
4380 (struct complain): Remove.
4381 (struct complaints) <root>: Remove.
4382 (complaint_sentinel): Remove.
4383 (symfile_complaint_book): Update.
4384 (find_complaint) Remove.
4385 (complaint_internal, clear_complaints): Update.
4386
7ff88174
TT
43872018-05-23 Tom Tromey <tom@tromey.com>
4388
4389 * complaints.c (struct complain) <file, line>: Remove.
4390 (find_complaint): Remove file, line parameters.
4391 (complaint_internal): Update.
4392
de54e1a5
TT
43932018-05-23 Tom Tromey <tom@tromey.com>
4394
4395 * complaints.c (vcomplaint): Remove.
4396 (complaint_internal) Merge in contents of vcomplaint.
4397
2ac237e5
TT
43982018-05-23 Tom Tromey <tom@tromey.com>
4399
4400 * complaints.c (struct complaints) <explanation>: Remove.
4401 (symfile_explanations): Remove.
4402 (symfile_complaint_book): Update.
4403 (vcomplaint): Update.
4404 (struct explanation): Remove.
4405
b98664d3
TT
44062018-05-23 Tom Tromey <tom@tromey.com>
4407
4408 * complaints.c (symfile_complaints): Remove.
4409 (complaint_internal): Remove "complaints" parameter.
4410 (clear_complaints, vcomplaint): Remove "c" parameter.
4411 (get_complaints): Remove.
4412 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
4413 (dwarf2_debug_line_missing_file_complaint)
4414 (dwarf2_debug_line_missing_end_sequence_complaint)
4415 (dwarf2_complex_location_expr_complaint)
4416 (dwarf2_const_value_length_mismatch_complaint)
4417 (dwarf2_section_buffer_overflow_complaint)
4418 (dwarf2_macro_malformed_definition_complaint)
4419 (dwarf2_invalid_attrib_class_complaint)
4420 (create_addrmap_from_index, dw2_symtab_iter_next)
4421 (dw2_expand_marked_cus)
4422 (dw2_debug_names_iterator::find_vec_in_debug_names)
4423 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
4424 (create_debug_type_hash_table, init_cutu_and_read_dies)
4425 (partial_die_parent_scope, add_partial_enumeration)
4426 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
4427 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
4428 (read_import_statement, read_file_scope, create_dwo_cu_reader)
4429 (create_cus_hash_table, create_dwp_hash_table)
4430 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
4431 (dwarf2_rnglists_process, dwarf2_ranges_process)
4432 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
4433 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
4434 (handle_struct_member_die, process_structure_scope)
4435 (read_array_type, read_common_block, read_module_type)
4436 (read_tag_pointer_type, read_typedef, read_base_type)
4437 (read_subrange_type, load_partial_dies, partial_die_info::read)
4438 (partial_die_info::read, partial_die_info::read)
4439 (partial_die_info::read, read_checked_initial_length_and_offset)
4440 (dwarf2_string_attr, read_formatted_entries)
4441 (dwarf_decode_line_header)
4442 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
4443 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
4444 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
4445 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
4446 (get_signatured_type, get_DW_AT_signature_type)
4447 (decode_locdesc, file_file_name, consume_improper_spaces)
4448 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
4449 (dwarf_decode_macro_bytes, dwarf_decode_macros)
4450 (dwarf2_symbol_mark_computed, set_die_type)
4451 (read_attribute_value): Update.
4452 * stap-probe.c (handle_stap_probe, get_stap_base_address):
4453 Update.
4454 * dbxread.c (unknown_symtype_complaint)
4455 (lbrac_mismatch_complaint, repeated_header_complaint)
4456 (set_namestring, function_outside_compilation_unit_complaint)
4457 (read_dbx_symtab, process_one_symbol): Update.
4458 * gdbtypes.c (stub_noname_complaint): Update.
4459 * windows-nat.c (handle_unload_dll): Update.
4460 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
4461 (decode_base_type): Update.
4462 * xcoffread.c (bf_notfound_complaint, ef_complaint)
4463 (eb_complaint, record_include_begin, record_include_end)
4464 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
4465 (process_xcoff_symbol, read_symbol)
4466 (function_outside_compilation_unit_complaint)
4467 (scan_xcoff_symtab): Update.
4468 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
4469 * buildsym.c (finish_block_internal, make_blockvector)
4470 (end_symtab_get_static_block, augment_type_symtab): Update.
4471 * dtrace-probe.c (dtrace_process_dof)
4472 (dtrace_static_probe_ops::get_probes): Update.
4473 * complaints.h (struct complaint): Don't declare.
4474 (symfile_complaints): Remove.
4475 (complaint_internal): Remove "complaints" parameter.
4476 (complaint): Likewise.
4477 (clear_complaints): Likewise.
4478 * symfile.c (syms_from_objfile_1, finish_new_objfile)
4479 (reread_symbols): Update.
4480 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
4481 (dwarf2_frame_cache, decode_frame_entry): Update.
4482 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
4483 * objc-lang.c (lookup_objc_class, lookup_child_selector)
4484 (info_selectors_command): Update.
4485 * macrotab.c (macro_include, check_for_redefinition)
4486 (macro_undef): Update.
4487 * objfiles.c (filter_overlapping_sections): Update.
4488 * stabsread.c (invalid_cpp_abbrev_complaint)
4489 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
4490 (define_symbol, error_type, read_type, rs6000_builtin_type)
4491 (stabs_method_name_from_physname, read_member_functions)
4492 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
4493 (attach_fields_to_type, complain_about_struct_wipeout)
4494 (read_range_type, read_args, common_block_start)
4495 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
4496 Update.
4497 * mdebugread.c (index_complaint, unknown_ext_complaint)
4498 (basic_type_complaint, bad_tag_guess_complaint)
4499 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
4500 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
4501 (parse_procedure, parse_lines)
4502 (function_outside_compilation_unit_complaint)
4503 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
4504 (bad_tag_guess_complaint, reg_value_complaint): Update.
4505 * cp-support.c (demangled_name_complaint): Update.
4506 * macroscope.c (sal_macro_scope): Update.
4507 * dwarf-index-write.c (class debug_names): Update.
4508
4e9668d0
TT
45092018-05-23 Tom Tromey <tom@tromey.com>
4510
4511 * complaints.c (clear_complaints): Remove "noisy" parameter.
4512 * complaints.h (clear_complaints): Update.
4513 * symfile.c (syms_from_objfile_1, finish_new_objfile)
4514 (reread_symbols): Update.
4515
43ba33c7
TT
45162018-05-23 Tom Tromey <tom@tromey.com>
4517
4518 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
4519 SUBSEQUENT_MESSAGE.
4520 (vcomplaint, clear_complaints): Update.
4521 (symfile_explanations): Remove some messages.
4522
2b9496b2
TT
45232018-05-23 Tom Tromey <tom@tromey.com>
4524
4525 * complaints.c (internal_complaint): Remove.
4526 * complaints.h (internal_complaint): Remove.
4527
35f1fea3
MR
45282018-05-22 Maciej W. Rozycki <macro@mips.com>
4529
4530 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
4531
6b8edb51
PA
45322018-05-22 Pedro Alves <palves@redhat.com>
4533
4534 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
4535 (remote_fileio_badfd, remote_fileio_return_errno)
4536 (remote_fileio_return_success, remote_fileio_func_open)
4537 (remote_fileio_func_open, remote_fileio_func_close)
4538 (remote_fileio_func_read, remote_fileio_func_write)
4539 (remote_fileio_func_lseek, remote_fileio_func_rename)
4540 (remote_fileio_func_unlink, remote_fileio_func_stat)
4541 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
4542 (remote_fileio_func_isatty, remote_fileio_func_system): Add
4543 remote_target parameter.
4544 (remote_fio_func_map) <func>: Add remote_target parameter.
4545 (do_remote_fileio_request, remote_fileio_request):
4546 * remote-fileio.h (remote_fileio_request):
4547 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
4548 remote_target parameter.
4549 (remote_notif_process, handle_notification): Adjust to pass down
4550 the remote.
4551 (remote_notif_state_allocate): Add remote_target parameter. Save
4552 it.
4553 * remote-notif.h (struct remote_target): Forward declare.
4554 (struct notif_client) <parse, ack, can_get_pending_events>: Add
4555 remote_target parameter.
4556 (struct remote_notif_state) <remote>: New field.
4557 (remote_notif_ack, remote_notif_parse): Add remote_target
4558 parameter.
4559 (remote_notif_state_allocate, remote_notif_state_allocate): Add
4560 remote_target parameter.
4561 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
4562 (threads_listing_context, rmt_thread_action, protocol_feature)
4563 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
4564 (packet_result, struct threads_listing_context, remote_state):
4565 Move definitions and declarations higher up.
4566 (remote_target) <~remote_target>: Declare.
4567 (remote_download_command_source, remote_file_put, remote_file_get)
4568 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
4569 (remote_hostio_pread_vFile, remote_hostio_send_command)
4570 (remote_hostio_set_filesystem, remote_hostio_open)
4571 (remote_hostio_close, remote_hostio_unlink, remote_state)
4572 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
4573 (get_memory_write_packet_size, get_memory_read_packet_size)
4574 (append_pending_thread_resumptions, remote_detach_1)
4575 (append_resumption, remote_resume_with_vcont)
4576 (add_current_inferior_and_thread, wait_ns, wait_as)
4577 (process_stop_reply, remote_notice_new_inferior)
4578 (process_initial_stop_replies, remote_add_thread)
4579 (btrace_sync_conf, remote_btrace_maybe_reopen)
4580 (remove_new_fork_children, kill_new_fork_children)
4581 (discard_pending_stop_replies, stop_reply_queue_length)
4582 (check_pending_events_prevent_wildcard_vcont)
4583 (discard_pending_stop_replies_in_queue, stop_reply)
4584 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
4585 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
4586 (remote_interrupt_as, remote_interrupt_ns)
4587 (remote_get_noisy_reply, remote_query_attached)
4588 (remote_add_inferior, remote_current_thread, get_current_thread)
4589 (set_thread, set_general_thread, set_continue_thread)
4590 (set_general_process, write_ptid)
4591 (remote_unpack_thread_info_response, remote_get_threadinfo)
4592 (parse_threadlist_response, remote_get_threadlist)
4593 (remote_threadlist_iterator, remote_get_threads_with_ql)
4594 (remote_get_threads_with_qxfer)
4595 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
4596 (get_offsets, remote_check_symbols, remote_supported_packet)
4597 (remote_query_supported, remote_packet_size)
4598 (remote_serial_quit_handler, remote_detach_pid)
4599 (remote_vcont_probe, remote_resume_with_hc)
4600 (send_interrupt_sequence, interrupt_query)
4601 (remote_notif_get_pending_events, fetch_register_using_p)
4602 (send_g_packet, process_g_packet, fetch_registers_using_g)
4603 (store_register_using_P, store_registers_using_G)
4604 (set_remote_traceframe, check_binary_download)
4605 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
4606 (remote_xfer_live_readonly_partial, remote_read_bytes)
4607 (remote_send_printf, remote_flash_write, readchar)
4608 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
4609 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
4610 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
4611 (extended_remote_disable_randomization, extended_remote_run)
4612 (send_environment_packet, extended_remote_environment_support)
4613 (extended_remote_set_inferior_cwd, remote_write_qxfer)
4614 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
4615 (packet_command): Now methods of ...
4616 (remote_target): ... this class.
4617 (m_remote_state) <remote_target>: New field.
4618 (struct remote_state) <stop_reply_queue,
4619 remote_async_inferior_event_token, wait_forever_enabled_p>: New
4620 fields.
4621 (remote_state::remote_state): Allocate stop_reply_queue.
4622 (remote_state): Delete global.
4623 (get_remote_state_raw): Delete.
4624 (remote_target::get_remote_state): Allocate m_remote_state on
4625 demand.
4626 (get_current_remote_target): New.
4627 (remote_ops, extended_remote_ops): Delete.
4628 (wait_forever_enabled_p, remote_async_inferior_event_token):
4629 Delete, moved to struct remote_state.
4630 (remote_target::close): Delete self. Destruction bits split to
4631 ...
4632 (remote_target::~remote_target): ... this.
4633 (show_memory_packet_size): Adjust to use
4634 get_current_remote_target.
4635 (struct protocol_feature) <func>: Add remote_target parameter.
4636 All callers adjusted.
4637 (curr_quit_handler_target): New.
4638 (remote_serial_quit_handler): Reimplement.
4639 (remote_target::open_1): Adjust to use get_current_remote_target.
4640 Heap-allocate remote_target/extended_remote_target instances.
4641 (vcont_builder::vcont_builder): Add remote_target parameter, and
4642 save it in m_remote. All callers adjusted.
4643 (vcont_builder::m_remote): New field.
4644 (vcont_builder::restart, vcont_builder::flush)
4645 (vcont_builder::push_action): Use it.
4646 (remote_target::commit_resume): Use it.
4647 (struct queue_iter_param) <remote>: New field.
4648 (remote_target::remove_new_fork_children): Fill in 'remote' field.
4649 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
4650 (check_pending_event_prevents_wildcard_vcont_callback)
4651 (remote_target::check_pending_events_prevent_wildcard_vcont)
4652 (remote_target::discard_pending_stop_replies)
4653 (remote_target::discard_pending_stop_replies_in_queue)
4654 (remote_target::remote_notif_remove_queued_reply): Fill in
4655 'remote' field.
4656 (remote_notif_get_pending_events): New.
4657 (remote_target::readchar, remote_target::remote_serial_write):
4658 Save/restore curr_quit_handler_target.
4659 (putpkt): New.
4660 (kill_new_fork_children): Fill in 'remote' field.
4661 (packet_command): Use get_current_remote_target, defer to
4662 remote_target method of same name.
4663 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
4664 parameter, and save it in m_remote. All callers adjusted.
4665 (scoped_remote_fd::release): Use m_remote.
4666 (scoped_remote_fd::m_remote): New field.
4667 (remote_file_put, remote_file_get, remote_file_delete): Use
4668 get_current_remote_target, defer to remote_target method of same
4669 name.
4670 (remote_btrace_reset): Add remote_state paremeter. Update all
4671 callers.
4672 (remote_async_inferior_event_handler). Pass down 'data'.
4673 (remote_new_objfile): Use get_current_remote_target.
4674 (remote_target::vcont_r_supported): New.
4675 (set_range_stepping): Use get_current_remote_target and
4676 remote_target::vcont_r_supported.
4677 (_initialize_remote): Don't allocate 'remote_state' and
4678 'stop_reply_queue' globals.
4679 * remote.h (struct remote_target): Forward declare.
4680 (getpkt, putpkt, remote_notif_get_pending_events): Add
4681 'remote_target' parameter.
4682
f5db4863
PA
46832018-05-22 Pedro Alves <palves@redhat.com>
4684
4685 * remote.c (vcont_builder): Now a class. Make all data members
4686 private.
4687 (vcont_builder) <vcont_builder, restart, flush, push_action>:
4688 Declare methods.
4689 (vcont_builder_restart): Rename to ...
4690 (vcont_builder::restart): ... this.
4691 (vcont_builder_flush): Rename to ...
4692 (vcont_builder::flush): ... this.
4693 (vcont_builder_push_action): Rename to ...
4694 (vcont_builder::push_action): ... this.
4695 (remote_target::commit_resume): Adjust.
4696
cc0be08f
PA
46972018-05-22 Pedro Alves <palves@redhat.com>
4698
4699 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
4700 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
4701 (get_fixed_memory_packet_size): New.
4702 (get_memory_packet_size): Use it.
4703 (set_memory_packet_size): Don't override the config size with
4704 DEFAULT_MAX_MEMORY_PACKET_SIZE.
4705 (show_memory_packet_size): Use get_fixed_memory_packet_size.
4706 Don't refer to get_memory_packet_size if not connected to a remote
4707 target. Show "(default)" if configured size is 0.
4708
9607784a
PA
47092018-05-22 Pedro Alves <palves@redhat.com>
4710
4711 * remote.c (remote_target::mourn_inferior): Move
4712 discard_pending_stop_replies call here from ...
4713 (_initialize_remote): ... here.
4714
0e9a6b2f
PA
47152018-05-22 Pedro Alves <palves@redhat.com>
4716
4717 * remote.c (compare_section_command): Remove set_general_process
4718 call.
4719
43c3a0e4
PA
47202018-05-22 Pedro Alves <palves@redhat.com>
4721
4722 * remote.c (struct packet_reg, struct remote_arch_state):
4723 Move higher up in the file.
4724 (remote_state) <m_arch_states>: Store remote_arch_state values
4725 instead of remote_arch_state pointers.
4726 (remote_state::get_remote_arch_state): Adjust.
4727
9d6eea31
PA
47282018-05-22 Pedro Alves <palves@redhat.com>
4729
4730 * remote.c: Include <unordered_map>.
4731 (remote_state): Now a class.
4732 (remote_state) <get_remote_arch_state>: Declare method.
4733 <get_remote_arch_state>: New field.
4734 (remote_arch_state) <remote_arch_state>: Declare ctor.
4735 <regs>: Now a unique_ptr.
4736 (remote_gdbarch_data_handle): Delete.
4737 (get_remote_arch_state): Delete.
4738 (remote_state::get_remote_arch_state): New.
4739 (get_remote_state): Adjust to call remote_state's
4740 get_remote_arch_state method.
4741 (init_remote_state): Delete, bits factored out to ...
4742 (remote_arch_state::remote_arch_state): ... this new method.
4743 (get_remote_packet_size, get_memory_packet_size)
4744 (process_g_packet, remote_target::fetch_registers)
4745 (remote_target::prepare_to_store, store_registers_using_G)
4746 (remote_target::store_registers, remote_target::get_trace_status):
4747 Adjust to call remote_state's method.
4748 (_initialize_remote): Remove reference to
4749 remote_gdbarch_data_handle.
4750
dd194f6b
PA
47512018-05-22 Pedro Alves <palves@redhat.com>
4752
4753 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
4754 pread>: New method declarations.
4755 (remote_target::open_1): Adjust.
4756 (readahead_cache_invalidate): Rename to ...
4757 (readahead_cache::invalidate): ... this, and adjust to be a class
4758 method.
4759 (readahead_cache_invalidate_fd): Rename to ...
4760 (readahead_cache::invalidate_fd): ... this, and adjust to be a
4761 class method.
4762 (remote_hostio_pwrite): Adjust.
4763 (remote_hostio_pread_from_cache): Rename to ...
4764 (readahead_cache::pread): ... this, and adjust to be a class
4765 method.
4766 (remote_hostio_close): Adjust.
4767
440b7aec
PA
47682018-05-22 Pedro Alves <palves@redhat.com>
4769
4770 * remote.c (remote_hostio_close_cleanup): Delete.
4771 (class scoped_remote_fd): New.
4772 (remote_file_put, remote_file_get): Use it.
4773
de44f5a7
PA
47742018-05-22 Pedro Alves <palves@redhat.com>
4775
4776 (struct vCont_action_support): Use bool and initialize all fields.
4777 (struct readahead_cache): Initialize all fields.
4778 (remote_state): Use bool and initialize all fields.
4779 (remote_state::remote_state, remote_state::~remote_state): New.
4780 (new_remote_state): Delete.
4781 (_initialize_remote): Use new to allocate remote_state.
4782
b1b60145
PA
47832018-05-22 Pedro Alves <palves@redhat.com>
4784 張俊芝 <zjz@zjz.name>
4785
4786 PR gdb/22973
4787 * c-exp.y: Include "c-support.h".
4788 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
4789 of tolower. Use c_ident_is_alpha to scan names.
4790 * c-lang.c: Include "c-support.h".
4791 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
4792 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
4793 * c-support.h: New file, with bits factored out from ...
4794 * cp-name-parser.y: ... this file.
4795 Include "c-support.h".
4796 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
4797 c-support.h and renamed.
4798 (symbol_end, yylex): Adjust.
4799
0ec848ad
PFC
48002018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4801
4802 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
4803 parameter type to CORE_ADDR.
4804 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
4805 parameter type in declaration to CORE_ADDR.
4806 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
4807 target_auxv_search to get AT_HWCAP and use the result to get the
4808 target description.
4809 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
4810 to CORE_ADDR. Remove the cast of the return value to unsigned
4811 long. Fix error predicate of target_auxv_search.
4812 (ppc_linux_nat_target::read_description): Change the type of the
4813 hwcap variable to CORE_ADDR.
4814
0fb2aaa1
PFC
48152018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4816
4817 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
4818 if the size of fpscr is larger than 32 bits.
4819
2c3305f6
PFC
48202018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4821
4822 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
4823 (ppc32_linux_vsxregmap): New global.
4824 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
4825 regcache_supply_regset, and regcache_collect_regset.
4826 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
4827 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
4828 (fetch_vsx_register, store_vsx_register): Remove.
4829 (fetch_vsx_registers): Add regno parameter. Get regset using
4830 ppc_linux_vsxregset. Use regset to supply registers.
4831 (store_vsx_registers): Add regno parameter. Get regset using
4832 ppc_linux_vsxregset. Use regset to collect registers.
4833 (fetch_register): Call fetch_vsx_registers instead of
4834 fetch_vsx_register.
4835 (store_register): Call store_vsx_registers instead of
4836 store_vsx_register.
4837 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
4838 new regno parameter.
4839 (store_ppc_registers): Call store_vsx_registers with -1 for the
4840 new regno parameter.
4841 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
4842 (ppc_collect_vsxregset): Remove.
4843
1d75a658
PFC
48442018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4845
4846 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
4847 offset fields.
4848 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
4849 for vector register offset fields.
4850 (ppc64_fbsd_reg_offsets): Likewise.
4851 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4852 to vector register offset fields.
4853 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4854 to vector register offset fields.
4855 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
4856 vector register offset fields.
4857 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
4858 initializers for vector register offset fields.
4859 (rs6000_aix64_reg_offsets): Likewise.
4860 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
4861 (ppc_supply_vrregset): Remove.
4862 (ppc_collect_vrregset): Remove.
4863 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
4864 (ppc_linux_vrregset) : New function.
4865 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
4866 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
4867 (ppc32_linux_vrregset): Remove.
4868 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
4869 and use result instead of ppc32_linux_vrregset.
4870 (ppc32_linux_reg_offsets): Remove initializers for vector register
4871 offset fields.
4872 (ppc64_linux_reg_offsets): Likewise.
4873 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
4874 * ppc-linux-nat.c: Include regset.h.
4875 (gdb_vrregset_t): Adjust comment to account for little-endian
4876 mode.
4877 (supply_vrregset, fill_vrregset): Remove.
4878 (fetch_altivec_register, store_altivec_register): Remove.
4879 (fetch_altivec_registers): Add regno parameter. Get regset using
4880 ppc_linux_vrregset. Use regset to supply registers.
4881 (store_altivec_registers): Add regno parameter. Get regset using
4882 ppc_linux_vrregset. Use regset to collect registers.
4883 (fetch_register): Call fetch_altivec_registers instead of
4884 fetch_altivec_register.
4885 (store_register): Call store_altivec_registers instead of
4886 store_altivec_register.
4887 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
4888 the new regno parameter.
4889 (store_ppc_registers): Call store_altivec_registers with -1 for
4890 the new regno parameter.
4891
d078308a
PFC
48922018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4893
4894 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
4895 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
4896 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
4897 (gdb_vrregset_t): Change array type size to
4898 PPC_LINUX_SIZEOF_VRREGSET.
4899 (gdb_vsxregset_t): Change array type size to
4900 PPC_LINUX_SIZEOF_VSXREGSET.
4901 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
4902 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
4903 PPC_LINUX_SIZEOF_VSXREGSET.
4904
2e077f5e
PFC
49052018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4906
4907 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
4908 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
4909 nat/ppc-linux.c.
4910 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
4911 ppc_linux_target_wordsize with tid.
4912 (ppc_linux_nat_target::read_description): Call ppc_linux_target
4913 wordsize with tid.
4914 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
4915 (ppc64_64bit_inferior_p): Add static and inline specifiers.
4916 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
4917 tid parameter. Remove static specifier.
4918 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
4919 (ppc_linux_target_wordsize): New declaration.
4920
bd64614e
PFC
49212018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4922
4923 * arch/ppc-linux-common.c: New file.
4924 * arch/ppc-linux-common.h: New file.
4925 * arch/ppc-linux-tdesc.h: New file.
4926 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
4927 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
4928 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
4929 arch/ppc-linux-tdesc.h.
4930 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
4931 arch/ppc-linux-tdesc.h.
4932 (ppc_linux_nat_target::read_description): Remove target
4933 description matching code. Fill a ppc_linux_features struct and
4934 call ppc_linux_match_description with it. Move comment about ISA
4935 2.05 to ppc-linux-common.c.
4936 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
4937 arch/ppc-linux-tdesc.h.
4938 (ppc_linux_core_read_description): Remove target description
4939 matching code. Fill a ppc_linux_features struct and call
4940 ppc_linux_match_description with it.
4941 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
4942 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
4943 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
4944 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
4945 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
4946 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
4947 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
4948 (tdesc_powerpc_e500l): Remove.
4949
241db429
JB
49502018-05-22 Joel Brobecker <brobecker@adacore.com>
4951
4952 * ada-lang.c (catch_assert_command): Pass empty string instead
4953 of NULL for excep_string argument.
4954
75d74cca
MR
49552018-05-22 Maciej W. Rozycki <macro@mips.com>
4956
4957 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
4958 the width of the requested register exceeds the width of the
4959 `ptrace' data type.
4960
122b53ea
TT
49612018-05-21 Tom Tromey <tom@tromey.com>
4962
4963 * printcmd.c (output_command): Remove.
4964 (output_command_const): Rename to output_command.
4965 * valprint.h (output_command): Rename from output_command_const.
4966 * tracepoint.c (trace_dump_actions): Call output_command.
4967
bc18fbb5
TT
49682018-05-21 Tom Tromey <tom@tromey.com>
4969
4970 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
4971 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
4972 * ada-lang.h (create_ada_exception_catchpoint): Update.
4973 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
4974 std::string.
4975 (create_excep_cond_exprs, ~ada_catchpoint)
4976 (should_stop_exception, print_one_exception)
4977 (print_mention_exception, print_recreate_exception): Update.
4978 (ada_get_next_arg): Remove.
4979 (catch_ada_exception_command_split): Use std::string. Change type
4980 of "excep_string", "cond_string".
4981 (catch_ada_exception_command): Update.
4982 (create_ada_exception_catchpoint): Change type of excep_string.
4983 (ada_exception_sal): Remove excep_string parameter.
4984 (~ada_catchpoint): Remove.
4985
790217f6
TT
49862018-05-21 Tom Tromey <tom@tromey.com>
4987
4988 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
4989 cleanup.
4990
6f46ac85
TT
49912018-05-21 Tom Tromey <tom@tromey.com>
4992
4993 * ada-lang.c (ada_exception_message_1, ada_exception_message):
4994 Return unique_xmalloc_ptr.
4995 (print_it_exception): Update.
4996
15b6611c
TT
49972018-05-21 Tom Tromey <tom@tromey.com>
4998
4999 * tracepoint.c (trace_dump_actions): Use std::string.
5000
c0c9f665
TT
50012018-05-21 Tom Tromey <tom@tromey.com>
5002
5003 * symfile.c (reread_symbols): Use std::string for original_name.
5004
22ca247e
TT
50052018-05-21 Tom Tromey <tom@tromey.com>
5006
5007 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
5008 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
5009 constructor.
5010
184cde75
SM
50112018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
5012
5013 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
5014 instance to...
5015 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
5016 * objfiles.c (get_objfile_bfd_data): Allocate
5017 objfile_per_bfd_storage with obstack_new when allocating on
5018 obstack.
5019
e39db4db
SM
50202018-05-20 Simon Marchi <simon.marchi@ericsson.com>
5021
5022 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
5023 OBSTACK_ZALLOC.
5024 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
5025 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
5026 * mdebugread.c (mdebug_build_psymtabs): Likewise.
5027 (add_pending): Likewise.
5028 (parse_symbol): Likewise.
5029 (parse_partial_symbols): Likewise.
5030 (psymtab_to_symtab_1): Likewise.
5031 (new_psymtab): Likewise.
5032 (elfmdebug_build_psymtabs): Likewise.
5033 * minsyms.c (terminate_minimal_symbol_table): Likewise.
5034 * objfiles.c (get_objfile_bfd_data): Likewise.
5035 (objfile_register_static_link): Likewise.
5036 * psymtab.c (allocate_psymtab): Likewise.
5037 * stabsread.c (read_member_functions): Likewise.
5038 * xcoffread.c (xcoff_end_psymtab): Likewise.
5039
284a0e3c
SM
50402018-05-20 Simon Marchi <simon.marchi@ericsson.com>
5041
5042 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
5043 compiler supports std::is_trivially_constructible.
5044 * common/poison.h: Include obstack.h.
5045 (IsMallocable): Define to is_trivially_constructible if the
5046 compiler supports it, define to true_type otherwise.
5047 (xobnew): New.
5048 (XOBNEW): Redefine.
5049 (xobnewvec): New.
5050 (XOBNEWVEC): Redefine.
5051 * gdb_obstack.h (obstack_zalloc): New.
5052 (OBSTACK_ZALLOC): Redefine.
5053 (obstack_calloc): New.
5054 (OBSTACK_CALLOC): Redefine.
5055 (obstack_new): New.
5056 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
5057 (gdbarch_obstack): New declaration in gdbarch.h, definition in
5058 gdbarch.c.
5059 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
5060 obstack_calloc/obstack_zalloc.
5061 (gdbarch_obstack_zalloc): Remove.
5062 * target-descriptions.c (tdesc_data_init): Use obstack_new.
5063
59f66be3
PW
50642018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5065
5066 * stack.c (backtrace_command_1): Remove useless variable int i.
5067
50c65c2d
PW
50682018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5069
5070 * stack.c (print_frame_info): Fix comment.
5071
7ff8cb8c
TT
50722018-05-18 Tom Tromey <tom@tromey.com>
5073
5074 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
5075 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
5076 (~dwarf2_per_objfile): Update
5077 (dwarf2_get_dwz_file): Use new.
5078 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
5079 unique_ptr.
5080
400174b1
TT
50812018-05-18 Tom Tromey <tom@tromey.com>
5082
5083 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
5084 unique_ptr.
5085 * dwarf2read.c (struct dwp_file): Add constructor and
5086 initializers.
5087 (open_and_init_dwp_file): Return a unique_ptr.
5088 (dwarf2_per_objfile, create_dwp_hash_table)
5089 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
5090 (lookup_dwo_unit_in_dwp): Update.
5091 (open_and_init_dwp_file, get_dwp_file): Update.
5092
3063847f
TT
50932018-05-18 Tom Tromey <tom@tromey.com>
5094
5095 * dwarf2read.c (dwarf2_per_objfile): Update.
5096 (struct mapped_index): Add initializers.
5097 (dwarf2_read_index): Use new.
5098 (dw2_symtab_iter_init): Update.
5099 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
5100 unique_ptr.
5101
d3d02dee
SM
51022018-05-18 Simon Marchi <simon.marchi@ericsson.com>
5103
5104 * dwarf2read.c (mapped_index) <total_size>: Remove.
5105
1d143c36
SM
51062018-05-18 Simon Marchi <simon.marchi@ericsson.com>
5107
5108 * unittests/format_pieces-selftests.c (test_format_specifier):
5109 Add ARI comments.
5110
ce1e8424
TT
51112018-05-18 Tom Tromey <tom@tromey.com>
5112
5113 * c-typeprint.c (maybe_print_hole): New function.
5114 (c_print_type_struct_field_offset): Update.
5115 (c_type_print_base_struct_union): Call maybe_print_hole.
5116
ddfe970e
KS
51172018-05-17 Keith Seitz <keiths@redhat.com>
5118
5119 * breakpoint.c (build_bpstat_chain): New function, moved from
5120 bpstat_stop_status.
5121 (bpstat_stop_status): Add optional parameter, `stop_chain'.
5122 If no stop chain is passed, call build_bpstat_chain to build it.
5123 * breakpoint.h (build_bpstat_chain): Declare.
5124 (bpstat_stop_status): Move documentation here from breakpoint.c.
5125 * infrun.c (handle_signal_stop): Before eliding inlined frames,
5126 build the stop chain and pass it to skip_inline_frames.
5127 Pass this stop chain to bpstat_stop_status.
5128 * inline-frame.c: Include breakpoint.h.
5129 (stopped_by_user_bp_inline_frame): New function.
5130 (skip_inline_frames): Add parameter `stop_chain'.
5131 Move documention to inline-frame.h.
5132 If non-NULL, use stopped_by_user_bp_inline_frame to determine
5133 whether the frame should be elided.
5134 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
5135 Add moved documentation and update for new parameter.
5136
b17992c1
SM
51372018-05-17 Simon Marchi <simon.marchi@ericsson.com>
5138
5139 PR cli/14975
5140 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5141 unittests/format_pieces-selftests.c.
5142 * common/format.h (format_piece) <operator==>: New.
5143 (format_pieces) <operator[]>: Remove.
5144 * common/format.c (format_pieces::format_pieces): Handle \e.
5145 * unittests/format_pieces-selftests.c: New.
5146
58f0c718
TT
51472018-05-17 Tom Tromey <tom@tromey.com>
5148
5149 PR symtab/23010:
5150 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
5151 (dw2_instantiate_symtab): Add skip_partial parameter.
5152 (dw2_find_last_source_symtab, dw2_map_expand_apply)
5153 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
5154 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
5155 (dw2_expand_symtabs_matching_one)
5156 (dw2_find_pc_sect_compunit_symtab)
5157 (dw2_debug_names_lookup_symbol)
5158 (dw2_debug_names_expand_symtabs_for_function): Update.
5159 (init_cutu_and_read_dies): Add skip_partial parameter.
5160 (process_psymtab_comp_unit, build_type_psymtabs_1)
5161 (process_skeletonless_type_unit, load_partial_comp_unit)
5162 (psymtab_to_symtab_1): Update.
5163 (load_full_comp_unit): Add skip_partial parameter.
5164 (process_imported_unit_die, dwarf2_read_addr_index)
5165 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
5166 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
5167 (read_signatured_type): Update.
5168
3e618834
SM
51692018-05-17 Simon Marchi <simon.marchi@ericsson.com>
5170
5171 * value.c (release_value): Remove unused variable.
5172 (record_latest_value): Likewise.
5173 (access_value_history): Likewise.
5174 (preserve_values): Likewise.
5175
fe10fe31
TT
51762018-05-17 Tom Tromey <tom@tromey.com>
5177
5178 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
5179 Initialize.
5180
1d761124
MR
51812018-05-16 Maciej W. Rozycki <macro@mips.com>
5182
5183 PR gdb/22286
5184 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
5185 Also handle registers whose width is not a multiple of
5186 PTRACE_TYPE_RET.
5187 (linux_nat_trad_target::store_register): Likewise.
5188
06333fea
TT
51892018-05-16 Tom Tromey <tom@tromey.com>
5190
5191 * gdbcore.h (core_bfd): Redefine.
5192 * corelow.c (core_target::close): Update.
5193 (core_target_open): Update.
5194 * progspace.h (struct program_space) <cbfd>: Now a
5195 gdb_bfd_ref_ptr.
5196
921222e2
TT
51972018-05-16 Tom Tromey <tom@tromey.com>
5198
5199 PR cli/19551:
5200 * symfile-add-flags.h (enum symfile_add_flags)
5201 <SYMFILE_NOT_FILENAME>: New constant.
5202 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
5203 objfile name from BFD.
5204 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
5205 * minidebug.c (find_separate_debug_file_in_section): Put
5206 ".gnu_debugdata" into BFD's file name.
5207
3acb7083
SM
52082018-05-16 Simon Marchi <simon.marchi@ericsson.com>
5209
5210 * regcache.c (regcache_read_ftype, regcache_write_ftype):
5211 Remove.
5212
561a72d4
TC
52132018-05-15 Tamar Christina <tamar.christina@arm.com>
5214
5215 PR binutils/21446
5216 * aarch64-tdep.c (aarch64_analyze_prologue,
5217 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
5218 Indicate not interested in errors.
5219
4e6ff0e1
MR
52202018-05-15 Maciej W. Rozycki <macro@mips.com>
5221
5222 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
5223 Supply the MIPS_ZERO_REGNUM register.
5224
ea33cd92
MR
52252018-05-15 Maciej W. Rozycki <macro@mips.com>
5226
5227 * mips-tdep.c (mask_address_var): Make variable static.
5228
2d79090e
TT
52292018-05-14 Tom Tromey <tom@tromey.com>
5230
5231 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
5232
cf4912ae
AB
52332018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
5234
5235 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
5236 FXSAVE_ADDR for the mxcsr register.
5237
67e6f569
MF
52382018-05-11 Max Filippov <jcmvbkbc@gmail.com>
5239
5240 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
5241
15244507
PA
52422018-05-11 Pedro Alves <palves@redhat.com>
5243
5244 * corelow.c (core_target) <core_target>: No longer inline.
5245 Initialize m_core_gdbarch, m_core_vec and build the section table
5246 here.
5247 <~core_target>: New.
5248 <core_gdbarch, get_core_register_section>: New methods.
5249 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
5250 factored out from ...
5251 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
5252 (core_ops): Delete.
5253 (sniff_core_bfd): Add gdbarch parameter.
5254 (core_close): Delete, merged into ...
5255 (core_target::close): ... here. Delete self.
5256 (core_close_cleanup): Delete.
5257 (core_target_open): Allocate a core_target on the heap. Use a
5258 unique_ptr instead of a cleanup. Bits moved into the core_target
5259 ctor. Adjust to use core_target methods instead of globals.
5260 (get_core_register_section): Rename to ...
5261 (core_target::get_core_register_section): ... this and adjust.
5262 (struct get_core_registers_cb_data): New.
5263 (get_core_registers_cb): Use it. Use bool.
5264 (core_target::fetch_registers, core_target::files_info)
5265 (core_target::xfer_partial, core_target::read_description)
5266 (core_target::pid_to, core_target::thread_name): Adjust to
5267 reference class fields instead of globals.
5268 * target.h (struct target_ops_deleter, target_ops_up): New.
5269
451953fa
PA
52702018-05-11 Pedro Alves <palves@redhat.com>
5271
5272 * corefile.c (core_file_command): Move to corelow.c.
5273 * corelow.c (the_core_target): Delete.
5274 (core_file_command): Moved from corefile.c. Check exec_bfd
5275 instead of the_core_target. Use target_detach instead of calling
5276 into the_core_target directly.
5277 (maybe_say_no_core_file_now): New.
5278 (core_target::detach): Use it.
5279 (_initialize_corelow): Remove references to the_core_target.
5280 * gdbcore.h (the_core_target): Delete.
5281
e540a5a2 52822018-05-11 Tom Tromey <tromey@redhat.com>
3afc23a6 5283 Pedro Alves <palves@redhat.com>
e540a5a2
TT
5284
5285 * corefile.c (core_bfd): Remove.
5286 * gdbcore.h (core_bfd): Now a macro.
5287 * progspace.h (struct program_space) <cbfd>: New field.
5288
633cf254
TT
52892018-05-11 Tom Tromey <tom@tromey.com>
5290
5291 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
5292 gdb::def_vector.
5293
1a34f210
TT
52942018-05-10 Tom Tromey <tom@tromey.com>
5295
5296 * configure: Rebuild.
5297 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
5298
190852c8
JB
52992018-05-10 Joel Brobecker <brobecker@adacore.com>
5300
5301 PR server/23158:
5302 * regformats/regdat.sh: Adjust script, following the addition
5303 of the new expedite_regs parameter to init_target_desc.
5304
8727de56
OJ
53052018-05-10 Omair Javaid <omair.javaid@linaro.org>
5306
5307 PR gdb/23127
5308 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
5309 set_gdbarch_significant_addr_bit.
5310 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
5311 set_gdbarch_significant_addr_bit.
5312 * utils.c (address_significant): Update to sign extend addr.
5313
37d9e062
MF
53142018-05-09 Max Filippov <jcmvbkbc@gmail.com>
5315
5316 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
5317 (xtensa_linux_init_abi): Limit tdep->num_regs by
5318 tdep->num_nopriv_regs.
5319 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
5320 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
5321 not initialized.
5322
7402fbca
SM
53232018-05-08 Simon Marchi <simon.marchi@ericsson.com>
5324
5325 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
5326
8ee22052
AB
53272018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5328
5329 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
5330 (I387_MXCSR_INIT_VAL): New constant.
5331 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
5332 buffer if it was supplied by the inferior.
5333 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
5334 (i387_xsave_get_clear_bv): New function.
5335 (i387_supply_xsave): Only read x87 control registers from the
5336 xsave buffer if the feature is enabled, and the state will have
5337 been written, otherwise, provide a suitable default.
5338 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
5339 including x87 control registers. Update control registers if they
5340 have changed from the default value, and mark features as enabled
5341 as required.
5342 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
5343
968ae51b
UW
53442018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
5345
5346 * spu-tdep.c (info_spu_event_command): Fix output formatting.
5347
aff689d3
TT
53482018-05-07 Tom Tromey <tom@tromey.com>
5349
5350 * configure: Rebuild.
5351 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
5352
ce887586
TT
53532018-05-07 Tom Tromey <tom@tromey.com>
5354
5355 PR tdep/20362:
5356 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
5357 bit. Use correct value for VDIV.
5358
85e26832
TT
53592018-05-04 Tom Tromey <tom@tromey.com>
5360
5361 * configure: Rebuild.
5362 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
5363
449b1ac7
TT
53642018-05-04 Tom Tromey <tom@tromey.com>
5365
5366 * linux-record.c (record_linux_system_call) <case
5367 RECORD_SYS_RECVFROM>: Add "break".
5368
15c9ffd6
TT
53692018-05-04 Tom Tromey <tom@tromey.com>
5370
5371 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
5372 Add missing "break".
5373 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
5374 Add missing "break".
5375
e3829d13
TT
53762018-05-04 Tom Tromey <tom@tromey.com>
5377
5378 * rs6000-tdep.c (ppc_process_record_op4)
5379 (ppc_process_record_op63): Add fall-through comment.
5380
da0e1563
TT
53812018-05-04 Tom Tromey <tom@tromey.com>
5382
5383 * i386-tdep.c (i386_process_record): Add fall-through comment.
5384
0019cd49
TT
53852018-05-04 Tom Tromey <tom@tromey.com>
5386
5387 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
5388 comment.
5389
565e0eda
TT
53902018-05-04 Tom Tromey <tom@tromey.com>
5391
5392 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
5393 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
5394 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
5395 comment.
5396 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
5397 comment.
5398 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
5399 comment.
5400
621846f4
TT
54012018-05-04 Tom Tromey <tom@tromey.com>
5402
5403 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
5404
86a73007
TT
54052018-05-04 Tom Tromey <tom@tromey.com>
5406
5407 * s390-tdep.c (s390_process_record): Fix fall-through comments.
5408 * xcoffread.c (scan_xcoff_symtab): Move comment later.
5409 * symfile.c (section_is_mapped): Fix fall-through comment.
5410 * stabsread.c (define_symbol, read_member_functions): Fix
5411 fall-through comment.
5412 * s390-linux-tdep.c (s390_process_record): Fix fall-through
5413 comment.
5414 * remote.c (remote_wait_as): Fix fall-through comment.
5415 * p-exp.y (yylex): Fix fall-through comment.
5416 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
5417 comment.
5418 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
5419 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
5420 * jv-exp.y (yylex): Fix fall-through comment.
5421 * go-exp.y (lex_one_token): Fix fall-through comment.
5422 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
5423 fall-through comment.
5424 * f-exp.y (yylex): Fix fall-through comment.
5425 * dwarf2read.c (process_die): Fix fall-through comments.
5426 * dbxread.c (process_one_symbol): Fix fall-through comment.
5427 * d-exp.y (lex_one_token): Fix fall-through comment.
5428 * cp-name-parser.y (yylex): Fix fall-through comment.
5429 * coffread.c (coff_symtab_read): Fix fall-through comment.
5430 * c-exp.y (lex_one_token): Fix fall-through comment.
5431 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
5432 comment.
5433 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
5434 comment.
5435
56bcdbea
TT
54362018-05-04 Tom Tromey <tom@tromey.com>
5437
5438 PR python/22730:
5439 * NEWS: Mention gdb.execute change.
5440 * gdbcmd.h (execute_control_command): Don't declare.
5441 * python/python.c (execute_gdb_command): Use read_command_lines_1,
5442 execute_control_commands, execute_control_commands_to_string.
5443 * cli/cli-script.h (execute_control_commands)
5444 (execute_control_commands_to_string): Declare.
5445 (execute_control_command): Add from_tty parameter.
5446 * cli/cli-script.c (execute_control_commands)
5447 (execute_control_commands_to_string): New functions.
5448 (execute_user_command): Use execute_control_commands.
5449 (execute_control_command_1): Add "from_tty" parameter. Update.
5450 (execute_control_command): Likewise.
5451
a913fffb
TT
54522018-05-04 Tom Tromey <tom@tromey.com>
5453
5454 PR python/22731:
5455 * NEWS: Mention that breakpoint commands are writable.
5456 * python/py-breakpoint.c (bppy_set_commands): New function.
5457 (breakpoint_object_getset) <"commands">: Use it.
5458
60b3cef2
TT
54592018-05-04 Tom Tromey <tom@tromey.com>
5460
5461 * tracepoint.c (actions_command): Update.
5462 * mi/mi-cmd-break.c (mi_command_line_array)
5463 (mi_command_line_array_cnt, mi_command_line_array_ptr)
5464 (mi_read_next_line): Remove.
5465 (mi_cmd_break_commands): Update.
5466 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
5467 function_view.
5468 * cli/cli-script.c (get_command_line): Update.
5469 (process_next_line): Use function_view. Constify.
5470 (recurse_read_control_structure, read_command_lines)
5471 (read_command_lines_1): Change argument types to function_view.
5472 (do_define_command, document_command): Update.
5473 * breakpoint.h (check_tracepoint_command): Don't declare.
5474 * breakpoint.c (check_tracepoint_command): Remove.
5475 (commands_command_1, create_tracepoint_from_upload): Update.
5476
7a2c85f2
TT
54772018-05-04 Tom Tromey <tom@tromey.com>
5478
5479 PR gdb/11750:
5480 * cli/cli-script.h (enum command_control_type) <define_control>:
5481 New constant.
5482 * cli/cli-script.c (multi_line_command_p): Handle define_control.
5483 (build_command_line, execute_control_command_1)
5484 (process_next_line): Likewise.
5485 (do_define_command): New function, extracted from define_command.
5486 (define_command): Use it.
5487
295dc222
TT
54882018-05-04 Tom Tromey <tom@tromey.com>
5489
5490 * tracepoint.c (actions_command): Update.
5491 * cli/cli-script.h (read_command_lines): Update.
5492 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
5493 (MAX_TMPBUF): Remove define.
5494 (define_command): Use string_printf.
5495 (document_command): Likewise.
5496 * breakpoint.c (commands_command_1): Update.
5497
1263a9d5
TT
54982018-05-04 Tom Tromey <tom@tromey.com>
5499
5500 * top.c (execute_command): Update.
5501 * cli/cli-script.h (print_command_lines): Now varargs.
5502 * cli/cli-script.c (print_command_lines): Now varargs.
5503 (execute_control_command_1) <case while_control, case if_control>:
5504 Update.
5505
12973681
TT
55062018-05-04 Tom Tromey <tom@tromey.com>
5507
5508 * tracepoint.c (all_tracepoint_actions): Rename from
5509 all_tracepoint_actions_and_cleanup. Change return type.
5510 (actions_command, encode_actions_1, encode_actions)
5511 (trace_dump_actions, tdump_command): Update.
5512 * remote.c (remote_download_command_source): Update.
5513 * python/python.c (gdbpy_eval_from_control_command)
5514 (python_command, python_interactive_command): Update.
5515 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
5516 * guile/guile.c (guile_command)
5517 (gdbscm_eval_from_control_command, guile_command): Update.
5518 * compile/compile.c (compile_code_command)
5519 (compile_print_command, compile_to_object): Update.
5520 * cli/cli-script.h (struct command_lines_deleter): New.
5521 (counted_command_line): New typedef.
5522 (struct command_line): Add constructor, destructor.
5523 <body_list>: Remove.
5524 <body_list_0, body_list_1>: New members.
5525 (command_line_up): Remove typedef.
5526 (read_command_lines, read_command_lines_1, get_command_line):
5527 Update.
5528 (copy_command_lines): Don't declare.
5529 * cli/cli-script.c (build_command_line): Use "new".
5530 (get_command_line): Return counted_command_line.
5531 (print_command_lines, execute_user_command)
5532 (execute_control_command_1, while_command, if_command): Update.
5533 (realloc_body_list): Remove.
5534 (process_next_line, recurse_read_control_structure): Update.
5535 (read_command_lines, read_command_lines_1): Return counted_command_line.
5536 (free_command_lines): Use "delete".
5537 (copy_command_lines): Remove.
5538 (define_command, document_command, show_user_1): Update.
5539 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
5540 a counted_command_line.
5541 * breakpoint.h (counted_command_line): Remove typedef.
5542 (breakpoint_set_commands): Update.
5543 * breakpoint.c (check_no_tracepoint_commands)
5544 (validate_commands_for_breakpoint): Update.
5545 (breakpoint_set_commands): Change commands to be a
5546 counted_command_line.
5547 (commands_command_1, update_dprintf_command_list)
5548 (create_tracepoint_from_upload): Update.
5549
e2fc72e2
TT
55502018-05-04 Tom Tromey <tom@tromey.com>
5551
5552 * cli/cli-decode.h (cmd_list_element): New constructor.
5553 (~cmd_list_element): New destructor.
5554 (struct cmd_list_element): Add initializers.
5555 * cli/cli-decode.c (do_add_cmd): Use "new".
5556 (delete_cmd): Use "delete".
5557
a3b60e45
JK
55582018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5559 Pedro Alves <palves@redhat.com>
5560
5561 PR breakpoints/19806 and support for PR external/20207.
5562 * NEWS: Mention Aarch64 watchpoint improvements.
5563 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
5564 watchpoints and PR external/20207 watchpoints.
5565 * nat/aarch64-linux-hw-point.c
5566 (kernel_supports_any_contiguous_range): New.
5567 (aarch64_watchpoint_offset): New.
5568 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
5569 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
5570 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
5571 (aarch64_align_watchpoint): New parameters aligned_offset_p and
5572 next_addr_orig_p. Support PR external/20207 watchpoints.
5573 (aarch64_downgrade_regs): New.
5574 (aarch64_dr_state_insert_one_point): New parameters offset and
5575 addr_orig.
5576 (aarch64_dr_state_remove_one_point): Likewise.
5577 (aarch64_handle_breakpoint): Update caller.
5578 (aarch64_handle_aligned_watchpoint): Likewise.
5579 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
5580 aligned_offset.
5581 (aarch64_linux_set_debug_regs): Remove const from state. Call
5582 aarch64_downgrade_regs.
5583 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
5584 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
5585 (DR_CONTROL_MASK): ... this.
5586 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
5587 (unsigned int aarch64_watchpoint_offset): New prototype.
5588 (aarch64_linux_set_debug_regs): Remove const from state.
5589 * utils.c (align_up, align_down): Move to ...
5590 * common/common-utils.c (align_up, align_down): ... here.
5591 * utils.h (align_up, align_down): Move to ...
5592 * common/common-utils.h (align_up, align_down): ... here.
5593
05bc7456
JB
55942018-05-04 Joel Brobecker <brobecker@adacore.com>
5595
5596 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
5597 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
5598 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
5599 Re-implement to match the ABI as summarized in GCC's
5600 gcc/config/sparc/sparc.c. All callers updated.
5601 (sparc32_store_arguments): Remove assertion.
5602
2f433492
TT
56032018-05-04 Tom Tromey <tom@tromey.com>
5604
5605 * printcmd.c: Don't include tui.h.
5606 (decode_format): Use skip_spaces.
5607
9be2ae8f
TT
56082018-05-04 Tom Tromey <tom@tromey.com>
5609
5610 PR gdb/22619:
5611 * printcmd.c (last_count): New global.
5612 (x_command): Use saved count when repeating.
5613
f0b3976b
TT
56142018-05-04 Tom Tromey <tom@tromey.com>
5615
5616 * nto-procfs.c (do_closedir_cleanup): Remove.
5617 (procfs_pidlist): Use gdb_dir_up.
5618 * procfs.c (do_closedir_cleanup): Remove.
5619 (proc_update_threads): Use gdb_dir_up.
5620 * common/filestuff.h (struct gdb_dir_deleter): New.
5621 (gdb_dir_up): New typedef.
5622
862d101a
TT
56232018-05-04 Tom Tromey <tom@tromey.com>
5624
5625 * ada-lang.c (print_mention_exception): Use std::string.
5626
cb7de75e
TT
56272018-05-04 Tom Tromey <tom@tromey.com>
5628
5629 * ada-lang.c (create_excep_cond_exprs): Update.
5630 (ada_exception_catchpoint_cond_string): Use std::string.
5631
49d83361
TT
56322018-05-04 Tom Tromey <tom@tromey.com>
5633
5634 * ada-lang.c (xget_renaming_scope): Return std::string.
5635 (old_renaming_is_invisible): Update.
5636
ade72a34
TT
56372018-05-04 Tom Tromey <tom@tromey.com>
5638
5639 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
5640 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
5641
2be4d7f0
UW
56422018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
5643
5644 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
5645
69b6ecb0
TT
56462018-05-04 Tom Tromey <tom@tromey.com>
5647
5648 * remote.c (remote_query_supported_append): Change type.
5649 (remote_check_symbols): Update.
5650
bf27f0e2
PP
56512018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
5652
5653 PR gdb/11420
5654 * configure.ac: Prepend libpython.
5655 * python/python-config.py: Likewise.
5656 * configure: Regenerate.
5657
4ea17de8
SM
56582018-05-03 Simon Marchi <simon.marchi@ericsson.com>
5659
5660 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
5661
bd732259
PA
56622018-05-03 Pedro Alves <palves@redhat.com>
5663
5664 * s390-linux-nat.c
5665 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
5666 override. Write 'true' instead of '1'.
5667 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
5668 declaration.
5669
d9f719f1
PA
56702018-05-02 Pedro Alves <palves@redhat.com>
5671
5672 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
5673 add_inf_child_target.
5674 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
5675 add_inf_child_target.
5676 * aix-thread.c (aix_thread_target_info): New.
5677 (aix_thread_target) <shortname, longname, doc>: Delete.
5678 <info>: New.
5679 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
5680 add_inf_child_target.
5681 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
5682 add_inf_child_target.
5683 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
5684 add_inf_child_target.
5685 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
5686 add_inf_child_target.
5687 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
5688 add_inf_child_target.
5689 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
5690 add_inf_child_target.
5691 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
5692 add_inf_child_target.
5693 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
5694 add_inf_child_target.
5695 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
5696 add_inf_child_target.
5697 * bfd-target.c (target_bfd_target_info): New.
5698 (target_bfd) <shortname, longname, doc>: Delete.
5699 <info>: New.
5700 * bsd-kvm.c (bsd_kvm_target_info): New.
5701 (bsd_kvm_target) <shortname, longname, doc>: Delete.
5702 <info>: New.
5703 (bsd_kvm_target::open): Rename to ...
5704 (bsd_kvm_target_open): ... this. Adjust.
5705 * bsd-uthread.c (bsd_uthread_target_info): New.
5706 (bsd_uthread_target) <shortname, longname, doc>: Delete.
5707 <info>: New.
5708 * corefile.c (core_file_command): Adjust.
5709 * corelow.c (core_target_info): New.
5710 (core_target) <shortname, longname, doc>: Delete.
5711 <info>: New.
5712 (core_target::open): Rename to ...
5713 (core_target_open): ... this. Adjust.
5714 * ctf.c (ctf_target_info): New.
5715 (ctf_target) <shortname, longname, doc>: Delete.
5716 <info>: New.
5717 (ctf_target::open): Rename to ...
5718 (ctf_target_open): ... this.
5719 (_initialize_ctf): Adjust.
5720 * exec.c (exec_target_info): New.
5721 (exec_target) <shortname, longname, doc>: Delete.
5722 <info>: New.
5723 (exec_target::open): Rename to ...
5724 (exec_target_open): ... this.
5725 * gdbcore.h (core_target_open): Declare.
5726 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
5727 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
5728 add_inf_child_target.
5729 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
5730 add_inf_child_target.
5731 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
5732 add_inf_child_target.
5733 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
5734 add_inf_child_target.
5735 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
5736 add_inf_child_target.
5737 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
5738 add_inf_child_target.
5739 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
5740 add_inf_child_target.
5741 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
5742 add_inf_child_target.
5743 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
5744 add_inf_child_target.
5745 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
5746 add_inf_child_target.
5747 * inf-child.c (inf_child_target_info): New.
5748 (inf_child_target::info): New.
5749 (inf_child_open_target): Remove 'target' parameter. Use
5750 get_native_target instead.
5751 (inf_child_target::open): Delete.
5752 (add_inf_child_target): New.
5753 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
5754 Delete.
5755 <info>: New.
5756 (add_inf_child_target): Declare.
5757 (inf_child_open_target): Declare.
5758 * linux-thread-db.c (thread_db_target_info): New.
5759 (thread_db_target) <shortname, longname, doc>: Delete.
5760 <info>: New.
5761 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
5762 add_inf_child_target.
5763 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
5764 add_inf_child_target.
5765 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
5766 add_inf_child_target.
5767 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
5768 add_inf_child_target.
5769 * make-target-delegates (print_class): Adjust.
5770 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
5771 add_inf_child_target.
5772 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
5773 add_inf_child_target.
5774 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
5775 add_inf_child_target.
5776 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
5777 add_inf_child_target.
5778 * nto-procfs.c (nto_native_target_info): New.
5779 (nto_procfs_target_native) <shortname, longname, doc>:
5780 Delete.
5781 <info>: New.
5782 (nto_procfs_target_info): New.
5783 (nto_procfs_target_procfs) <shortname, longname, doc>:
5784 Delete.
5785 <info>: New.
5786 (init_procfs_targets): Adjust.
5787 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
5788 add_inf_child_target.
5789 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
5790 add_inf_child_target.
5791 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
5792 add_inf_child_target.
5793 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
5794 add_inf_child_target.
5795 * ravenscar-thread.c (ravenscar_target_info): New.
5796 (ravenscar_thread_target) <shortname, longname, doc>:
5797 Delete.
5798 <info>: New.
5799 * record-btrace.c (record_btrace_target_info):
5800 (record_btrace_target) <shortname, longname, doc>: Delete.
5801 <info>: New.
5802 (record_btrace_target::open): Rename to ...
5803 (record_btrace_target_open): ... this. Adjust.
5804 * record-full.c (record_longname, record_doc): New.
5805 (record_full_base_target) <shortname, longname, doc>: Delete.
5806 <info>: New.
5807 (record_full_target_info): New.
5808 (record_full_target): <shortname>: Delete.
5809 <info>: New.
5810 (record_full_core_open_1, record_full_open_1): Update comments.
5811 (record_full_base_target::open): Rename to ...
5812 (record_full_open): ... this.
5813 (cmd_record_full_restore): Update.
5814 (_initialize_record_full): Update.
5815 * remote-sim.c (remote_sim_target_info): New.
5816 (gdbsim_target) <shortname, longname, doc>: Delete.
5817 <info>: New.
5818 (gdbsim_target::open): Rename to ...
5819 (gdbsim_target_open): ... this.
5820 (_initialize_remote_sim): Adjust.
5821 * remote.c (remote_doc): New.
5822 (remote_target_info): New.
5823 (remote_target) <shortname, longname, doc>: Delete.
5824 <info>: New.
5825 (extended_remote_target_info): New.
5826 (extended_remote_target) <shortname, longname, doc>: Delete.
5827 <info>: New.
5828 (remote_target::open_1): Make static. Adjust.
5829 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
5830 * s390-linux-nat.c (_initialize_s390_nat): Use
5831 add_inf_child_target.
5832 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
5833 add_inf_child_target.
5834 * sol-thread.c (thread_db_target_info): New.
5835 (sol_thread_target) <shortname, longname, doc>: Delete.
5836 <info>: New.
5837 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
5838 add_inf_child_target.
5839 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
5840 add_inf_child_target.
5841 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
5842 add_inf_child_target.
5843 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
5844 add_inf_child_target.
5845 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
5846 add_inf_child_target.
5847 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
5848 add_inf_child_target.
5849 * spu-linux-nat.c (_initialize_spu_nat): Use
5850 add_inf_child_target.
5851 * spu-multiarch.c (spu_multiarch_target_info): New.
5852 (spu_multiarch_target) <shortname, longname, doc>: Delete.
5853 <info>: New.
5854 * target-delegates.c: Regenerate.
5855 * target.c: Include <unordered_map>.
5856 (target_ops_p): Delete.
5857 (DEF_VEC_P(target_ops_p)): Delete.
5858 (target_factories): New.
5859 (test_target_info): New.
5860 (test_target_ops::info): New.
5861 (open_target): Adjust to use target_factories.
5862 (add_target_with_completer): Rename to ...
5863 (add_target): ... this. Change prototype. Register target_info
5864 and open callback in target_factories. Register target_info in
5865 command context instead of target_ops.
5866 (add_target): Delete old implementation.
5867 (add_deprecated_target_alias): Change prototype. Adjust.
5868 (the_native_target): New.
5869 (set_native_target, get_native_target): New.
5870 (find_default_run_target): Use the_native_target.
5871 (find_attach_target, find_run_target): Simplify.
5872 (target_ops::open): Delete.
5873 (dummy_target_info): New.
5874 (dummy_target::shortname, dummy_target::longname)
5875 (dummy_target::doc): Delete.
5876 (dummy_target::info): New.
5877 (debug_target::shortname, debug_target::longname)
5878 (debug_target::doc): Delete.
5879 (debug_target::info): New.
5880 * target.h (struct target_info): New.
5881 (target_ops::~target_ops): Add comment.
5882 (target_ops::info): New.
5883 (target_ops::shortname, target_ops::longname, target_ops::doc): No
5884 longer virtual. Implement in terms of target_info.
5885 (set_native_target, get_native_target): Declare.
5886 (target_open_ftype): New.
5887 (add_target, add_target_with_completer)
5888 (add_deprecated_target_alias): Change prototype.
5889 (test_target) <shortname, longname, doc>: Delete.
5890 <info>: New.
5891 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
5892 add_inf_child_target.
5893 * tracefile-tfile.c (tfile_target_info): New.
5894 (tfile_target) <shortname, longname, doc>: Delete.
5895 <info>: New.
5896 (tfile_target::open): Rename to ...
5897 (tfile_target_open): ... this.
5898 (_initialize_tracefile_tfile): Adjust.
5899 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
5900 add_inf_child_target.
5901 * windows-nat.c (_initialize_windows_nat): Use
5902 add_inf_child_target.
5903 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
5904 add_inf_child_target.
5905
135340af
PA
59062018-05-02 Pedro Alves <palves@redhat.com>
5907
5908 * linux-nat.h (linux_nat_target) <low_new_thread,
5909 low_delete_thread, low_new_fork, low_forget_process,
5910 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
5911 New virtual methods.
5912 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5913 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
5914 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
5915 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5916 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
5917 Delete.
5918 * linux-fork.c (delete_fork): Adjust to call low method.
5919 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
5920 (linux_nat_new_fork, linux_nat_forget_process_hook)
5921 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
5922 (linux_nat_status_is_event):
5923 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
5924 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
5925 to call low method.
5926 (sigtrap_is_event): Rename to ...
5927 (linux_nat_target::low_status_is_event): ... this.
5928 (linux_nat_set_status_is_event): Delete.
5929 (save_stop_reason, linux_nat_wait_1)
5930 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
5931 low methods.
5932 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5933 (linux_nat_set_new_fork, linux_nat_set_forget_process)
5934 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5935 (linux_nat_set_prepare_to_resume): Delete.
5936 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
5937 low virtual methods.
5938 * amd64-linux-nat.c: Likewise.
5939 * arm-linux-nat.c: Likewise.
5940 * i386-linux-nat.c: Likewise.
5941 * ia64-linux-nat.c: Likewise.
5942 * mips-linux-nat.c: Likewise.
5943 * ppc-linux-nat.c: Likewise.
5944 * s390-linux-nat.c: Likewise.
5945 * sparc64-linux-nat.c: Likewise.
5946 * x86-linux-nat.c: Likewise.
5947 * x86-linux-nat.h: Include "nat/x86-linux.h".
5948 (x86_linux_nat_target) <low_new_fork, low_forget_process,
5949 low_prepare_to_resume, low_new_thread, low_delete_thread>:
5950 Override methods.
5951
57810aa7
PA
59522018-05-02 Pedro Alves <palves@redhat.com>
5953
5954 * target.h (target_ops)
5955 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
5956 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
5957 stopped_by_watchpoint, have_continuable_watchpoint,
5958 stopped_data_address, watchpoint_addr_within_range,
5959 can_accel_watchpoint_condition, can_run, thread_alive,
5960 has_all_memory, has_memory, has_stack, has_registers,
5961 has_execution, can_async_p, is_async_p, supports_non_stop,
5962 always_non_stop_p, can_execute_reverse, supports_multi_process,
5963 supports_enable_disable_tracepoint,
5964 supports_disable_randomization, supports_string_tracing,
5965 supports_evaluation_of_breakpoint_conditions,
5966 can_run_breakpoint_commands, filesystem_is_local,
5967 can_download_tracepoint, get_trace_state_variable_value,
5968 set_trace_notes, get_tib_address, use_agent, can_use_agent,
5969 record_is_replaying, record_will_replay,
5970 augmented_libraries_svr4_read>: Adjust to return bool.
5971 * aarch64-linux-nat.c: All implementations adjusted.
5972 * aix-thread.c: All implementations adjusted.
5973 * arm-linux-nat.c: All implementations adjusted.
5974 * breakpoint.c: All implementations adjusted.
5975 * bsd-kvm.c: All implementations adjusted.
5976 * bsd-uthread.c: All implementations adjusted.
5977 * corelow.c: All implementations adjusted.
5978 * ctf.c: All implementations adjusted.
5979 * darwin-nat.c: All implementations adjusted.
5980 * darwin-nat.h: All implementations adjusted.
5981 * exec.c: All implementations adjusted.
5982 * fbsd-nat.c: All implementations adjusted.
5983 * fbsd-nat.h: All implementations adjusted.
5984 * gnu-nat.c: All implementations adjusted.
5985 * gnu-nat.h: All implementations adjusted.
5986 * go32-nat.c: All implementations adjusted.
5987 * ia64-linux-nat.c: All implementations adjusted.
5988 * inf-child.c: All implementations adjusted.
5989 * inf-child.h: All implementations adjusted.
5990 * inf-ptrace.c: All implementations adjusted.
5991 * inf-ptrace.h: All implementations adjusted.
5992 * linux-nat.c: All implementations adjusted.
5993 * linux-nat.h: All implementations adjusted.
5994 * mips-linux-nat.c: All implementations adjusted.
5995 * nto-procfs.c: All implementations adjusted.
5996 * ppc-linux-nat.c: All implementations adjusted.
5997 * procfs.c: All implementations adjusted.
5998 * ravenscar-thread.c: All implementations adjusted.
5999 * record-btrace.c: All implementations adjusted.
6000 * record-full.c: All implementations adjusted.
6001 * remote-sim.c: All implementations adjusted.
6002 * remote.c: All implementations adjusted.
6003 * s390-linux-nat.c: All implementations adjusted.
6004 * sol-thread.c: All implementations adjusted.
6005 * spu-multiarch.c: All implementations adjusted.
6006 * target-delegates.c: All implementations adjusted.
6007 * target.c: All implementations adjusted.
6008 * target.h: All implementations adjusted.
6009 * tracefile-tfile.c: All implementations adjusted.
6010 * tracefile.c: All implementations adjusted.
6011 * tracefile.h: All implementations adjusted.
6012 * windows-nat.c: All implementations adjusted.
6013 * x86-linux-nat.h: All implementations adjusted.
6014 * x86-nat.h: All implementations adjusted.
6015
ad6a4e2d
PA
60162018-05-02 Pedro Alves <palves@redhat.com>
6017
6018 * make-target-delegates (scan_target_h): Don't trim lines here.
6019 Replace sequences of tabs and/or whitespace with a single
6020 whitespace.
6021 (top level, parsing methods): Trim each line before processing it
6022 here.
6023
f6ac5f3d
PA
60242018-05-02 Pedro Alves <palves@redhat.com>
6025 John Baldwin <jhb@freebsd.org>
6026
6027 * target.h (enum strata) <debug_stratum>: New.
6028 (struct target_ops) <all delegation methods>: Replace by C++
6029 virtual methods, and drop "to_" prefix. All references updated
6030 throughout.
6031 <to_shortname, to_longname, to_doc, to_data,
6032 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
6033 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
6034 virtual methods. All references updated throughout.
6035 <can_attach, supports_terminal_ours, can_create_inferior,
6036 get_thread_control_capabilities, attach_no_wait>: New
6037 virtual methods.
6038 <insert_breakpoint, remove_breakpoint>: Now
6039 TARGET_DEFAULT_NORETURN methods.
6040 <info_proc>: Now returns bool.
6041 <to_magic>: Delete.
6042 (OPS_MAGIC): Delete.
6043 (current_target): Delete. All references replaced by references
6044 to ...
6045 (target_stack): ... this. New.
6046 (target_shortname, target_longname): Adjust.
6047 (target_can_run): Now a function declaration.
6048 (default_child_has_all_memory, default_child_has_memory)
6049 (default_child_has_stack, default_child_has_registers)
6050 (default_child_has_execution): Remove target_ops parameter.
6051 (complete_target_initialization): Delete.
6052 (memory_breakpoint_target): New template class.
6053 (test_target_ops): Refactor as a C++ class with virtual methods.
6054 * make-target-delegates (NAME_PART): Tighten.
6055 (POINTER_PART, CP_SYMBOL): New.
6056 (SIMPLE_RETURN_PART): Reimplement.
6057 (VEC_RETURN_PART): Expect less.
6058 (RETURN_PART, VIRTUAL_PART): New.
6059 (METHOD): Adjust to C++ virtual methods.
6060 (scan_target_h): Remove reference to C99.
6061 (dname): Output "target_ops::" prefix.
6062 (write_function_header): Adjust to output a C++ class method.
6063 (write_declaration): New.
6064 (write_delegator): Adjust to output a C++ class method.
6065 (tdname): Output "dummy_target::" prefix.
6066 (write_tdefault, write_debugmethod): Adjust to output a C++ class
6067 method.
6068 (tdefault_names, debug_names): Delete.
6069 (return_types, tdefaults, styles, argtypes_array): New.
6070 (top level): All methods are delegators.
6071 (print_class): New.
6072 (top level): Print dummy_target and debug_target classes.
6073 * target-delegates.c: Regenerate.
6074 * target-debug.h (target_debug_print_enum_info_proc_what)
6075 (target_debug_print_thread_control_capabilities)
6076 (target_debug_print_thread_info_p): New.
6077 * target.c (dummy_target): Delete.
6078 (the_dummy_target, the_debug_target): New.
6079 (target_stack): Now extern.
6080 (set_targetdebug): Push/unpush debug target.
6081 (default_child_has_all_memory, default_child_has_memory)
6082 (default_child_has_stack, default_child_has_registers)
6083 (default_child_has_execution): Remove target_ops parameter.
6084 (complete_target_initialization): Delete.
6085 (add_target_with_completer): No longer call
6086 complete_target_initialization.
6087 (target_supports_terminal_ours): Use regular delegation.
6088 (update_current_target): Delete.
6089 (push_target): No longer check magic number. Don't call
6090 update_current_target.
6091 (unpush_target): Don't call update_current_target.
6092 (target_is_pushed): No longer check magic number.
6093 (target_require_runnable): Skip for all stratums over
6094 process_stratum.
6095 (target_ops::info_proc): New.
6096 (target_info_proc): Use find_target_at and
6097 find_default_run_target.
6098 (target_supports_disable_randomization): Use regular delegation.
6099 (target_get_osdata): Use find_target_at.
6100 (target_ops::open, target_ops::close, target_ops::can_attach)
6101 (target_ops::attach, target_ops::can_create_inferior)
6102 (target_ops::create_inferior, target_ops::can_run)
6103 (target_can_run): New.
6104 (default_fileio_target): Use regular delegation.
6105 (target_ops::fileio_open, target_ops::fileio_pwrite)
6106 (target_ops::fileio_pread, target_ops::fileio_fstat)
6107 (target_ops::fileio_close, target_ops::fileio_unlink)
6108 (target_ops::fileio_readlink): New.
6109 (target_fileio_open_1, target_fileio_unlink)
6110 (target_fileio_readlink): Always call the target method. Handle
6111 FILEIO_ENOSYS.
6112 (return_zero, return_zero_has_execution): Delete.
6113 (init_dummy_target): Delete.
6114 (dummy_target::dummy_target, dummy_target::shortname)
6115 (dummy_target::longname, dummy_target::doc)
6116 (debug_target::debug_target, debug_target::shortname)
6117 (debug_target::longname, debug_target::doc): New.
6118 (target_supports_delete_record): Use regular delegation.
6119 (setup_target_debug): Delete.
6120 (maintenance_print_target_stack): Skip debug_stratum.
6121 (initialize_targets): Instantiate the_dummy_target and
6122 the_debug_target.
6123 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
6124 use target_stack.
6125 (target_auxv_search, fprint_target_auxv): Adjust.
6126 (info_auxv_command): Adjust to use target_stack.
6127 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
6128 * exceptions.c (print_flush): Handle a NULL target_stack.
6129 * regcache.c (target_ops_no_register): Refactor as class with
6130 virtual methods.
6131
6132 * exec.c (exec_target): New class.
6133 (exec_ops): Now an exec_target.
6134 (exec_open, exec_close_1, exec_get_section_table)
6135 (exec_xfer_partial, exec_files_info, exec_has_memory)
6136 (exec_make_note_section): Refactor as exec_target methods.
6137 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
6138 Delete.
6139 (exec_target::find_memory_regions): New.
6140 (_initialize_exec): Don't call init_exec_ops.
6141 * gdbcore.h (exec_file_clear): Delete.
6142
6143 * corefile.c (core_target): Delete.
6144 (core_file_command): Adjust.
6145 * corelow.c (core_target): New class.
6146 (the_core_target): New.
6147 (core_close): Remove target_ops parameter.
6148 (core_close_cleanup): Adjust.
6149 (core_target::close): New.
6150 (core_open, core_detach, get_core_registers, core_files_info)
6151 (core_xfer_partial, core_thread_alive, core_read_description)
6152 (core_pid_to_str, core_thread_name, core_has_memory)
6153 (core_has_stack, core_has_registers, core_info_proc): Rework as
6154 core_target methods.
6155 (ignore, core_remove_breakpoint, init_core_ops): Delete.
6156 (_initialize_corelow): Initialize the_core_target.
6157 * gdbcore.h (core_target): Delete.
6158 (the_core_target): New.
6159
6160 * ctf.c: (ctf_target): New class.
6161 (ctf_ops): Now a ctf_target.
6162 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
6163 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
6164 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
6165 methods.
6166 (init_ctf_ops): Delete.
6167 (_initialize_ctf): Don't call it.
6168 * tracefile-tfile.c (tfile_target): New class.
6169 (tfile_ops): Now a tfile_target.
6170 (tfile_open, tfile_close, tfile_files_info)
6171 (tfile_get_tracepoint_status, tfile_trace_find)
6172 (tfile_fetch_registers, tfile_xfer_partial)
6173 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
6174 Refactor as tfile_target methods.
6175 (tfile_xfer_partial_features): Remove target_ops parameter.
6176 (init_tfile_ops): Delete.
6177 (_initialize_tracefile_tfile): Don't call it.
6178 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
6179 (tracefile_has_stack, tracefile_has_registers)
6180 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
6181 tracefile_target methods.
6182 (init_tracefile_ops): Delete.
6183 (tracefile_target::tracefile_target): New.
6184 * tracefile.h: Include "target.h".
6185 (tracefile_target): New class.
6186 (init_tracefile_ops): Delete.
6187
6188 * spu-multiarch.c (spu_multiarch_target): New class.
6189 (spu_ops): Now a spu_multiarch_target.
6190 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
6191 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
6192 (spu_search_memory, spu_mourn_inferior): Refactor as
6193 spu_multiarch_target methods.
6194 (init_spu_ops): Delete.
6195 (_initialize_spu_multiarch): Remove references to init_spu_ops,
6196 complete_target_initialization.
6197
6198 * ravenscar-thread.c (ravenscar_thread_target): New class.
6199 (ravenscar_ops): Now a ravenscar_thread_target.
6200 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
6201 (ravenscar_thread_alive, ravenscar_pid_to_str)
6202 (ravenscar_fetch_registers, ravenscar_store_registers)
6203 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
6204 (ravenscar_stopped_by_hw_breakpoint)
6205 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
6206 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
6207 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
6208 methods.
6209 (init_ravenscar_thread_ops): Delete.
6210 (_initialize_ravenscar): Remove references to
6211 init_ravenscar_thread_ops and complete_target_initialization.
6212
6213 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
6214 (bsd_uthread_target): New class.
6215 (bsd_uthread_ops): Now a bsd_uthread_target.
6216 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
6217 (bsd_uthread_close, bsd_uthread_mourn_inferior)
6218 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
6219 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
6220 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
6221 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
6222 (bsd_uthread_target): Delete function.
6223 (_initialize_bsd_uthread): Remove reference to
6224 complete_target_initialization.
6225
6226 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
6227 (target_bfd): ... this new class.
6228 (target_bfd_xfer_partial, target_bfd_get_section_table)
6229 (target_bfd_close): Refactor as target_bfd methods.
6230 (target_bfd::~target_bfd): New.
6231 (target_bfd_reopen): Adjust.
6232 (target_bfd::close): New.
6233
6234 * record-btrace.c (record_btrace_target): New class.
6235 (record_btrace_ops): Now a record_btrace_target.
6236 (record_btrace_open, record_btrace_stop_recording)
6237 (record_btrace_disconnect, record_btrace_close)
6238 (record_btrace_async, record_btrace_info)
6239 (record_btrace_insn_history, record_btrace_insn_history_range)
6240 (record_btrace_insn_history_from, record_btrace_call_history)
6241 (record_btrace_call_history_range)
6242 (record_btrace_call_history_from, record_btrace_record_method)
6243 (record_btrace_is_replaying, record_btrace_will_replay)
6244 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
6245 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
6246 (record_btrace_store_registers, record_btrace_prepare_to_store)
6247 (record_btrace_to_get_unwinder)
6248 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
6249 (record_btrace_commit_resume, record_btrace_wait)
6250 (record_btrace_stop, record_btrace_can_execute_reverse)
6251 (record_btrace_stopped_by_sw_breakpoint)
6252 (record_btrace_supports_stopped_by_sw_breakpoint)
6253 (record_btrace_stopped_by_hw_breakpoint)
6254 (record_btrace_supports_stopped_by_hw_breakpoint)
6255 (record_btrace_update_thread_list, record_btrace_thread_alive)
6256 (record_btrace_goto_begin, record_btrace_goto_end)
6257 (record_btrace_goto, record_btrace_stop_replaying_all)
6258 (record_btrace_execution_direction)
6259 (record_btrace_prepare_to_generate_core)
6260 (record_btrace_done_generating_core): Refactor as
6261 record_btrace_target methods.
6262 (init_record_btrace_ops): Delete.
6263 (_initialize_record_btrace): Remove reference to
6264 init_record_btrace_ops.
6265 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
6266 the execution_direction global.
6267 (record_full_base_target, record_full_target)
6268 (record_full_core_target): New classes.
6269 (record_full_ops): Now a record_full_target.
6270 (record_full_core_ops): Now a record_full_core_target.
6271 (record_full_target::detach, record_full_target::disconnect)
6272 (record_full_core_target::disconnect)
6273 (record_full_target::mourn_inferior, record_full_target::kill):
6274 New.
6275 (record_full_open, record_full_close, record_full_async): Refactor
6276 as methods of the record_full_base_target class.
6277 (record_full_resume, record_full_commit_resume): Refactor
6278 as methods of the record_full_target class.
6279 (record_full_wait, record_full_stopped_by_watchpoint)
6280 (record_full_stopped_data_address)
6281 (record_full_stopped_by_sw_breakpoint)
6282 (record_full_supports_stopped_by_sw_breakpoint)
6283 (record_full_stopped_by_hw_breakpoint)
6284 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
6285 methods of the record_full_base_target class.
6286 (record_full_store_registers, record_full_xfer_partial)
6287 (record_full_insert_breakpoint, record_full_remove_breakpoint):
6288 Refactor as methods of the record_full_target class.
6289 (record_full_can_execute_reverse, record_full_get_bookmark)
6290 (record_full_goto_bookmark, record_full_execution_direction)
6291 (record_full_record_method, record_full_info, record_full_delete)
6292 (record_full_is_replaying, record_full_will_replay)
6293 (record_full_goto_begin, record_full_goto_end, record_full_goto)
6294 (record_full_stop_replaying): Refactor as methods of the
6295 record_full_base_target class.
6296 (record_full_core_resume, record_full_core_kill)
6297 (record_full_core_fetch_registers)
6298 (record_full_core_prepare_to_store)
6299 (record_full_core_store_registers, record_full_core_xfer_partial)
6300 (record_full_core_insert_breakpoint)
6301 (record_full_core_remove_breakpoint)
6302 (record_full_core_has_execution): Refactor
6303 as methods of the record_full_core_target class.
6304 (record_full_base_target::supports_delete_record): New.
6305 (init_record_full_ops): Delete.
6306 (init_record_full_core_ops): Delete.
6307 (record_full_save): Refactor as method of the
6308 record_full_base_target class.
6309 (_initialize_record_full): Remove references to
6310 init_record_full_ops and init_record_full_core_ops.
6311
6312 * remote.c (remote_target, extended_remote_target): New classes.
6313 (remote_ops): Now a remote_target.
6314 (extended_remote_ops): Now an extended_remote_target.
6315 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
6316 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
6317 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
6318 (remote_pass_signals, remote_set_syscall_catchpoint)
6319 (remote_program_signals, )
6320 (remote_thread_always_alive): Remove target_ops parameter.
6321 (remote_thread_alive, remote_thread_name)
6322 (remote_update_thread_list, remote_threads_extra_info)
6323 (remote_static_tracepoint_marker_at)
6324 (remote_static_tracepoint_markers_by_strid)
6325 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
6326 (remote_open): Refactor as methods of remote_target.
6327 (extended_remote_open, extended_remote_detach)
6328 (extended_remote_attach, extended_remote_post_attach):
6329 (extended_remote_supports_disable_randomization)
6330 (extended_remote_create_inferior): : Refactor as method of
6331 extended_remote_target.
6332 (remote_set_permissions, remote_open_1, remote_detach)
6333 (remote_follow_fork, remote_follow_exec, remote_disconnect)
6334 (remote_resume, remote_commit_resume, remote_stop)
6335 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
6336 (remote_terminal_ours, remote_wait, remote_fetch_registers)
6337 (remote_prepare_to_store, remote_store_registers)
6338 (remote_flash_erase, remote_flash_done, remote_files_info)
6339 (remote_kill, remote_mourn, remote_insert_breakpoint)
6340 (remote_remove_breakpoint, remote_insert_watchpoint)
6341 (remote_watchpoint_addr_within_range)
6342 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
6343 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
6344 (remote_supports_stopped_by_sw_breakpoint)
6345 (remote_stopped_by_hw_breakpoint)
6346 (remote_supports_stopped_by_hw_breakpoint)
6347 (remote_stopped_by_watchpoint, remote_stopped_data_address)
6348 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
6349 (remote_verify_memory): Refactor as methods of remote_target.
6350 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
6351 parameter.
6352 (remote_xfer_partial, remote_get_memory_xfer_limit)
6353 (remote_search_memory, remote_rcmd, remote_memory_map)
6354 (remote_pid_to_str, remote_get_thread_local_address)
6355 (remote_get_tib_address, remote_read_description): Refactor as
6356 methods of remote_target.
6357 (remote_target::fileio_open, remote_target::fileio_pwrite)
6358 (remote_target::fileio_pread, remote_target::fileio_close): New.
6359 (remote_hostio_readlink, remote_hostio_fstat)
6360 (remote_filesystem_is_local, remote_can_execute_reverse)
6361 (remote_supports_non_stop, remote_supports_disable_randomization)
6362 (remote_supports_multi_process, remote_supports_cond_breakpoints)
6363 (remote_supports_enable_disable_tracepoint)
6364 (remote_supports_string_tracing)
6365 (remote_can_run_breakpoint_commands, remote_trace_init)
6366 (remote_download_tracepoint, remote_can_download_tracepoint)
6367 (remote_download_trace_state_variable, remote_enable_tracepoint)
6368 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
6369 (remote_trace_start, remote_get_trace_status)
6370 (remote_get_tracepoint_status, remote_trace_stop)
6371 (remote_trace_find, remote_get_trace_state_variable_value)
6372 (remote_save_trace_data, remote_get_raw_trace_data)
6373 (remote_set_disconnected_tracing, remote_core_of_thread)
6374 (remote_set_circular_trace_buffer, remote_traceframe_info)
6375 (remote_get_min_fast_tracepoint_insn_len)
6376 (remote_set_trace_buffer_size, remote_set_trace_notes)
6377 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
6378 (remote_disable_btrace, remote_teardown_btrace)
6379 (remote_read_btrace, remote_btrace_conf)
6380 (remote_augmented_libraries_svr4_read, remote_load)
6381 (remote_pid_to_exec_file, remote_can_do_single_step)
6382 (remote_execution_direction, remote_thread_handle_to_thread_info):
6383 Refactor as methods of remote_target.
6384 (init_remote_ops, init_extended_remote_ops): Delete.
6385 (remote_can_async_p, remote_is_async_p, remote_async)
6386 (remote_thread_events, remote_upload_tracepoints)
6387 (remote_upload_trace_state_variables): Refactor as methods of
6388 remote_target.
6389 (_initialize_remote): Remove references to init_remote_ops and
6390 init_extended_remote_ops.
6391
6392 * remote-sim.c (gdbsim_target): New class.
6393 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
6394 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
6395 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
6396 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
6397 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
6398 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
6399 Refactor as methods of gdbsim_target.
6400 (gdbsim_ops): Now a gdbsim_target.
6401 (init_gdbsim_ops): Delete.
6402 (gdbsim_cntrl_c): Adjust.
6403 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
6404
6405 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
6406 (the_amd64_linux_nat_target): New.
6407 (amd64_linux_fetch_inferior_registers)
6408 (amd64_linux_store_inferior_registers): Refactor as methods of
6409 amd64_linux_nat_target.
6410 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
6411 * i386-linux-nat.c: Don't include "linux-nat.h".
6412 (i386_linux_nat_target): New class.
6413 (the_i386_linux_nat_target): New.
6414 (i386_linux_fetch_inferior_registers)
6415 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
6416 as methods of i386_linux_nat_target.
6417 (_initialize_i386_linux_nat): Adjust. Set linux_target.
6418 * inf-child.c (inf_child_ops): Delete.
6419 (inf_child_fetch_inferior_registers)
6420 (inf_child_store_inferior_registers): Delete.
6421 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
6422 methods of inf_child_target.
6423 (inf_child_target::supports_terminal_ours)
6424 (inf_child_target::terminal_init)
6425 (inf_child_target::terminal_inferior)
6426 (inf_child_target::terminal_ours_for_output)
6427 (inf_child_target::terminal_ours, inf_child_target::interrupt)
6428 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
6429 New.
6430 (inf_child_open, inf_child_disconnect, inf_child_close)
6431 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
6432 (inf_child_post_startup_inferior, inf_child_can_run)
6433 (inf_child_pid_to_exec_file): Refactor as methods of
6434 inf_child_target.
6435 (inf_child_follow_fork): Delete.
6436 (inf_child_target::can_create_inferior)
6437 (inf_child_target::can_attach): New.
6438 (inf_child_target::has_all_memory, inf_child_target::has_memory)
6439 (inf_child_target::has_stack, inf_child_target::has_registers)
6440 (inf_child_target::has_execution): New.
6441 (inf_child_fileio_open, inf_child_fileio_pwrite)
6442 (inf_child_fileio_pread, inf_child_fileio_fstat)
6443 (inf_child_fileio_close, inf_child_fileio_unlink)
6444 (inf_child_fileio_readlink, inf_child_use_agent)
6445 (inf_child_can_use_agent): Refactor as methods of
6446 inf_child_target.
6447 (return_zero, inf_child_target): Delete.
6448 (inf_child_target::inf_child_target): New.
6449 * inf-child.h: Include "target.h".
6450 (inf_child_target): Delete function prototype.
6451 (inf_child_target): New class.
6452 (inf_child_open_target, inf_child_mourn_inferior)
6453 (inf_child_maybe_unpush_target): Delete.
6454 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
6455 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
6456 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
6457 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
6458 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
6459 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
6460 (inf_ptrace_wait, inf_ptrace_xfer_partial)
6461 (inf_ptrace_thread_alive, inf_ptrace_files_info)
6462 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
6463 methods of inf_ptrace_target.
6464 (inf_ptrace_target): Delete function.
6465 * inf-ptrace.h: Include "inf-child.h".
6466 (inf_ptrace_target): Delete function declaration.
6467 (inf_ptrace_target): New class.
6468 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
6469 * linux-nat.c (linux_target): New.
6470 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
6471 (linux_nat_target::~linux_nat_target): New.
6472 (linux_child_post_attach, linux_child_post_startup_inferior)
6473 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
6474 (linux_child_remove_fork_catchpoint)
6475 (linux_child_insert_vfork_catchpoint)
6476 (linux_child_remove_vfork_catchpoint)
6477 (linux_child_insert_exec_catchpoint)
6478 (linux_child_remove_exec_catchpoint)
6479 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
6480 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
6481 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
6482 (linux_nat_stopped_data_address)
6483 (linux_nat_stopped_by_sw_breakpoint)
6484 (linux_nat_supports_stopped_by_sw_breakpoint)
6485 (linux_nat_stopped_by_hw_breakpoint)
6486 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
6487 (linux_nat_kill, linux_nat_mourn_inferior)
6488 (linux_nat_xfer_partial, linux_nat_thread_alive)
6489 (linux_nat_update_thread_list, linux_nat_pid_to_str)
6490 (linux_nat_thread_name, linux_child_pid_to_exec_file)
6491 (linux_child_static_tracepoint_markers_by_strid)
6492 (linux_nat_is_async_p, linux_nat_can_async_p)
6493 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
6494 (linux_nat_supports_multi_process)
6495 (linux_nat_supports_disable_randomization, linux_nat_async)
6496 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
6497 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
6498 (linux_nat_fileio_open, linux_nat_fileio_readlink)
6499 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
6500 methods of linux_nat_target.
6501 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
6502 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
6503 parameter.
6504 (check_stopped_by_watchpoint): Adjust.
6505 (linux_xfer_partial): Delete.
6506 (linux_target_install_ops, linux_target, linux_nat_add_target):
6507 Delete.
6508 (linux_nat_target::linux_nat_target): New.
6509 * linux-nat.h: Include "inf-ptrace.h".
6510 (linux_nat_target): New.
6511 (linux_target, linux_target_install_ops, linux_nat_add_target):
6512 Delete function declarations.
6513 (linux_target): Declare global.
6514 * linux-thread-db.c (thread_db_target): New.
6515 (thread_db_target::thread_db_target): New.
6516 (thread_db_ops): Delete.
6517 (the_thread_db_target): New.
6518 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
6519 (thread_db_update_thread_list, thread_db_pid_to_str)
6520 (thread_db_extra_thread_info)
6521 (thread_db_thread_handle_to_thread_info)
6522 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
6523 (thread_db_resume): Refactor as methods of thread_db_target.
6524 (init_thread_db_ops): Delete.
6525 (_initialize_thread_db): Remove reference to init_thread_db_ops.
6526 * x86-linux-nat.c: Don't include "linux-nat.h".
6527 (super_post_startup_inferior): Delete.
6528 (x86_linux_nat_target::~x86_linux_nat_target): New.
6529 (x86_linux_child_post_startup_inferior)
6530 (x86_linux_read_description, x86_linux_enable_btrace)
6531 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
6532 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
6533 methods of x86_linux_nat_target.
6534 (x86_linux_create_target): Delete. Bits folded ...
6535 (x86_linux_add_target): ... here. Now takes a linux_nat_target
6536 pointer.
6537 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
6538 (x86_linux_nat_target): New class.
6539 (x86_linux_create_target): Delete.
6540 (x86_linux_add_target): Now takes a linux_nat_target pointer.
6541 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
6542 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
6543 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
6544 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
6545 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
6546 make extern.
6547 (x86_use_watchpoints): Delete.
6548 * x86-nat.h: Include "breakpoint.h" and "target.h".
6549 (x86_use_watchpoints): Delete.
6550 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
6551 (x86_stopped_by_watchpoint, x86_stopped_data_address)
6552 (x86_insert_watchpoint, x86_remove_watchpoint)
6553 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
6554 (x86_stopped_by_hw_breakpoint): New declarations.
6555 (x86_nat_target): New template class.
6556
6557 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
6558 (the_ppc_linux_nat_target): New.
6559 (ppc_linux_fetch_inferior_registers)
6560 (ppc_linux_can_use_hw_breakpoint)
6561 (ppc_linux_region_ok_for_hw_watchpoint)
6562 (ppc_linux_ranged_break_num_registers)
6563 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
6564 (ppc_linux_insert_mask_watchpoint)
6565 (ppc_linux_remove_mask_watchpoint)
6566 (ppc_linux_can_accel_watchpoint_condition)
6567 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
6568 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
6569 (ppc_linux_watchpoint_addr_within_range)
6570 (ppc_linux_masked_watch_num_registers)
6571 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
6572 (ppc_linux_read_description): Refactor as methods of
6573 ppc_linux_nat_target.
6574 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
6575
6576 * procfs.c (procfs_xfer_partial): Delete forward declaration.
6577 (procfs_target): New class.
6578 (the_procfs_target): New.
6579 (procfs_target): Delete function.
6580 (procfs_auxv_parse, procfs_attach, procfs_detach)
6581 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
6582 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
6583 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
6584 (procfs_create_inferior, procfs_update_thread_list)
6585 (procfs_thread_alive, procfs_pid_to_str)
6586 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
6587 (procfs_stopped_data_address, procfs_insert_watchpoint)
6588 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
6589 (proc_find_memory_regions, procfs_info_proc)
6590 (procfs_make_note_section): Refactor as methods of procfs_target.
6591 (_initialize_procfs): Adjust.
6592 * sol-thread.c (sol_thread_target): New class.
6593 (sol_thread_ops): Now a sol_thread_target.
6594 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
6595 (sol_thread_fetch_registers, sol_thread_store_registers)
6596 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
6597 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
6598 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
6599 (init_sol_thread_ops): Delete.
6600 (_initialize_sol_thread): Adjust. Remove references to
6601 init_sol_thread_ops and complete_target_initialization.
6602
6603 * windows-nat.c (windows_nat_target): New class.
6604 (windows_fetch_inferior_registers)
6605 (windows_store_inferior_registers, windows_resume, windows_wait)
6606 (windows_attach, windows_detach, windows_pid_to_exec_file)
6607 (windows_files_info, windows_create_inferior)
6608 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
6609 (windows_close, windows_pid_to_str, windows_xfer_partial)
6610 (windows_get_tib_address, windows_get_ada_task_ptid)
6611 (windows_thread_name, windows_thread_alive): Refactor as
6612 windows_nat_target methods.
6613 (do_initial_windows_stuff): Adjust.
6614 (windows_target): Delete function.
6615 (_initialize_windows_nat): Adjust.
6616
6617 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
6618 (darwin_mourn_inferior, darwin_kill_inferior)
6619 (darwin_create_inferior, darwin_attach, darwin_detach)
6620 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
6621 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
6622 (darwin_supports_multi_process): Refactor as darwin_nat_target
6623 methods.
6624 (darwin_resume_to, darwin_files_info): Delete.
6625 (_initialize_darwin_inferior): Rename to ...
6626 (_initialize_darwin_nat): ... this. Adjust to C++ification.
6627 * darwin-nat.h: Include "inf-child.h".
6628 (darwin_nat_target): New class.
6629 (darwin_complete_target): Delete.
6630 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
6631 (darwin_target): New.
6632 (i386_darwin_fetch_inferior_registers)
6633 (i386_darwin_store_inferior_registers): Refactor as methods of
6634 darwin_nat_target.
6635 (darwin_complete_target): Delete, with ...
6636 (_initialize_i386_darwin_nat): ... bits factored out here.
6637
6638 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
6639 (the_alpha_linux_nat_target): New.
6640 (alpha_linux_register_u_offset): Refactor as
6641 alpha_linux_nat_target method.
6642 (_initialize_alpha_linux_nat): Adjust.
6643 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
6644 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6645 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
6646 methods of linux_nat_trad_target.
6647 (linux_trad_target): Delete.
6648 * linux-nat-trad.h (linux_trad_target): Delete function.
6649 (linux_nat_trad_target): New class.
6650 * mips-linux-nat.c (mips_linux_nat_target): New class.
6651 (super_fetch_registers, super_store_registers, super_close):
6652 Delete.
6653 (the_mips_linux_nat_target): New.
6654 (mips64_linux_regsets_fetch_registers)
6655 (mips64_linux_regsets_store_registers)
6656 (mips64_linux_fetch_registers, mips64_linux_store_registers)
6657 (mips_linux_register_u_offset, mips_linux_read_description)
6658 (mips_linux_can_use_hw_breakpoint)
6659 (mips_linux_stopped_by_watchpoint)
6660 (mips_linux_stopped_data_address)
6661 (mips_linux_region_ok_for_hw_watchpoint)
6662 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
6663 (mips_linux_close): Refactor as methods of mips_linux_nat.
6664 (_initialize_mips_linux_nat): Adjust to C++ification.
6665
6666 * aix-thread.c (aix_thread_target): New class.
6667 (aix_thread_ops): Now an aix_thread_target.
6668 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
6669 (aix_thread_fetch_registers, aix_thread_store_registers)
6670 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
6671 (aix_thread_thread_alive, aix_thread_pid_to_str)
6672 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
6673 Refactor as methods of aix_thread_target.
6674 (init_aix_thread_ops): Delete.
6675 (_initialize_aix_thread): Remove references to init_aix_thread_ops
6676 and complete_target_initialization.
6677 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
6678 (rs6000_nat_target): New class.
6679 (the_rs6000_nat_target): New.
6680 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
6681 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
6682 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
6683 (super_create_inferior): Delete.
6684 (_initialize_rs6000_nat): Adjust to C++ification.
6685
6686 * arm-linux-nat.c (arm_linux_nat_target): New class.
6687 (the_arm_linux_nat_target): New.
6688 (arm_linux_fetch_inferior_registers)
6689 (arm_linux_store_inferior_registers, arm_linux_read_description)
6690 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
6691 (arm_linux_remove_hw_breakpoint)
6692 (arm_linux_region_ok_for_hw_watchpoint)
6693 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
6694 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
6695 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
6696 arm_linux_nat_target.
6697 (_initialize_arm_linux_nat): Adjust to C++ification.
6698
6699 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
6700 (the_aarch64_linux_nat_target): New.
6701 (aarch64_linux_fetch_inferior_registers)
6702 (aarch64_linux_store_inferior_registers)
6703 (aarch64_linux_child_post_startup_inferior)
6704 (aarch64_linux_read_description)
6705 (aarch64_linux_can_use_hw_breakpoint)
6706 (aarch64_linux_insert_hw_breakpoint)
6707 (aarch64_linux_remove_hw_breakpoint)
6708 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
6709 (aarch64_linux_region_ok_for_hw_watchpoint)
6710 (aarch64_linux_stopped_data_address)
6711 (aarch64_linux_stopped_by_watchpoint)
6712 (aarch64_linux_watchpoint_addr_within_range)
6713 (aarch64_linux_can_do_single_step): Refactor as methods of
6714 aarch64_linux_nat_target.
6715 (super_post_startup_inferior): Delete.
6716 (_initialize_aarch64_linux_nat): Adjust to C++ification.
6717
6718 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
6719 (the_hppa_linux_nat_target): New.
6720 (hppa_linux_fetch_inferior_registers)
6721 (hppa_linux_store_inferior_registers): Refactor as methods of
6722 hppa_linux_nat_target.
6723 (_initialize_hppa_linux_nat): Adjust to C++ification.
6724
6725 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
6726 (the_ia64_linux_nat_target): New.
6727 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
6728 (ia64_linux_stopped_data_address)
6729 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
6730 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
6731 ia64_linux_nat_target methods.
6732 (super_xfer_partial): Delete.
6733 (_initialize_ia64_linux_nat): Adjust to C++ification.
6734
6735 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
6736 (the_m32r_linux_nat_target): New.
6737 (m32r_linux_fetch_inferior_registers)
6738 (m32r_linux_store_inferior_registers): Refactor as
6739 m32r_linux_nat_target methods.
6740 (_initialize_m32r_linux_nat): Adjust to C++ification.
6741
6742 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
6743 (the_m68k_linux_nat_target): New.
6744 (m68k_linux_fetch_inferior_registers)
6745 (m68k_linux_store_inferior_registers): Refactor as
6746 m68k_linux_nat_target methods.
6747 (_initialize_m68k_linux_nat): Adjust to C++ification.
6748
6749 * s390-linux-nat.c (s390_linux_nat_target): New class.
6750 (the_s390_linux_nat_target): New.
6751 (s390_linux_fetch_inferior_registers)
6752 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
6753 (s390_insert_watchpoint, s390_remove_watchpoint)
6754 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
6755 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
6756 (s390_auxv_parse, s390_read_description): Refactor as methods of
6757 s390_linux_nat_target.
6758 (_initialize_s390_nat): Adjust to C++ification.
6759
6760 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
6761 (the_sparc_linux_nat_target): New.
6762 (_initialize_sparc_linux_nat): Adjust to C++ification.
6763 * sparc-nat.c (sparc_fetch_inferior_registers)
6764 (sparc_store_inferior_registers): Remove target_ops parameter.
6765 * sparc-nat.h (sparc_fetch_inferior_registers)
6766 (sparc_store_inferior_registers): Remove target_ops parameter.
6767 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
6768 (the_sparc64_linux_nat_target): New.
6769 (_initialize_sparc64_linux_nat): Adjust to C++ification.
6770
6771 * spu-linux-nat.c (spu_linux_nat_target): New class.
6772 (the_spu_linux_nat_target): New.
6773 (spu_child_post_startup_inferior, spu_child_post_attach)
6774 (spu_child_wait, spu_fetch_inferior_registers)
6775 (spu_store_inferior_registers, spu_xfer_partial)
6776 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
6777 methods.
6778 (_initialize_spu_nat): Adjust to C++ification.
6779
6780 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
6781 (the_tilegx_linux_nat_target): New.
6782 (fetch_inferior_registers, store_inferior_registers):
6783 Refactor as methods.
6784 (_initialize_tile_linux_nat): Adjust to C++ification.
6785
6786 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
6787 (the_xtensa_linux_nat_target): New.
6788 (xtensa_linux_fetch_inferior_registers)
6789 (xtensa_linux_store_inferior_registers): Refactor as
6790 xtensa_linux_nat_target methods.
6791 (_initialize_xtensa_linux_nat): Adjust to C++ification.
6792
6793 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
6794 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
6795 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
6796 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
6797 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
6798 (fbsd_stopped_by_sw_breakpoint)
6799 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
6800 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
6801 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
6802 (fbsd_post_startup_inferior, fbsd_post_attach)
6803 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
6804 (fbsd_set_syscall_catchpoint)
6805 (super_xfer_partial, super_resume, super_wait)
6806 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
6807 (fbsd_handle_debug_trap): Remove target_ops parameter.
6808 (fbsd_nat_add_target): Delete.
6809 * fbsd-nat.h: Include "inf-ptrace.h".
6810 (fbsd_nat_add_target): Delete.
6811 (USE_SIGTRAP_SIGINFO): Define.
6812 (fbsd_nat_target): New class.
6813
6814 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
6815 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
6816 (amd64bsd_target): Delete.
6817 * amd64-bsd-nat.h: New file.
6818 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
6819 "x86-bsd-nat.h".
6820 (amd64_fbsd_nat_target): New class.
6821 (the_amd64_fbsd_nat_target): New.
6822 (amd64fbsd_read_description): Refactor as method of
6823 amd64_fbsd_nat_target.
6824 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6825 (_initialize_amd64fbsd_nat): Adjust to C++ification.
6826 * amd64-nat.h (amd64bsd_target): Delete function declaration.
6827 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
6828 (i386bsd_store_inferior_registers): Remove target_ops parameter.
6829 (i386bsd_target): Delete.
6830 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
6831 (i386bsd_fetch_inferior_registers)
6832 (i386bsd_store_inferior_registers): Declare.
6833 (i386_bsd_nat_target): New class.
6834 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
6835 (the_i386_fbsd_nat_target): New.
6836 (i386fbsd_resume, i386fbsd_read_description): Refactor as
6837 i386_fbsd_nat_target methods.
6838 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6839 (_initialize_i386fbsd_nat): Adjust to C++ification.
6840 * x86-bsd-nat.c (super_mourn_inferior): Delete.
6841 (x86bsd_mourn_inferior, x86bsd_target): Delete.
6842 (_initialize_x86_bsd_nat): Adjust to C++ification.
6843 * x86-bsd-nat.h: Include "x86-nat.h".
6844 (x86bsd_target): Delete declaration.
6845 (x86bsd_nat_target): New class.
6846
6847 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
6848 (the_aarch64_fbsd_nat_target): New.
6849 (aarch64_fbsd_fetch_inferior_registers)
6850 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
6851 aarch64_fbsd_nat_target.
6852 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
6853 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
6854 (the_alpha_bsd_nat_target): New.
6855 (alphabsd_fetch_inferior_registers)
6856 (alphabsd_store_inferior_registers): Refactor as
6857 alpha_bsd_nat_target methods.
6858 (_initialize_alphabsd_nat): Refactor as methods of
6859 alpha_bsd_nat_target.
6860 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
6861 (the_amd64_nbsd_nat_target): New.
6862 (_initialize_amd64nbsd_nat): Adjust to C++ification.
6863 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
6864 (the_amd64_obsd_nat_target): New.
6865 (_initialize_amd64obsd_nat): Adjust to C++ification.
6866 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
6867 (the_arm_fbsd_nat_target): New.
6868 (arm_fbsd_fetch_inferior_registers)
6869 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
6870 (_initialize_arm_fbsd_nat): Refactor as methods of
6871 arm_fbsd_nat_target.
6872 (_initialize_arm_fbsd_nat): Adjust to C++ification.
6873 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
6874 (the_arm_netbsd_nat_target): New.
6875 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
6876 arm_netbsd_nat_target.
6877 (_initialize_arm_netbsd_nat): Adjust to C++ification.
6878 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
6879 (the_hppa_nbsd_nat_target): New.
6880 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
6881 hppa_nbsd_nat_target methods.
6882 (_initialize_hppanbsd_nat): Adjust to C++ification.
6883 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
6884 (the_hppa_obsd_nat_target): New.
6885 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
6886 methods of hppa_obsd_nat_target.
6887 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
6888 add_target.
6889 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
6890 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
6891 add_target.
6892 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
6893 (_initialize_i386obsd_nat): Use add_target.
6894 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
6895 (the_m68k_bsd_nat_target): New.
6896 (m68kbsd_fetch_inferior_registers)
6897 (m68kbsd_store_inferior_registers): Refactor as methods of
6898 m68k_bsd_nat_target.
6899 (_initialize_m68kbsd_nat): Adjust to C++ification.
6900 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
6901 (the_mips_fbsd_nat_target): New.
6902 (mips_fbsd_fetch_inferior_registers)
6903 (mips_fbsd_store_inferior_registers): Refactor as methods of
6904 mips_fbsd_nat_target.
6905 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
6906 add_target.
6907 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
6908 (the_mips_nbsd_nat_target): New.
6909 (mipsnbsd_fetch_inferior_registers)
6910 (mipsnbsd_store_inferior_registers): Refactor as methods of
6911 mips_nbsd_nat_target.
6912 (_initialize_mipsnbsd_nat): Adjust to C++ification.
6913 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
6914 (the_mips64_obsd_nat_target): New.
6915 (mips64obsd_fetch_inferior_registers)
6916 (mips64obsd_store_inferior_registers): Refactor as methods of
6917 mips64_obsd_nat_target.
6918 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
6919 add_target.
6920 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
6921 nbsd_nat_target.
6922 * nbsd-nat.h: Include "inf-ptrace.h".
6923 (nbsd_nat_target): New class.
6924 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
6925 (obsd_wait): Refactor as methods of obsd_nat_target.
6926 (obsd_add_target): Delete.
6927 * obsd-nat.h: Include "inf-ptrace.h".
6928 (obsd_nat_target): New class.
6929 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
6930 (the_ppc_fbsd_nat_target): New.
6931 (ppcfbsd_fetch_inferior_registers)
6932 (ppcfbsd_store_inferior_registers): Refactor as methods of
6933 ppc_fbsd_nat_target.
6934 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
6935 add_target.
6936 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
6937 (the_ppc_nbsd_nat_target): New.
6938 (ppcnbsd_fetch_inferior_registers)
6939 (ppcnbsd_store_inferior_registers): Refactor as methods of
6940 ppc_nbsd_nat_target.
6941 (_initialize_ppcnbsd_nat): Adjust to C++ification.
6942 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
6943 (the_ppc_obsd_nat_target): New.
6944 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
6945 methods of ppc_obsd_nat_target.
6946 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
6947 add_target.
6948 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
6949 (the_sh_nbsd_nat_target): New.
6950 (shnbsd_fetch_inferior_registers)
6951 (shnbsd_store_inferior_registers): Refactor as methods of
6952 sh_nbsd_nat_target.
6953 (_initialize_shnbsd_nat): Adjust to C++ification.
6954 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
6955 (inf_ptrace_xfer_partial): Delete.
6956 (sparc_xfer_partial, sparc_target): Delete.
6957 * sparc-nat.h (sparc_fetch_inferior_registers)
6958 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
6959 (sparc_target): Delete function declaration.
6960 (sparc_target): New template class.
6961 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
6962 (_initialize_sparcnbsd_nat): Adjust to C++ification.
6963 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
6964 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
6965 add_target.
6966 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
6967 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
6968 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
6969 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
6970 add_target.
6971 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
6972 (the_vax_bsd_nat_target): New.
6973 (vaxbsd_fetch_inferior_registers)
6974 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
6975 methods.
6976 (_initialize_vaxbsd_nat): Adjust to C++ification.
6977
6978 * bsd-kvm.c (bsd_kvm_target): New class.
6979 (bsd_kvm_ops): Now a bsd_kvm_target.
6980 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
6981 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
6982 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
6983 bsd_kvm_target.
6984 (bsd_kvm_return_one): Delete.
6985 (bsd_kvm_add_target): Adjust to C++ification.
6986
6987 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
6988 (nto_procfs_target_procfs): New classes.
6989 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
6990 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
6991 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
6992 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
6993 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
6994 (procfs_remove_hw_breakpoint, procfs_resume)
6995 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
6996 (procfs_kill_inferior, procfs_store_registers)
6997 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
6998 as methods of nto_procfs_target.
6999 (nto_procfs_ops): Now an nto_procfs_target_procfs.
7000 (nto_native_ops): Delete.
7001 (procfs_open, procfs_native_open): Delete.
7002 (nto_native_ops): Now an nto_procfs_target_native.
7003 (init_procfs_targets): Adjust to C++ification.
7004 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
7005 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
7006 Refactor as methods of nto_procfs_target.
7007
7008 * go32-nat.c (go32_nat_target): New class.
7009 (the_go32_nat_target): New.
7010 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
7011 (go32_store_registers, go32_xfer_partial, go32_files_info)
7012 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
7013 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
7014 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
7015 (go32_pid_to_str): Refactor as methods of go32_nat_target.
7016 (go32_target): Delete.
7017 (_initialize_go32_nat): Adjust to C++ification.
7018
7019 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
7020 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
7021 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
7022 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
7023 gnu_nat_target.
7024 (gnu_target): Delete.
7025 * gnu-nat.h (gnu_target): Delete.
7026 (gnu_nat_target): New class.
7027 * i386-gnu-nat.c (gnu_base_target): New.
7028 (i386_gnu_nat_target): New class.
7029 (the_i386_gnu_nat_target): New.
7030 (_initialize_i386gnu_nat): Adjust to C++ification.
7031
3fffc070
PA
70322018-05-02 Pedro Alves <palves@redhat.com>
7033
7034 * bfd-target.c (target_bfd_xclose): Rename to ...
7035 (target_bfd_close): ... this.
7036 (target_bfd_reopen): Adjust.
7037 * target.c (target_close): Remove references to to_xclose.
7038 * target.h (target_ops::to_xclose): Delete.
7039 (target_ops::to_close): Update comments.
7040
6798487f
PA
70412018-05-02 Pedro Alves <palves@redhat.com>
7042
7043 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
7044 "linux-nat.h".
7045 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
7046 * inf-ptrace.c (inf_ptrace_register_u_offset)
7047 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
7048 (inf_ptrace_store_register, inf_ptrace_store_registers)
7049 (inf_ptrace_trad_target): Move to ...
7050 * linux-nat-trad.c: ... this new file.
7051 * linux-nat-trad.h: New file.
7052 * linux-nat.c (linux_target_install_ops): Make extern.
7053 (linux_trad_target): Delete.
7054 * linux-nat.h (linux_trad_target): Delete declaration.
7055 (linux_target_install_ops): Declare.
7056 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
7057 "linux-nat.h".
7058
c1955e17
PA
70592018-05-02 Pedro Alves <palves@redhat.com>
7060
7061 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
7062 procfs_target/add_target here.
7063 * procfs.c (procfs_target): Make static.
7064 (_initialize_procfs): Call add_target here.
7065 * procfs.h (struct target_ops): Remove forward declaration.
7066 (procfs_target): Remove declaration.
7067 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
7068
b5c8fcb1
PA
70692018-05-02 Pedro Alves <palves@redhat.com>
7070
7071 * procfs.c (procfs_stopped_by_watchpoint)
7072 (procfs_insert_watchpoint, procfs_remove_watchpoint)
7073 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
7074 Forward declare.
7075 (procfs_use_watchpoints): Delete, move contents...
7076 (procfs_target): ... here.
7077 * procfs.h (procfs_use_watchpoints): Delete declaration.
7078 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
7079 procfs_use_watchpoints.
7080 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
7081 procfs_use_watchpoints.
7082
0489430a
TT
70832018-05-02 Tom Tromey <tom@tromey.com>
7084
7085 PR python/20084:
7086 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
7087 and var_zuinteger_unlimited.
7088 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
7089 and PARAM_ZUINTEGER_UNLIMITED.
7090 (set_parameter_value): Handle var_zuinteger and
7091 var_zuinteger_unlimited.
7092 (add_setshow_generic): Likewise.
7093 (parmpy_init): Likewise.
7094
1632f8ba
DR
70952018-04-28 Dan Robertson <danlrobertson89@gmail.com>
7096
7097 PR rust/23124
7098 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
7099 pointer is not null before dereferencing it.
7100
76761936
TT
71012018-04-30 Tom Tromey <tom@tromey.com>
7102
7103 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
7104 is_mi_like_p.
7105
2d33446d
TT
71062018-04-30 Tom Tromey <tom@tromey.com>
7107
7108 * breakpoint.c (mention): Remove use of is_mi_like_p.
7109 (print_mention_ranged_breakpoint): Likewise.
7110 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
7111 of is_mi_like_p.
7112
f3c6abab
TT
71132018-04-30 Tom Tromey <tom@tromey.com>
7114
7115 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
7116
40c03530
TT
71172018-04-30 Tom Tromey <tom@tromey.com>
7118
7119 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
7120 (info_spu_event_command): Remove some uses of is_mi_like_p.
7121
2038b7fd
TT
71222018-04-30 Tom Tromey <tom@tromey.com>
7123
7124 * python/py-framefilter.c (py_print_single_arg)
7125 (enumerate_locals, py_print_args, py_print_frame): Remove some
7126 uses of is_mi_like_p.
7127
4904c3c6
TT
71282018-04-30 Tom Tromey <tom@tromey.com>
7129
7130 * ui-out.c: Update.
7131 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
7132 * ui-out.h (ui_out::is_mi_like_p): Now const.
7133 (ui_out::do_is_mi_like_p): Now const.
7134 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
7135
7c66fffc
TT
71362018-04-30 Tom Tromey <tom@tromey.com>
7137
7138 * varobj.c (varobj_set_visualizer): Use new_reference.
7139 * python/python.c (gdbpy_decode_line): Use new_reference.
7140 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
7141 new_reference.
7142
bbfa6f00
TT
71432018-04-30 Tom Tromey <tom@tromey.com>
7144
7145 * varobj.c (install_new_value): Use new_reference.
7146 * value.h (value_incref): Return void. Swap intro comment with
7147 value_decref.
7148 * value.c (set_value_parent): Use new_reference.
7149 (value_incref): Return void. Update intro comment.
7150 (release_value): Use new_reference.
7151 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
7152
1831a9f9
TT
71532018-04-30 Tom Tromey <tom@tromey.com>
7154
7155 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
7156 * gdb_bfd.h (new_bfd_ref): Remove.
7157 (gdb_bfd_open): Update comment.
7158 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
7159 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
7160 (gdb_bfd_fdopenr): Use new_reference.
7161 * exec.c (exec_file_attach): Use new_reference.
7162
7c1b5f3d
TT
71632018-04-30 Tom Tromey <tom@tromey.com>
7164
7165 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
7166 method.
7167
e11fb955
TT
71682018-04-30 Tom Tromey <tom@tromey.com>
7169
7170 * jit.c (jit_read_code_entry): Use type_align.
7171 * i386-tdep.c (i386_gdbarch_init): Don't call
7172 set_gdbarch_long_long_align_bit.
7173 * gdbarch.sh: Remove long_long_align_bit.
7174 * gdbarch.c, gdbarch.h: Rebuild.
7175 * arc-tdep.c (arc_type_align): New function.
7176 (arc_gdbarch_init): Use arc_type_align. Don't call
7177 set_gdbarch_long_long_align_bit.
7178
2fff16dd
TT
71792018-04-30 Tom Tromey <tom@tromey.com>
7180
7181 * rust-lang.c (rust_type_alignment): Remove.
7182 (rust_composite_type): Use type_align.
7183
6d7bb824
TT
71842018-04-30 Tom Tromey <tom@tromey.com>
7185
7186 * NEWS: Mention Type.align.
7187 * python/py-type.c (typy_get_alignof): New function.
7188 (type_object_getset): Add "alignof".
7189
007e1530
TT
71902018-04-30 Tom Tromey <tom@tromey.com>
7191
7192 PR exp/17095:
7193 * NEWS: Update.
7194 * std-operator.def (UNOP_ALIGNOF): New operator.
7195 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
7196 New.
7197 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
7198 * c-lang.c (c_op_print_tab): Add alignof.
7199 * c-exp.y (ALIGNOF): New token.
7200 (exp): Add "ALIGNOF" production.
7201 (ident_tokens): Add _Alignof and alignof.
7202
2b4424c3
TT
72032018-04-30 Tom Tromey <tom@tromey.com>
7204
7205 * i386-tdep.c (i386_type_align): New function.
7206 (i386_gdbarch_init): Update.
7207 * gdbarch.sh (type_align): New method.
7208 * gdbarch.c, gdbarch.h: Rebuild.
7209 * arch-utils.h (default_type_align): Declare.
7210 * arch-utils.c (default_type_align): New function.
7211 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
7212 (struct type) <align_log2>: New field.
7213 <instance_flags>: Now a bitfield.
7214 (TYPE_RAW_ALIGN): New macro.
7215 (type_align, type_raw_align, set_type_align): Declare.
7216 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
7217 functions.
7218 * dwarf2read.c (quirk_rust_enum): Set type alignment.
7219 (get_alignment, maybe_set_alignment): New functions.
7220 (read_structure_type, read_enumeration_type, read_array_type)
7221 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
7222 (read_subrange_type, read_base_type): Set type alignment.
7223
d33bc52e
SM
72242018-04-30 Simon Marchi <simon.marchi@ericsson.com>
7225
7226 * dwarf2read.c (read_index_from_section): Use bool.
7227
e28b63a9
FG
72282018-04-29 Fabian Groffen <grobian@gentoo.org>
7229
7230 PR gdb/22950
7231 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
7232 with #ifdef.
7233
cd8c76e4
JR
72342018-04-29 John Reiser <jreiser@BitWagon.com>
7235
7236 PR build/22873
7237 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
7238 last step, and do it atomically.
7239
476d250e
AO
72402018-04-27 Alexandre Oliva <aoliva@redhat.com>
7241
7242 * compile/compile-c-types.c (convert_int, convert_float):
7243 Update for C FE v1.
7244
6873858b
TT
72452018-04-27 Tom Tromey <tom@tromey.com>
7246
7247 PR rust/22545:
7248 * rust-lang.c (rust_inclusive_range_type_p): New function.
7249 (rust_range): Handle inclusive ranges.
7250 (rust_compute_range): Likewise.
7251 * rust-exp.y (struct rust_op) <inclusive>: New field.
7252 (DOTDOTEQ): New constant.
7253 (range_expr): Add "..=" productions.
7254 (operator_tokens): Add "..=" token.
7255 (ast_range): Add "inclusive" parameter.
7256 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
7257 ranges.
7258 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
7259 bounds values.
7260 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
7261 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
7262 Update comments.
7263 * expprint.c (print_subexp_standard): Handle new bounds values.
7264 (dump_subexp_body_standard): Likewise.
7265
632e107b
TT
72662018-04-27 Tom Tromey <tom@tromey.com>
7267
7268 * configure: Rebuild.
7269 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
7270 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
7271 "OVERRIDE".
7272 (class symbol_needs_eval_context): Likewise.
7273 * dwarf2read.c (mock_mapped_index::symbol_name_count)
7274 (mock_mapped_index::symbol_name_at): Use "override". Remove
7275 "virtual".
7276 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
7277 "override".
7278 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
7279 * aarch64-tdep.c (instruction_reader::read): Use "override".
7280 (instruction_reader_test::read): Likewise.
7281 * arm-tdep.c (instruction_reader::read): Use "override".
7282 (instruction_reader_thumb::read): Likewise.
7283
b75abf5b
AK
72842018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
7285
7286 PR remote/9665
7287 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
7288 instead of remote_send.
7289 (remote_send): Remove.
7290
79188d8d
PA
72912018-04-26 Pedro Alves <palves@redhat.com>
7292
7293 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
7294 find_function_start_sal instead of find_pc_line.
7295
f50776aa
PA
72962018-04-26 Pedro Alves <palves@redhat.com>
7297
7298 * breakpoint.c (set_breakpoint_location_function): Handle
7299 mst_data_gnu_ifunc.
7300 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
7301 * elfread.c (elf_symtab_read): Give data symbols with
7302 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
7303 (elf_rel_plt_read): Update comment.
7304 * linespec.c (convert_linespec_to_sals): Handle
7305 mst_data_gnu_ifunc.
7306 (minsym_found): Handle mst_data_gnu_ifunc.
7307 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
7308 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
7309 * parse.c (find_minsym_type_and_address): Handle
7310 mst_data_gnu_ifunc.
7311 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
7312 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
7313 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
7314 comment.
7315 <mst_data_gnu_ifunc>: New enumerator.
7316
20944a6e
PA
73172018-04-26 Pedro Alves <palves@redhat.com>
7318
7319 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
7320 (lookup_minimal_symbol_by_pc_section): ... this. Replace
7321 'want_trampoline' parameter by a lookup_msym_prefer parameter.
7322 Handle it.
7323 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
7324 (lookup_minimal_symbol_by_pc): Adjust.
7325 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
7326 (lookup_solib_trampoline_symbol_by_pc): Adjust.
7327 * minsyms.h (lookup_msym_prefer): New enum.
7328 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
7329 parameter by a lookup_msym_prefer parameter.
7330
1adeb822
PA
73312018-04-26 Pedro Alves <palves@redhat.com>
7332
7333 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
7334 ends in "@plt" instead of looking at the symbol's section.
7335
a0aca7b0
PA
73362018-04-26 Pedro Alves <palves@redhat.com>
7337
7338 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
7339 all references.
7340 (find_pc_partial_function_gnu_ifunc): Rename to ...
7341 (find_pc_partial_function): ... this, and remove references to
7342 'is_gnu_ifunc_p'.
7343 (find_pc_partial_function): Delete old implementation.
7344 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
7345
76af0f26
PA
73462018-04-26 Pedro Alves <palves@redhat.com>
7347
7348 * linespec.c (struct bound_minimal_symbol_search_key): New.
7349 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
7350 skip first line if we found a GNU ifunc minimal symbol by name.
7351 (compare_msymbols): Change parameters to work with a destructured
7352 lhs minsym.
7353 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
7354 functions.
7355
3467ec66
PA
73562018-04-26 Pedro Alves <palves@redhat.com>
7357
7358 * breakpoint.c (set_breakpoint_location_function): Don't resolve
7359 ifunc targets here. Instead, if we have an ifunc minsym, use its
7360 address/name.
7361 (add_location_to_breakpoint): Store the minsym and the objfile in
7362 the breakpoint location.
7363 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
7364 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
7365 Record the minsym in the sal.
7366 * symtab.h (symtab_and_line) <msymbol>: New field.
7367
28f4fa4d
PA
73682018-04-26 Pedro Alves <palves@redhat.com>
7369
7370 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
7371 unless we actually resolved the ifunc.
7372
ca31ab1d
PA
73732018-04-26 Pedro Alves <palves@redhat.com>
7374
7375 * c-exp.y (variable production): Prefer ifunc minsyms over
7376 regular function symbols.
7377 * symtab.c (find_gnu_ifunc): New function.
7378 * minsyms.h (lookup_msym_prefer): New enum.
7379 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
7380 parameter by a lookup_msym_prefer parameter.
7381 * symtab.h (find_gnu_ifunc): New declaration.
7382
8388016d
PA
73832018-04-26 Pedro Alves <palves@redhat.com>
7384
7385 * blockframe.c (find_gnu_ifunc_target_type): New function.
7386 (find_function_type): New.
7387 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
7388 return a value with a memory address.
7389 (eval_call): For calls to GNU ifunc functions, try to find the
7390 type of the target function from the type that the resolver
7391 returns.
7392 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
7393 symbols.
7394 * infcall.c (find_function_return_type): Delete.
7395 (find_function_addr): Add 'function_type' parameter. For calls to
7396 GNU ifunc functions, try to find the type of the target function
7397 from the type that the resolver returns, and return it via
7398 FUNCTION_TYPE.
7399 (call_function_by_hand_dummy): Adjust to use the function type
7400 returned by find_function_addr.
7401 (find_function_addr): Add 'function_type' parameter and move
7402 description here.
7403 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
7404 declarations.
7405
a376e11d
PA
74062018-04-26 Pedro Alves <palves@redhat.com>
7407
7408 * c-exp.y (variable production): Skip finding an alias for ifunc
7409 symbols.
7410
02e169e2
PA
74112018-04-26 Pedro Alves <palves@redhat.com>
7412
7413 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
7414
249b5733
PA
74152018-04-25 Pedro Alves <palves@redhat.com>
7416
7417 * infcmd.c (kill_command): Print the pid as string, not the whole
7418 thread's ptid. Add comment. s/has been killed/killed/ in output
7419 message.
7420 * remote.c (remote_detach_1): Print the pid as string, not the
7421 whole thread's ptid.
7422
f67c0c91
SDJ
74232018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7424 Sergio Durigan Junior <sergiodj@redhat.com>
7425 Pedro Alves <palves@redhat.com>
7426
7427 * infcmd.c (kill_command): Print message when inferior has
7428 been killed.
7429 * inferior.c (print_inferior_events): Remove 'static'. Set as
7430 '1'.
7431 (add_inferior): Improve message printed when
7432 'print_inferior_events' is on.
7433 (exit_inferior): Remove message printed when
7434 'print_inferior_events' is on.
7435 (detach_inferior): Improve message printed when
7436 'print_inferior_events' is on.
7437 (initialize_inferiors): Use 'add_inferior_silent' to set
7438 'current_inferior_'.
7439 * inferior.h (print_inferior_events): Declare here as
7440 'extern'.
7441 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
7442 '[Detaching...]' messages when 'print_inferior_events' is on.
7443 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
7444 as prefix/suffix for messages. Remove periods. Fix erroneous
7445 'Detaching after fork from child...', replace it by '... from
7446 parent...'.
7447 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
7448 prefix/suffix when printing 'Detaching...' messages. Print
7449 them when 'print_inferior_events' is on.
7450 * remote.c (remote_detach_1): Print message when detaching
7451 from inferior and '!is_fork_parent'.
7452
e427af18
TT
74532018-04-24 Tom Tromey <tom@tromey.com>
7454
7455 * cli-out.h: Reindent.
7456
05b1d8d6
TT
74572018-04-24 Tom Tromey <tom@tromey.com>
7458
7459 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
7460 (cli_ui_out::do_field_string): Use fputs_filtered.
7461 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
7462
a95c7dab
TT
74632018-04-23 Tom Tromey <tom@tromey.com>
7464
7465 * guile/scm-frame.c (gdbscm_frame_read_var): Use
7466 gdb::unique_xmalloc_ptr.
7467
458412c3
TT
74682018-04-23 Tom Tromey <tom@tromey.com>
7469
7470 * configure: Rebuild.
7471
db86b02b
RS
74722018-04-22 Rajendra SY <rajendra.sy@gmail.com>
7473
7474 PR gdb/23095
7475 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
7476 prepare_for_testing. Set normal_bp to r_debug_state if target
7477 is bsd.
7478
00aecdcf
PA
74792018-04-21 Pedro Alves <palves@redhat.com>
7480 Rajendra SY <rajendra.sy@gmail.com>
7481
7482 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
7483 * remote.c (extended_remote_attach): In all-stop mode, mark the
7484 thread as executing.
7485
224608c3
PW
74862018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7487
7488 * thread.c (thread_apply_all_command): Fix comment.
7489 (thread_command): Fix comment.
7490
3b74854b
AH
74912018-04-10 Alan Hayward <alan.hayward@arm.com>
7492
7493 * common/tdesc.h (tdesc_create_feature): Remove xml filename
7494 parameter.
7495 * features/aarch64-core.c (create_feature_aarch64_core):
7496 Regenerate.
7497 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
7498 Likewise.
7499 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
7500 Likewise.
7501 * features/i386/32bit-avx512.c
7502 (create_feature_i386_32bit_avx512): Likewise.
7503 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
7504 Likewise.
7505 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
7506 Likewise.
7507 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
7508 Likewise.
7509 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
7510 Likewise.
7511 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
7512 Likewise.
7513 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
7514 Likewise.
7515 * features/i386/64bit-avx512.c
7516 (create_feature_i386_64bit_avx512): Likewise.
7517 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
7518 Likewise.
7519 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
7520 Likewise.
7521 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
7522 Likewise.
7523 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
7524 Likewise.
7525 * features/i386/64bit-segments.c
7526 (create_feature_i386_64bit_segments): Likewise.
7527 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
7528 Likewise.
7529 * features/i386/x32-core.c
7530 (create_feature_i386_x32_core): Likewise.
7531 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
7532 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
7533 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
7534 * target-descriptions.c: In generated code, don't pass xml
7535 filename.
7536
e98577a9
AH
75372018-04-18 Alan Hayward <alan.hayward@arm.com>
7538
7539 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
7540 (print_xml_feature::visit_post): Likewise.
7541 (print_xml_feature::visit): Likewise.
7542 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
7543 (print_xml_feature): Add new class.
7544 * regformats/regdat.sh: Null xmltarget on feature targets.
7545 * target-descriptions.c (struct target_desc): Add xmltarget.
7546 (maintenance_check_tdesc_xml_convert): Add unittest function.
7547 (tdesc_get_features_xml): Add function to get xml.
7548 (maintenance_check_xml_descriptions): Test xml generation.
7549 * xml-tdesc.c (string_read_description_xml): Add function.
7550 * xml-tdesc.h (string_read_description_xml): Add declaration.
7551
ad7fc756
AH
75522018-04-18 Alan Hayward <alan.hayward@arm.com>
7553
7554 * features/Makefile: Add feature marker to targets with new style
7555 target descriptions.
7556 * regformats/aarch64.dat: Regenerate.
7557 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
7558 * regformats/i386/amd64-avx-linux.dat: Likewise.
7559 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
7560 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
7561 * regformats/i386/amd64-linux.dat: Likewise.
7562 * regformats/i386/amd64-mpx-linux.dat: Likewise.
7563 * regformats/i386/amd64.dat: Likewise.
7564 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
7565 * regformats/i386/i386-avx-linux.dat: Likewise.
7566 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
7567 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
7568 * regformats/i386/i386-linux.dat: Likewise.
7569 * regformats/i386/i386-mmx-linux.dat: Likewise.
7570 * regformats/i386/i386-mpx-linux.dat: Likewise.
7571 * regformats/i386/i386.dat: Likewise.
7572 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
7573 * regformats/i386/x32-avx-linux.dat: Likewise.
7574 * regformats/i386/x32-linux.dat: Likewise.
7575 * regformats/tic6x-c62x-linux.dat: Likewise.
7576 * regformats/tic6x-c64x-linux.dat: Likewise.
7577 * regformats/tic6x-c64xp-linux.dat: Likewise.
7578 * regformats/regdat.sh: Parse feature marker.
7579
d278f585
AH
75802018-04-18 Alan Hayward <alan.hayward@arm.com>
7581
7582 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
7583 (tdesc_osabi_name): Likewise.
7584 * target-descriptions.c (tdesc_architecture_name): Add new
7585 function.
7586 (tdesc_osabi_name): Likewise.
7587
eee8a18d
AH
75882018-04-18 Alan Hayward <alan.hayward@arm.com>
7589
7590 * common/tdesc.c (tdesc_predefined_type): Move to here.
7591 (tdesc_named_type): Likewise.
7592 (tdesc_create_vector): Likewise.
7593 (tdesc_create_struct): Likewise.
7594 (tdesc_set_struct_size): Likewise.
7595 (tdesc_create_union): Likewise.
7596 (tdesc_create_flags): Likewise.
7597 (tdesc_create_enum): Likewise.
7598 (tdesc_add_field): Likewise.
7599 (tdesc_add_typed_bitfield): Likewise.
7600 (tdesc_add_bitfield): Likewise.
7601 (tdesc_add_flag): Likewise.
7602 (tdesc_add_enum_value): Likewise.
7603 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
7604 (struct tdesc_type_vector): Likewise.
7605 (struct tdesc_type_field): Likewise.
7606 (struct tdesc_type_with_fields): Likewise.
7607 (tdesc_create_enum): Add declaration.
7608 (tdesc_add_typed_bitfield): Likewise.
7609 (tdesc_add_enum_value): Likewise.
7610 * target-descriptions.c (tdesc_type_field): Move from here.
7611 (tdesc_type_builtin): Likewise.
7612 (tdesc_type_vector): Likewise.
7613 (tdesc_type_with_fields): Likewise.
7614 (tdesc_predefined_types): Likewise.
7615 (tdesc_named_type): Likewise.
7616 (tdesc_create_vector): Likewise.
7617 (tdesc_create_struct): Likewise.
7618 (tdesc_set_struct_size): Likewise.
7619 (tdesc_create_union): Likewise.
7620 (tdesc_create_flags): Likewise.
7621 (tdesc_create_enum): Likewise.
7622 (tdesc_add_field): Likewise.
7623 (tdesc_add_typed_bitfield): Likewise.
7624 (tdesc_add_bitfield): Likewise.
7625 (tdesc_add_flag): Likewise.
7626 (tdesc_add_enum_value): Likewise.
7627 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
7628 (tdesc_add_typed_bitfield): Likewise.
7629 (tdesc_add_enum_value): Likewise.
7630
82ec9bc7
AH
76312018-04-18 Alan Hayward <alan.hayward@arm.com>
7632
7633 * common/tdesc.c (tdesc_feature::accept): Move to here.
7634 (tdesc_feature::operator==): Likewise.
7635 (tdesc_create_reg): Likewise.
7636 * common/tdesc.h (tdesc_type_kind): Likewise.
7637 (struct tdesc_type): Likewise.
7638 (struct tdesc_feature): Likewise.
7639 * regformats/regdat.sh: Create a feature.
7640 * target-descriptions.c (tdesc_type_kind): Move from here.
7641 (tdesc_type): Likewise.
7642 (tdesc_type_up): Likewise.
7643 (tdesc_feature): Likewise.
7644 (tdesc_create_reg): Likewise.
7645
ea3e7d71
AH
76462018-04-18 Alan Hayward <alan.hayward@arm.com>
7647
7648 * Makefile.in: Add arch/tdesc.c
7649 * common/tdesc.c: New file.
7650 * common/tdesc.h (tdesc_element_visitor): Move to here.
7651 (tdesc_element): Likewise.
7652 (tdesc_reg): Likewise.
7653 (tdesc_reg_up): Likewise.
7654 * regformats/regdef.h (reg): Add offset to constructors.
7655 * target-descriptions.c (tdesc_element_visitor): Move from here.
7656 (tdesc_element): Likewise.
7657 (tdesc_reg): Likewise.
7658 (tdesc_reg_up): Likewise.
7659
bedda9ac
TT
76602018-04-17 Tom Tromey <tom@tromey.com>
7661
7662 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
7663 discriminant field.
7664
a037790e
TT
76652018-04-17 Tom Tromey <tom@tromey.com>
7666
7667 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
7668
c7dcbf88
AA
76692018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
7670
7671 * symtab.c (print_symbol_info): Skip printing filename and line
7672 number when `last' is NULL.
7673 (symtab_symbol_info): Use empty string instead of NULL for first
7674 invocation of print_symbol_info.
7675 (rbreak_command): Pass NULL to `last' parameter of
7676 print_symbol_info.
7677
07d28c77
SM
76782018-04-16 Simon Marchi <simon.marchi@ericsson.com>
7679
7680 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
7681 instead of nullptr.
7682
8a3de5e1
PA
76832018-04-16 Pedro Alves <palves@redhat.com>
7684
7685 * MAINTAINERS (sh): Remove.
7686 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
7687 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
7688 (ALLDEPFILES): Remove sh64-tdep.c.
7689 * NEWS: Mentions that support for SH-5/SH64 is removed.
7690 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
7691 (sh*-*-openbsd*): Ditto.
7692 (sh64-*-elf*): Remove.
7693 (sh*): Remove.
7694 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
7695 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
7696 * sh-tdep.c: No longer include "sh64-tdep.h".
7697 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
7698 * sh64-tdep.c, sh64-tdep.h: Remove files.
7699
a2a79012
PA
77002018-04-16 Pedro Alves <palves@redhat.com>
7701
7702 * MAINTAINERS: Remove m88k.
7703 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
7704 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
7705 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
7706 * NEWS: Mention that support for m88k was removed.
7707 * configure.host (m88*-*-*): Remove support.
7708 * configure.nat (m88k-*-*): Remove support.
7709 * configure.tgt (m88*-*-openbsd*): Remove.
7710 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
7711
eda4efb1
SM
77122018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
7713
7714 * configure.tgt (x86_tobjs): New variable.
7715 (amd64_tobjs, i386_tobjs): Use it.
7716
b744723f
AA
77172018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7718
7719 * symtab.c (print_symbol_info): Precede the symbol definition by
7720 the line number when available.
7721 * NEWS: Advertise this enhancement.
7722
4a4495d6
MM
77232018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7724
7725 * NEWS (New options): announce set/show record btrace cpu.
7726 * btrace.c: Include record-btrace.h.
7727 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
7728 the vendor is unknown.
7729 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
7730 Maybe overwrite the btrace configuration's cpu.
7731 (btrace_compute_ftrace): Add cpu parameter. Update callers.
7732 (btrace_fetch): Add cpu parameter. Update callers.
7733 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
7734 Maybe overwrite the btrace configuration's cpu. Skip enabling
7735 errata workarounds if the vendor is unknown.
7736 * python/py-record-btrace.c: Include record-btrace.h.
7737 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
7738 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
7739 * record-btrace.c (record_btrace_cpu_state_kind): New.
7740 (record_btrace_cpu): New.
7741 (set_record_btrace_cpu_cmdlist): New.
7742 (record_btrace_get_cpu): New.
7743 (require_btrace_thread, record_btrace_info)
7744 (record_btrace_resume_thread): Call record_btrace_get_cpu.
7745 (cmd_set_record_btrace_cpu_none): New.
7746 (cmd_set_record_btrace_cpu_auto): New.
7747 (cmd_set_record_btrace_cpu): New.
7748 (cmd_show_record_btrace_cpu): New.
7749 (_initialize_record_btrace): Initialize set/show record btrace cpu
7750 commands.
7751 * record-btrace.h (record_btrace_get_cpu): New.
7752
69f90c75
MM
77532018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7754
7755 * record.c (set_record_command): Fix typo in message.
7756
b85310e1
MM
77572018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7758
7759 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
7760
1d509aa6
MM
77612018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7762
7763 * infrun.c (process_event_stop_test): Call
7764 gdbarch_in_indirect_branch_thunk.
7765 * gdbarch.sh (in_indirect_branch_thunk): New.
7766 * gdbarch.c: Regenerated.
7767 * gdbarch.h: Regenerated.
7768 * x86-tdep.h: New.
7769 * x86-tdep.c: New.
7770 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
7771 (HFILES_NO_SRCDIR): Add x86-tdep.h.
7772 (ALLDEPFILES): Add x86-tdep.c.
7773 * arch-utils.h (default_in_indirect_branch_thunk): New.
7774 * arch-utils.c (default_in_indirect_branch_thunk): New.
7775 * i386-tdep: Include x86-tdep.h.
7776 (i386_in_indirect_branch_thunk): New.
7777 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
7778 function.
7779 * amd64-tdep: Include x86-tdep.h.
7780 (amd64_in_indirect_branch_thunk): New.
7781 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
7782
b4be9bfd
JK
77832018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
7784
7785 PR gdb/23053
7786 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
7787 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
7788 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
7789 regression.
7790
53d7df28
TT
77912018-04-12 Tom Tromey <tom@tromey.com>
7792
7793 * rust-lang.c (rust_print_struct_def): Remove univariant code.
7794 (rust_evaluate_subexp): Likewise.
7795
70b33f19
PA
77962018-04-12 Pedro Alves <palves@redhat.com>
7797
7798 * procfs.c (procfs_detach): Make forward declaration's prototype
7799 match definition's protototype.
7800 (proc_get_LDT_entry): Remove stale do_cleanups call.
7801
436411b1
PA
78022018-04-12 Pedro Alves <palves@redhat.com>
7803
7804 * target.h (target_ops::to_has_exited): Delete.
7805 (target_has_exited): Delete.
7806 * target-delegates.c: Regenerate.
7807
20db9c52
PA
78082018-04-11 Pedro Alves <palves@redhat.com>
7809
7810 * target.c (fileio_fh_t::t): Add comment.
7811 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7812 (target_fileio_close): Handle a NULL target.
7813 (invalidate_fileio_fh): New.
7814 (target_close): Call it.
7815 * remote.c (remote_hostio_send_command): No longer check whether
7816 remote_desc is open.
7817
5ff79300
PA
78182018-04-11 Pedro Alves <palves@redhat.com>
7819
7820 * target.c (fileio_fh_t): Make it a named struct instead of a
7821 typedef.
7822 (fileio_fh_t::is_closed): New method.
7823 (DEF_VEC_O (fileio_fh_t)): Remove.
7824 (fileio_fhandles): Now a std::vector.
7825 (is_closed_fileio_fh): Delete.
7826 (acquire_fileio_fd): Adjust. Rename parameters.
7827 (release_fileio_fd): Adjust.
7828 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
7829 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7830 (target_fileio_close): Adjust.
7831
6e22e10d
SM
78322018-04-10 Simon Marchi <simon.marchi@ericsson.com>
7833
7834 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
7835 index.
7836
731f534f
PA
78372018-04-10 Pedro Alves <palves@redhat.com>
7838
7839 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
7840 (scoped_finish_thread_state): New class.
7841 * infcmd.c (run_command_1): Use it instead of finish_thread_state
7842 cleanup.
7843 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
7844 (fetch_inferior_event, normal_stop): Likewise.
7845 * thread.c (finish_thread_state_cleanup): Delete.
7846
d5f4488f
SM
78472018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7848 Pedro Alves <palves@redhat.com>
7849
7850 * value.c: Include "selftest.h" and "common/array-view.h".
7851 (struct range) <operator ==>: New.
7852 (test_ranges_contain): New.
7853 (check_ranges_vector): New.
7854 (test_insert_into_bit_range_vector): New.
7855 (_initialize_values): Register selftests.
7856 * common/array-view.h (operator==, operator!=): New.
7857
b24531ed
SM
78582018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7859
7860 * common/gdb_vecs.h (unordered_remove): Add overload that takes
7861 an iterator.
7862 * inline-frame.c: Include <algorithm>.
7863 (struct inline_state): Add constructor.
7864 (inline_state_s): Remove.
7865 (DEF_VEC_O(inline_state_s)): Remove.
7866 (inline_states): Change type to std::vector.
7867 (find_inline_frame_state): Adjust to std::vector.
7868 (allocate_inline_frame_state): Remove.
7869 (clear_inline_frame_state): Adjust to std::vector.
7870 (skip_inline_frames): Adjust to std::vector.
7871
c252925c
SM
78722018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7873
7874 * tracepoint.h (struct trace_state_variable): Add constructor.
7875 <name>: Change type to std::string.
7876 * tracepoint.c (tsv_s): Remove.
7877 (DEF_VEC_O(tsv_s)): Remove.
7878 (tvariables): Change to std::vector.
7879 (create_trace_state_variable): Adjust to std::vector.
7880 (find_trace_state_variable): Likewise.
7881 (find_trace_state_variable_by_number): Likewise.
7882 (delete_trace_state_variable): Likewise.
7883 (trace_variable_command): Adjust to std::string.
7884 (delete_trace_variable_command): Likewise.
7885 (tvariables_info_1): Adjust to std::vector.
7886 (save_trace_state_variables): Likewise.
7887 (start_tracing): Likewise.
7888 (merge_uploaded_trace_state_variables): Adjust to std::vector
7889 and std::string.
7890 * target.h (struct target_ops)
7891 <to_download_trace_state_variable>: Pass reference to
7892 trace_state_variable.
7893 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
7894 * target-delegates.c: Re-generate.
7895 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
7896 (mi_tsv_deleted): Likewise.
7897 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
7898 * remote.c (remote_download_trace_state_variable): Change
7899 pointer to reference and adjust.
7900 * make-target-delegates (parse_argtypes): Handle references.
7901 (write_function_header): Likewise.
7902 (munge_type): Likewise.
7903
c9638d26
SM
79042018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7905
7906 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7907 string_view-selftests.c.
7908 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
7909 testsuite.
7910 * unittests/basic_string_view/cons/char/1.cc: Likewise.
7911 * unittests/basic_string_view/cons/char/2.cc: Likewise.
7912 * unittests/basic_string_view/cons/char/3.cc: Likewise.
7913 * unittests/basic_string_view/element_access/char/1.cc:
7914 Likewise.
7915 * unittests/basic_string_view/element_access/char/empty.cc:
7916 Likewise.
7917 * unittests/basic_string_view/element_access/char/front_back.cc:
7918 Likewise.
7919 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
7920 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
7921 Likewise.
7922 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
7923 Likewise.
7924 * unittests/basic_string_view/modifiers/swap/char/1.cc:
7925 Likewise.
7926 * unittests/basic_string_view/operations/compare/char/1.cc:
7927 Likewise.
7928 * unittests/basic_string_view/operations/compare/char/13650.cc:
7929 Likewise.
7930 * unittests/basic_string_view/operations/copy/char/1.cc:
7931 Likewise.
7932 * unittests/basic_string_view/operations/data/char/1.cc:
7933 Likewise.
7934 * unittests/basic_string_view/operations/find/char/1.cc:
7935 Likewise.
7936 * unittests/basic_string_view/operations/find/char/2.cc:
7937 Likewise.
7938 * unittests/basic_string_view/operations/find/char/3.cc:
7939 Likewise.
7940 * unittests/basic_string_view/operations/find/char/4.cc:
7941 Likewise.
7942 * unittests/basic_string_view/operations/rfind/char/1.cc:
7943 Likewise.
7944 * unittests/basic_string_view/operations/rfind/char/2.cc:
7945 Likewise.
7946 * unittests/basic_string_view/operations/rfind/char/3.cc:
7947 Likewise.
7948 * unittests/basic_string_view/operations/substr/char/1.cc:
7949 Likewise.
7950 * unittests/basic_string_view/operators/char/2.cc: Likewise.
7951 * unittests/string_view-selftests.c: New file.
7952
fdc11678
SM
79532018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7954
7955 * unittests/basic_string_view/capacity/1.cc: New file.
7956 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
7957 * unittests/basic_string_view/cons/char/1.cc: New file.
7958 * unittests/basic_string_view/cons/char/2.cc: New file.
7959 * unittests/basic_string_view/cons/char/3.cc: New file.
7960 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
7961 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
7962 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
7963 * unittests/basic_string_view/element_access/char/1.cc: New file.
7964 * unittests/basic_string_view/element_access/char/2.cc: New file.
7965 * unittests/basic_string_view/element_access/char/empty.cc: New file.
7966 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
7967 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
7968 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
7969 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
7970 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
7971 * unittests/basic_string_view/include.cc: New file.
7972 * unittests/basic_string_view/inserters/char/1.cc: New file.
7973 * unittests/basic_string_view/inserters/char/2.cc: New file.
7974 * unittests/basic_string_view/inserters/char/3.cc: New file.
7975 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
7976 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
7977 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
7978 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
7979 * unittests/basic_string_view/literals/types.cc: New file.
7980 * unittests/basic_string_view/literals/values.cc: New file.
7981 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
7982 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
7983 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
7984 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
7985 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
7986 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
7987 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
7988 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
7989 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
7990 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
7991 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
7992 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
7993 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
7994 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
7995 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
7996 * unittests/basic_string_view/operations/data/char/1.cc: New file.
7997 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
7998 * unittests/basic_string_view/operations/find/char/1.cc: New file.
7999 * unittests/basic_string_view/operations/find/char/2.cc: New file.
8000 * unittests/basic_string_view/operations/find/char/3.cc: New file.
8001 * unittests/basic_string_view/operations/find/char/4.cc: New file.
8002 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
8003 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
8004 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
8005 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
8006 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
8007 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
8008 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
8009 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
8010 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
8011 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
8012 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
8013 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
8014 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
8015 * unittests/basic_string_view/operators/char/2.cc: New file.
8016 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
8017 * unittests/basic_string_view/range_access/char/1.cc: New file.
8018 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
8019 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
8020 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
8021 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
8022 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
8023 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
8024 * unittests/basic_string_view/requirements/typedefs.cc: New file.
8025 * unittests/basic_string_view/typedefs.cc: New file.
8026 * unittests/basic_string_view/types/1.cc: New file.
8027
8345c4a2
SM
80282018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8029
8030 * common/gdb_string_view.h: Remove libstdc++ implementation
8031 details, adjust to gdb reality.
8032 * common/gdb_string_view.tcc: Likewise.
8033 * cli/cli-script.c (struct string_view): Remove.
8034 (user_args) <m_args>: Change element type to gdb::string_view.
8035 (user_args::insert_args): Adjust.
8036
7adcdf08
SM
80372018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8038
8039 * common/gdb_string_view.h: New file.
8040 * common/gdb_string_view.tcc: New file.
8041
41260ac2
SM
80422018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8043
8044 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
8045 * configure: Re-generate.
8046
0bee6dd4
PA
80472018-04-09 Pedro Alves <palves@redhat.com>
8048
8049 * gdbarch.sh: Include "observable.h" instead of "observer.h".
8050 (set_target_gdbarch): Call
8051 gdb::observers::architecture_changed.notify instead of
8052 observer_notify_architecture_changed.
8053
6f14adc5
SM
80542018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8055
8056 * tracepoint.c (struct current_traceframe_cleanup): Remove.
8057 (do_restore_current_traceframe_cleanup): Remove.
8058 (restore_current_traceframe_cleanup_dtor): Remove.
8059 (make_cleanup_restore_current_traceframe): Remove.
8060 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
8061 New.
8062 * tracepoint.h (struct scoped_restore_current_traceframe): New.
8063 * infrun.c (fetch_inferior_event): Use
8064 scoped_restore_current_traceframe.
8065
b2bdb8cf
SM
80662018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8067
8068 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
8069 Remove.
8070 <n_allocated_type_units>: Remove.
8071 <all_type_units>: Change to std::vector.
8072 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
8073 to std::vector change.
8074 (dwarf2_per_objfile::get_cutu): Likewise.
8075 (dwarf2_per_objfile::get_tu): Likewise.
8076 (create_signatured_type_table_from_index): Likewise.
8077 (create_signatured_type_table_from_debug_names): Likewise.
8078 (dw2_symtab_iter_next): Likewise.
8079 (dw2_print_stats): Likewise.
8080 (dw2_expand_all_symtabs): Likewise.
8081 (dw2_expand_marked_cus): Likewise.
8082 (dw2_debug_names_iterator::next): Likewise.
8083 (dwarf2_initialize_objfile): Likewise.
8084 (add_signatured_type_cu_to_table): Likewise.
8085 (create_all_type_units): Likewise.
8086 (add_type_unit): Likewise.
8087 (struct tu_abbrev_offset): Add constructor.
8088 (build_type_psymtabs_1): Adjust to std::vector change.
8089 (print_tu_stats): Likewise.
8090 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
8091 (write_debug_names): Likewise.
8092
b76e467d
SM
80932018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8094
8095 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
8096 Make an std::vector.
8097 <n_comp_units>: Remove.
8098 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
8099 to std::vector change.
8100 (dwarf2_per_objfile::get_cutu): Likewise.
8101 (dwarf2_per_objfile::get_cu): Likewise.
8102 (create_cus_from_index): Likewise.
8103 (create_addrmap_from_index): Likewise.
8104 (create_addrmap_from_aranges): Likewise.
8105 (dwarf2_read_index): Likewise.
8106 (dw2_find_last_source_symtab): Likewise.
8107 (dw2_map_symtabs_matching_filename): Likewise.
8108 (dw2_symtab_iter_next): Likewise.
8109 (dw2_print_stats): Likewise.
8110 (dw2_expand_all_symtabs): Likewise.
8111 (dw2_expand_symtabs_with_fullname): Likewise.
8112 (dw2_expand_marked_cus): Likewise.
8113 (dw2_map_symbol_filenames): Likewise.
8114 (create_cus_from_debug_names): Likewise.
8115 (dwarf2_read_debug_names): Likewise.
8116 (dw2_debug_names_iterator::next): Likewise.
8117 (dwarf2_initialize_objfile): Likewise.
8118 (set_partial_user): Likewise.
8119 (dwarf2_build_psymtabs_hard): Likewise.
8120 (read_comp_units_from_section): Remove arguments, adjust to
8121 std::vector change.
8122 (create_all_comp_units): Adjust to std::vector and
8123 read_comp_units_from_section changes.
8124 (dwarf2_find_containing_comp_unit): Adjust to std::vector
8125 change.
8126 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
8127 (psyms_seen_size): Likewise.
8128 (write_gdbindex): Likewise.
8129 (write_debug_names): Likewise.
8130
12359b5e
SM
81312018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8132
8133 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
8134 with dwarf2_per_objfile.
8135 (create_cus_from_index): Likewise.
8136 (create_signatured_type_table_from_index): Likewise.
8137 (dwarf2_read_index): Likewise.
8138 (dwarf2_initialize_objfile): Likewise.
8139 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
8140 per_cu rather than get_dwarf2_per_objfile.
8141
ff4c9fec
SM
81422018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8143
8144 * dwarf2read.h (struct signatured_type): Forward declare.
8145 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
8146 New methods.
8147 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
8148 (dw2_get_cutu): ...this.
8149 (dwarf2_per_objfile::get_cu): Rename from...
8150 (dw2_get_cu): ...this.
8151 (dwarf2_per_objfile::get_tu): New.
8152 (create_addrmap_from_index): Adjust.
8153 (create_addrmap_from_aranges): Adjust.
8154 (dw2_find_last_source_symtab): Adjust.
8155 (dw2_map_symtabs_matching_filename): Adjust.
8156 (dw2_symtab_iter_next): Adjust.
8157 (dw2_print_stats): Adjust.
8158 (dw2_expand_all_symtabs): Adjust.
8159 (dw2_expand_symtabs_with_fullname): Adjust.
8160 (dw2_expand_marked_cus): Adjust.
8161 (dw_expand_symtabs_matching_file_matcher): Adjust.
8162 (dw2_map_symbol_filenames): Adjust.
8163 (dw2_debug_names_iterator::next): Adjust.
8164 (dwarf2_initialize_objfile): Adjust.
8165 (set_partial_user): Adjust.
8166 (dwarf2_build_psymtabs_hard): Adjust.
8167
5ca3fcb6
SM
81682018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8169
8170 * dwarf2read.c (create_signatured_type_table_from_debug_names):
8171 Remove unused variables.
8172 (dw2_map_symtabs_matching_filename): Likewise.
8173 (dwarf2_record_block_ranges): Likewise.
8174 (dwarf2_read_addr_index): Likewise.
8175 (follow_die_offset): Likewise.
8176
b2e586e8
SM
81772018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8178
8179 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
8180 to symbol_file_add_main.
8181
7c4e78cf
SM
81822018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8183
8184 PR mi/22299
8185 * mi/mi-console.c (do_fputc_async_safe): New.
8186 (mi_console_file::write_async_safe): New.
8187 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
8188 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
8189 New.
8190 * ui-file.c (ui_file::putstrn): Adjust call to
8191 fputstrn_unfiltered.
8192 * utils.c (printchar): Replace do_fputs and do_fprintf
8193 parameters by do_fputc.
8194 (fputstr_filtered): Adjust call to printchar.
8195 (fputstr_unfiltered): Likewise.
8196 (fputstrn_filtered): Likewise.
8197 (fputstrn_unfiltered): Add do_fputc parameter, pass to
8198 printchar.
8199 * utils.h (do_fputc_ftype): New typedef.
8200 (fputstrn_unfiltered): Add do_fputc parameter.
8201
5dc026d3
SM
82022018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8203
8204 * regformats/i386/i386-avx.dat: Remove.
8205
c912f608
SM
82062018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8207
8208 PR gdb/22979
8209 * amd64-tdep.c (amd64_none_init_abi): New function.
8210 (amd64_x32_none_init_abi): New function.
8211 (_initialize_amd64_tdep): Register handlers for x86-64 and
8212 x64_32 with GDB_OSABI_NONE.
8213 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
8214 GDB_OSABI_NONE osabi.
8215
26540402
SM
82162018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8217
8218 PR gdb/22980
8219 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
8220 GDB_OSABI_NONE.
8221 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
8222 * osabi.c (gdb_osabi_names): Add "unknown" entry.
8223
9018be22
SM
82242018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8225
8226 * common/byte-vector.h (char_vector): New type.
8227 * target.h (target_read_alloc): Return
8228 gdb::optional<byte_vector>.
8229 (target_read_stralloc): Return gdb::optional<char_vector>.
8230 (target_get_osdata): Return gdb::optional<char_vector>.
8231 * target.c (target_read_alloc_1): Templatize. Replacement
8232 manual memory management with vector.
8233 (target_read_alloc): Change return type, adjust.
8234 (target_read_stralloc): Change return type, adjust.
8235 (target_get_osdata): Change return type, adjust.
8236 * auxv.c (struct auxv_info) <length>: Remove.
8237 <data>: Change type to gdb::optional<byte_vector>.
8238 (auxv_inferior_data_cleanup): Free auxv_info with delete.
8239 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
8240 (target_auxv_search): Adjust.
8241 (fprint_target_auxv): Adjust.
8242 * avr-tdep.c (avr_io_reg_read_command): Adjust.
8243 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
8244 (linux_make_corefile_notes): Adjust.
8245 * osdata.c (get_osdata): Adjust.
8246 * remote.c (remote_get_threads_with_qxfer): Adjust.
8247 (remote_memory_map): Adjust.
8248 (remote_traceframe_info): Adjust.
8249 (btrace_read_config): Adjust.
8250 (remote_read_btrace): Adjust.
8251 (remote_pid_to_exec_file): Adjust.
8252 * solib-aix.c (solib_aix_get_library_list): Adjust.
8253 * solib-dsbt.c (decode_loadmap): Don't free buf.
8254 (dsbt_get_initial_loadmaps): Adjust.
8255 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
8256 * solib-target.c (solib_target_current_sos): Adjust.
8257 * tracepoint.c (sdata_make_value): Adjust.
8258 * xml-support.c (xinclude_start_include): Adjust.
8259 (xml_fetch_content_from_file): Adjust.
8260 * xml-support.h (xml_fetch_another): Change return type.
8261 (xml_fetch_content_from_file): Change return type.
8262 * xml-syscall.c (xml_init_syscalls_info): Adjust.
8263 * xml-tdesc.c (file_read_description_xml): Adjust.
8264 (fetch_available_features_from_target): Change return type.
8265 (target_fetch_description_xml): Adjust.
8266 (target_read_description_xml): Adjust.
8267
14c88955
TT
82682018-04-06 Tom Tromey <tom@tromey.com>
8269
8270 * value.c (~value): Update.
8271 (struct value) <contents>: Now unique_xmalloc_ptr.
8272 (value_contents_bits_eq, allocate_value_contents)
8273 (value_contents_raw, value_contents_all_raw)
8274 (value_contents_for_printing, value_contents_for_printing_const)
8275 (set_value_enclosing_type): Update.
8276
0c7e6dd8
TT
82772018-04-06 Tom Tromey <tom@tromey.com>
8278
8279 * value.c (range_s): Remove typedef, VEC.
8280 (struct range): Add operator<.
8281 (range_lessthan): Remove.
8282 (ranges_contain): Change type.
8283 (~value): Update.
8284 (struct value) <unavailable, optimized_out>: Now std::vector.
8285 (value_entirely_available)
8286 (value_entirely_covered_by_range_vector)
8287 (value_entirely_unavailable, value_entirely_optimized_out):
8288 Update.
8289 (insert_into_bit_range_vector): Change argument type.
8290 (find_first_range_overlap): Likewise.
8291 (struct ranges_and_idx, value_contents_bits_eq)
8292 (require_not_optimized_out, require_available): Update.
8293 (ranges_copy_adjusted): Change argument types.
8294 (value_optimized_out, value_copy, value_fetch_lazy): Update.
8295
2c8331b9
TT
82962018-04-06 Tom Tromey <tom@tromey.com>
8297
8298 * value.c (~value): Update.
8299 (struct value) <parent>: Now a value_ref_ptr.
8300 (value_parent, set_value_parent, value_address, value_copy):
8301 Update.
8302
466ce3ae
TT
83032018-04-06 Tom Tromey <tom@tromey.com>
8304
8305 * value.c (struct value): Add constructor, destructor, and member
8306 initializers.
8307 (allocate_value_lazy, value_decref): Update.
8308
062d818d
TT
83092018-04-06 Tom Tromey <tom@tromey.com>
8310
8311 * value.c (struct value) <released, next>: Remove.
8312 (all_values): Now a std::vector.
8313 (allocate_value_lazy): Update.
8314 (value_next): Remove.
8315 (value_mark, value_free_to_mark, release_value)
8316 (value_release_to_mark): Update.
8317
a6535de1
TT
83182018-04-06 Tom Tromey <tom@tromey.com>
8319
8320 * value.h (fetch_subexp_value, value_release_to_mark): Update.
8321 (free_value_chain): Remove.
8322 * value.c (free_value_chain): Remove.
8323 (value_release_to_mark): Return a std::vector.
8324 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
8325 std::vector.
8326 (check_condition): Update.
8327 * eval.c (fetch_subexp_value): Change "val_chain" to a
8328 std::vector.
8329 * breakpoint.c (update_watchpoint): Update.
8330 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
8331
b5621201
TT
83322018-04-06 Tom Tromey <tom@tromey.com>
8333
8334 * value.h (free_all_values): Remove.
8335 * value.c (free_all_values): Remove.
8336
4d0266a0
TT
83372018-04-06 Tom Tromey <tom@tromey.com>
8338
8339 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
8340 (value_history_chain, value_history_count): Remove.
8341 (value_history): New global.
8342 (record_latest_value, access_value_history, show_values)
8343 (preserve_values): Update.
8344
b4d61099
TT
83452018-04-06 Tom Tromey <tom@tromey.com>
8346
8347 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
8348 * varobj.c (varobj_set_display_format, varobj_set_value)
8349 (install_default_visualizer, construct_visualizer)
8350 (install_new_value, ~varobj, varobj_get_value_type)
8351 (my_value_of_variable, varobj_editable_p): Update.
8352 * c-varobj.c (c_describe_child, c_value_of_variable)
8353 (cplus_number_of_children, cplus_describe_child): Update.
8354 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
8355 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
8356 (ada_value_of_variable, ada_value_is_changeable_p): Update.
8357
9b558729
TT
83582018-04-06 Tom Tromey <tom@tromey.com>
8359
8360 * printcmd.c (last_examine_address): Change type to
8361 value_ref_ptr.
8362 (do_examine, x_command): Update.
8363
850645cf
TT
83642018-04-06 Tom Tromey <tom@tromey.com>
8365
8366 * value.c (release_value): Update.
8367 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
8368 (struct bpstats) <val>: Now a value_ref_ptr.
8369 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
8370 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
8371 (~watchpoint, print_it_watchpoint, watch_command_1)
8372 (invalidate_bp_value_on_memory_change): Update.
8373
22bc8444
TT
83742018-04-06 Tom Tromey <tom@tromey.com>
8375
8376 * varobj.c (varobj_clear_saved_item)
8377 (update_dynamic_varobj_children, install_new_value, ~varobj):
8378 Update.
8379 * value.h (value_incref): Move declaration earlier.
8380 (value_decref): Rename from value_free.
8381 (struct value_ref_policy): New.
8382 (value_ref_ptr): New typedef.
8383 (struct value_deleter): Remove.
8384 (gdb_value_up): Remove typedef.
8385 (release_value): Change return type.
8386 (release_value_or_incref): Remove.
8387 * value.c (set_value_parent): Update.
8388 (value_incref): Change return type.
8389 (value_decref): Rename from value_free.
8390 (value_free_to_mark, free_all_values, free_value_chain): Update.
8391 (release_value): Return value_ref_ptr.
8392 (release_value_or_incref): Remove.
8393 (record_latest_value, set_internalvar, clear_internalvar):
8394 Update.
8395 * stack.c (info_frame_command): Don't call value_free.
8396 * python/py-value.c (valpy_dealloc, valpy_new)
8397 (value_to_value_object): Update.
8398 * printcmd.c (do_examine): Update.
8399 * opencl-lang.c (lval_func_free_closure): Update.
8400 * mi/mi-main.c (register_changed_p): Don't call value_free.
8401 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
8402 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
8403 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
8404 value_free.
8405 * guile/scm-value.c (vlscm_free_value_smob)
8406 (vlscm_scm_from_value): Update.
8407 * frame.c (frame_register_unwind, frame_unwind_register_signed)
8408 (frame_unwind_register_unsigned, get_frame_register_bytes)
8409 (put_frame_register_bytes): Don't call value_free.
8410 * findvar.c (address_from_register): Don't call value_free.
8411 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
8412 * dwarf2loc.c (entry_data_value_free_closure)
8413 (value_of_dwarf_reg_entry, free_pieced_value_closure)
8414 (dwarf2_evaluate_loc_desc_full): Update.
8415 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
8416 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
8417 (~watchpoint, watch_command_1)
8418 (invalidate_bp_value_on_memory_change): Update.
8419 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
8420
7f8a5d38
SM
84212018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
8422
8423 PR gdb/23022
8424 * warning.m4: Add -Wno-error=deprecated-register.
8425 * configure: Re-generate.
8426
8a76bd3b
TT
84272018-04-05 Tom Tromey <tom@tromey.com>
8428
8429 * linespec.h: Remove include of "vec.h".
8430
8e8d776e
TT
84312018-04-05 Tom Tromey <tom@tromey.com>
8432
8433 * linespec.c (typep): Remove typedef.
8434 (find_methods, find_superclass_methods): Take a std::vector.
8435 (find_method): Use std::vector.
8436
9b2f8581
TT
84372018-04-05 Tom Tromey <tom@tromey.com>
8438
8439 * utils.c (compare_strings): Remove.
8440 * utils.h (compare_strings): Remove.
8441 * objc-lang.h (find_imps): Update.
8442 * objc-lang.c (find_methods): Take a std::vector.
8443 (uniquify_strings, find_imps): Likewise.
8444 * linespec.c (find_methods): Take a std::vector.
8445 (decode_objc): Use std::vector.
8446 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
8447 a std::vector.
8448 (find_method, find_function_symbols): Use std::vector.
8449
459a2e4c
TT
84502018-04-05 Tom Tromey <tom@tromey.com>
8451
8452 * completer.c (completion_tracker::completion_tracker): Remove
8453 cast.
8454 (completion_tracker::discard_completions): Likewise.
8455 * breakpoint.c (ambiguous_names_p): Remove cast.
8456 * ada-lang.c (_initialize_ada_language): Remove cast.
8457 * utils.h (streq): Update.
8458 (streq_hash): Add new declaration.
8459 * utils.c (streq): Return bool.
8460 (streq_hash): New function.
8461
9be2c17a
TT
84622018-04-05 Tom Tromey <tom@tromey.com>
8463
8464 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
8465 Remove a string copy.
8466
f73c6ece
TT
84672018-04-05 Tom Tromey <tom@tromey.com>
8468
8469 * linespec.c (filter_results): Use std::vector.
8470 (decode_line_2, decode_line_full): Update.
8471
53a0f8a2
TT
84722018-04-05 Tom Tromey <tom@tromey.com>
8473
8474 * linespec.c (canonical_to_fullform): Return std::string.
8475 (filter_results): Update.
8476 (struct decode_line_2_item): Add constructor.
8477 <fullform, displayform>: Now std::string.
8478 (decode_line_2_compare_items): Now a std::sort comparator.
8479 (decode_line_2): Update.
8480
a5b5adf5
TT
84812018-04-05 Tom Tromey <tom@tromey.com>
8482
8483 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
8484 (unexpected_linespec_error): Update.
8485 (linespec_parse_basic, parse_linespec): Update.
8486
6a307fc5
TT
84872018-04-05 Tom Tromey <tom@tromey.com>
8488
8489 * linespec.c (linespec_parse_basic): Reindent.
8490
41c1efc6
TT
84912018-04-05 Tom Tromey <tom@tromey.com>
8492
8493 * minsyms.h (iterate_over_minimal_symbols): Update.
8494 * minsyms.c (iterate_over_minimal_symbols): Take a
8495 gdb::function_view.
8496 * linespec.c (struct collect_minsyms): Remove.
8497 (compare_msyms): Now a std::sort comparator.
8498 (add_minsym): Add parameters.
8499 (search_minsyms_for_name): Update. Use std::vector.
8500
c5edbf3d
TT
85012018-04-03 Tom Tromey <tom@tromey.com>
8502
8503 * mipsread.c (read_alphacoff_dynamic_symtab): Use
8504 gdb::byte_vector.
8505
b39efc48
WP
85062018-04-02 Weimin Pan <weimin.pan@oracle.com>
8507
8508 * MAINTAINERS (Write After Approval): Add Weimin Pan.
8509
121ad66c 85102018-04-02 Weimin Pan <weimin.pan@oracle.com>
79f18731
WP
8511
8512 PR gdb/16959
8513 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
8514 printing static type.
8515
09473be8
TT
85162018-04-01 Tom Tromey <tom@tromey.com>
8517
8518 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
8519 (rs6000_xfer_shared_libraries): Update.
8520
ec1f2d91
SM
85212018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
8522
8523 * common/gdb_vecs.h (char_ptr): Remove.
8524 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
8525
d8611974
SM
85262018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
8527
8528 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
8529 with std::vector.
8530 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
8531
a18ba4e4
SM
85322018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
8533
8534 * tracepoint.h (struct uploaded_tp): Initialize fields.
8535 <actions, step_actions, cmd_strings>: Change type to
8536 std::vector<char *>.
8537 * tracepoint.c (get_uploaded_tp): Allocate with new.
8538 (free_uploaded_tps): Free with delete.
8539 (parse_tracepoint_definition): Adjust to std::vector change.
8540 * breakpoint.c (read_uploaded_action): Likewise.
8541 (create_tracepoint_from_upload): Likewise.
8542 * ctf.c (ctf_write_uploaded_tp): Likewise.
8543 (SET_ARRAY_FIELD): Likewise.
8544 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
8545
a7961323
TT
85462018-03-30 Tom Tromey <tom@tromey.com>
8547
8548 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
8549 std::unique_ptr.
8550 (svr4_keep_data_in_core): Update.
8551 (svr4_read_so_list): Update.
8552
e83e4e24
TT
85532018-03-30 Tom Tromey <tom@tromey.com>
8554
8555 * windows-nat.c (handle_output_debug_string, handle_exception):
8556 Update.
8557 * target.h (target_read_string): Update.
8558 * target.c (target_read_string): Change "string" to
8559 unique_xmalloc_ptr.
8560 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
8561 Update.
8562 * solib-frv.c (frv_current_sos): Update.
8563 * solib-dsbt.c (dsbt_current_sos): Update.
8564 * solib-darwin.c (darwin_current_sos): Update.
8565 * linux-thread-db.c (inferior_has_bug): Update.
8566 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
8567 Update. Remove alloca.
8568 * ada-lang.c (ada_main_name): Update.
8569
263db9a1
TT
85702018-03-30 Tom Tromey <tom@tromey.com>
8571
8572 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
8573 (struct dwo_file_deleter): New.
8574 (dwo_file_up): New typedef.
8575 (open_and_init_dwo_file): Use dwo_file_up.
8576 (free_dwo_file_cleanup): Remove.
8577
5dafb3d1
TT
85782018-03-30 Tom Tromey <tom@tromey.com>
8579
8580 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
8581 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
8582
11ed8cad
TT
85832018-03-30 Tom Tromey <tom@tromey.com>
8584
8585 * dwarf2read.c (class free_cached_comp_units): New class.
8586 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
8587 (free_cached_comp_units): Remove function.
8588
9ae79dac
TT
85892018-03-30 Tom Tromey <tom@tromey.com>
8590
8591 * utils.h (make_cleanup_unpush_target): Remove.
8592 * inf-ptrace.c (struct target_unpusher): New.
8593 (target_unpush_up) New typedef.
8594 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
8595 target_unpush_up.
8596 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
8597
5aa89276
TT
85982018-03-27 Tom Tromey <tom@tromey.com>
8599
8600 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
8601
1dbeed45
TT
86022018-03-27 Pedro Alves <palves@redhat.com>
8603 Tom Tromey <tom@tromey.com>
8604
8605 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
8606 destructor. Now a class.
8607 (gdb_readline_wrapper_cleanup): Remove function.
8608 (gdb_readline_wrapper): Remove cleanups.
8609
c819b2c0
TT
86102018-03-27 Tom Tromey <tom@tromey.com>
8611
8612 * typeprint.h (struct type_print_options) <local_typedefs,
8613 global_typedefs>: Remove "struct" keyword.
8614 (class typedef_hash_table): New class.
8615 (recursively_update_typedef_hash, add_template_parameters)
8616 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
8617 (find_typedef_in_hash): Don't declare.
8618 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
8619 (typedef_hash_table::recursively_update): Rename from
8620 recursively_update_typedef_hash. Now a member.
8621 (typedef_hash_table::add_template_parameters): Rename from
8622 add_template_parameters. Now a member.
8623 (typedef_hash_table::typedef_hash_table): Now a constructor;
8624 rename from create_typedef_hash.
8625 (typedef_hash_table::~typedef_hash_table): Now a destructor;
8626 rename from free_typedef_hash.
8627 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
8628 (do_free_global_table): Remove.
8629 (typedef_hash_table::typedef_hash_table): New constructor; renamed
8630 from copy_type_recursive.
8631 (create_global_typedef_table): Remove.
8632 (typedef_hash_table::find_global_typedef): Now a member of
8633 typedef_hash_table.
8634 (typedef_hash_table::find_typedef): Rename from
8635 find_typedef_in_hash; now a member.
8636 (whatis_exp): Update.
8637 * extension.h (struct ext_lang_type_printers): Add constructor and
8638 destructor.
8639 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
8640 declare.
8641 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
8642 Now a constructor; rename from start_ext_lang_type_printers.
8643 (ext_lang_type_printers): Now a destructor; rename from
8644 free_ext_lang_type_printers.
8645 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
8646 Update.
8647 (c_type_print_base_struct_union): Update. Remove cleanups.
8648
608219fb
TT
86492018-03-27 Tom Tromey <tom@tromey.com>
8650
8651 * dwarf-index-write.c: Include <cmath>.
8652
3fcded8f
JB
86532018-03-27 Joel Brobecker <brobecker@adacore.com>
8654
8655 * NEWS: Add entry describing new "set|show varsize-limit" command.
8656 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
8657 command.
8658 * printcmd.c (_initialize_printcmd): Add "set var" alias of
8659 "set variable".
8660
cd4fb1b2
SM
86612018-03-27 Simon Marchi <simon.marchi@ericsson.com>
8662
8663 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
8664 dwarf-index-write.c
8665 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
8666 * dwarf-index-common.c: New file.
8667 * dwarf-index-common.h: New file.
8668 * dwarf-index-write.c: New file.
8669 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
8670 (struct dwarf2_section_info): Move from here.
8671 (dwarf2_section_info_def): Likewise.
8672 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
8673 (offset_type): Likewise.
8674 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
8675 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
8676 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
8677 (byte_swap): Likewise.
8678 (MAYBE_SWAP): Likewise.
8679 (dwarf2_per_cu_ptr): Likewise.
8680 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
8681 (struct tu_stats): Likewise.
8682 (struct dwarf2_per_objfile): Likewise.
8683 (struct dwarf2_per_cu_data): Likewise.
8684 (struct signatured_type): Likewise.
8685 (sig_type_ptr): Likewise.
8686 (DEF_VEC_P (sig_type_ptr)): Likewise.
8687 (INDEX4_SUFFIX): Likewise.
8688 (INDEX5_SUFFIX): Likewise.
8689 (DEBUG_STR_SUFFIX): Likewise.
8690 (dwarf2_read_section): Make non-static.
8691 (mapped_index_string_hash): Move from here.
8692 (dwarf5_djb_hash): Likewise.
8693 (file_write): Likewise.
8694 (class data_buf): Likewise.
8695 (struct symtab_index_entry): Likewise.
8696 (struct mapped_symtab): Likewise.
8697 (find_slot): Likewise.
8698 (hash_expand): Likewise.
8699 (add_index_entry): Likewise.
8700 (uniquify_cu_indices): Likewise.
8701 (class c_str_view): Likewise.
8702 (class c_str_view_hasher): Likewise.
8703 (class vector_hasher): Likewise.
8704 (write_hash_table): Likewise.
8705 (psym_index_map): Likewise.
8706 (struct addrmap_index_data): Likewise.
8707 (add_address_entry): Likewise.
8708 (add_address_entry_worker): Likewise.
8709 (write_address_map): Likewise.
8710 (symbol_kind): Likewise.
8711 (write_psymbols): Likewise.
8712 (struct signatured_type_index_data): Likewise.
8713 (write_one_signatured_type): Likewise.
8714 (recursively_count_psymbols): Likewise.
8715 (recursively_write_psymbols): Likewise.
8716 (class debug_names): Likewise.
8717 (check_dwarf64_offsets): Likewise.
8718 (psyms_seen_size): Likewise.
8719 (write_gdbindex): Likewise.
8720 (write_debug_names): Likewise.
8721 (assert_file_size): Likewise.
8722 (write_psymtabs_to_index): Likewise.
8723 (save_gdb_index_command): Likewise.
8724 (_initialize_dwarf2_read): Don't register the "save gdb-index"
8725 command.
8726 * dwarf2read.h: New file.
8727
59cc4834
JB
87282018-03-27 Joel Brobecker <brobecker@adacore.com>
8729
8730 PR gdb/22670
8731 * dwarf2read.c (dwarf2_physname): Do not return the demangled
8732 symbol name if the CU's language stores symbol names in linkage
8733 format.
8734 * language.h (struct language_defn)
8735 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
8736 all instances of this struct.
8737
67501539
TT
87382018-03-26 Tom Tromey <tom@tromey.com>
8739
8740 * stack.c (backtrace_command_1): Remove verbose code.
8741
76c939ac
TT
87422018-03-26 Tom Tromey <tom@tromey.com>
8743
8744 * python/py-framefilter.c (py_print_type): Don't catch
8745 exceptions. Return void.
8746 (py_print_value): Likewise.
8747 (py_print_single_arg): Likewise.
8748 (enumerate_args): Don't catch exceptions.
8749 (py_print_args): Likewise.
8750 (py_print_frame): Likewise.
8751 (gdbpy_apply_frame_filter): Catch exceptions here.
8752
9507b29c
TT
87532018-03-26 Tom Tromey <tom@tromey.com>
8754
8755 * stack.c (_initialize_stack): Remove trailing newlines from help
8756 text. Add "Usage" line to "backtrace" help.
8757
eb68e487
TT
87582018-03-26 Tom Tromey <tom@tromey.com>
8759
8760 PR python/16486:
8761 * python/py-framefilter.c (py_print_args): Call wrap_hint.
8762
1f111921
TT
87632018-03-26 Tom Tromey <tom@tromey.com>
8764
8765 * python/py-framefilter.c (py_print_single_arg): Return
8766 EXT_LANG_BT_ERROR from catch.
8767
fb7eb8b5
TT
87682018-03-26 Tom Tromey <tom@tromey.com>
8769
8770 PR backtrace/15584:
8771 * stack.c (backtrace_command_1): Move some code into no-filters
8772 "if".
8773
4ca59a9f
TT
87742018-03-26 Tom Tromey <tom@tromey.com>
8775
8776 * python/py-framefilter.c (throw_quit_or_print_exception): New
8777 function.
8778 (gdbpy_apply_frame_filter): Use it.
8779
92256134
TT
87802018-03-26 Tom Tromey <tom@tromey.com>
8781
8782 PR cli/17716:
8783 * python/py-framefilter.c (py_print_type, py_print_value)
8784 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
8785 RETURN_MASK_ERROR.
8786
7a630bc2
TT
87872018-03-26 Tom Tromey <tom@tromey.com>
8788
8789 * python/py-framefilter.c (enumerate_args): Use
8790 gdb::unique_xmalloc_ptr.
8791
63283d4a
TT
87922018-03-26 Tom Tromey <tom@tromey.com>
8793
8794 * python/py-framefilter.c (py_print_frame): Return
8795 EXT_LANG_BT_OK.
8796 (gdbpy_apply_frame_filter): Update comment.
8797 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
8798 Remove.
8799 <EXT_LANG_BT_NO_FILTERS>: Change value.
8800
978d6c75
TT
88012018-03-26 Tom Tromey <tom@tromey.com>
8802
8803 PR backtrace/15582:
8804 * stack.c (backtrace_command): Parse "hide" argument.
8805 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
8806 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
8807 constant.
8808
1cf7e640
TT
88092018-03-26 Tom Tromey <tom@tromey.com>
8810
8811 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
8812 add "flags".
8813 (backtrace_command): Remove "fulltrace", add "flags".
8814
ea3b0687
TT
88152018-03-26 Tom Tromey <tom@tromey.com>
8816
8817 * stack.c (backtrace_command): Rewrite command line parsing.
8818
9f034d75
SM
88192018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8820
8821 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
8822
ce1459e5
SM
88232018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8824
8825 * filename-seen-cache.h: Add include guard.
8826
4f7ae6f5
KS
88272018-03-26 Keith Seitz <keiths@redhat.com>
8828
8829 * symfile.c (place_section): Remove "struct" from section_addr_info
8830 in comment.
8831 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
8832 "struct" keyword from section_addr_info.
8833
5cd3e386
AH
88342018-03-26 Alan Hayward <alan.hayward@arm.com>
8835
8836 * regformats/regdef.h (reg): Add constructors.
8837
3e5ef9a4
PA
88382018-03-25 Pedro Alves <palves@redhat.com>
8839
8840 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
8841 if then/else bodies in var_func_name extraction.
8842
c88d2fcc 88432018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
8844
8845 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
8846 lookup_minimal_symbol() to find symbol entry.
8847 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
8848
b7fee5a3
KS
88492018-03-23 Keith Seitz <keiths@redhat.com>
8850
8851 PR c++/22968
8852 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
8853 nested type definitions for C++, too.
8854
2cc9b304
TT
88552018-03-23 Tom Tromey <tom@tromey.com>
8856
8857 * machoread.c (struct oso_el): Add a constructor. Don't define as
8858 a typedef.
8859 (macho_register_oso): Remove.
8860 (macho_symtab_read): Take a std::vector.
8861 (oso_el_compare_name): Now a std::sort comparator.
8862 (macho_symfile_read_all_oso): Take a std::vector.
8863 (macho_symfile_read): Use std::vector. Remove cleanups.
8864
a2b2bc12
TT
88652018-03-22 Tom Tromey <tom@tromey.com>
8866
8867 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
8868 (record_full_goto_bookmark): Use std::string.
8869
7a8f494c
PFC
88702018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8871
8872 PR tdep/18295
8873 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
8874 a single mask.
8875
dd6d677f
PFC
88762018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8877
8878 * rs6000-tdep.c (store_insn_p): New function.
8879 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
8880 and cr_reg to their unshifted values. Use store_insn_p to
8881 match LR saves using either R1 or fdata->alloca_reg. Use
8882 store_insn_p to match CR saves. Set alloca_reg_offset
8883 when alloca_reg and framep are set. Remove lr_reg shift
8884 when assigning to fdata->lr_register.
8885
26d6cec4
AA
88862018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
8887
8888 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
8889 command line args instead of emitting a warning.
8890
5d9310c4
SM
88912018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8892
8893 * tracepoint.h (struct static_tracepoint_marker): Initialize
8894 fields, define default constructor, move constructor and move
8895 assignment, disable the rest.
8896 <str_id, extra>: Make std::string.
8897 (release_static_tracepoint_marker): Remove.
8898 (free_current_marker): Remove.
8899 * tracepoint.c (free_current_marker): Remove.
8900 (parse_static_tracepoint_marker_definition): Adjust to
8901 std::string, use new hex2str overload.
8902 (release_static_tracepoint_marker): Remove.
8903 (print_one_static_tracepoint_marker): Get marker by reference
8904 and adjust to std::string.
8905 (info_static_tracepoint_markers_command): Adjust to std::vector
8906 changes
8907 * target.h (static_tracepoint_marker_p): Remove typedef.
8908 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
8909 (struct target_ops) <to_static_tracepoint_marker_at>: Return
8910 bool.
8911 <to_static_tracepoint_markers_by_strid>: Return std::vector.
8912 * target-debug.h
8913 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
8914 (target_debug_print_std_vector_static_tracepoint_marker): New.
8915 (target_debug_print_struct_static_tracepoint_marker_p): Rename
8916 to...
8917 (target_debug_print_static_tracepoint_marker_p): ... this.
8918 * target-delegates.c: Re-generate.
8919 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
8920 Make std::string.
8921 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
8922 (decode_static_tracepoint_spec): Adjust to std::vector.
8923 (tracepoint_print_one_detail): Adjust to std::string.
8924 (strace_marker_decode_location): Adjust to std::string.
8925 (update_static_tracepoint): Adjust to std::string, remove call
8926 to release_static_tracepoint_marker.
8927 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
8928 Adjust to std::vector.
8929 * remote.c (remote_static_tracepoint_marker_at): Return bool.
8930 (remote_static_tracepoint_markers_by_strid): Adjust to
8931 std::vector.
8932 * common/rsp-low.h (hex2str): New overload with explicit count
8933 of bytes.
8934 * common/rsp-low.c (hex2str): New overload with explicit count
8935 of bytes.
8936 * unittests/rsp-low-selftests.c (test_hex2str): New function.
8937 (_initialize_rsp_low_selftests): Add test_hex2str test.
8938 * unittests/tracepoint-selftests.c
8939 (test_parse_static_tracepoint_marker_definition): Adjust to
8940 std::string.
8941
62c222b6
SM
89422018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8943
8944 * tracepoint.c (parse_static_tracepoint_marker_definition):
8945 Consider case where the definition is followed by more
8946 definitions.
8947 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8948 tracepoint-selftests.c.
8949 * unittests/tracepoint-selftests.c: New.
8950
7eb2418f
PFC
89512018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8952
8953 * MAINTAINERS (Write After Approval): Add Pedro Franco de
8954 Carvalho.
8955
7cbe16e9
SR
89562018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8957
3d6b3b82 8958 * symtab.c (find_pc_sect_line): fixed indentation.
7cbe16e9 8959
4ee89e90
SR
89602018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8961
3d6b3b82 8962 * symtab.c (find_pc_sect_line): now uses binary search.
4ee89e90 8963
92630041
TT
89642018-03-19 Tom Tromey <tom@tromey.com>
8965
8966 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
8967 "IDENT" production.
8968
76727919
TT
89692018-03-19 Pedro Alves <palves@redhat.com>
8970 Tom Tromey <tom@tromey.com>
8971
8972 * unittests/observable-selftests.c: New file.
8973 * common/observable.h: New file.
8974 * observable.h: New file.
8975 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
8976 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
8977 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
8978 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
8979 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
8980 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
8981 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
8982 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
8983 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
8984 python/py-breakpoint.c, python/py-finishbreakpoint.c,
8985 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
8986 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
8987 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
8988 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
8989 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
8990 tui/tui-interp.c, valops.c: Update all users.
8991 * tui/tui-hooks.c (tui_bp_created_observer)
8992 (tui_bp_deleted_observer, tui_bp_modified_observer)
8993 (tui_inferior_exit_observer, tui_before_prompt_observer)
8994 (tui_normal_stop_observer, tui_register_changed_observer):
8995 Remove.
8996 (tui_observers_token): New global.
8997 (attach_or_detach, tui_attach_detach_observers): New functions.
8998 (tui_install_hooks, tui_remove_hooks): Use
8999 tui_attach_detach_observers.
9000 * record-btrace.c (record_btrace_thread_observer): Remove.
9001 (record_btrace_thread_observer_token): New global.
9002 * observer.sh: Remove.
9003 * observer.c: Rename to observable.c.
9004 * observable.c (namespace gdb_observers): Define new objects.
9005 (observer_debug): Move into gdb_observers namespace.
9006 (struct observer, struct observer_list, xalloc_observer_list_node)
9007 (xfree_observer_list_node, generic_observer_attach)
9008 (generic_observer_detach, generic_observer_notify): Remove.
9009 (_initialize_observer): Update.
9010 Don't include observer.inc.
9011 * Makefile.in (generated_files): Remove observer.h, observer.inc.
9012 (clean mostlyclean): Likewise.
9013 (observer.h, observer.inc): Remove targets.
9014 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
9015 (COMMON_SFILES): Use observable.c, not observer.c.
9016 * .gitignore: Remove observer.h.
9017
1cb1f3da
TT
90182018-03-18 Tom Tromey <tom@tromey.com>
9019
9020 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
9021 gdb::def_vector.
9022 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
9023
a06ab151
TT
90242018-03-17 Tom Tromey <tom@tromey.com>
9025
9026 * auto-load.c (auto_load_objfile_script_1): Use std::string.
9027
770623f7
TT
90282018-03-17 Tom Tromey <tom@tromey.com>
9029
9030 * target.c (class scoped_target_fd): New.
9031 (target_fileio_close_cleanup): Remove.
9032 (target_fileio_read_alloc_1): Use scoped_target_fd.
9033
39be3c7e
SM
90342018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
9035
9036 * silent-rules.mk: New.
9037 * Makefile.in: Include silent-rules.mk
9038 (srcdir, VPATH, top_srcdir): Move up.
9039 (COMPILE): Add ECHO_CXX.
9040 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
9041 (init.c): Add ECHO_INIT_C.
9042 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
9043 (version.c): Add ECHO_GEN.
9044 (printcmd.o): Add ECHO_CXX.
9045 (target-float.o): Add ECHO_CXX.
9046 (ada-exp.o): Add ECHO_CXX.
9047 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
9048 (insight$(EXEEXT)): Add ECHO_CXXLD.
9049 * gnulib/configure.ac: Add AM_SILENT_RULES.
9050 * gnulib/aclocal.m4: Re-generate.
9051 * gnulib/configure: Re-generate.
9052 * gnulib/import/Makefile.in: Re-generate.
9053
37e136b1
TT
90542018-03-16 Tom Tromey <tom@tromey.com>
9055
9056 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
9057 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
9058 * utils.c (do_free_section_addr_info)
9059 (make_cleanup_free_section_addr_info): Remove.
9060 * symfile.h (struct other_sections): Add constructor.
9061 (struct section_addr_info): Remove.
9062 (section_addr_info): New typedef.
9063 (struct sym_fns) <sym_offsets>: Change type of parameter.
9064 (build_section_addr_info_from_objfile)
9065 (relative_addr_info_to_section_offsets, addr_info_make_relative)
9066 (default_symfile_offsets, symbol_file_add)
9067 (symbol_file_add_from_bfd)
9068 (build_section_addr_info_from_section_table): Update.
9069 (alloc_section_addr_info, free_section_addr_info): Don't declare.
9070 * symfile.c (alloc_section_addr_info): Remove.
9071 (build_section_addr_info_from_section_table): Change return type.
9072 Update.
9073 (build_section_addr_info_from_bfd)
9074 (build_section_addr_info_from_objfile): Likewise.
9075 (free_section_addr_info): Remove.
9076 (relative_addr_info_to_section_offsets): Change type of "addrs".
9077 (addrs_section_compar): Now a std::sort comparator.
9078 (addrs_section_sort): Change return type.
9079 (addr_info_make_relative): Change type of "addrs". Update.
9080 (default_symfile_offsets, syms_from_objfile_1)
9081 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
9082 (symbol_file_add_separate): Update.
9083 (symbol_file_add): Change type of "addrs". Update.
9084 (add_symbol_file_command): Update. Remove cleanups.
9085 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
9086 cleanups.
9087 * symfile-debug.c (debug_sym_offsets): Change type of "info".
9088 * solib.c (solib_read_symbols): Update.
9089 * objfiles.c (objfile_relocate): Update. Remove cleanups.
9090 * machoread.c (macho_symfile_offsets): Update.
9091 * jit.c (jit_bfd_try_read_symtab): Update.
9092
03afa6ef
SM
90932018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
9094
9095 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9096 unittests/utils-selftests.c.
9097 * unittests/utils-selftests.c: New file.
9098
3ae9ce5d
TT
90992018-03-14 Tom Tromey <tom@tromey.com>
9100
9101 PR cli/14977:
9102 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
9103 for NULL.
9104
b8c2339b
TT
91052018-03-14 Tom Tromey <tom@tromey.com>
9106
9107 PR cli/19918:
9108 * printcmd.c (printf_pointer): Allow "-" in format.
9109
80ae639d
TT
91102018-03-14 Tom Tromey <tom@tromey.com>
9111
9112 * printcmd.c (_initialize_printcmd): Add usage to printf.
9113
0d671d99
YQ
91142018-03-14 Yao Qi <qiyao@sourceware.org>
9115
9116 * MAINTAINERS: Update my email address.
9117
b577b6af
TT
91182018-03-13 Tom Tromey <tom@tromey.com>
9119
9120 * machoread.c (macho_check_dsym): Change filenamep to a
9121 std::string*.
9122 (macho_symfile_read): Update.
9123 * symfile.c (load_command): Use std::string.
9124
89a3b63e
AB
91252018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
9126
9127 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
9128 to error message string.
9129 (riscv_register_name): Use xsnprintf instead of sprintf.
9130 (riscv_insn::fetch_instruction): Use gdb_assert instead of
9131 internal_error.
9132 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
9133 error.
9134 (riscv_push_dummy_call): Likewise.
9135
984c7238
TT
91362018-03-12 Tom Tromey <tom@tromey.com>
9137
9138 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
9139 Use gdb::byte_vector.
9140 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
9141
933522d1
YQ
91422018-03-12 Yao Qi <yao.qi@linaro.org>
9143
9144 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
9145 parameter type to readable_regcache.
9146 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
9147 the declaration.
9148
be2daae6
TT
91492018-03-11 Tom Tromey <tom@tromey.com>
9150
9151 * dwarf2read.c (struct nextfield): Add initializers.
9152 (struct nextfnfield): Remove.
9153 (struct fnfieldlist): Add initializers. Remove "length" and
9154 "head", use std::vector.
9155 (struct decl_field_list): Remove.
9156 (struct field_info): Add initializers.
9157 <fields, baseclasses>: Now std::vector.
9158 <nbaseclasses, nfnfields, typedef_field_list_count,
9159 nested_types_list_count>: Remove.
9160 (dwarf2_add_field, dwarf2_add_type_defn)
9161 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
9162 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
9163 (process_structure_scope): Update.
9164
484cf504
TT
91652018-03-11 Tom Tromey <tom@tromey.com>
9166
9167 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
9168 for use by std::sort.
9169 (build_type_psymtabs_1): Use std::vector.
9170
9bd8e0b0
EZ
91712018-03-09 Eli Zaretskii <eliz@gnu.org>
9172
9173 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
9174 and LIBMPFR in the printed configuration.
9175
5dc1a704
TT
91762018-03-08 Tom Tromey <tom@tromey.com>
9177
9178 * source.c (get_filename_and_charpos): Use scoped_fd.
9179 * nto-procfs.c (procfs_open_1): Use scoped_fd.
9180 (procfs_pidlist): Likewise.
9181 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
9182 (iterate_over_mappings): Likewise.
9183
fdf07f3a
TT
91842018-03-08 Tom Tromey <tom@tromey.com>
9185
9186 * infcall.c (struct call_return_meta_info)
9187 <stack_temporaries_enabled>: Remove.
9188 (get_call_return_value, call_function_by_hand_dummy): Update.
9189 * thread.c (disable_thread_stack_temporaries): Remove.
9190 (enable_thread_stack_temporaries): Remove.
9191 (thread_stack_temporaries_enabled_p): Return bool.
9192 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
9193 (get_last_thread_stack_temporary): Update.
9194 * eval.c (evaluate_subexp): Update.
9195 * gdbthread.h (class enable_thread_stack_temporaries): Now a
9196 class, not a function.
9197 (value_ptr, value_vec): Remove typedefs.
9198 (class thread_info) <stack_temporaries_enabled>: Now bool.
9199 <stack_temporaries>: Now a std::vector.
9200 (thread_stack_temporaries_enabled_p)
9201 (value_in_thread_stack_temporaries): Return bool.
9202
567a3e54
SM
92032018-03-08 Simon Marchi <simon.marchi@ericsson.com>
9204
9205 * remote.c (putpkt_binary): Fix omitted bytes reporting.
9206 (getpkt_or_notif_sane_1): Likewise.
9207
00b40057
SM
92082018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9209
9210 * build-id.c (build_id_to_debug_bfd): Use std::string.
9211
a8dbfd58
SM
92122018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9213
9214 * build-id.c (find_separate_debug_file_by_buildid): Return
9215 std::string.
9216 * build-id.h (find_separate_debug_file_by_buildid): Return
9217 std::string.
9218 * coffread.c (coff_symfile_read): Adjust to std::string.
9219 * elfread.c (elf_symfile_read): Adjust to std::string.
9220 * symfile.c (separate_debug_file_exists): Change parameter to
9221 std::string.
9222 (find_separate_debug_file): Return std::string.
9223 (find_separate_debug_file_by_debuglink): Return std::string.
9224 * symfile.h (find_separate_debug_file_by_debuglink): Return
9225 std::string.
9226
e6a58aa8
SM
92272018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9228
9229 * common/xml-utils.c (xml_escape_text): Move code to...
9230 (xml_escape_text_append): ... this new function.
9231 * common/xml-utils.h (xml_escape_text_append): New declaration.
9232 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
9233 New function.
9234 (_initialize_xml_utils): register test_xml_escape_text_append as
9235 a selftest.
9236
4ef0bef6
AH
92372018-03-07 Alan Hayward <alan.hayward@arm.com>
9238
9239 * defs.h: Remove MAX_REGISTER_SIZE.
9240 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
9241 asserts.
9242 * python/py-unwind.c (pyuw_sniffer): Likewise.
9243
e0d3522b
TT
92442018-03-07 Tom Tromey <tom@tromey.com>
9245
9246 * linux-tdep.c (linux_info_proc): Update.
9247 * target.h (struct target_ops) <to_fileio_readlink>: Return
9248 optional<string>.
9249 (target_fileio_readlink): Return optional<string>.
9250 * remote.c (remote_hostio_readlink): Return optional<string>.
9251 * inf-child.c (inf_child_fileio_readlink): Return
9252 optional<string>.
9253 * target.c (target_fileio_readlink): Return optional<string>.
9254
ea005f31
AB
92552018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
9256
9257 * regcache.c (cooked_read_test): Add riscv to the list of
9258 architectures that have a save_reggroup.
9259
e95a97d4
AA
92602018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
9261
9262 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
9263 value is not a dynamic class object.
9264
d8344f3d
TT
92652018-03-06 Tom Tromey <tom@tromey.com>
9266
9267 * rust-exp.y: Formatting fixes.
9268
9add17f2
AB
92692018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9270
9271 * riscv-tdep.c (riscv_register_name): Remove target description
9272 support.
9273 (riscv_gdbarch_init): Remove target description check.
9274
c9486dfe
AB
92752018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9276
9277 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
9278 comment.
9279 * riscv-tdep.h: Likewise.
9280
d74aff3d
AB
92812018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9282
9283 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
9284 (riscv_pseudo_register_write): Delete.
9285 (riscv_gdbarch_init): Remove all use of pseudo registers.
9286
7ea78b59
SM
92872018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9288
9289 * record-btrace.c (btrace_print_lines): Replace cleanup
9290 parameter with RAII equivalents.
9291 (btrace_insn_history): Replace cleanup with RAII equivalents.
9292 * ui-out.h (make_cleanup_ui_out_list_begin_end,
9293 make_cleanup_ui_out_tuple_begin_end): Remove.
9294 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
9295 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
9296 make_cleanup_ui_out_list_begin_end): Remove.
9297
53127008
SM
92982018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9299
9300 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
9301 parameter types to std::vector. Use bool.
9302 (record_btrace_wait): Replace VEC(tp_t) with
9303 std::vector<thread_info *>.
9304 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
9305
228f1508
SM
93062018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9307
9308 * record-btrace.c (record_btrace_disable_callback): Remove.
9309 (struct scoped_btrace_disable): New.
9310 (record_btrace_open): Use scoped_btrace_disable.
9311
b2970c23
AB
93122018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9313
9314 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
9315 reading values from registers.
9316
fb294655
AB
93172018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9318
9319 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
9320 where appropriate.
9321
cab5bb9d
AB
93222018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9323
9324 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
9325 change parameter type. Use GDB's print functions, and use
9326 core_addr_to_string where appropriate.
9327 (riscv_push_dummy_call): Use core_addr_to_string where
9328 appropriate, update call to riscv_print_arg_location, and reindent
9329 a few lines.
9330 (riscv_return_value): Update call to riscv_print_arg_location.
9331
dbbb1059
AB
93322018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9333 Tim Newsome <tim@sifive.com>
9334 Albert Ou <a0u@eecs.berkeley.edu>
9335 Darius Rad <darius@bluespec.com>
9336
9337 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
9338 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
9339 (ALLDEPFILES): Add riscv-tdep.c
9340 * configure.tgt: Add riscv support.
9341 * riscv-tdep.c: New file.
9342 * riscv-tdep.h: New file.
9343 * NEWS: Mention new target.
9344 * MAINTAINERS: Add entry for riscv.
9345
5dc43913
AB
93462018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9347
9348 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
9349 fields within aggregates.
9350
3dea1ef7
SM
93512018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
9352
9353 * record-btrace.c (btrace_print_lines): Change type of flags to
9354 gdb_disassembly_flags.
9355
7efba073
JB
93562018-03-04 John Baldwin <jhb@FreeBSD.org>
9357
9358 * fbsd-nat.c: Include "inf-ptrace.h".
9359 (USE_SIGTRAP_SIGINFO): Conditionally define.
9360 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
9361 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
9362 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
9363 function.
9364 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
9365 Likewise.
9366 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
9367 Likewise.
9368 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
9369 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
9370 "supports_stopped_by_hw_breakpoint" target methods.
9371
386a8676
JB
93722018-03-04 John Baldwin <jhb@FreeBSD.org>
9373
9374 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
9375 * fbsd-nat.c (debug_fbsd_nat): New variable.
9376 (show_fbsd_nat_debug): New function.
9377 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
9378 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
9379
12279366
JB
93802018-03-04 John Baldwin <jhb@FreeBSD.org>
9381
9382 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
9383 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
9384 prototype.
9385 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
9386 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
9387 method.
9388
54693cf5
SM
93892018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9390
9391 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
9392 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
9393
ccb2231c
SM
93942018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9395
9396 * charset.c (struct charset_vector): New.
9397 (charsets): Change type to charset_vector.
9398 (find_charset_names): Adjust.
9399 (add_one): Adjust.
9400 (_initialize_charset): Adjust.
9401
6fb16ce6
SM
94022018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9403
9404 * progspace.h (struct program_space) <deleted_solibs>: Change
9405 type to std::vector<std::string>.
9406 * progspace.c (clear_program_space_solib_cache): Adjust.
9407 * breakpoint.c (print_solib_event): Adjust.
9408 (check_status_catch_solib): Adjust.
9409 * solib.c (update_solib_list): Adjust.
9410 * ui-out.h (class ui_out) <field_string>: New overload.
9411 * ui-out.c (ui_out::field_string): New overload.
9412
564b1e3f
SM
94132018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9414
9415 * progspace.h (struct program_space): Add constructor and
9416 destructor, initialize fields.
9417 (add_program_space): Remove.
9418 * progspace.c (add_program_space): Rename to...
9419 (program_space::program_space): ... this.
9420 (release_program_space): Rename to...
9421 (program_space::~program_space): ... this.
9422 (delete_program_space): Use delete to delete program_space.
9423 (initialize_progspace): Use new to allocate program_space.
9424 * inferior.c (add_inferior_with_spaces): Likewise.
9425 (clone_inferior_command): Likewise.
9426 * infrun.c (follow_fork_inferior): Likewise.
9427 (handle_vfork_child_exec_or_exit): Likewise.
9428
e80aaf61
SM
94292018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9430
9431 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
9432 (delim_string_to_char_ptr_vec): Return std::vector of
9433 gdb::unique_xmalloc_ptr.
9434 (dirnames_to_char_ptr_vec_append): Take std::vector of
9435 gdb::unique_xmalloc_ptr.
9436 (dirnames_to_char_ptr_vec): Return std::vector of
9437 gdb::unique_xmalloc_ptr.
9438 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
9439 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
9440 (delim_string_to_char_ptr_vec): Return an std::vector of
9441 gdb::unique_xmalloc_ptr, adjust the code.
9442 (dirnames_to_char_ptr_vec_append): Take an std::vector of
9443 gdb::unique_xmalloc_ptr, adjust the code.
9444 (dirnames_to_char_ptr_vec): Return an std::vector of
9445 gdb::unique_xmalloc_ptr, adjust the code.
9446 * auto-load.c (auto_load_safe_path_vec): Change type to
9447 std::vector of gdb::unique_xmalloc_ptr.
9448 (auto_load_expand_dir_vars): Return an std::vector of
9449 gdb::unique_xmalloc_ptr, adjust the code.
9450 (auto_load_safe_path_vec_update): Adjust.
9451 (filename_is_in_auto_load_safe_path_vec): Adjust.
9452 (auto_load_objfile_script_1): Adjust.
9453 * build-id.c (build_id_to_debug_bfd): Adjust.
9454 * linux-thread-db.c (thread_db_load_search): Adjust.
9455 * source.c (add_path): Adjust.
9456 (openp): Adjust.
9457 * symfile.c (find_separate_debug_file): Adjust.
9458 * utils.c (do_free_char_ptr_vec): Remove.
9459 (make_cleanup_free_char_ptr_vec): Remove.
9460
ab818ade
SDJ
94612018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
9462
9463 PR gdb/22907
9464 * common/pathstuff.c: Conditionally include "<windows.h>".
9465
e1e6f073
GS
94662018-03-01 Georg Sauthoff <mail@georg.so>
9467
9468 PR gdb/22888
9469 * gcore.in: Quote variables and switch interpreter to bash.
9470
c7b15a66
TT
94712018-03-01 Tom Tromey <tom@tromey.com>
9472
9473 * dwarf2read.c (alloc_discriminant_info): Fix default_index
9474 assertion. Add assertion for discriminant_index.
9475 (quirk_rust_enum): Use correct base type name in univariant case.
9476
0cb7c7b0
SM
94772018-03-01 Simon Marchi <simon.marchi@ericsson.com>
9478
9479 * record.c (get_call_history_modifiers): Return a
9480 record_print_flags.
9481 (cmd_record_call_history): Adjust.
9482 * record-btrace.c (record_btrace_call_history): Adjust.
9483 (record_btrace_call_history_range): Adjust.
9484 (record_btrace_call_history_from): Adjust.
9485 * target-debug.h (target_debug_print_record_print_flags): New.
9486 * target-delegates.c: Re-generate.
9487 * target.c (target_call_history): Change flags type.
9488 (target_call_history_from): Likewise.
9489 (target_call_history_range): Likewise.
9490 * target.h (struct target_ops) <target_call_history>: Likewise.
9491 (target_call_history_from): Likewise.
9492 (target_call_history_range): Likewise.
9493
25e3c82c
SDJ
94942018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
9495 Simon Marchi <simon.marchi@polymtl.ca>
9496
9497 * common/common-utils.c: Include "sys/stat.h".
9498 (is_regular_file): Move here from "source.c"; change return
9499 type to "bool".
9500 * common/common-utils.h (is_regular_file): New prototype.
9501 * common/pathstuff.c (contains_dir_separator): New function.
9502 * common/pathstuff.h (contains_dir_separator): New prototype.
9503 * source.c: Don't include "sys/stat.h".
9504 (is_regular_file): Move to "common/common-utils.c".
9505
b4987c95
SDJ
95062018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
9507
9508 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
9509 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
9510 * auto-load.c: Include "common/pathstuff.h".
9511 * common/common-def.h (current_directory): Move here.
9512 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
9513 function.
9514 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
9515 prototype.
9516 * common/pathstuff.c: New file.
9517 * common/pathstuff.h: New file.
9518 * compile/compile.c: Include "common/pathstuff.h".
9519 * defs.h (current_directory): Move to "common/common-defs.h".
9520 * dwarf2read.c: Include "common/pathstuff.h".
9521 * exec.c: Likewise.
9522 * guile/scm-safe-call.c: Likewise.
9523 * linux-thread-db.c: Likewise.
9524 * main.c: Likewise.
9525 * nto-tdep.c: Likewise.
9526 * objfiles.c: Likewise.
9527 * source.c: Likewise.
9528 * symtab.c: Likewise.
9529 * utils.c: Include "common/pathstuff.h".
9530 (gdb_realpath): Move to "common/pathstuff.c".
9531 (gdb_realpath_keepfile): Likewise.
9532 (gdb_abspath): Likewise.
9533 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
9534 (gdb_realpath_keepfile): Likewise.
9535 (gdb_abspath): Likewise.
9536
f169cfdc
JB
95372018-02-28 John Baldwin <jhb@FreeBSD.org>
9538
9539 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
9540 wildcard process pid for super_resume for kernels with a
9541 specific bug.
9542
e05cac70
PM
95432018-02-27 Phil Muldoon <pmuldoon@redhat.com>
9544
9545 * compile/compile.c (get_args): Add additional comments
9546 explaining function.
9547
55089490
TT
95482018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
9549 Tom Tromey <tom@tromey.com>
9550
9551 * target.h (memory_write_request_s): Remove typedef. Don't define
9552 VEC.
9553 (target_write_memory_blocks): Change argument to std::vector.
9554 (struct memory_write_request): Add constructor.
9555 * target-memory.c (compare_block_starting_address): Return bool.
9556 Change argument types.
9557 (claim_memory): Change arguments to use std::vector.
9558 (split_regular_and_flash_blocks, blocks_to_erase)
9559 (compute_garbled_blocks): Likewise.
9560 (cleanup_request_data, cleanup_write_requests_vector): Remove.
9561 (target_write_memory_blocks): Change argument to std::vector.
9562 * symfile.c (struct load_section_data): Add constructor and
9563 destructor. Use std::vector for "requests".
9564 (struct load_progress_data): Add initializers.
9565 (load_section_callback): Update. Use "new".
9566 (clear_memory_write_data): Remove.
9567 (generic_load): Update.
9568
0c305b61
AH
95692018-02-27 Alan Hayward <alan.hayward@arm.com>
9570
9571 * arch/aarch64.h: Use common/tdesc.h.
9572
c5196c92
MR
95732018-02-26 Maciej W. Rozycki <macro@mips.com>
9574
9575 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
9576 architecture with a 64-bit ABI.
9577
37c33887
MR
95782018-02-26 Maciej W. Rozycki <macro@mips.com>
9579
9580 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
9581 ahead of target description loading.
9582
d4dd3282
TT
95832018-02-26 Tom Tromey <tom@tromey.com>
9584
9585 * stack.c (backtrace_command_1): Update.
9586 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
9587 of "flags".
9588 * python/py-framefilter.c (py_print_frame)
9589 (gdbpy_apply_frame_filter): Change type of "flags".
9590 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
9591 of "flags".
9592 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
9593 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
9594 * extension.h (enum frame_filter_flag): Rename from
9595 frame_filter_flags.
9596 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
9597 (apply_ext_lang_frame_filter): Change type of "flags".
9598 * extension.c (apply_ext_lang_frame_filter): Change type of
9599 "flags".
9600 * extension-priv.h (struct extension_language_ops)
9601 <apply_frame_filter>: Change type of "flags".
9602
6893c19a
TT
96032018-02-26 Tom Tromey <tom@tromey.com>
9604
9605 PR python/16497:
9606 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
9607 off-by-one in py_end computation.
9608 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
9609 PRINT_MORE_FRAMES.
9610 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
9611 constant.
9612
2ddeaf8a
TT
96132018-02-26 Tom Tromey <tom@tromey.com>
9614
9615 * dwarf2read.c (struct variant_field): New.
9616 (struct nextfield) <variant>: New field.
9617 (dwarf2_add_field): Handle DW_TAG_variant_part.
9618 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
9619 discriminated union.
9620 (read_structure_type): Handle DW_TAG_variant_part.
9621 (handle_struct_member_die): New function, extracted from
9622 process_structure_scope. Handle DW_TAG_variant.
9623 (process_structure_scope): Handle discriminated unions. Call
9624 handle_struct_member_die.
9625
c9317f21
TT
96262018-02-26 Tom Tromey <tom@tromey.com>
9627
9628 * rust-lang.h (rust_last_path_segment): Declare.
9629 * rust-lang.c (rust_last_path_segment): Now public. Change
9630 contract.
9631 (struct disr_info): Remove.
9632 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
9633 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
9634 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
9635 (rust_enum_p, rust_enum_variant): New function.
9636 (rust_underscore_fields): Remove "offset" parameter.
9637 (rust_print_enum): New function.
9638 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
9639 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
9640 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
9641 enums.
9642 (rust_internal_print_type): New function, from rust_print_type.
9643 Remove enum code.
9644 (rust_print_type): Call rust_internal_print_type.
9645 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
9646 Update enum handling.
9647 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
9648 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
9649 (rust_union_quirks): New functions.
9650 (process_full_comp_unit, process_full_type_unit): Call
9651 rust_union_quirks.
9652 (process_structure_scope): Update rust_unions if necessary.
9653
7c22600a
TT
96542018-02-26 Tom Tromey <tom@tromey.com>
9655
9656 * value.h (value_union_variant): Declare.
9657 * valops.c (value_union_variant): New function.
9658 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
9659 (struct discriminant_info): New.
9660 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
9661 enumerator.
9662 (struct main_type) <flag_discriminated_union>: New field.
9663
15ce8941
TT
96642018-02-26 Tom Tromey <tom@tromey.com>
9665
9666 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9667 unittests/unpack-selftests.c.
9668 * unittests/unpack-selftests.c: New file.
9669 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
9670
48fbe735
YQ
96712018-02-26 Yao Qi <yao.qi@linaro.org>
9672
9673 * dwarf2read.c (struct partial_die_info) <read>: New method.
9674 (read_partial_die): Remove the declaration.
9675 (load_partial_dies): Update.
9676 (partial_die_info::partial_die_info):
9677 (read_partial_die): Change it to partial_die_info::read.
9678
52356b79
YQ
96792018-02-26 Yao Qi <yao.qi@linaro.org>
9680
9681 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
9682 (fixup_partial_die): Remove declaration.
9683 (scan_partial_symbols): Update.
9684 (partial_die_parent_scope): Likewise.
9685 (partial_die_full_name): Likewise.
9686 (fixup_partial_die): Change it to partial_die_info::fixup.
9687
35cc7ed7
YQ
96882018-02-26 Yao Qi <yao.qi@linaro.org>
9689
9690 * dwarf2read.c (read_partial_die): Update the declaration.
9691 (load_partial_dies): Caller update.
9692 (read_partial_die): Remove one argument abbrev_len.
9693
6f06d47b
YQ
96942018-02-26 Yao Qi <yao.qi@linaro.org>
9695
9696 * dwarf2read.c (struct partial_die_info): Add ctor, delete
9697 assignment operator.
9698 (load_partial_dies): Use ctor and copy ctor.
9699 (read_partial_die): Update.
9700 (dwarf2_cu::find_partial_die): Use ctor.
9701
d590ff25
YQ
97022018-02-26 Yao Qi <yao.qi@linaro.org>
9703
9704 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
9705 (find_partial_die_in_comp_unit): Change it to
9706 dwarf2_cu::find_partial_die.
9707 (find_partial_die): Update.
9708
fd0a254f
YQ
97092018-02-26 Yao Qi <yao.qi@linaro.org>
9710
9711 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
9712 is NULL.
9713
cd9983dd
YQ
97142018-02-26 Yao Qi <yao.qi@linaro.org>
9715
9716 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
9717
f46cd62a
AH
97182018-02-26 Alan Hayward <alan.hayward@arm.com>
9719
9720 * arch/amd64.h: Use common/tdesc.h.
9721 * arch/i386.c: Likewise.
9722 * arch/i386.h: Likewise.
9723 * arch/tic6x.c: Likewise.
9724 * arch/tdesc.h: Move file from here...
9725 * common/tdesc.h: ...to here.
9726 * features/aarch64-core.c: Regenerate.
9727 * features/aarch64-fpu.c: Regenerate.
9728 * features/i386/32bit-avx.c: Regenerate.
9729 * features/i386/32bit-avx512.c: Regenerate.
9730 * features/i386/32bit-core.c: Regenerate.
9731 * features/i386/32bit-linux.c: Regenerate.
9732 * features/i386/32bit-mpx.c: Regenerate.
9733 * features/i386/32bit-pkeys.c: Regenerate.
9734 * features/i386/32bit-sse.c: Regenerate.
9735 * features/i386/64bit-avx.c: Regenerate.
9736 * features/i386/64bit-avx512.c: Regenerate.
9737 * features/i386/64bit-core.c: Regenerate.
9738 * features/i386/64bit-linux.c: Regenerate.
9739 * features/i386/64bit-mpx.c: Regenerate.
9740 * features/i386/64bit-pkeys.c: Regenerate.
9741 * features/i386/64bit-segments.c: Regenerate.
9742 * features/i386/64bit-sse.c: Regenerate.
9743 * features/i386/x32-core.c: Regenerate.
9744 * features/tic6x-c6xp.c: Regenerate.
9745 * features/tic6x-core.c: Regenerate.
9746 * features/tic6x-gp.c: Regenerate.
9747 * target-descriptions.c: Use common/tdesc.h.
9748 * target-descriptions.h: Likewise.
9749
9b292f68
TT
97502018-02-24 Tom Tromey <tom@tromey.com>
9751
9752 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
9753 (try_thread_db_load_from_dir, thread_db_load_search): Use
9754 std::string.
9755 (info_auto_load_libthread_db_compare): Return bool. Change
9756 argument types.
9757 (info_auto_load_libthread_db): Use std::vector, std::string.
9758 Remove cleanups.
9759
281d762b
TT
97602018-02-24 Tom Tromey <tom@tromey.com>
9761
9762 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
9763 std::string.
9764 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
9765 std::string*.
9766 * gdbarch.c: Rebuild.
9767 * gdbarch.h: Rebuild.
9768 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
9769 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
9770 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
9771 std::string*.
9772
9d8780f0
SM
97732018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
9774
9775 * gdbtypes.h (sect_offset): Change type to uint64_t.
9776 (sect_offset_str): New function.
9777 * dwarf2read.c (create_addrmap_from_aranges): Use
9778 sect_offset_str.
9779 (error_check_comp_unit_head): Likewise.
9780 (create_debug_type_hash_table): Likewise.
9781 (read_cutu_die_from_dwo): Likewise.
9782 (init_cutu_and_read_dies): Likewise.
9783 (init_cutu_and_read_dies_no_follow): Likewise.
9784 (process_psymtab_comp_unit_reader): Likewise.
9785 (partial_die_parent_scope): Likewise.
9786 (peek_die_abbrev): Likewise.
9787 (process_queue): Likewise.
9788 (dwarf2_physname): Likewise.
9789 (read_namespace_alias): Likewise.
9790 (read_import_statement): Likewise.
9791 (create_dwo_cu_reader): Likewise.
9792 (create_cus_hash_table): Likewise.
9793 (lookup_dwo_cutu): Likewise.
9794 (inherit_abstract_dies): Likewise.
9795 (read_func_scope): Likewise.
9796 (read_call_site_scope): Likewise.
9797 (dwarf2_add_member_fn): Likewise.
9798 (read_common_block): Likewise.
9799 (read_module_type): Likewise.
9800 (read_typedef): Likewise.
9801 (read_subrange_type): Likewise.
9802 (load_partial_dies): Likewise.
9803 (read_partial_die): Likewise.
9804 (find_partial_die): Likewise.
9805 (read_str_index): Likewise.
9806 (dwarf2_string_attr): Likewise.
9807 (build_error_marker_type): Likewise.
9808 (lookup_die_type): Likewise.
9809 (dump_die_shallow): Likewise.
9810 (follow_die_ref): Likewise.
9811 (dwarf2_fetch_die_loc_sect_off): Likewise.
9812 (dwarf2_fetch_constant_bytes): Likewise.
9813 (follow_die_sig): Likewise.
9814 (get_signatured_type): Likewise.
9815 (get_DW_AT_signature_type): Likewise.
9816 (dwarf2_find_containing_comp_unit): Likewise.
9817 (set_die_type): Likewise.
9818
8ec57239
JB
98192018-02-21 John Baldwin <jhb@FreeBSD.org>
9820
9821 * arch/aarch64.c: Include "common-defs.h".
9822 * arch/amd64.c: Likewise.
9823 * arch/i386.c: Likewise.
9824
3eac2b65
TT
98252018-02-21 Tom Tromey <tom@tromey.com>
9826
9827 * value.h: (extract_field_op): Update.
9828 * eval.c (extract_field_op): Return a const char *.
9829 * expression.h (parse_expression_for_completion): Update.
9830 * completer.c (complete_expression): Update.
9831 (add_struct_fields): Make fieldname const.
9832 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
9833 (mark_completion_tag, parse_exp_in_context_1): Update.
9834 (parse_expression_for_completion): Change "name" to
9835 unique_xmalloc_ptr*.
9836
6ccb583f
TT
98372018-02-21 Tom Tromey <tom@tromey.com>
9838
9839 * infcall.c (call_function_by_hand_dummy): Use std::vector.
9840
c113ed0c
YQ
98412018-02-21 Yao Qi <yao.qi@linaro.org>
9842
9843 * avr-tdep.c (avr_read_pc): Change parameter type to
9844 readable_regcache.
9845 * gdbarch.sh (read_pc): Likewise.
9846 * gdbarch.c: Re-generated.
9847 * gdbarch.h: Re-generated.
9848 * hppa-tdep.c (hppa_read_pc): Change parameter type to
9849 readable_regcache.
9850 * ia64-tdep.c (ia64_read_pc): Likewise.
9851 * mips-tdep.c (mips_read_pc): Likewise.
9852 * spu-tdep.c (spu_read_pc): Likewise.
9853
4c74fe6b
YQ
98542018-02-21 Yao Qi <yao.qi@linaro.org>
9855
9856 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
9857 * regcache-dump.c: New file.
9858 * regcache.c: Move register_dump to regcache-dump.c.
9859 (maintenance_print_registers): Likewise.
9860 (maintenance_print_raw_registers): Likewise.
9861 (maintenance_print_cooked_registers): Likewise.
9862 (maintenance_print_register_groups): Likewise.
9863 (maintenance_print_remote_registers): Likewise.
9864 (_initialize_regcache): Likewise.
9865 * regcache.h (register_dump): Moved from regcache.c.
9866
796bb026
YQ
98672018-02-21 Yao Qi <yao.qi@linaro.org>
9868
9869 * regcache.c (regcache::regcache): Update.
9870 (regcache::invalidate): Move it to detached_regcache::invalidate.
9871 (get_thread_arch_aspace_regcache): Update.
9872 (regcache::raw_update): Update.
9873 (regcache::cooked_read): Remove some code.
9874 (regcache::cooked_read_value): Likewise.
9875 (regcache::raw_write): Remove assert on m_readonly_p.
9876 (regcache::raw_supply_integer): Move it to
9877 detached_regcache::raw_supply_integer.
9878 (regcache::raw_supply_zeroed): Likewise.
9879 * regcache.h (detached_regcache) <raw_supply_integer>: New
9880 declaration.
9881 <raw_supply_zeroed, invalidate>: Likewise.
9882 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
9883 <invalidate>: Likewise.
9884 <m_readonly_p>: Removed.
9885
215c69dc
YQ
98862018-02-21 Yao Qi <yao.qi@linaro.org>
9887
9888 * infcmd.c (get_return_value): Let stop_regs point to
9889 get_current_regcache.
9890 * regcache.c (regcache::regcache): Remove.
9891 (register_dump_reg_buffer): New class.
9892 (regcache_print): Adjust.
9893 * regcache.h (regcache): Remove constructors.
9894
f3384e66
YQ
98952018-02-21 Yao Qi <yao.qi@linaro.org>
9896
9897 * regcache.c (class register_dump): New class.
9898 (register_dump_regcache, register_dump_none): New class.
9899 (register_dump_remote, register_dump_groups): New class.
9900 (regcache_print): Update.
9901 * regcache.h (regcache_dump_what): Move it to regcache.c.
9902 (regcache) <dump>: Remove.
9903
c8ec2f33
YQ
99042018-02-21 Yao Qi <yao.qi@linaro.org>
9905
9906 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
9907 reg_buffer_rw *.
9908 (jit_unwind_reg_set_impl): Call raw_supply.
9909 (jit_frame_sniffer): Use reg_buffer_rw.
9910 * record-full.c (record_full_core_regbuf): Change its type.
9911 (record_full_core_open_1): Use reg_buffer_rw.
9912 (record_full_close): Likewise.
9913 (record_full_core_fetch_registers): Use regcache->raw_supply.
9914 (record_full_core_store_registers): Likewise.
9915 * regcache.c (regcache::get_register_status): Move it to
9916 reg_buffer.
9917 (regcache_raw_set_cached_value): Remove.
9918 (regcache::raw_set_cached_value): Remove.
9919 (regcache::raw_write): Call raw_supply.
9920 (regcache::raw_supply): Move it to reg_buffer_rw.
9921 * regcache.h (regcache_raw_set_cached_value): Remove.
9922 (reg_buffer_rw): New class.
9923
daf6667d
YQ
99242018-02-21 Yao Qi <yao.qi@linaro.org>
9925
9926 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
9927 readonly_detached_regcache.
9928 (dummy_frame_prev_register): Use regcache->cooked_read.
9929 * frame.c (frame_save_as_regcache): Change return type.
9930 (frame_pop): Update.
9931 * frame.h (frame_save_as_regcache): Update declaration.
9932 * inferior.h (get_infcall_suspend_state_regcache): Update
9933 declaration.
9934 * infrun.c (infcall_suspend_state) <registers>: use
9935 readonly_detached_regcache.
9936 (save_infcall_suspend_state): Don't use regcache_dup.
9937 (get_infcall_suspend_state_regcache): Change return type.
9938 * linux-fork.c (struct fork_info) <savedregs>: Change to
9939 readonly_detached_regcache.
9940 <pc>: New field.
9941 (fork_save_infrun_state): Don't use regcache_dup.
9942 (info_checkpoints_command): Adjust.
9943 * mi/mi-main.c (register_changed_p): Update declaration.
9944 (mi_cmd_data_list_changed_registers): Use
9945 readonly_detached_regcache.
9946 (register_changed_p): Change parameter type to
9947 readonly_detached_regcache.
9948 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
9949 readonly_detached_regcache.
9950 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
9951 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
9952 New.
9953 (regcache::save): Move it to reg_buffer.
9954 (regcache::restore): Change parameter type.
9955 (regcache_dup): Remove.
9956 * regcache.h (reg_buffer) <save>: New method.
9957 (readonly_detached_regcache): New class.
9958 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
9959 readonly_detached_regcache.
9960 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
9961
fc5b8736
YQ
99622018-02-21 Yao Qi <yao.qi@linaro.org>
9963
9964 * frame.c (frame_save_as_regcache): Use regcache method save.
9965 (frame_pop): Use regcache method restore.
9966 * infrun.c (restore_infcall_suspend_state): Likewise.
9967 * linux-fork.c (fork_load_infrun_state): Likewise.
9968 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
9969 save.
9970 * regcache.c (regcache_save): Remove.
9971 (regcache::restore): More asserts.
9972 (regcache_cpy): Remove.
9973 * regcache.h (regcache_save): Remove the declaration.
9974 (regcache::restore): Move from private to public.
9975 Remove the friend declaration of regcache_cpy.
9976 (regcache_cpy): Remove declaration.
9977
849d0ba8
YQ
99782018-02-21 Yao Qi <yao.qi@linaro.org>
9979
9980 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
9981 parameter type to 'readable_regcache *'.
9982 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9983 * arm-tdep.c (arm_neon_quad_read): Likewise.
9984 (arm_pseudo_read): Likewise.
9985 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9986 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9987 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9988 * gdbarch.c: Re-generated.
9989 * gdbarch.h: Re-generated.
9990 * gdbarch.sh (pseudo_register_read): Change parameter type to
9991 'readable_regcache *'.
9992 (pseudo_register_read_value): Likewise.
9993 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
9994 (h8300_pseudo_register_read): Likewise.
9995 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
9996 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9997 (i386_pseudo_register_read_into_value): Likewise.
9998 (i386_pseudo_register_read_value): Likewise.
9999 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
10000 declaration.
10001 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
10002 * m32c-tdep.c (m32c_raw_read): Likewise.
10003 (m32c_read_flg): Likewise.
10004 (m32c_banked_register): Likewise.
10005 (m32c_banked_read): Likewise.
10006 (m32c_sb_read): Likewise.
10007 (m32c_part_read): Likewise.
10008 (m32c_cat_read): Likewise.
10009 (m32c_r3r2r1r0_read): Likewise.
10010 (m32c_pseudo_register_read): Likewise.
10011 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
10012 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
10013 (mep_pseudo_cr64_read): Likewise.
10014 (mep_pseudo_register_read): Likewise.
10015 * mips-tdep.c (mips_pseudo_register_read): Likewise.
10016 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
10017 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
10018 * regcache.c (regcache::raw_read): Move it to readable_regcache.
10019 (regcache::cooked_read): Likewise.
10020 (regcache::cooked_read_value): Likewise.
10021 (regcache_cooked_read_signed):
10022 (regcache::cooked_read): Likewise.
10023 * regcache.h (readable_regcache): New class.
10024 (regcache): Inherit readable_regcache. Move some methods to
10025 readable_regcache.
10026 * rl78-tdep.c (rl78_pseudo_register_read): Change
10027 parameter type to 'readable_regcache *'.
10028 * rs6000-tdep.c (do_regcache_raw_read): Remove.
10029 (e500_pseudo_register_read): Change parameter type to
10030 'readable_regcache *'.
10031 (dfp_pseudo_register_read): Likewise.
10032 (vsx_pseudo_register_read): Likewise.
10033 (efpr_pseudo_register_read): Likewise.
10034 * s390-tdep.c (s390_pseudo_register_read): Likewise.
10035 * sh-tdep.c (sh_pseudo_register_read): Likewise.
10036 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
10037 (sh64_pseudo_register_read): Likewise.
10038 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
10039 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
10040 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
10041 (spu_pseudo_register_read): Likewise.
10042 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
10043 (xtensa_pseudo_register_read): Likewise.
10044
31716595
YQ
100452018-02-21 Yao Qi <yao.qi@linaro.org>
10046
10047 * regcache.c (regcache::regcache): Call reg_buffer ctor.
10048 (regcache::arch): Move it to reg_buffer::arch.
10049 (regcache::register_buffer): Likewise.
10050 (regcache::assert_regnum): Likewise.
10051 (regcache::num_raw_registers): Likewise.
10052 * regcache.h (reg_buffer): New class.
10053 (regcache): Inherit reg_buffer.
10054
7104e59b
SM
100552018-02-20 Simon Marchi <simon.marchi@ericsson.com>
10056
10057 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
10058 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
10059
2d8adcbd
MM
100602018-02-20 Markus Metzger <markus.t.metzger@intel.com>
10061
10062 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
10063
b5884fa7
AH
100642018-02-19 Alan Hayward <alan.hayward@arm.com>
10065
10066 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
10067 (SFILES): Remove common/*.c files.
10068 (COMMON_OBS): Remove some *.o files built from common/*.c files.
10069 * common/common.host: Add common reference.
10070 * configure.ac: Likewise.
10071 * configure: Regenerate.
10072
fd90ace4
YQ
100732018-02-16 Yao Qi <yao.qi@linaro.org>
10074
10075 * block.c (block_namespace_info): Inherit allocate_on_obstack.
10076 (block_initialize_namespace): Use new.
10077 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
10078 (dwarf2_free_objfile): Use delete.
10079 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
10080 (copy_type_recursive): Use new.
10081 * gdb_obstack.h (allocate_on_obstack): New.
10082
85046ae2
YQ
100832018-02-15 Yao Qi <yao.qi@linaro.org>
10084
10085 PR gdb/22849
10086 * inferior.c (exit_inferior_1): Reset inf->control.
10087
355c559b
JB
100882018-02-15 Joel Brobecker <brobecker@adacore.com>
10089
10090 * ada-lang.c (ada_to_fixed_value_create): Delete advance
10091 declaration.
10092
980548fd
PA
100932018-02-14 Pedro Alves <palves@redhat.com>
10094
10095 * frame-unwind.c (frame_unwind_try_unwinder): Always call
10096 frame_cleanup_after_sniffer on exception.
10097
692d6f97
TT
100982018-02-14 Tom Tromey <tom@tromey.com>
10099
10100 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
10101 const.
10102 (solib_bfd_open): Make pathname const.
10103 * solib.c (solib_bfd_open): Make pathname const.
10104 * solib-spu.c (spu_bfd_fopen): Make name const.
10105 (spu_bfd_open): Make pathname const.
10106 * solib-darwin.c (darwin_bfd_open): Make pathname const.
10107 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
10108
e0cc99a6
TT
101092018-02-14 Tom Tromey <tom@tromey.com>
10110
10111 * symfile.c (symfile_bfd_open): Update.
10112 * source.h (openp, source_full_path_of, find_and_open_source):
10113 Change argument type to unique_xmalloc_ptr.
10114 * source.c (openp): Take a unique_xmalloc_ptr.
10115 (source_full_path_of, find_and_open_source): Likewise.
10116 (open_source_file, symtab_to_fullname): Update.
10117 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
10118 unique_xmalloc_ptr.
10119 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
10120 (exec_file_find): Update.
10121 * psymtab.c (psymtab_to_fullname): Update.
10122 * nto-tdep.h (nto_find_and_open_solib): Update.
10123 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
10124 unique_xmalloc_ptr.
10125 * exec.c (exec_file_attach): Update.
10126 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
10127 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
10128
b46a8d7c
TT
101292018-02-14 Tom Tromey <tom@tromey.com>
10130
10131 * solib.c: Include source.h.
10132 * nto-tdep.c: Include source.h.
10133 * mi/mi-cmd-env.c: Include source.h.
10134 * infcmd.c: Include source.h.
10135 * exec.c: Include source.h.
10136 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
10137 (add_path, directory_switch, source_path, init_source_path): Move
10138 declarations...
10139 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
10140 (add_path, directory_switch, source_path, init_source_path):
10141 ...here.
10142
797bc1cb
TT
101432018-02-14 Tom Tromey <tom@tromey.com>
10144
10145 * solist.h (exec_file_find, solib_find): Return
10146 unique_xmalloc_ptr.
10147 (solib_bfd_fopen): Take a const char *.
10148 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
10149 (exec_file_find, solib_find): Likewise.
10150 (solib_bfd_fopen): Do not take ownership of "pathname".
10151 (solib_bfd_open): Use unique_xmalloc_ptr.
10152 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
10153 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
10154 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
10155 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
10156
f98b2e33
JB
101572018-02-14 Joel Brobecker <brobecker@adacore.com>
10158
10159 * ada-lang.c (name_match_type_from_name): Remove reference to
10160 ada_name_for_lookup in function's documentation.
10161 * ada-lang.h (ada_name_for_lookup): Delete declaration.
10162
24b9144d
SM
101632018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
10164
10165 * defs.h (enum openp_flags): New enum.
10166 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
10167 Move to enum openp_flags.
10168 (openp_flags): New enum flags.
10169 (openp): Change parameter type to openp_flags.
10170 * source.c (openp): Change parameter type to openp_flags.
10171 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
10172 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
10173
387cd15b
SM
101742018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
10175
10176 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
10177 per-command.
10178
b303c6f6
AB
101792018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
10180
10181 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
10182 into...
10183 (class dwarf2_queue_guard): ...the destructor of this new class.
10184 (dw2_do_instantiate_symtab): Create instance of the new class
10185 dwarf2_queue_guard, remove cleanup.
10186
9c3630e9
TT
101872018-02-09 Tom Tromey <tom@tromey.com>
10188
10189 * source.c (find_source_lines): Don't reference past the end of
10190 the vector.
10191
c4e12631
MM
101922018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10193
10194 * remote.c (remote_btrace_maybe_reopen): Change error message.
10195 * btrace.c (btrace_enable): Likewise.
10196 (parse_xml_btrace): Likewise.
10197 (parse_xml_btrace_conf): Likewise.
10198
88711fbf
MM
101992018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10200
10201 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
10202 (linux_enable_pt, linux_enable_bts): Call
10203 diagnose_perf_event_open_fail.
10204
17ad2a4f
MM
102052018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10206
10207 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
10208 Remove parameter and change return type. Update callers. Move it.
10209 (linux_enable_bts, linux_enable_pt): Improve error message.
10210 (linux_enable_pt): Remove zero buffer size check.
10211 (linux_enable_btrace): Improve error messages. Remove NULL return
10212 check.
10213
de6242d3
MM
102142018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10215
10216 * btrace.c (btrace_enable): Remove target_supports_btrace call.
10217 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
10218 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
10219 (linux_supports_pt, linux_supports_btrace): Remove.
10220 (linux_enable_bts): Call cpu_supports_bts.
10221 * nat/linux-btrace.h (linux_supports_btrace): Remove.
10222 * remote.c (remote_supports_btrace): Remove.
10223 (init_remote_ops): Remove remote_supports_btrace.
10224 * target-delegates.c: Regenerated.
10225 * target.c (target_supports_btrace): Remove.
10226 * target.h (target_ops) <to_supports_btrace>: Remove
10227 (target_supports_btrace): Remove.
10228 * x86-linux-nat.c (x86_linux_create_target): Remove
10229 linux_supports_btrace.
10230
9ee23a85
MM
102312018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10232
10233 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
10234 btrace failed.
10235 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
10236 exception and use message in own exception.
10237
5c3284c1
MM
102382018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10239
10240 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
10241 (perf_event_pt_event_type): Use gdb_file_up.
10242 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
10243 scoped_fd, and scoped_mmap.
10244
84696f37
MM
102452018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10246
10247 * common/scoped_mmap.h: New.
10248 * unittests/scoped_mmap-selftest.c: New.
10249 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10250 unittests/scoped_mmap-selftest.c.
10251
ea4a0888
MM
102522018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10253
10254 * common/scoped_fd.h: New.
10255 * unittests/scoped_fd-selftest.c: New.
10256 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10257 unittests/scoped_fd-selftest.c.
10258
869e8290
TT
102592018-02-09 Tom Tromey <tom@tromey.com>
10260
10261 * auto-load.c (auto_load_section_scripts): Use
10262 gdb::unique_xmalloc_ptr.
10263
a37a2ae7
TT
102642018-02-09 Tom Tromey <tom@tromey.com>
10265
10266 * auto-load.c (execute_script_contents): Use std::string.
10267
4e725347
JB
102682018-02-09 Joel Brobecker <brobecker@adacore.com>
10269
10270 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
10271 Python function, rather than a new command.
10272
9a897d43
TT
102732018-02-08 Tom Tromey <tom@tromey.com>
10274
10275 * solib.c (solib_find_1): Use std::string.
10276 (solib_bfd_fopen): Use unique_xmalloc_ptr.
10277
58ef3771
TT
102782018-02-08 Tom Tromey <tom@tromey.com>
10279
10280 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
10281
a9abc434
TT
102822018-02-08 Tom Tromey <tom@tromey.com>
10283
10284 * source.c (find_source_lines): Use gdb::def_vector.
10285
84f27c6f
TT
102862018-02-08 Tom Tromey <tom@tromey.com>
10287
10288 * macrocmd.c (struct temporary_macro_definition): New.
10289 (macro_define_command): Use temporary_macro_definition. Remove
10290 cleanups.
10291 (free_macro_definition_ptr): Remove.
10292
0354904b
TT
102932018-02-08 Tom Tromey <tom@tromey.com>
10294
10295 * macroexp.c (maybe_expand): Use std::string.
10296
1739cf24
TT
102972018-02-08 Tom Tromey <tom@tromey.com>
10298
10299 * macroexp.c (struct macro_buffer): Add initializers for some
10300 members.
10301 (init_buffer, init_shared_buffer, free_buffer)
10302 (free_buffer_return_text): Remove.
10303 (macro_buffer): New constructors.
10304 (~macro_buffer): New destructor.
10305 (macro_buffer::set_shared): New method.
10306 (macro_buffer::resize_buffer, macro_buffer::appendc)
10307 (macro_buffer::appendmem): Now methods, not free functions.
10308 (set_token, append_tokens_without_splicing, stringify)
10309 (macro_stringify): Update.
10310 (gather_arguments): Change return type. Remove argc_p argument,
10311 add args_ptr argument. Use std::vector.
10312 (substitute_args): Remove argc argument. Accept std::vector.
10313 (expand): Update. Use std::vector.
10314 (scan, macro_expand, macro_expand_next): Update.
10315
f6c2623e
TT
103162018-02-08 Tom Tromey <tom@tromey.com>
10317
10318 * symtab.c (default_collect_symbol_completion_matches_break_on):
10319 Use unique_xmalloc_ptr.
10320 * macroscope.h: (sal_macro_scope, user_macro_scope)
10321 (default_macro_scope): Return unique_xmalloc_ptr.
10322 * macroscope.c (sal_macro_scope, user_macro_scope)
10323 (default_macro_scope): Return unique_xmalloc_ptr.
10324 * macroexp.h (macro_expand, macro_expand_once): Return
10325 unique_xmalloc_ptr.
10326 * macroexp.c (macro_expand, macro_expand_once): Return
10327 unique_xmalloc_ptr.
10328 * macrocmd.c (macro_expand_command, macro_expand_once_command)
10329 (info_macro_command, info_macros_command): Use
10330 unique_xmalloc_ptr.
10331 * compile/compile-c-support.c (write_macro_definitions): Use
10332 unique_xmalloc_ptr.
10333 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
10334
c2e0e465
SM
103352018-02-07 Simon Marchi <simon.marchi@ericsson.com>
10336
10337 * value.c (value_static_field): Assign field type instead of
10338 containing type when returning an optimized out value.
10339
3f8c94b4
YQ
103402018-02-06 Yao Qi <yao.qi@linaro.org>
10341
10342 * ft32-tdep.c (ft32_read_pc): Remove.
10343 (ft32_write_pc): Remove.
10344 (ft32_gdbarch_init): Update.
10345 * m32r-tdep.c (m32r_read_pc): Remove.
10346 (m32r_gdbarch_init): Update.
10347 * mep-tdep.c (mep_read_pc): Remove.
10348 (mep_gdbarch_init): Update.
10349 * microblaze-tdep.c (microblaze_write_pc): Remove.
10350 (microblaze_gdbarch_init): Update.
10351 * mn10300-tdep.c (mn10300_read_pc): Remove.
10352 (mn10300_write_pc): Remove.
10353 (mn10300_gdbarch_init): Update.
10354 * moxie-tdep.c (moxie_read_pc): Remove.
10355 (moxie_write_pc): Remove.
10356 (moxie_gdbarch_init): Update.
10357
bca65a23
YQ
103582018-02-06 Yao Qi <yao.qi@linaro.org>
10359
10360 * expprint.c (print_subexp_standard): Handle
10361 OP_F77_UNDETERMINED_ARGLIST.
10362 (dump_subexp_body_standard): Likewise.
10363
583e3f90 103642018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 10365
583e3f90
YQ
10366 * target-descriptions.c (tdesc_element_visitor) Add empty
10367 implementations.
b8df6ca7
AH
10368 (tdesc_type): Move make_gdb_type from here.
10369 (tdesc_type_builtin): Likewise.
10370 (tdesc_type_vector): Likewise.
10371 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
10372 (make_gdb_type_struct): Move from tdesc_type_with_fields.
10373 (make_gdb_type_union): Likewise.
10374 (make_gdb_type_flags): Likewise.
10375 (make_gdb_type_enum): Likewise.
10376 (make_gdb_type): New function.
10377 (tdesc_register_type): Use static make_gdb_type.
10378
e813d34a
RK
103792018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
10380
10381 * infcmd.c (default_print_one_register_info): Align natural-format
10382 column values consistently one under another.
10383 (pad_to_column): New function.
10384
0eb876f5
JB
103852018-02-05 Joel Brobecker <brobecker@adacore.com>
10386
10387 * dwarf2read.c (dwarf2_physname): Move commment.
10388
0625771b
LS
103892018-02-01 Leszek Swirski <leszeks@google.com>
10390
10391 * varobj.c (varobj_formatted_print_options): Allow recursive
10392 pretty printing if pretty printing is enabled.
10393
59498c30
LS
103942018-02-01 Leszek Swirski <leszeks@google.com>
10395
10396 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
10397 names after a structop as a filename.
10398
2d9e6acb
YQ
103992018-02-01 Yao Qi <yao.qi@linaro.org>
10400
10401 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
10402 (arm_record_coproc_data_proc): Likewise.
10403
df95a9cf
YQ
104042018-02-01 Yao Qi <yao.qi@linaro.org>
10405
10406 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
10407
07e5f5cf
NP
104082018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
10409
10410 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
10411 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
10412
3045b475
PA
104132018-01-31 Pedro Alves <palves@redhat.com>
10414
10415 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
10416 * inflow.c (child_terminal_save_inferior): Wrap reference to
10417 tcgetpgrp in HAVE_TERMIOS_H.
10418 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
10419 _WIN32.
10420 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
10421 always iterate over all inferiors.
10422 (gdbsim_cntrl_c): Adjust.
10423 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
10424
929b5ad4
JB
104252018-01-31 Joel Brobecker <brobecker@adacore.com>
10426
10427 * gdbtypes.c (lookup_array_range_type): Make sure the array's
10428 index type is objfile-owned if the element type is as well.
10429
29236ca2
JB
104302018-01-31 Joel Brobecker <brobecker@adacore.com>
10431
10432 GDB 8.1 released.
10433
c81e8879
PR
104342018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
10435
10436 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
10437 "features/s390x-linux64.c".
10438 (_initialize_s390_linux_tdep): Remove initialization of tdescs
10439 s390_linux32 and s390x_linux64.
10440 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
10441 default tdesc.
10442 * s390-tdep.c: Include "features/s390-linux32.c" and
10443 "features/s390x-linux64.c".
10444 (s390_tdesc_valid): Add check for tdesc_has_registers.
10445 (s390_gdbarch_init): Make sure there is always a valid tdesc.
10446 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
10447 tdesc_s390x_linux64.
10448 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
10449 tdesc_s390x_linux64 to...
10450 * s390-tdep.h: ...here.
10451
e671cd59
PA
104522018-01-30 Pedro Alves <palves@redhat.com>
10453
10454 PR gdb/13211
10455 * config.in, configure: Regenerate.
10456 * configure.ac: Check for getpgid.
10457 * go32-nat.c (go32_pass_ctrlc): New.
10458 (go32_target): Install it.
10459 * inf-child.c (inf_child_target): Install
10460 child_terminal_save_inferior, child_pass_ctrlc and
10461 child_interrupt.
10462 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
10463 (inf_ptrace_target): No longer install it.
10464 * infcmd.c (interrupt_target_1): Adjust.
10465 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
10466 (child_interrupt): Declare.
10467 (inferior::terminal_state): New.
10468 * inflow.c (struct terminal_info): Update comments.
10469 (inferior_process_group): Delete.
10470 (terminal_is_ours): Delete.
10471 (gdb_tty_state): New.
10472 (child_terminal_init): Adjust.
10473 (is_gdb_terminal, sharing_input_terminal_1)
10474 (sharing_input_terminal): New functions.
10475 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
10476 Set the process's actual process group in the foreground if
10477 possible. Handle is_ours_for_output/is_ours distinction. Don't
10478 mark terminal as the inferior's if not sharing GDB's terminal.
10479 Don't check attach_flag.
10480 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
10481 pass down a target_terminal_state.
10482 (child_terminal_save_inferior): New, factored out from ...
10483 (child_terminal_ours_1): ... this. Handle
10484 target_terminal_state::is_ours_for_output.
10485 (child_interrupt, child_pass_ctrlc): New.
10486 (inflow_inferior_exit): Clear the inferior's terminal_state.
10487 (copy_terminal_info): Copy the inferior's terminal state.
10488 (_initialize_inflow): Remove reference to terminal_is_ours.
10489 * inflow.h (inferior_process_group): Delete.
10490 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
10491 * procfs.c (procfs_target): Don't install procfs_interrupt.
10492 (procfs_interrupt): Delete.
10493 * remote.c (remote_serial_quit_handler): Adjust.
10494 (remote_interrupt): Remove ptid parameter. Adjust.
10495 * target-delegates.c: Regenerate.
10496 * target.c: Include "terminal.h".
10497 (target_terminal::terminal_state): Rename to ...
10498 (target_terminal::m_terminal_state): ... this.
10499 (target_terminal::init): Adjust.
10500 (target_terminal::inferior): Adjust to per-inferior
10501 terminal_state.
10502 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
10503 (target_terminal::ours, target_terminal::ours_for_output): Use
10504 target_terminal_is_ours_kind.
10505 (target_interrupt): Remove ptid parameter. Adjust.
10506 (default_target_pass_ctrlc): Adjust.
10507 * target.h (target_ops::to_terminal_save_inferior): New field.
10508 (target_ops::to_interrupt): Remove ptid_t parameter.
10509 (target_interrupt): Remove ptid_t parameter. Update comment.
10510 (target_pass_ctrlc): Update comment.
10511 * target/target.h (target_terminal_state): New scoped enum,
10512 factored out of ...
10513 (target_terminal::terminal_state): ... here.
10514 (target_terminal::inferior): Update comments.
10515 (target_terminal::restore_inferior): New.
10516 (target_terminal::is_inferior, target_terminal::is_ours)
10517 (target_terminal::is_ours_for_output): Adjust.
10518 (target_terminal::scoped_restore_terminal_state): Adjust to
10519 rename, and call restore_inferior() instead of inferior().
10520 (target_terminal::scoped_restore_terminal_state::m_state): Change
10521 type.
10522 (target_terminal::terminal_state): Rename to ...
10523 (target_terminal::m_terminal_state): ... this and change type.
10524
9c3a5d93
PA
105252018-01-30 Pedro Alves <palves@redhat.com>
10526
10527 * linux-nat.c (wait_for_signal): New function.
10528 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
10529 directly.
10530 (async_terminal_is_ours)
10531 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
10532 (linux_nat_add_target): Don't override
10533 to_terminal_inferior/to_terminal_ours.
10534
69ab5edb
SDJ
105352018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
10536
10537 * remote.c (remote_follow_fork): Don't call "detach_inferior".
10538
fc8e7e75
SM
105392018-01-28 Simon Marchi <simon.marchi@ericsson.com>
10540
10541 * dwarf2read.c (free_dwo_files): Add forward-declaration.
10542 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
10543 dwarf2_per_objfile_free here.
10544 (dwarf2_per_objfile_free): Remove.
10545 (_initialize_dwarf2_read): Don't register
10546 dwarf2_per_objfile_free as a registry cleanup.
10547
b2a426e2
EZ
105482018-01-27 Eli Zaretskii <eliz@gnu.org>
10549
10550 Avoid compilation errors in MinGW native builds
10551
10552 The error is triggered by including python-internal.h, and the
10553 error message is:
10554
10555 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
10556 from build-gnulib/import/math.h:27,
10557 from d:/usr/Python26/include/pyport.h:235,
10558 from d:/usr/Python26/include/Python.h:58,
10559 from python/python-internal.h:94,
10560 from python/py-arch.c:24:
10561 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
10562 using ::hypot;
10563 ^~~~~
10564
10565 This happens because Python headers define 'hypot' to expand t
10566 '_hypot' in the Windows builds.
10567 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
10568 'hypoth'. This avoids a compilation error.
10569
0bdd8eac
AH
105702018-01-26 Alan Hayward <alan.hayward@arm.com>
10571
10572 * MAINTAINERS (Write After Approval): Fix ordering.
10573
56ae9dc3
AH
105742018-01-26 Alan Hayward <alan.hayward@arm.com>
10575
10576 * MAINTAINERS (Write After Approval): Add Alan Hayward.
10577
7433498b
AM
105782018-01-26 Alan Modra <amodra@gmail.com>
10579
10580 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
10581 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
10582 Remove nop. Make const. Comment.
10583 (powerpc32_plt_stub_so_2): New.
10584 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
10585 Correct count. Update uses.
10586 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
10587 Move common code reading PLT entry word. Correct
10588 powerpc32_plt_stub PLT address calculation.
10589 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
10590 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
10591 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
10592 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
10593 (ppc64_standard_linkage8): Likewise.
10594 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
10595 Correct insns description.
10596 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
10597
0f59d5fc
PA
105982018-01-24 Pedro Alves <palves@redhat.com>
10599
10600 GCC PR libstdc++/83906
10601 * gdbtypes.c (operator==(const dynamic_prop &,
10602 const dynamic_prop &)): New.
10603 (operator==(const range_bounds &, const range_bounds &)): New.
10604 (check_types_equal): Use them instead of memcmp.
10605 * gdbtypes.h (operator==(const dynamic_prop &,
10606 const dynamic_prop &)): Declare.
10607 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
10608 (operator==(const range_bounds &, const range_bounds &)): Declare.
10609 (operator!=(const range_bounds &, const range_bounds &)): Declare.
10610
ef8914a4
PR
106112018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10612
10613 * s390-linux-tdep.c (s390_record_address_mask)
10614 (s390_record_calc_disp_common, s390_record_calc_disp)
10615 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10616 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10617 (s390_process_record): Move to s390-tdep.c.
10618 (s390_linux_init_abi_any): Adjust.
10619 * s390-tdep.c (s390_record_address_mask)
10620 (s390_record_calc_disp_common, s390_record_calc_disp)
10621 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10622 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10623 (s390_process_record): Moved from s390-linux-tdep.c
10624 (s390_gdbarch_init): Adjust.
10625
d6e58945
PR
106262018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10627
10628 * s390-linux-nat.c (s390-tdep.h): New include.
10629 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
10630 (HFILES_NO_SRCDIR): Add s390-tdep.h.
10631 (ALLDEPFILES): Add s390-tdep.c.
10632 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
10633 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
10634 * s390-tdep.h: ...this. New file.
10635 * s390-linux-tdep.c (s390-tdep.h): New include.
10636 (_initialize_s390_tdep): Rename to...
10637 (_initialize_s390_linux_tdep): ...this and adjust.
10638 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
10639 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
10640 s390-tdep.h.
10641 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
10642 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
10643 (s390_is_partial_instruction, s390_software_single_step)
10644 (is_non_branch_ril, s390_displaced_step_copy_insn)
10645 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
10646 (s390_prologue_data, s390_addr, s390_store, s390_load)
10647 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
10648 (s390_register_call_saved, s390_guess_tracepoint_registers)
10649 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
10650 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
10651 (s390_pseudo_register_name, s390_pseudo_register_type)
10652 (s390_pseudo_register_read, s390_pseudo_register_write)
10653 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
10654 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
10655 (s390_addr_bits_remove, s390_address_class_type_flags)
10656 (s390_address_class_type_flags_to_name)
10657 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
10658 (s390_function_arg_float, s390_function_arg_vector)
10659 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
10660 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
10661 (s390_frame_align, s390_register_return_value, s390_return_value)
10662 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
10663 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
10664 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
10665 (s390_trad_frame_prev_register, s390_unwind_cache)
10666 (s390_prologue_frame_unwind_cache)
10667 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
10668 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
10669 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
10670 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
10671 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
10672 (s390_frame_base_address, s390_local_base_address)
10673 (s390_frame_base, s390_gcc_target_options)
10674 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
10675 (s390_validate_reg_range, s390_tdesc_valid)
10676 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
10677 * s390-tdep.c: ...this. New file.
10678
9c0b896e
PR
106792018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10680
10681 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
10682 (s390_process_record, s390_gdbarch_tdep_alloc)
10683 (s390_linux_init_abi_any): Use/set new hook.
10684
7042632b
PR
106852018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10686
10687 * s390-linux-tdep.c (osabi.h): New include.
10688 (s390_linux_init_abi_31, s390_linux_init_abi_64)
10689 (s390_linux_init_abi_any): New functions.
10690 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
10691
650f5e13
PR
106922018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10693
10694 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
10695 tdesc_has_registers check
10696
47c9317e
PR
106972018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10698
10699 * s390-linux-tdep.c (s390_tdesc_valid): New function.
10700 (s390_validate_reg_range): New macro.
10701 (s390_gdbarch_init): Adjust.
10702
095085d8
PR
107032018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10704
10705 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
10706 (s390_gdbarch_tdep_alloc): Adjust.
10707 (s390_gdbarch_init): Adjust.
10708
ab9bcc67
PR
107092018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10710
10711 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
10712 <have_tdb>: Change type to bool.
10713 (s390_gdbarch_tdep_alloc): Adjust.
10714 (s390_gdbarch_init): Adjust.
10715
21f6f5ff
PR
107162018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10717
10718 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
10719 (gdbarch_tdep) <have_upper, have_vx>: New fields.
10720 (s390_gdbarch_tdep_alloc): New function.
10721 (s390_gdbarch_init): Allocate tdep at start and use its fields
10722 instead of separate variables.
10723
0eb97953
PR
107242018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10725
10726 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
10727 when looking for cached gdbarch and add comment for remaining.
10728
5c319bb2
PA
107292018-01-22 Pedro Alves <palves@redhat.com>
10730 Sergio Durigan Junior <sergiodj@redhat.com>
10731
10732 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
10733 case.
10734
d65ce302
MR
107352018-01-22 Maciej W. Rozycki <macro@mips.com>
10736
10737 * MAINTAINERS: Update my company e-mail address.
10738
ec7a5fcb
YQ
107392018-01-22 Yao Qi <yao.qi@linaro.org>
10740
10741 * regcache.c (cooked_write_test): New function.
10742 (_initialize_regcache): Register the test.
10743
11f57cb6
YQ
107442018-01-22 Yao Qi <yao.qi@linaro.org>
10745
10746 * ia64-tdep.c (ia64_pseudo_register_read): Call
10747 regcache->cooked_read instead of regcache_cooked_read_unsigned.
10748 * m32c-tdep.c (m32c_cat_read): Likewise.
10749 (m32c_r3r2r1r0_read): Likewise.
10750 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
10751 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
10752
03f50fc8
YQ
107532018-01-22 Yao Qi <yao.qi@linaro.org>
10754
10755 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
10756 method raw_read instead of regcache_raw_read.
10757 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
10758 * arm-tdep.c (arm_neon_quad_read): Likewise.
10759 * avr-tdep.c (avr_pseudo_register_read): Likewise.
10760 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
10761 * frv-tdep.c (frv_pseudo_register_read): Likewise.
10762 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
10763 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
10764 (i386_pseudo_register_read_into_value): Likewise.
10765 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
10766 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
10767 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
10768 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
10769 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
10770 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
10771 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
10772 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
10773 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
10774
dc711524
YQ
107752018-01-22 Yao Qi <yao.qi@linaro.org>
10776
10777 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
10778 * configure.tgt: Remove target mt.
10779 * mt-tdep.c: Remove.
10780 * regcache.c (cooked_read_test): Remove the check for mt.
10781
3f5a868b
YQ
107822018-01-22 Yao Qi <yao.qi@linaro.org>
10783
10784 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
10785 instead of gdbarch_pseudo_register_read_value.
10786
de4cb04a
JB
107872018-01-22 Joel Brobecker <brobecker@adacore.com>
10788
10789 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
10790 language is Ada.
10791
a9e40818
JB
107922018-01-22 Joel Brobecker <brobecker@adacore.com>
10793
10794 * linespec.c (create_sals_line_offset): Remove code that preserved
10795 the symtab_and_line's line number.
10796
e707fc44
AB
107972018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10798
10799 * varobj.c (varobj_create): Don't set valid_block when creating a
10800 floating varobj.
10801
03d0bf7b
AB
108022018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10803
10804 * varobj.c (varobj_create): Remove out of date comment.
10805
ae451627
AB
108062018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10807
10808 PR mi/20395
10809 * ada-exp.y (write_var_from_sym): Pass extra parameter when
10810 updating innermost block.
10811 * parse.c (innermost_block_tracker::update): Take extra type
10812 parameter, and check types match before updating innermost block.
10813 (write_dollar_variable): Update innermost block for registers.
10814 * parser-defs.h (enum innermost_block_tracker_type): New enum.
10815 (innermost_block_tracker::innermost_block_tracker): Initialise
10816 m_types member.
10817 (innermost_block_tracker::reset): Take type parameter.
10818 (innermost_block_tracker::update): Take type parameter, and pass
10819 type through as needed.
10820 (innermost_block_tracker::m_types): New member.
10821 * varobj.c (varobj_create): Pass type when reseting innermost
10822 block.
10823
aee1fcdf
AB
108242018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10825
10826 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
10827 * ada-lang.c (resolve_subexp): Likewise.
10828 * breakpoint.c (set_breakpoint_condition) Likewise.
10829 (watch_command_1) Likewise.
10830 * c-exp.y (variable): Likewise.
10831 * d-exp.y (PrimaryExpression): Likewise.
10832 * f-exp.y (variable): Likewise.
10833 * go-exp.y (variable): Likewise.
10834 * m2-exp.y (variable): Likewise.
10835 * objfiles.c (objfile::~objfile): Likewise.
10836 * p-exp.y (variable): Likewise.
10837 * parse.c (innermost_block): Change type.
10838 * parser-defs.h (class innermost_block_tracker): New.
10839 (innermost_block): Change to innermost_block_tracker.
10840 * printcmd.c (display_command): Switch to innermost_block API.
10841 (do_one_display): Likewise.
10842 * rust-exp.y (do_one_display): Likewise.
10843 * symfile.c (clear_symtab_users): Likewise.
10844 * varobj.c (varobj_create): Switch to innermost_block API, replace
10845 use of innermost_block with block stored on varobj object.
10846
396af9a1
AB
108472018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10848
10849 * expression.h (innermost_block): Remove declaration.
10850 * varobj.c: Add 'parser-defs.h' include.
10851
fcfcc376
TT
108522018-01-19 Tom Tromey <tom@tromey.com>
10853
10854 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
10855 symbols in the static and global blocks.
10856
5a6c3296
JC
108572018-01-19 James Clarke <jrtc27@jrtc27.com>
10858
10859 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
10860 gdb_ptrace.h, and move including gdb_wait.h ...
10861 * nat/linux-ptrace.h: ... to here.
10862
bc09b0c1
SM
108632018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10864
10865 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
10866 inf_ptrace_detach_success.
10867 (inf_ptrace_detach_success): Add inferior parameter, use it
10868 instead of inferior_ptid, pass it to detach_inferior.
10869 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
10870 parameter.
10871 * inferior.c (detach_inferior): Add overload that takes an
10872 inferior object.
10873 * inferior.h (detach_inferior): Likewise.
10874 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
10875 use inferior_ptid, adjust call to inf_ptrace_detach_success.
10876 * linux-thread-db.c (thread_db_detach): Use inf parameter.
10877
6e1e1966
SM
108782018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10879
10880 * target.h (struct target_ops) <to_detach>: Add inferior
10881 parameter.
10882 (target_detach): Likewise.
10883 * target.c (dispose_inferior): Pass inferior down.
10884 (target_detach): Pass inferior down. Assert that it is equal to
10885 the current inferior.
10886 * aix-thread.c (aix_thread_detach): Pass inferior down.
10887 * corefile.c (core_file_command): Pass current_inferior() down.
10888 * corelow.c (core_detach): Add inferior parameter.
10889 * darwin-nat.c (darwin_detach): Likewise.
10890 * gnu-nat.c (gnu_detach): Likewise.
10891 * inf-ptrace.c (inf_ptrace_detach): Likewise.
10892 * infcmd.c (detach_command): Pass current_inferior() down to
10893 target_detach.
10894 * infrun.c (follow_fork_inferior): Pass parent_inf to
10895 target_detach.
10896 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
10897 target_detach.
10898 * linux-nat.c (linux_nat_detach): Add inferior parameter.
10899 * linux-thread-db.c (thread_db_detach): Likewise.
10900 * nto-procfs.c (procfs_detach): Likewise.
10901 * procfs.c (procfs_detach): Likewise.
10902 * record.c (record_detach): Likewise.
10903 * record.h (struct inferior): Forward-declare.
10904 (record_detach): Add inferior parameter.
10905 * remote-sim.c (gdbsim_detach): Likewise.
10906 * remote.c (remote_detach_1): Likewise.
10907 (remote_detach): Likewise.
10908 (extended_remote_detach): Likewise.
10909 * sol-thread.c (sol_thread_detach): Likewise.
10910 * target-debug.h (target_debug_print_inferior_p): New macro.
10911 * target-delegates.c: Re-generate.
10912 * top.c (kill_or_detach): Pass inferior down to target_detach.
10913 * windows-nat.c (windows_detach): Add inferior parameter.
10914
6bd6f3b6
SM
109152018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10916
10917 * target.h (struct target_ops) <to_detach>: Remove args
10918 parameter.
10919 (target_detach): Likewise.
10920 * target.c (dispose_inferior): Adjust.
10921 (target_detach): Remove args parameter, adjust.
10922 * aix-thread.c (aix_thread_detach): Adjust.
10923 * corefile.c (core_file_command): Adjust.
10924 * corelow.c (core_detach): Adjust.
10925 * darwin-nat.c (darwin_detach): Adjust.
10926 * gnu-nat.c (gnu_detach): Adjust.
10927 * inf-ptrace.c (inf_ptrace_detach): Adjust.
10928 * infcmd.c (detach_command): Adjust
10929 * infrun.c (follow_fork_inferior): Adjust.
10930 (handle_vfork_child_exec_or_exit): Adjust.
10931 * linux-fork.c (linux_fork_detach): Remove args parameter.
10932 * linux-fork.h (linux_fork_detach): Likewise.
10933 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
10934 * linux-thread-db.c (thread_db_detach): Likewise.
10935 * nto-procfs.c (procfs_detach): Likewise.
10936 * procfs.c (procfs_detach): Likewise.
10937 (do_detach): Remove signo parameter.
10938 * record.c (record_detach): Remove args parameter.
10939 * record.h (record_detach): Likewise.
10940 * remote-sim.c (gdbsim_detach): Likewise.
10941 * remote.c (remote_detach_1): Likewise.
10942 (remote_detach): Likewise.
10943 (extended_remote_detach): Likewise.
10944 * sol-thread.c (sol_thread_detach): Likewise.
10945 * target-delegates.c: Re-generate.
10946 * top.c (struct qt_args) <args>: Remove field.
10947 (kill_or_detach): Don't pass args.
10948 (quit_force): Don't set args.
10949 * windows-nat.c (windows_detach): Remove args parameter.
10950
88af8ea8
YQ
109512018-01-19 Yao Qi <yao.qi@linaro.org>
10952
10953 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
10954 (arm_linux_init_abi): Install it.
10955
dea445b9
YQ
109562018-01-19 Yao Qi <yao.qi@linaro.org>
10957
10958 * osabi.c (gdb_osabi_names): Extend the regexp for
10959 arm-linux-gnueabihf.
10960
4a17f768
YQ
109612018-01-18 Yao Qi <yao.qi@linaro.org>
10962
10963 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
10964 m_abbrevs.
10965 (abbrev_table::add_abbrev): Update.
10966 (abbrev_table::lookup_abbrev): Update.
10967
d679c21a
YQ
109682018-01-18 Yao Qi <yao.qi@linaro.org>
10969
10970 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
10971
7d937cad
SDJ
109722018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
10973
10974 * compile/compile.c (compile_to_object): Convert "triplet_rx"
10975 to "std::string".
10976
9e14690d
TT
109772018-01-17 Tom Tromey <tom@tromey.com>
10978
10979 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
10980
50a82047
TT
109812018-01-17 Tom Tromey <tom@tromey.com>
10982
10983 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
10984 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
10985 (create_array_type_with_stride): Update.
10986 * dwarf2read.c (set_die_type): Update.
10987
c89b44cd
TT
109882018-01-17 Tom Tromey <tom@tromey.com>
10989
10990 * dwarf2read.c (delayed_method_info): Remove typedef.
10991 (dwarf2_cu::method_info): Now a std::vector.
10992 (add_to_method_list): Update.
10993 (free_delayed_list): Remove.
10994 (compute_delayed_physnames): Update.
10995 (process_full_comp_unit, process_full_type_unit): Clear the method
10996 list. Remove cleanups.
10997 (psymtab_include_file_name): Add name_holder parameter. Use
10998 unique_xmalloc_ptr.
10999 (dwarf_decode_lines): Update.
11000
fcd3b13d
SM
110012018-01-17 Tom Tromey <tom@tromey.com>
11002 Simon Marchi <simon.marchi@ericsson.com>
11003
11004 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
11005 (dwarf2_per_objfile::free_cached_comp_units)
11006 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
11007 (init_cutu_and_read_dies_no_follow): Update.
11008 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
11009 (dwarf2_cu::~dwarf2_cu): New.
11010 (free_heap_comp_unit, free_stack_comp_unit): Remove.
11011 (age_cached_comp_units, free_one_cached_comp_unit): Update.
11012
685af9cd
TT
110132018-01-17 Tom Tromey <tom@tromey.com>
11014 Simon Marchi <simon.marchi@ericsson.com>
11015
11016 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
11017 (struct die_reader_specs) <abbrev_table>: New member.
11018 (struct abbrev_table): Add constructor.
11019 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
11020 <abbrev_obstack>: Now an auto_obstack.
11021 (abbrev_table_up): New typedef.
11022 (init_cu_die_reader): Add abbrev_table parameter.
11023 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
11024 Add result_dwo_abbrev_table.
11025 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
11026 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
11027 Update.
11028 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
11029 parameter.
11030 (skip_children): Update.
11031 (abbrev_table::alloc_abbrev): Rename from
11032 abbrev_table_alloc_abbrev.
11033 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
11034 (abbrev_table::lookup_abbrev): Rename from
11035 abbrev_table_lookup_abbrev.
11036 (abbrev_table_read_table): Return abbrev_table_up.
11037 (abbrev_table_free, abbrev_table_free_cleanup)
11038 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
11039 (load_partial_dies): Update.
11040
5e2db402
TT
110412018-01-17 Tom Tromey <tom@tromey.com>
11042
11043 * dwarf2read.c (dwarf2_compute_name): Update comment.
11044 (read_func_scope, read_variable): Update.
11045 (new_symbol): Remove.
11046 (new_symbol_full): Rename to new_symbol.
11047
ee7f689e 110482018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
11049
11050 PR gdb/16577
11051 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
11052 a warning instead of throwing an error, set section size to 0 and return
11053 NULL.
11054 * gdb_bfd.h (gdb_bfd_map_section): Update description.
11055
4d9b86e1
SM
110562018-01-17 Simon Marchi <simon.marchi@ericsson.com>
11057
11058 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
11059 std::string.
11060 (linux_ptrace_attach_fail_reason_string): Likewise.
11061 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
11062 Likewise.
11063 (linux_ptrace_attach_fail_reason_string): Likewise.
11064 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
11065
a7b2d0fb
SM
110662018-01-17 Simon Marchi <simon.marchi@ericsson.com>
11067
11068 * linux-nat.c (linux_nat_attach): Remove xstrdup.
11069
f517c180
EA
110702018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
11071
11072 PR gdb/21559
11073 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
11074 checking for fs_base/gs_base fields in struct user_regs_struct.
11075 * configure: Regenerate.
11076
7045b1ca
YQ
110772018-01-17 Yao Qi <yao.qi@linaro.org>
11078
11079 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
11080 function.
11081 (aarch64_linux_init_abi): Install it to gdbarch hook
11082 gcc_target_options.
11083
db422fb2
PA
110842018-01-15 Pedro Alves <palves@redhat.com>
11085
11086 * common/signals-state-save-restore.c
11087 (save_original_signals_state): Fix typos.
11088
ba643918
SDJ
110892017-01-12 Tom Tromey <tom@tromey.com>
11090 Sergio Durigan Junior <sergiodj@redhat.com>
11091
11092 * Makefile.in (install-only): Install gdb-add-index.
11093
906b4aac
JB
110942018-01-12 John Baldwin <jhb@FreeBSD.org>
11095
11096 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
11097
bdf2a94a
AA
110982018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11099
11100 * infrun.c (keep_going_pass_signal): Clear step-over info when
11101 insert_breakpoints fails.
11102
71d378ae
PA
111032018-01-11 Pedro Alves <palves@redhat.com>
11104
11105 PR gdb/22583
11106 * infrun.c (resume): Rename to ...
11107 (resume_1): ... this.
11108 (resume): Reimplement as wrapper around resume_1.
11109
3cada740
PA
111102018-01-11 Pedro Alves <palves@redhat.com>
11111
11112 PR remote/22597
11113 * remote.c (remote_parse_stop_reply): Default to the last-set
11114 general thread instead of to 'magic_null_ptid'.
11115
618daa93
PA
111162018-01-10 Pedro Alves <palves@redhat.com>
11117
11118 * language.h (language_get_symbol_name_matcher): Rename ...
11119 (get_symbol_name_matcher): ... this.
11120 * language.c (language_get_symbol_name_matcher): Ditto.
11121 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
11122 callers adjusted.
11123
c63d3e8d
PA
111242018-01-10 Pedro Alves <palves@redhat.com>
11125
11126 PR gdb/22670
11127 * dwarf2read.c
11128 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
11129 Adjust to use language_get_symbol_name_matcher instead of
11130 language_defn::la_get_symbol_name_matcher.
11131 * language.c (language_get_symbol_name_matcher): If in Ada mode
11132 and the lookup name is a verbatim match, return Ada's matcher.
11133 * language.h (language_get_symbol_name_matcher): Adjust comment.
11134 (ada_lookup_name_info::verbatim_p):: New method.
11135
d4c2a405
PA
111362018-01-10 Pedro Alves <palves@redhat.com>
11137
11138 PR gdb/22670
11139 * ada-lang.c (ada_collect_symbol_completion_matches): If the
11140 minsym's language is language_auto or language_cplus, pass down
11141 language_ada instead.
11142 * symtab.c (compare_symbol_name): Don't frob symbol language here.
11143
8825213e
PA
111442018-01-10 Pedro Alves <palves@redhat.com>
11145
11146 PR gdb/22670
11147 * minsyms.c (linkage_name_str): New function.
11148 (iterate_over_minimal_symbols): Use it.
11149
2d97a5d9
JB
111502018-01-09 John Baldwin <jhb@FreeBSD.org>
11151
11152 * NEWS: Document that 'info proc' now works on FreeBSD.
11153
92fce24d
JB
111542018-01-09 John Baldwin <jhb@FreeBSD.org>
11155
11156 * configure.ac: Check for kinfo_getfile in libutil.
11157 * configure: Regenerate.
11158 * config.in: Regenerate.
11159 * fbsd-nat.c: Include "fbsd-tdep.h".
11160 (fbsd_fetch_cmdline): New.
11161 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
11162 rather than calling error.
11163 (fbsd_info_proc): New.
11164 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
11165 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
11166 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
11167
262f62f5
JB
111682018-01-09 John Baldwin <jhb@FreeBSD.org>
11169
11170 * fbsd-nat.c (struct free_deleter): Remove.
11171 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
11172
b999e203
JB
111732018-01-09 John Baldwin <jhb@FreeBSD.org>
11174
11175 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
11176 NULL for an empty pathname.
11177
d2176225
JB
111782018-01-09 John Baldwin <jhb@FreeBSD.org>
11179
11180 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
11181 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
11182 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
11183 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
11184 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
11185 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
11186 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
11187 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
11188 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
11189 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
11190 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
11191 (fbsd_core_fetch_timeval, fbsd_print_sigset)
11192 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
11193 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
11194 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
11195
9c4ac400
ST
111962018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
11197
11198 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
11199 (gnu_xfer_auxv): New function.
11200 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
11201 TARGET_OBJECT_AUXV.
11202
1e5ded6c
YQ
112032018-01-08 Yao Qi <yao.qi@linaro.org>
11204 Simon Marchi <simon.marchi@ericsson.com>
11205
11206 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
11207 common/selftest.c.
11208 (COMMON_OBS): Remove selftest.o.
11209 * configure.ac: Append selftest-arch.c and common/selftest.c to
11210 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
11211 * configure: Re-generated.
11212 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
11213 GDB_SELF_TEST.
11214 (maintenance_info_selftests): Likewise.
11215
04bafb1e
XR
112162018-01-08 Xavier Roirand <roirand@adacore.com>
11217
11218 * ada-valprint.c (val_print_packed_array_elements): Use
11219 proper number of elements when printing an array indexed
11220 by an enumeration type.
11221
518817b3
SM
112222018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11223
11224 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
11225 (dw2_get_file_names_reader): Adjust.
11226 (lookup_dwo_signatured_type): Adjust.
11227 (lookup_dwp_signatured_type): Adjust.
11228 (lookup_signatured_type): Adjust.
11229 (create_type_unit_group): Adjust.
11230 (get_type_unit_group): Adjust.
11231 (process_psymtab_comp_unit_reader): Adjust.
11232 (build_type_psymtabs_reader): Adjust.
11233 (scan_partial_symbols): Adjust.
11234 (add_partial_symbol): Adjust.
11235 (add_partial_subprogram): Adjust.
11236 (peek_die_abbrev): Adjust.
11237 (fixup_go_packaging): Adjust.
11238 (process_imported_unit_die): Adjust.
11239 (dwarf2_compute_name): Adjust.
11240 (dwarf2_physname): Adjust.
11241 (read_import_statement): Adjust.
11242 (handle_DW_AT_stmt_list): Adjust.
11243 (read_file_scope): Adjust.
11244 (read_func_scope): Adjust.
11245 (read_lexical_block_scope): Adjust.
11246 (read_call_site_scope): Adjust.
11247 (read_variable): Adjust.
11248 (dwarf2_rnglists_process): Adjust.
11249 (dwarf2_ranges_process): Adjust.
11250 (dwarf2_ranges_read): Adjust.
11251 (dwarf2_get_pc_bounds): Adjust.
11252 (dwarf2_record_block_ranges): Adjust.
11253 (dwarf2_add_field): Adjust.
11254 (dwarf2_add_member_fn): Adjust.
11255 (read_structure_type): Adjust.
11256 (process_structure_scope): Adjust.
11257 (read_enumeration_type): Adjust.
11258 (read_array_type): Adjust.
11259 (mark_common_block_symbol_computed): Adjust.
11260 (read_common_block): Adjust.
11261 (read_namespace_type): Adjust.
11262 (read_namespace): Adjust.
11263 (read_module_type): Adjust.
11264 (read_tag_pointer_type): Adjust.
11265 (read_tag_ptr_to_member_type): Adjust.
11266 (read_tag_string_type): Adjust.
11267 (read_subroutine_type): Adjust.
11268 (read_typedef): Adjust.
11269 (read_base_type): Adjust.
11270 (attr_to_dynamic_prop): Adjust.
11271 (read_subrange_type): Adjust.
11272 (read_unspecified_type): Adjust.
11273 (dwarf2_read_abbrevs): Adjust.
11274 (load_partial_dies): Adjust.
11275 (read_partial_die): Adjust.
11276 (find_partial_die): Adjust.
11277 (guess_partial_die_structure_name): Adjust.
11278 (fixup_partial_die): Adjust.
11279 (read_attribute_value): Adjust.
11280 (read_addr_index): Adjust.
11281 (read_addr_index_from_leb128): Adjust.
11282 (read_str_index): Adjust.
11283 (dwarf2_string_attr): Adjust.
11284 (get_debug_line_section): Adjust.
11285 (dwarf_decode_line_header): Adjust.
11286 (lnp_state_machine::check_line_address): Adjust.
11287 (dwarf_decode_lines_1): Adjust.
11288 (dwarf_decode_lines): Adjust.
11289 (dwarf2_start_symtab): Adjust.
11290 (var_decode_location): Adjust.
11291 (new_symbol_full): Adjust.
11292 (dwarf2_const_value_data): Adjust.
11293 (dwarf2_const_value_attr): Adjust.
11294 (dwarf2_const_value): Adjust.
11295 (die_type): Adjust.
11296 (die_containing_type): Adjust.
11297 (build_error_marker_type): Adjust.
11298 (lookup_die_type): Adjust.
11299 (guess_full_die_structure_name): Adjust.
11300 (anonymous_struct_prefix): Adjust.
11301 (determine_prefix): Adjust.
11302 (dwarf2_name): Adjust.
11303 (follow_die_ref_or_sig): Adjust.
11304 (follow_die_offset): Adjust.
11305 (follow_die_ref): Adjust.
11306 (follow_die_sig_1): Adjust.
11307 (follow_die_sig): Adjust.
11308 (get_signatured_type): Adjust.
11309 (get_DW_AT_signature_type): Adjust.
11310 (decode_locdesc): Adjust.
11311 (dwarf_decode_macros): Adjust.
11312 (cu_debug_loc_section): Adjust.
11313 (fill_in_loclist_baton): Adjust.
11314 (dwarf2_symbol_mark_computed): Adjust.
11315 (init_one_comp_unit): Don't assign
11316 dwarf2_cu::dwarf2_per_objfile.
11317 (set_die_type): Adjust.
11318
ed2dc618
SM
113192018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11320
11321 * dwarf2read.c (struct mapped_debug_names): Add constructor.
11322 <dwarf2_per_objfile>: New field.
11323 (dwarf2_per_objfile): Remove global.
11324 (get_dwarf2_per_objfile): New function.
11325 (set_dwarf2_per_objfile): New function.
11326 (dwarf2_build_psymtabs_hard): Change objfile parameter to
11327 dwarf2_per_objfile.
11328 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
11329 (read_abbrev_offset): Likewise.
11330 (read_indirect_string): Likewise.
11331 (read_indirect_line_string): Likewise.
11332 (read_indirect_string_at_offset): Likewise.
11333 (read_indirect_string_from_dwz): Likewise.
11334 (dwarf2_find_containing_comp_unit): Change objfile parameter to
11335 dwarf2_per_objfile.
11336 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
11337 (create_all_comp_units): Change objfile parameter to
11338 dwarf2_per_objfile.
11339 (create_all_type_units): Likewise.
11340 (process_queue): Add dwarf2_per_objfile parameter.
11341 (read_and_check_comp_unit_head): Likewise.
11342 (lookup_dwo_unit_in_dwp): Likewise.
11343 (get_dwp_file): Likewise.
11344 (process_cu_includes): Likewise.
11345 (struct free_dwo_file_cleanup_data): New struct.
11346 (dwarf2_has_info): Use get_dwarf2_per_objfile and
11347 set_dwarf2_per_objfile.
11348 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
11349 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
11350 context, adjust calls.
11351 (dw2_instantiate_symtab): Likewise.
11352 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
11353 (dw2_get_cu): Likewise.
11354 (create_cu_from_index_list): Change objfile parameter to
11355 dwarf2_per_objfile.
11356 (create_cus_from_index_list): Get dwarf2_per_objfile from
11357 context, adjust calls.
11358 (create_cus_from_index): Likewise.
11359 (create_signatured_type_table_from_index): Change objfile
11360 parameter to dwarf2_per_objfile.
11361 (create_signatured_type_table_from_debug_names): Change objfile
11362 parameter to dwarf2_per_objfile.
11363 (create_addrmap_from_index): Likewise.
11364 (create_addrmap_from_aranges): Likewise.
11365 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
11366 (dw2_setup): Remove.
11367 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
11368 context.
11369 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
11370 get_dwarf2_per_objfile.
11371 (dw2_forget_cached_source_info): Likewise.
11372 (dw2_map_symtabs_matching_filename): Likewise.
11373 (struct dw2_symtab_iterator) <index>: Remove.
11374 <dwarf2_per_objfile>: New field.
11375 (dw2_symtab_iter_init): Replace index parameter with
11376 dwarf2_per_objfile.
11377 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
11378 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
11379 (dw2_print_stats): Likewise.
11380 (dw2_dump): Likewise.
11381 (dw2_expand_symtabs_for_function): Likewise.
11382 (dw2_expand_all_symtabs): Likewise.
11383 (dw2_expand_symtabs_with_fullname): Likewise.
11384 (dw2_expand_marked_cus): Replace index and objfile parameters
11385 with dwarf2_per_objfile.
11386 (dw_expand_symtabs_matching_file_matcher): Add
11387 dwarf2_per_objfile parameter and adjust calls.
11388 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
11389 adjust calls.
11390 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
11391 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
11392 adjust calls.
11393 (create_cus_from_debug_names_list): Replace objfile parameter
11394 with dwarf2_per_objfile and adjust calls.
11395 (create_cus_from_debug_names): Likewise.
11396 (dwarf2_read_debug_names): Likewise.
11397 (mapped_debug_names::namei_to_name): Adjust call.
11398 (dw2_debug_names_iterator::next): Likewise.
11399 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
11400 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
11401 (dw2_debug_names_dump): Likewise.
11402 (dw2_debug_names_expand_symtabs_for_function): Likewise.
11403 (dw2_debug_names_expand_symtabs_matching): Likewise.
11404 (dwarf2_initialize_objfile): Likewise.
11405 (dwarf2_build_psymtabs): Likewise.
11406 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
11407 this_cu.
11408 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
11409 (read_and_check_comp_unit_head): Likewise.
11410 (read_abbrev_offset): Likewise.
11411 (create_debug_type_hash_table): Likewise.
11412 (create_debug_types_hash_table): Likewise.
11413 (create_all_type_units): Replace objfile parameter with
11414 dwarf2_per_objfile.
11415 (add_type_unit): Add dwarf2_per_objfile parameter.
11416 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
11417 with dwarf2_per_objfile.
11418 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
11419 (lookup_dwp_signatured_type): Likewise.
11420 (lookup_signatured_type): Likewise.
11421 (read_cutu_die_from_dwo): Likewise.
11422 (init_tu_and_read_dwo_dies): Likewise.
11423 (init_cutu_and_read_dies): Likewise.
11424 (init_cutu_and_read_dies_no_follow): Likewise.
11425 (allocate_type_unit_groups_table): Add objfile parameter.
11426 (create_type_unit_group): Use dwarf2_per_objfile from cu.
11427 (get_type_unit_group): Likewise.
11428 (process_psymtab_comp_unit): Update call.
11429 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
11430 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
11431 (print_tu_stats): Likewise.
11432 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
11433 in void* parameter.
11434 (build_type_psymtabs): Change objfile parameter to
11435 dwarf2_per_objfile.
11436 (process_skeletonless_type_unit): Use dwarf2_per_objfile
11437 passed in void* parameter.
11438 (process_skeletonless_type_units): Change objfile parameter to
11439 dwarf2_per_objfile.
11440 (set_partial_user): Likewise.
11441 (dwarf2_build_psymtabs_hard): Likewise.
11442 (read_comp_units_from_section): Likewise.
11443 (create_all_comp_units): Likewise.
11444 (scan_partial_symbols): Update calls.
11445 (add_partial_symbol): Likewise.
11446 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
11447 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
11448 (process_queue): Add dwarf2_per_objfile parameter.
11449 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
11450 (compute_compunit_symtab_includes): Likewise.
11451 (process_cu_includes): Add dwarf2_per_objfile parameter.
11452 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
11453 (process_full_type_unit): Likewise.
11454 (process_imported_unit_die): Update call.
11455 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
11456 (read_file_scope): Likewise.
11457 (allocate_dwo_file_hash_table): Add objfile parameter.
11458 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
11459 (create_cus_hash_table): Likewise.
11460 (create_dwp_hash_table): Likewise.
11461 (create_dwo_unit_in_dwp_v1): Likewise.
11462 (create_dwp_v2_section): Likewise.
11463 (create_dwo_unit_in_dwp_v2): Likewise.
11464 (lookup_dwo_unit_in_dwp): Likewise.
11465 (try_open_dwop_file): Likewise.
11466 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
11467 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
11468 cleanup to include a reference to dwarf2_per_objfile.
11469 (open_dwp_file): Add dwarf2_per_objfile parameter.
11470 (open_and_init_dwp_file): Likewise.
11471 (get_dwp_file): Likewise.
11472 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
11473 (queue_and_load_all_dwo_tus): Update call.
11474 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
11475 data.
11476 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
11477 (dwarf2_ranges_process): Likewise.
11478 (dwarf2_get_pc_bounds): Likewise.
11479 (mark_common_block_symbol_computed): Likewise.
11480 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
11481 (dwarf2_read_abbrevs): Update call.
11482 (read_partial_die): Use dwarf2_per_objfile from cu.
11483 (find_partial_die): Likewise.
11484 (fixup_partial_die): Likewise.
11485 (read_attribute_value): Likewise.
11486 (read_indirect_string_at_offset_from): Add objfile parameter.
11487 (read_indirect_string_at_offset): Add dwarf2_per_objfile
11488 parameter.
11489 (read_indirect_string_from_dwz): Add objfile parameter.
11490 (read_indirect_string): Add objfile parameter.
11491 (read_addr_index_1): Add dwarf2_per_objfile parameter.
11492 (read_addr_index): Use dwarf2_per_objfile from cu.
11493 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
11494 call dw2_setup.
11495 (read_str_index): Use dwarf2_per_objfile from cu.
11496 (get_debug_line_section): Likewise.
11497 (read_formatted_entries): Add dwarf2_per_objfile parameter.
11498 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
11499 (new_symbol_full): Use dwarf2_per_objfile from cu.
11500 (build_error_marker_type): Likewise.
11501 (lookup_die_type): Likewise.
11502 (determine_prefix): Likewise.
11503 (follow_die_offset): Likewise.
11504 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
11505 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
11506 (dwarf2_fetch_die_type_sect_off): Likewise.
11507 (dwarf2_get_die_type): Likewise.
11508 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
11509 (get_signatured_type): Likewise.
11510 (get_DW_AT_signature_type): Likewise.
11511 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
11512 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
11513 (cu_debug_loc_section): Likewise.
11514 (fill_in_loclist_baton): Likewise.
11515 (dwarf2_symbol_mark_computed): Likewise.
11516 (dwarf2_find_containing_comp_unit): Change objfile parameter to
11517 dwarf2_per_objfile.
11518 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
11519 parameter.
11520 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
11521 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
11522 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
11523 (set_die_type): Use dwarf2_free_objfile from cu.
11524 (get_die_type_at_offset): Likewise.
11525 (dwarf2_per_objfile_free): Don't assign global variable.
11526 (debug_names) <constructor>: Add dwarf2_per_objfile
11527 parameter, update m_debugstrlookup construction.
11528 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
11529 parameter.
11530 <m_dwarf2_per_objfile>: New field.
11531 <lookup>: Use m_dwarf2_per_objfile.
11532 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
11533 (psyms_seen_size): Likewise.
11534 (write_gdbindex): Replace objfile parameter with
11535 dwarf2_per_objfile.
11536 (write_debug_names): Likewise.
11537 (write_psymtabs_to_index): Likewise.
11538 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
11539 calls.
11540
e3b94546
SM
115412018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11542
11543 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
11544 <dwarf2_per_objfile>: New field.
11545 (struct dwarf2_per_cu_data) <objfile>: Remove.
11546 <dwarf2_per_objfile>: New field.
11547 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
11548 of objfile.
11549 (create_signatured_type_table_from_index): Likewise.
11550 (create_debug_type_hash_table): Likewise.
11551 (fill_in_sig_entry_from_dwo_entry): Likewise.
11552 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
11553 (create_type_unit_group): Assign dwarf2_per_objfile instead of
11554 objfile.
11555 (create_partial_symtab): Access objfile through
11556 dwarf2_per_objfile.
11557 (process_psymtab_comp_unit_reader): Likewise.
11558 (read_comp_units_from_section): Likewise.
11559 (scan_partial_symbols): Likewise.
11560 (add_partial_symbol): Likewise.
11561 (add_partial_subprogram): Likewise.
11562 (peek_die_abbrev): Likewise.
11563 (fixup_go_packaging): Likewise.
11564 (process_full_comp_unit): Likewise.
11565 (process_full_type_unit): Likewise.
11566 (process_imported_unit_die): Likewise.
11567 (dwarf2_compute_name): Likewise.
11568 (dwarf2_physname): Likewise.
11569 (read_import_statement): Likewise.
11570 (create_cus_hash_table): Assign dwarf2_physname instead of
11571 objfile.
11572 (read_func_scope): Access objfile through dwarf2_per_objfile.
11573 (read_lexical_block_scope): Likewise.
11574 (read_call_site_scope): Likewise.
11575 (read_variable): Likewise.
11576 (dwarf2_rnglists_process): Likewise.
11577 (dwarf2_ranges_process): Likewise.
11578 (dwarf2_ranges_read): Likewise.
11579 (dwarf2_record_block_ranges): Likewise.
11580 (dwarf2_add_field): Likewise.
11581 (dwarf2_add_member_fn): Likewise.
11582 (read_structure_type): Likewise.
11583 (process_structure_scope): Likewise.
11584 (read_enumeration_type): Likewise.
11585 (read_array_type): Likewise.
11586 (read_common_block): Likewise.
11587 (read_namespace_type): Likewise.
11588 (read_namespace): Likewise.
11589 (read_module_type): Likewise.
11590 (read_tag_pointer_type): Likewise.
11591 (read_tag_ptr_to_member_type): Likewise.
11592 (read_tag_string_type): Likewise.
11593 (read_subroutine_type): Likewise.
11594 (read_typedef): Likewise.
11595 (read_base_type): Likewise.
11596 (attr_to_dynamic_prop): Likewise.
11597 (read_subrange_type): Likewise.
11598 (read_unspecified_type): Likewise.
11599 (load_partial_dies): Likewise.
11600 (read_partial_die): Likewise.
11601 (find_partial_die): Likewise.
11602 (guess_partial_die_structure_name): Likewise.
11603 (fixup_partial_die): Likewise.
11604 (read_attribute_value): Likewise.
11605 (read_addr_index_from_leb128): Likewise.
11606 (dwarf2_read_addr_index): Likewise.
11607 (dwarf2_string_attr): Likewise.
11608 (lnp_state_machine::check_line_address): Likewise.
11609 (dwarf_decode_lines_1): Likewise.
11610 (dwarf_decode_lines): Likewise.
11611 (dwarf2_start_symtab): Likewise.
11612 (var_decode_location): Likewise.
11613 (new_symbol_full): Likewise.
11614 (dwarf2_const_value_data): Likewise.
11615 (dwarf2_const_value_attr): Likewise.
11616 (dwarf2_const_value): Likewise.
11617 (die_type): Likewise.
11618 (die_containing_type): Likewise.
11619 (lookup_die_type): Likewise.
11620 (guess_full_die_structure_name): Likewise.
11621 (anonymous_struct_prefix): Likewise.
11622 (dwarf2_name): Likewise.
11623 (follow_die_ref_or_sig): Likewise.
11624 (follow_die_offset): Likewise.
11625 (follow_die_ref): Likewise.
11626 (dwarf2_fetch_die_loc_sect_off): Likewise.
11627 (dwarf2_fetch_constant_bytes): Likewise.
11628 (dwarf2_fetch_die_type_sect_off): Likewise.
11629 (dwarf2_get_die_type): Likewise.
11630 (follow_die_sig): Likewise.
11631 (decode_locdesc): Likewise.
11632 (dwarf2_per_cu_objfile): Likewise.
11633 (dwarf2_per_cu_text_offset): Likewise.
11634 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
11635 objfile.
11636 (set_die_type): Access objfile through
11637 dwarf2_per_objfile.
11638
b01ba14d
SM
116392018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11640
11641 * valprint.c (converted_character_d): Remove typedef.
11642 (DEF_VEC_O (converted_character_d)): Remove.
11643 (count_next_character): Use std::vector.
11644 (print_converted_chars_to_obstack): Likewise.
11645 (generic_printstr): Likewise.
11646
4d0fdd9b
SM
116472018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11648
11649 * xml-support.h (struct gdb_xml_value): Add constructor.
11650 <value>: Change type to unique_xmalloc_ptr.
11651 (gdb_xml_value_s): Remove typedef.
11652 (DEF_VEC_O (gdb_xml_value_s)): Remove.
11653 (gdb_xml_element_start_handler): Change parameter type to
11654 std::vector.
11655 (xml_find_attribute): Likewise.
11656 * xml-support.c (xml_find_attribute): Change parameter type to
11657 std::vector and adjust.
11658 (gdb_xml_values_cleanup): Remove.
11659 (gdb_xml_parser::start_element): Adjust to std::vector.
11660 (xinclude_start_include): Change paraeter type to std::vector
11661 and adjust.
11662 * btrace.c (check_xml_btrace_version): Likewise.
11663 (parse_xml_btrace_block): Likewise.
11664 (parse_xml_btrace_pt_config_cpu): Likewise.
11665 (parse_xml_btrace_pt): Likewise.
11666 (parse_xml_btrace_conf_bts): Likewise.
11667 (parse_xml_btrace_conf_pt): Likewise.
11668 * memory-map.c (memory_map_start_memory): Likewise.
11669 (memory_map_start_property): Likewise.
11670 * osdata.c (osdata_start_osdata): Likewise.
11671 (osdata_start_item): Likewise.
11672 (osdata_start_column): Likewise.
11673 * remote.c (start_thread): Likewise.
11674 * solib-aix.c (library_list_start_library): Likewise.
11675 (library_list_start_list): Likewise.
11676 * solib-svr4.c (library_list_start_library): Likewise.
11677 (svr4_library_list_start_list): Likewise.
11678 * solib-target.c (library_list_start_segment): Likewise.
11679 (library_list_start_section): Likewise.
11680 (library_list_start_library): Likewise.
11681 (library_list_start_list): Likewise.
11682 * tracepoint.c (traceframe_info_start_memory): Likewise.
11683 (traceframe_info_start_tvar): Likewise.
11684 * xml-syscall.c (syscall_start_syscall): Likewise.
11685 * xml-tdesc.c (tdesc_start_target): Likewise.
11686 (tdesc_start_feature): Likewise.
11687 (tdesc_start_reg): Likewise.
11688 (tdesc_start_union): Likewise.
11689 (tdesc_start_struct): Likewise.
11690 (tdesc_start_flags): Likewise.
11691 (tdesc_start_enum): Likewise.
11692 (tdesc_start_field): Likewise.
11693 (tdesc_start_enum_value): Likewise.
11694 (tdesc_start_vector): Likewise.
11695
f979c73f
SM
116962018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11697
11698 * extension.h (struct xmethod_worker) <clone>: Remove.
11699 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
11700 Remove.
11701 (python_xmethod_worker::clone): Remove.
11702 * valops.c (find_overload_match): Use std::move instead of
11703 clone.
11704
ba18742c
SM
117052018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11706
11707 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
11708 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
11709 <free_xmethod_worker_data>: Remove.
11710 <get_matching_xmethod_workers>: Chance VEC to std::vector.
11711 <get_xmethod_arg_types>: Remove.
11712 <get_xmethod_result_type>: Remove.
11713 <invoke_xmethod>: Remove.
11714 * extension.c (new_xmethod_worker): Remove.
11715 (clone_xmethod_worker): Remove.
11716 (get_matching_xmethod_workers): Return void, pass std::vector by
11717 pointer.
11718 (get_xmethod_arg_types): Rename to...
11719 (xmethod_worker::get_arg_types): ... this, and adjust.
11720 (get_xmethod_result_type): Rename to...
11721 (xmethod_worker::get_result_type): ... this, and adjust.
11722 (invoke_xmethod): Remove.
11723 (free_xmethod_worker): Remove.
11724 (free_xmethod_worker_vec): Remove.
11725 * extension.h (enum ext_lang_rc): Move here from
11726 extension-priv.h.
11727 (struct xmethod_worker): Add constructor and destructor.
11728 <data>: Remove.
11729 <value>: Remove.
11730 <invoke, clone, do_get_result_type, do_get_arg_types>: New
11731 virtual pure methods.
11732 <get_arg_types, get_result_type>: New methods.
11733 (xmethod_worker_ptr): Remove typedef.
11734 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
11735 (xmethod_worker_vec): Remove typedef.
11736 (xmethod_worker_up): New typedef.
11737 (invoke_xmethod): Remove.
11738 (clone_xmethod_worker): Remove.
11739 (free_xmethod_worker): Remove.
11740 (free_xmethod_worker_vec): Remove.
11741 (get_xmethod_arg_types): Remove.
11742 (get_xmethod_result_type): Remove.
11743 * valops.c (find_method_list): Use std::vector, don't use
11744 intermediate vector.
11745 (value_find_oload_method_list): Use std::vector.
11746 (find_overload_match): Use std::vector.
11747 (find_oload_champ): Use std::vector.
11748 * value.c (value_free): Use operator delete.
11749 (value_of_xmethod): Rename to...
11750 (value_from_xmethod): ... this. Don't assign
11751 xmethod_worker::value, take rvalue-reference.
11752 (result_type_of_xmethod): Adjust.
11753 (call_xmethod): Adjust.
11754 * value.h: Include extension.h.
11755 (struct xmethod_worker): Don't forward-declare.
11756 (value_of_xmethod): Rename to...
11757 (value_from_xmethod): ... this, take rvalue-reference.
11758 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
11759 (struct python_xmethod_worker): ... this, add constructor and
11760 destructor.
11761 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
11762 (gdbpy_free_xmethod_worker_data): Rename to...
11763 (python_xmethod_worker::~python_xmethod_worker): ... this and
11764 adjust.
11765 (gdbpy_clone_xmethod_worker_data): Rename to...
11766 (python_xmethod_worker::clone): ... this and adjust.
11767 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
11768 temporary vector.
11769 (gdbpy_get_xmethod_arg_types): Rename to...
11770 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
11771 (gdbpy_get_xmethod_result_type): Rename to...
11772 (python_xmethod_worker::do_get_result_type): ... this and
11773 adjust.
11774 (gdbpy_invoke_xmethod): Rename to...
11775 (python_xmethod_worker::invoke): ... this and adjust.
11776 (new_python_xmethod_worker): Rename to...
11777 (python_xmethod_worker::python_xmethod_worker): ... this and
11778 adjust.
11779 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
11780 Remove.
11781 (gdbpy_free_xmethod_worker_data): Remove.
11782 (gdbpy_get_matching_xmethod_workers): Use std::vector.
11783 (gdbpy_get_xmethod_arg_types): Remove.
11784 (gdbpy_get_xmethod_result_type): Remove.
11785 (gdbpy_invoke_xmethod): Remove.
11786 * python/python.c (python_extension_ops): Remove obsolete
11787 callbacks.
11788
e379cee6
PA
117892018-01-05 Pedro Alves <palves@redhat.com>
11790
11791 PR gdb/18653
11792 * common/signals-state-save-restore.c
11793 (save_original_signals_state): New parameter 'quiet'. Warn if we
11794 find a custom handler preinstalled, instead of internal erroring.
11795 But only warn if !quiet.
11796 * common/signals-state-save-restore.h
11797 (save_original_signals_state): New parameter 'quiet'.
11798 * main.c (captured_main_1): Move save_original_signals_state call
11799 after option handling, and pass QUIET.
11800
a655456c
PA
118012018-01-05 Pedro Alves <palves@redhat.com>
11802
11803 * spu-tdep.c (spu_catch_start): Pass
11804 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
11805
de63c46b
PA
118062018-01-05 Pedro Alves <palves@redhat.com>
11807
11808 PR gdb/22670
11809 * ada-lang.c (literal_symbol_name_matcher): New function.
11810 (ada_get_symbol_name_matcher): Use it for
11811 symbol_name_match_type::SEARCH_NAME.
11812 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
11813 it down instead of assuming symbol_name_match_type::FULL.
11814 * block.h (block_lookup_symbol): New parameter 'match_type'.
11815 * c-valprint.c (print_unpacked_pointer): Use
11816 lookup_symbol_search_name instead of lookup_symbol.
11817 * compile/compile-object-load.c (get_out_value_type): Pass down
11818 symbol_name_match_type::SEARCH_NAME.
11819 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
11820 symbol_name_match_type::FULL.
11821 * cp-support.c (cp_get_symbol_name_matcher): Handle
11822 symbol_name_match_type::SEARCH_NAME.
11823 * infrun.c (insert_exception_resume_breakpoint): Use
11824 lookup_symbol_search_name.
11825 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
11826 * psymtab.c (maintenance_check_psymtabs): Use
11827 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
11828 * stack.c (print_frame_args): Use lookup_symbol_search_name and
11829 SYMBOL_SEARCH_NAME.
11830 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
11831 if symbol_name_match_type::SEARCH_NAME.
11832 (lookup_symbol_in_language): Pass down
11833 symbol_name_match_type::FULL.
11834 (lookup_symbol_search_name): New.
11835 (lookup_language_this): Pass down
11836 symbol_name_match_type::SEARCH_NAME.
11837 (lookup_symbol_aux, lookup_local_symbol): New parameter
11838 'match_type'. Pass it down.
11839 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
11840 (lookup_symbol_search_name): New declaration.
11841 (lookup_symbol_in_block): New 'match_type' parameter.
11842
f98fc17b
PA
118432018-01-05 Pedro Alves <palves@redhat.com>
11844
11845 PR gdb/22670
11846 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
11847 ada_lookup_symbol.
11848 (ada_lookup_symbol): Reimplement in terms of
11849 ada_lookup_symbol_list, bits factored out from
11850 ada_lookup_encoded_symbol.
11851
342f8240
JB
118522018-01-05 Joel Brobecker <brobecker@adacore.com>
11853
11854 * ada-exp.y (write_object_renaming): When subscripting an array
11855 using a symbol as the index, pass the block in call to
11856 ada_lookup_encoded_symbol when looking that symbol up.
11857
7150d33c
JG
118582018-01-05 Jerome Guitton <guitton@adacore.com>
11859
11860 * ada-lang.c (ada_array_length): Use ada_index_type instead of
11861 TYPE_INDEX_TYPE.
11862
cc0e770c
JB
118632018-01-05 Joel Brobecker <brobecker@adacore.com>
11864
11865 * ada-lang.c (ada_to_fixed_value_create): Add handling of
11866 the case where VALUE_LVAL (val0) is not lval_memory.
11867
f79da888 118682018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
11869
11870 * ada-valprint.c (print_optional_low_bound): Handle
11871 character-indexed array printing like boolean-indexed array
11872 printing.
11873
cd385f94
JB
118742018-01-05 Joel Brobecker <brobecker@adacore.com>
11875
11876 * NEWS: Create a new section for the next release branch.
11877 Rename the section of the current branch, now that it has
11878 been cut.
11879
09aca949
JB
118802018-01-05 Joel Brobecker <brobecker@adacore.com>
11881
11882 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
11883 * version.in: Bump version to 8.1.50.DATE-git.
11884
9f757bf7
XR
118852018-01-03 Xavier Roirand <roirand@adacore.com>
11886
11887 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
11888 Add field.
11889 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
11890 Add field.
11891 (default_exception_support_info) <catch_handlers_sym>: Add field.
11892 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
11893 (ada_exception_name_addr_1): Add "catch handlers" handling.
11894 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
11895 Update all callers.
11896 (create_excep_cond_exprs) <ex>: Add parameter.
11897 (re_set_exception): Update create_excep_cond_exprs call.
11898 (print_it_exception, print_one_exception, print_mention_exception)
11899 (print_recreate_exception): Add "catch handler" handling.
11900 (allocate_location_catch_handlers, re_set_catch_handlers)
11901 (check_status_catch_handlers, print_it_catch_handlers)
11902 (print_one_catch_handlers, print_mention_catch_handlers)
11903 (print_recreate_catch_handlers): New function.
11904 (catch_handlers_breakpoint_ops): New variable.
11905 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
11906 Add parameter. Add "catch handler" handling.
11907 (ada_exception_sym_name, ada_exception_breakpoint_ops):
11908 Add "catch handler" handling.
11909 (ada_exception_catchpoint_cond_string): Add "catch handler"
11910 handling.
11911 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
11912 call.
11913 (catch_ada_handlers_command): New function.
11914 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
11915 operations structure.
11916 (_initialize_ada_language): Add "catch handlers" command entry.
11917 * NEWS: Document "catch handlers" feature.
11918
9fe561ab
JB
119192018-01-02 Joel Brobecker <brobecker@adacore.com>
11920
11921 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
11922 account when creating the array type of the slice.
11923 (ada_value_slice): Likewise.
11924
a405673c
JB
119252018-01-02 Joel Brobecker <brobecker@adacore.com>
11926
11927 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
11928 New enum value.
11929 (create_array_type_with_stride): Add byte_stride_prop parameter.
11930 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
11931 New parameter. Update all callers in this file.
11932 (array_type_has_dynamic_stride): New function.
11933 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
11934 of arrays with dynamic byte strides.
11935 * dwarf2read.c (read_array_type): Add support for dynamic
11936 DW_AT_byte_stride attributes.
11937
74a2f8ff
JB
119382018-01-02 Joel Brobecker <brobecker@adacore.com>
11939
11940 * dwarf2read.c (read_unspecified_type): Treat
11941 DW_TAG_enumeration_type DIEs from Ada units as stubs.
11942
e2882c85
JB
119432018-01-01 Joel Brobecker <brobecker@adacore.com>
11944
11945 Update copyright year range in all GDB files.
11946
1690bb24
JB
119472018-01-01 Joel Brobecker <brobecker@adacore.com>
11948
11949 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
11950 and gdb/testsuite/gdb.base/step-line.c.
11951
0f0c98a8
JB
119522018-01-01 Joel Brobecker <brobecker@adacore.com>
11953
11954 * copyright.py (main): Dump the contents of
11955 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
11956 even if BY_HAND is empty.
11957
82e1e79a
JB
119582018-01-01 Joel Brobecker <brobecker@adacore.com>
11959
11960 * top.c (print_gdb_version): Update Copyright year in version
11961 message.
11962
053f54e5 119632018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 11964
053f54e5 11965 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 11966
053f54e5 11967For older changes see ChangeLog-2017.
c906108c
SS
11968\f
11969Local Variables:
11970mode: change-log
11971left-margin: 8
11972fill-column: 74
11973version-control: never
57da7796 11974coding: utf-8
c906108c 11975End:
This page took 3.915162 seconds and 4 git commands to generate.