Add selftests for range_contains and insert_into_bit_range_vector
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
d5f4488f
SM
12018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2 Pedro Alves <palves@redhat.com>
3
4 * value.c: Include "selftest.h" and "common/array-view.h".
5 (struct range) <operator ==>: New.
6 (test_ranges_contain): New.
7 (check_ranges_vector): New.
8 (test_insert_into_bit_range_vector): New.
9 (_initialize_values): Register selftests.
10 * common/array-view.h (operator==, operator!=): New.
11
b24531ed
SM
122018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13
14 * common/gdb_vecs.h (unordered_remove): Add overload that takes
15 an iterator.
16 * inline-frame.c: Include <algorithm>.
17 (struct inline_state): Add constructor.
18 (inline_state_s): Remove.
19 (DEF_VEC_O(inline_state_s)): Remove.
20 (inline_states): Change type to std::vector.
21 (find_inline_frame_state): Adjust to std::vector.
22 (allocate_inline_frame_state): Remove.
23 (clear_inline_frame_state): Adjust to std::vector.
24 (skip_inline_frames): Adjust to std::vector.
25
c252925c
SM
262018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
27
28 * tracepoint.h (struct trace_state_variable): Add constructor.
29 <name>: Change type to std::string.
30 * tracepoint.c (tsv_s): Remove.
31 (DEF_VEC_O(tsv_s)): Remove.
32 (tvariables): Change to std::vector.
33 (create_trace_state_variable): Adjust to std::vector.
34 (find_trace_state_variable): Likewise.
35 (find_trace_state_variable_by_number): Likewise.
36 (delete_trace_state_variable): Likewise.
37 (trace_variable_command): Adjust to std::string.
38 (delete_trace_variable_command): Likewise.
39 (tvariables_info_1): Adjust to std::vector.
40 (save_trace_state_variables): Likewise.
41 (start_tracing): Likewise.
42 (merge_uploaded_trace_state_variables): Adjust to std::vector
43 and std::string.
44 * target.h (struct target_ops)
45 <to_download_trace_state_variable>: Pass reference to
46 trace_state_variable.
47 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
48 * target-delegates.c: Re-generate.
49 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
50 (mi_tsv_deleted): Likewise.
51 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
52 * remote.c (remote_download_trace_state_variable): Change
53 pointer to reference and adjust.
54 * make-target-delegates (parse_argtypes): Handle references.
55 (write_function_header): Likewise.
56 (munge_type): Likewise.
57
c9638d26
SM
582018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
59
60 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
61 string_view-selftests.c.
62 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
63 testsuite.
64 * unittests/basic_string_view/cons/char/1.cc: Likewise.
65 * unittests/basic_string_view/cons/char/2.cc: Likewise.
66 * unittests/basic_string_view/cons/char/3.cc: Likewise.
67 * unittests/basic_string_view/element_access/char/1.cc:
68 Likewise.
69 * unittests/basic_string_view/element_access/char/empty.cc:
70 Likewise.
71 * unittests/basic_string_view/element_access/char/front_back.cc:
72 Likewise.
73 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
74 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
75 Likewise.
76 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
77 Likewise.
78 * unittests/basic_string_view/modifiers/swap/char/1.cc:
79 Likewise.
80 * unittests/basic_string_view/operations/compare/char/1.cc:
81 Likewise.
82 * unittests/basic_string_view/operations/compare/char/13650.cc:
83 Likewise.
84 * unittests/basic_string_view/operations/copy/char/1.cc:
85 Likewise.
86 * unittests/basic_string_view/operations/data/char/1.cc:
87 Likewise.
88 * unittests/basic_string_view/operations/find/char/1.cc:
89 Likewise.
90 * unittests/basic_string_view/operations/find/char/2.cc:
91 Likewise.
92 * unittests/basic_string_view/operations/find/char/3.cc:
93 Likewise.
94 * unittests/basic_string_view/operations/find/char/4.cc:
95 Likewise.
96 * unittests/basic_string_view/operations/rfind/char/1.cc:
97 Likewise.
98 * unittests/basic_string_view/operations/rfind/char/2.cc:
99 Likewise.
100 * unittests/basic_string_view/operations/rfind/char/3.cc:
101 Likewise.
102 * unittests/basic_string_view/operations/substr/char/1.cc:
103 Likewise.
104 * unittests/basic_string_view/operators/char/2.cc: Likewise.
105 * unittests/string_view-selftests.c: New file.
106
fdc11678
SM
1072018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
108
109 * unittests/basic_string_view/capacity/1.cc: New file.
110 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
111 * unittests/basic_string_view/cons/char/1.cc: New file.
112 * unittests/basic_string_view/cons/char/2.cc: New file.
113 * unittests/basic_string_view/cons/char/3.cc: New file.
114 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
115 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
116 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
117 * unittests/basic_string_view/element_access/char/1.cc: New file.
118 * unittests/basic_string_view/element_access/char/2.cc: New file.
119 * unittests/basic_string_view/element_access/char/empty.cc: New file.
120 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
121 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
122 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
123 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
124 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
125 * unittests/basic_string_view/include.cc: New file.
126 * unittests/basic_string_view/inserters/char/1.cc: New file.
127 * unittests/basic_string_view/inserters/char/2.cc: New file.
128 * unittests/basic_string_view/inserters/char/3.cc: New file.
129 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
130 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
131 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
132 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
133 * unittests/basic_string_view/literals/types.cc: New file.
134 * unittests/basic_string_view/literals/values.cc: New file.
135 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
136 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
137 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
138 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
139 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
140 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
141 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
142 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
143 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
144 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
145 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
146 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
147 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
148 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
149 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
150 * unittests/basic_string_view/operations/data/char/1.cc: New file.
151 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
152 * unittests/basic_string_view/operations/find/char/1.cc: New file.
153 * unittests/basic_string_view/operations/find/char/2.cc: New file.
154 * unittests/basic_string_view/operations/find/char/3.cc: New file.
155 * unittests/basic_string_view/operations/find/char/4.cc: New file.
156 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
157 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
158 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
159 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
160 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
161 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
162 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
163 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
164 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
165 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
166 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
167 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
168 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
169 * unittests/basic_string_view/operators/char/2.cc: New file.
170 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
171 * unittests/basic_string_view/range_access/char/1.cc: New file.
172 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
173 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
174 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
175 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
176 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
177 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
178 * unittests/basic_string_view/requirements/typedefs.cc: New file.
179 * unittests/basic_string_view/typedefs.cc: New file.
180 * unittests/basic_string_view/types/1.cc: New file.
181
8345c4a2
SM
1822018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
183
184 * common/gdb_string_view.h: Remove libstdc++ implementation
185 details, adjust to gdb reality.
186 * common/gdb_string_view.tcc: Likewise.
187 * cli/cli-script.c (struct string_view): Remove.
188 (user_args) <m_args>: Change element type to gdb::string_view.
189 (user_args::insert_args): Adjust.
190
7adcdf08
SM
1912018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
192
193 * common/gdb_string_view.h: New file.
194 * common/gdb_string_view.tcc: New file.
195
41260ac2
SM
1962018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
197
198 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
199 * configure: Re-generate.
200
0bee6dd4
PA
2012018-04-09 Pedro Alves <palves@redhat.com>
202
203 * gdbarch.sh: Include "observable.h" instead of "observer.h".
204 (set_target_gdbarch): Call
205 gdb::observers::architecture_changed.notify instead of
206 observer_notify_architecture_changed.
207
6f14adc5
SM
2082018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
209
210 * tracepoint.c (struct current_traceframe_cleanup): Remove.
211 (do_restore_current_traceframe_cleanup): Remove.
212 (restore_current_traceframe_cleanup_dtor): Remove.
213 (make_cleanup_restore_current_traceframe): Remove.
214 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
215 New.
216 * tracepoint.h (struct scoped_restore_current_traceframe): New.
217 * infrun.c (fetch_inferior_event): Use
218 scoped_restore_current_traceframe.
219
b2bdb8cf
SM
2202018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
221
222 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
223 Remove.
224 <n_allocated_type_units>: Remove.
225 <all_type_units>: Change to std::vector.
226 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
227 to std::vector change.
228 (dwarf2_per_objfile::get_cutu): Likewise.
229 (dwarf2_per_objfile::get_tu): Likewise.
230 (create_signatured_type_table_from_index): Likewise.
231 (create_signatured_type_table_from_debug_names): Likewise.
232 (dw2_symtab_iter_next): Likewise.
233 (dw2_print_stats): Likewise.
234 (dw2_expand_all_symtabs): Likewise.
235 (dw2_expand_marked_cus): Likewise.
236 (dw2_debug_names_iterator::next): Likewise.
237 (dwarf2_initialize_objfile): Likewise.
238 (add_signatured_type_cu_to_table): Likewise.
239 (create_all_type_units): Likewise.
240 (add_type_unit): Likewise.
241 (struct tu_abbrev_offset): Add constructor.
242 (build_type_psymtabs_1): Adjust to std::vector change.
243 (print_tu_stats): Likewise.
244 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
245 (write_debug_names): Likewise.
246
b76e467d
SM
2472018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
248
249 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
250 Make an std::vector.
251 <n_comp_units>: Remove.
252 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
253 to std::vector change.
254 (dwarf2_per_objfile::get_cutu): Likewise.
255 (dwarf2_per_objfile::get_cu): Likewise.
256 (create_cus_from_index): Likewise.
257 (create_addrmap_from_index): Likewise.
258 (create_addrmap_from_aranges): Likewise.
259 (dwarf2_read_index): Likewise.
260 (dw2_find_last_source_symtab): Likewise.
261 (dw2_map_symtabs_matching_filename): Likewise.
262 (dw2_symtab_iter_next): Likewise.
263 (dw2_print_stats): Likewise.
264 (dw2_expand_all_symtabs): Likewise.
265 (dw2_expand_symtabs_with_fullname): Likewise.
266 (dw2_expand_marked_cus): Likewise.
267 (dw2_map_symbol_filenames): Likewise.
268 (create_cus_from_debug_names): Likewise.
269 (dwarf2_read_debug_names): Likewise.
270 (dw2_debug_names_iterator::next): Likewise.
271 (dwarf2_initialize_objfile): Likewise.
272 (set_partial_user): Likewise.
273 (dwarf2_build_psymtabs_hard): Likewise.
274 (read_comp_units_from_section): Remove arguments, adjust to
275 std::vector change.
276 (create_all_comp_units): Adjust to std::vector and
277 read_comp_units_from_section changes.
278 (dwarf2_find_containing_comp_unit): Adjust to std::vector
279 change.
280 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
281 (psyms_seen_size): Likewise.
282 (write_gdbindex): Likewise.
283 (write_debug_names): Likewise.
284
12359b5e
SM
2852018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
286
287 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
288 with dwarf2_per_objfile.
289 (create_cus_from_index): Likewise.
290 (create_signatured_type_table_from_index): Likewise.
291 (dwarf2_read_index): Likewise.
292 (dwarf2_initialize_objfile): Likewise.
293 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
294 per_cu rather than get_dwarf2_per_objfile.
295
ff4c9fec
SM
2962018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
297
298 * dwarf2read.h (struct signatured_type): Forward declare.
299 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
300 New methods.
301 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
302 (dw2_get_cutu): ...this.
303 (dwarf2_per_objfile::get_cu): Rename from...
304 (dw2_get_cu): ...this.
305 (dwarf2_per_objfile::get_tu): New.
306 (create_addrmap_from_index): Adjust.
307 (create_addrmap_from_aranges): Adjust.
308 (dw2_find_last_source_symtab): Adjust.
309 (dw2_map_symtabs_matching_filename): Adjust.
310 (dw2_symtab_iter_next): Adjust.
311 (dw2_print_stats): Adjust.
312 (dw2_expand_all_symtabs): Adjust.
313 (dw2_expand_symtabs_with_fullname): Adjust.
314 (dw2_expand_marked_cus): Adjust.
315 (dw_expand_symtabs_matching_file_matcher): Adjust.
316 (dw2_map_symbol_filenames): Adjust.
317 (dw2_debug_names_iterator::next): Adjust.
318 (dwarf2_initialize_objfile): Adjust.
319 (set_partial_user): Adjust.
320 (dwarf2_build_psymtabs_hard): Adjust.
321
5ca3fcb6
SM
3222018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
323
324 * dwarf2read.c (create_signatured_type_table_from_debug_names):
325 Remove unused variables.
326 (dw2_map_symtabs_matching_filename): Likewise.
327 (dwarf2_record_block_ranges): Likewise.
328 (dwarf2_read_addr_index): Likewise.
329 (follow_die_offset): Likewise.
330
b2e586e8
SM
3312018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
332
333 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
334 to symbol_file_add_main.
335
7c4e78cf
SM
3362018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
337
338 PR mi/22299
339 * mi/mi-console.c (do_fputc_async_safe): New.
340 (mi_console_file::write_async_safe): New.
341 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
342 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
343 New.
344 * ui-file.c (ui_file::putstrn): Adjust call to
345 fputstrn_unfiltered.
346 * utils.c (printchar): Replace do_fputs and do_fprintf
347 parameters by do_fputc.
348 (fputstr_filtered): Adjust call to printchar.
349 (fputstr_unfiltered): Likewise.
350 (fputstrn_filtered): Likewise.
351 (fputstrn_unfiltered): Add do_fputc parameter, pass to
352 printchar.
353 * utils.h (do_fputc_ftype): New typedef.
354 (fputstrn_unfiltered): Add do_fputc parameter.
355
5dc026d3
SM
3562018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
357
358 * regformats/i386/i386-avx.dat: Remove.
359
c912f608
SM
3602018-04-07 Simon Marchi <simon.marchi@ericsson.com>
361
362 PR gdb/22979
363 * amd64-tdep.c (amd64_none_init_abi): New function.
364 (amd64_x32_none_init_abi): New function.
365 (_initialize_amd64_tdep): Register handlers for x86-64 and
366 x64_32 with GDB_OSABI_NONE.
367 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
368 GDB_OSABI_NONE osabi.
369
26540402
SM
3702018-04-07 Simon Marchi <simon.marchi@ericsson.com>
371
372 PR gdb/22980
373 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
374 GDB_OSABI_NONE.
375 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
376 * osabi.c (gdb_osabi_names): Add "unknown" entry.
377
9018be22
SM
3782018-04-07 Simon Marchi <simon.marchi@ericsson.com>
379
380 * common/byte-vector.h (char_vector): New type.
381 * target.h (target_read_alloc): Return
382 gdb::optional<byte_vector>.
383 (target_read_stralloc): Return gdb::optional<char_vector>.
384 (target_get_osdata): Return gdb::optional<char_vector>.
385 * target.c (target_read_alloc_1): Templatize. Replacement
386 manual memory management with vector.
387 (target_read_alloc): Change return type, adjust.
388 (target_read_stralloc): Change return type, adjust.
389 (target_get_osdata): Change return type, adjust.
390 * auxv.c (struct auxv_info) <length>: Remove.
391 <data>: Change type to gdb::optional<byte_vector>.
392 (auxv_inferior_data_cleanup): Free auxv_info with delete.
393 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
394 (target_auxv_search): Adjust.
395 (fprint_target_auxv): Adjust.
396 * avr-tdep.c (avr_io_reg_read_command): Adjust.
397 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
398 (linux_make_corefile_notes): Adjust.
399 * osdata.c (get_osdata): Adjust.
400 * remote.c (remote_get_threads_with_qxfer): Adjust.
401 (remote_memory_map): Adjust.
402 (remote_traceframe_info): Adjust.
403 (btrace_read_config): Adjust.
404 (remote_read_btrace): Adjust.
405 (remote_pid_to_exec_file): Adjust.
406 * solib-aix.c (solib_aix_get_library_list): Adjust.
407 * solib-dsbt.c (decode_loadmap): Don't free buf.
408 (dsbt_get_initial_loadmaps): Adjust.
409 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
410 * solib-target.c (solib_target_current_sos): Adjust.
411 * tracepoint.c (sdata_make_value): Adjust.
412 * xml-support.c (xinclude_start_include): Adjust.
413 (xml_fetch_content_from_file): Adjust.
414 * xml-support.h (xml_fetch_another): Change return type.
415 (xml_fetch_content_from_file): Change return type.
416 * xml-syscall.c (xml_init_syscalls_info): Adjust.
417 * xml-tdesc.c (file_read_description_xml): Adjust.
418 (fetch_available_features_from_target): Change return type.
419 (target_fetch_description_xml): Adjust.
420 (target_read_description_xml): Adjust.
421
14c88955
TT
4222018-04-06 Tom Tromey <tom@tromey.com>
423
424 * value.c (~value): Update.
425 (struct value) <contents>: Now unique_xmalloc_ptr.
426 (value_contents_bits_eq, allocate_value_contents)
427 (value_contents_raw, value_contents_all_raw)
428 (value_contents_for_printing, value_contents_for_printing_const)
429 (set_value_enclosing_type): Update.
430
0c7e6dd8
TT
4312018-04-06 Tom Tromey <tom@tromey.com>
432
433 * value.c (range_s): Remove typedef, VEC.
434 (struct range): Add operator<.
435 (range_lessthan): Remove.
436 (ranges_contain): Change type.
437 (~value): Update.
438 (struct value) <unavailable, optimized_out>: Now std::vector.
439 (value_entirely_available)
440 (value_entirely_covered_by_range_vector)
441 (value_entirely_unavailable, value_entirely_optimized_out):
442 Update.
443 (insert_into_bit_range_vector): Change argument type.
444 (find_first_range_overlap): Likewise.
445 (struct ranges_and_idx, value_contents_bits_eq)
446 (require_not_optimized_out, require_available): Update.
447 (ranges_copy_adjusted): Change argument types.
448 (value_optimized_out, value_copy, value_fetch_lazy): Update.
449
2c8331b9
TT
4502018-04-06 Tom Tromey <tom@tromey.com>
451
452 * value.c (~value): Update.
453 (struct value) <parent>: Now a value_ref_ptr.
454 (value_parent, set_value_parent, value_address, value_copy):
455 Update.
456
466ce3ae
TT
4572018-04-06 Tom Tromey <tom@tromey.com>
458
459 * value.c (struct value): Add constructor, destructor, and member
460 initializers.
461 (allocate_value_lazy, value_decref): Update.
462
062d818d
TT
4632018-04-06 Tom Tromey <tom@tromey.com>
464
465 * value.c (struct value) <released, next>: Remove.
466 (all_values): Now a std::vector.
467 (allocate_value_lazy): Update.
468 (value_next): Remove.
469 (value_mark, value_free_to_mark, release_value)
470 (value_release_to_mark): Update.
471
a6535de1
TT
4722018-04-06 Tom Tromey <tom@tromey.com>
473
474 * value.h (fetch_subexp_value, value_release_to_mark): Update.
475 (free_value_chain): Remove.
476 * value.c (free_value_chain): Remove.
477 (value_release_to_mark): Return a std::vector.
478 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
479 std::vector.
480 (check_condition): Update.
481 * eval.c (fetch_subexp_value): Change "val_chain" to a
482 std::vector.
483 * breakpoint.c (update_watchpoint): Update.
484 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
485
b5621201
TT
4862018-04-06 Tom Tromey <tom@tromey.com>
487
488 * value.h (free_all_values): Remove.
489 * value.c (free_all_values): Remove.
490
4d0266a0
TT
4912018-04-06 Tom Tromey <tom@tromey.com>
492
493 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
494 (value_history_chain, value_history_count): Remove.
495 (value_history): New global.
496 (record_latest_value, access_value_history, show_values)
497 (preserve_values): Update.
498
b4d61099
TT
4992018-04-06 Tom Tromey <tom@tromey.com>
500
501 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
502 * varobj.c (varobj_set_display_format, varobj_set_value)
503 (install_default_visualizer, construct_visualizer)
504 (install_new_value, ~varobj, varobj_get_value_type)
505 (my_value_of_variable, varobj_editable_p): Update.
506 * c-varobj.c (c_describe_child, c_value_of_variable)
507 (cplus_number_of_children, cplus_describe_child): Update.
508 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
509 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
510 (ada_value_of_variable, ada_value_is_changeable_p): Update.
511
9b558729
TT
5122018-04-06 Tom Tromey <tom@tromey.com>
513
514 * printcmd.c (last_examine_address): Change type to
515 value_ref_ptr.
516 (do_examine, x_command): Update.
517
850645cf
TT
5182018-04-06 Tom Tromey <tom@tromey.com>
519
520 * value.c (release_value): Update.
521 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
522 (struct bpstats) <val>: Now a value_ref_ptr.
523 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
524 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
525 (~watchpoint, print_it_watchpoint, watch_command_1)
526 (invalidate_bp_value_on_memory_change): Update.
527
22bc8444
TT
5282018-04-06 Tom Tromey <tom@tromey.com>
529
530 * varobj.c (varobj_clear_saved_item)
531 (update_dynamic_varobj_children, install_new_value, ~varobj):
532 Update.
533 * value.h (value_incref): Move declaration earlier.
534 (value_decref): Rename from value_free.
535 (struct value_ref_policy): New.
536 (value_ref_ptr): New typedef.
537 (struct value_deleter): Remove.
538 (gdb_value_up): Remove typedef.
539 (release_value): Change return type.
540 (release_value_or_incref): Remove.
541 * value.c (set_value_parent): Update.
542 (value_incref): Change return type.
543 (value_decref): Rename from value_free.
544 (value_free_to_mark, free_all_values, free_value_chain): Update.
545 (release_value): Return value_ref_ptr.
546 (release_value_or_incref): Remove.
547 (record_latest_value, set_internalvar, clear_internalvar):
548 Update.
549 * stack.c (info_frame_command): Don't call value_free.
550 * python/py-value.c (valpy_dealloc, valpy_new)
551 (value_to_value_object): Update.
552 * printcmd.c (do_examine): Update.
553 * opencl-lang.c (lval_func_free_closure): Update.
554 * mi/mi-main.c (register_changed_p): Don't call value_free.
555 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
556 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
557 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
558 value_free.
559 * guile/scm-value.c (vlscm_free_value_smob)
560 (vlscm_scm_from_value): Update.
561 * frame.c (frame_register_unwind, frame_unwind_register_signed)
562 (frame_unwind_register_unsigned, get_frame_register_bytes)
563 (put_frame_register_bytes): Don't call value_free.
564 * findvar.c (address_from_register): Don't call value_free.
565 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
566 * dwarf2loc.c (entry_data_value_free_closure)
567 (value_of_dwarf_reg_entry, free_pieced_value_closure)
568 (dwarf2_evaluate_loc_desc_full): Update.
569 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
570 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
571 (~watchpoint, watch_command_1)
572 (invalidate_bp_value_on_memory_change): Update.
573 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
574
7f8a5d38
SM
5752018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
576
577 PR gdb/23022
578 * warning.m4: Add -Wno-error=deprecated-register.
579 * configure: Re-generate.
580
8a76bd3b
TT
5812018-04-05 Tom Tromey <tom@tromey.com>
582
583 * linespec.h: Remove include of "vec.h".
584
8e8d776e
TT
5852018-04-05 Tom Tromey <tom@tromey.com>
586
587 * linespec.c (typep): Remove typedef.
588 (find_methods, find_superclass_methods): Take a std::vector.
589 (find_method): Use std::vector.
590
9b2f8581
TT
5912018-04-05 Tom Tromey <tom@tromey.com>
592
593 * utils.c (compare_strings): Remove.
594 * utils.h (compare_strings): Remove.
595 * objc-lang.h (find_imps): Update.
596 * objc-lang.c (find_methods): Take a std::vector.
597 (uniquify_strings, find_imps): Likewise.
598 * linespec.c (find_methods): Take a std::vector.
599 (decode_objc): Use std::vector.
600 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
601 a std::vector.
602 (find_method, find_function_symbols): Use std::vector.
603
459a2e4c
TT
6042018-04-05 Tom Tromey <tom@tromey.com>
605
606 * completer.c (completion_tracker::completion_tracker): Remove
607 cast.
608 (completion_tracker::discard_completions): Likewise.
609 * breakpoint.c (ambiguous_names_p): Remove cast.
610 * ada-lang.c (_initialize_ada_language): Remove cast.
611 * utils.h (streq): Update.
612 (streq_hash): Add new declaration.
613 * utils.c (streq): Return bool.
614 (streq_hash): New function.
615
9be2c17a
TT
6162018-04-05 Tom Tromey <tom@tromey.com>
617
618 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
619 Remove a string copy.
620
f73c6ece
TT
6212018-04-05 Tom Tromey <tom@tromey.com>
622
623 * linespec.c (filter_results): Use std::vector.
624 (decode_line_2, decode_line_full): Update.
625
53a0f8a2
TT
6262018-04-05 Tom Tromey <tom@tromey.com>
627
628 * linespec.c (canonical_to_fullform): Return std::string.
629 (filter_results): Update.
630 (struct decode_line_2_item): Add constructor.
631 <fullform, displayform>: Now std::string.
632 (decode_line_2_compare_items): Now a std::sort comparator.
633 (decode_line_2): Update.
634
a5b5adf5
TT
6352018-04-05 Tom Tromey <tom@tromey.com>
636
637 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
638 (unexpected_linespec_error): Update.
639 (linespec_parse_basic, parse_linespec): Update.
640
6a307fc5
TT
6412018-04-05 Tom Tromey <tom@tromey.com>
642
643 * linespec.c (linespec_parse_basic): Reindent.
644
41c1efc6
TT
6452018-04-05 Tom Tromey <tom@tromey.com>
646
647 * minsyms.h (iterate_over_minimal_symbols): Update.
648 * minsyms.c (iterate_over_minimal_symbols): Take a
649 gdb::function_view.
650 * linespec.c (struct collect_minsyms): Remove.
651 (compare_msyms): Now a std::sort comparator.
652 (add_minsym): Add parameters.
653 (search_minsyms_for_name): Update. Use std::vector.
654
c5edbf3d
TT
6552018-04-03 Tom Tromey <tom@tromey.com>
656
657 * mipsread.c (read_alphacoff_dynamic_symtab): Use
658 gdb::byte_vector.
659
b39efc48
WP
6602018-04-02 Weimin Pan <weimin.pan@oracle.com>
661
662 * MAINTAINERS (Write After Approval): Add Weimin Pan.
663
121ad66c 6642018-04-02 Weimin Pan <weimin.pan@oracle.com>
79f18731
WP
665
666 PR gdb/16959
667 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
668 printing static type.
669
09473be8
TT
6702018-04-01 Tom Tromey <tom@tromey.com>
671
672 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
673 (rs6000_xfer_shared_libraries): Update.
674
ec1f2d91
SM
6752018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
676
677 * common/gdb_vecs.h (char_ptr): Remove.
678 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
679
d8611974
SM
6802018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
681
682 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
683 with std::vector.
684 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
685
a18ba4e4
SM
6862018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
687
688 * tracepoint.h (struct uploaded_tp): Initialize fields.
689 <actions, step_actions, cmd_strings>: Change type to
690 std::vector<char *>.
691 * tracepoint.c (get_uploaded_tp): Allocate with new.
692 (free_uploaded_tps): Free with delete.
693 (parse_tracepoint_definition): Adjust to std::vector change.
694 * breakpoint.c (read_uploaded_action): Likewise.
695 (create_tracepoint_from_upload): Likewise.
696 * ctf.c (ctf_write_uploaded_tp): Likewise.
697 (SET_ARRAY_FIELD): Likewise.
698 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
699
a7961323
TT
7002018-03-30 Tom Tromey <tom@tromey.com>
701
702 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
703 std::unique_ptr.
704 (svr4_keep_data_in_core): Update.
705 (svr4_read_so_list): Update.
706
e83e4e24
TT
7072018-03-30 Tom Tromey <tom@tromey.com>
708
709 * windows-nat.c (handle_output_debug_string, handle_exception):
710 Update.
711 * target.h (target_read_string): Update.
712 * target.c (target_read_string): Change "string" to
713 unique_xmalloc_ptr.
714 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
715 Update.
716 * solib-frv.c (frv_current_sos): Update.
717 * solib-dsbt.c (dsbt_current_sos): Update.
718 * solib-darwin.c (darwin_current_sos): Update.
719 * linux-thread-db.c (inferior_has_bug): Update.
720 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
721 Update. Remove alloca.
722 * ada-lang.c (ada_main_name): Update.
723
263db9a1
TT
7242018-03-30 Tom Tromey <tom@tromey.com>
725
726 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
727 (struct dwo_file_deleter): New.
728 (dwo_file_up): New typedef.
729 (open_and_init_dwo_file): Use dwo_file_up.
730 (free_dwo_file_cleanup): Remove.
731
5dafb3d1
TT
7322018-03-30 Tom Tromey <tom@tromey.com>
733
734 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
735 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
736
11ed8cad
TT
7372018-03-30 Tom Tromey <tom@tromey.com>
738
739 * dwarf2read.c (class free_cached_comp_units): New class.
740 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
741 (free_cached_comp_units): Remove function.
742
9ae79dac
TT
7432018-03-30 Tom Tromey <tom@tromey.com>
744
745 * utils.h (make_cleanup_unpush_target): Remove.
746 * inf-ptrace.c (struct target_unpusher): New.
747 (target_unpush_up) New typedef.
748 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
749 target_unpush_up.
750 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
751
5aa89276
TT
7522018-03-27 Tom Tromey <tom@tromey.com>
753
754 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
755
1dbeed45
TT
7562018-03-27 Pedro Alves <palves@redhat.com>
757 Tom Tromey <tom@tromey.com>
758
759 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
760 destructor. Now a class.
761 (gdb_readline_wrapper_cleanup): Remove function.
762 (gdb_readline_wrapper): Remove cleanups.
763
c819b2c0
TT
7642018-03-27 Tom Tromey <tom@tromey.com>
765
766 * typeprint.h (struct type_print_options) <local_typedefs,
767 global_typedefs>: Remove "struct" keyword.
768 (class typedef_hash_table): New class.
769 (recursively_update_typedef_hash, add_template_parameters)
770 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
771 (find_typedef_in_hash): Don't declare.
772 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
773 (typedef_hash_table::recursively_update): Rename from
774 recursively_update_typedef_hash. Now a member.
775 (typedef_hash_table::add_template_parameters): Rename from
776 add_template_parameters. Now a member.
777 (typedef_hash_table::typedef_hash_table): Now a constructor;
778 rename from create_typedef_hash.
779 (typedef_hash_table::~typedef_hash_table): Now a destructor;
780 rename from free_typedef_hash.
781 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
782 (do_free_global_table): Remove.
783 (typedef_hash_table::typedef_hash_table): New constructor; renamed
784 from copy_type_recursive.
785 (create_global_typedef_table): Remove.
786 (typedef_hash_table::find_global_typedef): Now a member of
787 typedef_hash_table.
788 (typedef_hash_table::find_typedef): Rename from
789 find_typedef_in_hash; now a member.
790 (whatis_exp): Update.
791 * extension.h (struct ext_lang_type_printers): Add constructor and
792 destructor.
793 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
794 declare.
795 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
796 Now a constructor; rename from start_ext_lang_type_printers.
797 (ext_lang_type_printers): Now a destructor; rename from
798 free_ext_lang_type_printers.
799 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
800 Update.
801 (c_type_print_base_struct_union): Update. Remove cleanups.
802
608219fb
TT
8032018-03-27 Tom Tromey <tom@tromey.com>
804
805 * dwarf-index-write.c: Include <cmath>.
806
3fcded8f
JB
8072018-03-27 Joel Brobecker <brobecker@adacore.com>
808
809 * NEWS: Add entry describing new "set|show varsize-limit" command.
810 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
811 command.
812 * printcmd.c (_initialize_printcmd): Add "set var" alias of
813 "set variable".
814
cd4fb1b2
SM
8152018-03-27 Simon Marchi <simon.marchi@ericsson.com>
816
817 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
818 dwarf-index-write.c
819 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
820 * dwarf-index-common.c: New file.
821 * dwarf-index-common.h: New file.
822 * dwarf-index-write.c: New file.
823 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
824 (struct dwarf2_section_info): Move from here.
825 (dwarf2_section_info_def): Likewise.
826 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
827 (offset_type): Likewise.
828 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
829 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
830 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
831 (byte_swap): Likewise.
832 (MAYBE_SWAP): Likewise.
833 (dwarf2_per_cu_ptr): Likewise.
834 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
835 (struct tu_stats): Likewise.
836 (struct dwarf2_per_objfile): Likewise.
837 (struct dwarf2_per_cu_data): Likewise.
838 (struct signatured_type): Likewise.
839 (sig_type_ptr): Likewise.
840 (DEF_VEC_P (sig_type_ptr)): Likewise.
841 (INDEX4_SUFFIX): Likewise.
842 (INDEX5_SUFFIX): Likewise.
843 (DEBUG_STR_SUFFIX): Likewise.
844 (dwarf2_read_section): Make non-static.
845 (mapped_index_string_hash): Move from here.
846 (dwarf5_djb_hash): Likewise.
847 (file_write): Likewise.
848 (class data_buf): Likewise.
849 (struct symtab_index_entry): Likewise.
850 (struct mapped_symtab): Likewise.
851 (find_slot): Likewise.
852 (hash_expand): Likewise.
853 (add_index_entry): Likewise.
854 (uniquify_cu_indices): Likewise.
855 (class c_str_view): Likewise.
856 (class c_str_view_hasher): Likewise.
857 (class vector_hasher): Likewise.
858 (write_hash_table): Likewise.
859 (psym_index_map): Likewise.
860 (struct addrmap_index_data): Likewise.
861 (add_address_entry): Likewise.
862 (add_address_entry_worker): Likewise.
863 (write_address_map): Likewise.
864 (symbol_kind): Likewise.
865 (write_psymbols): Likewise.
866 (struct signatured_type_index_data): Likewise.
867 (write_one_signatured_type): Likewise.
868 (recursively_count_psymbols): Likewise.
869 (recursively_write_psymbols): Likewise.
870 (class debug_names): Likewise.
871 (check_dwarf64_offsets): Likewise.
872 (psyms_seen_size): Likewise.
873 (write_gdbindex): Likewise.
874 (write_debug_names): Likewise.
875 (assert_file_size): Likewise.
876 (write_psymtabs_to_index): Likewise.
877 (save_gdb_index_command): Likewise.
878 (_initialize_dwarf2_read): Don't register the "save gdb-index"
879 command.
880 * dwarf2read.h: New file.
881
59cc4834
JB
8822018-03-27 Joel Brobecker <brobecker@adacore.com>
883
884 PR gdb/22670
885 * dwarf2read.c (dwarf2_physname): Do not return the demangled
886 symbol name if the CU's language stores symbol names in linkage
887 format.
888 * language.h (struct language_defn)
889 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
890 all instances of this struct.
891
67501539
TT
8922018-03-26 Tom Tromey <tom@tromey.com>
893
894 * stack.c (backtrace_command_1): Remove verbose code.
895
76c939ac
TT
8962018-03-26 Tom Tromey <tom@tromey.com>
897
898 * python/py-framefilter.c (py_print_type): Don't catch
899 exceptions. Return void.
900 (py_print_value): Likewise.
901 (py_print_single_arg): Likewise.
902 (enumerate_args): Don't catch exceptions.
903 (py_print_args): Likewise.
904 (py_print_frame): Likewise.
905 (gdbpy_apply_frame_filter): Catch exceptions here.
906
9507b29c
TT
9072018-03-26 Tom Tromey <tom@tromey.com>
908
909 * stack.c (_initialize_stack): Remove trailing newlines from help
910 text. Add "Usage" line to "backtrace" help.
911
eb68e487
TT
9122018-03-26 Tom Tromey <tom@tromey.com>
913
914 PR python/16486:
915 * python/py-framefilter.c (py_print_args): Call wrap_hint.
916
1f111921
TT
9172018-03-26 Tom Tromey <tom@tromey.com>
918
919 * python/py-framefilter.c (py_print_single_arg): Return
920 EXT_LANG_BT_ERROR from catch.
921
fb7eb8b5
TT
9222018-03-26 Tom Tromey <tom@tromey.com>
923
924 PR backtrace/15584:
925 * stack.c (backtrace_command_1): Move some code into no-filters
926 "if".
927
4ca59a9f
TT
9282018-03-26 Tom Tromey <tom@tromey.com>
929
930 * python/py-framefilter.c (throw_quit_or_print_exception): New
931 function.
932 (gdbpy_apply_frame_filter): Use it.
933
92256134
TT
9342018-03-26 Tom Tromey <tom@tromey.com>
935
936 PR cli/17716:
937 * python/py-framefilter.c (py_print_type, py_print_value)
938 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
939 RETURN_MASK_ERROR.
940
7a630bc2
TT
9412018-03-26 Tom Tromey <tom@tromey.com>
942
943 * python/py-framefilter.c (enumerate_args): Use
944 gdb::unique_xmalloc_ptr.
945
63283d4a
TT
9462018-03-26 Tom Tromey <tom@tromey.com>
947
948 * python/py-framefilter.c (py_print_frame): Return
949 EXT_LANG_BT_OK.
950 (gdbpy_apply_frame_filter): Update comment.
951 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
952 Remove.
953 <EXT_LANG_BT_NO_FILTERS>: Change value.
954
978d6c75
TT
9552018-03-26 Tom Tromey <tom@tromey.com>
956
957 PR backtrace/15582:
958 * stack.c (backtrace_command): Parse "hide" argument.
959 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
960 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
961 constant.
962
1cf7e640
TT
9632018-03-26 Tom Tromey <tom@tromey.com>
964
965 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
966 add "flags".
967 (backtrace_command): Remove "fulltrace", add "flags".
968
ea3b0687
TT
9692018-03-26 Tom Tromey <tom@tromey.com>
970
971 * stack.c (backtrace_command): Rewrite command line parsing.
972
9f034d75
SM
9732018-03-26 Simon Marchi <simon.marchi@ericsson.com>
974
975 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
976
ce1459e5
SM
9772018-03-26 Simon Marchi <simon.marchi@ericsson.com>
978
979 * filename-seen-cache.h: Add include guard.
980
4f7ae6f5
KS
9812018-03-26 Keith Seitz <keiths@redhat.com>
982
983 * symfile.c (place_section): Remove "struct" from section_addr_info
984 in comment.
985 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
986 "struct" keyword from section_addr_info.
987
5cd3e386
AH
9882018-03-26 Alan Hayward <alan.hayward@arm.com>
989
990 * regformats/regdef.h (reg): Add constructors.
991
3e5ef9a4
PA
9922018-03-25 Pedro Alves <palves@redhat.com>
993
994 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
995 if then/else bodies in var_func_name extraction.
996
c88d2fcc 9972018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
998
999 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
1000 lookup_minimal_symbol() to find symbol entry.
1001 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
1002
b7fee5a3
KS
10032018-03-23 Keith Seitz <keiths@redhat.com>
1004
1005 PR c++/22968
1006 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
1007 nested type definitions for C++, too.
1008
2cc9b304
TT
10092018-03-23 Tom Tromey <tom@tromey.com>
1010
1011 * machoread.c (struct oso_el): Add a constructor. Don't define as
1012 a typedef.
1013 (macho_register_oso): Remove.
1014 (macho_symtab_read): Take a std::vector.
1015 (oso_el_compare_name): Now a std::sort comparator.
1016 (macho_symfile_read_all_oso): Take a std::vector.
1017 (macho_symfile_read): Use std::vector. Remove cleanups.
1018
a2b2bc12
TT
10192018-03-22 Tom Tromey <tom@tromey.com>
1020
1021 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
1022 (record_full_goto_bookmark): Use std::string.
1023
7a8f494c
PFC
10242018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1025
1026 PR tdep/18295
1027 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
1028 a single mask.
1029
dd6d677f
PFC
10302018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1031
1032 * rs6000-tdep.c (store_insn_p): New function.
1033 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
1034 and cr_reg to their unshifted values. Use store_insn_p to
1035 match LR saves using either R1 or fdata->alloca_reg. Use
1036 store_insn_p to match CR saves. Set alloca_reg_offset
1037 when alloca_reg and framep are set. Remove lr_reg shift
1038 when assigning to fdata->lr_register.
1039
26d6cec4
AA
10402018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
1041
1042 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
1043 command line args instead of emitting a warning.
1044
5d9310c4
SM
10452018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
1046
1047 * tracepoint.h (struct static_tracepoint_marker): Initialize
1048 fields, define default constructor, move constructor and move
1049 assignment, disable the rest.
1050 <str_id, extra>: Make std::string.
1051 (release_static_tracepoint_marker): Remove.
1052 (free_current_marker): Remove.
1053 * tracepoint.c (free_current_marker): Remove.
1054 (parse_static_tracepoint_marker_definition): Adjust to
1055 std::string, use new hex2str overload.
1056 (release_static_tracepoint_marker): Remove.
1057 (print_one_static_tracepoint_marker): Get marker by reference
1058 and adjust to std::string.
1059 (info_static_tracepoint_markers_command): Adjust to std::vector
1060 changes
1061 * target.h (static_tracepoint_marker_p): Remove typedef.
1062 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
1063 (struct target_ops) <to_static_tracepoint_marker_at>: Return
1064 bool.
1065 <to_static_tracepoint_markers_by_strid>: Return std::vector.
1066 * target-debug.h
1067 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
1068 (target_debug_print_std_vector_static_tracepoint_marker): New.
1069 (target_debug_print_struct_static_tracepoint_marker_p): Rename
1070 to...
1071 (target_debug_print_static_tracepoint_marker_p): ... this.
1072 * target-delegates.c: Re-generate.
1073 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
1074 Make std::string.
1075 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
1076 (decode_static_tracepoint_spec): Adjust to std::vector.
1077 (tracepoint_print_one_detail): Adjust to std::string.
1078 (strace_marker_decode_location): Adjust to std::string.
1079 (update_static_tracepoint): Adjust to std::string, remove call
1080 to release_static_tracepoint_marker.
1081 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
1082 Adjust to std::vector.
1083 * remote.c (remote_static_tracepoint_marker_at): Return bool.
1084 (remote_static_tracepoint_markers_by_strid): Adjust to
1085 std::vector.
1086 * common/rsp-low.h (hex2str): New overload with explicit count
1087 of bytes.
1088 * common/rsp-low.c (hex2str): New overload with explicit count
1089 of bytes.
1090 * unittests/rsp-low-selftests.c (test_hex2str): New function.
1091 (_initialize_rsp_low_selftests): Add test_hex2str test.
1092 * unittests/tracepoint-selftests.c
1093 (test_parse_static_tracepoint_marker_definition): Adjust to
1094 std::string.
1095
62c222b6
SM
10962018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
1097
1098 * tracepoint.c (parse_static_tracepoint_marker_definition):
1099 Consider case where the definition is followed by more
1100 definitions.
1101 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1102 tracepoint-selftests.c.
1103 * unittests/tracepoint-selftests.c: New.
1104
7eb2418f
PFC
11052018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1106
1107 * MAINTAINERS (Write After Approval): Add Pedro Franco de
1108 Carvalho.
1109
7cbe16e9
SR
11102018-03-20 Stephen Roberts <stephen.roberts@arm.com>
1111
3d6b3b82 1112 * symtab.c (find_pc_sect_line): fixed indentation.
7cbe16e9 1113
4ee89e90
SR
11142018-03-20 Stephen Roberts <stephen.roberts@arm.com>
1115
3d6b3b82 1116 * symtab.c (find_pc_sect_line): now uses binary search.
4ee89e90 1117
92630041
TT
11182018-03-19 Tom Tromey <tom@tromey.com>
1119
1120 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
1121 "IDENT" production.
1122
76727919
TT
11232018-03-19 Pedro Alves <palves@redhat.com>
1124 Tom Tromey <tom@tromey.com>
1125
1126 * unittests/observable-selftests.c: New file.
1127 * common/observable.h: New file.
1128 * observable.h: New file.
1129 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
1130 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
1131 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
1132 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
1133 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
1134 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
1135 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
1136 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
1137 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
1138 python/py-breakpoint.c, python/py-finishbreakpoint.c,
1139 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
1140 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
1141 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
1142 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
1143 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
1144 tui/tui-interp.c, valops.c: Update all users.
1145 * tui/tui-hooks.c (tui_bp_created_observer)
1146 (tui_bp_deleted_observer, tui_bp_modified_observer)
1147 (tui_inferior_exit_observer, tui_before_prompt_observer)
1148 (tui_normal_stop_observer, tui_register_changed_observer):
1149 Remove.
1150 (tui_observers_token): New global.
1151 (attach_or_detach, tui_attach_detach_observers): New functions.
1152 (tui_install_hooks, tui_remove_hooks): Use
1153 tui_attach_detach_observers.
1154 * record-btrace.c (record_btrace_thread_observer): Remove.
1155 (record_btrace_thread_observer_token): New global.
1156 * observer.sh: Remove.
1157 * observer.c: Rename to observable.c.
1158 * observable.c (namespace gdb_observers): Define new objects.
1159 (observer_debug): Move into gdb_observers namespace.
1160 (struct observer, struct observer_list, xalloc_observer_list_node)
1161 (xfree_observer_list_node, generic_observer_attach)
1162 (generic_observer_detach, generic_observer_notify): Remove.
1163 (_initialize_observer): Update.
1164 Don't include observer.inc.
1165 * Makefile.in (generated_files): Remove observer.h, observer.inc.
1166 (clean mostlyclean): Likewise.
1167 (observer.h, observer.inc): Remove targets.
1168 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
1169 (COMMON_SFILES): Use observable.c, not observer.c.
1170 * .gitignore: Remove observer.h.
1171
1cb1f3da
TT
11722018-03-18 Tom Tromey <tom@tromey.com>
1173
1174 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
1175 gdb::def_vector.
1176 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
1177
a06ab151
TT
11782018-03-17 Tom Tromey <tom@tromey.com>
1179
1180 * auto-load.c (auto_load_objfile_script_1): Use std::string.
1181
770623f7
TT
11822018-03-17 Tom Tromey <tom@tromey.com>
1183
1184 * target.c (class scoped_target_fd): New.
1185 (target_fileio_close_cleanup): Remove.
1186 (target_fileio_read_alloc_1): Use scoped_target_fd.
1187
39be3c7e
SM
11882018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1189
1190 * silent-rules.mk: New.
1191 * Makefile.in: Include silent-rules.mk
1192 (srcdir, VPATH, top_srcdir): Move up.
1193 (COMPILE): Add ECHO_CXX.
1194 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
1195 (init.c): Add ECHO_INIT_C.
1196 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1197 (version.c): Add ECHO_GEN.
1198 (printcmd.o): Add ECHO_CXX.
1199 (target-float.o): Add ECHO_CXX.
1200 (ada-exp.o): Add ECHO_CXX.
1201 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
1202 (insight$(EXEEXT)): Add ECHO_CXXLD.
1203 * gnulib/configure.ac: Add AM_SILENT_RULES.
1204 * gnulib/aclocal.m4: Re-generate.
1205 * gnulib/configure: Re-generate.
1206 * gnulib/import/Makefile.in: Re-generate.
1207
37e136b1
TT
12082018-03-16 Tom Tromey <tom@tromey.com>
1209
1210 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
1211 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
1212 * utils.c (do_free_section_addr_info)
1213 (make_cleanup_free_section_addr_info): Remove.
1214 * symfile.h (struct other_sections): Add constructor.
1215 (struct section_addr_info): Remove.
1216 (section_addr_info): New typedef.
1217 (struct sym_fns) <sym_offsets>: Change type of parameter.
1218 (build_section_addr_info_from_objfile)
1219 (relative_addr_info_to_section_offsets, addr_info_make_relative)
1220 (default_symfile_offsets, symbol_file_add)
1221 (symbol_file_add_from_bfd)
1222 (build_section_addr_info_from_section_table): Update.
1223 (alloc_section_addr_info, free_section_addr_info): Don't declare.
1224 * symfile.c (alloc_section_addr_info): Remove.
1225 (build_section_addr_info_from_section_table): Change return type.
1226 Update.
1227 (build_section_addr_info_from_bfd)
1228 (build_section_addr_info_from_objfile): Likewise.
1229 (free_section_addr_info): Remove.
1230 (relative_addr_info_to_section_offsets): Change type of "addrs".
1231 (addrs_section_compar): Now a std::sort comparator.
1232 (addrs_section_sort): Change return type.
1233 (addr_info_make_relative): Change type of "addrs". Update.
1234 (default_symfile_offsets, syms_from_objfile_1)
1235 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
1236 (symbol_file_add_separate): Update.
1237 (symbol_file_add): Change type of "addrs". Update.
1238 (add_symbol_file_command): Update. Remove cleanups.
1239 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
1240 cleanups.
1241 * symfile-debug.c (debug_sym_offsets): Change type of "info".
1242 * solib.c (solib_read_symbols): Update.
1243 * objfiles.c (objfile_relocate): Update. Remove cleanups.
1244 * machoread.c (macho_symfile_offsets): Update.
1245 * jit.c (jit_bfd_try_read_symtab): Update.
1246
03afa6ef
SM
12472018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
1248
1249 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1250 unittests/utils-selftests.c.
1251 * unittests/utils-selftests.c: New file.
1252
3ae9ce5d
TT
12532018-03-14 Tom Tromey <tom@tromey.com>
1254
1255 PR cli/14977:
1256 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
1257 for NULL.
1258
b8c2339b
TT
12592018-03-14 Tom Tromey <tom@tromey.com>
1260
1261 PR cli/19918:
1262 * printcmd.c (printf_pointer): Allow "-" in format.
1263
80ae639d
TT
12642018-03-14 Tom Tromey <tom@tromey.com>
1265
1266 * printcmd.c (_initialize_printcmd): Add usage to printf.
1267
0d671d99
YQ
12682018-03-14 Yao Qi <qiyao@sourceware.org>
1269
1270 * MAINTAINERS: Update my email address.
1271
b577b6af
TT
12722018-03-13 Tom Tromey <tom@tromey.com>
1273
1274 * machoread.c (macho_check_dsym): Change filenamep to a
1275 std::string*.
1276 (macho_symfile_read): Update.
1277 * symfile.c (load_command): Use std::string.
1278
89a3b63e
AB
12792018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
1280
1281 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
1282 to error message string.
1283 (riscv_register_name): Use xsnprintf instead of sprintf.
1284 (riscv_insn::fetch_instruction): Use gdb_assert instead of
1285 internal_error.
1286 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
1287 error.
1288 (riscv_push_dummy_call): Likewise.
1289
984c7238
TT
12902018-03-12 Tom Tromey <tom@tromey.com>
1291
1292 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
1293 Use gdb::byte_vector.
1294 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
1295
933522d1
YQ
12962018-03-12 Yao Qi <yao.qi@linaro.org>
1297
1298 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
1299 parameter type to readable_regcache.
1300 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
1301 the declaration.
1302
be2daae6
TT
13032018-03-11 Tom Tromey <tom@tromey.com>
1304
1305 * dwarf2read.c (struct nextfield): Add initializers.
1306 (struct nextfnfield): Remove.
1307 (struct fnfieldlist): Add initializers. Remove "length" and
1308 "head", use std::vector.
1309 (struct decl_field_list): Remove.
1310 (struct field_info): Add initializers.
1311 <fields, baseclasses>: Now std::vector.
1312 <nbaseclasses, nfnfields, typedef_field_list_count,
1313 nested_types_list_count>: Remove.
1314 (dwarf2_add_field, dwarf2_add_type_defn)
1315 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
1316 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
1317 (process_structure_scope): Update.
1318
484cf504
TT
13192018-03-11 Tom Tromey <tom@tromey.com>
1320
1321 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
1322 for use by std::sort.
1323 (build_type_psymtabs_1): Use std::vector.
1324
9bd8e0b0
EZ
13252018-03-09 Eli Zaretskii <eliz@gnu.org>
1326
1327 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
1328 and LIBMPFR in the printed configuration.
1329
5dc1a704
TT
13302018-03-08 Tom Tromey <tom@tromey.com>
1331
1332 * source.c (get_filename_and_charpos): Use scoped_fd.
1333 * nto-procfs.c (procfs_open_1): Use scoped_fd.
1334 (procfs_pidlist): Likewise.
1335 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
1336 (iterate_over_mappings): Likewise.
1337
fdf07f3a
TT
13382018-03-08 Tom Tromey <tom@tromey.com>
1339
1340 * infcall.c (struct call_return_meta_info)
1341 <stack_temporaries_enabled>: Remove.
1342 (get_call_return_value, call_function_by_hand_dummy): Update.
1343 * thread.c (disable_thread_stack_temporaries): Remove.
1344 (enable_thread_stack_temporaries): Remove.
1345 (thread_stack_temporaries_enabled_p): Return bool.
1346 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
1347 (get_last_thread_stack_temporary): Update.
1348 * eval.c (evaluate_subexp): Update.
1349 * gdbthread.h (class enable_thread_stack_temporaries): Now a
1350 class, not a function.
1351 (value_ptr, value_vec): Remove typedefs.
1352 (class thread_info) <stack_temporaries_enabled>: Now bool.
1353 <stack_temporaries>: Now a std::vector.
1354 (thread_stack_temporaries_enabled_p)
1355 (value_in_thread_stack_temporaries): Return bool.
1356
567a3e54
SM
13572018-03-08 Simon Marchi <simon.marchi@ericsson.com>
1358
1359 * remote.c (putpkt_binary): Fix omitted bytes reporting.
1360 (getpkt_or_notif_sane_1): Likewise.
1361
00b40057
SM
13622018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1363
1364 * build-id.c (build_id_to_debug_bfd): Use std::string.
1365
a8dbfd58
SM
13662018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1367
1368 * build-id.c (find_separate_debug_file_by_buildid): Return
1369 std::string.
1370 * build-id.h (find_separate_debug_file_by_buildid): Return
1371 std::string.
1372 * coffread.c (coff_symfile_read): Adjust to std::string.
1373 * elfread.c (elf_symfile_read): Adjust to std::string.
1374 * symfile.c (separate_debug_file_exists): Change parameter to
1375 std::string.
1376 (find_separate_debug_file): Return std::string.
1377 (find_separate_debug_file_by_debuglink): Return std::string.
1378 * symfile.h (find_separate_debug_file_by_debuglink): Return
1379 std::string.
1380
e6a58aa8
SM
13812018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1382
1383 * common/xml-utils.c (xml_escape_text): Move code to...
1384 (xml_escape_text_append): ... this new function.
1385 * common/xml-utils.h (xml_escape_text_append): New declaration.
1386 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
1387 New function.
1388 (_initialize_xml_utils): register test_xml_escape_text_append as
1389 a selftest.
1390
4ef0bef6
AH
13912018-03-07 Alan Hayward <alan.hayward@arm.com>
1392
1393 * defs.h: Remove MAX_REGISTER_SIZE.
1394 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
1395 asserts.
1396 * python/py-unwind.c (pyuw_sniffer): Likewise.
1397
e0d3522b
TT
13982018-03-07 Tom Tromey <tom@tromey.com>
1399
1400 * linux-tdep.c (linux_info_proc): Update.
1401 * target.h (struct target_ops) <to_fileio_readlink>: Return
1402 optional<string>.
1403 (target_fileio_readlink): Return optional<string>.
1404 * remote.c (remote_hostio_readlink): Return optional<string>.
1405 * inf-child.c (inf_child_fileio_readlink): Return
1406 optional<string>.
1407 * target.c (target_fileio_readlink): Return optional<string>.
1408
ea005f31
AB
14092018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
1410
1411 * regcache.c (cooked_read_test): Add riscv to the list of
1412 architectures that have a save_reggroup.
1413
e95a97d4
AA
14142018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
1415
1416 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
1417 value is not a dynamic class object.
1418
d8344f3d
TT
14192018-03-06 Tom Tromey <tom@tromey.com>
1420
1421 * rust-exp.y: Formatting fixes.
1422
9add17f2
AB
14232018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1424
1425 * riscv-tdep.c (riscv_register_name): Remove target description
1426 support.
1427 (riscv_gdbarch_init): Remove target description check.
1428
c9486dfe
AB
14292018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1430
1431 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
1432 comment.
1433 * riscv-tdep.h: Likewise.
1434
d74aff3d
AB
14352018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1436
1437 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
1438 (riscv_pseudo_register_write): Delete.
1439 (riscv_gdbarch_init): Remove all use of pseudo registers.
1440
7ea78b59
SM
14412018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
1442
1443 * record-btrace.c (btrace_print_lines): Replace cleanup
1444 parameter with RAII equivalents.
1445 (btrace_insn_history): Replace cleanup with RAII equivalents.
1446 * ui-out.h (make_cleanup_ui_out_list_begin_end,
1447 make_cleanup_ui_out_tuple_begin_end): Remove.
1448 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
1449 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
1450 make_cleanup_ui_out_list_begin_end): Remove.
1451
53127008
SM
14522018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
1453
1454 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
1455 parameter types to std::vector. Use bool.
1456 (record_btrace_wait): Replace VEC(tp_t) with
1457 std::vector<thread_info *>.
1458 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
1459
228f1508
SM
14602018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
1461
1462 * record-btrace.c (record_btrace_disable_callback): Remove.
1463 (struct scoped_btrace_disable): New.
1464 (record_btrace_open): Use scoped_btrace_disable.
1465
b2970c23
AB
14662018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1467
1468 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
1469 reading values from registers.
1470
fb294655
AB
14712018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1472
1473 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
1474 where appropriate.
1475
cab5bb9d
AB
14762018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1477
1478 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
1479 change parameter type. Use GDB's print functions, and use
1480 core_addr_to_string where appropriate.
1481 (riscv_push_dummy_call): Use core_addr_to_string where
1482 appropriate, update call to riscv_print_arg_location, and reindent
1483 a few lines.
1484 (riscv_return_value): Update call to riscv_print_arg_location.
1485
dbbb1059
AB
14862018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1487 Tim Newsome <tim@sifive.com>
1488 Albert Ou <a0u@eecs.berkeley.edu>
1489 Darius Rad <darius@bluespec.com>
1490
1491 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
1492 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
1493 (ALLDEPFILES): Add riscv-tdep.c
1494 * configure.tgt: Add riscv support.
1495 * riscv-tdep.c: New file.
1496 * riscv-tdep.h: New file.
1497 * NEWS: Mention new target.
1498 * MAINTAINERS: Add entry for riscv.
1499
5dc43913
AB
15002018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
1501
1502 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
1503 fields within aggregates.
1504
3dea1ef7
SM
15052018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
1506
1507 * record-btrace.c (btrace_print_lines): Change type of flags to
1508 gdb_disassembly_flags.
1509
7efba073
JB
15102018-03-04 John Baldwin <jhb@FreeBSD.org>
1511
1512 * fbsd-nat.c: Include "inf-ptrace.h".
1513 (USE_SIGTRAP_SIGINFO): Conditionally define.
1514 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
1515 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
1516 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
1517 function.
1518 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
1519 Likewise.
1520 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
1521 Likewise.
1522 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
1523 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
1524 "supports_stopped_by_hw_breakpoint" target methods.
1525
386a8676
JB
15262018-03-04 John Baldwin <jhb@FreeBSD.org>
1527
1528 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
1529 * fbsd-nat.c (debug_fbsd_nat): New variable.
1530 (show_fbsd_nat_debug): New function.
1531 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
1532 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
1533
12279366
JB
15342018-03-04 John Baldwin <jhb@FreeBSD.org>
1535
1536 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
1537 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
1538 prototype.
1539 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
1540 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
1541 method.
1542
54693cf5
SM
15432018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1544
1545 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
1546 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
1547
ccb2231c
SM
15482018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1549
1550 * charset.c (struct charset_vector): New.
1551 (charsets): Change type to charset_vector.
1552 (find_charset_names): Adjust.
1553 (add_one): Adjust.
1554 (_initialize_charset): Adjust.
1555
6fb16ce6
SM
15562018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1557
1558 * progspace.h (struct program_space) <deleted_solibs>: Change
1559 type to std::vector<std::string>.
1560 * progspace.c (clear_program_space_solib_cache): Adjust.
1561 * breakpoint.c (print_solib_event): Adjust.
1562 (check_status_catch_solib): Adjust.
1563 * solib.c (update_solib_list): Adjust.
1564 * ui-out.h (class ui_out) <field_string>: New overload.
1565 * ui-out.c (ui_out::field_string): New overload.
1566
564b1e3f
SM
15672018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1568
1569 * progspace.h (struct program_space): Add constructor and
1570 destructor, initialize fields.
1571 (add_program_space): Remove.
1572 * progspace.c (add_program_space): Rename to...
1573 (program_space::program_space): ... this.
1574 (release_program_space): Rename to...
1575 (program_space::~program_space): ... this.
1576 (delete_program_space): Use delete to delete program_space.
1577 (initialize_progspace): Use new to allocate program_space.
1578 * inferior.c (add_inferior_with_spaces): Likewise.
1579 (clone_inferior_command): Likewise.
1580 * infrun.c (follow_fork_inferior): Likewise.
1581 (handle_vfork_child_exec_or_exit): Likewise.
1582
e80aaf61
SM
15832018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1584
1585 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
1586 (delim_string_to_char_ptr_vec): Return std::vector of
1587 gdb::unique_xmalloc_ptr.
1588 (dirnames_to_char_ptr_vec_append): Take std::vector of
1589 gdb::unique_xmalloc_ptr.
1590 (dirnames_to_char_ptr_vec): Return std::vector of
1591 gdb::unique_xmalloc_ptr.
1592 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
1593 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
1594 (delim_string_to_char_ptr_vec): Return an std::vector of
1595 gdb::unique_xmalloc_ptr, adjust the code.
1596 (dirnames_to_char_ptr_vec_append): Take an std::vector of
1597 gdb::unique_xmalloc_ptr, adjust the code.
1598 (dirnames_to_char_ptr_vec): Return an std::vector of
1599 gdb::unique_xmalloc_ptr, adjust the code.
1600 * auto-load.c (auto_load_safe_path_vec): Change type to
1601 std::vector of gdb::unique_xmalloc_ptr.
1602 (auto_load_expand_dir_vars): Return an std::vector of
1603 gdb::unique_xmalloc_ptr, adjust the code.
1604 (auto_load_safe_path_vec_update): Adjust.
1605 (filename_is_in_auto_load_safe_path_vec): Adjust.
1606 (auto_load_objfile_script_1): Adjust.
1607 * build-id.c (build_id_to_debug_bfd): Adjust.
1608 * linux-thread-db.c (thread_db_load_search): Adjust.
1609 * source.c (add_path): Adjust.
1610 (openp): Adjust.
1611 * symfile.c (find_separate_debug_file): Adjust.
1612 * utils.c (do_free_char_ptr_vec): Remove.
1613 (make_cleanup_free_char_ptr_vec): Remove.
1614
ab818ade
SDJ
16152018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
1616
1617 PR gdb/22907
1618 * common/pathstuff.c: Conditionally include "<windows.h>".
1619
e1e6f073
GS
16202018-03-01 Georg Sauthoff <mail@georg.so>
1621
1622 PR gdb/22888
1623 * gcore.in: Quote variables and switch interpreter to bash.
1624
c7b15a66
TT
16252018-03-01 Tom Tromey <tom@tromey.com>
1626
1627 * dwarf2read.c (alloc_discriminant_info): Fix default_index
1628 assertion. Add assertion for discriminant_index.
1629 (quirk_rust_enum): Use correct base type name in univariant case.
1630
0cb7c7b0
SM
16312018-03-01 Simon Marchi <simon.marchi@ericsson.com>
1632
1633 * record.c (get_call_history_modifiers): Return a
1634 record_print_flags.
1635 (cmd_record_call_history): Adjust.
1636 * record-btrace.c (record_btrace_call_history): Adjust.
1637 (record_btrace_call_history_range): Adjust.
1638 (record_btrace_call_history_from): Adjust.
1639 * target-debug.h (target_debug_print_record_print_flags): New.
1640 * target-delegates.c: Re-generate.
1641 * target.c (target_call_history): Change flags type.
1642 (target_call_history_from): Likewise.
1643 (target_call_history_range): Likewise.
1644 * target.h (struct target_ops) <target_call_history>: Likewise.
1645 (target_call_history_from): Likewise.
1646 (target_call_history_range): Likewise.
1647
25e3c82c
SDJ
16482018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1649 Simon Marchi <simon.marchi@polymtl.ca>
1650
1651 * common/common-utils.c: Include "sys/stat.h".
1652 (is_regular_file): Move here from "source.c"; change return
1653 type to "bool".
1654 * common/common-utils.h (is_regular_file): New prototype.
1655 * common/pathstuff.c (contains_dir_separator): New function.
1656 * common/pathstuff.h (contains_dir_separator): New prototype.
1657 * source.c: Don't include "sys/stat.h".
1658 (is_regular_file): Move to "common/common-utils.c".
1659
b4987c95
SDJ
16602018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1661
1662 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
1663 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
1664 * auto-load.c: Include "common/pathstuff.h".
1665 * common/common-def.h (current_directory): Move here.
1666 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
1667 function.
1668 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
1669 prototype.
1670 * common/pathstuff.c: New file.
1671 * common/pathstuff.h: New file.
1672 * compile/compile.c: Include "common/pathstuff.h".
1673 * defs.h (current_directory): Move to "common/common-defs.h".
1674 * dwarf2read.c: Include "common/pathstuff.h".
1675 * exec.c: Likewise.
1676 * guile/scm-safe-call.c: Likewise.
1677 * linux-thread-db.c: Likewise.
1678 * main.c: Likewise.
1679 * nto-tdep.c: Likewise.
1680 * objfiles.c: Likewise.
1681 * source.c: Likewise.
1682 * symtab.c: Likewise.
1683 * utils.c: Include "common/pathstuff.h".
1684 (gdb_realpath): Move to "common/pathstuff.c".
1685 (gdb_realpath_keepfile): Likewise.
1686 (gdb_abspath): Likewise.
1687 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
1688 (gdb_realpath_keepfile): Likewise.
1689 (gdb_abspath): Likewise.
1690
f169cfdc
JB
16912018-02-28 John Baldwin <jhb@FreeBSD.org>
1692
1693 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
1694 wildcard process pid for super_resume for kernels with a
1695 specific bug.
1696
e05cac70
PM
16972018-02-27 Phil Muldoon <pmuldoon@redhat.com>
1698
1699 * compile/compile.c (get_args): Add additional comments
1700 explaining function.
1701
55089490
TT
17022018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
1703 Tom Tromey <tom@tromey.com>
1704
1705 * target.h (memory_write_request_s): Remove typedef. Don't define
1706 VEC.
1707 (target_write_memory_blocks): Change argument to std::vector.
1708 (struct memory_write_request): Add constructor.
1709 * target-memory.c (compare_block_starting_address): Return bool.
1710 Change argument types.
1711 (claim_memory): Change arguments to use std::vector.
1712 (split_regular_and_flash_blocks, blocks_to_erase)
1713 (compute_garbled_blocks): Likewise.
1714 (cleanup_request_data, cleanup_write_requests_vector): Remove.
1715 (target_write_memory_blocks): Change argument to std::vector.
1716 * symfile.c (struct load_section_data): Add constructor and
1717 destructor. Use std::vector for "requests".
1718 (struct load_progress_data): Add initializers.
1719 (load_section_callback): Update. Use "new".
1720 (clear_memory_write_data): Remove.
1721 (generic_load): Update.
1722
0c305b61
AH
17232018-02-27 Alan Hayward <alan.hayward@arm.com>
1724
1725 * arch/aarch64.h: Use common/tdesc.h.
1726
c5196c92
MR
17272018-02-26 Maciej W. Rozycki <macro@mips.com>
1728
1729 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
1730 architecture with a 64-bit ABI.
1731
37c33887
MR
17322018-02-26 Maciej W. Rozycki <macro@mips.com>
1733
1734 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
1735 ahead of target description loading.
1736
d4dd3282
TT
17372018-02-26 Tom Tromey <tom@tromey.com>
1738
1739 * stack.c (backtrace_command_1): Update.
1740 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
1741 of "flags".
1742 * python/py-framefilter.c (py_print_frame)
1743 (gdbpy_apply_frame_filter): Change type of "flags".
1744 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
1745 of "flags".
1746 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
1747 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
1748 * extension.h (enum frame_filter_flag): Rename from
1749 frame_filter_flags.
1750 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
1751 (apply_ext_lang_frame_filter): Change type of "flags".
1752 * extension.c (apply_ext_lang_frame_filter): Change type of
1753 "flags".
1754 * extension-priv.h (struct extension_language_ops)
1755 <apply_frame_filter>: Change type of "flags".
1756
6893c19a
TT
17572018-02-26 Tom Tromey <tom@tromey.com>
1758
1759 PR python/16497:
1760 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
1761 off-by-one in py_end computation.
1762 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
1763 PRINT_MORE_FRAMES.
1764 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
1765 constant.
1766
2ddeaf8a
TT
17672018-02-26 Tom Tromey <tom@tromey.com>
1768
1769 * dwarf2read.c (struct variant_field): New.
1770 (struct nextfield) <variant>: New field.
1771 (dwarf2_add_field): Handle DW_TAG_variant_part.
1772 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
1773 discriminated union.
1774 (read_structure_type): Handle DW_TAG_variant_part.
1775 (handle_struct_member_die): New function, extracted from
1776 process_structure_scope. Handle DW_TAG_variant.
1777 (process_structure_scope): Handle discriminated unions. Call
1778 handle_struct_member_die.
1779
c9317f21
TT
17802018-02-26 Tom Tromey <tom@tromey.com>
1781
1782 * rust-lang.h (rust_last_path_segment): Declare.
1783 * rust-lang.c (rust_last_path_segment): Now public. Change
1784 contract.
1785 (struct disr_info): Remove.
1786 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
1787 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
1788 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
1789 (rust_enum_p, rust_enum_variant): New function.
1790 (rust_underscore_fields): Remove "offset" parameter.
1791 (rust_print_enum): New function.
1792 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
1793 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
1794 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
1795 enums.
1796 (rust_internal_print_type): New function, from rust_print_type.
1797 Remove enum code.
1798 (rust_print_type): Call rust_internal_print_type.
1799 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
1800 Update enum handling.
1801 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
1802 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
1803 (rust_union_quirks): New functions.
1804 (process_full_comp_unit, process_full_type_unit): Call
1805 rust_union_quirks.
1806 (process_structure_scope): Update rust_unions if necessary.
1807
7c22600a
TT
18082018-02-26 Tom Tromey <tom@tromey.com>
1809
1810 * value.h (value_union_variant): Declare.
1811 * valops.c (value_union_variant): New function.
1812 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
1813 (struct discriminant_info): New.
1814 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
1815 enumerator.
1816 (struct main_type) <flag_discriminated_union>: New field.
1817
15ce8941
TT
18182018-02-26 Tom Tromey <tom@tromey.com>
1819
1820 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1821 unittests/unpack-selftests.c.
1822 * unittests/unpack-selftests.c: New file.
1823 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
1824
48fbe735
YQ
18252018-02-26 Yao Qi <yao.qi@linaro.org>
1826
1827 * dwarf2read.c (struct partial_die_info) <read>: New method.
1828 (read_partial_die): Remove the declaration.
1829 (load_partial_dies): Update.
1830 (partial_die_info::partial_die_info):
1831 (read_partial_die): Change it to partial_die_info::read.
1832
52356b79
YQ
18332018-02-26 Yao Qi <yao.qi@linaro.org>
1834
1835 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
1836 (fixup_partial_die): Remove declaration.
1837 (scan_partial_symbols): Update.
1838 (partial_die_parent_scope): Likewise.
1839 (partial_die_full_name): Likewise.
1840 (fixup_partial_die): Change it to partial_die_info::fixup.
1841
35cc7ed7
YQ
18422018-02-26 Yao Qi <yao.qi@linaro.org>
1843
1844 * dwarf2read.c (read_partial_die): Update the declaration.
1845 (load_partial_dies): Caller update.
1846 (read_partial_die): Remove one argument abbrev_len.
1847
6f06d47b
YQ
18482018-02-26 Yao Qi <yao.qi@linaro.org>
1849
1850 * dwarf2read.c (struct partial_die_info): Add ctor, delete
1851 assignment operator.
1852 (load_partial_dies): Use ctor and copy ctor.
1853 (read_partial_die): Update.
1854 (dwarf2_cu::find_partial_die): Use ctor.
1855
d590ff25
YQ
18562018-02-26 Yao Qi <yao.qi@linaro.org>
1857
1858 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
1859 (find_partial_die_in_comp_unit): Change it to
1860 dwarf2_cu::find_partial_die.
1861 (find_partial_die): Update.
1862
fd0a254f
YQ
18632018-02-26 Yao Qi <yao.qi@linaro.org>
1864
1865 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
1866 is NULL.
1867
cd9983dd
YQ
18682018-02-26 Yao Qi <yao.qi@linaro.org>
1869
1870 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
1871
f46cd62a
AH
18722018-02-26 Alan Hayward <alan.hayward@arm.com>
1873
1874 * arch/amd64.h: Use common/tdesc.h.
1875 * arch/i386.c: Likewise.
1876 * arch/i386.h: Likewise.
1877 * arch/tic6x.c: Likewise.
1878 * arch/tdesc.h: Move file from here...
1879 * common/tdesc.h: ...to here.
1880 * features/aarch64-core.c: Regenerate.
1881 * features/aarch64-fpu.c: Regenerate.
1882 * features/i386/32bit-avx.c: Regenerate.
1883 * features/i386/32bit-avx512.c: Regenerate.
1884 * features/i386/32bit-core.c: Regenerate.
1885 * features/i386/32bit-linux.c: Regenerate.
1886 * features/i386/32bit-mpx.c: Regenerate.
1887 * features/i386/32bit-pkeys.c: Regenerate.
1888 * features/i386/32bit-sse.c: Regenerate.
1889 * features/i386/64bit-avx.c: Regenerate.
1890 * features/i386/64bit-avx512.c: Regenerate.
1891 * features/i386/64bit-core.c: Regenerate.
1892 * features/i386/64bit-linux.c: Regenerate.
1893 * features/i386/64bit-mpx.c: Regenerate.
1894 * features/i386/64bit-pkeys.c: Regenerate.
1895 * features/i386/64bit-segments.c: Regenerate.
1896 * features/i386/64bit-sse.c: Regenerate.
1897 * features/i386/x32-core.c: Regenerate.
1898 * features/tic6x-c6xp.c: Regenerate.
1899 * features/tic6x-core.c: Regenerate.
1900 * features/tic6x-gp.c: Regenerate.
1901 * target-descriptions.c: Use common/tdesc.h.
1902 * target-descriptions.h: Likewise.
1903
9b292f68
TT
19042018-02-24 Tom Tromey <tom@tromey.com>
1905
1906 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
1907 (try_thread_db_load_from_dir, thread_db_load_search): Use
1908 std::string.
1909 (info_auto_load_libthread_db_compare): Return bool. Change
1910 argument types.
1911 (info_auto_load_libthread_db): Use std::vector, std::string.
1912 Remove cleanups.
1913
281d762b
TT
19142018-02-24 Tom Tromey <tom@tromey.com>
1915
1916 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
1917 std::string.
1918 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
1919 std::string*.
1920 * gdbarch.c: Rebuild.
1921 * gdbarch.h: Rebuild.
1922 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
1923 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
1924 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
1925 std::string*.
1926
9d8780f0
SM
19272018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
1928
1929 * gdbtypes.h (sect_offset): Change type to uint64_t.
1930 (sect_offset_str): New function.
1931 * dwarf2read.c (create_addrmap_from_aranges): Use
1932 sect_offset_str.
1933 (error_check_comp_unit_head): Likewise.
1934 (create_debug_type_hash_table): Likewise.
1935 (read_cutu_die_from_dwo): Likewise.
1936 (init_cutu_and_read_dies): Likewise.
1937 (init_cutu_and_read_dies_no_follow): Likewise.
1938 (process_psymtab_comp_unit_reader): Likewise.
1939 (partial_die_parent_scope): Likewise.
1940 (peek_die_abbrev): Likewise.
1941 (process_queue): Likewise.
1942 (dwarf2_physname): Likewise.
1943 (read_namespace_alias): Likewise.
1944 (read_import_statement): Likewise.
1945 (create_dwo_cu_reader): Likewise.
1946 (create_cus_hash_table): Likewise.
1947 (lookup_dwo_cutu): Likewise.
1948 (inherit_abstract_dies): Likewise.
1949 (read_func_scope): Likewise.
1950 (read_call_site_scope): Likewise.
1951 (dwarf2_add_member_fn): Likewise.
1952 (read_common_block): Likewise.
1953 (read_module_type): Likewise.
1954 (read_typedef): Likewise.
1955 (read_subrange_type): Likewise.
1956 (load_partial_dies): Likewise.
1957 (read_partial_die): Likewise.
1958 (find_partial_die): Likewise.
1959 (read_str_index): Likewise.
1960 (dwarf2_string_attr): Likewise.
1961 (build_error_marker_type): Likewise.
1962 (lookup_die_type): Likewise.
1963 (dump_die_shallow): Likewise.
1964 (follow_die_ref): Likewise.
1965 (dwarf2_fetch_die_loc_sect_off): Likewise.
1966 (dwarf2_fetch_constant_bytes): Likewise.
1967 (follow_die_sig): Likewise.
1968 (get_signatured_type): Likewise.
1969 (get_DW_AT_signature_type): Likewise.
1970 (dwarf2_find_containing_comp_unit): Likewise.
1971 (set_die_type): Likewise.
1972
8ec57239
JB
19732018-02-21 John Baldwin <jhb@FreeBSD.org>
1974
1975 * arch/aarch64.c: Include "common-defs.h".
1976 * arch/amd64.c: Likewise.
1977 * arch/i386.c: Likewise.
1978
3eac2b65
TT
19792018-02-21 Tom Tromey <tom@tromey.com>
1980
1981 * value.h: (extract_field_op): Update.
1982 * eval.c (extract_field_op): Return a const char *.
1983 * expression.h (parse_expression_for_completion): Update.
1984 * completer.c (complete_expression): Update.
1985 (add_struct_fields): Make fieldname const.
1986 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
1987 (mark_completion_tag, parse_exp_in_context_1): Update.
1988 (parse_expression_for_completion): Change "name" to
1989 unique_xmalloc_ptr*.
1990
6ccb583f
TT
19912018-02-21 Tom Tromey <tom@tromey.com>
1992
1993 * infcall.c (call_function_by_hand_dummy): Use std::vector.
1994
c113ed0c
YQ
19952018-02-21 Yao Qi <yao.qi@linaro.org>
1996
1997 * avr-tdep.c (avr_read_pc): Change parameter type to
1998 readable_regcache.
1999 * gdbarch.sh (read_pc): Likewise.
2000 * gdbarch.c: Re-generated.
2001 * gdbarch.h: Re-generated.
2002 * hppa-tdep.c (hppa_read_pc): Change parameter type to
2003 readable_regcache.
2004 * ia64-tdep.c (ia64_read_pc): Likewise.
2005 * mips-tdep.c (mips_read_pc): Likewise.
2006 * spu-tdep.c (spu_read_pc): Likewise.
2007
4c74fe6b
YQ
20082018-02-21 Yao Qi <yao.qi@linaro.org>
2009
2010 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
2011 * regcache-dump.c: New file.
2012 * regcache.c: Move register_dump to regcache-dump.c.
2013 (maintenance_print_registers): Likewise.
2014 (maintenance_print_raw_registers): Likewise.
2015 (maintenance_print_cooked_registers): Likewise.
2016 (maintenance_print_register_groups): Likewise.
2017 (maintenance_print_remote_registers): Likewise.
2018 (_initialize_regcache): Likewise.
2019 * regcache.h (register_dump): Moved from regcache.c.
2020
796bb026
YQ
20212018-02-21 Yao Qi <yao.qi@linaro.org>
2022
2023 * regcache.c (regcache::regcache): Update.
2024 (regcache::invalidate): Move it to detached_regcache::invalidate.
2025 (get_thread_arch_aspace_regcache): Update.
2026 (regcache::raw_update): Update.
2027 (regcache::cooked_read): Remove some code.
2028 (regcache::cooked_read_value): Likewise.
2029 (regcache::raw_write): Remove assert on m_readonly_p.
2030 (regcache::raw_supply_integer): Move it to
2031 detached_regcache::raw_supply_integer.
2032 (regcache::raw_supply_zeroed): Likewise.
2033 * regcache.h (detached_regcache) <raw_supply_integer>: New
2034 declaration.
2035 <raw_supply_zeroed, invalidate>: Likewise.
2036 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
2037 <invalidate>: Likewise.
2038 <m_readonly_p>: Removed.
2039
215c69dc
YQ
20402018-02-21 Yao Qi <yao.qi@linaro.org>
2041
2042 * infcmd.c (get_return_value): Let stop_regs point to
2043 get_current_regcache.
2044 * regcache.c (regcache::regcache): Remove.
2045 (register_dump_reg_buffer): New class.
2046 (regcache_print): Adjust.
2047 * regcache.h (regcache): Remove constructors.
2048
f3384e66
YQ
20492018-02-21 Yao Qi <yao.qi@linaro.org>
2050
2051 * regcache.c (class register_dump): New class.
2052 (register_dump_regcache, register_dump_none): New class.
2053 (register_dump_remote, register_dump_groups): New class.
2054 (regcache_print): Update.
2055 * regcache.h (regcache_dump_what): Move it to regcache.c.
2056 (regcache) <dump>: Remove.
2057
c8ec2f33
YQ
20582018-02-21 Yao Qi <yao.qi@linaro.org>
2059
2060 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
2061 reg_buffer_rw *.
2062 (jit_unwind_reg_set_impl): Call raw_supply.
2063 (jit_frame_sniffer): Use reg_buffer_rw.
2064 * record-full.c (record_full_core_regbuf): Change its type.
2065 (record_full_core_open_1): Use reg_buffer_rw.
2066 (record_full_close): Likewise.
2067 (record_full_core_fetch_registers): Use regcache->raw_supply.
2068 (record_full_core_store_registers): Likewise.
2069 * regcache.c (regcache::get_register_status): Move it to
2070 reg_buffer.
2071 (regcache_raw_set_cached_value): Remove.
2072 (regcache::raw_set_cached_value): Remove.
2073 (regcache::raw_write): Call raw_supply.
2074 (regcache::raw_supply): Move it to reg_buffer_rw.
2075 * regcache.h (regcache_raw_set_cached_value): Remove.
2076 (reg_buffer_rw): New class.
2077
daf6667d
YQ
20782018-02-21 Yao Qi <yao.qi@linaro.org>
2079
2080 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
2081 readonly_detached_regcache.
2082 (dummy_frame_prev_register): Use regcache->cooked_read.
2083 * frame.c (frame_save_as_regcache): Change return type.
2084 (frame_pop): Update.
2085 * frame.h (frame_save_as_regcache): Update declaration.
2086 * inferior.h (get_infcall_suspend_state_regcache): Update
2087 declaration.
2088 * infrun.c (infcall_suspend_state) <registers>: use
2089 readonly_detached_regcache.
2090 (save_infcall_suspend_state): Don't use regcache_dup.
2091 (get_infcall_suspend_state_regcache): Change return type.
2092 * linux-fork.c (struct fork_info) <savedregs>: Change to
2093 readonly_detached_regcache.
2094 <pc>: New field.
2095 (fork_save_infrun_state): Don't use regcache_dup.
2096 (info_checkpoints_command): Adjust.
2097 * mi/mi-main.c (register_changed_p): Update declaration.
2098 (mi_cmd_data_list_changed_registers): Use
2099 readonly_detached_regcache.
2100 (register_changed_p): Change parameter type to
2101 readonly_detached_regcache.
2102 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
2103 readonly_detached_regcache.
2104 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
2105 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
2106 New.
2107 (regcache::save): Move it to reg_buffer.
2108 (regcache::restore): Change parameter type.
2109 (regcache_dup): Remove.
2110 * regcache.h (reg_buffer) <save>: New method.
2111 (readonly_detached_regcache): New class.
2112 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
2113 readonly_detached_regcache.
2114 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
2115
fc5b8736
YQ
21162018-02-21 Yao Qi <yao.qi@linaro.org>
2117
2118 * frame.c (frame_save_as_regcache): Use regcache method save.
2119 (frame_pop): Use regcache method restore.
2120 * infrun.c (restore_infcall_suspend_state): Likewise.
2121 * linux-fork.c (fork_load_infrun_state): Likewise.
2122 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
2123 save.
2124 * regcache.c (regcache_save): Remove.
2125 (regcache::restore): More asserts.
2126 (regcache_cpy): Remove.
2127 * regcache.h (regcache_save): Remove the declaration.
2128 (regcache::restore): Move from private to public.
2129 Remove the friend declaration of regcache_cpy.
2130 (regcache_cpy): Remove declaration.
2131
849d0ba8
YQ
21322018-02-21 Yao Qi <yao.qi@linaro.org>
2133
2134 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
2135 parameter type to 'readable_regcache *'.
2136 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
2137 * arm-tdep.c (arm_neon_quad_read): Likewise.
2138 (arm_pseudo_read): Likewise.
2139 * avr-tdep.c (avr_pseudo_register_read): Likewise.
2140 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
2141 * frv-tdep.c (frv_pseudo_register_read): Likewise.
2142 * gdbarch.c: Re-generated.
2143 * gdbarch.h: Re-generated.
2144 * gdbarch.sh (pseudo_register_read): Change parameter type to
2145 'readable_regcache *'.
2146 (pseudo_register_read_value): Likewise.
2147 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
2148 (h8300_pseudo_register_read): Likewise.
2149 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
2150 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
2151 (i386_pseudo_register_read_into_value): Likewise.
2152 (i386_pseudo_register_read_value): Likewise.
2153 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
2154 declaration.
2155 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
2156 * m32c-tdep.c (m32c_raw_read): Likewise.
2157 (m32c_read_flg): Likewise.
2158 (m32c_banked_register): Likewise.
2159 (m32c_banked_read): Likewise.
2160 (m32c_sb_read): Likewise.
2161 (m32c_part_read): Likewise.
2162 (m32c_cat_read): Likewise.
2163 (m32c_r3r2r1r0_read): Likewise.
2164 (m32c_pseudo_register_read): Likewise.
2165 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
2166 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
2167 (mep_pseudo_cr64_read): Likewise.
2168 (mep_pseudo_register_read): Likewise.
2169 * mips-tdep.c (mips_pseudo_register_read): Likewise.
2170 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
2171 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
2172 * regcache.c (regcache::raw_read): Move it to readable_regcache.
2173 (regcache::cooked_read): Likewise.
2174 (regcache::cooked_read_value): Likewise.
2175 (regcache_cooked_read_signed):
2176 (regcache::cooked_read): Likewise.
2177 * regcache.h (readable_regcache): New class.
2178 (regcache): Inherit readable_regcache. Move some methods to
2179 readable_regcache.
2180 * rl78-tdep.c (rl78_pseudo_register_read): Change
2181 parameter type to 'readable_regcache *'.
2182 * rs6000-tdep.c (do_regcache_raw_read): Remove.
2183 (e500_pseudo_register_read): Change parameter type to
2184 'readable_regcache *'.
2185 (dfp_pseudo_register_read): Likewise.
2186 (vsx_pseudo_register_read): Likewise.
2187 (efpr_pseudo_register_read): Likewise.
2188 * s390-tdep.c (s390_pseudo_register_read): Likewise.
2189 * sh-tdep.c (sh_pseudo_register_read): Likewise.
2190 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
2191 (sh64_pseudo_register_read): Likewise.
2192 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
2193 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
2194 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
2195 (spu_pseudo_register_read): Likewise.
2196 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
2197 (xtensa_pseudo_register_read): Likewise.
2198
31716595
YQ
21992018-02-21 Yao Qi <yao.qi@linaro.org>
2200
2201 * regcache.c (regcache::regcache): Call reg_buffer ctor.
2202 (regcache::arch): Move it to reg_buffer::arch.
2203 (regcache::register_buffer): Likewise.
2204 (regcache::assert_regnum): Likewise.
2205 (regcache::num_raw_registers): Likewise.
2206 * regcache.h (reg_buffer): New class.
2207 (regcache): Inherit reg_buffer.
2208
7104e59b
SM
22092018-02-20 Simon Marchi <simon.marchi@ericsson.com>
2210
2211 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
2212 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
2213
2d8adcbd
MM
22142018-02-20 Markus Metzger <markus.t.metzger@intel.com>
2215
2216 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
2217
b5884fa7
AH
22182018-02-19 Alan Hayward <alan.hayward@arm.com>
2219
2220 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
2221 (SFILES): Remove common/*.c files.
2222 (COMMON_OBS): Remove some *.o files built from common/*.c files.
2223 * common/common.host: Add common reference.
2224 * configure.ac: Likewise.
2225 * configure: Regenerate.
2226
fd90ace4
YQ
22272018-02-16 Yao Qi <yao.qi@linaro.org>
2228
2229 * block.c (block_namespace_info): Inherit allocate_on_obstack.
2230 (block_initialize_namespace): Use new.
2231 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
2232 (dwarf2_free_objfile): Use delete.
2233 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
2234 (copy_type_recursive): Use new.
2235 * gdb_obstack.h (allocate_on_obstack): New.
2236
85046ae2
YQ
22372018-02-15 Yao Qi <yao.qi@linaro.org>
2238
2239 PR gdb/22849
2240 * inferior.c (exit_inferior_1): Reset inf->control.
2241
355c559b
JB
22422018-02-15 Joel Brobecker <brobecker@adacore.com>
2243
2244 * ada-lang.c (ada_to_fixed_value_create): Delete advance
2245 declaration.
2246
980548fd
PA
22472018-02-14 Pedro Alves <palves@redhat.com>
2248
2249 * frame-unwind.c (frame_unwind_try_unwinder): Always call
2250 frame_cleanup_after_sniffer on exception.
2251
692d6f97
TT
22522018-02-14 Tom Tromey <tom@tromey.com>
2253
2254 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
2255 const.
2256 (solib_bfd_open): Make pathname const.
2257 * solib.c (solib_bfd_open): Make pathname const.
2258 * solib-spu.c (spu_bfd_fopen): Make name const.
2259 (spu_bfd_open): Make pathname const.
2260 * solib-darwin.c (darwin_bfd_open): Make pathname const.
2261 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
2262
e0cc99a6
TT
22632018-02-14 Tom Tromey <tom@tromey.com>
2264
2265 * symfile.c (symfile_bfd_open): Update.
2266 * source.h (openp, source_full_path_of, find_and_open_source):
2267 Change argument type to unique_xmalloc_ptr.
2268 * source.c (openp): Take a unique_xmalloc_ptr.
2269 (source_full_path_of, find_and_open_source): Likewise.
2270 (open_source_file, symtab_to_fullname): Update.
2271 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
2272 unique_xmalloc_ptr.
2273 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
2274 (exec_file_find): Update.
2275 * psymtab.c (psymtab_to_fullname): Update.
2276 * nto-tdep.h (nto_find_and_open_solib): Update.
2277 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
2278 unique_xmalloc_ptr.
2279 * exec.c (exec_file_attach): Update.
2280 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
2281 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
2282
b46a8d7c
TT
22832018-02-14 Tom Tromey <tom@tromey.com>
2284
2285 * solib.c: Include source.h.
2286 * nto-tdep.c: Include source.h.
2287 * mi/mi-cmd-env.c: Include source.h.
2288 * infcmd.c: Include source.h.
2289 * exec.c: Include source.h.
2290 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
2291 (add_path, directory_switch, source_path, init_source_path): Move
2292 declarations...
2293 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
2294 (add_path, directory_switch, source_path, init_source_path):
2295 ...here.
2296
797bc1cb
TT
22972018-02-14 Tom Tromey <tom@tromey.com>
2298
2299 * solist.h (exec_file_find, solib_find): Return
2300 unique_xmalloc_ptr.
2301 (solib_bfd_fopen): Take a const char *.
2302 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
2303 (exec_file_find, solib_find): Likewise.
2304 (solib_bfd_fopen): Do not take ownership of "pathname".
2305 (solib_bfd_open): Use unique_xmalloc_ptr.
2306 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
2307 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
2308 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
2309 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
2310
f98b2e33
JB
23112018-02-14 Joel Brobecker <brobecker@adacore.com>
2312
2313 * ada-lang.c (name_match_type_from_name): Remove reference to
2314 ada_name_for_lookup in function's documentation.
2315 * ada-lang.h (ada_name_for_lookup): Delete declaration.
2316
24b9144d
SM
23172018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
2318
2319 * defs.h (enum openp_flags): New enum.
2320 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
2321 Move to enum openp_flags.
2322 (openp_flags): New enum flags.
2323 (openp): Change parameter type to openp_flags.
2324 * source.c (openp): Change parameter type to openp_flags.
2325 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
2326 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
2327
387cd15b
SM
23282018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
2329
2330 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
2331 per-command.
2332
b303c6f6
AB
23332018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
2334
2335 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
2336 into...
2337 (class dwarf2_queue_guard): ...the destructor of this new class.
2338 (dw2_do_instantiate_symtab): Create instance of the new class
2339 dwarf2_queue_guard, remove cleanup.
2340
9c3630e9
TT
23412018-02-09 Tom Tromey <tom@tromey.com>
2342
2343 * source.c (find_source_lines): Don't reference past the end of
2344 the vector.
2345
c4e12631
MM
23462018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2347
2348 * remote.c (remote_btrace_maybe_reopen): Change error message.
2349 * btrace.c (btrace_enable): Likewise.
2350 (parse_xml_btrace): Likewise.
2351 (parse_xml_btrace_conf): Likewise.
2352
88711fbf
MM
23532018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2354
2355 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
2356 (linux_enable_pt, linux_enable_bts): Call
2357 diagnose_perf_event_open_fail.
2358
17ad2a4f
MM
23592018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2360
2361 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
2362 Remove parameter and change return type. Update callers. Move it.
2363 (linux_enable_bts, linux_enable_pt): Improve error message.
2364 (linux_enable_pt): Remove zero buffer size check.
2365 (linux_enable_btrace): Improve error messages. Remove NULL return
2366 check.
2367
de6242d3
MM
23682018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2369
2370 * btrace.c (btrace_enable): Remove target_supports_btrace call.
2371 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
2372 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
2373 (linux_supports_pt, linux_supports_btrace): Remove.
2374 (linux_enable_bts): Call cpu_supports_bts.
2375 * nat/linux-btrace.h (linux_supports_btrace): Remove.
2376 * remote.c (remote_supports_btrace): Remove.
2377 (init_remote_ops): Remove remote_supports_btrace.
2378 * target-delegates.c: Regenerated.
2379 * target.c (target_supports_btrace): Remove.
2380 * target.h (target_ops) <to_supports_btrace>: Remove
2381 (target_supports_btrace): Remove.
2382 * x86-linux-nat.c (x86_linux_create_target): Remove
2383 linux_supports_btrace.
2384
9ee23a85
MM
23852018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2386
2387 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
2388 btrace failed.
2389 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
2390 exception and use message in own exception.
2391
5c3284c1
MM
23922018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2393
2394 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
2395 (perf_event_pt_event_type): Use gdb_file_up.
2396 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
2397 scoped_fd, and scoped_mmap.
2398
84696f37
MM
23992018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2400
2401 * common/scoped_mmap.h: New.
2402 * unittests/scoped_mmap-selftest.c: New.
2403 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2404 unittests/scoped_mmap-selftest.c.
2405
ea4a0888
MM
24062018-02-09 Markus Metzger <markus.t.metzger@intel.com>
2407
2408 * common/scoped_fd.h: New.
2409 * unittests/scoped_fd-selftest.c: New.
2410 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2411 unittests/scoped_fd-selftest.c.
2412
869e8290
TT
24132018-02-09 Tom Tromey <tom@tromey.com>
2414
2415 * auto-load.c (auto_load_section_scripts): Use
2416 gdb::unique_xmalloc_ptr.
2417
a37a2ae7
TT
24182018-02-09 Tom Tromey <tom@tromey.com>
2419
2420 * auto-load.c (execute_script_contents): Use std::string.
2421
4e725347
JB
24222018-02-09 Joel Brobecker <brobecker@adacore.com>
2423
2424 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
2425 Python function, rather than a new command.
2426
9a897d43
TT
24272018-02-08 Tom Tromey <tom@tromey.com>
2428
2429 * solib.c (solib_find_1): Use std::string.
2430 (solib_bfd_fopen): Use unique_xmalloc_ptr.
2431
58ef3771
TT
24322018-02-08 Tom Tromey <tom@tromey.com>
2433
2434 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
2435
a9abc434
TT
24362018-02-08 Tom Tromey <tom@tromey.com>
2437
2438 * source.c (find_source_lines): Use gdb::def_vector.
2439
84f27c6f
TT
24402018-02-08 Tom Tromey <tom@tromey.com>
2441
2442 * macrocmd.c (struct temporary_macro_definition): New.
2443 (macro_define_command): Use temporary_macro_definition. Remove
2444 cleanups.
2445 (free_macro_definition_ptr): Remove.
2446
0354904b
TT
24472018-02-08 Tom Tromey <tom@tromey.com>
2448
2449 * macroexp.c (maybe_expand): Use std::string.
2450
1739cf24
TT
24512018-02-08 Tom Tromey <tom@tromey.com>
2452
2453 * macroexp.c (struct macro_buffer): Add initializers for some
2454 members.
2455 (init_buffer, init_shared_buffer, free_buffer)
2456 (free_buffer_return_text): Remove.
2457 (macro_buffer): New constructors.
2458 (~macro_buffer): New destructor.
2459 (macro_buffer::set_shared): New method.
2460 (macro_buffer::resize_buffer, macro_buffer::appendc)
2461 (macro_buffer::appendmem): Now methods, not free functions.
2462 (set_token, append_tokens_without_splicing, stringify)
2463 (macro_stringify): Update.
2464 (gather_arguments): Change return type. Remove argc_p argument,
2465 add args_ptr argument. Use std::vector.
2466 (substitute_args): Remove argc argument. Accept std::vector.
2467 (expand): Update. Use std::vector.
2468 (scan, macro_expand, macro_expand_next): Update.
2469
f6c2623e
TT
24702018-02-08 Tom Tromey <tom@tromey.com>
2471
2472 * symtab.c (default_collect_symbol_completion_matches_break_on):
2473 Use unique_xmalloc_ptr.
2474 * macroscope.h: (sal_macro_scope, user_macro_scope)
2475 (default_macro_scope): Return unique_xmalloc_ptr.
2476 * macroscope.c (sal_macro_scope, user_macro_scope)
2477 (default_macro_scope): Return unique_xmalloc_ptr.
2478 * macroexp.h (macro_expand, macro_expand_once): Return
2479 unique_xmalloc_ptr.
2480 * macroexp.c (macro_expand, macro_expand_once): Return
2481 unique_xmalloc_ptr.
2482 * macrocmd.c (macro_expand_command, macro_expand_once_command)
2483 (info_macro_command, info_macros_command): Use
2484 unique_xmalloc_ptr.
2485 * compile/compile-c-support.c (write_macro_definitions): Use
2486 unique_xmalloc_ptr.
2487 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
2488
c2e0e465
SM
24892018-02-07 Simon Marchi <simon.marchi@ericsson.com>
2490
2491 * value.c (value_static_field): Assign field type instead of
2492 containing type when returning an optimized out value.
2493
3f8c94b4
YQ
24942018-02-06 Yao Qi <yao.qi@linaro.org>
2495
2496 * ft32-tdep.c (ft32_read_pc): Remove.
2497 (ft32_write_pc): Remove.
2498 (ft32_gdbarch_init): Update.
2499 * m32r-tdep.c (m32r_read_pc): Remove.
2500 (m32r_gdbarch_init): Update.
2501 * mep-tdep.c (mep_read_pc): Remove.
2502 (mep_gdbarch_init): Update.
2503 * microblaze-tdep.c (microblaze_write_pc): Remove.
2504 (microblaze_gdbarch_init): Update.
2505 * mn10300-tdep.c (mn10300_read_pc): Remove.
2506 (mn10300_write_pc): Remove.
2507 (mn10300_gdbarch_init): Update.
2508 * moxie-tdep.c (moxie_read_pc): Remove.
2509 (moxie_write_pc): Remove.
2510 (moxie_gdbarch_init): Update.
2511
bca65a23
YQ
25122018-02-06 Yao Qi <yao.qi@linaro.org>
2513
2514 * expprint.c (print_subexp_standard): Handle
2515 OP_F77_UNDETERMINED_ARGLIST.
2516 (dump_subexp_body_standard): Likewise.
2517
583e3f90 25182018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 2519
583e3f90
YQ
2520 * target-descriptions.c (tdesc_element_visitor) Add empty
2521 implementations.
b8df6ca7
AH
2522 (tdesc_type): Move make_gdb_type from here.
2523 (tdesc_type_builtin): Likewise.
2524 (tdesc_type_vector): Likewise.
2525 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
2526 (make_gdb_type_struct): Move from tdesc_type_with_fields.
2527 (make_gdb_type_union): Likewise.
2528 (make_gdb_type_flags): Likewise.
2529 (make_gdb_type_enum): Likewise.
2530 (make_gdb_type): New function.
2531 (tdesc_register_type): Use static make_gdb_type.
2532
e813d34a
RK
25332018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
2534
2535 * infcmd.c (default_print_one_register_info): Align natural-format
2536 column values consistently one under another.
2537 (pad_to_column): New function.
2538
0eb876f5
JB
25392018-02-05 Joel Brobecker <brobecker@adacore.com>
2540
2541 * dwarf2read.c (dwarf2_physname): Move commment.
2542
0625771b
LS
25432018-02-01 Leszek Swirski <leszeks@google.com>
2544
2545 * varobj.c (varobj_formatted_print_options): Allow recursive
2546 pretty printing if pretty printing is enabled.
2547
59498c30
LS
25482018-02-01 Leszek Swirski <leszeks@google.com>
2549
2550 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
2551 names after a structop as a filename.
2552
2d9e6acb
YQ
25532018-02-01 Yao Qi <yao.qi@linaro.org>
2554
2555 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
2556 (arm_record_coproc_data_proc): Likewise.
2557
df95a9cf
YQ
25582018-02-01 Yao Qi <yao.qi@linaro.org>
2559
2560 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
2561
07e5f5cf
NP
25622018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
2563
2564 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
2565 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
2566
3045b475
PA
25672018-01-31 Pedro Alves <palves@redhat.com>
2568
2569 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
2570 * inflow.c (child_terminal_save_inferior): Wrap reference to
2571 tcgetpgrp in HAVE_TERMIOS_H.
2572 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
2573 _WIN32.
2574 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
2575 always iterate over all inferiors.
2576 (gdbsim_cntrl_c): Adjust.
2577 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
2578
929b5ad4
JB
25792018-01-31 Joel Brobecker <brobecker@adacore.com>
2580
2581 * gdbtypes.c (lookup_array_range_type): Make sure the array's
2582 index type is objfile-owned if the element type is as well.
2583
29236ca2
JB
25842018-01-31 Joel Brobecker <brobecker@adacore.com>
2585
2586 GDB 8.1 released.
2587
c81e8879
PR
25882018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
2589
2590 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
2591 "features/s390x-linux64.c".
2592 (_initialize_s390_linux_tdep): Remove initialization of tdescs
2593 s390_linux32 and s390x_linux64.
2594 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
2595 default tdesc.
2596 * s390-tdep.c: Include "features/s390-linux32.c" and
2597 "features/s390x-linux64.c".
2598 (s390_tdesc_valid): Add check for tdesc_has_registers.
2599 (s390_gdbarch_init): Make sure there is always a valid tdesc.
2600 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
2601 tdesc_s390x_linux64.
2602 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
2603 tdesc_s390x_linux64 to...
2604 * s390-tdep.h: ...here.
2605
e671cd59
PA
26062018-01-30 Pedro Alves <palves@redhat.com>
2607
2608 PR gdb/13211
2609 * config.in, configure: Regenerate.
2610 * configure.ac: Check for getpgid.
2611 * go32-nat.c (go32_pass_ctrlc): New.
2612 (go32_target): Install it.
2613 * inf-child.c (inf_child_target): Install
2614 child_terminal_save_inferior, child_pass_ctrlc and
2615 child_interrupt.
2616 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
2617 (inf_ptrace_target): No longer install it.
2618 * infcmd.c (interrupt_target_1): Adjust.
2619 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
2620 (child_interrupt): Declare.
2621 (inferior::terminal_state): New.
2622 * inflow.c (struct terminal_info): Update comments.
2623 (inferior_process_group): Delete.
2624 (terminal_is_ours): Delete.
2625 (gdb_tty_state): New.
2626 (child_terminal_init): Adjust.
2627 (is_gdb_terminal, sharing_input_terminal_1)
2628 (sharing_input_terminal): New functions.
2629 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
2630 Set the process's actual process group in the foreground if
2631 possible. Handle is_ours_for_output/is_ours distinction. Don't
2632 mark terminal as the inferior's if not sharing GDB's terminal.
2633 Don't check attach_flag.
2634 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
2635 pass down a target_terminal_state.
2636 (child_terminal_save_inferior): New, factored out from ...
2637 (child_terminal_ours_1): ... this. Handle
2638 target_terminal_state::is_ours_for_output.
2639 (child_interrupt, child_pass_ctrlc): New.
2640 (inflow_inferior_exit): Clear the inferior's terminal_state.
2641 (copy_terminal_info): Copy the inferior's terminal state.
2642 (_initialize_inflow): Remove reference to terminal_is_ours.
2643 * inflow.h (inferior_process_group): Delete.
2644 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
2645 * procfs.c (procfs_target): Don't install procfs_interrupt.
2646 (procfs_interrupt): Delete.
2647 * remote.c (remote_serial_quit_handler): Adjust.
2648 (remote_interrupt): Remove ptid parameter. Adjust.
2649 * target-delegates.c: Regenerate.
2650 * target.c: Include "terminal.h".
2651 (target_terminal::terminal_state): Rename to ...
2652 (target_terminal::m_terminal_state): ... this.
2653 (target_terminal::init): Adjust.
2654 (target_terminal::inferior): Adjust to per-inferior
2655 terminal_state.
2656 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
2657 (target_terminal::ours, target_terminal::ours_for_output): Use
2658 target_terminal_is_ours_kind.
2659 (target_interrupt): Remove ptid parameter. Adjust.
2660 (default_target_pass_ctrlc): Adjust.
2661 * target.h (target_ops::to_terminal_save_inferior): New field.
2662 (target_ops::to_interrupt): Remove ptid_t parameter.
2663 (target_interrupt): Remove ptid_t parameter. Update comment.
2664 (target_pass_ctrlc): Update comment.
2665 * target/target.h (target_terminal_state): New scoped enum,
2666 factored out of ...
2667 (target_terminal::terminal_state): ... here.
2668 (target_terminal::inferior): Update comments.
2669 (target_terminal::restore_inferior): New.
2670 (target_terminal::is_inferior, target_terminal::is_ours)
2671 (target_terminal::is_ours_for_output): Adjust.
2672 (target_terminal::scoped_restore_terminal_state): Adjust to
2673 rename, and call restore_inferior() instead of inferior().
2674 (target_terminal::scoped_restore_terminal_state::m_state): Change
2675 type.
2676 (target_terminal::terminal_state): Rename to ...
2677 (target_terminal::m_terminal_state): ... this and change type.
2678
9c3a5d93
PA
26792018-01-30 Pedro Alves <palves@redhat.com>
2680
2681 * linux-nat.c (wait_for_signal): New function.
2682 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
2683 directly.
2684 (async_terminal_is_ours)
2685 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
2686 (linux_nat_add_target): Don't override
2687 to_terminal_inferior/to_terminal_ours.
2688
69ab5edb
SDJ
26892018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
2690
2691 * remote.c (remote_follow_fork): Don't call "detach_inferior".
2692
fc8e7e75
SM
26932018-01-28 Simon Marchi <simon.marchi@ericsson.com>
2694
2695 * dwarf2read.c (free_dwo_files): Add forward-declaration.
2696 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
2697 dwarf2_per_objfile_free here.
2698 (dwarf2_per_objfile_free): Remove.
2699 (_initialize_dwarf2_read): Don't register
2700 dwarf2_per_objfile_free as a registry cleanup.
2701
b2a426e2
EZ
27022018-01-27 Eli Zaretskii <eliz@gnu.org>
2703
2704 Avoid compilation errors in MinGW native builds
2705
2706 The error is triggered by including python-internal.h, and the
2707 error message is:
2708
2709 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
2710 from build-gnulib/import/math.h:27,
2711 from d:/usr/Python26/include/pyport.h:235,
2712 from d:/usr/Python26/include/Python.h:58,
2713 from python/python-internal.h:94,
2714 from python/py-arch.c:24:
2715 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
2716 using ::hypot;
2717 ^~~~~
2718
2719 This happens because Python headers define 'hypot' to expand t
2720 '_hypot' in the Windows builds.
2721 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
2722 'hypoth'. This avoids a compilation error.
2723
0bdd8eac
AH
27242018-01-26 Alan Hayward <alan.hayward@arm.com>
2725
2726 * MAINTAINERS (Write After Approval): Fix ordering.
2727
56ae9dc3
AH
27282018-01-26 Alan Hayward <alan.hayward@arm.com>
2729
2730 * MAINTAINERS (Write After Approval): Add Alan Hayward.
2731
7433498b
AM
27322018-01-26 Alan Modra <amodra@gmail.com>
2733
2734 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
2735 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
2736 Remove nop. Make const. Comment.
2737 (powerpc32_plt_stub_so_2): New.
2738 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
2739 Correct count. Update uses.
2740 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
2741 Move common code reading PLT entry word. Correct
2742 powerpc32_plt_stub PLT address calculation.
2743 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
2744 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
2745 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
2746 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
2747 (ppc64_standard_linkage8): Likewise.
2748 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
2749 Correct insns description.
2750 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
2751
0f59d5fc
PA
27522018-01-24 Pedro Alves <palves@redhat.com>
2753
2754 GCC PR libstdc++/83906
2755 * gdbtypes.c (operator==(const dynamic_prop &,
2756 const dynamic_prop &)): New.
2757 (operator==(const range_bounds &, const range_bounds &)): New.
2758 (check_types_equal): Use them instead of memcmp.
2759 * gdbtypes.h (operator==(const dynamic_prop &,
2760 const dynamic_prop &)): Declare.
2761 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
2762 (operator==(const range_bounds &, const range_bounds &)): Declare.
2763 (operator!=(const range_bounds &, const range_bounds &)): Declare.
2764
ef8914a4
PR
27652018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
2766
2767 * s390-linux-tdep.c (s390_record_address_mask)
2768 (s390_record_calc_disp_common, s390_record_calc_disp)
2769 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
2770 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
2771 (s390_process_record): Move to s390-tdep.c.
2772 (s390_linux_init_abi_any): Adjust.
2773 * s390-tdep.c (s390_record_address_mask)
2774 (s390_record_calc_disp_common, s390_record_calc_disp)
2775 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
2776 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
2777 (s390_process_record): Moved from s390-linux-tdep.c
2778 (s390_gdbarch_init): Adjust.
2779
d6e58945
PR
27802018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
2781
2782 * s390-linux-nat.c (s390-tdep.h): New include.
2783 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
2784 (HFILES_NO_SRCDIR): Add s390-tdep.h.
2785 (ALLDEPFILES): Add s390-tdep.c.
2786 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
2787 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
2788 * s390-tdep.h: ...this. New file.
2789 * s390-linux-tdep.c (s390-tdep.h): New include.
2790 (_initialize_s390_tdep): Rename to...
2791 (_initialize_s390_linux_tdep): ...this and adjust.
2792 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
2793 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
2794 s390-tdep.h.
2795 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
2796 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
2797 (s390_is_partial_instruction, s390_software_single_step)
2798 (is_non_branch_ril, s390_displaced_step_copy_insn)
2799 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
2800 (s390_prologue_data, s390_addr, s390_store, s390_load)
2801 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
2802 (s390_register_call_saved, s390_guess_tracepoint_registers)
2803 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
2804 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
2805 (s390_pseudo_register_name, s390_pseudo_register_type)
2806 (s390_pseudo_register_read, s390_pseudo_register_write)
2807 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
2808 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
2809 (s390_addr_bits_remove, s390_address_class_type_flags)
2810 (s390_address_class_type_flags_to_name)
2811 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
2812 (s390_function_arg_float, s390_function_arg_vector)
2813 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
2814 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
2815 (s390_frame_align, s390_register_return_value, s390_return_value)
2816 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
2817 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
2818 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
2819 (s390_trad_frame_prev_register, s390_unwind_cache)
2820 (s390_prologue_frame_unwind_cache)
2821 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
2822 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
2823 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
2824 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
2825 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
2826 (s390_frame_base_address, s390_local_base_address)
2827 (s390_frame_base, s390_gcc_target_options)
2828 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
2829 (s390_validate_reg_range, s390_tdesc_valid)
2830 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
2831 * s390-tdep.c: ...this. New file.
2832
9c0b896e
PR
28332018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
2834
2835 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
2836 (s390_process_record, s390_gdbarch_tdep_alloc)
2837 (s390_linux_init_abi_any): Use/set new hook.
2838
7042632b
PR
28392018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
2840
2841 * s390-linux-tdep.c (osabi.h): New include.
2842 (s390_linux_init_abi_31, s390_linux_init_abi_64)
2843 (s390_linux_init_abi_any): New functions.
2844 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
2845
650f5e13
PR
28462018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
2847
2848 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
2849 tdesc_has_registers check
2850
47c9317e
PR
28512018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
2852
2853 * s390-linux-tdep.c (s390_tdesc_valid): New function.
2854 (s390_validate_reg_range): New macro.
2855 (s390_gdbarch_init): Adjust.
2856
095085d8
PR
28572018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
2858
2859 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
2860 (s390_gdbarch_tdep_alloc): Adjust.
2861 (s390_gdbarch_init): Adjust.
2862
ab9bcc67
PR
28632018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
2864
2865 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
2866 <have_tdb>: Change type to bool.
2867 (s390_gdbarch_tdep_alloc): Adjust.
2868 (s390_gdbarch_init): Adjust.
2869
21f6f5ff
PR
28702018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
2871
2872 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
2873 (gdbarch_tdep) <have_upper, have_vx>: New fields.
2874 (s390_gdbarch_tdep_alloc): New function.
2875 (s390_gdbarch_init): Allocate tdep at start and use its fields
2876 instead of separate variables.
2877
0eb97953
PR
28782018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
2879
2880 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
2881 when looking for cached gdbarch and add comment for remaining.
2882
5c319bb2
PA
28832018-01-22 Pedro Alves <palves@redhat.com>
2884 Sergio Durigan Junior <sergiodj@redhat.com>
2885
2886 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
2887 case.
2888
d65ce302
MR
28892018-01-22 Maciej W. Rozycki <macro@mips.com>
2890
2891 * MAINTAINERS: Update my company e-mail address.
2892
ec7a5fcb
YQ
28932018-01-22 Yao Qi <yao.qi@linaro.org>
2894
2895 * regcache.c (cooked_write_test): New function.
2896 (_initialize_regcache): Register the test.
2897
11f57cb6
YQ
28982018-01-22 Yao Qi <yao.qi@linaro.org>
2899
2900 * ia64-tdep.c (ia64_pseudo_register_read): Call
2901 regcache->cooked_read instead of regcache_cooked_read_unsigned.
2902 * m32c-tdep.c (m32c_cat_read): Likewise.
2903 (m32c_r3r2r1r0_read): Likewise.
2904 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
2905 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
2906
03f50fc8
YQ
29072018-01-22 Yao Qi <yao.qi@linaro.org>
2908
2909 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
2910 method raw_read instead of regcache_raw_read.
2911 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
2912 * arm-tdep.c (arm_neon_quad_read): Likewise.
2913 * avr-tdep.c (avr_pseudo_register_read): Likewise.
2914 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
2915 * frv-tdep.c (frv_pseudo_register_read): Likewise.
2916 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
2917 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
2918 (i386_pseudo_register_read_into_value): Likewise.
2919 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
2920 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
2921 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
2922 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
2923 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
2924 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
2925 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
2926 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
2927 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
2928
dc711524
YQ
29292018-01-22 Yao Qi <yao.qi@linaro.org>
2930
2931 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
2932 * configure.tgt: Remove target mt.
2933 * mt-tdep.c: Remove.
2934 * regcache.c (cooked_read_test): Remove the check for mt.
2935
3f5a868b
YQ
29362018-01-22 Yao Qi <yao.qi@linaro.org>
2937
2938 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
2939 instead of gdbarch_pseudo_register_read_value.
2940
de4cb04a
JB
29412018-01-22 Joel Brobecker <brobecker@adacore.com>
2942
2943 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
2944 language is Ada.
2945
a9e40818
JB
29462018-01-22 Joel Brobecker <brobecker@adacore.com>
2947
2948 * linespec.c (create_sals_line_offset): Remove code that preserved
2949 the symtab_and_line's line number.
2950
e707fc44
AB
29512018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
2952
2953 * varobj.c (varobj_create): Don't set valid_block when creating a
2954 floating varobj.
2955
03d0bf7b
AB
29562018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
2957
2958 * varobj.c (varobj_create): Remove out of date comment.
2959
ae451627
AB
29602018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
2961
2962 PR mi/20395
2963 * ada-exp.y (write_var_from_sym): Pass extra parameter when
2964 updating innermost block.
2965 * parse.c (innermost_block_tracker::update): Take extra type
2966 parameter, and check types match before updating innermost block.
2967 (write_dollar_variable): Update innermost block for registers.
2968 * parser-defs.h (enum innermost_block_tracker_type): New enum.
2969 (innermost_block_tracker::innermost_block_tracker): Initialise
2970 m_types member.
2971 (innermost_block_tracker::reset): Take type parameter.
2972 (innermost_block_tracker::update): Take type parameter, and pass
2973 type through as needed.
2974 (innermost_block_tracker::m_types): New member.
2975 * varobj.c (varobj_create): Pass type when reseting innermost
2976 block.
2977
aee1fcdf
AB
29782018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
2979
2980 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
2981 * ada-lang.c (resolve_subexp): Likewise.
2982 * breakpoint.c (set_breakpoint_condition) Likewise.
2983 (watch_command_1) Likewise.
2984 * c-exp.y (variable): Likewise.
2985 * d-exp.y (PrimaryExpression): Likewise.
2986 * f-exp.y (variable): Likewise.
2987 * go-exp.y (variable): Likewise.
2988 * m2-exp.y (variable): Likewise.
2989 * objfiles.c (objfile::~objfile): Likewise.
2990 * p-exp.y (variable): Likewise.
2991 * parse.c (innermost_block): Change type.
2992 * parser-defs.h (class innermost_block_tracker): New.
2993 (innermost_block): Change to innermost_block_tracker.
2994 * printcmd.c (display_command): Switch to innermost_block API.
2995 (do_one_display): Likewise.
2996 * rust-exp.y (do_one_display): Likewise.
2997 * symfile.c (clear_symtab_users): Likewise.
2998 * varobj.c (varobj_create): Switch to innermost_block API, replace
2999 use of innermost_block with block stored on varobj object.
3000
396af9a1
AB
30012018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
3002
3003 * expression.h (innermost_block): Remove declaration.
3004 * varobj.c: Add 'parser-defs.h' include.
3005
fcfcc376
TT
30062018-01-19 Tom Tromey <tom@tromey.com>
3007
3008 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
3009 symbols in the static and global blocks.
3010
5a6c3296
JC
30112018-01-19 James Clarke <jrtc27@jrtc27.com>
3012
3013 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
3014 gdb_ptrace.h, and move including gdb_wait.h ...
3015 * nat/linux-ptrace.h: ... to here.
3016
bc09b0c1
SM
30172018-01-19 Simon Marchi <simon.marchi@ericsson.com>
3018
3019 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
3020 inf_ptrace_detach_success.
3021 (inf_ptrace_detach_success): Add inferior parameter, use it
3022 instead of inferior_ptid, pass it to detach_inferior.
3023 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
3024 parameter.
3025 * inferior.c (detach_inferior): Add overload that takes an
3026 inferior object.
3027 * inferior.h (detach_inferior): Likewise.
3028 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
3029 use inferior_ptid, adjust call to inf_ptrace_detach_success.
3030 * linux-thread-db.c (thread_db_detach): Use inf parameter.
3031
6e1e1966
SM
30322018-01-19 Simon Marchi <simon.marchi@ericsson.com>
3033
3034 * target.h (struct target_ops) <to_detach>: Add inferior
3035 parameter.
3036 (target_detach): Likewise.
3037 * target.c (dispose_inferior): Pass inferior down.
3038 (target_detach): Pass inferior down. Assert that it is equal to
3039 the current inferior.
3040 * aix-thread.c (aix_thread_detach): Pass inferior down.
3041 * corefile.c (core_file_command): Pass current_inferior() down.
3042 * corelow.c (core_detach): Add inferior parameter.
3043 * darwin-nat.c (darwin_detach): Likewise.
3044 * gnu-nat.c (gnu_detach): Likewise.
3045 * inf-ptrace.c (inf_ptrace_detach): Likewise.
3046 * infcmd.c (detach_command): Pass current_inferior() down to
3047 target_detach.
3048 * infrun.c (follow_fork_inferior): Pass parent_inf to
3049 target_detach.
3050 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
3051 target_detach.
3052 * linux-nat.c (linux_nat_detach): Add inferior parameter.
3053 * linux-thread-db.c (thread_db_detach): Likewise.
3054 * nto-procfs.c (procfs_detach): Likewise.
3055 * procfs.c (procfs_detach): Likewise.
3056 * record.c (record_detach): Likewise.
3057 * record.h (struct inferior): Forward-declare.
3058 (record_detach): Add inferior parameter.
3059 * remote-sim.c (gdbsim_detach): Likewise.
3060 * remote.c (remote_detach_1): Likewise.
3061 (remote_detach): Likewise.
3062 (extended_remote_detach): Likewise.
3063 * sol-thread.c (sol_thread_detach): Likewise.
3064 * target-debug.h (target_debug_print_inferior_p): New macro.
3065 * target-delegates.c: Re-generate.
3066 * top.c (kill_or_detach): Pass inferior down to target_detach.
3067 * windows-nat.c (windows_detach): Add inferior parameter.
3068
6bd6f3b6
SM
30692018-01-19 Simon Marchi <simon.marchi@ericsson.com>
3070
3071 * target.h (struct target_ops) <to_detach>: Remove args
3072 parameter.
3073 (target_detach): Likewise.
3074 * target.c (dispose_inferior): Adjust.
3075 (target_detach): Remove args parameter, adjust.
3076 * aix-thread.c (aix_thread_detach): Adjust.
3077 * corefile.c (core_file_command): Adjust.
3078 * corelow.c (core_detach): Adjust.
3079 * darwin-nat.c (darwin_detach): Adjust.
3080 * gnu-nat.c (gnu_detach): Adjust.
3081 * inf-ptrace.c (inf_ptrace_detach): Adjust.
3082 * infcmd.c (detach_command): Adjust
3083 * infrun.c (follow_fork_inferior): Adjust.
3084 (handle_vfork_child_exec_or_exit): Adjust.
3085 * linux-fork.c (linux_fork_detach): Remove args parameter.
3086 * linux-fork.h (linux_fork_detach): Likewise.
3087 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
3088 * linux-thread-db.c (thread_db_detach): Likewise.
3089 * nto-procfs.c (procfs_detach): Likewise.
3090 * procfs.c (procfs_detach): Likewise.
3091 (do_detach): Remove signo parameter.
3092 * record.c (record_detach): Remove args parameter.
3093 * record.h (record_detach): Likewise.
3094 * remote-sim.c (gdbsim_detach): Likewise.
3095 * remote.c (remote_detach_1): Likewise.
3096 (remote_detach): Likewise.
3097 (extended_remote_detach): Likewise.
3098 * sol-thread.c (sol_thread_detach): Likewise.
3099 * target-delegates.c: Re-generate.
3100 * top.c (struct qt_args) <args>: Remove field.
3101 (kill_or_detach): Don't pass args.
3102 (quit_force): Don't set args.
3103 * windows-nat.c (windows_detach): Remove args parameter.
3104
88af8ea8
YQ
31052018-01-19 Yao Qi <yao.qi@linaro.org>
3106
3107 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
3108 (arm_linux_init_abi): Install it.
3109
dea445b9
YQ
31102018-01-19 Yao Qi <yao.qi@linaro.org>
3111
3112 * osabi.c (gdb_osabi_names): Extend the regexp for
3113 arm-linux-gnueabihf.
3114
4a17f768
YQ
31152018-01-18 Yao Qi <yao.qi@linaro.org>
3116
3117 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
3118 m_abbrevs.
3119 (abbrev_table::add_abbrev): Update.
3120 (abbrev_table::lookup_abbrev): Update.
3121
d679c21a
YQ
31222018-01-18 Yao Qi <yao.qi@linaro.org>
3123
3124 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
3125
7d937cad
SDJ
31262018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
3127
3128 * compile/compile.c (compile_to_object): Convert "triplet_rx"
3129 to "std::string".
3130
9e14690d
TT
31312018-01-17 Tom Tromey <tom@tromey.com>
3132
3133 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
3134
50a82047
TT
31352018-01-17 Tom Tromey <tom@tromey.com>
3136
3137 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
3138 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
3139 (create_array_type_with_stride): Update.
3140 * dwarf2read.c (set_die_type): Update.
3141
c89b44cd
TT
31422018-01-17 Tom Tromey <tom@tromey.com>
3143
3144 * dwarf2read.c (delayed_method_info): Remove typedef.
3145 (dwarf2_cu::method_info): Now a std::vector.
3146 (add_to_method_list): Update.
3147 (free_delayed_list): Remove.
3148 (compute_delayed_physnames): Update.
3149 (process_full_comp_unit, process_full_type_unit): Clear the method
3150 list. Remove cleanups.
3151 (psymtab_include_file_name): Add name_holder parameter. Use
3152 unique_xmalloc_ptr.
3153 (dwarf_decode_lines): Update.
3154
fcd3b13d
SM
31552018-01-17 Tom Tromey <tom@tromey.com>
3156 Simon Marchi <simon.marchi@ericsson.com>
3157
3158 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
3159 (dwarf2_per_objfile::free_cached_comp_units)
3160 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
3161 (init_cutu_and_read_dies_no_follow): Update.
3162 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
3163 (dwarf2_cu::~dwarf2_cu): New.
3164 (free_heap_comp_unit, free_stack_comp_unit): Remove.
3165 (age_cached_comp_units, free_one_cached_comp_unit): Update.
3166
685af9cd
TT
31672018-01-17 Tom Tromey <tom@tromey.com>
3168 Simon Marchi <simon.marchi@ericsson.com>
3169
3170 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
3171 (struct die_reader_specs) <abbrev_table>: New member.
3172 (struct abbrev_table): Add constructor.
3173 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
3174 <abbrev_obstack>: Now an auto_obstack.
3175 (abbrev_table_up): New typedef.
3176 (init_cu_die_reader): Add abbrev_table parameter.
3177 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
3178 Add result_dwo_abbrev_table.
3179 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
3180 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
3181 Update.
3182 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
3183 parameter.
3184 (skip_children): Update.
3185 (abbrev_table::alloc_abbrev): Rename from
3186 abbrev_table_alloc_abbrev.
3187 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
3188 (abbrev_table::lookup_abbrev): Rename from
3189 abbrev_table_lookup_abbrev.
3190 (abbrev_table_read_table): Return abbrev_table_up.
3191 (abbrev_table_free, abbrev_table_free_cleanup)
3192 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
3193 (load_partial_dies): Update.
3194
5e2db402
TT
31952018-01-17 Tom Tromey <tom@tromey.com>
3196
3197 * dwarf2read.c (dwarf2_compute_name): Update comment.
3198 (read_func_scope, read_variable): Update.
3199 (new_symbol): Remove.
3200 (new_symbol_full): Rename to new_symbol.
3201
ee7f689e 32022018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
3203
3204 PR gdb/16577
3205 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
3206 a warning instead of throwing an error, set section size to 0 and return
3207 NULL.
3208 * gdb_bfd.h (gdb_bfd_map_section): Update description.
3209
4d9b86e1
SM
32102018-01-17 Simon Marchi <simon.marchi@ericsson.com>
3211
3212 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
3213 std::string.
3214 (linux_ptrace_attach_fail_reason_string): Likewise.
3215 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
3216 Likewise.
3217 (linux_ptrace_attach_fail_reason_string): Likewise.
3218 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
3219
a7b2d0fb
SM
32202018-01-17 Simon Marchi <simon.marchi@ericsson.com>
3221
3222 * linux-nat.c (linux_nat_attach): Remove xstrdup.
3223
f517c180
EA
32242018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
3225
3226 PR gdb/21559
3227 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
3228 checking for fs_base/gs_base fields in struct user_regs_struct.
3229 * configure: Regenerate.
3230
7045b1ca
YQ
32312018-01-17 Yao Qi <yao.qi@linaro.org>
3232
3233 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
3234 function.
3235 (aarch64_linux_init_abi): Install it to gdbarch hook
3236 gcc_target_options.
3237
db422fb2
PA
32382018-01-15 Pedro Alves <palves@redhat.com>
3239
3240 * common/signals-state-save-restore.c
3241 (save_original_signals_state): Fix typos.
3242
ba643918
SDJ
32432017-01-12 Tom Tromey <tom@tromey.com>
3244 Sergio Durigan Junior <sergiodj@redhat.com>
3245
3246 * Makefile.in (install-only): Install gdb-add-index.
3247
906b4aac
JB
32482018-01-12 John Baldwin <jhb@FreeBSD.org>
3249
3250 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
3251
bdf2a94a
AA
32522018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
3253
3254 * infrun.c (keep_going_pass_signal): Clear step-over info when
3255 insert_breakpoints fails.
3256
71d378ae
PA
32572018-01-11 Pedro Alves <palves@redhat.com>
3258
3259 PR gdb/22583
3260 * infrun.c (resume): Rename to ...
3261 (resume_1): ... this.
3262 (resume): Reimplement as wrapper around resume_1.
3263
3cada740
PA
32642018-01-11 Pedro Alves <palves@redhat.com>
3265
3266 PR remote/22597
3267 * remote.c (remote_parse_stop_reply): Default to the last-set
3268 general thread instead of to 'magic_null_ptid'.
3269
618daa93
PA
32702018-01-10 Pedro Alves <palves@redhat.com>
3271
3272 * language.h (language_get_symbol_name_matcher): Rename ...
3273 (get_symbol_name_matcher): ... this.
3274 * language.c (language_get_symbol_name_matcher): Ditto.
3275 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
3276 callers adjusted.
3277
c63d3e8d
PA
32782018-01-10 Pedro Alves <palves@redhat.com>
3279
3280 PR gdb/22670
3281 * dwarf2read.c
3282 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
3283 Adjust to use language_get_symbol_name_matcher instead of
3284 language_defn::la_get_symbol_name_matcher.
3285 * language.c (language_get_symbol_name_matcher): If in Ada mode
3286 and the lookup name is a verbatim match, return Ada's matcher.
3287 * language.h (language_get_symbol_name_matcher): Adjust comment.
3288 (ada_lookup_name_info::verbatim_p):: New method.
3289
d4c2a405
PA
32902018-01-10 Pedro Alves <palves@redhat.com>
3291
3292 PR gdb/22670
3293 * ada-lang.c (ada_collect_symbol_completion_matches): If the
3294 minsym's language is language_auto or language_cplus, pass down
3295 language_ada instead.
3296 * symtab.c (compare_symbol_name): Don't frob symbol language here.
3297
8825213e
PA
32982018-01-10 Pedro Alves <palves@redhat.com>
3299
3300 PR gdb/22670
3301 * minsyms.c (linkage_name_str): New function.
3302 (iterate_over_minimal_symbols): Use it.
3303
2d97a5d9
JB
33042018-01-09 John Baldwin <jhb@FreeBSD.org>
3305
3306 * NEWS: Document that 'info proc' now works on FreeBSD.
3307
92fce24d
JB
33082018-01-09 John Baldwin <jhb@FreeBSD.org>
3309
3310 * configure.ac: Check for kinfo_getfile in libutil.
3311 * configure: Regenerate.
3312 * config.in: Regenerate.
3313 * fbsd-nat.c: Include "fbsd-tdep.h".
3314 (fbsd_fetch_cmdline): New.
3315 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
3316 rather than calling error.
3317 (fbsd_info_proc): New.
3318 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
3319 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
3320 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
3321
262f62f5
JB
33222018-01-09 John Baldwin <jhb@FreeBSD.org>
3323
3324 * fbsd-nat.c (struct free_deleter): Remove.
3325 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
3326
b999e203
JB
33272018-01-09 John Baldwin <jhb@FreeBSD.org>
3328
3329 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
3330 NULL for an empty pathname.
3331
d2176225
JB
33322018-01-09 John Baldwin <jhb@FreeBSD.org>
3333
3334 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
3335 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
3336 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
3337 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
3338 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
3339 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
3340 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
3341 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
3342 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
3343 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
3344 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
3345 (fbsd_core_fetch_timeval, fbsd_print_sigset)
3346 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
3347 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
3348 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
3349
9c4ac400
ST
33502018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
3351
3352 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
3353 (gnu_xfer_auxv): New function.
3354 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
3355 TARGET_OBJECT_AUXV.
3356
1e5ded6c
YQ
33572018-01-08 Yao Qi <yao.qi@linaro.org>
3358 Simon Marchi <simon.marchi@ericsson.com>
3359
3360 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
3361 common/selftest.c.
3362 (COMMON_OBS): Remove selftest.o.
3363 * configure.ac: Append selftest-arch.c and common/selftest.c to
3364 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
3365 * configure: Re-generated.
3366 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
3367 GDB_SELF_TEST.
3368 (maintenance_info_selftests): Likewise.
3369
04bafb1e
XR
33702018-01-08 Xavier Roirand <roirand@adacore.com>
3371
3372 * ada-valprint.c (val_print_packed_array_elements): Use
3373 proper number of elements when printing an array indexed
3374 by an enumeration type.
3375
518817b3
SM
33762018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
3377
3378 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
3379 (dw2_get_file_names_reader): Adjust.
3380 (lookup_dwo_signatured_type): Adjust.
3381 (lookup_dwp_signatured_type): Adjust.
3382 (lookup_signatured_type): Adjust.
3383 (create_type_unit_group): Adjust.
3384 (get_type_unit_group): Adjust.
3385 (process_psymtab_comp_unit_reader): Adjust.
3386 (build_type_psymtabs_reader): Adjust.
3387 (scan_partial_symbols): Adjust.
3388 (add_partial_symbol): Adjust.
3389 (add_partial_subprogram): Adjust.
3390 (peek_die_abbrev): Adjust.
3391 (fixup_go_packaging): Adjust.
3392 (process_imported_unit_die): Adjust.
3393 (dwarf2_compute_name): Adjust.
3394 (dwarf2_physname): Adjust.
3395 (read_import_statement): Adjust.
3396 (handle_DW_AT_stmt_list): Adjust.
3397 (read_file_scope): Adjust.
3398 (read_func_scope): Adjust.
3399 (read_lexical_block_scope): Adjust.
3400 (read_call_site_scope): Adjust.
3401 (read_variable): Adjust.
3402 (dwarf2_rnglists_process): Adjust.
3403 (dwarf2_ranges_process): Adjust.
3404 (dwarf2_ranges_read): Adjust.
3405 (dwarf2_get_pc_bounds): Adjust.
3406 (dwarf2_record_block_ranges): Adjust.
3407 (dwarf2_add_field): Adjust.
3408 (dwarf2_add_member_fn): Adjust.
3409 (read_structure_type): Adjust.
3410 (process_structure_scope): Adjust.
3411 (read_enumeration_type): Adjust.
3412 (read_array_type): Adjust.
3413 (mark_common_block_symbol_computed): Adjust.
3414 (read_common_block): Adjust.
3415 (read_namespace_type): Adjust.
3416 (read_namespace): Adjust.
3417 (read_module_type): Adjust.
3418 (read_tag_pointer_type): Adjust.
3419 (read_tag_ptr_to_member_type): Adjust.
3420 (read_tag_string_type): Adjust.
3421 (read_subroutine_type): Adjust.
3422 (read_typedef): Adjust.
3423 (read_base_type): Adjust.
3424 (attr_to_dynamic_prop): Adjust.
3425 (read_subrange_type): Adjust.
3426 (read_unspecified_type): Adjust.
3427 (dwarf2_read_abbrevs): Adjust.
3428 (load_partial_dies): Adjust.
3429 (read_partial_die): Adjust.
3430 (find_partial_die): Adjust.
3431 (guess_partial_die_structure_name): Adjust.
3432 (fixup_partial_die): Adjust.
3433 (read_attribute_value): Adjust.
3434 (read_addr_index): Adjust.
3435 (read_addr_index_from_leb128): Adjust.
3436 (read_str_index): Adjust.
3437 (dwarf2_string_attr): Adjust.
3438 (get_debug_line_section): Adjust.
3439 (dwarf_decode_line_header): Adjust.
3440 (lnp_state_machine::check_line_address): Adjust.
3441 (dwarf_decode_lines_1): Adjust.
3442 (dwarf_decode_lines): Adjust.
3443 (dwarf2_start_symtab): Adjust.
3444 (var_decode_location): Adjust.
3445 (new_symbol_full): Adjust.
3446 (dwarf2_const_value_data): Adjust.
3447 (dwarf2_const_value_attr): Adjust.
3448 (dwarf2_const_value): Adjust.
3449 (die_type): Adjust.
3450 (die_containing_type): Adjust.
3451 (build_error_marker_type): Adjust.
3452 (lookup_die_type): Adjust.
3453 (guess_full_die_structure_name): Adjust.
3454 (anonymous_struct_prefix): Adjust.
3455 (determine_prefix): Adjust.
3456 (dwarf2_name): Adjust.
3457 (follow_die_ref_or_sig): Adjust.
3458 (follow_die_offset): Adjust.
3459 (follow_die_ref): Adjust.
3460 (follow_die_sig_1): Adjust.
3461 (follow_die_sig): Adjust.
3462 (get_signatured_type): Adjust.
3463 (get_DW_AT_signature_type): Adjust.
3464 (decode_locdesc): Adjust.
3465 (dwarf_decode_macros): Adjust.
3466 (cu_debug_loc_section): Adjust.
3467 (fill_in_loclist_baton): Adjust.
3468 (dwarf2_symbol_mark_computed): Adjust.
3469 (init_one_comp_unit): Don't assign
3470 dwarf2_cu::dwarf2_per_objfile.
3471 (set_die_type): Adjust.
3472
ed2dc618
SM
34732018-01-07 Simon Marchi <simon.marchi@ericsson.com>
3474
3475 * dwarf2read.c (struct mapped_debug_names): Add constructor.
3476 <dwarf2_per_objfile>: New field.
3477 (dwarf2_per_objfile): Remove global.
3478 (get_dwarf2_per_objfile): New function.
3479 (set_dwarf2_per_objfile): New function.
3480 (dwarf2_build_psymtabs_hard): Change objfile parameter to
3481 dwarf2_per_objfile.
3482 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
3483 (read_abbrev_offset): Likewise.
3484 (read_indirect_string): Likewise.
3485 (read_indirect_line_string): Likewise.
3486 (read_indirect_string_at_offset): Likewise.
3487 (read_indirect_string_from_dwz): Likewise.
3488 (dwarf2_find_containing_comp_unit): Change objfile parameter to
3489 dwarf2_per_objfile.
3490 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
3491 (create_all_comp_units): Change objfile parameter to
3492 dwarf2_per_objfile.
3493 (create_all_type_units): Likewise.
3494 (process_queue): Add dwarf2_per_objfile parameter.
3495 (read_and_check_comp_unit_head): Likewise.
3496 (lookup_dwo_unit_in_dwp): Likewise.
3497 (get_dwp_file): Likewise.
3498 (process_cu_includes): Likewise.
3499 (struct free_dwo_file_cleanup_data): New struct.
3500 (dwarf2_has_info): Use get_dwarf2_per_objfile and
3501 set_dwarf2_per_objfile.
3502 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
3503 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
3504 context, adjust calls.
3505 (dw2_instantiate_symtab): Likewise.
3506 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
3507 (dw2_get_cu): Likewise.
3508 (create_cu_from_index_list): Change objfile parameter to
3509 dwarf2_per_objfile.
3510 (create_cus_from_index_list): Get dwarf2_per_objfile from
3511 context, adjust calls.
3512 (create_cus_from_index): Likewise.
3513 (create_signatured_type_table_from_index): Change objfile
3514 parameter to dwarf2_per_objfile.
3515 (create_signatured_type_table_from_debug_names): Change objfile
3516 parameter to dwarf2_per_objfile.
3517 (create_addrmap_from_index): Likewise.
3518 (create_addrmap_from_aranges): Likewise.
3519 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
3520 (dw2_setup): Remove.
3521 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
3522 context.
3523 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
3524 get_dwarf2_per_objfile.
3525 (dw2_forget_cached_source_info): Likewise.
3526 (dw2_map_symtabs_matching_filename): Likewise.
3527 (struct dw2_symtab_iterator) <index>: Remove.
3528 <dwarf2_per_objfile>: New field.
3529 (dw2_symtab_iter_init): Replace index parameter with
3530 dwarf2_per_objfile.
3531 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
3532 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
3533 (dw2_print_stats): Likewise.
3534 (dw2_dump): Likewise.
3535 (dw2_expand_symtabs_for_function): Likewise.
3536 (dw2_expand_all_symtabs): Likewise.
3537 (dw2_expand_symtabs_with_fullname): Likewise.
3538 (dw2_expand_marked_cus): Replace index and objfile parameters
3539 with dwarf2_per_objfile.
3540 (dw_expand_symtabs_matching_file_matcher): Add
3541 dwarf2_per_objfile parameter and adjust calls.
3542 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
3543 adjust calls.
3544 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
3545 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
3546 adjust calls.
3547 (create_cus_from_debug_names_list): Replace objfile parameter
3548 with dwarf2_per_objfile and adjust calls.
3549 (create_cus_from_debug_names): Likewise.
3550 (dwarf2_read_debug_names): Likewise.
3551 (mapped_debug_names::namei_to_name): Adjust call.
3552 (dw2_debug_names_iterator::next): Likewise.
3553 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
3554 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
3555 (dw2_debug_names_dump): Likewise.
3556 (dw2_debug_names_expand_symtabs_for_function): Likewise.
3557 (dw2_debug_names_expand_symtabs_matching): Likewise.
3558 (dwarf2_initialize_objfile): Likewise.
3559 (dwarf2_build_psymtabs): Likewise.
3560 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
3561 this_cu.
3562 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
3563 (read_and_check_comp_unit_head): Likewise.
3564 (read_abbrev_offset): Likewise.
3565 (create_debug_type_hash_table): Likewise.
3566 (create_debug_types_hash_table): Likewise.
3567 (create_all_type_units): Replace objfile parameter with
3568 dwarf2_per_objfile.
3569 (add_type_unit): Add dwarf2_per_objfile parameter.
3570 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
3571 with dwarf2_per_objfile.
3572 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
3573 (lookup_dwp_signatured_type): Likewise.
3574 (lookup_signatured_type): Likewise.
3575 (read_cutu_die_from_dwo): Likewise.
3576 (init_tu_and_read_dwo_dies): Likewise.
3577 (init_cutu_and_read_dies): Likewise.
3578 (init_cutu_and_read_dies_no_follow): Likewise.
3579 (allocate_type_unit_groups_table): Add objfile parameter.
3580 (create_type_unit_group): Use dwarf2_per_objfile from cu.
3581 (get_type_unit_group): Likewise.
3582 (process_psymtab_comp_unit): Update call.
3583 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
3584 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
3585 (print_tu_stats): Likewise.
3586 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
3587 in void* parameter.
3588 (build_type_psymtabs): Change objfile parameter to
3589 dwarf2_per_objfile.
3590 (process_skeletonless_type_unit): Use dwarf2_per_objfile
3591 passed in void* parameter.
3592 (process_skeletonless_type_units): Change objfile parameter to
3593 dwarf2_per_objfile.
3594 (set_partial_user): Likewise.
3595 (dwarf2_build_psymtabs_hard): Likewise.
3596 (read_comp_units_from_section): Likewise.
3597 (create_all_comp_units): Likewise.
3598 (scan_partial_symbols): Update calls.
3599 (add_partial_symbol): Likewise.
3600 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
3601 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
3602 (process_queue): Add dwarf2_per_objfile parameter.
3603 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
3604 (compute_compunit_symtab_includes): Likewise.
3605 (process_cu_includes): Add dwarf2_per_objfile parameter.
3606 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
3607 (process_full_type_unit): Likewise.
3608 (process_imported_unit_die): Update call.
3609 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
3610 (read_file_scope): Likewise.
3611 (allocate_dwo_file_hash_table): Add objfile parameter.
3612 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
3613 (create_cus_hash_table): Likewise.
3614 (create_dwp_hash_table): Likewise.
3615 (create_dwo_unit_in_dwp_v1): Likewise.
3616 (create_dwp_v2_section): Likewise.
3617 (create_dwo_unit_in_dwp_v2): Likewise.
3618 (lookup_dwo_unit_in_dwp): Likewise.
3619 (try_open_dwop_file): Likewise.
3620 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
3621 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
3622 cleanup to include a reference to dwarf2_per_objfile.
3623 (open_dwp_file): Add dwarf2_per_objfile parameter.
3624 (open_and_init_dwp_file): Likewise.
3625 (get_dwp_file): Likewise.
3626 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
3627 (queue_and_load_all_dwo_tus): Update call.
3628 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
3629 data.
3630 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
3631 (dwarf2_ranges_process): Likewise.
3632 (dwarf2_get_pc_bounds): Likewise.
3633 (mark_common_block_symbol_computed): Likewise.
3634 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
3635 (dwarf2_read_abbrevs): Update call.
3636 (read_partial_die): Use dwarf2_per_objfile from cu.
3637 (find_partial_die): Likewise.
3638 (fixup_partial_die): Likewise.
3639 (read_attribute_value): Likewise.
3640 (read_indirect_string_at_offset_from): Add objfile parameter.
3641 (read_indirect_string_at_offset): Add dwarf2_per_objfile
3642 parameter.
3643 (read_indirect_string_from_dwz): Add objfile parameter.
3644 (read_indirect_string): Add objfile parameter.
3645 (read_addr_index_1): Add dwarf2_per_objfile parameter.
3646 (read_addr_index): Use dwarf2_per_objfile from cu.
3647 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
3648 call dw2_setup.
3649 (read_str_index): Use dwarf2_per_objfile from cu.
3650 (get_debug_line_section): Likewise.
3651 (read_formatted_entries): Add dwarf2_per_objfile parameter.
3652 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
3653 (new_symbol_full): Use dwarf2_per_objfile from cu.
3654 (build_error_marker_type): Likewise.
3655 (lookup_die_type): Likewise.
3656 (determine_prefix): Likewise.
3657 (follow_die_offset): Likewise.
3658 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
3659 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
3660 (dwarf2_fetch_die_type_sect_off): Likewise.
3661 (dwarf2_get_die_type): Likewise.
3662 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
3663 (get_signatured_type): Likewise.
3664 (get_DW_AT_signature_type): Likewise.
3665 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
3666 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
3667 (cu_debug_loc_section): Likewise.
3668 (fill_in_loclist_baton): Likewise.
3669 (dwarf2_symbol_mark_computed): Likewise.
3670 (dwarf2_find_containing_comp_unit): Change objfile parameter to
3671 dwarf2_per_objfile.
3672 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
3673 parameter.
3674 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
3675 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
3676 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
3677 (set_die_type): Use dwarf2_free_objfile from cu.
3678 (get_die_type_at_offset): Likewise.
3679 (dwarf2_per_objfile_free): Don't assign global variable.
3680 (debug_names) <constructor>: Add dwarf2_per_objfile
3681 parameter, update m_debugstrlookup construction.
3682 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
3683 parameter.
3684 <m_dwarf2_per_objfile>: New field.
3685 <lookup>: Use m_dwarf2_per_objfile.
3686 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
3687 (psyms_seen_size): Likewise.
3688 (write_gdbindex): Replace objfile parameter with
3689 dwarf2_per_objfile.
3690 (write_debug_names): Likewise.
3691 (write_psymtabs_to_index): Likewise.
3692 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
3693 calls.
3694
e3b94546
SM
36952018-01-07 Simon Marchi <simon.marchi@ericsson.com>
3696
3697 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
3698 <dwarf2_per_objfile>: New field.
3699 (struct dwarf2_per_cu_data) <objfile>: Remove.
3700 <dwarf2_per_objfile>: New field.
3701 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
3702 of objfile.
3703 (create_signatured_type_table_from_index): Likewise.
3704 (create_debug_type_hash_table): Likewise.
3705 (fill_in_sig_entry_from_dwo_entry): Likewise.
3706 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
3707 (create_type_unit_group): Assign dwarf2_per_objfile instead of
3708 objfile.
3709 (create_partial_symtab): Access objfile through
3710 dwarf2_per_objfile.
3711 (process_psymtab_comp_unit_reader): Likewise.
3712 (read_comp_units_from_section): Likewise.
3713 (scan_partial_symbols): Likewise.
3714 (add_partial_symbol): Likewise.
3715 (add_partial_subprogram): Likewise.
3716 (peek_die_abbrev): Likewise.
3717 (fixup_go_packaging): Likewise.
3718 (process_full_comp_unit): Likewise.
3719 (process_full_type_unit): Likewise.
3720 (process_imported_unit_die): Likewise.
3721 (dwarf2_compute_name): Likewise.
3722 (dwarf2_physname): Likewise.
3723 (read_import_statement): Likewise.
3724 (create_cus_hash_table): Assign dwarf2_physname instead of
3725 objfile.
3726 (read_func_scope): Access objfile through dwarf2_per_objfile.
3727 (read_lexical_block_scope): Likewise.
3728 (read_call_site_scope): Likewise.
3729 (read_variable): Likewise.
3730 (dwarf2_rnglists_process): Likewise.
3731 (dwarf2_ranges_process): Likewise.
3732 (dwarf2_ranges_read): Likewise.
3733 (dwarf2_record_block_ranges): Likewise.
3734 (dwarf2_add_field): Likewise.
3735 (dwarf2_add_member_fn): Likewise.
3736 (read_structure_type): Likewise.
3737 (process_structure_scope): Likewise.
3738 (read_enumeration_type): Likewise.
3739 (read_array_type): Likewise.
3740 (read_common_block): Likewise.
3741 (read_namespace_type): Likewise.
3742 (read_namespace): Likewise.
3743 (read_module_type): Likewise.
3744 (read_tag_pointer_type): Likewise.
3745 (read_tag_ptr_to_member_type): Likewise.
3746 (read_tag_string_type): Likewise.
3747 (read_subroutine_type): Likewise.
3748 (read_typedef): Likewise.
3749 (read_base_type): Likewise.
3750 (attr_to_dynamic_prop): Likewise.
3751 (read_subrange_type): Likewise.
3752 (read_unspecified_type): Likewise.
3753 (load_partial_dies): Likewise.
3754 (read_partial_die): Likewise.
3755 (find_partial_die): Likewise.
3756 (guess_partial_die_structure_name): Likewise.
3757 (fixup_partial_die): Likewise.
3758 (read_attribute_value): Likewise.
3759 (read_addr_index_from_leb128): Likewise.
3760 (dwarf2_read_addr_index): Likewise.
3761 (dwarf2_string_attr): Likewise.
3762 (lnp_state_machine::check_line_address): Likewise.
3763 (dwarf_decode_lines_1): Likewise.
3764 (dwarf_decode_lines): Likewise.
3765 (dwarf2_start_symtab): Likewise.
3766 (var_decode_location): Likewise.
3767 (new_symbol_full): Likewise.
3768 (dwarf2_const_value_data): Likewise.
3769 (dwarf2_const_value_attr): Likewise.
3770 (dwarf2_const_value): Likewise.
3771 (die_type): Likewise.
3772 (die_containing_type): Likewise.
3773 (lookup_die_type): Likewise.
3774 (guess_full_die_structure_name): Likewise.
3775 (anonymous_struct_prefix): Likewise.
3776 (dwarf2_name): Likewise.
3777 (follow_die_ref_or_sig): Likewise.
3778 (follow_die_offset): Likewise.
3779 (follow_die_ref): Likewise.
3780 (dwarf2_fetch_die_loc_sect_off): Likewise.
3781 (dwarf2_fetch_constant_bytes): Likewise.
3782 (dwarf2_fetch_die_type_sect_off): Likewise.
3783 (dwarf2_get_die_type): Likewise.
3784 (follow_die_sig): Likewise.
3785 (decode_locdesc): Likewise.
3786 (dwarf2_per_cu_objfile): Likewise.
3787 (dwarf2_per_cu_text_offset): Likewise.
3788 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
3789 objfile.
3790 (set_die_type): Access objfile through
3791 dwarf2_per_objfile.
3792
b01ba14d
SM
37932018-01-07 Simon Marchi <simon.marchi@ericsson.com>
3794
3795 * valprint.c (converted_character_d): Remove typedef.
3796 (DEF_VEC_O (converted_character_d)): Remove.
3797 (count_next_character): Use std::vector.
3798 (print_converted_chars_to_obstack): Likewise.
3799 (generic_printstr): Likewise.
3800
4d0fdd9b
SM
38012018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
3802
3803 * xml-support.h (struct gdb_xml_value): Add constructor.
3804 <value>: Change type to unique_xmalloc_ptr.
3805 (gdb_xml_value_s): Remove typedef.
3806 (DEF_VEC_O (gdb_xml_value_s)): Remove.
3807 (gdb_xml_element_start_handler): Change parameter type to
3808 std::vector.
3809 (xml_find_attribute): Likewise.
3810 * xml-support.c (xml_find_attribute): Change parameter type to
3811 std::vector and adjust.
3812 (gdb_xml_values_cleanup): Remove.
3813 (gdb_xml_parser::start_element): Adjust to std::vector.
3814 (xinclude_start_include): Change paraeter type to std::vector
3815 and adjust.
3816 * btrace.c (check_xml_btrace_version): Likewise.
3817 (parse_xml_btrace_block): Likewise.
3818 (parse_xml_btrace_pt_config_cpu): Likewise.
3819 (parse_xml_btrace_pt): Likewise.
3820 (parse_xml_btrace_conf_bts): Likewise.
3821 (parse_xml_btrace_conf_pt): Likewise.
3822 * memory-map.c (memory_map_start_memory): Likewise.
3823 (memory_map_start_property): Likewise.
3824 * osdata.c (osdata_start_osdata): Likewise.
3825 (osdata_start_item): Likewise.
3826 (osdata_start_column): Likewise.
3827 * remote.c (start_thread): Likewise.
3828 * solib-aix.c (library_list_start_library): Likewise.
3829 (library_list_start_list): Likewise.
3830 * solib-svr4.c (library_list_start_library): Likewise.
3831 (svr4_library_list_start_list): Likewise.
3832 * solib-target.c (library_list_start_segment): Likewise.
3833 (library_list_start_section): Likewise.
3834 (library_list_start_library): Likewise.
3835 (library_list_start_list): Likewise.
3836 * tracepoint.c (traceframe_info_start_memory): Likewise.
3837 (traceframe_info_start_tvar): Likewise.
3838 * xml-syscall.c (syscall_start_syscall): Likewise.
3839 * xml-tdesc.c (tdesc_start_target): Likewise.
3840 (tdesc_start_feature): Likewise.
3841 (tdesc_start_reg): Likewise.
3842 (tdesc_start_union): Likewise.
3843 (tdesc_start_struct): Likewise.
3844 (tdesc_start_flags): Likewise.
3845 (tdesc_start_enum): Likewise.
3846 (tdesc_start_field): Likewise.
3847 (tdesc_start_enum_value): Likewise.
3848 (tdesc_start_vector): Likewise.
3849
f979c73f
SM
38502018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
3851
3852 * extension.h (struct xmethod_worker) <clone>: Remove.
3853 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
3854 Remove.
3855 (python_xmethod_worker::clone): Remove.
3856 * valops.c (find_overload_match): Use std::move instead of
3857 clone.
3858
ba18742c
SM
38592018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
3860
3861 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
3862 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
3863 <free_xmethod_worker_data>: Remove.
3864 <get_matching_xmethod_workers>: Chance VEC to std::vector.
3865 <get_xmethod_arg_types>: Remove.
3866 <get_xmethod_result_type>: Remove.
3867 <invoke_xmethod>: Remove.
3868 * extension.c (new_xmethod_worker): Remove.
3869 (clone_xmethod_worker): Remove.
3870 (get_matching_xmethod_workers): Return void, pass std::vector by
3871 pointer.
3872 (get_xmethod_arg_types): Rename to...
3873 (xmethod_worker::get_arg_types): ... this, and adjust.
3874 (get_xmethod_result_type): Rename to...
3875 (xmethod_worker::get_result_type): ... this, and adjust.
3876 (invoke_xmethod): Remove.
3877 (free_xmethod_worker): Remove.
3878 (free_xmethod_worker_vec): Remove.
3879 * extension.h (enum ext_lang_rc): Move here from
3880 extension-priv.h.
3881 (struct xmethod_worker): Add constructor and destructor.
3882 <data>: Remove.
3883 <value>: Remove.
3884 <invoke, clone, do_get_result_type, do_get_arg_types>: New
3885 virtual pure methods.
3886 <get_arg_types, get_result_type>: New methods.
3887 (xmethod_worker_ptr): Remove typedef.
3888 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
3889 (xmethod_worker_vec): Remove typedef.
3890 (xmethod_worker_up): New typedef.
3891 (invoke_xmethod): Remove.
3892 (clone_xmethod_worker): Remove.
3893 (free_xmethod_worker): Remove.
3894 (free_xmethod_worker_vec): Remove.
3895 (get_xmethod_arg_types): Remove.
3896 (get_xmethod_result_type): Remove.
3897 * valops.c (find_method_list): Use std::vector, don't use
3898 intermediate vector.
3899 (value_find_oload_method_list): Use std::vector.
3900 (find_overload_match): Use std::vector.
3901 (find_oload_champ): Use std::vector.
3902 * value.c (value_free): Use operator delete.
3903 (value_of_xmethod): Rename to...
3904 (value_from_xmethod): ... this. Don't assign
3905 xmethod_worker::value, take rvalue-reference.
3906 (result_type_of_xmethod): Adjust.
3907 (call_xmethod): Adjust.
3908 * value.h: Include extension.h.
3909 (struct xmethod_worker): Don't forward-declare.
3910 (value_of_xmethod): Rename to...
3911 (value_from_xmethod): ... this, take rvalue-reference.
3912 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
3913 (struct python_xmethod_worker): ... this, add constructor and
3914 destructor.
3915 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
3916 (gdbpy_free_xmethod_worker_data): Rename to...
3917 (python_xmethod_worker::~python_xmethod_worker): ... this and
3918 adjust.
3919 (gdbpy_clone_xmethod_worker_data): Rename to...
3920 (python_xmethod_worker::clone): ... this and adjust.
3921 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
3922 temporary vector.
3923 (gdbpy_get_xmethod_arg_types): Rename to...
3924 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
3925 (gdbpy_get_xmethod_result_type): Rename to...
3926 (python_xmethod_worker::do_get_result_type): ... this and
3927 adjust.
3928 (gdbpy_invoke_xmethod): Rename to...
3929 (python_xmethod_worker::invoke): ... this and adjust.
3930 (new_python_xmethod_worker): Rename to...
3931 (python_xmethod_worker::python_xmethod_worker): ... this and
3932 adjust.
3933 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
3934 Remove.
3935 (gdbpy_free_xmethod_worker_data): Remove.
3936 (gdbpy_get_matching_xmethod_workers): Use std::vector.
3937 (gdbpy_get_xmethod_arg_types): Remove.
3938 (gdbpy_get_xmethod_result_type): Remove.
3939 (gdbpy_invoke_xmethod): Remove.
3940 * python/python.c (python_extension_ops): Remove obsolete
3941 callbacks.
3942
e379cee6
PA
39432018-01-05 Pedro Alves <palves@redhat.com>
3944
3945 PR gdb/18653
3946 * common/signals-state-save-restore.c
3947 (save_original_signals_state): New parameter 'quiet'. Warn if we
3948 find a custom handler preinstalled, instead of internal erroring.
3949 But only warn if !quiet.
3950 * common/signals-state-save-restore.h
3951 (save_original_signals_state): New parameter 'quiet'.
3952 * main.c (captured_main_1): Move save_original_signals_state call
3953 after option handling, and pass QUIET.
3954
a655456c
PA
39552018-01-05 Pedro Alves <palves@redhat.com>
3956
3957 * spu-tdep.c (spu_catch_start): Pass
3958 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
3959
de63c46b
PA
39602018-01-05 Pedro Alves <palves@redhat.com>
3961
3962 PR gdb/22670
3963 * ada-lang.c (literal_symbol_name_matcher): New function.
3964 (ada_get_symbol_name_matcher): Use it for
3965 symbol_name_match_type::SEARCH_NAME.
3966 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
3967 it down instead of assuming symbol_name_match_type::FULL.
3968 * block.h (block_lookup_symbol): New parameter 'match_type'.
3969 * c-valprint.c (print_unpacked_pointer): Use
3970 lookup_symbol_search_name instead of lookup_symbol.
3971 * compile/compile-object-load.c (get_out_value_type): Pass down
3972 symbol_name_match_type::SEARCH_NAME.
3973 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
3974 symbol_name_match_type::FULL.
3975 * cp-support.c (cp_get_symbol_name_matcher): Handle
3976 symbol_name_match_type::SEARCH_NAME.
3977 * infrun.c (insert_exception_resume_breakpoint): Use
3978 lookup_symbol_search_name.
3979 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
3980 * psymtab.c (maintenance_check_psymtabs): Use
3981 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
3982 * stack.c (print_frame_args): Use lookup_symbol_search_name and
3983 SYMBOL_SEARCH_NAME.
3984 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
3985 if symbol_name_match_type::SEARCH_NAME.
3986 (lookup_symbol_in_language): Pass down
3987 symbol_name_match_type::FULL.
3988 (lookup_symbol_search_name): New.
3989 (lookup_language_this): Pass down
3990 symbol_name_match_type::SEARCH_NAME.
3991 (lookup_symbol_aux, lookup_local_symbol): New parameter
3992 'match_type'. Pass it down.
3993 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
3994 (lookup_symbol_search_name): New declaration.
3995 (lookup_symbol_in_block): New 'match_type' parameter.
3996
f98fc17b
PA
39972018-01-05 Pedro Alves <palves@redhat.com>
3998
3999 PR gdb/22670
4000 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
4001 ada_lookup_symbol.
4002 (ada_lookup_symbol): Reimplement in terms of
4003 ada_lookup_symbol_list, bits factored out from
4004 ada_lookup_encoded_symbol.
4005
342f8240
JB
40062018-01-05 Joel Brobecker <brobecker@adacore.com>
4007
4008 * ada-exp.y (write_object_renaming): When subscripting an array
4009 using a symbol as the index, pass the block in call to
4010 ada_lookup_encoded_symbol when looking that symbol up.
4011
7150d33c
JG
40122018-01-05 Jerome Guitton <guitton@adacore.com>
4013
4014 * ada-lang.c (ada_array_length): Use ada_index_type instead of
4015 TYPE_INDEX_TYPE.
4016
cc0e770c
JB
40172018-01-05 Joel Brobecker <brobecker@adacore.com>
4018
4019 * ada-lang.c (ada_to_fixed_value_create): Add handling of
4020 the case where VALUE_LVAL (val0) is not lval_memory.
4021
f79da888 40222018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
4023
4024 * ada-valprint.c (print_optional_low_bound): Handle
4025 character-indexed array printing like boolean-indexed array
4026 printing.
4027
cd385f94
JB
40282018-01-05 Joel Brobecker <brobecker@adacore.com>
4029
4030 * NEWS: Create a new section for the next release branch.
4031 Rename the section of the current branch, now that it has
4032 been cut.
4033
09aca949
JB
40342018-01-05 Joel Brobecker <brobecker@adacore.com>
4035
4036 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
4037 * version.in: Bump version to 8.1.50.DATE-git.
4038
9f757bf7
XR
40392018-01-03 Xavier Roirand <roirand@adacore.com>
4040
4041 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
4042 Add field.
4043 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
4044 Add field.
4045 (default_exception_support_info) <catch_handlers_sym>: Add field.
4046 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
4047 (ada_exception_name_addr_1): Add "catch handlers" handling.
4048 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
4049 Update all callers.
4050 (create_excep_cond_exprs) <ex>: Add parameter.
4051 (re_set_exception): Update create_excep_cond_exprs call.
4052 (print_it_exception, print_one_exception, print_mention_exception)
4053 (print_recreate_exception): Add "catch handler" handling.
4054 (allocate_location_catch_handlers, re_set_catch_handlers)
4055 (check_status_catch_handlers, print_it_catch_handlers)
4056 (print_one_catch_handlers, print_mention_catch_handlers)
4057 (print_recreate_catch_handlers): New function.
4058 (catch_handlers_breakpoint_ops): New variable.
4059 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
4060 Add parameter. Add "catch handler" handling.
4061 (ada_exception_sym_name, ada_exception_breakpoint_ops):
4062 Add "catch handler" handling.
4063 (ada_exception_catchpoint_cond_string): Add "catch handler"
4064 handling.
4065 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
4066 call.
4067 (catch_ada_handlers_command): New function.
4068 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
4069 operations structure.
4070 (_initialize_ada_language): Add "catch handlers" command entry.
4071 * NEWS: Document "catch handlers" feature.
4072
9fe561ab
JB
40732018-01-02 Joel Brobecker <brobecker@adacore.com>
4074
4075 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
4076 account when creating the array type of the slice.
4077 (ada_value_slice): Likewise.
4078
a405673c
JB
40792018-01-02 Joel Brobecker <brobecker@adacore.com>
4080
4081 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
4082 New enum value.
4083 (create_array_type_with_stride): Add byte_stride_prop parameter.
4084 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
4085 New parameter. Update all callers in this file.
4086 (array_type_has_dynamic_stride): New function.
4087 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
4088 of arrays with dynamic byte strides.
4089 * dwarf2read.c (read_array_type): Add support for dynamic
4090 DW_AT_byte_stride attributes.
4091
74a2f8ff
JB
40922018-01-02 Joel Brobecker <brobecker@adacore.com>
4093
4094 * dwarf2read.c (read_unspecified_type): Treat
4095 DW_TAG_enumeration_type DIEs from Ada units as stubs.
4096
e2882c85
JB
40972018-01-01 Joel Brobecker <brobecker@adacore.com>
4098
4099 Update copyright year range in all GDB files.
4100
1690bb24
JB
41012018-01-01 Joel Brobecker <brobecker@adacore.com>
4102
4103 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
4104 and gdb/testsuite/gdb.base/step-line.c.
4105
0f0c98a8
JB
41062018-01-01 Joel Brobecker <brobecker@adacore.com>
4107
4108 * copyright.py (main): Dump the contents of
4109 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
4110 even if BY_HAND is empty.
4111
82e1e79a
JB
41122018-01-01 Joel Brobecker <brobecker@adacore.com>
4113
4114 * top.c (print_gdb_version): Update Copyright year in version
4115 message.
4116
053f54e5 41172018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 4118
053f54e5 4119 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 4120
053f54e5 4121For older changes see ChangeLog-2017.
c906108c
SS
4122\f
4123Local Variables:
4124mode: change-log
4125left-margin: 8
4126fill-column: 74
4127version-control: never
57da7796 4128coding: utf-8
c906108c 4129End:
This page took 2.46205 seconds and 4 git commands to generate.