Get rid of -Wodr warning (PR build/23399)
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
2
3 PR build/23399
4 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
5 (struct ipa_sym_addresses): Rename to...
6 (struct ipa_sym_addresses_common): ... this.
7 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
8
9 2018-08-28 Tom Tromey <tom@tromey.com>
10
11 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
12 (token_fifo): Now a std::vector.
13 (yylex, c_parse): Update.
14 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
15 (token_fifo): Now a std::vector.
16 (yylex, d_parse): Update.
17 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
18 (token_fifo): Now a std::vector.
19 (yylex, go_parse): Update.
20
21 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
22
23 * parser-defs.h (struct type_stack) <elements>: Change type to
24 std::vector<union type_stack_elt>.
25 <depth, size>: Remove.
26 * parse.c (parse_exp_in_context_1): Adjust.
27 (type_stack_reserve): Remove.
28 (check_type_stack_depth): Remove.
29 (insert_into_type_stack): Adjust to std::vector.
30 (insert_type): Likewise.
31 (push_type): Likewise.
32 (push_type_int): Likewise.
33 (insert_type_address_space): Likewise.
34 (pop_type): Likewise.
35 (pop_type_int): Likewise.
36 (pop_typelist): Likewise.
37 (pop_type_stack): Likewise.
38 (append_type_stack): Likewise.
39 (push_type_stack): Likewise.
40 (get_type_stack): Likewise.
41 (type_stack_cleanup): Likewise.
42 (push_typelist): Likewise.
43 (follow_types): Likewise.
44 (_initialize_parse): Likewise.
45
46 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
47
48 * NEWS: Mention csky target.
49
50 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
51 Hafiz Abid Qadeer <abidh@codesourcery.com>
52 Don Breazeal <donb@codesourcery.com>
53
54 * csky-linux-tdep.c: New file.
55 * csky-tdep.c: Likewise.
56 * csky-tdep.h: Likewise.
57 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
58 csky-tdep.o.
59 (HFILES_NO_SRCDIR): Add csky-tdep.h.
60 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
61 * configure.tgt: Add csky support.
62
63 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
64
65 * python/py-framefilter.c (py_print_frame): Print frame architecture
66 when printing on an MI output.
67
68 2018-08-27 Tom Tromey <tom@tromey.com>
69
70 PR build/23087:
71 * configure: Rebuild.
72 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
73
74 2018-08-27 Tom Tromey <tom@tromey.com>
75
76 * aarch64-linux-tdep.c
77 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
78 casts to int.
79
80 2018-08-27 Tom Tromey <tom@tromey.com>
81
82 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
83 unsigned.
84 (ppc64_standard_linkage1, ppc64_standard_linkage2)
85 (ppc64_standard_linkage3, ppc64_standard_linkage4)
86 (ppc64_standard_linkage5, ppc64_standard_linkage6)
87 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
88 unsigned.
89
90 2018-08-27 Tom Tromey <tom@tromey.com>
91
92 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
93 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
94
95 2018-08-27 Tom Tromey <tom@tromey.com>
96
97 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
98 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
99 ULONGEST_MAX.
100 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
101 ULONGEST_MAX.
102 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
103 ULONGEST_MAX.
104 * sparc-linux-tdep.c (sparc32_linux_sigframe)
105 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
106 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
107 ULONGEST_MAX.
108 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
109 (ppc64_linux_sigaction_tramp_frame)
110 (ppc32_linux_sighandler_tramp_frame)
111 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
112 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
113 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
114 * mn10300-linux-tdep.c (am33_linux_sigframe)
115 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
116 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
117 * mips-linux-tdep.c (mips_linux_o32_sigframe)
118 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
119 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
120 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
121 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
122 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
123 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
124 * microblaze-linux-tdep.c
125 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
126 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
127 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
128 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
129 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
130 * common/common-types.h (ULONGEST_MAX): New define.
131 (CORE_ADDR_MAX): Fix formatting.
132 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
133 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
134 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
135 (arm_linux_rt_sigreturn_tramp_frame)
136 (arm_eabi_linux_sigreturn_tramp_frame)
137 (arm_eabi_linux_rt_sigreturn_tramp_frame)
138 (thumb2_eabi_linux_sigreturn_tramp_frame)
139 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
140 (arm_linux_restart_syscall_tramp_frame)
141 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
142 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
143 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
144 ULONGEST_MAX.
145 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
146
147 2018-08-27 Tom Tromey <tom@tromey.com>
148
149 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
150 CORE_ADDR_MAX.
151 * mips-tdep.c (mips_deal_with_atomic_sequence)
152 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
153 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
154 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
155 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
156 CORE_ADDR_MAX.
157 * aarch64-tdep.c (aarch64_software_single_step): Use
158 CORE_ADDR_MAX.
159
160 2018-08-27 Tom Tromey <tom@tromey.com>
161
162 * linespec.c (complete_linespec_component): Add cast to "char".
163 * completer.c (completion_tracker::build_completion_result): Add
164 cast to "char".
165
166 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
167
168 * solist.h (struct solist, struct target_so_ops): Fix
169 indentation.
170
171 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
172
173 * ada-tasks.c (ada_task_info_s): Remove typedef.
174 (DEF_VEC_O(ada_task_info_s)): Remove.
175 (struct ada_tasks_inferior_data): Initialize fields.
176 <task_list>: Make an std::vector.
177 (get_ada_tasks_inferior_data): Allocate with new.
178 (ada_get_task_number): Adjust.
179 (get_task_number_from_id): Likewise.
180 (valid_task_id): Likewise.
181 (ada_get_task_info_from_ptid): Likewise.
182 (iterate_over_live_ada_tasks): Likewise.
183 (add_ada_task): Likewise.
184 (read_known_tasks): Likewise.
185 (ada_build_task_list): Likewise.
186 (print_ada_task_info): Likewise.
187 (info_task): Likewise.
188 (task_command_1): Likewise.
189
190 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
191
192 * ada-lang.c (add_angle_brackets): Return std::string.
193
194 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
195
196 * python/py-threadevent.c (py_get_event_thread): Initialize
197 pythread.
198
199 2018-08-24 Pedro Alves <palves@redhat.com>
200
201 * python/py-bpevent.c (create_breakpoint_event_object): Use
202 copy-initialization.
203 * python/py-continueevent.c (emit_continue_event): Use
204 copy-initialization.
205 * python/py-exitedevent.c (create_exited_event_object): Return a
206 gdbpy_ref<>.
207 (emit_exited_event): Use copy-initialization.
208 * python/py-inferior.c (python_new_inferior)
209 (python_inferior_deleted, add_thread_object): Use
210 copy-initialization.
211 * python/py-infevents.c (create_inferior_call_event_object)
212 (create_register_changed_event_object)
213 (create_memory_changed_event_object): Return a gdbpy_ref<>.
214 (emit_inferior_call_event, emit_memory_changed_event)
215 (emit_register_changed_event): Use copy-initialization.
216 * python/py-newobjfileevent.c (create_new_objfile_event_object):
217 Return a gdbpy_ref<>.
218 (emit_new_objfile_event): Use copy-initialization.
219 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
220 (emit_clear_objfiles_event): Use copy-initialization.
221 * python/py-signalevent.c (create_signal_event_object): Use
222 copy-initialization.
223 * python/py-threadevent.c (create_thread_event_object): Use
224 copy-initialization.
225
226 2018-08-24 Pedro Alves <palves@redhat.com>
227 Simon Marchi <simon.marchi@ericsson.com>
228
229 PR gdb/23379
230 * python/py-continueevent.c: Include "gdbthread.h".
231 (create_continue_event_object): Add intro comment. Add 'ptid'
232 parameter. Use it to find thread to pass to
233 create_thread_event_object.
234 (emit_continue_event): Pass PTID down to
235 create_continue_event_object.
236 * python/py-event.h (py_get_event_thread): Declare.
237 (create_thread_event_object): Remove default from 'thread'
238 parameter.
239 * python/py-stopevent.c (create_stop_event_object): Use
240 py_get_event_thread.
241 * python/py-threadevent.c (get_event_thread): Rename to ...
242 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
243 and use it to find the thread.
244 (create_thread_event_object): Assert that THREAD isn't null.
245 Don't find the event thread here.
246
247 2018-08-23 Kevin Buettner <kevinb@redhat.com>
248
249 * block.h (blockrange, blockranges): New struct declarations.
250 (struct block): Add new field named `ranges'.
251 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
252 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
253 macros for accessing ranges in struct block.
254 (make_blockranges): New declaration.
255 block.c (make_blockranges): New function.
256 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
257 for block.
258 * symtab.h (find_pc_partial_function): Add new parameter `block'.
259 * blockframe.c (cache_pc_function_block): New static global.
260 (clear_pc_function_cache): Clear cache_pc_function_block.
261 (find_pc_partial_function): Move comment to symtab.h. Add
262 support for non-contiguous blocks.
263 * cli/cli-cmds.c (block.h): Include.
264 (print_disassembly): Handle printing of non-contiguous blocks.
265 (disassemble_current_function): Likewise.
266 (disassemble_command): Likewise.
267
268 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
269 BLOCK_START.
270 * blockframe.c (get_pc_function_start): Likewise.
271 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
272 (gcc_symbol_address): Likewise.
273 * compile/compile-object-run.c (compile_object_run): Likewise.
274 * compile/compile.c (get_expr_block_and_pc): Likewise.
275 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
276 (func_addr_to_tail_call_list): Likewise.
277 * findvar.c (default_read_var_value): Likewise.
278 * inline-frame.c (inline_frame_this_id): Likewise.
279 (skip-inline_frames): Likewise.
280 * infcmd.c (until_next_command): Likewise.
281 * linespec.c (convert_linespec_to_sals): Likewise.
282 * parse.c (parse_exp_in_context_1): Likewise.
283 * printcmd.c (build_address_symbolic): likewise.
284 (info_address_command): Likewise.
285 symtab.c (find_function_start_sal): Likewise.
286 (skip_prologue_sal): Likewise.
287 (find_function_alias_target): Likewise.
288 (find_gnu_ifunc): Likewise.
289 * stack.c (find_frame_funname): Likewise.
290 * symtab.c (fixup_symbol_section): Likewise.
291 (find_function_start_sal): Likewise.
292 (skip_prologue_sal): Likewsie.
293 (find_function_alias_target): Likewise.
294 (find_gnu_ifunc): Likewise.
295 * tracepoint.c (info_scope_command): Likewise.
296 * value.c (value_fn_field): Likewise.
297
298 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
299 in place of find_pc_partial_function.
300 * blockframe.c (find_function_entry_range_from_pc): New function.
301 * symtab.h (find_function_entry_range_from_pc): Declare and document.
302 * objfiles.c (objfile_relocate1): Relocate start and end addresses
303 for each range in a block.
304
305
306 2018-08-23 Xavier Roirand <roirand@adacore.com>
307
308 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
309 incrementation.
310
311 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
312
313 * solib-svr4.c (read_program_headers_from_bfd): Return
314 gdb::optional<gdb::byte_vector>.
315 (svr4_exec_displacement): Adjust.
316
317 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
318
319 * solib-svr4.c (read_program_header): Return
320 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
321 (find_program_interpreter): Return
322 gdb::optional<gdb::byte_vector>.
323 (scan_dyntag_auxv): Adjust.
324 (enable_break): Adjust.
325 (svr4_exec_displacement): Adjust.
326
327 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
328
329 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
330 * inf-child.c (inf_child_target::terminal_save_inferior): New.
331
332 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
333
334 * guile/scm-string.c (gdbscm_scm_from_printf): Use
335 string_vprintf.
336 * guile/scm-utils.c (gdbscm_printf): Likewise.
337 * serial.c (serial_printf): Likewise.
338 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
339
340 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
341
342 * stack.c (print_frame): Print frame architecture when printing on
343 an MI output.
344 * NEWS: Mention new "arch" attribute in frame output.
345
346 2018-08-21 Alan Hayward <alan.hayward@arm.com>
347
348 * arch/aarch64.h (aarch64_regnum): Update comment.
349
350 2018-08-21 Alan Hayward <alan.hayward@arm.com>
351
352 * NEWS: Add SVE to 8.2 section.
353
354 2018-08-21 Pedro Alves <palves@redhat.com>
355
356 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
357 out from gdbscm_parse_function_args.
358 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
359 gdbscm_parse_function_args_1.
360
361 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
362
363 PR gdb/17816
364 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
365 operator.
366
367 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
368
369 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
370
371 2018-08-19 Michael Spang <spang@google.com>
372
373 PR gdb/11786
374 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
375 for PT_TLS segments.
376
377 2018-08-18 Kevin Buettner <kevinb@redhat.com>
378
379 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
380 dwarf_variable_value.
381 * dwarf2-frame.c (class dwarf_expr_executor):
382 Add override for dwarf_variable_value.
383 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
384 (class symbol_needs_eval_context): Likewise.
385 (indirect_synthetic_pointer): Add forward declaration.
386 (sect_variable_value): New function.
387 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
388 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
389 for DW_OP_GNU_variable_value.
390
391 2018-08-16 Tom Tromey <tom@tromey.com>
392
393 * top.c (read_command_file): Update.
394 (command_line_input): Remove "repeat" argument.
395 * ada-lang.c (get_selections): Update.
396 * linespec.c (decode_line_2): Update.
397 * defs.h (command_line_input): Remove argument.
398 * cli/cli-script.c (read_next_line): Update.
399 * python/py-gdb-readline.c: Update.
400
401 2018-08-17 Tom Tromey <tom@tromey.com>
402
403 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
404 command_line_input.
405
406 2018-08-15 Tom Tromey <tom@tromey.com>
407
408 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
409
410 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
411
412 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
413 If used, use find_pc_partial_function to find address range
414 to disassemble.
415 * mi/mi-main.c (mi_cmd_list_features): Report
416 "data-disassemble-a-option" feature.
417 * NEWS: Mention new -data-disassemble option -a.
418
419 2018-08-13 Tom Tromey <tom@tromey.com>
420
421 * common/common-defs.h (_FORTIFY_SOURCE): Define.
422
423 2018-08-13 Alan Hayward <alan.hayward@arm.com>
424
425 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
426 (aarch64_linux_collect_sve_regset): Likewise.
427 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
428 * regcache.h (regcache_map_entry_size): New function.
429
430 2018-08-13 Alan Hayward <alan.hayward@arm.com>
431
432 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
433 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
434 (SVE_HEADER_VL_LENGTH): Likewise.
435 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
436 (SVE_HEADER_FLAGS_LENGTH): Likewise.
437 (SVE_HEADER_RESERVED_LENGTH): Likewise.
438 (SVE_HEADER_SIZE_OFFSET): Likewise.
439 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
440 (SVE_HEADER_VL_OFFSET): Likewise.
441 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
442 (SVE_HEADER_FLAGS_OFFSET): Likewise.
443 (SVE_HEADER_RESERVED_OFFSET): Likewise.
444 (SVE_HEADER_SIZE): Likewise.
445 (aarch64_linux_core_read_vq): Add function.
446 (aarch64_linux_core_read_description): Check for SVE section.
447
448 2018-08-13 Alan Hayward <alan.hayward@arm.com>
449
450 * aarch64-fbsd-tdep.c
451 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
452 collect_size.
453 * aarch64-linux-tdep.c
454 (aarch64_linux_iterate_over_regset_sections): Likewise.
455 * alpha-linux-tdep.c
456 (alpha_linux_iterate_over_regset_sections):
457 * alpha-nbsd-tdep.c
458 (alphanbsd_iterate_over_regset_sections): Likewise.
459 * amd64-fbsd-tdep.c
460 (amd64fbsd_iterate_over_regset_sections): Likewise.
461 * amd64-linux-tdep.c
462 (amd64_linux_iterate_over_regset_sections): Likewise.
463 * arm-bsd-tdep.c
464 (armbsd_iterate_over_regset_sections): Likewise.
465 * arm-fbsd-tdep.c
466 (arm_fbsd_iterate_over_regset_sections): Likewise.
467 * arm-linux-tdep.c
468 (arm_linux_iterate_over_regset_sections): Likewise.
469 * corelow.c (get_core_registers_cb): Likewise.
470 (core_target::fetch_registers): Likewise.
471 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
472 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
473 * gdbarch.h (void): Regenerate.
474 * gdbarch.sh: Add supply_size and collect_size.
475 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
476 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
477 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
478 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
479 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
480 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
481 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
482 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
483 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
484 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
485 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
486 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
487 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
488 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
489 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
490 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
491 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
492 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
493 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
494 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
495 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
496 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
497 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
498 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
499 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
500 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
501 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
502 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
503 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
504 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
505
506 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
507
508 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
509 with string_printf.
510
511 2018-08-10 Keith Seitz <keiths@redhat.com>
512
513 * compile/compile-c-support.c (add_code_header, add_code_footer):
514 Move into policy class.
515 (c_push_user_expression, pop_user_expression_nop)
516 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
517 (compile_program): New host class.
518 (c_compile_program): New typedef.
519 (c_compute_porgram): Use c_compile_program.
520
521 2018-08-10 Keith Seitz <keiths@redhat.com>
522
523 * compile/compile-internal.h (compile_instance::~compile_instance):
524 Remove calls to htab_delete.
525 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
526 * compile.c (compile_instance::compile_instance): Initialize
527 htab unique pointers.
528 (compile_instance::get_cached_type, compile_instance::insert_type)
529 (compile_instance::error_symbol_once): Update for unique_ptr.
530
531 2018-08-10 Keith Seitz <keiths@redhat.com>
532
533 * compile/compile-c-symbols.c (struct symbol_error)
534 (hash_symbol_error, eq_symbol_error, del_symbol_error)
535 (compile_instance::insert_symbol_error)
536 (compile_instance::error_symbol_once): Move to ...
537 * compile/compile.c: ... here.
538
539 2018-08-10 Keith Seitz <keiths@redhat.com>
540
541 * compile/compile-c-support.c (c_get_compile_context): Use `new'
542 instead of `new_compile_instance'.
543 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
544 Update description.
545 If the symbol error map is not initialized, create it.
546 (generate_c_for_for_one_symbol): Do not check/initialize
547 the symbol error map.
548 * compile/compile-c-types.c (compile_c_instance): Make a class.
549 Update all callers.
550 (compile_instance::compile_instance): Initialize the type cache.
551 (get_cached_type): New function.
552 (insert_type): Update description.
553 (compile_c_instance::m_default_cflags): Define.
554 (convert_type): Update description. Use get_cached_type.
555 (delete_instance): Moved to destructor.
556 (new_compile_instance): Moved to constructor.
557 * compile/compile-c.h (compile_c_instance): Make class inheriting
558 from compile_instance.
559 <base>: Remove field.
560 <type_map, symbol_err_map>: Move to base class.
561 <c_plugin>: Rename to `m_plugin' and remove pointer type.
562 * compile/compile-internal.h (compile_instance): Make class.
563 <type_map_t, symbol_err_map_t>: Define.
564 <fe>: Rename to `m_gcc_fe'.
565 <scope, block, gcc_target_options>: Add `m_' prefix.
566 <m_type_map, m_symbol_err_map>: New fields, moved from
567 compile_c_instance.
568 <destroy>: Remove.
569 (convert_type, new_compile_instance): Remove.
570 * compile/compile.c (cleanup_compile_instance): Remove.
571 (compile_to_object): Use unique_ptr to eliminate cleanups.
572 (compile_instance::set_print_callback, compile_instance::version)
573 (compile_instance::set_verbose)
574 (compile_instance::set_driver_filename)
575 (compile_instance::set_triplet_regexp)
576 (compile_instance::set_arguments)
577 (compile_instance::set_source_file)
578 (compile_instance::compile): Define.
579
580 2018-08-10 Keith Seitz <keiths@redhat.com>
581
582 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
583 * compile/compile-c-types.c: Define GCC_METHODN macros and include
584 gcc-c-fe.def to define C plugin.
585 (delete_instance): Delete `c_plugin'.
586 (new_compile_instance): Initialize `c_plugin'.
587 * compile/compile-c.h: Include gcc_c_plugin.h.
588 (struct compile_c_instance) <c_plugin>: New member.
589 * gcc-c-plugin.h: New file.
590 Update all callers with API change.
591
592 2018-08-10 Keith Seitz <keiths@redhat.com>
593
594 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
595 (HFILES_NO_SRCDIR): ... to here.
596 Add compile-internal.h and compile-c.h.
597 * compile/compile-c-support.c: Include compile-c.h.
598 * compile/compile-c-symbols.c: Include compile-c.h.
599 (generate_c_for_variable_locations): Update comment.
600 * compile/compile-c-types.c: Include compile-c.h.
601 * compile/compile-c.h: New file -- moved C language declarations
602 from other files here.
603 * compile/compile-internal.h: Do not include hashtab.h or
604 common/enum-flags.h.
605 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
606 (gcc_convert_symbol, gcc_symbol_address)
607 (generate_c_for_variable_locations, c_get_mode_for_size)
608 (c_get_range_decl_name): Definitions moved to compile-c.h.
609 * compile/compile-loc2c.c: Include compile-c.h.
610
611 2018-08-10 Keith Seitz <keiths@redhat.com>
612
613 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
614 (c_symbol_substitution_name): ... this.
615 Update all callers.
616
617 2018-08-10 Keith Seitz <keiths@redhat.com>
618
619 * compile/compile-c-support.c (c_compute_program): Use
620 unique_xmalloc_ptr to eliminate cleanup.
621 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
622 Return a unique_xmalloc_ptr and eliminate cleanup.
623 * compile/compile-internal.h (generate_c_for_variable_locations):
624 Return unique_xmalloc_ptr and update description.
625
626 2018-08-10 Alan Hayward <alan.hayward@arm.com>
627
628 * corelow.c (core_target::get_core_register_section): Rename
629 min_size to section_min_size.
630
631 2018-08-09 Jim Wilson <jimw@sifive.com>
632
633 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
634 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
635 * NEWS: Mention new GNU/Linux RISC-V target.
636 * configure.host: Add riscv*-*-linux*.
637 * configure.nat: Add riscv*.
638 * configure.tgt: Add riscv*-*-linux*.
639 * riscv-linux-nat.c: New file.
640 * riscv-linux-tdep.c: New file.
641
642 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
643
644 * infrun.c (resume): Make static, add forward declaration.
645 (proceed): Update header comment.
646 * infrun.h (resume): Delete declaration.
647
648 2018-08-09 Tom Tromey <tom@tromey.com>
649
650 * riscv-tdep.h: Minor formatting fixes.
651
652 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
653
654 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
655 * dwarf-index-cache.c (create_dir_and_check): Likewise.
656 (test_mkdir_recursive): Likewise.
657 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
658
659 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
660
661 * valarith.c (value_subscripted_rvalue): If an array is not in
662 memory, and we don't know the upper bound, then we can't know that
663 the requested element exists or not.
664
665 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
666
667 * target.c (str_comma_list_concat_elem): Fix typo in comment.
668 (target_options_to_string): Add comment.
669
670 2018-08-08 Tom Tromey <tom@tromey.com>
671
672 * unittests/scoped_mmap-selftests.c: Check result of "write".
673
674 2018-08-08 Jim Wilson <jimw@sifive.com>
675
676 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
677 (decode_register_index_short): New.
678 (decode_j_type_insn, decode_cj_type_insn): New.
679 (decode_b_type_insn, decode_cb_type_insn): New.
680 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
681 local xlen. Check xlen when decoding ambiguous compressed insns. In
682 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
683 is_c_sw_insn instead of is_sw_insn.
684 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
685 (riscv_software_single_step): New.
686 * riscv-tdep.h (riscv_software_single_step): Declare.
687
688 * riscv-tdep.c (riscv_isa_xlen): Drop static.
689 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
690
691 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
692
693 PR gdb/18050:
694 * target.c (dispose_inferior): Don't dispose of inferiors that are
695 already killed.
696
697 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
698
699 * remote.c (remote_target::download_tracepoint): Change char* to
700 const char*.
701
702 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
703
704 * target.h (target_options_to_string): Return an std::string.
705 * target.c (str_comma_list_concat_elem): Return void, use
706 std::string.
707 (do_option): Likewise.
708 (target_options_to_string): Return an std::string.
709 * linux-nat.c (linux_nat_target::wait): Adjust.
710 * target-debug.h (target_debug_print_options): Adjust.
711
712 2018-08-07 Tom Tromey <tom@tromey.com>
713
714 * Makefile.in (CPPFLAGS): New variable.
715 (INTERNAL_CPPFLAGS): Use it.
716
717 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
718
719 * NEWS: Mention the index cache.
720
721 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
722
723 * common/pathstuff.h (get_standard_cache_dir): New.
724 * common/pathstuff.c (get_standard_cache_dir): New.
725 * build-id.h (build_id_to_string): New.
726 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
727 DEBUG_STR_SUFFIX): Move to here.
728 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
729 DEBUG_STR_SUFFIX): Move from there.
730 (write_psymtabs_to_index): Make non-static, add basename
731 parameter. Write to temporary files, rename when done.
732 (save_gdb_index_command): Adjust call to
733 write_psymtabs_to_index.
734 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
735 field.
736 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
737 (get_gdb_index_contents_from_cache): New.
738 (get_gdb_index_contents_from_cache_dwz): New.
739 (dwarf2_initialize_objfile): Read index from cache.
740 (dwarf2_build_psymtabs): Save to index.
741 * dwarf-index-cache.h: New file.
742 * dwarf-index-cache.c: New file.
743 * dwarf-index-write.h: New file.
744
745 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
746
747 * gnulib/aclocal.m4: Re-generate.
748 * gnulib/config.in: Re-generate.
749 * gnulib/configure: Re-generate.
750 * gnulib/import/Makefile.am: Re-generate.
751 * gnulib/import/Makefile.in: Re-generate.
752 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
753 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
754 * gnulib/import/m4/mkdir.m4: New file.
755 * gnulib/import/mkdir.c: New file.
756 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
757 module.
758
759 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
760
761 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
762 * common/scoped_mmap.c: New file.
763 * common/scoped_mmap.h (destroy): New method.
764 (~scoped_mmap, reset): Use destroy.
765 (scoped_mmap): New move constructor.
766 (mmap_file): New declaration.
767 * unittests/scoped_mmap-selftests.c (test_normal,
768 test_invalid_filename, run_tests): New functions.
769 (_initialize_scoped_mmap_selftests): Register selftest.
770
771 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
772
773 * dwarf2read.c (read_gdb_index_from_section): Rename to...
774 (read_gdb_index_from_buffer): ... this. Remove section
775 parameter, add buffer parameter.
776 (get_gdb_index_contents_ftype,
777 get_gdb_index_contents_dwz_ftype): New typedefs.
778 (dwarf2_read_gdb_index): Add callback parameters to get the
779 index contents.
780 (get_gdb_index_contents_from_section): New.
781 (dwarf2_initialize_objfile): Update call to
782 dwarf2_read_gdb_index.
783
784 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
785
786 * common/filestuff.h (gdb_fopen_cloexec): New overload.
787 (gdb_open_cloexec): Likewise.
788 * nat/linux-osdata.c (command_from_pid): Use string_printf.
789 (commandline_from_pid): Likewise.
790 (linux_xfer_osdata_threads): Likewise.
791 (linux_xfer_osdata_fds): Likewise.
792 * ada-lang.c (is_package_name): Likewise.
793 * auxv.c (procfs_xfer_auxv): Likewise.
794 * breakpoint.c (print_one_breakpoint_location): Use
795 uiout::field_fmt.
796 (print_one_catch_solib): Use string_printf.
797 * coff-pe-read.c (add_pe_exported_sym): Likewise.
798 (add_pe_forwarded_sym): Likewise.
799 * dwarf2read.c (create_type_unit_group): Likewise.
800 (build_error_marker_type): Likewise.
801 * infcall.c (get_function_name): Likewise.
802 * valprint.c (print_converted_chars_to_obstack): Likewise.
803 * xtensa-tdep.c (xtensa_register_type): Likewise.
804
805 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
806
807 * remote.c (remote_target::download_tracepoint): Fix format
808 string errors.
809
810 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
811
812 * tracefile.c: Include common/byte-vector.h.
813 (trace_save): Change type of buf to gdb::byte_vector. Initialize
814 with trace_regblock_size if needed. Update uses of buf.
815
816 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
817
818 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
819 std::vector<unsigned char>.
820 * tracepoint.c (collection_list::collection_list): Remove
821 m_regs_mask initializer from initializer list. Resize
822 m_regs_mask using the largest remote register number.
823 (collection_list::add_remote_register): Remove size check on
824 m_regs_mask. Use at to access element.
825 (collection_list::stringify): Change type of temp_buf to
826 gdb::char_vector. Update uses of temp_buf. Resize if needed to
827 stringify the register mask. Use pack_hex_byte for the register
828 mask.
829
830 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
831
832 * tracepoint.h (class collection_list) <add_register>: Remove.
833 <add_remote_register, add_ax_registers, add_local_register>:
834 Declare.
835 <add_memrange>: Add scope parameter.
836 * tracepoint.c (encode_actions_1): Likewise.
837 (collection_list::add_register): Rename to ...
838 (collection_list::add_remote_register): ... this. Update
839 comment.
840 (collection_list::add_ax_registers, add_local_register): New
841 methods.
842 (collection_list::add_memrange): Add scope parameter. Call
843 add_local_register instead of add_register.
844 (finalize_tracepoint_aexpr): New function.
845 (collection_list::collect_symbol): Update calls to add_memrange.
846 Call add_local_register instead of add_register. Call
847 add_ax_registers. Call finalize_tracepoint_aexpr.
848 (encode_actions_1): Get remote regnos for $reg action. Call
849 add_remote_register, add_ax_registers, and add_local_register.
850 Update call to add_memrange. Call finalize_tracepoint_aexpr.
851 (validate_actionline): Call finalize_tracepoint_aexpr.
852
853 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
854
855 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
856 Replace array buf with gdb::char_vector buf, of size
857 get_remote_packet_size (). Replace references to buf and
858 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
859 and xsnprintf with snprintf. Raise errors if the buffer is too
860 small.
861
862 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
863
864 * remote.c (remote_target::download_tracepoint): Fix the has_more
865 predicate in the QTDP action list iteration.
866
867 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
868
869 * remote.c (remote_target::download_tracepoint): Fix indentation
870 in for block.
871
872 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
873
874 * proc-api.c (_initialize_proc_api): Remove c, unused.
875 * procfs.c (procfs_init_inferior): Remove signals, unused.
876 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
877 unused.
878
879 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
880 Andrew Burgess <andrew.burgess@embecosm.com>
881
882 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
883 'W_STOPCODE (0)' as this could be ambiguous.
884
885 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
886
887 * ser-tcp.c (net_open): Fix thinko when deciding whether to
888 disable TCP's Nagle algorithm (use "ai_protocol" instead of
889 "ai_socktype").
890
891 2018-08-02 Tom Tromey <tom@tromey.com>
892
893 PR symtab/16842.
894 * dwarf2read.c (read_func_scope): Set symtab on template parameter
895 symbols.
896 (process_structure_scope): Likewise.
897
898 2018-08-02 Xavier Roirand <roirand@adacore.com>
899
900 PR gdb/22629:
901 * darwin-nat.c (darwin_kill_inferior): Fix handling of
902 kill inferior.
903
904 2018-08-02 Tom Tromey <tom@tromey.com>
905
906 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
907 (darwin_suspend_inferior, darwin_resume_inferior)
908 (darwin_decode_notify_message, darwin_resume_inferior_threads)
909 (darwin_check_new_threads): Check result of get_darwin_inferior.
910
911 2018-07-31 Joel Brobecker <brobecker@adacore.com>
912
913 GDB 8.1.1 released.
914
915 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
916
917 * varobj.c (varobj_get_path_expr_parent): Report an error if
918 parent is a dynamic varobj.
919
920 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
921
922 * gnulib/aclocal.m4: Re-generate.
923 * gnulib/config.in: Re-generate.
924 * gnulib/configure: Re-generate.
925 * gnulib/import/Makefile.in: Re-generate.
926 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
927 * gnulib/import/m4/onceonly.m4: Re-generate.
928
929 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
930
931 * target-descriptions.c (struct xml_test_tdesc): New.
932 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
933 (record_xml_tdesc): Update.
934 (maintenance_check_xml_descriptions): Update.
935 * target-descriptions.h (record_xml_tdesc): Update comment.
936
937 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
938
939 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
940 checking array bounds are defined.
941
942 2018-07-30 Tom Tromey <tom@tromey.com>
943
944 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
945 irreflexivity violation.
946
947 2018-07-30 Tom Tromey <tom@tromey.com>
948
949 * cli/cli-decode.c (lookup_cmd): Remove lint code.
950 * value.c (unpack_long): Remove lint code.
951 * valops.c (value_ind): Remove lint code.
952 * valarith.c (value_x_binop, value_x_unop, value_equal)
953 (value_pos): Remove lint code.
954
955 2018-07-28 Tom de Vries <tdevries@suse.de>
956
957 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
958 with undefined upper bound as <optimized out>.
959
960 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
961
962 * gcore.in: Rename variable "name" to "prefix". Expand
963 "usage" text.
964
965 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
966
967 * windows-nat.c (windows_nat_target::create_inferior): Update to
968 call close() in global namespace.
969
970 2018-07-26 Tom Tromey <tom@tromey.com>
971
972 * dwarf-index-write.c (add_address_entry): Don't add objfile
973 offsets.
974 * dbxread.c (find_stab_function): Rename from
975 find_stab_function_addr. Return a bound_minimal_symbol.
976 (read_dbx_symtab): Use raw_text_low, raw_text_high.
977 Don't add objfile offsets.
978 (end_psymtab): Use raw_text_low, raw_text_high,
979 MSYMBOL_VALUE_RAW_ADDRESS.
980 (read_ofile_symtab): Update.
981 (process_one_symbol): Update.
982 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
983 offsets.
984 (dw2_relocate): Remove.
985 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
986 searching addrmap.
987 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
988 Update.
989 (process_psymtab_comp_unit_reader, add_partial_symbol)
990 (add_partial_subprogram, dwarf2_ranges_read): Update.
991 (load_partial_dies): Update.
992 (add_address_entry): Don't add objfile offsets.
993 (dwarf2_build_include_psymtabs): Update.
994 (create_addrmap_from_aranges): Don't add objfile offsets.
995 (dw2_find_pc_sect_compunit_symtab): Update.
996 * mdebugread.c (parse_symbol): Don't add objfile offsets.
997 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
998 Update.
999 (parse_partial_symbols): Don't add objfile offsets. Use
1000 raw_text_low, raw_text_high. Update.
1001 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
1002 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
1003 or call 'relocate' quick function. Clear psymbol_map.
1004 * psympriv.h (struct partial_symbol) <address>: Add section
1005 offset.
1006 <set_unrelocated_address>: Rename from set_address.
1007 <raw_text_low, raw_text_high>: New methods.
1008 <text_low, text_high>: Add objfile parameter.
1009 (add_psymbol_to_bcache): Add 'section' parameter. Call
1010 set_unrelocated_address.
1011 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
1012 (find_pc_psymbol): Update.
1013 (fixup_psymbol_section, relocate_psymtabs): Remove.
1014 (dump_psymtab, psym_functions): Update.
1015 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
1016 parameter.
1017 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
1018 (start_psymtab_common): Update.
1019 * symfile-debug.c (debug_qf_relocate): Remove.
1020 (debug_sym_quick_functions): Update.
1021 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
1022 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
1023 Update.
1024
1025 2018-07-26 Tom Tromey <tromey@redhat.com>
1026
1027 * dbxread.c (end_psymtab): Use text_high_valid and
1028 text_low_valid.
1029 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
1030 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
1031 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
1032 Update comment.
1033 <text_low_valid, text_high_valid>: New fields.
1034 <set_text_low, set_text_high>: Update.
1035 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
1036
1037 2018-07-26 Tom Tromey <tom@tromey.com>
1038
1039 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
1040 Update.
1041 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
1042 textlow and texthigh fields.
1043 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
1044 Update.
1045 * mdebugread.c (parse_lines, parse_partial_symbols)
1046 (psymtab_to_symtab_1): Update.
1047 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
1048 Rename fields. Update comment. Now private.
1049 <text_low, text_high, set_text_low, set_text_high>: New methods.
1050 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
1051 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
1052 (start_psymtab_common, maintenance_info_psymtabs)
1053 (maintenance_check_psymtabs): Update.
1054 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
1055 texthigh fields.
1056 (scan_xcoff_symtab): Update.
1057
1058 2018-07-26 Tom Tromey <tromey@redhat.com>
1059
1060 * psympriv.h (struct partial_symbol) <unrelocated_address,
1061 address, set_address>: New methods.
1062 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
1063 (fixup_psymbol_section, relocate_psymtabs): Update.
1064 (print_partial_symbols): Add 'objfile' parameter. Update.
1065 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
1066 Update.
1067
1068 2018-07-26 Tom Tromey <tom@tromey.com>
1069
1070 * dwarf-index-write.c (write_psymbols, debug_names::insert)
1071 (debug_names::write_psymbols): Update.
1072 * psympriv.h (struct partial_symbol): Derive from
1073 general_symbol_info.
1074 <obj_section>: New method.
1075 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
1076 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
1077 (find_pc_sect_psymbol, fixup_psymbol_section)
1078 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
1079 (print_partial_symbols, recursively_search_psymtabs)
1080 (compare_psymbols, psymbol_hash, psymbol_compare)
1081 (add_psymbol_to_bcache, maintenance_check_psymtabs)
1082 (psymbol_name_matches, psym_fill_psymbol_map): Update.
1083
1084 2018-07-26 Tom Tromey <tromey@redhat.com>
1085
1086 * dbxread.c (end_psymtab): Remove dead code.
1087
1088 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
1089
1090 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
1091 DWARF unwinders are disabled.
1092 * dwarf2-frame.c: Add dwarf2read.h include.
1093 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
1094 disabled.
1095 (dwarf2_frame_unwinders_enabled_p): Define.
1096 (show_dwarf_unwinders_enabled_p): New function.
1097 (_initialize_dwarf2_frame): Register switch to control DWARF
1098 unwinder use.
1099 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
1100 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
1101 (show_dwarf_cmdlist): Remove static keyword.
1102 * dwarf2read.h (set_dwarf_cmdlist): Declare.
1103 (show_dwarf_cmdlist): Declare.
1104 * NEWS: Document new feature.
1105
1106 2018-07-26 Tom de Vries <tdevries@suse.de>
1107
1108 PR breakpoints/23366
1109 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
1110
1111 2018-07-26 Tom de Vries <tdevries@suse.de>
1112
1113 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
1114 DW_AT_count can't be translated to a dynamic prop.
1115
1116 2018-07-25 Tom de Vries <tdevries@suse.de>
1117
1118 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
1119 try/catch.
1120
1121 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
1122
1123 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
1124
1125 2018-07-25 Joel Brobecker <brobecker@adacore.com>
1126
1127 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
1128
1129 2018-07-24 Keith Seitz <keiths@redhat.comt
1130
1131 PR symtab/23010
1132 * dwarf2read.c (dw2_add_symbol_to_list): New function.
1133 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
1134 instead of add_symbol_to_list.
1135 (read_file_scope): Call prepare_one_comp_unit before reading
1136 any other DIEs.
1137
1138 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
1139
1140 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
1141
1142 2018-07-24 Tom Tromey <tom@tromey.com>
1143
1144 * utils.c (malloc, realloc, free): Don't declare.
1145 * configure, config.in: Rebuild.
1146 * configure.ac: Don't check for declarations of free, malloc, or
1147 realloc.
1148
1149 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1150
1151 * aarch64-linux-nat.c
1152 (aarch64_linux_nat_target::stopped_data_address): Remove unused
1153 variable.
1154 * arm-linux-nat.c (fetch_regs): Likewise.
1155 (store_regs): Likewise.
1156 (fetch_vfp_regs): Likewise.
1157 (store_vfp_regs): Likewise.
1158 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
1159 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
1160 (arm_linux_nat_target::insert_watchpoint): Likewise.
1161 (arm_linux_nat_target::remove_watchpoint): Likewise.
1162 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
1163 Likewise.
1164 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
1165 Likewise.
1166 * ppc-linux-nat.c (fetch_register): Likewise.
1167 (fetch_all_gp_regs): Likewise.
1168 (fetch_ppc_registers): Likewise.
1169 (store_all_gp_regs): Likewise.
1170 (store_ppc_registers): Likewise.
1171 (hwdebug_insert_point): Likewise.
1172 (can_use_watchpoint_cond_accel): Likewise.
1173 * remote-sim.c (gdb_os_write_stdout): Likewise.
1174
1175 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1176 Tom Tromey <tom@tromey.com>
1177
1178 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
1179 test for it.
1180 * configure: Rebuild.
1181
1182 2018-07-22 Tom Tromey <tom@tromey.com>
1183
1184 * regformats/regdat.sh: Define xmltarget_${name} inside
1185 #ifndef IN_PROCESS_AGENT.
1186
1187 2018-07-22 Tom Tromey <tom@tromey.com>
1188
1189 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
1190
1191 2018-07-22 Tom Tromey <tom@tromey.com>
1192
1193 * symfile.c (reread_symbols): Notify iter, not objfile.
1194
1195 2018-07-22 Tom Tromey <tom@tromey.com>
1196
1197 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
1198 Use arch_ops.
1199 (ravenscar_thread_target::prepare_to_store): Likewise.
1200
1201 2018-07-22 Tom Tromey <tom@tromey.com>
1202
1203 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
1204 unused variable. Call value_fetch_lazy when needed.
1205 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
1206 Remove unused variable. Call value_fetch_lazy when needed.
1207
1208 2018-07-22 Tom Tromey <tom@tromey.com>
1209
1210 * m32c-tdep.c (mark_dma): Return void.
1211 (make_regs): Remove unused declarations.
1212
1213 2018-07-22 Tom Tromey <tom@tromey.com>
1214
1215 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
1216 cmdscm_get_valid_command_smob_arg_unsafe for effect.
1217 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
1218 bkscm_get_valid_block_smob_arg_unsafe for effect.
1219
1220 2018-07-22 Tom Tromey <tom@tromey.com>
1221
1222 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
1223 value_type.
1224
1225 2018-07-22 Tom Tromey <tom@tromey.com>
1226
1227 * windows-nat.c (saved_context): Conditionally define.
1228 * remote.c (remote_target::remote_btrace_maybe_reopen):
1229 Conditionally declare "warned".
1230 * inflow.c (sigquit_ours): Conditionally define.
1231 (new_tty): Move "tty" declaration inside #if.
1232 * guile/guile.c (guile_datadir): Conditionally define.
1233 * charset.c (set_be_le_names): Move some declarations inside #if.
1234 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
1235 #if.
1236 (parse_xml_btrace_conf): Likewise.
1237
1238 2018-07-22 Tom Tromey <tom@tromey.com>
1239
1240 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
1241
1242 2018-07-22 Tom Tromey <tom@tromey.com>
1243
1244 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
1245 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
1246 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
1247 * buildsym-legacy.c (get_macro_table): Remove unused variable.
1248 * stack.c (frame_apply_level_command): Remove unused variable.
1249 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
1250 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
1251 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
1252 unused variable.
1253 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
1254 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
1255 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
1256 variable.
1257 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
1258 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
1259 variable.
1260 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
1261 Remove unused variable.
1262 * cli/cli-script.c (recurse_read_control_structure): Remove unused
1263 variable.
1264 * common/tdesc.c (print_xml_feature::visit): Remove unused
1265 variable.
1266 * compile/compile-object-load.c (store_regs): Remove unused
1267 variables.
1268 * complaints.c (clear_complaints): Remove unused variable.
1269 * corelow.c (core_target_open): Remove unused variable.
1270 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
1271 variable.
1272 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
1273 variable.
1274 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
1275 variable.
1276 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
1277 variable.
1278 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
1279 variable.
1280 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
1281 variable.
1282 * ia64-tdep.c (examine_prologue): Remove unused variable.
1283 * infcall.c (run_inferior_call): Remove unused variable.
1284 * inferior.c (exit_inferior): Remove unused variable.
1285 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
1286 * linespec.c (decode_line_2): Remove unused variable.
1287 * linux-nat.c (super_close): Remove.
1288 * linux-tdep.c (linux_info_proc): Remove unused variable.
1289 * mi/mi-main.c (mi_execute_command): Remove unused variable.
1290 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
1291 Remove unused variable.
1292 * parse.c (find_minsym_type_and_address): Remove unused variable.
1293 * printcmd.c (info_symbol_command, printf_floating): Remove unused
1294 variable.
1295 * python/py-breakpoint.c (bppy_set_commands): Remove unused
1296 variable.
1297 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
1298 variables.
1299 * record-btrace.c (record_btrace_target::store_registers): Remove
1300 unused variable.
1301 (cmd_show_record_btrace_cpu): Remove unused variable.
1302 * riscv-tdep.c (riscv_register_reggroup_p)
1303 (riscv_push_dummy_call, riscv_return_value): Remove unused
1304 variable.
1305 * rust-exp.y (literal): Remove unused variable.
1306 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
1307 unused variable.
1308 <STRUCTOP_ANONYMOUS>: Likewise.
1309 * s390-linux-tdep.c (s390_linux_init_abi_31)
1310 (s390_linux_init_abi_64): Remove unused variable.
1311 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
1312 (file_select_thread, net_windows_open, _initialize_ser_windows):
1313 Remove unused variables.
1314 * symtab.c (find_pc_sect_line): Remove unused variable.
1315 * target-memory.c (compute_garbled_blocks): Remove unused
1316 variable.
1317 (target_write_memory_blocks): Remove unused variable.
1318 * target.c (target_stack::unpush): Remove unused variables.
1319 * tracepoint.c (start_tracing, all_tracepoint_actions)
1320 (merge_uploaded_trace_state_variables)
1321 (print_one_static_tracepoint_marker): Remove unused variable.
1322 * unittests/basic_string_view/element_access/char/1.cc (test01):
1323 Remove unused variable.
1324 * windows-nat.c (windows_continue, windows_add_all_dlls)
1325 (do_initial_windows_stuff, windows_nat_target::create_inferior):
1326 Remove unused variables.
1327
1328 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
1329
1330 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
1331 attr_profile in HAVE_ELF.
1332 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
1333 HAVE_ELF.
1334
1335 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
1336
1337 * frame.c (frame_register_unwind): Change parameter name.
1338 (frame_unwind_register): Likewise.
1339 (frame_unwind_register_value): Likewise.
1340 (frame_unwind_register_signed): Likewise.
1341 (frame_unwind_register_unsigned): Likewise.
1342 * frame.h (frame_register_unwind): Likewise.
1343 (frame_unwind_register): Likewise.
1344 (frame_unwind_register_value): Likewise.
1345 (frame_unwind_register_signed): Likewise.
1346 (frame_unwind_register_unsigned): Likewise.
1347 (frame_unwind_arch): Likewise.
1348
1349 2018-07-20 Maciej W. Rozycki <macro@mips.com>
1350
1351 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
1352 ISA maintenance.
1353
1354 2018-07-20 Maciej W. Rozycki <macro@mips.com>
1355
1356 * mips-linux-nat.c (mips_linux_nat_target::read_description):
1357 Call `get_ptrace_pid' rather than extracting the ptrace PID by
1358 hand.
1359
1360 2018-07-20 Keith Seitz <keiths@redhat.com>
1361
1362 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
1363 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
1364 m_compunit_symtab, m_language>: Add "m_" prefix.
1365 Update all uses.
1366 * buildsym.c: Update all uses.
1367
1368 2018-07-20 Tom Tromey <tom@tromey.com>
1369
1370 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
1371 * buildsym.h (record_line_ftype): Remove typedef.
1372
1373 2018-07-20 Tom Tromey <tom@tromey.com>
1374
1375 * buildsym-legacy.h (augment_type_symtab): Don't declare.
1376 (end_expandable_symtab): Likewise.
1377 (end_symtab_get_static_block): Likewise.
1378 (end_symtab_from_static_block): Likewise.
1379 * buildsym-legacy.c (augment_type_symtab): Remove.
1380 (end_expandable_symtab): Remove.
1381 (end_symtab_get_static_block): Remove.
1382 (end_symtab_from_static_block): Remove.
1383
1384 2018-07-20 Tom Tromey <tom@tromey.com>
1385
1386 * dwarf2read.c: Include buildsym.h.
1387 (struct dwarf2_cu) <builder>: New method.
1388 (fixup_go_packaging): Update.
1389 (process_full_comp_unit, process_full_type_unit): Update. Don't
1390 use scoped_free_pendings.
1391 (using_directives): Add "cu" parameter, remove "language".
1392 (read_import_statement, setup_type_unit_groups, )
1393 (read_func_scope, read_lexical_block_scope)
1394 (dwarf2_record_block_ranges, read_namespace): Update.
1395 (lnp_state_machine::lnp_state_machine): Add cu parameter.
1396 (lnp_state_machine::handle_end_sequence): Update.
1397 (class lnp_state_machine) <m_cu>: New member.
1398 <m_record_line_callback>: Remove.
1399 <m_currently_recording_lines>: New member.
1400 (lnp_state_machine::handle_set_file): Update.
1401 (noop_record_line): Remove.
1402 (dwarf_record_line_p): Add cu parameter.
1403 (dwarf_record_line_1, dwarf_finish_line): Likewise.
1404 (lnp_state_machine::record_line)
1405 (lnp_state_machine::lnp_state_machine)
1406 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
1407 (dwarf_decode_lines): Update.
1408 (dwarf2_start_subfile): Add cu parameter.
1409 (dwarf2_start_symtab, new_symbol): Update.
1410 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
1411 Remove dwarf2_per_objfile parameter.
1412 (dwarf_decode_macros): Update.
1413
1414 2018-07-20 Tom Tromey <tom@tromey.com>
1415
1416 * stabsread.c (define_symbol): Update.
1417 * buildsym-legacy.h (get_buildsym_compunit): Declare.
1418 * dwarf2read.c (new_symbol): Update.
1419 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
1420 * cp-namespace.c: Include buildsym.h.
1421 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
1422 * buildsym-legacy.c (get_buildsym_compunit): New function.
1423
1424 2018-07-20 Tom Tromey <tom@tromey.com>
1425
1426 * xcoffread.c: Include buildsym-legacy.h.
1427 * windows-nat.c: Include buildsym-legacy.h.
1428 * stabsread.c: Include buildsym-legacy.h.
1429 * mdebugread.c: Include buildsym-legacy.h.
1430 * buildsym-legacy.h: New file.
1431 * buildsym-legacy.c: New file, from buildsym.c.
1432 * go32-nat.c: Include buildsym-legacy.h.
1433 * dwarf2read.c: Include buildsym-legacy.h.
1434 * dbxread.c: Include buildsym-legacy.h.
1435 * cp-namespace.c: Include buildsym-legacy.h.
1436 * coffread.c: Include buildsym-legacy.h.
1437 * buildsym.h: Move some contents to buildsym-legacy.h.
1438 * buildsym.c: Include buildsym-legacy.h. Move many functions to
1439 buildsym-legacy.c.
1440 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
1441
1442 2018-07-20 Tom Tromey <tom@tromey.com>
1443
1444 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
1445 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
1446 (buildsym_compunit::buildsym_compunit)
1447 (buildsym_compunit::~buildsym_compunit)
1448 (buildsym_compunit::get_macro_table): Define.
1449
1450 2018-07-20 Tom Tromey <tom@tromey.com>
1451
1452 * buildsym.c (reset_symtab_globals): Remove.
1453 (buildsym_compunit::end_symtab_from_static_block): Update.
1454 (buildsym_compunit::augment_type_symtab): Update.
1455 (end_symtab_from_static_block): Call free_buildsym_compunit.
1456 (augment_type_symtab, end_symtab, end_expandable_symtab):
1457 Likewise.
1458
1459 2018-07-20 Tom Tromey <tom@tromey.com>
1460
1461 * arch-utils.c: Do not include buildsym.h.
1462 * mipsread.c: Do not include buildsym.h.
1463 * machoread.c: Do not include buildsym.h.
1464 * elfread.c: Do not include buildsym.h.
1465
1466 2018-07-20 Tom Tromey <tom@tromey.com>
1467
1468 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
1469 initialization.
1470 (buildsym_compunit): Add new constructor.
1471 (struct buildsym_compunit) <get_last_source_file, finish_block,
1472 record_block_range, start_subfile, patch_subfile_names,
1473 push_subfile, pop_subfile, record_line, get_compunit_symtab,
1474 set_last_source_start_addr, get_last_source_start_addr,
1475 get_local_using_directives, set_local_using_directives,
1476 get_global_using_directives, outermost_context_p,
1477 get_current_context_stack, get_context_stack_depth,
1478 get_current_subfile, get_local_symbols, get_file_symbols,
1479 get_global_symbols, record_debugformat, record_producer,
1480 push_context, pop_context, end_symtab_get_static_block,
1481 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
1482 New public methods.
1483 <record_pending_block, finish_block_internal, make_blockvector,
1484 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
1485 private methods.
1486 Update all users.
1487
1488 2018-05-22 Tom Tromey <tom@tromey.com>
1489
1490 * buildsym.c (record_pending_block): Move earlier. Remove objfile
1491 parameter.
1492 (finish_block_internal): Update.
1493
1494 2018-07-20 Tom Tromey <tom@tromey.com>
1495
1496 * buildsym.c (record_pending_block): Move earlier. Remove objfile
1497 parameter.
1498 (finish_block_internal): Update.
1499
1500 2018-07-20 Tom Tromey <tom@tromey.com>
1501
1502 * buildsym.h (EXTERN): Don't define or undef.
1503 * buildsym.c (EXTERN): Don't define.
1504
1505 2018-07-20 Tom Tromey <tom@tromey.com>
1506
1507 * buildsym.c: Remove TODO comment.
1508
1509 2018-07-20 Tom Tromey <tom@tromey.com>
1510
1511 * coffread.c (coff_symtab_read): Update.
1512 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
1513 (xcoff_new_init): Update.
1514 * mipsread.c (mipscoff_new_init): Update.
1515 * mdebugread.c (mdebug_build_psymtabs): Update.
1516 * elfread.c (elf_new_init): Update.
1517 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
1518 Update.
1519 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
1520 (coffstab_build_psymtabs, elfstab_build_psymtabs)
1521 (stabsect_build_psymtabs): Update.
1522 * buildsym.h (buildsym_init): Don't declare.
1523 * buildsym.c: Update comment.
1524 (prepare_for_building): Remove.
1525 (start_symtab, restart_symtab): Update.
1526 (reset_symtab_globals): Update comment.
1527 (buildsym_init): Remove.
1528
1529 2018-07-20 Tom Tromey <tom@tromey.com>
1530
1531 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
1532 * stabsread.c (patch_block_stabs, define_symbol, read_type)
1533 (read_enum_type, common_block_start, common_block_end)
1534 (cleanup_undefined_types_1, finish_global_stabs): Update.
1535 * mdebugread.c (psymtab_to_symtab_1): Update.
1536 * dwarf2read.c (fixup_go_packaging, read_func_scope)
1537 (read_lexical_block_scope, new_symbol): Update.
1538 * dbxread.c (process_one_symbol): Update.
1539 * coffread.c (coff_symtab_read, process_coff_symbol)
1540 (coff_read_enum_type): Update.
1541 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
1542 declare.
1543 (get_local_symbols, get_file_symbols, get_global_symbols): New
1544 functions.
1545 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
1546 m_global_symbols.
1547 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
1548 (~scoped_free_pendings): Update.
1549 (finish_block, prepare_for_building, reset_symtab_globals)
1550 (end_symtab_get_static_block, end_symtab_with_blockvector)
1551 (augment_type_symtab, push_context): Update.
1552 (get_local_symbols, get_file_symbols, get_global_symbols): New
1553 functions.
1554 (buildsym_init): Update.
1555
1556 2018-07-20 Tom Tromey <tom@tromey.com>
1557
1558 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
1559 (process_full_type_unit): Likewise.
1560 (dwarf2_start_symtab): Set list_in_scope.
1561
1562 2018-07-20 Tom Tromey <tom@tromey.com>
1563
1564 * dwarf2read.c (process_psymtab_comp_unit_reader)
1565 (build_type_psymtabs_reader): Do not set list_in_scope.
1566
1567 2018-07-20 Tom Tromey <tom@tromey.com>
1568
1569 * buildsym.c (free_pendings): Remove.
1570 (add_symbol_to_list, scoped_free_pendings)
1571 (finish_block_internal, buildsym_init): Update.
1572
1573 2018-07-20 Tom Tromey <tom@tromey.com>
1574
1575 * xcoffread.c (read_xcoff_symtab): Update.
1576 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
1577 Update.
1578 * dbxread.c (process_one_symbol): Update.
1579 * coffread.c (coff_symtab_read): Update.
1580 * buildsym.h (finish_block): Update.
1581 * buildsym.c (finish_block): Remove "listhead" argument.
1582 (end_symtab_get_static_block): Update.
1583
1584 2018-07-20 Tom Tromey <tom@tromey.com>
1585
1586 * buildsym.h (class scoped_free_pendings): Remove constructor.
1587 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
1588 method.
1589 <m_pending_block_obstack, m_pending_blocks>: New members.
1590 (pending_block_obstack, pending_blocks): Remove.
1591 (scoped_free_pendings::scoped_free_pendings): Default.
1592 (~scoped_free_pendings): Update.
1593 (free_pending_blocks): Remove.
1594 (finish_block_internal, record_pending_block, make_blockvector)
1595 (end_symtab_get_static_block, augment_type_symtab, push_context)
1596 (buildsym_init): Update.
1597
1598 2018-07-20 Tom Tromey <tom@tromey.com>
1599
1600 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
1601 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
1602 members.
1603 (pending_addrmap, pending_addrmap_obstack)
1604 (pending_addrmap_interesting): Remove.
1605 (scoped_free_pendings, record_block_range, make_blockvector)
1606 (prepare_for_building, reset_symtab_globals, buildsym_init):
1607 Update.
1608
1609 2018-07-20 Tom Tromey <tom@tromey.com>
1610
1611 * xcoffread.c (process_linenos): Update.
1612 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
1613 * mdebugread.c (psymtab_to_symtab_1): Update.
1614 * dwarf2read.c (setup_type_unit_groups)
1615 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
1616 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
1617 * dbxread.c (process_one_symbol): Update.
1618 * coffread.c (coff_symtab_read, enter_linenos)
1619 (process_coff_symbol): Update.
1620 * buildsym.h (current_subfile): Don't declare.
1621 (get_current_subfile): Declare.
1622 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
1623 member.
1624 (start_subfile, free_buildsym_compunit, push_subfile)
1625 (prepare_for_building, start_symtab): Update.
1626 (get_current_subfile): New function.
1627
1628 2018-07-20 Tom Tromey <tom@tromey.com>
1629
1630 * coffread.c (coff_symtab_read): Update.
1631 * xcoffread.c (read_xcoff_symtab): Update.
1632 * dwarf2read.c (new_symbol): Update.
1633 (read_func_scope, read_lexical_block_scope): Update.
1634 * dbxread.c (process_one_symbol): Update.
1635 * buildsym.h (context_stack, context_stack_depth): Don't declare.
1636 (outermost_context_p): Remove macro.
1637 (outermost_context_p, get_current_context_stack)
1638 (get_context_stack_depth): Declare.
1639 (pop_context): Return struct context_stack.
1640 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
1641 member.
1642 (context_stack_size): Remove.
1643 (INITIAL_CONTEXT_STACK_SIZE): Remove.
1644 (prepare_for_building, end_symtab_get_static_block)
1645 (augment_type_symtab, push_context): Update.
1646 (pop_context): Return struct context_stack.
1647 (outermost_context_p, get_current_context_stack)
1648 (get_context_stack_depth): New functions.
1649 (buildsym_init): Update.
1650
1651 2018-07-20 Tom Tromey <tom@tromey.com>
1652
1653 * rust-exp.y: Now a pure parser. Update all rules.
1654 (%union): Move earlier.
1655 (current_parser, work_obstack): Remove globals.
1656 (rust_parser, ~rust_parser): Update.
1657 (class rust_parser) <copy_name, concat3, crate_name, super_name,
1658 lex_character, lex_number, lex_string, lex_identifier,
1659 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
1660 convert_name, convert_params_to_expression,
1661 convert_ast_to_expression, ast_basic_type, ast_operation,
1662 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
1663 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
1664 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
1665 ast_array_type, ast_slice_type, ast_reference_type,
1666 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
1667 (rust_parse): Update.
1668 (rustyyerror, rustyylex): Add parser parameter.
1669 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
1670 (rust_lex_stringish_test, rust_lex_test_sequence)
1671 (rust_lex_test_trailing_dot, rust_lex_test_completion)
1672 (rust_lex_test_push_back, rust_lex_tests): Update.
1673
1674 2018-07-19 Pedro Alves <palves@redhat.com>
1675
1676 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
1677 gdb::unique_xmalloc_ptr.
1678 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
1679 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
1680 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
1681 copy-initialization.
1682 * guile/scm-pretty-print.c (ppscm_print_children): Use
1683 gdb::unique_xmalloc_ptr instead of cleanups.
1684 (gdbscm_apply_val_pretty_printer): Remove cleanups.
1685 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
1686 gdb::unique_xmalloc_ptr.
1687 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1688 Adjust to use gdb::unique_xmalloc_ptr.
1689 * guile/scm-utils.c (extract_arg): Adjust.
1690 * guile/scm-value.c (gdbscm_value_field): Adjust to use
1691 gdb::unique_xmalloc_ptr instead of a cleanup.
1692
1693 2018-07-19 Tom Tromey <tom@tromey.com>
1694
1695 * utils.c (do_value_free_to_mark)
1696 (make_cleanup_value_free_to_mark): Remove.
1697 * utils.h (make_cleanup_value_free_to_mark): Remove.
1698
1699 2018-07-19 Pedro Alves <palves@redhat.com>
1700
1701 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
1702 forwarding reference.
1703
1704 2018-07-18 Pedro Alves <palves@redhat.com>
1705
1706 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
1707 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
1708 cleanup.
1709
1710 2018-07-18 Pedro Alves <palves@redhat.com>
1711
1712 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
1713 exceptions.
1714 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
1715 (gdbscm_wrap): New.
1716 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
1717 directly instead of a cleanup.
1718 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
1719 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
1720 (vlscm_binop_gdbthrow): New, factored out from ...
1721 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
1722 (vlscm_rich_compare): Use gdbscm_wrap.
1723 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
1724 instead of a cleanup.
1725 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
1726 cleanup.
1727 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1728 Use xfree directly instead of a cleanup.
1729 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
1730 Adjust to use gdbscm_wrap and scoped_value_mark.
1731 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
1732 (gdbscm_value_address, gdbscm_value_dereference)
1733 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
1734 scoped_value_mark.
1735 (gdbscm_value_dynamic_type): Use scoped_value_mark.
1736 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
1737 scoped_value_mark.
1738 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
1739 gdbscm_wrap and scoped_value_mark.
1740 (gdbscm_value_to_string): Use xfree directly instead of a
1741 cleanup. Move 'buffer' unique_ptr to TRY scope.
1742 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
1743 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
1744 scoped_value_mark.
1745 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
1746 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
1747 scoped_value_mark.
1748 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
1749 gdbscm_wrap.
1750
1751 2018-07-18 Tom de Vries <tdevries@suse.de>
1752
1753 * findvar.c (default_read_var_value): Also resolve dynamic type for
1754 LOC_OPTIMIZED_OUT vars.
1755
1756 2018-07-18 Maciej W. Rozycki <macro@mips.com>
1757
1758 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
1759 decoding.
1760
1761 2018-07-17 Tom Tromey <tom@tromey.com>
1762
1763 * guile/scm-param.c (pascm_set_func, pascm_show_func)
1764 (compute_enum_list, pascm_set_param_value_x)
1765 (gdbscm_parameter_value): Update.
1766 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
1767 (gdbscm_scm_to_host_string): Update.
1768 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
1769 Update.
1770 * guile/scm-cmd.c (cmdscm_add_completion): Update.
1771 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
1772 * guile/scm-string.c (gdbscm_scm_to_string): Return
1773 unique_xmalloc_ptr.
1774 (gdbscm_scm_to_host_string): Likewise.
1775
1776 2018-07-17 Tom Tromey <tom@tromey.com>
1777
1778 * guile/guile.c (gdbscm_eval_from_control_command): Update.
1779 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
1780 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
1781 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
1782 unique_xmalloc_ptr.
1783
1784 2018-07-17 Tom Tromey <tom@tromey.com>
1785
1786 * guile/scm-param.c (pascm_signal_setshow_error): Update.
1787 * guile/guile-internal.h (gdbscm_exception_message_to_string):
1788 Update.
1789 * guile/scm-cmd.c (cmdscm_function): Update.
1790 * guile/scm-pretty-print.c
1791 (ppscm_print_exception_unless_memory_error): Update.
1792 * guile/scm-exception.c (gdbscm_exception_message_to_string):
1793 Return unique_xmalloc_ptr.
1794
1795 2018-07-17 Tom Tromey <tom@tromey.com>
1796
1797 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
1798 Use string_printf.
1799
1800 2018-07-17 Jim Wilson <jimw@sifive.com>
1801
1802 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
1803 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
1804 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
1805 unecessary braces after EF_RISCV_RVC test. Delete call to
1806 set_gdbarch_decr_pc_after_break.
1807
1808 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
1809 RISCV_LAST_FP_REGNUM + 1.
1810 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
1811
1812 2018-07-17 Tom Tromey <tom@tromey.com>
1813
1814 * configure.ac: Remove --disable-gdbcli.
1815 * configure: Rebuild.
1816 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
1817 (SUBDIR_CLI_CFLAGS): Remove.
1818 (SFILES): Use SUBDIR_CLI_SRCS.
1819 (COMMON_OBS): Use SUBDIR_CLI_OBS.
1820
1821 2018-07-17 Tom Tromey <tom@tromey.com>
1822
1823 PR gdb/18624:
1824 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
1825
1826 2018-07-16 Jim Wilson <jimw@sifive.com>
1827
1828 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
1829
1830 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1831
1832 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
1833 variable.
1834 (libunwind_frame_sniffer): Likewise.
1835 (libunwind_frame_prev_register): Likewise.
1836 (libunwind_sigtramp_frame_sniffer): Likewise.
1837 * ia64-tdep.c (ia64_access_reg): Likewise.
1838 (ia64_access_rse_reg): Likewise.
1839 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
1840 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
1841
1842 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1843
1844 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
1845
1846 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1847
1848 * remote-sim.c (gdbsim_target::close,
1849 gdbsim_target::mourn_inferior): Remove unused variables.
1850
1851 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
1852
1853 * ia64-tdep.c (ktab_buf): New global.
1854 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
1855 (get_kernel_table): Adjust.
1856
1857 2018-07-16 Tom Tromey <tom@tromey.com>
1858
1859 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
1860 * dwarf2read.c (using_directives, new_symbol): Use
1861 outermost_context_p.
1862 * dbxread.c (process_one_symbol): Use outermost_context_p.
1863 * coffread.c (coff_symtab_read): Use outermost_context_p.
1864
1865 2018-07-16 Tom Tromey <tom@tromey.com>
1866
1867 * dwarf2read.c (using_directives, read_func_scope)
1868 (read_lexical_block_scope): Update.
1869 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1870 * buildsym.h (local_using_directives, global_using_directives):
1871 Don't declare.
1872 (get_local_using_directives, set_local_using_directives)
1873 (get_global_using_directives): Declare.
1874 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
1875 m_global_using_directives>: New members.
1876 (finish_block_internal, prepare_for_building)
1877 (reset_symtab_globals, end_symtab_get_static_block)
1878 (push_context): Update.
1879 (get_local_using_directives, set_local_using_directives)
1880 (get_global_using_directives): New functions.
1881 (buildsym_init): Update.
1882
1883 2018-07-16 Tom Tromey <tom@tromey.com>
1884
1885 * xcoffread.c (xcoff_initial_scan): Don't call
1886 free_pending_blocks.
1887 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
1888 * buildsym.h (class scoped_free_pendings): Add constructor.
1889 (free_pending_blocks): Don't declare.
1890 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
1891 (free_pending_blocks): Now static.
1892
1893 2018-07-16 Tom Tromey <tom@tromey.com>
1894
1895 * buildsym.h (push_subfile, pop_subfile): Update declarations.
1896 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
1897 member.
1898 (struct subfile_stack): Remove.
1899 (subfile_stack): Remove.
1900 (push_subfile, pop_subfile, buildsym_init): Update.
1901
1902 2018-07-16 Tom Tromey <tom@tromey.com>
1903
1904 * buildsym.c (push_subfile): Use gdb_assert.
1905 (pop_subfile): Use gdb_assert.
1906
1907 2018-07-16 Tom Tromey <tom@tromey.com>
1908
1909 * buildsym.h (merge_symbol_lists): Remove.
1910 * buildsym.c (merge_symbol_lists): Remove.
1911
1912 2018-07-16 Tom Tromey <tom@tromey.com>
1913
1914 * stabsread.c (scan_file_globals): Update comment.
1915 * stabsread.h (scan_file_globals): Move from buildsym.h.
1916 * buildsym.h (scan_file_globals): Move to stabsread.h.
1917
1918 2018-07-16 Tom Tromey <tom@tromey.com>
1919
1920 * xcoffread.c (xcoff_new_init): Update.
1921 * mipsread.c (mipscoff_new_init): Update.
1922 * mdebugread.c (mdebug_build_psymtabs): Update.
1923 * elfread.c (elf_new_init): Update.
1924 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
1925 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
1926 * buildsym.h (buildsym_new_init): Don't declare.
1927 * buildsym.c (buildsym_new_init): Remove.
1928
1929 2018-07-16 Tom Tromey <tom@tromey.com>
1930
1931 * stabsread.h (within_function): Move from buildsym.h.
1932 * stabsread.c (start_stabs): Clear within_function.
1933 * coffread.c (coff_start_symtab): Clear within_function.
1934 * buildsym.h (within_function): Move to stabsread.h.
1935 * buildsym.c (prepare_for_building): Update.
1936
1937 2018-07-16 Tom Tromey <tom@tromey.com>
1938
1939 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
1940 * dwarf2read.c (dwarf2_start_symtab): Don't set
1941 processing_gcc_compilation.
1942 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
1943
1944 2018-07-16 Tom Tromey <tom@tromey.com>
1945
1946 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
1947 (next_symbol_text_func): Move from buildsym.h.
1948 * stabsread.c (hashname): Move from buildsym.c.
1949 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
1950 (next_symbol_text_func, hashname): Move to stabsread.h.
1951 * buildsym.c: Don't include bcache.h
1952 (hashname): Move to stasbread.c.
1953
1954 2018-07-16 Tom Tromey <tom@tromey.com>
1955
1956 * buildsym.h (context_stack_size): Don't declare.
1957 * buildsym.c (context_stack_size): New global.
1958
1959 2018-07-16 Tom Tromey <tom@tromey.com>
1960
1961 * dbxread.c (processing_acc_compilation): New global.
1962 * buildsym.h (processing_acc_compilation): Don't declare.
1963
1964 2018-07-16 Tom Tromey <tom@tromey.com>
1965
1966 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
1967 * dbxread.c (read_ofile_symtab): Update.
1968 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
1969 * buildsym.h (last_source_start_addr): Remove.
1970 (set_last_source_start_addr, get_last_source_start_addr):
1971 Declare.
1972 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
1973 parameter.
1974 (struct buildsym_compunit) <m_last_source_start_addr>: New
1975 member.
1976 (prepare_for_building): Remove start_addr parameter.
1977 (start_symtab, restart_symtab, end_symtab_get_static_block)
1978 (end_symtab_with_blockvector): Update.
1979 (set_last_source_start_addr, get_last_source_start_addr): New
1980 functions.
1981
1982 2018-07-16 Tom Tromey <tom@tromey.com>
1983
1984 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
1985 member.
1986 (have_line_numbers): Remove.
1987 (record_line, prepare_for_building, end_symtab_get_static_block)
1988 (augment_type_symtab): Update.
1989
1990 2018-07-16 Tom Tromey <tom@tromey.com>
1991
1992 * buildsym.c (~buildsym_compunit): Free the macro table.
1993 (struct buildsym_compunit) <get_macro_table, release_macros>: New
1994 methods.
1995 <m_pending_macros>: New member.
1996 (pending_macros): Remove.
1997 (~scoped_free_pendings, get_macro_table, prepare_for_building)
1998 (reset_symtab_globals, end_symtab_get_static_block)
1999 (end_symtab_with_blockvector, augment_type_symtab)
2000 (buildsym_init): Update.
2001
2002 2018-07-16 Tom Tromey <tom@tromey.com>
2003
2004 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
2005 parameter.
2006 (buildsym_compunit::set_last_source_file): New method.
2007 <m_last_source_file>: New member.
2008 (prepare_for_building): Remove "name" parameter.
2009 (start_symtab, restart_symtab, reset_symtab_globals): Update.
2010 (last_source_file): Remove.
2011 (set_last_source_file, get_last_source_file): Update.
2012
2013 2018-07-16 Tom Tromey <tom@tromey.com>
2014
2015 * buildsym.c (prepare_for_building): Add assert.
2016
2017 2018-07-16 Tom Tromey <tom@tromey.com>
2018
2019 * buildsym.c (~buildsym_compunit): Update.
2020 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
2021 (start_subfile, patch_subfile_names)
2022 (end_symtab_with_blockvector): Update.
2023
2024 2018-07-16 Tom Tromey <tom@tromey.com>
2025
2026 * buildsym.c (struct buildsym_compunit): Add constructor,
2027 destructor, initializers.
2028 (start_buildsym_compunit): Remove.
2029 (free_buildsym_compunit): Use "delete".
2030 (start_symtab, restart_symtab): Use "new".
2031
2032 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
2033
2034 * symfile.c (set_objfile_default_section_offset): Remove struct
2035 keyword.
2036
2037 2018-07-14 Stafford Horne <shorne@gmail.com>
2038
2039 * (Responsible Maintainers): Add myself as or1k maintainer.
2040
2041 2018-07-13 Tom Tromey <tom@tromey.com>
2042
2043 * symfile.c (set_objfile_default_section_offset): Use extra braces
2044 around initializer.
2045
2046 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
2047
2048 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
2049 non-branching basr.
2050
2051 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2052
2053 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2054 unittests/cli-utils-selftests.c
2055 * unittests/cli-utils-selftests.c: New file.
2056
2057 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2058
2059 * NEWS: Mention new commands. Mention change to 'thread apply'.
2060
2061 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2062
2063 * thread.c (thr_try_catch_cmd): New function.
2064 (thread_apply_all_command): Handle qcs flags.
2065 (thread_apply_command): Handle qcs flags.
2066 (taas_command): New function.
2067 (tfaas_command): New function.
2068 (_initialize_thread): Update to setup the new commands 'taas
2069 and 'tfaas'. Change doc string for 'thread apply'.
2070
2071 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2072
2073 * stack.c: (trailing_outermost_frame): New function, mostly
2074 extracted from backtrace_command_1.
2075 (leading_innermost_frame): New function.
2076 (backtrace_command_1): Update to call trailing_outermost_frame.
2077 (frame_apply_command_count): New function.
2078 (frame_apply_level_command): New function.
2079 (frame_apply_all_command): New function.
2080 (frame_apply_command): New function.
2081 (faas_command): New function.
2082 (frame_cmd_list): New variable.
2083 (_initialize_stack): Update to setup the new commands 'frame apply'
2084 and 'faas'.
2085
2086 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2087
2088 * cli-utils.c (number_or_range_parser::get_number): Only handle
2089 numbers or convenience var as numbers.
2090 (parse_flags): New function.
2091 (parse_flags_qcs): New function.
2092 (number_or_range_parser::finished): Ensure parsing end is detected
2093 before end of string.
2094 * cli-utils.h (parse_flags): New function.
2095 (parse_flags_qcs): New function.
2096 (number_or_range_parser): Remove m_finished bool.
2097 (number_or_range_parser::skip_range): Set m_in_range to false.
2098
2099 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
2100
2101 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
2102 on Windows.
2103
2104 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
2105 Jan Kratochvil <jan.kratochvil@redhat.com>
2106 Paul Fertser <fercerpav@gmail.com>
2107 Tsutomu Seki <sekiriki@gmail.com>
2108 Pedro Alves <palves@redhat.com>
2109
2110 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2111 'unittests/parse-connection-spec-selftests.c'.
2112 (COMMON_SFILES): Add 'common/netstuff.c'.
2113 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
2114 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
2115 * common/netstuff.c: New file.
2116 * common/netstuff.h: New file.
2117 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
2118 (wait_for_connect): Update comment. New parameter
2119 'gdb::optional<int> sock' instead of 'struct serial *scb'.
2120 Use 'sock' directly instead of 'scb->fd'.
2121 (try_connect): New function, with code from 'net_open'.
2122 (net_open): Rewrite main loop to deal with multiple
2123 sockets/addresses. Handle IPv6-style hostnames; implement
2124 support for IPv6 connections.
2125 * unittests/parse-connection-spec-selftests.c: New file.
2126
2127 2018-07-11 Pedro Alves <palves@redhat.com>
2128
2129 PR gdb/23377
2130 * remote.c (remote_target::remote_detach_pid): Call
2131 set_current_process.
2132
2133 2018-07-11 Pedro Alves <palves@redhat.com>
2134
2135 * h8300-tdep.c (h8300_gdbarch_init): Remove
2136 set_gdbarch_ecoff_reg_to_regnum calls.
2137
2138 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
2139
2140 PR c++/23373
2141 * c-typeprint.c (c_type_print_base_struct_union): Don't print
2142 offsets/sizes for static members of a class/struct.
2143
2144 2018-07-11 Alan Hayward <alan.hayward@arm.com>
2145
2146 * target-descriptions.c (tdesc_register_bitsize): Rename.
2147 * target-descriptions.h (tdesc_register_bitsize): Likewise.
2148 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
2149 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
2150
2151 2018-07-10 Tom Tromey <tom@tromey.com>
2152
2153 * breakpoint.c (moribund_locations): Now static and a
2154 std::vector.
2155 (breakpoint_init_inferior, moribund_breakpoint_here_p)
2156 (build_bpstat_chain, update_global_location_list)
2157 (breakpoint_retire_moribund): Update.
2158 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
2159 VEC.
2160
2161 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
2162
2163 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
2164 (riscv_register_reggroup_p): Use new function, remove unneeded
2165 parenthesis.
2166 (riscv_push_dummy_call): Extend assert to compare against xlen or
2167 flen based on register type.
2168
2169 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
2170
2171 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
2172
2173 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
2174
2175 * remote.c (show_hardware_watchpoint_limit): New function.
2176 (show_hardware_watchpoint_length_limit): New function.
2177 (show_hardware_breakpoint_limit): New function.
2178 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
2179 where appropriate, update help text.
2180
2181 2018-07-09 Tom Tromey <tom@tromey.com>
2182
2183 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
2184 (CLIBS): Don't mention NAT_CLIBS.
2185
2186 2018-07-09 Tom Tromey <tom@tromey.com>
2187
2188 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
2189 (LIBGDB_OBS, clean mostlyclean): Update.
2190 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
2191
2192 2018-07-09 Tom Tromey <tom@tromey.com>
2193
2194 * Makefile.in (%.c: %.y): Use ECHO_YACC.
2195 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
2196 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
2197
2198 2018-07-09 Tom Tromey <tom@tromey.com>
2199
2200 * Makefile.in (ALLDEPFILES): Remove exec.c.
2201 (COMMON_OBS): Remove exec.o.
2202 (COMMON_SFILES): Add exec.c.
2203
2204 2018-07-09 Tom Tromey <tom@tromey.com>
2205
2206 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
2207
2208 2018-07-09 Tom Tromey <tom@tromey.com>
2209
2210 * Makefile.in (clean mostlyclean): Remove stamp-version.
2211 (version.c): Depend on stamp-version.
2212 (stamp-version): New rule, from version.c rule.
2213
2214 2018-07-09 Tom Tromey <tom@tromey.com>
2215
2216 * Makefile.in (init.c): Depend on stamp-init.
2217 (stamp-init): New rule, from init.c rule.
2218 (clean mostlyclean): Remove stamp-init.
2219
2220 2018-07-09 Tom Tromey <tom@tromey.com>
2221
2222 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
2223 SUBDIR_GCC_COMPILE_SRCS.
2224
2225 2018-07-09 Tom Tromey <tom@tromey.com>
2226
2227 * Makefile.in (init.c): Remove some unused sed rules.
2228
2229 2018-07-09 Tom Tromey <tom@tromey.com>
2230
2231 * Makefile.in (TSOBS): Remove.
2232 (INIT_FILES): Update.
2233 (LIBGDB_OBS): Update.
2234 (COMMON_SFILES): Add inflow.c.
2235 (SFILES): Remove inflow.c.
2236
2237 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
2238
2239 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
2240
2241 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
2242
2243 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
2244 get_saveloc_name, is_signal_frame_name, step_name,
2245 init_remote_name, create_addr_space_name,
2246 destroy_addr_space_name, search_unwind_table_name,
2247 find_dyn_list_name): Constify.
2248
2249 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
2250
2251 * darwin-nat.c (darwin_pthread_kill): New function.
2252 (darwin_resume_thread): Use darwin_pthread_kill.
2253
2254 2018-07-05 Tom de Vries <tdevries@suse.de>
2255
2256 * macroexp.c (macro_buffer) <operator=>: New member function.
2257
2258 2018-07-04 Tom Tromey <tom@tromey.com>
2259
2260 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
2261
2262 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
2263
2264 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
2265 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
2266 * maint.c: Likewise.
2267 * top.c: Likewise.
2268
2269 2018-07-04 Joel Brobecker <brobecker@adacore.com>
2270
2271 * NEWS: Create a new section for the next release branch.
2272 Rename the section of the current branch, now that it has
2273 been cut.
2274
2275 2018-07-04 Joel Brobecker <brobecker@adacore.com>
2276
2277 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
2278 * version.in: Bump version to 8.2.50.DATE-git.
2279
2280 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
2281 Pedro Alves <palves@redhat.com>
2282
2283 * linux-nat.c (linux_init_ptrace): Rename to ...
2284 (linux_init_ptrace_procfs): ... this. Call
2285 linux_proc_init_warnings.
2286 (linux_nat_target::post_attach)
2287 (linux_nat_target::post_startup_inferior): Adjust.
2288 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
2289 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
2290
2291 2018-07-04 Tom de Vries <tdevries@suse.de>
2292
2293 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
2294 check ...
2295 (read_comp_unit_head): ... here.
2296
2297 2018-07-03 Tom Tromey <tom@tromey.com>
2298
2299 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
2300 (stop_tracing, tstatus_command)
2301 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
2302 (print_one_static_tracepoint_marker): Update.
2303 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
2304 std::vector.
2305 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
2306 VEC.
2307 (all_tracepoints, static_tracepoints_here): Return std::vector.
2308
2309 2018-07-03 Tom Tromey <tom@tromey.com>
2310
2311 * common/ptid.c (ptid_equal): Remove.
2312 * common/ptid.h (ptid_equal): Don't declare.
2313 * ada-tasks.c: Update.
2314 * breakpoint.c: Update.
2315 * common/agent.c: Update.
2316 * corelow.c: Update.
2317 * darwin-nat-info.c: Update.
2318 * darwin-nat.c: Update.
2319 * dcache.c: Update.
2320 * dtrace-probe.c: Update.
2321 * dummy-frame.c: Update.
2322 * fbsd-nat.c: Update.
2323 * frame.c: Update.
2324 * gdbthread.h: Update.
2325 * gnu-nat.c: Update.
2326 * go32-nat.c: Update.
2327 * inf-loop.c: Update.
2328 * inf-ptrace.c: Update.
2329 * infcall.c: Update.
2330 * infcmd.c: Update.
2331 * inflow.c: Update.
2332 * infrun.c: Update.
2333 * linux-fork.c: Update.
2334 * linux-nat.c: Update.
2335 * linux-thread-db.c: Update.
2336 * mi/mi-cmd-var.c: Update.
2337 * mi/mi-interp.c: Update.
2338 * mi/mi-main.c: Update.
2339 * nto-procfs.c: Update.
2340 * ppc-linux-tdep.c: Update.
2341 * procfs.c: Update.
2342 * python/py-inferior.c: Update.
2343 * python/py-record-btrace.c: Update.
2344 * python/py-record.c: Update.
2345 * ravenscar-thread.c: Update.
2346 * regcache.c: Update.
2347 * remote-sim.c: Update.
2348 * remote.c: Update.
2349 * sol-thread.c: Update.
2350 * solib.c: Update.
2351 * target.c: Update.
2352 * tui/tui-stack.c: Update.
2353 * varobj.c: Update.
2354 * windows-nat.c: Update.
2355 * windows-tdep.c: Update.
2356
2357 2018-07-03 Tom Tromey <tom@tromey.com>
2358
2359 * common/ptid.c (ptid_match): Remove.
2360 * common/ptid.h (ptid_match): Don't declare.
2361 * fbsd-nat.c: Update.
2362 * infcmd.c: Update.
2363 * infrun.c: Update.
2364 * linux-nat.c: Update.
2365 * record-btrace.c: Update.
2366 * regcache.c: Update.
2367 * remote.c: Update.
2368
2369 2018-07-03 Tom Tromey <tom@tromey.com>
2370
2371 * common/ptid.c (ptid_tid_p): Remove.
2372 * common/ptid.h (ptid_tid_p): Don't declare.
2373 * sol-thread.c: Update.
2374
2375 2018-07-03 Tom Tromey <tom@tromey.com>
2376
2377 * common/ptid.c (ptid_lwp_p): Remove.
2378 * common/ptid.h (ptid_lwp_p): Don't declare.
2379 * fbsd-nat.c: Update.
2380 * linux-nat.c: Update.
2381 * nat/linux-procfs.c: Update.
2382 * nat/x86-linux-dregs.c: Update.
2383 * sol-thread.c: Update.
2384
2385 2018-07-03 Tom Tromey <tom@tromey.com>
2386
2387 * common/ptid.c (ptid_is_pid): Remove.
2388 * common/ptid.h (ptid_is_pid): Don't declare.
2389 * infrun.c: Update.
2390 * linux-nat.c: Update.
2391 * mi/mi-interp.c: Update.
2392 * remote.c: Update.
2393 * thread.c: Update.
2394
2395 2018-07-03 Tom Tromey <tom@tromey.com>
2396
2397 * common/ptid.c (ptid_get_tid): Remove.
2398 * common/ptid.h (ptid_get_tid): Don't declare.
2399 * ada-tasks.c: Update.
2400 * aix-thread.c: Update.
2401 * bsd-uthread.c: Update.
2402 * darwin-nat.c: Update.
2403 * fbsd-nat.c: Update.
2404 * i386-darwin-nat.c: Update.
2405 * infrun.c: Update.
2406 * linux-tdep.c: Update.
2407 * nto-procfs.c: Update.
2408 * ppc-ravenscar-thread.c: Update.
2409 * python/py-infthread.c: Update.
2410 * ravenscar-thread.c: Update.
2411 * sol-thread.c: Update.
2412 * sparc-ravenscar-thread.c: Update.
2413 * windows-nat.c: Update.
2414
2415 2018-07-03 Tom Tromey <tom@tromey.com>
2416
2417 * common/ptid.c (ptid_get_lwp): Remove.
2418 * common/ptid.h (ptid_get_lwp): Don't declare.
2419 * aarch64-linux-nat.c: Update.
2420 * ada-tasks.c: Update.
2421 * aix-thread.c: Update.
2422 * amd64-linux-nat.c: Update.
2423 * arm-linux-nat.c: Update.
2424 * corelow.c: Update.
2425 * fbsd-nat.c: Update.
2426 * fbsd-tdep.c: Update.
2427 * gnu-nat.c: Update.
2428 * i386-cygwin-tdep.c: Update.
2429 * i386-gnu-nat.c: Update.
2430 * i386-linux-nat.c: Update.
2431 * ia64-linux-nat.c: Update.
2432 * inf-ptrace.c: Update.
2433 * infrun.c: Update.
2434 * linux-fork.c: Update.
2435 * linux-nat.c: Update.
2436 * linux-tdep.c: Update.
2437 * linux-thread-db.c: Update.
2438 * mips-linux-nat.c: Update.
2439 * nat/aarch64-linux-hw-point.c: Update.
2440 * nat/aarch64-linux.c: Update.
2441 * nat/linux-btrace.c: Update.
2442 * nat/linux-osdata.c: Update.
2443 * nat/linux-procfs.c: Update.
2444 * nat/x86-linux-dregs.c: Update.
2445 * obsd-nat.c: Update.
2446 * ppc-fbsd-nat.c: Update.
2447 * ppc-linux-nat.c: Update.
2448 * procfs.c: Update.
2449 * python/py-infthread.c: Update.
2450 * ravenscar-thread.c: Update.
2451 * remote.c: Update.
2452 * s390-linux-nat.c: Update.
2453 * sol-thread.c: Update.
2454 * sol2-tdep.c: Update.
2455 * spu-linux-nat.c: Update.
2456 * x86-linux-nat.c: Update.
2457 * xtensa-linux-nat.c: Update.
2458
2459 2018-07-03 Tom Tromey <tom@tromey.com>
2460
2461 * common/ptid.c (ptid_get_pid): Remove.
2462 * common/ptid.h (ptid_get_pid): Don't declare.
2463 * aarch64-linux-nat.c: Update.
2464 * ada-lang.c: Update.
2465 * aix-thread.c: Update.
2466 * alpha-bsd-nat.c: Update.
2467 * amd64-fbsd-nat.c: Update.
2468 * amd64-linux-nat.c: Update.
2469 * arm-linux-nat.c: Update.
2470 * arm-nbsd-nat.c: Update.
2471 * auxv.c: Update.
2472 * break-catch-syscall.c: Update.
2473 * breakpoint.c: Update.
2474 * bsd-uthread.c: Update.
2475 * corelow.c: Update.
2476 * ctf.c: Update.
2477 * darwin-nat.c: Update.
2478 * fbsd-nat.c: Update.
2479 * fbsd-tdep.c: Update.
2480 * gcore.c: Update.
2481 * gnu-nat.c: Update.
2482 * hppa-nbsd-nat.c: Update.
2483 * hppa-obsd-nat.c: Update.
2484 * i386-fbsd-nat.c: Update.
2485 * ia64-linux-nat.c: Update.
2486 * inf-ptrace.c: Update.
2487 * infcmd.c: Update.
2488 * inferior.c: Update.
2489 * inferior.h: Update.
2490 * inflow.c: Update.
2491 * infrun.c: Update.
2492 * linux-fork.c: Update.
2493 * linux-nat.c: Update.
2494 * linux-tdep.c: Update.
2495 * linux-thread-db.c: Update.
2496 * m68k-bsd-nat.c: Update.
2497 * mi/mi-interp.c: Update.
2498 * mi/mi-main.c: Update.
2499 * mips-linux-nat.c: Update.
2500 * mips-nbsd-nat.c: Update.
2501 * mips64-obsd-nat.c: Update.
2502 * nat/aarch64-linux-hw-point.c: Update.
2503 * nat/aarch64-linux.c: Update.
2504 * nat/linux-btrace.c: Update.
2505 * nat/linux-osdata.c: Update.
2506 * nat/linux-procfs.c: Update.
2507 * nat/x86-linux-dregs.c: Update.
2508 * nto-procfs.c: Update.
2509 * obsd-nat.c: Update.
2510 * ppc-linux-nat.c: Update.
2511 * ppc-nbsd-nat.c: Update.
2512 * ppc-obsd-nat.c: Update.
2513 * proc-service.c: Update.
2514 * procfs.c: Update.
2515 * python/py-inferior.c: Update.
2516 * python/py-infthread.c: Update.
2517 * ravenscar-thread.c: Update.
2518 * record.c: Update.
2519 * remote-sim.c: Update.
2520 * remote.c: Update.
2521 * rs6000-nat.c: Update.
2522 * s390-linux-nat.c: Update.
2523 * sh-nbsd-nat.c: Update.
2524 * sol-thread.c: Update.
2525 * sparc-nat.c: Update.
2526 * sparc64-tdep.c: Update.
2527 * spu-linux-nat.c: Update.
2528 * spu-tdep.c: Update.
2529 * target-debug.h: Update.
2530 * target.c: Update.
2531 * thread.c: Update.
2532 * tid-parse.c: Update.
2533 * tracefile-tfile.c: Update.
2534 * vax-bsd-nat.c: Update.
2535 * windows-nat.c: Update.
2536 * x86-linux-nat.c: Update.
2537 * x86-nat.c: Update.
2538
2539 2018-07-03 Tom Tromey <tom@tromey.com>
2540
2541 * common/ptid.c (pid_to_ptid): Remove.
2542 * common/ptid.h (pid_to_ptid): Don't declare.
2543 * aix-thread.c: Update.
2544 * arm-linux-nat.c: Update.
2545 * common/ptid.c: Update.
2546 * common/ptid.h: Update.
2547 * corelow.c: Update.
2548 * ctf.c: Update.
2549 * darwin-nat.c: Update.
2550 * fbsd-nat.c: Update.
2551 * fork-child.c: Update.
2552 * gnu-nat.c: Update.
2553 * go32-nat.c: Update.
2554 * inf-ptrace.c: Update.
2555 * infcmd.c: Update.
2556 * inferior.c: Update.
2557 * infrun.c: Update.
2558 * linux-fork.c: Update.
2559 * linux-nat.c: Update.
2560 * nat/aarch64-linux-hw-point.c: Update.
2561 * nat/fork-inferior.c: Update.
2562 * nat/x86-linux-dregs.c: Update.
2563 * nto-procfs.c: Update.
2564 * obsd-nat.c: Update.
2565 * procfs.c: Update.
2566 * progspace.c: Update.
2567 * remote.c: Update.
2568 * rs6000-nat.c: Update.
2569 * s390-linux-nat.c: Update.
2570 * sol-thread.c: Update.
2571 * spu-linux-nat.c: Update.
2572 * target.c: Update.
2573 * top.c: Update.
2574 * tracefile-tfile.c: Update.
2575 * windows-nat.c: Update.
2576
2577 2018-07-03 Tom Tromey <tom@tromey.com>
2578
2579 * common/ptid.h (ptid_build): Don't declare.
2580 * common/ptid.c (ptid_build): Remove.
2581 * aix-thread.c: Update.
2582 * bsd-kvm.c: Update.
2583 * bsd-uthread.c: Update.
2584 * common/agent.c: Update.
2585 * common/ptid.c: Update.
2586 * common/ptid.h: Update.
2587 * corelow.c: Update.
2588 * darwin-nat.c: Update.
2589 * fbsd-nat.c: Update.
2590 * gnu-nat.c: Update.
2591 * linux-fork.c: Update.
2592 * linux-nat.c: Update.
2593 * linux-thread-db.c: Update.
2594 * nat/linux-osdata.c: Update.
2595 * nat/linux-procfs.c: Update.
2596 * nto-procfs.c: Update.
2597 * obsd-nat.c: Update.
2598 * proc-service.c: Update.
2599 * procfs.c: Update.
2600 * ravenscar-thread.c: Update.
2601 * remote-sim.c: Update.
2602 * remote.c: Update.
2603 * sol-thread.c: Update.
2604 * target.c: Update.
2605 * windows-nat.c: Update.
2606
2607 2018-07-03 Tom Tromey <tom@tromey.com>
2608
2609 * infrun.c (follow_exec): Use exit_inferior_silent.
2610 * inferior.c (exit_inferior_num_silent): Remove.
2611 * inferior.h (exit_inferior_num_silent): Don't declare.
2612
2613 2018-07-03 Tom Tromey <tom@tromey.com>
2614
2615 PR cli/23340:
2616 * darwin-nat.c (darwin_attach_pid): Reset inferior and
2617 inferior_ptid on error.
2618
2619 2018-07-02 Maciej W. Rozycki <macro@mips.com>
2620 Simon Marchi <simon.marchi@polymtl.ca>
2621
2622 PR tdep/8282
2623 * disasm.h (gdb_disassembler): Add
2624 `m_disassembler_options_holder'. member
2625 * disasm.c (get_all_disassembler_options): New function.
2626 (gdb_disassembler::gdb_disassembler): Use it.
2627 (gdb_buffered_insn_length_init_dis): Likewise.
2628 (gdb_buffered_insn_length): Adjust accordingly.
2629 (set_disassembler_options): Handle options with arguments.
2630 (show_disassembler_options_sfunc): Likewise. Add a leading new
2631 line if showing options with descriptions.
2632 (disassembler_options_completer): Adapt to using the
2633 `disasm_options_and_args_t' structure.
2634 * mips-tdep.c (mips_disassembler_options): New variable.
2635 (mips_disassembler_options_o32): Likewise.
2636 (mips_disassembler_options_n32): Likewise.
2637 (mips_disassembler_options_n64): Likewise.
2638 (gdb_print_insn_mips): Don't set `disassembler_options'.
2639 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
2640 functions.
2641 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
2642 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
2643 `gdbarch_disassembler_options_implicit' and
2644 `gdbarch_valid_disassembler_options'.
2645 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
2646 `disasm_options_and_args_t' structure.
2647 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
2648 method.
2649 (valid_disassembler_options): Switch from `disasm_options_t' to
2650 the `disasm_options_and_args_t' structure.
2651 * NEWS: Document `set disassembler-options' support for the MIPS
2652 target.
2653 * gdbarch.h: Regenerate.
2654 * gdbarch.c: Regenerate.
2655
2656 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
2657
2658 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
2659
2660 2018-06-29 Joel Brobecker <brobecker@adacore.com>
2661
2662 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
2663 parameter in call to amd64_target_description.
2664 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
2665 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
2666 (amd64fbsd_init_abi): Likewise.
2667 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
2668 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
2669 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
2670 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
2671
2672 2018-06-29 Pedro Alves <palves@redhat.com>
2673
2674 * gdb/amd64-tdep.h (amd64_create_target_description): Add
2675 "segments" parameter.
2676 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
2677 (_initialize_amd64_tdep): Update call to
2678 amd64_create_target_description.
2679 (amd64_target_description): Add "segments" parameter. Adjust
2680 the implementation to use it.
2681 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
2682 call to amd64_create_target_description.
2683 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
2684 * gdb/arch/amd64.h (amd64_create_target_description): Add
2685 "segments" register.
2686 * gdb/arch/amd64.c (amd64_create_target_description): Add
2687 "segments" parameter. Call create_feature_i386_64bit_segments
2688 only if SEGMENTS is true.
2689 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
2690 call to amd64_create_target_description.
2691
2692 2018-06-29 Pedro Alves <palves@redhat.com>
2693
2694 * thread.c (thread_target_id_str): New, factored out from ...
2695 (print_thread_info_1): ... here. Use it to compute the max
2696 "Target Id" column width.
2697
2698 2018-06-29 Pedro Alves <palves@redhat.com>
2699
2700 * remote.c (remote_target::extra_thread_info): Delete
2701 'display_buf' and 'n' locals. from the cache, regardless of
2702 packet mechanims is in use. Use cache for qThreadExtra and qP
2703 methods too.
2704
2705 2018-06-29 Pedro Alves <palves@redhat.com>
2706
2707 * blockframe.c (find_pc_sect_containing_function): New function.
2708 * breakpoint.c (print_breakpoint_location): Don't call
2709 find_pc_sect_function.
2710 * linespec.c (create_sals_line_offset): Record the location's
2711 symbol in the sal.
2712 * linespec.c (convert_address_location_to_sals): Fill in sal's
2713 symbol with find_pc_sect_containing_function.
2714 * symtab.c (find_function_start_sal): Rename to ...
2715 (find_function_start_sal_1): ... this.
2716 (find_function_start_sal): Reimplement as wrapper around
2717 find_function_start_sal_1, and use
2718 find_pc_sect_containing_function to fill in the sal's symbol.
2719 (find_function_start_sal(symbol*, bool)): Adjust.
2720 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
2721 comments.
2722 (find_pc_sect_containing_function): Declare.
2723
2724 2018-06-29 Pedro Alves <palves@redhat.com>
2725
2726 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
2727 true if the the location has no symbol.
2728
2729 2018-06-28 Tom Tromey <tom@tromey.com>
2730
2731 * NEWS: Mention --enable-codesign.
2732 * silent-rules.mk (ECHO_SIGN): New variable.
2733 * configure.ac: Add --enable-codesign.
2734 * configure: Rebuild.
2735 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
2736 (gdb$(EXEEXT)): Optionally invoke codesign.
2737
2738 2018-06-28 Pedro Alves <palves@redhat.com>
2739
2740 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
2741 comments.
2742 (switch_to_thread_no_regs): Adjust comment.
2743 * infcmd.c (stop_pc): Delete.
2744 (post_create_inferior, info_program_command): Replace references
2745 to stop_pc with references to thread_info->suspend.stop_pc.
2746 * inferior.h (stop_pc): Delete declaration.
2747 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
2748 (handle_inferior_event_1, handle_signal_stop)
2749 (process_event_stop_test, keep_going_stepped_thread)
2750 (handle_step_into_function, handle_step_into_function_backward)
2751 (print_stop_location): Replace references to stop_pc with
2752 references to thread_info->suspend.stop_pc.
2753 (struct infcall_suspend_state) <stop_pc>: Delete field.
2754 (save_infcall_suspend_state, restore_infcall_suspend_state):
2755 Remove references to inf_stat->stop_pc.
2756 * linux-fork.c (fork_load_infrun_state): Likewise.
2757 * record-btrace.c (record_btrace_set_replay): Likewise.
2758 * record-full.c (record_full_goto_entry): Likewise.
2759 * remote.c (print_one_stopped_thread): Likewise.
2760 * target.c (target_resume): Extend comment.
2761 * thread.c (set_executing_thread): New.
2762 (set_executing): Use it.
2763 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
2764 Remove references to stop_pc.
2765
2766 2018-06-28 Pedro Alves <palves@redhat.com>
2767
2768 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
2769 Moving fetching stop_pc until after ecs->event_thread is refreshed.
2770
2771 2018-06-28 Tom Tromey <tom@tromey.com>
2772
2773 * coffread.c (coff_symfile_finish): Update.
2774 * xcoffread.c (xcoff_symfile_finish): Update.
2775 * elfread.c (elf_symfile_finish): Update.
2776 * symfile.h (dwarf2_free_objfile): Don't declare.
2777 * dwarf2read.c (_initialize_dwarf2_read): Use
2778 register_objfile_data_with_cleanup.
2779 (dwarf2_free_objfile): Now static. Change signature.
2780
2781 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2782
2783 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
2784 option "-o" to add-symbol-file-load to add an offset to each
2785 section's load address.
2786 * symfile.c (set_objfile_default_section_offset): New function.
2787
2788 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2789
2790 * symfile.c (add_symbol_file_command): Make sure that sections
2791 with the same name are sorted in the same order.
2792
2793 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2794
2795 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
2796 require the second argument. If omitted, load sections at the
2797 addresses specified in the file.
2798
2799 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2800
2801 * symfile.c (symbol_file_command, symbol_file_add_main_1)
2802 (_initialize_symfile): Add option "-o" to symbol-file to add an
2803 offset to each section of the symbol file.
2804
2805 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2806
2807 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
2808
2809 2018-06-27 Tom Tromey <tom@tromey.com>
2810
2811 * stack.c (_initialize_stack): Update "func" help text.
2812
2813 2018-06-27 Tom Tromey <tom@tromey.com>
2814
2815 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
2816 std::vector.
2817 (unwind_infopy_str, pyuw_create_unwind_info)
2818 (unwind_infopy_add_saved_register, pyuw_sniffer)
2819 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
2820 Update.
2821 (struct saved_reg): Add constructor.
2822 <value>: Now a gdbpy_ref<>.
2823
2824 2018-06-27 Tom Tromey <tom@tromey.com>
2825
2826 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
2827
2828 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2829
2830 * gdb-gdb.py.in: Format using autopep8.
2831
2832 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2833
2834 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
2835 (type_lookup_function): Recognize CORE_ADDR values.
2836
2837 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2838
2839 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
2840 print tag_name.
2841
2842 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2843
2844 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
2845 <__lt__>: Add.
2846
2847 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2848
2849 * gdb-gdb.py: Move to...
2850 * gdb-gdb.py.in: ... here.
2851 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
2852 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
2853 dependencies.
2854 (distclean): Remove gdb-gdb.py when cleaning.
2855 (gdb-gdb.py, gdb-gdb.gdb): New rules.
2856 * configure: Re-generate.
2857
2858 2018-06-27 Pedro Alves <palves@redhat.com>
2859
2860 * proc-service.c (get_ps_regcache): New.
2861 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
2862 (ps_lsetfpregs): Use it.
2863
2864 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
2865
2866 PR gdb/21695
2867 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
2868 (dwarf_decode_lines_1): Adjust.
2869
2870 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2871
2872 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
2873 override.
2874 <info_proc>: Likewise.
2875
2876 2018-06-26 Joel Brobecker <brobecker@adacore.com>
2877
2878 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
2879 to windows_fetch_one_register, and only handle the case of
2880 fetching one register. Move the code that reloads the context
2881 and iterates over all registers if R is negative to...
2882 (windows_nat_target::fetch_registers): ... here.
2883 (do_windows_store_inferior_registers): Rename to
2884 windows_store_one_register, and only handle the case of storing
2885 one register. Move the code that handles the case where r is
2886 negative to...
2887 (windows_nat_target::store_registers) ... here.
2888
2889 2018-06-26 Tom Tromey <tom@tromey.com>
2890
2891 PR rust/22574:
2892 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
2893 * rust-lang.c (rust_print_struct_def): Add podata parameter.
2894 Update.
2895 (rust_internal_print_type): Add podata parameter.
2896 (rust_print_type): Update.
2897
2898 2018-06-26 Tom Tromey <tom@tromey.com>
2899
2900 * typeprint.h (struct print_offset_data) <update, finish,
2901 maybe_print_hole>: New methods.
2902 <indentation>: New constant.
2903 * typeprint.c (print_offset_data::indentation): Define.
2904 (print_offset_data::maybe_print_hole, print_offset_data::update)
2905 (print_offset_data::finish): Move from c-typeprint.c and rename.
2906 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
2907 (print_spaces_filtered_with_print_options): Update.
2908 (c_print_type_union_field_offset, maybe_print_hole)
2909 (c_print_type_struct_field_offset): Move to typeprint.c and
2910 rename.
2911 (c_type_print_base_struct_union): Update.
2912
2913 2018-06-25 Pedro Alves <palves@redhat.com>
2914
2915 * gdbthread.h (thread_info_ref, delete_thread)
2916 (delete_thread_silent, first_thread_of_inferior)
2917 (any_thread_of_inferior, switch_to_thread)
2918 (enable_thread_stack_temporaries)
2919 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2920 (get_last_thread_stack_temporary)
2921 (value_in_thread_stack_temporaries, can_access_registers_thread):
2922 Spell out "struct thread_info" instead of just "thread_info".
2923 * inferior.h (notice_new_inferior): Likewise.
2924
2925 2018-06-25 Pedro Alves <palves@redhat.com>
2926
2927 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2928 pass thread_info pointer to delete_thread.
2929 (windows_nat_target::detach): Pass inferior pointer to
2930 detach_inferior.
2931 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
2932 delete_thread.
2933 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
2934 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
2935 and pass a thread_info pointer to delete_thread.
2936 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
2937 pass thread_info pointer to delete_thread.
2938 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
2939 delete_thread_silent call.
2940 * procfs.c (procfs_target::detach): Pass inferior pointer to
2941 detach_inferior.
2942 (procfs_target::wait): Pass thread_info pointer to delete_thread.
2943 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
2944 delete_thread_silent call.
2945 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2946 pass thread_info pointer to delete_thread.
2947 (windows_nat_target::detach): Pass inferior pointer to
2948 delete_inferior.
2949
2950 2018-06-22 Alan Hayward <alan.hayward@arm.com>
2951
2952 * regcache.c (readable_regcache::read_part): Fix asserts.
2953 (reg_buffer::raw_collect_part): New function.
2954 (regcache::write_part): Fix asserts.
2955 (reg_buffer::raw_supply_part): New function.
2956 (regcache::transfer_regset_register): New helper function.
2957 (regcache::transfer_regset): Call new functions.
2958 (regcache_supply_regset): Use gdb_byte*.
2959 (regcache::supply_regset): Likewise.
2960 (regcache_collect_regset): Likewise.
2961 (regcache::collect_regset): Likewise.
2962 * regcache.h (reg_buffer::raw_collect_part): New declaration.
2963 (reg_buffer::raw_supply_part): Likewise.
2964 (regcache::transfer_regset_register): Likewise.
2965 (regcache::transfer_regset): Use gdb_byte*.
2966
2967 2018-06-22 Alan Hayward <alan.hayward@arm.com>
2968
2969 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
2970
2971 2018-06-21 Pedro Alves <palves@redhat.com>
2972
2973 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
2974 instead of a ptid_t. All callers adjusted.
2975 * ada-tasks.c (ada_get_task_number): Likewise. All callers
2976 adjusted.
2977 (print_ada_task_info, display_current_task_id, task_command_1):
2978 Adjust.
2979 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
2980 inferior_thread.
2981 (breakpoint_kind): Adjust.
2982 (remove_breakpoints_pid): Rename to ...
2983 (remove_breakpoints_inf): ... this. Adjust to take an inferior
2984 pointer. All callers adjusted.
2985 (bpstat_clear_actions): Use inferior_thread.
2986 (get_bpstat_thread): New.
2987 (bpstat_do_actions): Use it.
2988 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
2989 to take a thread_info pointer. All callers adjusted.
2990 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
2991 (breakpoint_re_set_thread): Use inferior_thread.
2992 * breakpoint.h (struct inferior): Forward declare.
2993 (bpstat_stop_status): Update.
2994 (remove_breakpoints_pid): Delete.
2995 (remove_breakpoints_inf): New.
2996 * bsd-uthread.c (bsd_uthread_target::wait)
2997 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
2998 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
2999 (maint_btrace_packet_history_cmd)
3000 (maint_btrace_clear_packet_history_cmd): Adjust.
3001 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
3002 inferior_thread.
3003 * cli/cli-interp.c: Include "inferior.h".
3004 * common/refcounted-object.h (struct
3005 refcounted_object_ref_policy): New.
3006 * compile/compile-object-load.c: Include gdbthread.h.
3007 (store_regs): Use inferior_thread.
3008 * corelow.c (core_target::close): Use current_inferior.
3009 (core_target_open): Adjust to use first_thread_of_inferior and use
3010 the current inferior.
3011 * ctf.c (ctf_target::close): Adjust to use current_inferior.
3012 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
3013 <thread>: ... this new field. All references adjusted.
3014 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
3015 Take a thread_info pointer instead of a ptid_t.
3016 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
3017 (dummy_frame_discard, register_dummy_frame_dtor): Take a
3018 thread_info pointer instead of a ptid_t.
3019 * elfread.c: Include "inferior.h".
3020 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
3021 Use inferior_thread.
3022 * eval.c (evaluate_subexp): Likewise.
3023 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
3024 inferior_thread.
3025 * gdb_proc_service.h (struct thread_info): Forward declare.
3026 (struct ps_prochandle) <ptid>: Delete, replaced by ...
3027 <thread>: ... this new field. All references adjusted.
3028 * gdbarch.h, gdbarch.c: Regenerate.
3029 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
3030 'thread' parameter. All implementations and callers adjusted.
3031 * gdbthread.h (thread_info) <set_running>: New method.
3032 (delete_thread, delete_thread_silent): Take a thread_info pointer
3033 instead of a ptid.
3034 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
3035 (first_thread_of_process): Delete, replaced by ...
3036 (first_thread_of_inferior): ... this new function. All callers
3037 adjusted.
3038 (any_live_thread_of_process): Delete, replaced by ...
3039 (any_live_thread_of_inferior): ... this new function. All callers
3040 adjusted.
3041 (switch_to_thread, switch_to_no_thread): Declare.
3042 (is_executing): Delete.
3043 (enable_thread_stack_temporaries): Update comment.
3044 <enable_thread_stack_temporaries>: Take a thread_info pointer
3045 instead of a ptid_t. Incref the thread.
3046 <~enable_thread_stack_temporaries>: Decref the thread.
3047 <m_ptid>: Delete
3048 <m_thr>: New.
3049 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
3050 (get_last_thread_stack_temporary)
3051 (value_in_thread_stack_temporaries, can_access_registers_thread):
3052 Take a thread_info pointer instead of a ptid_t. All callers
3053 adjusted.
3054 * infcall.c (get_call_return_value): Use inferior_thread.
3055 (run_inferior_call): Work with thread pointers instead of ptid_t.
3056 (call_function_by_hand_dummy): Work with thread pointers instead
3057 of ptid_t. Use thread_info_ref.
3058 * infcmd.c (proceed_thread_callback): Access thread's state
3059 directly.
3060 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
3061 access thread's state directly.
3062 (continue_command): Use inferior_thread.
3063 (info_program_command): Use find_thread_ptid and access thread
3064 state directly.
3065 (proceed_after_attach_callback): Use thread state directly.
3066 (notice_new_inferior): Take a thread_info pointer instead of a
3067 ptid_t. All callers adjusted.
3068 (exit_inferior): Take an inferior pointer instead of a pid. All
3069 callers adjusted.
3070 (exit_inferior_silent): New.
3071 (detach_inferior): Delete.
3072 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
3073 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
3074 (detach_inferior_command, kill_inferior_command): Use
3075 find_inferior_id instead of valid_gdb_inferior_id and
3076 gdb_inferior_id_to_pid.
3077 (inferior_command): Use inferior and thread pointers.
3078 * inferior.h (struct thread_info): Forward declare.
3079 (notice_new_inferior): Take a thread_info pointer instead of a
3080 ptid_t. All callers adjusted.
3081 (detach_inferior): Delete declaration.
3082 (exit_inferior, exit_inferior_silent): Take an inferior pointer
3083 instead of a pid. All callers adjusted.
3084 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
3085 (valid_gdb_inferior_id): Delete.
3086 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
3087 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
3088 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
3089 ...
3090 <inf>: ... this new field.
3091 <step_ptid>: Delete, replaced by ...
3092 <step_thread>: ... this new field.
3093 (get_displaced_stepping_state): Take an inferior pointer instead
3094 of a pid. All callers adjusted.
3095 (displaced_step_in_progress_any_inferior): Adjust.
3096 (displaced_step_in_progress_thread): Take a thread pointer instead
3097 of a ptid_t. All callers adjusted.
3098 (displaced_step_in_progress, add_displaced_stepping_state): Take
3099 an inferior pointer instead of a pid. All callers adjusted.
3100 (get_displaced_step_closure_by_addr): Adjust.
3101 (remove_displaced_stepping_state): Take an inferior pointer
3102 instead of a pid. All callers adjusted.
3103 (displaced_step_prepare_throw, displaced_step_prepare)
3104 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
3105 All callers adjusted.
3106 (start_step_over): Adjust.
3107 (infrun_thread_ptid_changed): Remove bit updating ptids in the
3108 displaced step queue.
3109 (do_target_resume): Adjust.
3110 (fetch_inferior_event): Use inferior_thread.
3111 (context_switch, get_inferior_stop_soon): Take an
3112 execution_control_state pointer instead of a ptid_t. All callers
3113 adjusted.
3114 (switch_to_thread_cleanup): Delete.
3115 (stop_all_threads): Use scoped_restore_current_thread.
3116 * inline-frame.c: Include "gdbthread.h".
3117 (inline_state) <inline_state>: Take a thread pointer instead of a
3118 ptid_t. All callers adjusted.
3119 <ptid>: Delete, replaced by ...
3120 <thread>: ... this new field.
3121 (find_inline_frame_state): Take a thread pointer instead of a
3122 ptid_t. All callers adjusted.
3123 (skip_inline_frames, step_into_inline_frame)
3124 (inline_skipped_frames, inline_skipped_symbol): Take a thread
3125 pointer instead of a ptid_t. All callers adjusted.
3126 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
3127 (inline_skipped_frames, inline_skipped_symbol): Likewise.
3128 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
3129 pointers directly.
3130 * linux-nat.c (get_detach_signal): Likewise.
3131 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
3132 (thread_db_notice_clone): Adjust.
3133 (thread_db_find_new_threads_silently)
3134 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
3135 a thread pointer instead of a ptid_t. All callers adjusted.
3136 * mi/mi-cmd-var.c: Include "inferior.h".
3137 (mi_cmd_var_update_iter): Update to use thread pointers.
3138 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
3139 inferior directly.
3140 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
3141 out to ...
3142 (mi_output_running): ... this new function.
3143 (mi_on_resume_1): Adjust to use it.
3144 (mi_user_selected_context_changed): Adjust to use inferior_thread.
3145 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
3146 directly.
3147 (interrupt_thread_callback): : Adjust to use thread and inferior
3148 pointers.
3149 * proc-service.c: Include "gdbthread.h".
3150 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
3151 * progspace-and-thread.c: Include "inferior.h".
3152 * progspace.c: Include "inferior.h".
3153 * python/py-exitedevent.c (create_exited_event_object): Adjust to
3154 hold a reference to an inferior_object.
3155 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
3156 inferior_thread.
3157 * python/py-inferior.c (struct inferior_object): Give the type a
3158 tag name instead of a typedef.
3159 (python_on_normal_stop): No need to check if the current thread is
3160 listed.
3161 (inferior_to_inferior_object): Change return type to
3162 inferior_object. All callers adjusted.
3163 (find_thread_object): Delete, bits factored out to ...
3164 (thread_to_thread_object): ... this new function.
3165 * python/py-infthread.c (create_thread_object): Use
3166 inferior_to_inferior_object.
3167 (thpy_is_stopped): Use thread pointer directly.
3168 (gdbpy_selected_thread): Use inferior_thread.
3169 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
3170 field, replaced with ...
3171 <thread>: ... this new field. All users adjusted.
3172 (btpy_insn_or_gap_new): Drop const.
3173 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
3174 callers adjusted.
3175 * python/py-record.c: Include "gdbthread.h".
3176 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
3177 a ptid_t. All callers adjusted.
3178 (gdbpy_current_recording): Use inferior_thread.
3179 * python/py-record.h (recpy_record_object) <ptid>: Delete
3180 field, replaced with ...
3181 <thread>: ... this new field. All users adjusted.
3182 (recpy_element_object) <ptid>: Delete
3183 field, replaced with ...
3184 <thread>: ... this new field. All users adjusted.
3185 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
3186 a ptid_t. All callers adjusted.
3187 * python/py-threadevent.c: Include "gdbthread.h".
3188 (get_event_thread): Use thread_to_thread_object.
3189 * python/python-internal.h (struct inferior_object): Forward
3190 declare.
3191 (find_thread_object, find_inferior_object): Delete declarations.
3192 (thread_to_thread_object, inferior_to_inferior_object): New
3193 declarations.
3194 * record-btrace.c: Include "inferior.h".
3195 (require_btrace_thread): Use inferior_thread.
3196 (record_btrace_frame_sniffer)
3197 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
3198 (get_thread_current_frame): Use scoped_restore_current_thread and
3199 switch_to_thread.
3200 (get_thread_current_frame): Use thread pointer directly.
3201 (record_btrace_replay_at_breakpoint): Use thread's inferior
3202 pointer directly.
3203 * record-full.c: Include "inferior.h".
3204 * regcache.c: Include "gdbthread.h".
3205 (get_thread_arch_regcache): Use the inferior's address space
3206 directly.
3207 (get_thread_regcache, registers_changed_thread): New.
3208 * regcache.h (get_thread_regcache(thread_info *thread)): New
3209 overload.
3210 (registers_changed_thread): New.
3211 (remote_target) <remote_detach_1>: Swap order of parameters.
3212 (remote_add_thread): <remote_add_thread>: Return the new thread.
3213 (get_remote_thread_info(ptid_t)): New overload.
3214 (remote_target::remote_notice_new_inferior): Use thread pointers
3215 directly.
3216 (remote_target::process_initial_stop_replies): Use
3217 thread_info::set_running.
3218 (remote_target::remote_detach_1, remote_target::detach)
3219 (extended_remote_target::detach): Adjust.
3220 * stack.c (frame_show_address): Use inferior_thread.
3221 * target-debug.h (target_debug_print_thread_info_pp): New.
3222 * target-delegates.c: Regenerate.
3223 * target.c (default_thread_address_space): Delete.
3224 (memory_xfer_partial_1): Use current_inferior.
3225 (target_detach): Use current_inferior.
3226 (target_thread_address_space): Delete.
3227 (generic_mourn_inferior): Use current_inferior.
3228 * target.h (struct target_ops) <thread_address_space>: Delete.
3229 (target_thread_address_space): Delete.
3230 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
3231 pointers directly.
3232 (delete_thread_1, delete_thread, delete_thread_silent): Take a
3233 thread pointer instead of a ptid_t. Adjust all callers.
3234 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
3235 (first_thread_of_process): Delete, replaced by ...
3236 (first_thread_of_inferior): ... this new function. All callers
3237 adjusted.
3238 (any_thread_of_process): Rename to ...
3239 (any_thread_of_inferior): ... this, and take an inferior pointer.
3240 (any_live_thread_of_process): Rename to ...
3241 (any_live_thread_of_inferior): ... this, and take an inferior
3242 pointer.
3243 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
3244 (value_in_thread_stack_temporaries)
3245 (get_last_thread_stack_temporary): Take a thread pointer instead
3246 of a ptid_t. Adjust all callers.
3247 (thread_info::set_running): New.
3248 (validate_registers_access): Use inferior_thread.
3249 (can_access_registers_ptid): Rename to ...
3250 (can_access_registers_thread): ... this, and take a thread
3251 pointer.
3252 (print_thread_info_1): Adjust to compare thread pointers instead
3253 of ptids.
3254 (switch_to_no_thread, switch_to_thread): Make extern.
3255 (scoped_restore_current_thread::~scoped_restore_current_thread):
3256 Use m_thread pointer directly.
3257 (scoped_restore_current_thread::scoped_restore_current_thread):
3258 Use inferior_thread.
3259 (thread_command): Use thread pointer directly.
3260 (thread_num_make_value_helper): Use inferior_thread.
3261 * top.c (execute_command): Use inferior_thread.
3262 * tui/tui-interp.c: Include "inferior.h".
3263 * varobj.c (varobj_create): Use inferior_thread.
3264 (value_of_root_1): Use find_thread_global_id instead of
3265 global_thread_id_to_ptid.
3266
3267 2018-06-21 Alan Hayward <alan.hayward@arm.com>
3268
3269 * regcache.c (readable_regcache::read_part): Avoid memcpy when
3270 possible.
3271 (regcache::write_part): Likewise.
3272 (readable_regcache::cooked_read_part): Update comment.
3273 (readable_regcache::cooked_write_part): Likewise.
3274 * regcache.h: (readable_regcache::read_part): Likewise.
3275 (regcache::write_part): Likewise.
3276
3277 2018-06-21 Richard Bunt <richard.bunt@arm.com>
3278 Dirk Schubert <dirk.schubert@arm.com>
3279
3280 * aarch64-linux-nat.c (post_attach): New.
3281 (aarch64_linux_nat_target::post_attach): Override post_attach to
3282 record the number of hardware debug registers.
3283
3284 2018-06-20 Tom Tromey <tom@tromey.com>
3285
3286 * python/py-param.c (add_setshow_generic): Make parameters const.
3287 (parmpy_init): Update.
3288
3289 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
3290
3291 * regcache.h (regcache_cooked_read_ftype): Rename to...
3292 (register_read_ftype): ...this, change type to function_view.
3293 (class reg_buffer) <save>: Remove src parameter.
3294 (readonly_detached_regcache) <readonly_detached_regcache>: Make
3295 parameter non-const in first overload. Remove src parameter in
3296 second overload.
3297 * regcache.c (do_cooked_read): Remove.
3298 (readonly_detached_regcache::readonly_detached_regcache): Make
3299 parameter non-const, adjust call to other constructor.
3300 (reg_buffer::save): Remove src parameter.
3301 * frame.c (do_frame_register_read): Remove.
3302 (frame_save_as_regcache): Use lambda function.
3303 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
3304 parameter to ppu2spu_data *.
3305 (ppu2spu_sniffer): Use lambda function.
3306
3307 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
3308
3309 * record-full.c (record_full_target::insert_breakpoint): Remove
3310 "struct" keyword, add const.
3311
3312 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
3313
3314 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
3315 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
3316 * configure.ac: Remove AC_PREREQ, add missing quoting.
3317 * gnulib/configure.ac: Modernize usage of
3318 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
3319 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
3320 (AUTOMAKE_VERSION): Bump to 1.15.1.
3321 * configure: Re-generate.
3322 * config.in: Re-generate.
3323 * aclocal.m4: Re-generate.
3324 * gnulib/aclocal.m4: Re-generate.
3325 * gnulib/config.in: Re-generate.
3326 * gnulib/configure: Re-generate.
3327 * gnulib/import/Makefile.in: Re-generate.
3328
3329 2018-06-19 Pedro Alves <palves@redhat.com>
3330
3331 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
3332 (lookup_minimal_symbol_by_pc_section): ... here with
3333 gdb_assert_not_reached added.
3334
3335 2018-06-19 Pedro Alves <palves@redhat.com>
3336
3337 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
3338 parameter with a block parameter. Compare location's block symbol
3339 with the frame's block instead of addresses.
3340 (skip_inline_frames): Pass the current block instead of the
3341 frame's address. Break out as soon as we determine the frame
3342 should not be skipped.
3343
3344 2018-06-18 Tom Tromey <tom@tromey.com>
3345
3346 * solib-aix.c (solib_aix_get_section_offsets): Return
3347 unique_xmalloc_ptr.
3348 (solib_aix_solib_create_inferior_hook): Update.
3349
3350 2018-06-18 Tom Tromey <tom@tromey.com>
3351
3352 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
3353
3354 2018-06-18 Tom Tromey <tom@tromey.com>
3355
3356 * solib-frv.c (frv_relocate_main_executable): Use
3357 unique_xmalloc_ptr.
3358 * solib-dsbt.c (dsbt_relocate_main_executable): Use
3359 unique_xmalloc_ptr.
3360
3361 2018-06-18 Tom Tromey <tom@tromey.com>
3362
3363 * objfiles.h (inhibit_section_map_updates): Update.
3364 (resume_section_map_updates, resume_section_map_updates_cleanup):
3365 Remove.
3366 * solib-svr4.c (svr4_handle_solib_event): Update.
3367 * objfiles.c (inhibit_section_map_updates): Return
3368 scoped_restore_tmpl<int>.
3369 (resume_section_map_updates, resume_section_map_updates_cleanup):
3370 Remove.
3371
3372 2018-06-18 Tom Tromey <tom@tromey.com>
3373
3374 * valprint.h (read_string): Update.
3375 * valprint.c (read_string): Change type of "buffer".
3376 (val_print_string): Update.
3377 * python/py-value.c (valpy_string): Update.
3378 * language.h (struct language_defn) <la_get_string>: Change
3379 type of "buffer".
3380 (default_get_string, c_get_string): Update.
3381 * language.c (default_get_string): Change type of "buffer".
3382 * guile/scm-value.c (gdbscm_value_to_string): Update.
3383 * c-lang.c (c_get_string): Change type of "buffer".
3384
3385 2018-06-18 Tom Tromey <tom@tromey.com>
3386
3387 * ser-mingw.c (struct pipe_state_destroyer): New.
3388 (pipe_state_up): New typedef.
3389 (cleanup_pipe_state): Remove.
3390 (pipe_windows_open): Use pipe_state_up. Don't release argv.
3391
3392 2018-06-18 Tom Tromey <tom@tromey.com>
3393
3394 * rust-lang.h (rust_yyerror): Don't declare.
3395 * rust-lang.c (rust_language_defn): Update.
3396 * rust-exp.y (yyerror): Now static.
3397 * parse.c (parse_exp_in_context_1): Update.
3398 * p-lang.h (p_yyerror): Don't declare.
3399 * p-lang.c (p_language_defn): Update.
3400 * p-exp.y (yyerror): Now static.
3401 * opencl-lang.c (opencl_language_defn): Update.
3402 * objc-lang.c (objc_language_defn): Update.
3403 * m2-lang.h (m2_yyerror): Don't declare.
3404 * m2-lang.c (m2_language_defn): Update.
3405 * m2-exp.y (yyerror): Now static.
3406 * language.h (struct language_defn) <la_error>: Remove.
3407 * language.c (unk_lang_error): Remove.
3408 (unknown_language_defn, auto_language_defn): Remove.
3409 * go-lang.h (go_yyerror): Don't declare.
3410 * go-lang.c (go_language_defn): Update.
3411 * go-exp.y (yyerror): Now static.
3412 * f-lang.h (f_yyerror): Don't declare.
3413 * f-lang.c (f_language_defn): Update.
3414 * f-exp.y (yyerror): Now static.
3415 * d-lang.h (d_yyerror): Don't declare.
3416 * d-lang.c (d_language_defn): Update.
3417 * d-exp.y (yyerror): Now static.
3418 * c-lang.h (c_yyerror): Don't declare.
3419 * c-lang.c (c_language_defn, cplus_language_defn)
3420 (asm_language_defn, minimal_language_defn): Update.
3421 * c-exp.y (yyerror): Now static.
3422 * ada-lang.h (ada_yyerror): Don't declare.
3423 * ada-lang.c (ada_language_defn): Update.
3424 * ada-exp.y (yyerror): Now static.
3425
3426 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3427
3428 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
3429 (store_sveregs_to_thread): Likewise.
3430 (aarch64_linux_fetch_inferior_registers): Check for SVE.
3431 (aarch64_linux_store_inferior_registers): Likewise.
3432 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
3433 function.
3434 (aarch64_sve_regs_copy_to_regcache): Likewise.
3435 (aarch64_sve_regs_copy_from_regcache): Likewise.
3436 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
3437 declaration.
3438 (aarch64_sve_regs_copy_to_regcache): Likewise.
3439 (aarch64_sve_regs_copy_from_regcache): Likewise.
3440 (sve_context): Structure from Linux headers.
3441 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
3442 (SVE_SIG_ZREG_SIZE): Likewise.
3443 (SVE_SIG_PREG_SIZE): Likewise.
3444 (SVE_SIG_FFR_SIZE): Likewise.
3445 (SVE_SIG_REGS_OFFSET): Likewise.
3446 (SVE_SIG_ZREGS_OFFSET): Likewise.
3447 (SVE_SIG_ZREG_OFFSET): Likewise.
3448 (SVE_SIG_ZREGS_SIZE): Likewise.
3449 (SVE_SIG_PREGS_OFFSET): Likewise.
3450 (SVE_SIG_PREG_OFFSET): Likewise.
3451 (SVE_SIG_PREGS_SIZE): Likewise.
3452 (SVE_SIG_FFR_OFFSET): Likewise.
3453 (SVE_SIG_REGS_SIZE): Likewise.
3454 (SVE_SIG_CONTEXT_SIZE): Likewise.
3455 (SVE_PT_REGS_MASK): Likewise.
3456 (SVE_PT_REGS_FPSIMD): Likewise.
3457 (SVE_PT_REGS_SVE): Likewise.
3458 (SVE_PT_VL_INHERIT): Likewise.
3459 (SVE_PT_VL_ONEXEC): Likewise.
3460 (SVE_PT_REGS_OFFSET): Likewise.
3461 (SVE_PT_FPSIMD_OFFSET): Likewise.
3462 (SVE_PT_FPSIMD_SIZE): Likewise.
3463 (SVE_PT_SVE_ZREG_SIZE): Likewise.
3464 (SVE_PT_SVE_PREG_SIZE): Likewise.
3465 (SVE_PT_SVE_FFR_SIZE): Likewise.
3466 (SVE_PT_SVE_FPSR_SIZE): Likewise.
3467 (SVE_PT_SVE_FPCR_SIZE): Likewise.
3468 (__SVE_SIG_TO_PT): Likewise.
3469 (SVE_PT_SVE_OFFSET): Likewise.
3470 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
3471 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
3472 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
3473 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
3474 (SVE_PT_SVE_PREG_OFFSET): Likewise.
3475 (SVE_PT_SVE_PREGS_SIZE): Likewise.
3476 (SVE_PT_SVE_FFR_OFFSET): Likewise.
3477 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
3478 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
3479 (SVE_PT_SVE_SIZE): Likewise.
3480 (SVE_PT_SIZE): Likewise.
3481 (HAS_SVE_STATE): New define.
3482
3483 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3484
3485 * nat/aarch64-sve-linux-sigcontext.h: New file.
3486 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
3487 new files.
3488 (SVE_VQ_MIN): Likewise.
3489 (SVE_VQ_MAX): Likewise.
3490 (SVE_VL_MIN): Likewise.
3491 (SVE_VL_MAX): Likewise.
3492 (SVE_NUM_ZREGS): Likewise.
3493 (SVE_NUM_PREGS): Likewise.
3494 (sve_vl_valid): Likewise.
3495 (struct user_sve_header): Likewise.
3496
3497 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
3498 Richard Bunt <Richard.Bunt@arm.com>
3499
3500 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
3501 was requested by GDB.
3502
3503 2018-06-15 Tom de Vries <tdevries@suse.de>
3504
3505 * MAINTAINERS (Write After Approval): Add Tom de Vries.
3506
3507 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
3508
3509 * gnulib/update-gnulib.sh: Print expected versions of
3510 autoconf/aclocal.
3511
3512 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
3513
3514 * arch-utils.c (default_type_align): Use type_length_units.
3515 * gdbtypes.c (type_align): Use type_length_units.
3516
3517 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3518
3519 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
3520 of 'define' command.
3521
3522 2018-06-14 Tom de Vries <tdevries@suse.de>
3523
3524 PR cli/22573
3525 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
3526 get_no_prettyformat_print_options.
3527
3528 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
3529
3530 * sparc-nat.h: Include target.h.
3531 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
3532 <fetch_registers>: Remove this argument in function call.
3533 <store_registers>: Remove this argument in function call, remove
3534 extra semicolon.
3535 <low_forget_process>: Call sparc64_forget_process instead of
3536 sparc_forget_process.
3537
3538 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3539
3540 * procfs.c (_initialize_procfs): Use add_inf_child_target.
3541 (procfs_target::make_corefile_notes): Adjust to new
3542 target_read_alloc return type.
3543
3544 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3545 Stephen Roberts <stephen.roberts@arm.com>
3546
3547 PR gdb/22882
3548 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
3549 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
3550 Move should_notify_stop local into more inner scope.
3551
3552 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3553 Stephen Roberts <stephen.roberts@arm.com>
3554
3555 PR gdb/22882
3556 * infrun.c (resume_1): Add call to mark_async_event_handler.
3557
3558 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3559
3560 * infrun.c (do_target_wait): Change old version of $pc printed.
3561
3562 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
3563
3564 * dwarf2read.c (read_index_from_section): Rename to...
3565 (read_gdb_index_from_section): ... this, update all callers.
3566 (dwarf2_read_index): Rename to...
3567 (dwarf2_read_gdb_index): ... this, update all callers.
3568
3569 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
3570
3571 * gdb/hppa-linux-nat.c
3572 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
3573 hppa_linux_nat_target::fetch_registers.
3574
3575 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3576
3577 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
3578 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
3579 (AARCH64_DWARF_SVE_FFR): Likewise.
3580 (AARCH64_DWARF_SVE_P0): Likewise.
3581 (AARCH64_DWARF_SVE_Z0): Likewise.
3582
3583 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3584
3585 * common/common-regcache.h (raw_compare): New function.
3586 * regcache.c (regcache::raw_compare): Likewise.
3587 * regcache.h (regcache::raw_compare): New declaration.
3588
3589 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3590
3591 * common/common-regcache.h (reg_buffer_common): New structure.
3592 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
3593 (reg_buffer::raw_supply): Likewise.
3594 (reg_buffer::raw_supply_integer): Likewise.
3595 (reg_buffer::raw_supply_zeroed): Likewise.
3596 (reg_buffer::raw_collect): Likewise.
3597 (reg_buffer::raw_collect_integer): Likewise.
3598 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
3599 (reg_buffer::raw_supply): Likewise.
3600 (reg_buffer::raw_supply_integer): Likewise.
3601 (reg_buffer::raw_supply_zeroed): Likewise.
3602 (reg_buffer::raw_collect): Likewise.
3603 (reg_buffer::raw_collect_integer): Likewise.
3604
3605 2018-06-10 Tom Tromey <tom@tromey.com>
3606
3607 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
3608 (class remote_state) <stop_reply_queue>: Now std::vector.
3609 (remote_state::~remote_state)
3610 (remote_target::stop_reply_queue_length): Update.
3611 (struct queue_iter_param, remove_child_of_pending_fork)
3612 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
3613 (check_pending_event_prevents_wildcard_vcont_callback)
3614 (remove_stop_reply_for_inferior)
3615 (remove_stop_reply_of_remote_state)
3616 (remote_notif_remove_once_on_match)
3617 (stop_reply_match_ptid_and_ws)
3618 (remote_kill_child_of_pending_fork): Remove.
3619 (remote_target::remove_new_fork_children)
3620 (remote_target::check_pending_events_prevent_wildcard_vcont)
3621 (remote_target::discard_pending_stop_replies)
3622 (remote_target::discard_pending_stop_replies_in_queue)
3623 (remote_target::remote_notif_remove_queued_reply)
3624 (remote_target::queued_stop_reply)
3625 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
3626 (remote_target::wait, remote_target::kill_new_fork_children)
3627 (remote_target::async): Update.
3628
3629 2018-06-10 Tom Tromey <tom@tromey.com>
3630
3631 * record-full.c (record_full_arch_list_cleanups): Remove.
3632 (record_full_message): Use try/catch.
3633 (record_full_wait_cleanups): Remove.
3634 (record_full_wait_1): Use try/catch.
3635 (record_full_restore): Likewise.
3636
3637 2018-06-10 Tom Tromey <tom@tromey.com>
3638
3639 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
3640 declare VEC. Add constructor.
3641 <in_target_beneath>: Now bool.
3642 (record_full_breakpoints): Now a std::vector, static.
3643 (record_full_sync_record_breakpoints)
3644 (record_full_init_record_breakpoints)
3645 (record_full_target::insert_breakpoint)
3646 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
3647
3648 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
3649
3650 * dwarf2read.c (process_cu_includes): Remove struct keyword.
3651 * serial.c (serial_interface_lookup): Remove struct keyword.
3652
3653 2018-06-10 Tom Tromey <tom@tromey.com>
3654
3655 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
3656 method.
3657 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
3658 a method.
3659 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
3660 method.
3661 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
3662 "beneath" as a method.
3663 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
3664 Use "beneath" as a method.
3665
3666 2018-06-10 Tom Tromey <tom@tromey.com>
3667
3668 * tracefile.c (struct trace_file_writer_deleter): New.
3669 <operator()>: Rename from trace_file_writer_xfree.
3670 (trace_file_writer_up): New typedef.
3671 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
3672
3673 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
3674
3675 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
3676 <m_registers, m_register_status>: Change type to
3677 std::unique_ptr.
3678 * regcache.c (reg_buffer::reg_buffer): Use new instead of
3679 XCNEWVEC.
3680
3681 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
3682
3683 * common/common-regcache.h (enum register_status): Add
3684 underlying type "signed char".
3685 * regcache.h (reg_buffer) <m_register_status>: Change type to
3686 register_status *.
3687 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
3688 register_status instead of signed char.
3689 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
3690 (reg_buffer::get_register_status): Remove cast.
3691 (readable_regcache::raw_read): Remove cast.
3692 (readable_regcache::cooked_read): Remove cast.
3693
3694 2018-06-09 Tom Tromey <tom@tromey.com>
3695
3696 * source.c (reverse_search_command, forward_search_command): Use
3697 scoped_fd.
3698
3699 2018-06-09 Tom Tromey <tom@tromey.com>
3700
3701 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
3702 (serial_ops_list): Now static, std::vector.
3703 (serial_interface_lookup, serial_add_interface): Update.
3704
3705 2018-06-09 Tom Tromey <tom@tromey.com>
3706
3707 * dwarf2read.c (process_cu_includes): Update.
3708 (process_full_comp_unit): Update.
3709 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
3710 std::vector.
3711
3712 2018-06-08 Paul Koning <paul_koning@dell.com>
3713
3714 PR gdb/23252
3715
3716 * python/python.c (do_start_initialization):
3717 Avoid call to internal Python API.
3718 (init__gdb_module): New function.
3719
3720 2018-06-08 Gary Benson <gbenson@redhat.com>
3721
3722 * linux-thread-db.c (valprint.h): New include.
3723 (struct check_thread_db_info): New structure.
3724 (check_thread_db_on_load, tdb_testinfo): New static globals.
3725 (check_thread_db, check_thread_db_callback): New functions.
3726 (try_thread_db_load_1): Run integrity checks if requested.
3727 (maintenance_check_libthread_db): New function.
3728 (_initialize_thread_db): Register "maint check libthread-db"
3729 and "maint set/show check-libthread-db".
3730 * NEWS: Mention the above new commands.
3731
3732 2018-06-08 Tom Tromey <tom@tromey.com>
3733
3734 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
3735 now a method.
3736
3737 2018-06-08 Tom Tromey <tom@tromey.com>
3738
3739 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
3740
3741 2018-06-08 Tom Tromey <tom@tromey.com>
3742
3743 * common/btrace-common.h (struct btrace_data): Add constructor,
3744 destructor, move assignment operator.
3745 <empty, clear, fini>: New methods.
3746 <format>: Initialize.
3747 (btrace_data_init, btrace_data_fini, btrace_data_clear)
3748 (btrace_data_empty): Don't declare.
3749 * common/btrace-common.c (btrace_data_init): Remove.
3750 (btrace_data::fini): Rename from btrace_data_fini.
3751 (btrace_data::empty): Rename from btrace_data_empty.
3752 (btrace_data::clear): Rename from btrace_data_clear. Return
3753 bool.
3754 * btrace.h (make_cleanup_btrace_data): Don't declare.
3755 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
3756 (parse_xml_btrace): Update.
3757 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
3758 (maint_btrace_clear_packet_history_cmd): Update.
3759
3760 2018-06-07 Pedro Alves <palves@redhat.com>
3761
3762 * target.h (target_ops) <beneath>: Now a method. All references
3763 updated.
3764 (class target_stack): New.
3765 * target.c (g_target_stack): New.
3766 (g_current_top_target): Delete.
3767 (current_top_target): Get the top target out of g_target_stack.
3768 (target_stack::push, target_stack::unpush): New.
3769 (push_target, unpush_target): Reimplement.
3770 (target_is_pushed): Reimplement in terms of g_target_stack.
3771 (target_ops::beneath, target_stack::find_beneath): New.
3772
3773 2018-06-07 Pedro Alves <palves@redhat.com>
3774
3775 * target.h (find_target_beneath): Delete declaration.
3776 * target.c (find_target_beneath): Delete definition.
3777 * aix-thread.c: All callers of find_target_beneath adjusted to
3778 call target_ops::beneath instead.
3779 * bsd-uthread.c: Likewise.
3780 * linux-thread-db.c: Likewise.
3781 * ravenscar-thread.c: Likewise.
3782 * sol-thread.c: Likewise.
3783 * spu-multiarch.c: Likewise.
3784
3785 2018-06-07 Pedro Alves <palves@redhat.com>
3786
3787 * target.h (target_ops) <beneath>: Now a method. All references
3788 updated.
3789 (target_ops) <m_beneath>: New.
3790 * target.c (target_ops::beneath): New.
3791 * corelow.c: Adjust all references to target_ops::beneath.
3792 * linux-thread-db.c: Likewise.
3793 * make-target-delegates: Likewise.
3794 * record-btrace.c: Likewise.
3795 * record-full.c: Likewise.
3796 * remote.c: Likewise.
3797 * target.c: Likewise.
3798 * target-delegates.c: Regenerate.
3799
3800 2018-06-07 Pedro Alves <palves@redhat.com>
3801
3802 * target.h (target_stack): Delete.
3803 (current_top_target): Declare function.
3804 * target.c (target_stack): Delete.
3805 (g_current_top_target): New.
3806 (current_top_target): New function.
3807 * auxv.c: Use current_top_target instead of target_stack
3808 throughout.
3809 * avr-tdep.c: Likewise.
3810 * breakpoint.c: Likewise.
3811 * corefile.c: Likewise.
3812 * elfread.c: Likewise.
3813 * eval.c: Likewise.
3814 * exceptions.c: Likewise.
3815 * frame.c: Likewise.
3816 * gdbarch-selftests.c: Likewise.
3817 * gnu-v3-abi.c: Likewise.
3818 * ia64-tdep.c: Likewise.
3819 * ia64-vms-tdep.c: Likewise.
3820 * infcall.c: Likewise.
3821 * infcmd.c: Likewise.
3822 * infrun.c: Likewise.
3823 * linespec.c: Likewise.
3824 * linux-tdep.c: Likewise.
3825 * minsyms.c: Likewise.
3826 * ppc-linux-nat.c: Likewise.
3827 * ppc-linux-tdep.c: Likewise.
3828 * procfs.c: Likewise.
3829 * regcache.c: Likewise.
3830 * remote.c: Likewise.
3831 * rs6000-tdep.c: Likewise.
3832 * s390-linux-nat.c: Likewise.
3833 * s390-tdep.c: Likewise.
3834 * solib-aix.c: Likewise.
3835 * solib-darwin.c: Likewise.
3836 * solib-dsbt.c: Likewise.
3837 * solib-spu.c: Likewise.
3838 * solib-svr4.c: Likewise.
3839 * solib-target.c: Likewise.
3840 * sparc-tdep.c: Likewise.
3841 * sparc64-tdep.c: Likewise.
3842 * spu-tdep.c: Likewise.
3843 * symfile.c: Likewise.
3844 * symtab.c: Likewise.
3845 * target-descriptions.c: Likewise.
3846 * target-memory.c: Likewise.
3847 * target.c: Likewise.
3848 * target.h: Likewise.
3849 * tracefile-tfile.c: Likewise.
3850 * tracepoint.c: Likewise.
3851 * valops.c: Likewise.
3852 * valprint.c: Likewise.
3853 * value.c: Likewise.
3854 * windows-tdep.c: Likewise.
3855 * mi/mi-main.c: Likewise.
3856
3857 2018-06-07 Tom Tromey <tom@tromey.com>
3858
3859 * valprint.h (build_address_symbolic): Declare.
3860 * printcmd.c (print_address_symbolic): Update.
3861 (build_address_symbolic): Change "name" and "filename" to
3862 std::string.
3863 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
3864 Update.
3865 * defs.h (build_address_symbolic): Remove declaration.
3866
3867 2018-06-07 Alan Hayward <alan.hayward@arm.com>
3868
3869 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
3870 (aarch64_vnv_type): Add function.
3871 (aarch64_pseudo_register_name): Add V regs for SVE.
3872 (aarch64_pseudo_register_type): Likewise.
3873 (aarch64_pseudo_register_reggroup_p): Likewise.
3874 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
3875 (aarch64_pseudo_read_value): Add V regs for SVE.
3876 (aarch64_pseudo_write_2): Use V0 offset for SVE
3877 (aarch64_pseudo_write): Add V regs for SVE.
3878 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
3879
3880 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
3881
3882 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
3883 (sve_vl_from_vq): Likewise.
3884
3885 2018-06-05 Tom Tromey <tom@tromey.com>
3886
3887 * cli/cli-cmds.c (show_version): Update.
3888 * top.c (print_gdb_version): Add "interactive" parameter.
3889 Update.
3890 * main.c (captured_main_1): Update.
3891 * top.h (print_gdb_version): Add "interactive" parameter and a
3892 comment.
3893
3894 2018-06-05 David Malcolm <dmalcolm@redhat.com>
3895
3896 * common/enum-flags.h: Add trailing semicolon to example in
3897 comment.
3898
3899 2018-06-05 Tom Tromey <tom@tromey.com>
3900
3901 PR cli/12326:
3902 * NEWS: Add entry about pager.
3903 * utils.c (pagination_disabled_for_command): New global.
3904 (prompt_for_continue): Allow "c" response to prompt.
3905 (reinitialize_more_filter): Clear
3906 pagination_disabled_for_command.
3907 (fputs_maybe_filtered): Check pagination_disabled_for_command.
3908
3909 2018-06-04 Tom Tromey <tom@tromey.com>
3910
3911 * ada-lang.h (ada_lookup_symbol_list): Update.
3912 * ada-lang.c (resolve_subexp): Update.
3913 (symbols_are_identical_enums): Change type of syms. Remove nsyms
3914 parameter.
3915 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
3916 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
3917 results parameter to std::vector.
3918 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
3919 Update.
3920 * ada-exp.y (block_lookup): Update.
3921 (select_possible_type_sym): Change type of syms. Remove nsyms
3922 parameter.
3923 (write_var_or_type, write_name_assoc): Update.
3924
3925 2018-06-04 Joel Brobecker <brobecker@adacore.com>
3926
3927 * windows-nat.c (windows_nat_target::xfer_partial): Return
3928 TARGET_XFER_E_IO if we need to delegate to the target beneath
3929 but BENEATH is NULL.
3930
3931 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
3932
3933 * Makefile.in (config.status): Add configure.nat as a
3934 dependency.
3935
3936 2018-06-04 Tom Tromey <tom@tromey.com>
3937
3938 * cp-name-parser.y (cpname_state): Add method declarations.
3939 (HANDLE_QUAL): Update.
3940 (cpname_state::d_grab, cpname_state::fill_comp)
3941 (cpname_state::make_operator, cpname_state::make_dtor)
3942 (cpname_state::make_builtin_type, cpname_state::make_name)
3943 (cpname_state::d_qualify, cpname_state::d_int_type)
3944 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
3945 (%union): Move earlier.
3946
3947 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3948
3949 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
3950
3951 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3952
3953 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
3954 (aarch64_pseudo_write_1): Likewise.
3955 (aarch64_pseudo_read_value): Use helper.
3956 (aarch64_pseudo_write): Likewise.
3957
3958 2018-06-04 Pedro Alves <palves@redhat.com>
3959
3960 * darwin-nat.c (darwin_ops): Delete.
3961 (darwin_attach_pid): Use get_native_target.
3962
3963 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3964
3965 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
3966 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
3967
3968 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3969
3970 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
3971 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
3972 (aarch64_gdbarch_init): Check for SVE.
3973 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
3974
3975 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3976
3977 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
3978 * aarch64-tdep.h (aarch64_read_description): Likewise.
3979 * arch/aarch64.c (aarch64_create_target_description): Likewise.
3980 * arch/aarch64.h (aarch64_create_target_description): Likewise.
3981 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
3982 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
3983 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
3984
3985 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
3986
3987 * value.c (value_fetch_lazy_bitfield): New.
3988 (value_fetch_lazy_memory): New.
3989 (value_fetch_lazy_register): New.
3990 (value_fetch_lazy): Factor out to smaller functions.
3991
3992 2018-06-01 Tom Tromey <tom@tromey.com>
3993
3994 * cp-name-parser.y (backslashable, represented): Now const.
3995
3996 2018-06-01 Tom Tromey <tom@tromey.com>
3997
3998 * cp-name-parser.y: Include parser-defs.h.
3999 (parser_fprintf): Remove declaration.
4000
4001 2018-06-01 Tom Tromey <tom@tromey.com>
4002
4003 * cp-name-parser.y: Use %pure-parser, %lex-param, and
4004 %parse-param.
4005 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
4006 (global_result): Remove globals.
4007 (struct cpname_state): New.
4008 (yyparse): Don't declare.
4009 (yylex, yyerror): Move declarations after %union.
4010 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
4011 (make_name): Add state parameter.
4012 Update all callers.
4013 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
4014 parameter.
4015 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
4016 Update.
4017 (yylex): Add lvalp, state parameters.
4018 (yyerror): Add state parameter.
4019 (cp_demangled_name_to_comp): Update.
4020
4021 2018-06-01 Tom Tromey <tom@tromey.com>
4022
4023 * cp-name-parser.y (parser_fprintf): Declare.
4024 (GDB_YY_REMAP_PREFIX): Define.
4025 Include yy-remap.h. Don't redefine yy* identifiers.
4026
4027 2018-06-01 Tom Tromey <tom@tromey.com>
4028
4029 * python/py-type.c (typy_legacy_template_argument): Update.
4030 * cp-support.h (cp_demangled_name_to_comp): Update.
4031 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
4032 parameter to be a "std::string *".
4033 (main): Update.
4034
4035 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
4036
4037 * ada-lex.l: Include "diagnostics.h" instead of
4038 "common/diagnostics.h".
4039 * unittests/environ-selftests.c: Likewise.
4040 * common/diagnostics.h: Moved to ../include.
4041
4042 2018-06-01 Joel Brobecker <brobecker@adacore.com>
4043
4044 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
4045 to language_mode_manual while calling breakpoint_re_set_one.
4046
4047 2018-06-01 Tom Tromey <tom@tromey.com>
4048
4049 * valops.c (value_cast_structs, destructor_name_p): Update.
4050 * symtab.c (gdb_mangle_name): Update.
4051 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
4052 Update.
4053 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
4054 (pascal_object_print_value_fields, pascal_object_print_value):
4055 Update.
4056 * p-typeprint.c (pascal_type_print_derivation_info): Update.
4057 * linespec.c (find_methods): Update.
4058 * gdbtypes.h (type_name_no_tag): Remove.
4059 (type_name_or_error): Rename from type_name_no_tag_or_error.
4060 * gdbtypes.c (type_name_no_tag): Remove.
4061 (type_name_or_error): Rename from type_name_no_tag_or_error.
4062 (lookup_struct_elt_type, check_typedef): Update.
4063 * expprint.c (print_subexp_standard): Update.
4064 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
4065 * d-namespace.c (d_lookup_nested_symbol): Update.
4066 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
4067 (cp_print_class_member): Update.
4068 * cp-namespace.c (cp_lookup_nested_symbol): Update.
4069 * completer.c (add_struct_fields): Update.
4070 * c-typeprint.c (cp_type_print_derivation_info)
4071 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
4072 Update.
4073 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
4074 (ada_prefer_type, ada_is_exception_sym): Update.
4075
4076 2018-06-01 Tom Tromey <tom@tromey.com>
4077
4078 * valops.c (enum_constant_from_type, value_namespace_elt)
4079 (value_maybe_namespace_elt): Update.
4080 * valarith.c (find_size_for_pointer_math): Update.
4081 * target-descriptions.c (make_gdb_type): Update.
4082 * symmisc.c (print_symbol): Update.
4083 * stabsread.c (define_symbol, read_type)
4084 (complain_about_struct_wipeout, add_undefined_type)
4085 (cleanup_undefined_types_1): Update.
4086 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
4087 (rust_range_type_p, val_print_struct, rust_print_struct_def)
4088 (rust_internal_print_type, rust_composite_type)
4089 (rust_evaluate_funcall, rust_evaluate_subexp)
4090 (rust_inclusive_range_type_p): Update.
4091 * python/py-type.c (typy_get_tag): Update.
4092 * p-typeprint.c (pascal_type_print_base): Update.
4093 * mdebugread.c (parse_symbol, parse_type): Update.
4094 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
4095 Update.
4096 * guile/scm-type.c (gdbscm_type_tag): Update.
4097 * go-lang.c (sixg_string_p): Update.
4098 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
4099 Update.
4100 * gdbtypes.h (struct main_type) <tag_name>: Remove.
4101 (TYPE_TAG_NAME): Remove.
4102 * gdbtypes.c (type_name_no_tag): Simplify.
4103 (check_typedef, check_types_equal, recursive_dump_type)
4104 (copy_type_recursive, arch_composite_type): Update.
4105 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
4106 in summary mode when needed.
4107 * eval.c (evaluate_funcall): Update.
4108 * dwarf2read.c (fixup_go_packaging, read_structure_type)
4109 (process_structure_scope, read_enumeration_type)
4110 (read_namespace_type, read_module_type, determine_prefix): Update.
4111 * cp-support.c (inspect_type): Update.
4112 * coffread.c (process_coff_symbol, decode_base_type): Update.
4113 * c-varobj.c (c_is_path_expr_parent): Update.
4114 * c-typeprint.c (c_type_print_base_struct_union): Update.
4115 (c_type_print_base_1): Update. Print struct/class/union/enum in
4116 summary when using C language.
4117 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
4118 (gen_maybe_namespace_elt): Update.
4119 * ada-lang.c (ada_type_name): Simplify.
4120 (empty_record, ada_template_to_fixed_record_type_1)
4121 (template_to_static_fixed_type)
4122 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
4123
4124 2018-06-01 Tom Tromey <tom@tromey.com>
4125
4126 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
4127 c_print_type.
4128 * c-typeprint.c (c_print_type_1): Add "language" parameter.
4129 (c_print_type): Update.
4130 (c_print_type): New overload.
4131 (c_type_print_varspec_prefix, c_type_print_args)
4132 (c_type_print_varspec_suffix, c_print_type_no_offsets)
4133 (c_type_print_base_struct_union, c_type_print_base_1)
4134 (cp_type_print_method_args): Add "language" parameter.
4135 (c_type_print_base): Update.
4136 * c-lang.h (c_print_type): Add new overload.
4137
4138 2018-06-01 Tom Tromey <tom@tromey.com>
4139
4140 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
4141 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
4142
4143 2018-06-01 Alan Hayward <alan.hayward@arm.com>
4144
4145 * aarch64-tdep.c (aarch64_sve_register_names): New const
4146 var.
4147 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
4148 (AARCH64_SVE_Z_REGS_NUM): New define.
4149 (AARCH64_SVE_P_REGS_NUM): Likewise.
4150 (AARCH64_SVE_NUM_REGS): Likewise.
4151
4152 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
4153
4154 * nat/linux-ptrace.h [__alpha__]
4155 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
4156 definitions.
4157
4158 2018-05-31 Maciej W. Rozycki <macro@mips.com>
4159
4160 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
4161 the endianness selected.
4162 * NEWS: Document `set endian auto' mode operation update.
4163
4164 2018-05-31 Alan Hayward <alan.hayward@arm.com>
4165
4166 * Makefile.in: Add new header.
4167 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
4168 (sve_vl_from_vg): Likewise.
4169 (sve_vq_from_vl): Likewise.
4170 (sve_vl_from_vq): Likewise.
4171 (sve_vq_from_vg): Likewise.
4172 (sve_vg_from_vq): Likewise.
4173 * configure.nat: Add new c file.
4174 * nat/aarch64-sve-linux-ptrace.c: New file.
4175 * nat/aarch64-sve-linux-ptrace.h: New file.
4176
4177 2018-05-31 Alan Hayward <alan.hayward@arm.com>
4178
4179 * aarch64-linux-nat.c (aarch64_linux_read_description):
4180 Add parmeter zero.
4181 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
4182 Likewise.
4183 * aarch64-tdep.c (tdesc_aarch64_list): Add.
4184 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
4185 (aarch64_gdbarch_init): Add parmeter zero.
4186 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
4187 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
4188 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
4189 parmeter.
4190 * doc/gdb.texinfo: Describe SVE feature
4191 * features/aarch64-sve.c: New file.
4192
4193 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
4194
4195 PR gdb/23210
4196 * gdbarch.sh (significant_addr_bit): Default to zero when
4197 not set by target architecture.
4198 * gdbarch.c: Re-generated.
4199 * utils.c (address_significant): Update.
4200
4201 2018-05-30 Joel Brobecker <brobecker@adacore.com>
4202
4203 * stack.c (func_command): Remove trailing newline in call to error.
4204
4205 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4206
4207 * regcache.h (regcache_raw_collect): Remove, update callers to
4208 use regcache::raw_collect.
4209 * regcache.c (regcache_raw_collect): Remove.
4210
4211 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4212
4213 * regcache.h (regcache_raw_supply): Remove, update callers to
4214 use detached_regcache::raw_supply.
4215 * regcache.c (regcache_raw_supply): Remove.
4216
4217 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4218
4219 * regcache.h (regcache_cooked_write_part): Remove, update
4220 callers to use regcache::cooked_write_part.
4221 * regcache.c (regcache_cooked_write_part): Remove.
4222
4223 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4224
4225 * regcache.h (regcache_cooked_read_part): Remove, update callers
4226 to use readable_regcache::cooked_read_part.
4227 * regcache.c (regcache_cooked_read_part): Remove.
4228
4229 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4230
4231 * regcache.h (regcache_cooked_read_value): Remove, update
4232 callers to use readable_regcache::cooked_read_value.
4233 * regcache.c (regcache_cooked_read_value): Remove.
4234
4235 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4236
4237 * regcache.h (regcache_cooked_write): Remove, update callers to
4238 use regcache::cooked_write.
4239 * regcache.c (regcache_cooked_write): Remove.
4240
4241 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4242
4243 * regcache.h (regcache_invalidate): Remove, update callers to
4244 use detached_regcache::invalidate instead.
4245 * regcache.c (regcache_invalidate): Remove.
4246
4247 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4248
4249 * regcache.h (regcache_raw_write_part): Remove, update callers
4250 to use regcache::raw_write_part instead.
4251 * regcache.c (regcache_raw_write_part): Remove.
4252
4253 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4254
4255 * regcache.h (regcache_raw_read_part): Remove, update callers to
4256 use readable_regcache::raw_read_part instead.
4257 * regcache.c (regcache_raw_read_part): Remove.
4258
4259 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4260
4261 * regcache.h (regcache_cooked_read): Remove, update callers to
4262 use readable_regcache::cooked_read instead.
4263 * regcache.c (regcache_cooked_read): Remove.
4264
4265 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4266
4267 * regcache.h (regcache_raw_write): Remove, update callers to use
4268 regcache::raw_write instead.
4269 * regcache.c (regcache_raw_write): Remove.
4270
4271 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4272
4273 * regcache.h (regcache_raw_read): Remove, update callers to use
4274 readable_regcache::raw_read instead.
4275 * regcache.c (regcache_raw_read): Remove.
4276
4277 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4278
4279 * regcache.h (regcache_raw_update): Remove, update callers to
4280 use readable_regcache::raw_update instead.
4281 * regcache.c (regcache_raw_update): Remove.
4282
4283 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4284
4285 * regcache.h (regcache_register_status): Remove, update callers
4286 to use reg_buffer::get_register_status directly instead.
4287 * regcache.c (regcache_register_status): Remove.
4288
4289 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4290
4291 * regcache.h (regcache_get_ptid): Remove, update all callers to
4292 call regcache::ptid instead.
4293 * regcache.c (regcache_get_ptid): Remove.
4294
4295 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4296
4297 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
4298
4299 2018-05-30 Pedro Alves <palves@redhat.com>
4300
4301 * common/common-exceptions.h (exception_rethrow): Use
4302 ATTRIBUTE_NORETURN.
4303
4304 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
4305
4306 * breakpoint.c (print_solib_event, check_status_catch_solib):
4307 Remove struct keyword in range-based for loops.
4308 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
4309 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
4310 Likewise.
4311 * linespec.c (find_superclass_methods, search_minsyms_for_name):
4312 Likewise.
4313 * symfile.c (addr_info_make_relative): Likewise.
4314 * thread.c (value_in_thread_stack_temporaries): Likewise.
4315
4316 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
4317
4318 PR gdb/16841
4319 * valops.c (value_struct_elt_for_reference): Call check_typedef on
4320 aggregate type to get its real type before accessing it.
4321
4322 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
4323
4324 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
4325 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
4326 * coff-pe-read.c (add_pe_forwarded_sym): Replace
4327 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
4328 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
4329 * jit.c (jit_breakpoint_re_set_internal): Likewise.
4330 * printcmd.c (info_address_command): Likewise.
4331
4332 2018-05-29 Tom Tromey <tom@tromey.com>
4333
4334 * windows-nat.c (handle_exception): Update fall-through comment.
4335
4336 2018-05-29 Tom Tromey <tom@tromey.com>
4337
4338 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
4339 (struct program_space) <added_solibs>: Now a std::vector.
4340 * breakpoint.c (print_solib_event): Update.
4341 (check_status_catch_solib): Update.
4342 * progspace.c (clear_program_space_solib_cache): Update.
4343 * solib.c (update_solib_list): Update.
4344
4345 2018-05-29 Tom Tromey <tom@tromey.com>
4346
4347 * python/py-type.c (typy_richcompare): Update.
4348 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
4349 * gdbtypes.h (types_deeply_equal): Return bool.
4350 (types_equal): Likewise.
4351 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
4352 declare VEC.
4353 (check_types_equal): Change worklist to std::vector. Return
4354 bool.
4355 (struct type_equality_entry): Add constructor.
4356 (compare_maybe_null_strings): Return bool.
4357 (check_types_worklist): Return bool. Change worklist to
4358 std::vector.
4359 (types_deeply_equal): Use std::vector.
4360 (types_equal): Return bool.
4361 (compare_maybe_null_strings): Simplify.
4362
4363 2018-05-29 Tom Tromey <tom@tromey.com>
4364
4365 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
4366
4367 2018-05-29 Tom Tromey <tom@tromey.com>
4368
4369 * objc-lang.h: Don't include cp-support.h.
4370 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
4371 declare VEC.
4372
4373 2018-05-27 Tom Tromey <tom@tromey.com>
4374
4375 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
4376
4377 2018-05-25 Tom Tromey <tom@tromey.com>
4378
4379 * value.c (value::location): Initialize.
4380
4381 2018-05-25 Tom Tromey <tom@tromey.com>
4382
4383 * dbxread.c (init_bincl_list): Remove.
4384 (bincl_list): Now a std::vector.
4385 (bincls_allocated, next_bincl): Remove.
4386 (free_bincl_list, do_free_bincl_list_cleanup)
4387 (make_cleanup_free_bincl_list): Remove.
4388 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
4389 unique_xmalloc_ptr.
4390 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
4391 (struct header_file_location): Add constructor.
4392 (add_bincl_to_list): Remove.
4393
4394 2018-05-25 Tom Tromey <tom@tromey.com>
4395
4396 * tui/tui.c (tui_enable): Update.
4397 * mi/mi-interp.c (mi_interp::init): Update.
4398 * interps.h (class interp) <name>: New method.
4399 <m_name>: Rename from name.
4400 (~scoped_restore_interp): Update.
4401 * interps.c (interp::interp): Update.
4402 (interp_add, interp_set, interp_lookup_existing)
4403 (current_interp_named_p): Update.
4404
4405 2018-05-25 Tom Tromey <tom@tromey.com>
4406
4407 * interps.c (interp_name): Remove.
4408 * mi/mi-interp.c (mi_interp::init): Update.
4409 * interps.h (interp_name): Remove.
4410 (~scoped_restore_interp): Update.
4411 * tui/tui.c (tui_enable): Update.
4412
4413 2018-05-25 Tom Tromey <tom@tromey.com>
4414
4415 * utils.c (fputs_maybe_filtered): Update.
4416 * linespec.c (decode_line_full): Update.
4417 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
4418 (mi_print_breakpoint_for_event, mi_solib_loaded)
4419 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
4420 (mi_user_selected_context_changed): Update.
4421 * mi/mi-main.c (mi_execute_command): Update.
4422 * cli/cli-script.c (execute_control_command): Update.
4423 * python/python.c (execute_gdb_command): Update.
4424 * solib.c (info_sharedlibrary_command): Update.
4425 * interps.c (interp_ui_out): Remove.
4426 * interps.h (interp_ui_out): Remove.
4427
4428 2018-05-25 Tom Tromey <tom@tromey.com>
4429
4430 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
4431 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
4432 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
4433
4434 2018-05-25 Tom Tromey <tom@tromey.com>
4435
4436 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
4437 * interps.c (interp_exec): Use scoped_restore.
4438
4439 2018-05-25 Tom Tromey <tom@tromey.com>
4440
4441 * remote.c (remote_target::remote_file_get): Use
4442 gdb::byte_vector.
4443 (remote_target::remote_file_put): Likewise.
4444
4445 2018-05-25 Tom Tromey <tom@tromey.com>
4446
4447 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
4448 a std::string.
4449 (get_pe_section_index, add_pe_exported_sym): Update.
4450 (read_pe_exported_syms): Use gdb::def_vector.
4451
4452 2018-05-25 Tom Tromey <tom@tromey.com>
4453
4454 * frame.c (remove_prev_frame): Remove.
4455 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
4456
4457 2018-05-25 Maciej W. Rozycki <macro@mips.com>
4458
4459 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
4460 Remove prototypes.
4461 * mips-linux-nat.c (supply_fpregset): Always call
4462 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
4463 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
4464 `mips_fill_fpregset'.
4465 * mips-linux-tdep.c (mips_supply_fpregset)
4466 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
4467 (mips_fill_fpregset_wrapper): Remove functions.
4468 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
4469 (mips_linux_fpregset): Remove variable.
4470 (mips_linux_iterate_over_regset_sections): Use
4471 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
4472 (mips_linux_o32_sigframe_init): Remove comment.
4473
4474 2018-05-25 Pedro Alves <palves@redhat.com>
4475
4476 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
4477 (struct readahead_cache, struct packet_reg, struct
4478 remote_arch_state, class remote_state): Move higher up in the
4479 file.
4480 (remote_target::m_remote_state): Now an object instead of a pointer.
4481 (remote_target::get_remote_state): Adjust.
4482
4483 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
4484
4485 * stack.c (select_and_print_frame): Delete.
4486 (struct function_bounds): Move struct within function.
4487 (func_command): Most content moved into new function
4488 find_frame_for_function, use new function, print result, add
4489 function comment.
4490 (find_frame_for_function): New function, now returns a result.
4491
4492 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4493
4494 * stack.c (iterate_over_block_arg_vars): Fix comment.
4495 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
4496
4497 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
4498
4499 PR gdb/23203
4500 * frame.c
4501 (scoped_restore_selected_frame::scoped_restore_selected_frame):
4502 Define.
4503 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
4504 Define.
4505 * frame.h (class scoped_restore_selected_frame): New class.
4506 * stack.c (print_frame_local_vars): Remove catching and rethrowing
4507 of any exception, use scoped_restore_selected_frame to restore the
4508 frame instead.
4509
4510 2018-05-24 Pedro Alves <palves@redhat.com>
4511
4512 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
4513 override.
4514
4515 2018-05-23 Tom Tromey <tom@tromey.com>
4516
4517 * complaints.c (struct complaints): Remove.
4518 (symfile_complaint_book): Remove.
4519 (series): New global.
4520 (complaint_internal): Update.
4521 (clear_complaints): Update.
4522
4523 2018-05-23 Tom Tromey <tom@tromey.com>
4524
4525 * complaints.c (counters): New global.
4526 (struct complain): Remove.
4527 (struct complaints) <root>: Remove.
4528 (complaint_sentinel): Remove.
4529 (symfile_complaint_book): Update.
4530 (find_complaint) Remove.
4531 (complaint_internal, clear_complaints): Update.
4532
4533 2018-05-23 Tom Tromey <tom@tromey.com>
4534
4535 * complaints.c (struct complain) <file, line>: Remove.
4536 (find_complaint): Remove file, line parameters.
4537 (complaint_internal): Update.
4538
4539 2018-05-23 Tom Tromey <tom@tromey.com>
4540
4541 * complaints.c (vcomplaint): Remove.
4542 (complaint_internal) Merge in contents of vcomplaint.
4543
4544 2018-05-23 Tom Tromey <tom@tromey.com>
4545
4546 * complaints.c (struct complaints) <explanation>: Remove.
4547 (symfile_explanations): Remove.
4548 (symfile_complaint_book): Update.
4549 (vcomplaint): Update.
4550 (struct explanation): Remove.
4551
4552 2018-05-23 Tom Tromey <tom@tromey.com>
4553
4554 * complaints.c (symfile_complaints): Remove.
4555 (complaint_internal): Remove "complaints" parameter.
4556 (clear_complaints, vcomplaint): Remove "c" parameter.
4557 (get_complaints): Remove.
4558 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
4559 (dwarf2_debug_line_missing_file_complaint)
4560 (dwarf2_debug_line_missing_end_sequence_complaint)
4561 (dwarf2_complex_location_expr_complaint)
4562 (dwarf2_const_value_length_mismatch_complaint)
4563 (dwarf2_section_buffer_overflow_complaint)
4564 (dwarf2_macro_malformed_definition_complaint)
4565 (dwarf2_invalid_attrib_class_complaint)
4566 (create_addrmap_from_index, dw2_symtab_iter_next)
4567 (dw2_expand_marked_cus)
4568 (dw2_debug_names_iterator::find_vec_in_debug_names)
4569 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
4570 (create_debug_type_hash_table, init_cutu_and_read_dies)
4571 (partial_die_parent_scope, add_partial_enumeration)
4572 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
4573 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
4574 (read_import_statement, read_file_scope, create_dwo_cu_reader)
4575 (create_cus_hash_table, create_dwp_hash_table)
4576 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
4577 (dwarf2_rnglists_process, dwarf2_ranges_process)
4578 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
4579 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
4580 (handle_struct_member_die, process_structure_scope)
4581 (read_array_type, read_common_block, read_module_type)
4582 (read_tag_pointer_type, read_typedef, read_base_type)
4583 (read_subrange_type, load_partial_dies, partial_die_info::read)
4584 (partial_die_info::read, partial_die_info::read)
4585 (partial_die_info::read, read_checked_initial_length_and_offset)
4586 (dwarf2_string_attr, read_formatted_entries)
4587 (dwarf_decode_line_header)
4588 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
4589 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
4590 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
4591 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
4592 (get_signatured_type, get_DW_AT_signature_type)
4593 (decode_locdesc, file_file_name, consume_improper_spaces)
4594 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
4595 (dwarf_decode_macro_bytes, dwarf_decode_macros)
4596 (dwarf2_symbol_mark_computed, set_die_type)
4597 (read_attribute_value): Update.
4598 * stap-probe.c (handle_stap_probe, get_stap_base_address):
4599 Update.
4600 * dbxread.c (unknown_symtype_complaint)
4601 (lbrac_mismatch_complaint, repeated_header_complaint)
4602 (set_namestring, function_outside_compilation_unit_complaint)
4603 (read_dbx_symtab, process_one_symbol): Update.
4604 * gdbtypes.c (stub_noname_complaint): Update.
4605 * windows-nat.c (handle_unload_dll): Update.
4606 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
4607 (decode_base_type): Update.
4608 * xcoffread.c (bf_notfound_complaint, ef_complaint)
4609 (eb_complaint, record_include_begin, record_include_end)
4610 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
4611 (process_xcoff_symbol, read_symbol)
4612 (function_outside_compilation_unit_complaint)
4613 (scan_xcoff_symtab): Update.
4614 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
4615 * buildsym.c (finish_block_internal, make_blockvector)
4616 (end_symtab_get_static_block, augment_type_symtab): Update.
4617 * dtrace-probe.c (dtrace_process_dof)
4618 (dtrace_static_probe_ops::get_probes): Update.
4619 * complaints.h (struct complaint): Don't declare.
4620 (symfile_complaints): Remove.
4621 (complaint_internal): Remove "complaints" parameter.
4622 (complaint): Likewise.
4623 (clear_complaints): Likewise.
4624 * symfile.c (syms_from_objfile_1, finish_new_objfile)
4625 (reread_symbols): Update.
4626 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
4627 (dwarf2_frame_cache, decode_frame_entry): Update.
4628 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
4629 * objc-lang.c (lookup_objc_class, lookup_child_selector)
4630 (info_selectors_command): Update.
4631 * macrotab.c (macro_include, check_for_redefinition)
4632 (macro_undef): Update.
4633 * objfiles.c (filter_overlapping_sections): Update.
4634 * stabsread.c (invalid_cpp_abbrev_complaint)
4635 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
4636 (define_symbol, error_type, read_type, rs6000_builtin_type)
4637 (stabs_method_name_from_physname, read_member_functions)
4638 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
4639 (attach_fields_to_type, complain_about_struct_wipeout)
4640 (read_range_type, read_args, common_block_start)
4641 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
4642 Update.
4643 * mdebugread.c (index_complaint, unknown_ext_complaint)
4644 (basic_type_complaint, bad_tag_guess_complaint)
4645 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
4646 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
4647 (parse_procedure, parse_lines)
4648 (function_outside_compilation_unit_complaint)
4649 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
4650 (bad_tag_guess_complaint, reg_value_complaint): Update.
4651 * cp-support.c (demangled_name_complaint): Update.
4652 * macroscope.c (sal_macro_scope): Update.
4653 * dwarf-index-write.c (class debug_names): Update.
4654
4655 2018-05-23 Tom Tromey <tom@tromey.com>
4656
4657 * complaints.c (clear_complaints): Remove "noisy" parameter.
4658 * complaints.h (clear_complaints): Update.
4659 * symfile.c (syms_from_objfile_1, finish_new_objfile)
4660 (reread_symbols): Update.
4661
4662 2018-05-23 Tom Tromey <tom@tromey.com>
4663
4664 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
4665 SUBSEQUENT_MESSAGE.
4666 (vcomplaint, clear_complaints): Update.
4667 (symfile_explanations): Remove some messages.
4668
4669 2018-05-23 Tom Tromey <tom@tromey.com>
4670
4671 * complaints.c (internal_complaint): Remove.
4672 * complaints.h (internal_complaint): Remove.
4673
4674 2018-05-22 Maciej W. Rozycki <macro@mips.com>
4675
4676 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
4677
4678 2018-05-22 Pedro Alves <palves@redhat.com>
4679
4680 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
4681 (remote_fileio_badfd, remote_fileio_return_errno)
4682 (remote_fileio_return_success, remote_fileio_func_open)
4683 (remote_fileio_func_open, remote_fileio_func_close)
4684 (remote_fileio_func_read, remote_fileio_func_write)
4685 (remote_fileio_func_lseek, remote_fileio_func_rename)
4686 (remote_fileio_func_unlink, remote_fileio_func_stat)
4687 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
4688 (remote_fileio_func_isatty, remote_fileio_func_system): Add
4689 remote_target parameter.
4690 (remote_fio_func_map) <func>: Add remote_target parameter.
4691 (do_remote_fileio_request, remote_fileio_request):
4692 * remote-fileio.h (remote_fileio_request):
4693 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
4694 remote_target parameter.
4695 (remote_notif_process, handle_notification): Adjust to pass down
4696 the remote.
4697 (remote_notif_state_allocate): Add remote_target parameter. Save
4698 it.
4699 * remote-notif.h (struct remote_target): Forward declare.
4700 (struct notif_client) <parse, ack, can_get_pending_events>: Add
4701 remote_target parameter.
4702 (struct remote_notif_state) <remote>: New field.
4703 (remote_notif_ack, remote_notif_parse): Add remote_target
4704 parameter.
4705 (remote_notif_state_allocate, remote_notif_state_allocate): Add
4706 remote_target parameter.
4707 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
4708 (threads_listing_context, rmt_thread_action, protocol_feature)
4709 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
4710 (packet_result, struct threads_listing_context, remote_state):
4711 Move definitions and declarations higher up.
4712 (remote_target) <~remote_target>: Declare.
4713 (remote_download_command_source, remote_file_put, remote_file_get)
4714 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
4715 (remote_hostio_pread_vFile, remote_hostio_send_command)
4716 (remote_hostio_set_filesystem, remote_hostio_open)
4717 (remote_hostio_close, remote_hostio_unlink, remote_state)
4718 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
4719 (get_memory_write_packet_size, get_memory_read_packet_size)
4720 (append_pending_thread_resumptions, remote_detach_1)
4721 (append_resumption, remote_resume_with_vcont)
4722 (add_current_inferior_and_thread, wait_ns, wait_as)
4723 (process_stop_reply, remote_notice_new_inferior)
4724 (process_initial_stop_replies, remote_add_thread)
4725 (btrace_sync_conf, remote_btrace_maybe_reopen)
4726 (remove_new_fork_children, kill_new_fork_children)
4727 (discard_pending_stop_replies, stop_reply_queue_length)
4728 (check_pending_events_prevent_wildcard_vcont)
4729 (discard_pending_stop_replies_in_queue, stop_reply)
4730 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
4731 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
4732 (remote_interrupt_as, remote_interrupt_ns)
4733 (remote_get_noisy_reply, remote_query_attached)
4734 (remote_add_inferior, remote_current_thread, get_current_thread)
4735 (set_thread, set_general_thread, set_continue_thread)
4736 (set_general_process, write_ptid)
4737 (remote_unpack_thread_info_response, remote_get_threadinfo)
4738 (parse_threadlist_response, remote_get_threadlist)
4739 (remote_threadlist_iterator, remote_get_threads_with_ql)
4740 (remote_get_threads_with_qxfer)
4741 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
4742 (get_offsets, remote_check_symbols, remote_supported_packet)
4743 (remote_query_supported, remote_packet_size)
4744 (remote_serial_quit_handler, remote_detach_pid)
4745 (remote_vcont_probe, remote_resume_with_hc)
4746 (send_interrupt_sequence, interrupt_query)
4747 (remote_notif_get_pending_events, fetch_register_using_p)
4748 (send_g_packet, process_g_packet, fetch_registers_using_g)
4749 (store_register_using_P, store_registers_using_G)
4750 (set_remote_traceframe, check_binary_download)
4751 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
4752 (remote_xfer_live_readonly_partial, remote_read_bytes)
4753 (remote_send_printf, remote_flash_write, readchar)
4754 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
4755 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
4756 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
4757 (extended_remote_disable_randomization, extended_remote_run)
4758 (send_environment_packet, extended_remote_environment_support)
4759 (extended_remote_set_inferior_cwd, remote_write_qxfer)
4760 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
4761 (packet_command): Now methods of ...
4762 (remote_target): ... this class.
4763 (m_remote_state) <remote_target>: New field.
4764 (struct remote_state) <stop_reply_queue,
4765 remote_async_inferior_event_token, wait_forever_enabled_p>: New
4766 fields.
4767 (remote_state::remote_state): Allocate stop_reply_queue.
4768 (remote_state): Delete global.
4769 (get_remote_state_raw): Delete.
4770 (remote_target::get_remote_state): Allocate m_remote_state on
4771 demand.
4772 (get_current_remote_target): New.
4773 (remote_ops, extended_remote_ops): Delete.
4774 (wait_forever_enabled_p, remote_async_inferior_event_token):
4775 Delete, moved to struct remote_state.
4776 (remote_target::close): Delete self. Destruction bits split to
4777 ...
4778 (remote_target::~remote_target): ... this.
4779 (show_memory_packet_size): Adjust to use
4780 get_current_remote_target.
4781 (struct protocol_feature) <func>: Add remote_target parameter.
4782 All callers adjusted.
4783 (curr_quit_handler_target): New.
4784 (remote_serial_quit_handler): Reimplement.
4785 (remote_target::open_1): Adjust to use get_current_remote_target.
4786 Heap-allocate remote_target/extended_remote_target instances.
4787 (vcont_builder::vcont_builder): Add remote_target parameter, and
4788 save it in m_remote. All callers adjusted.
4789 (vcont_builder::m_remote): New field.
4790 (vcont_builder::restart, vcont_builder::flush)
4791 (vcont_builder::push_action): Use it.
4792 (remote_target::commit_resume): Use it.
4793 (struct queue_iter_param) <remote>: New field.
4794 (remote_target::remove_new_fork_children): Fill in 'remote' field.
4795 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
4796 (check_pending_event_prevents_wildcard_vcont_callback)
4797 (remote_target::check_pending_events_prevent_wildcard_vcont)
4798 (remote_target::discard_pending_stop_replies)
4799 (remote_target::discard_pending_stop_replies_in_queue)
4800 (remote_target::remote_notif_remove_queued_reply): Fill in
4801 'remote' field.
4802 (remote_notif_get_pending_events): New.
4803 (remote_target::readchar, remote_target::remote_serial_write):
4804 Save/restore curr_quit_handler_target.
4805 (putpkt): New.
4806 (kill_new_fork_children): Fill in 'remote' field.
4807 (packet_command): Use get_current_remote_target, defer to
4808 remote_target method of same name.
4809 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
4810 parameter, and save it in m_remote. All callers adjusted.
4811 (scoped_remote_fd::release): Use m_remote.
4812 (scoped_remote_fd::m_remote): New field.
4813 (remote_file_put, remote_file_get, remote_file_delete): Use
4814 get_current_remote_target, defer to remote_target method of same
4815 name.
4816 (remote_btrace_reset): Add remote_state paremeter. Update all
4817 callers.
4818 (remote_async_inferior_event_handler). Pass down 'data'.
4819 (remote_new_objfile): Use get_current_remote_target.
4820 (remote_target::vcont_r_supported): New.
4821 (set_range_stepping): Use get_current_remote_target and
4822 remote_target::vcont_r_supported.
4823 (_initialize_remote): Don't allocate 'remote_state' and
4824 'stop_reply_queue' globals.
4825 * remote.h (struct remote_target): Forward declare.
4826 (getpkt, putpkt, remote_notif_get_pending_events): Add
4827 'remote_target' parameter.
4828
4829 2018-05-22 Pedro Alves <palves@redhat.com>
4830
4831 * remote.c (vcont_builder): Now a class. Make all data members
4832 private.
4833 (vcont_builder) <vcont_builder, restart, flush, push_action>:
4834 Declare methods.
4835 (vcont_builder_restart): Rename to ...
4836 (vcont_builder::restart): ... this.
4837 (vcont_builder_flush): Rename to ...
4838 (vcont_builder::flush): ... this.
4839 (vcont_builder_push_action): Rename to ...
4840 (vcont_builder::push_action): ... this.
4841 (remote_target::commit_resume): Adjust.
4842
4843 2018-05-22 Pedro Alves <palves@redhat.com>
4844
4845 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
4846 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
4847 (get_fixed_memory_packet_size): New.
4848 (get_memory_packet_size): Use it.
4849 (set_memory_packet_size): Don't override the config size with
4850 DEFAULT_MAX_MEMORY_PACKET_SIZE.
4851 (show_memory_packet_size): Use get_fixed_memory_packet_size.
4852 Don't refer to get_memory_packet_size if not connected to a remote
4853 target. Show "(default)" if configured size is 0.
4854
4855 2018-05-22 Pedro Alves <palves@redhat.com>
4856
4857 * remote.c (remote_target::mourn_inferior): Move
4858 discard_pending_stop_replies call here from ...
4859 (_initialize_remote): ... here.
4860
4861 2018-05-22 Pedro Alves <palves@redhat.com>
4862
4863 * remote.c (compare_section_command): Remove set_general_process
4864 call.
4865
4866 2018-05-22 Pedro Alves <palves@redhat.com>
4867
4868 * remote.c (struct packet_reg, struct remote_arch_state):
4869 Move higher up in the file.
4870 (remote_state) <m_arch_states>: Store remote_arch_state values
4871 instead of remote_arch_state pointers.
4872 (remote_state::get_remote_arch_state): Adjust.
4873
4874 2018-05-22 Pedro Alves <palves@redhat.com>
4875
4876 * remote.c: Include <unordered_map>.
4877 (remote_state): Now a class.
4878 (remote_state) <get_remote_arch_state>: Declare method.
4879 <get_remote_arch_state>: New field.
4880 (remote_arch_state) <remote_arch_state>: Declare ctor.
4881 <regs>: Now a unique_ptr.
4882 (remote_gdbarch_data_handle): Delete.
4883 (get_remote_arch_state): Delete.
4884 (remote_state::get_remote_arch_state): New.
4885 (get_remote_state): Adjust to call remote_state's
4886 get_remote_arch_state method.
4887 (init_remote_state): Delete, bits factored out to ...
4888 (remote_arch_state::remote_arch_state): ... this new method.
4889 (get_remote_packet_size, get_memory_packet_size)
4890 (process_g_packet, remote_target::fetch_registers)
4891 (remote_target::prepare_to_store, store_registers_using_G)
4892 (remote_target::store_registers, remote_target::get_trace_status):
4893 Adjust to call remote_state's method.
4894 (_initialize_remote): Remove reference to
4895 remote_gdbarch_data_handle.
4896
4897 2018-05-22 Pedro Alves <palves@redhat.com>
4898
4899 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
4900 pread>: New method declarations.
4901 (remote_target::open_1): Adjust.
4902 (readahead_cache_invalidate): Rename to ...
4903 (readahead_cache::invalidate): ... this, and adjust to be a class
4904 method.
4905 (readahead_cache_invalidate_fd): Rename to ...
4906 (readahead_cache::invalidate_fd): ... this, and adjust to be a
4907 class method.
4908 (remote_hostio_pwrite): Adjust.
4909 (remote_hostio_pread_from_cache): Rename to ...
4910 (readahead_cache::pread): ... this, and adjust to be a class
4911 method.
4912 (remote_hostio_close): Adjust.
4913
4914 2018-05-22 Pedro Alves <palves@redhat.com>
4915
4916 * remote.c (remote_hostio_close_cleanup): Delete.
4917 (class scoped_remote_fd): New.
4918 (remote_file_put, remote_file_get): Use it.
4919
4920 2018-05-22 Pedro Alves <palves@redhat.com>
4921
4922 (struct vCont_action_support): Use bool and initialize all fields.
4923 (struct readahead_cache): Initialize all fields.
4924 (remote_state): Use bool and initialize all fields.
4925 (remote_state::remote_state, remote_state::~remote_state): New.
4926 (new_remote_state): Delete.
4927 (_initialize_remote): Use new to allocate remote_state.
4928
4929 2018-05-22 Pedro Alves <palves@redhat.com>
4930 張俊芝 <zjz@zjz.name>
4931
4932 PR gdb/22973
4933 * c-exp.y: Include "c-support.h".
4934 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
4935 of tolower. Use c_ident_is_alpha to scan names.
4936 * c-lang.c: Include "c-support.h".
4937 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
4938 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
4939 * c-support.h: New file, with bits factored out from ...
4940 * cp-name-parser.y: ... this file.
4941 Include "c-support.h".
4942 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
4943 c-support.h and renamed.
4944 (symbol_end, yylex): Adjust.
4945
4946 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4947
4948 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
4949 parameter type to CORE_ADDR.
4950 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
4951 parameter type in declaration to CORE_ADDR.
4952 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
4953 target_auxv_search to get AT_HWCAP and use the result to get the
4954 target description.
4955 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
4956 to CORE_ADDR. Remove the cast of the return value to unsigned
4957 long. Fix error predicate of target_auxv_search.
4958 (ppc_linux_nat_target::read_description): Change the type of the
4959 hwcap variable to CORE_ADDR.
4960
4961 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4962
4963 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
4964 if the size of fpscr is larger than 32 bits.
4965
4966 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4967
4968 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
4969 (ppc32_linux_vsxregmap): New global.
4970 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
4971 regcache_supply_regset, and regcache_collect_regset.
4972 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
4973 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
4974 (fetch_vsx_register, store_vsx_register): Remove.
4975 (fetch_vsx_registers): Add regno parameter. Get regset using
4976 ppc_linux_vsxregset. Use regset to supply registers.
4977 (store_vsx_registers): Add regno parameter. Get regset using
4978 ppc_linux_vsxregset. Use regset to collect registers.
4979 (fetch_register): Call fetch_vsx_registers instead of
4980 fetch_vsx_register.
4981 (store_register): Call store_vsx_registers instead of
4982 store_vsx_register.
4983 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
4984 new regno parameter.
4985 (store_ppc_registers): Call store_vsx_registers with -1 for the
4986 new regno parameter.
4987 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
4988 (ppc_collect_vsxregset): Remove.
4989
4990 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4991
4992 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
4993 offset fields.
4994 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
4995 for vector register offset fields.
4996 (ppc64_fbsd_reg_offsets): Likewise.
4997 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4998 to vector register offset fields.
4999 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
5000 to vector register offset fields.
5001 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
5002 vector register offset fields.
5003 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
5004 initializers for vector register offset fields.
5005 (rs6000_aix64_reg_offsets): Likewise.
5006 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
5007 (ppc_supply_vrregset): Remove.
5008 (ppc_collect_vrregset): Remove.
5009 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
5010 (ppc_linux_vrregset) : New function.
5011 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
5012 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
5013 (ppc32_linux_vrregset): Remove.
5014 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
5015 and use result instead of ppc32_linux_vrregset.
5016 (ppc32_linux_reg_offsets): Remove initializers for vector register
5017 offset fields.
5018 (ppc64_linux_reg_offsets): Likewise.
5019 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
5020 * ppc-linux-nat.c: Include regset.h.
5021 (gdb_vrregset_t): Adjust comment to account for little-endian
5022 mode.
5023 (supply_vrregset, fill_vrregset): Remove.
5024 (fetch_altivec_register, store_altivec_register): Remove.
5025 (fetch_altivec_registers): Add regno parameter. Get regset using
5026 ppc_linux_vrregset. Use regset to supply registers.
5027 (store_altivec_registers): Add regno parameter. Get regset using
5028 ppc_linux_vrregset. Use regset to collect registers.
5029 (fetch_register): Call fetch_altivec_registers instead of
5030 fetch_altivec_register.
5031 (store_register): Call store_altivec_registers instead of
5032 store_altivec_register.
5033 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
5034 the new regno parameter.
5035 (store_ppc_registers): Call store_altivec_registers with -1 for
5036 the new regno parameter.
5037
5038 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5039
5040 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
5041 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
5042 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5043 (gdb_vrregset_t): Change array type size to
5044 PPC_LINUX_SIZEOF_VRREGSET.
5045 (gdb_vsxregset_t): Change array type size to
5046 PPC_LINUX_SIZEOF_VSXREGSET.
5047 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
5048 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
5049 PPC_LINUX_SIZEOF_VSXREGSET.
5050
5051 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5052
5053 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
5054 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
5055 nat/ppc-linux.c.
5056 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
5057 ppc_linux_target_wordsize with tid.
5058 (ppc_linux_nat_target::read_description): Call ppc_linux_target
5059 wordsize with tid.
5060 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
5061 (ppc64_64bit_inferior_p): Add static and inline specifiers.
5062 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
5063 tid parameter. Remove static specifier.
5064 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
5065 (ppc_linux_target_wordsize): New declaration.
5066
5067 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5068
5069 * arch/ppc-linux-common.c: New file.
5070 * arch/ppc-linux-common.h: New file.
5071 * arch/ppc-linux-tdesc.h: New file.
5072 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
5073 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
5074 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
5075 arch/ppc-linux-tdesc.h.
5076 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
5077 arch/ppc-linux-tdesc.h.
5078 (ppc_linux_nat_target::read_description): Remove target
5079 description matching code. Fill a ppc_linux_features struct and
5080 call ppc_linux_match_description with it. Move comment about ISA
5081 2.05 to ppc-linux-common.c.
5082 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
5083 arch/ppc-linux-tdesc.h.
5084 (ppc_linux_core_read_description): Remove target description
5085 matching code. Fill a ppc_linux_features struct and call
5086 ppc_linux_match_description with it.
5087 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5088 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5089 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5090 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5091 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5092 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5093 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5094 (tdesc_powerpc_e500l): Remove.
5095
5096 2018-05-22 Joel Brobecker <brobecker@adacore.com>
5097
5098 * ada-lang.c (catch_assert_command): Pass empty string instead
5099 of NULL for excep_string argument.
5100
5101 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5102
5103 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
5104 the width of the requested register exceeds the width of the
5105 `ptrace' data type.
5106
5107 2018-05-21 Tom Tromey <tom@tromey.com>
5108
5109 * printcmd.c (output_command): Remove.
5110 (output_command_const): Rename to output_command.
5111 * valprint.h (output_command): Rename from output_command_const.
5112 * tracepoint.c (trace_dump_actions): Call output_command.
5113
5114 2018-05-21 Tom Tromey <tom@tromey.com>
5115
5116 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
5117 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
5118 * ada-lang.h (create_ada_exception_catchpoint): Update.
5119 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
5120 std::string.
5121 (create_excep_cond_exprs, ~ada_catchpoint)
5122 (should_stop_exception, print_one_exception)
5123 (print_mention_exception, print_recreate_exception): Update.
5124 (ada_get_next_arg): Remove.
5125 (catch_ada_exception_command_split): Use std::string. Change type
5126 of "excep_string", "cond_string".
5127 (catch_ada_exception_command): Update.
5128 (create_ada_exception_catchpoint): Change type of excep_string.
5129 (ada_exception_sal): Remove excep_string parameter.
5130 (~ada_catchpoint): Remove.
5131
5132 2018-05-21 Tom Tromey <tom@tromey.com>
5133
5134 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
5135 cleanup.
5136
5137 2018-05-21 Tom Tromey <tom@tromey.com>
5138
5139 * ada-lang.c (ada_exception_message_1, ada_exception_message):
5140 Return unique_xmalloc_ptr.
5141 (print_it_exception): Update.
5142
5143 2018-05-21 Tom Tromey <tom@tromey.com>
5144
5145 * tracepoint.c (trace_dump_actions): Use std::string.
5146
5147 2018-05-21 Tom Tromey <tom@tromey.com>
5148
5149 * symfile.c (reread_symbols): Use std::string for original_name.
5150
5151 2018-05-21 Tom Tromey <tom@tromey.com>
5152
5153 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
5154 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
5155 constructor.
5156
5157 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
5158
5159 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
5160 instance to...
5161 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
5162 * objfiles.c (get_objfile_bfd_data): Allocate
5163 objfile_per_bfd_storage with obstack_new when allocating on
5164 obstack.
5165
5166 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
5167
5168 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
5169 OBSTACK_ZALLOC.
5170 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
5171 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
5172 * mdebugread.c (mdebug_build_psymtabs): Likewise.
5173 (add_pending): Likewise.
5174 (parse_symbol): Likewise.
5175 (parse_partial_symbols): Likewise.
5176 (psymtab_to_symtab_1): Likewise.
5177 (new_psymtab): Likewise.
5178 (elfmdebug_build_psymtabs): Likewise.
5179 * minsyms.c (terminate_minimal_symbol_table): Likewise.
5180 * objfiles.c (get_objfile_bfd_data): Likewise.
5181 (objfile_register_static_link): Likewise.
5182 * psymtab.c (allocate_psymtab): Likewise.
5183 * stabsread.c (read_member_functions): Likewise.
5184 * xcoffread.c (xcoff_end_psymtab): Likewise.
5185
5186 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
5187
5188 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
5189 compiler supports std::is_trivially_constructible.
5190 * common/poison.h: Include obstack.h.
5191 (IsMallocable): Define to is_trivially_constructible if the
5192 compiler supports it, define to true_type otherwise.
5193 (xobnew): New.
5194 (XOBNEW): Redefine.
5195 (xobnewvec): New.
5196 (XOBNEWVEC): Redefine.
5197 * gdb_obstack.h (obstack_zalloc): New.
5198 (OBSTACK_ZALLOC): Redefine.
5199 (obstack_calloc): New.
5200 (OBSTACK_CALLOC): Redefine.
5201 (obstack_new): New.
5202 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
5203 (gdbarch_obstack): New declaration in gdbarch.h, definition in
5204 gdbarch.c.
5205 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
5206 obstack_calloc/obstack_zalloc.
5207 (gdbarch_obstack_zalloc): Remove.
5208 * target-descriptions.c (tdesc_data_init): Use obstack_new.
5209
5210 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5211
5212 * stack.c (backtrace_command_1): Remove useless variable int i.
5213
5214 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5215
5216 * stack.c (print_frame_info): Fix comment.
5217
5218 2018-05-18 Tom Tromey <tom@tromey.com>
5219
5220 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
5221 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
5222 (~dwarf2_per_objfile): Update
5223 (dwarf2_get_dwz_file): Use new.
5224 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
5225 unique_ptr.
5226
5227 2018-05-18 Tom Tromey <tom@tromey.com>
5228
5229 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
5230 unique_ptr.
5231 * dwarf2read.c (struct dwp_file): Add constructor and
5232 initializers.
5233 (open_and_init_dwp_file): Return a unique_ptr.
5234 (dwarf2_per_objfile, create_dwp_hash_table)
5235 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
5236 (lookup_dwo_unit_in_dwp): Update.
5237 (open_and_init_dwp_file, get_dwp_file): Update.
5238
5239 2018-05-18 Tom Tromey <tom@tromey.com>
5240
5241 * dwarf2read.c (dwarf2_per_objfile): Update.
5242 (struct mapped_index): Add initializers.
5243 (dwarf2_read_index): Use new.
5244 (dw2_symtab_iter_init): Update.
5245 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
5246 unique_ptr.
5247
5248 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
5249
5250 * dwarf2read.c (mapped_index) <total_size>: Remove.
5251
5252 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
5253
5254 * unittests/format_pieces-selftests.c (test_format_specifier):
5255 Add ARI comments.
5256
5257 2018-05-18 Tom Tromey <tom@tromey.com>
5258
5259 * c-typeprint.c (maybe_print_hole): New function.
5260 (c_print_type_struct_field_offset): Update.
5261 (c_type_print_base_struct_union): Call maybe_print_hole.
5262
5263 2018-05-17 Keith Seitz <keiths@redhat.com>
5264
5265 * breakpoint.c (build_bpstat_chain): New function, moved from
5266 bpstat_stop_status.
5267 (bpstat_stop_status): Add optional parameter, `stop_chain'.
5268 If no stop chain is passed, call build_bpstat_chain to build it.
5269 * breakpoint.h (build_bpstat_chain): Declare.
5270 (bpstat_stop_status): Move documentation here from breakpoint.c.
5271 * infrun.c (handle_signal_stop): Before eliding inlined frames,
5272 build the stop chain and pass it to skip_inline_frames.
5273 Pass this stop chain to bpstat_stop_status.
5274 * inline-frame.c: Include breakpoint.h.
5275 (stopped_by_user_bp_inline_frame): New function.
5276 (skip_inline_frames): Add parameter `stop_chain'.
5277 Move documention to inline-frame.h.
5278 If non-NULL, use stopped_by_user_bp_inline_frame to determine
5279 whether the frame should be elided.
5280 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
5281 Add moved documentation and update for new parameter.
5282
5283 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
5284
5285 PR cli/14975
5286 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5287 unittests/format_pieces-selftests.c.
5288 * common/format.h (format_piece) <operator==>: New.
5289 (format_pieces) <operator[]>: Remove.
5290 * common/format.c (format_pieces::format_pieces): Handle \e.
5291 * unittests/format_pieces-selftests.c: New.
5292
5293 2018-05-17 Tom Tromey <tom@tromey.com>
5294
5295 PR symtab/23010:
5296 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
5297 (dw2_instantiate_symtab): Add skip_partial parameter.
5298 (dw2_find_last_source_symtab, dw2_map_expand_apply)
5299 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
5300 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
5301 (dw2_expand_symtabs_matching_one)
5302 (dw2_find_pc_sect_compunit_symtab)
5303 (dw2_debug_names_lookup_symbol)
5304 (dw2_debug_names_expand_symtabs_for_function): Update.
5305 (init_cutu_and_read_dies): Add skip_partial parameter.
5306 (process_psymtab_comp_unit, build_type_psymtabs_1)
5307 (process_skeletonless_type_unit, load_partial_comp_unit)
5308 (psymtab_to_symtab_1): Update.
5309 (load_full_comp_unit): Add skip_partial parameter.
5310 (process_imported_unit_die, dwarf2_read_addr_index)
5311 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
5312 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
5313 (read_signatured_type): Update.
5314
5315 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
5316
5317 * value.c (release_value): Remove unused variable.
5318 (record_latest_value): Likewise.
5319 (access_value_history): Likewise.
5320 (preserve_values): Likewise.
5321
5322 2018-05-17 Tom Tromey <tom@tromey.com>
5323
5324 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
5325 Initialize.
5326
5327 2018-05-16 Maciej W. Rozycki <macro@mips.com>
5328
5329 PR gdb/22286
5330 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
5331 Also handle registers whose width is not a multiple of
5332 PTRACE_TYPE_RET.
5333 (linux_nat_trad_target::store_register): Likewise.
5334
5335 2018-05-16 Tom Tromey <tom@tromey.com>
5336
5337 * gdbcore.h (core_bfd): Redefine.
5338 * corelow.c (core_target::close): Update.
5339 (core_target_open): Update.
5340 * progspace.h (struct program_space) <cbfd>: Now a
5341 gdb_bfd_ref_ptr.
5342
5343 2018-05-16 Tom Tromey <tom@tromey.com>
5344
5345 PR cli/19551:
5346 * symfile-add-flags.h (enum symfile_add_flags)
5347 <SYMFILE_NOT_FILENAME>: New constant.
5348 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
5349 objfile name from BFD.
5350 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
5351 * minidebug.c (find_separate_debug_file_in_section): Put
5352 ".gnu_debugdata" into BFD's file name.
5353
5354 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
5355
5356 * regcache.c (regcache_read_ftype, regcache_write_ftype):
5357 Remove.
5358
5359 2018-05-15 Tamar Christina <tamar.christina@arm.com>
5360
5361 PR binutils/21446
5362 * aarch64-tdep.c (aarch64_analyze_prologue,
5363 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
5364 Indicate not interested in errors.
5365
5366 2018-05-15 Maciej W. Rozycki <macro@mips.com>
5367
5368 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
5369 Supply the MIPS_ZERO_REGNUM register.
5370
5371 2018-05-15 Maciej W. Rozycki <macro@mips.com>
5372
5373 * mips-tdep.c (mask_address_var): Make variable static.
5374
5375 2018-05-14 Tom Tromey <tom@tromey.com>
5376
5377 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
5378
5379 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
5380
5381 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
5382 FXSAVE_ADDR for the mxcsr register.
5383
5384 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
5385
5386 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
5387
5388 2018-05-11 Pedro Alves <palves@redhat.com>
5389
5390 * corelow.c (core_target) <core_target>: No longer inline.
5391 Initialize m_core_gdbarch, m_core_vec and build the section table
5392 here.
5393 <~core_target>: New.
5394 <core_gdbarch, get_core_register_section>: New methods.
5395 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
5396 factored out from ...
5397 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
5398 (core_ops): Delete.
5399 (sniff_core_bfd): Add gdbarch parameter.
5400 (core_close): Delete, merged into ...
5401 (core_target::close): ... here. Delete self.
5402 (core_close_cleanup): Delete.
5403 (core_target_open): Allocate a core_target on the heap. Use a
5404 unique_ptr instead of a cleanup. Bits moved into the core_target
5405 ctor. Adjust to use core_target methods instead of globals.
5406 (get_core_register_section): Rename to ...
5407 (core_target::get_core_register_section): ... this and adjust.
5408 (struct get_core_registers_cb_data): New.
5409 (get_core_registers_cb): Use it. Use bool.
5410 (core_target::fetch_registers, core_target::files_info)
5411 (core_target::xfer_partial, core_target::read_description)
5412 (core_target::pid_to, core_target::thread_name): Adjust to
5413 reference class fields instead of globals.
5414 * target.h (struct target_ops_deleter, target_ops_up): New.
5415
5416 2018-05-11 Pedro Alves <palves@redhat.com>
5417
5418 * corefile.c (core_file_command): Move to corelow.c.
5419 * corelow.c (the_core_target): Delete.
5420 (core_file_command): Moved from corefile.c. Check exec_bfd
5421 instead of the_core_target. Use target_detach instead of calling
5422 into the_core_target directly.
5423 (maybe_say_no_core_file_now): New.
5424 (core_target::detach): Use it.
5425 (_initialize_corelow): Remove references to the_core_target.
5426 * gdbcore.h (the_core_target): Delete.
5427
5428 2018-05-11 Tom Tromey <tromey@redhat.com>
5429 Pedro Alves <palves@redhat.com>
5430
5431 * corefile.c (core_bfd): Remove.
5432 * gdbcore.h (core_bfd): Now a macro.
5433 * progspace.h (struct program_space) <cbfd>: New field.
5434
5435 2018-05-11 Tom Tromey <tom@tromey.com>
5436
5437 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
5438 gdb::def_vector.
5439
5440 2018-05-10 Tom Tromey <tom@tromey.com>
5441
5442 * configure: Rebuild.
5443 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
5444
5445 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5446
5447 PR server/23158:
5448 * regformats/regdat.sh: Adjust script, following the addition
5449 of the new expedite_regs parameter to init_target_desc.
5450
5451 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
5452
5453 PR gdb/23127
5454 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
5455 set_gdbarch_significant_addr_bit.
5456 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
5457 set_gdbarch_significant_addr_bit.
5458 * utils.c (address_significant): Update to sign extend addr.
5459
5460 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
5461
5462 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
5463 (xtensa_linux_init_abi): Limit tdep->num_regs by
5464 tdep->num_nopriv_regs.
5465 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
5466 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
5467 not initialized.
5468
5469 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
5470
5471 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
5472
5473 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5474
5475 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
5476 (I387_MXCSR_INIT_VAL): New constant.
5477 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
5478 buffer if it was supplied by the inferior.
5479 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
5480 (i387_xsave_get_clear_bv): New function.
5481 (i387_supply_xsave): Only read x87 control registers from the
5482 xsave buffer if the feature is enabled, and the state will have
5483 been written, otherwise, provide a suitable default.
5484 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
5485 including x87 control registers. Update control registers if they
5486 have changed from the default value, and mark features as enabled
5487 as required.
5488 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
5489
5490 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
5491
5492 * spu-tdep.c (info_spu_event_command): Fix output formatting.
5493
5494 2018-05-07 Tom Tromey <tom@tromey.com>
5495
5496 * configure: Rebuild.
5497 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
5498
5499 2018-05-07 Tom Tromey <tom@tromey.com>
5500
5501 PR tdep/20362:
5502 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
5503 bit. Use correct value for VDIV.
5504
5505 2018-05-04 Tom Tromey <tom@tromey.com>
5506
5507 * configure: Rebuild.
5508 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
5509
5510 2018-05-04 Tom Tromey <tom@tromey.com>
5511
5512 * linux-record.c (record_linux_system_call) <case
5513 RECORD_SYS_RECVFROM>: Add "break".
5514
5515 2018-05-04 Tom Tromey <tom@tromey.com>
5516
5517 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
5518 Add missing "break".
5519 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
5520 Add missing "break".
5521
5522 2018-05-04 Tom Tromey <tom@tromey.com>
5523
5524 * rs6000-tdep.c (ppc_process_record_op4)
5525 (ppc_process_record_op63): Add fall-through comment.
5526
5527 2018-05-04 Tom Tromey <tom@tromey.com>
5528
5529 * i386-tdep.c (i386_process_record): Add fall-through comment.
5530
5531 2018-05-04 Tom Tromey <tom@tromey.com>
5532
5533 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
5534 comment.
5535
5536 2018-05-04 Tom Tromey <tom@tromey.com>
5537
5538 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
5539 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
5540 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
5541 comment.
5542 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
5543 comment.
5544 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
5545 comment.
5546
5547 2018-05-04 Tom Tromey <tom@tromey.com>
5548
5549 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
5550
5551 2018-05-04 Tom Tromey <tom@tromey.com>
5552
5553 * s390-tdep.c (s390_process_record): Fix fall-through comments.
5554 * xcoffread.c (scan_xcoff_symtab): Move comment later.
5555 * symfile.c (section_is_mapped): Fix fall-through comment.
5556 * stabsread.c (define_symbol, read_member_functions): Fix
5557 fall-through comment.
5558 * s390-linux-tdep.c (s390_process_record): Fix fall-through
5559 comment.
5560 * remote.c (remote_wait_as): Fix fall-through comment.
5561 * p-exp.y (yylex): Fix fall-through comment.
5562 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
5563 comment.
5564 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
5565 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
5566 * jv-exp.y (yylex): Fix fall-through comment.
5567 * go-exp.y (lex_one_token): Fix fall-through comment.
5568 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
5569 fall-through comment.
5570 * f-exp.y (yylex): Fix fall-through comment.
5571 * dwarf2read.c (process_die): Fix fall-through comments.
5572 * dbxread.c (process_one_symbol): Fix fall-through comment.
5573 * d-exp.y (lex_one_token): Fix fall-through comment.
5574 * cp-name-parser.y (yylex): Fix fall-through comment.
5575 * coffread.c (coff_symtab_read): Fix fall-through comment.
5576 * c-exp.y (lex_one_token): Fix fall-through comment.
5577 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
5578 comment.
5579 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
5580 comment.
5581
5582 2018-05-04 Tom Tromey <tom@tromey.com>
5583
5584 PR python/22730:
5585 * NEWS: Mention gdb.execute change.
5586 * gdbcmd.h (execute_control_command): Don't declare.
5587 * python/python.c (execute_gdb_command): Use read_command_lines_1,
5588 execute_control_commands, execute_control_commands_to_string.
5589 * cli/cli-script.h (execute_control_commands)
5590 (execute_control_commands_to_string): Declare.
5591 (execute_control_command): Add from_tty parameter.
5592 * cli/cli-script.c (execute_control_commands)
5593 (execute_control_commands_to_string): New functions.
5594 (execute_user_command): Use execute_control_commands.
5595 (execute_control_command_1): Add "from_tty" parameter. Update.
5596 (execute_control_command): Likewise.
5597
5598 2018-05-04 Tom Tromey <tom@tromey.com>
5599
5600 PR python/22731:
5601 * NEWS: Mention that breakpoint commands are writable.
5602 * python/py-breakpoint.c (bppy_set_commands): New function.
5603 (breakpoint_object_getset) <"commands">: Use it.
5604
5605 2018-05-04 Tom Tromey <tom@tromey.com>
5606
5607 * tracepoint.c (actions_command): Update.
5608 * mi/mi-cmd-break.c (mi_command_line_array)
5609 (mi_command_line_array_cnt, mi_command_line_array_ptr)
5610 (mi_read_next_line): Remove.
5611 (mi_cmd_break_commands): Update.
5612 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
5613 function_view.
5614 * cli/cli-script.c (get_command_line): Update.
5615 (process_next_line): Use function_view. Constify.
5616 (recurse_read_control_structure, read_command_lines)
5617 (read_command_lines_1): Change argument types to function_view.
5618 (do_define_command, document_command): Update.
5619 * breakpoint.h (check_tracepoint_command): Don't declare.
5620 * breakpoint.c (check_tracepoint_command): Remove.
5621 (commands_command_1, create_tracepoint_from_upload): Update.
5622
5623 2018-05-04 Tom Tromey <tom@tromey.com>
5624
5625 PR gdb/11750:
5626 * cli/cli-script.h (enum command_control_type) <define_control>:
5627 New constant.
5628 * cli/cli-script.c (multi_line_command_p): Handle define_control.
5629 (build_command_line, execute_control_command_1)
5630 (process_next_line): Likewise.
5631 (do_define_command): New function, extracted from define_command.
5632 (define_command): Use it.
5633
5634 2018-05-04 Tom Tromey <tom@tromey.com>
5635
5636 * tracepoint.c (actions_command): Update.
5637 * cli/cli-script.h (read_command_lines): Update.
5638 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
5639 (MAX_TMPBUF): Remove define.
5640 (define_command): Use string_printf.
5641 (document_command): Likewise.
5642 * breakpoint.c (commands_command_1): Update.
5643
5644 2018-05-04 Tom Tromey <tom@tromey.com>
5645
5646 * top.c (execute_command): Update.
5647 * cli/cli-script.h (print_command_lines): Now varargs.
5648 * cli/cli-script.c (print_command_lines): Now varargs.
5649 (execute_control_command_1) <case while_control, case if_control>:
5650 Update.
5651
5652 2018-05-04 Tom Tromey <tom@tromey.com>
5653
5654 * tracepoint.c (all_tracepoint_actions): Rename from
5655 all_tracepoint_actions_and_cleanup. Change return type.
5656 (actions_command, encode_actions_1, encode_actions)
5657 (trace_dump_actions, tdump_command): Update.
5658 * remote.c (remote_download_command_source): Update.
5659 * python/python.c (gdbpy_eval_from_control_command)
5660 (python_command, python_interactive_command): Update.
5661 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
5662 * guile/guile.c (guile_command)
5663 (gdbscm_eval_from_control_command, guile_command): Update.
5664 * compile/compile.c (compile_code_command)
5665 (compile_print_command, compile_to_object): Update.
5666 * cli/cli-script.h (struct command_lines_deleter): New.
5667 (counted_command_line): New typedef.
5668 (struct command_line): Add constructor, destructor.
5669 <body_list>: Remove.
5670 <body_list_0, body_list_1>: New members.
5671 (command_line_up): Remove typedef.
5672 (read_command_lines, read_command_lines_1, get_command_line):
5673 Update.
5674 (copy_command_lines): Don't declare.
5675 * cli/cli-script.c (build_command_line): Use "new".
5676 (get_command_line): Return counted_command_line.
5677 (print_command_lines, execute_user_command)
5678 (execute_control_command_1, while_command, if_command): Update.
5679 (realloc_body_list): Remove.
5680 (process_next_line, recurse_read_control_structure): Update.
5681 (read_command_lines, read_command_lines_1): Return counted_command_line.
5682 (free_command_lines): Use "delete".
5683 (copy_command_lines): Remove.
5684 (define_command, document_command, show_user_1): Update.
5685 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
5686 a counted_command_line.
5687 * breakpoint.h (counted_command_line): Remove typedef.
5688 (breakpoint_set_commands): Update.
5689 * breakpoint.c (check_no_tracepoint_commands)
5690 (validate_commands_for_breakpoint): Update.
5691 (breakpoint_set_commands): Change commands to be a
5692 counted_command_line.
5693 (commands_command_1, update_dprintf_command_list)
5694 (create_tracepoint_from_upload): Update.
5695
5696 2018-05-04 Tom Tromey <tom@tromey.com>
5697
5698 * cli/cli-decode.h (cmd_list_element): New constructor.
5699 (~cmd_list_element): New destructor.
5700 (struct cmd_list_element): Add initializers.
5701 * cli/cli-decode.c (do_add_cmd): Use "new".
5702 (delete_cmd): Use "delete".
5703
5704 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5705 Pedro Alves <palves@redhat.com>
5706
5707 PR breakpoints/19806 and support for PR external/20207.
5708 * NEWS: Mention Aarch64 watchpoint improvements.
5709 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
5710 watchpoints and PR external/20207 watchpoints.
5711 * nat/aarch64-linux-hw-point.c
5712 (kernel_supports_any_contiguous_range): New.
5713 (aarch64_watchpoint_offset): New.
5714 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
5715 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
5716 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
5717 (aarch64_align_watchpoint): New parameters aligned_offset_p and
5718 next_addr_orig_p. Support PR external/20207 watchpoints.
5719 (aarch64_downgrade_regs): New.
5720 (aarch64_dr_state_insert_one_point): New parameters offset and
5721 addr_orig.
5722 (aarch64_dr_state_remove_one_point): Likewise.
5723 (aarch64_handle_breakpoint): Update caller.
5724 (aarch64_handle_aligned_watchpoint): Likewise.
5725 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
5726 aligned_offset.
5727 (aarch64_linux_set_debug_regs): Remove const from state. Call
5728 aarch64_downgrade_regs.
5729 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
5730 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
5731 (DR_CONTROL_MASK): ... this.
5732 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
5733 (unsigned int aarch64_watchpoint_offset): New prototype.
5734 (aarch64_linux_set_debug_regs): Remove const from state.
5735 * utils.c (align_up, align_down): Move to ...
5736 * common/common-utils.c (align_up, align_down): ... here.
5737 * utils.h (align_up, align_down): Move to ...
5738 * common/common-utils.h (align_up, align_down): ... here.
5739
5740 2018-05-04 Joel Brobecker <brobecker@adacore.com>
5741
5742 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
5743 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
5744 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
5745 Re-implement to match the ABI as summarized in GCC's
5746 gcc/config/sparc/sparc.c. All callers updated.
5747 (sparc32_store_arguments): Remove assertion.
5748
5749 2018-05-04 Tom Tromey <tom@tromey.com>
5750
5751 * printcmd.c: Don't include tui.h.
5752 (decode_format): Use skip_spaces.
5753
5754 2018-05-04 Tom Tromey <tom@tromey.com>
5755
5756 PR gdb/22619:
5757 * printcmd.c (last_count): New global.
5758 (x_command): Use saved count when repeating.
5759
5760 2018-05-04 Tom Tromey <tom@tromey.com>
5761
5762 * nto-procfs.c (do_closedir_cleanup): Remove.
5763 (procfs_pidlist): Use gdb_dir_up.
5764 * procfs.c (do_closedir_cleanup): Remove.
5765 (proc_update_threads): Use gdb_dir_up.
5766 * common/filestuff.h (struct gdb_dir_deleter): New.
5767 (gdb_dir_up): New typedef.
5768
5769 2018-05-04 Tom Tromey <tom@tromey.com>
5770
5771 * ada-lang.c (print_mention_exception): Use std::string.
5772
5773 2018-05-04 Tom Tromey <tom@tromey.com>
5774
5775 * ada-lang.c (create_excep_cond_exprs): Update.
5776 (ada_exception_catchpoint_cond_string): Use std::string.
5777
5778 2018-05-04 Tom Tromey <tom@tromey.com>
5779
5780 * ada-lang.c (xget_renaming_scope): Return std::string.
5781 (old_renaming_is_invisible): Update.
5782
5783 2018-05-04 Tom Tromey <tom@tromey.com>
5784
5785 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
5786 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
5787
5788 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
5789
5790 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
5791
5792 2018-05-04 Tom Tromey <tom@tromey.com>
5793
5794 * remote.c (remote_query_supported_append): Change type.
5795 (remote_check_symbols): Update.
5796
5797 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
5798
5799 PR gdb/11420
5800 * configure.ac: Prepend libpython.
5801 * python/python-config.py: Likewise.
5802 * configure: Regenerate.
5803
5804 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
5805
5806 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
5807
5808 2018-05-03 Pedro Alves <palves@redhat.com>
5809
5810 * s390-linux-nat.c
5811 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
5812 override. Write 'true' instead of '1'.
5813 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
5814 declaration.
5815
5816 2018-05-02 Pedro Alves <palves@redhat.com>
5817
5818 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
5819 add_inf_child_target.
5820 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
5821 add_inf_child_target.
5822 * aix-thread.c (aix_thread_target_info): New.
5823 (aix_thread_target) <shortname, longname, doc>: Delete.
5824 <info>: New.
5825 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
5826 add_inf_child_target.
5827 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
5828 add_inf_child_target.
5829 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
5830 add_inf_child_target.
5831 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
5832 add_inf_child_target.
5833 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
5834 add_inf_child_target.
5835 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
5836 add_inf_child_target.
5837 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
5838 add_inf_child_target.
5839 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
5840 add_inf_child_target.
5841 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
5842 add_inf_child_target.
5843 * bfd-target.c (target_bfd_target_info): New.
5844 (target_bfd) <shortname, longname, doc>: Delete.
5845 <info>: New.
5846 * bsd-kvm.c (bsd_kvm_target_info): New.
5847 (bsd_kvm_target) <shortname, longname, doc>: Delete.
5848 <info>: New.
5849 (bsd_kvm_target::open): Rename to ...
5850 (bsd_kvm_target_open): ... this. Adjust.
5851 * bsd-uthread.c (bsd_uthread_target_info): New.
5852 (bsd_uthread_target) <shortname, longname, doc>: Delete.
5853 <info>: New.
5854 * corefile.c (core_file_command): Adjust.
5855 * corelow.c (core_target_info): New.
5856 (core_target) <shortname, longname, doc>: Delete.
5857 <info>: New.
5858 (core_target::open): Rename to ...
5859 (core_target_open): ... this. Adjust.
5860 * ctf.c (ctf_target_info): New.
5861 (ctf_target) <shortname, longname, doc>: Delete.
5862 <info>: New.
5863 (ctf_target::open): Rename to ...
5864 (ctf_target_open): ... this.
5865 (_initialize_ctf): Adjust.
5866 * exec.c (exec_target_info): New.
5867 (exec_target) <shortname, longname, doc>: Delete.
5868 <info>: New.
5869 (exec_target::open): Rename to ...
5870 (exec_target_open): ... this.
5871 * gdbcore.h (core_target_open): Declare.
5872 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
5873 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
5874 add_inf_child_target.
5875 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
5876 add_inf_child_target.
5877 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
5878 add_inf_child_target.
5879 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
5880 add_inf_child_target.
5881 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
5882 add_inf_child_target.
5883 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
5884 add_inf_child_target.
5885 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
5886 add_inf_child_target.
5887 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
5888 add_inf_child_target.
5889 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
5890 add_inf_child_target.
5891 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
5892 add_inf_child_target.
5893 * inf-child.c (inf_child_target_info): New.
5894 (inf_child_target::info): New.
5895 (inf_child_open_target): Remove 'target' parameter. Use
5896 get_native_target instead.
5897 (inf_child_target::open): Delete.
5898 (add_inf_child_target): New.
5899 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
5900 Delete.
5901 <info>: New.
5902 (add_inf_child_target): Declare.
5903 (inf_child_open_target): Declare.
5904 * linux-thread-db.c (thread_db_target_info): New.
5905 (thread_db_target) <shortname, longname, doc>: Delete.
5906 <info>: New.
5907 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
5908 add_inf_child_target.
5909 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
5910 add_inf_child_target.
5911 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
5912 add_inf_child_target.
5913 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
5914 add_inf_child_target.
5915 * make-target-delegates (print_class): Adjust.
5916 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
5917 add_inf_child_target.
5918 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
5919 add_inf_child_target.
5920 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
5921 add_inf_child_target.
5922 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
5923 add_inf_child_target.
5924 * nto-procfs.c (nto_native_target_info): New.
5925 (nto_procfs_target_native) <shortname, longname, doc>:
5926 Delete.
5927 <info>: New.
5928 (nto_procfs_target_info): New.
5929 (nto_procfs_target_procfs) <shortname, longname, doc>:
5930 Delete.
5931 <info>: New.
5932 (init_procfs_targets): Adjust.
5933 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
5934 add_inf_child_target.
5935 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
5936 add_inf_child_target.
5937 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
5938 add_inf_child_target.
5939 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
5940 add_inf_child_target.
5941 * ravenscar-thread.c (ravenscar_target_info): New.
5942 (ravenscar_thread_target) <shortname, longname, doc>:
5943 Delete.
5944 <info>: New.
5945 * record-btrace.c (record_btrace_target_info):
5946 (record_btrace_target) <shortname, longname, doc>: Delete.
5947 <info>: New.
5948 (record_btrace_target::open): Rename to ...
5949 (record_btrace_target_open): ... this. Adjust.
5950 * record-full.c (record_longname, record_doc): New.
5951 (record_full_base_target) <shortname, longname, doc>: Delete.
5952 <info>: New.
5953 (record_full_target_info): New.
5954 (record_full_target): <shortname>: Delete.
5955 <info>: New.
5956 (record_full_core_open_1, record_full_open_1): Update comments.
5957 (record_full_base_target::open): Rename to ...
5958 (record_full_open): ... this.
5959 (cmd_record_full_restore): Update.
5960 (_initialize_record_full): Update.
5961 * remote-sim.c (remote_sim_target_info): New.
5962 (gdbsim_target) <shortname, longname, doc>: Delete.
5963 <info>: New.
5964 (gdbsim_target::open): Rename to ...
5965 (gdbsim_target_open): ... this.
5966 (_initialize_remote_sim): Adjust.
5967 * remote.c (remote_doc): New.
5968 (remote_target_info): New.
5969 (remote_target) <shortname, longname, doc>: Delete.
5970 <info>: New.
5971 (extended_remote_target_info): New.
5972 (extended_remote_target) <shortname, longname, doc>: Delete.
5973 <info>: New.
5974 (remote_target::open_1): Make static. Adjust.
5975 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
5976 * s390-linux-nat.c (_initialize_s390_nat): Use
5977 add_inf_child_target.
5978 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
5979 add_inf_child_target.
5980 * sol-thread.c (thread_db_target_info): New.
5981 (sol_thread_target) <shortname, longname, doc>: Delete.
5982 <info>: New.
5983 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
5984 add_inf_child_target.
5985 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
5986 add_inf_child_target.
5987 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
5988 add_inf_child_target.
5989 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
5990 add_inf_child_target.
5991 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
5992 add_inf_child_target.
5993 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
5994 add_inf_child_target.
5995 * spu-linux-nat.c (_initialize_spu_nat): Use
5996 add_inf_child_target.
5997 * spu-multiarch.c (spu_multiarch_target_info): New.
5998 (spu_multiarch_target) <shortname, longname, doc>: Delete.
5999 <info>: New.
6000 * target-delegates.c: Regenerate.
6001 * target.c: Include <unordered_map>.
6002 (target_ops_p): Delete.
6003 (DEF_VEC_P(target_ops_p)): Delete.
6004 (target_factories): New.
6005 (test_target_info): New.
6006 (test_target_ops::info): New.
6007 (open_target): Adjust to use target_factories.
6008 (add_target_with_completer): Rename to ...
6009 (add_target): ... this. Change prototype. Register target_info
6010 and open callback in target_factories. Register target_info in
6011 command context instead of target_ops.
6012 (add_target): Delete old implementation.
6013 (add_deprecated_target_alias): Change prototype. Adjust.
6014 (the_native_target): New.
6015 (set_native_target, get_native_target): New.
6016 (find_default_run_target): Use the_native_target.
6017 (find_attach_target, find_run_target): Simplify.
6018 (target_ops::open): Delete.
6019 (dummy_target_info): New.
6020 (dummy_target::shortname, dummy_target::longname)
6021 (dummy_target::doc): Delete.
6022 (dummy_target::info): New.
6023 (debug_target::shortname, debug_target::longname)
6024 (debug_target::doc): Delete.
6025 (debug_target::info): New.
6026 * target.h (struct target_info): New.
6027 (target_ops::~target_ops): Add comment.
6028 (target_ops::info): New.
6029 (target_ops::shortname, target_ops::longname, target_ops::doc): No
6030 longer virtual. Implement in terms of target_info.
6031 (set_native_target, get_native_target): Declare.
6032 (target_open_ftype): New.
6033 (add_target, add_target_with_completer)
6034 (add_deprecated_target_alias): Change prototype.
6035 (test_target) <shortname, longname, doc>: Delete.
6036 <info>: New.
6037 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
6038 add_inf_child_target.
6039 * tracefile-tfile.c (tfile_target_info): New.
6040 (tfile_target) <shortname, longname, doc>: Delete.
6041 <info>: New.
6042 (tfile_target::open): Rename to ...
6043 (tfile_target_open): ... this.
6044 (_initialize_tracefile_tfile): Adjust.
6045 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
6046 add_inf_child_target.
6047 * windows-nat.c (_initialize_windows_nat): Use
6048 add_inf_child_target.
6049 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
6050 add_inf_child_target.
6051
6052 2018-05-02 Pedro Alves <palves@redhat.com>
6053
6054 * linux-nat.h (linux_nat_target) <low_new_thread,
6055 low_delete_thread, low_new_fork, low_forget_process,
6056 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
6057 New virtual methods.
6058 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
6059 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
6060 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
6061 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
6062 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
6063 Delete.
6064 * linux-fork.c (delete_fork): Adjust to call low method.
6065 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
6066 (linux_nat_new_fork, linux_nat_forget_process_hook)
6067 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
6068 (linux_nat_status_is_event):
6069 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
6070 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
6071 to call low method.
6072 (sigtrap_is_event): Rename to ...
6073 (linux_nat_target::low_status_is_event): ... this.
6074 (linux_nat_set_status_is_event): Delete.
6075 (save_stop_reason, linux_nat_wait_1)
6076 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
6077 low methods.
6078 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
6079 (linux_nat_set_new_fork, linux_nat_set_forget_process)
6080 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
6081 (linux_nat_set_prepare_to_resume): Delete.
6082 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
6083 low virtual methods.
6084 * amd64-linux-nat.c: Likewise.
6085 * arm-linux-nat.c: Likewise.
6086 * i386-linux-nat.c: Likewise.
6087 * ia64-linux-nat.c: Likewise.
6088 * mips-linux-nat.c: Likewise.
6089 * ppc-linux-nat.c: Likewise.
6090 * s390-linux-nat.c: Likewise.
6091 * sparc64-linux-nat.c: Likewise.
6092 * x86-linux-nat.c: Likewise.
6093 * x86-linux-nat.h: Include "nat/x86-linux.h".
6094 (x86_linux_nat_target) <low_new_fork, low_forget_process,
6095 low_prepare_to_resume, low_new_thread, low_delete_thread>:
6096 Override methods.
6097
6098 2018-05-02 Pedro Alves <palves@redhat.com>
6099
6100 * target.h (target_ops)
6101 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6102 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
6103 stopped_by_watchpoint, have_continuable_watchpoint,
6104 stopped_data_address, watchpoint_addr_within_range,
6105 can_accel_watchpoint_condition, can_run, thread_alive,
6106 has_all_memory, has_memory, has_stack, has_registers,
6107 has_execution, can_async_p, is_async_p, supports_non_stop,
6108 always_non_stop_p, can_execute_reverse, supports_multi_process,
6109 supports_enable_disable_tracepoint,
6110 supports_disable_randomization, supports_string_tracing,
6111 supports_evaluation_of_breakpoint_conditions,
6112 can_run_breakpoint_commands, filesystem_is_local,
6113 can_download_tracepoint, get_trace_state_variable_value,
6114 set_trace_notes, get_tib_address, use_agent, can_use_agent,
6115 record_is_replaying, record_will_replay,
6116 augmented_libraries_svr4_read>: Adjust to return bool.
6117 * aarch64-linux-nat.c: All implementations adjusted.
6118 * aix-thread.c: All implementations adjusted.
6119 * arm-linux-nat.c: All implementations adjusted.
6120 * breakpoint.c: All implementations adjusted.
6121 * bsd-kvm.c: All implementations adjusted.
6122 * bsd-uthread.c: All implementations adjusted.
6123 * corelow.c: All implementations adjusted.
6124 * ctf.c: All implementations adjusted.
6125 * darwin-nat.c: All implementations adjusted.
6126 * darwin-nat.h: All implementations adjusted.
6127 * exec.c: All implementations adjusted.
6128 * fbsd-nat.c: All implementations adjusted.
6129 * fbsd-nat.h: All implementations adjusted.
6130 * gnu-nat.c: All implementations adjusted.
6131 * gnu-nat.h: All implementations adjusted.
6132 * go32-nat.c: All implementations adjusted.
6133 * ia64-linux-nat.c: All implementations adjusted.
6134 * inf-child.c: All implementations adjusted.
6135 * inf-child.h: All implementations adjusted.
6136 * inf-ptrace.c: All implementations adjusted.
6137 * inf-ptrace.h: All implementations adjusted.
6138 * linux-nat.c: All implementations adjusted.
6139 * linux-nat.h: All implementations adjusted.
6140 * mips-linux-nat.c: All implementations adjusted.
6141 * nto-procfs.c: All implementations adjusted.
6142 * ppc-linux-nat.c: All implementations adjusted.
6143 * procfs.c: All implementations adjusted.
6144 * ravenscar-thread.c: All implementations adjusted.
6145 * record-btrace.c: All implementations adjusted.
6146 * record-full.c: All implementations adjusted.
6147 * remote-sim.c: All implementations adjusted.
6148 * remote.c: All implementations adjusted.
6149 * s390-linux-nat.c: All implementations adjusted.
6150 * sol-thread.c: All implementations adjusted.
6151 * spu-multiarch.c: All implementations adjusted.
6152 * target-delegates.c: All implementations adjusted.
6153 * target.c: All implementations adjusted.
6154 * target.h: All implementations adjusted.
6155 * tracefile-tfile.c: All implementations adjusted.
6156 * tracefile.c: All implementations adjusted.
6157 * tracefile.h: All implementations adjusted.
6158 * windows-nat.c: All implementations adjusted.
6159 * x86-linux-nat.h: All implementations adjusted.
6160 * x86-nat.h: All implementations adjusted.
6161
6162 2018-05-02 Pedro Alves <palves@redhat.com>
6163
6164 * make-target-delegates (scan_target_h): Don't trim lines here.
6165 Replace sequences of tabs and/or whitespace with a single
6166 whitespace.
6167 (top level, parsing methods): Trim each line before processing it
6168 here.
6169
6170 2018-05-02 Pedro Alves <palves@redhat.com>
6171 John Baldwin <jhb@freebsd.org>
6172
6173 * target.h (enum strata) <debug_stratum>: New.
6174 (struct target_ops) <all delegation methods>: Replace by C++
6175 virtual methods, and drop "to_" prefix. All references updated
6176 throughout.
6177 <to_shortname, to_longname, to_doc, to_data,
6178 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
6179 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
6180 virtual methods. All references updated throughout.
6181 <can_attach, supports_terminal_ours, can_create_inferior,
6182 get_thread_control_capabilities, attach_no_wait>: New
6183 virtual methods.
6184 <insert_breakpoint, remove_breakpoint>: Now
6185 TARGET_DEFAULT_NORETURN methods.
6186 <info_proc>: Now returns bool.
6187 <to_magic>: Delete.
6188 (OPS_MAGIC): Delete.
6189 (current_target): Delete. All references replaced by references
6190 to ...
6191 (target_stack): ... this. New.
6192 (target_shortname, target_longname): Adjust.
6193 (target_can_run): Now a function declaration.
6194 (default_child_has_all_memory, default_child_has_memory)
6195 (default_child_has_stack, default_child_has_registers)
6196 (default_child_has_execution): Remove target_ops parameter.
6197 (complete_target_initialization): Delete.
6198 (memory_breakpoint_target): New template class.
6199 (test_target_ops): Refactor as a C++ class with virtual methods.
6200 * make-target-delegates (NAME_PART): Tighten.
6201 (POINTER_PART, CP_SYMBOL): New.
6202 (SIMPLE_RETURN_PART): Reimplement.
6203 (VEC_RETURN_PART): Expect less.
6204 (RETURN_PART, VIRTUAL_PART): New.
6205 (METHOD): Adjust to C++ virtual methods.
6206 (scan_target_h): Remove reference to C99.
6207 (dname): Output "target_ops::" prefix.
6208 (write_function_header): Adjust to output a C++ class method.
6209 (write_declaration): New.
6210 (write_delegator): Adjust to output a C++ class method.
6211 (tdname): Output "dummy_target::" prefix.
6212 (write_tdefault, write_debugmethod): Adjust to output a C++ class
6213 method.
6214 (tdefault_names, debug_names): Delete.
6215 (return_types, tdefaults, styles, argtypes_array): New.
6216 (top level): All methods are delegators.
6217 (print_class): New.
6218 (top level): Print dummy_target and debug_target classes.
6219 * target-delegates.c: Regenerate.
6220 * target-debug.h (target_debug_print_enum_info_proc_what)
6221 (target_debug_print_thread_control_capabilities)
6222 (target_debug_print_thread_info_p): New.
6223 * target.c (dummy_target): Delete.
6224 (the_dummy_target, the_debug_target): New.
6225 (target_stack): Now extern.
6226 (set_targetdebug): Push/unpush debug target.
6227 (default_child_has_all_memory, default_child_has_memory)
6228 (default_child_has_stack, default_child_has_registers)
6229 (default_child_has_execution): Remove target_ops parameter.
6230 (complete_target_initialization): Delete.
6231 (add_target_with_completer): No longer call
6232 complete_target_initialization.
6233 (target_supports_terminal_ours): Use regular delegation.
6234 (update_current_target): Delete.
6235 (push_target): No longer check magic number. Don't call
6236 update_current_target.
6237 (unpush_target): Don't call update_current_target.
6238 (target_is_pushed): No longer check magic number.
6239 (target_require_runnable): Skip for all stratums over
6240 process_stratum.
6241 (target_ops::info_proc): New.
6242 (target_info_proc): Use find_target_at and
6243 find_default_run_target.
6244 (target_supports_disable_randomization): Use regular delegation.
6245 (target_get_osdata): Use find_target_at.
6246 (target_ops::open, target_ops::close, target_ops::can_attach)
6247 (target_ops::attach, target_ops::can_create_inferior)
6248 (target_ops::create_inferior, target_ops::can_run)
6249 (target_can_run): New.
6250 (default_fileio_target): Use regular delegation.
6251 (target_ops::fileio_open, target_ops::fileio_pwrite)
6252 (target_ops::fileio_pread, target_ops::fileio_fstat)
6253 (target_ops::fileio_close, target_ops::fileio_unlink)
6254 (target_ops::fileio_readlink): New.
6255 (target_fileio_open_1, target_fileio_unlink)
6256 (target_fileio_readlink): Always call the target method. Handle
6257 FILEIO_ENOSYS.
6258 (return_zero, return_zero_has_execution): Delete.
6259 (init_dummy_target): Delete.
6260 (dummy_target::dummy_target, dummy_target::shortname)
6261 (dummy_target::longname, dummy_target::doc)
6262 (debug_target::debug_target, debug_target::shortname)
6263 (debug_target::longname, debug_target::doc): New.
6264 (target_supports_delete_record): Use regular delegation.
6265 (setup_target_debug): Delete.
6266 (maintenance_print_target_stack): Skip debug_stratum.
6267 (initialize_targets): Instantiate the_dummy_target and
6268 the_debug_target.
6269 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
6270 use target_stack.
6271 (target_auxv_search, fprint_target_auxv): Adjust.
6272 (info_auxv_command): Adjust to use target_stack.
6273 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
6274 * exceptions.c (print_flush): Handle a NULL target_stack.
6275 * regcache.c (target_ops_no_register): Refactor as class with
6276 virtual methods.
6277
6278 * exec.c (exec_target): New class.
6279 (exec_ops): Now an exec_target.
6280 (exec_open, exec_close_1, exec_get_section_table)
6281 (exec_xfer_partial, exec_files_info, exec_has_memory)
6282 (exec_make_note_section): Refactor as exec_target methods.
6283 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
6284 Delete.
6285 (exec_target::find_memory_regions): New.
6286 (_initialize_exec): Don't call init_exec_ops.
6287 * gdbcore.h (exec_file_clear): Delete.
6288
6289 * corefile.c (core_target): Delete.
6290 (core_file_command): Adjust.
6291 * corelow.c (core_target): New class.
6292 (the_core_target): New.
6293 (core_close): Remove target_ops parameter.
6294 (core_close_cleanup): Adjust.
6295 (core_target::close): New.
6296 (core_open, core_detach, get_core_registers, core_files_info)
6297 (core_xfer_partial, core_thread_alive, core_read_description)
6298 (core_pid_to_str, core_thread_name, core_has_memory)
6299 (core_has_stack, core_has_registers, core_info_proc): Rework as
6300 core_target methods.
6301 (ignore, core_remove_breakpoint, init_core_ops): Delete.
6302 (_initialize_corelow): Initialize the_core_target.
6303 * gdbcore.h (core_target): Delete.
6304 (the_core_target): New.
6305
6306 * ctf.c: (ctf_target): New class.
6307 (ctf_ops): Now a ctf_target.
6308 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
6309 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
6310 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
6311 methods.
6312 (init_ctf_ops): Delete.
6313 (_initialize_ctf): Don't call it.
6314 * tracefile-tfile.c (tfile_target): New class.
6315 (tfile_ops): Now a tfile_target.
6316 (tfile_open, tfile_close, tfile_files_info)
6317 (tfile_get_tracepoint_status, tfile_trace_find)
6318 (tfile_fetch_registers, tfile_xfer_partial)
6319 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
6320 Refactor as tfile_target methods.
6321 (tfile_xfer_partial_features): Remove target_ops parameter.
6322 (init_tfile_ops): Delete.
6323 (_initialize_tracefile_tfile): Don't call it.
6324 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
6325 (tracefile_has_stack, tracefile_has_registers)
6326 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
6327 tracefile_target methods.
6328 (init_tracefile_ops): Delete.
6329 (tracefile_target::tracefile_target): New.
6330 * tracefile.h: Include "target.h".
6331 (tracefile_target): New class.
6332 (init_tracefile_ops): Delete.
6333
6334 * spu-multiarch.c (spu_multiarch_target): New class.
6335 (spu_ops): Now a spu_multiarch_target.
6336 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
6337 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
6338 (spu_search_memory, spu_mourn_inferior): Refactor as
6339 spu_multiarch_target methods.
6340 (init_spu_ops): Delete.
6341 (_initialize_spu_multiarch): Remove references to init_spu_ops,
6342 complete_target_initialization.
6343
6344 * ravenscar-thread.c (ravenscar_thread_target): New class.
6345 (ravenscar_ops): Now a ravenscar_thread_target.
6346 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
6347 (ravenscar_thread_alive, ravenscar_pid_to_str)
6348 (ravenscar_fetch_registers, ravenscar_store_registers)
6349 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
6350 (ravenscar_stopped_by_hw_breakpoint)
6351 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
6352 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
6353 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
6354 methods.
6355 (init_ravenscar_thread_ops): Delete.
6356 (_initialize_ravenscar): Remove references to
6357 init_ravenscar_thread_ops and complete_target_initialization.
6358
6359 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
6360 (bsd_uthread_target): New class.
6361 (bsd_uthread_ops): Now a bsd_uthread_target.
6362 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
6363 (bsd_uthread_close, bsd_uthread_mourn_inferior)
6364 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
6365 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
6366 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
6367 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
6368 (bsd_uthread_target): Delete function.
6369 (_initialize_bsd_uthread): Remove reference to
6370 complete_target_initialization.
6371
6372 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
6373 (target_bfd): ... this new class.
6374 (target_bfd_xfer_partial, target_bfd_get_section_table)
6375 (target_bfd_close): Refactor as target_bfd methods.
6376 (target_bfd::~target_bfd): New.
6377 (target_bfd_reopen): Adjust.
6378 (target_bfd::close): New.
6379
6380 * record-btrace.c (record_btrace_target): New class.
6381 (record_btrace_ops): Now a record_btrace_target.
6382 (record_btrace_open, record_btrace_stop_recording)
6383 (record_btrace_disconnect, record_btrace_close)
6384 (record_btrace_async, record_btrace_info)
6385 (record_btrace_insn_history, record_btrace_insn_history_range)
6386 (record_btrace_insn_history_from, record_btrace_call_history)
6387 (record_btrace_call_history_range)
6388 (record_btrace_call_history_from, record_btrace_record_method)
6389 (record_btrace_is_replaying, record_btrace_will_replay)
6390 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
6391 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
6392 (record_btrace_store_registers, record_btrace_prepare_to_store)
6393 (record_btrace_to_get_unwinder)
6394 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
6395 (record_btrace_commit_resume, record_btrace_wait)
6396 (record_btrace_stop, record_btrace_can_execute_reverse)
6397 (record_btrace_stopped_by_sw_breakpoint)
6398 (record_btrace_supports_stopped_by_sw_breakpoint)
6399 (record_btrace_stopped_by_hw_breakpoint)
6400 (record_btrace_supports_stopped_by_hw_breakpoint)
6401 (record_btrace_update_thread_list, record_btrace_thread_alive)
6402 (record_btrace_goto_begin, record_btrace_goto_end)
6403 (record_btrace_goto, record_btrace_stop_replaying_all)
6404 (record_btrace_execution_direction)
6405 (record_btrace_prepare_to_generate_core)
6406 (record_btrace_done_generating_core): Refactor as
6407 record_btrace_target methods.
6408 (init_record_btrace_ops): Delete.
6409 (_initialize_record_btrace): Remove reference to
6410 init_record_btrace_ops.
6411 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
6412 the execution_direction global.
6413 (record_full_base_target, record_full_target)
6414 (record_full_core_target): New classes.
6415 (record_full_ops): Now a record_full_target.
6416 (record_full_core_ops): Now a record_full_core_target.
6417 (record_full_target::detach, record_full_target::disconnect)
6418 (record_full_core_target::disconnect)
6419 (record_full_target::mourn_inferior, record_full_target::kill):
6420 New.
6421 (record_full_open, record_full_close, record_full_async): Refactor
6422 as methods of the record_full_base_target class.
6423 (record_full_resume, record_full_commit_resume): Refactor
6424 as methods of the record_full_target class.
6425 (record_full_wait, record_full_stopped_by_watchpoint)
6426 (record_full_stopped_data_address)
6427 (record_full_stopped_by_sw_breakpoint)
6428 (record_full_supports_stopped_by_sw_breakpoint)
6429 (record_full_stopped_by_hw_breakpoint)
6430 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
6431 methods of the record_full_base_target class.
6432 (record_full_store_registers, record_full_xfer_partial)
6433 (record_full_insert_breakpoint, record_full_remove_breakpoint):
6434 Refactor as methods of the record_full_target class.
6435 (record_full_can_execute_reverse, record_full_get_bookmark)
6436 (record_full_goto_bookmark, record_full_execution_direction)
6437 (record_full_record_method, record_full_info, record_full_delete)
6438 (record_full_is_replaying, record_full_will_replay)
6439 (record_full_goto_begin, record_full_goto_end, record_full_goto)
6440 (record_full_stop_replaying): Refactor as methods of the
6441 record_full_base_target class.
6442 (record_full_core_resume, record_full_core_kill)
6443 (record_full_core_fetch_registers)
6444 (record_full_core_prepare_to_store)
6445 (record_full_core_store_registers, record_full_core_xfer_partial)
6446 (record_full_core_insert_breakpoint)
6447 (record_full_core_remove_breakpoint)
6448 (record_full_core_has_execution): Refactor
6449 as methods of the record_full_core_target class.
6450 (record_full_base_target::supports_delete_record): New.
6451 (init_record_full_ops): Delete.
6452 (init_record_full_core_ops): Delete.
6453 (record_full_save): Refactor as method of the
6454 record_full_base_target class.
6455 (_initialize_record_full): Remove references to
6456 init_record_full_ops and init_record_full_core_ops.
6457
6458 * remote.c (remote_target, extended_remote_target): New classes.
6459 (remote_ops): Now a remote_target.
6460 (extended_remote_ops): Now an extended_remote_target.
6461 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
6462 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
6463 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
6464 (remote_pass_signals, remote_set_syscall_catchpoint)
6465 (remote_program_signals, )
6466 (remote_thread_always_alive): Remove target_ops parameter.
6467 (remote_thread_alive, remote_thread_name)
6468 (remote_update_thread_list, remote_threads_extra_info)
6469 (remote_static_tracepoint_marker_at)
6470 (remote_static_tracepoint_markers_by_strid)
6471 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
6472 (remote_open): Refactor as methods of remote_target.
6473 (extended_remote_open, extended_remote_detach)
6474 (extended_remote_attach, extended_remote_post_attach):
6475 (extended_remote_supports_disable_randomization)
6476 (extended_remote_create_inferior): : Refactor as method of
6477 extended_remote_target.
6478 (remote_set_permissions, remote_open_1, remote_detach)
6479 (remote_follow_fork, remote_follow_exec, remote_disconnect)
6480 (remote_resume, remote_commit_resume, remote_stop)
6481 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
6482 (remote_terminal_ours, remote_wait, remote_fetch_registers)
6483 (remote_prepare_to_store, remote_store_registers)
6484 (remote_flash_erase, remote_flash_done, remote_files_info)
6485 (remote_kill, remote_mourn, remote_insert_breakpoint)
6486 (remote_remove_breakpoint, remote_insert_watchpoint)
6487 (remote_watchpoint_addr_within_range)
6488 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
6489 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
6490 (remote_supports_stopped_by_sw_breakpoint)
6491 (remote_stopped_by_hw_breakpoint)
6492 (remote_supports_stopped_by_hw_breakpoint)
6493 (remote_stopped_by_watchpoint, remote_stopped_data_address)
6494 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
6495 (remote_verify_memory): Refactor as methods of remote_target.
6496 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
6497 parameter.
6498 (remote_xfer_partial, remote_get_memory_xfer_limit)
6499 (remote_search_memory, remote_rcmd, remote_memory_map)
6500 (remote_pid_to_str, remote_get_thread_local_address)
6501 (remote_get_tib_address, remote_read_description): Refactor as
6502 methods of remote_target.
6503 (remote_target::fileio_open, remote_target::fileio_pwrite)
6504 (remote_target::fileio_pread, remote_target::fileio_close): New.
6505 (remote_hostio_readlink, remote_hostio_fstat)
6506 (remote_filesystem_is_local, remote_can_execute_reverse)
6507 (remote_supports_non_stop, remote_supports_disable_randomization)
6508 (remote_supports_multi_process, remote_supports_cond_breakpoints)
6509 (remote_supports_enable_disable_tracepoint)
6510 (remote_supports_string_tracing)
6511 (remote_can_run_breakpoint_commands, remote_trace_init)
6512 (remote_download_tracepoint, remote_can_download_tracepoint)
6513 (remote_download_trace_state_variable, remote_enable_tracepoint)
6514 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
6515 (remote_trace_start, remote_get_trace_status)
6516 (remote_get_tracepoint_status, remote_trace_stop)
6517 (remote_trace_find, remote_get_trace_state_variable_value)
6518 (remote_save_trace_data, remote_get_raw_trace_data)
6519 (remote_set_disconnected_tracing, remote_core_of_thread)
6520 (remote_set_circular_trace_buffer, remote_traceframe_info)
6521 (remote_get_min_fast_tracepoint_insn_len)
6522 (remote_set_trace_buffer_size, remote_set_trace_notes)
6523 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
6524 (remote_disable_btrace, remote_teardown_btrace)
6525 (remote_read_btrace, remote_btrace_conf)
6526 (remote_augmented_libraries_svr4_read, remote_load)
6527 (remote_pid_to_exec_file, remote_can_do_single_step)
6528 (remote_execution_direction, remote_thread_handle_to_thread_info):
6529 Refactor as methods of remote_target.
6530 (init_remote_ops, init_extended_remote_ops): Delete.
6531 (remote_can_async_p, remote_is_async_p, remote_async)
6532 (remote_thread_events, remote_upload_tracepoints)
6533 (remote_upload_trace_state_variables): Refactor as methods of
6534 remote_target.
6535 (_initialize_remote): Remove references to init_remote_ops and
6536 init_extended_remote_ops.
6537
6538 * remote-sim.c (gdbsim_target): New class.
6539 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
6540 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
6541 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
6542 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
6543 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
6544 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
6545 Refactor as methods of gdbsim_target.
6546 (gdbsim_ops): Now a gdbsim_target.
6547 (init_gdbsim_ops): Delete.
6548 (gdbsim_cntrl_c): Adjust.
6549 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
6550
6551 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
6552 (the_amd64_linux_nat_target): New.
6553 (amd64_linux_fetch_inferior_registers)
6554 (amd64_linux_store_inferior_registers): Refactor as methods of
6555 amd64_linux_nat_target.
6556 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
6557 * i386-linux-nat.c: Don't include "linux-nat.h".
6558 (i386_linux_nat_target): New class.
6559 (the_i386_linux_nat_target): New.
6560 (i386_linux_fetch_inferior_registers)
6561 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
6562 as methods of i386_linux_nat_target.
6563 (_initialize_i386_linux_nat): Adjust. Set linux_target.
6564 * inf-child.c (inf_child_ops): Delete.
6565 (inf_child_fetch_inferior_registers)
6566 (inf_child_store_inferior_registers): Delete.
6567 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
6568 methods of inf_child_target.
6569 (inf_child_target::supports_terminal_ours)
6570 (inf_child_target::terminal_init)
6571 (inf_child_target::terminal_inferior)
6572 (inf_child_target::terminal_ours_for_output)
6573 (inf_child_target::terminal_ours, inf_child_target::interrupt)
6574 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
6575 New.
6576 (inf_child_open, inf_child_disconnect, inf_child_close)
6577 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
6578 (inf_child_post_startup_inferior, inf_child_can_run)
6579 (inf_child_pid_to_exec_file): Refactor as methods of
6580 inf_child_target.
6581 (inf_child_follow_fork): Delete.
6582 (inf_child_target::can_create_inferior)
6583 (inf_child_target::can_attach): New.
6584 (inf_child_target::has_all_memory, inf_child_target::has_memory)
6585 (inf_child_target::has_stack, inf_child_target::has_registers)
6586 (inf_child_target::has_execution): New.
6587 (inf_child_fileio_open, inf_child_fileio_pwrite)
6588 (inf_child_fileio_pread, inf_child_fileio_fstat)
6589 (inf_child_fileio_close, inf_child_fileio_unlink)
6590 (inf_child_fileio_readlink, inf_child_use_agent)
6591 (inf_child_can_use_agent): Refactor as methods of
6592 inf_child_target.
6593 (return_zero, inf_child_target): Delete.
6594 (inf_child_target::inf_child_target): New.
6595 * inf-child.h: Include "target.h".
6596 (inf_child_target): Delete function prototype.
6597 (inf_child_target): New class.
6598 (inf_child_open_target, inf_child_mourn_inferior)
6599 (inf_child_maybe_unpush_target): Delete.
6600 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
6601 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
6602 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
6603 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
6604 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
6605 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
6606 (inf_ptrace_wait, inf_ptrace_xfer_partial)
6607 (inf_ptrace_thread_alive, inf_ptrace_files_info)
6608 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
6609 methods of inf_ptrace_target.
6610 (inf_ptrace_target): Delete function.
6611 * inf-ptrace.h: Include "inf-child.h".
6612 (inf_ptrace_target): Delete function declaration.
6613 (inf_ptrace_target): New class.
6614 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
6615 * linux-nat.c (linux_target): New.
6616 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
6617 (linux_nat_target::~linux_nat_target): New.
6618 (linux_child_post_attach, linux_child_post_startup_inferior)
6619 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
6620 (linux_child_remove_fork_catchpoint)
6621 (linux_child_insert_vfork_catchpoint)
6622 (linux_child_remove_vfork_catchpoint)
6623 (linux_child_insert_exec_catchpoint)
6624 (linux_child_remove_exec_catchpoint)
6625 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
6626 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
6627 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
6628 (linux_nat_stopped_data_address)
6629 (linux_nat_stopped_by_sw_breakpoint)
6630 (linux_nat_supports_stopped_by_sw_breakpoint)
6631 (linux_nat_stopped_by_hw_breakpoint)
6632 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
6633 (linux_nat_kill, linux_nat_mourn_inferior)
6634 (linux_nat_xfer_partial, linux_nat_thread_alive)
6635 (linux_nat_update_thread_list, linux_nat_pid_to_str)
6636 (linux_nat_thread_name, linux_child_pid_to_exec_file)
6637 (linux_child_static_tracepoint_markers_by_strid)
6638 (linux_nat_is_async_p, linux_nat_can_async_p)
6639 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
6640 (linux_nat_supports_multi_process)
6641 (linux_nat_supports_disable_randomization, linux_nat_async)
6642 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
6643 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
6644 (linux_nat_fileio_open, linux_nat_fileio_readlink)
6645 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
6646 methods of linux_nat_target.
6647 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
6648 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
6649 parameter.
6650 (check_stopped_by_watchpoint): Adjust.
6651 (linux_xfer_partial): Delete.
6652 (linux_target_install_ops, linux_target, linux_nat_add_target):
6653 Delete.
6654 (linux_nat_target::linux_nat_target): New.
6655 * linux-nat.h: Include "inf-ptrace.h".
6656 (linux_nat_target): New.
6657 (linux_target, linux_target_install_ops, linux_nat_add_target):
6658 Delete function declarations.
6659 (linux_target): Declare global.
6660 * linux-thread-db.c (thread_db_target): New.
6661 (thread_db_target::thread_db_target): New.
6662 (thread_db_ops): Delete.
6663 (the_thread_db_target): New.
6664 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
6665 (thread_db_update_thread_list, thread_db_pid_to_str)
6666 (thread_db_extra_thread_info)
6667 (thread_db_thread_handle_to_thread_info)
6668 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
6669 (thread_db_resume): Refactor as methods of thread_db_target.
6670 (init_thread_db_ops): Delete.
6671 (_initialize_thread_db): Remove reference to init_thread_db_ops.
6672 * x86-linux-nat.c: Don't include "linux-nat.h".
6673 (super_post_startup_inferior): Delete.
6674 (x86_linux_nat_target::~x86_linux_nat_target): New.
6675 (x86_linux_child_post_startup_inferior)
6676 (x86_linux_read_description, x86_linux_enable_btrace)
6677 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
6678 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
6679 methods of x86_linux_nat_target.
6680 (x86_linux_create_target): Delete. Bits folded ...
6681 (x86_linux_add_target): ... here. Now takes a linux_nat_target
6682 pointer.
6683 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
6684 (x86_linux_nat_target): New class.
6685 (x86_linux_create_target): Delete.
6686 (x86_linux_add_target): Now takes a linux_nat_target pointer.
6687 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
6688 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
6689 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
6690 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
6691 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
6692 make extern.
6693 (x86_use_watchpoints): Delete.
6694 * x86-nat.h: Include "breakpoint.h" and "target.h".
6695 (x86_use_watchpoints): Delete.
6696 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
6697 (x86_stopped_by_watchpoint, x86_stopped_data_address)
6698 (x86_insert_watchpoint, x86_remove_watchpoint)
6699 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
6700 (x86_stopped_by_hw_breakpoint): New declarations.
6701 (x86_nat_target): New template class.
6702
6703 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
6704 (the_ppc_linux_nat_target): New.
6705 (ppc_linux_fetch_inferior_registers)
6706 (ppc_linux_can_use_hw_breakpoint)
6707 (ppc_linux_region_ok_for_hw_watchpoint)
6708 (ppc_linux_ranged_break_num_registers)
6709 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
6710 (ppc_linux_insert_mask_watchpoint)
6711 (ppc_linux_remove_mask_watchpoint)
6712 (ppc_linux_can_accel_watchpoint_condition)
6713 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
6714 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
6715 (ppc_linux_watchpoint_addr_within_range)
6716 (ppc_linux_masked_watch_num_registers)
6717 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
6718 (ppc_linux_read_description): Refactor as methods of
6719 ppc_linux_nat_target.
6720 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
6721
6722 * procfs.c (procfs_xfer_partial): Delete forward declaration.
6723 (procfs_target): New class.
6724 (the_procfs_target): New.
6725 (procfs_target): Delete function.
6726 (procfs_auxv_parse, procfs_attach, procfs_detach)
6727 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
6728 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
6729 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
6730 (procfs_create_inferior, procfs_update_thread_list)
6731 (procfs_thread_alive, procfs_pid_to_str)
6732 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
6733 (procfs_stopped_data_address, procfs_insert_watchpoint)
6734 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
6735 (proc_find_memory_regions, procfs_info_proc)
6736 (procfs_make_note_section): Refactor as methods of procfs_target.
6737 (_initialize_procfs): Adjust.
6738 * sol-thread.c (sol_thread_target): New class.
6739 (sol_thread_ops): Now a sol_thread_target.
6740 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
6741 (sol_thread_fetch_registers, sol_thread_store_registers)
6742 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
6743 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
6744 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
6745 (init_sol_thread_ops): Delete.
6746 (_initialize_sol_thread): Adjust. Remove references to
6747 init_sol_thread_ops and complete_target_initialization.
6748
6749 * windows-nat.c (windows_nat_target): New class.
6750 (windows_fetch_inferior_registers)
6751 (windows_store_inferior_registers, windows_resume, windows_wait)
6752 (windows_attach, windows_detach, windows_pid_to_exec_file)
6753 (windows_files_info, windows_create_inferior)
6754 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
6755 (windows_close, windows_pid_to_str, windows_xfer_partial)
6756 (windows_get_tib_address, windows_get_ada_task_ptid)
6757 (windows_thread_name, windows_thread_alive): Refactor as
6758 windows_nat_target methods.
6759 (do_initial_windows_stuff): Adjust.
6760 (windows_target): Delete function.
6761 (_initialize_windows_nat): Adjust.
6762
6763 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
6764 (darwin_mourn_inferior, darwin_kill_inferior)
6765 (darwin_create_inferior, darwin_attach, darwin_detach)
6766 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
6767 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
6768 (darwin_supports_multi_process): Refactor as darwin_nat_target
6769 methods.
6770 (darwin_resume_to, darwin_files_info): Delete.
6771 (_initialize_darwin_inferior): Rename to ...
6772 (_initialize_darwin_nat): ... this. Adjust to C++ification.
6773 * darwin-nat.h: Include "inf-child.h".
6774 (darwin_nat_target): New class.
6775 (darwin_complete_target): Delete.
6776 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
6777 (darwin_target): New.
6778 (i386_darwin_fetch_inferior_registers)
6779 (i386_darwin_store_inferior_registers): Refactor as methods of
6780 darwin_nat_target.
6781 (darwin_complete_target): Delete, with ...
6782 (_initialize_i386_darwin_nat): ... bits factored out here.
6783
6784 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
6785 (the_alpha_linux_nat_target): New.
6786 (alpha_linux_register_u_offset): Refactor as
6787 alpha_linux_nat_target method.
6788 (_initialize_alpha_linux_nat): Adjust.
6789 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
6790 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6791 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
6792 methods of linux_nat_trad_target.
6793 (linux_trad_target): Delete.
6794 * linux-nat-trad.h (linux_trad_target): Delete function.
6795 (linux_nat_trad_target): New class.
6796 * mips-linux-nat.c (mips_linux_nat_target): New class.
6797 (super_fetch_registers, super_store_registers, super_close):
6798 Delete.
6799 (the_mips_linux_nat_target): New.
6800 (mips64_linux_regsets_fetch_registers)
6801 (mips64_linux_regsets_store_registers)
6802 (mips64_linux_fetch_registers, mips64_linux_store_registers)
6803 (mips_linux_register_u_offset, mips_linux_read_description)
6804 (mips_linux_can_use_hw_breakpoint)
6805 (mips_linux_stopped_by_watchpoint)
6806 (mips_linux_stopped_data_address)
6807 (mips_linux_region_ok_for_hw_watchpoint)
6808 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
6809 (mips_linux_close): Refactor as methods of mips_linux_nat.
6810 (_initialize_mips_linux_nat): Adjust to C++ification.
6811
6812 * aix-thread.c (aix_thread_target): New class.
6813 (aix_thread_ops): Now an aix_thread_target.
6814 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
6815 (aix_thread_fetch_registers, aix_thread_store_registers)
6816 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
6817 (aix_thread_thread_alive, aix_thread_pid_to_str)
6818 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
6819 Refactor as methods of aix_thread_target.
6820 (init_aix_thread_ops): Delete.
6821 (_initialize_aix_thread): Remove references to init_aix_thread_ops
6822 and complete_target_initialization.
6823 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
6824 (rs6000_nat_target): New class.
6825 (the_rs6000_nat_target): New.
6826 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
6827 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
6828 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
6829 (super_create_inferior): Delete.
6830 (_initialize_rs6000_nat): Adjust to C++ification.
6831
6832 * arm-linux-nat.c (arm_linux_nat_target): New class.
6833 (the_arm_linux_nat_target): New.
6834 (arm_linux_fetch_inferior_registers)
6835 (arm_linux_store_inferior_registers, arm_linux_read_description)
6836 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
6837 (arm_linux_remove_hw_breakpoint)
6838 (arm_linux_region_ok_for_hw_watchpoint)
6839 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
6840 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
6841 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
6842 arm_linux_nat_target.
6843 (_initialize_arm_linux_nat): Adjust to C++ification.
6844
6845 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
6846 (the_aarch64_linux_nat_target): New.
6847 (aarch64_linux_fetch_inferior_registers)
6848 (aarch64_linux_store_inferior_registers)
6849 (aarch64_linux_child_post_startup_inferior)
6850 (aarch64_linux_read_description)
6851 (aarch64_linux_can_use_hw_breakpoint)
6852 (aarch64_linux_insert_hw_breakpoint)
6853 (aarch64_linux_remove_hw_breakpoint)
6854 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
6855 (aarch64_linux_region_ok_for_hw_watchpoint)
6856 (aarch64_linux_stopped_data_address)
6857 (aarch64_linux_stopped_by_watchpoint)
6858 (aarch64_linux_watchpoint_addr_within_range)
6859 (aarch64_linux_can_do_single_step): Refactor as methods of
6860 aarch64_linux_nat_target.
6861 (super_post_startup_inferior): Delete.
6862 (_initialize_aarch64_linux_nat): Adjust to C++ification.
6863
6864 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
6865 (the_hppa_linux_nat_target): New.
6866 (hppa_linux_fetch_inferior_registers)
6867 (hppa_linux_store_inferior_registers): Refactor as methods of
6868 hppa_linux_nat_target.
6869 (_initialize_hppa_linux_nat): Adjust to C++ification.
6870
6871 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
6872 (the_ia64_linux_nat_target): New.
6873 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
6874 (ia64_linux_stopped_data_address)
6875 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
6876 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
6877 ia64_linux_nat_target methods.
6878 (super_xfer_partial): Delete.
6879 (_initialize_ia64_linux_nat): Adjust to C++ification.
6880
6881 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
6882 (the_m32r_linux_nat_target): New.
6883 (m32r_linux_fetch_inferior_registers)
6884 (m32r_linux_store_inferior_registers): Refactor as
6885 m32r_linux_nat_target methods.
6886 (_initialize_m32r_linux_nat): Adjust to C++ification.
6887
6888 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
6889 (the_m68k_linux_nat_target): New.
6890 (m68k_linux_fetch_inferior_registers)
6891 (m68k_linux_store_inferior_registers): Refactor as
6892 m68k_linux_nat_target methods.
6893 (_initialize_m68k_linux_nat): Adjust to C++ification.
6894
6895 * s390-linux-nat.c (s390_linux_nat_target): New class.
6896 (the_s390_linux_nat_target): New.
6897 (s390_linux_fetch_inferior_registers)
6898 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
6899 (s390_insert_watchpoint, s390_remove_watchpoint)
6900 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
6901 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
6902 (s390_auxv_parse, s390_read_description): Refactor as methods of
6903 s390_linux_nat_target.
6904 (_initialize_s390_nat): Adjust to C++ification.
6905
6906 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
6907 (the_sparc_linux_nat_target): New.
6908 (_initialize_sparc_linux_nat): Adjust to C++ification.
6909 * sparc-nat.c (sparc_fetch_inferior_registers)
6910 (sparc_store_inferior_registers): Remove target_ops parameter.
6911 * sparc-nat.h (sparc_fetch_inferior_registers)
6912 (sparc_store_inferior_registers): Remove target_ops parameter.
6913 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
6914 (the_sparc64_linux_nat_target): New.
6915 (_initialize_sparc64_linux_nat): Adjust to C++ification.
6916
6917 * spu-linux-nat.c (spu_linux_nat_target): New class.
6918 (the_spu_linux_nat_target): New.
6919 (spu_child_post_startup_inferior, spu_child_post_attach)
6920 (spu_child_wait, spu_fetch_inferior_registers)
6921 (spu_store_inferior_registers, spu_xfer_partial)
6922 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
6923 methods.
6924 (_initialize_spu_nat): Adjust to C++ification.
6925
6926 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
6927 (the_tilegx_linux_nat_target): New.
6928 (fetch_inferior_registers, store_inferior_registers):
6929 Refactor as methods.
6930 (_initialize_tile_linux_nat): Adjust to C++ification.
6931
6932 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
6933 (the_xtensa_linux_nat_target): New.
6934 (xtensa_linux_fetch_inferior_registers)
6935 (xtensa_linux_store_inferior_registers): Refactor as
6936 xtensa_linux_nat_target methods.
6937 (_initialize_xtensa_linux_nat): Adjust to C++ification.
6938
6939 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
6940 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
6941 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
6942 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
6943 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
6944 (fbsd_stopped_by_sw_breakpoint)
6945 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
6946 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
6947 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
6948 (fbsd_post_startup_inferior, fbsd_post_attach)
6949 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
6950 (fbsd_set_syscall_catchpoint)
6951 (super_xfer_partial, super_resume, super_wait)
6952 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
6953 (fbsd_handle_debug_trap): Remove target_ops parameter.
6954 (fbsd_nat_add_target): Delete.
6955 * fbsd-nat.h: Include "inf-ptrace.h".
6956 (fbsd_nat_add_target): Delete.
6957 (USE_SIGTRAP_SIGINFO): Define.
6958 (fbsd_nat_target): New class.
6959
6960 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
6961 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
6962 (amd64bsd_target): Delete.
6963 * amd64-bsd-nat.h: New file.
6964 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
6965 "x86-bsd-nat.h".
6966 (amd64_fbsd_nat_target): New class.
6967 (the_amd64_fbsd_nat_target): New.
6968 (amd64fbsd_read_description): Refactor as method of
6969 amd64_fbsd_nat_target.
6970 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6971 (_initialize_amd64fbsd_nat): Adjust to C++ification.
6972 * amd64-nat.h (amd64bsd_target): Delete function declaration.
6973 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
6974 (i386bsd_store_inferior_registers): Remove target_ops parameter.
6975 (i386bsd_target): Delete.
6976 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
6977 (i386bsd_fetch_inferior_registers)
6978 (i386bsd_store_inferior_registers): Declare.
6979 (i386_bsd_nat_target): New class.
6980 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
6981 (the_i386_fbsd_nat_target): New.
6982 (i386fbsd_resume, i386fbsd_read_description): Refactor as
6983 i386_fbsd_nat_target methods.
6984 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6985 (_initialize_i386fbsd_nat): Adjust to C++ification.
6986 * x86-bsd-nat.c (super_mourn_inferior): Delete.
6987 (x86bsd_mourn_inferior, x86bsd_target): Delete.
6988 (_initialize_x86_bsd_nat): Adjust to C++ification.
6989 * x86-bsd-nat.h: Include "x86-nat.h".
6990 (x86bsd_target): Delete declaration.
6991 (x86bsd_nat_target): New class.
6992
6993 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
6994 (the_aarch64_fbsd_nat_target): New.
6995 (aarch64_fbsd_fetch_inferior_registers)
6996 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
6997 aarch64_fbsd_nat_target.
6998 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
6999 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
7000 (the_alpha_bsd_nat_target): New.
7001 (alphabsd_fetch_inferior_registers)
7002 (alphabsd_store_inferior_registers): Refactor as
7003 alpha_bsd_nat_target methods.
7004 (_initialize_alphabsd_nat): Refactor as methods of
7005 alpha_bsd_nat_target.
7006 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
7007 (the_amd64_nbsd_nat_target): New.
7008 (_initialize_amd64nbsd_nat): Adjust to C++ification.
7009 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
7010 (the_amd64_obsd_nat_target): New.
7011 (_initialize_amd64obsd_nat): Adjust to C++ification.
7012 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
7013 (the_arm_fbsd_nat_target): New.
7014 (arm_fbsd_fetch_inferior_registers)
7015 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
7016 (_initialize_arm_fbsd_nat): Refactor as methods of
7017 arm_fbsd_nat_target.
7018 (_initialize_arm_fbsd_nat): Adjust to C++ification.
7019 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
7020 (the_arm_netbsd_nat_target): New.
7021 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
7022 arm_netbsd_nat_target.
7023 (_initialize_arm_netbsd_nat): Adjust to C++ification.
7024 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
7025 (the_hppa_nbsd_nat_target): New.
7026 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
7027 hppa_nbsd_nat_target methods.
7028 (_initialize_hppanbsd_nat): Adjust to C++ification.
7029 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
7030 (the_hppa_obsd_nat_target): New.
7031 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
7032 methods of hppa_obsd_nat_target.
7033 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
7034 add_target.
7035 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
7036 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
7037 add_target.
7038 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
7039 (_initialize_i386obsd_nat): Use add_target.
7040 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
7041 (the_m68k_bsd_nat_target): New.
7042 (m68kbsd_fetch_inferior_registers)
7043 (m68kbsd_store_inferior_registers): Refactor as methods of
7044 m68k_bsd_nat_target.
7045 (_initialize_m68kbsd_nat): Adjust to C++ification.
7046 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
7047 (the_mips_fbsd_nat_target): New.
7048 (mips_fbsd_fetch_inferior_registers)
7049 (mips_fbsd_store_inferior_registers): Refactor as methods of
7050 mips_fbsd_nat_target.
7051 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
7052 add_target.
7053 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
7054 (the_mips_nbsd_nat_target): New.
7055 (mipsnbsd_fetch_inferior_registers)
7056 (mipsnbsd_store_inferior_registers): Refactor as methods of
7057 mips_nbsd_nat_target.
7058 (_initialize_mipsnbsd_nat): Adjust to C++ification.
7059 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
7060 (the_mips64_obsd_nat_target): New.
7061 (mips64obsd_fetch_inferior_registers)
7062 (mips64obsd_store_inferior_registers): Refactor as methods of
7063 mips64_obsd_nat_target.
7064 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
7065 add_target.
7066 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
7067 nbsd_nat_target.
7068 * nbsd-nat.h: Include "inf-ptrace.h".
7069 (nbsd_nat_target): New class.
7070 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
7071 (obsd_wait): Refactor as methods of obsd_nat_target.
7072 (obsd_add_target): Delete.
7073 * obsd-nat.h: Include "inf-ptrace.h".
7074 (obsd_nat_target): New class.
7075 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
7076 (the_ppc_fbsd_nat_target): New.
7077 (ppcfbsd_fetch_inferior_registers)
7078 (ppcfbsd_store_inferior_registers): Refactor as methods of
7079 ppc_fbsd_nat_target.
7080 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
7081 add_target.
7082 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
7083 (the_ppc_nbsd_nat_target): New.
7084 (ppcnbsd_fetch_inferior_registers)
7085 (ppcnbsd_store_inferior_registers): Refactor as methods of
7086 ppc_nbsd_nat_target.
7087 (_initialize_ppcnbsd_nat): Adjust to C++ification.
7088 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
7089 (the_ppc_obsd_nat_target): New.
7090 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
7091 methods of ppc_obsd_nat_target.
7092 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
7093 add_target.
7094 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
7095 (the_sh_nbsd_nat_target): New.
7096 (shnbsd_fetch_inferior_registers)
7097 (shnbsd_store_inferior_registers): Refactor as methods of
7098 sh_nbsd_nat_target.
7099 (_initialize_shnbsd_nat): Adjust to C++ification.
7100 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
7101 (inf_ptrace_xfer_partial): Delete.
7102 (sparc_xfer_partial, sparc_target): Delete.
7103 * sparc-nat.h (sparc_fetch_inferior_registers)
7104 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
7105 (sparc_target): Delete function declaration.
7106 (sparc_target): New template class.
7107 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
7108 (_initialize_sparcnbsd_nat): Adjust to C++ification.
7109 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
7110 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
7111 add_target.
7112 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
7113 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
7114 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
7115 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
7116 add_target.
7117 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
7118 (the_vax_bsd_nat_target): New.
7119 (vaxbsd_fetch_inferior_registers)
7120 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
7121 methods.
7122 (_initialize_vaxbsd_nat): Adjust to C++ification.
7123
7124 * bsd-kvm.c (bsd_kvm_target): New class.
7125 (bsd_kvm_ops): Now a bsd_kvm_target.
7126 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
7127 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
7128 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
7129 bsd_kvm_target.
7130 (bsd_kvm_return_one): Delete.
7131 (bsd_kvm_add_target): Adjust to C++ification.
7132
7133 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
7134 (nto_procfs_target_procfs): New classes.
7135 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
7136 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
7137 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
7138 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
7139 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
7140 (procfs_remove_hw_breakpoint, procfs_resume)
7141 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
7142 (procfs_kill_inferior, procfs_store_registers)
7143 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
7144 as methods of nto_procfs_target.
7145 (nto_procfs_ops): Now an nto_procfs_target_procfs.
7146 (nto_native_ops): Delete.
7147 (procfs_open, procfs_native_open): Delete.
7148 (nto_native_ops): Now an nto_procfs_target_native.
7149 (init_procfs_targets): Adjust to C++ification.
7150 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
7151 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
7152 Refactor as methods of nto_procfs_target.
7153
7154 * go32-nat.c (go32_nat_target): New class.
7155 (the_go32_nat_target): New.
7156 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
7157 (go32_store_registers, go32_xfer_partial, go32_files_info)
7158 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
7159 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
7160 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
7161 (go32_pid_to_str): Refactor as methods of go32_nat_target.
7162 (go32_target): Delete.
7163 (_initialize_go32_nat): Adjust to C++ification.
7164
7165 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
7166 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
7167 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
7168 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
7169 gnu_nat_target.
7170 (gnu_target): Delete.
7171 * gnu-nat.h (gnu_target): Delete.
7172 (gnu_nat_target): New class.
7173 * i386-gnu-nat.c (gnu_base_target): New.
7174 (i386_gnu_nat_target): New class.
7175 (the_i386_gnu_nat_target): New.
7176 (_initialize_i386gnu_nat): Adjust to C++ification.
7177
7178 2018-05-02 Pedro Alves <palves@redhat.com>
7179
7180 * bfd-target.c (target_bfd_xclose): Rename to ...
7181 (target_bfd_close): ... this.
7182 (target_bfd_reopen): Adjust.
7183 * target.c (target_close): Remove references to to_xclose.
7184 * target.h (target_ops::to_xclose): Delete.
7185 (target_ops::to_close): Update comments.
7186
7187 2018-05-02 Pedro Alves <palves@redhat.com>
7188
7189 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
7190 "linux-nat.h".
7191 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
7192 * inf-ptrace.c (inf_ptrace_register_u_offset)
7193 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
7194 (inf_ptrace_store_register, inf_ptrace_store_registers)
7195 (inf_ptrace_trad_target): Move to ...
7196 * linux-nat-trad.c: ... this new file.
7197 * linux-nat-trad.h: New file.
7198 * linux-nat.c (linux_target_install_ops): Make extern.
7199 (linux_trad_target): Delete.
7200 * linux-nat.h (linux_trad_target): Delete declaration.
7201 (linux_target_install_ops): Declare.
7202 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
7203 "linux-nat.h".
7204
7205 2018-05-02 Pedro Alves <palves@redhat.com>
7206
7207 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
7208 procfs_target/add_target here.
7209 * procfs.c (procfs_target): Make static.
7210 (_initialize_procfs): Call add_target here.
7211 * procfs.h (struct target_ops): Remove forward declaration.
7212 (procfs_target): Remove declaration.
7213 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
7214
7215 2018-05-02 Pedro Alves <palves@redhat.com>
7216
7217 * procfs.c (procfs_stopped_by_watchpoint)
7218 (procfs_insert_watchpoint, procfs_remove_watchpoint)
7219 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
7220 Forward declare.
7221 (procfs_use_watchpoints): Delete, move contents...
7222 (procfs_target): ... here.
7223 * procfs.h (procfs_use_watchpoints): Delete declaration.
7224 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
7225 procfs_use_watchpoints.
7226 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
7227 procfs_use_watchpoints.
7228
7229 2018-05-02 Tom Tromey <tom@tromey.com>
7230
7231 PR python/20084:
7232 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
7233 and var_zuinteger_unlimited.
7234 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
7235 and PARAM_ZUINTEGER_UNLIMITED.
7236 (set_parameter_value): Handle var_zuinteger and
7237 var_zuinteger_unlimited.
7238 (add_setshow_generic): Likewise.
7239 (parmpy_init): Likewise.
7240
7241 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
7242
7243 PR rust/23124
7244 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
7245 pointer is not null before dereferencing it.
7246
7247 2018-04-30 Tom Tromey <tom@tromey.com>
7248
7249 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
7250 is_mi_like_p.
7251
7252 2018-04-30 Tom Tromey <tom@tromey.com>
7253
7254 * breakpoint.c (mention): Remove use of is_mi_like_p.
7255 (print_mention_ranged_breakpoint): Likewise.
7256 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
7257 of is_mi_like_p.
7258
7259 2018-04-30 Tom Tromey <tom@tromey.com>
7260
7261 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
7262
7263 2018-04-30 Tom Tromey <tom@tromey.com>
7264
7265 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
7266 (info_spu_event_command): Remove some uses of is_mi_like_p.
7267
7268 2018-04-30 Tom Tromey <tom@tromey.com>
7269
7270 * python/py-framefilter.c (py_print_single_arg)
7271 (enumerate_locals, py_print_args, py_print_frame): Remove some
7272 uses of is_mi_like_p.
7273
7274 2018-04-30 Tom Tromey <tom@tromey.com>
7275
7276 * ui-out.c: Update.
7277 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
7278 * ui-out.h (ui_out::is_mi_like_p): Now const.
7279 (ui_out::do_is_mi_like_p): Now const.
7280 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
7281
7282 2018-04-30 Tom Tromey <tom@tromey.com>
7283
7284 * varobj.c (varobj_set_visualizer): Use new_reference.
7285 * python/python.c (gdbpy_decode_line): Use new_reference.
7286 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
7287 new_reference.
7288
7289 2018-04-30 Tom Tromey <tom@tromey.com>
7290
7291 * varobj.c (install_new_value): Use new_reference.
7292 * value.h (value_incref): Return void. Swap intro comment with
7293 value_decref.
7294 * value.c (set_value_parent): Use new_reference.
7295 (value_incref): Return void. Update intro comment.
7296 (release_value): Use new_reference.
7297 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
7298
7299 2018-04-30 Tom Tromey <tom@tromey.com>
7300
7301 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
7302 * gdb_bfd.h (new_bfd_ref): Remove.
7303 (gdb_bfd_open): Update comment.
7304 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
7305 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
7306 (gdb_bfd_fdopenr): Use new_reference.
7307 * exec.c (exec_file_attach): Use new_reference.
7308
7309 2018-04-30 Tom Tromey <tom@tromey.com>
7310
7311 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
7312 method.
7313
7314 2018-04-30 Tom Tromey <tom@tromey.com>
7315
7316 * jit.c (jit_read_code_entry): Use type_align.
7317 * i386-tdep.c (i386_gdbarch_init): Don't call
7318 set_gdbarch_long_long_align_bit.
7319 * gdbarch.sh: Remove long_long_align_bit.
7320 * gdbarch.c, gdbarch.h: Rebuild.
7321 * arc-tdep.c (arc_type_align): New function.
7322 (arc_gdbarch_init): Use arc_type_align. Don't call
7323 set_gdbarch_long_long_align_bit.
7324
7325 2018-04-30 Tom Tromey <tom@tromey.com>
7326
7327 * rust-lang.c (rust_type_alignment): Remove.
7328 (rust_composite_type): Use type_align.
7329
7330 2018-04-30 Tom Tromey <tom@tromey.com>
7331
7332 * NEWS: Mention Type.align.
7333 * python/py-type.c (typy_get_alignof): New function.
7334 (type_object_getset): Add "alignof".
7335
7336 2018-04-30 Tom Tromey <tom@tromey.com>
7337
7338 PR exp/17095:
7339 * NEWS: Update.
7340 * std-operator.def (UNOP_ALIGNOF): New operator.
7341 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
7342 New.
7343 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
7344 * c-lang.c (c_op_print_tab): Add alignof.
7345 * c-exp.y (ALIGNOF): New token.
7346 (exp): Add "ALIGNOF" production.
7347 (ident_tokens): Add _Alignof and alignof.
7348
7349 2018-04-30 Tom Tromey <tom@tromey.com>
7350
7351 * i386-tdep.c (i386_type_align): New function.
7352 (i386_gdbarch_init): Update.
7353 * gdbarch.sh (type_align): New method.
7354 * gdbarch.c, gdbarch.h: Rebuild.
7355 * arch-utils.h (default_type_align): Declare.
7356 * arch-utils.c (default_type_align): New function.
7357 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
7358 (struct type) <align_log2>: New field.
7359 <instance_flags>: Now a bitfield.
7360 (TYPE_RAW_ALIGN): New macro.
7361 (type_align, type_raw_align, set_type_align): Declare.
7362 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
7363 functions.
7364 * dwarf2read.c (quirk_rust_enum): Set type alignment.
7365 (get_alignment, maybe_set_alignment): New functions.
7366 (read_structure_type, read_enumeration_type, read_array_type)
7367 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
7368 (read_subrange_type, read_base_type): Set type alignment.
7369
7370 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
7371
7372 * dwarf2read.c (read_index_from_section): Use bool.
7373
7374 2018-04-29 Fabian Groffen <grobian@gentoo.org>
7375
7376 PR gdb/22950
7377 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
7378 with #ifdef.
7379
7380 2018-04-29 John Reiser <jreiser@BitWagon.com>
7381
7382 PR build/22873
7383 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
7384 last step, and do it atomically.
7385
7386 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
7387
7388 * compile/compile-c-types.c (convert_int, convert_float):
7389 Update for C FE v1.
7390
7391 2018-04-27 Tom Tromey <tom@tromey.com>
7392
7393 PR rust/22545:
7394 * rust-lang.c (rust_inclusive_range_type_p): New function.
7395 (rust_range): Handle inclusive ranges.
7396 (rust_compute_range): Likewise.
7397 * rust-exp.y (struct rust_op) <inclusive>: New field.
7398 (DOTDOTEQ): New constant.
7399 (range_expr): Add "..=" productions.
7400 (operator_tokens): Add "..=" token.
7401 (ast_range): Add "inclusive" parameter.
7402 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
7403 ranges.
7404 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
7405 bounds values.
7406 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
7407 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
7408 Update comments.
7409 * expprint.c (print_subexp_standard): Handle new bounds values.
7410 (dump_subexp_body_standard): Likewise.
7411
7412 2018-04-27 Tom Tromey <tom@tromey.com>
7413
7414 * configure: Rebuild.
7415 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
7416 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
7417 "OVERRIDE".
7418 (class symbol_needs_eval_context): Likewise.
7419 * dwarf2read.c (mock_mapped_index::symbol_name_count)
7420 (mock_mapped_index::symbol_name_at): Use "override". Remove
7421 "virtual".
7422 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
7423 "override".
7424 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
7425 * aarch64-tdep.c (instruction_reader::read): Use "override".
7426 (instruction_reader_test::read): Likewise.
7427 * arm-tdep.c (instruction_reader::read): Use "override".
7428 (instruction_reader_thumb::read): Likewise.
7429
7430 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
7431
7432 PR remote/9665
7433 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
7434 instead of remote_send.
7435 (remote_send): Remove.
7436
7437 2018-04-26 Pedro Alves <palves@redhat.com>
7438
7439 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
7440 find_function_start_sal instead of find_pc_line.
7441
7442 2018-04-26 Pedro Alves <palves@redhat.com>
7443
7444 * breakpoint.c (set_breakpoint_location_function): Handle
7445 mst_data_gnu_ifunc.
7446 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
7447 * elfread.c (elf_symtab_read): Give data symbols with
7448 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
7449 (elf_rel_plt_read): Update comment.
7450 * linespec.c (convert_linespec_to_sals): Handle
7451 mst_data_gnu_ifunc.
7452 (minsym_found): Handle mst_data_gnu_ifunc.
7453 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
7454 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
7455 * parse.c (find_minsym_type_and_address): Handle
7456 mst_data_gnu_ifunc.
7457 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
7458 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
7459 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
7460 comment.
7461 <mst_data_gnu_ifunc>: New enumerator.
7462
7463 2018-04-26 Pedro Alves <palves@redhat.com>
7464
7465 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
7466 (lookup_minimal_symbol_by_pc_section): ... this. Replace
7467 'want_trampoline' parameter by a lookup_msym_prefer parameter.
7468 Handle it.
7469 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
7470 (lookup_minimal_symbol_by_pc): Adjust.
7471 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
7472 (lookup_solib_trampoline_symbol_by_pc): Adjust.
7473 * minsyms.h (lookup_msym_prefer): New enum.
7474 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
7475 parameter by a lookup_msym_prefer parameter.
7476
7477 2018-04-26 Pedro Alves <palves@redhat.com>
7478
7479 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
7480 ends in "@plt" instead of looking at the symbol's section.
7481
7482 2018-04-26 Pedro Alves <palves@redhat.com>
7483
7484 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
7485 all references.
7486 (find_pc_partial_function_gnu_ifunc): Rename to ...
7487 (find_pc_partial_function): ... this, and remove references to
7488 'is_gnu_ifunc_p'.
7489 (find_pc_partial_function): Delete old implementation.
7490 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
7491
7492 2018-04-26 Pedro Alves <palves@redhat.com>
7493
7494 * linespec.c (struct bound_minimal_symbol_search_key): New.
7495 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
7496 skip first line if we found a GNU ifunc minimal symbol by name.
7497 (compare_msymbols): Change parameters to work with a destructured
7498 lhs minsym.
7499 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
7500 functions.
7501
7502 2018-04-26 Pedro Alves <palves@redhat.com>
7503
7504 * breakpoint.c (set_breakpoint_location_function): Don't resolve
7505 ifunc targets here. Instead, if we have an ifunc minsym, use its
7506 address/name.
7507 (add_location_to_breakpoint): Store the minsym and the objfile in
7508 the breakpoint location.
7509 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
7510 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
7511 Record the minsym in the sal.
7512 * symtab.h (symtab_and_line) <msymbol>: New field.
7513
7514 2018-04-26 Pedro Alves <palves@redhat.com>
7515
7516 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
7517 unless we actually resolved the ifunc.
7518
7519 2018-04-26 Pedro Alves <palves@redhat.com>
7520
7521 * c-exp.y (variable production): Prefer ifunc minsyms over
7522 regular function symbols.
7523 * symtab.c (find_gnu_ifunc): New function.
7524 * minsyms.h (lookup_msym_prefer): New enum.
7525 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
7526 parameter by a lookup_msym_prefer parameter.
7527 * symtab.h (find_gnu_ifunc): New declaration.
7528
7529 2018-04-26 Pedro Alves <palves@redhat.com>
7530
7531 * blockframe.c (find_gnu_ifunc_target_type): New function.
7532 (find_function_type): New.
7533 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
7534 return a value with a memory address.
7535 (eval_call): For calls to GNU ifunc functions, try to find the
7536 type of the target function from the type that the resolver
7537 returns.
7538 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
7539 symbols.
7540 * infcall.c (find_function_return_type): Delete.
7541 (find_function_addr): Add 'function_type' parameter. For calls to
7542 GNU ifunc functions, try to find the type of the target function
7543 from the type that the resolver returns, and return it via
7544 FUNCTION_TYPE.
7545 (call_function_by_hand_dummy): Adjust to use the function type
7546 returned by find_function_addr.
7547 (find_function_addr): Add 'function_type' parameter and move
7548 description here.
7549 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
7550 declarations.
7551
7552 2018-04-26 Pedro Alves <palves@redhat.com>
7553
7554 * c-exp.y (variable production): Skip finding an alias for ifunc
7555 symbols.
7556
7557 2018-04-26 Pedro Alves <palves@redhat.com>
7558
7559 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
7560
7561 2018-04-25 Pedro Alves <palves@redhat.com>
7562
7563 * infcmd.c (kill_command): Print the pid as string, not the whole
7564 thread's ptid. Add comment. s/has been killed/killed/ in output
7565 message.
7566 * remote.c (remote_detach_1): Print the pid as string, not the
7567 whole thread's ptid.
7568
7569 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7570 Sergio Durigan Junior <sergiodj@redhat.com>
7571 Pedro Alves <palves@redhat.com>
7572
7573 * infcmd.c (kill_command): Print message when inferior has
7574 been killed.
7575 * inferior.c (print_inferior_events): Remove 'static'. Set as
7576 '1'.
7577 (add_inferior): Improve message printed when
7578 'print_inferior_events' is on.
7579 (exit_inferior): Remove message printed when
7580 'print_inferior_events' is on.
7581 (detach_inferior): Improve message printed when
7582 'print_inferior_events' is on.
7583 (initialize_inferiors): Use 'add_inferior_silent' to set
7584 'current_inferior_'.
7585 * inferior.h (print_inferior_events): Declare here as
7586 'extern'.
7587 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
7588 '[Detaching...]' messages when 'print_inferior_events' is on.
7589 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
7590 as prefix/suffix for messages. Remove periods. Fix erroneous
7591 'Detaching after fork from child...', replace it by '... from
7592 parent...'.
7593 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
7594 prefix/suffix when printing 'Detaching...' messages. Print
7595 them when 'print_inferior_events' is on.
7596 * remote.c (remote_detach_1): Print message when detaching
7597 from inferior and '!is_fork_parent'.
7598
7599 2018-04-24 Tom Tromey <tom@tromey.com>
7600
7601 * cli-out.h: Reindent.
7602
7603 2018-04-24 Tom Tromey <tom@tromey.com>
7604
7605 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
7606 (cli_ui_out::do_field_string): Use fputs_filtered.
7607 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
7608
7609 2018-04-23 Tom Tromey <tom@tromey.com>
7610
7611 * guile/scm-frame.c (gdbscm_frame_read_var): Use
7612 gdb::unique_xmalloc_ptr.
7613
7614 2018-04-23 Tom Tromey <tom@tromey.com>
7615
7616 * configure: Rebuild.
7617
7618 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
7619
7620 PR gdb/23095
7621 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
7622 prepare_for_testing. Set normal_bp to r_debug_state if target
7623 is bsd.
7624
7625 2018-04-21 Pedro Alves <palves@redhat.com>
7626 Rajendra SY <rajendra.sy@gmail.com>
7627
7628 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
7629 * remote.c (extended_remote_attach): In all-stop mode, mark the
7630 thread as executing.
7631
7632 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7633
7634 * thread.c (thread_apply_all_command): Fix comment.
7635 (thread_command): Fix comment.
7636
7637 2018-04-10 Alan Hayward <alan.hayward@arm.com>
7638
7639 * common/tdesc.h (tdesc_create_feature): Remove xml filename
7640 parameter.
7641 * features/aarch64-core.c (create_feature_aarch64_core):
7642 Regenerate.
7643 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
7644 Likewise.
7645 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
7646 Likewise.
7647 * features/i386/32bit-avx512.c
7648 (create_feature_i386_32bit_avx512): Likewise.
7649 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
7650 Likewise.
7651 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
7652 Likewise.
7653 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
7654 Likewise.
7655 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
7656 Likewise.
7657 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
7658 Likewise.
7659 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
7660 Likewise.
7661 * features/i386/64bit-avx512.c
7662 (create_feature_i386_64bit_avx512): Likewise.
7663 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
7664 Likewise.
7665 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
7666 Likewise.
7667 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
7668 Likewise.
7669 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
7670 Likewise.
7671 * features/i386/64bit-segments.c
7672 (create_feature_i386_64bit_segments): Likewise.
7673 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
7674 Likewise.
7675 * features/i386/x32-core.c
7676 (create_feature_i386_x32_core): Likewise.
7677 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
7678 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
7679 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
7680 * target-descriptions.c: In generated code, don't pass xml
7681 filename.
7682
7683 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7684
7685 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
7686 (print_xml_feature::visit_post): Likewise.
7687 (print_xml_feature::visit): Likewise.
7688 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
7689 (print_xml_feature): Add new class.
7690 * regformats/regdat.sh: Null xmltarget on feature targets.
7691 * target-descriptions.c (struct target_desc): Add xmltarget.
7692 (maintenance_check_tdesc_xml_convert): Add unittest function.
7693 (tdesc_get_features_xml): Add function to get xml.
7694 (maintenance_check_xml_descriptions): Test xml generation.
7695 * xml-tdesc.c (string_read_description_xml): Add function.
7696 * xml-tdesc.h (string_read_description_xml): Add declaration.
7697
7698 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7699
7700 * features/Makefile: Add feature marker to targets with new style
7701 target descriptions.
7702 * regformats/aarch64.dat: Regenerate.
7703 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
7704 * regformats/i386/amd64-avx-linux.dat: Likewise.
7705 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
7706 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
7707 * regformats/i386/amd64-linux.dat: Likewise.
7708 * regformats/i386/amd64-mpx-linux.dat: Likewise.
7709 * regformats/i386/amd64.dat: Likewise.
7710 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
7711 * regformats/i386/i386-avx-linux.dat: Likewise.
7712 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
7713 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
7714 * regformats/i386/i386-linux.dat: Likewise.
7715 * regformats/i386/i386-mmx-linux.dat: Likewise.
7716 * regformats/i386/i386-mpx-linux.dat: Likewise.
7717 * regformats/i386/i386.dat: Likewise.
7718 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
7719 * regformats/i386/x32-avx-linux.dat: Likewise.
7720 * regformats/i386/x32-linux.dat: Likewise.
7721 * regformats/tic6x-c62x-linux.dat: Likewise.
7722 * regformats/tic6x-c64x-linux.dat: Likewise.
7723 * regformats/tic6x-c64xp-linux.dat: Likewise.
7724 * regformats/regdat.sh: Parse feature marker.
7725
7726 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7727
7728 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
7729 (tdesc_osabi_name): Likewise.
7730 * target-descriptions.c (tdesc_architecture_name): Add new
7731 function.
7732 (tdesc_osabi_name): Likewise.
7733
7734 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7735
7736 * common/tdesc.c (tdesc_predefined_type): Move to here.
7737 (tdesc_named_type): Likewise.
7738 (tdesc_create_vector): Likewise.
7739 (tdesc_create_struct): Likewise.
7740 (tdesc_set_struct_size): Likewise.
7741 (tdesc_create_union): Likewise.
7742 (tdesc_create_flags): Likewise.
7743 (tdesc_create_enum): Likewise.
7744 (tdesc_add_field): Likewise.
7745 (tdesc_add_typed_bitfield): Likewise.
7746 (tdesc_add_bitfield): Likewise.
7747 (tdesc_add_flag): Likewise.
7748 (tdesc_add_enum_value): Likewise.
7749 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
7750 (struct tdesc_type_vector): Likewise.
7751 (struct tdesc_type_field): Likewise.
7752 (struct tdesc_type_with_fields): Likewise.
7753 (tdesc_create_enum): Add declaration.
7754 (tdesc_add_typed_bitfield): Likewise.
7755 (tdesc_add_enum_value): Likewise.
7756 * target-descriptions.c (tdesc_type_field): Move from here.
7757 (tdesc_type_builtin): Likewise.
7758 (tdesc_type_vector): Likewise.
7759 (tdesc_type_with_fields): Likewise.
7760 (tdesc_predefined_types): Likewise.
7761 (tdesc_named_type): Likewise.
7762 (tdesc_create_vector): Likewise.
7763 (tdesc_create_struct): Likewise.
7764 (tdesc_set_struct_size): Likewise.
7765 (tdesc_create_union): Likewise.
7766 (tdesc_create_flags): Likewise.
7767 (tdesc_create_enum): Likewise.
7768 (tdesc_add_field): Likewise.
7769 (tdesc_add_typed_bitfield): Likewise.
7770 (tdesc_add_bitfield): Likewise.
7771 (tdesc_add_flag): Likewise.
7772 (tdesc_add_enum_value): Likewise.
7773 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
7774 (tdesc_add_typed_bitfield): Likewise.
7775 (tdesc_add_enum_value): Likewise.
7776
7777 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7778
7779 * common/tdesc.c (tdesc_feature::accept): Move to here.
7780 (tdesc_feature::operator==): Likewise.
7781 (tdesc_create_reg): Likewise.
7782 * common/tdesc.h (tdesc_type_kind): Likewise.
7783 (struct tdesc_type): Likewise.
7784 (struct tdesc_feature): Likewise.
7785 * regformats/regdat.sh: Create a feature.
7786 * target-descriptions.c (tdesc_type_kind): Move from here.
7787 (tdesc_type): Likewise.
7788 (tdesc_type_up): Likewise.
7789 (tdesc_feature): Likewise.
7790 (tdesc_create_reg): Likewise.
7791
7792 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7793
7794 * Makefile.in: Add arch/tdesc.c
7795 * common/tdesc.c: New file.
7796 * common/tdesc.h (tdesc_element_visitor): Move to here.
7797 (tdesc_element): Likewise.
7798 (tdesc_reg): Likewise.
7799 (tdesc_reg_up): Likewise.
7800 * regformats/regdef.h (reg): Add offset to constructors.
7801 * target-descriptions.c (tdesc_element_visitor): Move from here.
7802 (tdesc_element): Likewise.
7803 (tdesc_reg): Likewise.
7804 (tdesc_reg_up): Likewise.
7805
7806 2018-04-17 Tom Tromey <tom@tromey.com>
7807
7808 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
7809 discriminant field.
7810
7811 2018-04-17 Tom Tromey <tom@tromey.com>
7812
7813 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
7814
7815 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
7816
7817 * symtab.c (print_symbol_info): Skip printing filename and line
7818 number when `last' is NULL.
7819 (symtab_symbol_info): Use empty string instead of NULL for first
7820 invocation of print_symbol_info.
7821 (rbreak_command): Pass NULL to `last' parameter of
7822 print_symbol_info.
7823
7824 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
7825
7826 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
7827 instead of nullptr.
7828
7829 2018-04-16 Pedro Alves <palves@redhat.com>
7830
7831 * MAINTAINERS (sh): Remove.
7832 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
7833 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
7834 (ALLDEPFILES): Remove sh64-tdep.c.
7835 * NEWS: Mentions that support for SH-5/SH64 is removed.
7836 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
7837 (sh*-*-openbsd*): Ditto.
7838 (sh64-*-elf*): Remove.
7839 (sh*): Remove.
7840 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
7841 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
7842 * sh-tdep.c: No longer include "sh64-tdep.h".
7843 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
7844 * sh64-tdep.c, sh64-tdep.h: Remove files.
7845
7846 2018-04-16 Pedro Alves <palves@redhat.com>
7847
7848 * MAINTAINERS: Remove m88k.
7849 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
7850 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
7851 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
7852 * NEWS: Mention that support for m88k was removed.
7853 * configure.host (m88*-*-*): Remove support.
7854 * configure.nat (m88k-*-*): Remove support.
7855 * configure.tgt (m88*-*-openbsd*): Remove.
7856 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
7857
7858 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
7859
7860 * configure.tgt (x86_tobjs): New variable.
7861 (amd64_tobjs, i386_tobjs): Use it.
7862
7863 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7864
7865 * symtab.c (print_symbol_info): Precede the symbol definition by
7866 the line number when available.
7867 * NEWS: Advertise this enhancement.
7868
7869 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7870
7871 * NEWS (New options): announce set/show record btrace cpu.
7872 * btrace.c: Include record-btrace.h.
7873 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
7874 the vendor is unknown.
7875 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
7876 Maybe overwrite the btrace configuration's cpu.
7877 (btrace_compute_ftrace): Add cpu parameter. Update callers.
7878 (btrace_fetch): Add cpu parameter. Update callers.
7879 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
7880 Maybe overwrite the btrace configuration's cpu. Skip enabling
7881 errata workarounds if the vendor is unknown.
7882 * python/py-record-btrace.c: Include record-btrace.h.
7883 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
7884 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
7885 * record-btrace.c (record_btrace_cpu_state_kind): New.
7886 (record_btrace_cpu): New.
7887 (set_record_btrace_cpu_cmdlist): New.
7888 (record_btrace_get_cpu): New.
7889 (require_btrace_thread, record_btrace_info)
7890 (record_btrace_resume_thread): Call record_btrace_get_cpu.
7891 (cmd_set_record_btrace_cpu_none): New.
7892 (cmd_set_record_btrace_cpu_auto): New.
7893 (cmd_set_record_btrace_cpu): New.
7894 (cmd_show_record_btrace_cpu): New.
7895 (_initialize_record_btrace): Initialize set/show record btrace cpu
7896 commands.
7897 * record-btrace.h (record_btrace_get_cpu): New.
7898
7899 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7900
7901 * record.c (set_record_command): Fix typo in message.
7902
7903 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7904
7905 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
7906
7907 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7908
7909 * infrun.c (process_event_stop_test): Call
7910 gdbarch_in_indirect_branch_thunk.
7911 * gdbarch.sh (in_indirect_branch_thunk): New.
7912 * gdbarch.c: Regenerated.
7913 * gdbarch.h: Regenerated.
7914 * x86-tdep.h: New.
7915 * x86-tdep.c: New.
7916 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
7917 (HFILES_NO_SRCDIR): Add x86-tdep.h.
7918 (ALLDEPFILES): Add x86-tdep.c.
7919 * arch-utils.h (default_in_indirect_branch_thunk): New.
7920 * arch-utils.c (default_in_indirect_branch_thunk): New.
7921 * i386-tdep: Include x86-tdep.h.
7922 (i386_in_indirect_branch_thunk): New.
7923 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
7924 function.
7925 * amd64-tdep: Include x86-tdep.h.
7926 (amd64_in_indirect_branch_thunk): New.
7927 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
7928
7929 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
7930
7931 PR gdb/23053
7932 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
7933 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
7934 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
7935 regression.
7936
7937 2018-04-12 Tom Tromey <tom@tromey.com>
7938
7939 * rust-lang.c (rust_print_struct_def): Remove univariant code.
7940 (rust_evaluate_subexp): Likewise.
7941
7942 2018-04-12 Pedro Alves <palves@redhat.com>
7943
7944 * procfs.c (procfs_detach): Make forward declaration's prototype
7945 match definition's protototype.
7946 (proc_get_LDT_entry): Remove stale do_cleanups call.
7947
7948 2018-04-12 Pedro Alves <palves@redhat.com>
7949
7950 * target.h (target_ops::to_has_exited): Delete.
7951 (target_has_exited): Delete.
7952 * target-delegates.c: Regenerate.
7953
7954 2018-04-11 Pedro Alves <palves@redhat.com>
7955
7956 * target.c (fileio_fh_t::t): Add comment.
7957 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7958 (target_fileio_close): Handle a NULL target.
7959 (invalidate_fileio_fh): New.
7960 (target_close): Call it.
7961 * remote.c (remote_hostio_send_command): No longer check whether
7962 remote_desc is open.
7963
7964 2018-04-11 Pedro Alves <palves@redhat.com>
7965
7966 * target.c (fileio_fh_t): Make it a named struct instead of a
7967 typedef.
7968 (fileio_fh_t::is_closed): New method.
7969 (DEF_VEC_O (fileio_fh_t)): Remove.
7970 (fileio_fhandles): Now a std::vector.
7971 (is_closed_fileio_fh): Delete.
7972 (acquire_fileio_fd): Adjust. Rename parameters.
7973 (release_fileio_fd): Adjust.
7974 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
7975 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7976 (target_fileio_close): Adjust.
7977
7978 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
7979
7980 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
7981 index.
7982
7983 2018-04-10 Pedro Alves <palves@redhat.com>
7984
7985 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
7986 (scoped_finish_thread_state): New class.
7987 * infcmd.c (run_command_1): Use it instead of finish_thread_state
7988 cleanup.
7989 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
7990 (fetch_inferior_event, normal_stop): Likewise.
7991 * thread.c (finish_thread_state_cleanup): Delete.
7992
7993 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7994 Pedro Alves <palves@redhat.com>
7995
7996 * value.c: Include "selftest.h" and "common/array-view.h".
7997 (struct range) <operator ==>: New.
7998 (test_ranges_contain): New.
7999 (check_ranges_vector): New.
8000 (test_insert_into_bit_range_vector): New.
8001 (_initialize_values): Register selftests.
8002 * common/array-view.h (operator==, operator!=): New.
8003
8004 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8005
8006 * common/gdb_vecs.h (unordered_remove): Add overload that takes
8007 an iterator.
8008 * inline-frame.c: Include <algorithm>.
8009 (struct inline_state): Add constructor.
8010 (inline_state_s): Remove.
8011 (DEF_VEC_O(inline_state_s)): Remove.
8012 (inline_states): Change type to std::vector.
8013 (find_inline_frame_state): Adjust to std::vector.
8014 (allocate_inline_frame_state): Remove.
8015 (clear_inline_frame_state): Adjust to std::vector.
8016 (skip_inline_frames): Adjust to std::vector.
8017
8018 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8019
8020 * tracepoint.h (struct trace_state_variable): Add constructor.
8021 <name>: Change type to std::string.
8022 * tracepoint.c (tsv_s): Remove.
8023 (DEF_VEC_O(tsv_s)): Remove.
8024 (tvariables): Change to std::vector.
8025 (create_trace_state_variable): Adjust to std::vector.
8026 (find_trace_state_variable): Likewise.
8027 (find_trace_state_variable_by_number): Likewise.
8028 (delete_trace_state_variable): Likewise.
8029 (trace_variable_command): Adjust to std::string.
8030 (delete_trace_variable_command): Likewise.
8031 (tvariables_info_1): Adjust to std::vector.
8032 (save_trace_state_variables): Likewise.
8033 (start_tracing): Likewise.
8034 (merge_uploaded_trace_state_variables): Adjust to std::vector
8035 and std::string.
8036 * target.h (struct target_ops)
8037 <to_download_trace_state_variable>: Pass reference to
8038 trace_state_variable.
8039 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
8040 * target-delegates.c: Re-generate.
8041 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
8042 (mi_tsv_deleted): Likewise.
8043 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
8044 * remote.c (remote_download_trace_state_variable): Change
8045 pointer to reference and adjust.
8046 * make-target-delegates (parse_argtypes): Handle references.
8047 (write_function_header): Likewise.
8048 (munge_type): Likewise.
8049
8050 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8051
8052 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8053 string_view-selftests.c.
8054 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
8055 testsuite.
8056 * unittests/basic_string_view/cons/char/1.cc: Likewise.
8057 * unittests/basic_string_view/cons/char/2.cc: Likewise.
8058 * unittests/basic_string_view/cons/char/3.cc: Likewise.
8059 * unittests/basic_string_view/element_access/char/1.cc:
8060 Likewise.
8061 * unittests/basic_string_view/element_access/char/empty.cc:
8062 Likewise.
8063 * unittests/basic_string_view/element_access/char/front_back.cc:
8064 Likewise.
8065 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
8066 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
8067 Likewise.
8068 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
8069 Likewise.
8070 * unittests/basic_string_view/modifiers/swap/char/1.cc:
8071 Likewise.
8072 * unittests/basic_string_view/operations/compare/char/1.cc:
8073 Likewise.
8074 * unittests/basic_string_view/operations/compare/char/13650.cc:
8075 Likewise.
8076 * unittests/basic_string_view/operations/copy/char/1.cc:
8077 Likewise.
8078 * unittests/basic_string_view/operations/data/char/1.cc:
8079 Likewise.
8080 * unittests/basic_string_view/operations/find/char/1.cc:
8081 Likewise.
8082 * unittests/basic_string_view/operations/find/char/2.cc:
8083 Likewise.
8084 * unittests/basic_string_view/operations/find/char/3.cc:
8085 Likewise.
8086 * unittests/basic_string_view/operations/find/char/4.cc:
8087 Likewise.
8088 * unittests/basic_string_view/operations/rfind/char/1.cc:
8089 Likewise.
8090 * unittests/basic_string_view/operations/rfind/char/2.cc:
8091 Likewise.
8092 * unittests/basic_string_view/operations/rfind/char/3.cc:
8093 Likewise.
8094 * unittests/basic_string_view/operations/substr/char/1.cc:
8095 Likewise.
8096 * unittests/basic_string_view/operators/char/2.cc: Likewise.
8097 * unittests/string_view-selftests.c: New file.
8098
8099 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8100
8101 * unittests/basic_string_view/capacity/1.cc: New file.
8102 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
8103 * unittests/basic_string_view/cons/char/1.cc: New file.
8104 * unittests/basic_string_view/cons/char/2.cc: New file.
8105 * unittests/basic_string_view/cons/char/3.cc: New file.
8106 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
8107 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
8108 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
8109 * unittests/basic_string_view/element_access/char/1.cc: New file.
8110 * unittests/basic_string_view/element_access/char/2.cc: New file.
8111 * unittests/basic_string_view/element_access/char/empty.cc: New file.
8112 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
8113 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
8114 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
8115 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
8116 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
8117 * unittests/basic_string_view/include.cc: New file.
8118 * unittests/basic_string_view/inserters/char/1.cc: New file.
8119 * unittests/basic_string_view/inserters/char/2.cc: New file.
8120 * unittests/basic_string_view/inserters/char/3.cc: New file.
8121 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
8122 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
8123 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
8124 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
8125 * unittests/basic_string_view/literals/types.cc: New file.
8126 * unittests/basic_string_view/literals/values.cc: New file.
8127 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
8128 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
8129 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
8130 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
8131 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
8132 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
8133 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
8134 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
8135 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
8136 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
8137 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
8138 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
8139 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
8140 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
8141 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
8142 * unittests/basic_string_view/operations/data/char/1.cc: New file.
8143 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
8144 * unittests/basic_string_view/operations/find/char/1.cc: New file.
8145 * unittests/basic_string_view/operations/find/char/2.cc: New file.
8146 * unittests/basic_string_view/operations/find/char/3.cc: New file.
8147 * unittests/basic_string_view/operations/find/char/4.cc: New file.
8148 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
8149 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
8150 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
8151 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
8152 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
8153 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
8154 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
8155 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
8156 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
8157 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
8158 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
8159 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
8160 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
8161 * unittests/basic_string_view/operators/char/2.cc: New file.
8162 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
8163 * unittests/basic_string_view/range_access/char/1.cc: New file.
8164 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
8165 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
8166 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
8167 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
8168 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
8169 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
8170 * unittests/basic_string_view/requirements/typedefs.cc: New file.
8171 * unittests/basic_string_view/typedefs.cc: New file.
8172 * unittests/basic_string_view/types/1.cc: New file.
8173
8174 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8175
8176 * common/gdb_string_view.h: Remove libstdc++ implementation
8177 details, adjust to gdb reality.
8178 * common/gdb_string_view.tcc: Likewise.
8179 * cli/cli-script.c (struct string_view): Remove.
8180 (user_args) <m_args>: Change element type to gdb::string_view.
8181 (user_args::insert_args): Adjust.
8182
8183 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8184
8185 * common/gdb_string_view.h: New file.
8186 * common/gdb_string_view.tcc: New file.
8187
8188 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8189
8190 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
8191 * configure: Re-generate.
8192
8193 2018-04-09 Pedro Alves <palves@redhat.com>
8194
8195 * gdbarch.sh: Include "observable.h" instead of "observer.h".
8196 (set_target_gdbarch): Call
8197 gdb::observers::architecture_changed.notify instead of
8198 observer_notify_architecture_changed.
8199
8200 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8201
8202 * tracepoint.c (struct current_traceframe_cleanup): Remove.
8203 (do_restore_current_traceframe_cleanup): Remove.
8204 (restore_current_traceframe_cleanup_dtor): Remove.
8205 (make_cleanup_restore_current_traceframe): Remove.
8206 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
8207 New.
8208 * tracepoint.h (struct scoped_restore_current_traceframe): New.
8209 * infrun.c (fetch_inferior_event): Use
8210 scoped_restore_current_traceframe.
8211
8212 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8213
8214 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
8215 Remove.
8216 <n_allocated_type_units>: Remove.
8217 <all_type_units>: Change to std::vector.
8218 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
8219 to std::vector change.
8220 (dwarf2_per_objfile::get_cutu): Likewise.
8221 (dwarf2_per_objfile::get_tu): Likewise.
8222 (create_signatured_type_table_from_index): Likewise.
8223 (create_signatured_type_table_from_debug_names): Likewise.
8224 (dw2_symtab_iter_next): Likewise.
8225 (dw2_print_stats): Likewise.
8226 (dw2_expand_all_symtabs): Likewise.
8227 (dw2_expand_marked_cus): Likewise.
8228 (dw2_debug_names_iterator::next): Likewise.
8229 (dwarf2_initialize_objfile): Likewise.
8230 (add_signatured_type_cu_to_table): Likewise.
8231 (create_all_type_units): Likewise.
8232 (add_type_unit): Likewise.
8233 (struct tu_abbrev_offset): Add constructor.
8234 (build_type_psymtabs_1): Adjust to std::vector change.
8235 (print_tu_stats): Likewise.
8236 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
8237 (write_debug_names): Likewise.
8238
8239 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8240
8241 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
8242 Make an std::vector.
8243 <n_comp_units>: Remove.
8244 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
8245 to std::vector change.
8246 (dwarf2_per_objfile::get_cutu): Likewise.
8247 (dwarf2_per_objfile::get_cu): Likewise.
8248 (create_cus_from_index): Likewise.
8249 (create_addrmap_from_index): Likewise.
8250 (create_addrmap_from_aranges): Likewise.
8251 (dwarf2_read_index): Likewise.
8252 (dw2_find_last_source_symtab): Likewise.
8253 (dw2_map_symtabs_matching_filename): Likewise.
8254 (dw2_symtab_iter_next): Likewise.
8255 (dw2_print_stats): Likewise.
8256 (dw2_expand_all_symtabs): Likewise.
8257 (dw2_expand_symtabs_with_fullname): Likewise.
8258 (dw2_expand_marked_cus): Likewise.
8259 (dw2_map_symbol_filenames): Likewise.
8260 (create_cus_from_debug_names): Likewise.
8261 (dwarf2_read_debug_names): Likewise.
8262 (dw2_debug_names_iterator::next): Likewise.
8263 (dwarf2_initialize_objfile): Likewise.
8264 (set_partial_user): Likewise.
8265 (dwarf2_build_psymtabs_hard): Likewise.
8266 (read_comp_units_from_section): Remove arguments, adjust to
8267 std::vector change.
8268 (create_all_comp_units): Adjust to std::vector and
8269 read_comp_units_from_section changes.
8270 (dwarf2_find_containing_comp_unit): Adjust to std::vector
8271 change.
8272 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
8273 (psyms_seen_size): Likewise.
8274 (write_gdbindex): Likewise.
8275 (write_debug_names): Likewise.
8276
8277 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8278
8279 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
8280 with dwarf2_per_objfile.
8281 (create_cus_from_index): Likewise.
8282 (create_signatured_type_table_from_index): Likewise.
8283 (dwarf2_read_index): Likewise.
8284 (dwarf2_initialize_objfile): Likewise.
8285 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
8286 per_cu rather than get_dwarf2_per_objfile.
8287
8288 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8289
8290 * dwarf2read.h (struct signatured_type): Forward declare.
8291 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
8292 New methods.
8293 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
8294 (dw2_get_cutu): ...this.
8295 (dwarf2_per_objfile::get_cu): Rename from...
8296 (dw2_get_cu): ...this.
8297 (dwarf2_per_objfile::get_tu): New.
8298 (create_addrmap_from_index): Adjust.
8299 (create_addrmap_from_aranges): Adjust.
8300 (dw2_find_last_source_symtab): Adjust.
8301 (dw2_map_symtabs_matching_filename): Adjust.
8302 (dw2_symtab_iter_next): Adjust.
8303 (dw2_print_stats): Adjust.
8304 (dw2_expand_all_symtabs): Adjust.
8305 (dw2_expand_symtabs_with_fullname): Adjust.
8306 (dw2_expand_marked_cus): Adjust.
8307 (dw_expand_symtabs_matching_file_matcher): Adjust.
8308 (dw2_map_symbol_filenames): Adjust.
8309 (dw2_debug_names_iterator::next): Adjust.
8310 (dwarf2_initialize_objfile): Adjust.
8311 (set_partial_user): Adjust.
8312 (dwarf2_build_psymtabs_hard): Adjust.
8313
8314 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8315
8316 * dwarf2read.c (create_signatured_type_table_from_debug_names):
8317 Remove unused variables.
8318 (dw2_map_symtabs_matching_filename): Likewise.
8319 (dwarf2_record_block_ranges): Likewise.
8320 (dwarf2_read_addr_index): Likewise.
8321 (follow_die_offset): Likewise.
8322
8323 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8324
8325 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
8326 to symbol_file_add_main.
8327
8328 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8329
8330 PR mi/22299
8331 * mi/mi-console.c (do_fputc_async_safe): New.
8332 (mi_console_file::write_async_safe): New.
8333 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
8334 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
8335 New.
8336 * ui-file.c (ui_file::putstrn): Adjust call to
8337 fputstrn_unfiltered.
8338 * utils.c (printchar): Replace do_fputs and do_fprintf
8339 parameters by do_fputc.
8340 (fputstr_filtered): Adjust call to printchar.
8341 (fputstr_unfiltered): Likewise.
8342 (fputstrn_filtered): Likewise.
8343 (fputstrn_unfiltered): Add do_fputc parameter, pass to
8344 printchar.
8345 * utils.h (do_fputc_ftype): New typedef.
8346 (fputstrn_unfiltered): Add do_fputc parameter.
8347
8348 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8349
8350 * regformats/i386/i386-avx.dat: Remove.
8351
8352 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8353
8354 PR gdb/22979
8355 * amd64-tdep.c (amd64_none_init_abi): New function.
8356 (amd64_x32_none_init_abi): New function.
8357 (_initialize_amd64_tdep): Register handlers for x86-64 and
8358 x64_32 with GDB_OSABI_NONE.
8359 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
8360 GDB_OSABI_NONE osabi.
8361
8362 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8363
8364 PR gdb/22980
8365 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
8366 GDB_OSABI_NONE.
8367 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
8368 * osabi.c (gdb_osabi_names): Add "unknown" entry.
8369
8370 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8371
8372 * common/byte-vector.h (char_vector): New type.
8373 * target.h (target_read_alloc): Return
8374 gdb::optional<byte_vector>.
8375 (target_read_stralloc): Return gdb::optional<char_vector>.
8376 (target_get_osdata): Return gdb::optional<char_vector>.
8377 * target.c (target_read_alloc_1): Templatize. Replacement
8378 manual memory management with vector.
8379 (target_read_alloc): Change return type, adjust.
8380 (target_read_stralloc): Change return type, adjust.
8381 (target_get_osdata): Change return type, adjust.
8382 * auxv.c (struct auxv_info) <length>: Remove.
8383 <data>: Change type to gdb::optional<byte_vector>.
8384 (auxv_inferior_data_cleanup): Free auxv_info with delete.
8385 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
8386 (target_auxv_search): Adjust.
8387 (fprint_target_auxv): Adjust.
8388 * avr-tdep.c (avr_io_reg_read_command): Adjust.
8389 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
8390 (linux_make_corefile_notes): Adjust.
8391 * osdata.c (get_osdata): Adjust.
8392 * remote.c (remote_get_threads_with_qxfer): Adjust.
8393 (remote_memory_map): Adjust.
8394 (remote_traceframe_info): Adjust.
8395 (btrace_read_config): Adjust.
8396 (remote_read_btrace): Adjust.
8397 (remote_pid_to_exec_file): Adjust.
8398 * solib-aix.c (solib_aix_get_library_list): Adjust.
8399 * solib-dsbt.c (decode_loadmap): Don't free buf.
8400 (dsbt_get_initial_loadmaps): Adjust.
8401 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
8402 * solib-target.c (solib_target_current_sos): Adjust.
8403 * tracepoint.c (sdata_make_value): Adjust.
8404 * xml-support.c (xinclude_start_include): Adjust.
8405 (xml_fetch_content_from_file): Adjust.
8406 * xml-support.h (xml_fetch_another): Change return type.
8407 (xml_fetch_content_from_file): Change return type.
8408 * xml-syscall.c (xml_init_syscalls_info): Adjust.
8409 * xml-tdesc.c (file_read_description_xml): Adjust.
8410 (fetch_available_features_from_target): Change return type.
8411 (target_fetch_description_xml): Adjust.
8412 (target_read_description_xml): Adjust.
8413
8414 2018-04-06 Tom Tromey <tom@tromey.com>
8415
8416 * value.c (~value): Update.
8417 (struct value) <contents>: Now unique_xmalloc_ptr.
8418 (value_contents_bits_eq, allocate_value_contents)
8419 (value_contents_raw, value_contents_all_raw)
8420 (value_contents_for_printing, value_contents_for_printing_const)
8421 (set_value_enclosing_type): Update.
8422
8423 2018-04-06 Tom Tromey <tom@tromey.com>
8424
8425 * value.c (range_s): Remove typedef, VEC.
8426 (struct range): Add operator<.
8427 (range_lessthan): Remove.
8428 (ranges_contain): Change type.
8429 (~value): Update.
8430 (struct value) <unavailable, optimized_out>: Now std::vector.
8431 (value_entirely_available)
8432 (value_entirely_covered_by_range_vector)
8433 (value_entirely_unavailable, value_entirely_optimized_out):
8434 Update.
8435 (insert_into_bit_range_vector): Change argument type.
8436 (find_first_range_overlap): Likewise.
8437 (struct ranges_and_idx, value_contents_bits_eq)
8438 (require_not_optimized_out, require_available): Update.
8439 (ranges_copy_adjusted): Change argument types.
8440 (value_optimized_out, value_copy, value_fetch_lazy): Update.
8441
8442 2018-04-06 Tom Tromey <tom@tromey.com>
8443
8444 * value.c (~value): Update.
8445 (struct value) <parent>: Now a value_ref_ptr.
8446 (value_parent, set_value_parent, value_address, value_copy):
8447 Update.
8448
8449 2018-04-06 Tom Tromey <tom@tromey.com>
8450
8451 * value.c (struct value): Add constructor, destructor, and member
8452 initializers.
8453 (allocate_value_lazy, value_decref): Update.
8454
8455 2018-04-06 Tom Tromey <tom@tromey.com>
8456
8457 * value.c (struct value) <released, next>: Remove.
8458 (all_values): Now a std::vector.
8459 (allocate_value_lazy): Update.
8460 (value_next): Remove.
8461 (value_mark, value_free_to_mark, release_value)
8462 (value_release_to_mark): Update.
8463
8464 2018-04-06 Tom Tromey <tom@tromey.com>
8465
8466 * value.h (fetch_subexp_value, value_release_to_mark): Update.
8467 (free_value_chain): Remove.
8468 * value.c (free_value_chain): Remove.
8469 (value_release_to_mark): Return a std::vector.
8470 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
8471 std::vector.
8472 (check_condition): Update.
8473 * eval.c (fetch_subexp_value): Change "val_chain" to a
8474 std::vector.
8475 * breakpoint.c (update_watchpoint): Update.
8476 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
8477
8478 2018-04-06 Tom Tromey <tom@tromey.com>
8479
8480 * value.h (free_all_values): Remove.
8481 * value.c (free_all_values): Remove.
8482
8483 2018-04-06 Tom Tromey <tom@tromey.com>
8484
8485 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
8486 (value_history_chain, value_history_count): Remove.
8487 (value_history): New global.
8488 (record_latest_value, access_value_history, show_values)
8489 (preserve_values): Update.
8490
8491 2018-04-06 Tom Tromey <tom@tromey.com>
8492
8493 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
8494 * varobj.c (varobj_set_display_format, varobj_set_value)
8495 (install_default_visualizer, construct_visualizer)
8496 (install_new_value, ~varobj, varobj_get_value_type)
8497 (my_value_of_variable, varobj_editable_p): Update.
8498 * c-varobj.c (c_describe_child, c_value_of_variable)
8499 (cplus_number_of_children, cplus_describe_child): Update.
8500 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
8501 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
8502 (ada_value_of_variable, ada_value_is_changeable_p): Update.
8503
8504 2018-04-06 Tom Tromey <tom@tromey.com>
8505
8506 * printcmd.c (last_examine_address): Change type to
8507 value_ref_ptr.
8508 (do_examine, x_command): Update.
8509
8510 2018-04-06 Tom Tromey <tom@tromey.com>
8511
8512 * value.c (release_value): Update.
8513 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
8514 (struct bpstats) <val>: Now a value_ref_ptr.
8515 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
8516 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
8517 (~watchpoint, print_it_watchpoint, watch_command_1)
8518 (invalidate_bp_value_on_memory_change): Update.
8519
8520 2018-04-06 Tom Tromey <tom@tromey.com>
8521
8522 * varobj.c (varobj_clear_saved_item)
8523 (update_dynamic_varobj_children, install_new_value, ~varobj):
8524 Update.
8525 * value.h (value_incref): Move declaration earlier.
8526 (value_decref): Rename from value_free.
8527 (struct value_ref_policy): New.
8528 (value_ref_ptr): New typedef.
8529 (struct value_deleter): Remove.
8530 (gdb_value_up): Remove typedef.
8531 (release_value): Change return type.
8532 (release_value_or_incref): Remove.
8533 * value.c (set_value_parent): Update.
8534 (value_incref): Change return type.
8535 (value_decref): Rename from value_free.
8536 (value_free_to_mark, free_all_values, free_value_chain): Update.
8537 (release_value): Return value_ref_ptr.
8538 (release_value_or_incref): Remove.
8539 (record_latest_value, set_internalvar, clear_internalvar):
8540 Update.
8541 * stack.c (info_frame_command): Don't call value_free.
8542 * python/py-value.c (valpy_dealloc, valpy_new)
8543 (value_to_value_object): Update.
8544 * printcmd.c (do_examine): Update.
8545 * opencl-lang.c (lval_func_free_closure): Update.
8546 * mi/mi-main.c (register_changed_p): Don't call value_free.
8547 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
8548 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
8549 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
8550 value_free.
8551 * guile/scm-value.c (vlscm_free_value_smob)
8552 (vlscm_scm_from_value): Update.
8553 * frame.c (frame_register_unwind, frame_unwind_register_signed)
8554 (frame_unwind_register_unsigned, get_frame_register_bytes)
8555 (put_frame_register_bytes): Don't call value_free.
8556 * findvar.c (address_from_register): Don't call value_free.
8557 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
8558 * dwarf2loc.c (entry_data_value_free_closure)
8559 (value_of_dwarf_reg_entry, free_pieced_value_closure)
8560 (dwarf2_evaluate_loc_desc_full): Update.
8561 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
8562 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
8563 (~watchpoint, watch_command_1)
8564 (invalidate_bp_value_on_memory_change): Update.
8565 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
8566
8567 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
8568
8569 PR gdb/23022
8570 * warning.m4: Add -Wno-error=deprecated-register.
8571 * configure: Re-generate.
8572
8573 2018-04-05 Tom Tromey <tom@tromey.com>
8574
8575 * linespec.h: Remove include of "vec.h".
8576
8577 2018-04-05 Tom Tromey <tom@tromey.com>
8578
8579 * linespec.c (typep): Remove typedef.
8580 (find_methods, find_superclass_methods): Take a std::vector.
8581 (find_method): Use std::vector.
8582
8583 2018-04-05 Tom Tromey <tom@tromey.com>
8584
8585 * utils.c (compare_strings): Remove.
8586 * utils.h (compare_strings): Remove.
8587 * objc-lang.h (find_imps): Update.
8588 * objc-lang.c (find_methods): Take a std::vector.
8589 (uniquify_strings, find_imps): Likewise.
8590 * linespec.c (find_methods): Take a std::vector.
8591 (decode_objc): Use std::vector.
8592 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
8593 a std::vector.
8594 (find_method, find_function_symbols): Use std::vector.
8595
8596 2018-04-05 Tom Tromey <tom@tromey.com>
8597
8598 * completer.c (completion_tracker::completion_tracker): Remove
8599 cast.
8600 (completion_tracker::discard_completions): Likewise.
8601 * breakpoint.c (ambiguous_names_p): Remove cast.
8602 * ada-lang.c (_initialize_ada_language): Remove cast.
8603 * utils.h (streq): Update.
8604 (streq_hash): Add new declaration.
8605 * utils.c (streq): Return bool.
8606 (streq_hash): New function.
8607
8608 2018-04-05 Tom Tromey <tom@tromey.com>
8609
8610 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
8611 Remove a string copy.
8612
8613 2018-04-05 Tom Tromey <tom@tromey.com>
8614
8615 * linespec.c (filter_results): Use std::vector.
8616 (decode_line_2, decode_line_full): Update.
8617
8618 2018-04-05 Tom Tromey <tom@tromey.com>
8619
8620 * linespec.c (canonical_to_fullform): Return std::string.
8621 (filter_results): Update.
8622 (struct decode_line_2_item): Add constructor.
8623 <fullform, displayform>: Now std::string.
8624 (decode_line_2_compare_items): Now a std::sort comparator.
8625 (decode_line_2): Update.
8626
8627 2018-04-05 Tom Tromey <tom@tromey.com>
8628
8629 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
8630 (unexpected_linespec_error): Update.
8631 (linespec_parse_basic, parse_linespec): Update.
8632
8633 2018-04-05 Tom Tromey <tom@tromey.com>
8634
8635 * linespec.c (linespec_parse_basic): Reindent.
8636
8637 2018-04-05 Tom Tromey <tom@tromey.com>
8638
8639 * minsyms.h (iterate_over_minimal_symbols): Update.
8640 * minsyms.c (iterate_over_minimal_symbols): Take a
8641 gdb::function_view.
8642 * linespec.c (struct collect_minsyms): Remove.
8643 (compare_msyms): Now a std::sort comparator.
8644 (add_minsym): Add parameters.
8645 (search_minsyms_for_name): Update. Use std::vector.
8646
8647 2018-04-03 Tom Tromey <tom@tromey.com>
8648
8649 * mipsread.c (read_alphacoff_dynamic_symtab): Use
8650 gdb::byte_vector.
8651
8652 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
8653
8654 * MAINTAINERS (Write After Approval): Add Weimin Pan.
8655
8656 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
8657
8658 PR gdb/16959
8659 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
8660 printing static type.
8661
8662 2018-04-01 Tom Tromey <tom@tromey.com>
8663
8664 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
8665 (rs6000_xfer_shared_libraries): Update.
8666
8667 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
8668
8669 * common/gdb_vecs.h (char_ptr): Remove.
8670 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
8671
8672 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
8673
8674 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
8675 with std::vector.
8676 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
8677
8678 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
8679
8680 * tracepoint.h (struct uploaded_tp): Initialize fields.
8681 <actions, step_actions, cmd_strings>: Change type to
8682 std::vector<char *>.
8683 * tracepoint.c (get_uploaded_tp): Allocate with new.
8684 (free_uploaded_tps): Free with delete.
8685 (parse_tracepoint_definition): Adjust to std::vector change.
8686 * breakpoint.c (read_uploaded_action): Likewise.
8687 (create_tracepoint_from_upload): Likewise.
8688 * ctf.c (ctf_write_uploaded_tp): Likewise.
8689 (SET_ARRAY_FIELD): Likewise.
8690 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
8691
8692 2018-03-30 Tom Tromey <tom@tromey.com>
8693
8694 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
8695 std::unique_ptr.
8696 (svr4_keep_data_in_core): Update.
8697 (svr4_read_so_list): Update.
8698
8699 2018-03-30 Tom Tromey <tom@tromey.com>
8700
8701 * windows-nat.c (handle_output_debug_string, handle_exception):
8702 Update.
8703 * target.h (target_read_string): Update.
8704 * target.c (target_read_string): Change "string" to
8705 unique_xmalloc_ptr.
8706 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
8707 Update.
8708 * solib-frv.c (frv_current_sos): Update.
8709 * solib-dsbt.c (dsbt_current_sos): Update.
8710 * solib-darwin.c (darwin_current_sos): Update.
8711 * linux-thread-db.c (inferior_has_bug): Update.
8712 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
8713 Update. Remove alloca.
8714 * ada-lang.c (ada_main_name): Update.
8715
8716 2018-03-30 Tom Tromey <tom@tromey.com>
8717
8718 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
8719 (struct dwo_file_deleter): New.
8720 (dwo_file_up): New typedef.
8721 (open_and_init_dwo_file): Use dwo_file_up.
8722 (free_dwo_file_cleanup): Remove.
8723
8724 2018-03-30 Tom Tromey <tom@tromey.com>
8725
8726 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
8727 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
8728
8729 2018-03-30 Tom Tromey <tom@tromey.com>
8730
8731 * dwarf2read.c (class free_cached_comp_units): New class.
8732 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
8733 (free_cached_comp_units): Remove function.
8734
8735 2018-03-30 Tom Tromey <tom@tromey.com>
8736
8737 * utils.h (make_cleanup_unpush_target): Remove.
8738 * inf-ptrace.c (struct target_unpusher): New.
8739 (target_unpush_up) New typedef.
8740 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
8741 target_unpush_up.
8742 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
8743
8744 2018-03-27 Tom Tromey <tom@tromey.com>
8745
8746 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
8747
8748 2018-03-27 Pedro Alves <palves@redhat.com>
8749 Tom Tromey <tom@tromey.com>
8750
8751 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
8752 destructor. Now a class.
8753 (gdb_readline_wrapper_cleanup): Remove function.
8754 (gdb_readline_wrapper): Remove cleanups.
8755
8756 2018-03-27 Tom Tromey <tom@tromey.com>
8757
8758 * typeprint.h (struct type_print_options) <local_typedefs,
8759 global_typedefs>: Remove "struct" keyword.
8760 (class typedef_hash_table): New class.
8761 (recursively_update_typedef_hash, add_template_parameters)
8762 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
8763 (find_typedef_in_hash): Don't declare.
8764 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
8765 (typedef_hash_table::recursively_update): Rename from
8766 recursively_update_typedef_hash. Now a member.
8767 (typedef_hash_table::add_template_parameters): Rename from
8768 add_template_parameters. Now a member.
8769 (typedef_hash_table::typedef_hash_table): Now a constructor;
8770 rename from create_typedef_hash.
8771 (typedef_hash_table::~typedef_hash_table): Now a destructor;
8772 rename from free_typedef_hash.
8773 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
8774 (do_free_global_table): Remove.
8775 (typedef_hash_table::typedef_hash_table): New constructor; renamed
8776 from copy_type_recursive.
8777 (create_global_typedef_table): Remove.
8778 (typedef_hash_table::find_global_typedef): Now a member of
8779 typedef_hash_table.
8780 (typedef_hash_table::find_typedef): Rename from
8781 find_typedef_in_hash; now a member.
8782 (whatis_exp): Update.
8783 * extension.h (struct ext_lang_type_printers): Add constructor and
8784 destructor.
8785 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
8786 declare.
8787 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
8788 Now a constructor; rename from start_ext_lang_type_printers.
8789 (ext_lang_type_printers): Now a destructor; rename from
8790 free_ext_lang_type_printers.
8791 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
8792 Update.
8793 (c_type_print_base_struct_union): Update. Remove cleanups.
8794
8795 2018-03-27 Tom Tromey <tom@tromey.com>
8796
8797 * dwarf-index-write.c: Include <cmath>.
8798
8799 2018-03-27 Joel Brobecker <brobecker@adacore.com>
8800
8801 * NEWS: Add entry describing new "set|show varsize-limit" command.
8802 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
8803 command.
8804 * printcmd.c (_initialize_printcmd): Add "set var" alias of
8805 "set variable".
8806
8807 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
8808
8809 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
8810 dwarf-index-write.c
8811 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
8812 * dwarf-index-common.c: New file.
8813 * dwarf-index-common.h: New file.
8814 * dwarf-index-write.c: New file.
8815 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
8816 (struct dwarf2_section_info): Move from here.
8817 (dwarf2_section_info_def): Likewise.
8818 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
8819 (offset_type): Likewise.
8820 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
8821 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
8822 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
8823 (byte_swap): Likewise.
8824 (MAYBE_SWAP): Likewise.
8825 (dwarf2_per_cu_ptr): Likewise.
8826 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
8827 (struct tu_stats): Likewise.
8828 (struct dwarf2_per_objfile): Likewise.
8829 (struct dwarf2_per_cu_data): Likewise.
8830 (struct signatured_type): Likewise.
8831 (sig_type_ptr): Likewise.
8832 (DEF_VEC_P (sig_type_ptr)): Likewise.
8833 (INDEX4_SUFFIX): Likewise.
8834 (INDEX5_SUFFIX): Likewise.
8835 (DEBUG_STR_SUFFIX): Likewise.
8836 (dwarf2_read_section): Make non-static.
8837 (mapped_index_string_hash): Move from here.
8838 (dwarf5_djb_hash): Likewise.
8839 (file_write): Likewise.
8840 (class data_buf): Likewise.
8841 (struct symtab_index_entry): Likewise.
8842 (struct mapped_symtab): Likewise.
8843 (find_slot): Likewise.
8844 (hash_expand): Likewise.
8845 (add_index_entry): Likewise.
8846 (uniquify_cu_indices): Likewise.
8847 (class c_str_view): Likewise.
8848 (class c_str_view_hasher): Likewise.
8849 (class vector_hasher): Likewise.
8850 (write_hash_table): Likewise.
8851 (psym_index_map): Likewise.
8852 (struct addrmap_index_data): Likewise.
8853 (add_address_entry): Likewise.
8854 (add_address_entry_worker): Likewise.
8855 (write_address_map): Likewise.
8856 (symbol_kind): Likewise.
8857 (write_psymbols): Likewise.
8858 (struct signatured_type_index_data): Likewise.
8859 (write_one_signatured_type): Likewise.
8860 (recursively_count_psymbols): Likewise.
8861 (recursively_write_psymbols): Likewise.
8862 (class debug_names): Likewise.
8863 (check_dwarf64_offsets): Likewise.
8864 (psyms_seen_size): Likewise.
8865 (write_gdbindex): Likewise.
8866 (write_debug_names): Likewise.
8867 (assert_file_size): Likewise.
8868 (write_psymtabs_to_index): Likewise.
8869 (save_gdb_index_command): Likewise.
8870 (_initialize_dwarf2_read): Don't register the "save gdb-index"
8871 command.
8872 * dwarf2read.h: New file.
8873
8874 2018-03-27 Joel Brobecker <brobecker@adacore.com>
8875
8876 PR gdb/22670
8877 * dwarf2read.c (dwarf2_physname): Do not return the demangled
8878 symbol name if the CU's language stores symbol names in linkage
8879 format.
8880 * language.h (struct language_defn)
8881 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
8882 all instances of this struct.
8883
8884 2018-03-26 Tom Tromey <tom@tromey.com>
8885
8886 * stack.c (backtrace_command_1): Remove verbose code.
8887
8888 2018-03-26 Tom Tromey <tom@tromey.com>
8889
8890 * python/py-framefilter.c (py_print_type): Don't catch
8891 exceptions. Return void.
8892 (py_print_value): Likewise.
8893 (py_print_single_arg): Likewise.
8894 (enumerate_args): Don't catch exceptions.
8895 (py_print_args): Likewise.
8896 (py_print_frame): Likewise.
8897 (gdbpy_apply_frame_filter): Catch exceptions here.
8898
8899 2018-03-26 Tom Tromey <tom@tromey.com>
8900
8901 * stack.c (_initialize_stack): Remove trailing newlines from help
8902 text. Add "Usage" line to "backtrace" help.
8903
8904 2018-03-26 Tom Tromey <tom@tromey.com>
8905
8906 PR python/16486:
8907 * python/py-framefilter.c (py_print_args): Call wrap_hint.
8908
8909 2018-03-26 Tom Tromey <tom@tromey.com>
8910
8911 * python/py-framefilter.c (py_print_single_arg): Return
8912 EXT_LANG_BT_ERROR from catch.
8913
8914 2018-03-26 Tom Tromey <tom@tromey.com>
8915
8916 PR backtrace/15584:
8917 * stack.c (backtrace_command_1): Move some code into no-filters
8918 "if".
8919
8920 2018-03-26 Tom Tromey <tom@tromey.com>
8921
8922 * python/py-framefilter.c (throw_quit_or_print_exception): New
8923 function.
8924 (gdbpy_apply_frame_filter): Use it.
8925
8926 2018-03-26 Tom Tromey <tom@tromey.com>
8927
8928 PR cli/17716:
8929 * python/py-framefilter.c (py_print_type, py_print_value)
8930 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
8931 RETURN_MASK_ERROR.
8932
8933 2018-03-26 Tom Tromey <tom@tromey.com>
8934
8935 * python/py-framefilter.c (enumerate_args): Use
8936 gdb::unique_xmalloc_ptr.
8937
8938 2018-03-26 Tom Tromey <tom@tromey.com>
8939
8940 * python/py-framefilter.c (py_print_frame): Return
8941 EXT_LANG_BT_OK.
8942 (gdbpy_apply_frame_filter): Update comment.
8943 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
8944 Remove.
8945 <EXT_LANG_BT_NO_FILTERS>: Change value.
8946
8947 2018-03-26 Tom Tromey <tom@tromey.com>
8948
8949 PR backtrace/15582:
8950 * stack.c (backtrace_command): Parse "hide" argument.
8951 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
8952 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
8953 constant.
8954
8955 2018-03-26 Tom Tromey <tom@tromey.com>
8956
8957 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
8958 add "flags".
8959 (backtrace_command): Remove "fulltrace", add "flags".
8960
8961 2018-03-26 Tom Tromey <tom@tromey.com>
8962
8963 * stack.c (backtrace_command): Rewrite command line parsing.
8964
8965 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8966
8967 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
8968
8969 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8970
8971 * filename-seen-cache.h: Add include guard.
8972
8973 2018-03-26 Keith Seitz <keiths@redhat.com>
8974
8975 * symfile.c (place_section): Remove "struct" from section_addr_info
8976 in comment.
8977 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
8978 "struct" keyword from section_addr_info.
8979
8980 2018-03-26 Alan Hayward <alan.hayward@arm.com>
8981
8982 * regformats/regdef.h (reg): Add constructors.
8983
8984 2018-03-25 Pedro Alves <palves@redhat.com>
8985
8986 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
8987 if then/else bodies in var_func_name extraction.
8988
8989 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
8990
8991 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
8992 lookup_minimal_symbol() to find symbol entry.
8993 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
8994
8995 2018-03-23 Keith Seitz <keiths@redhat.com>
8996
8997 PR c++/22968
8998 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
8999 nested type definitions for C++, too.
9000
9001 2018-03-23 Tom Tromey <tom@tromey.com>
9002
9003 * machoread.c (struct oso_el): Add a constructor. Don't define as
9004 a typedef.
9005 (macho_register_oso): Remove.
9006 (macho_symtab_read): Take a std::vector.
9007 (oso_el_compare_name): Now a std::sort comparator.
9008 (macho_symfile_read_all_oso): Take a std::vector.
9009 (macho_symfile_read): Use std::vector. Remove cleanups.
9010
9011 2018-03-22 Tom Tromey <tom@tromey.com>
9012
9013 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
9014 (record_full_goto_bookmark): Use std::string.
9015
9016 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9017
9018 PR tdep/18295
9019 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
9020 a single mask.
9021
9022 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9023
9024 * rs6000-tdep.c (store_insn_p): New function.
9025 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
9026 and cr_reg to their unshifted values. Use store_insn_p to
9027 match LR saves using either R1 or fdata->alloca_reg. Use
9028 store_insn_p to match CR saves. Set alloca_reg_offset
9029 when alloca_reg and framep are set. Remove lr_reg shift
9030 when assigning to fdata->lr_register.
9031
9032 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
9033
9034 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
9035 command line args instead of emitting a warning.
9036
9037 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
9038
9039 * tracepoint.h (struct static_tracepoint_marker): Initialize
9040 fields, define default constructor, move constructor and move
9041 assignment, disable the rest.
9042 <str_id, extra>: Make std::string.
9043 (release_static_tracepoint_marker): Remove.
9044 (free_current_marker): Remove.
9045 * tracepoint.c (free_current_marker): Remove.
9046 (parse_static_tracepoint_marker_definition): Adjust to
9047 std::string, use new hex2str overload.
9048 (release_static_tracepoint_marker): Remove.
9049 (print_one_static_tracepoint_marker): Get marker by reference
9050 and adjust to std::string.
9051 (info_static_tracepoint_markers_command): Adjust to std::vector
9052 changes
9053 * target.h (static_tracepoint_marker_p): Remove typedef.
9054 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
9055 (struct target_ops) <to_static_tracepoint_marker_at>: Return
9056 bool.
9057 <to_static_tracepoint_markers_by_strid>: Return std::vector.
9058 * target-debug.h
9059 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
9060 (target_debug_print_std_vector_static_tracepoint_marker): New.
9061 (target_debug_print_struct_static_tracepoint_marker_p): Rename
9062 to...
9063 (target_debug_print_static_tracepoint_marker_p): ... this.
9064 * target-delegates.c: Re-generate.
9065 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
9066 Make std::string.
9067 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
9068 (decode_static_tracepoint_spec): Adjust to std::vector.
9069 (tracepoint_print_one_detail): Adjust to std::string.
9070 (strace_marker_decode_location): Adjust to std::string.
9071 (update_static_tracepoint): Adjust to std::string, remove call
9072 to release_static_tracepoint_marker.
9073 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
9074 Adjust to std::vector.
9075 * remote.c (remote_static_tracepoint_marker_at): Return bool.
9076 (remote_static_tracepoint_markers_by_strid): Adjust to
9077 std::vector.
9078 * common/rsp-low.h (hex2str): New overload with explicit count
9079 of bytes.
9080 * common/rsp-low.c (hex2str): New overload with explicit count
9081 of bytes.
9082 * unittests/rsp-low-selftests.c (test_hex2str): New function.
9083 (_initialize_rsp_low_selftests): Add test_hex2str test.
9084 * unittests/tracepoint-selftests.c
9085 (test_parse_static_tracepoint_marker_definition): Adjust to
9086 std::string.
9087
9088 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
9089
9090 * tracepoint.c (parse_static_tracepoint_marker_definition):
9091 Consider case where the definition is followed by more
9092 definitions.
9093 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9094 tracepoint-selftests.c.
9095 * unittests/tracepoint-selftests.c: New.
9096
9097 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9098
9099 * MAINTAINERS (Write After Approval): Add Pedro Franco de
9100 Carvalho.
9101
9102 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
9103
9104 * symtab.c (find_pc_sect_line): fixed indentation.
9105
9106 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
9107
9108 * symtab.c (find_pc_sect_line): now uses binary search.
9109
9110 2018-03-19 Tom Tromey <tom@tromey.com>
9111
9112 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
9113 "IDENT" production.
9114
9115 2018-03-19 Pedro Alves <palves@redhat.com>
9116 Tom Tromey <tom@tromey.com>
9117
9118 * unittests/observable-selftests.c: New file.
9119 * common/observable.h: New file.
9120 * observable.h: New file.
9121 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
9122 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
9123 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
9124 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
9125 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
9126 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
9127 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
9128 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
9129 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
9130 python/py-breakpoint.c, python/py-finishbreakpoint.c,
9131 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
9132 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
9133 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
9134 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
9135 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
9136 tui/tui-interp.c, valops.c: Update all users.
9137 * tui/tui-hooks.c (tui_bp_created_observer)
9138 (tui_bp_deleted_observer, tui_bp_modified_observer)
9139 (tui_inferior_exit_observer, tui_before_prompt_observer)
9140 (tui_normal_stop_observer, tui_register_changed_observer):
9141 Remove.
9142 (tui_observers_token): New global.
9143 (attach_or_detach, tui_attach_detach_observers): New functions.
9144 (tui_install_hooks, tui_remove_hooks): Use
9145 tui_attach_detach_observers.
9146 * record-btrace.c (record_btrace_thread_observer): Remove.
9147 (record_btrace_thread_observer_token): New global.
9148 * observer.sh: Remove.
9149 * observer.c: Rename to observable.c.
9150 * observable.c (namespace gdb_observers): Define new objects.
9151 (observer_debug): Move into gdb_observers namespace.
9152 (struct observer, struct observer_list, xalloc_observer_list_node)
9153 (xfree_observer_list_node, generic_observer_attach)
9154 (generic_observer_detach, generic_observer_notify): Remove.
9155 (_initialize_observer): Update.
9156 Don't include observer.inc.
9157 * Makefile.in (generated_files): Remove observer.h, observer.inc.
9158 (clean mostlyclean): Likewise.
9159 (observer.h, observer.inc): Remove targets.
9160 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
9161 (COMMON_SFILES): Use observable.c, not observer.c.
9162 * .gitignore: Remove observer.h.
9163
9164 2018-03-18 Tom Tromey <tom@tromey.com>
9165
9166 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
9167 gdb::def_vector.
9168 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
9169
9170 2018-03-17 Tom Tromey <tom@tromey.com>
9171
9172 * auto-load.c (auto_load_objfile_script_1): Use std::string.
9173
9174 2018-03-17 Tom Tromey <tom@tromey.com>
9175
9176 * target.c (class scoped_target_fd): New.
9177 (target_fileio_close_cleanup): Remove.
9178 (target_fileio_read_alloc_1): Use scoped_target_fd.
9179
9180 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
9181
9182 * silent-rules.mk: New.
9183 * Makefile.in: Include silent-rules.mk
9184 (srcdir, VPATH, top_srcdir): Move up.
9185 (COMPILE): Add ECHO_CXX.
9186 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
9187 (init.c): Add ECHO_INIT_C.
9188 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
9189 (version.c): Add ECHO_GEN.
9190 (printcmd.o): Add ECHO_CXX.
9191 (target-float.o): Add ECHO_CXX.
9192 (ada-exp.o): Add ECHO_CXX.
9193 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
9194 (insight$(EXEEXT)): Add ECHO_CXXLD.
9195 * gnulib/configure.ac: Add AM_SILENT_RULES.
9196 * gnulib/aclocal.m4: Re-generate.
9197 * gnulib/configure: Re-generate.
9198 * gnulib/import/Makefile.in: Re-generate.
9199
9200 2018-03-16 Tom Tromey <tom@tromey.com>
9201
9202 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
9203 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
9204 * utils.c (do_free_section_addr_info)
9205 (make_cleanup_free_section_addr_info): Remove.
9206 * symfile.h (struct other_sections): Add constructor.
9207 (struct section_addr_info): Remove.
9208 (section_addr_info): New typedef.
9209 (struct sym_fns) <sym_offsets>: Change type of parameter.
9210 (build_section_addr_info_from_objfile)
9211 (relative_addr_info_to_section_offsets, addr_info_make_relative)
9212 (default_symfile_offsets, symbol_file_add)
9213 (symbol_file_add_from_bfd)
9214 (build_section_addr_info_from_section_table): Update.
9215 (alloc_section_addr_info, free_section_addr_info): Don't declare.
9216 * symfile.c (alloc_section_addr_info): Remove.
9217 (build_section_addr_info_from_section_table): Change return type.
9218 Update.
9219 (build_section_addr_info_from_bfd)
9220 (build_section_addr_info_from_objfile): Likewise.
9221 (free_section_addr_info): Remove.
9222 (relative_addr_info_to_section_offsets): Change type of "addrs".
9223 (addrs_section_compar): Now a std::sort comparator.
9224 (addrs_section_sort): Change return type.
9225 (addr_info_make_relative): Change type of "addrs". Update.
9226 (default_symfile_offsets, syms_from_objfile_1)
9227 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
9228 (symbol_file_add_separate): Update.
9229 (symbol_file_add): Change type of "addrs". Update.
9230 (add_symbol_file_command): Update. Remove cleanups.
9231 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
9232 cleanups.
9233 * symfile-debug.c (debug_sym_offsets): Change type of "info".
9234 * solib.c (solib_read_symbols): Update.
9235 * objfiles.c (objfile_relocate): Update. Remove cleanups.
9236 * machoread.c (macho_symfile_offsets): Update.
9237 * jit.c (jit_bfd_try_read_symtab): Update.
9238
9239 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
9240
9241 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9242 unittests/utils-selftests.c.
9243 * unittests/utils-selftests.c: New file.
9244
9245 2018-03-14 Tom Tromey <tom@tromey.com>
9246
9247 PR cli/14977:
9248 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
9249 for NULL.
9250
9251 2018-03-14 Tom Tromey <tom@tromey.com>
9252
9253 PR cli/19918:
9254 * printcmd.c (printf_pointer): Allow "-" in format.
9255
9256 2018-03-14 Tom Tromey <tom@tromey.com>
9257
9258 * printcmd.c (_initialize_printcmd): Add usage to printf.
9259
9260 2018-03-14 Yao Qi <qiyao@sourceware.org>
9261
9262 * MAINTAINERS: Update my email address.
9263
9264 2018-03-13 Tom Tromey <tom@tromey.com>
9265
9266 * machoread.c (macho_check_dsym): Change filenamep to a
9267 std::string*.
9268 (macho_symfile_read): Update.
9269 * symfile.c (load_command): Use std::string.
9270
9271 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
9272
9273 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
9274 to error message string.
9275 (riscv_register_name): Use xsnprintf instead of sprintf.
9276 (riscv_insn::fetch_instruction): Use gdb_assert instead of
9277 internal_error.
9278 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
9279 error.
9280 (riscv_push_dummy_call): Likewise.
9281
9282 2018-03-12 Tom Tromey <tom@tromey.com>
9283
9284 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
9285 Use gdb::byte_vector.
9286 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
9287
9288 2018-03-12 Yao Qi <yao.qi@linaro.org>
9289
9290 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
9291 parameter type to readable_regcache.
9292 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
9293 the declaration.
9294
9295 2018-03-11 Tom Tromey <tom@tromey.com>
9296
9297 * dwarf2read.c (struct nextfield): Add initializers.
9298 (struct nextfnfield): Remove.
9299 (struct fnfieldlist): Add initializers. Remove "length" and
9300 "head", use std::vector.
9301 (struct decl_field_list): Remove.
9302 (struct field_info): Add initializers.
9303 <fields, baseclasses>: Now std::vector.
9304 <nbaseclasses, nfnfields, typedef_field_list_count,
9305 nested_types_list_count>: Remove.
9306 (dwarf2_add_field, dwarf2_add_type_defn)
9307 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
9308 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
9309 (process_structure_scope): Update.
9310
9311 2018-03-11 Tom Tromey <tom@tromey.com>
9312
9313 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
9314 for use by std::sort.
9315 (build_type_psymtabs_1): Use std::vector.
9316
9317 2018-03-09 Eli Zaretskii <eliz@gnu.org>
9318
9319 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
9320 and LIBMPFR in the printed configuration.
9321
9322 2018-03-08 Tom Tromey <tom@tromey.com>
9323
9324 * source.c (get_filename_and_charpos): Use scoped_fd.
9325 * nto-procfs.c (procfs_open_1): Use scoped_fd.
9326 (procfs_pidlist): Likewise.
9327 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
9328 (iterate_over_mappings): Likewise.
9329
9330 2018-03-08 Tom Tromey <tom@tromey.com>
9331
9332 * infcall.c (struct call_return_meta_info)
9333 <stack_temporaries_enabled>: Remove.
9334 (get_call_return_value, call_function_by_hand_dummy): Update.
9335 * thread.c (disable_thread_stack_temporaries): Remove.
9336 (enable_thread_stack_temporaries): Remove.
9337 (thread_stack_temporaries_enabled_p): Return bool.
9338 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
9339 (get_last_thread_stack_temporary): Update.
9340 * eval.c (evaluate_subexp): Update.
9341 * gdbthread.h (class enable_thread_stack_temporaries): Now a
9342 class, not a function.
9343 (value_ptr, value_vec): Remove typedefs.
9344 (class thread_info) <stack_temporaries_enabled>: Now bool.
9345 <stack_temporaries>: Now a std::vector.
9346 (thread_stack_temporaries_enabled_p)
9347 (value_in_thread_stack_temporaries): Return bool.
9348
9349 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
9350
9351 * remote.c (putpkt_binary): Fix omitted bytes reporting.
9352 (getpkt_or_notif_sane_1): Likewise.
9353
9354 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9355
9356 * build-id.c (build_id_to_debug_bfd): Use std::string.
9357
9358 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9359
9360 * build-id.c (find_separate_debug_file_by_buildid): Return
9361 std::string.
9362 * build-id.h (find_separate_debug_file_by_buildid): Return
9363 std::string.
9364 * coffread.c (coff_symfile_read): Adjust to std::string.
9365 * elfread.c (elf_symfile_read): Adjust to std::string.
9366 * symfile.c (separate_debug_file_exists): Change parameter to
9367 std::string.
9368 (find_separate_debug_file): Return std::string.
9369 (find_separate_debug_file_by_debuglink): Return std::string.
9370 * symfile.h (find_separate_debug_file_by_debuglink): Return
9371 std::string.
9372
9373 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9374
9375 * common/xml-utils.c (xml_escape_text): Move code to...
9376 (xml_escape_text_append): ... this new function.
9377 * common/xml-utils.h (xml_escape_text_append): New declaration.
9378 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
9379 New function.
9380 (_initialize_xml_utils): register test_xml_escape_text_append as
9381 a selftest.
9382
9383 2018-03-07 Alan Hayward <alan.hayward@arm.com>
9384
9385 * defs.h: Remove MAX_REGISTER_SIZE.
9386 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
9387 asserts.
9388 * python/py-unwind.c (pyuw_sniffer): Likewise.
9389
9390 2018-03-07 Tom Tromey <tom@tromey.com>
9391
9392 * linux-tdep.c (linux_info_proc): Update.
9393 * target.h (struct target_ops) <to_fileio_readlink>: Return
9394 optional<string>.
9395 (target_fileio_readlink): Return optional<string>.
9396 * remote.c (remote_hostio_readlink): Return optional<string>.
9397 * inf-child.c (inf_child_fileio_readlink): Return
9398 optional<string>.
9399 * target.c (target_fileio_readlink): Return optional<string>.
9400
9401 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
9402
9403 * regcache.c (cooked_read_test): Add riscv to the list of
9404 architectures that have a save_reggroup.
9405
9406 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
9407
9408 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
9409 value is not a dynamic class object.
9410
9411 2018-03-06 Tom Tromey <tom@tromey.com>
9412
9413 * rust-exp.y: Formatting fixes.
9414
9415 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9416
9417 * riscv-tdep.c (riscv_register_name): Remove target description
9418 support.
9419 (riscv_gdbarch_init): Remove target description check.
9420
9421 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9422
9423 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
9424 comment.
9425 * riscv-tdep.h: Likewise.
9426
9427 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9428
9429 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
9430 (riscv_pseudo_register_write): Delete.
9431 (riscv_gdbarch_init): Remove all use of pseudo registers.
9432
9433 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9434
9435 * record-btrace.c (btrace_print_lines): Replace cleanup
9436 parameter with RAII equivalents.
9437 (btrace_insn_history): Replace cleanup with RAII equivalents.
9438 * ui-out.h (make_cleanup_ui_out_list_begin_end,
9439 make_cleanup_ui_out_tuple_begin_end): Remove.
9440 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
9441 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
9442 make_cleanup_ui_out_list_begin_end): Remove.
9443
9444 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9445
9446 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
9447 parameter types to std::vector. Use bool.
9448 (record_btrace_wait): Replace VEC(tp_t) with
9449 std::vector<thread_info *>.
9450 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
9451
9452 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9453
9454 * record-btrace.c (record_btrace_disable_callback): Remove.
9455 (struct scoped_btrace_disable): New.
9456 (record_btrace_open): Use scoped_btrace_disable.
9457
9458 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9459
9460 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
9461 reading values from registers.
9462
9463 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9464
9465 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
9466 where appropriate.
9467
9468 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9469
9470 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
9471 change parameter type. Use GDB's print functions, and use
9472 core_addr_to_string where appropriate.
9473 (riscv_push_dummy_call): Use core_addr_to_string where
9474 appropriate, update call to riscv_print_arg_location, and reindent
9475 a few lines.
9476 (riscv_return_value): Update call to riscv_print_arg_location.
9477
9478 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9479 Tim Newsome <tim@sifive.com>
9480 Albert Ou <a0u@eecs.berkeley.edu>
9481 Darius Rad <darius@bluespec.com>
9482
9483 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
9484 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
9485 (ALLDEPFILES): Add riscv-tdep.c
9486 * configure.tgt: Add riscv support.
9487 * riscv-tdep.c: New file.
9488 * riscv-tdep.h: New file.
9489 * NEWS: Mention new target.
9490 * MAINTAINERS: Add entry for riscv.
9491
9492 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9493
9494 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
9495 fields within aggregates.
9496
9497 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
9498
9499 * record-btrace.c (btrace_print_lines): Change type of flags to
9500 gdb_disassembly_flags.
9501
9502 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9503
9504 * fbsd-nat.c: Include "inf-ptrace.h".
9505 (USE_SIGTRAP_SIGINFO): Conditionally define.
9506 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
9507 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
9508 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
9509 function.
9510 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
9511 Likewise.
9512 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
9513 Likewise.
9514 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
9515 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
9516 "supports_stopped_by_hw_breakpoint" target methods.
9517
9518 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9519
9520 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
9521 * fbsd-nat.c (debug_fbsd_nat): New variable.
9522 (show_fbsd_nat_debug): New function.
9523 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
9524 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
9525
9526 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9527
9528 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
9529 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
9530 prototype.
9531 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
9532 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
9533 method.
9534
9535 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9536
9537 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
9538 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
9539
9540 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9541
9542 * charset.c (struct charset_vector): New.
9543 (charsets): Change type to charset_vector.
9544 (find_charset_names): Adjust.
9545 (add_one): Adjust.
9546 (_initialize_charset): Adjust.
9547
9548 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9549
9550 * progspace.h (struct program_space) <deleted_solibs>: Change
9551 type to std::vector<std::string>.
9552 * progspace.c (clear_program_space_solib_cache): Adjust.
9553 * breakpoint.c (print_solib_event): Adjust.
9554 (check_status_catch_solib): Adjust.
9555 * solib.c (update_solib_list): Adjust.
9556 * ui-out.h (class ui_out) <field_string>: New overload.
9557 * ui-out.c (ui_out::field_string): New overload.
9558
9559 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9560
9561 * progspace.h (struct program_space): Add constructor and
9562 destructor, initialize fields.
9563 (add_program_space): Remove.
9564 * progspace.c (add_program_space): Rename to...
9565 (program_space::program_space): ... this.
9566 (release_program_space): Rename to...
9567 (program_space::~program_space): ... this.
9568 (delete_program_space): Use delete to delete program_space.
9569 (initialize_progspace): Use new to allocate program_space.
9570 * inferior.c (add_inferior_with_spaces): Likewise.
9571 (clone_inferior_command): Likewise.
9572 * infrun.c (follow_fork_inferior): Likewise.
9573 (handle_vfork_child_exec_or_exit): Likewise.
9574
9575 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9576
9577 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
9578 (delim_string_to_char_ptr_vec): Return std::vector of
9579 gdb::unique_xmalloc_ptr.
9580 (dirnames_to_char_ptr_vec_append): Take std::vector of
9581 gdb::unique_xmalloc_ptr.
9582 (dirnames_to_char_ptr_vec): Return std::vector of
9583 gdb::unique_xmalloc_ptr.
9584 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
9585 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
9586 (delim_string_to_char_ptr_vec): Return an std::vector of
9587 gdb::unique_xmalloc_ptr, adjust the code.
9588 (dirnames_to_char_ptr_vec_append): Take an std::vector of
9589 gdb::unique_xmalloc_ptr, adjust the code.
9590 (dirnames_to_char_ptr_vec): Return an std::vector of
9591 gdb::unique_xmalloc_ptr, adjust the code.
9592 * auto-load.c (auto_load_safe_path_vec): Change type to
9593 std::vector of gdb::unique_xmalloc_ptr.
9594 (auto_load_expand_dir_vars): Return an std::vector of
9595 gdb::unique_xmalloc_ptr, adjust the code.
9596 (auto_load_safe_path_vec_update): Adjust.
9597 (filename_is_in_auto_load_safe_path_vec): Adjust.
9598 (auto_load_objfile_script_1): Adjust.
9599 * build-id.c (build_id_to_debug_bfd): Adjust.
9600 * linux-thread-db.c (thread_db_load_search): Adjust.
9601 * source.c (add_path): Adjust.
9602 (openp): Adjust.
9603 * symfile.c (find_separate_debug_file): Adjust.
9604 * utils.c (do_free_char_ptr_vec): Remove.
9605 (make_cleanup_free_char_ptr_vec): Remove.
9606
9607 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
9608
9609 PR gdb/22907
9610 * common/pathstuff.c: Conditionally include "<windows.h>".
9611
9612 2018-03-01 Georg Sauthoff <mail@georg.so>
9613
9614 PR gdb/22888
9615 * gcore.in: Quote variables and switch interpreter to bash.
9616
9617 2018-03-01 Tom Tromey <tom@tromey.com>
9618
9619 * dwarf2read.c (alloc_discriminant_info): Fix default_index
9620 assertion. Add assertion for discriminant_index.
9621 (quirk_rust_enum): Use correct base type name in univariant case.
9622
9623 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
9624
9625 * record.c (get_call_history_modifiers): Return a
9626 record_print_flags.
9627 (cmd_record_call_history): Adjust.
9628 * record-btrace.c (record_btrace_call_history): Adjust.
9629 (record_btrace_call_history_range): Adjust.
9630 (record_btrace_call_history_from): Adjust.
9631 * target-debug.h (target_debug_print_record_print_flags): New.
9632 * target-delegates.c: Re-generate.
9633 * target.c (target_call_history): Change flags type.
9634 (target_call_history_from): Likewise.
9635 (target_call_history_range): Likewise.
9636 * target.h (struct target_ops) <target_call_history>: Likewise.
9637 (target_call_history_from): Likewise.
9638 (target_call_history_range): Likewise.
9639
9640 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
9641 Simon Marchi <simon.marchi@polymtl.ca>
9642
9643 * common/common-utils.c: Include "sys/stat.h".
9644 (is_regular_file): Move here from "source.c"; change return
9645 type to "bool".
9646 * common/common-utils.h (is_regular_file): New prototype.
9647 * common/pathstuff.c (contains_dir_separator): New function.
9648 * common/pathstuff.h (contains_dir_separator): New prototype.
9649 * source.c: Don't include "sys/stat.h".
9650 (is_regular_file): Move to "common/common-utils.c".
9651
9652 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
9653
9654 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
9655 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
9656 * auto-load.c: Include "common/pathstuff.h".
9657 * common/common-def.h (current_directory): Move here.
9658 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
9659 function.
9660 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
9661 prototype.
9662 * common/pathstuff.c: New file.
9663 * common/pathstuff.h: New file.
9664 * compile/compile.c: Include "common/pathstuff.h".
9665 * defs.h (current_directory): Move to "common/common-defs.h".
9666 * dwarf2read.c: Include "common/pathstuff.h".
9667 * exec.c: Likewise.
9668 * guile/scm-safe-call.c: Likewise.
9669 * linux-thread-db.c: Likewise.
9670 * main.c: Likewise.
9671 * nto-tdep.c: Likewise.
9672 * objfiles.c: Likewise.
9673 * source.c: Likewise.
9674 * symtab.c: Likewise.
9675 * utils.c: Include "common/pathstuff.h".
9676 (gdb_realpath): Move to "common/pathstuff.c".
9677 (gdb_realpath_keepfile): Likewise.
9678 (gdb_abspath): Likewise.
9679 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
9680 (gdb_realpath_keepfile): Likewise.
9681 (gdb_abspath): Likewise.
9682
9683 2018-02-28 John Baldwin <jhb@FreeBSD.org>
9684
9685 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
9686 wildcard process pid for super_resume for kernels with a
9687 specific bug.
9688
9689 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
9690
9691 * compile/compile.c (get_args): Add additional comments
9692 explaining function.
9693
9694 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
9695 Tom Tromey <tom@tromey.com>
9696
9697 * target.h (memory_write_request_s): Remove typedef. Don't define
9698 VEC.
9699 (target_write_memory_blocks): Change argument to std::vector.
9700 (struct memory_write_request): Add constructor.
9701 * target-memory.c (compare_block_starting_address): Return bool.
9702 Change argument types.
9703 (claim_memory): Change arguments to use std::vector.
9704 (split_regular_and_flash_blocks, blocks_to_erase)
9705 (compute_garbled_blocks): Likewise.
9706 (cleanup_request_data, cleanup_write_requests_vector): Remove.
9707 (target_write_memory_blocks): Change argument to std::vector.
9708 * symfile.c (struct load_section_data): Add constructor and
9709 destructor. Use std::vector for "requests".
9710 (struct load_progress_data): Add initializers.
9711 (load_section_callback): Update. Use "new".
9712 (clear_memory_write_data): Remove.
9713 (generic_load): Update.
9714
9715 2018-02-27 Alan Hayward <alan.hayward@arm.com>
9716
9717 * arch/aarch64.h: Use common/tdesc.h.
9718
9719 2018-02-26 Maciej W. Rozycki <macro@mips.com>
9720
9721 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
9722 architecture with a 64-bit ABI.
9723
9724 2018-02-26 Maciej W. Rozycki <macro@mips.com>
9725
9726 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
9727 ahead of target description loading.
9728
9729 2018-02-26 Tom Tromey <tom@tromey.com>
9730
9731 * stack.c (backtrace_command_1): Update.
9732 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
9733 of "flags".
9734 * python/py-framefilter.c (py_print_frame)
9735 (gdbpy_apply_frame_filter): Change type of "flags".
9736 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
9737 of "flags".
9738 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
9739 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
9740 * extension.h (enum frame_filter_flag): Rename from
9741 frame_filter_flags.
9742 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
9743 (apply_ext_lang_frame_filter): Change type of "flags".
9744 * extension.c (apply_ext_lang_frame_filter): Change type of
9745 "flags".
9746 * extension-priv.h (struct extension_language_ops)
9747 <apply_frame_filter>: Change type of "flags".
9748
9749 2018-02-26 Tom Tromey <tom@tromey.com>
9750
9751 PR python/16497:
9752 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
9753 off-by-one in py_end computation.
9754 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
9755 PRINT_MORE_FRAMES.
9756 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
9757 constant.
9758
9759 2018-02-26 Tom Tromey <tom@tromey.com>
9760
9761 * dwarf2read.c (struct variant_field): New.
9762 (struct nextfield) <variant>: New field.
9763 (dwarf2_add_field): Handle DW_TAG_variant_part.
9764 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
9765 discriminated union.
9766 (read_structure_type): Handle DW_TAG_variant_part.
9767 (handle_struct_member_die): New function, extracted from
9768 process_structure_scope. Handle DW_TAG_variant.
9769 (process_structure_scope): Handle discriminated unions. Call
9770 handle_struct_member_die.
9771
9772 2018-02-26 Tom Tromey <tom@tromey.com>
9773
9774 * rust-lang.h (rust_last_path_segment): Declare.
9775 * rust-lang.c (rust_last_path_segment): Now public. Change
9776 contract.
9777 (struct disr_info): Remove.
9778 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
9779 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
9780 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
9781 (rust_enum_p, rust_enum_variant): New function.
9782 (rust_underscore_fields): Remove "offset" parameter.
9783 (rust_print_enum): New function.
9784 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
9785 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
9786 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
9787 enums.
9788 (rust_internal_print_type): New function, from rust_print_type.
9789 Remove enum code.
9790 (rust_print_type): Call rust_internal_print_type.
9791 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
9792 Update enum handling.
9793 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
9794 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
9795 (rust_union_quirks): New functions.
9796 (process_full_comp_unit, process_full_type_unit): Call
9797 rust_union_quirks.
9798 (process_structure_scope): Update rust_unions if necessary.
9799
9800 2018-02-26 Tom Tromey <tom@tromey.com>
9801
9802 * value.h (value_union_variant): Declare.
9803 * valops.c (value_union_variant): New function.
9804 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
9805 (struct discriminant_info): New.
9806 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
9807 enumerator.
9808 (struct main_type) <flag_discriminated_union>: New field.
9809
9810 2018-02-26 Tom Tromey <tom@tromey.com>
9811
9812 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9813 unittests/unpack-selftests.c.
9814 * unittests/unpack-selftests.c: New file.
9815 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
9816
9817 2018-02-26 Yao Qi <yao.qi@linaro.org>
9818
9819 * dwarf2read.c (struct partial_die_info) <read>: New method.
9820 (read_partial_die): Remove the declaration.
9821 (load_partial_dies): Update.
9822 (partial_die_info::partial_die_info):
9823 (read_partial_die): Change it to partial_die_info::read.
9824
9825 2018-02-26 Yao Qi <yao.qi@linaro.org>
9826
9827 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
9828 (fixup_partial_die): Remove declaration.
9829 (scan_partial_symbols): Update.
9830 (partial_die_parent_scope): Likewise.
9831 (partial_die_full_name): Likewise.
9832 (fixup_partial_die): Change it to partial_die_info::fixup.
9833
9834 2018-02-26 Yao Qi <yao.qi@linaro.org>
9835
9836 * dwarf2read.c (read_partial_die): Update the declaration.
9837 (load_partial_dies): Caller update.
9838 (read_partial_die): Remove one argument abbrev_len.
9839
9840 2018-02-26 Yao Qi <yao.qi@linaro.org>
9841
9842 * dwarf2read.c (struct partial_die_info): Add ctor, delete
9843 assignment operator.
9844 (load_partial_dies): Use ctor and copy ctor.
9845 (read_partial_die): Update.
9846 (dwarf2_cu::find_partial_die): Use ctor.
9847
9848 2018-02-26 Yao Qi <yao.qi@linaro.org>
9849
9850 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
9851 (find_partial_die_in_comp_unit): Change it to
9852 dwarf2_cu::find_partial_die.
9853 (find_partial_die): Update.
9854
9855 2018-02-26 Yao Qi <yao.qi@linaro.org>
9856
9857 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
9858 is NULL.
9859
9860 2018-02-26 Yao Qi <yao.qi@linaro.org>
9861
9862 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
9863
9864 2018-02-26 Alan Hayward <alan.hayward@arm.com>
9865
9866 * arch/amd64.h: Use common/tdesc.h.
9867 * arch/i386.c: Likewise.
9868 * arch/i386.h: Likewise.
9869 * arch/tic6x.c: Likewise.
9870 * arch/tdesc.h: Move file from here...
9871 * common/tdesc.h: ...to here.
9872 * features/aarch64-core.c: Regenerate.
9873 * features/aarch64-fpu.c: Regenerate.
9874 * features/i386/32bit-avx.c: Regenerate.
9875 * features/i386/32bit-avx512.c: Regenerate.
9876 * features/i386/32bit-core.c: Regenerate.
9877 * features/i386/32bit-linux.c: Regenerate.
9878 * features/i386/32bit-mpx.c: Regenerate.
9879 * features/i386/32bit-pkeys.c: Regenerate.
9880 * features/i386/32bit-sse.c: Regenerate.
9881 * features/i386/64bit-avx.c: Regenerate.
9882 * features/i386/64bit-avx512.c: Regenerate.
9883 * features/i386/64bit-core.c: Regenerate.
9884 * features/i386/64bit-linux.c: Regenerate.
9885 * features/i386/64bit-mpx.c: Regenerate.
9886 * features/i386/64bit-pkeys.c: Regenerate.
9887 * features/i386/64bit-segments.c: Regenerate.
9888 * features/i386/64bit-sse.c: Regenerate.
9889 * features/i386/x32-core.c: Regenerate.
9890 * features/tic6x-c6xp.c: Regenerate.
9891 * features/tic6x-core.c: Regenerate.
9892 * features/tic6x-gp.c: Regenerate.
9893 * target-descriptions.c: Use common/tdesc.h.
9894 * target-descriptions.h: Likewise.
9895
9896 2018-02-24 Tom Tromey <tom@tromey.com>
9897
9898 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
9899 (try_thread_db_load_from_dir, thread_db_load_search): Use
9900 std::string.
9901 (info_auto_load_libthread_db_compare): Return bool. Change
9902 argument types.
9903 (info_auto_load_libthread_db): Use std::vector, std::string.
9904 Remove cleanups.
9905
9906 2018-02-24 Tom Tromey <tom@tromey.com>
9907
9908 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
9909 std::string.
9910 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
9911 std::string*.
9912 * gdbarch.c: Rebuild.
9913 * gdbarch.h: Rebuild.
9914 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
9915 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
9916 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
9917 std::string*.
9918
9919 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
9920
9921 * gdbtypes.h (sect_offset): Change type to uint64_t.
9922 (sect_offset_str): New function.
9923 * dwarf2read.c (create_addrmap_from_aranges): Use
9924 sect_offset_str.
9925 (error_check_comp_unit_head): Likewise.
9926 (create_debug_type_hash_table): Likewise.
9927 (read_cutu_die_from_dwo): Likewise.
9928 (init_cutu_and_read_dies): Likewise.
9929 (init_cutu_and_read_dies_no_follow): Likewise.
9930 (process_psymtab_comp_unit_reader): Likewise.
9931 (partial_die_parent_scope): Likewise.
9932 (peek_die_abbrev): Likewise.
9933 (process_queue): Likewise.
9934 (dwarf2_physname): Likewise.
9935 (read_namespace_alias): Likewise.
9936 (read_import_statement): Likewise.
9937 (create_dwo_cu_reader): Likewise.
9938 (create_cus_hash_table): Likewise.
9939 (lookup_dwo_cutu): Likewise.
9940 (inherit_abstract_dies): Likewise.
9941 (read_func_scope): Likewise.
9942 (read_call_site_scope): Likewise.
9943 (dwarf2_add_member_fn): Likewise.
9944 (read_common_block): Likewise.
9945 (read_module_type): Likewise.
9946 (read_typedef): Likewise.
9947 (read_subrange_type): Likewise.
9948 (load_partial_dies): Likewise.
9949 (read_partial_die): Likewise.
9950 (find_partial_die): Likewise.
9951 (read_str_index): Likewise.
9952 (dwarf2_string_attr): Likewise.
9953 (build_error_marker_type): Likewise.
9954 (lookup_die_type): Likewise.
9955 (dump_die_shallow): Likewise.
9956 (follow_die_ref): Likewise.
9957 (dwarf2_fetch_die_loc_sect_off): Likewise.
9958 (dwarf2_fetch_constant_bytes): Likewise.
9959 (follow_die_sig): Likewise.
9960 (get_signatured_type): Likewise.
9961 (get_DW_AT_signature_type): Likewise.
9962 (dwarf2_find_containing_comp_unit): Likewise.
9963 (set_die_type): Likewise.
9964
9965 2018-02-21 John Baldwin <jhb@FreeBSD.org>
9966
9967 * arch/aarch64.c: Include "common-defs.h".
9968 * arch/amd64.c: Likewise.
9969 * arch/i386.c: Likewise.
9970
9971 2018-02-21 Tom Tromey <tom@tromey.com>
9972
9973 * value.h: (extract_field_op): Update.
9974 * eval.c (extract_field_op): Return a const char *.
9975 * expression.h (parse_expression_for_completion): Update.
9976 * completer.c (complete_expression): Update.
9977 (add_struct_fields): Make fieldname const.
9978 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
9979 (mark_completion_tag, parse_exp_in_context_1): Update.
9980 (parse_expression_for_completion): Change "name" to
9981 unique_xmalloc_ptr*.
9982
9983 2018-02-21 Tom Tromey <tom@tromey.com>
9984
9985 * infcall.c (call_function_by_hand_dummy): Use std::vector.
9986
9987 2018-02-21 Yao Qi <yao.qi@linaro.org>
9988
9989 * avr-tdep.c (avr_read_pc): Change parameter type to
9990 readable_regcache.
9991 * gdbarch.sh (read_pc): Likewise.
9992 * gdbarch.c: Re-generated.
9993 * gdbarch.h: Re-generated.
9994 * hppa-tdep.c (hppa_read_pc): Change parameter type to
9995 readable_regcache.
9996 * ia64-tdep.c (ia64_read_pc): Likewise.
9997 * mips-tdep.c (mips_read_pc): Likewise.
9998 * spu-tdep.c (spu_read_pc): Likewise.
9999
10000 2018-02-21 Yao Qi <yao.qi@linaro.org>
10001
10002 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
10003 * regcache-dump.c: New file.
10004 * regcache.c: Move register_dump to regcache-dump.c.
10005 (maintenance_print_registers): Likewise.
10006 (maintenance_print_raw_registers): Likewise.
10007 (maintenance_print_cooked_registers): Likewise.
10008 (maintenance_print_register_groups): Likewise.
10009 (maintenance_print_remote_registers): Likewise.
10010 (_initialize_regcache): Likewise.
10011 * regcache.h (register_dump): Moved from regcache.c.
10012
10013 2018-02-21 Yao Qi <yao.qi@linaro.org>
10014
10015 * regcache.c (regcache::regcache): Update.
10016 (regcache::invalidate): Move it to detached_regcache::invalidate.
10017 (get_thread_arch_aspace_regcache): Update.
10018 (regcache::raw_update): Update.
10019 (regcache::cooked_read): Remove some code.
10020 (regcache::cooked_read_value): Likewise.
10021 (regcache::raw_write): Remove assert on m_readonly_p.
10022 (regcache::raw_supply_integer): Move it to
10023 detached_regcache::raw_supply_integer.
10024 (regcache::raw_supply_zeroed): Likewise.
10025 * regcache.h (detached_regcache) <raw_supply_integer>: New
10026 declaration.
10027 <raw_supply_zeroed, invalidate>: Likewise.
10028 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
10029 <invalidate>: Likewise.
10030 <m_readonly_p>: Removed.
10031
10032 2018-02-21 Yao Qi <yao.qi@linaro.org>
10033
10034 * infcmd.c (get_return_value): Let stop_regs point to
10035 get_current_regcache.
10036 * regcache.c (regcache::regcache): Remove.
10037 (register_dump_reg_buffer): New class.
10038 (regcache_print): Adjust.
10039 * regcache.h (regcache): Remove constructors.
10040
10041 2018-02-21 Yao Qi <yao.qi@linaro.org>
10042
10043 * regcache.c (class register_dump): New class.
10044 (register_dump_regcache, register_dump_none): New class.
10045 (register_dump_remote, register_dump_groups): New class.
10046 (regcache_print): Update.
10047 * regcache.h (regcache_dump_what): Move it to regcache.c.
10048 (regcache) <dump>: Remove.
10049
10050 2018-02-21 Yao Qi <yao.qi@linaro.org>
10051
10052 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
10053 reg_buffer_rw *.
10054 (jit_unwind_reg_set_impl): Call raw_supply.
10055 (jit_frame_sniffer): Use reg_buffer_rw.
10056 * record-full.c (record_full_core_regbuf): Change its type.
10057 (record_full_core_open_1): Use reg_buffer_rw.
10058 (record_full_close): Likewise.
10059 (record_full_core_fetch_registers): Use regcache->raw_supply.
10060 (record_full_core_store_registers): Likewise.
10061 * regcache.c (regcache::get_register_status): Move it to
10062 reg_buffer.
10063 (regcache_raw_set_cached_value): Remove.
10064 (regcache::raw_set_cached_value): Remove.
10065 (regcache::raw_write): Call raw_supply.
10066 (regcache::raw_supply): Move it to reg_buffer_rw.
10067 * regcache.h (regcache_raw_set_cached_value): Remove.
10068 (reg_buffer_rw): New class.
10069
10070 2018-02-21 Yao Qi <yao.qi@linaro.org>
10071
10072 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
10073 readonly_detached_regcache.
10074 (dummy_frame_prev_register): Use regcache->cooked_read.
10075 * frame.c (frame_save_as_regcache): Change return type.
10076 (frame_pop): Update.
10077 * frame.h (frame_save_as_regcache): Update declaration.
10078 * inferior.h (get_infcall_suspend_state_regcache): Update
10079 declaration.
10080 * infrun.c (infcall_suspend_state) <registers>: use
10081 readonly_detached_regcache.
10082 (save_infcall_suspend_state): Don't use regcache_dup.
10083 (get_infcall_suspend_state_regcache): Change return type.
10084 * linux-fork.c (struct fork_info) <savedregs>: Change to
10085 readonly_detached_regcache.
10086 <pc>: New field.
10087 (fork_save_infrun_state): Don't use regcache_dup.
10088 (info_checkpoints_command): Adjust.
10089 * mi/mi-main.c (register_changed_p): Update declaration.
10090 (mi_cmd_data_list_changed_registers): Use
10091 readonly_detached_regcache.
10092 (register_changed_p): Change parameter type to
10093 readonly_detached_regcache.
10094 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
10095 readonly_detached_regcache.
10096 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
10097 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
10098 New.
10099 (regcache::save): Move it to reg_buffer.
10100 (regcache::restore): Change parameter type.
10101 (regcache_dup): Remove.
10102 * regcache.h (reg_buffer) <save>: New method.
10103 (readonly_detached_regcache): New class.
10104 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
10105 readonly_detached_regcache.
10106 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
10107
10108 2018-02-21 Yao Qi <yao.qi@linaro.org>
10109
10110 * frame.c (frame_save_as_regcache): Use regcache method save.
10111 (frame_pop): Use regcache method restore.
10112 * infrun.c (restore_infcall_suspend_state): Likewise.
10113 * linux-fork.c (fork_load_infrun_state): Likewise.
10114 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
10115 save.
10116 * regcache.c (regcache_save): Remove.
10117 (regcache::restore): More asserts.
10118 (regcache_cpy): Remove.
10119 * regcache.h (regcache_save): Remove the declaration.
10120 (regcache::restore): Move from private to public.
10121 Remove the friend declaration of regcache_cpy.
10122 (regcache_cpy): Remove declaration.
10123
10124 2018-02-21 Yao Qi <yao.qi@linaro.org>
10125
10126 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
10127 parameter type to 'readable_regcache *'.
10128 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
10129 * arm-tdep.c (arm_neon_quad_read): Likewise.
10130 (arm_pseudo_read): Likewise.
10131 * avr-tdep.c (avr_pseudo_register_read): Likewise.
10132 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
10133 * frv-tdep.c (frv_pseudo_register_read): Likewise.
10134 * gdbarch.c: Re-generated.
10135 * gdbarch.h: Re-generated.
10136 * gdbarch.sh (pseudo_register_read): Change parameter type to
10137 'readable_regcache *'.
10138 (pseudo_register_read_value): Likewise.
10139 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
10140 (h8300_pseudo_register_read): Likewise.
10141 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
10142 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
10143 (i386_pseudo_register_read_into_value): Likewise.
10144 (i386_pseudo_register_read_value): Likewise.
10145 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
10146 declaration.
10147 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
10148 * m32c-tdep.c (m32c_raw_read): Likewise.
10149 (m32c_read_flg): Likewise.
10150 (m32c_banked_register): Likewise.
10151 (m32c_banked_read): Likewise.
10152 (m32c_sb_read): Likewise.
10153 (m32c_part_read): Likewise.
10154 (m32c_cat_read): Likewise.
10155 (m32c_r3r2r1r0_read): Likewise.
10156 (m32c_pseudo_register_read): Likewise.
10157 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
10158 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
10159 (mep_pseudo_cr64_read): Likewise.
10160 (mep_pseudo_register_read): Likewise.
10161 * mips-tdep.c (mips_pseudo_register_read): Likewise.
10162 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
10163 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
10164 * regcache.c (regcache::raw_read): Move it to readable_regcache.
10165 (regcache::cooked_read): Likewise.
10166 (regcache::cooked_read_value): Likewise.
10167 (regcache_cooked_read_signed):
10168 (regcache::cooked_read): Likewise.
10169 * regcache.h (readable_regcache): New class.
10170 (regcache): Inherit readable_regcache. Move some methods to
10171 readable_regcache.
10172 * rl78-tdep.c (rl78_pseudo_register_read): Change
10173 parameter type to 'readable_regcache *'.
10174 * rs6000-tdep.c (do_regcache_raw_read): Remove.
10175 (e500_pseudo_register_read): Change parameter type to
10176 'readable_regcache *'.
10177 (dfp_pseudo_register_read): Likewise.
10178 (vsx_pseudo_register_read): Likewise.
10179 (efpr_pseudo_register_read): Likewise.
10180 * s390-tdep.c (s390_pseudo_register_read): Likewise.
10181 * sh-tdep.c (sh_pseudo_register_read): Likewise.
10182 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
10183 (sh64_pseudo_register_read): Likewise.
10184 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
10185 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
10186 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
10187 (spu_pseudo_register_read): Likewise.
10188 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
10189 (xtensa_pseudo_register_read): Likewise.
10190
10191 2018-02-21 Yao Qi <yao.qi@linaro.org>
10192
10193 * regcache.c (regcache::regcache): Call reg_buffer ctor.
10194 (regcache::arch): Move it to reg_buffer::arch.
10195 (regcache::register_buffer): Likewise.
10196 (regcache::assert_regnum): Likewise.
10197 (regcache::num_raw_registers): Likewise.
10198 * regcache.h (reg_buffer): New class.
10199 (regcache): Inherit reg_buffer.
10200
10201 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
10202
10203 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
10204 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
10205
10206 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
10207
10208 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
10209
10210 2018-02-19 Alan Hayward <alan.hayward@arm.com>
10211
10212 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
10213 (SFILES): Remove common/*.c files.
10214 (COMMON_OBS): Remove some *.o files built from common/*.c files.
10215 * common/common.host: Add common reference.
10216 * configure.ac: Likewise.
10217 * configure: Regenerate.
10218
10219 2018-02-16 Yao Qi <yao.qi@linaro.org>
10220
10221 * block.c (block_namespace_info): Inherit allocate_on_obstack.
10222 (block_initialize_namespace): Use new.
10223 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
10224 (dwarf2_free_objfile): Use delete.
10225 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
10226 (copy_type_recursive): Use new.
10227 * gdb_obstack.h (allocate_on_obstack): New.
10228
10229 2018-02-15 Yao Qi <yao.qi@linaro.org>
10230
10231 PR gdb/22849
10232 * inferior.c (exit_inferior_1): Reset inf->control.
10233
10234 2018-02-15 Joel Brobecker <brobecker@adacore.com>
10235
10236 * ada-lang.c (ada_to_fixed_value_create): Delete advance
10237 declaration.
10238
10239 2018-02-14 Pedro Alves <palves@redhat.com>
10240
10241 * frame-unwind.c (frame_unwind_try_unwinder): Always call
10242 frame_cleanup_after_sniffer on exception.
10243
10244 2018-02-14 Tom Tromey <tom@tromey.com>
10245
10246 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
10247 const.
10248 (solib_bfd_open): Make pathname const.
10249 * solib.c (solib_bfd_open): Make pathname const.
10250 * solib-spu.c (spu_bfd_fopen): Make name const.
10251 (spu_bfd_open): Make pathname const.
10252 * solib-darwin.c (darwin_bfd_open): Make pathname const.
10253 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
10254
10255 2018-02-14 Tom Tromey <tom@tromey.com>
10256
10257 * symfile.c (symfile_bfd_open): Update.
10258 * source.h (openp, source_full_path_of, find_and_open_source):
10259 Change argument type to unique_xmalloc_ptr.
10260 * source.c (openp): Take a unique_xmalloc_ptr.
10261 (source_full_path_of, find_and_open_source): Likewise.
10262 (open_source_file, symtab_to_fullname): Update.
10263 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
10264 unique_xmalloc_ptr.
10265 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
10266 (exec_file_find): Update.
10267 * psymtab.c (psymtab_to_fullname): Update.
10268 * nto-tdep.h (nto_find_and_open_solib): Update.
10269 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
10270 unique_xmalloc_ptr.
10271 * exec.c (exec_file_attach): Update.
10272 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
10273 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
10274
10275 2018-02-14 Tom Tromey <tom@tromey.com>
10276
10277 * solib.c: Include source.h.
10278 * nto-tdep.c: Include source.h.
10279 * mi/mi-cmd-env.c: Include source.h.
10280 * infcmd.c: Include source.h.
10281 * exec.c: Include source.h.
10282 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
10283 (add_path, directory_switch, source_path, init_source_path): Move
10284 declarations...
10285 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
10286 (add_path, directory_switch, source_path, init_source_path):
10287 ...here.
10288
10289 2018-02-14 Tom Tromey <tom@tromey.com>
10290
10291 * solist.h (exec_file_find, solib_find): Return
10292 unique_xmalloc_ptr.
10293 (solib_bfd_fopen): Take a const char *.
10294 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
10295 (exec_file_find, solib_find): Likewise.
10296 (solib_bfd_fopen): Do not take ownership of "pathname".
10297 (solib_bfd_open): Use unique_xmalloc_ptr.
10298 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
10299 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
10300 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
10301 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
10302
10303 2018-02-14 Joel Brobecker <brobecker@adacore.com>
10304
10305 * ada-lang.c (name_match_type_from_name): Remove reference to
10306 ada_name_for_lookup in function's documentation.
10307 * ada-lang.h (ada_name_for_lookup): Delete declaration.
10308
10309 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
10310
10311 * defs.h (enum openp_flags): New enum.
10312 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
10313 Move to enum openp_flags.
10314 (openp_flags): New enum flags.
10315 (openp): Change parameter type to openp_flags.
10316 * source.c (openp): Change parameter type to openp_flags.
10317 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
10318 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
10319
10320 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
10321
10322 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
10323 per-command.
10324
10325 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
10326
10327 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
10328 into...
10329 (class dwarf2_queue_guard): ...the destructor of this new class.
10330 (dw2_do_instantiate_symtab): Create instance of the new class
10331 dwarf2_queue_guard, remove cleanup.
10332
10333 2018-02-09 Tom Tromey <tom@tromey.com>
10334
10335 * source.c (find_source_lines): Don't reference past the end of
10336 the vector.
10337
10338 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10339
10340 * remote.c (remote_btrace_maybe_reopen): Change error message.
10341 * btrace.c (btrace_enable): Likewise.
10342 (parse_xml_btrace): Likewise.
10343 (parse_xml_btrace_conf): Likewise.
10344
10345 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10346
10347 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
10348 (linux_enable_pt, linux_enable_bts): Call
10349 diagnose_perf_event_open_fail.
10350
10351 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10352
10353 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
10354 Remove parameter and change return type. Update callers. Move it.
10355 (linux_enable_bts, linux_enable_pt): Improve error message.
10356 (linux_enable_pt): Remove zero buffer size check.
10357 (linux_enable_btrace): Improve error messages. Remove NULL return
10358 check.
10359
10360 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10361
10362 * btrace.c (btrace_enable): Remove target_supports_btrace call.
10363 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
10364 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
10365 (linux_supports_pt, linux_supports_btrace): Remove.
10366 (linux_enable_bts): Call cpu_supports_bts.
10367 * nat/linux-btrace.h (linux_supports_btrace): Remove.
10368 * remote.c (remote_supports_btrace): Remove.
10369 (init_remote_ops): Remove remote_supports_btrace.
10370 * target-delegates.c: Regenerated.
10371 * target.c (target_supports_btrace): Remove.
10372 * target.h (target_ops) <to_supports_btrace>: Remove
10373 (target_supports_btrace): Remove.
10374 * x86-linux-nat.c (x86_linux_create_target): Remove
10375 linux_supports_btrace.
10376
10377 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10378
10379 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
10380 btrace failed.
10381 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
10382 exception and use message in own exception.
10383
10384 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10385
10386 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
10387 (perf_event_pt_event_type): Use gdb_file_up.
10388 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
10389 scoped_fd, and scoped_mmap.
10390
10391 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10392
10393 * common/scoped_mmap.h: New.
10394 * unittests/scoped_mmap-selftest.c: New.
10395 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10396 unittests/scoped_mmap-selftest.c.
10397
10398 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10399
10400 * common/scoped_fd.h: New.
10401 * unittests/scoped_fd-selftest.c: New.
10402 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10403 unittests/scoped_fd-selftest.c.
10404
10405 2018-02-09 Tom Tromey <tom@tromey.com>
10406
10407 * auto-load.c (auto_load_section_scripts): Use
10408 gdb::unique_xmalloc_ptr.
10409
10410 2018-02-09 Tom Tromey <tom@tromey.com>
10411
10412 * auto-load.c (execute_script_contents): Use std::string.
10413
10414 2018-02-09 Joel Brobecker <brobecker@adacore.com>
10415
10416 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
10417 Python function, rather than a new command.
10418
10419 2018-02-08 Tom Tromey <tom@tromey.com>
10420
10421 * solib.c (solib_find_1): Use std::string.
10422 (solib_bfd_fopen): Use unique_xmalloc_ptr.
10423
10424 2018-02-08 Tom Tromey <tom@tromey.com>
10425
10426 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
10427
10428 2018-02-08 Tom Tromey <tom@tromey.com>
10429
10430 * source.c (find_source_lines): Use gdb::def_vector.
10431
10432 2018-02-08 Tom Tromey <tom@tromey.com>
10433
10434 * macrocmd.c (struct temporary_macro_definition): New.
10435 (macro_define_command): Use temporary_macro_definition. Remove
10436 cleanups.
10437 (free_macro_definition_ptr): Remove.
10438
10439 2018-02-08 Tom Tromey <tom@tromey.com>
10440
10441 * macroexp.c (maybe_expand): Use std::string.
10442
10443 2018-02-08 Tom Tromey <tom@tromey.com>
10444
10445 * macroexp.c (struct macro_buffer): Add initializers for some
10446 members.
10447 (init_buffer, init_shared_buffer, free_buffer)
10448 (free_buffer_return_text): Remove.
10449 (macro_buffer): New constructors.
10450 (~macro_buffer): New destructor.
10451 (macro_buffer::set_shared): New method.
10452 (macro_buffer::resize_buffer, macro_buffer::appendc)
10453 (macro_buffer::appendmem): Now methods, not free functions.
10454 (set_token, append_tokens_without_splicing, stringify)
10455 (macro_stringify): Update.
10456 (gather_arguments): Change return type. Remove argc_p argument,
10457 add args_ptr argument. Use std::vector.
10458 (substitute_args): Remove argc argument. Accept std::vector.
10459 (expand): Update. Use std::vector.
10460 (scan, macro_expand, macro_expand_next): Update.
10461
10462 2018-02-08 Tom Tromey <tom@tromey.com>
10463
10464 * symtab.c (default_collect_symbol_completion_matches_break_on):
10465 Use unique_xmalloc_ptr.
10466 * macroscope.h: (sal_macro_scope, user_macro_scope)
10467 (default_macro_scope): Return unique_xmalloc_ptr.
10468 * macroscope.c (sal_macro_scope, user_macro_scope)
10469 (default_macro_scope): Return unique_xmalloc_ptr.
10470 * macroexp.h (macro_expand, macro_expand_once): Return
10471 unique_xmalloc_ptr.
10472 * macroexp.c (macro_expand, macro_expand_once): Return
10473 unique_xmalloc_ptr.
10474 * macrocmd.c (macro_expand_command, macro_expand_once_command)
10475 (info_macro_command, info_macros_command): Use
10476 unique_xmalloc_ptr.
10477 * compile/compile-c-support.c (write_macro_definitions): Use
10478 unique_xmalloc_ptr.
10479 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
10480
10481 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
10482
10483 * value.c (value_static_field): Assign field type instead of
10484 containing type when returning an optimized out value.
10485
10486 2018-02-06 Yao Qi <yao.qi@linaro.org>
10487
10488 * ft32-tdep.c (ft32_read_pc): Remove.
10489 (ft32_write_pc): Remove.
10490 (ft32_gdbarch_init): Update.
10491 * m32r-tdep.c (m32r_read_pc): Remove.
10492 (m32r_gdbarch_init): Update.
10493 * mep-tdep.c (mep_read_pc): Remove.
10494 (mep_gdbarch_init): Update.
10495 * microblaze-tdep.c (microblaze_write_pc): Remove.
10496 (microblaze_gdbarch_init): Update.
10497 * mn10300-tdep.c (mn10300_read_pc): Remove.
10498 (mn10300_write_pc): Remove.
10499 (mn10300_gdbarch_init): Update.
10500 * moxie-tdep.c (moxie_read_pc): Remove.
10501 (moxie_write_pc): Remove.
10502 (moxie_gdbarch_init): Update.
10503
10504 2018-02-06 Yao Qi <yao.qi@linaro.org>
10505
10506 * expprint.c (print_subexp_standard): Handle
10507 OP_F77_UNDETERMINED_ARGLIST.
10508 (dump_subexp_body_standard): Likewise.
10509
10510 2018-02-05 Alan Hayward <alan.hayward@arm.com>
10511
10512 * target-descriptions.c (tdesc_element_visitor) Add empty
10513 implementations.
10514 (tdesc_type): Move make_gdb_type from here.
10515 (tdesc_type_builtin): Likewise.
10516 (tdesc_type_vector): Likewise.
10517 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
10518 (make_gdb_type_struct): Move from tdesc_type_with_fields.
10519 (make_gdb_type_union): Likewise.
10520 (make_gdb_type_flags): Likewise.
10521 (make_gdb_type_enum): Likewise.
10522 (make_gdb_type): New function.
10523 (tdesc_register_type): Use static make_gdb_type.
10524
10525 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
10526
10527 * infcmd.c (default_print_one_register_info): Align natural-format
10528 column values consistently one under another.
10529 (pad_to_column): New function.
10530
10531 2018-02-05 Joel Brobecker <brobecker@adacore.com>
10532
10533 * dwarf2read.c (dwarf2_physname): Move commment.
10534
10535 2018-02-01 Leszek Swirski <leszeks@google.com>
10536
10537 * varobj.c (varobj_formatted_print_options): Allow recursive
10538 pretty printing if pretty printing is enabled.
10539
10540 2018-02-01 Leszek Swirski <leszeks@google.com>
10541
10542 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
10543 names after a structop as a filename.
10544
10545 2018-02-01 Yao Qi <yao.qi@linaro.org>
10546
10547 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
10548 (arm_record_coproc_data_proc): Likewise.
10549
10550 2018-02-01 Yao Qi <yao.qi@linaro.org>
10551
10552 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
10553
10554 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
10555
10556 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
10557 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
10558
10559 2018-01-31 Pedro Alves <palves@redhat.com>
10560
10561 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
10562 * inflow.c (child_terminal_save_inferior): Wrap reference to
10563 tcgetpgrp in HAVE_TERMIOS_H.
10564 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
10565 _WIN32.
10566 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
10567 always iterate over all inferiors.
10568 (gdbsim_cntrl_c): Adjust.
10569 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
10570
10571 2018-01-31 Joel Brobecker <brobecker@adacore.com>
10572
10573 * gdbtypes.c (lookup_array_range_type): Make sure the array's
10574 index type is objfile-owned if the element type is as well.
10575
10576 2018-01-31 Joel Brobecker <brobecker@adacore.com>
10577
10578 GDB 8.1 released.
10579
10580 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
10581
10582 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
10583 "features/s390x-linux64.c".
10584 (_initialize_s390_linux_tdep): Remove initialization of tdescs
10585 s390_linux32 and s390x_linux64.
10586 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
10587 default tdesc.
10588 * s390-tdep.c: Include "features/s390-linux32.c" and
10589 "features/s390x-linux64.c".
10590 (s390_tdesc_valid): Add check for tdesc_has_registers.
10591 (s390_gdbarch_init): Make sure there is always a valid tdesc.
10592 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
10593 tdesc_s390x_linux64.
10594 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
10595 tdesc_s390x_linux64 to...
10596 * s390-tdep.h: ...here.
10597
10598 2018-01-30 Pedro Alves <palves@redhat.com>
10599
10600 PR gdb/13211
10601 * config.in, configure: Regenerate.
10602 * configure.ac: Check for getpgid.
10603 * go32-nat.c (go32_pass_ctrlc): New.
10604 (go32_target): Install it.
10605 * inf-child.c (inf_child_target): Install
10606 child_terminal_save_inferior, child_pass_ctrlc and
10607 child_interrupt.
10608 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
10609 (inf_ptrace_target): No longer install it.
10610 * infcmd.c (interrupt_target_1): Adjust.
10611 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
10612 (child_interrupt): Declare.
10613 (inferior::terminal_state): New.
10614 * inflow.c (struct terminal_info): Update comments.
10615 (inferior_process_group): Delete.
10616 (terminal_is_ours): Delete.
10617 (gdb_tty_state): New.
10618 (child_terminal_init): Adjust.
10619 (is_gdb_terminal, sharing_input_terminal_1)
10620 (sharing_input_terminal): New functions.
10621 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
10622 Set the process's actual process group in the foreground if
10623 possible. Handle is_ours_for_output/is_ours distinction. Don't
10624 mark terminal as the inferior's if not sharing GDB's terminal.
10625 Don't check attach_flag.
10626 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
10627 pass down a target_terminal_state.
10628 (child_terminal_save_inferior): New, factored out from ...
10629 (child_terminal_ours_1): ... this. Handle
10630 target_terminal_state::is_ours_for_output.
10631 (child_interrupt, child_pass_ctrlc): New.
10632 (inflow_inferior_exit): Clear the inferior's terminal_state.
10633 (copy_terminal_info): Copy the inferior's terminal state.
10634 (_initialize_inflow): Remove reference to terminal_is_ours.
10635 * inflow.h (inferior_process_group): Delete.
10636 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
10637 * procfs.c (procfs_target): Don't install procfs_interrupt.
10638 (procfs_interrupt): Delete.
10639 * remote.c (remote_serial_quit_handler): Adjust.
10640 (remote_interrupt): Remove ptid parameter. Adjust.
10641 * target-delegates.c: Regenerate.
10642 * target.c: Include "terminal.h".
10643 (target_terminal::terminal_state): Rename to ...
10644 (target_terminal::m_terminal_state): ... this.
10645 (target_terminal::init): Adjust.
10646 (target_terminal::inferior): Adjust to per-inferior
10647 terminal_state.
10648 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
10649 (target_terminal::ours, target_terminal::ours_for_output): Use
10650 target_terminal_is_ours_kind.
10651 (target_interrupt): Remove ptid parameter. Adjust.
10652 (default_target_pass_ctrlc): Adjust.
10653 * target.h (target_ops::to_terminal_save_inferior): New field.
10654 (target_ops::to_interrupt): Remove ptid_t parameter.
10655 (target_interrupt): Remove ptid_t parameter. Update comment.
10656 (target_pass_ctrlc): Update comment.
10657 * target/target.h (target_terminal_state): New scoped enum,
10658 factored out of ...
10659 (target_terminal::terminal_state): ... here.
10660 (target_terminal::inferior): Update comments.
10661 (target_terminal::restore_inferior): New.
10662 (target_terminal::is_inferior, target_terminal::is_ours)
10663 (target_terminal::is_ours_for_output): Adjust.
10664 (target_terminal::scoped_restore_terminal_state): Adjust to
10665 rename, and call restore_inferior() instead of inferior().
10666 (target_terminal::scoped_restore_terminal_state::m_state): Change
10667 type.
10668 (target_terminal::terminal_state): Rename to ...
10669 (target_terminal::m_terminal_state): ... this and change type.
10670
10671 2018-01-30 Pedro Alves <palves@redhat.com>
10672
10673 * linux-nat.c (wait_for_signal): New function.
10674 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
10675 directly.
10676 (async_terminal_is_ours)
10677 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
10678 (linux_nat_add_target): Don't override
10679 to_terminal_inferior/to_terminal_ours.
10680
10681 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
10682
10683 * remote.c (remote_follow_fork): Don't call "detach_inferior".
10684
10685 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
10686
10687 * dwarf2read.c (free_dwo_files): Add forward-declaration.
10688 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
10689 dwarf2_per_objfile_free here.
10690 (dwarf2_per_objfile_free): Remove.
10691 (_initialize_dwarf2_read): Don't register
10692 dwarf2_per_objfile_free as a registry cleanup.
10693
10694 2018-01-27 Eli Zaretskii <eliz@gnu.org>
10695
10696 Avoid compilation errors in MinGW native builds
10697
10698 The error is triggered by including python-internal.h, and the
10699 error message is:
10700
10701 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
10702 from build-gnulib/import/math.h:27,
10703 from d:/usr/Python26/include/pyport.h:235,
10704 from d:/usr/Python26/include/Python.h:58,
10705 from python/python-internal.h:94,
10706 from python/py-arch.c:24:
10707 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
10708 using ::hypot;
10709 ^~~~~
10710
10711 This happens because Python headers define 'hypot' to expand t
10712 '_hypot' in the Windows builds.
10713 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
10714 'hypoth'. This avoids a compilation error.
10715
10716 2018-01-26 Alan Hayward <alan.hayward@arm.com>
10717
10718 * MAINTAINERS (Write After Approval): Fix ordering.
10719
10720 2018-01-26 Alan Hayward <alan.hayward@arm.com>
10721
10722 * MAINTAINERS (Write After Approval): Add Alan Hayward.
10723
10724 2018-01-26 Alan Modra <amodra@gmail.com>
10725
10726 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
10727 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
10728 Remove nop. Make const. Comment.
10729 (powerpc32_plt_stub_so_2): New.
10730 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
10731 Correct count. Update uses.
10732 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
10733 Move common code reading PLT entry word. Correct
10734 powerpc32_plt_stub PLT address calculation.
10735 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
10736 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
10737 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
10738 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
10739 (ppc64_standard_linkage8): Likewise.
10740 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
10741 Correct insns description.
10742 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
10743
10744 2018-01-24 Pedro Alves <palves@redhat.com>
10745
10746 GCC PR libstdc++/83906
10747 * gdbtypes.c (operator==(const dynamic_prop &,
10748 const dynamic_prop &)): New.
10749 (operator==(const range_bounds &, const range_bounds &)): New.
10750 (check_types_equal): Use them instead of memcmp.
10751 * gdbtypes.h (operator==(const dynamic_prop &,
10752 const dynamic_prop &)): Declare.
10753 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
10754 (operator==(const range_bounds &, const range_bounds &)): Declare.
10755 (operator!=(const range_bounds &, const range_bounds &)): Declare.
10756
10757 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10758
10759 * s390-linux-tdep.c (s390_record_address_mask)
10760 (s390_record_calc_disp_common, s390_record_calc_disp)
10761 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10762 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10763 (s390_process_record): Move to s390-tdep.c.
10764 (s390_linux_init_abi_any): Adjust.
10765 * s390-tdep.c (s390_record_address_mask)
10766 (s390_record_calc_disp_common, s390_record_calc_disp)
10767 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10768 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10769 (s390_process_record): Moved from s390-linux-tdep.c
10770 (s390_gdbarch_init): Adjust.
10771
10772 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10773
10774 * s390-linux-nat.c (s390-tdep.h): New include.
10775 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
10776 (HFILES_NO_SRCDIR): Add s390-tdep.h.
10777 (ALLDEPFILES): Add s390-tdep.c.
10778 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
10779 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
10780 * s390-tdep.h: ...this. New file.
10781 * s390-linux-tdep.c (s390-tdep.h): New include.
10782 (_initialize_s390_tdep): Rename to...
10783 (_initialize_s390_linux_tdep): ...this and adjust.
10784 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
10785 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
10786 s390-tdep.h.
10787 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
10788 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
10789 (s390_is_partial_instruction, s390_software_single_step)
10790 (is_non_branch_ril, s390_displaced_step_copy_insn)
10791 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
10792 (s390_prologue_data, s390_addr, s390_store, s390_load)
10793 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
10794 (s390_register_call_saved, s390_guess_tracepoint_registers)
10795 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
10796 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
10797 (s390_pseudo_register_name, s390_pseudo_register_type)
10798 (s390_pseudo_register_read, s390_pseudo_register_write)
10799 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
10800 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
10801 (s390_addr_bits_remove, s390_address_class_type_flags)
10802 (s390_address_class_type_flags_to_name)
10803 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
10804 (s390_function_arg_float, s390_function_arg_vector)
10805 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
10806 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
10807 (s390_frame_align, s390_register_return_value, s390_return_value)
10808 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
10809 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
10810 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
10811 (s390_trad_frame_prev_register, s390_unwind_cache)
10812 (s390_prologue_frame_unwind_cache)
10813 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
10814 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
10815 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
10816 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
10817 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
10818 (s390_frame_base_address, s390_local_base_address)
10819 (s390_frame_base, s390_gcc_target_options)
10820 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
10821 (s390_validate_reg_range, s390_tdesc_valid)
10822 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
10823 * s390-tdep.c: ...this. New file.
10824
10825 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10826
10827 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
10828 (s390_process_record, s390_gdbarch_tdep_alloc)
10829 (s390_linux_init_abi_any): Use/set new hook.
10830
10831 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10832
10833 * s390-linux-tdep.c (osabi.h): New include.
10834 (s390_linux_init_abi_31, s390_linux_init_abi_64)
10835 (s390_linux_init_abi_any): New functions.
10836 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
10837
10838 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10839
10840 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
10841 tdesc_has_registers check
10842
10843 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10844
10845 * s390-linux-tdep.c (s390_tdesc_valid): New function.
10846 (s390_validate_reg_range): New macro.
10847 (s390_gdbarch_init): Adjust.
10848
10849 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10850
10851 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
10852 (s390_gdbarch_tdep_alloc): Adjust.
10853 (s390_gdbarch_init): Adjust.
10854
10855 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10856
10857 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
10858 <have_tdb>: Change type to bool.
10859 (s390_gdbarch_tdep_alloc): Adjust.
10860 (s390_gdbarch_init): Adjust.
10861
10862 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10863
10864 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
10865 (gdbarch_tdep) <have_upper, have_vx>: New fields.
10866 (s390_gdbarch_tdep_alloc): New function.
10867 (s390_gdbarch_init): Allocate tdep at start and use its fields
10868 instead of separate variables.
10869
10870 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10871
10872 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
10873 when looking for cached gdbarch and add comment for remaining.
10874
10875 2018-01-22 Pedro Alves <palves@redhat.com>
10876 Sergio Durigan Junior <sergiodj@redhat.com>
10877
10878 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
10879 case.
10880
10881 2018-01-22 Maciej W. Rozycki <macro@mips.com>
10882
10883 * MAINTAINERS: Update my company e-mail address.
10884
10885 2018-01-22 Yao Qi <yao.qi@linaro.org>
10886
10887 * regcache.c (cooked_write_test): New function.
10888 (_initialize_regcache): Register the test.
10889
10890 2018-01-22 Yao Qi <yao.qi@linaro.org>
10891
10892 * ia64-tdep.c (ia64_pseudo_register_read): Call
10893 regcache->cooked_read instead of regcache_cooked_read_unsigned.
10894 * m32c-tdep.c (m32c_cat_read): Likewise.
10895 (m32c_r3r2r1r0_read): Likewise.
10896 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
10897 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
10898
10899 2018-01-22 Yao Qi <yao.qi@linaro.org>
10900
10901 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
10902 method raw_read instead of regcache_raw_read.
10903 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
10904 * arm-tdep.c (arm_neon_quad_read): Likewise.
10905 * avr-tdep.c (avr_pseudo_register_read): Likewise.
10906 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
10907 * frv-tdep.c (frv_pseudo_register_read): Likewise.
10908 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
10909 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
10910 (i386_pseudo_register_read_into_value): Likewise.
10911 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
10912 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
10913 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
10914 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
10915 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
10916 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
10917 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
10918 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
10919 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
10920
10921 2018-01-22 Yao Qi <yao.qi@linaro.org>
10922
10923 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
10924 * configure.tgt: Remove target mt.
10925 * mt-tdep.c: Remove.
10926 * regcache.c (cooked_read_test): Remove the check for mt.
10927
10928 2018-01-22 Yao Qi <yao.qi@linaro.org>
10929
10930 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
10931 instead of gdbarch_pseudo_register_read_value.
10932
10933 2018-01-22 Joel Brobecker <brobecker@adacore.com>
10934
10935 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
10936 language is Ada.
10937
10938 2018-01-22 Joel Brobecker <brobecker@adacore.com>
10939
10940 * linespec.c (create_sals_line_offset): Remove code that preserved
10941 the symtab_and_line's line number.
10942
10943 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10944
10945 * varobj.c (varobj_create): Don't set valid_block when creating a
10946 floating varobj.
10947
10948 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10949
10950 * varobj.c (varobj_create): Remove out of date comment.
10951
10952 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10953
10954 PR mi/20395
10955 * ada-exp.y (write_var_from_sym): Pass extra parameter when
10956 updating innermost block.
10957 * parse.c (innermost_block_tracker::update): Take extra type
10958 parameter, and check types match before updating innermost block.
10959 (write_dollar_variable): Update innermost block for registers.
10960 * parser-defs.h (enum innermost_block_tracker_type): New enum.
10961 (innermost_block_tracker::innermost_block_tracker): Initialise
10962 m_types member.
10963 (innermost_block_tracker::reset): Take type parameter.
10964 (innermost_block_tracker::update): Take type parameter, and pass
10965 type through as needed.
10966 (innermost_block_tracker::m_types): New member.
10967 * varobj.c (varobj_create): Pass type when reseting innermost
10968 block.
10969
10970 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10971
10972 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
10973 * ada-lang.c (resolve_subexp): Likewise.
10974 * breakpoint.c (set_breakpoint_condition) Likewise.
10975 (watch_command_1) Likewise.
10976 * c-exp.y (variable): Likewise.
10977 * d-exp.y (PrimaryExpression): Likewise.
10978 * f-exp.y (variable): Likewise.
10979 * go-exp.y (variable): Likewise.
10980 * m2-exp.y (variable): Likewise.
10981 * objfiles.c (objfile::~objfile): Likewise.
10982 * p-exp.y (variable): Likewise.
10983 * parse.c (innermost_block): Change type.
10984 * parser-defs.h (class innermost_block_tracker): New.
10985 (innermost_block): Change to innermost_block_tracker.
10986 * printcmd.c (display_command): Switch to innermost_block API.
10987 (do_one_display): Likewise.
10988 * rust-exp.y (do_one_display): Likewise.
10989 * symfile.c (clear_symtab_users): Likewise.
10990 * varobj.c (varobj_create): Switch to innermost_block API, replace
10991 use of innermost_block with block stored on varobj object.
10992
10993 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10994
10995 * expression.h (innermost_block): Remove declaration.
10996 * varobj.c: Add 'parser-defs.h' include.
10997
10998 2018-01-19 Tom Tromey <tom@tromey.com>
10999
11000 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
11001 symbols in the static and global blocks.
11002
11003 2018-01-19 James Clarke <jrtc27@jrtc27.com>
11004
11005 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
11006 gdb_ptrace.h, and move including gdb_wait.h ...
11007 * nat/linux-ptrace.h: ... to here.
11008
11009 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
11010
11011 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
11012 inf_ptrace_detach_success.
11013 (inf_ptrace_detach_success): Add inferior parameter, use it
11014 instead of inferior_ptid, pass it to detach_inferior.
11015 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
11016 parameter.
11017 * inferior.c (detach_inferior): Add overload that takes an
11018 inferior object.
11019 * inferior.h (detach_inferior): Likewise.
11020 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
11021 use inferior_ptid, adjust call to inf_ptrace_detach_success.
11022 * linux-thread-db.c (thread_db_detach): Use inf parameter.
11023
11024 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
11025
11026 * target.h (struct target_ops) <to_detach>: Add inferior
11027 parameter.
11028 (target_detach): Likewise.
11029 * target.c (dispose_inferior): Pass inferior down.
11030 (target_detach): Pass inferior down. Assert that it is equal to
11031 the current inferior.
11032 * aix-thread.c (aix_thread_detach): Pass inferior down.
11033 * corefile.c (core_file_command): Pass current_inferior() down.
11034 * corelow.c (core_detach): Add inferior parameter.
11035 * darwin-nat.c (darwin_detach): Likewise.
11036 * gnu-nat.c (gnu_detach): Likewise.
11037 * inf-ptrace.c (inf_ptrace_detach): Likewise.
11038 * infcmd.c (detach_command): Pass current_inferior() down to
11039 target_detach.
11040 * infrun.c (follow_fork_inferior): Pass parent_inf to
11041 target_detach.
11042 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
11043 target_detach.
11044 * linux-nat.c (linux_nat_detach): Add inferior parameter.
11045 * linux-thread-db.c (thread_db_detach): Likewise.
11046 * nto-procfs.c (procfs_detach): Likewise.
11047 * procfs.c (procfs_detach): Likewise.
11048 * record.c (record_detach): Likewise.
11049 * record.h (struct inferior): Forward-declare.
11050 (record_detach): Add inferior parameter.
11051 * remote-sim.c (gdbsim_detach): Likewise.
11052 * remote.c (remote_detach_1): Likewise.
11053 (remote_detach): Likewise.
11054 (extended_remote_detach): Likewise.
11055 * sol-thread.c (sol_thread_detach): Likewise.
11056 * target-debug.h (target_debug_print_inferior_p): New macro.
11057 * target-delegates.c: Re-generate.
11058 * top.c (kill_or_detach): Pass inferior down to target_detach.
11059 * windows-nat.c (windows_detach): Add inferior parameter.
11060
11061 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
11062
11063 * target.h (struct target_ops) <to_detach>: Remove args
11064 parameter.
11065 (target_detach): Likewise.
11066 * target.c (dispose_inferior): Adjust.
11067 (target_detach): Remove args parameter, adjust.
11068 * aix-thread.c (aix_thread_detach): Adjust.
11069 * corefile.c (core_file_command): Adjust.
11070 * corelow.c (core_detach): Adjust.
11071 * darwin-nat.c (darwin_detach): Adjust.
11072 * gnu-nat.c (gnu_detach): Adjust.
11073 * inf-ptrace.c (inf_ptrace_detach): Adjust.
11074 * infcmd.c (detach_command): Adjust
11075 * infrun.c (follow_fork_inferior): Adjust.
11076 (handle_vfork_child_exec_or_exit): Adjust.
11077 * linux-fork.c (linux_fork_detach): Remove args parameter.
11078 * linux-fork.h (linux_fork_detach): Likewise.
11079 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
11080 * linux-thread-db.c (thread_db_detach): Likewise.
11081 * nto-procfs.c (procfs_detach): Likewise.
11082 * procfs.c (procfs_detach): Likewise.
11083 (do_detach): Remove signo parameter.
11084 * record.c (record_detach): Remove args parameter.
11085 * record.h (record_detach): Likewise.
11086 * remote-sim.c (gdbsim_detach): Likewise.
11087 * remote.c (remote_detach_1): Likewise.
11088 (remote_detach): Likewise.
11089 (extended_remote_detach): Likewise.
11090 * sol-thread.c (sol_thread_detach): Likewise.
11091 * target-delegates.c: Re-generate.
11092 * top.c (struct qt_args) <args>: Remove field.
11093 (kill_or_detach): Don't pass args.
11094 (quit_force): Don't set args.
11095 * windows-nat.c (windows_detach): Remove args parameter.
11096
11097 2018-01-19 Yao Qi <yao.qi@linaro.org>
11098
11099 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
11100 (arm_linux_init_abi): Install it.
11101
11102 2018-01-19 Yao Qi <yao.qi@linaro.org>
11103
11104 * osabi.c (gdb_osabi_names): Extend the regexp for
11105 arm-linux-gnueabihf.
11106
11107 2018-01-18 Yao Qi <yao.qi@linaro.org>
11108
11109 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
11110 m_abbrevs.
11111 (abbrev_table::add_abbrev): Update.
11112 (abbrev_table::lookup_abbrev): Update.
11113
11114 2018-01-18 Yao Qi <yao.qi@linaro.org>
11115
11116 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
11117
11118 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
11119
11120 * compile/compile.c (compile_to_object): Convert "triplet_rx"
11121 to "std::string".
11122
11123 2018-01-17 Tom Tromey <tom@tromey.com>
11124
11125 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
11126
11127 2018-01-17 Tom Tromey <tom@tromey.com>
11128
11129 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
11130 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
11131 (create_array_type_with_stride): Update.
11132 * dwarf2read.c (set_die_type): Update.
11133
11134 2018-01-17 Tom Tromey <tom@tromey.com>
11135
11136 * dwarf2read.c (delayed_method_info): Remove typedef.
11137 (dwarf2_cu::method_info): Now a std::vector.
11138 (add_to_method_list): Update.
11139 (free_delayed_list): Remove.
11140 (compute_delayed_physnames): Update.
11141 (process_full_comp_unit, process_full_type_unit): Clear the method
11142 list. Remove cleanups.
11143 (psymtab_include_file_name): Add name_holder parameter. Use
11144 unique_xmalloc_ptr.
11145 (dwarf_decode_lines): Update.
11146
11147 2018-01-17 Tom Tromey <tom@tromey.com>
11148 Simon Marchi <simon.marchi@ericsson.com>
11149
11150 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
11151 (dwarf2_per_objfile::free_cached_comp_units)
11152 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
11153 (init_cutu_and_read_dies_no_follow): Update.
11154 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
11155 (dwarf2_cu::~dwarf2_cu): New.
11156 (free_heap_comp_unit, free_stack_comp_unit): Remove.
11157 (age_cached_comp_units, free_one_cached_comp_unit): Update.
11158
11159 2018-01-17 Tom Tromey <tom@tromey.com>
11160 Simon Marchi <simon.marchi@ericsson.com>
11161
11162 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
11163 (struct die_reader_specs) <abbrev_table>: New member.
11164 (struct abbrev_table): Add constructor.
11165 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
11166 <abbrev_obstack>: Now an auto_obstack.
11167 (abbrev_table_up): New typedef.
11168 (init_cu_die_reader): Add abbrev_table parameter.
11169 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
11170 Add result_dwo_abbrev_table.
11171 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
11172 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
11173 Update.
11174 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
11175 parameter.
11176 (skip_children): Update.
11177 (abbrev_table::alloc_abbrev): Rename from
11178 abbrev_table_alloc_abbrev.
11179 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
11180 (abbrev_table::lookup_abbrev): Rename from
11181 abbrev_table_lookup_abbrev.
11182 (abbrev_table_read_table): Return abbrev_table_up.
11183 (abbrev_table_free, abbrev_table_free_cleanup)
11184 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
11185 (load_partial_dies): Update.
11186
11187 2018-01-17 Tom Tromey <tom@tromey.com>
11188
11189 * dwarf2read.c (dwarf2_compute_name): Update comment.
11190 (read_func_scope, read_variable): Update.
11191 (new_symbol): Remove.
11192 (new_symbol_full): Rename to new_symbol.
11193
11194 2018-01-17 Mike Gulick <mgulick@mathworks.com>
11195
11196 PR gdb/16577
11197 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
11198 a warning instead of throwing an error, set section size to 0 and return
11199 NULL.
11200 * gdb_bfd.h (gdb_bfd_map_section): Update description.
11201
11202 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
11203
11204 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
11205 std::string.
11206 (linux_ptrace_attach_fail_reason_string): Likewise.
11207 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
11208 Likewise.
11209 (linux_ptrace_attach_fail_reason_string): Likewise.
11210 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
11211
11212 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
11213
11214 * linux-nat.c (linux_nat_attach): Remove xstrdup.
11215
11216 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
11217
11218 PR gdb/21559
11219 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
11220 checking for fs_base/gs_base fields in struct user_regs_struct.
11221 * configure: Regenerate.
11222
11223 2018-01-17 Yao Qi <yao.qi@linaro.org>
11224
11225 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
11226 function.
11227 (aarch64_linux_init_abi): Install it to gdbarch hook
11228 gcc_target_options.
11229
11230 2018-01-15 Pedro Alves <palves@redhat.com>
11231
11232 * common/signals-state-save-restore.c
11233 (save_original_signals_state): Fix typos.
11234
11235 2017-01-12 Tom Tromey <tom@tromey.com>
11236 Sergio Durigan Junior <sergiodj@redhat.com>
11237
11238 * Makefile.in (install-only): Install gdb-add-index.
11239
11240 2018-01-12 John Baldwin <jhb@FreeBSD.org>
11241
11242 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
11243
11244 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11245
11246 * infrun.c (keep_going_pass_signal): Clear step-over info when
11247 insert_breakpoints fails.
11248
11249 2018-01-11 Pedro Alves <palves@redhat.com>
11250
11251 PR gdb/22583
11252 * infrun.c (resume): Rename to ...
11253 (resume_1): ... this.
11254 (resume): Reimplement as wrapper around resume_1.
11255
11256 2018-01-11 Pedro Alves <palves@redhat.com>
11257
11258 PR remote/22597
11259 * remote.c (remote_parse_stop_reply): Default to the last-set
11260 general thread instead of to 'magic_null_ptid'.
11261
11262 2018-01-10 Pedro Alves <palves@redhat.com>
11263
11264 * language.h (language_get_symbol_name_matcher): Rename ...
11265 (get_symbol_name_matcher): ... this.
11266 * language.c (language_get_symbol_name_matcher): Ditto.
11267 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
11268 callers adjusted.
11269
11270 2018-01-10 Pedro Alves <palves@redhat.com>
11271
11272 PR gdb/22670
11273 * dwarf2read.c
11274 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
11275 Adjust to use language_get_symbol_name_matcher instead of
11276 language_defn::la_get_symbol_name_matcher.
11277 * language.c (language_get_symbol_name_matcher): If in Ada mode
11278 and the lookup name is a verbatim match, return Ada's matcher.
11279 * language.h (language_get_symbol_name_matcher): Adjust comment.
11280 (ada_lookup_name_info::verbatim_p):: New method.
11281
11282 2018-01-10 Pedro Alves <palves@redhat.com>
11283
11284 PR gdb/22670
11285 * ada-lang.c (ada_collect_symbol_completion_matches): If the
11286 minsym's language is language_auto or language_cplus, pass down
11287 language_ada instead.
11288 * symtab.c (compare_symbol_name): Don't frob symbol language here.
11289
11290 2018-01-10 Pedro Alves <palves@redhat.com>
11291
11292 PR gdb/22670
11293 * minsyms.c (linkage_name_str): New function.
11294 (iterate_over_minimal_symbols): Use it.
11295
11296 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11297
11298 * NEWS: Document that 'info proc' now works on FreeBSD.
11299
11300 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11301
11302 * configure.ac: Check for kinfo_getfile in libutil.
11303 * configure: Regenerate.
11304 * config.in: Regenerate.
11305 * fbsd-nat.c: Include "fbsd-tdep.h".
11306 (fbsd_fetch_cmdline): New.
11307 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
11308 rather than calling error.
11309 (fbsd_info_proc): New.
11310 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
11311 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
11312 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
11313
11314 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11315
11316 * fbsd-nat.c (struct free_deleter): Remove.
11317 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
11318
11319 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11320
11321 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
11322 NULL for an empty pathname.
11323
11324 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11325
11326 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
11327 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
11328 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
11329 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
11330 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
11331 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
11332 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
11333 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
11334 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
11335 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
11336 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
11337 (fbsd_core_fetch_timeval, fbsd_print_sigset)
11338 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
11339 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
11340 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
11341
11342 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
11343
11344 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
11345 (gnu_xfer_auxv): New function.
11346 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
11347 TARGET_OBJECT_AUXV.
11348
11349 2018-01-08 Yao Qi <yao.qi@linaro.org>
11350 Simon Marchi <simon.marchi@ericsson.com>
11351
11352 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
11353 common/selftest.c.
11354 (COMMON_OBS): Remove selftest.o.
11355 * configure.ac: Append selftest-arch.c and common/selftest.c to
11356 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
11357 * configure: Re-generated.
11358 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
11359 GDB_SELF_TEST.
11360 (maintenance_info_selftests): Likewise.
11361
11362 2018-01-08 Xavier Roirand <roirand@adacore.com>
11363
11364 * ada-valprint.c (val_print_packed_array_elements): Use
11365 proper number of elements when printing an array indexed
11366 by an enumeration type.
11367
11368 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11369
11370 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
11371 (dw2_get_file_names_reader): Adjust.
11372 (lookup_dwo_signatured_type): Adjust.
11373 (lookup_dwp_signatured_type): Adjust.
11374 (lookup_signatured_type): Adjust.
11375 (create_type_unit_group): Adjust.
11376 (get_type_unit_group): Adjust.
11377 (process_psymtab_comp_unit_reader): Adjust.
11378 (build_type_psymtabs_reader): Adjust.
11379 (scan_partial_symbols): Adjust.
11380 (add_partial_symbol): Adjust.
11381 (add_partial_subprogram): Adjust.
11382 (peek_die_abbrev): Adjust.
11383 (fixup_go_packaging): Adjust.
11384 (process_imported_unit_die): Adjust.
11385 (dwarf2_compute_name): Adjust.
11386 (dwarf2_physname): Adjust.
11387 (read_import_statement): Adjust.
11388 (handle_DW_AT_stmt_list): Adjust.
11389 (read_file_scope): Adjust.
11390 (read_func_scope): Adjust.
11391 (read_lexical_block_scope): Adjust.
11392 (read_call_site_scope): Adjust.
11393 (read_variable): Adjust.
11394 (dwarf2_rnglists_process): Adjust.
11395 (dwarf2_ranges_process): Adjust.
11396 (dwarf2_ranges_read): Adjust.
11397 (dwarf2_get_pc_bounds): Adjust.
11398 (dwarf2_record_block_ranges): Adjust.
11399 (dwarf2_add_field): Adjust.
11400 (dwarf2_add_member_fn): Adjust.
11401 (read_structure_type): Adjust.
11402 (process_structure_scope): Adjust.
11403 (read_enumeration_type): Adjust.
11404 (read_array_type): Adjust.
11405 (mark_common_block_symbol_computed): Adjust.
11406 (read_common_block): Adjust.
11407 (read_namespace_type): Adjust.
11408 (read_namespace): Adjust.
11409 (read_module_type): Adjust.
11410 (read_tag_pointer_type): Adjust.
11411 (read_tag_ptr_to_member_type): Adjust.
11412 (read_tag_string_type): Adjust.
11413 (read_subroutine_type): Adjust.
11414 (read_typedef): Adjust.
11415 (read_base_type): Adjust.
11416 (attr_to_dynamic_prop): Adjust.
11417 (read_subrange_type): Adjust.
11418 (read_unspecified_type): Adjust.
11419 (dwarf2_read_abbrevs): Adjust.
11420 (load_partial_dies): Adjust.
11421 (read_partial_die): Adjust.
11422 (find_partial_die): Adjust.
11423 (guess_partial_die_structure_name): Adjust.
11424 (fixup_partial_die): Adjust.
11425 (read_attribute_value): Adjust.
11426 (read_addr_index): Adjust.
11427 (read_addr_index_from_leb128): Adjust.
11428 (read_str_index): Adjust.
11429 (dwarf2_string_attr): Adjust.
11430 (get_debug_line_section): Adjust.
11431 (dwarf_decode_line_header): Adjust.
11432 (lnp_state_machine::check_line_address): Adjust.
11433 (dwarf_decode_lines_1): Adjust.
11434 (dwarf_decode_lines): Adjust.
11435 (dwarf2_start_symtab): Adjust.
11436 (var_decode_location): Adjust.
11437 (new_symbol_full): Adjust.
11438 (dwarf2_const_value_data): Adjust.
11439 (dwarf2_const_value_attr): Adjust.
11440 (dwarf2_const_value): Adjust.
11441 (die_type): Adjust.
11442 (die_containing_type): Adjust.
11443 (build_error_marker_type): Adjust.
11444 (lookup_die_type): Adjust.
11445 (guess_full_die_structure_name): Adjust.
11446 (anonymous_struct_prefix): Adjust.
11447 (determine_prefix): Adjust.
11448 (dwarf2_name): Adjust.
11449 (follow_die_ref_or_sig): Adjust.
11450 (follow_die_offset): Adjust.
11451 (follow_die_ref): Adjust.
11452 (follow_die_sig_1): Adjust.
11453 (follow_die_sig): Adjust.
11454 (get_signatured_type): Adjust.
11455 (get_DW_AT_signature_type): Adjust.
11456 (decode_locdesc): Adjust.
11457 (dwarf_decode_macros): Adjust.
11458 (cu_debug_loc_section): Adjust.
11459 (fill_in_loclist_baton): Adjust.
11460 (dwarf2_symbol_mark_computed): Adjust.
11461 (init_one_comp_unit): Don't assign
11462 dwarf2_cu::dwarf2_per_objfile.
11463 (set_die_type): Adjust.
11464
11465 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11466
11467 * dwarf2read.c (struct mapped_debug_names): Add constructor.
11468 <dwarf2_per_objfile>: New field.
11469 (dwarf2_per_objfile): Remove global.
11470 (get_dwarf2_per_objfile): New function.
11471 (set_dwarf2_per_objfile): New function.
11472 (dwarf2_build_psymtabs_hard): Change objfile parameter to
11473 dwarf2_per_objfile.
11474 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
11475 (read_abbrev_offset): Likewise.
11476 (read_indirect_string): Likewise.
11477 (read_indirect_line_string): Likewise.
11478 (read_indirect_string_at_offset): Likewise.
11479 (read_indirect_string_from_dwz): Likewise.
11480 (dwarf2_find_containing_comp_unit): Change objfile parameter to
11481 dwarf2_per_objfile.
11482 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
11483 (create_all_comp_units): Change objfile parameter to
11484 dwarf2_per_objfile.
11485 (create_all_type_units): Likewise.
11486 (process_queue): Add dwarf2_per_objfile parameter.
11487 (read_and_check_comp_unit_head): Likewise.
11488 (lookup_dwo_unit_in_dwp): Likewise.
11489 (get_dwp_file): Likewise.
11490 (process_cu_includes): Likewise.
11491 (struct free_dwo_file_cleanup_data): New struct.
11492 (dwarf2_has_info): Use get_dwarf2_per_objfile and
11493 set_dwarf2_per_objfile.
11494 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
11495 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
11496 context, adjust calls.
11497 (dw2_instantiate_symtab): Likewise.
11498 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
11499 (dw2_get_cu): Likewise.
11500 (create_cu_from_index_list): Change objfile parameter to
11501 dwarf2_per_objfile.
11502 (create_cus_from_index_list): Get dwarf2_per_objfile from
11503 context, adjust calls.
11504 (create_cus_from_index): Likewise.
11505 (create_signatured_type_table_from_index): Change objfile
11506 parameter to dwarf2_per_objfile.
11507 (create_signatured_type_table_from_debug_names): Change objfile
11508 parameter to dwarf2_per_objfile.
11509 (create_addrmap_from_index): Likewise.
11510 (create_addrmap_from_aranges): Likewise.
11511 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
11512 (dw2_setup): Remove.
11513 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
11514 context.
11515 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
11516 get_dwarf2_per_objfile.
11517 (dw2_forget_cached_source_info): Likewise.
11518 (dw2_map_symtabs_matching_filename): Likewise.
11519 (struct dw2_symtab_iterator) <index>: Remove.
11520 <dwarf2_per_objfile>: New field.
11521 (dw2_symtab_iter_init): Replace index parameter with
11522 dwarf2_per_objfile.
11523 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
11524 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
11525 (dw2_print_stats): Likewise.
11526 (dw2_dump): Likewise.
11527 (dw2_expand_symtabs_for_function): Likewise.
11528 (dw2_expand_all_symtabs): Likewise.
11529 (dw2_expand_symtabs_with_fullname): Likewise.
11530 (dw2_expand_marked_cus): Replace index and objfile parameters
11531 with dwarf2_per_objfile.
11532 (dw_expand_symtabs_matching_file_matcher): Add
11533 dwarf2_per_objfile parameter and adjust calls.
11534 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
11535 adjust calls.
11536 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
11537 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
11538 adjust calls.
11539 (create_cus_from_debug_names_list): Replace objfile parameter
11540 with dwarf2_per_objfile and adjust calls.
11541 (create_cus_from_debug_names): Likewise.
11542 (dwarf2_read_debug_names): Likewise.
11543 (mapped_debug_names::namei_to_name): Adjust call.
11544 (dw2_debug_names_iterator::next): Likewise.
11545 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
11546 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
11547 (dw2_debug_names_dump): Likewise.
11548 (dw2_debug_names_expand_symtabs_for_function): Likewise.
11549 (dw2_debug_names_expand_symtabs_matching): Likewise.
11550 (dwarf2_initialize_objfile): Likewise.
11551 (dwarf2_build_psymtabs): Likewise.
11552 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
11553 this_cu.
11554 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
11555 (read_and_check_comp_unit_head): Likewise.
11556 (read_abbrev_offset): Likewise.
11557 (create_debug_type_hash_table): Likewise.
11558 (create_debug_types_hash_table): Likewise.
11559 (create_all_type_units): Replace objfile parameter with
11560 dwarf2_per_objfile.
11561 (add_type_unit): Add dwarf2_per_objfile parameter.
11562 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
11563 with dwarf2_per_objfile.
11564 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
11565 (lookup_dwp_signatured_type): Likewise.
11566 (lookup_signatured_type): Likewise.
11567 (read_cutu_die_from_dwo): Likewise.
11568 (init_tu_and_read_dwo_dies): Likewise.
11569 (init_cutu_and_read_dies): Likewise.
11570 (init_cutu_and_read_dies_no_follow): Likewise.
11571 (allocate_type_unit_groups_table): Add objfile parameter.
11572 (create_type_unit_group): Use dwarf2_per_objfile from cu.
11573 (get_type_unit_group): Likewise.
11574 (process_psymtab_comp_unit): Update call.
11575 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
11576 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
11577 (print_tu_stats): Likewise.
11578 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
11579 in void* parameter.
11580 (build_type_psymtabs): Change objfile parameter to
11581 dwarf2_per_objfile.
11582 (process_skeletonless_type_unit): Use dwarf2_per_objfile
11583 passed in void* parameter.
11584 (process_skeletonless_type_units): Change objfile parameter to
11585 dwarf2_per_objfile.
11586 (set_partial_user): Likewise.
11587 (dwarf2_build_psymtabs_hard): Likewise.
11588 (read_comp_units_from_section): Likewise.
11589 (create_all_comp_units): Likewise.
11590 (scan_partial_symbols): Update calls.
11591 (add_partial_symbol): Likewise.
11592 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
11593 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
11594 (process_queue): Add dwarf2_per_objfile parameter.
11595 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
11596 (compute_compunit_symtab_includes): Likewise.
11597 (process_cu_includes): Add dwarf2_per_objfile parameter.
11598 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
11599 (process_full_type_unit): Likewise.
11600 (process_imported_unit_die): Update call.
11601 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
11602 (read_file_scope): Likewise.
11603 (allocate_dwo_file_hash_table): Add objfile parameter.
11604 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
11605 (create_cus_hash_table): Likewise.
11606 (create_dwp_hash_table): Likewise.
11607 (create_dwo_unit_in_dwp_v1): Likewise.
11608 (create_dwp_v2_section): Likewise.
11609 (create_dwo_unit_in_dwp_v2): Likewise.
11610 (lookup_dwo_unit_in_dwp): Likewise.
11611 (try_open_dwop_file): Likewise.
11612 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
11613 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
11614 cleanup to include a reference to dwarf2_per_objfile.
11615 (open_dwp_file): Add dwarf2_per_objfile parameter.
11616 (open_and_init_dwp_file): Likewise.
11617 (get_dwp_file): Likewise.
11618 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
11619 (queue_and_load_all_dwo_tus): Update call.
11620 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
11621 data.
11622 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
11623 (dwarf2_ranges_process): Likewise.
11624 (dwarf2_get_pc_bounds): Likewise.
11625 (mark_common_block_symbol_computed): Likewise.
11626 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
11627 (dwarf2_read_abbrevs): Update call.
11628 (read_partial_die): Use dwarf2_per_objfile from cu.
11629 (find_partial_die): Likewise.
11630 (fixup_partial_die): Likewise.
11631 (read_attribute_value): Likewise.
11632 (read_indirect_string_at_offset_from): Add objfile parameter.
11633 (read_indirect_string_at_offset): Add dwarf2_per_objfile
11634 parameter.
11635 (read_indirect_string_from_dwz): Add objfile parameter.
11636 (read_indirect_string): Add objfile parameter.
11637 (read_addr_index_1): Add dwarf2_per_objfile parameter.
11638 (read_addr_index): Use dwarf2_per_objfile from cu.
11639 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
11640 call dw2_setup.
11641 (read_str_index): Use dwarf2_per_objfile from cu.
11642 (get_debug_line_section): Likewise.
11643 (read_formatted_entries): Add dwarf2_per_objfile parameter.
11644 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
11645 (new_symbol_full): Use dwarf2_per_objfile from cu.
11646 (build_error_marker_type): Likewise.
11647 (lookup_die_type): Likewise.
11648 (determine_prefix): Likewise.
11649 (follow_die_offset): Likewise.
11650 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
11651 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
11652 (dwarf2_fetch_die_type_sect_off): Likewise.
11653 (dwarf2_get_die_type): Likewise.
11654 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
11655 (get_signatured_type): Likewise.
11656 (get_DW_AT_signature_type): Likewise.
11657 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
11658 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
11659 (cu_debug_loc_section): Likewise.
11660 (fill_in_loclist_baton): Likewise.
11661 (dwarf2_symbol_mark_computed): Likewise.
11662 (dwarf2_find_containing_comp_unit): Change objfile parameter to
11663 dwarf2_per_objfile.
11664 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
11665 parameter.
11666 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
11667 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
11668 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
11669 (set_die_type): Use dwarf2_free_objfile from cu.
11670 (get_die_type_at_offset): Likewise.
11671 (dwarf2_per_objfile_free): Don't assign global variable.
11672 (debug_names) <constructor>: Add dwarf2_per_objfile
11673 parameter, update m_debugstrlookup construction.
11674 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
11675 parameter.
11676 <m_dwarf2_per_objfile>: New field.
11677 <lookup>: Use m_dwarf2_per_objfile.
11678 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
11679 (psyms_seen_size): Likewise.
11680 (write_gdbindex): Replace objfile parameter with
11681 dwarf2_per_objfile.
11682 (write_debug_names): Likewise.
11683 (write_psymtabs_to_index): Likewise.
11684 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
11685 calls.
11686
11687 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11688
11689 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
11690 <dwarf2_per_objfile>: New field.
11691 (struct dwarf2_per_cu_data) <objfile>: Remove.
11692 <dwarf2_per_objfile>: New field.
11693 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
11694 of objfile.
11695 (create_signatured_type_table_from_index): Likewise.
11696 (create_debug_type_hash_table): Likewise.
11697 (fill_in_sig_entry_from_dwo_entry): Likewise.
11698 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
11699 (create_type_unit_group): Assign dwarf2_per_objfile instead of
11700 objfile.
11701 (create_partial_symtab): Access objfile through
11702 dwarf2_per_objfile.
11703 (process_psymtab_comp_unit_reader): Likewise.
11704 (read_comp_units_from_section): Likewise.
11705 (scan_partial_symbols): Likewise.
11706 (add_partial_symbol): Likewise.
11707 (add_partial_subprogram): Likewise.
11708 (peek_die_abbrev): Likewise.
11709 (fixup_go_packaging): Likewise.
11710 (process_full_comp_unit): Likewise.
11711 (process_full_type_unit): Likewise.
11712 (process_imported_unit_die): Likewise.
11713 (dwarf2_compute_name): Likewise.
11714 (dwarf2_physname): Likewise.
11715 (read_import_statement): Likewise.
11716 (create_cus_hash_table): Assign dwarf2_physname instead of
11717 objfile.
11718 (read_func_scope): Access objfile through dwarf2_per_objfile.
11719 (read_lexical_block_scope): Likewise.
11720 (read_call_site_scope): Likewise.
11721 (read_variable): Likewise.
11722 (dwarf2_rnglists_process): Likewise.
11723 (dwarf2_ranges_process): Likewise.
11724 (dwarf2_ranges_read): Likewise.
11725 (dwarf2_record_block_ranges): Likewise.
11726 (dwarf2_add_field): Likewise.
11727 (dwarf2_add_member_fn): Likewise.
11728 (read_structure_type): Likewise.
11729 (process_structure_scope): Likewise.
11730 (read_enumeration_type): Likewise.
11731 (read_array_type): Likewise.
11732 (read_common_block): Likewise.
11733 (read_namespace_type): Likewise.
11734 (read_namespace): Likewise.
11735 (read_module_type): Likewise.
11736 (read_tag_pointer_type): Likewise.
11737 (read_tag_ptr_to_member_type): Likewise.
11738 (read_tag_string_type): Likewise.
11739 (read_subroutine_type): Likewise.
11740 (read_typedef): Likewise.
11741 (read_base_type): Likewise.
11742 (attr_to_dynamic_prop): Likewise.
11743 (read_subrange_type): Likewise.
11744 (read_unspecified_type): Likewise.
11745 (load_partial_dies): Likewise.
11746 (read_partial_die): Likewise.
11747 (find_partial_die): Likewise.
11748 (guess_partial_die_structure_name): Likewise.
11749 (fixup_partial_die): Likewise.
11750 (read_attribute_value): Likewise.
11751 (read_addr_index_from_leb128): Likewise.
11752 (dwarf2_read_addr_index): Likewise.
11753 (dwarf2_string_attr): Likewise.
11754 (lnp_state_machine::check_line_address): Likewise.
11755 (dwarf_decode_lines_1): Likewise.
11756 (dwarf_decode_lines): Likewise.
11757 (dwarf2_start_symtab): Likewise.
11758 (var_decode_location): Likewise.
11759 (new_symbol_full): Likewise.
11760 (dwarf2_const_value_data): Likewise.
11761 (dwarf2_const_value_attr): Likewise.
11762 (dwarf2_const_value): Likewise.
11763 (die_type): Likewise.
11764 (die_containing_type): Likewise.
11765 (lookup_die_type): Likewise.
11766 (guess_full_die_structure_name): Likewise.
11767 (anonymous_struct_prefix): Likewise.
11768 (dwarf2_name): Likewise.
11769 (follow_die_ref_or_sig): Likewise.
11770 (follow_die_offset): Likewise.
11771 (follow_die_ref): Likewise.
11772 (dwarf2_fetch_die_loc_sect_off): Likewise.
11773 (dwarf2_fetch_constant_bytes): Likewise.
11774 (dwarf2_fetch_die_type_sect_off): Likewise.
11775 (dwarf2_get_die_type): Likewise.
11776 (follow_die_sig): Likewise.
11777 (decode_locdesc): Likewise.
11778 (dwarf2_per_cu_objfile): Likewise.
11779 (dwarf2_per_cu_text_offset): Likewise.
11780 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
11781 objfile.
11782 (set_die_type): Access objfile through
11783 dwarf2_per_objfile.
11784
11785 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11786
11787 * valprint.c (converted_character_d): Remove typedef.
11788 (DEF_VEC_O (converted_character_d)): Remove.
11789 (count_next_character): Use std::vector.
11790 (print_converted_chars_to_obstack): Likewise.
11791 (generic_printstr): Likewise.
11792
11793 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11794
11795 * xml-support.h (struct gdb_xml_value): Add constructor.
11796 <value>: Change type to unique_xmalloc_ptr.
11797 (gdb_xml_value_s): Remove typedef.
11798 (DEF_VEC_O (gdb_xml_value_s)): Remove.
11799 (gdb_xml_element_start_handler): Change parameter type to
11800 std::vector.
11801 (xml_find_attribute): Likewise.
11802 * xml-support.c (xml_find_attribute): Change parameter type to
11803 std::vector and adjust.
11804 (gdb_xml_values_cleanup): Remove.
11805 (gdb_xml_parser::start_element): Adjust to std::vector.
11806 (xinclude_start_include): Change paraeter type to std::vector
11807 and adjust.
11808 * btrace.c (check_xml_btrace_version): Likewise.
11809 (parse_xml_btrace_block): Likewise.
11810 (parse_xml_btrace_pt_config_cpu): Likewise.
11811 (parse_xml_btrace_pt): Likewise.
11812 (parse_xml_btrace_conf_bts): Likewise.
11813 (parse_xml_btrace_conf_pt): Likewise.
11814 * memory-map.c (memory_map_start_memory): Likewise.
11815 (memory_map_start_property): Likewise.
11816 * osdata.c (osdata_start_osdata): Likewise.
11817 (osdata_start_item): Likewise.
11818 (osdata_start_column): Likewise.
11819 * remote.c (start_thread): Likewise.
11820 * solib-aix.c (library_list_start_library): Likewise.
11821 (library_list_start_list): Likewise.
11822 * solib-svr4.c (library_list_start_library): Likewise.
11823 (svr4_library_list_start_list): Likewise.
11824 * solib-target.c (library_list_start_segment): Likewise.
11825 (library_list_start_section): Likewise.
11826 (library_list_start_library): Likewise.
11827 (library_list_start_list): Likewise.
11828 * tracepoint.c (traceframe_info_start_memory): Likewise.
11829 (traceframe_info_start_tvar): Likewise.
11830 * xml-syscall.c (syscall_start_syscall): Likewise.
11831 * xml-tdesc.c (tdesc_start_target): Likewise.
11832 (tdesc_start_feature): Likewise.
11833 (tdesc_start_reg): Likewise.
11834 (tdesc_start_union): Likewise.
11835 (tdesc_start_struct): Likewise.
11836 (tdesc_start_flags): Likewise.
11837 (tdesc_start_enum): Likewise.
11838 (tdesc_start_field): Likewise.
11839 (tdesc_start_enum_value): Likewise.
11840 (tdesc_start_vector): Likewise.
11841
11842 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11843
11844 * extension.h (struct xmethod_worker) <clone>: Remove.
11845 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
11846 Remove.
11847 (python_xmethod_worker::clone): Remove.
11848 * valops.c (find_overload_match): Use std::move instead of
11849 clone.
11850
11851 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11852
11853 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
11854 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
11855 <free_xmethod_worker_data>: Remove.
11856 <get_matching_xmethod_workers>: Chance VEC to std::vector.
11857 <get_xmethod_arg_types>: Remove.
11858 <get_xmethod_result_type>: Remove.
11859 <invoke_xmethod>: Remove.
11860 * extension.c (new_xmethod_worker): Remove.
11861 (clone_xmethod_worker): Remove.
11862 (get_matching_xmethod_workers): Return void, pass std::vector by
11863 pointer.
11864 (get_xmethod_arg_types): Rename to...
11865 (xmethod_worker::get_arg_types): ... this, and adjust.
11866 (get_xmethod_result_type): Rename to...
11867 (xmethod_worker::get_result_type): ... this, and adjust.
11868 (invoke_xmethod): Remove.
11869 (free_xmethod_worker): Remove.
11870 (free_xmethod_worker_vec): Remove.
11871 * extension.h (enum ext_lang_rc): Move here from
11872 extension-priv.h.
11873 (struct xmethod_worker): Add constructor and destructor.
11874 <data>: Remove.
11875 <value>: Remove.
11876 <invoke, clone, do_get_result_type, do_get_arg_types>: New
11877 virtual pure methods.
11878 <get_arg_types, get_result_type>: New methods.
11879 (xmethod_worker_ptr): Remove typedef.
11880 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
11881 (xmethod_worker_vec): Remove typedef.
11882 (xmethod_worker_up): New typedef.
11883 (invoke_xmethod): Remove.
11884 (clone_xmethod_worker): Remove.
11885 (free_xmethod_worker): Remove.
11886 (free_xmethod_worker_vec): Remove.
11887 (get_xmethod_arg_types): Remove.
11888 (get_xmethod_result_type): Remove.
11889 * valops.c (find_method_list): Use std::vector, don't use
11890 intermediate vector.
11891 (value_find_oload_method_list): Use std::vector.
11892 (find_overload_match): Use std::vector.
11893 (find_oload_champ): Use std::vector.
11894 * value.c (value_free): Use operator delete.
11895 (value_of_xmethod): Rename to...
11896 (value_from_xmethod): ... this. Don't assign
11897 xmethod_worker::value, take rvalue-reference.
11898 (result_type_of_xmethod): Adjust.
11899 (call_xmethod): Adjust.
11900 * value.h: Include extension.h.
11901 (struct xmethod_worker): Don't forward-declare.
11902 (value_of_xmethod): Rename to...
11903 (value_from_xmethod): ... this, take rvalue-reference.
11904 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
11905 (struct python_xmethod_worker): ... this, add constructor and
11906 destructor.
11907 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
11908 (gdbpy_free_xmethod_worker_data): Rename to...
11909 (python_xmethod_worker::~python_xmethod_worker): ... this and
11910 adjust.
11911 (gdbpy_clone_xmethod_worker_data): Rename to...
11912 (python_xmethod_worker::clone): ... this and adjust.
11913 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
11914 temporary vector.
11915 (gdbpy_get_xmethod_arg_types): Rename to...
11916 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
11917 (gdbpy_get_xmethod_result_type): Rename to...
11918 (python_xmethod_worker::do_get_result_type): ... this and
11919 adjust.
11920 (gdbpy_invoke_xmethod): Rename to...
11921 (python_xmethod_worker::invoke): ... this and adjust.
11922 (new_python_xmethod_worker): Rename to...
11923 (python_xmethod_worker::python_xmethod_worker): ... this and
11924 adjust.
11925 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
11926 Remove.
11927 (gdbpy_free_xmethod_worker_data): Remove.
11928 (gdbpy_get_matching_xmethod_workers): Use std::vector.
11929 (gdbpy_get_xmethod_arg_types): Remove.
11930 (gdbpy_get_xmethod_result_type): Remove.
11931 (gdbpy_invoke_xmethod): Remove.
11932 * python/python.c (python_extension_ops): Remove obsolete
11933 callbacks.
11934
11935 2018-01-05 Pedro Alves <palves@redhat.com>
11936
11937 PR gdb/18653
11938 * common/signals-state-save-restore.c
11939 (save_original_signals_state): New parameter 'quiet'. Warn if we
11940 find a custom handler preinstalled, instead of internal erroring.
11941 But only warn if !quiet.
11942 * common/signals-state-save-restore.h
11943 (save_original_signals_state): New parameter 'quiet'.
11944 * main.c (captured_main_1): Move save_original_signals_state call
11945 after option handling, and pass QUIET.
11946
11947 2018-01-05 Pedro Alves <palves@redhat.com>
11948
11949 * spu-tdep.c (spu_catch_start): Pass
11950 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
11951
11952 2018-01-05 Pedro Alves <palves@redhat.com>
11953
11954 PR gdb/22670
11955 * ada-lang.c (literal_symbol_name_matcher): New function.
11956 (ada_get_symbol_name_matcher): Use it for
11957 symbol_name_match_type::SEARCH_NAME.
11958 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
11959 it down instead of assuming symbol_name_match_type::FULL.
11960 * block.h (block_lookup_symbol): New parameter 'match_type'.
11961 * c-valprint.c (print_unpacked_pointer): Use
11962 lookup_symbol_search_name instead of lookup_symbol.
11963 * compile/compile-object-load.c (get_out_value_type): Pass down
11964 symbol_name_match_type::SEARCH_NAME.
11965 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
11966 symbol_name_match_type::FULL.
11967 * cp-support.c (cp_get_symbol_name_matcher): Handle
11968 symbol_name_match_type::SEARCH_NAME.
11969 * infrun.c (insert_exception_resume_breakpoint): Use
11970 lookup_symbol_search_name.
11971 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
11972 * psymtab.c (maintenance_check_psymtabs): Use
11973 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
11974 * stack.c (print_frame_args): Use lookup_symbol_search_name and
11975 SYMBOL_SEARCH_NAME.
11976 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
11977 if symbol_name_match_type::SEARCH_NAME.
11978 (lookup_symbol_in_language): Pass down
11979 symbol_name_match_type::FULL.
11980 (lookup_symbol_search_name): New.
11981 (lookup_language_this): Pass down
11982 symbol_name_match_type::SEARCH_NAME.
11983 (lookup_symbol_aux, lookup_local_symbol): New parameter
11984 'match_type'. Pass it down.
11985 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
11986 (lookup_symbol_search_name): New declaration.
11987 (lookup_symbol_in_block): New 'match_type' parameter.
11988
11989 2018-01-05 Pedro Alves <palves@redhat.com>
11990
11991 PR gdb/22670
11992 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
11993 ada_lookup_symbol.
11994 (ada_lookup_symbol): Reimplement in terms of
11995 ada_lookup_symbol_list, bits factored out from
11996 ada_lookup_encoded_symbol.
11997
11998 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11999
12000 * ada-exp.y (write_object_renaming): When subscripting an array
12001 using a symbol as the index, pass the block in call to
12002 ada_lookup_encoded_symbol when looking that symbol up.
12003
12004 2018-01-05 Jerome Guitton <guitton@adacore.com>
12005
12006 * ada-lang.c (ada_array_length): Use ada_index_type instead of
12007 TYPE_INDEX_TYPE.
12008
12009 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12010
12011 * ada-lang.c (ada_to_fixed_value_create): Add handling of
12012 the case where VALUE_LVAL (val0) is not lval_memory.
12013
12014 2018-01-05 Xavier Roirand <roirand@adacore.com>
12015
12016 * ada-valprint.c (print_optional_low_bound): Handle
12017 character-indexed array printing like boolean-indexed array
12018 printing.
12019
12020 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12021
12022 * NEWS: Create a new section for the next release branch.
12023 Rename the section of the current branch, now that it has
12024 been cut.
12025
12026 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12027
12028 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
12029 * version.in: Bump version to 8.1.50.DATE-git.
12030
12031 2018-01-03 Xavier Roirand <roirand@adacore.com>
12032
12033 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
12034 Add field.
12035 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
12036 Add field.
12037 (default_exception_support_info) <catch_handlers_sym>: Add field.
12038 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
12039 (ada_exception_name_addr_1): Add "catch handlers" handling.
12040 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
12041 Update all callers.
12042 (create_excep_cond_exprs) <ex>: Add parameter.
12043 (re_set_exception): Update create_excep_cond_exprs call.
12044 (print_it_exception, print_one_exception, print_mention_exception)
12045 (print_recreate_exception): Add "catch handler" handling.
12046 (allocate_location_catch_handlers, re_set_catch_handlers)
12047 (check_status_catch_handlers, print_it_catch_handlers)
12048 (print_one_catch_handlers, print_mention_catch_handlers)
12049 (print_recreate_catch_handlers): New function.
12050 (catch_handlers_breakpoint_ops): New variable.
12051 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
12052 Add parameter. Add "catch handler" handling.
12053 (ada_exception_sym_name, ada_exception_breakpoint_ops):
12054 Add "catch handler" handling.
12055 (ada_exception_catchpoint_cond_string): Add "catch handler"
12056 handling.
12057 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
12058 call.
12059 (catch_ada_handlers_command): New function.
12060 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
12061 operations structure.
12062 (_initialize_ada_language): Add "catch handlers" command entry.
12063 * NEWS: Document "catch handlers" feature.
12064
12065 2018-01-02 Joel Brobecker <brobecker@adacore.com>
12066
12067 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
12068 account when creating the array type of the slice.
12069 (ada_value_slice): Likewise.
12070
12071 2018-01-02 Joel Brobecker <brobecker@adacore.com>
12072
12073 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
12074 New enum value.
12075 (create_array_type_with_stride): Add byte_stride_prop parameter.
12076 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
12077 New parameter. Update all callers in this file.
12078 (array_type_has_dynamic_stride): New function.
12079 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
12080 of arrays with dynamic byte strides.
12081 * dwarf2read.c (read_array_type): Add support for dynamic
12082 DW_AT_byte_stride attributes.
12083
12084 2018-01-02 Joel Brobecker <brobecker@adacore.com>
12085
12086 * dwarf2read.c (read_unspecified_type): Treat
12087 DW_TAG_enumeration_type DIEs from Ada units as stubs.
12088
12089 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12090
12091 Update copyright year range in all GDB files.
12092
12093 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12094
12095 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
12096 and gdb/testsuite/gdb.base/step-line.c.
12097
12098 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12099
12100 * copyright.py (main): Dump the contents of
12101 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
12102 even if BY_HAND is empty.
12103
12104 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12105
12106 * top.c (print_gdb_version): Update Copyright year in version
12107 message.
12108
12109 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12110
12111 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
12112
12113 For older changes see ChangeLog-2017.
12114 \f
12115 Local Variables:
12116 mode: change-log
12117 left-margin: 8
12118 fill-column: 74
12119 version-control: never
12120 coding: utf-8
12121 End:
This page took 0.307888 seconds and 4 git commands to generate.