Make program_space::deleted_solibs a vector of std::string
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2
3 * progspace.h (struct program_space) <deleted_solibs>: Change
4 type to std::vector<std::string>.
5 * progspace.c (clear_program_space_solib_cache): Adjust.
6 * breakpoint.c (print_solib_event): Adjust.
7 (check_status_catch_solib): Adjust.
8 * solib.c (update_solib_list): Adjust.
9 * ui-out.h (class ui_out) <field_string>: New overload.
10 * ui-out.c (ui_out::field_string): New overload.
11
12 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
13
14 * progspace.h (struct program_space): Add constructor and
15 destructor, initialize fields.
16 (add_program_space): Remove.
17 * progspace.c (add_program_space): Rename to...
18 (program_space::program_space): ... this.
19 (release_program_space): Rename to...
20 (program_space::~program_space): ... this.
21 (delete_program_space): Use delete to delete program_space.
22 (initialize_progspace): Use new to allocate program_space.
23 * inferior.c (add_inferior_with_spaces): Likewise.
24 (clone_inferior_command): Likewise.
25 * infrun.c (follow_fork_inferior): Likewise.
26 (handle_vfork_child_exec_or_exit): Likewise.
27
28 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
29
30 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
31 (delim_string_to_char_ptr_vec): Return std::vector of
32 gdb::unique_xmalloc_ptr.
33 (dirnames_to_char_ptr_vec_append): Take std::vector of
34 gdb::unique_xmalloc_ptr.
35 (dirnames_to_char_ptr_vec): Return std::vector of
36 gdb::unique_xmalloc_ptr.
37 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
38 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
39 (delim_string_to_char_ptr_vec): Return an std::vector of
40 gdb::unique_xmalloc_ptr, adjust the code.
41 (dirnames_to_char_ptr_vec_append): Take an std::vector of
42 gdb::unique_xmalloc_ptr, adjust the code.
43 (dirnames_to_char_ptr_vec): Return an std::vector of
44 gdb::unique_xmalloc_ptr, adjust the code.
45 * auto-load.c (auto_load_safe_path_vec): Change type to
46 std::vector of gdb::unique_xmalloc_ptr.
47 (auto_load_expand_dir_vars): Return an std::vector of
48 gdb::unique_xmalloc_ptr, adjust the code.
49 (auto_load_safe_path_vec_update): Adjust.
50 (filename_is_in_auto_load_safe_path_vec): Adjust.
51 (auto_load_objfile_script_1): Adjust.
52 * build-id.c (build_id_to_debug_bfd): Adjust.
53 * linux-thread-db.c (thread_db_load_search): Adjust.
54 * source.c (add_path): Adjust.
55 (openp): Adjust.
56 * symfile.c (find_separate_debug_file): Adjust.
57 * utils.c (do_free_char_ptr_vec): Remove.
58 (make_cleanup_free_char_ptr_vec): Remove.
59
60 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
61
62 PR gdb/22907
63 * common/pathstuff.c: Conditionally include "<windows.h>".
64
65 2018-03-01 Georg Sauthoff <mail@georg.so>
66
67 PR gdb/22888
68 * gcore.in: Quote variables and switch interpreter to bash.
69
70 2018-03-01 Tom Tromey <tom@tromey.com>
71
72 * dwarf2read.c (alloc_discriminant_info): Fix default_index
73 assertion. Add assertion for discriminant_index.
74 (quirk_rust_enum): Use correct base type name in univariant case.
75
76 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
77
78 * record.c (get_call_history_modifiers): Return a
79 record_print_flags.
80 (cmd_record_call_history): Adjust.
81 * record-btrace.c (record_btrace_call_history): Adjust.
82 (record_btrace_call_history_range): Adjust.
83 (record_btrace_call_history_from): Adjust.
84 * target-debug.h (target_debug_print_record_print_flags): New.
85 * target-delegates.c: Re-generate.
86 * target.c (target_call_history): Change flags type.
87 (target_call_history_from): Likewise.
88 (target_call_history_range): Likewise.
89 * target.h (struct target_ops) <target_call_history>: Likewise.
90 (target_call_history_from): Likewise.
91 (target_call_history_range): Likewise.
92
93 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
94 Simon Marchi <simon.marchi@polymtl.ca>
95
96 * common/common-utils.c: Include "sys/stat.h".
97 (is_regular_file): Move here from "source.c"; change return
98 type to "bool".
99 * common/common-utils.h (is_regular_file): New prototype.
100 * common/pathstuff.c (contains_dir_separator): New function.
101 * common/pathstuff.h (contains_dir_separator): New prototype.
102 * source.c: Don't include "sys/stat.h".
103 (is_regular_file): Move to "common/common-utils.c".
104
105 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
106
107 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
108 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
109 * auto-load.c: Include "common/pathstuff.h".
110 * common/common-def.h (current_directory): Move here.
111 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
112 function.
113 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
114 prototype.
115 * common/pathstuff.c: New file.
116 * common/pathstuff.h: New file.
117 * compile/compile.c: Include "common/pathstuff.h".
118 * defs.h (current_directory): Move to "common/common-defs.h".
119 * dwarf2read.c: Include "common/pathstuff.h".
120 * exec.c: Likewise.
121 * guile/scm-safe-call.c: Likewise.
122 * linux-thread-db.c: Likewise.
123 * main.c: Likewise.
124 * nto-tdep.c: Likewise.
125 * objfiles.c: Likewise.
126 * source.c: Likewise.
127 * symtab.c: Likewise.
128 * utils.c: Include "common/pathstuff.h".
129 (gdb_realpath): Move to "common/pathstuff.c".
130 (gdb_realpath_keepfile): Likewise.
131 (gdb_abspath): Likewise.
132 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
133 (gdb_realpath_keepfile): Likewise.
134 (gdb_abspath): Likewise.
135
136 2018-02-28 John Baldwin <jhb@FreeBSD.org>
137
138 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
139 wildcard process pid for super_resume for kernels with a
140 specific bug.
141
142 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
143
144 * compile/compile.c (get_args): Add additional comments
145 explaining function.
146
147 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
148 Tom Tromey <tom@tromey.com>
149
150 * target.h (memory_write_request_s): Remove typedef. Don't define
151 VEC.
152 (target_write_memory_blocks): Change argument to std::vector.
153 (struct memory_write_request): Add constructor.
154 * target-memory.c (compare_block_starting_address): Return bool.
155 Change argument types.
156 (claim_memory): Change arguments to use std::vector.
157 (split_regular_and_flash_blocks, blocks_to_erase)
158 (compute_garbled_blocks): Likewise.
159 (cleanup_request_data, cleanup_write_requests_vector): Remove.
160 (target_write_memory_blocks): Change argument to std::vector.
161 * symfile.c (struct load_section_data): Add constructor and
162 destructor. Use std::vector for "requests".
163 (struct load_progress_data): Add initializers.
164 (load_section_callback): Update. Use "new".
165 (clear_memory_write_data): Remove.
166 (generic_load): Update.
167
168 2018-02-27 Alan Hayward <alan.hayward@arm.com>
169
170 * arch/aarch64.h: Use common/tdesc.h.
171
172 2018-02-26 Maciej W. Rozycki <macro@mips.com>
173
174 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
175 architecture with a 64-bit ABI.
176
177 2018-02-26 Maciej W. Rozycki <macro@mips.com>
178
179 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
180 ahead of target description loading.
181
182 2018-02-26 Tom Tromey <tom@tromey.com>
183
184 * stack.c (backtrace_command_1): Update.
185 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
186 of "flags".
187 * python/py-framefilter.c (py_print_frame)
188 (gdbpy_apply_frame_filter): Change type of "flags".
189 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
190 of "flags".
191 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
192 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
193 * extension.h (enum frame_filter_flag): Rename from
194 frame_filter_flags.
195 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
196 (apply_ext_lang_frame_filter): Change type of "flags".
197 * extension.c (apply_ext_lang_frame_filter): Change type of
198 "flags".
199 * extension-priv.h (struct extension_language_ops)
200 <apply_frame_filter>: Change type of "flags".
201
202 2018-02-26 Tom Tromey <tom@tromey.com>
203
204 PR python/16497:
205 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
206 off-by-one in py_end computation.
207 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
208 PRINT_MORE_FRAMES.
209 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
210 constant.
211
212 2018-02-26 Tom Tromey <tom@tromey.com>
213
214 * dwarf2read.c (struct variant_field): New.
215 (struct nextfield) <variant>: New field.
216 (dwarf2_add_field): Handle DW_TAG_variant_part.
217 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
218 discriminated union.
219 (read_structure_type): Handle DW_TAG_variant_part.
220 (handle_struct_member_die): New function, extracted from
221 process_structure_scope. Handle DW_TAG_variant.
222 (process_structure_scope): Handle discriminated unions. Call
223 handle_struct_member_die.
224
225 2018-02-26 Tom Tromey <tom@tromey.com>
226
227 * rust-lang.h (rust_last_path_segment): Declare.
228 * rust-lang.c (rust_last_path_segment): Now public. Change
229 contract.
230 (struct disr_info): Remove.
231 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
232 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
233 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
234 (rust_enum_p, rust_enum_variant): New function.
235 (rust_underscore_fields): Remove "offset" parameter.
236 (rust_print_enum): New function.
237 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
238 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
239 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
240 enums.
241 (rust_internal_print_type): New function, from rust_print_type.
242 Remove enum code.
243 (rust_print_type): Call rust_internal_print_type.
244 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
245 Update enum handling.
246 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
247 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
248 (rust_union_quirks): New functions.
249 (process_full_comp_unit, process_full_type_unit): Call
250 rust_union_quirks.
251 (process_structure_scope): Update rust_unions if necessary.
252
253 2018-02-26 Tom Tromey <tom@tromey.com>
254
255 * value.h (value_union_variant): Declare.
256 * valops.c (value_union_variant): New function.
257 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
258 (struct discriminant_info): New.
259 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
260 enumerator.
261 (struct main_type) <flag_discriminated_union>: New field.
262
263 2018-02-26 Tom Tromey <tom@tromey.com>
264
265 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
266 unittests/unpack-selftests.c.
267 * unittests/unpack-selftests.c: New file.
268 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
269
270 2018-02-26 Yao Qi <yao.qi@linaro.org>
271
272 * dwarf2read.c (struct partial_die_info) <read>: New method.
273 (read_partial_die): Remove the declaration.
274 (load_partial_dies): Update.
275 (partial_die_info::partial_die_info):
276 (read_partial_die): Change it to partial_die_info::read.
277
278 2018-02-26 Yao Qi <yao.qi@linaro.org>
279
280 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
281 (fixup_partial_die): Remove declaration.
282 (scan_partial_symbols): Update.
283 (partial_die_parent_scope): Likewise.
284 (partial_die_full_name): Likewise.
285 (fixup_partial_die): Change it to partial_die_info::fixup.
286
287 2018-02-26 Yao Qi <yao.qi@linaro.org>
288
289 * dwarf2read.c (read_partial_die): Update the declaration.
290 (load_partial_dies): Caller update.
291 (read_partial_die): Remove one argument abbrev_len.
292
293 2018-02-26 Yao Qi <yao.qi@linaro.org>
294
295 * dwarf2read.c (struct partial_die_info): Add ctor, delete
296 assignment operator.
297 (load_partial_dies): Use ctor and copy ctor.
298 (read_partial_die): Update.
299 (dwarf2_cu::find_partial_die): Use ctor.
300
301 2018-02-26 Yao Qi <yao.qi@linaro.org>
302
303 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
304 (find_partial_die_in_comp_unit): Change it to
305 dwarf2_cu::find_partial_die.
306 (find_partial_die): Update.
307
308 2018-02-26 Yao Qi <yao.qi@linaro.org>
309
310 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
311 is NULL.
312
313 2018-02-26 Yao Qi <yao.qi@linaro.org>
314
315 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
316
317 2018-02-26 Alan Hayward <alan.hayward@arm.com>
318
319 * arch/amd64.h: Use common/tdesc.h.
320 * arch/i386.c: Likewise.
321 * arch/i386.h: Likewise.
322 * arch/tic6x.c: Likewise.
323 * arch/tdesc.h: Move file from here...
324 * common/tdesc.h: ...to here.
325 * features/aarch64-core.c: Regenerate.
326 * features/aarch64-fpu.c: Regenerate.
327 * features/i386/32bit-avx.c: Regenerate.
328 * features/i386/32bit-avx512.c: Regenerate.
329 * features/i386/32bit-core.c: Regenerate.
330 * features/i386/32bit-linux.c: Regenerate.
331 * features/i386/32bit-mpx.c: Regenerate.
332 * features/i386/32bit-pkeys.c: Regenerate.
333 * features/i386/32bit-sse.c: Regenerate.
334 * features/i386/64bit-avx.c: Regenerate.
335 * features/i386/64bit-avx512.c: Regenerate.
336 * features/i386/64bit-core.c: Regenerate.
337 * features/i386/64bit-linux.c: Regenerate.
338 * features/i386/64bit-mpx.c: Regenerate.
339 * features/i386/64bit-pkeys.c: Regenerate.
340 * features/i386/64bit-segments.c: Regenerate.
341 * features/i386/64bit-sse.c: Regenerate.
342 * features/i386/x32-core.c: Regenerate.
343 * features/tic6x-c6xp.c: Regenerate.
344 * features/tic6x-core.c: Regenerate.
345 * features/tic6x-gp.c: Regenerate.
346 * target-descriptions.c: Use common/tdesc.h.
347 * target-descriptions.h: Likewise.
348
349 2018-02-24 Tom Tromey <tom@tromey.com>
350
351 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
352 (try_thread_db_load_from_dir, thread_db_load_search): Use
353 std::string.
354 (info_auto_load_libthread_db_compare): Return bool. Change
355 argument types.
356 (info_auto_load_libthread_db): Use std::vector, std::string.
357 Remove cleanups.
358
359 2018-02-24 Tom Tromey <tom@tromey.com>
360
361 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
362 std::string.
363 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
364 std::string*.
365 * gdbarch.c: Rebuild.
366 * gdbarch.h: Rebuild.
367 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
368 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
369 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
370 std::string*.
371
372 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
373
374 * gdbtypes.h (sect_offset): Change type to uint64_t.
375 (sect_offset_str): New function.
376 * dwarf2read.c (create_addrmap_from_aranges): Use
377 sect_offset_str.
378 (error_check_comp_unit_head): Likewise.
379 (create_debug_type_hash_table): Likewise.
380 (read_cutu_die_from_dwo): Likewise.
381 (init_cutu_and_read_dies): Likewise.
382 (init_cutu_and_read_dies_no_follow): Likewise.
383 (process_psymtab_comp_unit_reader): Likewise.
384 (partial_die_parent_scope): Likewise.
385 (peek_die_abbrev): Likewise.
386 (process_queue): Likewise.
387 (dwarf2_physname): Likewise.
388 (read_namespace_alias): Likewise.
389 (read_import_statement): Likewise.
390 (create_dwo_cu_reader): Likewise.
391 (create_cus_hash_table): Likewise.
392 (lookup_dwo_cutu): Likewise.
393 (inherit_abstract_dies): Likewise.
394 (read_func_scope): Likewise.
395 (read_call_site_scope): Likewise.
396 (dwarf2_add_member_fn): Likewise.
397 (read_common_block): Likewise.
398 (read_module_type): Likewise.
399 (read_typedef): Likewise.
400 (read_subrange_type): Likewise.
401 (load_partial_dies): Likewise.
402 (read_partial_die): Likewise.
403 (find_partial_die): Likewise.
404 (read_str_index): Likewise.
405 (dwarf2_string_attr): Likewise.
406 (build_error_marker_type): Likewise.
407 (lookup_die_type): Likewise.
408 (dump_die_shallow): Likewise.
409 (follow_die_ref): Likewise.
410 (dwarf2_fetch_die_loc_sect_off): Likewise.
411 (dwarf2_fetch_constant_bytes): Likewise.
412 (follow_die_sig): Likewise.
413 (get_signatured_type): Likewise.
414 (get_DW_AT_signature_type): Likewise.
415 (dwarf2_find_containing_comp_unit): Likewise.
416 (set_die_type): Likewise.
417
418 2018-02-21 John Baldwin <jhb@FreeBSD.org>
419
420 * arch/aarch64.c: Include "common-defs.h".
421 * arch/amd64.c: Likewise.
422 * arch/i386.c: Likewise.
423
424 2018-02-21 Tom Tromey <tom@tromey.com>
425
426 * value.h: (extract_field_op): Update.
427 * eval.c (extract_field_op): Return a const char *.
428 * expression.h (parse_expression_for_completion): Update.
429 * completer.c (complete_expression): Update.
430 (add_struct_fields): Make fieldname const.
431 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
432 (mark_completion_tag, parse_exp_in_context_1): Update.
433 (parse_expression_for_completion): Change "name" to
434 unique_xmalloc_ptr*.
435
436 2018-02-21 Tom Tromey <tom@tromey.com>
437
438 * infcall.c (call_function_by_hand_dummy): Use std::vector.
439
440 2018-02-21 Yao Qi <yao.qi@linaro.org>
441
442 * avr-tdep.c (avr_read_pc): Change parameter type to
443 readable_regcache.
444 * gdbarch.sh (read_pc): Likewise.
445 * gdbarch.c: Re-generated.
446 * gdbarch.h: Re-generated.
447 * hppa-tdep.c (hppa_read_pc): Change parameter type to
448 readable_regcache.
449 * ia64-tdep.c (ia64_read_pc): Likewise.
450 * mips-tdep.c (mips_read_pc): Likewise.
451 * spu-tdep.c (spu_read_pc): Likewise.
452
453 2018-02-21 Yao Qi <yao.qi@linaro.org>
454
455 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
456 * regcache-dump.c: New file.
457 * regcache.c: Move register_dump to regcache-dump.c.
458 (maintenance_print_registers): Likewise.
459 (maintenance_print_raw_registers): Likewise.
460 (maintenance_print_cooked_registers): Likewise.
461 (maintenance_print_register_groups): Likewise.
462 (maintenance_print_remote_registers): Likewise.
463 (_initialize_regcache): Likewise.
464 * regcache.h (register_dump): Moved from regcache.c.
465
466 2018-02-21 Yao Qi <yao.qi@linaro.org>
467
468 * regcache.c (regcache::regcache): Update.
469 (regcache::invalidate): Move it to detached_regcache::invalidate.
470 (get_thread_arch_aspace_regcache): Update.
471 (regcache::raw_update): Update.
472 (regcache::cooked_read): Remove some code.
473 (regcache::cooked_read_value): Likewise.
474 (regcache::raw_write): Remove assert on m_readonly_p.
475 (regcache::raw_supply_integer): Move it to
476 detached_regcache::raw_supply_integer.
477 (regcache::raw_supply_zeroed): Likewise.
478 * regcache.h (detached_regcache) <raw_supply_integer>: New
479 declaration.
480 <raw_supply_zeroed, invalidate>: Likewise.
481 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
482 <invalidate>: Likewise.
483 <m_readonly_p>: Removed.
484
485 2018-02-21 Yao Qi <yao.qi@linaro.org>
486
487 * infcmd.c (get_return_value): Let stop_regs point to
488 get_current_regcache.
489 * regcache.c (regcache::regcache): Remove.
490 (register_dump_reg_buffer): New class.
491 (regcache_print): Adjust.
492 * regcache.h (regcache): Remove constructors.
493
494 2018-02-21 Yao Qi <yao.qi@linaro.org>
495
496 * regcache.c (class register_dump): New class.
497 (register_dump_regcache, register_dump_none): New class.
498 (register_dump_remote, register_dump_groups): New class.
499 (regcache_print): Update.
500 * regcache.h (regcache_dump_what): Move it to regcache.c.
501 (regcache) <dump>: Remove.
502
503 2018-02-21 Yao Qi <yao.qi@linaro.org>
504
505 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
506 reg_buffer_rw *.
507 (jit_unwind_reg_set_impl): Call raw_supply.
508 (jit_frame_sniffer): Use reg_buffer_rw.
509 * record-full.c (record_full_core_regbuf): Change its type.
510 (record_full_core_open_1): Use reg_buffer_rw.
511 (record_full_close): Likewise.
512 (record_full_core_fetch_registers): Use regcache->raw_supply.
513 (record_full_core_store_registers): Likewise.
514 * regcache.c (regcache::get_register_status): Move it to
515 reg_buffer.
516 (regcache_raw_set_cached_value): Remove.
517 (regcache::raw_set_cached_value): Remove.
518 (regcache::raw_write): Call raw_supply.
519 (regcache::raw_supply): Move it to reg_buffer_rw.
520 * regcache.h (regcache_raw_set_cached_value): Remove.
521 (reg_buffer_rw): New class.
522
523 2018-02-21 Yao Qi <yao.qi@linaro.org>
524
525 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
526 readonly_detached_regcache.
527 (dummy_frame_prev_register): Use regcache->cooked_read.
528 * frame.c (frame_save_as_regcache): Change return type.
529 (frame_pop): Update.
530 * frame.h (frame_save_as_regcache): Update declaration.
531 * inferior.h (get_infcall_suspend_state_regcache): Update
532 declaration.
533 * infrun.c (infcall_suspend_state) <registers>: use
534 readonly_detached_regcache.
535 (save_infcall_suspend_state): Don't use regcache_dup.
536 (get_infcall_suspend_state_regcache): Change return type.
537 * linux-fork.c (struct fork_info) <savedregs>: Change to
538 readonly_detached_regcache.
539 <pc>: New field.
540 (fork_save_infrun_state): Don't use regcache_dup.
541 (info_checkpoints_command): Adjust.
542 * mi/mi-main.c (register_changed_p): Update declaration.
543 (mi_cmd_data_list_changed_registers): Use
544 readonly_detached_regcache.
545 (register_changed_p): Change parameter type to
546 readonly_detached_regcache.
547 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
548 readonly_detached_regcache.
549 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
550 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
551 New.
552 (regcache::save): Move it to reg_buffer.
553 (regcache::restore): Change parameter type.
554 (regcache_dup): Remove.
555 * regcache.h (reg_buffer) <save>: New method.
556 (readonly_detached_regcache): New class.
557 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
558 readonly_detached_regcache.
559 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
560
561 2018-02-21 Yao Qi <yao.qi@linaro.org>
562
563 * frame.c (frame_save_as_regcache): Use regcache method save.
564 (frame_pop): Use regcache method restore.
565 * infrun.c (restore_infcall_suspend_state): Likewise.
566 * linux-fork.c (fork_load_infrun_state): Likewise.
567 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
568 save.
569 * regcache.c (regcache_save): Remove.
570 (regcache::restore): More asserts.
571 (regcache_cpy): Remove.
572 * regcache.h (regcache_save): Remove the declaration.
573 (regcache::restore): Move from private to public.
574 Remove the friend declaration of regcache_cpy.
575 (regcache_cpy): Remove declaration.
576
577 2018-02-21 Yao Qi <yao.qi@linaro.org>
578
579 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
580 parameter type to 'readable_regcache *'.
581 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
582 * arm-tdep.c (arm_neon_quad_read): Likewise.
583 (arm_pseudo_read): Likewise.
584 * avr-tdep.c (avr_pseudo_register_read): Likewise.
585 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
586 * frv-tdep.c (frv_pseudo_register_read): Likewise.
587 * gdbarch.c: Re-generated.
588 * gdbarch.h: Re-generated.
589 * gdbarch.sh (pseudo_register_read): Change parameter type to
590 'readable_regcache *'.
591 (pseudo_register_read_value): Likewise.
592 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
593 (h8300_pseudo_register_read): Likewise.
594 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
595 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
596 (i386_pseudo_register_read_into_value): Likewise.
597 (i386_pseudo_register_read_value): Likewise.
598 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
599 declaration.
600 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
601 * m32c-tdep.c (m32c_raw_read): Likewise.
602 (m32c_read_flg): Likewise.
603 (m32c_banked_register): Likewise.
604 (m32c_banked_read): Likewise.
605 (m32c_sb_read): Likewise.
606 (m32c_part_read): Likewise.
607 (m32c_cat_read): Likewise.
608 (m32c_r3r2r1r0_read): Likewise.
609 (m32c_pseudo_register_read): Likewise.
610 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
611 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
612 (mep_pseudo_cr64_read): Likewise.
613 (mep_pseudo_register_read): Likewise.
614 * mips-tdep.c (mips_pseudo_register_read): Likewise.
615 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
616 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
617 * regcache.c (regcache::raw_read): Move it to readable_regcache.
618 (regcache::cooked_read): Likewise.
619 (regcache::cooked_read_value): Likewise.
620 (regcache_cooked_read_signed):
621 (regcache::cooked_read): Likewise.
622 * regcache.h (readable_regcache): New class.
623 (regcache): Inherit readable_regcache. Move some methods to
624 readable_regcache.
625 * rl78-tdep.c (rl78_pseudo_register_read): Change
626 parameter type to 'readable_regcache *'.
627 * rs6000-tdep.c (do_regcache_raw_read): Remove.
628 (e500_pseudo_register_read): Change parameter type to
629 'readable_regcache *'.
630 (dfp_pseudo_register_read): Likewise.
631 (vsx_pseudo_register_read): Likewise.
632 (efpr_pseudo_register_read): Likewise.
633 * s390-tdep.c (s390_pseudo_register_read): Likewise.
634 * sh-tdep.c (sh_pseudo_register_read): Likewise.
635 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
636 (sh64_pseudo_register_read): Likewise.
637 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
638 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
639 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
640 (spu_pseudo_register_read): Likewise.
641 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
642 (xtensa_pseudo_register_read): Likewise.
643
644 2018-02-21 Yao Qi <yao.qi@linaro.org>
645
646 * regcache.c (regcache::regcache): Call reg_buffer ctor.
647 (regcache::arch): Move it to reg_buffer::arch.
648 (regcache::register_buffer): Likewise.
649 (regcache::assert_regnum): Likewise.
650 (regcache::num_raw_registers): Likewise.
651 * regcache.h (reg_buffer): New class.
652 (regcache): Inherit reg_buffer.
653
654 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
655
656 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
657 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
658
659 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
660
661 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
662
663 2018-02-19 Alan Hayward <alan.hayward@arm.com>
664
665 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
666 (SFILES): Remove common/*.c files.
667 (COMMON_OBS): Remove some *.o files built from common/*.c files.
668 * common/common.host: Add common reference.
669 * configure.ac: Likewise.
670 * configure: Regenerate.
671
672 2018-02-16 Yao Qi <yao.qi@linaro.org>
673
674 * block.c (block_namespace_info): Inherit allocate_on_obstack.
675 (block_initialize_namespace): Use new.
676 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
677 (dwarf2_free_objfile): Use delete.
678 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
679 (copy_type_recursive): Use new.
680 * gdb_obstack.h (allocate_on_obstack): New.
681
682 2018-02-15 Yao Qi <yao.qi@linaro.org>
683
684 PR gdb/22849
685 * inferior.c (exit_inferior_1): Reset inf->control.
686
687 2018-02-15 Joel Brobecker <brobecker@adacore.com>
688
689 * ada-lang.c (ada_to_fixed_value_create): Delete advance
690 declaration.
691
692 2018-02-14 Pedro Alves <palves@redhat.com>
693
694 * frame-unwind.c (frame_unwind_try_unwinder): Always call
695 frame_cleanup_after_sniffer on exception.
696
697 2018-02-14 Tom Tromey <tom@tromey.com>
698
699 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
700 const.
701 (solib_bfd_open): Make pathname const.
702 * solib.c (solib_bfd_open): Make pathname const.
703 * solib-spu.c (spu_bfd_fopen): Make name const.
704 (spu_bfd_open): Make pathname const.
705 * solib-darwin.c (darwin_bfd_open): Make pathname const.
706 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
707
708 2018-02-14 Tom Tromey <tom@tromey.com>
709
710 * symfile.c (symfile_bfd_open): Update.
711 * source.h (openp, source_full_path_of, find_and_open_source):
712 Change argument type to unique_xmalloc_ptr.
713 * source.c (openp): Take a unique_xmalloc_ptr.
714 (source_full_path_of, find_and_open_source): Likewise.
715 (open_source_file, symtab_to_fullname): Update.
716 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
717 unique_xmalloc_ptr.
718 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
719 (exec_file_find): Update.
720 * psymtab.c (psymtab_to_fullname): Update.
721 * nto-tdep.h (nto_find_and_open_solib): Update.
722 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
723 unique_xmalloc_ptr.
724 * exec.c (exec_file_attach): Update.
725 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
726 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
727
728 2018-02-14 Tom Tromey <tom@tromey.com>
729
730 * solib.c: Include source.h.
731 * nto-tdep.c: Include source.h.
732 * mi/mi-cmd-env.c: Include source.h.
733 * infcmd.c: Include source.h.
734 * exec.c: Include source.h.
735 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
736 (add_path, directory_switch, source_path, init_source_path): Move
737 declarations...
738 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
739 (add_path, directory_switch, source_path, init_source_path):
740 ...here.
741
742 2018-02-14 Tom Tromey <tom@tromey.com>
743
744 * solist.h (exec_file_find, solib_find): Return
745 unique_xmalloc_ptr.
746 (solib_bfd_fopen): Take a const char *.
747 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
748 (exec_file_find, solib_find): Likewise.
749 (solib_bfd_fopen): Do not take ownership of "pathname".
750 (solib_bfd_open): Use unique_xmalloc_ptr.
751 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
752 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
753 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
754 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
755
756 2018-02-14 Joel Brobecker <brobecker@adacore.com>
757
758 * ada-lang.c (name_match_type_from_name): Remove reference to
759 ada_name_for_lookup in function's documentation.
760 * ada-lang.h (ada_name_for_lookup): Delete declaration.
761
762 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
763
764 * defs.h (enum openp_flags): New enum.
765 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
766 Move to enum openp_flags.
767 (openp_flags): New enum flags.
768 (openp): Change parameter type to openp_flags.
769 * source.c (openp): Change parameter type to openp_flags.
770 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
771 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
772
773 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
774
775 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
776 per-command.
777
778 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
779
780 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
781 into...
782 (class dwarf2_queue_guard): ...the destructor of this new class.
783 (dw2_do_instantiate_symtab): Create instance of the new class
784 dwarf2_queue_guard, remove cleanup.
785
786 2018-02-09 Tom Tromey <tom@tromey.com>
787
788 * source.c (find_source_lines): Don't reference past the end of
789 the vector.
790
791 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
792
793 * remote.c (remote_btrace_maybe_reopen): Change error message.
794 * btrace.c (btrace_enable): Likewise.
795 (parse_xml_btrace): Likewise.
796 (parse_xml_btrace_conf): Likewise.
797
798 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
799
800 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
801 (linux_enable_pt, linux_enable_bts): Call
802 diagnose_perf_event_open_fail.
803
804 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
805
806 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
807 Remove parameter and change return type. Update callers. Move it.
808 (linux_enable_bts, linux_enable_pt): Improve error message.
809 (linux_enable_pt): Remove zero buffer size check.
810 (linux_enable_btrace): Improve error messages. Remove NULL return
811 check.
812
813 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
814
815 * btrace.c (btrace_enable): Remove target_supports_btrace call.
816 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
817 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
818 (linux_supports_pt, linux_supports_btrace): Remove.
819 (linux_enable_bts): Call cpu_supports_bts.
820 * nat/linux-btrace.h (linux_supports_btrace): Remove.
821 * remote.c (remote_supports_btrace): Remove.
822 (init_remote_ops): Remove remote_supports_btrace.
823 * target-delegates.c: Regenerated.
824 * target.c (target_supports_btrace): Remove.
825 * target.h (target_ops) <to_supports_btrace>: Remove
826 (target_supports_btrace): Remove.
827 * x86-linux-nat.c (x86_linux_create_target): Remove
828 linux_supports_btrace.
829
830 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
831
832 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
833 btrace failed.
834 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
835 exception and use message in own exception.
836
837 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
838
839 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
840 (perf_event_pt_event_type): Use gdb_file_up.
841 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
842 scoped_fd, and scoped_mmap.
843
844 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
845
846 * common/scoped_mmap.h: New.
847 * unittests/scoped_mmap-selftest.c: New.
848 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
849 unittests/scoped_mmap-selftest.c.
850
851 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
852
853 * common/scoped_fd.h: New.
854 * unittests/scoped_fd-selftest.c: New.
855 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
856 unittests/scoped_fd-selftest.c.
857
858 2018-02-09 Tom Tromey <tom@tromey.com>
859
860 * auto-load.c (auto_load_section_scripts): Use
861 gdb::unique_xmalloc_ptr.
862
863 2018-02-09 Tom Tromey <tom@tromey.com>
864
865 * auto-load.c (execute_script_contents): Use std::string.
866
867 2018-02-09 Joel Brobecker <brobecker@adacore.com>
868
869 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
870 Python function, rather than a new command.
871
872 2018-02-08 Tom Tromey <tom@tromey.com>
873
874 * solib.c (solib_find_1): Use std::string.
875 (solib_bfd_fopen): Use unique_xmalloc_ptr.
876
877 2018-02-08 Tom Tromey <tom@tromey.com>
878
879 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
880
881 2018-02-08 Tom Tromey <tom@tromey.com>
882
883 * source.c (find_source_lines): Use gdb::def_vector.
884
885 2018-02-08 Tom Tromey <tom@tromey.com>
886
887 * macrocmd.c (struct temporary_macro_definition): New.
888 (macro_define_command): Use temporary_macro_definition. Remove
889 cleanups.
890 (free_macro_definition_ptr): Remove.
891
892 2018-02-08 Tom Tromey <tom@tromey.com>
893
894 * macroexp.c (maybe_expand): Use std::string.
895
896 2018-02-08 Tom Tromey <tom@tromey.com>
897
898 * macroexp.c (struct macro_buffer): Add initializers for some
899 members.
900 (init_buffer, init_shared_buffer, free_buffer)
901 (free_buffer_return_text): Remove.
902 (macro_buffer): New constructors.
903 (~macro_buffer): New destructor.
904 (macro_buffer::set_shared): New method.
905 (macro_buffer::resize_buffer, macro_buffer::appendc)
906 (macro_buffer::appendmem): Now methods, not free functions.
907 (set_token, append_tokens_without_splicing, stringify)
908 (macro_stringify): Update.
909 (gather_arguments): Change return type. Remove argc_p argument,
910 add args_ptr argument. Use std::vector.
911 (substitute_args): Remove argc argument. Accept std::vector.
912 (expand): Update. Use std::vector.
913 (scan, macro_expand, macro_expand_next): Update.
914
915 2018-02-08 Tom Tromey <tom@tromey.com>
916
917 * symtab.c (default_collect_symbol_completion_matches_break_on):
918 Use unique_xmalloc_ptr.
919 * macroscope.h: (sal_macro_scope, user_macro_scope)
920 (default_macro_scope): Return unique_xmalloc_ptr.
921 * macroscope.c (sal_macro_scope, user_macro_scope)
922 (default_macro_scope): Return unique_xmalloc_ptr.
923 * macroexp.h (macro_expand, macro_expand_once): Return
924 unique_xmalloc_ptr.
925 * macroexp.c (macro_expand, macro_expand_once): Return
926 unique_xmalloc_ptr.
927 * macrocmd.c (macro_expand_command, macro_expand_once_command)
928 (info_macro_command, info_macros_command): Use
929 unique_xmalloc_ptr.
930 * compile/compile-c-support.c (write_macro_definitions): Use
931 unique_xmalloc_ptr.
932 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
933
934 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
935
936 * value.c (value_static_field): Assign field type instead of
937 containing type when returning an optimized out value.
938
939 2018-02-06 Yao Qi <yao.qi@linaro.org>
940
941 * ft32-tdep.c (ft32_read_pc): Remove.
942 (ft32_write_pc): Remove.
943 (ft32_gdbarch_init): Update.
944 * m32r-tdep.c (m32r_read_pc): Remove.
945 (m32r_gdbarch_init): Update.
946 * mep-tdep.c (mep_read_pc): Remove.
947 (mep_gdbarch_init): Update.
948 * microblaze-tdep.c (microblaze_write_pc): Remove.
949 (microblaze_gdbarch_init): Update.
950 * mn10300-tdep.c (mn10300_read_pc): Remove.
951 (mn10300_write_pc): Remove.
952 (mn10300_gdbarch_init): Update.
953 * moxie-tdep.c (moxie_read_pc): Remove.
954 (moxie_write_pc): Remove.
955 (moxie_gdbarch_init): Update.
956
957 2018-02-06 Yao Qi <yao.qi@linaro.org>
958
959 * expprint.c (print_subexp_standard): Handle
960 OP_F77_UNDETERMINED_ARGLIST.
961 (dump_subexp_body_standard): Likewise.
962
963 2018-02-05 Alan Hayward <alan.hayward@arm.com>
964
965 * target-descriptions.c (tdesc_element_visitor) Add empty
966 implementations.
967 (tdesc_type): Move make_gdb_type from here.
968 (tdesc_type_builtin): Likewise.
969 (tdesc_type_vector): Likewise.
970 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
971 (make_gdb_type_struct): Move from tdesc_type_with_fields.
972 (make_gdb_type_union): Likewise.
973 (make_gdb_type_flags): Likewise.
974 (make_gdb_type_enum): Likewise.
975 (make_gdb_type): New function.
976 (tdesc_register_type): Use static make_gdb_type.
977
978 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
979
980 * infcmd.c (default_print_one_register_info): Align natural-format
981 column values consistently one under another.
982 (pad_to_column): New function.
983
984 2018-02-05 Joel Brobecker <brobecker@adacore.com>
985
986 * dwarf2read.c (dwarf2_physname): Move commment.
987
988 2018-02-01 Leszek Swirski <leszeks@google.com>
989
990 * varobj.c (varobj_formatted_print_options): Allow recursive
991 pretty printing if pretty printing is enabled.
992
993 2018-02-01 Leszek Swirski <leszeks@google.com>
994
995 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
996 names after a structop as a filename.
997
998 2018-02-01 Yao Qi <yao.qi@linaro.org>
999
1000 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
1001 (arm_record_coproc_data_proc): Likewise.
1002
1003 2018-02-01 Yao Qi <yao.qi@linaro.org>
1004
1005 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
1006
1007 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
1008
1009 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
1010 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
1011
1012 2018-01-31 Pedro Alves <palves@redhat.com>
1013
1014 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
1015 * inflow.c (child_terminal_save_inferior): Wrap reference to
1016 tcgetpgrp in HAVE_TERMIOS_H.
1017 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
1018 _WIN32.
1019 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
1020 always iterate over all inferiors.
1021 (gdbsim_cntrl_c): Adjust.
1022 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
1023
1024 2018-01-31 Joel Brobecker <brobecker@adacore.com>
1025
1026 * gdbtypes.c (lookup_array_range_type): Make sure the array's
1027 index type is objfile-owned if the element type is as well.
1028
1029 2018-01-31 Joel Brobecker <brobecker@adacore.com>
1030
1031 GDB 8.1 released.
1032
1033 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
1034
1035 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
1036 "features/s390x-linux64.c".
1037 (_initialize_s390_linux_tdep): Remove initialization of tdescs
1038 s390_linux32 and s390x_linux64.
1039 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
1040 default tdesc.
1041 * s390-tdep.c: Include "features/s390-linux32.c" and
1042 "features/s390x-linux64.c".
1043 (s390_tdesc_valid): Add check for tdesc_has_registers.
1044 (s390_gdbarch_init): Make sure there is always a valid tdesc.
1045 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
1046 tdesc_s390x_linux64.
1047 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
1048 tdesc_s390x_linux64 to...
1049 * s390-tdep.h: ...here.
1050
1051 2018-01-30 Pedro Alves <palves@redhat.com>
1052
1053 PR gdb/13211
1054 * config.in, configure: Regenerate.
1055 * configure.ac: Check for getpgid.
1056 * go32-nat.c (go32_pass_ctrlc): New.
1057 (go32_target): Install it.
1058 * inf-child.c (inf_child_target): Install
1059 child_terminal_save_inferior, child_pass_ctrlc and
1060 child_interrupt.
1061 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
1062 (inf_ptrace_target): No longer install it.
1063 * infcmd.c (interrupt_target_1): Adjust.
1064 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
1065 (child_interrupt): Declare.
1066 (inferior::terminal_state): New.
1067 * inflow.c (struct terminal_info): Update comments.
1068 (inferior_process_group): Delete.
1069 (terminal_is_ours): Delete.
1070 (gdb_tty_state): New.
1071 (child_terminal_init): Adjust.
1072 (is_gdb_terminal, sharing_input_terminal_1)
1073 (sharing_input_terminal): New functions.
1074 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
1075 Set the process's actual process group in the foreground if
1076 possible. Handle is_ours_for_output/is_ours distinction. Don't
1077 mark terminal as the inferior's if not sharing GDB's terminal.
1078 Don't check attach_flag.
1079 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
1080 pass down a target_terminal_state.
1081 (child_terminal_save_inferior): New, factored out from ...
1082 (child_terminal_ours_1): ... this. Handle
1083 target_terminal_state::is_ours_for_output.
1084 (child_interrupt, child_pass_ctrlc): New.
1085 (inflow_inferior_exit): Clear the inferior's terminal_state.
1086 (copy_terminal_info): Copy the inferior's terminal state.
1087 (_initialize_inflow): Remove reference to terminal_is_ours.
1088 * inflow.h (inferior_process_group): Delete.
1089 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
1090 * procfs.c (procfs_target): Don't install procfs_interrupt.
1091 (procfs_interrupt): Delete.
1092 * remote.c (remote_serial_quit_handler): Adjust.
1093 (remote_interrupt): Remove ptid parameter. Adjust.
1094 * target-delegates.c: Regenerate.
1095 * target.c: Include "terminal.h".
1096 (target_terminal::terminal_state): Rename to ...
1097 (target_terminal::m_terminal_state): ... this.
1098 (target_terminal::init): Adjust.
1099 (target_terminal::inferior): Adjust to per-inferior
1100 terminal_state.
1101 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
1102 (target_terminal::ours, target_terminal::ours_for_output): Use
1103 target_terminal_is_ours_kind.
1104 (target_interrupt): Remove ptid parameter. Adjust.
1105 (default_target_pass_ctrlc): Adjust.
1106 * target.h (target_ops::to_terminal_save_inferior): New field.
1107 (target_ops::to_interrupt): Remove ptid_t parameter.
1108 (target_interrupt): Remove ptid_t parameter. Update comment.
1109 (target_pass_ctrlc): Update comment.
1110 * target/target.h (target_terminal_state): New scoped enum,
1111 factored out of ...
1112 (target_terminal::terminal_state): ... here.
1113 (target_terminal::inferior): Update comments.
1114 (target_terminal::restore_inferior): New.
1115 (target_terminal::is_inferior, target_terminal::is_ours)
1116 (target_terminal::is_ours_for_output): Adjust.
1117 (target_terminal::scoped_restore_terminal_state): Adjust to
1118 rename, and call restore_inferior() instead of inferior().
1119 (target_terminal::scoped_restore_terminal_state::m_state): Change
1120 type.
1121 (target_terminal::terminal_state): Rename to ...
1122 (target_terminal::m_terminal_state): ... this and change type.
1123
1124 2018-01-30 Pedro Alves <palves@redhat.com>
1125
1126 * linux-nat.c (wait_for_signal): New function.
1127 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
1128 directly.
1129 (async_terminal_is_ours)
1130 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
1131 (linux_nat_add_target): Don't override
1132 to_terminal_inferior/to_terminal_ours.
1133
1134 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
1135
1136 * remote.c (remote_follow_fork): Don't call "detach_inferior".
1137
1138 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
1139
1140 * dwarf2read.c (free_dwo_files): Add forward-declaration.
1141 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
1142 dwarf2_per_objfile_free here.
1143 (dwarf2_per_objfile_free): Remove.
1144 (_initialize_dwarf2_read): Don't register
1145 dwarf2_per_objfile_free as a registry cleanup.
1146
1147 2018-01-27 Eli Zaretskii <eliz@gnu.org>
1148
1149 Avoid compilation errors in MinGW native builds
1150
1151 The error is triggered by including python-internal.h, and the
1152 error message is:
1153
1154 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
1155 from build-gnulib/import/math.h:27,
1156 from d:/usr/Python26/include/pyport.h:235,
1157 from d:/usr/Python26/include/Python.h:58,
1158 from python/python-internal.h:94,
1159 from python/py-arch.c:24:
1160 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
1161 using ::hypot;
1162 ^~~~~
1163
1164 This happens because Python headers define 'hypot' to expand t
1165 '_hypot' in the Windows builds.
1166 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
1167 'hypoth'. This avoids a compilation error.
1168
1169 2018-01-26 Alan Hayward <alan.hayward@arm.com>
1170
1171 * MAINTAINERS (Write After Approval): Fix ordering.
1172
1173 2018-01-26 Alan Hayward <alan.hayward@arm.com>
1174
1175 * MAINTAINERS (Write After Approval): Add Alan Hayward.
1176
1177 2018-01-26 Alan Modra <amodra@gmail.com>
1178
1179 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
1180 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
1181 Remove nop. Make const. Comment.
1182 (powerpc32_plt_stub_so_2): New.
1183 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
1184 Correct count. Update uses.
1185 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
1186 Move common code reading PLT entry word. Correct
1187 powerpc32_plt_stub PLT address calculation.
1188 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
1189 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
1190 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
1191 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
1192 (ppc64_standard_linkage8): Likewise.
1193 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
1194 Correct insns description.
1195 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
1196
1197 2018-01-24 Pedro Alves <palves@redhat.com>
1198
1199 GCC PR libstdc++/83906
1200 * gdbtypes.c (operator==(const dynamic_prop &,
1201 const dynamic_prop &)): New.
1202 (operator==(const range_bounds &, const range_bounds &)): New.
1203 (check_types_equal): Use them instead of memcmp.
1204 * gdbtypes.h (operator==(const dynamic_prop &,
1205 const dynamic_prop &)): Declare.
1206 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
1207 (operator==(const range_bounds &, const range_bounds &)): Declare.
1208 (operator!=(const range_bounds &, const range_bounds &)): Declare.
1209
1210 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1211
1212 * s390-linux-tdep.c (s390_record_address_mask)
1213 (s390_record_calc_disp_common, s390_record_calc_disp)
1214 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
1215 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
1216 (s390_process_record): Move to s390-tdep.c.
1217 (s390_linux_init_abi_any): Adjust.
1218 * s390-tdep.c (s390_record_address_mask)
1219 (s390_record_calc_disp_common, s390_record_calc_disp)
1220 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
1221 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
1222 (s390_process_record): Moved from s390-linux-tdep.c
1223 (s390_gdbarch_init): Adjust.
1224
1225 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1226
1227 * s390-linux-nat.c (s390-tdep.h): New include.
1228 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
1229 (HFILES_NO_SRCDIR): Add s390-tdep.h.
1230 (ALLDEPFILES): Add s390-tdep.c.
1231 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
1232 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
1233 * s390-tdep.h: ...this. New file.
1234 * s390-linux-tdep.c (s390-tdep.h): New include.
1235 (_initialize_s390_tdep): Rename to...
1236 (_initialize_s390_linux_tdep): ...this and adjust.
1237 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
1238 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
1239 s390-tdep.h.
1240 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
1241 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
1242 (s390_is_partial_instruction, s390_software_single_step)
1243 (is_non_branch_ril, s390_displaced_step_copy_insn)
1244 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
1245 (s390_prologue_data, s390_addr, s390_store, s390_load)
1246 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
1247 (s390_register_call_saved, s390_guess_tracepoint_registers)
1248 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
1249 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
1250 (s390_pseudo_register_name, s390_pseudo_register_type)
1251 (s390_pseudo_register_read, s390_pseudo_register_write)
1252 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
1253 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
1254 (s390_addr_bits_remove, s390_address_class_type_flags)
1255 (s390_address_class_type_flags_to_name)
1256 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
1257 (s390_function_arg_float, s390_function_arg_vector)
1258 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
1259 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
1260 (s390_frame_align, s390_register_return_value, s390_return_value)
1261 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
1262 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
1263 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
1264 (s390_trad_frame_prev_register, s390_unwind_cache)
1265 (s390_prologue_frame_unwind_cache)
1266 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
1267 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
1268 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
1269 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
1270 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
1271 (s390_frame_base_address, s390_local_base_address)
1272 (s390_frame_base, s390_gcc_target_options)
1273 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
1274 (s390_validate_reg_range, s390_tdesc_valid)
1275 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
1276 * s390-tdep.c: ...this. New file.
1277
1278 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1279
1280 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
1281 (s390_process_record, s390_gdbarch_tdep_alloc)
1282 (s390_linux_init_abi_any): Use/set new hook.
1283
1284 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1285
1286 * s390-linux-tdep.c (osabi.h): New include.
1287 (s390_linux_init_abi_31, s390_linux_init_abi_64)
1288 (s390_linux_init_abi_any): New functions.
1289 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
1290
1291 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1292
1293 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
1294 tdesc_has_registers check
1295
1296 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1297
1298 * s390-linux-tdep.c (s390_tdesc_valid): New function.
1299 (s390_validate_reg_range): New macro.
1300 (s390_gdbarch_init): Adjust.
1301
1302 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1303
1304 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
1305 (s390_gdbarch_tdep_alloc): Adjust.
1306 (s390_gdbarch_init): Adjust.
1307
1308 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1309
1310 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
1311 <have_tdb>: Change type to bool.
1312 (s390_gdbarch_tdep_alloc): Adjust.
1313 (s390_gdbarch_init): Adjust.
1314
1315 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1316
1317 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
1318 (gdbarch_tdep) <have_upper, have_vx>: New fields.
1319 (s390_gdbarch_tdep_alloc): New function.
1320 (s390_gdbarch_init): Allocate tdep at start and use its fields
1321 instead of separate variables.
1322
1323 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1324
1325 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
1326 when looking for cached gdbarch and add comment for remaining.
1327
1328 2018-01-22 Pedro Alves <palves@redhat.com>
1329 Sergio Durigan Junior <sergiodj@redhat.com>
1330
1331 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
1332 case.
1333
1334 2018-01-22 Maciej W. Rozycki <macro@mips.com>
1335
1336 * MAINTAINERS: Update my company e-mail address.
1337
1338 2018-01-22 Yao Qi <yao.qi@linaro.org>
1339
1340 * regcache.c (cooked_write_test): New function.
1341 (_initialize_regcache): Register the test.
1342
1343 2018-01-22 Yao Qi <yao.qi@linaro.org>
1344
1345 * ia64-tdep.c (ia64_pseudo_register_read): Call
1346 regcache->cooked_read instead of regcache_cooked_read_unsigned.
1347 * m32c-tdep.c (m32c_cat_read): Likewise.
1348 (m32c_r3r2r1r0_read): Likewise.
1349 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
1350 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
1351
1352 2018-01-22 Yao Qi <yao.qi@linaro.org>
1353
1354 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
1355 method raw_read instead of regcache_raw_read.
1356 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
1357 * arm-tdep.c (arm_neon_quad_read): Likewise.
1358 * avr-tdep.c (avr_pseudo_register_read): Likewise.
1359 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
1360 * frv-tdep.c (frv_pseudo_register_read): Likewise.
1361 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
1362 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
1363 (i386_pseudo_register_read_into_value): Likewise.
1364 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
1365 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
1366 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
1367 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
1368 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
1369 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
1370 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
1371 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
1372 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
1373
1374 2018-01-22 Yao Qi <yao.qi@linaro.org>
1375
1376 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
1377 * configure.tgt: Remove target mt.
1378 * mt-tdep.c: Remove.
1379 * regcache.c (cooked_read_test): Remove the check for mt.
1380
1381 2018-01-22 Yao Qi <yao.qi@linaro.org>
1382
1383 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
1384 instead of gdbarch_pseudo_register_read_value.
1385
1386 2018-01-22 Joel Brobecker <brobecker@adacore.com>
1387
1388 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
1389 language is Ada.
1390
1391 2018-01-22 Joel Brobecker <brobecker@adacore.com>
1392
1393 * linespec.c (create_sals_line_offset): Remove code that preserved
1394 the symtab_and_line's line number.
1395
1396 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1397
1398 * varobj.c (varobj_create): Don't set valid_block when creating a
1399 floating varobj.
1400
1401 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1402
1403 * varobj.c (varobj_create): Remove out of date comment.
1404
1405 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1406
1407 PR mi/20395
1408 * ada-exp.y (write_var_from_sym): Pass extra parameter when
1409 updating innermost block.
1410 * parse.c (innermost_block_tracker::update): Take extra type
1411 parameter, and check types match before updating innermost block.
1412 (write_dollar_variable): Update innermost block for registers.
1413 * parser-defs.h (enum innermost_block_tracker_type): New enum.
1414 (innermost_block_tracker::innermost_block_tracker): Initialise
1415 m_types member.
1416 (innermost_block_tracker::reset): Take type parameter.
1417 (innermost_block_tracker::update): Take type parameter, and pass
1418 type through as needed.
1419 (innermost_block_tracker::m_types): New member.
1420 * varobj.c (varobj_create): Pass type when reseting innermost
1421 block.
1422
1423 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1424
1425 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
1426 * ada-lang.c (resolve_subexp): Likewise.
1427 * breakpoint.c (set_breakpoint_condition) Likewise.
1428 (watch_command_1) Likewise.
1429 * c-exp.y (variable): Likewise.
1430 * d-exp.y (PrimaryExpression): Likewise.
1431 * f-exp.y (variable): Likewise.
1432 * go-exp.y (variable): Likewise.
1433 * m2-exp.y (variable): Likewise.
1434 * objfiles.c (objfile::~objfile): Likewise.
1435 * p-exp.y (variable): Likewise.
1436 * parse.c (innermost_block): Change type.
1437 * parser-defs.h (class innermost_block_tracker): New.
1438 (innermost_block): Change to innermost_block_tracker.
1439 * printcmd.c (display_command): Switch to innermost_block API.
1440 (do_one_display): Likewise.
1441 * rust-exp.y (do_one_display): Likewise.
1442 * symfile.c (clear_symtab_users): Likewise.
1443 * varobj.c (varobj_create): Switch to innermost_block API, replace
1444 use of innermost_block with block stored on varobj object.
1445
1446 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1447
1448 * expression.h (innermost_block): Remove declaration.
1449 * varobj.c: Add 'parser-defs.h' include.
1450
1451 2018-01-19 Tom Tromey <tom@tromey.com>
1452
1453 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
1454 symbols in the static and global blocks.
1455
1456 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1457
1458 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
1459 gdb_ptrace.h, and move including gdb_wait.h ...
1460 * nat/linux-ptrace.h: ... to here.
1461
1462 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
1463
1464 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
1465 inf_ptrace_detach_success.
1466 (inf_ptrace_detach_success): Add inferior parameter, use it
1467 instead of inferior_ptid, pass it to detach_inferior.
1468 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
1469 parameter.
1470 * inferior.c (detach_inferior): Add overload that takes an
1471 inferior object.
1472 * inferior.h (detach_inferior): Likewise.
1473 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
1474 use inferior_ptid, adjust call to inf_ptrace_detach_success.
1475 * linux-thread-db.c (thread_db_detach): Use inf parameter.
1476
1477 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
1478
1479 * target.h (struct target_ops) <to_detach>: Add inferior
1480 parameter.
1481 (target_detach): Likewise.
1482 * target.c (dispose_inferior): Pass inferior down.
1483 (target_detach): Pass inferior down. Assert that it is equal to
1484 the current inferior.
1485 * aix-thread.c (aix_thread_detach): Pass inferior down.
1486 * corefile.c (core_file_command): Pass current_inferior() down.
1487 * corelow.c (core_detach): Add inferior parameter.
1488 * darwin-nat.c (darwin_detach): Likewise.
1489 * gnu-nat.c (gnu_detach): Likewise.
1490 * inf-ptrace.c (inf_ptrace_detach): Likewise.
1491 * infcmd.c (detach_command): Pass current_inferior() down to
1492 target_detach.
1493 * infrun.c (follow_fork_inferior): Pass parent_inf to
1494 target_detach.
1495 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
1496 target_detach.
1497 * linux-nat.c (linux_nat_detach): Add inferior parameter.
1498 * linux-thread-db.c (thread_db_detach): Likewise.
1499 * nto-procfs.c (procfs_detach): Likewise.
1500 * procfs.c (procfs_detach): Likewise.
1501 * record.c (record_detach): Likewise.
1502 * record.h (struct inferior): Forward-declare.
1503 (record_detach): Add inferior parameter.
1504 * remote-sim.c (gdbsim_detach): Likewise.
1505 * remote.c (remote_detach_1): Likewise.
1506 (remote_detach): Likewise.
1507 (extended_remote_detach): Likewise.
1508 * sol-thread.c (sol_thread_detach): Likewise.
1509 * target-debug.h (target_debug_print_inferior_p): New macro.
1510 * target-delegates.c: Re-generate.
1511 * top.c (kill_or_detach): Pass inferior down to target_detach.
1512 * windows-nat.c (windows_detach): Add inferior parameter.
1513
1514 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
1515
1516 * target.h (struct target_ops) <to_detach>: Remove args
1517 parameter.
1518 (target_detach): Likewise.
1519 * target.c (dispose_inferior): Adjust.
1520 (target_detach): Remove args parameter, adjust.
1521 * aix-thread.c (aix_thread_detach): Adjust.
1522 * corefile.c (core_file_command): Adjust.
1523 * corelow.c (core_detach): Adjust.
1524 * darwin-nat.c (darwin_detach): Adjust.
1525 * gnu-nat.c (gnu_detach): Adjust.
1526 * inf-ptrace.c (inf_ptrace_detach): Adjust.
1527 * infcmd.c (detach_command): Adjust
1528 * infrun.c (follow_fork_inferior): Adjust.
1529 (handle_vfork_child_exec_or_exit): Adjust.
1530 * linux-fork.c (linux_fork_detach): Remove args parameter.
1531 * linux-fork.h (linux_fork_detach): Likewise.
1532 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
1533 * linux-thread-db.c (thread_db_detach): Likewise.
1534 * nto-procfs.c (procfs_detach): Likewise.
1535 * procfs.c (procfs_detach): Likewise.
1536 (do_detach): Remove signo parameter.
1537 * record.c (record_detach): Remove args parameter.
1538 * record.h (record_detach): Likewise.
1539 * remote-sim.c (gdbsim_detach): Likewise.
1540 * remote.c (remote_detach_1): Likewise.
1541 (remote_detach): Likewise.
1542 (extended_remote_detach): Likewise.
1543 * sol-thread.c (sol_thread_detach): Likewise.
1544 * target-delegates.c: Re-generate.
1545 * top.c (struct qt_args) <args>: Remove field.
1546 (kill_or_detach): Don't pass args.
1547 (quit_force): Don't set args.
1548 * windows-nat.c (windows_detach): Remove args parameter.
1549
1550 2018-01-19 Yao Qi <yao.qi@linaro.org>
1551
1552 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
1553 (arm_linux_init_abi): Install it.
1554
1555 2018-01-19 Yao Qi <yao.qi@linaro.org>
1556
1557 * osabi.c (gdb_osabi_names): Extend the regexp for
1558 arm-linux-gnueabihf.
1559
1560 2018-01-18 Yao Qi <yao.qi@linaro.org>
1561
1562 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
1563 m_abbrevs.
1564 (abbrev_table::add_abbrev): Update.
1565 (abbrev_table::lookup_abbrev): Update.
1566
1567 2018-01-18 Yao Qi <yao.qi@linaro.org>
1568
1569 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
1570
1571 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
1572
1573 * compile/compile.c (compile_to_object): Convert "triplet_rx"
1574 to "std::string".
1575
1576 2018-01-17 Tom Tromey <tom@tromey.com>
1577
1578 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
1579
1580 2018-01-17 Tom Tromey <tom@tromey.com>
1581
1582 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
1583 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
1584 (create_array_type_with_stride): Update.
1585 * dwarf2read.c (set_die_type): Update.
1586
1587 2018-01-17 Tom Tromey <tom@tromey.com>
1588
1589 * dwarf2read.c (delayed_method_info): Remove typedef.
1590 (dwarf2_cu::method_info): Now a std::vector.
1591 (add_to_method_list): Update.
1592 (free_delayed_list): Remove.
1593 (compute_delayed_physnames): Update.
1594 (process_full_comp_unit, process_full_type_unit): Clear the method
1595 list. Remove cleanups.
1596 (psymtab_include_file_name): Add name_holder parameter. Use
1597 unique_xmalloc_ptr.
1598 (dwarf_decode_lines): Update.
1599
1600 2018-01-17 Tom Tromey <tom@tromey.com>
1601 Simon Marchi <simon.marchi@ericsson.com>
1602
1603 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
1604 (dwarf2_per_objfile::free_cached_comp_units)
1605 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
1606 (init_cutu_and_read_dies_no_follow): Update.
1607 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
1608 (dwarf2_cu::~dwarf2_cu): New.
1609 (free_heap_comp_unit, free_stack_comp_unit): Remove.
1610 (age_cached_comp_units, free_one_cached_comp_unit): Update.
1611
1612 2018-01-17 Tom Tromey <tom@tromey.com>
1613 Simon Marchi <simon.marchi@ericsson.com>
1614
1615 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
1616 (struct die_reader_specs) <abbrev_table>: New member.
1617 (struct abbrev_table): Add constructor.
1618 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
1619 <abbrev_obstack>: Now an auto_obstack.
1620 (abbrev_table_up): New typedef.
1621 (init_cu_die_reader): Add abbrev_table parameter.
1622 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
1623 Add result_dwo_abbrev_table.
1624 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
1625 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
1626 Update.
1627 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
1628 parameter.
1629 (skip_children): Update.
1630 (abbrev_table::alloc_abbrev): Rename from
1631 abbrev_table_alloc_abbrev.
1632 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
1633 (abbrev_table::lookup_abbrev): Rename from
1634 abbrev_table_lookup_abbrev.
1635 (abbrev_table_read_table): Return abbrev_table_up.
1636 (abbrev_table_free, abbrev_table_free_cleanup)
1637 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
1638 (load_partial_dies): Update.
1639
1640 2018-01-17 Tom Tromey <tom@tromey.com>
1641
1642 * dwarf2read.c (dwarf2_compute_name): Update comment.
1643 (read_func_scope, read_variable): Update.
1644 (new_symbol): Remove.
1645 (new_symbol_full): Rename to new_symbol.
1646
1647 2018-01-17 Mike Gulick <mgulick@mathworks.com>
1648
1649 PR gdb/16577
1650 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
1651 a warning instead of throwing an error, set section size to 0 and return
1652 NULL.
1653 * gdb_bfd.h (gdb_bfd_map_section): Update description.
1654
1655 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1656
1657 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
1658 std::string.
1659 (linux_ptrace_attach_fail_reason_string): Likewise.
1660 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
1661 Likewise.
1662 (linux_ptrace_attach_fail_reason_string): Likewise.
1663 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
1664
1665 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1666
1667 * linux-nat.c (linux_nat_attach): Remove xstrdup.
1668
1669 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1670
1671 PR gdb/21559
1672 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1673 checking for fs_base/gs_base fields in struct user_regs_struct.
1674 * configure: Regenerate.
1675
1676 2018-01-17 Yao Qi <yao.qi@linaro.org>
1677
1678 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
1679 function.
1680 (aarch64_linux_init_abi): Install it to gdbarch hook
1681 gcc_target_options.
1682
1683 2018-01-15 Pedro Alves <palves@redhat.com>
1684
1685 * common/signals-state-save-restore.c
1686 (save_original_signals_state): Fix typos.
1687
1688 2017-01-12 Tom Tromey <tom@tromey.com>
1689 Sergio Durigan Junior <sergiodj@redhat.com>
1690
1691 * Makefile.in (install-only): Install gdb-add-index.
1692
1693 2018-01-12 John Baldwin <jhb@FreeBSD.org>
1694
1695 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
1696
1697 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
1698
1699 * infrun.c (keep_going_pass_signal): Clear step-over info when
1700 insert_breakpoints fails.
1701
1702 2018-01-11 Pedro Alves <palves@redhat.com>
1703
1704 PR gdb/22583
1705 * infrun.c (resume): Rename to ...
1706 (resume_1): ... this.
1707 (resume): Reimplement as wrapper around resume_1.
1708
1709 2018-01-11 Pedro Alves <palves@redhat.com>
1710
1711 PR remote/22597
1712 * remote.c (remote_parse_stop_reply): Default to the last-set
1713 general thread instead of to 'magic_null_ptid'.
1714
1715 2018-01-10 Pedro Alves <palves@redhat.com>
1716
1717 * language.h (language_get_symbol_name_matcher): Rename ...
1718 (get_symbol_name_matcher): ... this.
1719 * language.c (language_get_symbol_name_matcher): Ditto.
1720 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
1721 callers adjusted.
1722
1723 2018-01-10 Pedro Alves <palves@redhat.com>
1724
1725 PR gdb/22670
1726 * dwarf2read.c
1727 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
1728 Adjust to use language_get_symbol_name_matcher instead of
1729 language_defn::la_get_symbol_name_matcher.
1730 * language.c (language_get_symbol_name_matcher): If in Ada mode
1731 and the lookup name is a verbatim match, return Ada's matcher.
1732 * language.h (language_get_symbol_name_matcher): Adjust comment.
1733 (ada_lookup_name_info::verbatim_p):: New method.
1734
1735 2018-01-10 Pedro Alves <palves@redhat.com>
1736
1737 PR gdb/22670
1738 * ada-lang.c (ada_collect_symbol_completion_matches): If the
1739 minsym's language is language_auto or language_cplus, pass down
1740 language_ada instead.
1741 * symtab.c (compare_symbol_name): Don't frob symbol language here.
1742
1743 2018-01-10 Pedro Alves <palves@redhat.com>
1744
1745 PR gdb/22670
1746 * minsyms.c (linkage_name_str): New function.
1747 (iterate_over_minimal_symbols): Use it.
1748
1749 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1750
1751 * NEWS: Document that 'info proc' now works on FreeBSD.
1752
1753 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1754
1755 * configure.ac: Check for kinfo_getfile in libutil.
1756 * configure: Regenerate.
1757 * config.in: Regenerate.
1758 * fbsd-nat.c: Include "fbsd-tdep.h".
1759 (fbsd_fetch_cmdline): New.
1760 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
1761 rather than calling error.
1762 (fbsd_info_proc): New.
1763 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
1764 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
1765 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
1766
1767 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1768
1769 * fbsd-nat.c (struct free_deleter): Remove.
1770 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
1771
1772 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1773
1774 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
1775 NULL for an empty pathname.
1776
1777 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1778
1779 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
1780 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
1781 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
1782 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
1783 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
1784 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
1785 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
1786 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
1787 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
1788 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
1789 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
1790 (fbsd_core_fetch_timeval, fbsd_print_sigset)
1791 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
1792 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
1793 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
1794
1795 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
1796
1797 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
1798 (gnu_xfer_auxv): New function.
1799 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
1800 TARGET_OBJECT_AUXV.
1801
1802 2018-01-08 Yao Qi <yao.qi@linaro.org>
1803 Simon Marchi <simon.marchi@ericsson.com>
1804
1805 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
1806 common/selftest.c.
1807 (COMMON_OBS): Remove selftest.o.
1808 * configure.ac: Append selftest-arch.c and common/selftest.c to
1809 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
1810 * configure: Re-generated.
1811 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
1812 GDB_SELF_TEST.
1813 (maintenance_info_selftests): Likewise.
1814
1815 2018-01-08 Xavier Roirand <roirand@adacore.com>
1816
1817 * ada-valprint.c (val_print_packed_array_elements): Use
1818 proper number of elements when printing an array indexed
1819 by an enumeration type.
1820
1821 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1822
1823 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
1824 (dw2_get_file_names_reader): Adjust.
1825 (lookup_dwo_signatured_type): Adjust.
1826 (lookup_dwp_signatured_type): Adjust.
1827 (lookup_signatured_type): Adjust.
1828 (create_type_unit_group): Adjust.
1829 (get_type_unit_group): Adjust.
1830 (process_psymtab_comp_unit_reader): Adjust.
1831 (build_type_psymtabs_reader): Adjust.
1832 (scan_partial_symbols): Adjust.
1833 (add_partial_symbol): Adjust.
1834 (add_partial_subprogram): Adjust.
1835 (peek_die_abbrev): Adjust.
1836 (fixup_go_packaging): Adjust.
1837 (process_imported_unit_die): Adjust.
1838 (dwarf2_compute_name): Adjust.
1839 (dwarf2_physname): Adjust.
1840 (read_import_statement): Adjust.
1841 (handle_DW_AT_stmt_list): Adjust.
1842 (read_file_scope): Adjust.
1843 (read_func_scope): Adjust.
1844 (read_lexical_block_scope): Adjust.
1845 (read_call_site_scope): Adjust.
1846 (read_variable): Adjust.
1847 (dwarf2_rnglists_process): Adjust.
1848 (dwarf2_ranges_process): Adjust.
1849 (dwarf2_ranges_read): Adjust.
1850 (dwarf2_get_pc_bounds): Adjust.
1851 (dwarf2_record_block_ranges): Adjust.
1852 (dwarf2_add_field): Adjust.
1853 (dwarf2_add_member_fn): Adjust.
1854 (read_structure_type): Adjust.
1855 (process_structure_scope): Adjust.
1856 (read_enumeration_type): Adjust.
1857 (read_array_type): Adjust.
1858 (mark_common_block_symbol_computed): Adjust.
1859 (read_common_block): Adjust.
1860 (read_namespace_type): Adjust.
1861 (read_namespace): Adjust.
1862 (read_module_type): Adjust.
1863 (read_tag_pointer_type): Adjust.
1864 (read_tag_ptr_to_member_type): Adjust.
1865 (read_tag_string_type): Adjust.
1866 (read_subroutine_type): Adjust.
1867 (read_typedef): Adjust.
1868 (read_base_type): Adjust.
1869 (attr_to_dynamic_prop): Adjust.
1870 (read_subrange_type): Adjust.
1871 (read_unspecified_type): Adjust.
1872 (dwarf2_read_abbrevs): Adjust.
1873 (load_partial_dies): Adjust.
1874 (read_partial_die): Adjust.
1875 (find_partial_die): Adjust.
1876 (guess_partial_die_structure_name): Adjust.
1877 (fixup_partial_die): Adjust.
1878 (read_attribute_value): Adjust.
1879 (read_addr_index): Adjust.
1880 (read_addr_index_from_leb128): Adjust.
1881 (read_str_index): Adjust.
1882 (dwarf2_string_attr): Adjust.
1883 (get_debug_line_section): Adjust.
1884 (dwarf_decode_line_header): Adjust.
1885 (lnp_state_machine::check_line_address): Adjust.
1886 (dwarf_decode_lines_1): Adjust.
1887 (dwarf_decode_lines): Adjust.
1888 (dwarf2_start_symtab): Adjust.
1889 (var_decode_location): Adjust.
1890 (new_symbol_full): Adjust.
1891 (dwarf2_const_value_data): Adjust.
1892 (dwarf2_const_value_attr): Adjust.
1893 (dwarf2_const_value): Adjust.
1894 (die_type): Adjust.
1895 (die_containing_type): Adjust.
1896 (build_error_marker_type): Adjust.
1897 (lookup_die_type): Adjust.
1898 (guess_full_die_structure_name): Adjust.
1899 (anonymous_struct_prefix): Adjust.
1900 (determine_prefix): Adjust.
1901 (dwarf2_name): Adjust.
1902 (follow_die_ref_or_sig): Adjust.
1903 (follow_die_offset): Adjust.
1904 (follow_die_ref): Adjust.
1905 (follow_die_sig_1): Adjust.
1906 (follow_die_sig): Adjust.
1907 (get_signatured_type): Adjust.
1908 (get_DW_AT_signature_type): Adjust.
1909 (decode_locdesc): Adjust.
1910 (dwarf_decode_macros): Adjust.
1911 (cu_debug_loc_section): Adjust.
1912 (fill_in_loclist_baton): Adjust.
1913 (dwarf2_symbol_mark_computed): Adjust.
1914 (init_one_comp_unit): Don't assign
1915 dwarf2_cu::dwarf2_per_objfile.
1916 (set_die_type): Adjust.
1917
1918 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
1919
1920 * dwarf2read.c (struct mapped_debug_names): Add constructor.
1921 <dwarf2_per_objfile>: New field.
1922 (dwarf2_per_objfile): Remove global.
1923 (get_dwarf2_per_objfile): New function.
1924 (set_dwarf2_per_objfile): New function.
1925 (dwarf2_build_psymtabs_hard): Change objfile parameter to
1926 dwarf2_per_objfile.
1927 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
1928 (read_abbrev_offset): Likewise.
1929 (read_indirect_string): Likewise.
1930 (read_indirect_line_string): Likewise.
1931 (read_indirect_string_at_offset): Likewise.
1932 (read_indirect_string_from_dwz): Likewise.
1933 (dwarf2_find_containing_comp_unit): Change objfile parameter to
1934 dwarf2_per_objfile.
1935 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
1936 (create_all_comp_units): Change objfile parameter to
1937 dwarf2_per_objfile.
1938 (create_all_type_units): Likewise.
1939 (process_queue): Add dwarf2_per_objfile parameter.
1940 (read_and_check_comp_unit_head): Likewise.
1941 (lookup_dwo_unit_in_dwp): Likewise.
1942 (get_dwp_file): Likewise.
1943 (process_cu_includes): Likewise.
1944 (struct free_dwo_file_cleanup_data): New struct.
1945 (dwarf2_has_info): Use get_dwarf2_per_objfile and
1946 set_dwarf2_per_objfile.
1947 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
1948 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
1949 context, adjust calls.
1950 (dw2_instantiate_symtab): Likewise.
1951 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
1952 (dw2_get_cu): Likewise.
1953 (create_cu_from_index_list): Change objfile parameter to
1954 dwarf2_per_objfile.
1955 (create_cus_from_index_list): Get dwarf2_per_objfile from
1956 context, adjust calls.
1957 (create_cus_from_index): Likewise.
1958 (create_signatured_type_table_from_index): Change objfile
1959 parameter to dwarf2_per_objfile.
1960 (create_signatured_type_table_from_debug_names): Change objfile
1961 parameter to dwarf2_per_objfile.
1962 (create_addrmap_from_index): Likewise.
1963 (create_addrmap_from_aranges): Likewise.
1964 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
1965 (dw2_setup): Remove.
1966 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
1967 context.
1968 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
1969 get_dwarf2_per_objfile.
1970 (dw2_forget_cached_source_info): Likewise.
1971 (dw2_map_symtabs_matching_filename): Likewise.
1972 (struct dw2_symtab_iterator) <index>: Remove.
1973 <dwarf2_per_objfile>: New field.
1974 (dw2_symtab_iter_init): Replace index parameter with
1975 dwarf2_per_objfile.
1976 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
1977 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
1978 (dw2_print_stats): Likewise.
1979 (dw2_dump): Likewise.
1980 (dw2_expand_symtabs_for_function): Likewise.
1981 (dw2_expand_all_symtabs): Likewise.
1982 (dw2_expand_symtabs_with_fullname): Likewise.
1983 (dw2_expand_marked_cus): Replace index and objfile parameters
1984 with dwarf2_per_objfile.
1985 (dw_expand_symtabs_matching_file_matcher): Add
1986 dwarf2_per_objfile parameter and adjust calls.
1987 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
1988 adjust calls.
1989 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
1990 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
1991 adjust calls.
1992 (create_cus_from_debug_names_list): Replace objfile parameter
1993 with dwarf2_per_objfile and adjust calls.
1994 (create_cus_from_debug_names): Likewise.
1995 (dwarf2_read_debug_names): Likewise.
1996 (mapped_debug_names::namei_to_name): Adjust call.
1997 (dw2_debug_names_iterator::next): Likewise.
1998 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
1999 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
2000 (dw2_debug_names_dump): Likewise.
2001 (dw2_debug_names_expand_symtabs_for_function): Likewise.
2002 (dw2_debug_names_expand_symtabs_matching): Likewise.
2003 (dwarf2_initialize_objfile): Likewise.
2004 (dwarf2_build_psymtabs): Likewise.
2005 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
2006 this_cu.
2007 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
2008 (read_and_check_comp_unit_head): Likewise.
2009 (read_abbrev_offset): Likewise.
2010 (create_debug_type_hash_table): Likewise.
2011 (create_debug_types_hash_table): Likewise.
2012 (create_all_type_units): Replace objfile parameter with
2013 dwarf2_per_objfile.
2014 (add_type_unit): Add dwarf2_per_objfile parameter.
2015 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
2016 with dwarf2_per_objfile.
2017 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
2018 (lookup_dwp_signatured_type): Likewise.
2019 (lookup_signatured_type): Likewise.
2020 (read_cutu_die_from_dwo): Likewise.
2021 (init_tu_and_read_dwo_dies): Likewise.
2022 (init_cutu_and_read_dies): Likewise.
2023 (init_cutu_and_read_dies_no_follow): Likewise.
2024 (allocate_type_unit_groups_table): Add objfile parameter.
2025 (create_type_unit_group): Use dwarf2_per_objfile from cu.
2026 (get_type_unit_group): Likewise.
2027 (process_psymtab_comp_unit): Update call.
2028 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
2029 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
2030 (print_tu_stats): Likewise.
2031 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
2032 in void* parameter.
2033 (build_type_psymtabs): Change objfile parameter to
2034 dwarf2_per_objfile.
2035 (process_skeletonless_type_unit): Use dwarf2_per_objfile
2036 passed in void* parameter.
2037 (process_skeletonless_type_units): Change objfile parameter to
2038 dwarf2_per_objfile.
2039 (set_partial_user): Likewise.
2040 (dwarf2_build_psymtabs_hard): Likewise.
2041 (read_comp_units_from_section): Likewise.
2042 (create_all_comp_units): Likewise.
2043 (scan_partial_symbols): Update calls.
2044 (add_partial_symbol): Likewise.
2045 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
2046 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
2047 (process_queue): Add dwarf2_per_objfile parameter.
2048 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
2049 (compute_compunit_symtab_includes): Likewise.
2050 (process_cu_includes): Add dwarf2_per_objfile parameter.
2051 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
2052 (process_full_type_unit): Likewise.
2053 (process_imported_unit_die): Update call.
2054 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
2055 (read_file_scope): Likewise.
2056 (allocate_dwo_file_hash_table): Add objfile parameter.
2057 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
2058 (create_cus_hash_table): Likewise.
2059 (create_dwp_hash_table): Likewise.
2060 (create_dwo_unit_in_dwp_v1): Likewise.
2061 (create_dwp_v2_section): Likewise.
2062 (create_dwo_unit_in_dwp_v2): Likewise.
2063 (lookup_dwo_unit_in_dwp): Likewise.
2064 (try_open_dwop_file): Likewise.
2065 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
2066 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
2067 cleanup to include a reference to dwarf2_per_objfile.
2068 (open_dwp_file): Add dwarf2_per_objfile parameter.
2069 (open_and_init_dwp_file): Likewise.
2070 (get_dwp_file): Likewise.
2071 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
2072 (queue_and_load_all_dwo_tus): Update call.
2073 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
2074 data.
2075 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
2076 (dwarf2_ranges_process): Likewise.
2077 (dwarf2_get_pc_bounds): Likewise.
2078 (mark_common_block_symbol_computed): Likewise.
2079 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
2080 (dwarf2_read_abbrevs): Update call.
2081 (read_partial_die): Use dwarf2_per_objfile from cu.
2082 (find_partial_die): Likewise.
2083 (fixup_partial_die): Likewise.
2084 (read_attribute_value): Likewise.
2085 (read_indirect_string_at_offset_from): Add objfile parameter.
2086 (read_indirect_string_at_offset): Add dwarf2_per_objfile
2087 parameter.
2088 (read_indirect_string_from_dwz): Add objfile parameter.
2089 (read_indirect_string): Add objfile parameter.
2090 (read_addr_index_1): Add dwarf2_per_objfile parameter.
2091 (read_addr_index): Use dwarf2_per_objfile from cu.
2092 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
2093 call dw2_setup.
2094 (read_str_index): Use dwarf2_per_objfile from cu.
2095 (get_debug_line_section): Likewise.
2096 (read_formatted_entries): Add dwarf2_per_objfile parameter.
2097 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
2098 (new_symbol_full): Use dwarf2_per_objfile from cu.
2099 (build_error_marker_type): Likewise.
2100 (lookup_die_type): Likewise.
2101 (determine_prefix): Likewise.
2102 (follow_die_offset): Likewise.
2103 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
2104 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
2105 (dwarf2_fetch_die_type_sect_off): Likewise.
2106 (dwarf2_get_die_type): Likewise.
2107 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
2108 (get_signatured_type): Likewise.
2109 (get_DW_AT_signature_type): Likewise.
2110 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
2111 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
2112 (cu_debug_loc_section): Likewise.
2113 (fill_in_loclist_baton): Likewise.
2114 (dwarf2_symbol_mark_computed): Likewise.
2115 (dwarf2_find_containing_comp_unit): Change objfile parameter to
2116 dwarf2_per_objfile.
2117 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
2118 parameter.
2119 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
2120 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
2121 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
2122 (set_die_type): Use dwarf2_free_objfile from cu.
2123 (get_die_type_at_offset): Likewise.
2124 (dwarf2_per_objfile_free): Don't assign global variable.
2125 (debug_names) <constructor>: Add dwarf2_per_objfile
2126 parameter, update m_debugstrlookup construction.
2127 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
2128 parameter.
2129 <m_dwarf2_per_objfile>: New field.
2130 <lookup>: Use m_dwarf2_per_objfile.
2131 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
2132 (psyms_seen_size): Likewise.
2133 (write_gdbindex): Replace objfile parameter with
2134 dwarf2_per_objfile.
2135 (write_debug_names): Likewise.
2136 (write_psymtabs_to_index): Likewise.
2137 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
2138 calls.
2139
2140 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
2141
2142 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
2143 <dwarf2_per_objfile>: New field.
2144 (struct dwarf2_per_cu_data) <objfile>: Remove.
2145 <dwarf2_per_objfile>: New field.
2146 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
2147 of objfile.
2148 (create_signatured_type_table_from_index): Likewise.
2149 (create_debug_type_hash_table): Likewise.
2150 (fill_in_sig_entry_from_dwo_entry): Likewise.
2151 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
2152 (create_type_unit_group): Assign dwarf2_per_objfile instead of
2153 objfile.
2154 (create_partial_symtab): Access objfile through
2155 dwarf2_per_objfile.
2156 (process_psymtab_comp_unit_reader): Likewise.
2157 (read_comp_units_from_section): Likewise.
2158 (scan_partial_symbols): Likewise.
2159 (add_partial_symbol): Likewise.
2160 (add_partial_subprogram): Likewise.
2161 (peek_die_abbrev): Likewise.
2162 (fixup_go_packaging): Likewise.
2163 (process_full_comp_unit): Likewise.
2164 (process_full_type_unit): Likewise.
2165 (process_imported_unit_die): Likewise.
2166 (dwarf2_compute_name): Likewise.
2167 (dwarf2_physname): Likewise.
2168 (read_import_statement): Likewise.
2169 (create_cus_hash_table): Assign dwarf2_physname instead of
2170 objfile.
2171 (read_func_scope): Access objfile through dwarf2_per_objfile.
2172 (read_lexical_block_scope): Likewise.
2173 (read_call_site_scope): Likewise.
2174 (read_variable): Likewise.
2175 (dwarf2_rnglists_process): Likewise.
2176 (dwarf2_ranges_process): Likewise.
2177 (dwarf2_ranges_read): Likewise.
2178 (dwarf2_record_block_ranges): Likewise.
2179 (dwarf2_add_field): Likewise.
2180 (dwarf2_add_member_fn): Likewise.
2181 (read_structure_type): Likewise.
2182 (process_structure_scope): Likewise.
2183 (read_enumeration_type): Likewise.
2184 (read_array_type): Likewise.
2185 (read_common_block): Likewise.
2186 (read_namespace_type): Likewise.
2187 (read_namespace): Likewise.
2188 (read_module_type): Likewise.
2189 (read_tag_pointer_type): Likewise.
2190 (read_tag_ptr_to_member_type): Likewise.
2191 (read_tag_string_type): Likewise.
2192 (read_subroutine_type): Likewise.
2193 (read_typedef): Likewise.
2194 (read_base_type): Likewise.
2195 (attr_to_dynamic_prop): Likewise.
2196 (read_subrange_type): Likewise.
2197 (read_unspecified_type): Likewise.
2198 (load_partial_dies): Likewise.
2199 (read_partial_die): Likewise.
2200 (find_partial_die): Likewise.
2201 (guess_partial_die_structure_name): Likewise.
2202 (fixup_partial_die): Likewise.
2203 (read_attribute_value): Likewise.
2204 (read_addr_index_from_leb128): Likewise.
2205 (dwarf2_read_addr_index): Likewise.
2206 (dwarf2_string_attr): Likewise.
2207 (lnp_state_machine::check_line_address): Likewise.
2208 (dwarf_decode_lines_1): Likewise.
2209 (dwarf_decode_lines): Likewise.
2210 (dwarf2_start_symtab): Likewise.
2211 (var_decode_location): Likewise.
2212 (new_symbol_full): Likewise.
2213 (dwarf2_const_value_data): Likewise.
2214 (dwarf2_const_value_attr): Likewise.
2215 (dwarf2_const_value): Likewise.
2216 (die_type): Likewise.
2217 (die_containing_type): Likewise.
2218 (lookup_die_type): Likewise.
2219 (guess_full_die_structure_name): Likewise.
2220 (anonymous_struct_prefix): Likewise.
2221 (dwarf2_name): Likewise.
2222 (follow_die_ref_or_sig): Likewise.
2223 (follow_die_offset): Likewise.
2224 (follow_die_ref): Likewise.
2225 (dwarf2_fetch_die_loc_sect_off): Likewise.
2226 (dwarf2_fetch_constant_bytes): Likewise.
2227 (dwarf2_fetch_die_type_sect_off): Likewise.
2228 (dwarf2_get_die_type): Likewise.
2229 (follow_die_sig): Likewise.
2230 (decode_locdesc): Likewise.
2231 (dwarf2_per_cu_objfile): Likewise.
2232 (dwarf2_per_cu_text_offset): Likewise.
2233 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
2234 objfile.
2235 (set_die_type): Access objfile through
2236 dwarf2_per_objfile.
2237
2238 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
2239
2240 * valprint.c (converted_character_d): Remove typedef.
2241 (DEF_VEC_O (converted_character_d)): Remove.
2242 (count_next_character): Use std::vector.
2243 (print_converted_chars_to_obstack): Likewise.
2244 (generic_printstr): Likewise.
2245
2246 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2247
2248 * xml-support.h (struct gdb_xml_value): Add constructor.
2249 <value>: Change type to unique_xmalloc_ptr.
2250 (gdb_xml_value_s): Remove typedef.
2251 (DEF_VEC_O (gdb_xml_value_s)): Remove.
2252 (gdb_xml_element_start_handler): Change parameter type to
2253 std::vector.
2254 (xml_find_attribute): Likewise.
2255 * xml-support.c (xml_find_attribute): Change parameter type to
2256 std::vector and adjust.
2257 (gdb_xml_values_cleanup): Remove.
2258 (gdb_xml_parser::start_element): Adjust to std::vector.
2259 (xinclude_start_include): Change paraeter type to std::vector
2260 and adjust.
2261 * btrace.c (check_xml_btrace_version): Likewise.
2262 (parse_xml_btrace_block): Likewise.
2263 (parse_xml_btrace_pt_config_cpu): Likewise.
2264 (parse_xml_btrace_pt): Likewise.
2265 (parse_xml_btrace_conf_bts): Likewise.
2266 (parse_xml_btrace_conf_pt): Likewise.
2267 * memory-map.c (memory_map_start_memory): Likewise.
2268 (memory_map_start_property): Likewise.
2269 * osdata.c (osdata_start_osdata): Likewise.
2270 (osdata_start_item): Likewise.
2271 (osdata_start_column): Likewise.
2272 * remote.c (start_thread): Likewise.
2273 * solib-aix.c (library_list_start_library): Likewise.
2274 (library_list_start_list): Likewise.
2275 * solib-svr4.c (library_list_start_library): Likewise.
2276 (svr4_library_list_start_list): Likewise.
2277 * solib-target.c (library_list_start_segment): Likewise.
2278 (library_list_start_section): Likewise.
2279 (library_list_start_library): Likewise.
2280 (library_list_start_list): Likewise.
2281 * tracepoint.c (traceframe_info_start_memory): Likewise.
2282 (traceframe_info_start_tvar): Likewise.
2283 * xml-syscall.c (syscall_start_syscall): Likewise.
2284 * xml-tdesc.c (tdesc_start_target): Likewise.
2285 (tdesc_start_feature): Likewise.
2286 (tdesc_start_reg): Likewise.
2287 (tdesc_start_union): Likewise.
2288 (tdesc_start_struct): Likewise.
2289 (tdesc_start_flags): Likewise.
2290 (tdesc_start_enum): Likewise.
2291 (tdesc_start_field): Likewise.
2292 (tdesc_start_enum_value): Likewise.
2293 (tdesc_start_vector): Likewise.
2294
2295 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2296
2297 * extension.h (struct xmethod_worker) <clone>: Remove.
2298 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
2299 Remove.
2300 (python_xmethod_worker::clone): Remove.
2301 * valops.c (find_overload_match): Use std::move instead of
2302 clone.
2303
2304 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2305
2306 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
2307 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
2308 <free_xmethod_worker_data>: Remove.
2309 <get_matching_xmethod_workers>: Chance VEC to std::vector.
2310 <get_xmethod_arg_types>: Remove.
2311 <get_xmethod_result_type>: Remove.
2312 <invoke_xmethod>: Remove.
2313 * extension.c (new_xmethod_worker): Remove.
2314 (clone_xmethod_worker): Remove.
2315 (get_matching_xmethod_workers): Return void, pass std::vector by
2316 pointer.
2317 (get_xmethod_arg_types): Rename to...
2318 (xmethod_worker::get_arg_types): ... this, and adjust.
2319 (get_xmethod_result_type): Rename to...
2320 (xmethod_worker::get_result_type): ... this, and adjust.
2321 (invoke_xmethod): Remove.
2322 (free_xmethod_worker): Remove.
2323 (free_xmethod_worker_vec): Remove.
2324 * extension.h (enum ext_lang_rc): Move here from
2325 extension-priv.h.
2326 (struct xmethod_worker): Add constructor and destructor.
2327 <data>: Remove.
2328 <value>: Remove.
2329 <invoke, clone, do_get_result_type, do_get_arg_types>: New
2330 virtual pure methods.
2331 <get_arg_types, get_result_type>: New methods.
2332 (xmethod_worker_ptr): Remove typedef.
2333 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
2334 (xmethod_worker_vec): Remove typedef.
2335 (xmethod_worker_up): New typedef.
2336 (invoke_xmethod): Remove.
2337 (clone_xmethod_worker): Remove.
2338 (free_xmethod_worker): Remove.
2339 (free_xmethod_worker_vec): Remove.
2340 (get_xmethod_arg_types): Remove.
2341 (get_xmethod_result_type): Remove.
2342 * valops.c (find_method_list): Use std::vector, don't use
2343 intermediate vector.
2344 (value_find_oload_method_list): Use std::vector.
2345 (find_overload_match): Use std::vector.
2346 (find_oload_champ): Use std::vector.
2347 * value.c (value_free): Use operator delete.
2348 (value_of_xmethod): Rename to...
2349 (value_from_xmethod): ... this. Don't assign
2350 xmethod_worker::value, take rvalue-reference.
2351 (result_type_of_xmethod): Adjust.
2352 (call_xmethod): Adjust.
2353 * value.h: Include extension.h.
2354 (struct xmethod_worker): Don't forward-declare.
2355 (value_of_xmethod): Rename to...
2356 (value_from_xmethod): ... this, take rvalue-reference.
2357 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
2358 (struct python_xmethod_worker): ... this, add constructor and
2359 destructor.
2360 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
2361 (gdbpy_free_xmethod_worker_data): Rename to...
2362 (python_xmethod_worker::~python_xmethod_worker): ... this and
2363 adjust.
2364 (gdbpy_clone_xmethod_worker_data): Rename to...
2365 (python_xmethod_worker::clone): ... this and adjust.
2366 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
2367 temporary vector.
2368 (gdbpy_get_xmethod_arg_types): Rename to...
2369 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
2370 (gdbpy_get_xmethod_result_type): Rename to...
2371 (python_xmethod_worker::do_get_result_type): ... this and
2372 adjust.
2373 (gdbpy_invoke_xmethod): Rename to...
2374 (python_xmethod_worker::invoke): ... this and adjust.
2375 (new_python_xmethod_worker): Rename to...
2376 (python_xmethod_worker::python_xmethod_worker): ... this and
2377 adjust.
2378 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
2379 Remove.
2380 (gdbpy_free_xmethod_worker_data): Remove.
2381 (gdbpy_get_matching_xmethod_workers): Use std::vector.
2382 (gdbpy_get_xmethod_arg_types): Remove.
2383 (gdbpy_get_xmethod_result_type): Remove.
2384 (gdbpy_invoke_xmethod): Remove.
2385 * python/python.c (python_extension_ops): Remove obsolete
2386 callbacks.
2387
2388 2018-01-05 Pedro Alves <palves@redhat.com>
2389
2390 PR gdb/18653
2391 * common/signals-state-save-restore.c
2392 (save_original_signals_state): New parameter 'quiet'. Warn if we
2393 find a custom handler preinstalled, instead of internal erroring.
2394 But only warn if !quiet.
2395 * common/signals-state-save-restore.h
2396 (save_original_signals_state): New parameter 'quiet'.
2397 * main.c (captured_main_1): Move save_original_signals_state call
2398 after option handling, and pass QUIET.
2399
2400 2018-01-05 Pedro Alves <palves@redhat.com>
2401
2402 * spu-tdep.c (spu_catch_start): Pass
2403 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
2404
2405 2018-01-05 Pedro Alves <palves@redhat.com>
2406
2407 PR gdb/22670
2408 * ada-lang.c (literal_symbol_name_matcher): New function.
2409 (ada_get_symbol_name_matcher): Use it for
2410 symbol_name_match_type::SEARCH_NAME.
2411 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
2412 it down instead of assuming symbol_name_match_type::FULL.
2413 * block.h (block_lookup_symbol): New parameter 'match_type'.
2414 * c-valprint.c (print_unpacked_pointer): Use
2415 lookup_symbol_search_name instead of lookup_symbol.
2416 * compile/compile-object-load.c (get_out_value_type): Pass down
2417 symbol_name_match_type::SEARCH_NAME.
2418 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
2419 symbol_name_match_type::FULL.
2420 * cp-support.c (cp_get_symbol_name_matcher): Handle
2421 symbol_name_match_type::SEARCH_NAME.
2422 * infrun.c (insert_exception_resume_breakpoint): Use
2423 lookup_symbol_search_name.
2424 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
2425 * psymtab.c (maintenance_check_psymtabs): Use
2426 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
2427 * stack.c (print_frame_args): Use lookup_symbol_search_name and
2428 SYMBOL_SEARCH_NAME.
2429 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
2430 if symbol_name_match_type::SEARCH_NAME.
2431 (lookup_symbol_in_language): Pass down
2432 symbol_name_match_type::FULL.
2433 (lookup_symbol_search_name): New.
2434 (lookup_language_this): Pass down
2435 symbol_name_match_type::SEARCH_NAME.
2436 (lookup_symbol_aux, lookup_local_symbol): New parameter
2437 'match_type'. Pass it down.
2438 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
2439 (lookup_symbol_search_name): New declaration.
2440 (lookup_symbol_in_block): New 'match_type' parameter.
2441
2442 2018-01-05 Pedro Alves <palves@redhat.com>
2443
2444 PR gdb/22670
2445 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
2446 ada_lookup_symbol.
2447 (ada_lookup_symbol): Reimplement in terms of
2448 ada_lookup_symbol_list, bits factored out from
2449 ada_lookup_encoded_symbol.
2450
2451 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2452
2453 * ada-exp.y (write_object_renaming): When subscripting an array
2454 using a symbol as the index, pass the block in call to
2455 ada_lookup_encoded_symbol when looking that symbol up.
2456
2457 2018-01-05 Jerome Guitton <guitton@adacore.com>
2458
2459 * ada-lang.c (ada_array_length): Use ada_index_type instead of
2460 TYPE_INDEX_TYPE.
2461
2462 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2463
2464 * ada-lang.c (ada_to_fixed_value_create): Add handling of
2465 the case where VALUE_LVAL (val0) is not lval_memory.
2466
2467 2018-01-05 Xavier Roirand <roirand@adacore.com>
2468
2469 * ada-valprint.c (print_optional_low_bound): Handle
2470 character-indexed array printing like boolean-indexed array
2471 printing.
2472
2473 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2474
2475 * NEWS: Create a new section for the next release branch.
2476 Rename the section of the current branch, now that it has
2477 been cut.
2478
2479 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2480
2481 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
2482 * version.in: Bump version to 8.1.50.DATE-git.
2483
2484 2018-01-03 Xavier Roirand <roirand@adacore.com>
2485
2486 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
2487 Add field.
2488 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
2489 Add field.
2490 (default_exception_support_info) <catch_handlers_sym>: Add field.
2491 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
2492 (ada_exception_name_addr_1): Add "catch handlers" handling.
2493 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
2494 Update all callers.
2495 (create_excep_cond_exprs) <ex>: Add parameter.
2496 (re_set_exception): Update create_excep_cond_exprs call.
2497 (print_it_exception, print_one_exception, print_mention_exception)
2498 (print_recreate_exception): Add "catch handler" handling.
2499 (allocate_location_catch_handlers, re_set_catch_handlers)
2500 (check_status_catch_handlers, print_it_catch_handlers)
2501 (print_one_catch_handlers, print_mention_catch_handlers)
2502 (print_recreate_catch_handlers): New function.
2503 (catch_handlers_breakpoint_ops): New variable.
2504 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
2505 Add parameter. Add "catch handler" handling.
2506 (ada_exception_sym_name, ada_exception_breakpoint_ops):
2507 Add "catch handler" handling.
2508 (ada_exception_catchpoint_cond_string): Add "catch handler"
2509 handling.
2510 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
2511 call.
2512 (catch_ada_handlers_command): New function.
2513 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
2514 operations structure.
2515 (_initialize_ada_language): Add "catch handlers" command entry.
2516 * NEWS: Document "catch handlers" feature.
2517
2518 2018-01-02 Joel Brobecker <brobecker@adacore.com>
2519
2520 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
2521 account when creating the array type of the slice.
2522 (ada_value_slice): Likewise.
2523
2524 2018-01-02 Joel Brobecker <brobecker@adacore.com>
2525
2526 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
2527 New enum value.
2528 (create_array_type_with_stride): Add byte_stride_prop parameter.
2529 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
2530 New parameter. Update all callers in this file.
2531 (array_type_has_dynamic_stride): New function.
2532 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
2533 of arrays with dynamic byte strides.
2534 * dwarf2read.c (read_array_type): Add support for dynamic
2535 DW_AT_byte_stride attributes.
2536
2537 2018-01-02 Joel Brobecker <brobecker@adacore.com>
2538
2539 * dwarf2read.c (read_unspecified_type): Treat
2540 DW_TAG_enumeration_type DIEs from Ada units as stubs.
2541
2542 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2543
2544 Update copyright year range in all GDB files.
2545
2546 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2547
2548 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
2549 and gdb/testsuite/gdb.base/step-line.c.
2550
2551 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2552
2553 * copyright.py (main): Dump the contents of
2554 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
2555 even if BY_HAND is empty.
2556
2557 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2558
2559 * top.c (print_gdb_version): Update Copyright year in version
2560 message.
2561
2562 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2563
2564 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
2565
2566 For older changes see ChangeLog-2017.
2567 \f
2568 Local Variables:
2569 mode: change-log
2570 left-margin: 8
2571 fill-column: 74
2572 version-control: never
2573 coding: utf-8
2574 End:
This page took 0.128328 seconds and 4 git commands to generate.