regcache::cooked_read unit test
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2017-11-24 Yao Qi <yao.qi@linaro.org>
2
3 * gdbarch-selftests.c (test_target_has_registers): Move it to
4 target.c.
5 (test_target_has_stack): Likewise.
6 (test_target_has_memory): Likewise.
7 (test_target_prepare_to_store): Likewise.
8 (test_target_store_registers): Likewise.
9 (test_target_ops): Likewise.
10 * regcache.c: Include selftest-arch.h and gdbthread.h.
11 (target_ops_no_register): New class.
12 (test_target_fetch_registers): New.
13 (test_target_store_registers): New.
14 (test_target_xfer_partial): New.
15 (readwrite_regcache): New.
16 (cooked_read_test): New.
17 (_initialize_regcache): Register the test.
18 * target.c: (test_target_has_registers): Moved from
19 gdbarch-selftests.c.
20 (test_target_has_stack): Likewise.
21 (test_target_has_memory): Likewise.
22 (test_target_prepare_to_store): Likewise.
23 (test_target_store_registers): Likewise.
24 * target.h (test_target_ops): New class.
25
26 2017-11-24 Alan Hayward <alan.hayward@arm.com>
27
28 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
29 selftest.
30
31 2017-11-24 Alan Hayward <alan.hayward@arm.com>
32
33 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
34 * arch/aarch64.c (aarch64_create_target_description): Create
35 new target description.
36 * features/Makefile: Add new files.
37 * features/aarch64.c: Remove file.
38 * features/aarch64-core.c: New autogenerated file.
39 * features/aarch64-fpu.c: New autogenerated file.
40 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
41
42 2017-11-24 Alan Hayward <alan.hayward@arm.com>
43
44 * Makefile.in: Add new files.
45 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
46 aarch64_read_description.
47 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
48 Call aarch64_read_description.
49 * aarch64-tdep.c (aarch64_read_description): New function.
50 (aarch64_gdbarch_init): Call aarch64_read_description.
51 * aarch64-tdep.h (aarch64_read_description): New function.
52 * arch/aarch64.c: New file.
53 * configure.tgt: Add new files.
54
55 2017-11-24 Yao Qi <yao.qi@linaro.org>
56
57 * mi/mi-main.c (register_changed_p): Update.
58 * value.c (value_contents_bits_eq): Change return type.
59 (value_contents_eq): Likewise.
60 * value.h: Update comments.
61
62 2017-11-24 Yao Qi <yao.qi@linaro.org>
63
64 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
65 local 'changed'. Remove error.
66 (register_changed_p): Change return type to bool.
67
68 2017-11-24 Yao Qi <yao.qi@linaro.org>
69
70 * arch/tic6x.c: New file.
71 * arch/tic6x.h: New file.
72 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
73 tic6x-core.xml and tic6x-gp.xml.
74 * features/tic6x-c6xp.c: Generated.
75 * features/tic6x-core.c: Generated.
76 * features/tic6x-gp.c: Generated.
77 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
78 "tic6x-".
79
80 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
81
82 * mi/mi-main.c (list_available_thread_groups): Change map value
83 type to std::vector.
84
85 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
86
87 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
88
89 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
90
91 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
92 back to...
93 <children_requested>: ... this.
94 (varobj_get_num_children, varobj_update): Adjust.
95
96 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
97
98 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
99 (ada_value_has_mutated): Likewise.
100 * c-varobj.c (varobj_is_anonymous_child): Likewise.
101 (c_is_path_expr_parent): Likewise.
102 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
103 (mi_cmd_var_set_frozen): Likewise.
104 (mi_cmd_var_update_iter): Likewise.
105 (mi_cmd_var_update): Likewise.
106 * varobj.c (pretty_printing): Likewise.
107 (varobj_enable_pretty_printing): Likewise.
108 (struct varobj_root) <floating, is_valid>: Likewise.
109 (struct varobj_dynamic) <children_requested>: Likewise.
110 (delete_variable): Likewise.
111 (delete_variable_1): Likewise.
112 (install_variable): Likewise.
113 (update_type_if_necessary): Likewise.
114 (install_new_value): Likewise.
115 (value_of_root): Likewise.
116 (is_root_p): Likewise.
117 (varobj_create): Likewise.
118 (varobj_delete): Likewise.
119 (varobj_has_more): Likewise.
120 (varobj_set_frozen): Likewise.
121 (varobj_get_frozen): Likewise.
122 (install_dynamic_child): Likewise.
123 (dynamic_varobj_has_child_method): Likewise.
124 (update_dynamic_varobj_children): Likewise.
125 (varobj_get_num_children): Likewise.
126 (varobj_list_children): Likewise.
127 (is_path_expr_parent): Likewise.
128 (varobj_default_is_path_expr_parent): Likewise.
129 (varobj_is_dynamic_p): Likewise.
130 (varobj_set_value): Likewise.
131 (varobj_value_has_mutated): Likewise.
132 (varobj_update): Likewise.
133 (check_scope): Likewise.
134 (value_of_root_1): Likewise.
135 (varobj_value_get_print_value): Likewise.
136 (varobj_editable_p): Likewise.
137 (varobj_value_is_changeable_p): Likewise.
138 (varobj_floating_p): Likewise.
139 (varobj_default_value_is_changeable_p): Likewise.
140 (varobj_invalidate_iter): Likewise.
141 * varobj.h (struct varobj_update_result) <type_changed,
142 children_changed, changed, value_installed>: Likewise.
143 (struct varobj) <updated, frozen, not_fetched>: Likewise.
144 (struct lang_varobj_ops) <value_is_changeable_p,
145 value_has_mutated, is_path_expr_parent>: Likewise.
146 (varobj_delete): Likewise.
147 (varobj_set_frozen): Likewise.
148 (varobj_get_frozen): Likewise.
149 (varobj_set_value): Likewise.
150 (varobj_update): Likewise.
151 (varobj_editable_p): Likewise.
152 (varobj_floating_p): Likewise.
153 (varobj_has_more): Likewise.
154 (varobj_is_dynamic_p): Likewise.
155 (varobj_default_value_is_changeable_p): Likewise.
156 (varobj_value_is_changeable_p): Likewise.
157 (varobj_is_anonymous_child): Likewise.
158 (varobj_default_is_path_expr_parent): Likewise.
159
160 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
161
162 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
163 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
164 <type_str>: Convert to 'std::string'.
165 <expr>: Convert to 'expression_up'.
166 (dtrace_probe_arg_s): Delete type and VEC.
167 (dtrace_probe_enabler_s): Likewise.
168 (struct dtrace_probe): Replace by...
169 (class dtrace_static_probe_ops): ...this and...
170 (class dtrace_probe): ...this.
171 (dtrace_probe_is_linespec): Rename to...
172 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
173 to reflect change.
174 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
175 Adjust code. Create new instance of 'dtrace_probe'.
176 (dtrace_build_arg_exprs): Rename to...
177 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
178 reflect change.
179 (dtrace_get_probes): Rename to...
180 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
181 to reflect change.
182 (dtrace_get_arg): Rename to...
183 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
184 reflect change.
185 (dtrace_probe_is_enabled): Rename to...
186 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
187 change.
188 (dtrace_get_probe_address): Rename to...
189 (dtrace_probe::get_relocated_address): ...this. Adjust code
190 to reflect change.
191 (dtrace_get_probe_argument_count): Rename to...
192 (dtrace_probe::get_argument_count): ...this. Adjust code to
193 reflect change.
194 (dtrace_can_evaluate_probe_arguments): Rename to...
195 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
196 to reflect change.
197 (dtrace_evaluate_probe_argument): Rename to...
198 (dtrace_probe::evaluate_argument): ...this. Adjust code to
199 reflect change.
200 (dtrace_compile_to_ax): Rename to...
201 (dtrace_probe::compile_to_ax): ...this. Adjust code to
202 reflect change.
203 (dtrace_probe_destroy): Delete.
204 (dtrace_type_name): Rename to...
205 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
206 reflect change.
207 (dtrace_probe::get_static_ops): New method.
208 (dtrace_gen_info_probes_table_header): Rename to...
209 (dtrace_static_probe_ops::gen_info_probes_table_header):
210 ...this. Adjust code to reflect change.
211 (dtrace_gen_info_probes_table_values): Rename to...
212 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
213 code to reflect change.
214 (dtrace_enable_probe): Rename to...
215 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
216 change.
217 (dtrace_disable_probe): Rename to...
218 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
219 change.
220 (struct probe_ops dtrace_probe_ops): Delete.
221 (info_probes_dtrace_command): Call 'info_probes_for_spops'
222 instead of 'info_probes_for_ops'.
223 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
224 of 'all_probe_ops'.
225
226 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
227 Simon Marchi <simark@simark.ca>
228
229 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
230 variable.
231 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
232 <aexpr>: Change type to 'expression_up'.
233 (stap_probe_arg_s): Delete type and VEC.
234 (struct stap_probe): Delete. Replace by...
235 (class stap_static_probe_ops): ...this and...
236 (class stap_probe): ...this. Rename variables to add 'm_'
237 prefix. Do not use 'union' for arguments anymore.
238 (stap_get_expected_argument_type): Receive probe name instead
239 of 'struct stap_probe'. Adjust code.
240 (stap_parse_probe_arguments): Rename to...
241 (stap_probe::parse_arguments): ...this. Adjust code to
242 reflect change.
243 (stap_get_probe_address): Rename to...
244 (stap_probe::get_relocated_address): ...this. Adjust code
245 to reflect change.
246 (stap_get_probe_argument_count): Rename to...
247 (stap_probe::get_argument_count): ...this. Adjust code
248 to reflect change.
249 (stap_get_arg): Rename to...
250 (stap_probe::get_arg_by_number'): ...this. Adjust code to
251 reflect change.
252 (can_evaluate_probe_arguments): Rename to...
253 (stap_probe::can_evaluate_arguments): ...this. Adjust code
254 to reflect change.
255 (stap_evaluate_probe_argument): Rename to...
256 (stap_probe::evaluate_argument): ...this. Adjust code
257 to reflect change.
258 (stap_compile_to_ax): Rename to...
259 (stap_probe::compile_to_ax): ...this. Adjust code to
260 reflect change.
261 (stap_probe_destroy): Delete.
262 (stap_modify_semaphore): Adjust comment.
263 (stap_set_semaphore): Rename to...
264 (stap_probe::set_semaphore): ...this. Adjust code to reflect
265 change.
266 (stap_clear_semaphore): Rename to...
267 (stap_probe::clear_semaphore): ...this. Adjust code to
268 reflect change.
269 (stap_probe::get_static_ops): New method.
270 (handle_stap_probe): Adjust code to create instance of
271 'stap_probe'.
272 (stap_get_probes): Rename to...
273 (stap_static_probe_ops::get_probes): ...this. Adjust code to
274 reflect change.
275 (stap_probe_is_linespec): Rename to...
276 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
277 reflect change.
278 (stap_type_name): Rename to...
279 (stap_static_probe_ops::type_name): ...this. Adjust code to
280 reflect change.
281 (stap_gen_info_probes_table_header): Rename to...
282 (stap_static_probe_ops::gen_info_probes_table_header):
283 ...this. Adjust code to reflect change.
284 (stap_gen_info_probes_table_values): Rename to...
285 (stap_probe::gen_info_probes_table_values): ...this. Adjust
286 code to reflect change.
287 (struct probe_ops stap_probe_ops): Delete.
288 (info_probes_stap_command): Use 'info_probes_for_spops'
289 instead of 'info_probes_for_ops'.
290 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
291 of 'all_probe_ops'.
292
293 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
294
295 * break-catch-throw.c (fetch_probe_arguments): Use
296 'probe.prob' instead of 'probe.probe'.
297 * breakpoint.c (create_longjmp_master_breakpoint): Call
298 'can_evaluate_arguments' and 'get_relocated_address' methods
299 from probe.
300 (create_exception_master_breakpoint): Likewise.
301 (add_location_to_breakpoint): Use 'sal->prob' instead of
302 'sal->probe'.
303 (bkpt_probe_insert_location): Call 'set_semaphore' method from
304 probe.
305 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
306 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
307 of 'probe_ops'.
308 (probe_key_free): Call 'delete' on probe.
309 (check_exception_resume): Use 'probe.prob' instead of
310 'probe.probe'.
311 * location.c (string_to_event_location_basic): Call
312 'probe_linespec_to_static_ops'.
313 * probe.c (class any_static_probe_ops): New class.
314 (any_static_probe_ops any_static_probe_ops): New variable.
315 (parse_probes_in_pspace): Receive 'static_probe_ops' as
316 argument. Adjust code to reflect change.
317 (parse_probes): Use 'static_probe_ops' instead of
318 'probe_ops'. Adjust code to reflect change.
319 (find_probes_in_objfile): Call methods to get name and
320 provider from probe.
321 (find_probe_by_pc): Use 'result.prob' instead of
322 'result.probe'. Call 'get_relocated_address' method from
323 probe.
324 (collect_probes): Adjust comment and argument list to receive
325 'static_probe_ops' instead of 'probe_ops'. Adjust code to
326 reflect change. Call necessary methods from probe.
327 (compare_probes): Call methods to get name and provider from
328 probes.
329 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
330 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
331 adjust code accordingly.
332 (print_ui_out_not_applicables): Likewise.
333 (info_probes_for_ops): Rename to...
334 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
335 as argument instead of 'probe_ops'. Adjust code. Call
336 necessary methods from probe.
337 (info_probes_command): Use 'info_probes_for_spops'.
338 (enable_probes_command): Pass correct argument to
339 'collect_probes'. Call methods from probe.
340 (disable_probes_command): Likewise.
341 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
342 (get_probe_argument_count): Move to
343 'any_static_probe_ops::get_argument_count'.
344 (can_evaluate_probe_arguments): Move to
345 'any_static_probe_ops::can_evaluate_arguments'.
346 (evaluate_probe_argument): Move to
347 'any_static_probe_ops::evaluate_argument'.
348 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
349 'probe.probe'.
350 (probe_linespec_to_ops): Rename to...
351 (probe_linespec_to_static_ops): ...this. Adjust code.
352 (probe_any_is_linespec): Rename to...
353 (any_static_probe_ops::is_linespec): ...this.
354 (probe_any_get_probes): Rename to...
355 (any_static_probe_ops::get_probes): ...this.
356 (any_static_probe_ops::type_name): New method.
357 (any_static_probe_ops::gen_info_probes_table_header): New
358 method.
359 (compute_probe_arg): Use 'pc_probe.prob' instead of
360 'pc_probe.probe'. Call methods from probe.
361 (compile_probe_arg): Likewise.
362 (std::vector<const probe_ops *> all_probe_ops): Delete.
363 (std::vector<const static_probe_ops *> all_static_probe_ops):
364 New variable.
365 (_initialize_probe): Use 'all_static_probe_ops' instead of
366 'all_probe_ops'.
367 * probe.h (struct info_probe_column) <field_name>: Delete
368 extraneous newline
369 (info_probe_column_s): Delete type and VEC.
370 (struct probe_ops): Delete. Replace with...
371 (class static_probe_ops): ...this and...
372 (clas probe): ...this.
373 (struct bound_probe) <bound_probe>: Delete extraneous
374 newline. Adjust constructor to receive 'probe' instead of
375 'struct probe'.
376 <probe>: Rename to...
377 <prob>: ...this. Delete extraneous newline.
378 <objfile>: Delete extraneous newline.
379 (register_probe_ops): Delete unused prototype.
380 (info_probes_for_ops): Rename to...
381 (info_probes_for_spops): ...this. Adjust comment.
382 (get_probe_address): Move to 'probe::get_address'.
383 (get_probe_argument_count): Move to
384 'probe::get_argument_count'.
385 (can_evaluate_probe_arguments): Move to
386 'probe::can_evaluate_arguments'.
387 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
388 * solib-svr4.c (struct svr4_info): Adjust comment.
389 (struct probe_and_action) <probe>: Rename to...
390 <prob>: ...this.
391 (register_solib_event_probe): Receive 'probe' instead of
392 'struct probe' as argument. Use 'prob' instead of 'probe'
393 when applicable.
394 (solib_event_probe_action): Call 'get_argument_count' method
395 from probe. Adjust comment.
396 (svr4_handle_solib_event): Adjust comment. Call
397 'evaluate_argument' method from probe.
398 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
399 from probe.
400 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
401 'struct probe'. Call 'can_evaluate_arguments' from probe.
402 * symfile.h: Forward declare 'class probe' instead of 'struct
403 probe'.
404 * symtab.h: Likewise.
405 (struct symtab_and_line) <probe>: Rename to...
406 <prob>: ...this.
407 * tracepoint.c (start_tracing): Use 'prob' when applicable.
408 Call probe methods.
409 (stop_tracing): Likewise.
410
411 2017-11-22 Joel Brobecker <brobecker@adacore.com>
412
413 * ravenscar-thread.c (ravenscar_inferior_created): Remove
414 trailing newline at end of string in call to warning.
415
416 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
417
418 * osdata.h: Include vector isntead of vec.h.
419 (osdata_column_s): Remove typedef.
420 (struct osdata_column): Add constructor.
421 <name, value>: Change type to std::string.
422 (DEF_VEC_O (osdata_column_s)): Remove.
423 (osdata_item_s): Remove typedef.
424 (struct osdata_item) <columns>: Change type to std::vector.
425 (DEF_VEC_O (osdata_item_s)): Remove.
426 (struct osdata): Add constructor.
427 <type>: Change type to std::string.
428 <items>: Change type to std::vector.
429 (osdata_p): Remove typedef.
430 (DEF_VEC_P (osdata_p)): Remove.
431 (osdata_parse): Return a unique_ptr.
432 (osdata_free): Remove.
433 (make_cleanup_osdata_free): Remove.
434 (get_osdata): Return a unique_ptr.
435 (get_osdata_column): Return pointer to std::string, take a
436 reference to osdata_item as parameter.
437 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
438 unique_ptr.
439 <property_name>: Change type to std::string.
440 (osdata_start_osdata): Allocate osdata with new and adjust.
441 (osdata_start_item): Adjust.
442 (osdata_start_column): Adjust.
443 (osdata_end_column): Adjust.
444 (clear_parsing_data): Remove.
445 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
446 (osdata_item_clear): Remove.
447 (get_osdata): return a unique_ptr and adjust.
448 (get_osdata_column): Return a pointer to std::string and adjust.
449 (info_osdata): Adjust.
450 * mi/mi-main.c: Include <map>.
451 (free_vector_of_osdata_items): Remove.
452 (list_available_thread_groups): Adjust, use std::map instead of
453 splay tree.
454
455 2017-11-22 Simon Marchi <simon.marchi@ericsson.com>
456
457 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
458 case in switch.
459
460 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
461
462 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
463
464 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
465
466 * varobj.h (struct varobj_update_result): Add constructor, add
467 move constructor, disable copy and assign, initialize fields.
468 <newobj>: Change type to std::vector.
469 (varobj_update): Return std::vector.
470 * varobj.c (install_dynamic_child): Change VEC parameters to
471 std::vector and adjust.
472 (update_dynamic_varobj_children): Likewise.
473 (varobj_update): Return std::vector and adjust.
474 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
475
476 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
477
478 * varobj.h (struct varobj) <parent>: Remove const.
479 <children>: Change type to std::vector.
480 (varobj_list_children): Return std::vector const reference.
481 (varobj_restrict_range): Change parameter type to std::vector
482 const reference.
483 * varobj.c (varobj_has_more): Adjust.
484 (varobj_restrict_range): Change parameter type to std::vector
485 const reference and adjust.
486 (install_dynamic_child): Adjust.
487 (update_dynamic_varobj_children): Adjust.
488 (varobj_list_children): Return std::vector const reference and
489 adjust.
490 (varobj_add_child): Adjust.
491 (update_type_if_necessary): Adjust.
492 (varobj_update): Adjust.
493 (delete_variable_1): Adjust.
494 * ada-varobj.c (ada_value_has_mutated): Adjust.
495 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
496
497 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
498
499 * varobj.h (struct varobj): Add constructor and destructor,
500 initialize fields.
501 * varobj.c (struct varobj_root): Initialize fields.
502 (struct varobj_dynamic): Initialize fields.
503 (varobj_create): Use unique_ptr instead of cleanup. Create
504 varobj with new instead of new_root_variable.
505 (delete_variable_1): Free variable with delete instead of
506 free_variable.
507 (create_child_with_value): Create variable with new instead of
508 new_variable.
509 (varobj::varobj): New.
510 (varobj::~varobj): New (body mostly coming from free_variable).
511 (new_variable): Remove.
512 (free_variable): Remove.
513 (do_free_variable_cleanup): Remove.
514 (make_cleanup_free_variable): Remove.
515
516 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
517
518 * core-regset.c: Remove file.
519 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
520
521 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
522
523 * NEWS: Document use of GNU MPFR.
524 * README: Likewise.
525
526 * Makefile.in (LIBMPFR): Add define.
527 (CLIBS): Add $(LIBMPFR).
528 * configure.ac: Add --with-mpfr configure option.
529 * configure: Regenerate.
530 * config.in: Regenerate.
531
532 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
533 (class mpfr_float_ops): New type.
534 (mpfr_float_ops::from_target): Two new overloaded functions.
535 (mpfr_float_ops::to_target): Likewise.
536 (mpfr_float_ops::to_string): New function.
537 (mpfr_float_ops::from_string): Likewise.
538 (mpfr_float_ops::to_longest): Likewise.
539 (mpfr_float_ops::from_longest): Likewise.
540 (mpfr_float_ops::from_ulongest): Likewise.
541 (mpfr_float_ops::to_host_double): Likewise.
542 (mpfr_float_ops::from_host_double): Likewise.
543 (mpfr_float_ops::convert): Likewise.
544 (mpfr_float_ops::binop): Likewise.
545 (mpfr_float_ops::compare): Likewise.
546 (get_target_float_ops): Use mpfr_float_ops if available.
547
548 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
549
550 * target-float.c: Do not include <math.h>.
551 Include <cmath> and <limits>.
552 (DOUBLEST): Do not define.
553 (class target_float_ops): New type.
554 (class host_float_ops): New templated type.
555 (class decimal_float_ops): New type.
556
557 (floatformat_to_doublest): Rename to ...
558 (host_float_ops<T>::from_target): ... this. Use template type T
559 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
560 (host_float_ops<T>::from_target): New overload using a type argument.
561 (floatformat_from_doublest): Rename to ...
562 (host_float_ops<T>::to_target): ... this. Use template type T
563 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
564 (host_float_ops<T>::to_target): New overload using a type argument.
565 (floatformat_printf_format): New function.
566 (struct printf_length_modifier): New templated type.
567 (floatformat_to_string): Rename to ...
568 (host_float_ops<T>::to_string): ... this. Use type instead of
569 floatformat argument. Use floatformat_printf_format and
570 printf_length_modifier. Remove special handling of invalid numbers,
571 infinities and NaN (moved to target_float_to_string).
572 (struct scanf_length_modifier): New templated type.
573 (floatformat_from_string): Rename to ...
574 (host_float_ops<T>::from_string): ... this. Use type instead of
575 floatformat argument. Use scanf_length_modifier.
576 (floatformat_to_longest): Rename to ...
577 (host_float_ops<T>::to_longest): ... this. Use type instead of
578 floatformat argument. Handle out-of-range values deterministically.
579 (floatformat_from_longest): Rename to ...
580 (host_float_ops<T>::from_longest): ... this. Use type instead of
581 floatformat argument.
582 (floatformat_from_ulongest): Rename to ...
583 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
584 floatformat argument.
585 (floatformat_to_host_double): Rename to ...
586 (host_float_ops<T>::to_host_double): ... this. Use type instead of
587 floatformat argument.
588 (floatformat_from_host_double): Rename to ...
589 (host_float_ops<T>::from_host_double): ... this. Use type instead of
590 floatformat argument.
591 (floatformat_convert): Rename to ...
592 (host_float_ops<T>::convert): ... this. Use type instead of
593 floatformat arguments. Remove handling of no-op conversions.
594 (floatformat_binop): Rename to ...
595 (host_float_ops<T>::binop): ... this. Use type instead of
596 floatformat arguments.
597 (floatformat_compare): Rename to ...
598 (host_float_ops<T>::compare): ... this. Use type instead of
599 floatformat arguments.
600
601 (match_endianness): Use type instead of length/byte_order arguments.
602 (set_decnumber_context): Likewise.
603 (decimal_from_number): Likewise. Update calls.
604 (decimal_to_number): Likewise.
605 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
606 (decimal_float_ops::to_host_double): New dummy function.
607 (decimal_float_ops::from_host_double): Likewise.
608 (decimal_to_string): Rename to ...
609 (decimal_float_ops::to_string): ... this. Use type instead of
610 length/byte_order arguments. Update calls.
611 (decimal_from_string): Rename to ...
612 (decimal_float_ops::from_string): ... this. Use type instead of
613 length/byte_order arguments. Update calls.
614 (decimal_from_longest): Rename to ...
615 (decimal_float_ops::from_longest): ... this. Use type instead of
616 length/byte_order arguments. Update calls.
617 (decimal_from_ulongest): Rename to ...
618 (decimal_float_ops::from_ulongest): ... this. Use type instead of
619 length/byte_order arguments. Update calls.
620 (decimal_to_longest): Rename to ...
621 (decimal_float_ops::to_longest): ... this. Use type instead of
622 length/byte_order arguments. Update calls.
623 (decimal_binop): Rename to ...
624 (decimal_float_ops::binop): ... this. Use type instead of
625 length/byte_order arguments. Update calls.
626 (decimal_compare): Rename to ...
627 (decimal_float_ops::compare): ... this. Use type instead of
628 length/byte_order arguments. Update calls.
629 (decimal_convert): Rename to ...
630 (decimal_float_ops::convert): ... this. Use type instead of
631 length/byte_order arguments. Update calls.
632
633 (target_float_same_category_p): New function.
634 (target_float_same_format_p): Likewise.
635 (target_float_format_length): Likewise.
636 (enum target_float_ops_kind): New type.
637 (get_target_float_ops_kind): New function.
638 (get_target_float_ops): Three new overloaded functions.
639
640 (target_float_is_zero): Update call.
641 (target_float_to_string): Add special handling of invalid numbers,
642 infinities and NaN (moved from floatformat_to_string). Use
643 target_float_ops callback.
644 (target_float_from_string): Use target_float_ops callback.
645 (target_float_to_longest): Likewise.
646 (target_float_from_longest): Likewise.
647 (target_float_from_ulongest): Likewise.
648 (target_float_to_host_double): Likewise.
649 (target_float_from_host_double): Likewise.
650 (target_float_convert): Add special case for no-op conversions.
651 Use target_float_ops callback.
652 (target_float_binop): Use target_float_ops callback.
653 (target_float_compare): Likewise.
654
655 2017-11-22 Yao Qi <yao.qi@linaro.org>
656
657 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
658
659 2017-11-22 Yao Qi <yao.qi@linaro.org>
660
661 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
662 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
663
664 2017-11-21 Jerome Guitton <guitton@adacore.com>
665
666 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
667 with event ptid from the lower layer before doing the
668 ravenscar-specific update.
669
670 2017-11-21 Joel Brobecker <brobecker@adacore.com>
671
672 * ravenscar-thread.c (is_ravenscar_task): Also verify that
673 the ptid's TID is nonzero.
674
675 2017-11-21 Joel Brobecker <brobecker@adacore.com>
676
677 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
678 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
679 Make non-static. Change return type to char *. Adjust code
680 accordingly. Rewrite the function's documentation.
681 (read_atcb): Adjust call to get_tcb_types_info accordingly.
682 * ravenscar-thread.c (ravenscar_inferior_created): Check that
683 we have enough debugging information in the runtime to support
684 Ada task debugging before we enable the ravenscar-thread layer.
685
686 2017-11-21 Joel Brobecker <brobecker@adacore.com>
687
688 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
689 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
690 * ravenscar-thread.c: Add into comment.
691 (base_magic_null_ptid): Delete.
692 (base_ptid): Change documentation.
693 (ravenscar_active_task): Renames ravenscar_running_thread.
694 All callers updated throughout.
695 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
696 (ravenscar_task_is_currently_active): Likewise.
697 (get_base_thread_from_ravenscar_task): Ditto.
698 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
699 (ravenscar_runtime_initialized): Likewise.
700 (get_running_thread_id): Add new parameter "cpu". Adjust
701 implementation to handle this new parameter.
702 (ravenscar_fetch_registers): Small adjustment to use
703 is_ravenscar_task and ravenscar_task_is_currently_active in
704 order to decide whether to use the target beneath or this
705 module's arch_ops.
706 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
707 (ravenscar_stopped_by_sw_breakpoint): Use
708 get_base_thread_from_ravenscar_task to get the underlying
709 thread, rather than using base_ptid.
710 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
711 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
712 Likewise.
713 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
714
715 2017-11-21 Joel Brobecker <brobecker@adacore.com>
716
717 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
718 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
719 (get_tcb_types_info): Set fieldnos.base_cpu.
720 (read_atcb): Set task_info->base_cpu.
721 (info_task): Print "Base CPU" info if set by runtime.
722
723 2017-11-21 Joel Brobecker <brobecker@adacore.com>
724
725 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
726 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
727 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
728 New functions.
729 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
730 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
731 to_stopped_data_address and to_core_of_thread fields of
732 ravenscar_ops.
733
734 2017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
735
736 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
737 (struct gdbarch_tdep): New member long_double_abi.
738 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
739 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
740 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
741 format depending on long_double_abi tdep member.
742 (ppc_floatformat_for_type): Handle __ibm128 type.
743
744 2017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
745
746 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
747
748 2017-11-21 Pedro Alves <palves@redhat.com>
749
750 * dwarf2read.c (mapped_index::find_name_components_bounds)
751 <completion mode, upper bound>: Use std::lower_bound instead of
752 std::upper_bound.
753 (test_mapped_index_find_name_component_bounds): Remove incorrect
754 "t1_fund" from expected symbols.
755
756 2017-11-21 Pedro Alves <palves@redhat.com>
757
758 * dwarf2read.c (mapped_index::name_components_casing): New field.
759 (mapped_index) <build_name_components,
760 find_name_components_bounds): Declare new methods.
761 (mapped_index::find_name_components_bounds)
762 (mapped_index::build_name_components): New methods, factored out
763 from dw2_expand_symtabs_matching_symbol.
764 (check_find_bounds_finds)
765 (test_mapped_index_find_name_component_bounds): New.
766 (run_test): Rename to ...
767 (test_dw2_expand_symtabs_matching_symbol): ... this.
768 (run_test): Reimplement.
769
770 2017-11-21 Pedro Alves <palves@redhat.com>
771
772 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
773 (symbol_end): Use cp_ident_is_alnum.
774 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
775 * dwarf2read.c (make_sort_after_prefix_name): New function.
776 (dw2_expand_symtabs_matching_symbol): Use it.
777 (test_symbols): Add more symbols.
778 (run_test): Add tests.
779
780 2017-11-17 Tom Tromey <tom@tromey.com>
781
782 * symtab.h (enum symbol_subclass_kind): New.
783 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
784 Remove.
785 <subclass>: New member.
786 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
787 * rust-lang.c (rust_get_trait_object_pointer): Update.
788 * dwarf2read.c (read_func_scope): Update.
789 (read_variable): Update.
790
791 2017-11-17 Tom Tromey <tom@tromey.com>
792
793 * dwarf2read.c (read_func_scope): Update.
794 * symtab.h (struct template_symbol): Derive from symbol.
795 <base>: Remove.
796
797 2017-11-17 Tom Tromey <tom@tromey.com>
798
799 * symtab.h (struct symbol) <is_rust_vtable>: New member.
800 (struct rust_vtable_symbol): New.
801 (find_symbol_at_address): Declare.
802 * symtab.c (find_symbol_at_address): New function.
803 * symfile.h (struct quick_symbol_functions)
804 <find_compunit_symtab_by_address>: New member.
805 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
806 function.
807 (debug_sym_quick_functions): Link to
808 debug_qf_find_compunit_symtab_by_address.
809 * rust-lang.c (rust_get_trait_object_pointer): New function.
810 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
811 rust_get_trait_object_pointer.
812 * psymtab.c (psym_relocate): Clear psymbol_map.
813 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
814 functions.
815 (psym_functions): Link to psym_find_compunit_symtab_by_address.
816 * objfiles.h (struct objfile) <psymbol_map>: New member.
817 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
818 (process_die) <DW_TAG_variable>: New case. Call read_variable.
819 (rust_containing_type, read_variable): New functions.
820
821 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
822
823 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
824
825 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
826
827 * common/filestuff.c: Include <algorithm>.
828 (open_fds): Change type to std::vector<int>.
829 (do_mark_open_fd): Adjust.
830 (unmark_fd_no_cloexec): Adjust.
831 (do_close): Adjust.
832
833 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
834
835 * breakpoint.c (output_thread_groups): Take an std::vector.
836 (print_one_breakpoint_location): Adjust.
837
838 2017-11-17 Joel Brobecker <brobecker@adacore.com>
839
840 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
841 (ada_evaluate_subexp_for_cast): New function.
842 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
843 ada_evaluate_subexp_for_cast.
844 (ada_evaluate_subexp) <nosideret>: Replace code by call to
845 eval_skip_value.
846 * eval.c (evaluate_var_value): Make non-static.
847 (evaluate_var_msym_value, eval_skip_value): Likewise.
848 * value.h (evaluate_var_value, evaluate_var_msym_value)
849 (eval_skip_value): Declare.
850
851 2017-11-16 Joel Brobecker <brobecker@adacore.com>
852
853 * ada-lang.c (ada_value_cast): Remove parameter "noside".
854 Update all callers.
855
856 2017-11-16 Pedro Alves <palves@redhat.com>
857
858 * python/py-unwind.c (pyuw_sniffer): Translate
859 PyExc_KeyboardInterrupt to a GDB Quit exception.
860
861 2017-11-16 Pedro Alves <palves@redhat.com>
862
863 * infrun.c (resume_cleanups): Delete.
864 (resume): No longer install a resume_cleanups cleanup nor call
865 QUIT.
866 (proceed): Pass the terminal to the inferior.
867 (keep_going_pass_signal): No longer install a resume_cleanups
868 cleanup.
869
870 2017-11-16 Pedro Alves <palves@redhat.com>
871
872 * inf-loop.c (inferior_event_handler): Don't swallow the exception
873 if the prompt is blocked.
874
875 2017-11-16 Pedro Alves <palves@redhat.com>
876
877 * breakpoint.c (insert_bp_location): Replace bp_err and
878 bp_err_message locals by a gdb_exception local.
879
880 2017-11-16 Pedro Alves <palves@redhat.com>
881
882 * inflow.c (scoped_ignore_sigttou): New class.
883 (child_terminal_ours_1, new_tty): Use it.
884
885 2017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
886
887 * target-float.c (decimal_from_number): Add byte_order argument and
888 call match_endianness. Error if unknown floating-point type.
889 (decimal_to_number): Add byte_order argument and call match_endianness.
890 (decimal_from_longest): Update call. Do not call match_endianness.
891 (decimal_from_ulongest): Likewise.
892 (decimal_binop): Likewise.
893 (decimal_is_zero): Likewise.
894 (decimal_compare): Likewise.
895 (decimal_convert): Likewise.
896
897 2017-11-16 Phil Muldoon <pmuldoon@redhat.com>
898
899 * python/python.c (gdbpy_rbreak): New function.
900 * NEWS: Document Python rbreak feature.
901
902 2017-11-16 Yao Qi <yao.qi@linaro.org>
903
904 * features/tic6x-c62x.xml: Remove.
905 * features/tic6x-c64x.xml: Remove.
906 * features/tic6x-c64xp.xml: Remove.
907
908 2017-11-15 John Baldwin <jhb@FreeBSD.org>
909
910 * symtab.h: Include <array>.
911
912 2017-11-15 John Baldwin <jhb@FreeBSD.org>
913
914 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
915 (bsd_kvm_proc_cmd): Likewise.
916
917 2017-11-15 Simon Marchi <simon.marchi@ericsson.com>
918
919 * tui/tui-win.c (window_name_completer): Replace VEC with
920 std::vector.
921
922 2017-11-15 Andrew Cagney <cagney@gnu.org>
923
924 * MAINTAINERS: Remove no-longer applicable entries.
925
926 2017-11-15 Andrew Cagney <cagney@gnu.org>
927
928 * MAINTAINERS: Move self to Past Maintainers.
929
930 2017-11-15 Yao Qi <yao.qi@linaro.org>
931
932 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
933 * features/nios2-linux.c: Remove.
934 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
935 initialize_tdesc_nios2_linux.
936
937 2017-11-15 Yao Qi <yao.qi@linaro.org>
938
939 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
940 M68HC11_LAST_HARD_REG + 1.
941
942 2017-11-14 Paul Carroll <pcarroll@codesourcery.com>
943
944 PR gdb/22388
945 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
946 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
947 Return TARGET_XFER_EOF if size of returned data is 0.
948
949 2017-11-14 Simon Marchi <simon.marchi@ericsson.com>
950
951 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
952 memory-map-selftests.c.
953 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
954 * memory-map.c (memory_map_start_memory): Fix computation of hi
955 address.
956 * unittests/memory-map-selftests.c: New file.
957
958 2017-11-09 Joel Brobecker <brobecker@adacore.com>
959
960 * ada-lang.c: Fix some typos in the general command documenting
961 how Ada expressions are being evaluated and how their result
962 is printed.
963
964 2017-11-09 Tom Tromey <tom@tromey.com>
965
966 * psymtab.c (psymbol_hash): Do not hash string contents.
967 (psymbol_compare): Add comment.
968
969 2017-11-09 Tom Tromey <tom@tromey.com>
970
971 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
972
973 2017-11-08 Joel Brobecker <brobecker@adacore.com>
974
975 * ada-exp.y (write_var_from_sym): Remove parameter
976 "orig_left_context". Update all callers.
977
978 2017-11-08 Simon Marchi <simon.marchi@ericsson.com>
979
980 * tracepoint.h (class collection_list) <stringify>: Return
981 std::vector<std::string>.
982 (encode_actions_rsp): Change parameters to
983 std::vector<std::string> *.
984 * tracepoint.c (collection_list::stringify): Return
985 std::vector<std::string> and adjust accordingly.
986 (encode_actions_rsp): Changee parameters to
987 std::vector<std::string> and adjust accordingly.
988 * remote.c (free_actions_list),
989 free_actions_list_cleanup_wrapper): Remove.
990 (remote_download_tracepoint): Adjust to std::vector.
991
992 2017-11-08 Tom Tromey <tom@tromey.com>
993
994 * dwarf2read.c (symbolp): Remove typedef.
995 (read_func_scope): Use std::vector.
996 (process_structure_scope): Use std::vector.
997
998 2017-11-08 Pedro Alves <palves@redhat.com>
999
1000 * ada-lang.c (ada_make_symbol_completion_list): Use
1001 completion_skip_symbol.
1002 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
1003 (symbol_is_function_or_method(symbol*)): New.
1004 (add_symtab_completions): Add complete_symbol_mode parameter. Use
1005 completion_skip_symbol.
1006 (default_collect_symbol_completion_matches_break_on): Use
1007 completion_skip_symbol. Pass down mode.
1008 (collect_file_symbol_completion_matches): Pass down mode.
1009 * symtab.h (symbol_is_function_or_method): New declarations.
1010 (completion_skip_symbol): New template function.
1011
1012 2017-11-08 Pedro Alves <palves@redhat.com>
1013
1014 * linespec.c (iterate_over_all_matching_symtabs): Add
1015 search_domain parameter. Pass it down to expand_symtabs_matching.
1016 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
1017 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
1018 search_domain.
1019 (add_all_symbol_names_from_pspace): Add search_domain parameter.
1020 Pass it down.
1021 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
1022 symbols.
1023 (add_matching_symbols_to_info): Add search_domain parameter. Pass
1024 it down.
1025
1026 2017-11-08 Pedro Alves <palves@redhat.com>
1027
1028 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
1029 text_len locals and don't pass them down.
1030 * symtab.c (completion_list_add_name): Remove
1031 sym_text/sym_text_len parameters and adjust.
1032 (completion_list_add_symbol, completion_list_add_msymbol)
1033 (completion_list_objc_symbol, completion_list_add_fields)
1034 (add_symtab_completions): Likewise.
1035 (default_collect_symbol_completion_matches_break_on)
1036 (collect_file_symbol_completion_matches): Remove sym_text_len
1037 local and don't pass it down.
1038 * symtab.h (completion_list_add_name): Remove
1039 sym_text/sym_text_len parameters.
1040
1041 2017-11-08 Pedro Alves <palves@redhat.com>
1042
1043 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1044 unittests/lookup_name_info-selftests.c.
1045 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
1046 * cp-support.c: Include "selftest.h".
1047 (cp_remove_params_1): Rename from cp_remove_params. Add
1048 'require_param' parameter, and handle it.
1049 (cp_remove_params): Reimplement.
1050 (cp_remove_params_if_any): New.
1051 (selftests::quote): New.
1052 (selftests::check_remove_params): New.
1053 (selftests::test_cp_remove_params): New.
1054 (_initialize_cp_support): Install
1055 selftests::test_cp_remove_params.
1056 * cp-support.h (cp_remove_params_if_any): Declare.
1057 * dwarf2read.c :Include "selftest.h".
1058 (dw2_expand_symtabs_matching_symbol): Use
1059 lookup_name_info::make_ignore_params.
1060 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
1061 (selftests::dw2_expand_symtabs_matching::string_or_null)
1062 (selftests::dw2_expand_symtabs_matching::check_match)
1063 (selftests::dw2_expand_symtabs_matching::test_symbols)
1064 (selftests::dw2_expand_symtabs_matching::run_test): New.
1065 (_initialize_dwarf2_read): Register
1066 selftests::dw2_expand_symtabs_matching::run_test.
1067 * psymtab.c (psym_expand_symtabs_matching): Use
1068 lookup_name_info::make_ignore_params.
1069 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
1070 If the lookup name wants to ignore parameters, strip them.
1071 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
1072 code handling '('.
1073 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
1074 (default_collect_symbol_completion_matches_break_on): Don't try to
1075 strip parameters.
1076 * symtab.h (lookup_name_info::lookup_name_info): Add
1077 'ignore_parameters' parameter.
1078 (lookup_name_info::ignore_parameters)
1079 (lookup_name_info::make_ignore_params): New methods.
1080 (lookup_name_info::m_ignore_parameters): New field.
1081 * unittests/lookup_name_info-selftests.c: New file.
1082
1083 2017-11-08 Pedro Alves <palves@redhat.com>
1084
1085 * dwarf2read.c (dw2_expand_marked_cus)
1086 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
1087 (dw2_expand_symtabs_matching): Move further below.
1088 (dw2_expand_marked_cus): Reindent.
1089
1090 2017-11-08 Pedro Alves <palves@redhat.com>
1091
1092 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
1093 (struct name_component): New.
1094 (mapped_index::name_components): New field.
1095 (mapped_index::symbol_name_at): New method.
1096 (dwarf2_read_index): Call mapped_index ctor.
1097 (dw2_map_matching_symbols): Add comment about name_components
1098 table.
1099 (dw2_expand_symtabs_matching): Factor part to...
1100 (dw2_expand_symtabs_matching_symbol): ... this new function.
1101 Build name components table, and lookup symbols in it before
1102 calling the name matcher.
1103 (dw2_expand_marked_cus): New, factored out from
1104 dw2_expand_symtabs_matching.
1105 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
1106
1107 2017-11-08 Pedro Alves <palves@redhat.com>
1108
1109 * ada-lang.c (ada_encode): Rename to ..
1110 (ada_encode_1): ... this. Add throw_errors parameter and handle
1111 it.
1112 (ada_encode): Reimplement.
1113 (match_name): Delete, folded into full_name.
1114 (resolve_subexp): No longer pass the encoded name to
1115 ada_lookup_symbol_list.
1116 (should_use_wild_match): Delete.
1117 (name_match_type_from_name): New.
1118 (ada_lookup_simple_minsym): Use lookup_name_info and the
1119 language's symbol_name_matcher_ftype.
1120 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
1121 (ada_add_block_renamings): Adjust to use lookup_name_info.
1122 (ada_lookup_name): New.
1123 (add_nonlocal_symbols, ada_add_all_symbols)
1124 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
1125 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
1126 (ada_name_for_lookup): Delete.
1127 (ada_lookup_encoded_symbol): Construct a verbatim name.
1128 (wild_match): Reverse sense of return type. Use bool.
1129 (full_match): Reverse sense of return type. Inline bits of old
1130 match_name here.
1131 (ada_add_block_symbols): Adjust to use lookup_name_info.
1132 (symbol_completion_match): Delete, folded into...
1133 (ada_lookup_name_info::matches): ... .this new method.
1134 (symbol_completion_add): Delete.
1135 (ada_collect_symbol_completion_matches): Add name_match_type
1136 parameter. Adjust to use lookup_name_info and
1137 completion_list_add_name.
1138 (get_var_value, ada_add_global_exceptions): Adjust to use
1139 lookup_name_info.
1140 (ada_get_symbol_name_cmp): Delete.
1141 (do_wild_match, do_full_match): New functions.
1142 (ada_lookup_name_info::ada_lookup_name_info): New method.
1143 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
1144 functions.
1145 (ada_language_defn): Install ada_get_symbol_name_matcher.
1146 * ada-lex.l (processId): If name starts with '<', copy it
1147 verbatim.
1148 * block.c (block_iter_match_step, block_iter_match_first)
1149 (block_iter_match_next, block_lookup_symbol)
1150 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
1151 lookup_name_info.
1152 * block.h (block_iter_match_first, block_iter_match_next)
1153 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
1154 * c-lang.c (c_language_defn, cplus_language_defn)
1155 (asm_language_defn, minimal_language_defn): Adjust comments to
1156 refer to la_get_symbol_name_matcher.
1157 * completer.c (complete_files_symbols)
1158 (collect_explicit_location_matches, symbol_completer): Pass a
1159 symbol_name_match_type down.
1160 * completer.h (class completion_match, completion_match_result):
1161 New classes.
1162 (completion_tracker::reset_completion_match_result): New method.
1163 (completion_tracker::m_completion_match_result): New field.
1164 * cp-support.c (make_symbol_overload_list_block): Adjust to use
1165 lookup_name_info.
1166 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
1167 functions.
1168 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
1169 * d-lang.c: Adjust comments to refer to
1170 la_get_symbol_name_matcher.
1171 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
1172 Adjust to use lookup_name_info.
1173 (dict_iter_match_first, dict_iter_match_next)
1174 (iter_match_first_hashed, iter_match_next_hashed)
1175 (iter_match_first_linear, iter_match_next_linear): Adjust to work
1176 with a lookup_name_info.
1177 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
1178 Likewise.
1179 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
1180 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
1181 (gdb_index_symbol_name_matcher): New class.
1182 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
1183 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
1184 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
1185 with a symbol_name_match_type.
1186 (f_language_defn): Adjust comments to refer to
1187 la_get_symbol_name_matcher.
1188 * go-lang.c (go_language_defn): Adjust comments to refer to
1189 la_get_symbol_name_matcher.
1190 * language.c (default_symbol_name_matcher)
1191 (language_get_symbol_name_matcher): New functions.
1192 (unknown_language_defn, auto_language_defn): Adjust comments to
1193 refer to la_get_symbol_name_matcher.
1194 * language.h (symbol_name_cmp_ftype): Delete.
1195 (language_defn) <la_collect_symbol_completion_matches>: Add match
1196 type parameter.
1197 <la_get_symbol_name_cmp>: Delete field.
1198 <la_get_symbol_name_matcher>: New field.
1199 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
1200 (default_symbol_name_matcher, language_get_symbol_name_matcher):
1201 Declare.
1202 * linespec.c (iterate_over_all_matching_symtabs)
1203 (iterate_over_file_blocks): Adjust to use lookup_name_info.
1204 (find_methods): Add language parameter, and use lookup_name_info
1205 and the language's symbol_name_matcher_ftype.
1206 (linespec_complete_function): Adjust.
1207 (lookup_prefix_sym): Use lookup_name_info.
1208 (add_all_symbol_names_from_pspace): Adjust.
1209 (find_superclass_methods): Add language parameter and pass it
1210 down.
1211 (find_method): Pass symbol language down.
1212 (find_linespec_symbols): Don't demangle or Ada encode here.
1213 (search_minsyms_for_name): Add lookup_name_info parameter.
1214 (add_matching_symbols_to_info): Add name_match_type parameter.
1215 Use lookup_name_info.
1216 * m2-lang.c (m2_language_defn): Adjust comments to refer to
1217 la_get_symbol_name_matcher.
1218 * minsyms.c: Include <algorithm>.
1219 (add_minsym_to_demangled_hash_table): Remove table parameter and
1220 add objfile parameter. Use search_name_hash, and add language to
1221 demangled languages vector.
1222 (struct found_minimal_symbols): New struct.
1223 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
1224 New functions.
1225 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
1226 input names here. Use lookup_name_info instead. Lookup up
1227 demangled names once for each language in the demangled names
1228 vector.
1229 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
1230 demangled names once for each language in the demangled names
1231 vector.
1232 (build_minimal_symbol_hash_tables): Adjust.
1233 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
1234 lookup_name_info.
1235 * objc-lang.c (objc_language_defn): Adjust comment to refer to
1236 la_get_symbol_name_matcher.
1237 * objfiles.h: Include <vector>.
1238 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
1239 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
1240 la_get_symbol_name_matcher.
1241 * p-lang.c (pascal_language_defn): Adjust comment to refer to
1242 la_get_symbol_name_matcher.
1243 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
1244 (match_partial_symbol): Use symbol_name_match_type,
1245 lookup_name_info and psymbol_name_matches.
1246 (lookup_partial_symbol): Use lookup_name_info.
1247 (map_block): Use symbol_name_match_type and lookup_name_info.
1248 (psym_map_matching_symbols): Use symbol_name_match_type.
1249 (psymbol_name_matches): New.
1250 (recursively_search_psymtabs): Use lookup_name_info and
1251 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
1252 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
1253 'kind' parameter to 'domain'.
1254 * rust-lang.c (rust_language_defn): Adjust comment to refer to
1255 la_get_symbol_name_matcher.
1256 * symfile-debug.c (debug_qf_map_matching_symbols)
1257 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
1258 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
1259 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
1260 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
1261 Adjust to use symbol_name_match_type.
1262 <expand_symtabs_matching>: Adjust to use lookup_name_info.
1263 (expand_symtabs_matching): Adjust to use lookup_name_info.
1264 * symmisc.c (maintenance_expand_symtabs): Use
1265 lookup_name_info::match_any ().
1266 * symtab.c (symbol_matches_search_name): New.
1267 (eq_symbol_entry): Adjust to use lookup_name_info and the
1268 language's matcher.
1269 (demangle_for_lookup_info::demangle_for_lookup_info): New.
1270 (lookup_name_info::match_any): New.
1271 (iterate_over_symbols, search_symbols): Use lookup_name_info.
1272 (compare_symbol_name): Add language, lookup_name_info and
1273 completion_match_result parameters, and use them.
1274 (completion_list_add_name): Make extern. Add language and
1275 lookup_name_info parameters. Use them.
1276 (completion_list_add_symbol, completion_list_add_msymbol)
1277 (completion_list_objc_symbol): Add lookup_name_info parameters and
1278 adjust. Pass down language.
1279 (completion_list_add_fields): Add lookup_name_info parameters and
1280 adjust. Pass down language.
1281 (add_symtab_completions): Add lookup_name_info parameters and
1282 adjust.
1283 (default_collect_symbol_completion_matches_break_on): Add
1284 name_match_type parameter, and use it. Use lookup_name_info.
1285 (default_collect_symbol_completion_matches)
1286 (collect_symbol_completion_matches): Add name_match_type
1287 parameter, and pass it down.
1288 (collect_symbol_completion_matches_type): Adjust.
1289 (collect_file_symbol_completion_matches): Add name_match_type
1290 parameter, and use lookup_name_info.
1291 * symtab.h: Include <string> and "common/gdb_optional.h".
1292 (enum class symbol_name_match_type): New.
1293 (class ada_lookup_name_info): New.
1294 (struct demangle_for_lookup_info): New.
1295 (class lookup_name_info): New.
1296 (symbol_name_matcher_ftype): New.
1297 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
1298 (symbol_matches_search_name): Declare.
1299 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
1300 (default_collect_symbol_completion_matches)
1301 (collect_symbol_completion_matches)
1302 (collect_file_symbol_completion_matches): Add name_match_type
1303 parameter.
1304 (iterate_over_symbols): Use lookup_name_info.
1305 (completion_list_add_name): Declare.
1306 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
1307 (strncmp_iw_with_mode): Now extern.
1308 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
1309 (strncmp_iw_with_mode): Declare.
1310
1311 2017-11-08 Keith Seitz <keiths@redhat.com>
1312 Pedro Alves <palves@redhat.com>
1313
1314 * ada-lang.c (ada_language_defn): Install
1315 default_search_name_hash.
1316 * buildsym.c (struct buildsym_compunit): <language>: New field.
1317 (finish_block_internal): Pass language when creating dictionaries.
1318 (start_buildsym_compunit, start_symtab): New language parameters.
1319 Use them.
1320 (restart_symtab): Pass down compilation unit's language.
1321 * buildsym.h (enum language): Forward declare.
1322 (start_symtab): New 'language' parameter.
1323 * c-lang.c (c_language_defn, cplus_language_defn)
1324 (asm_language_defn, minimal_language_defn): Install
1325 default_search_name_hash.
1326 * coffread.c (coff_start_symtab): Adjust.
1327 * d-lang.c (d_language_defn): Install default_search_name_hash.
1328 * dbxread.c (struct symloc): Add 'pst_language' field.
1329 (PST_LANGUAGE): Define.
1330 (start_psymtab, read_ofile_symtab): Use it.
1331 (process_one_symbol): New 'language' parameter. Pass it down.
1332 * dictionary.c (struct dictionary) <language>: New field.
1333 (DICT_LANGUAGE): Define.
1334 (dict_create_hashed, dict_create_hashed_expandable)
1335 (dict_create_linear, dict_create_linear_expandable): New parameter
1336 'language'. Set the dictionary's language.
1337 (iter_match_first_hashed): Adjust to rename.
1338 (insert_symbol_hashed): Assert we don't see mismatching
1339 languages. Adjust to rename.
1340 (dict_hash): Rename to ...
1341 (default_search_name_hash): ... this and make extern.
1342 * dictionary.h (struct language_defn): Forward declare.
1343 (dict_create_hashed): New parameter 'language'.
1344 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
1345 * f-lang.c (f_language_defn): Install default_search_name_hash.
1346 * go-lang.c (go_language_defn): Install default_search_name_hash.
1347 * jit.c (finalize_symtab): Pass compunit's language to dictionary
1348 creation.
1349 * language.c (unknown_language_defn, auto_language_defn):
1350 * language.h (language_defn::la_search_name_hash): New field.
1351 (default_search_name_hash): Declare.
1352 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
1353 * mdebugread.c (new_block): New parameter 'language'.
1354 * mdebugread.c (parse_symbol): Pass symbol language to block
1355 allocation.
1356 (psymtab_to_symtab_1): Pass down language.
1357 (new_symtab): Pass compunit's language to block allocation.
1358 * objc-lang.c (objc_language_defn): Install
1359 default_search_name_hash.
1360 * opencl-lang.c (opencl_language_defn):
1361 * p-lang.c (pascal_language_defn): Install
1362 default_search_name_hash.
1363 * rust-lang.c (rust_language_defn): Install
1364 default_search_name_hash.
1365 * stabsread.h (enum language): Forward declare.
1366 (process_one_symbol): Add 'language' parameter.
1367 * symtab.c (search_name_hash): New function.
1368 * symtab.h (search_name_hash): Declare.
1369 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
1370
1371 2017-11-08 Pedro Alves <palves@redhat.com>
1372
1373 * cp-name-parser.y (main): Don't initialize extra_chars.
1374
1375 2017-11-07 Tom Tromey <tom@tromey.com>
1376
1377 * event-top.h (command_handler): Constify.
1378 * record-full.c (cmd_record_full_start): Update.
1379 * thread.c (thread_apply_all_command): Update.
1380 * printcmd.c (eval_command): Update.
1381 * mi/mi-main.c (mi_execute_cli_command): Update.
1382 (mi_execute_async_cli_command): Update.
1383 * tui/tui-stack.c (tui_update_command): Update.
1384 * cli/cli-interp.c (safe_execute_command): Constify.
1385 * record.c (record_start): Update.
1386 (record_start, record_stop, cmd_record_start): Update.
1387 * record-btrace.c (cmd_record_btrace_bts_start): Update.
1388 (cmd_record_btrace_pt_start): Update.
1389 (cmd_record_btrace_start): Update.
1390 (cmd_record_btrace_start): Update.
1391 * reverse.c (exec_reverse_once): Update.
1392 * python/python.c (execute_gdb_command): Don't copy the command.
1393 * event-top.c (command_line_handler): Update.
1394 (command_handler): Constify.
1395 * defs.h (deprecated_call_command_hook): Constify.
1396 * cli/cli-script.h (execute_user_command): Constify.
1397 * cli/cli-script.c (execute_user_command): Constify.
1398 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
1399 (enum command_control_type): Update.
1400 * main.c (catch_command_errors): Remove non-const overload.
1401 (catch_command_errors_ftype): Remove.
1402 * python/py-cmd.c (cmdpy_function): Constify.
1403 * guile/scm-cmd.c (cmdscm_function): Constify.
1404 * cli/cli-dump.c (call_dump_func): Constify.
1405 * cli/cli-decode.c (do_const_cfunc): Constify.
1406 (do_sfunc): Constify.
1407 (cmd_func): Constify.
1408 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
1409 * top.h (execute_command): Constify.
1410 * top.c (execute_command): Constify.
1411 (execute_command_to_string): Constify.
1412 (deprecated_call_command_hook): Constify.
1413 * command.h (cmd_func): Constify.
1414 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
1415
1416 2017-11-07 Tom Tromey <tom@tromey.com>
1417
1418 * ada-lang.c (catch_ada_exception_command): Constify.
1419 (catch_assert_command): Constify.
1420 * break-catch-throw.c (catch_catch_command, catch_throw_command)
1421 (catch_rethrow_command): Constify.
1422 (catch_exception_command_1): Constify.
1423 * breakpoint.h (add_catch_command): Constify.
1424 * break-catch-syscall.c (catch_syscall_command_1): Constify.
1425 (catch_syscall_split_args): Constify.
1426 * break-catch-sig.c (catch_signal_command): Constify.
1427 (catch_signal_split_args): Constify.
1428 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
1429 cmd_const_sfunc_ftype.
1430 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
1431 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
1432 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
1433 (add_setshow_string_cmd, struct cmd_list_element)
1434 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
1435 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
1436 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
1437 Constify.
1438 (set_cmd_sfunc): Constify.
1439 (empty_sfunc): Constify.
1440 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
1441 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
1442 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
1443 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
1444 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
1445 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
1446 Constify.
1447 (set_cmd_sfunc): Constify.
1448 (cmd_sfunc_ftype): Remove.
1449 * compile/compile.c (set_compile_args): Constify.
1450 * infrun.c (set_disable_randomization): Constify.
1451 * infcmd.c (set_args_command, set_cwd_command): Constify.
1452 * breakpoint.c (set_condition_evaluation_mode): Constify.
1453 (add_catch_command): Constify.
1454 (catch_fork_command_1, catch_exec_command_1)
1455 (catch_load_command_1, catch_unload_command_1): Constify.
1456 (catch_load_or_unload): Constify.
1457 * guile/scm-param.c (pascm_set_func): Constify.
1458 (add_setshow_generic): Constify.
1459 * python/py-param.c (get_set_value): Constify.
1460 * top.h (set_verbose): Constify.
1461 * tui/tui-win.c (tui_set_var_cmd): Constify.
1462 * mi/mi-main.c (set_mi_async_command): Constify.
1463 * cli/cli-logging.c (set_logging_overwrite)
1464 (set_logging_redirect): Constify.
1465 * value.c (set_max_value_size): Constify.
1466 * valprint.c (set_input_radix, set_output_radix): Constify.
1467 * utils.c (set_width_command, set_height_command): Constify.
1468 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
1469 * tracepoint.c (set_disconnected_tracing)
1470 (set_circular_trace_buffer, set_trace_buffer_size)
1471 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
1472 * top.c (set_history_size_command, set_verbose, set_editing)
1473 (set_gdb_datadir, set_history_filename): Constify.
1474 * target.c (set_targetdebug, maint_set_target_async_command)
1475 (maint_set_target_non_stop_command, set_target_permissions)
1476 (set_write_memory_permission): Constify.
1477 (open_target): Constify.
1478 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
1479 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
1480 * symtab.c (set_symbol_cache_size_handler): Constify.
1481 * symfile.c (set_ext_lang_command): Constify.
1482 * symfile-debug.c (set_debug_symfile): Constify.
1483 * source.c (set_directories_command): Constify.
1484 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
1485 * serial.c (set_parity): Constify.
1486 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
1487 * remote.c (set_remote_exec_file, set_remotebreak)
1488 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
1489 * record.c (set_record_insn_history_size)
1490 (set_record_call_history_size): Constify.
1491 * record-full.c (set_record_full_insn_max_num): Constify.
1492 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
1493 * osabi.c (set_osabi): Constify.
1494 * mips-tdep.c (set_mips64_transfers_32bit_regs)
1495 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
1496 * maint.c (maintenance_set_profile_cmd): Constify.
1497 * linux-thread-db.c (set_libthread_db_search_path): Constify.
1498 * language.c (set_language_command, set_range_command)
1499 (set_case_command): Constify.
1500 * infrun.c (set_non_stop, set_observer_mode)
1501 (set_stop_on_solib_events, set_schedlock_func)
1502 (set_exec_direction_func): Constify.
1503 * infcmd.c (set_inferior_tty_command): Constify.
1504 * disasm.c (set_disassembler_options_sfunc): Constify.
1505 * demangle.c (set_demangling_command): Constify.
1506 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
1507 * cris-tdep.c (set_cris_version, set_cris_mode)
1508 (set_cris_dwarf2_cfi): Constify.
1509 * corefile.c (set_gnutarget_command): Constify.
1510 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
1511 (set_target_wide_charset_sfunc): Constify.
1512 * breakpoint.c (update_dprintf_commands): Constify.
1513 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
1514 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
1515 (set_disassembly_style_sfunc): Constify.
1516 * arch-utils.c (set_endian, set_architecture): Constify.
1517 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
1518 * agent.c (set_can_use_agent): Constify.
1519
1520 2017-11-07 Tom Tromey <tom@tromey.com>
1521
1522 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
1523 (go32_pde, go32_pte, go32_pte_for_address): Constify.
1524 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
1525 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
1526 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
1527 (parse_int_arg, show_thread_default_detach_sc_cmd)
1528 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
1529 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
1530 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
1531 (show_task_pause_cmd, set_task_detach_sc_cmd)
1532 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
1533 (set_noninvasive_cmd, set_thread_pause_cmd)
1534 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
1535 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
1536 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
1537 * windows-nat.c (display_selectors): Constify.
1538 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
1539 non-const "cfunc".
1540 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
1541 (cmd_cfunc_eq): Likewise.
1542 (struct cmd_list_element): Likewise.
1543 (do_cfunc): Remove.
1544 (cli_user_command_p): Update.
1545 * command.h (add_cmd): Remove non-const overload.
1546 (cmd_cfunc_ftype): Remove typedef.
1547 (cmd_cfunc_eq): Remove non-const overload.
1548 * value.c (show_values): Constify.
1549 * thread.c (thread_apply_all_command): Constify.
1550 * symfile.c (load_command): Constify.
1551 * source.c (directory_command): Constify.
1552 * maint.c (maintenance_internal_error)
1553 (maintenance_demangler_warning, maintenance_space_display)
1554 (maintenance_print_architecture, maintenance_translate_address)
1555 (maintenance_info_selftests, maintenance_internal_warning):
1556 Constify.
1557 * breakpoint.c (disable_trace_command, enable_trace_command):
1558 Constify.
1559 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
1560 Constify.
1561 (add_auto_load_safe_path): Constify.
1562 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
1563 * top.h (show_commands): Constify.
1564 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
1565 * sparc64-tdep.c (adi_examine_command): Constify.
1566 (adi_assign_command): Constify.
1567
1568 2017-11-07 Tom Tromey <tom@tromey.com>
1569
1570 * frame.h (info_locals_command, info_args_command): Constify.
1571 * auto-load.h (auto_load_info_scripts): Constify.
1572 * inferior.h (registers_info): Constify.
1573 * copying.c: Rebuild.
1574 * copying.awk: Constify generated commands.
1575 * auto-load.c (auto_load_info_scripts)
1576 (info_auto_load_gdb_scripts): Constify.
1577 * cli/cli-decode.c (struct cmd_list_element): Take a
1578 cmd_const_cfunc_ftype.
1579 * command.h (add_info): Take a cmd_const_cfunc_ftype.
1580 * tui/tui-win.c (tui_all_windows_info): Constify.
1581 * python/py-auto-load.c (info_auto_load_python_scripts):
1582 Constify.
1583 * cli/cli-cmds.c (show_command): Remove non-const overload.
1584 * tracepoint.c (info_tvariables_command, info_scope_command):
1585 Constify.
1586 (info_static_tracepoint_markers_command): Constify.
1587 * thread.c (info_threads_command): Constify.
1588 (print_thread_info_1): Constify.
1589 * target.c (info_target_command): Constify.
1590 * symtab.c (info_sources_command, info_functions_command)
1591 (info_types_command): Constify.
1592 (info_variables_command): Remove non-const overload.
1593 * symfile.c (info_ext_lang_command): Constify.
1594 * stack.c (info_frame_command, info_locals_command)
1595 (info_args_command): Constify.
1596 (backtrace_command): Remove non-const overload.
1597 * source.c (info_source_command, info_line_command): Constify.
1598 * solib.c (info_sharedlibrary_command): Constify.
1599 * skip.c (info_skip_command): Constify.
1600 * ser-go32.c (info_serial_command): Constify.
1601 * reverse.c (info_bookmarks_command): Constify.
1602 * printcmd.c (info_symbol_command, info_address_command)
1603 (info_display_command): Constify.
1604 * osdata.c (info_osdata_command): Constify.
1605 * objc-lang.c (info_selectors_command, info_classes_command):
1606 Constify.
1607 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
1608 * memattr.c (info_mem_command): Constify.
1609 * macrocmd.c (info_macro_command, info_macros_command): Constify.
1610 * linux-fork.c (info_checkpoints_command): Constify.
1611 * infrun.c (info_signals_command): Constify.
1612 * inflow.c (info_terminal_command): Constify.
1613 * inferior.c (info_inferiors_command): Constify.
1614 (print_inferior): Constify.
1615 * infcmd.c (info_program_command, info_all_registers_command)
1616 (info_registers_command, info_vector_command)
1617 (info_float_command): Constify.
1618 (registers_info): Constify.
1619 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
1620 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
1621 Constify.
1622 * f-valprint.c (info_common_command): Constify.
1623 * dcache.c (info_dcache_command): Constify.
1624 (dcache_info_1): Constify.
1625 * darwin-nat-info.c (info_mach_tasks_command)
1626 (info_mach_task_command, info_mach_ports_command)
1627 (info_mach_port_command, info_mach_threads_command)
1628 (info_mach_thread_command, info_mach_regions_command)
1629 (info_mach_regions_recurse_command, info_mach_region_command)
1630 (info_mach_exceptions_command): Constify.
1631 (get_task_from_args): Constify.
1632 * cp-support.c (info_vtbl_command): Constify.
1633 * breakpoint.c (info_watchpoints_command)
1634 (info_tracepoints_command): Constify.
1635 (info_breakpoints_command): Remove non-const overload.
1636 * avr-tdep.c (avr_io_reg_read_command): Constify.
1637 * auxv.c (info_auxv_command): Constify.
1638 * ada-tasks.c (info_tasks_command): Constify.
1639 (info_task): Constify.
1640 * ada-lang.c (info_exceptions_command): Constify.
1641
1642 2017-11-07 Tom Tromey <tom@tromey.com>
1643
1644 * solib.h (no_shared_libraries): Constify.
1645 * frame.h (return_command): Constify.
1646 * cli/cli-cmds.h (quit_command): Constify.
1647 * top.h (quit_command, execute_command): Constify.
1648 * target.h (flash_erase_command): Constify.
1649 * inferior.h (set_inferior_args, attach_command): Constify.
1650 * tracepoint.h (start_tracing, stop_tracing): Constify.
1651 * breakpoint.h (break_command, tbreak_command)
1652 (hbreak_command_wrapper, thbreak_command_wrapper)
1653 (rbreak_command_wrapper, watch_command_wrapper)
1654 (awatch_command_wrapper, rwatch_command_wrapper)
1655 (get_tracepoint_by_number): Constify.
1656 * symtab.c (info_variables_command, rbreak_command)
1657 (symtab_symbol_info): Constify.
1658 (info_variables_command): Add non-const overload.
1659 * top.c (dont_repeat_command): Constify.
1660 * breakpoint.c (ignore_command, commands_command)
1661 (condition_command, tbreak_command, hbreak_command)
1662 (thbreak_command, clear_command, break_command)
1663 (info_breakpoints_command, watch_command, rwatch_command)
1664 (awatch_command, trace_command, ftrace_command, strace_command)
1665 (trace_pass_command, break_range_command, dprintf_command)
1666 (agent_printf_command, get_tracepoint_by_number)
1667 (watch_maybe_just_location, trace_pass_command): Constify.
1668 (info_breakpoints_command): Add non-const overload.
1669 * tracefile.c (tsave_command): Constify.
1670 * infcmd.c (attach_command, disconnect_command, signal_command)
1671 (queue_signal_command, stepi_command, nexti_command)
1672 (finish_command, next_command, step_command, until_command)
1673 (advance_command, jump_command, continue_command, run_command)
1674 (start_command, starti_command, interrupt_command)
1675 (run_command_1, set_inferior_args, step_1): Constify.
1676 * inferior.c (add_inferior_command, remove_inferior_command)
1677 (clone_inferior_command): Constify.
1678 * linux-fork.c (checkpoint_command, restart_command): Constify.
1679 * windows-nat.c (signal_event_command): Constify.
1680 * guile/guile.c (guile_repl_command, guile_command): Constify.
1681 * printcmd.c (x_command, display_command, printf_command)
1682 (output_command, set_command, call_command, print_command)
1683 (eval_command): Constify.
1684 (non_const_set_command): Remove.
1685 (_initialize_printcmd): Update.
1686 * source.c (forward_search_command, reverse_search_command):
1687 Constify.
1688 * jit.c (jit_reader_load_command, jit_reader_unload_command):
1689 Constify.
1690 * infrun.c (handle_command): Constify.
1691 * memattr.c (mem_command): Constify.
1692 * stack.c (return_command, up_command, up_silently_command)
1693 (down_command, down_silently_command, frame_command)
1694 (backtrace_command, func_command, backtrace_command_1): Constify.
1695 (backtrace_command): Add non-const overload.
1696 * remote-sim.c (simulator_command): Constify.
1697 * exec.c (set_section_command): Constify.
1698 * tracepoint.c (tdump_command, trace_variable_command)
1699 (tstatus_command, tstop_command, tstart_command)
1700 (end_actions_pseudocommand, while_stepping_pseudocommand)
1701 (collect_pseudocommand, teval_pseudocommand, actions_command)
1702 (start_tracing, stop_tracing): Constify.
1703 * value.c (init_if_undefined_command): Constify.
1704 * tui/tui-stack.c (tui_update_command): Constify.
1705 * tui/tui-win.c (tui_refresh_all_command)
1706 (tui_set_tab_width_command, tui_set_win_height_command)
1707 (tui_set_focus_command, tui_scroll_forward_command)
1708 (tui_scroll_backward_command, tui_scroll_left_command)
1709 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
1710 (tui_set_win_height): Constify.
1711 * tui/tui-layout.c (tui_layout_command): Constify.
1712 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
1713 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
1714 (proc_untrace_sysexit_cmd): Constify.
1715 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
1716 (threadset_test_cmd, threadlist_update_test_cmd)
1717 (threadalive_test): Constify.
1718 * objc-lang.c (print_object_command): Constify.
1719 * command.h (add_com): Constify.
1720 * cli/cli-dump.c (restore_command): Constify.
1721 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
1722 (help_command, complete_command, shell_command, edit_command)
1723 (list_command, disassemble_command, make_command)
1724 (apropos_command, alias_command): Constify.
1725 * cli/cli-script.c (document_command, define_command)
1726 (while_command, if_command, validate_comname): Constify.
1727 * cli/cli-decode.c (struct cmd_list_element): Change type of
1728 "fun".
1729 * target.c (do_monitor_command, flash_erase_command): Constify.
1730 * regcache.c (reg_flush_command): Constify.
1731 * reverse.c (reverse_step, reverse_next, reverse_stepi)
1732 (reverse_nexti, reverse_continue, reverse_finish)
1733 (save_bookmark_command, goto_bookmark_command)
1734 (exec_reverse_once): Constify.
1735 * python/python.c (python_interactive_command, python_command):
1736 Constify.
1737 * typeprint.c (ptype_command, whatis_command, whatis_exp):
1738 Constify.
1739 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
1740 * gcore.c (gcore_command): Constify.
1741
1742 2017-11-07 Tom Tromey <tom@tromey.com>
1743
1744 * printcmd.c (x_command): Call set_repeat_arguments.
1745 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
1746 * top.c (repeat_arguments): New global.
1747 (set_repeat_arguments): New function.
1748 (execute_command): Handle repeat_arguments.
1749 (show_commands): Calls set_repeat_arguments.
1750 * command.h (set_repeat_arguments): Declare.
1751
1752 2017-11-07 Tom Tromey <tom@tromey.com>
1753
1754 * stack.c (backtrace_command): Use std::string.
1755 (backtrace_command_1): Make "count_exp" const.
1756
1757 2017-11-07 Tom Tromey <tom@tromey.com>
1758
1759 * source.c (directory_switch, mod_path, add_path): Constify.
1760 * defs.h (add_path, mod_path, directory_switch): Constify.
1761 * mi/mi-cmd-env.c (env_mod_path): Constify.
1762
1763 2017-11-07 Tom Tromey <tom@tromey.com>
1764
1765 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
1766 (run_command_1, continue_command, step_1, jump_command)
1767 (signal_command, until_command, advance_command, finish_command)
1768 (attach_command): Update.
1769
1770 2017-11-07 Tom Tromey <tom@tromey.com>
1771
1772 * command.h (set_cmd_cfunc): Don't declare.
1773 * cli/cli-decode.c (set_cmd_cfunc): Now static.
1774
1775 2017-11-07 Tom Tromey <tom@tromey.com>
1776
1777 * stack.c (select_frame_command): Constify.
1778 * cli/cli-decode.c (add_com_suppress_notification): Constify.
1779 * command.h (add_com_suppress_notification): Constify.
1780
1781 2017-11-07 Tom Tromey <tom@tromey.com>
1782
1783 * breakpoint.c (stop_command): Constify.
1784 * cli/cli-decode.c (struct cmd_list_element): Constify.
1785 * command.h (add_abbrev_prefix_cmd): Constify.
1786
1787 2017-11-07 Pedro Alves <palves@redhat.com>
1788
1789 * breakpoint.c (extract_bp_kind): New enum.
1790 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
1791 factored out from ...
1792 (extract_bp_number_and_location): ... here.
1793 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
1794
1795 2017-11-07 Pedro Alves <palves@redhat.com>
1796
1797 * breakpoint.c (extract_bp_number_and_location): Change return
1798 type to void. Throw error instead of warning.
1799 (enable_disable_command): Adjust.
1800
1801 2017-11-07 Xavier Roirand <roirand@adacore.com>
1802 Pedro Alves <palves@redhat.com>
1803
1804 * breakpoint.c (map_breakpoint_number_range): New, factored out
1805 from ...
1806 (map_breakpoint_numbers): ... here.
1807 (find_location_by_number): Change parameters from string to
1808 breakpoint number and location.
1809 (extract_bp_number_and_location): New function.
1810 (enable_disable_bp_num_loc)
1811 (enable_disable_breakpoint_location_range)
1812 (enable_disable_command): New functions, factored out ...
1813 (enable_command, disable_command): ... these functions, and
1814 adjusted to support ranges.
1815 * NEWS: Document enable/disable breakpoint location range feature.
1816
1817 2017-11-06 Luis Machado <luis.machado@linaro.org>
1818
1819 * MAINTAINERS (Write After Approval): Update my e-mail address.
1820
1821 2017-11-06 Pedro Alves <palves@redhat.com>
1822
1823 * gnu-nat.c (gnu_terminal_init): Delete.
1824 (gnu_target): Don't install gnu_terminal_init.
1825 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
1826 (child_terminal_init): ... this function.
1827
1828 2017-11-06 Pedro Alves <palves@redhat.com>
1829
1830 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
1831 sgtty.h.
1832 * config.in, configure: Regenerate.
1833
1834 2017-11-06 Pedro Alves <palves@redhat.com>
1835
1836 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
1837 (async_init_signals): Adjust.
1838 (handle_stop_sig): Rename to ...
1839 (handle_sigtstp): ... this.
1840 (async_stop_sig): Rename to ...
1841 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
1842 SIGTSTP path.
1843 * event-top.h: Move signal.h include to the top. Check SIGTSTP
1844 instead of STOP_SIGNAL thoughout.
1845 (handle_stop_sig): Rename to ...
1846 (handle_sigtstp): ... this.
1847 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
1848
1849 2017-11-06 Pedro Alves <palves@redhat.com>
1850
1851 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
1852 longer set flags twice in row.
1853
1854 2017-11-06 Pedro Alves <palves@redhat.com>
1855
1856 * Makefile.in (SER_HARDWIRE): Update comment.
1857 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
1858 * common/gdb_termios.h: Delete file.
1859 * common/job-control.c: Include termios.h and unistd.h instead of
1860 gdb_termios.h.
1861 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
1862 check.
1863 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
1864 Remove sgtty code.
1865 * configure.ac: No longer check for termio.h and sgtty.h.
1866 * configure: Regenerate.
1867 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
1868 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
1869 Replace PROCESS_GROUP_TYPE references with pid_t references
1870 throughout.
1871 (gdb_getpgrp): Delete.
1872 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
1873 (child_terminal_inferior): Remove comment. Remove sgtty code.
1874 (child_terminal_ours_1): Use tcgetpgrp directly instead of
1875 gdb_getpgrp. Use serial_set_tty_state instead aof
1876 serial_noflush_set_tty_state. Remove sgtty code.
1877 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
1878 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
1879 (inferior_process_group): Now returns pid_t.
1880 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
1881 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
1882 * ser-event.c (serial_event_ops): Update.
1883 * ser-go32.c (dos_noflush_set_tty_state): Delete.
1884 (dos_ops): Update.
1885 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
1886 * ser-pipe.c (pipe_ops): Update.
1887 * ser-tcp.c (tcp_ops): Update.
1888 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
1889 HAVE_TERMIOS checks.
1890 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
1891 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
1892 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
1893 assume termios.
1894 (hardwire_noflush_set_tty_state): Delete.
1895 (hardwire_print_tty_state, hardwire_drain_output)
1896 (hardwire_flush_output, hardwire_flush_input)
1897 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
1898 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
1899 code, and assume termios.
1900 (hardwire_ops): Update.
1901 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
1902 * serial.c (serial_noflush_set_tty_state): Delete.
1903 * serial.h (serial_noflush_set_tty_state): Delete.
1904 (serial_ops::noflush_set_tty_state): Delete.
1905
1906 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1907
1908 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
1909 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
1910 (COMMON_OBS): Remove doublest.o and dfp.o.
1911 Do not build target-float.c (instead of doublest.c)
1912 with -Wformat-nonliteral.
1913
1914 * doublest.c: Remove file.
1915 * doublest.h: Remove file.
1916 * dfp.c: Remove file.
1917 * dfp.h: Remove file.
1918
1919 * target-float.c: Do not include "doublest.h" and "dfp.h".
1920 (DOUBLEST): Move here from doublest.h.
1921 (enum float_kind): Likewise.
1922 (FLOATFORMAT_CHAR_BIT): Likewise.
1923 (FLOATFORMAT_LARGEST_BYTES): Likewise.
1924 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
1925 (floatformat_precision): Likewise.
1926 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
1927 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
1928 Likewise.
1929 (host_float_format, host_double_format, host_long_double_format):
1930 Likewise.
1931 (floatformat_to_string, floatformat_from_string): Likewise.
1932 (floatformat_to_doublest): Likewise. Also, inline the original
1933 convert_floatformat_to_doublest.
1934 (floatformat_from_doublest): Likewise. Also, inline the original
1935 convert_floatformat_from_doublest.
1936
1937 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
1938 (MAX_DECIMAL_STRING): Move here from dfp.c.
1939 (match_endianness): Likewise.
1940 (set_decnumber_context, decimal_check_errors): Likewise.
1941 (decimal_from_number, decimal_to_number): Likewise.
1942 (decimal_to_string, decimal_from_string): Likewise. Make static.
1943 (decimal_from_longest, decimal_from_ulongest): Likewise.
1944 (decimal_to_longest): Likewise.
1945 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
1946 (decimal_convert): Likewise.
1947
1948 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1949
1950 * doublest.c: Do not include "gdbtypes.h".
1951 (extract_typed_floating): Remove.
1952 (store_typed_floating): Remove.
1953 (convert_typed_floating): Remove.
1954 * doublest.h (struct type): Remove.
1955 (DOUBLEST_PRINT_FORMAT): Remove.
1956 (DOUBLEST_SCAN_FORMAT): Remove.
1957 (extract_typed_floating): Remove.
1958 (store_typed_floating): Remove.
1959 (convert_typed_floating): Remove.
1960
1961 * dfp.c (decimal_from_doublest): Remove.
1962 (decimal_to_doublest): Remove.
1963 * dfp.h: Do not include "doublest.h".
1964 (decimal_from_doublest): Remove.
1965 (decimal_to_doublest): Remove.
1966
1967 * value.c: Do not include "doublest.h" and "dfp.h".
1968 (value_as_double): Remove.
1969 (unpack_double): Remove.
1970 (value_from_double): Remove.
1971 (value_from_decfloat): Remove.
1972 * value.h: Do not include "doublest.h".
1973 (value_as_double): Remove.
1974 (unpack_double): Remove.
1975 (value_from_double): Remove.
1976 (value_from_decfloat): Remove.
1977
1978 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1979
1980 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
1981 (i386_extract_return_value): Use target_float_convert.
1982 (i386_store_return_value): Likewise.
1983 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
1984 (i387_value_to_register): Likewise.
1985 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
1986 (ia64_register_to_value): Use target_float_convert.
1987 (ia64_value_to_register): Likewise.
1988 (ia64_extract_return_value): Likewise.
1989 (ia64_store_return_value): Likewise.
1990 (ia64_push_dummy_call): Likewise.
1991 * m68k-tdep.c: Include "target-float.h".
1992 (m68k_register_to_value): Use target_float_convert.
1993 (m68k_value_to_register): Likewise.
1994 (m68k_svr4_extract_return_value): Likewise.
1995 (m68k_svr4_store_return_value): Likewise.
1996 * ppc-sysv-tdep.c: Include "target-float.h".
1997 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
1998 (do_ppc_sysv_return_value): Likewise.
1999 (ppc64_sysv_abi_push_freg): Likewise.
2000 (ppc64_sysv_abi_return_value_base): Likewise.
2001 * rs6000-aix-tdep.c: Include "target-float.h".
2002 (rs6000_push_dummy_call): Use target_float_convert.
2003 (rs6000_return_value): Likewise.
2004 * rs6000-lynx178-tdep.c: Include "target-float.h".
2005 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
2006 (rs6000_lynx178_return_value): Likewise.
2007 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
2008 (rs6000_register_to_value): Use target_float_convert.
2009 (rs6000_value_to_register): Likewise.
2010 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
2011 (arm_extract_return_value): Use target_float_convert.
2012 (arm_store_return_value): Likewise.
2013 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
2014 (sh_register_convert_to_virtual): Use target_float_convert.
2015 (sh_register_convert_to_raw): Likewise.
2016 * sh64-tdep.c: Include "target-float.h".
2017 (sh64_extract_return_value): Use target_float_convert.
2018 (sh64_register_convert_to_virtual): Likewise.
2019 (sh64_register_convert_to_raw): Likewise. Fix argument types.
2020
2021 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2022
2023 * target-float.c (floatformat_to_host_double): New function.
2024 (floatformat_from_host_double): Likewise.
2025 (target_float_to_host_double): Likewise.
2026 (target_float_from_host_double): Likewise.
2027 * target-float.h (target_float_to_host_double): Add prototype.
2028 (target_float_from_host_double): Likewise.
2029
2030 * guile/scm-value.c: Include "target-float.h".
2031 (gdbscm_value_to_real): Use target_float_to_host_double.
2032 Handle integer source values via value_as_long.
2033 * guile/scm-math.c: Include "target-float.h". Do not include
2034 "doublest.h", "dfp.h", and "expression.h".
2035 (vlscm_convert_typed_number): Use target_float_from_host_double.
2036 (vlscm_convert_number): Likewise.
2037
2038 * python/py-value.c (valpy_float): Use target_float_to_host_double.
2039 (convert_value_from_python): Use target_float_from_host_double.
2040
2041 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2042
2043 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
2044 (cast_from_fixed): Likewise.
2045 (ada_scaling_type): New function.
2046 (ada_delta): Return value instead of DOUBLEST. Perform target
2047 arithmetic instead of host arithmetic.
2048 (scaling_factor): Rename to ...
2049 (ada_scaling_factor) ... this. Make non-static. Return value instead
2050 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
2051 (ada_fixed_to_float): Remove.
2052 (ada_float_to_fixed): Remove.
2053 * ada-lang.h (ada_fixed_to_float): Remove.
2054 (ada_float_to_fixed): Remove.
2055 (ada_delta): Return value instead of DOUBLEST.
2056 (ada_scaling_factor): Add prototype.
2057
2058 * ada-typeprint.c: Include "target-float.h".
2059 (print_fixed_point_type): Perform target arithmetic instead of
2060 host arithmetic.
2061 * ada-valprint.c: Include "target-float.h".
2062 (ada_val_print_num): Perform target arithmetic instead of
2063 host arithmetic for fixed-point types.
2064
2065 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2066
2067 * target-float.c: Include <math.h>.
2068 (floatformat_binop): New function.
2069 (floatformat_compare): Likewise.
2070 (target_float_binop): Likewise.
2071 (target_float_compare): Likewise.
2072 * target-float.h: Include "expression.h".
2073 (target_float_binop): Add prototype.
2074 (target_float_compare): Likewise.
2075
2076 * valarith.c: Do not include "doublest.h" and "dfp.h".
2077 Include "common/byte-vector.h".
2078 (value_args_as_decimal): Remove, replace by ...
2079 (value_args_as_target_float): ... this function. Handle both
2080 binary and decimal target floating-point formats.
2081 (scalar_binop): Handle both binary and decimal FP using
2082 value_args_as_target_float and target_float_binop.
2083 (value_equal): Handle both binary and decimal FP using
2084 value_args_as_target_float and target_float_compare.
2085 (value_less): Likewise.
2086 (value_pos): Handle all scalar types as simple copy.
2087 (value_neg): Handle all scalar types via BINOP_SUB from 0.
2088 * dfp.c (decimal_binop): Throw error instead of internal_error
2089 when called with an unsupported operation code.
2090
2091 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2092
2093 * target-float.c (target_float_to_string): New function.
2094 (target_float_from_string): New function.
2095 * target-float.h (target_float_to_string): Add prototype.
2096 (target_float_from_string): Add prototype.
2097
2098 * valprint.c: Include "target-float.h". Do not include
2099 "doublest.h" and "dfp.h".
2100 (print_floating): Use target_float_to_string.
2101 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
2102 (printf_floating): Use target_float_to_string.
2103 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
2104 (print_i387_value): Use target_float_to_string.
2105 * mips-tdep.c: Include "target-float.h".
2106 (mips_print_fp_register): Use target_float_to_string.
2107 * sh64-tdep.c: Include "target-float.h".
2108 (sh64_do_fp_register): Use target_float_to_string.
2109
2110 * parse.c: Include "target-float.h". Do not include
2111 "doublest.h" and "dfp.h".
2112 (parse_float): Use target_float_from_string.
2113 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
2114 (define_symbol): Use target_float_from_string.
2115 * gdbarch-selftests.c: Include "target-float.h".
2116 (register_to_value_test): Use target_float_from_string.
2117
2118 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2119
2120 * Makefile.c (SFILES): Add target-float.c.
2121 (HFILES_NO_SRCDIR): Add target-float.h.
2122 (COMMON_OBS): Add target-float.o.
2123 * target-float.h: New file.
2124 * target-float.c: New file.
2125
2126 * doublest.c (floatformat_classify): Fix detection of float_zero.
2127
2128 * gdbtypes.c (is_floating_type): New function.
2129 * gdbtypes.h (is_floating_type): Add prototype.
2130
2131 * value.c: Do not include "floatformat.h".
2132 (unpack_double): Use target_float_is_valid.
2133 (is_floating_value): New function.
2134 * value.h (is_floating_value): Add prototype-
2135
2136 * valarith.c: Include "target-float.h".
2137 (value_logical_not): Use target_float_is_zero.
2138
2139 * python/py-value.c: Include "target-float.h".
2140 (valpy_nonzero): Use target_float_is_zero.
2141
2142 2017-11-04 Tom Tromey <tom@tromey.com>
2143
2144 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
2145
2146 2017-11-04 Tom Tromey <tom@tromey.com>
2147
2148 * breakpoint.c (set_momentary_breakpoint): Return
2149 breakpoint_up.
2150 (until_break_command): Update.
2151 (new_until_break_fsm): Change argument types to
2152 breakpoint_up.
2153 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
2154 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
2155 Remove.
2156 * infcmd.c (finish_forward): Update.
2157 * breakpoint.h (set_momentary_breakpoint)
2158 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
2159 (make_cleanup_delete_breakpoint): Remove.
2160 (struct breakpoint_deleter): New.
2161 (breakpoint_up): New typedef.
2162 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
2163 (insert_exception_resume_breakpoint): Update.
2164 (insert_exception_resume_from_probe): Update.
2165 (insert_longjmp_resume_breakpoint): Update.
2166 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
2167 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
2168 * infcall.c (call_function_by_hand_dummy): Update
2169
2170 2017-11-04 Tom Tromey <tom@tromey.com>
2171
2172 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
2173
2174 2017-11-04 Tom Tromey <tom@tromey.com>
2175
2176 * linux-tdep.c (linux_core_info_proc_mappings): Use
2177 gdb::def_vector.
2178 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
2179 "size" argument.
2180 (linux_corefile_thread): Update.
2181 (linux_make_corefile_notes): Remove unused variable.
2182
2183 2017-11-04 Tom Tromey <tom@tromey.com>
2184
2185 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
2186 gdb::byte_vector.
2187
2188 2017-11-04 Tom Tromey <tom@tromey.com>
2189
2190 * objfiles.c (do_free_objfile_cleanup): Remove.
2191 * compile/compile-object-load.c (compile_object_load): Update.
2192 * objfiles.h (make_cleanup_free_objfile): Remove.
2193
2194 2017-11-04 Tom Tromey <tom@tromey.com>
2195
2196 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
2197 (adi_read_versions): Change "tags" to "gdb_byte *".
2198 (adi_print_versions): Likewise.
2199
2200 2017-11-04 Tom Tromey <tom@tromey.com>
2201
2202 * breakpoint.c
2203 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
2204 from start_rbreak_breakpoints.
2205 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
2206 * breakpoint.h (class scoped_rbreak_breakpoints): New.
2207 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
2208 * symtab.c (do_end_rbreak_breakpoints): Remove.
2209 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
2210
2211 2017-11-04 Tom Tromey <tom@tromey.com>
2212
2213 * cp-namespace.c (reset_directive_searched): Remove.
2214 (cp_lookup_symbol_via_imports): Use scoped_restore.
2215 * cp-support.c (reset_directive_searched): Remove.
2216 (make_symbol_overload_list_using): Use scoped_restore.
2217 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
2218 (reset_directive_searched): Remove.
2219
2220 2017-11-04 Tom Tromey <tom@tromey.com>
2221
2222 * symfile.c (find_separate_debug_file_by_debuglink): Use
2223 unique_xmalloc_ptr.
2224
2225 2017-11-04 Tom Tromey <tom@tromey.com>
2226
2227 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
2228 type of "info".
2229 (compute_stack_depth): Likewise.
2230 (do_compile_dwarf_expr_to_c): Use std::vector.
2231
2232 2017-11-04 Tom Tromey <tom@tromey.com>
2233
2234 * compile/compile-object-load.c (link_callbacks_einfo): Use
2235 std::string.
2236
2237 2017-11-04 Tom Tromey <tom@tromey.com>
2238
2239 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
2240 Use scoped_free_pendings.
2241 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
2242 scoped_free_pendings.
2243 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
2244 (xcoff_initial_scan): Likewise.
2245 * buildsym.c (reset_symtab_globals): Update comment.
2246 (scoped_free_pendings): Rename from really_free_pendings.
2247 (prepare_for_building): Update comment.
2248 (buildsym_init): Likewise.
2249 * buildsym.h (class scoped_free_pendings): New class.
2250 (really_free_pendings): Don't declare.
2251
2252 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
2253
2254 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
2255 output when converting a zero value to a special byteorder format.
2256
2257 2017-11-02 Yao Qi <yao.qi@linaro.org>
2258
2259 * frame.c (do_frame_register_read): Remove aspace.
2260 * jit.c (jit_frame_sniffer): Likwise.
2261 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
2262 * regcache.c (regcache::regcache): Pass nullptr.
2263 (regcache_print): Caller updated.
2264 * regcache.h (regcache::regcache): Remove one constructor
2265 parameter aspace.
2266
2267 2017-11-02 Yao Qi <yao.qi@linaro.org>
2268
2269 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
2270
2271 2017-11-02 Yao Qi <yao.qi@linaro.org>
2272
2273 * breakpoint.c (insert_single_step_breakpoints): Update.
2274 * frame.c (struct frame_info) <aspace>: Add const.
2275 (frame_save_as_regcache): Add const.
2276 (get_frame_address_space): Return const address_space *.
2277 * frame.h (get_frame_address_space): Update declaration.
2278 * infrun.c (struct step_over_info) <aspace>: Add const.
2279 (set_step_over_info): Make aspace const.
2280 (displaced_step_prepare_throw): Change variable const.
2281 (resume): Likewise.
2282 (proceed): Likewise.
2283 (adjust_pc_after_break): Likewise.
2284 (save_waitstatus): Likewise.
2285 (handle_signal_stop): Likewise.
2286 (keep_going_pass_signal): Likewise.
2287 * jit.c (jit_frame_sniffer): Add const.
2288 * mips-tdep.c (mips_single_step_through_delay): Likewise.
2289 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
2290 * record-full.c (record_full_wait_1): Likewise.
2291 * regcache.c (regcache::regcache): Change parameter to const.
2292 * regcache.h (regcache::regcache): Likewise.
2293 (regcache::aspace): Return const address_space *.
2294 (regcache) <m_aspace>: Add const.
2295
2296 2017-11-02 Yao Qi <yao.qi@linaro.org>
2297
2298 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
2299 * frame.c (create_sentinel_frame): Likewise.
2300 * infrun.c (displaced_step_prepare_throw): Likewise.
2301 (resume): Likewise.
2302 (thread_still_needs_step_over_bp): Likewise.
2303 (proceed): Likewise.
2304 (do_target_wait): Likewise.
2305 (adjust_pc_after_break): Likewise.
2306 (handle_syscall_event): Likewise.
2307 (save_waitstatus): Likewise.
2308 (handle_inferior_event_1): Likewise.
2309 (handle_signal_stop): Likewise.
2310 (keep_going_pass_signal): Likewise.
2311 * linux-nat.c (status_callback): Likewise.
2312 (save_stop_reason): Likewise.
2313 (resume_stopped_resumed_lwps): Likewise.
2314 * record-full.c (record_full_exec_insn): Likewise.
2315 (record_full_wait_1): Likewise.
2316 * regcache.c (get_regcache_aspace): Remove.
2317 * regcache.h (get_regcache_aspace): Remove.
2318
2319 2017-11-02 Yao Qi <yao.qi@linaro.org>
2320
2321 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
2322 (init_regcache_descr): Use gdbarch_num_regs.
2323 (regcache::regcache): Likewise.
2324 (regcache::get_register_status): Likewise.
2325 (regcache::assert_raw_regnum): Likewise.
2326 (regcache::cooked_read): Likewise.
2327 (regcache::cooked_read_value): Likewise.
2328 (regcache::cooked_write): Likewise.
2329 (regcache::dump): Likewise.
2330 (regcache::num_raw_registers): New method.
2331 * regcache.h (class regcache) <num_raw_registers>: New.
2332
2333 2017-11-02 Yao Qi <yao.qi@linaro.org>
2334
2335 * regcache.c (regcache::assert_regnum): New method.
2336 (regcache::invalidate): Call assert_regnum.
2337 (regcache::raw_update): Likewise.
2338 (regcache::raw_write): Likewise.
2339 (regcache::raw_read_part): Likewise.
2340 (regcache::raw_write_part): Likewise.
2341 (regcache::raw_supply): Likewise.
2342 (regcache::raw_supply_integer): Likewise.
2343 (regcache::raw_supply_zeroed): Likewise.
2344 (regcache::raw_collect): Likewise.
2345 (regcache::raw_collect_integer): Likewise.
2346 * regcache.h (regcache::assert_regnum): Declare.
2347
2348 2017-11-02 Yao Qi <yao.qi@linaro.org>
2349
2350 * regcache.c (regcache::dump): Remove code.
2351
2352 2017-11-02 Yao Qi <yao.qi@linaro.org>
2353
2354 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
2355 Remove.
2356 <sizeof_cooked_register_status>: Remove.
2357 (init_regcache_descr): Update.
2358 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
2359 (regcache::save): Likewise.
2360 (regcache::dump): Likewise.
2361
2362 2017-11-01 James Bowman <james.bowman@ftdichip.com>
2363
2364 * ft32-tdep.c (ft32_fetch_instruction): New function.
2365 (ft32_analyze_prologue): Use ft32_fetch_instruction().
2366
2367 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
2368
2369 * cli/cli-script.c (execute_control_command): Rename to ...
2370 (execute_control_command_1): ... this.
2371 (execute_control_command): New function.
2372
2373 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
2374
2375 * tracepoint.c (tfind_command): Remove const_cast.
2376
2377 2017-10-30 Mike Gulick <mgulick@mathworks.com>
2378
2379 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
2380
2381 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
2382
2383 * common/common-utils.h (in_inclusive_range): New function.
2384 * arm-tdep.c (arm_record_extension_space): Use
2385 in_inclusive_range.
2386 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
2387 * cris-tdep.c (cris_spec_reg_applicable): Use
2388 in_inclusive_range.
2389
2390 2017-10-30 Pedro Alves <palves@redhat.com>
2391 Simon Marchi <simon.marchi@ericsson.com>
2392
2393 * remote.c (remote_set_syscall_catchpoint): Build a std::string
2394 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
2395
2396 2017-10-30 Pedro Alves <palves@redhat.com>
2397
2398 * common/common-utils.c (string_appendf, string_vappendf): New
2399 functions.
2400 * common/common-utils.h (string_appendf, string_vappendf): New
2401 declarations.
2402 * unittests/common-utils-selftests.c (string_appendf_func)
2403 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
2404 (string_vappendf_tests): New functions.
2405 (_initialize_common_utils_selftests): Register "string_appendf" and
2406 "string_vappendf tests".
2407
2408 2017-10-30 Pedro Alves <palves@redhat.com>
2409
2410 * unittests/common-utils-selftests.c (format_func): New typedef.
2411 (string_printf_tests, string_vprintf_tests): Tests factored out
2412 and merged to ...
2413 (test_format_func): ... this new function.
2414 (string_printf_tests, string_vprintf_tests): Reimplement on top of
2415 test_format_func.
2416
2417 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2418
2419 * darwin-nat.c: Remove include of gdb.h.
2420
2421 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2422
2423 * xtensa-xtregs.c: Fix formatting issues.
2424
2425 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2426
2427 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
2428
2429 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
2430
2431 PR python/21213
2432 * python/py-infthread.c (thpy_get_inferior): Increment reference
2433 of inferior before returning it.
2434
2435 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2436
2437 * unittests/common-utils-selftests.c (format): Add
2438 ATTRIBUTE_PRINTF.
2439
2440 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
2441
2442 * xml-syscall.c (struct syscall_desc): Add constructor.
2443 <name>: Change type to std::string.
2444 (syscall_desc_up): New typedef.
2445 (syscall_desc_p): Remove typeder.
2446 (DEF_VEC_P(syscall_desc_p)): Remove.
2447 (struct syscall_group_desc): Add constructor.
2448 <name>: Change type to std::string.
2449 <syscalls>: Change type to std::vector.
2450 (syscall_group_desc_up): New typedef.
2451 (syscall_group_desc_p): Remove typedef.
2452 (DEF_VEC_P(syscall_group_desc_p)): Remove.
2453 (struct syscalls_info) <syscalls>: Change type to std::vector of
2454 unique_ptr.
2455 <groups>: Likewise.
2456 <my_gdb_datadir>: Change type to std::string.
2457 (syscalls_info_up): New typedef.
2458 (allocate_syscalls_info): Remove.
2459 (syscalls_info_free_syscalls_desc): Remove.
2460 (syscalls_info_free_syscall_group_desc): Remove.
2461 (free_syscalls_info): Remove.
2462 (make_cleanup_free_syscalls_info): Remove.
2463 (syscall_group_create_syscall_group_desc): Adjust.
2464 (syscall_group_add_syscall): Adjust.
2465 (syscall_create_syscall_desc): Adjust.
2466 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
2467 (init_syscalls_info): Adjust.
2468 (syscall_group_get_group_by_name): Adjust.
2469 (xml_get_syscall_number): Adjust.
2470 (xml_get_syscall_name): Adjust.
2471 (xml_list_of_syscalls): Adjust.
2472 (xml_list_syscalls_by_group): Adjust.
2473 (xml_list_of_groups): Adjust.
2474
2475 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2476
2477 * probe.h: Don't include gdb_vecs.h.
2478 (DEF_VEC_P (probe_p)): Remove.
2479 (find_probes_in_objfile): Return an std::vector.
2480 * probe.c (find_probes_in_objfile): Likewise.
2481 * breakpoint.c (breakpoint_objfile_data)
2482 <longjmp_probes>: Change type to std::vector.
2483 <exception_probes>: Likewise.
2484 (free_breakpoint_probes): Don't manually free vectors.
2485 (create_longjmp_master_breakpoint): Adjust.
2486 (create_exception_master_breakpoint): Adjust.
2487 * solib-svr4.c (svr4_create_probe_breakpoints): Change
2488 parameter type, adjust.
2489 (svr4_create_solib_event_breakpoints): Adjust.
2490
2491 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2492
2493 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
2494 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
2495 with new.
2496 (free_breakpoint_probes): Rename to ...
2497 (free_breakpoint_objfile_data): ... this, and call delete on
2498 bp_objfile_data..
2499
2500 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
2501
2502 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
2503 (loaded_script_ptr): Remove typedef.
2504 (DEF_VEC_P (loaded_script_ptr)): Remove.
2505 (struct collect_matching_scripts_data): Add constructor.
2506 <scripts_p>: Change type to (pointer to) std::vector.
2507 (collect_matching_scripts_data): Adjust.
2508 (sort_scripts_by_name): Make suitable for std::sort.
2509 (print_scripts): Don't sort vector, adjust to std::vector.
2510 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
2511
2512 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2513
2514 * symfile.c (filename_language): Make struct, not typedef. Add
2515 constructor.
2516 <ext>: Change type to std::string.
2517 (DEF_VEC_O (filename_language)): Remove.
2518 (filename_language_table): Change type to std::vector.
2519 (add_filename_language): Adjust.
2520 (set_ext_lang_command): Adjust.
2521 (info_ext_lang_command): Adjust.
2522 (deduce_language_from_filename): Adjust.
2523 (class scoped_restore_filename_language_table): Remove.
2524 (test_filename_language): Use scoped_restore.
2525 (test_set_ext_lang_command): Use scoped_restore, adjust to
2526 std::vector change.
2527
2528 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2529
2530 * symfile.c: Include selftest.h.
2531 (class scoped_restore_filename_language_table): New.
2532 (test_filename_language): New test.
2533 (test_set_ext_lang_command): New test.
2534 (_initialize_symfile): Register tests.
2535
2536 2017-10-27 Keith Seitz <keiths@redhat.com>
2537
2538 * breakpoint.c (print_breakpoint_location): Use the symbol saved
2539 in the bp_location, falling back to find_pc_sect_function when
2540 needed.
2541 (add_location_to_breakpoint): Save sal->symbol.
2542 * breakpoint.h (struct bp_location) <symbol>: New field.
2543 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
2544 * symtab.h (struct symtab_and_line) <symbol>: New field.
2545
2546 2017-10-26 Patrick Frants <osscontribute@gmail.com>
2547
2548 PR gdb/13669
2549 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
2550 to rewind obstack.
2551
2552 2017-10-26 Pedro Alves <palves@redhat.com>
2553
2554 * remote.c (remote_async_terminal_ours_p): Delete.
2555 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
2556 Remove references to 'remote_async_terminal_ours_p'.
2557
2558 2017-10-26 Yao Qi <yao.qi@linaro.org>
2559
2560 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
2561
2562 2017-10-26 Yao Qi <yao.qi@linaro.org>
2563
2564 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
2565 aspace const.
2566 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
2567 Likewise.
2568 * breakpoint.c (bpstat_check_location): Remove cast.
2569 (breakpoint_hit_catch_fork): Make aspce const.
2570 (breakpoint_hit_catch_solib): Likewise.
2571 (breakpoint_hit_catch_exec): Likewise.
2572 (breakpoint_hit_ranged_breakpoint): Likewise.
2573 (breakpoint_hit_watchpoint): Likewise.
2574 (base_breakpoint_breakpoint_hit): Likewise.
2575 (bkpt_breakpoint_hit): Likewise.
2576 (dprintf_breakpoint_hit): Likewise.
2577 (tracepoint_breakpoint_hit): Likewise.
2578 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
2579
2580 2017-10-26 Yao Qi <yao.qi@linaro.org>
2581
2582 * breakpoint.c (breakpoint_location_address_match): Change
2583 "struct address_space *" to "const address_space".
2584 (breakpoint_location_address_range_overlap): Likewise.
2585 (breakpoint_here_p): Likewise.
2586 (breakpoint_in_range_p): Likewise.
2587 (moribund_breakpoint_here_p): Likewise.
2588 (bp_location_inserted_here_p): Likewise.
2589 (software_breakpoint_inserted_here_p): Likewise.
2590 (hardware_breakpoint_inserted_here_p): Likewise.
2591 (hardware_watchpoint_inserted_in_range): Likewise.
2592 (bpstat_check_location): Likewise.
2593 (bpstat_stop_status): Likewise.
2594 (breakpoint_address_match): Likewise.
2595 (breakpoint_address_match_range): Likewise.
2596 (breakpoint_location_address_match): Likewise.
2597 (breakpoint_location_address_range_overlap): Likewise.
2598 (insert_single_step_breakpoint): Likewise.
2599 (breakpoint_has_location_inserted_here): Likewise.
2600 (single_step_breakpoint_inserted_here_p): Likewise.
2601 (pc_at_non_inline_function): Likewise.
2602 * breakpoint.h (bpstat_stop_status): Update declaration.
2603 (breakpoint_here_p): Likewise.
2604 (breakpoint_in_range_p): Likewise.
2605 (moribund_breakpoint_here_p): Likewise.
2606 (breakpoint_inserted_here_p): Likewise.
2607 (software_breakpoint_inserted_here_p): Likewise.
2608 (hardware_breakpoint_inserted_here_p): Likewise.
2609 (breakpoint_has_location_inserted_here): Likewise.
2610 (single_step_breakpoint_inserted_here_p): Likewise.
2611 (hardware_watchpoint_inserted_in_range): Likewise.
2612 (breakpoint_address_match): Likewise.
2613 (insert_single_step_breakpoint): Likewise.
2614 (pc_at_non_inline_function): Likewise.
2615 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
2616 * record.c (record_check_stopped_by_breakpoint): Likewise.
2617 * record.h (record_check_stopped_by_breakpoint): Likewise.
2618 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
2619
2620 2017-10-25 Yao Qi <yao.qi@linaro.org>
2621
2622 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
2623 regcache->arch () instead get_regcache_arch.
2624 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
2625 Likewise.
2626 (aarch64_fbsd_store_inferior_registers): Likewise.
2627 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
2628 (store_gregs_to_thread): Likewise.
2629 (fetch_fpregs_from_thread): Likewise.
2630 (store_fpregs_to_thread): Likewise.
2631 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
2632 (aarch64_store_return_value): Likewise.
2633 (aarch64_software_single_step): Likewise.
2634 * aix-thread.c (aix_thread_wait): Likewise.
2635 (supply_reg32): Likewise.
2636 (supply_sprs64): Likewise.
2637 (supply_sprs32): Likewise.
2638 (fill_gprs64): Likewise.
2639 (fill_gprs32): Likewise.
2640 (fill_sprs64): Likewise.
2641 (fill_sprs32): Likewise.
2642 (store_regs_user_thread): Likewise.
2643 (store_regs_kernel_thread): Likewise.
2644 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
2645 (alphabsd_store_inferior_registers): Likewise.
2646 * alpha-tdep.c (alpha_extract_return_value): Likewise.
2647 (alpha_store_return_value): Likewise.
2648 (alpha_deal_with_atomic_sequence): Likewise.
2649 (alpha_next_pc): Likewise.
2650 (alpha_software_single_step): Likewise.
2651 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
2652 (amd64bsd_store_inferior_registers): Likewise.
2653 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
2654 Likewise.
2655 (amd64_linux_store_inferior_registers): Likewise.
2656 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
2657 (amd64_collect_native_gregset): Likewise.
2658 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
2659 (amd64obsd_collect_uthread): Likewise.
2660 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
2661 (amd64_collect_fpregset): Likewise.
2662 (amd64_supply_fxsave): Likewise.
2663 (amd64_supply_xsave): Likewise.
2664 (amd64_collect_fxsave): Likewise.
2665 (amd64_collect_xsave): Likewise.
2666 * arc-tdep.c (arc_write_pc): Likewise.
2667 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
2668 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
2669 (arm_fbsd_store_inferior_registers): Likewise.
2670 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
2671 (store_vfp_regs): Likewise.
2672 (arm_linux_fetch_inferior_registers): Likewise.
2673 (arm_linux_store_inferior_registers): Likewise.
2674 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
2675 (arm_linux_sigreturn_next_pc): Likewise.
2676 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
2677 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
2678 (fetch_register): Likewise.
2679 (store_register): Likewise.
2680 * arm-tdep.c (arm_is_thumb): Likewise.
2681 (displaced_in_arm_mode): Likewise.
2682 (bx_write_pc): Likewise.
2683 (arm_get_next_pcs_addr_bits_remove): Likewise.
2684 (arm_software_single_step): Likewise.
2685 (arm_extract_return_value): Likewise.
2686 (arm_store_return_value): Likewise.
2687 (arm_write_pc): Likewise.
2688 * bfin-tdep.c (bfin_extract_return_value): Likewise.
2689 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
2690 (bsd_uthread_store_registers): Likewise.
2691 * core-regset.c (fetch_core_registers): Likewise.
2692 * corelow.c (get_core_registers): Likewise.
2693 * cris-tdep.c (cris_store_return_value): Likewise.
2694 (cris_extract_return_value): Likewise.
2695 (find_step_target): Likewise.
2696 (find_step_target): Likewise.
2697 (cris_software_single_step): Likewise.
2698 * ctf.c (ctf_fetch_registers): Likewise.
2699 * darwin-nat.c (cancel_breakpoint): Likewise.
2700 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
2701 * frv-tdep.c (frv_extract_return_value): Likewise.
2702 * ft32-tdep.c (ft32_store_return_value): Likewise.
2703 (ft32_extract_return_value): Likewise.
2704 * go32-nat.c (fetch_register): Likewise.
2705 (go32_fetch_registers): Likewise.
2706 (go32_store_registers): Likewise.
2707 (store_register): Likewise.
2708 * h8300-tdep.c (h8300_extract_return_value): Likewise.
2709 (h8300_store_return_value): Likewise.
2710 * hppa-linux-nat.c (fetch_register): Likewise.
2711 (store_register): Likewise.
2712 (hppa_linux_fetch_inferior_registers): Likewise.
2713 (hppa_linux_store_inferior_registers): Likewise.
2714 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
2715 (i386_darwin_store_inferior_registers): Likewise.
2716 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
2717 (gnu_store_registers): Likewise.
2718 * i386-linux-nat.c (fetch_register): Likewise.
2719 (store_register): Likewise.
2720 (supply_gregset): Likewise.
2721 (fill_gregset): Likewise.
2722 (i386_linux_fetch_inferior_registers): Likewise.
2723 (i386_linux_store_inferior_registers): Likewise.
2724 (i386_linux_resume): Likewise.
2725 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
2726 Likewise.
2727 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
2728 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
2729 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
2730 (i386obsd_collect_uthread): Likewise.
2731 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
2732 (i386_supply_gregset): Likewise.
2733 (i386_collect_gregset): Likewise.
2734 (i386_supply_fpregset): Likewise.
2735 (i386_collect_fpregset): Likewise.
2736 (i386_mpx_bd_base): Likewise.
2737 * i386-v4-nat.c (supply_fpregset): Likewise.
2738 (fill_fpregset): Likewise.
2739 * i387-tdep.c (i387_supply_fsave): Likewise.
2740 (i387_collect_fsave): Likewise.
2741 (i387_supply_fxsave): Likewise.
2742 (i387_collect_fxsave): Likewise.
2743 (i387_supply_xsave): Likewise.
2744 (i387_collect_xsave): Likewise.
2745 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
2746 (ia64_linux_store_registers): Likewise.
2747 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
2748 (ia64_extract_return_value): Likewise.
2749 (ia64_store_return_value): Likewise.
2750 (find_func_descr): Likewise.
2751 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
2752 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
2753 (inf_ptrace_store_registers): Likewise.
2754 * infrun.c (use_displaced_stepping): Likewise.
2755 (displaced_step_prepare_throw): Likewise.
2756 (resume): Likewise.
2757 (proceed): Likewise.
2758 (do_target_wait): Likewise.
2759 (adjust_pc_after_break): Likewise.
2760 (handle_inferior_event_1): Likewise.
2761 (handle_signal_stop): Likewise.
2762 (save_infcall_suspend_state): Likewise.
2763 (restore_infcall_suspend_state): Likewise.
2764 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
2765 * jit.c (jit_frame_prev_register): Likewise.
2766 * linux-nat.c (save_stop_reason): Likewise.
2767 (linux_nat_wait_1): Likewise.
2768 (resume_stopped_resumed_lwps): Likewise.
2769 * linux-record.c (record_linux_sockaddr): Likewise.
2770 (record_linux_msghdr): Likewise.
2771 (record_linux_system_call): Likewise.
2772 * linux-tdep.c (linux_collect_thread_registers): Likewise.
2773 * lm32-tdep.c (lm32_extract_return_value): Likewise.
2774 (lm32_store_return_value): Likewise.
2775 * m32c-tdep.c (m32c_read_flg): Likewise.
2776 (m32c_pseudo_register_read): Likewise.
2777 (m32c_pseudo_register_write): Likewise.
2778 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
2779 (m32r_linux_collect_gregset): Likewise.
2780 * m32r-tdep.c (m32r_store_return_value): Likewise.
2781 (m32r_extract_return_value): Likewise.
2782 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
2783 (m68kbsd_collect_fpregset): Likewise.
2784 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
2785 * m68k-linux-nat.c (fetch_register): Likewise.
2786 (old_fetch_inferior_registers): Likewise.
2787 (old_store_inferior_registers): Likewise.
2788 (store_regs): Likewise.
2789 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
2790 (m68k_svr4_store_return_value): Likewise.
2791 * m88k-tdep.c (m88k_store_arguments): Likewise.
2792 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
2793 (mi_cmd_data_write_register_values): Likewise.
2794 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
2795 (mips_fbsd_store_inferior_registers): Likewise.
2796 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
2797 (mips_fbsd_supply_gregs): Likewise.
2798 (mips_fbsd_collect_fpregs): Likewise.
2799 (mips_fbsd_collect_gregs): Likewise.
2800 (mips_fbsd_supply_fpregset): Likewise.
2801 (mips_fbsd_collect_fpregset): Likewise.
2802 (mips_fbsd_supply_gregset): Likewise.
2803 (mips_fbsd_collect_gregset): Likewise.
2804 * mips-linux-nat.c (supply_gregset): Likewise.
2805 (fill_gregset): Likewise.
2806 (supply_fpregset): Likewise.
2807 (fill_fpregset): Likewise.
2808 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
2809 (mips_fill_gregset): Likewise.
2810 (mips_supply_fpregset): Likewise.
2811 (mips_fill_fpregset): Likewise.
2812 (mips64_supply_gregset): Likewise.
2813 (micromips_linux_sigframe_validate): Likewise.
2814 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
2815 (mipsnbsd_fetch_inferior_registers): Likewise.
2816 (mipsnbsd_store_inferior_registers): Likewise.
2817 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
2818 (mipsnbsd_supply_gregset): Likewise.
2819 (mipsnbsd_iterate_over_regset_sections): Likewise.
2820 (mipsnbsd_supply_reg): Likewise.
2821 (mipsnbsd_supply_fpreg): Likewise.
2822 * mips-tdep.c (mips_in_frame_stub): Likewise.
2823 (mips_dummy_id): Likewise.
2824 (is_octeon_bbit_op): Likewise.
2825 (micromips_bc1_pc): Likewise.
2826 (extended_mips16_next_pc): Likewise.
2827 (mips16_next_pc): Likewise.
2828 (deal_with_atomic_sequence): Likewise.
2829 * moxie-tdep.c (moxie_process_readu): Likewise.
2830 * nios2-tdep.c (nios2_get_next_pc): Likewise.
2831 * nto-procfs.c (procfs_store_registers): Likewise.
2832 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
2833 (ppcfbsd_store_inferior_registers): Likewise.
2834 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
2835 (fetch_altivec_register): Likewise.
2836 (get_spe_registers): Likewise.
2837 (fetch_spe_register): Likewise.
2838 (fetch_altivec_registers): Likewise.
2839 (fetch_all_gp_regs): Likewise.
2840 (fetch_all_fp_regs): Likewise.
2841 (store_vsx_register): Likewise.
2842 (store_altivec_register): Likewise.
2843 (set_spe_registers): Likewise.
2844 (store_spe_register): Likewise.
2845 (store_altivec_registers): Likewise.
2846 (store_all_gp_regs): Likewise.
2847 (store_all_fp_regs): Likewise.
2848 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
2849 (ppc_linux_collect_gregset): Likewise.
2850 (ppc_canonicalize_syscall): Likewise.
2851 (ppc_linux_record_signal): Likewise.
2852 (ppu2spu_prev_register): Likewise.
2853 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
2854 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
2855 (ppcobsd_store_registers): Likewise.
2856 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
2857 Likewise.
2858 (ppc_ravenscar_generic_store_registers): Likewise.
2859 * procfs.c (procfs_fetch_registers): Likewise.
2860 (procfs_store_registers): Likewise.
2861 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
2862 (ravenscar_store_registers): Likewise.
2863 (ravenscar_prepare_to_store): Likewise.
2864 * record-btrace.c (record_btrace_fetch_registers): Likewise.
2865 * record-full.c (record_full_wait_1): Likewise.
2866 (record_full_registers_change): Likewise.
2867 (record_full_store_registers): Likewise.
2868 (record_full_core_fetch_registers): Likewise.
2869 (record_full_save): Likewise.
2870 (record_full_goto_insn): Likewise.
2871 * regcache.c (regcache_register_size): Likewise.
2872 (get_regcache_arch): Remove.
2873 (regcache_read_pc): Likewise.
2874 * regcache.h (get_regcache_arch): Remove.
2875 * remote-sim.c (gdbsim_fetch_register): Likewise.
2876 (gdbsim_store_register): Likewise.
2877 * remote.c (fetch_register_using_p): Likewise.
2878 (send_g_packet): Likewise.
2879 (remote_prepare_to_store): Likewise.
2880 (store_registers_using_G): Likewise.
2881 * reverse.c (save_bookmark_command): Likewise.
2882 (goto_bookmark_command): Likewise.
2883 * rs6000-aix-tdep.c (branch_dest): Likewise.
2884 * rs6000-nat.c (rs6000_ptrace64): Likewise.
2885 (fetch_register): Likewise.
2886 * rs6000-tdep.c (ppc_supply_reg): Likewise.
2887 (ppc_collect_reg): Likewise.
2888 (ppc_collect_gregset): Likewise.
2889 (ppc_collect_fpregset): Likewise.
2890 (ppc_collect_vsxregset): Likewise.
2891 (ppc_collect_vrregset): Likewise.
2892 (ppc_displaced_step_hw_singlestep): Likewise.
2893 (rs6000_pseudo_register_read): Likewise.
2894 (rs6000_pseudo_register_write): Likewise.
2895 * s390-linux-nat.c (supply_gregset): Likewise.
2896 (fill_gregset): Likewise.
2897 (s390_linux_fetch_inferior_registers): Likewise.
2898 * s390-linux-tdep.c (s390_write_pc): Likewise.
2899 (s390_software_single_step): Likewise.
2900 (s390_all_but_pc_registers_record): Likewise.
2901 (s390_linux_syscall_record): Likewise.
2902 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
2903 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
2904 (shnbsd_store_inferior_registers): Likewise.
2905 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
2906 (sh_extract_return_value_fpu): Likewise.
2907 (sh_store_return_value_nofpu): Likewise.
2908 (sh_corefile_supply_regset): Likewise.
2909 (sh_corefile_collect_regset): Likewise.
2910 * sh64-tdep.c (sh64_extract_return_value): Likewise.
2911 (sh64_store_return_value): Likewise.
2912 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
2913 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
2914 (sparc_store_inferior_registers): Likewise.
2915 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
2916 (sparc_ravenscar_prepare_to_store): Likewise.
2917 * sparc-tdep.c (sparc32_store_arguments): Likewise.
2918 (sparc_analyze_control_transfer): Likewise.
2919 (sparc_step_trap): Likewise.
2920 (sparc_software_single_step): Likewise.
2921 (sparc32_gdbarch_init): Likewise.
2922 (sparc_supply_rwindow): Likewise.
2923 (sparc_collect_rwindow): Likewise.
2924 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
2925 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
2926 (sparc64nbsd_collect_gregset): Likewise.
2927 (sparc64nbsd_supply_fpregset): Likewise.
2928 (sparc64nbsd_collect_fpregset): Likewise.
2929 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
2930 (sparc64_supply_gregset): Likewise.
2931 (sparc64_collect_gregset): Likewise.
2932 (sparc64_supply_fpregset): Likewise.
2933 (sparc64_collect_fpregset): Likewise.
2934 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
2935 * spu-tdep.c (spu_unwind_sp): Likewise.
2936 (spu2ppu_prev_register): Likewise.
2937 (spu_memory_remove_breakpoint): Likewise.
2938 * stack.c (return_command): Likewise.
2939 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
2940 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
2941 * tracefile.c (trace_save_ctf): Likewise.
2942 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
2943 (do_windows_store_inferior_registers): Likewise.
2944 (windows_resume): Likewise.
2945 * xtensa-linux-nat.c (fill_gregset): Likewise.
2946 (supply_gregset_reg): Likewise.
2947 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
2948 (xtensa_register_read_masked): Likewise.
2949 (xtensa_supply_gregset): Likewise.
2950 (xtensa_extract_return_value): Likewise.
2951 (xtensa_store_return_value): Likewise.
2952
2953 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
2954
2955 * doublest.c (floatformat_from_string): New function.
2956 * doublest.h (floatformat_from_string): Add prototype.
2957
2958 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
2959 (OP_FLOAT): ... this.
2960 * expression.h: Do not include "doublest.h".
2961 (union exp_element): Replace doubleconst and decfloatconst by
2962 new element floatconst.
2963 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
2964 (ada_evaluate_subexp): Likewise.
2965 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
2966 OP_DOUBLE and OP_DECFLOAT.
2967 * expprint.c (print_subexp_standard): Likewise.
2968 (dump_subexp_body_standard): Likewise.
2969 * breakpoint.c (watchpoint_exp_is_const): Likewise.
2970
2971 * parse.c: Include "dfp.h".
2972 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
2973 (write_exp_elt_floatcst): New function.
2974 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
2975 and OP_DECFLOAT.
2976 (operator_check_standard): Likewise.
2977 (parse_float): Do not accept suffix. Take type as input. Return bool.
2978 Return target format buffer instead of host DOUBLEST.
2979 Use floatformat_from_string and decimal_from_string to parse
2980 either binary or decimal floating-point types.
2981 (parse_c_float): Remove.
2982 * parser-defs.h: Do not include "doublest.h".
2983 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
2984 (write_exp_elt_floatcst): Add prototype.
2985 (parse_float): Update prototype.
2986 (parse_c_float): Remove.
2987
2988 * c-exp.y: Do not include "dfp.h".
2989 (typed_val_float): Use byte buffer instead of DOUBLEST.
2990 (typed_val_decfloat): Remove.
2991 (DECFLOAT): Remove.
2992 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2993 (parse_number): Update to new parse_float interface.
2994 Parse suffixes and determine type before calling parse_float.
2995 Handle decimal and binary FP types the same way.
2996
2997 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2998 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
2999 (parse_number): Update to new parse_float interface.
3000 Parse suffixes and determine type before calling parse_float.
3001
3002 * f-exp.y: Replace dval by typed_val_float.
3003 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3004 (parse_number): Use parse_float instead of atof.
3005
3006 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3007 (parse_go_float): Remove.
3008 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3009 (parse_number): Call parse_float instead of parse_go_float.
3010 Parse suffixes and determine type before calling parse_float.
3011
3012 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3013 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3014 (parse_number): Update to new parse_float interface.
3015 Parse suffixes and determine type before calling parse_float.
3016
3017 * m2-exp.y: Replace dval by byte buffer val.
3018 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3019 (parse_number): Call parse_float instead of atof.
3020
3021 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3022 (lex_number): Call parse_float instead of strtod.
3023 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
3024 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
3025 Use write_exp_elt_floatcst.
3026 (unit_testing): Remove static variable.
3027 (rust_type): Do not check unit_testing.
3028 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
3029
3030 * ada-exp.y (type_float, type_double): Remove.
3031 (typed_val_float): Use byte buffer instead of DOUBLEST.
3032 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3033 * ada-lex.l (processReal): Use parse_float instead of sscanf.
3034
3035 2017-10-25 Alan Hayward <alan.hayward@arm.com>
3036
3037 * aarch64-tdep.h (enum aarch64_regnum): Remove.
3038 * arch/aarch64.h: New file.
3039
3040 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3041
3042 * dfp.h (decimal_from_string): Use const reference for argument.
3043 * dfp.c (decimal_from_string): Likewise.
3044
3045 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3046
3047 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
3048 * sh64-tdep.c (sh64_do_fp_register): Likewise.
3049 * mips-tdep.c (mips_print_fp_register): Likewise.
3050
3051 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3052
3053 * common/format.h (enum argclass): Replace decfloat_arg by
3054 dec32float_arg, dec64float_arg, and dec128float_arg.
3055 * common/format.c (parse_format_string): Update to return
3056 new decimal float argument classes.
3057
3058 * printcmd.c (printf_decfloat): Rename to ...
3059 (printf_floating): ... this. Add argclass argument, and use it
3060 instead of parsing the format string again. Add support for
3061 binary floating-point values, using floatformat_to_string.
3062 Convert value to the target format if it doesn't already match.
3063 (ui_printf): Call printf_floating instead of printf_decfloat,
3064 also for double_arg / long_double_arg. Pass argclass.
3065
3066 * dfp.c (decimal_to_string): Add format string argument.
3067 * dfp.h (decimal_to_string): Likewise.
3068
3069 * doublest.c (floatformat_to_string): Add format string argument.
3070 * doublest.h (floatformat_to_string): Likewise.
3071
3072 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3073
3074 * doublest.c (floatformat_precision): New routine.
3075 (floatformat_to_string): Likewise.
3076 * doublest.c (floatformat_to_string): Add prototype.
3077
3078 * printcmd.c (print_scalar_formatted): Only call print_floating
3079 on floating-point types.
3080 * valprint.c: Do not include "floatformat.h".
3081 (generic_val_print_decfloat): Remove.
3082 (generic_val_print): Call generic_val_print_float for both
3083 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
3084 (print_floating): Use floatformat_to_string. Handle decimal float.
3085 (print_decimal_floating): Remove, merge into floatformat_to_string.
3086 * value.h (print_decimal_floating): Remove.
3087
3088 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
3089
3090 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3091
3092 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
3093
3094 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3095
3096 * memattr.h: Don't include vec.h.
3097 (struct mem_attrib): Initialize fields.
3098 <unknown>: New static method.
3099 (struct mem_region): Add constructors, operator<, initialize
3100 fields.
3101 * memattr.c: Include algorithm.
3102 (default_mem_attrib, unknown_mem_attrib): Remove.
3103 (user_mem_region_list): New global.
3104 (target_mem_region_list, mem_region_list): Change type to
3105 std::vector<mem_region>.
3106 (mem_use_target): Now a function.
3107 (target_mem_regions_valid): Change type to bool.
3108 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
3109 (require_user_regions): Adjust.
3110 (require_target_regions): Adjust.
3111 (create_mem_region): Adjust.
3112 (lookup_mem_region): Adjust.
3113 (invalidate_target_mem_regions): Adjust.
3114 (mem_clear): Rename to...
3115 (user_mem_clear): ... this, and adjust.
3116 (mem_command): Adjust.
3117 (info_mem_command): Adjust.
3118 (mem_enable, enable_mem_command, mem_disable,
3119 disable_mem_command): Adjust.
3120 (mem_delete): Adjust.
3121 (delete_mem_command): Adjust.
3122 * memory-map.h (parse_memory_map): Return an std::vector.
3123 * memory-map.c (parse_memory_map): Likewise.
3124 (struct memory_map_parsing_data): Add constructor.
3125 <memory_map>: Point to std::vector.
3126 (memory_map_start_memory): Adjust.
3127 (memory_map_end_memory): Adjust.
3128 (memory_map_end_property): Adjust.
3129 (clear_result): Remove.
3130 * remote.c (remote_memory_map): Return an std::vector.
3131 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
3132 Remove.
3133 (target_debug_print_mem_region_vector): New.
3134 * target-delegates.c: Regenerate.
3135 * target.h (mem_region_vector): New typedef.
3136 (to_memory_map): Return mem_region_vector.
3137 (target_memory_map): Return an std::vector.
3138 * target.c (target_memory_map): Return an std::vector.
3139 (flash_erase_command): Adjust.
3140
3141 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3142
3143 * memory-map.c (struct memory_map_parsing_data) <property_name>:
3144 Change type to std::string.
3145 (memory_map_start_property): Adjust.
3146 (memory_map_end_property): Adjust.
3147
3148 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
3149
3150 * infrun.h: Include common/byte-vector.h.
3151 (struct displaced_step_closure): New struct.
3152 (struct buf_displaced_step_closure): New struct.
3153 * infrun.c (displaced_step_closure::~displaced_step_closure):
3154 Provide default implementation.
3155 (displaced_step_clear): Deallocate step closure with delete.
3156 * aarch64-tdep.c (displaced_step_closure): Rename to ...
3157 (aarch64_displaced_step_closure): ... this, extend
3158 displaced_step_closure.
3159 (aarch64_displaced_step_data) <dsc>: Change type to
3160 aarch64_displaced_step_closure.
3161 (aarch64_displaced_step_copy_insn): Adjust to type change, use
3162 unique_ptr.
3163 (aarch64_displaced_step_fixup): Add cast for displaced step
3164 closure.
3165 * amd64-tdep.c (displaced_step_closure): Rename to ...
3166 (amd64_displaced_step_closure): ... this, extend
3167 displaced_step_closure.
3168 <insn_buf>: Change type to std::vector<gdb_byte>.
3169 <max_len>: Remove.
3170 (fixup_riprel): Change type of DSC parameter, adjust to type
3171 change of insn_buf.
3172 (fixup_displaced_copy): Change type of DSC parameter.
3173 (amd64_displaced_step_copy_insn): Instantiate
3174 amd64_displaced_step_closure.
3175 (amd64_displaced_step_fixup): Add cast for closure type, adjust
3176 to type change of insn_buf.
3177 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
3178 parameter DSC.
3179 (arm_linux_copy_svc): Likewise.
3180 (cleanup_kernel_helper_return): Likewise.
3181 (arm_catch_kernel_helper_return): Likewise.
3182 (arm_linux_displaced_step_copy_insn): Instantiate
3183 arm_displaced_step_closure.
3184 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
3185 (displaced_read_reg): Change type of parameter DSC.
3186 (branch_write_pc): Likewise.
3187 (load_write_pc): Likewise.
3188 (alu_write_pc): Likewise.
3189 (displaced_write_reg): Likewise.
3190 (arm_copy_unmodified): Likewise.
3191 (thumb_copy_unmodified_32bit): Likewise.
3192 (thumb_copy_unmodified_16bit): Likewise.
3193 (cleanup_preload): Likewise.
3194 (install_preload): Likewise.
3195 (arm_copy_preload): Likewise.
3196 (thumb2_copy_preload): Likewise.
3197 (install_preload_reg): Likewise.
3198 (arm_copy_preload_reg): Likewise.
3199 (cleanup_copro_load_store): Likewise.
3200 (install_copro_load_store): Likewise.
3201 (arm_copy_copro_load_store) Likewise.
3202 (thumb2_copy_copro_load_store): Likewise.
3203 (cleanup_branch): Likewise.
3204 (install_b_bl_blx): Likewise.
3205 (arm_copy_b_bl_blx): Likewise.
3206 (thumb2_copy_b_bl_blx): Likewise.
3207 (thumb_copy_b): Likewise.
3208 (install_bx_blx_reg): Likewise.
3209 (arm_copy_bx_blx_reg): Likewise.
3210 (thumb_copy_bx_blx_reg): Likewise.
3211 (cleanup_alu_imm): Likewise.
3212 (arm_copy_alu_imm): Likewise.
3213 (thumb2_copy_alu_imm): Likewise.
3214 (cleanup_alu_reg): Likewise.
3215 (install_alu_reg): Likewise.
3216 (arm_copy_alu_reg): Likewise.
3217 (thumb_copy_alu_reg): Likewise.
3218 (cleanup_alu_shifted_reg): Likewise.
3219 (install_alu_shifted_reg): Likewise.
3220 (arm_copy_alu_shifted_reg): Likewise.
3221 (cleanup_load): Likewise.
3222 (cleanup_store): Likewise.
3223 (arm_copy_extra_ld_st): Likewise.
3224 (install_load_store): Likewise.
3225 (thumb2_copy_load_literal): Likewise.
3226 (thumb2_copy_load_reg_imm): Likewise.
3227 (arm_copy_ldr_str_ldrb_strb): Likewise.
3228 (cleanup_block_load_all): Likewise.
3229 (cleanup_block_store_pc): Likewise.
3230 (cleanup_block_load_pc): Likewise.
3231 (arm_copy_block_xfer): Likewise.
3232 (thumb2_copy_block_xfer): Likewise.
3233 (cleanup_svc): Likewise.
3234 (install_svc): Likewise.
3235 (arm_copy_svc): Likewise.
3236 (thumb_copy_svc): Likewise.
3237 (arm_copy_undef): Likewise.
3238 (thumb_32bit_copy_undef): Likewise.
3239 (arm_copy_unpred): Likewise.
3240 (arm_decode_misc_memhint_neon): Likewise.
3241 (arm_decode_unconditional): Likewise.
3242 (arm_decode_miscellaneous): Likewise.
3243 (arm_decode_dp_misc): Likewise.
3244 (arm_decode_ld_st_word_ubyte): Likewise.
3245 (arm_decode_media): Likewise.
3246 (arm_decode_b_bl_ldmstm): Likewise.
3247 (arm_decode_ext_reg_ld_st): Likewise.
3248 (thumb2_decode_dp_shift_reg): Likewise.
3249 (thumb2_decode_ext_reg_ld_st): Likewise.
3250 (arm_decode_svc_copro): Likewise.
3251 (thumb2_decode_svc_copro): Likewise.
3252 (install_pc_relative): Likewise.
3253 (thumb_copy_pc_relative_16bit): Likewise.
3254 (thumb_decode_pc_relative_16bit): Likewise.
3255 (thumb_copy_pc_relative_32bit): Likewise.
3256 (thumb_copy_16bit_ldr_literal): Likewise.
3257 (thumb_copy_cbnz_cbz): Likewise.
3258 (thumb2_copy_table_branch): Likewise.
3259 (cleanup_pop_pc_16bit_all): Likewise.
3260 (thumb_copy_pop_pc_16bit): Likewise.
3261 (thumb_process_displaced_16bit_insn): Likewise.
3262 (decode_thumb_32bit_ld_mem_hints): Likewise.
3263 (thumb_process_displaced_32bit_insn): Likewise.
3264 (thumb_process_displaced_insn): Likewise.
3265 (arm_process_displaced_insn): Likewise.
3266 (arm_displaced_init_closure): Likewise.
3267 (arm_displaced_step_fixup): Add cast for closure.
3268 * arm-tdep.h: Include infrun.h.
3269 (displaced_step_closure): Rename to ...
3270 (arm_displaced_step_closure): ... this, extend
3271 displaced_step_closure.
3272 <u::svc::copy_svc_os>: Change type of parameter DSC.
3273 <cleanup>: Likewise.
3274 (arm_process_displaced_insn): Likewise.
3275 (arm_displaced_init_closure): Likewise.
3276 (displaced_read_reg): Likewise.
3277 (displaced_write_reg): Likewise.
3278 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
3279 Adjust.
3280 * i386-tdep.h: Include infrun.h.
3281 (i386_displaced_step_closure): New typedef.
3282 * i386-tdep.c (i386_displaced_step_copy_insn): Use
3283 i386_displaced_step_closure.
3284 (i386_displaced_step_fixup): Adjust.
3285 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
3286 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
3287 and unique_ptr.
3288 (ppc_displaced_step_fixup): Adjust.
3289 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
3290 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
3291 and unique_ptr.
3292 (s390_displaced_step_fixup): Adjust.
3293
3294 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
3295
3296 * interps.h (interp_resume, interp_suspend, interp_set_temp):
3297 Remove declarations.
3298
3299 2017-10-20 Tom Tromey <tom@tromey.com>
3300
3301 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
3302 std::vector.
3303 (gdb_bfd_record_inclusion): Update.
3304 (bfdp): Remove typedef.
3305
3306 2017-10-20 Tom Tromey <tom@tromey.com>
3307
3308 * gdb_bfd.c (gdb_bfd_ref): Use new.
3309 (struct gdb_bfd_data): Add constructor, destructor, and member
3310 initializers.
3311 (gdb_bfd_unref): Use delete.
3312
3313 2017-10-20 Tom Tromey <tom@tromey.com>
3314
3315 * exec.c (exec_file_attach): Use new_bfd_ref.
3316 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
3317 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
3318 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
3319 new_bfd_ref.
3320 * gdb_bfd.h (new_bfd_ref): New function.
3321
3322 2017-10-20 Pedro Alves <palves@redhat.com>
3323
3324 * main.c (captured_command_loop): Add attribute noinline.
3325
3326 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
3327
3328 * interps.c (struct interp_factory): Add constructor.
3329 (interp_factory_p): Remove typedef.
3330 (DEF_VEC_P(interp_factory_p)): Remove.
3331 (interpreter_factories): Change type to std::vector.
3332 (interp_factory_register): Adjust.
3333 (interp_lookup): Adjust.
3334 (interpreter_completer): Adjust.
3335
3336 2017-10-19 Tom Tromey <tom@tromey.com>
3337
3338 * break-catch-syscall.c (catch_syscall_completer): Use
3339 std::string, gdb::unique_xmalloc_ptr.
3340
3341 2017-10-19 Tom Tromey <tom@tromey.com>
3342
3343 * infcall.c (call_function_by_hand_dummy): Use std::string.
3344
3345 2017-10-19 Tom Tromey <tom@tromey.com>
3346
3347 * mi/mi-main.c (mi_cmd_execute): Update.
3348 * top.h (prepare_execute_command): Return scoped_value_mark.
3349 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
3350 Add move constructor.
3351 * top.c (prepare_execute_command): Return scoped_value_mark.
3352 (execute_command): Update.
3353
3354 2017-10-19 Pedro Alves <palves@redhat.com>
3355
3356 * xml-support.c (xml_fetch_content_from_file): Check fread's
3357 return.
3358
3359 2017-10-19 Pedro Alves <palves@redhat.com>
3360
3361 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
3362 async.
3363 (handle_error_fd): New function.
3364 (ser_base_async): Add/delete an event loop file handler for
3365 error_fd.
3366
3367 2017-10-19 Pedro Alves <palves@redhat.com>
3368
3369 * xml-support.c (xml_fetch_content_from_file): Don't read in
3370 chunks. Instead use fseek to determine the file's size, and read
3371 it in one go.
3372
3373 2017-11-18 Keith Seitz <keiths@redhat.com>
3374
3375 * c-exp.y (oper): Canonicalize conversion operators of user-defined
3376 types.
3377 Add whitespace to front of type name.
3378
3379 2017-10-18 Keith Seitz <keiths@redhat.com>
3380
3381 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
3382 DW_AT_accessibility.
3383
3384 2017-10-18 Yao Qi <yao.qi@linaro.org>
3385
3386 * features/tic6x-c62x-linux.c: Remove.
3387
3388 2017-10-17 Tom Tromey <tom@tromey.com>
3389
3390 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
3391 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
3392 (do_mixed_source_and_assembly): Likewise.
3393
3394 2017-10-17 Tom Tromey <tom@tromey.com>
3395
3396 * regcache.c (regcache::xfer_part): Remove assertion.
3397
3398 2017-10-17 Pedro Alves <palves@redhat.com>
3399
3400 * xml-support.c (xml_fetch_content_from_file): Call
3401 unique_ptr::release() instead unique_ptr::get() when passing
3402 through xrealloc.
3403
3404 2017-10-17 Yao Qi <yao.qi@linaro.org>
3405
3406 * regcache.c (regcache::xfer_part): Remove parameters read and
3407 write, add parameter is_raw. All callers are updated.
3408
3409 2017-10-16 Keith Seitz <keiths@redhat.com>
3410
3411 * c-typeprint.c (enum access_specifier): Moved here from
3412 c_type_print_base.
3413 (output_access_specifier): New function.
3414 (c_type_print_base): Consider typedefs when assessing
3415 whether access labels are needed.
3416 Use output_access_specifier as needed.
3417 Output access specifier for typedefs, if needed.
3418 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
3419 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
3420 fields.
3421 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
3422 accessor macros.
3423
3424 2017-10-16 Tom Tromey <tom@tromey.com>
3425
3426 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
3427 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
3428 * target.c (target_fileio_read_stralloc): Update.
3429 * sparc64-tdep.c (adi_is_addr_mapped): Update.
3430 * target.h (target_fileio_read_stralloc): Return
3431 unique_xmalloc_ptr.
3432
3433 2017-10-16 Tom Tromey <tom@tromey.com>
3434
3435 * xml-syscall.c (xml_init_syscalls_info): Update.
3436 * xml-support.c (xinclude_start_include): Update.
3437 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
3438 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
3439 (xml_fetch_content_from_file): Likewise.
3440 * osdata.c (get_osdata): Update.
3441 * target.h (target_read_stralloc, target_get_osdata): Return
3442 unique_xmalloc_ptr.
3443 * solib-aix.c (solib_aix_get_library_list): Update.
3444 * solib-target.c (solib_target_current_sos): Update.
3445 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
3446 * xml-tdesc.c (fetch_available_features_from_target): Update.
3447 (target_fetch_description_xml): Update.
3448 (file_read_description_xml): Update.
3449 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
3450 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
3451 (remote_pid_to_exec_file): Update.
3452 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
3453 (target_get_osdata): Likewise.
3454
3455 2017-10-16 Tom Tromey <tom@tromey.com>
3456
3457 * remote.c (remote_register_number_and_offset): Use std::vector.
3458 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
3459 (putpkt_binary): Use gdb::def_vector.
3460 (compare_sections_command): Use gdb::byte_vector.
3461
3462 2017-10-16 Tom Tromey <tom@tromey.com>
3463
3464 * ppc-linux-nat.c (hwdebug_insert_point): Use
3465 gdb::unique_xmalloc_ptr, XDUP.
3466
3467 2017-10-16 Tom Tromey <tom@tromey.com>
3468
3469 * probe.c (parse_probes): Use std::string.
3470 (info_probes_for_ops, enable_probes_command)
3471 (disable_probes_command): Remove cleanups.
3472
3473 2017-10-16 Tom Tromey <tom@tromey.com>
3474
3475 * buildsym.c (block_compar): Remove.
3476 (end_symtab_get_static_block): Use std::vector.
3477
3478 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
3479
3480 * memrange.h (struct mem_range): Define operator< and operator==.
3481 (mem_range_s): Remove.
3482 (DEF_VEC_O (mem_range_s)): Remove.
3483 (normalize_mem_ranges): Change parameter type to std::vector.
3484 * memrange.c (compare_mem_ranges): Remove.
3485 (normalize_mem_ranges): Change parameter type to std::vector,
3486 adjust to vector change.
3487 * exec.c (section_table_available_memory): Return vector, remove
3488 parameter.
3489 (section_table_read_available_memory): Adjust to std::vector
3490 change.
3491 * remote.c (remote_read_bytes): Adjust to std::vector
3492 change.
3493 * tracepoint.h (traceframe_available_memory): Change parameter
3494 type to std::vector.
3495 * tracepoint.c (traceframe_available_memory): Change parameter
3496 type to std::vector, adjust.
3497 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
3498 std::vector change.
3499 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3500 unittests/memrange-selftests.c.
3501 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
3502 * gdb/unittests/memrange-selftests.c: New file.
3503
3504 2017-10-16 Pedro Alves <palves@redhat.com>
3505
3506 * elfread.c (probe_key_free): Rename range-for variable.
3507 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
3508 (find_probe_by_pc, collect_probes): Rename range-for variable.
3509
3510 2017-10-16 Yao Qi <yao.qi@linaro.org>
3511
3512 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
3513 * features/tic6x-c62x.c: Remove.
3514 * features/tic6x-c64x-linux.c: Remove.
3515 * features/tic6x-c64x.c: Remove.
3516 * features/tic6x-c64xp-linux.c: Remove.
3517 * features/tic6x-c64xp.c: Remove.
3518 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
3519 initialize_tdesc_tic6x_*_linux functions.
3520 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
3521 initialize_tdesc_tic6x_* functions.
3522
3523 2017-10-16 Yao Qi <yao.qi@linaro.org>
3524
3525 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
3526 tic6x-c62x.
3527 * regformats/tic6x-c62x.dat: Remove.
3528 * regformats/tic6x-c64x.dat: Remove.
3529 * regformats/tic6x-c64xp.dat: Remove.
3530
3531 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
3532
3533 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
3534 (the !HAVE_LIBEXPAT version).
3535
3536 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
3537
3538 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
3539 const.
3540
3541 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3542
3543 * target.h: Include tracepoint.h.
3544 (enum trace_find_type): Move to tracepoint.h.
3545 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
3546 * tracepoint.h: Don't include target.h
3547 (enum trace_find_type): Move from target.h.
3548 (parse_traceframe_info): Return a unique ptr.
3549 * tracepoint.c (current_traceframe_info): Change type to unique
3550 ptr.
3551 (free_traceframe_info): Remove.
3552 (clear_traceframe_info): Don't manually free
3553 current_traceframe_info.
3554 (free_result): Remove.
3555 (parse_traceframe_info): Return a unique ptr.
3556 (get_traceframe_info): Adjust to unique ptr.
3557 * ctf.c (ctf_traceframe_info): Return a unique ptr.
3558 * remote.c (remote_traceframe_info): Return a unique ptr.
3559 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
3560 ptr.
3561 * target-debug.h (target_debug_print_traceframe_info_up): New
3562 macro.
3563 * target-delegates.c: Regenerate.
3564
3565 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3566
3567 * memrange.h (struct mem_range): Add constructors.
3568 * tracepoint.h (struct traceframe_info) <memory>: Change type to
3569 std::vector<mem_range>.
3570 * tracepoint.c (free_traceframe_info): Don't manually free
3571 vector.
3572 (traceframe_info_start_memory): Adjust to vector change.
3573 (traceframe_available_memory): Likewise.
3574 * tracefile-tfile.c (build_traceframe_info): Likewise.
3575 * ctf.c (ctf_traceframe_info): Likewise.
3576
3577 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3578
3579 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
3580 std::vector<int>.
3581 * tracepoint.c (free_traceframe_info): Deallocate with delete.
3582 (traceframe_info_start_tvar): Adjust to vector change.
3583 (parse_traceframe_info): Allocate with new.
3584 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
3585 vector change.
3586 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
3587 change.
3588 tfile_traceframe_info): Allocate with new.
3589 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
3590 change.
3591
3592 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3593
3594 * tracepoint.c (traceframe_info): Rename to...
3595 (current_traceframe_info): ...this.
3596 (clear_traceframe_info): Adjust.
3597 (get_traceframe_info): Adjust.
3598
3599 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
3600
3601 * nat/linux-osdata.c: Include algorithm.
3602 (compare_processes): Remove.
3603 (struct pid_pgid_entry): New struct.
3604 (linux_xfer_osdata_processgroups): Use std::vector instead of
3605 XNEWVEC.
3606
3607 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
3608
3609 * objfiles.h: Don't include symfile.h.
3610 (struct partial_symbol): Remove forward-declaration.
3611 (struct objfile) <global_psymbols, static_psymbols>: Change type
3612 to std::vector<partial_symbol *>.
3613 * objfiles.c (objfile::objfile): Don't memset those fields.
3614 (objfile::~objfile): Don't free those fields.
3615 * psympriv.h (struct psymbol_allocation_list): Remove
3616 forward-declaration.
3617 (add_psymbol_to_list): Change psymbol_allocation_list parameter
3618 to std::vector.
3619 (start_psymtab_common): Change parameters to std::vector.
3620 * psymtab.c: Include algorithm.
3621 (require_partial_symbols): Call shrink_to_fit.
3622 (find_pc_sect_psymbol): Adjust to vector change.
3623 (match_partial_symbol): Likewise.
3624 (lookup_partial_symbol): Likewise.
3625 (psym_relocate): Likewise.
3626 (dump_psymtab): Likewise.
3627 (recursively_search_psymtabs): Likewise.
3628 (compare_psymbols): Remove.
3629 (sort_pst_symbols): Adjust to vector change.
3630 (start_psymtab_common): Likewise.
3631 (end_psymtab_common): Likewise.
3632 (psymbol_bcache_full): De-constify return value.
3633 (add_psymbol_to_bcache): Likewise.
3634 (extend_psymbol_list): Remove.
3635 (append_psymbol_to_list): Adjust to vector change.
3636 (add_psymbol_to_list): Likewise.
3637 (init_psymbol_list): Likewise.
3638 (maintenance_info_psymtabs): Likewise.
3639 (maintenance_check_psymtabs): Likewise.
3640 * symfile.h (struct psymbol_allocation_list): Remove.
3641 * symfile.c (reread_symbols): Adjust to vector change.
3642 * dbxread.c (start_psymtab): Change type of parameters.
3643 (dbx_symfile_read): Adjust to vector change.
3644 (read_dbx_symtab): Likewise.
3645 (start_psymtab): Change type of parameters.
3646 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
3647 (create_partial_symtab): Likewise.
3648 (add_partial_symbol): Likewise.
3649 (write_one_signatured_type): Likewise.
3650 (recursively_write_psymbols): Likewise.
3651 * mdebugread.c (parse_partial_symbols): Likewise.
3652 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
3653 (scan_xcoff_symtab): Adjust to vector change.
3654 (xcoff_initial_scan): Likewise.
3655
3656 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
3657
3658 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
3659
3660 2017-10-13 Yao Qi <yao.qi@linaro.org>
3661
3662 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
3663 Remove s390x-*-expedite, add s390x-expedite.
3664
3665 2017-10-13 Yao Qi <yao.qi@linaro.org>
3666
3667 * features/s390-gs-linux64.c: Regenerated.
3668 * features/s390x-gs-linux64.c: Regenerated.
3669
3670 2017-10-13 Tom Tromey <tom@tromey.com>
3671
3672 * compile/compile-object-run.c (do_module_cleanup): Use delete.
3673 * solib.c (update_solib_list, reload_shared_libraries_1): Use
3674 delete.
3675 * symfile.c (symbol_file_add_with_addrs): Use new.
3676 (symbol_file_add_separate): Update comment.
3677 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
3678 * jit.c (jit_object_close_impl): Use new.
3679 (jit_unregister_code): Use delete.
3680 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
3681 (~objfile): Rename from free_objfile.
3682 (free_objfile_separate_debug, do_free_objfile_cleanup)
3683 (free_all_objfiles, objfile_purge_solibs): Use delete.
3684 * objfiles.h (struct objfile): Add constructor and destructor.
3685 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
3686 (allocate_objfile, free_objfile): Don't declare.
3687 (struct objstats): Add initializers.
3688
3689 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3690
3691 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
3692 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
3693 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
3694 * gdbarch.h: Regenerate.
3695 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
3696 Adjust comment.
3697 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
3698 (i386_displaced_step_fixup): Adjust comment.
3699 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
3700
3701 2017-10-12 Tom Tromey <tom@tromey.com>
3702
3703 * prologue-value.h (pv_area::store_would_trash): Return bool.
3704 (pv_area::find_reg): Likewise.
3705 * prologue-value.c (pv_area::store_would_trash): Return bool.
3706 (pv_area::find_reg): Likewise.
3707
3708 2017-10-12 Tom Tromey <tom@tromey.com>
3709
3710 * s390-linux-tdep.c (s390_store, s390_load)
3711 (s390_check_for_saved, s390_analyze_prologue): Update.
3712 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
3713 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
3714 * prologue-value.h (class pv_area): Move from prologue-value.c.
3715 Change names of members. Add constructor, destructor, member
3716 functions.
3717 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
3718 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
3719 (pv_area_fetch, pv_area_scan): Don't declare.
3720 * prologue-value.c (struct pv_area::area_entry): Now member of
3721 pv_area.
3722 (struct pv_area): Move to prologue-value.h.
3723 (pv_area::pv_area): Rename from make_pv_area.
3724 (pv_area::~pv_area): Rename from free_pv_area.
3725 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
3726 (clear_entries, find_entry, overlaps, store_would_trash, store)
3727 (fetch, find_reg, scan): Now member of pv_area.
3728 Remove "area" argument. Update.
3729 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
3730 Update.
3731 * mn10300-tdep.c (push_reg, check_for_saved)
3732 (mn10300_analyze_prologue): Update.
3733 * mep-tdep.c (is_arg_spill, check_for_saved)
3734 (mep_analyze_prologue): Update.
3735 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
3736 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
3737 (m32c_is_struct_return, m32c_analyze_prologue): Update.
3738 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
3739 Update.
3740 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
3741 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
3742
3743 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3744
3745 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
3746 * linux-nat.c (linux_nat_delete_thread): New variable.
3747 (lwp_free): Invoke linux_nat_delete_thread if set.
3748 (linux_nat_set_delete_thread): New function.
3749 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
3750 thread delete callback.
3751 * arm-linux-nat.c (arm_linux_delete_thread): New function.
3752 (_initialize_arm_linux_nat): Assign thread delete callback.
3753 * s390-linux-nat.c (s390_delete_thread): New function.
3754 (_initialize_s390_nat): Assign thread delete callback.
3755 * x86-linux-nat.c (x86_linux_add_target): Likewise.
3756 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
3757 function.
3758 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
3759 declaration.
3760 * nat/x86-linux.c (x86_linux_delete_thread): New function.
3761 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
3762
3763 2017-10-09 Tom Tromey <tom@tromey.com>
3764
3765 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
3766 std::string.
3767 * tui/tui-layout.c (enum tui_status): Use std::string.
3768
3769 2017-10-11 Tom Tromey <tom@tromey.com>
3770
3771 * gdbthread.h (thread_command): Constify.
3772 * inferior.h (detach_command): Constify.
3773 * top.h (set_history, show_history): Constify.
3774 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
3775 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
3776 * bsd-kvm.c (bsd_kvm_cmd): Constify.
3777 * printcmd.c (set_command): Constify.
3778 (non_const_set_command): New function.
3779 * dcache.c (set_dcache_command, show_dcache_command): Constify.
3780 * breakpoint.c (enable_command, disable_command, delete_command)
3781 (catch_command, tcatch_command, set_breakpoint_cmd)
3782 (show_breakpoint_cmd): Constify.
3783 * macrocmd.c (macro_command): Constify.
3784 * infcmd.c (unset_command, kill_command, detach_command)
3785 (info_proc_cmd): Constify.
3786 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
3787 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
3788 (info_auto_load_cmd): Constify.
3789 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
3790 (unset_tdesc_cmd): Constify.
3791 * ada-lang.c (set_ada_command, show_ada_command)
3792 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
3793 * guile/guile.c (set_guile_command, show_guile_command)
3794 (info_guile_command): Constify.
3795 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
3796 Constify.
3797 * skip.c (skip_command): Constify.
3798 * compile/compile.c (_initialize_compile): Constify.
3799 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
3800 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
3801 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
3802 (maint_btrace_pt_show_cmd): Constify.
3803 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
3804 Constify.
3805 * python/python.c (user_show_python, user_set_python): Constify.
3806 * mips-tdep.c (set_mips_command, show_mips_command)
3807 (set_mipsfpu_command): Constify.
3808 * record-btrace.c (cmd_record_btrace_start)
3809 (cmd_set_record_btrace, cmd_show_record_btrace)
3810 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
3811 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
3812 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
3813 Constify.
3814 * symfile.c (overlay_command): Constify.
3815 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
3816 * cli/cli-logging.c (set_logging_command, show_logging_command):
3817 Constify.
3818 * cli/cli-dump.c (dump_command, append_command)
3819 (srec_dump_command, ihex_dump_command, verilog_dump_command)
3820 (tekhex_dump_command, binary_dump_command)
3821 (binary_append_command): Constify.
3822 * cli/cli-decode.c (struct cmd_list_element): Change type of
3823 "fun".
3824 * cli/cli-cmds.c (info_command, show_command, set_debug)
3825 (show_debug): Constify.
3826 (show_command): Add non-const overload.
3827 * top.c (set_history, show_history): Constify.
3828 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
3829 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
3830 * target.c (target_command): Constify.
3831 * sparc64-tdep.c (info_adi_command): Constify.
3832 * record-full.c (cmd_record_full_start): Constify.
3833 (set_record_full_command): Constify. Fix typo.
3834 (show_record_full_command): Constify.
3835 * thread.c (thread_command, thread_apply_command): Constify.
3836 * memattr.c (dummy_cmd): Constify.
3837 * value.c (function_command): Constify.
3838 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
3839 * probe.c (info_probes_command): Constify.
3840 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
3841 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
3842 (show_thread_cmd, set_thread_default_cmd)
3843 (show_thread_default_cmd): Constify.
3844 (check_empty): Constify.
3845 * tracepoint.c (tfind_command): Constify.
3846 * cp-support.c (maint_cplus_command): Constify.
3847 * windows-tdep.c (info_w32_command): Constify.
3848 * record.c (cmd_record_start, set_record_command)
3849 (show_record_command, info_record_command, cmd_record_goto):
3850 Constify.
3851 * ravenscar-thread.c (set_ravenscar_command)
3852 (show_ravenscar_command): Constify.
3853 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
3854 Constify.
3855 (add_internal_problem_command): Remove casts.
3856 * arc-tdep.c (maintenance_print_arc_command): Constify.
3857 * valprint.c (set_print, show_print, set_print_raw)
3858 (show_print_raw): Constify.
3859 * maint.c (maintenance_command, maintenance_info_command)
3860 (maintenance_print_command, maintenance_set_cmd)
3861 (maintenance_show_cmd, set_per_command_cmd)
3862 (show_per_command_cmd, maintenance_check_command): Constify.
3863 * language.c (set_check, show_check): Constify.
3864 * typeprint.c (show_print_type, set_print_type): Constify.
3865 * go32-nat.c (go32_info_dos_command): Constify.
3866
3867 2017-10-11 Tom Tromey <tom@tromey.com>
3868
3869 * breakpoint.c (prepare_re_set_context): Remove.
3870 (breakpoint_re_set_one): Update. Don't use cleanups.
3871 (breakpoint_re_set): Use scoped_restore, std::string, and
3872 scoped_restore_current_language.
3873
3874 2017-10-11 Tom Tromey <tom@tromey.com>
3875
3876 * breakpoint.c (commands_command_1): Use std::string.
3877 (cleanup_executing_breakpoints): Remove.
3878 (bpstat_do_actions_1): Use scoped_restore.
3879 (bpstat_check_watchpoint): Use std::string.
3880 (decode_static_tracepoint_spec): Likewise.
3881 (break_range_command): Likewise.
3882 (watch_command_1): Likewise.
3883 (compare_breakpoints): Change argument types.
3884 (clear_command): Use std::vector.
3885 (cleanup_executing_breakpoints): Remove.
3886 (update_global_location_list): Use unique_xmalloc_ptr.
3887 (strace_command): Remove unused declaration.
3888
3889 2017-10-11 John Baldwin <jhb@FreeBSD.org>
3890
3891 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
3892 * NEWS: Mention new FreeBSD/arm native configuration.
3893 * configure.host: Add arm*-*-freebsd*.
3894 * configure.nat: Likewise.
3895 * arm-fbsd-nat.c: New file.
3896
3897 2017-10-11 John Baldwin <jhb@FreeBSD.org>
3898
3899 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
3900 (ALLDEPFILES): Add arm-fbsd-tdep.c.
3901 * NEWS: Mention new FreeBSD/arm target.
3902 * configure.tgt: Add arm*-*-freebsd*.
3903 * arm-fbsd-tdep.c: New file.
3904 * arm-fbsd-tdep.h: New file.
3905
3906 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
3907
3908 * linux-tdep.c (linux_make_corefile_notes): Remove call to
3909 `gdbarch_elfcore_write_linux_prpsinfo'.
3910 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
3911 method.
3912 (elf_internal_linux_prpsinfo): Remove declaration.
3913 * gdbarch.h: Regenerate.
3914 * gdbarch.c: Regenerate.
3915
3916 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
3917
3918 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
3919 `set_gdbarch_elfcore_write_linux_prpsinfo'.
3920
3921 2017-10-11 Pedro Alves <palves@redhat.com>
3922
3923 * breakpoint.c (reattach_breakpoints): Delete.
3924 * breakpoint.h (reattach_breakpoints): Delete.
3925
3926 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
3927
3928 * symfile.c (registered_sym_fns): Make struct, not typedef.
3929 (DEF_VEC_O (registered_sym_fns)): Remove.
3930 (symtab_fns): Change type to std::vector.
3931 (add_symtab_fns): Adjust.
3932 (find_sym_fns): Adjust.
3933
3934 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
3935
3936 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
3937 * arc-tdep.h (arc_arch_is_em): New function.
3938 (arc_arch_is_hs): Likewise.
3939
3940 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
3941
3942 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
3943 parentheses in the declaration.
3944 (macro_lookup_inclusion): Likewise.
3945 (macro_lookup_definition): Likewise.
3946 * p-lang.h (pascal_builtin_types): Likewise.
3947 * tui/tui-data.c (tui_win_list): Likewise.
3948 * tui/tui-data.h (tui_win_list): Likewise.
3949 * utils.h (make_cleanup_free_section_addr_info): Likewise.
3950
3951 2017-10-11 Mark Rages <markrages@gmail.com>
3952
3953 * target-memory.c (block_boundaries): Fix for block address not
3954 aligned on block size.
3955
3956 2017-10-10 Pedro Alves <palves@redhat.com>
3957 Tom Tromey <tom@tromey.com>
3958
3959 * breakpoint.c (struct captured_breakpoint_query_args)
3960 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
3961 (print_breakpoint): New.
3962 * breakpoint.h (print_breakpoint): Declare.
3963 * common/common-exceptions.h (enum return_reason): Remove
3964 references to catch_exceptions.
3965 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
3966 Delete.
3967 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
3968 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
3969 * gdb.h: Delete.
3970 * gdbthread.h (thread_select): Declare.
3971 * mi/mi-cmd-break.c: Don't include gdb.h.
3972 (breakpoint_notify): Use print_breakpoint.
3973 * mi/mi-cmd-catch.c: Don't include gdb.h.
3974 * mi/mi-interp.c: Don't include gdb.h.
3975 (mi_print_breakpoint_for_event): New.
3976 (mi_breakpoint_created, mi_breakpoint_modified): Use
3977 mi_print_breakpoint_for_event.
3978 * mi/mi-main.c: Don't include gdb.h.
3979 (mi_cmd_thread_select): Parse the global thread ID here. Use
3980 thread_select instead of gdb_thread_select.
3981 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
3982 of using gdb_list_thread_ids.
3983 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
3984 FILEIO_ENOSYS here.
3985 (remote_fileio_request): Use TRY/CATCH instead of
3986 catch_exceptions.
3987 * symfile-mem.c (struct symbol_file_add_from_memory_args)
3988 (symbol_file_add_from_memory_wrapper): Delete.
3989 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
3990 * thread.c: Don't include gdb.h.
3991 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
3992 (thread_alive): Use thread_select.
3993 (do_captured_thread_select): Delete, parts salvaged as ...
3994 (thread_select): ... this new function.
3995 (gdb_thread_select): Delete.
3996
3997 2017-10-10 Pedro Alves <palves@redhat.com>
3998 Tom Tromey <tom@tromey.com>
3999
4000 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
4001 and reverse logic.
4002 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
4003 No longer macros. Instead ...
4004 (enum wp_check_result): They're now values of this new
4005 enumeration.
4006 (watchpoint_check): Change return type to wp_check_result and
4007 parameter type to bpstat.
4008 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
4009 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
4010 catch_errors. Reverse logic of watchpoint_check call.
4011 (breakpoint_re_set_one): Now returns void and takes a breakpoint
4012 pointer as parameter.
4013 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
4014 * common/common-exceptions.c (throw_exception_sjlj): Update
4015 comments to avoid mentioning catch_errors.
4016 * exceptions.c (catch_errors): Delete.
4017 * exceptions.h: Update comments to avoid mentioning catch_errors.
4018 (catch_errors_ftype, catch_errors): Delete.
4019 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
4020 (hook_stop_stub): Delete.
4021 (restore_selected_frame): Change return type to void, and
4022 parameter type to const frame_id &.
4023 (restore_infcall_control_state): Use TRY/CATCH instead of
4024 catch_errors.
4025 * main.c (captured_command_loop): Return void and remove
4026 parameter. Remove references to catch_errors.
4027 (captured_main): Use TRY/CATCH instead of catch_errors.
4028 * objc-lang.c (objc_submethod_helper_data)
4029 (find_objc_msgcall_submethod_helper): Delete.
4030 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
4031 catch_errors.
4032 * record-full.c (record_full_message): Return void.
4033 (record_full_message_args, record_full_message_wrapper): Delete.
4034 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
4035 instead of catch_errors.
4036 * solib-aix.c (solib_aix_open_symbol_file_object): Change
4037 parameter type to int.
4038 * solib-darwin.c (open_symbol_file_object): Ditto.
4039 * solib-dsbt.c (open_symbol_file_object): Ditto.
4040 * solib-frv.c (open_symbol_file_object): Ditto.
4041 * solib-svr4.c (open_symbol_file_object): Ditto.
4042 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
4043 * solib.c (update_solib_list): Use TRY/CATCH instead of
4044 catch_errors.
4045 * solist.h (struct target_so_ops) <open_symbol_file_object>:
4046 Change type.
4047 * symmisc.c (struct print_symbol_args): Remove.
4048 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
4049 (print_symbol): Change type.
4050 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
4051 and remove parameters.
4052 (catch_errors): New.
4053 (get_windows_debug_event): Adjust.
4054
4055 2017-10-09 Tom Tromey <tom@tromey.com>
4056
4057 * mi/mi-main.c (free_splay_tree): Remove.
4058 (list_available_thread_groups): Use splay_tree_up.
4059 * common/gdb_splay_tree.h: New file.
4060
4061 2017-10-09 Tom Tromey <tom@tromey.com>
4062
4063 * mi/mi-main.c (do_nothing): Remove.
4064 (list_available_thread_groups): Update.
4065
4066 2017-10-09 Pedro Alves <palves@redhat.com>
4067
4068 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
4069 reading registers when switching context.
4070
4071 2017-10-09 John Baldwin <jhb@FreeBSD.org>
4072
4073 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
4074 (fbsd_convert_siginfo): Likewise.
4075 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
4076
4077 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
4078
4079 * configure.ac (try_guile_versions): Remove guile-2.2.
4080 * configure: Regenerate.
4081
4082 2017-10-09 Tom Tromey <tom@tromey.com>
4083
4084 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
4085 (COMPILE.pre): Use $(CXX).
4086
4087 2017-10-09 Pedro Alves <palves@redhat.com>
4088
4089 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
4090 Use bool.
4091 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
4092 * cp-support.h (cp_remove_params): Now returns a
4093 gdb::unique_xmalloc_ptr.
4094 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
4095 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
4096 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
4097 returning a gdb::unique_xmalloc_ptr.
4098 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
4099 * stack.c (find_frame_funname): Adjust to cp_remove_params
4100 returning a gdb::unique_xmalloc_ptr.
4101
4102 2017-10-08 Tom Tromey <tom@tromey.com>
4103
4104 * dwarf2read.c (dwarf2_get_dwz_file): Use
4105 gdb::unique_xmalloc_ptr.
4106 (find_slot_in_mapped_hash): Likewise.
4107 (dwarf2_physname): Likewise.
4108 (create_dwo_unit_in_dwp_v1): Use std::string.
4109 (create_dwo_unit_in_dwp_v2): Likewise.
4110 (lookup_dwo_cutu): Likewise.
4111 (inherit_abstract_dies): Use std::vector.
4112 (read_array_type): Likewise.
4113 (dwarf_decode_macros): Remove unused declaration.
4114 (unsigned_int_compar): Remove.
4115 (dwarf2_build_psymtabs_hard): Use scoped_restore.
4116 (psymtabs_addrmap_cleanup): Remove.
4117
4118 2017-10-08 Tom Tromey <tom@tromey.com>
4119
4120 * frame-unwind.c (frame_unwind_try_unwinder): Update.
4121 * frame.h (frame_cleanup_after_sniffer): Declare.
4122 (frame_prepare_for_sniffer): Return void.
4123 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
4124 type of argument.
4125 (frame_prepare_for_sniffer): Return void.
4126
4127 2017-10-08 Tom Tromey <tom@tromey.com>
4128
4129 * utils.h (make_cleanup_value_free): Remove.
4130 * utils.c (do_value_free, struct cleanup): Remove.
4131 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
4132 Use gdb_value_up.
4133 * value.h (struct value_deleter): New.
4134 (gdb_value_up): New typedef.
4135
4136 2017-10-08 Tom Tromey <tom@tromey.com>
4137
4138 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
4139 (make_cleanup_free_search_symbols): Remove.
4140 (search_symbols): Return std::vector.
4141 (symbol_search::compare_search_syms): Now member of
4142 symbol_search. Change arguments.
4143 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
4144 (symtab_symbol_info, rbreak_command): Update.
4145 * symtab.h (struct symbol_search) <next>: Remove.
4146 Add constructors.
4147 (symbol_search::operator<): New function.
4148 (symbol_search::operator==): New function.
4149 (search_symbols): Remove std::vector.
4150 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
4151 (symbol_search::compare_search_syms): Declare.
4152
4153 2017-10-06 Yao Qi <yao.qi@linaro.org>
4154
4155 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
4156 arch/aarch64-insn.o.
4157 Remove one rule.
4158 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
4159
4160 2017-10-06 Yao Qi <yao.qi@linaro.org>
4161
4162 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
4163 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
4164 arch/arm-linux.o respectively.
4165 * configure.tgt: Likewise.
4166
4167 2017-10-06 Yao Qi <yao.qi@linaro.org>
4168
4169 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
4170 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
4171
4172 2017-10-06 Pedro Alves <palves@redhat.com>
4173
4174 * windows-nat.c: Include <algorithm>.
4175
4176 2017-10-06 Yao Qi <yao.qi@linaro.org>
4177
4178 * configure.tgt (i386_tobjs): New variable.
4179 (amd64_tobjs): New variable.
4180 Set $cpu_obs and $os_obs.
4181
4182 2017-10-06 Yao Qi <yao.qi@linaro.org>
4183
4184 * Makefile.in (CONFIG_SRC_SUBDIR): New.
4185 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
4186 (clean): Remove object files and dependency files.
4187 (distclean): Remove the directory.
4188 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4189 * configure: Re-generated.
4190 * configure.tgt: Replace amd64.o with arch/amd64.o.
4191
4192 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
4193
4194 PR build/22188
4195 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
4196 and SETEND.
4197
4198 2017-10-05 Pedro Alves <palves@redhat.com>
4199
4200 * linux-nat.c (linux_child_follow_fork): When following the parent
4201 and detaching the child, consult the parent thread's architecture
4202 instead of the child's.
4203
4204 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4205
4206 * ax.h: Do not include "doublest.h".
4207 (union agent_val): Remove.
4208
4209 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4210
4211 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
4212 (decimal_to_string): Return std::string object.
4213 (decimal_from_string): Accept std::string object. Return bool.
4214 (decimal_from_integral, decimal_from_doublest): Remove.
4215 (decimal_from_longest): Add prototype.
4216 (decimal_from_ulongest): Likewise.
4217 (decimal_to_longest): Likewise.
4218 (decimal_from_doublest): Likewise.
4219 * dfp.c: Do not include "gdbtypes.h" or "value.h".
4220 (MAX_DECIMAL_STRING): Move here.
4221 (decimal_to_string): Return std::string object.
4222 (decimal_from_string): Accept std::string object. Return bool.
4223 (decimal_from_integral): Remove, replace by ...
4224 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
4225 (decimal_to_longest): New function.
4226 (decimal_from_floating): Remove, replace by ...
4227 (decimal_from_doublest): ... this new function.
4228 (decimal_to_doublest): Update to new decimal_to_string interface.
4229
4230 * value.c (unpack_long): Use decimal_to_longest.
4231 * valops.c (value_cast): Use decimal_from_doublest instead of
4232 decimal_from_floating. Use decimal_from_[u]longest isntead of
4233 decimal_from_integral.
4234 * valarith.c (value_args_as_decimal): Likewise.
4235 * valprint.c (print_decimal_floating): Update to new
4236 decimal_to_string interface.
4237 * printcmd.c (printf_decfloat): Likewise.
4238 * c-exp.y (parse_number): Update to new decimal_from_string interface.
4239
4240 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4241
4242 * doublest.h: Do not include "floatformat.h". Remove stale comments.
4243 * gdbtypes.c: Include "floatformat.h".
4244 * value.c: Likewise.
4245 * m68k-tdep.c: Likewise.
4246
4247 * findvar.c: Do not include "floatformat.h".
4248 * amd64-darwin-tdep.c: Likewise.
4249 * arm-linux-tdep.c: Likewise.
4250 * i386-darwin-tdep.c: Likewise.
4251 * i387-tdep.c: Likewise.
4252 * m68k-linux-tdep.c: Likewise.
4253 * mep-tdep.c: Likewise.
4254 * mips-tdep.c: Likewise.
4255 * nios2-tdep.c: Likewise.
4256 * s390-linux-tdep.c: Likewise.
4257 * sparc-obsd-tdep.c: Likewise.
4258 * sparc-tdep.c: Likewise.
4259 * sparc64-tdep.c: Likewise.
4260 * spu-tdep.c: Likewise.
4261 * tic6x-tdep.c: Likewise.
4262 * tilegx-tdep.c: Likewise.
4263 * vax-tdep.c: Likewise.
4264 * xstormy16-tdep.c: Likewise.
4265 * xtensa-tdep.c: Likewise.
4266
4267 * top.c: Do not include "doublest.h".
4268 * aarch64-tdep.c: Likewise.
4269 * alpha-tdep.c: Likewise.
4270 * arm-linux-tdep.c: Likewise.
4271 * m68k-linux-tdep.c: Likewise.
4272 * tilegx-tdep.c: Likewise.
4273 * xstormy16-tdep.c: Likewise.
4274
4275 2017-10-05 John Baldwin <jhb@FreeBSD.org>
4276
4277 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
4278 (mipsn32_fbsd_sigframe): Define.
4279 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
4280 for FreeBSD/mipsn32.
4281
4282 2017-10-05 John Baldwin <jhb@FreeBSD.org>
4283
4284 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
4285 AT_HWCAP.
4286
4287 2017-10-05 Tristan Gingold <tgingold@free.fr>
4288
4289 * MAINTAINERS (Misc): Update my email address.
4290
4291 2017-10-04 Pedro Alves <palves@redhat.com>
4292
4293 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
4294 it instead of target_gdbarch.
4295 (get_remote_state, get_remote_packet_size): Adjust
4296 get_remote_arch_state calls, passing down target_gdbarch
4297 explicitly.
4298 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
4299 'gdbarch' and use it instead of target_gdbarch.
4300 (get_memory_packet_size): Adjust get_remote_arch_state calls,
4301 passing down target_gdbarch explicitly.
4302 (struct stop_reply) <arch>: New field.
4303 (remote_parse_stop_reply): Use the stopped thread's architecture,
4304 not the current inferior's. Save the architecture in the
4305 stop_reply.
4306 (process_stop_reply): Use the stop reply's architecture.
4307 (process_g_packet, remote_fetch_registers)
4308 (remote_prepare_to_store, store_registers_using_G)
4309 (remote_store_registers): Adjust get_remote_arch_state calls,
4310 using the regcache's architecture.
4311 (remote_get_trace_status): Adjust get_remote_arch_state calls,
4312 passing down target_gdbarch explicitly.
4313 * spu-multiarch.c (spu_thread_architecture): Defer to the target
4314 beneath instead of calling target_gdbarch.
4315 * target.c (default_thread_architecture): Use the specified
4316 inferior's architecture, instead of the current inferior's
4317 architecture (via target_gdbarch).
4318
4319 2017-10-04 Pedro Alves <palves@redhat.com>
4320
4321 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
4322 case.
4323 (regcache_print): Handle !target_has_registers here instead.
4324
4325 2017-10-04 Pedro Alves <palves@redhat.com>
4326
4327 * frame.c (create_test_frame): Delete.
4328 * frame.h (create_test_frame): Delete.
4329 * gdbarch-selftests.c: Include gdbthread.h and target.h.
4330 (class regcache_test): Delete.
4331 (test_target_has_registers, test_target_has_stack)
4332 (test_target_has_memory, test_target_prepare_to_store)
4333 (test_target_store_registers): New functions.
4334 (test_target_ops): New class.
4335 (register_to_value_test): Error out if there's already a
4336 process_stratum (or higher) target pushed. Create a fuller mock
4337 environment, with mock target_ops, inferior, address space, thread
4338 and inferior_ptid.
4339 * progspace.c (struct address_space): Move to ...
4340 * progspace.h (struct address_space): ... here.
4341 * regcache.h (regcache::~regcache, regcache::raw_write)
4342 [GDB_SELF_TEST]: No longer virtual.
4343
4344 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
4345
4346 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
4347
4348 2017-10-04 Pedro Alves <palves@redhat.com>
4349
4350 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
4351 out of 'between TRY and CATCH'.
4352
4353 2017-10-04 Pedro Alves <palves@redhat.com>
4354
4355 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
4356 * common/common-exceptions.h (TRY): Open an outermost scope.
4357 Expand intro comment.
4358 (CATCH): Reindent.
4359 (END_CATCH): Close the outermost scope.
4360 * completer.c (complete_line_internal): Add missing END_CATCH.
4361
4362 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4363
4364 * NEWS (Changes since GDB 8.0): Add entry about new
4365 'set-cwd-on-gdbserver' feature.
4366 (New remote packets): Add entry for QSetWorkingDir.
4367 * common/common-inferior.h (set_inferior_cwd): New prototype.
4368 * infcmd.c (set_inferior_cwd): Remove "static".
4369 (show_cwd_command): Expand text to include remote debugging.
4370 * remote.c: Add PACKET_QSetWorkingDir.
4371 (remote_protocol_features) <QSetWorkingDir>: New entry for
4372 PACKET_QSetWorkingDir.
4373 (extended_remote_set_inferior_cwd): New function.
4374 (extended_remote_create_inferior): Call
4375 "extended_remote_set_inferior_cwd".
4376 (_initialize_remote): Call "add_packet_config_cmd" for
4377 QSetWorkingDir.
4378
4379 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4380
4381 * NEWS (New commands): Mention "set/show cwd".
4382 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
4383 "cd" command's help text.
4384 * common/common-inferior.h (get_inferior_cwd): New prototype.
4385 * infcmd.c (inferior_cwd_scratch): New global variable.
4386 (set_inferior_cwd): New function.
4387 (get_inferior_cwd): Likewise.
4388 (set_cwd_command): Likewise.
4389 (show_cwd_command): Likewise.
4390 (_initialize_infcmd): Add "set/show cwd" commands.
4391 * inferior.h (class inferior) <cwd>: New field.
4392 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
4393 (fork_inferior): Change inferior's cwd before its execution.
4394 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
4395 to CreateProcess.
4396
4397 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4398
4399 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
4400 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
4401 (COMMON_OBS): Add gdb_tilde_expand.o.
4402 * common/gdb_tilde_expand.c: New file.
4403 * common/gdb_tilde_expand.h: Likewise.
4404
4405 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
4406
4407 * gdbarch.sh (objfile): Remove duplicate declaration.
4408 * gdbarch.h: Regenerate.
4409
4410 2017-10-03 Tom Tromey <tom@tromey.com>
4411
4412 * utils.c (internal_vproblem): Use string_vprintf.
4413
4414 2017-10-03 Tom Tromey <tom@tromey.com>
4415
4416 * printcmd.c (info_symbol_command): Use std::string.
4417
4418 2017-10-03 Tom Tromey <tom@tromey.com>
4419
4420 * top.c (gdb_safe_append_history): Use std::string.
4421
4422 2017-10-03 Tom Tromey <tom@tromey.com>
4423
4424 * event-top.c (stdin_event_handler): Update.
4425 * main.c (captured_main_1): Update.
4426 * top.h (make_delete_ui_cleanup): Remove.
4427 (struct ui): Add constructor and destructor.
4428 (new_ui, delete_ui): Remove.
4429 * top.c (make_delete_ui_cleanup): Remove.
4430 (new_ui_command): Use std::unique_ptr.
4431 (delete_ui_cleanup): Remove.
4432 (ui::ui): Rename from new_ui. Update.
4433 (free_ui): Remove.
4434 (ui::~ui): Rename from delete_ui. Update.
4435
4436 2017-10-03 Tom Tromey <tom@tromey.com>
4437
4438 * symfile.c (load_progress): Use gdb::byte_vector.
4439
4440 2017-10-03 Tom Tromey <tom@tromey.com>
4441
4442 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
4443 declaration.
4444 * printcmd.c (x_command): Remove unused declaration.
4445 * symfile.c (symbol_file_command): Remove unused declaration.
4446
4447 2017-10-03 Tom Tromey <tom@tromey.com>
4448
4449 * utils.c (internal_vproblem): Use std::string.
4450 (defaulted_query): Likewise.
4451
4452 2017-10-03 Tom Tromey <tom@tromey.com>
4453
4454 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
4455 * top.c (execute_command_to_string): Update.
4456 * utils.c (make_cleanup_restore_page_info): Remove.
4457 (do_restore_page_info_cleanup): Remove.
4458 (set_batch_flag_and_restore_page_info):
4459 New.
4460 (make_cleanup_restore_page_info): Remove.
4461 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
4462 (~set_batch_flag_and_restore_page_info): New
4463 (make_cleanup_restore_uinteger): Remove.
4464 (make_cleanup_restore_integer): Remove.
4465 (struct restore_integer_closure): Remove.
4466 (restore_integer): Remove.
4467 * utils.h (struct set_batch_flag_and_restore_page_info): New
4468 class.
4469 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
4470 (make_cleanup_restore_page_info): Remove.
4471 (make_cleanup_restore_uinteger) Remove.
4472 (make_cleanup_restore_integer) Remove.
4473
4474 2017-10-03 Tom Tromey <tom@tromey.com>
4475
4476 * record-full.h (record_full_gdb_operation_disable_set): Return
4477 scoped_restore_tmpl<int>.
4478 * infrun.c (adjust_pc_after_break): Update.
4479 (handle_signal_stop): Update.
4480 * record-full.c (record_full_gdb_operation_disable_set): Return
4481 scoped_restore_tmpl<int>.
4482 (record_full_wait_1, record_full_insert_breakpoint)
4483 (record_full_remove_breakpoint, record_full_save)
4484 (record_full_goto_insn): Update.
4485
4486 2017-10-02 Tom Tromey <tom@tromey.com>
4487
4488 PR rust/22236:
4489 * rust-lang.c (rust_val_print_str): New function.
4490 (val_print_struct): Call it.
4491 (rust_subscript): Preserve name of slice type.
4492
4493 2017-10-02 Tom Tromey <tom@tromey.com>
4494
4495 * rust-lang.c (rust_subscript): Handle slices in
4496 EVAL_AVOID_SIDE_EFFECTS case.
4497
4498 2017-10-02 Tom Tromey <tom@tromey.com>
4499
4500 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
4501
4502 2017-10-02 Tom Tromey <tom@tromey.com>
4503
4504 * rust-lang.h (rust_slice_type): Add "extern".
4505
4506 2017-10-02 Tom Tromey <tom@tromey.com>
4507 Pedro Alves <palves@redhat.com>
4508
4509 * ada-lang.h (ada_exc_info::operator<): Make const.
4510 (ada_exc_info::operator==): Make const.
4511 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
4512 Make const.
4513
4514 2017-09-29 Tom Tromey <tom@tromey.com>
4515
4516 * target.c (read_whatever_is_readable): Change type of "result".
4517 Update.
4518 (free_memory_read_result_vector): Remove.
4519 (read_memory_robust): Change return type. Update.
4520 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
4521 bin2hex, std::string.
4522 * target.h (memory_read_result_s): Remove typedef.
4523 (free_memory_read_result_vector): Remove.
4524 (read_memory_robust): Return std::vector.
4525
4526 2017-09-29 Tom Tromey <tom@tromey.com>
4527
4528 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
4529
4530 2017-09-29 Tom Tromey <tom@tromey.com>
4531
4532 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
4533 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
4534 operator< and operator==.
4535 (ada_exceptions_list): Return a std::vector.
4536 * ada-lang.c (ada_exc_info::operator<): Rename from
4537 compare_ada_exception_info.
4538 (ada_exc_info::operator==): New.
4539 (sort_remove_dups_ada_exceptions_list): Change type of
4540 "exceptions".
4541 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
4542 (ada_add_global_exceptions): Likewise.
4543 (ada_exceptions_list_1): Return a std::vector.
4544 (ada_exceptions_list): Likewise.
4545
4546 2017-09-29 Tom Tromey <tom@tromey.com>
4547
4548 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
4549 'std::set *'.
4550 (print_one_inferior): Update.
4551 (free_vector_of_ints): Remove.
4552 (list_available_thread_groups): Change "ids" to std::set.
4553 (mi_cmd_list_thread_groups): Update.
4554 (struct collect_cores_data) <core>: Now a std::set.
4555 (collect_cores): Update.
4556 (unique): Remove.
4557 (print_one_inferior): Update.
4558
4559 2017-09-29 Tom Tromey <tom@tromey.com>
4560
4561 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
4562 (mi_execute_async_cli_command): Likewise.
4563 (mi_cmd_trace_frame_collected): Use field_fmt.
4564
4565 2017-09-29 Tom Tromey <tom@tromey.com>
4566
4567 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
4568 gdb::byte_vector.
4569
4570 2017-09-29 Tom Tromey <tom@tromey.com>
4571
4572 * mi/mi-parse.c (mi_parse): Remove unused declaration.
4573
4574 2017-09-29 Tom Tromey <tom@tromey.com>
4575
4576 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
4577
4578 2017-09-29 Tom Tromey <tom@tromey.com>
4579
4580 * varobj.h (varobj_gen_name): Return std::string.
4581 * varobj.c (varobj_gen_name): Return std::string.
4582 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
4583 (mi_cmd_var_delete): Don't copy "name".
4584
4585 2017-09-29 Tom Tromey <tom@tromey.com>
4586
4587 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
4588 (mi_cmd_break_insert_1): Update.
4589
4590 2017-09-29 Tom Tromey <tom@tromey.com>
4591
4592 * target.h (make_scoped_defer_target_commit_resume): Update.
4593 * target.c (make_scoped_defer_target_commit_resume): Rename from
4594 make_cleanup_defer_target_commit_resume. Return a
4595 scoped_restore.
4596 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
4597
4598 2017-09-29 Tom Tromey <tom@tromey.com>
4599
4600 * main.c (captured_main_1): Remove unused declaration.
4601 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
4602
4603 2017-09-29 Tom Tromey <tom@tromey.com>
4604
4605 * symtab.c (search_symbols): Remove unused outer cleanup.
4606 (make_source_files_completion_list): Remove unused declaration.
4607
4608 2017-09-29 Tom Tromey <tom@tromey.com>
4609
4610 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
4611
4612 2017-09-29 Tom Tromey <tom@tromey.com>
4613
4614 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
4615 gdb::byte_vector.
4616
4617 2017-09-29 Tom Tromey <tom@tromey.com>
4618
4619 * complaints.c (vcomplaint): Use std::string.
4620
4621 2017-09-29 Tom Tromey <tom@tromey.com>
4622
4623 * tracepoint.c (trace_variable_command): Use std::string.
4624 (encode_actions_1): Remove unused declarations.
4625 (create_tsv_from_upload): Use std::string.
4626
4627 2017-09-29 Tom Tromey <tom@tromey.com>
4628
4629 * cp-support.c (gdb_demangle): Use std::string.
4630
4631 2017-09-29 Tom Tromey <tom@tromey.com>
4632
4633 * stack.c (parse_frame_specification): Use std::string
4634 (info_frame_command): Use gdb::unique_xmalloc_ptr.
4635
4636 2017-09-29 Tom Tromey <tom@tromey.com>
4637
4638 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
4639
4640 2017-09-29 Tom Tromey <tom@tromey.com>
4641
4642 * utils.c (vfprintf_maybe_filtered): Use std::string.
4643 (vfprintf_unfiltered): Likewise.
4644
4645 2017-09-29 Tom Tromey <tom@tromey.com>
4646
4647 * event-top.c (top_level_prompt): Return std::string.
4648 (display_gdb_prompt): Update.
4649
4650 2017-09-29 Tom Tromey <tom@tromey.com>
4651
4652 * unittests/common-utils-selftests.c (format): New function.
4653 (string_vprintf_tests): New function.
4654 (_initialize_common_utils_selftests): Register new tests.
4655 * common/common-utils.c (string_vprintf): New function.
4656 * common/common-utils.h (string_vprintf): Declare.
4657
4658 2017-09-29 Pedro Alves <palves@redhat.com>
4659
4660 * common/rsp-low.c (unpack_varlen_hex): Constify.
4661 * common/rsp-low.h (unpack_varlen_hex): Constify.
4662 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
4663 Constify.
4664 * remote.c (remote_set_permissions, read_ptid)
4665 (remote_current_thread, remote_get_threads_with_qthreadinfo)
4666 (remote_static_tracepoint_marker_at)
4667 (remote_static_tracepoint_markers_by_strid)
4668 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
4669 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
4670 (parse_tracepoint_definition, parse_tsv_definition)
4671 (parse_static_tracepoint_marker_definition): Constify.
4672 * tracepoint.h (parse_static_tracepoint_marker_definition)
4673 (parse_trace_status, parse_tracepoint_status)
4674 (parse_tracepoint_definition, parse_tsv_definition): Constify.
4675
4676 2017-09-29 Pedro Alves <palves@redhat.com>
4677
4678 * remote.c (target_buf, target_buf_size): Delete.
4679 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
4680 Use the connection's packet buffer instead.
4681 All callers adjusted.
4682 (_initialize_remote): Remove references to target_buf and
4683 target_buf_size.
4684
4685 2017-09-28 Pedro Alves <palves@redhat.com>
4686
4687 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4688 unittests/common-utils-selftests.c.
4689 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
4690 (COMMON_OBS): Remove utils-selftests.o.
4691 * utils-selftests.c: Move to ...
4692 * unittests/common-utils-selftests.c: ... here and rename self
4693 test to "string_printf".
4694
4695 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
4696
4697 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
4698 having NULL cus or tus.
4699
4700 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
4701
4702 * arm-tdep.c: (convert_from_extended): Remove.
4703 (convert_to_extended): Likewise.
4704 (arm_extract_return_value): Use convert_typed_floating.
4705 (arm_store_return_value): Likewise.
4706
4707 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
4708 * sh-tdep.c: Do not include "floatformat.h".
4709 (sh_littlebyte_bigword_type): New function.
4710 (sh_register_convert_to_virtual): Use convert_typed_floating.
4711 (sh_register_convert_to_raw): Likewise.
4712 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
4713 (sh64_littlebyte_bigword_type): New function.
4714 (sh64_extract_return_value): Use convert_typed_floating.
4715 (sh64_register_convert_to_virtual): Likewise.
4716 (sh64_register_convert_to_raw): Likewise.
4717
4718 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
4719
4720 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
4721 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
4722
4723 * gdbtypes.h (union type_specific): Make field floatformat hold
4724 just a single struct floatformat, not an array.
4725 (floatformat_from_type): Move here.
4726 * gdbtypes.c (floatformat_from_type): Move here. Update to
4727 changed TYPE_FLOATFORMAT definition.
4728 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
4729 (recursive_dump_type): Likewise.
4730 (init_float_type): Install correct floatformat for byte order.
4731 (arch_float_type): Likewise.
4732
4733 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
4734
4735 * gdbtypes.c (init_type): Change incoming argument from
4736 length-in-bytes to length-in-bits. Assert length is a
4737 multiple of TARGET_CHAR_BITS.
4738 (arch_type, arch_flags_type): Likewise.
4739 (init_integer_type): Update call to init_type.
4740 (init_character_type): Likewise.
4741 (init_boolean_type): Likewise.
4742 (init_float_type): Likewise.
4743 (init_decfloat_type): Likewise.
4744 (init_complex_type): Likewise.
4745 (init_pointer_type): Likewise.
4746 (objfile_type): Likewise.
4747 (arch_integer_type): Update call to arch_type.
4748 (arch_character_type): Likewise.
4749 (arch_boolean_type): Likewise.
4750 (arch_float_type): Likewise.
4751 (arch_decfloat_type): Likewise.
4752 (arch_complex_type): Likewise.
4753 (arch_pointer_type): Likewise.
4754 (gdbtypes_post_init): Likewise.
4755
4756 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
4757 (read_base_type): Likewise.
4758 * mdebugread.c (basic_type): Likewise.
4759 * stabsread.c (dbx_init_float_type): Likewise.
4760 (rs6000_builtin_type): Likewise.
4761 (read_range_type): Likewise. Also, fix call to init_integer_type
4762 with erroneous length argument.
4763
4764 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
4765 * d-lang.c (build_d_types): Likewise.
4766 * f-lang.c (build_fortran_types): Likewise.
4767 * go-lang.c (build_go_types): Likewise.
4768 * opencl-lang.c (build_opencl_types): Likewise.
4769 * jit.c (finalize_symtab): Likewise.
4770 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
4771 (build_std_type_info_type): Likewise.
4772 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
4773 update call to arch_flags_type.
4774
4775 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
4776 arch_type.
4777 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
4778 * windows-tdep.c (windows_get_tlb_type): Likewise.
4779
4780 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
4781 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
4782 * m32c-tdep.c (make_types): Likewise.
4783 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
4784 (rl78_psw_type): Update call to arch_flags_type.
4785 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
4786 * rx-tdep.c (rx_psw_type): Likewise.
4787 (rx_fpsw_type): Likewise.
4788 * sparc-tdep.c (sparc_psr_type): Likewise.
4789 (sparc_fsr_type): Likewise.
4790 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
4791 (sparc64_ccr_type): Likewise.
4792 (sparc64_fsr_type): Likewise.
4793 (sparc64_fprs_type): Likewise.
4794
4795 2017-09-27 Tom Tromey <tom@tromey.com>
4796
4797 * findcmd.c (find_command): Constify.
4798
4799 2017-09-27 Tom Tromey <tom@tromey.com>
4800
4801 * ada-tasks.c (task_command_1, task_command): Constify.
4802
4803 2017-09-27 Tom Tromey <tom@tromey.com>
4804
4805 * symtab.c (maintenance_print_symbol_cache)
4806 (maintenance_flush_symbol_cache)
4807 (maintenance_print_symbol_cache_statistics): Constify.
4808
4809 2017-09-27 Tom Tromey <tom@tromey.com>
4810
4811 * inferior.c (detach_inferior_command, kill_inferior_command)
4812 (inferior_command): Constify.
4813
4814 2017-09-27 Tom Tromey <tom@tromey.com>
4815
4816 * regcache.c (regcache_print, maintenance_print_registers)
4817 (maintenance_print_raw_registers)
4818 (maintenance_print_cooked_registers)
4819 (maintenance_print_register_groups)
4820 (maintenance_print_remote_registers): Constify.
4821
4822 2017-09-27 Tom Tromey <tom@tromey.com>
4823
4824 * printcmd.c (map_display_numbers, undisplay_command)
4825 (enable_disable_display_command, enable_display_command)
4826 (disable_display_command): Constify.
4827
4828 2017-09-27 Tom Tromey <tom@tromey.com>
4829
4830 * breakpoint.h (delete_command): Don't declare.
4831 * breakpoint.c (delete_command, enable_once_command)
4832 (enable_count_command, enable_delete_command, breakpoint_1)
4833 (maintenance_info_breakpoints, stopin_command, stopat_command)
4834 (delete_command, delete_trace_command, save_breakpoints)
4835 (save_breakpoints_command, save_tracepoints_command): Constify.
4836
4837 2017-09-27 Tom Tromey <tom@tromey.com>
4838
4839 * macrocmd.c (macro_expand_command, macro_expand_once_command)
4840 (skip_ws, extract_identifier, macro_define_command)
4841 (macro_undef_command, macro_list_command): Constify.
4842
4843 2017-09-27 Tom Tromey <tom@tromey.com>
4844
4845 * infcmd.c (environment_info, set_environment_command)
4846 (unset_environment_command, path_info, info_proc_cmd_1)
4847 (info_proc_cmd_mappings, info_proc_cmd_stat)
4848 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
4849 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
4850
4851 2017-09-27 Tom Tromey <tom@tromey.com>
4852
4853 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
4854 Constify.
4855
4856 2017-09-27 Tom Tromey <tom@tromey.com>
4857
4858 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
4859
4860 2017-09-27 Tom Tromey <tom@tromey.com>
4861
4862 * demangle.c (demangle_command): Constify.
4863
4864 2017-09-27 Tom Tromey <tom@tromey.com>
4865
4866 * progspace.c (maintenance_info_program_spaces_command):
4867 Constify.
4868
4869 2017-09-27 Tom Tromey <tom@tromey.com>
4870
4871 * compile/compile.c (check_raw_argument, compile_file_command)
4872 (compile_code_command, compile_print_command): Constify.
4873
4874 2017-09-27 Tom Tromey <tom@tromey.com>
4875
4876 * reggroups.c (maintenance_print_reggroups): Constify.
4877
4878 2017-09-27 Tom Tromey <tom@tromey.com>
4879
4880 * dwarf2read.c (save_gdb_index_command): Constify.
4881
4882 2017-09-27 Tom Tromey <tom@tromey.com>
4883
4884 * stap-probe.c (info_probes_stap_command): Constify.
4885
4886 2017-09-27 Tom Tromey <tom@tromey.com>
4887
4888 * fork-child.c (unset_exec_wrapper_command): Constify.
4889
4890 2017-09-27 Tom Tromey <tom@tromey.com>
4891
4892 * btrace.c (get_uint, get_context_size, no_chunk)
4893 (maint_btrace_packet_history_cmd)
4894 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
4895 (maint_info_btrace_cmd): Constify.
4896
4897 2017-09-27 Tom Tromey <tom@tromey.com>
4898
4899 * reverse.c (delete_bookmark_command): Constify.
4900
4901 2017-09-27 Tom Tromey <tom@tromey.com>
4902
4903 * remote.c (set_memory_packet_size)
4904 (set_memory_write_packet_size, show_memory_write_packet_size)
4905 (set_memory_read_packet_size, show_memory_read_packet_size)
4906 (compare_sections_command, packet_command, remote_put_command)
4907 (remote_get_command, remote_delete_command): Constify.
4908
4909 2017-09-27 Tom Tromey <tom@tromey.com>
4910
4911 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
4912 (set_mipsfpu_double_command, set_mipsfpu_none_command)
4913 (set_mipsfpu_auto_command): Constify.
4914
4915 2017-09-27 Tom Tromey <tom@tromey.com>
4916
4917 * cli/cli-cmds.h (cd_command): Constify.
4918 * cli/cli-cmds.c (cd_command): Constify.
4919
4920 2017-09-27 Tom Tromey <tom@tromey.com>
4921
4922 * thread.c (thread_name_command, thread_find_command): Constify.
4923
4924 2017-09-27 Tom Tromey <tom@tromey.com>
4925
4926 * probe.c (enable_probes_command, disable_probes_command):
4927 Constify.
4928
4929 2017-09-27 Tom Tromey <tom@tromey.com>
4930
4931 * symfile.c (symbol_file_command): Constify.
4932 * gdbcore.h (deprecated_file_changed_hook): Constify.
4933 * exec.c (deprecated_file_changed_hook, exec_file_command)
4934 (file_command): Constify.
4935 * defs.h (symbol_file_command): Constify.
4936
4937 2017-09-27 Tom Tromey <tom@tromey.com>
4938
4939 * remote-fileio.c (set_system_call_allowed)
4940 (show_system_call_allowed): Constify.
4941
4942 2017-09-27 Tom Tromey <tom@tromey.com>
4943
4944 * tracepoint.c (delete_trace_variable_command)
4945 (tfind_end_command, tfind_start_command, tfind_pc_command)
4946 (tfind_tracepoint_command, tfind_line_command)
4947 (tfind_range_command, tfind_outside_command): Constify.
4948
4949 2017-09-27 Tom Tromey <tom@tromey.com>
4950
4951 * ax-gdb.c (maint_agent_printf_command, agent_command)
4952 (agent_eval_command): Constify.
4953
4954 2017-09-27 Tom Tromey <tom@tromey.com>
4955
4956 * tracepoint.c (info_scope_command): Constify.
4957 * python/python.c (gdbpy_decode_line): Constify.
4958 * python/py-breakpoint.c (bppy_init): Constify.
4959 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
4960 * location.h: (new_linespec_location)
4961 (string_to_event_location_basic, string_to_event_location):
4962 Constify.
4963 * location.c (new_linespec_location)
4964 (string_to_event_location_basic, string_to_event_location):
4965 Constify.
4966 * linespec.h (decode_line_with_current_source)
4967 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
4968 * linespec.c (linespec_lex_to_end)
4969 (decode_line_with_current_source)
4970 (decode_line_with_last_displayed): Constify.
4971 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
4972 Constify.
4973 * cli/cli-cmds.c (edit_command, list_command): Constify.
4974 * breakpoint.h (until_break_command, watch_command_wrapper)
4975 (awatch_command_wrapper, rwatch_command_wrapper)
4976 (init_ada_exception_breakpoint): Constify.
4977 * breakpoint.c (break_command_1, dprintf_command)
4978 (break_range_command, watch_command_wrapper)
4979 (rwatch_command_wrapper, awatch_command_wrapper)
4980 (until_break_command, init_ada_exception_breakpoint)
4981 (strace_marker_create_sals_from_location, trace_command)
4982 (ftrace_command, strace_command, struct tracepoint): Constify.
4983 * ax-gdb.c (agent_command_1): Constify.
4984 * ada-lang.c (ada_exception_sal): Constify.
4985
4986 2017-09-27 Tom Tromey <tom@tromey.com>
4987
4988 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
4989 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
4990 (get_context_size, no_chunk, get_insn_history_modifiers)
4991 (cmd_record_insn_history, get_call_history_modifiers)
4992 (cmd_record_call_history): Constify.
4993
4994 2017-09-27 Tom Tromey <tom@tromey.com>
4995
4996 * source.c (show_substitute_path_command)
4997 (unset_substitute_path_command, set_substitute_path_command):
4998 Constify.
4999
5000 2017-09-27 Tom Tromey <tom@tromey.com>
5001
5002 * typeprint.c (maintenance_print_type): Constify.
5003 * maint.c (maintenance_dump_me, maintenance_demangle)
5004 (maintenance_time_display, maintenance_info_sections)
5005 (maintenance_print_statistics, maintenance_deprecate)
5006 (maintenance_undeprecate): Constify.
5007 (maintenance_do_deprecate): Constify. Use std::string.
5008 (maintenance_selftest): Constify.
5009 * gdbtypes.h (maintenance_print_type): Constify.
5010
5011 2017-09-27 Tom Tromey <tom@tromey.com>
5012
5013 * hppa-tdep.c (unwind_command): Constify.
5014
5015 2017-09-27 Tom Tromey <tom@tromey.com>
5016
5017 * target-descriptions.c (unset_tdesc_filename_cmd)
5018 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
5019 Constify.
5020
5021 2017-09-27 Tom Tromey <tom@tromey.com>
5022
5023 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
5024
5025 2017-09-27 Tom Tromey <tom@tromey.com>
5026
5027 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
5028
5029 2017-09-27 Tom Tromey <tom@tromey.com>
5030
5031 * tui/tui-regs.c (tui_reg_command): Constify.
5032
5033 2017-09-27 Tom Tromey <tom@tromey.com>
5034
5035 * skip.c (skip_file_command, skip_function_command)
5036 (skip_enable_command, skip_disable_command, skip_delete_command):
5037 Constify.
5038
5039 2017-09-27 Tom Tromey <tom@tromey.com>
5040
5041 * record-btrace.c (cmd_record_btrace_bts_start)
5042 (cmd_record_btrace_pt_start): Constify.
5043
5044 2017-09-27 Tom Tromey <tom@tromey.com>
5045
5046 * symmisc.c (maintenance_print_symbols)
5047 (maintenance_print_msymbols, maintenance_print_objfiles)
5048 (maintenance_info_symtabs, maintenance_check_symtabs)
5049 (maintenance_expand_symtabs, maintenance_info_line_tables):
5050 Constify.
5051
5052 2017-09-27 Tom Tromey <tom@tromey.com>
5053
5054 * top.c (new_ui_command): Constify.
5055
5056 2017-09-27 Tom Tromey <tom@tromey.com>
5057
5058 * symfile.c (add_symbol_file_command)
5059 (remove_symbol_file_command, list_overlays_command)
5060 (map_overlay_command, unmap_overlay_command)
5061 (overlay_auto_command, overlay_manual_command)
5062 (overlay_off_command, overlay_load_command): Constify.
5063
5064 2017-09-27 Tom Tromey <tom@tromey.com>
5065
5066 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
5067 (info_spu_mailbox_command, info_spu_dma_command)
5068 (info_spu_proxydma_command): Constify.
5069
5070 2017-09-27 Tom Tromey <tom@tromey.com>
5071
5072 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
5073
5074 2017-09-27 Tom Tromey <tom@tromey.com>
5075
5076 * cli/cli-script.c (user_defined_command): Constify.
5077
5078 2017-09-27 Tom Tromey <tom@tromey.com>
5079
5080 * cli/cli-dump.c (dump_memory_command, dump_value_command)
5081 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
5082 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
5083 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
5084 (dump_binary_value, append_binary_memory, append_binary_value):
5085 Constify.
5086 (struct dump_context) <func>: Constify.
5087 (add_dump_command): Update.
5088
5089 2017-09-27 Tom Tromey <tom@tromey.com>
5090
5091 * cli/cli-cmds.c (show_version, show_configuration)
5092 (source_command, show_user): Constify.
5093
5094 2017-09-27 Tom Tromey <tom@tromey.com>
5095
5096 * target.c (maintenance_print_target_stack): Constify.
5097
5098 2017-09-27 Tom Tromey <tom@tromey.com>
5099
5100 * interps.c (interpreter_exec_cmd): Constify.
5101
5102 2017-09-27 Tom Tromey <tom@tromey.com>
5103
5104 * record-full.c (cmd_record_full_restore): Constify.
5105
5106 2017-09-27 Tom Tromey <tom@tromey.com>
5107
5108 * memattr.c (enable_mem_command, disable_mem_command)
5109 (delete_mem_command): Constify.
5110
5111 2017-09-27 Tom Tromey <tom@tromey.com>
5112
5113 * value.c (show_convenience): Constify.
5114
5115 2017-09-27 Tom Tromey <tom@tromey.com>
5116
5117 * gdbcore.h (core_file_command): Update.
5118 * corefile.c (core_file_command): Constify.
5119
5120 2017-09-27 Tom Tromey <tom@tromey.com>
5121
5122 * user-regs.c (maintenance_print_user_registers): Constify.
5123
5124 2017-09-27 Tom Tromey <tom@tromey.com>
5125
5126 * cp-namespace.c (maintenance_cplus_namespace): Constify.
5127
5128 2017-09-27 Tom Tromey <tom@tromey.com>
5129
5130 * cp-support.c (first_component_command): Constify.
5131
5132 2017-09-27 Tom Tromey <tom@tromey.com>
5133
5134 * psymtab.c (maintenance_print_psymbols)
5135 (maintenance_info_psymtabs, maintenance_check_psymtabs):
5136 Constify.
5137
5138 2017-09-27 Tom Tromey <tom@tromey.com>
5139
5140 * windows-tdep.c (display_tib): Constify.
5141
5142 2017-09-27 Tom Tromey <tom@tromey.com>
5143
5144 * linux-fork.c (delete_checkpoint_command)
5145 (detach_checkpoint_command): Constify.
5146
5147 2017-09-27 Tom Tromey <tom@tromey.com>
5148
5149 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
5150
5151 2017-09-27 Tom Tromey <tom@tromey.com>
5152
5153 * arc-tdep.c (dump_arc_instruction_command): Constify.
5154
5155 2017-09-27 Tom Tromey <tom@tromey.com>
5156
5157 * valprint.c (set_radix, show_radix): Constify.
5158
5159 2017-09-27 Tom Tromey <tom@tromey.com>
5160
5161 * dtrace-probe.c (info_probes_dtrace_command): Constify.
5162
5163 2017-09-27 Tom Tromey <tom@tromey.com>
5164
5165 * command.h (not_just_help_class_command): Update.
5166 * cli/cli-decode.h (not_just_help_class_command): Update.
5167 * cli/cli-decode.c (not_just_help_class_command): Constify.
5168
5169 2017-09-27 Tom Tromey <tom@tromey.com>
5170
5171 * gdb_bfd.c (maintenance_info_bfds): Constify.
5172
5173 2017-09-27 Tom Tromey <tom@tromey.com>
5174
5175 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
5176 overloads.
5177 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
5178 (do_const_cfunc): New function.
5179 (cmd_cfunc_eq): New overload.
5180 (cli_user_command_p): Check do_const_cfunc.
5181 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
5182 const_cfunc.
5183 * command.h (add_cmd): Add const overload and no-function
5184 overload.
5185 (set_cmd_cfunc): Add const overload.
5186 (cmd_const_cfunc_ftype): Declare.
5187 (cmd_cfunc_eq): Add const overload.
5188 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
5189 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
5190 overload.
5191
5192 2017-09-27 Tom Tromey <tom@tromey.com>
5193
5194 * macroexp.c (get_next_token_for_substitution): New function.
5195 (substitute_args): Call it. Check for __VA_OPT__.
5196
5197 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
5198 Pedro Alves <palves@redhat.com>
5199
5200 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
5201 producer_is_icc_lt_14.
5202 (producer_is_icc_lt_14): New function.
5203 (check_producer): Add code for checking version of ICC.
5204 (producer_is_icc): Move to producer.c.
5205 (read_structure_type): Restrict ICC workaround to ICC<14.
5206 * producer.c: Include selftest.h.
5207 (producer_is_icc, producer_parsing_tests, _initialize_producer):
5208 New functions.
5209 * producer.h (producer_is_icc): New declaration.
5210
5211 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
5212
5213 * Makefile.in (SFILES): Add producer.c.
5214 (COMMON_OBS): Add producer.o
5215 * amd64-tdep.c (producer.h): Add new include.
5216 * dwarf2read.c (producer.h): Add new include.
5217 * producer.c: New file.
5218 * producer.h: New file.
5219 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
5220 producer.c.
5221 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
5222 producer.h.
5223
5224 2017-09-26 Matthias Klose <doko@ubuntu.com>
5225
5226 * configure.ac: Search ncursesw before ncurses.
5227 Check ncursesw/ncurses.h before ncurses/ncurses.h.
5228 * gdb_curses.h: Include <ncursesw/ncurses.h>
5229 * config.in, configure: Regenerate.
5230
5231 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5232
5233 PR gdb/22185
5234 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
5235 obsolete.
5236 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
5237 Remove i386sol2 support.
5238 * configure.nat <i386sol2>: Remove.
5239 <sol2-64>: Fold into ...
5240 <sol2>: ... this.
5241 Move common settings to default section.
5242 Add sol-thread.o.
5243 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
5244 x86_64-*-solaris2.1[0-9]*>: Rename to ...
5245 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
5246 <i[34567]86-*-solaris*>: Remove.
5247 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
5248
5249 * configure.ac: Remove wctype in libw check.
5250 (_MSE_INT_H): Don't define on Solaris 7-9.
5251 <solaris*>: Remove libthread_db.so.1 check.
5252 * configure: Regenerate.
5253 * config.in: Regenerate.
5254
5255 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
5256 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
5257 (gdb_ps_size_t): Remove.
5258 Use base types in users.
5259 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
5260
5261 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
5262
5263 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5264
5265 PR build/22206
5266 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
5267 (adi_is_addr_mapped): Likewise.
5268 (PSR_ICC): Don't redefine.
5269 (PSR_IMPL): Likewise.
5270
5271 2017-09-25 Tom Tromey <tom@tromey.com>
5272
5273 * regcache.c (regcache::dump): Use string_printf.
5274
5275 2017-09-25 Tom Tromey <tom@tromey.com>
5276
5277 * regcache.c (class regcache_invalidator): New.
5278 (struct register_to_invalidate): Remove.
5279 (make_cleanup_regcache_invalidate): Remove.
5280 (regcache::raw_write): Use regcache_invalidator.
5281
5282 2017-09-25 Tom Tromey <tom@tromey.com>
5283
5284 * spu-tdep.c (spu2ppu_sniffer): Update.
5285 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
5286 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
5287 Remove.
5288 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
5289 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
5290 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
5291 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
5292 (frame_pop): Update.
5293
5294 2017-09-25 Tom Tromey <tom@tromey.com>
5295
5296 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
5297 * regcache.h (regcache_xfree): Don't declare.
5298 * regcache.c (regcache_xfree): Remove.
5299 (do_regcache_xfree): Use delete.
5300 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
5301 * linux-fork.c (free_fork): Use delete.
5302 (fork_save_infrun_state): Likewise.
5303 * jit.c (jit_dealloc_cache): Use delete.
5304 * infrun.c (discard_infcall_suspend_state): Use delete.
5305
5306 2017-09-25 Tom Tromey <tom@tromey.com>
5307
5308 * regcache.h (regcache_xmalloc): Don't declare.
5309 (regcache_raw_set_cached_value): Update comment.
5310 * regcache.c (regcache_xmalloc): Remove.
5311 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
5312 * jit.c (jit_frame_sniffer): Use new.
5313 * frame.c (frame_save_as_regcache): Use new.
5314
5315 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5316
5317 * NEWS: Advertise support for guarded-storage registers on IBM z.
5318
5319 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5320
5321 * s390-linux-nat.c (have_regset_gs): New static variable.
5322 (s390_linux_fetch_inferior_registers): Handle guarded-storage
5323 control block and guarded-storage broadcast control regsets.
5324 (s390_read_description): Detect whether the target has
5325 guarded-storage support, return appropriate tdesc.
5326 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
5327 (features/s390x-gs-linux64.c): Likewise.
5328 (struct gdbarch_tdep) <have_gs>: New field.
5329 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
5330 (s390_gsbc_regset): New variables.
5331 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
5332 and s390_gsbc_regset, if applicable.
5333 (s390_core_read_description): Check whether core file was from a
5334 target with guarded-storage support; include appropriate regsets.
5335 (s390_gdbarch_init): Add registers for guarded-storage support.
5336 (_initialize_s390_tdep): Initialize new target descriptions that
5337 include registers for guarded-storage support.
5338 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
5339 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
5340 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
5341 (S390_NUM_REGS): Adjust macro definition.
5342 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
5343 (tdesc_s390x_gs_linux64): New declarations.
5344
5345 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5346
5347 * features/s390-gs-linux64.xml: New file.
5348 * features/s390-gs.xml: New file.
5349 * features/s390-gsbc.xml: New file.
5350 * features/s390x-gs-linux64.xml: New file.
5351 * features/Makefile (WHICH): Add s390-gs-linux64 and
5352 s390x-gs-linux64.
5353 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
5354 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
5355 * features/s390-gs-linux64.c: New generated file.
5356 * features/s390x-gs-linux64.c: New file.
5357 * regformats/s390-gs-linux64.dat: New file.
5358 * regformats/s390x-gs-linux64.dat: New file.
5359
5360 2017-09-23 Tom Tromey <tom@tromey.com>
5361
5362 * defs.h (make_cleanup_override_quit_handler): Don't declare.
5363
5364 2017-09-22 Tom Tromey <tom@tromey.com>
5365
5366 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
5367 type to scoped_restore_tmpl.
5368 <scoped_input_handler>: Initialize m_quit_handler directly.
5369
5370 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
5371
5372 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
5373 (cd_command): Likewise. Free "current_directory" before
5374 assigning to it.
5375 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
5376 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
5377 * top.c (gdb_dirbuf): Remove global declaration.
5378 * top.h (gdb_dirbuf): Likewise.
5379
5380 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
5381
5382 * gnulib/aclocal.m4: Regenerate.
5383 * gnulib/config.in: Regenerate.
5384 * gnulib/configure: Regenerate.
5385 * gnulib/import/Makefile.am: Regenerate.
5386 * gnulib/import/Makefile.in: Regenerate.
5387 * gnulib/import/assure.h: New file.
5388 * gnulib/import/at-func.c: Likewise
5389 * gnulib/import/chdir-long.c: New file.
5390 * gnulib/import/chdir-long.h: New file.
5391 * gnulib/import/cloexec.c: New file.
5392 * gnulib/import/cloexec.h: New file.
5393 * gnulib/import/close.c: New file.
5394 * gnulib/import/closedir.c: New file.
5395 * gnulib/import/dirent-private.h: New file.
5396 * gnulib/import/dup-safer.c: New file.
5397 * gnulib/import/dup.c: New file.
5398 * gnulib/import/dup2.c: New file.
5399 * gnulib/import/error.c: New file.
5400 * gnulib/import/error.h: New file.
5401 * gnulib/import/exitfail.c: New file.
5402 * gnulib/import/exitfail.h: New file.
5403 * gnulib/import/fchdir.c: New file.
5404 * gnulib/import/fcntl.c: New file.
5405 * gnulib/import/fcntl.in.h: New file.
5406 * gnulib/import/fd-hook.c: New file.
5407 * gnulib/import/fd-hook.h: New file.
5408 * gnulib/import/fd-safer.c: New file.
5409 * gnulib/import/fdopendir.c: New file.
5410 * gnulib/import/filename.h: New file.
5411 * gnulib/import/filenamecat-lgpl.c: New file.
5412 * gnulib/import/filenamecat.h: New file.
5413 * gnulib/import/fstat.c: New file.
5414 * gnulib/import/fstatat.c: New file.
5415 * gnulib/import/getcwd-lgpl.c: New file.
5416 * gnulib/import/getcwd.c: New file.
5417 * gnulib/import/getdtablesize.c: New file.
5418 * gnulib/import/getlogin_r.c: New file.
5419 * gnulib/import/getprogname.c: New file.
5420 * gnulib/import/getprogname.h: New file.
5421 * gnulib/import/gettext.h: New file.
5422 * gnulib/import/glob-libc.h: New file.
5423 * gnulib/import/glob.c: New file.
5424 * gnulib/import/glob.in.h: New file.
5425 * gnulib/import/intprops.h: New file.
5426 * gnulib/import/m4/chdir-long.m4: New file.
5427 * gnulib/import/m4/close.m4: New file.
5428 * gnulib/import/m4/closedir.m4: New file.
5429 * gnulib/import/m4/d-ino.m4: New file.
5430 * gnulib/import/m4/d-type.m4: New file.
5431 * gnulib/import/m4/dup.m4: New file.
5432 * gnulib/import/m4/dup2.m4: New file.
5433 * gnulib/import/m4/error.m4: New file.
5434 * gnulib/import/m4/fchdir.m4: New file.
5435 * gnulib/import/m4/fcntl.m4: New file.
5436 * gnulib/import/m4/fcntl_h.m4: New file.
5437 * gnulib/import/m4/fdopendir.m4: New file.
5438 * gnulib/import/m4/filenamecat.m4: New file.
5439 * gnulib/import/m4/fstat.m4: New file.
5440 * gnulib/import/m4/fstatat.m4: New file.
5441 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
5442 * gnulib/import/m4/getcwd-path-max.m4: New file.
5443 * gnulib/import/m4/getcwd.m4: New file.
5444 * gnulib/import/m4/getdtablesize.m4: New file.
5445 * gnulib/import/m4/getlogin_r.m4: New file.
5446 * gnulib/import/m4/getprogname.m4: New file.
5447 * gnulib/import/m4/glob.m4: New file.
5448 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
5449 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
5450 * gnulib/import/m4/mempcpy.m4: New file.
5451 * gnulib/import/m4/memrchr.m4: New file.
5452 * gnulib/import/m4/mode_t.m4: New file.
5453 * gnulib/import/m4/msvc-inval.m4: New file.
5454 * gnulib/import/m4/msvc-nothrow.m4: New file.
5455 * gnulib/import/m4/open.m4: New file.
5456 * gnulib/import/m4/openat.m4: New file.
5457 * gnulib/import/m4/opendir.m4: New file.
5458 * gnulib/import/m4/readdir.m4: New file.
5459 * gnulib/import/m4/realloc.m4: New file.
5460 * gnulib/import/m4/rewinddir.m4: New file.
5461 * gnulib/import/m4/save-cwd.m4: New file.
5462 * gnulib/import/m4/strdup.m4: New file.
5463 * gnulib/import/m4/strerror.m4: New file.
5464 * gnulib/import/m4/unistd-safer.m4: New file.
5465 * gnulib/import/mempcpy.c: New file.
5466 * gnulib/import/memrchr.c: New file.
5467 * gnulib/import/msvc-inval.c: New file.
5468 * gnulib/import/msvc-inval.h: New file.
5469 * gnulib/import/msvc-nothrow.c: New file.
5470 * gnulib/import/msvc-nothrow.h: New file.
5471 * gnulib/import/open.c: New file.
5472 * gnulib/import/openat-die.c: New file.
5473 * gnulib/import/openat-priv.h: New file.
5474 * gnulib/import/openat-proc.c: New file.
5475 * gnulib/import/openat.c: New file.
5476 * gnulib/import/openat.h: New file.
5477 * gnulib/import/opendir.c: New file.
5478 * gnulib/import/pipe-safer.c: New file.
5479 * gnulib/import/readdir.c: New file.
5480 * gnulib/import/realloc.c: New file.
5481 * gnulib/import/rewinddir.c: New file.
5482 * gnulib/import/save-cwd.c: New file.
5483 * gnulib/import/save-cwd.h: New file.
5484 * gnulib/import/strdup.c: New file.
5485 * gnulib/import/strerror-override.c: New file.
5486 * gnulib/import/strerror-override.h: New file.
5487 * gnulib/import/strerror.c: New file.
5488 * gnulib/import/unistd--.h: New file.
5489 * gnulib/import/unistd-safer.h: New file.
5490 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
5491 "getcwd" and "glob".
5492 * ser-tcp.c: Undefine "close" before redefining it.
5493
5494 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5495
5496 * guile/scm-value.c (gdbscm_value_address): Initialize address,
5497 get rid of res_val.
5498
5499 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5500
5501 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
5502 <sol2,sparc>: Likewise.
5503 <sol2-64,i386>: Likewise.
5504
5505 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
5506 -Wdeprecated-declarations on *-*-solaris*.
5507 * configure: Regenerate.
5508
5509 * procfs.c: Include "nat/inferior.h".
5510 (procfs_info_proc): Fix typo.
5511
5512 2017-09-21 Kevin Buettner <kevinb@redhat.com>
5513
5514 * remote.c (vector): Include.
5515 (struct private_thread_info): Add field, thread_handle.
5516 (free_private_thread_info): Deallocate storage associated with
5517 thread handle.
5518 (get_private_info_thread): Initialize `thread_handle' field.
5519 (struct thread_item): Add field, thread_handle.
5520 (clear_threads_listing_context): Deallocate storage associated
5521 with thread handle.
5522 (start_thread): Add support for "handle" attribute.
5523 (thread_attributes): Add "handle".
5524 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
5525 field.
5526 (remote_update_thread_list): Update thread_handle.
5527 (remote_thread_handle_to_thread_info): New function.
5528 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
5529
5530 2017-09-21 Kevin Buettner <kevinb@redhat.com>
5531
5532 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
5533 function.
5534 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
5535 * python/python-internal.h (thread_object_type): Declare.
5536
5537 2017-09-21 Kevin Buettner <kevinb@redhat.com>
5538
5539 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
5540 (target_thread_handle_to_thread_info): Declare.
5541 * target.c (target_thread_handle_to_thread_info): New function.
5542 * target-delegates.c: Regenerate.
5543 * gdbthread.h (find_thread_by_handle): Declare.
5544 * thread.c (find_thread_by_handle): New function.
5545 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
5546 function.
5547 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
5548
5549 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5550
5551 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
5552
5553 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5554
5555 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
5556
5557 2017-09-21 Yao Qi <yao.qi@linaro.org>
5558
5559 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
5560 to gdb_target_obs.
5561
5562 2017-09-20 Tom Tromey <tom@tromey.com>
5563
5564 * breakpoint.c (struct counted_command_line): Remove.
5565 (breakpoint_commands): Update.
5566 (alloc_counted_command_line, incref_counted_command_line)
5567 (decref_counted_command_line, do_cleanup_counted_command_line)
5568 (make_cleanup_decref_counted_command_line): Remove.
5569 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
5570 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
5571 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
5572 (save_breakpoints): Update.
5573 * breakpoint.h (counted_command_line): Now a typedef to
5574 shared_ptr.
5575 (struct breakpoint) <commands>: Now a counted_command_line.
5576 (struct bpstats) <command>: Likewise.
5577
5578 2017-09-20 Tom Tromey <tom@tromey.com>
5579
5580 * breakpoint.c (struct commands_info, do_map_commands_command):
5581 Remove.
5582 (commands_command_1): Update.
5583 (iterate_over_related_breakpoints): Take a function_view.
5584 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
5585 (delete_command): Update.
5586 (map_breakpoint_numbers): Take a function_view.
5587 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
5588 (disable_command): Update.
5589 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
5590 (enable_command): Update.
5591 (struct disp_data, do_enable_breakpoint_disp)
5592 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
5593 (do_map_enable_delete_breakpoint): Remove.
5594 (enable_once_command, enable_count_command, enable_delete_command)
5595 (delete_trace_variable_command): Update.
5596
5597 2017-09-20 Tom Tromey <tom@tromey.com>
5598
5599 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
5600 (bpstat_clear): Use delete.
5601 (bpstats): New constructors.
5602 (bpstat_copy, bpstat_stop_status): Use new.
5603 (dprintf_after_condition_true): Update.
5604 * breakpoint.h (bpstats::bpstats): Add constructors.
5605 (bpstats::~bpstats): Add destructor.
5606
5607 2017-09-20 Pedro Alves <palves@redhat.com>
5608
5609 * eval.c (make_params): Delete, refactored as ...
5610 (class fake_method): ... this new type's ctor.
5611 (fake_method::~fake_method): New.
5612 (evaluate_subexp_standard): Use 'fake_method'.
5613
5614 2017-09-20 Tom Tromey <tom@tromey.com>
5615
5616 * windows-nat.c (get_windows_debug_event, windows_wait)
5617 (do_initial_windows_stuff, windows_attach): Update.
5618 * utils.c (vwarning, internal_vproblem): Update.
5619 (ui_unregister_input_event_handler_cleanup)
5620 (prepare_to_handle_input): Remove.
5621 (class scoped_input_handler): New.
5622 (defaulted_query, prompt_for_continue): Update.
5623 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
5624 Update.
5625 * top.c (undo_terminal_modifications_before_exit): Update.
5626 * target/target.h (target_terminal_init, target_terminal_inferior)
5627 (target_terminal_ours): Don't declare.
5628 (class target_terminal): New.
5629 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
5630 (target_terminal_ours_for_output)
5631 (make_cleanup_restore_target_terminal): Don't declare.
5632 (target_terminal_info): Remove.
5633 * target.c (enum terminal_state, terminal_state): Remove.
5634 (target_terminal::terminal_state): Define.
5635 (target_terminal::init): Rename from target_terminal_init.
5636 (target_terminal::inferior): Rename from
5637 target_terminal_inferior.
5638 (target_terminal::ours): Rename from target_terminal_ours.
5639 (target_terminal::ours_for_output): Rename from
5640 target_terminal_ours_for_output.
5641 (target_terminal::info): New method.
5642 (cleanup_restore_target_terminal)
5643 (make_cleanup_restore_target_terminal): Remove.
5644 * solib.c (handle_solib_event): Update.
5645 * remote.c (remote_serial_quit_handler): Update.
5646 (remote_terminal_inferior, remote_wait_as): Update.
5647 * record-full.c (record_full_wait_1): Update.
5648 * nto-procfs.c (procfs_create_inferior): Update.
5649 * nat/fork-inferior.c (startup_inferior): Update.
5650 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
5651 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
5652 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
5653 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
5654 (mi_breakpoint_created, mi_breakpoint_deleted)
5655 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
5656 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
5657 (mi_user_selected_context_changed, report_initial_inferior):
5658 Update.
5659 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
5660 (linux_nat_terminal_inferior): Update.
5661 * infrun.c (follow_fork_inferior)
5662 (handle_vfork_child_exec_or_exit, do_target_resume)
5663 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
5664 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
5665 Update.
5666 * inflow.c (child_terminal_init, info_terminal_command): Update.
5667 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
5668 (attach_command): Update.
5669 * infcall.c (call_thread_fsm_should_stop): Update.
5670 * gnu-nat.c (gnu_attach): Update.
5671 * extension.c (struct active_ext_lang_state)
5672 (restore_active_ext_lang): Update.
5673 * exceptions.c (print_flush): Update.
5674 * event-top.c (async_enable_stdin, default_quit_handler): Update.
5675 (struct quit_handler_cleanup_data, restore_quit_handler)
5676 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
5677 Remove.
5678 * cp-support.c (gdb_demangle): Update.
5679 * breakpoint.c (update_inserted_breakpoint_locations)
5680 (insert_breakpoint_locations, handle_jit_event)
5681 (disable_breakpoints_in_unloaded_shlib): Update.
5682 * annotate.c (annotate_breakpoints_invalid)
5683 (annotate_frames_invalid): Update.
5684
5685 2017-09-20 Tom Tromey <tom@tromey.com>
5686
5687 * main.c (catch_command_errors): Rename from
5688 catch_command_errors_const.
5689 (captured_main_1): Update.
5690
5691 2017-09-20 Pedro Alves <palves@redhat.com>
5692
5693 * cli/cli-cmds.c (list_command): Use print_sal_location.
5694 (print_sal_location): New function.
5695 (ambiguous_line_spec): Use print_sal_location.
5696 * linespec.c (symbol_to_sal): Record the symbol in the sal.
5697 * symtab.c (find_function_start_sal): Likewise.
5698 * symtab.h (symtab_and_line::symbol): New field.
5699
5700 2017-09-20 Pedro Alves <palves@redhat.com>
5701
5702 * linespec.c (minsym_found): Handle non-text minsyms.
5703 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
5704
5705 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
5706
5707 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
5708 backslash.
5709
5710 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
5711
5712 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
5713 vmovups instead vmovaps.
5714 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
5715
5716 2017-09-19 John Baldwin <jhb@FreeBSD.org>
5717
5718 * NEWS (Changes since GDB 8.0): Add starti.
5719 * infcmd.c (enum run_break): New.
5720 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
5721 case.
5722 (run_command): Use enum run_how.
5723 (start_command): Likewise.
5724 (starti_command): New function.
5725 (RUN_ARGS_HELP): New macro.
5726 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
5727 commands. Add starti command.
5728
5729 2017-09-19 Yao Qi <yao.qi@linaro.org>
5730
5731 * Makefile.in (monitor.o): Remove the rule.
5732
5733 2017-09-19 Yao Qi <yao.qi@linaro.org>
5734
5735 * annotate.h (struct annotate_arg_emitter): Use
5736 DISABLE_COPY_AND_ASSIGN.
5737 * common/refcounted-object.h (refcounted_object): Likewise.
5738 * completer.h (struct completion_result): Likewise.
5739 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
5740 * filename-seen-cache.h (filename_seen_cache): Likewise.
5741 * gdbcore.h (thread_section_name): Likewise.
5742 * gdb_regex.h (compiled_regex): Likewise.
5743 * gdbthread.h (scoped_restore_current_thread): Likewise.
5744 * inferior.h (scoped_restore_current_inferior): Likewise.
5745 * jit.c (jit_reader): Likewise.
5746 * linespec.h (struct linespec_result): Likewise.
5747 * mi/mi-parse.h (struct mi_parse): Likewise.
5748 * nat/fork-inferior.c (execv_argv): Likewise.
5749 * progspace.h (scoped_restore_current_program_space): Likewise.
5750 * python/python-internal.h (class gdbpy_enter): Likewise.
5751 * regcache.h (regcache): Likewise.
5752 * target-descriptions.c (struct tdesc_reg): Likewise.
5753 (struct tdesc_type): Likewise.
5754 (struct tdesc_feature): Likewise.
5755 * ui-out.h (ui_out_emit_type): Likewise.
5756
5757 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
5758
5759 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
5760 label abort_expression.
5761
5762 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5763
5764 * common/buffer.c (buffer_xml_printf): Adjust.
5765 * common/xml-utils.c (xml_escape_text): Change return type to
5766 std::string, update code accordingly.
5767 * common/xml-utils.h (xml_escape_text): Change return type to
5768 std::string.
5769 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
5770 * windows-tdep.c (windows_xfer_shared_library): Adjust.
5771 * unittests/xml-utils-selftests.c (test_xml_escape_text):
5772 Adjust.
5773
5774 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5775
5776 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
5777 (SUBDIR_UNITTESTS_OBS): Add new object file.
5778 * unittests/xml-utils-selftests.c: New file.
5779
5780 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5781
5782 * common/selftest.h (selftest): New struct/interface.
5783 (register_test): Add name parameter, add new overload.
5784 (run_tests): Add filter parameter.
5785 (for_each_selftest_ftype): New typedef.
5786 (for_each_selftest): New declaration.
5787 * common/selftest.c (tests): Change type to
5788 map<string, unique_ptr<selftest>>.
5789 (simple_selftest): New struct.
5790 (register_test): New function.
5791 (register_test): Add name parameter and use it.
5792 (run_tests): Add filter parameter and use it. Add prints.
5793 Adjust to vector -> map change.
5794 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
5795 registering selftests.
5796 * arm-tdep.c (_initialize_arm_tdep): Likewise.
5797 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
5798 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
5799 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
5800 * findvar.c (_initialize_findvar): Likewise.
5801 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
5802 * maint.c (maintenance_selftest): Update call to run_tests.
5803 (maintenance_info_selftests): New function.
5804 (_initialize_maint_cmds): Register "maintenance info selftests"
5805 command. Update "maintenance selftest" doc.
5806 * regcache.c (_initialize_regcache): Add names when registering
5807 selftests.
5808 * rust-exp.y (_initialize_rust_exp): Likewise.
5809 * selftest-arch.c (gdbarch_selftest): New struct.
5810 (gdbarch_tests): Remove.
5811 (register_test_foreach_arch): Add name parameter. Call
5812 register_test.
5813 (tests_with_arch): Remove, move most content to
5814 gdbarch_selftest::operator().
5815 (_initialize_selftests_foreach_arch): Remove.
5816 * selftest-arch.h (register_test_foreach_arch): Add name
5817 parameter.
5818 (run_tests_with_arch): New declaration.
5819 * utils-selftests.c (_initialize_utils_selftests): Add names
5820 when registering selftests.
5821 * utils.c (_initialize_utils): Likewise.
5822 * unittests/array-view-selftests.c
5823 (_initialize_array_view_selftests): Likewise.
5824 * unittests/environ-selftests.c (_initialize_environ_selftests):
5825 Likewise.
5826 * unittests/function-view-selftests.c
5827 (_initialize_function_view_selftests): Likewise.
5828 * unittests/offset-type-selftests.c
5829 (_initialize_offset_type_selftests): Likewise.
5830 * unittests/optional-selftests.c
5831 (_initialize_optional_selftests): Likewise.
5832 * unittests/scoped_restore-selftests.c
5833 (_initialize_scoped_restore_selftests): Likewise.
5834 * NEWS: Document "maintenance selftest" and "maint info
5835 selftests".
5836
5837 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5838
5839 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
5840 scoped_restore.
5841
5842 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5843
5844 * mi/mi-main.c (mi_load_progress): Make uiout variable
5845 a unique_ptr.
5846
5847 2017-09-15 Pedro Alves <palves@redhat.com>
5848
5849 * compile/compile-c-types.c (convert_enum, convert_int)
5850 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
5851
5852 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5853
5854 * dwarf2read.c (copy_string): Remove.
5855 (parse_macro_definition): Replace copy_string with savestring.
5856
5857 2017-09-15 Yao Qi <yao.qi@linaro.org>
5858
5859 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
5860 gdb_target_obs.
5861 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
5862 Likewise.
5863 (i[34567]86-*-linux*): Likewise.
5864
5865 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5866
5867 * dwarf2expr.h (dwarf_stack_value): Add constructor.
5868 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
5869 <stack>: Change type to std::vector.
5870 <stack_len, stack_allocated>: Remove.
5871 <grow_stack>: Remove.
5872 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
5873 (dwarf_expr_context::~dwarf_expr_context): Remove.
5874 (dwarf_expr_context::grow_stack): Remove.
5875 (dwarf_expr_context::push): Adjust.
5876 (dwarf_expr_context::pop): Adjust.
5877 (dwarf_expr_context::fetch): Adjust.
5878 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
5879 (dwarf_expr_context::stack_empty_p): Adjust.
5880 (dwarf_expr_context::execute_stack_op): Adjust.
5881
5882 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5883
5884 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
5885 return type to bool.
5886 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
5887
5888 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5889
5890 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
5891 Change type to bool.
5892 (dwarf_stack_value) <in_stack_memory>: Likewise.
5893 (dwarf_expr_context) <push_address>: Change parameter type to
5894 bool.
5895 <fetch_in_stack_memory>: Change return type to bool.
5896 <push>: Change parameter type to bool.
5897 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
5898 to bool.
5899 (dwarf_expr_context::push_address): Likewise.
5900 (dwarf_expr_context::fetch_in_stack_memory): Change return type
5901 to bool.
5902 (dwarf_expr_context::execute_stack_op): Adjust.
5903 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
5904
5905 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5906
5907 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
5908 (struct dwarf_expr_context) <n_pieces>: Remove.
5909 <pieces>: Change type to std::vector.
5910 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
5911 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
5912 pieces.
5913 (dwarf_expr_context::add_piece): Adjust.
5914 * dwarf2loc.c (struct piece_closure): Initialize fields.
5915 <n_pieces>: Remove.
5916 <pieces>: Change type to std::vector.
5917 (allocate_piece_closure): Adjust, change parameter to
5918 std::vector rvalue and std::move it to piece_closure.
5919 (rw_pieced_value): Adjust.
5920 (check_pieced_synthetic_pointer): Adjust.
5921 (indirect_synthetic_pointer): Adjust.
5922 (coerce_pieced_ref): Adjust.
5923 (free_pieced_value_closure): Adjust. Use delete to free
5924 piece_closure.
5925 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
5926 to allocate_piece_closure.
5927 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
5928
5929 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5930
5931 * probe.h (probe_ops_cp): Remove typedef.
5932 (DEF_VEC_P (probe_ops_cp)): Remove.
5933 (all_probe_ops): Change type to std::vector.
5934 * probe.c (info_probes_for_ops): Adjust to vector change.
5935 (probe_linespec_to_ops): Likewise.
5936 (all_probe_ops): Change type to std::vector.
5937 (_initialize_probe): Adjust to vector change.
5938 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
5939 * elfread.c (elf_get_probes): Likewise.
5940 * stap-probe.c (_initialize_stap_probe): Likewise.
5941
5942 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5943
5944 * probe.h (struct bound_probe): Define constructors.
5945 * probe.c (bound_probe_s): Remove typedef.
5946 (DEF_VEC_O (bound_probe_s)): Remove VEC.
5947 (collect_probes): Change return type to std::vector, remove
5948 cleanup.
5949 (compare_probes): Return bool, change parameter type. Change
5950 semantic to "less than".
5951 (gen_ui_out_table_header_info): Change parameter to std::vector
5952 and update.
5953 (exists_probe_with_pops): Likewise.
5954 (info_probes_for_ops): Update to std::vector change.
5955 (enable_probes_command): Likewise.
5956 (disable_probes_command): Likewise.
5957
5958 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5959
5960 * probe.h (struct probe_ops) <get_probes>: Change parameter from
5961 vec to std::vector.
5962 * probe.c (parse_probes_in_pspace): Update.
5963 (find_probes_in_objfile): Update.
5964 (find_probe_by_pc): Update.
5965 (collect_probes): Update.
5966 (probe_any_get_probes): Update.
5967 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
5968 return type to reference to std::vector.
5969 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
5970 std::vector and update.
5971 (dtrace_process_dof): Likewise.
5972 (dtrace_get_probes): Likewise.
5973 * elfread.c (elf_get_probes): Change return type to std::vector,
5974 store an std::vector in bfd_data.
5975 (probe_key_free): Update to std::vector.
5976 * stap-probe.c (handle_stap_probe): Change parameter to
5977 std::vector and update.
5978 (stap_get_probes): Likewise.
5979 * symfile-debug.c (debug_sym_get_probes): Change return type to
5980 std::vector and update.
5981
5982 2017-09-11 Tom Tromey <tom@tromey.com>
5983
5984 * breakpoint.c (program_breakpoint_here_p): Update.
5985 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
5986 from make_show_memory_breakpoints_cleanup. Return a
5987 scoped_restore_tmpl<int>.
5988 (restore_show_memory_breakpoints): Remove.
5989 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
5990 * mem-break.c (memory_validate_breakpoint): Update.
5991 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
5992 (ia64_memory_remove_breakpoint): Update.
5993 (ia64_breakpoint_from_pc): Update.
5994 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
5995 from make_show_memory_breakpoints_cleanup.
5996
5997 2017-09-11 Tom Tromey <tom@tromey.com>
5998
5999 * d-namespace.c (d_lookup_symbol): Use std::string.
6000 (find_symbol_in_baseclass): Likewise.
6001
6002 2017-09-11 Tom Tromey <tom@tromey.com>
6003
6004 * ctf.c (ctf_start): Use std::string.
6005
6006 2017-09-11 Tom Tromey <tom@tromey.com>
6007
6008 * ada-lang.c (is_known_support_routine): Update.
6009 (ada_unhandled_exception_name_addr_from_raise): Update.
6010 * guile/scm-frame.c (gdbscm_frame_name): Update.
6011 * python/py-frame.c (frapy_name): Update.
6012 (frapy_function): Update.
6013 * stack.h (find_frame_funname): Update.
6014 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
6015 (print_frame): Update.
6016
6017 2017-09-11 Tom Tromey <tom@tromey.com>
6018
6019 * findcmd.c (put_bits): Take a gdb::byte_vector.
6020 (parse_find_args): Return gdb::byte_vector. "args" now const.
6021 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
6022 cleanups.
6023 (find_command): Update.
6024
6025 2017-09-11 Tom Tromey <tom@tromey.com>
6026
6027 * cli/cli-script.c (class scoped_restore_hook_in): New.
6028 (clear_hook_in_cleanup): Remove.
6029 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
6030 scoped_restore_hook_in.
6031
6032 2017-09-11 Tom Tromey <tom@tromey.com>
6033
6034 * cli/cli-script.c (restore_interp): Remove.
6035 (read_command_lines): Use scoped_restore_interp.
6036 * interps.c (scoped_restore_interp::set_temp): Rename from
6037 interp_set_temp.
6038 * interps.h (class scoped_restore_interp): New.
6039 (interp_set_temp): Remove.
6040
6041 2017-09-11 Tom Tromey <tom@tromey.com>
6042
6043 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6044 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
6045 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
6046 scoped_restore.
6047 (mi_cmd_break_insert_1): Update.
6048 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
6049 scoped_restore.
6050
6051 2017-09-11 Tom Tromey <tom@tromey.com>
6052
6053 * demangle.c (demangle_command): Update.
6054 * breakpoint.c (disable_command): Update.
6055 (enable_command): Update.
6056 (find_location_by_number): Make "number" const. Use
6057 get_number_trailer.
6058 * cli/cli-utils.c (extract_arg): Return std::string.
6059 * probe.c (parse_probe_linespec): Update. Change types.
6060 (collect_probes): Take string arguments.
6061 (parse_probe_linespec): Likewise.
6062 (info_probes_for_ops): Update.
6063 (enable_probes_command): Update.
6064 (disable_probes_command): Update.
6065 * break-catch-sig.c (catch_signal_split_args): Update.
6066 * mi/mi-parse.c (mi_parse): Update.
6067
6068 2017-09-11 Tom Tromey <tom@tromey.com>
6069
6070 * language.h (language_enum): Make argument const.
6071 * language.c (language_enum): Make argument const.
6072
6073 2017-09-11 Tom Tromey <tom@tromey.com>
6074
6075 * common/common-utils.h (skip_to_space): Remove macro, redeclare
6076 as function.
6077 (skip_to_space): Rename from skip_to_space_const.
6078 * common/common-utils.c (skip_to_space): New function.
6079 (skip_to_space): Rename from skip_to_space_const.
6080 * cli/cli-utils.h (get_number): Rename from get_number_const.
6081 (extract_arg): Rename from extract_arg_const.
6082 * cli/cli-utils.c (get_number): Rename from get_number_const.
6083 (extract_arg): Rename from extract_arg_const.
6084 (number_or_range_parser::get_number): Use ::get_number.
6085 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
6086 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
6087 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
6088 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
6089 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
6090 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
6091 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
6092 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
6093
6094 2017-09-11 Tom Tromey <tom@tromey.com>
6095
6096 * python/python.c (do_start_initialization): Use
6097 py-event-types.def to initialize types.
6098 Define all object type structures.
6099 * python/python-internal.h: Don't declare event initialization
6100 functions.
6101 * python/py-threadevent.c (thread_event_object_type): Don't
6102 define.
6103 * python/py-stopevent.c (stop_event_object_type): Don't define.
6104 * python/py-signalevent.c (signal_event_object_type): Don't
6105 declare or define.
6106 * python/py-newobjfileevent.c (new_objfile_event_object_type)
6107 (clear_objfiles_event_object_type): Don't declare or define.
6108 * python/py-infevents.c (inferior_call_pre_event_object_type)
6109 (inferior_call_post_event_object_type)
6110 (register_changed_event_object_type)
6111 (memory_changed_event_object_type): Don't declare or define.
6112 * python/py-inferior.c (new_thread_event_object_type)
6113 (new_inferior_event_object_type)
6114 (inferior_deleted_event_object_type): Don't declare or define.
6115 * python/py-exitedevent.c (exited_event_object_type): Don't
6116 declare or define.
6117 * python/py-evts.c (gdbpy_initialize_py_events): Use
6118 py-all-events.def.
6119 * python/py-events.h (thread_event_object_type): Don't declare.
6120 (events_object): Use py-all-events.def.
6121 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
6122 py-event-types.def.
6123 * python/py-event-types.def: New file.
6124 * python/py-continueevent.c (create_continue_event_object): Don't
6125 declare or define.
6126 * python/py-bpevent.c (breakpoint_event_object_type): Don't
6127 declare or define.
6128 * python/py-all-events.def: New file.
6129
6130 2017-09-11 Tom Tromey <tom@tromey.com>
6131
6132 * python/py-threadevent.c (create_thread_event_object): Return
6133 gdbpy_ref.
6134 * python/py-stopevent.h (create_stop_event_object)
6135 (create_breakpoint_event_object, create_signal_event_object):
6136 Update.
6137 * python/py-stopevent.c (create_stop_event_object): Return
6138 gdbpy_ref.
6139 (emit_stop_event): Update.
6140 * python/py-signalevent.c (create_signal_event_object): Return
6141 gdbpy_ref.
6142 * python/py-infevents.c (create_inferior_call_event_object):
6143 Update.
6144 * python/py-event.h (create_event_object)
6145 (create_thread_event_object): Update.
6146 * python/py-event.c (create_event_object): Return gdbpy_ref.
6147 * python/py-continueevent.c: Return gdbpy_ref.
6148 * python/py-bpevent.c (create_breakpoint_event_object): Return
6149 gdbpy_ref.
6150
6151 2017-09-11 Tom Tromey <tom@tromey.com>
6152
6153 PR python/15622:
6154 * NEWS: Add entry.
6155 * python/python.c (do_start_initialization): Initialize new event
6156 types.
6157 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
6158 (gdbpy_initialize_inferior_deleted_event)
6159 (gdbpy_initialize_new_thread_event): Declare.
6160 * python/py-threadevent.c (create_thread_event_object): Add option
6161 "thread" parameter.
6162 * python/py-inferior.c (new_thread_event_object_type)
6163 (new_inferior_event_object_type)
6164 (inferior_deleted_event_object_type): Declare.
6165 (python_new_inferior, python_inferior_deleted): New functions.
6166 (add_thread_object): Emit new_thread event.
6167 (gdbpy_initialize_inferior): Attach new functions to corresponding
6168 observers.
6169 (new_thread, new_inferior, inferior_deleted): Define new event
6170 types.
6171 * python/py-evts.c (gdbpy_initialize_py_events): Add new
6172 registries.
6173 * python/py-events.h (events_object) <new_inferior,
6174 inferior_deleted, new_thread>: New fields.
6175 * python/py-event.h (create_thread_event_breakpoint): Add optional
6176 "thread" parameter.
6177
6178 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
6179
6180 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
6181 check current_ui instead.
6182 (internal_vproblem): Likewise.
6183
6184 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
6185
6186 * thread.c (print_thread_info_1): Remove unnecessary calls to
6187 uiout->is_mi_like_p.
6188
6189 2017-09-09 Tom Tromey <tom@tromey.com>
6190
6191 * namespace.h (add_using_directive): Update.
6192 * namespace.c (add_using_directive): Change type of excludes to
6193 std::vector.
6194 * dwarf2read.c (read_import_statement): Use std::vector.
6195 (read_namespace): Update.
6196 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
6197
6198 2017-09-09 Tom Tromey <tom@tromey.com>
6199
6200 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
6201
6202 2017-09-09 Tom Tromey <tom@tromey.com>
6203
6204 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
6205
6206 2017-09-09 Tom Tromey <tom@tromey.com>
6207
6208 * stack.c (func_command): Use gdb::def_vector.
6209
6210 2017-09-09 Tom Tromey <tom@tromey.com>
6211
6212 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
6213 ui_out_emit_list, ui_out_emit_tuple.
6214 (mi_cmd_var_update): Likewise.
6215
6216 2017-09-09 Tom Tromey <tom@tromey.com>
6217
6218 * mi/mi-interp.c (mi_user_selected_context_changed): Use
6219 ui_out_redirect_pop.
6220 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
6221 ui_out_redirect_pop.
6222 * utils.c (do_ui_out_redirect_pop)
6223 (make_cleanup_ui_out_redirect_pop): Remove.
6224 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
6225 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
6226 * ui-out.h (ui_out_redirect_pop): New class.
6227
6228 2017-09-09 Tom Tromey <tom@tromey.com>
6229
6230 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
6231 (list_available_thread_groups, mi_cmd_list_thread_groups)
6232 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
6233 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
6234 Likewise.
6235
6236 2017-09-09 Tom Tromey <tom@tromey.com>
6237
6238 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
6239 ui_out_emit_tuple.
6240
6241 2017-09-09 Tom Tromey <tom@tromey.com>
6242
6243 * target.c (flash_erase_command): Use ui_out_emit_tuple.
6244 * stack.c (print_frame): Use ui_out_emit_tuple.
6245 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
6246 (info_spu_mailbox_command, info_spu_dma_command)
6247 (info_spu_proxydma_command): Likewise.
6248 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
6249 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
6250 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
6251 ui_out_emit_tuple.
6252 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
6253
6254 2017-09-09 Tom Tromey <tom@tromey.com>
6255
6256 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
6257 (class ui_out_emit_table): Update comment.
6258 * ui-out.c (do_cleanup_table_end)
6259 (make_cleanup_ui_out_table_begin_end): Remove.
6260 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
6261 (info_spu_dma_cmdlist): Likewise.
6262 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
6263 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
6264 ui_out_emit_table.
6265
6266 2017-09-09 Tom Tromey <tom@tromey.com>
6267
6268 * thread.c (print_thread_info_1): Use ui_out_emit_table,
6269 ui_out_emit_list, gdb::optional.
6270
6271 2017-09-09 John Baldwin <jhb@FreeBSD.org>
6272
6273 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
6274 prototype.
6275 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
6276 prototype.
6277 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
6278 prototype.
6279 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
6280 * ada-exp.y: Remove _initialize_ada_exp prototype.
6281 * ada-lang.c: Remove _initialize_ada_language prototype.
6282 * ada-tasks.c: Remove _initialize_tasks prototype.
6283 * addrmap.c: Remove _initialize_addrmap prototype.
6284 * agent.c: Remove _initialize_agent prototype.
6285 * aix-thread.c: Remove _initialize_aix_thread prototype.
6286 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
6287 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
6288 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
6289 prototype.
6290 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
6291 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
6292 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
6293 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
6294 prototype.
6295 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
6296 prototype.
6297 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
6298 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
6299 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
6300 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
6301 prototype.
6302 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
6303 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
6304 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
6305 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
6306 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
6307 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
6308 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
6309 prototype.
6310 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
6311 prototype.
6312 * annotate.c: Remove _initialize_annotate prototype.
6313 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
6314 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
6315 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
6316 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
6317 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
6318 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
6319 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
6320 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
6321 prototype.
6322 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
6323 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
6324 * auto-load.c: Remove _initialize_auto_load prototype.
6325 * auxv.c: Remove _initialize_auxv prototype.
6326 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
6327 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
6328 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
6329 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
6330 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
6331 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
6332 prototype.
6333 * break-catch-throw.c: Remove _initialize_break_catch_throw
6334 prototype.
6335 * breakpoint.c: Remove _initialize_breakpoint prototype.
6336 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
6337 * btrace.c: Remove _initialize_btrace prototype.
6338 * charset.c: Remove _initialize_charset prototype.
6339 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
6340 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
6341 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
6342 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
6343 * cli/cli-script.c: Remove _initialize_cli_script prototype.
6344 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
6345 * coffread.c: Remove _initialize_coffread prototype.
6346 * compile/compile.c: Remove _initialize_compile prototype.
6347 * complaints.c: Remove _initialize_complaints prototype.
6348 * completer.c: Remove _initialize_completer prototype.
6349 * copying.awk: Remove _initialize_copying prototype.
6350 * copying.c: Regenerate.
6351 * core-regset.c: Remove _initialize_core_regset prototype.
6352 * corefile.c: Remove _initialize_core prototype.
6353 * corelow.c: Remove _initialize_corelow prototype.
6354 * cp-abi.c: Remove _initialize_cp_abi prototype.
6355 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
6356 * cp-support.c: Remove _initialize_cp_support prototype.
6357 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
6358 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
6359 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
6360 * ctf.c: Remove _initialize_ctf prototype.
6361 * d-lang.c: Remove _initialize_d_language prototype.
6362 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
6363 prototype.
6364 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
6365 * dbxread.c: Remove _initialize_dbxread prototype.
6366 * dcache.c: Remove _initialize_dcache prototype.
6367 * demangle.c: Remove _initialize_demangler prototype.
6368 * disasm-selftests.c: Remove _initialize_disasm_selftests
6369 prototype.
6370 * disasm.c: Remove _initialize_disasm prototype.
6371 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
6372 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
6373 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
6374 prototype.
6375 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
6376 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
6377 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
6378 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
6379 * elfread.c: Remove _initialize_elfread prototype.
6380 * exec.c: Remove _initialize_exec prototype.
6381 * extension.c: Remove _initialize_extension prototype.
6382 * f-lang.c: Remove _initialize_f_language prototype.
6383 * f-valprint.c: Remove _initialize_f_valprint prototype.
6384 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
6385 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
6386 * filesystem.c: Remove _initialize_filesystem prototype.
6387 * findcmd.c: Remove _initialize_mem_search prototype.
6388 * fork-child.c: Remove _initialize_fork_child prototype.
6389 * frame-base.c: Remove _initialize_frame_base prototype.
6390 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
6391 * frame.c: Remove _initialize_frame prototype.
6392 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
6393 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
6394 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
6395 * gcore.c: Remove _initialize_gcore prototype.
6396 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
6397 * gdbarch.c: Regenerate.
6398 * gdbarch.sh: Remove _initialize_gdbarch prototype.
6399 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
6400 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
6401 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
6402 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
6403 * go-lang.c: Remove _initialize_go_language prototype.
6404 * go32-nat.c: Remove _initialize_go32_nat prototype.
6405 * guile/guile.c: Remove _initialize_guile prototype.
6406 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
6407 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
6408 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
6409 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
6410 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
6411 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
6412 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
6413 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
6414 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
6415 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
6416 prototype.
6417 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
6418 prototype.
6419 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
6420 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
6421 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
6422 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
6423 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
6424 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
6425 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
6426 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
6427 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
6428 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
6429 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
6430 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
6431 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
6432 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
6433 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
6434 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
6435 prototype.
6436 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
6437 prototype.
6438 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
6439 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
6440 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
6441 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
6442 * infcall.c: Remove _initialize_infcall prototype.
6443 * infcmd.c: Remove _initialize_infcmd prototype.
6444 * inferior.c: Remove _initialize_inferiors prototype.
6445 * inflow.c: Remove _initialize_inflow prototype.
6446 * infrun.c: Remove _initialize_infrun prototype.
6447 * interps.c: Remove _initialize_interpreter prototype.
6448 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
6449 * jit.c: Remove _initialize_jit prototype.
6450 * language.c: Remove _initialize_language prototype.
6451 * linux-fork.c: Remove _initialize_linux_fork prototype.
6452 * linux-nat.c: Remove _initialize_linux_nat prototype.
6453 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
6454 * linux-thread-db.c: Remove _initialize_thread_db prototype.
6455 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
6456 * m2-lang.c: Remove _initialize_m2_language prototype.
6457 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
6458 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
6459 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
6460 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
6461 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
6462 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
6463 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
6464 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
6465 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
6466 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
6467 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
6468 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
6469 * machoread.c: Remove _initialize_machoread prototype.
6470 * macrocmd.c: Remove _initialize_macrocmd prototype.
6471 * macroscope.c: Remove _initialize_macroscope prototype.
6472 * maint.c: Remove _initialize_maint_cmds prototype.
6473 * mdebugread.c: Remove _initialize_mdebugread prototype.
6474 * memattr.c: Remove _initialize_mem prototype.
6475 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
6476 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
6477 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
6478 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
6479 * mi/mi-main.c: Remove _initialize_mi_main prototype.
6480 * microblaze-linux-tdep.c: Remove
6481 _initialize_microblaze_linux_tdep prototype.
6482 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
6483 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
6484 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
6485 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
6486 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
6487 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
6488 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
6489 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
6490 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
6491 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
6492 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
6493 prototype.
6494 * mipsread.c: Remove _initialize_mipsread prototype.
6495 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
6496 prototype.
6497 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
6498 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
6499 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
6500 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
6501 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
6502 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
6503 prototype.
6504 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
6505 * nto-procfs.c: Remove _initialize_procfs prototype.
6506 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
6507 * objc-lang.c: Remove _initialize_objc_language prototype.
6508 * objfiles.c: Remove _initialize_objfiles prototype.
6509 * observer.c: Remove observer_test_first_notification_function,
6510 observer_test_second_notification_function,
6511 observer_test_third_notification_function, and
6512 _initialize_observer prototypes.
6513 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
6514 * osabi.c: Remove _initialize_gdb_osabi prototype.
6515 * osdata.c: Remove _initialize_osdata prototype.
6516 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
6517 * parse.c: Remove _initialize_parse prototype.
6518 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
6519 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
6520 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
6521 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
6522 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
6523 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
6524 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
6525 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
6526 * printcmd.c: Remove _initialize_printcmd prototype.
6527 * probe.c: Remove _initialize_probe prototype.
6528 * proc-api.c: Remove _initialize_proc_api prototype.
6529 * proc-events.c: Remove _initialize_proc_events prototype.
6530 * proc-service.c: Remove _initialize_proc_service prototype.
6531 * procfs.c: Remove _initialize_procfs prototype.
6532 * psymtab.c: Remove _initialize_psymtab prototype.
6533 * python/python.c: Remove _initialize_python prototype.
6534 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
6535 * record-btrace.c: Remove _initialize_record_btrace prototype.
6536 * record-full.c: Remove _initialize_record_full prototype.
6537 * record.c: Remove _initialize_record prototype.
6538 * regcache.c: Remove _initialize_regcache prototype.
6539 * reggroups.c: Remove _initialize_reggroup prototype.
6540 * remote-notif.c: Remove _initialize_notif prototype.
6541 * remote-sim.c: Remove _initialize_remote_sim prototype.
6542 * remote.c: Remove _initialize_remote prototype.
6543 * reverse.c: Remove _initialize_reverse prototype.
6544 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
6545 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
6546 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
6547 prototype.
6548 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
6549 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
6550 * rust-exp.y: Remove _initialize_rust_exp prototype.
6551 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
6552 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
6553 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
6554 * score-tdep.c: Remove _initialize_score_tdep prototype.
6555 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
6556 prototype.
6557 * ser-go32.c: Remove _initialize_ser_dos prototype.
6558 * ser-mingw.c: Remove _initialize_ser_windows prototype.
6559 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
6560 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
6561 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
6562 * serial.c: Remove _initialize_serial prototype.
6563 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
6564 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
6565 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
6566 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
6567 * skip.c: Remove _initialize_step_skip prototype.
6568 * sol-thread.c: Remove _initialize_sol_thread prototype.
6569 * solib-aix.c: Remove _initialize_solib_aix prototype.
6570 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
6571 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
6572 * solib-frv.c: Remove _initialize_frv_solib prototype.
6573 * solib-spu.c: Remove _initialize_spu_solib prototype.
6574 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
6575 * solib-target.c: Remove _initialize_solib_target prototype.
6576 * solib.c: Remove _initialize_solib prototype.
6577 * source.c: Remove _initialize_source prototype.
6578 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
6579 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
6580 prototype.
6581 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
6582 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
6583 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
6584 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
6585 prototype.
6586 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
6587 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
6588 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
6589 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
6590 prototype.
6591 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
6592 prototype.
6593 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
6594 prototype.
6595 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
6596 prototype.
6597 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
6598 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
6599 prototype.
6600 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
6601 prototype.
6602 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
6603 prototype.
6604 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
6605 prototype.
6606 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
6607 prototype.
6608 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
6609 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
6610 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
6611 * stabsread.c: Remove _initialize_stabsread prototype.
6612 * stack.c: Remove _initialize_stack prototype.
6613 * stap-probe.c: Remove _initialize_stap_probe prototype.
6614 * std-regs.c: Remove _initialize_frame_reg prototype.
6615 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
6616 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
6617 * symfile.c: Remove _initialize_symfile prototype.
6618 * symmisc.c: Remove _initialize_symmisc prototype.
6619 * symtab.c: Remove _initialize_symtab prototype.
6620 * target-dcache.c: Remove _initialize_target_dcache prototype.
6621 * target-descriptions.c: Remove _initialize_target_descriptions
6622 prototype.
6623 * thread.c: Remove _initialize_thread prototype.
6624 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
6625 prototype.
6626 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
6627 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
6628 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
6629 prototype.
6630 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
6631 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
6632 * tracefile.c: Remove _initialize_tracefile prototype.
6633 * tracepoint.c: Remove _initialize_tracepoint prototype.
6634 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
6635 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
6636 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
6637 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
6638 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
6639 * tui/tui-win.c: Remove _initialize_tui_win prototype.
6640 * tui/tui.c: Remove _initialize_tui prototype.
6641 * typeprint.c: Remove _initialize_typeprint prototype.
6642 * user-regs.c: Remove _initialize_user_regs prototype.
6643 * utils.c: Remove _initialize_utils prototype.
6644 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
6645 * valarith.c: Remove _initialize_valarith prototype.
6646 * valops.c: Remove _initialize_valops prototype.
6647 * valprint.c: Remove _initialize_valprint prototype.
6648 * value.c: Remove _initialize_values prototype.
6649 * varobj.c: Remove _initialize_varobj prototype.
6650 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
6651 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
6652 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
6653 * windows-nat.c: Remove _initialize_windows_nat,
6654 _initialize_check_for_gdb_ini, and _initialize_loadable
6655 prototypes.
6656 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
6657 * xcoffread.c: Remove _initialize_xcoffread prototype.
6658 * xml-support.c: Remove _initialize_xml_support prototype.
6659 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
6660 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
6661 prototype.
6662 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
6663 prototype.
6664 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
6665
6666 2017-09-08 Keith Seitz <keiths@redhat.com>
6667
6668 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
6669 field.
6670
6671 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
6672
6673 * f-valprint.c (f_val_print): Remove check for one byte
6674 sized integers. Remove printing of character type.
6675
6676 2017-09-08 Frank Penczek <frank.penczek@intel.com>
6677 Christoph Weinmann <christoph.t.weinmann@intel.com>
6678 Bernhard Heckel <bernhard.heckel@intel.com>
6679
6680 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
6681 to maintain proper indentation when printing pointers/refs.
6682
6683 2017-09-07 Joel Brobecker <brobecker@adacore.com>
6684
6685 GDB 8.0.1 released.
6686
6687 2017-09-07 Joel Brobecker <brobecker@adacore.com>
6688
6689 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
6690
6691 2017-09-05 Tom Tromey <tom@tromey.com>
6692
6693 * parse.c (funcall_chain): Now a std::vector.
6694 (start_arglist, end_arglist): Simplify.
6695 (free_funcalls): Remove.
6696 (parse_exp_in_context_1): Remove cleanup.
6697
6698 2017-09-05 Tom Tromey <tom@tromey.com>
6699
6700 * go-exp.y (go_parse): Don't create a cleanup.
6701
6702 2017-09-05 Tom Tromey <tom@tromey.com>
6703
6704 * d-exp.y (PrimaryExpression): Use std::string.
6705 (d_parse): Don't create a cleanup.
6706
6707 2017-09-05 Tom Tromey <tom@tromey.com>
6708
6709 * utils.c (do_clear_parser_state): Remove.
6710 (make_cleanup_clear_parser_state): Remove.
6711 * p-exp.y (pascal_parse): Use scoped_restore.
6712 * m2-exp.y (m2_parse): Use scoped_restore.
6713 * f-exp.y (f_parse): Use scoped_restore.
6714 * d-exp.y (d_parse): Use scoped_restore.
6715 * c-exp.y (c_parse): Use scoped_restore.
6716 * ada-exp.y (ada_parse): Use scoped_restore.
6717 * utils.h (make_cleanup_clear_parser_state): Remove.
6718
6719 2017-09-06 Keith Seitz <keiths@redhat.com>
6720
6721 * dwarf2read.c (dw2_linkage_name_attr): New function.
6722 (dw2_linkage_name): New function.
6723 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
6724 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
6725 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
6726
6727 2017-09-06 Kamil Rytarowski <n54@gmx.com>
6728
6729 * config/djgpp/djconfig.sh: Correct shell portability issue.
6730
6731 2017-09-06 Kamil Rytarowski <n54@gmx.com>
6732
6733 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
6734
6735 2017-09-06 John Baldwin <jhb@FreeBSD.org>
6736
6737 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
6738 * NEWS: Mention new FreeBSD/mips native configuration.
6739 * configure.host: Add aarch64*-*-freebsd*.
6740 * configure.nat: Likewise.
6741 * aarch64-fbsd-nat.c: New file.
6742
6743 2017-09-06 John Baldwin <jhb@FreeBSD.org>
6744
6745 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
6746 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
6747 * NEWS: Mention new FreeBSD/aarch64 target.
6748 * configure.tgt: Add aarch64*-*-freebsd*.
6749 * aarch64-fbsd-tdep.c: New file.
6750 * aarch64-fbsd-tdep.h: New file.
6751
6752 2017-09-06 Kamil Rytarowski <n54@gmx.com>
6753
6754 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
6755
6756 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
6757
6758 * parse.c (find_minsym_type_and_address): Don't relocate addresses
6759 of TLS symbols.
6760
6761 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6762
6763 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
6764 call.
6765
6766 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6767
6768 * infrun.c (follow_exec): Call add_thread after
6769 target_find_description.
6770
6771 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6772
6773 * infrun.c (handle_inferior_event_1): When exec'ing, read
6774 stop_pc after follow_exec.
6775
6776 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6777
6778 * remote.c (process_g_packet): Update error message.
6779
6780 2017-09-05 Yao Qi <yao.qi@linaro.org>
6781
6782 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
6783 targets.
6784
6785 2017-09-05 Pedro Alves <palves@redhat.com>
6786
6787 * eval.c (eval_call, evaluate_funcall): New functions, factored
6788 out from ...
6789 (evaluate_subexp_standard): ... this.
6790
6791 2017-09-05 Yao Qi <yao.qi@linaro.org>
6792
6793 * amd64-tdep.c (amd64_target_description): Create target
6794 descriptions.
6795 (_initialize_amd64_tdep): Don't call functions
6796 initialize_tdesc_amd64_*. Add self tests.
6797 * arch/amd64.c (amd64_create_target_description): Add parameter
6798 is_linux. Call set_tdesc_osabi if is_linux is true.
6799 * arch/amd64.h (amd64_create_target_description): Update the
6800 declaration.
6801 * arch/i386.c (i386_create_target_description): Add parameter
6802 is_linux. Call set_tdesc_osabi if is_linux is true.
6803 * arch/i386.h (i386_create_target_description): Update
6804 declaration.
6805 * configure.tgt: Add i386.o to gdb_target_obs.
6806 * features/Makefile (XMLTOC): Remove i386/*.xml.
6807 * features/i386/amd64-avx-avx512.c: Remove.
6808 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
6809 * features/i386/amd64-avx-mpx.c: Remove.
6810 * features/i386/amd64-avx.c: Remove.
6811 * features/i386/amd64-mpx.c: Remove.
6812 * features/i386/amd64.c: Remove.
6813 * features/i386/i386-avx-avx512.c: Remove.
6814 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
6815 * features/i386/i386-avx-mpx.c: Remove.
6816 * features/i386/i386-avx.c: Remove.
6817 * features/i386/i386-mmx.c: Remove.
6818 * features/i386/i386-mpx.c: Remove.
6819 * features/i386/i386.c: Remove.
6820 * i386-tdep.c: Don't include features/i386/i386*.c., include
6821 target-descriptions.h and arch/i386.h.
6822 (i386_target_description): Create target descriptions.
6823 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
6824 functions. Do self tests.
6825
6826 2017-09-05 Yao Qi <yao.qi@linaro.org>
6827
6828 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
6829 * features/i386/amd64-avx-avx512-linux.c: Removed.
6830 * features/i386/amd64-avx-linux.c: Removed.
6831 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
6832 * features/i386/amd64-avx-mpx-linux.c: Removed.
6833 * features/i386/amd64-linux.c: Removed.
6834 * features/i386/amd64-mpx-linux.c: Removed.
6835 * features/i386/x32-avx-avx512-linux.c: Removed.
6836 * features/i386/x32-avx-linux.c: Removed.
6837 * features/i386/x32-linux.c: Removed.
6838
6839 2017-09-05 Yao Qi <yao.qi@linaro.org>
6840
6841 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
6842 features/i386/*.c.
6843 (amd64_linux_read_description): Call
6844 amd64_create_target_description.
6845 * arch/amd64.c: New file.
6846 * arch/amd64.h: New file.
6847 * configure.tgt (x86_64-*-linux*): Append amd64.o.
6848 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
6849
6850 2017-09-05 Yao Qi <yao.qi@linaro.org>
6851
6852 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
6853 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
6854 (amd64_linux_read_description): Create target descriptions.
6855 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
6856 functions. Add unit tests.
6857 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
6858 x32-core.xml.
6859 * features/i386/64bit-avx.c: Generated.
6860 * features/i386/64bit-avx512.c: Generated.
6861 * features/i386/64bit-core.c: Generated.
6862 * features/i386/64bit-linux.c: Generated.
6863 * features/i386/64bit-mpx.c: Generated.
6864 * features/i386/64bit-pkeys.c: Generated.
6865 * features/i386/64bit-segments.c: Generated.
6866 * features/i386/64bit-sse.c: Generated.
6867 * features/i386/x32-core.c: Generated.
6868 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
6869 c files for amd64-linux and x32-linux.
6870
6871 2017-09-05 Yao Qi <yao.qi@linaro.org>
6872
6873 * amd64-linux-tdep.c (amd64_linux_read_description): New
6874 function.
6875 (amd64_linux_core_read_description): Call
6876 amd64_linux_read_description.
6877 (amd64_linux_init_abi): Likewise.
6878 (amd64_x32_linux_init_abi): Likewise.
6879 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
6880 * x86-linux-nat.c (x86_linux_read_description): Call
6881 amd64_linux_read_description.
6882
6883 2017-09-05 Yao Qi <yao.qi@linaro.org>
6884
6885 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
6886 comments.
6887
6888 2017-09-05 Yao Qi <yao.qi@linaro.org>
6889
6890 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
6891 * features/i386/i386-avx-avx512-linux.c: Remove.
6892 * features/i386/i386-avx-linux.c: Remove.
6893 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
6894 * features/i386/i386-avx-mpx-linux.c: Remove.
6895 * features/i386/i386-linux.c: Remove.
6896 * features/i386/i386-mmx-linux.c: Remove.
6897 * features/i386/i386-mpx-linux.c: Remove.
6898
6899 2017-09-05 Yao Qi <yao.qi@linaro.org>
6900
6901 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
6902 (SFILES): Add arch/i386.c.
6903 (HFILES_NO_SRCDIR): Add arch/i386.h.
6904 * arch/i386.c: New file.
6905 * arch/i386.h: New file.
6906 * arch/tdesc.h (allocate_target_description): Declare.
6907 (set_tdesc_architecture): Declare.
6908 (set_tdesc_osabi): Declare.
6909 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
6910 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
6911 include arch/i386.h.
6912 (i386_linux_read_description): Remove code and call
6913 i386_create_target_description.
6914 (set_tdesc_architecture): New function.
6915 (set_tdesc_osabi): New function.
6916 * target-descriptions.h (allocate_target_description): Remove.
6917
6918 2017-09-05 Yao Qi <yao.qi@linaro.org>
6919
6920 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
6921 * target-descriptions.c (tdesc_create_feature): Likewise, and
6922 adjust code.
6923 * features/i386/32bit-avx.c: Re-generated.
6924 * features/i386/32bit-avx512.c: Re-generated.
6925 * features/i386/32bit-core.c: Re-generated.
6926 * features/i386/32bit-linux.c: Re-generated.
6927 * features/i386/32bit-mpx.c: Re-generated.
6928 * features/i386/32bit-pkeys.c: Re-generated.
6929 * features/i386/32bit-sse.c: Re-generated.
6930
6931 2017-09-05 Yao Qi <yao.qi@linaro.org>
6932
6933 * regformats/regdef.h (struct reg): Override operator == and !=.
6934
6935 2017-09-05 Yao Qi <yao.qi@linaro.org>
6936
6937 * arch/tdesc.h: New file.
6938 * regformats/regdat.sh: Generate code using tdesc_create_reg.
6939 * target-descriptions.c: Update comments.
6940 * target-descriptions.h: Include "arch/tdesc.h". Remove the
6941 declarations.
6942 * features/i386/32bit-avx.c: Re-generated.
6943 * features/i386/32bit-avx512.c: Re-generated.
6944 * features/i386/32bit-core.c: Re-generated.
6945 * features/i386/32bit-linux.c: Re-generated.
6946 * features/i386/32bit-mpx.c: Re-generated.
6947 * features/i386/32bit-pkeys.c: Re-generated.
6948 * features/i386/32bit-sse.c: Re-generated.
6949
6950 2017-09-05 Yao Qi <yao.qi@linaro.org>
6951
6952 * regformats/regdat.sh: Update generated code.
6953
6954 2017-09-05 Yao Qi <yao.qi@linaro.org>
6955
6956 * regformats/regdat.sh: Adjust code order.
6957
6958 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6959
6960 * expprint.c (dump_subexp_body_standard): Use constant format
6961 string in fprintf_filtered call.
6962
6963 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6964
6965 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
6966 NetBSD/i386.
6967 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
6968
6969 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6970
6971 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
6972
6973 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6974
6975 * bsd-kvm.o: Define _KMEMUSER.
6976 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
6977 * configure: Regenerate.
6978
6979 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6980
6981 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
6982 * i386-fbsd-nat.c: Likewise.
6983
6984 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6985
6986 * unittests/array-view-selftests.c: Add include of <array>.
6987
6988 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6989
6990 * spu-tdep.c (flush_ea_cache): Add missing argument to
6991 call_function_by_hand.
6992
6993 2017-09-04 Pedro Alves <palves@redhat.com>
6994
6995 * NEWS (Safer support for debugging with no debug info): New.
6996
6997 2017-09-04 Pedro Alves <palves@redhat.com>
6998
6999 * c-exp.y (function_method, function_method_void): Add current
7000 instance flags to TYPE_INSTANCE.
7001 * dwarf2read.c (check_modifier): New.
7002 (compute_delayed_physnames): Assert that only C++ adds delayed
7003 physnames. Mark fn_fields as const/volatile depending on
7004 physname.
7005 * eval.c (make_params): New type_instance_flags parameter. Use
7006 it as the new type's instance flags.
7007 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
7008 flags element and pass it to make_params.
7009 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
7010 instance flags element.
7011 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
7012 * gdbtypes.h: Include "enum-flags.h".
7013 (type_instance_flags): New enum-flags type.
7014 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
7015 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
7016 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
7017 (follow_type_instance_flags): New function.
7018 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
7019 * parser-defs.h (follow_type_instance_flags): Declare.
7020 * valops.c (value_struct_elt_for_reference): const/volatile must
7021 match too.
7022
7023 2017-09-04 Pedro Alves <palves@redhat.com>
7024
7025 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
7026 function/method scopes; lookup the nested name as a function local
7027 static variable.
7028
7029 2017-09-04 Pedro Alves <palves@redhat.com>
7030
7031 (%type <voidval>): Add function_method.
7032 * c-exp.y (exp): New production for calls with no arguments.
7033 (function_method, function_method_void_or_typelist): New
7034 productions.
7035 (exp): New production for "method()::static_var".
7036 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
7037 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7038 Handle OP_FUNC_STATIC_VAR.
7039 * parse.c (operator_length_standard):
7040 Handle OP_FUNC_STATIC_VAR.
7041
7042 2017-09-04 Pedro Alves <palves@redhat.com>
7043
7044 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
7045 handling.
7046 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7047 Ditto.
7048 * parse.c (operator_length_standard, operator_check_standard):
7049 Ditto.
7050 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
7051
7052 2017-09-04 Pedro Alves <palves@redhat.com>
7053
7054 * ax-gdb.c: Include "typeprint.h".
7055 (gen_expr_for_cast): New function.
7056 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
7057 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
7058 type is unknown.
7059 * dwarf2read.c (new_symbol_full): Fallback to int instead of
7060 nodebug_data_symbol.
7061 * eval.c: Include "typeprint.h".
7062 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
7063 Error out if symbol has unknown type.
7064 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
7065 evaluate_subexp_for_cast.
7066 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
7067 OP_VAR_MSYM_VALUE.
7068 (evaluate_subexp_for_cast): New function.
7069 * gdbtypes.c (init_nodebug_var_type): New function.
7070 (objfile_type): Use it to initialize types of variables with no
7071 debug info.
7072 * typeprint.c (error_unknown_type): New.
7073 * typeprint.h (error_unknown_type): New declaration.
7074 * compile/compile-c-types.c (convert_type_basic): Handle
7075 TYPE_CODE_ERROR; warn and fallback to int for variables with
7076 unknown type.
7077
7078 2017-09-04 Pedro Alves <palves@redhat.com>
7079
7080 * eval.c (evaluate_var_value): New function, factored out from ...
7081 (evaluate_subexp_standard): ... here.
7082
7083 2017-09-04 Pedro Alves <palves@redhat.com>
7084
7085 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
7086 Remove useless assignments to 'op'.
7087
7088 2017-09-04 Pedro Alves <palves@redhat.com>
7089
7090 * eval.c (eval_skip_value): New function.
7091 (evaluate_subexp_standard): Use it.
7092
7093 2017-09-04 Pedro Alves <palves@redhat.com>
7094
7095 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
7096 function name from symbol/minsym and pass it to
7097 error_call_unknown_return_type.
7098
7099 2017-09-04 Pedro Alves <palves@redhat.com>
7100
7101 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
7102 * ax-gdb.c (gen_msym_var_ref): New function.
7103 (gen_expr): Handle OP_VAR_MSYM_VALUE.
7104 * eval.c (evaluate_var_msym_value): New function.
7105 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
7106 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
7107 to call_function_by_hand.
7108 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7109 Handle OP_VAR_MSYM_VALUE.
7110 (union exp_element) <msymbol>: New field.
7111 * minsyms.h (struct type): Forward declare.
7112 (find_minsym_type_and_address): Declare.
7113 * parse.c (write_exp_elt_msym): New function.
7114 (write_exp_msymbol): Delete, refactored as ...
7115 (find_minsym_type_and_address): ... this new function.
7116 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
7117 (operator_length_standard, operator_check_standard): Handle
7118 OP_VAR_MSYM_VALUE.
7119 * std-operator.def (OP_VAR_MSYM_VALUE): New.
7120
7121 2017-09-04 Pedro Alves <palves@redhat.com>
7122
7123 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
7124 TYPE_GNU_IFUNC specially here. Throw error if return type is
7125 unknown.
7126 * ada-typeprint.c (print_func_type): Handle functions with unknown
7127 return type.
7128 * c-typeprint.c (c_type_print_base): Handle functions and methods
7129 with unknown return type.
7130 * compile/compile-c-symbols.c (convert_symbol_bmsym)
7131 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
7132 * compile/compile-c-types.c: Include "objfiles.h".
7133 (convert_func): For functions with unknown return type, warn and
7134 default to int.
7135 * compile/compile-object-run.c (compile_object_run): Adjust call
7136 to call_function_by_hand_dummy.
7137 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
7138 call_function_by_hand.
7139 * eval.c (evaluate_subexp_standard): Adjust calls to
7140 call_function_by_hand. Handle functions and methods with unknown
7141 return type. Pass expect_type to call_function_by_hand.
7142 * f-typeprint.c (f_type_print_base): Handle functions with unknown
7143 return type.
7144 * gcore.c (call_target_sbrk): Adjust call to
7145 call_function_by_hand.
7146 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
7147 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
7148 an integer address type instead of nodebug.
7149 * guile/scm-value.c (gdbscm_value_call): Adjust call to
7150 call_function_by_hand.
7151 * infcall.c (error_call_unknown_return_type): New function.
7152 (call_function_by_hand): New "default_return_type" parameter.
7153 Pass it down.
7154 (call_function_by_hand_dummy): New "default_return_type"
7155 parameter. Use it instead of defaulting to int. If there's no
7156 default and the return type is unknown, throw an error. If
7157 there's a default return type, and the called function has no
7158 debug info, then assume the function is prototyped.
7159 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
7160 New "default_return_type" parameter.
7161 (error_call_unknown_return_type): New declaration.
7162 * linux-fork.c (call_lseek): Cast return type of lseek.
7163 (inferior_call_waitpid, checkpoint_command): Adjust calls to
7164 call_function_by_hand.
7165 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
7166 calls to call_function_by_hand.
7167 * m2-typeprint.c (m2_procedure): Handle functions with unknown
7168 return type.
7169 * objc-lang.c (lookup_objc_class, lookup_child_selector)
7170 (value_nsstring, print_object_command): Adjust calls to
7171 call_function_by_hand.
7172 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
7173 functions with unknown return type.
7174 (pascal_type_print_func_varspec_suffix): New function.
7175 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
7176 TYPE_CODE_METHOD>: Use it.
7177 * python/py-value.c (valpy_call): Adjust call to
7178 call_function_by_hand.
7179 * rust-lang.c (rust_evaluate_funcall): Adjust call to
7180 call_function_by_hand.
7181 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
7182 call_function_by_hand.
7183 * valops.c (value_allocate_space_in_inferior): Adjust call to
7184 call_function_by_hand.
7185 * typeprint.c (type_print_unknown_return_type): New function.
7186 * typeprint.h (type_print_unknown_return_type): New declaration.
7187
7188 2017-09-04 Pedro Alves <palves@redhat.com>
7189
7190 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
7191 types with more than one parameter as prototyped.
7192
7193 2017-09-04 Pedro Alves <palves@redhat.com>
7194
7195 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
7196 (disassemble_command): Use gdb_disassembly_flags instead of bare
7197 int.
7198 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
7199 (dump_insns, do_mixed_source_and_assembly_deprecated)
7200 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
7201 Use gdb_disassembly_flags instead of bare int.
7202 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
7203 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
7204 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
7205 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
7206 (enum gdb_disassembly_flag): ... values of this new enumeration.
7207 (gdb_disassembly_flags): Define.
7208 (gdb_disassembly)
7209 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
7210 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
7211 gdb_disassembly_flags instead of bare int.
7212 * record-btrace.c (btrace_insn_history)
7213 (record_btrace_insn_history, record_btrace_insn_history_range)
7214 (record_btrace_insn_history_from): Use gdb_disassembly_flags
7215 instead of bare int.
7216 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
7217 Use gdb_disassembly_flags instead of bare int.
7218 * target-debug.h (target_debug_print_gdb_disassembly_flags):
7219 Define.
7220 * target-delegates.c: Regenerate.
7221 * target.c (target_insn_history, target_insn_history_from)
7222 (target_insn_history_range): Use gdb_disassembly_flags instead of
7223 bare int.
7224 * target.h: Include "disasm.h".
7225 (struct target_ops) <to_insn_history, to_insn_history_from,
7226 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
7227 int.
7228 (target_insn_history, target_insn_history_from)
7229 (target_insn_history_range): Use gdb_disassembly_flags instead of
7230 bare int.
7231
7232 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7233
7234 * cli/cli-script.c (build_command_line): For if/while commands,
7235 check whether args is empty.
7236
7237 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7238
7239 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
7240 (enum command_control_type): Likewise.
7241 (struct command_line): Likewise.
7242 (free_command_lines): Likewise.
7243 (struct command_lines_deleter): Likewise.
7244 (command_line_up): Likewise.
7245 (read_command_lines): Likewise.
7246 (read_command_lines_1): Likewise.
7247 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
7248 (enum command_control_type): Likewise.
7249 (struct command_line): Likewise.
7250 (free_command_lines): Likewise.
7251 (struct command_lines_deleter): Likewise.
7252 (command_line_up): Likewise.
7253 (read_command_lines): Likewise.
7254 (read_command_lines_1): Likewise.
7255 * breakpoint.h: Include cli/cli-script.h.
7256 * extension-priv.h: Likewise.
7257 * gdbcmd.h: Likewise.
7258
7259 2017-09-04 Pedro Alves <palves@redhat.com>
7260
7261 * ada-lang.c (is_known_support_routine): Move sal declaration to
7262 where it is initialized.
7263 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
7264 (parse_breakpoint_sals, decode_static_tracepoint_spec)
7265 (clear_command, update_static_tracepoint): Remove init_sal
7266 references. Move declarations closer to initializations.
7267 * cli/cli-cmds.c (list_command): Move sal declarations closer to
7268 initializations.
7269 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
7270 references. Move sal declarations closer to initializations.
7271 * frame.c (find_frame_sal): Return a symtab_and_line via function
7272 return instead of output parameter. Remove init_sal references.
7273 * frame.h (find_frame_sal): Return a symtab_and_line via function
7274 return instead of output parameter.
7275 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
7276 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
7277 instead of memset.
7278 (gdbscm_find_pc_line): Remove init_sal reference.
7279 * infcall.c (call_function_by_hand_dummy): Remove init_sal
7280 references. Move declarations closer to initializations.
7281 * infcmd.c (set_step_frame): Update. Move declarations closer to
7282 initializations.
7283 (finish_backward): Remove init_sal references. Move declarations
7284 closer to initializations.
7285 * infrun.c (process_event_stop_test, handle_step_into_function)
7286 (insert_hp_step_resume_breakpoint_at_frame)
7287 (insert_step_resume_breakpoint_at_caller): Likewise.
7288 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
7289 (symbol_to_sal): Likewise.
7290 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
7291 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
7292 to its initialization.
7293 * reverse.c (save_bookmark_command): Use new/delete. Remove
7294 init_sal references. Move declarations closer to initializations.
7295 * source.c (get_current_source_symtab_and_line): Remove brace
7296 initialization.
7297 (set_current_source_symtab_and_line): Now takes the sal by const
7298 reference. Remove brace initialization.
7299 (line_info): Remove init_sal reference.
7300 * source.h (set_current_source_symtab_and_line): Now takes a
7301 symtab_and_line via const reference.
7302 * stack.c (set_current_sal_from_frame): Adjust.
7303 (print_frame_info): Adjust.
7304 (get_last_displayed_sal): Return the sal via function return
7305 instead of via output parameter. Simplify.
7306 (frame_info): Adjust.
7307 * stack.h (get_last_displayed_sal): Return the sal via function
7308 return instead of via output parameter.
7309 * symtab.c (init_sal): Delete.
7310 (find_pc_sect_line): Remove init_sal references. Move
7311 declarations closer to initializations.
7312 (find_function_start_sal): Remove init_sal references. Move
7313 declarations closer to initializations.
7314 * symtab.h (struct symtab_and_line): In-class initialize all
7315 fields.
7316 * tracepoint.c (set_traceframe_context)
7317 (print_one_static_tracepoint_marker): Remove init_sal references.
7318 Move declarations closer to initializations.
7319 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
7320 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
7321 declarations closer to initializations.
7322 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
7323 init_sal references. Adjust.
7324
7325 2017-09-04 Pedro Alves <palves@redhat.com>
7326
7327 * ax-gdb.c (agent_command_1): Use range-for.
7328 * break-catch-throw.c (re_set_exception_catchpoint): Update.
7329 * breakpoint.c: Include "common/array-view.h".
7330 (init_breakpoint_sal, create_breakpoint_sal): Change sals
7331 parameter from struct symtabs_and_lines to
7332 array_view<symtab_and_line>. Adjust. Use range-for. Update.
7333 (breakpoint_sals_to_pc): Change sals parameter from struct
7334 symtabs_and_lines to std::vector reference.
7335 (check_fast_tracepoint_sals): Change sals parameter from struct
7336 symtabs_and_lines to std::array_view. Use range-for.
7337 (decode_static_tracepoint_spec): Return a std::vector instead of
7338 symtabs_and_lines. Update.
7339 (create_breakpoint): Update.
7340 (break_range_command, until_break_command, clear_command): Update.
7341 (base_breakpoint_decode_location, bkpt_decode_location)
7342 (bkpt_probe_create_sals_from_location)
7343 (bkpt_probe_decode_location, tracepoint_decode_location)
7344 (tracepoint_probe_decode_location)
7345 (strace_marker_create_sals_from_location): Return a std::vector
7346 instead of symtabs_and_lines.
7347 (strace_marker_create_breakpoints_sal): Update.
7348 (strace_marker_decode_location): Return a std::vector instead of
7349 symtabs_and_lines. Update.
7350 (update_breakpoint_locations): Change struct symtabs_and_lines
7351 parameters to gdb::array_view. Adjust.
7352 (location_to_sals): Return a std::vector instead of
7353 symtabs_and_lines. Update.
7354 (breakpoint_re_set_default): Use std::vector instead of struct
7355 symtabs_and_lines.
7356 (decode_location_default): Return a std::vector instead of
7357 symtabs_and_lines. Update.
7358 * breakpoint.h: Include "common/array-view.h".
7359 (struct breakpoint_ops) <decode_location>: Now returns a
7360 std::vector instead of returning a symtabs_and_lines via output
7361 parameter.
7362 (update_breakpoint_locations): Change sals parameters to use
7363 gdb::array_view.
7364 * cli/cli-cmds.c (edit_command, list_command): Update to use
7365 std::vector and gdb::array_view.
7366 (ambiguous_line_spec): Adjust to use gdb::array_view and
7367 range-for.
7368 (compare_symtabs): Rename to ...
7369 (cmp_symtabs): ... this. Change parameters to symtab_and_line
7370 const reference and adjust.
7371 (filter_sals): Rewrite using std::vector and standard algorithms.
7372 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
7373 (jump_command): Update to use std::vector.
7374 * linespec.c (struct linespec_state) <canonical_names>: Update
7375 comment.
7376 (add_sal_to_sals_basic): Delete.
7377 (add_sal_to_sals, filter_results, convert_results_to_lsals)
7378 (decode_line_2, create_sals_line_offset)
7379 (convert_address_location_to_sals, convert_linespec_to_sals)
7380 (convert_explicit_location_to_sals, parse_linespec)
7381 (event_location_to_sals, decode_line_full, decode_line_1)
7382 (decode_line_with_current_source)
7383 (decode_line_with_last_displayed, decode_objc)
7384 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
7385 (linespec_result::~linespec_result): Adjust to use std::vector
7386 instead of symtabs_and_lines.
7387 * linespec.h (linespec_sals::sals): Now a std::vector.
7388 (struct linespec_result): Use std::vector, bool, and in-class
7389 initialization.
7390 (decode_line_1, decode_line_with_current_source)
7391 (decode_line_with_last_displayed): Return std::vector.
7392 * macrocmd.c (info_macros_command): Use std::vector.
7393 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
7394 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
7395 std::vector.
7396 * probe.h (parse_probes): Return a std::vector.
7397 * python/python.c (gdbpy_decode_line): Use std::vector and
7398 gdb::array_view.
7399 * source.c (select_source_symtab, line_info): Use std::vector.
7400 * stack.c (func_command): Use std::vector.
7401 * symtab.h (struct symtabs_and_lines): Delete.
7402 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
7403
7404 2017-09-04 Pedro Alves <palves@redhat.com>
7405
7406 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7407 unittests/array-view-selftests.c.
7408 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
7409 * common/array-view.h: New file.
7410 * unittests/array-view-selftests.c: New file.
7411
7412 2017-09-04 Pedro Alves <palves@redhat.com>
7413
7414 * cli/cli-cmds.c (edit_command): Pass message to
7415 ambiguous_line_spec.
7416 (list_command): Pass message to ambiguous_line_spec. Say
7417 "first"/"last" instead of "start" and "end" to be consistent with
7418 the manual.
7419 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
7420 them to print formatted message.
7421
7422 2017-09-04 Pedro Alves <palves@redhat.com>
7423
7424 * btrace.c (ftrace_add_pt): Pass btrace_insn to
7425 ftrace_update_insns by reference instead of pointer.
7426
7427 2017-09-04 Yao Qi <yao.qi@linaro.org>
7428
7429 * i386-go32-tdep.c: Include x86-xstate.h.
7430 (i386_go32_init_abi): Call i386_target_description.
7431 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
7432 if xcr0 is X86_XSTATE_X87_MASK.
7433 * i386-tdep.h (tdesc_i386): Remove the declaration.
7434 (tdesc_i386_mmx): Likewise.
7435
7436 2017-09-04 Yao Qi <yao.qi@linaro.org>
7437
7438 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
7439 X86_XSTATE_SSE_MASK instead of 0.
7440
7441 2017-09-04 Yao Qi <yao.qi@linaro.org>
7442
7443 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
7444 i386_target_description.
7445 * i386-fbsd-nat.c (i386fbsd_read_description): Call
7446 i386_target_description.
7447 * i386-tdep.c (i386_gdbarch_init): Likewise.
7448
7449 2017-09-04 Yao Qi <yao.qi@linaro.org>
7450
7451 * amd64-darwin-tdep.c: Include "x86-xstate.h".
7452 (x86_darwin_init_abi_64): Call amd64_target_description.
7453 * amd64-dicos-tdep.c: Likewise.
7454 * amd64-fbsd-nat.c: Likewise.
7455 * amd64-fbsd-tdep.c: Likewise.
7456 * amd64-nbsd-tdep.c: Likewise.
7457 * amd64-obsd-tdep.c: Likewise.
7458 * amd64-sol2-tdep.c: Likewise.
7459 * amd64-windows-tdep.c: Likewise.
7460 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
7461
7462 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7463
7464 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
7465 (btrace_function) <insn>: Change type to use std::vector.
7466 * btrace.c (ftrace_debug, ftrace_call_num_insn,
7467 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
7468 ftrace_update_insns, ftrace_compute_global_level_offset,
7469 btrace_stitch_bts, btrace_clear, btrace_insn_get,
7470 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
7471 change to std::vector.
7472 (ftrace_update_insns): Adjust to change to std::vector, change
7473 type of INSN parameter.
7474 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
7475 * record-btrace.c (btrace_call_history_insn_range,
7476 btrace_compute_src_line_range,
7477 record_btrace_frame_prev_register): Adjust to change to
7478 std::vector.
7479 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
7480 to change to std::vector.
7481
7482 2017-09-03 Tom Tromey <tom@tromey.com>
7483
7484 * corefile.c (reopen_exec_file): Use std::string.
7485
7486 2017-09-03 Tom Tromey <tom@tromey.com>
7487
7488 * compile/compile.c (compile_register_name_mangled): Return
7489 std::string.
7490 * compile/compile-loc2c.c (pushf_register_address): Update.
7491 (pushf_register): Update.
7492 * compile/compile-c-types.c (convert_array): Update.
7493 * compile/compile-c-symbols.c (generate_vla_size): Update.
7494 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
7495 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
7496 (convert_one_symbol): Update.
7497 (generate_c_for_for_one_variable): Update.
7498 * compile/compile-c-support.c (c_get_range_decl_name): Return a
7499 std::string.
7500 (generate_register_struct): Update.
7501 * compile/compile-internal.h (c_get_range_decl_name): Return a
7502 std::string.
7503 (compile_register_name_mangled): Return std::string.
7504
7505 2017-09-03 Tom Tromey <tom@tromey.com>
7506
7507 * utils.c (perror_string): Return a std::string.
7508 (throw_perror_with_name, perror_warning_with_name): Update.
7509
7510 2017-09-03 Tom Tromey <tom@tromey.com>
7511
7512 * demangle.c (demangle_command): Use std::string,
7513 unique_xmalloc_ptr.
7514
7515 2017-09-03 Tom Tromey <tom@tromey.com>
7516
7517 * cli/cli-setshow.c (do_set_command): Use std::string.
7518
7519 2017-09-03 Tom Tromey <tom@tromey.com>
7520
7521 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
7522
7523 2017-09-03 Tom Tromey <tom@tromey.com>
7524
7525 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
7526
7527 2017-09-03 Tom Tromey <tom@tromey.com>
7528
7529 * mi/mi-cmd-env.c (env_execute_cli_command): Use
7530 gdb::unique_xmalloc_ptr.
7531
7532 2017-09-03 Tom Tromey <tom@tromey.com>
7533
7534 * thread.c (print_thread_info_1): Use string_printf.
7535 (thread_apply_command, thread_apply_all_command): Use
7536 std::string.
7537
7538 2017-09-03 Tom Tromey <tom@tromey.com>
7539
7540 * valprint.c (val_print_string): Update.
7541 * gdbcore.h (memory_error_message): Return std::string.
7542 * corefile.c (memory_error_message): Return std::string.
7543 (memory_error): Update.
7544 * breakpoint.c (insert_bp_location): Update.
7545
7546 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
7547
7548 * target/waitstatus.h (target_waitstatus_to_string): Change
7549 return type to std::string.
7550 * target/waitstatus.c (target_waitstatus_to_string): Return
7551 std::string.
7552 * target.h (target_waitstatus_to_string): Remove declaration.
7553 * infrun.c (resume, clear_proceed_status_thread,
7554 print_target_wait_results, do_target_wait, save_waitstatus,
7555 stop_all_threads): Adjust.
7556 * record-btrace.c (record_btrace_wait): Adjust.
7557 * target-debug.h
7558 (target_debug_print_struct_target_waitstatus_p): Adjust.
7559
7560 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
7561
7562 PR gdb/22046
7563 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
7564 detection.
7565
7566 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
7567
7568 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
7569 for setting/unsetting environment variables on the remote target.
7570 (New remote packets): Add entries for QEnvironmentHexEncoded,
7571 QEnvironmentUnset and QEnvironmentReset.
7572 * common/environ.c (gdb_environ::operator=): Extend method to
7573 handle m_user_set_env_list and m_user_unset_env_list.
7574 (gdb_environ::clear): Likewise.
7575 (match_var_in_string): Change type of first parameter from 'char
7576 *' to 'const char *'.
7577 (gdb_environ::set): Extend method to handle
7578 m_user_set_env_list and m_user_unset_env_list.
7579 (gdb_environ::unset): Likewise.
7580 (gdb_environ::clear_user_set_env): New method.
7581 (gdb_environ::user_set_envp): Likewise.
7582 (gdb_environ::user_unset_envp): Likewise.
7583 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
7584 m_user_unset_env_list on move constructor/assignment.
7585 (unset): Add new default parameter 'update_unset_list = true'.
7586 (clear_user_set_env): New method.
7587 (user_set_envp): Likewise.
7588 (user_unset_envp): Likewise.
7589 (m_user_set_env_list): New std::set.
7590 (m_user_unset_env_list): Likewise.
7591 * common/rsp-low.c (hex2str): New function.
7592 (bin2hex): New overload for bin2hex function.
7593 * common/rsp-low.c (hex2str): New prototype.
7594 (str2hex): New overload prototype.
7595 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
7596 QEnvironmentUnset and QEnvironmentReset.
7597 (remote_protocol_features): Add QEnvironmentHexEncoded,
7598 QEnvironmentUnset and QEnvironmentReset packets.
7599 (send_environment_packet): New function.
7600 (extended_remote_environment_support): Likewise.
7601 (extended_remote_create_inferior): Call
7602 extended_remote_environment_support.
7603 (_initialize_remote): Add QEnvironmentHexEncoded,
7604 QEnvironmentUnset and QEnvironmentReset packet configs.
7605 * unittests/environ-selftests.c (gdb_selftest_env_var):
7606 New variable.
7607 (test_vector_initialization): New function.
7608 (test_init_from_host_environ): Likewise.
7609 (test_reinit_from_host_environ): Likewise.
7610 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
7611 Likewise.
7612 (test_unset_set_empty_vector): Likewise.
7613 (test_vector_clear): Likewise.
7614 (test_std_move): Likewise.
7615 (test_move_constructor):
7616 (test_self_move): Likewise.
7617 (test_set_unset_reset): Likewise.
7618 (run_tests): Rewrite in terms of the functions above.
7619
7620 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
7621
7622 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
7623 (adi_available): Use a temp variable of type CORE_ADDR as argument
7624 3 when calling target_auxv_search.
7625 (adi_normalize_address): Use masks and xor operators to calculate
7626 normalized address.
7627 (adi_read_versions, adi_write_versions, adi_print_versions)
7628 (do_examine, do_assign): Use paddress.
7629
7630 2017-08-29 John Baldwin <jhb@FreeBSD.org>
7631
7632 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
7633 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
7634 out of loop and add supply of FIR.
7635 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
7636 add collect of FIR.
7637
7638 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
7639
7640 PR gdb/21827
7641 * cli/cli-script.c (define_command): Don't convert command name
7642 to lower case.
7643
7644 2017-08-25 Joel Brobecker <brobecker@adacore.com>
7645
7646 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
7647 Update all callers accordingly. Remove all code blocks handling
7648 the case where DISPP is not NULL.
7649
7650 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7651
7652 PR symtab/22003
7653 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
7654 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
7655 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
7656
7657 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7658
7659 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
7660 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
7661 (read_comp_units_from_section): New parameter abbrev_section, use
7662 read_and_check_comp_unit_head, allocate signatured_type if needed.
7663 (create_all_comp_units): Update read_comp_units_from_section caller.
7664
7665 2017-08-23 Pedro Alves <palves@redhat.com>
7666
7667 PR remote/21852
7668 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
7669 to null_ptid and switch to thread without reading the registers
7670 after adding the inferior.
7671
7672 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
7673
7674 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
7675 compile-gcc.
7676 * compile/compile.c (compile_gcc, show_compile_gcc): New.
7677 (compile_to_object): Implement compile_gcc.
7678 (_initialize_compile): Install "set compile-gcc". Initialize
7679 compile_gcc.
7680
7681 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
7682
7683 * compile/compile.c (compile_to_object): Conditionally call
7684 set_verbose. Conditionally call compile or compile_v0.
7685
7686 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
7687
7688 * sparc64-tdep.h: (adi_normalize_address): New export.
7689 * sparc-nat.h: (open_adi_tag_fd): New export.
7690 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
7691 * sparc64-linux-tdep.c:
7692 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
7693 (sparc64_linux_handle_segmentation_fault): New function.
7694 (sparc64_linux_init_abi): Register
7695 sparc64_linux_handle_segmentation_fault
7696 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
7697 (sparc64_addr_bits_remove): New function.
7698 (sparc64_init_abi): Register sparc64_addr_bits_remove.
7699 (MAX_PROC_NAME_SIZE): New macro.
7700 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
7701 (sparc64adilist): New variable.
7702 (adi_proc_list): New variable.
7703 (find_adi_info): New function.
7704 (add_adi_info): New function.
7705 (get_adi_info_proc): New function.
7706 (get_adi_info): New function.
7707 (info_adi_command): New function.
7708 (read_maps_entry): New function.
7709 (adi_available): New function.
7710 (adi_normalize_address): New function.
7711 (adi_align_address): New function.
7712 (adi_convert_byte_count): New function.
7713 (adi_tag_fd): New function.
7714 (adi_is_addr_mapped): New function.
7715 (adi_read_versions): New function.
7716 (adi_write_versions): New function.
7717 (adi_print_versions): New function.
7718 (do_examine): New function.
7719 (do_assign): New function.
7720 (adi_examine_command): New function.
7721 (adi_assign_command): New function.
7722 (_initialize_sparc64_adi_tdep): New function.
7723
7724 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
7725
7726 * breakpoint.c (breakpoints_info): Rename to ...
7727 (info_breakpoints_command): ... this.
7728 (watchpoints_info): Rename to ...
7729 (info_watchpoints_command): ... this.
7730 (tracepoints_info): Rename to ...
7731 (info_tracepoints_command): ... this.
7732 (_initialize_breakpoint): Adjust.
7733 * dcache.c (dcache_info): Rename to ...
7734 (info_display_command): ... this.
7735 (_initialize_dcache): Adjust.
7736 * frame.h (args_info): Rename to ...
7737 (info_args_command): ... this.
7738 (locals_info): Rename to ...
7739 (info_locals_command): ... this.
7740 * infcmd.c (nofp_registers_info): Rename to ...
7741 (info_registers_command): ... this.
7742 (float_info): Rename to ...
7743 (info_float_command): ... this.
7744 (program_info): Rename to ...
7745 (info_program_command): ... this.
7746 (all_registers_info): Rename to ...
7747 (info_all_registers_command): ... this.
7748 (vector_info): Rename to ...
7749 (info_vector_command): ... this.
7750 (float_info): Rename to ...
7751 (info_float_command): ... this.
7752 (_initialize_infcmd): Adjust.
7753 * inferior.h (term_info): Rename to ...
7754 (info_terminal_command): ... this.
7755 * inflow.c (term_info): Rename to ...
7756 (info_terminal_command): ... this.
7757 (_initialize_inflow): Adjust.
7758 * infrun.c (signals_info): Rename to ...
7759 (info_signals_command): ... this.
7760 (_initialize_infrun): Adjust.
7761 * objc-lang.c (classes_info): Rename to ...
7762 (info_classes_command): ... this.
7763 (selectors_info): Rename to ...
7764 (info_selectors_command): ... this.
7765 (_initialize_objc_language): Adjust.
7766 * printcmd.c (sym_info): Rename to ...
7767 (info_symbol_command): ... this.
7768 (address_info): Rename to ...
7769 (info_address_command): ... this.
7770 (display_info): Rename to ...
7771 (info_display_command): ... this.
7772 (_initialize_printcmd): Adjust.
7773 * reverse.c (bookmarks_info): Rename to ...
7774 (info_breakpoints_command): ... this.
7775 (_initialize_reverse): Adjust.
7776 * ser-go32.c (dos_info): Rename to ...
7777 (info_serial_command): ... this.
7778 (_initialize_ser_dos): Adjust.
7779 * skip.c (skip_info): Rename to ...
7780 (info_skip_command): ... this.
7781 (_initialize_step_skip): Adjust.
7782 * source.c (line_info): Rename to ...
7783 (info_line_command): ... this.
7784 (source_info): Rename to ...
7785 (info_source_command)
7786 * stack.c (frame_info): Rename to ...
7787 (info_frame_command): ... this.
7788 (locals_info): Rename to ...
7789 (info_locals_command): ... this.
7790 (args_info): Rename to ...
7791 (info_args_command): ... this.
7792 (_initialize_stack): Adjust.
7793 * symtab.c (sources_info): Rename to ...
7794 (info_sources_command): ... this.
7795 (variables_info): Rename to ...
7796 (info_variables_command): ... this.
7797 (functions_info): Rename to ...
7798 (info_functions_command): ... this.
7799 (types_info): Rename to ...
7800 (info_types_command): ... this.
7801 (_initialize_symtab): Adjust.
7802 * target.c (target_info): Rename to ...
7803 (info_target_command): ... this.
7804 (initialize_targets): Adjust.
7805 * tracepoint.c (tvariables_info): Rename to ...
7806 (info_tvariables_command): ... this.
7807 (scope_info): Rename to ...
7808 (info_scope_command): ... this.
7809 (trace_dump_actions): Adjust.
7810 (_initialize_tracepoint): Adjust.
7811
7812 2017-08-22 Tom Tromey <tom@tromey.com>
7813
7814 * breakpoint.h (install_breakpoint): Update.
7815 * breakpoint.c (add_solib_catchpoint): Update.
7816 (install_breakpoint): Change argument to a std::unique_ptr.
7817 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
7818 (create_breakpoint_sal, create_breakpoint): Update.
7819 (watch_command_1, catch_exec_command_1)
7820 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
7821 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
7822 Return the breakpoint.
7823 (set_raw_breakpoint_without_location, set_raw_breakpoint)
7824 (new_single_step_breakpoint): Update.
7825 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
7826 std::unique_ptr.
7827 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
7828 std::unique_ptr.
7829 * break-catch-sig.c (create_signal_catchpoint): Use
7830 std::unique_ptr.
7831 * ada-lang.c (create_ada_exception_catchpoint): Use
7832 std::unique_ptr.
7833
7834 2017-08-22 Tom Tromey <tom@tromey.com>
7835
7836 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
7837
7838 2017-08-22 Tom Tromey <tom@tromey.com>
7839
7840 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
7841 (lookup_partial_symbol): Update.
7842
7843 2017-08-22 Tom Tromey <tom@tromey.com>
7844
7845 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
7846 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
7847 (find_and_open_source, symtab_to_fullname): Update.
7848 * psymtab.c (psymtab_to_fullname): Update.
7849
7850 2017-08-22 Tom Tromey <tom@tromey.com>
7851
7852 * exec.c (exec_file_attach): Update.
7853 * linux-thread-db.c (try_thread_db_load): Update.
7854 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
7855 * utils.c (gdb_realpath): Change return type.
7856 (gdb_realpath_keepfile): Update.
7857 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
7858 (_initialize_utils): Register the new self test.
7859 * source.c (openp): Update.
7860 (find_and_open_source): Update.
7861 * nto-tdep.c (nto_find_and_open_solib): Update.
7862 * main.c (set_gdb_data_directory): Update.
7863 (captured_main_1): Update.
7864 * dwarf2read.c (dwarf2_get_dwz_file): Update
7865 (dw2_map_symbol_filenames): Update.
7866 * auto-load.c (auto_load_safe_path_vec_update): Update.
7867 (filename_is_in_auto_load_safe_path_vec): Change type of
7868 "filename_realp".
7869 (auto_load_objfile_script): Update.
7870 (file_is_auto_load_safe): Update. Use std::string.
7871 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
7872
7873 2017-08-22 Tom Tromey <tom@tromey.com>
7874
7875 * utils.c (gdb_realpath_keepfile): Return a
7876 gdb::unique_xmalloc_ptr.
7877 * exec.c (exec_file_attach): Update.
7878 * utils.h (gdb_realpath_keepfile): Return a
7879 gdb::unique_xmalloc_ptr.
7880
7881 2017-08-22 Tom Tromey <tom@tromey.com>
7882
7883 * compile/compile.c (compile_file_command): Use
7884 gdb::unique_xmalloc_ptr, std::string.
7885 * utils.c (gdb_abspath): Change return type.
7886 * source.c (openp): Update.
7887 * objfiles.c (allocate_objfile): Update.
7888 * main.c (set_gdb_data_directory): Update.
7889 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
7890
7891 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
7892
7893 * cli-cmds.c (list_commands): List actual code around more than
7894 one location.
7895
7896 2017-08-21 John Baldwin <jhb@FreeBSD.org>
7897
7898 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
7899
7900 2017-08-21 Pedro Alves <palves@redhat.com>
7901
7902 PR gdb/19487
7903 * c-exp.y (variable production): Handle function aliases.
7904 * minsyms.c (msymbol_is_text): New function.
7905 * minsyms.h (msymbol_is_text): Declare.
7906 * symtab.c (find_function_alias_target): New function.
7907 * symtab.h (find_function_alias_target): Declare.
7908
7909 2017-08-21 Pedro Alves <palves@redhat.com>
7910
7911 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
7912 typedefs.
7913 * typeprint.c (whatis_exp): If handling "whatis", and expression
7914 is OP_TYPE, strip one typedef level. Otherwise don't strip
7915 typedefs here.
7916 * valops.c (value_cast): Save "to" type before resolving
7917 stubs/typedefs. Use that type as resulting value's type.
7918
7919 2017-08-18 Tom Tromey <tom@tromey.com>
7920 Pedro Alves <palves@redhat.com>
7921
7922 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
7923 * sol-thread.c (sol_thread_resume, sol_thread_wait)
7924 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
7925 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
7926 * proc-service.c (ps_xfer_memory): Use scoped_restore.
7927 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
7928 (linux_get_siginfo_data): Add "thread" argument. Use
7929 scoped_restore.
7930 * linux-nat.c (linux_child_follow_fork)
7931 (check_stopped_by_watchpoint): Use scoped_restore.
7932 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
7933 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
7934 (restore_inferior_ptid, save_inferior_ptid): Remove.
7935 * btrace.c (btrace_fetch): Use scoped_restore.
7936 * bsd-uthread.c (bsd_uthread_fetch_registers)
7937 (bsd_uthread_store_registers): Use scoped_restore.
7938 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
7939 scoped_restore.
7940 * aix-thread.c (aix_thread_resume, aix_thread_wait)
7941 (aix_thread_xfer_partial): Use scoped_restore.
7942 * inferior.h (save_inferior_ptid): Remove.
7943
7944 2017-08-18 Yao Qi <yao.qi@linaro.org>
7945
7946 PR tdep/21818
7947 * arm-tdep.c (gdb_print_insn_arm): Mark
7948 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
7949
7950 2017-08-18 Yao Qi <yao.qi@linaro.org>
7951
7952 * NEWS: Mention GDBserver's new option "--selftest".
7953 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
7954 * selftest.c: Move it to common/selftest.c.
7955 * selftest.h: Move it to common/selftest.h.
7956 * selftest-arch.c (reset): New function.
7957 (tests_with_arch): Call reset.
7958
7959 2017-08-18 Yao Qi <yao.qi@linaro.org>
7960
7961 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
7962 instead of exception_fprintf and printf_filtered.
7963
7964 2017-08-18 Yao Qi <yao.qi@linaro.org>
7965
7966 * selftest.c (register_self_test): Rename it to
7967 selftests::register_test.
7968 (run_self_tests): selftest::run_tests.
7969 * selftest.h: Update declarations.
7970 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
7971 selftests::register_test_foreach_arch.
7972 * selftest-arch.h: Update declaration.
7973 * aarch64-tdep.c: Update.
7974 * arm-tdep.c: Likewise.
7975 * disasm-selftests.c: Likewise.
7976 * dwarf2loc.c: Likewise.
7977 * dwarf2-frame.c: Likewise.
7978 * findvar.c: Likewise.
7979 * gdbarch-selftests.c: Likewise.
7980 * maint.c (maintenance_selftest): Likewise.
7981 * regcache.c: Likewise.
7982 * rust-exp.y: Likewise.
7983 * selftest-arch.c: Likewise.
7984 * unittests/environ-selftests.c: Likewise.
7985 * unittests/function-view-selftests.c: Likewise.
7986 * unittests/offset-type-selftests.c: Likewise.
7987 * unittests/optional-selftests.c: Likewise.
7988 * unittests/scoped_restore-selftests.c: Likewise.
7989 * utils-selftests.c: Likewise.
7990
7991 2017-08-17 Pedro Alves <palves@redhat.com>
7992
7993 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
7994 local.
7995
7996 2017-08-17 Pedro Alves <palves@redhat.com>
7997
7998 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
7999 field.
8000 (reset_die_in_process): Delete, replaced by ...
8001 (process_die_scope): ... this new class. Make it responsible for
8002 freeing cu->line_header too.
8003 (process_die): Use process_die_scope.
8004 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
8005 cu->line_header_die_owner. Don't release the line header if it's
8006 owned by the CU.
8007 (setup_type_unit_groups): Make the CU/DIE own the line header.
8008 Don't release the line header here.
8009
8010 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
8011
8012 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
8013
8014 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
8015
8016 * NEWS: Mention new shortcuts for nexti and stepi in TUI
8017 Single-Key mode
8018
8019 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
8020
8021 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
8022 mode command list.
8023
8024 2017-08-15 Stafford Horne <shorne@gmail.com>
8025
8026 * MAINTAINERS (Write After Approval): Add Stafford Horne.
8027
8028 2017-08-15 Stafford Horne <shorne@gmail.com>
8029
8030 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
8031
8032 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
8033
8034 PR gdb/21954
8035 * infcmd.c (unset_environment_command): Use the 'clear' method on
8036 the environment instead of resetting it.
8037
8038 2017-08-15 John Baldwin <jhb@FreeBSD.org>
8039
8040 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
8041 platforms.
8042
8043 2017-08-14 Tom Tromey <tom@tromey.com>
8044
8045 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
8046 (print_binary_chars): Likewise.
8047 (BITS_IN_BYTES): Remove.
8048
8049 2017-08-14 Tom Tromey <tom@tromey.com>
8050
8051 PR gdb/21675
8052 * valprint.c (LOW_ZERO): Change value to 034.
8053 (print_octal_chars): Add static_asserts for octal constants.
8054 * printcmd.c (print_scalar_formatted): Add 'd' case.
8055
8056 2017-08-11 Tom Tromey <tom@tromey.com>
8057
8058 * symfile.c (add_symbol_file_command): Use std::vector.
8059
8060 2017-08-14 Tom Tromey <tom@tromey.com>
8061
8062 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
8063 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
8064 std::move.
8065 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
8066
8067 2017-08-11 Pedro Alves <palves@redhat.com>
8068
8069 * infrun.c (process_event_stop_test): Adjust
8070 function_name_is_marked_for_skip call.
8071 * skip.c: Include <list>.
8072 (skiplist_entry): Make it a class with private fields, and
8073 getters/setters.
8074 (skiplist_entry_chain): Delete.
8075 (skiplist_entries): New.
8076 (skiplist_entry_count): Delete.
8077 (highest_skiplist_entry_num): New.
8078 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
8079 (add_skiplist_entry): Delete.
8080 (skiplist_entry::skiplist_entry): New.
8081 (skiplist_entry::add_entry): New.
8082 (skip_file_command, skip_function): Adjust.
8083 (compile_skip_regexp): Delete.
8084 (skip_command): Don't compile regexp here. Adjust to use
8085 skiplist_entry::add_entry.
8086 (skip_info): Adjust to use range-for and getters.
8087 (skip_enable_command, skip_disable_command): Adjust to use
8088 range-for and setters.
8089 (skip_delete_command): Adjust to use std::list.
8090 (add_skiplist_entry): Delete.
8091 (skip_file_p): Delete, refactored as ...
8092 (skiplist_entry::do_skip_file_p): ... this new method.
8093 (skip_gfile_p): Delete, refactored as ...
8094 (skiplist_entry::do_gskip_file_p): ... this new method.
8095 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
8096 (skiplist_entry::skip_function_p): ... this new method.
8097 (function_name_is_marked_for_skip): Now returns bool, and takes
8098 the function sal by const reference. Adjust to use range-for and
8099 skiplist_entry methods.
8100 (_initialize_step_skip): Remove references to
8101 skiplist_entry_chain, skiplist_entry_count.
8102 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
8103 takes the function sal by const reference.
8104
8105 2017-08-11 Yao Qi <yao.qi@linaro.org>
8106
8107 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
8108 (dwarf2_frame_cache): Remove reset_cache_cleanup.
8109 (dwarf2_frame_cache):
8110 * frame-unwind.c (frame_unwind_try_unwinder): Catch
8111 RETURN_MASK_ALL and set *this_case to NULL.
8112 * frame-unwind.h: Update comments.
8113
8114 2017-08-11 Yao Qi <yao.qi@linaro.org>
8115
8116 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
8117 (dwarf2_frame_state_copy_regs): Remove.
8118 (dwarf2_frame_state_free_regs): Remove.
8119 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
8120 (dwarf2_restore_rule): Call method .alloc_regs instead of
8121 dwarf2_frame_state_alloc_regs.
8122 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
8123 constructor. Call std::move.
8124 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
8125 (dwarf2_frame_cache): Likewise.
8126
8127 [GDB_SELF_TEST]: Include selftest.h and
8128 selftest-arch.h.
8129 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
8130 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
8131 execute_cfa_program_test.
8132
8133 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
8134 copy ctor, assignment operator, move assignment.
8135 <alloc_regs>: New method.
8136 <swap>: New method.
8137 (struct dwarf2_frame_state): Delete dtor.
8138 (dwarf2_frame_state_alloc_regs): Remove declaration.
8139 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
8140 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
8141
8142 2017-08-11 Yao Qi <yao.qi@linaro.org>
8143
8144 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
8145 (dwarf2_frame_state::dwarf2_frame_state): New.
8146 (dwarf2_frame_state::~dwarf2_frame_state): New.
8147 (dwarf2_fetch_cfa_info): Update.
8148 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
8149 rather than a pointer. Update code.
8150 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
8151 dtor.
8152 <data_align, code_align, retaddr_column>: Change them to const.
8153 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
8154 to bool.
8155
8156 2017-08-11 Yao Qi <yao.qi@linaro.org>
8157
8158 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
8159 <loc.exp>: New field.
8160 * dwarf2-frame.c (execute_cfa_program): Update.
8161 (dwarf2_frame_prev_register): Update.
8162
8163 2017-08-10 Pedro Alves <palves@redhat.com>
8164
8165 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
8166
8167 2017-08-09 John Baldwin <jhb@FreeBSD.org>
8168
8169 * fbsd-nat.c (struct fbsd_fork_info): Remove.
8170 (fbsd_pending_children): Use std::list.
8171 (fbsd_remember_child): Likewise.
8172 (fbsd_is_child_pending): Likewise.
8173 (fbsd_pending_vfork_done): Use std::forward_list.
8174 (fbsd_add_vfork_done): Likewise.
8175 (fbsd_is_vfork_done_pending): Likewise.
8176 (fbsd_next_vfork_done): Likewise.
8177
8178 2017-08-09 John Baldwin <jhb@FreeBSD.org>
8179
8180 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
8181 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
8182 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
8183 for `mapfilename'.
8184 (fbsd_xfer_partial): Use gdb::byte_vector.
8185 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
8186
8187 2017-08-09 John Baldwin <jhb@FreeBSD.org>
8188
8189 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
8190 "filestuff.h".
8191 (fbsd_find_memory_regions): Fix `mapfile' initialization.
8192
8193 2017-08-09 Tom Tromey <tom@tromey.com>
8194
8195 * skip.c (skiplist_entry): New constructor.
8196 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
8197 (skiplist_entry::file_is_glob): Now bool.
8198 (skiplist_entry::file, skiplist_entry::function): Now
8199 std::string.
8200 (make_skip_entry): Return a unique_ptr. Use new.
8201 (free_skiplist_entry, free_skiplist_entry_cleanup)
8202 (make_free_skiplist_entry_cleanup): Remove.
8203 (skip_command, skip_disable_command, add_skiplist_entry)
8204 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
8205 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
8206 (function_name_is_marked_for_skip): Update.
8207 (skip_delete_command): Update. Use delete.
8208
8209 2017-08-09 Jiong Wang <jiong.wang@arm.com>
8210
8211 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
8212 (aarch64_linux_core_read_description): New function.
8213 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
8214
8215 2017-08-09 Pedro Alves <palves@redhat.com>
8216
8217 * cp-name-parser.y (cp_comp_to_string): Return a
8218 gdb::unique_xmalloc_ptr<char>.
8219 * cp-support.c (replace_typedefs_qualified_name)
8220 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
8221 (cp_canonicalize_string_full): Use op= instead of explicit
8222 convertion.
8223 (cp_class_name_from_physname, method_name_from_physname)
8224 (cp_func_name, cp_remove_params): Adjust to use
8225 gdb::unique_xmalloc_ptr<char>.
8226 * cp-support.h (cp_comp_to_string): Return a
8227 gdb::unique_xmalloc_ptr<char>.
8228 * python/py-type.c (typy_lookup_type): Adjust to use
8229 gdb::unique_xmalloc_ptr<char>.
8230
8231 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
8232
8233 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
8234
8235 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
8236 Yao Qi <yao.qi@linaro.org>
8237
8238 * cp-support.c (cp_canonicalize_string_full): Use
8239 gdb::unique_xmalloc_ptr<char>.
8240 (cp_canonicalize_string): Likewise.
8241
8242 2017-08-09 Yao Qi <yao.qi@linaro.org>
8243
8244 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
8245 * regformats/i386/amd64-avx-avx512.dat: Remove.
8246 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
8247 * regformats/i386/amd64-avx-mpx.dat:Remove.
8248 * regformats/i386/amd64-avx.dat: Remove.
8249 * regformats/i386/amd64-mpx.dat: Remove.
8250 * regformats/i386/i386-avx-avx512.dat: Remove.
8251 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
8252 * regformats/i386/i386-avx-mpx.dat: Remove.
8253 * regformats/i386/i386-mmx.dat: Remove.
8254 * regformats/i386/i386-mpx.dat: Remove.
8255
8256 2017-08-09 Yao Qi <yao.qi@linaro.org>
8257
8258 * amd64-tdep.h (tdesc_x32): Remove the declaration.
8259 * amd64-tdep.c: Don't include features/i386/x32*.c.
8260 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
8261 functions.
8262 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
8263 and i386/x32-avx-avx512.
8264 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
8265 and i386/x32.xml.
8266 * features/i386/x32-avx-avx512.c: Removed.
8267 * features/i386/x32-avx-avx512.xml: Removed.
8268 * features/i386/x32-avx.c: Removed.
8269 * features/i386/x32-avx.xml: Removed.
8270 * features/i386/x32.c: Removed.
8271 * features/i386/x32.xml: Removed.
8272 * regformats/i386/x32-avx-avx512.dat: Removed.
8273 * regformats/i386/x32-avx.dat: Removed.
8274 * regformats/i386/x32.dat: Removed.
8275
8276 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8277
8278 PR breakpoints/21886
8279 * mem-break.c (default_memory_insert_breakpoint): Use
8280 `->placed_address' rather than `->reqstd_address' for the
8281 breakpoint location.
8282
8283 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8284
8285 * arch-utils.c (default_print_insn): Remove arch/mach/endian
8286 assertions.
8287
8288 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8289
8290 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
8291 a union of `tdep_info', `tdesc_data' and `id'.
8292 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
8293 rather than `info.tdep_info'.
8294 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
8295 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
8296 * i386-tdep.c (i386_gdbarch_init): Likewise.
8297 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
8298 * mips-tdep.c (mips_gdbarch_init): Likewise.
8299 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8300 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
8301 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
8302 `info.tdep_info'.
8303 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
8304 `info.tdep_info'.
8305 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8306 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
8307 `info.tdep_info'.
8308 * spu-tdep.c (spu_gdbarch_init): Likewise.
8309 * gdbarch.h: Regenerate.
8310
8311 2017-08-07 Leszek Swirski <leszeks@google.com>
8312
8313 PR symtab/20899
8314 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
8315
8316 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
8317
8318 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
8319 (gdbsim_open): Rename gdb_argv args object to argv.
8320
8321 2017-08-05 Tom Tromey <tom@tromey.com>
8322
8323 * compile/compile-object-load.c (compile_object_load): Use
8324 gdb::unique_xmalloc_ptr.
8325 * cli/cli-dump.c (scan_filename): Rename from
8326 scan_filename_with_cleanup. Change return type.
8327 (scan_expression): Rename from scan_expression_with_cleanup.
8328 Change return type.
8329 (dump_memory_to_file, dump_value_to_file, restore_command):
8330 Use gdb::unique_xmalloc_ptr. Update.
8331 * cli/cli-cmds.c (find_and_open_script): Use
8332 gdb::unique_xmalloc_ptr.
8333 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
8334 * symmisc.c (maintenance_print_symbols)
8335 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
8336 * symfile.c (symfile_bfd_open, generic_load)
8337 (add_symbol_file_command, remove_symbol_file_command): Use
8338 gdb::unique_xmalloc_ptr.
8339 * source.c (openp): Use gdb::unique_xmalloc_ptr.
8340 * psymtab.c (maintenance_print_psymbols): Use
8341 gdb::unique_xmalloc_ptr.
8342 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
8343 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
8344 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
8345 (reload_shared_libraries_1): Likewise.
8346
8347 2017-08-05 Tom Tromey <tom@tromey.com>
8348
8349 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
8350 (rust_op_vector, rust_set_vector): New typedefs.
8351 (current_parser): New global.
8352 (work_obstack): Change to pointer type. Update all users.
8353 (rust_ast, pstate): Remove globals.
8354 (struct rust_parser): New.
8355 (%union) <params, field_inits>: Change type.
8356 (start, tuple_expr, unit_expr, struct_expr_list, literal)
8357 (field_expr, expr_list, maybe_expr_list, type_list): Update.
8358 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
8359 (convert_params_to_types, convert_params_to_expression): Change
8360 type of "params".
8361 (ast_string): Change type of "fields".
8362 (rust_parse): Make a rust_parser. Remove cleanups.
8363 (rust_lex_tests): Make and install an auto_obstack.
8364
8365 2017-08-04 Yao Qi <yao.qi@linaro.org>
8366
8367 * configure.srv (ipa_x32_linux_regobj): New.
8368 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
8369 instead of X86_TDESC_AVX512.
8370 (initialize_low_tracepoint): Call
8371 init_registers_x32_avx_avx512_linux.
8372
8373 2017-08-04 Yao Qi <yao.qi@linaro.org>
8374
8375 * utils.h (gdb_argv): Add namespace std for nullptr_t.
8376
8377 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
8378
8379 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
8380
8381 2017-08-03 Tom Tromey <tom@tromey.com>
8382
8383 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
8384 Remove.
8385 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
8386
8387 2017-08-03 Tom Tromey <tom@tromey.com>
8388
8389 * python/py-param.c (compute_enum_values): Use gdb_argv.
8390
8391 2017-08-03 Tom Tromey <tom@tromey.com>
8392
8393 * utils.h (struct gdb_argv_deleter): New.
8394 (gdb_argv): New class.
8395 * utils.c (gdb_argv::reset): New method.
8396 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
8397 * tracefile.c (tsave_command): Use gdb_argv.
8398 * top.c (new_ui_command): Use gdb_argv.
8399 * symmisc.c (maintenance_print_symbols)
8400 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
8401 * symfile.c (symbol_file_command, generic_load)
8402 (remove_symbol_file_command): Use gdb_argv.
8403 * stack.c (backtrace_command): Use gdb_argv.
8404 * source.c (add_path, show_substitute_path_command)
8405 (unset_substitute_path_command, set_substitute_path_command):
8406 Use gdb_argv.
8407 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
8408 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
8409 * remote.c (extended_remote_run, remote_put_command)
8410 (remote_get_command, remote_delete_command): Use gdb_argv.
8411 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
8412 (gdbsim_open): Use gdb_argv.
8413 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
8414 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
8415 * procfs.c (procfs_info_proc): Use gdb_argv.
8416 * interps.c (interpreter_exec_cmd): Use gdb_argv.
8417 * infrun.c (handle_command): Use gdb_argv.
8418 * inferior.c (add_inferior_command, clone_inferior_command):
8419 Use gdb_argv.
8420 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
8421 * exec.c (exec_file_command): Use gdb_argv.
8422 * cli/cli-cmds.c (alias_command): Use gdb_argv.
8423 * compile/compile.c (build_argc_argv): Use gdb_argv.
8424
8425 2017-08-03 Tom Tromey <tom@tromey.com>
8426
8427 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
8428
8429 2017-08-03 Tom Tromey <tom@tromey.com>
8430
8431 * python/python.c (compute_python_string): Return std::string.
8432 (gdbpy_eval_from_control_command): Update.
8433 (do_start_initialization): Use std::string.
8434 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
8435 xstrprintf.
8436 * python/py-breakpoint.c (local_setattro): Use string_printf, not
8437 xstrprintf.
8438
8439 2017-08-03 Tom Tromey <tom@tromey.com>
8440
8441 * top.h (do_restore_instream_cleanup): Remove.
8442 * top.c (do_restore_instream_cleanup): Remove.
8443 (read_command_file): Use scoped_restore.
8444 * cli/cli-script.c (execute_user_command): Use scoped_restore.
8445
8446 2017-08-03 Tom Tromey <tom@tromey.com>
8447
8448 * cli/cli-script.c (execute_user_command)
8449 (execute_control_command): Use scoped_restore.
8450
8451 2017-08-03 Tom Tromey <tom@tromey.com>
8452
8453 * cli/cli-script.c (do_restore_user_call_depth): Remove.
8454 (execute_user_command): Remove user_call_depth; use
8455 user_args_stack's size instead.
8456
8457 2017-08-03 Tom Tromey <tom@tromey.com>
8458
8459 * top.h (in_user_command): Remove.
8460 * top.c (in_user_command): Remove.
8461 * cli/cli-script.c (do_restore_user_call_depth)
8462 (execute_user_command): Update.
8463
8464 2017-08-03 Tom Tromey <tom@tromey.com>
8465
8466 * valops.c (search_struct_method): Use gdb::byte_vector.
8467 * valarith.c (value_concat): Use std::vector.
8468 * target.c (memory_xfer_partial): Use gdb::byte_vector.
8469 (simple_search_memory): Likewise.
8470 * printcmd.c (find_string_backward): Use gdb::byte_vector.
8471 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
8472 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
8473 * elfread.c (elf_rel_plt_read): Use std::string.
8474 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
8475 * cli/cli-dump.c (restore_section_callback): Use
8476 gdb::byte_vector.
8477
8478 2017-08-03 Tom Tromey <tom@tromey.com>
8479
8480 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
8481
8482 2017-08-03 Tom Tromey <tom@tromey.com>
8483
8484 * tui/tui-regs.c (tui_restore_gdbout): Remove.
8485 (tui_register_format): Use scoped_restore.
8486
8487 2017-08-03 Tom Tromey <tom@tromey.com>
8488
8489 * reverse.c (exec_direction_default): Remove.
8490 (exec_reverse_once): Use scoped_restore.
8491 * remote.c (restore_remote_timeout): Remove.
8492 (remote_flash_erase, remote_flash_write, remote_flash_done)
8493 (readchar, remote_serial_write): Use scoped_restore.
8494 * cli/cli-script.c (struct source_cleanup_lines_args)
8495 (source_cleanup_lines): Remove.
8496 (script_from_file): Use scoped_restore.
8497 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
8498 (source_command): Use scoped_restore.
8499
8500 2017-08-03 Tom Tromey <tom@tromey.com>
8501
8502 * utils.h (make_cleanup_free_so): Remove.
8503 * utils.c (do_free_so, make_cleanup_free_so): Remove.
8504 * solist.h (struct so_deleter): New.
8505 (so_list_up): New typedef.
8506 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
8507
8508 2017-08-03 Tom Tromey <tom@tromey.com>
8509
8510 * utils.h (make_cleanup_restore_current_language): Remove.
8511 * utils.c (do_restore_current_language)
8512 (make_cleanup_restore_current_language): Remove.
8513 * parse.c (parse_exp_in_context_1)
8514 (parse_expression_with_language): Use
8515 scoped_restore_current_language.
8516 * mi/mi-main.c (mi_cmd_execute): Use
8517 scoped_restore_current_language.
8518 * language.h (scoped_restore_current_language): New class.
8519
8520 2017-08-03 Tom Tromey <tom@tromey.com>
8521
8522 * compile/compile.c (cleanup_unlink_file): Remove.
8523 (compile_to_object): Use gdb::unlinker.
8524 (eval_compile_command): Likewise.
8525
8526 2017-08-03 Tom Tromey <tom@tromey.com>
8527
8528 * utils.h (make_cleanup_fclose): Remove.
8529 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
8530
8531 2017-08-03 Tom Tromey <tom@tromey.com>
8532
8533 * top.c (open_terminal_stream): Return gdb_file_up.
8534 (new_ui_command): Update.
8535
8536 2017-08-03 Tom Tromey <tom@tromey.com>
8537
8538 * source.c (print_source_lines_base, forward_search_command)
8539 (reverse_search_command): Use gdb_file_up.
8540
8541 2017-08-03 Tom Tromey <tom@tromey.com>
8542
8543 * fbsd-nat.c (fbsd_find_memory_regions): Update.
8544
8545 2017-08-03 Tom Tromey <tom@tromey.com>
8546
8547 * cli/cli-cmds.c (find_and_open_script): Change return type.
8548 Remove "streamp" and "full_path" parameters.
8549 (source_script_with_search): Update.
8550 * auto-load.c (source_script_file): Update.
8551 * cli/cli-cmds.h (find_and_open_script): Change type.
8552 (open_script): New struct.
8553
8554 2017-08-03 Tom Tromey <tom@tromey.com>
8555
8556 * xml-support.c (xml_fetch_content_from_file): Update.
8557 * ui-file.c (stdio_file::open): Update.
8558 * tracefile-tfile.c (tfile_start): Update.
8559 * remote.c (remote_file_put, remote_file_get): Update.
8560 * nat/linux-procfs.c (linux_proc_get_int)
8561 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
8562 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
8563 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
8564 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
8565 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
8566 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
8567 * linux-nat.c (linux_proc_pending_signals): Update.
8568 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
8569 (file_closer): Remove.
8570 * compile/compile.c (compile_to_object): Update.
8571 * common/filestuff.h (struct gdb_file_deleter): New.
8572 (gdb_file_up): New typedef.
8573 (gdb_fopen_cloexec): Change return type.
8574 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
8575 * cli/cli-dump.c (fopen_with_cleanup): Remove.
8576 (dump_binary_file, restore_binary_file): Update.
8577 * auto-load.c (auto_load_objfile_script_1): Update.
8578
8579 2017-08-03 Tom Tromey <tom@tromey.com>
8580
8581 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
8582 (info_static_tracepoint_markers_command): Likewise.
8583 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
8584 * skip.c (skip_info): Use ui_out_emit_table.
8585 * progspace.c (print_program_space): Use ui_out_emit_table.
8586 * osdata.c (info_osdata): Use ui_out_emit_table.
8587 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
8588 ui_out_emit_table.
8589 * linux-thread-db.c (info_auto_load_libthread_db): Use
8590 ui_out_emit_table.
8591 * inferior.c (print_inferior): Use ui_out_emit_table.
8592 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
8593 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
8594 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
8595 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
8596 * ui-out.h (class ui_out_emit_table): New.
8597
8598 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
8599
8600 * mips-tdep.c (mips_fpu_type_str): New function.
8601 (mips_dump_tdep): Call it.
8602
8603 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
8604
8605 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
8606 `->mips_fpu_type'.
8607
8608 2017-07-31 Xavier Roirand <roirand@adacore.com>
8609
8610 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
8611
8612 2017-07-27 Xavier Roirand <roirand@adacore.com>
8613
8614 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
8615
8616 2017-07-26 Yao Qi <yao.qi@linaro.org>
8617
8618 * cli/cli-cmds.c (maintenancechecklist): New variable.
8619 * gdbcmd.h (maintenancechecklist): Declare it.
8620 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
8621 Call i386_linux_read_description with different masks.
8622 * maint.c (maintenance_check_command): New function.
8623 (_initialize_maint_cmds): Call add_prefix_cmd.
8624 * target-descriptions.c (tdesc_reg): override operator != and ==.
8625 (tdesc_type): Likewise.
8626 (tdesc_feature): Likewise.
8627 (target_desc): Likewise.
8628 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
8629 (maintenance_check_xml_descriptions): New function.
8630 (_initialize_target_descriptions) Add command "xml-descriptions".
8631 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
8632
8633 2017-07-26 Yao Qi <yao.qi@linaro.org>
8634
8635 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
8636 Include features/i386/32bit-*.c.
8637 (i386_linux_read_description): Generate target description if it
8638 doesn't exist.
8639 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
8640 functions.
8641 * features/i386/32bit-linux.c: Re-generated.
8642 * features/i386/32bit-sse.c: Likewise.
8643 * target-descriptions.c (print_c_feature::visit): Print code to
8644 set register number if needed.
8645 (print_c_feature) <m_next_regnum>: New field.
8646
8647 2017-07-26 Yao Qi <yao.qi@linaro.org>
8648
8649 * features/Makefile (CFILES): Rename with TDESC_CFILES.
8650 (FEATURE_XMLFILES): New.
8651 (FEATURE_CFILES): New.
8652 New rules.
8653 (clean-cfiles): Remove generated c files.
8654 * features/i386/32bit-avx.c: Generated.
8655 * features/i386/32bit-avx512.c: Generated.
8656 * features/i386/32bit-core.c: Generated.
8657 * features/i386/32bit-linux.c: Generated.
8658 * features/i386/32bit-mpx.c: Generated.
8659 * features/i386/32bit-pkeys.c: Generated.
8660 * features/i386/32bit-sse.c: Generated.
8661 * target-descriptions.c: Include algorithm.
8662 (tdesc_element_visitor): Add method visit_end.
8663 (print_c_tdesc): Implement visit_end.
8664 (print_c_tdesc:: m_filename_after_features): Move it to
8665 protected.
8666 (print_c_feature): New class.
8667 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
8668 name starts with "i386/32bit-".
8669
8670 2017-07-26 Yao Qi <yao.qi@linaro.org>
8671
8672 * target-descriptions.c (tdesc_element_visitor): New class.
8673 (tdesc_element): New class.
8674 (tdesc_reg): Inherit from tdesc_element.
8675 (tdesc_reg::accept): New function.
8676 (tdesc_type): Inherit from tdesc_element.
8677 (tdesc_type::accept): New function.
8678 (tdesc_feature): Inherit from tdesc_element.
8679 (tdesc_feature::accept): New function.
8680 (target_desc): Inherit from tdesc_element.
8681 (target_desc::target_desc): New.
8682 (target_desc::~target_desc): New.
8683 (target_desc::accept): New.
8684 (allocate_target_description): Use new.
8685 (free_target_description): Use delete.
8686 (print_c_tdesc): New class.
8687 (maint_print_c_tdesc_cmd): Adjust.
8688
8689 * features/aarch64.c: Re-generated.
8690 * features/arc-arcompact.c: Re-generated.
8691 * features/arc-v2.c: Re-generated.
8692 * features/arm/arm-with-iwmmxt.c: Re-generated.
8693 * features/arm/arm-with-m.c: Re-generated.
8694 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
8695 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
8696 * features/arm/arm-with-neon.c: Re-generated.
8697 * features/arm/arm-with-vfpv2.c: Re-generated.
8698 * features/arm/arm-with-vfpv3.c: Re-generated.
8699 * features/i386/amd64-avx-avx512.c: Re-generated.
8700 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
8701 * features/i386/amd64-avx.c: Re-generated.
8702 * features/i386/amd64-avx-linux.c: Re-generated.
8703 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
8704 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
8705 * features/i386/amd64-avx-mpx.c: Re-generated.
8706 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
8707 * features/i386/amd64.c: Re-generated.
8708 * features/i386/amd64-linux.c: Re-generated.
8709 * features/i386/amd64-mpx.c: Re-generated.
8710 * features/i386/amd64-mpx-linux.c: Re-generated.
8711 * features/i386/i386-avx-avx512.c: Re-generated.
8712 * features/i386/i386-avx-avx512-linux.c: Re-generated.
8713 * features/i386/i386-avx.c: Re-generated.
8714 * features/i386/i386-avx-linux.c: Re-generated.
8715 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
8716 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
8717 * features/i386/i386-avx-mpx.c: Re-generated.
8718 * features/i386/i386-avx-mpx-linux.c: Re-generated.
8719 * features/i386/i386.c: Re-generated.
8720 * features/i386/i386-linux.c: Re-generated.
8721 * features/i386/i386-mmx.c: Re-generated.
8722 * features/i386/i386-mmx-linux.c: Re-generated.
8723 * features/i386/i386-mpx.c: Re-generated.
8724 * features/i386/i386-mpx-linux.c: Re-generated.
8725 * features/i386/x32-avx-avx512.c: Re-generated.
8726 * features/i386/x32-avx-avx512-linux.c: Re-generated.
8727 * features/i386/x32-avx.c: Re-generated.
8728 * features/i386/x32-avx-linux.c: Re-generated.
8729 * features/i386/x32.c: Re-generated.
8730 * features/i386/x32-linux.c: Re-generated.
8731 * features/microblaze.c: Re-generated.
8732 * features/microblaze-with-stack-protect.c: Re-generated.
8733 * features/mips64-dsp-linux.c: Re-generated.
8734 * features/mips64-linux.c: Re-generated.
8735 * features/mips-dsp-linux.c: Re-generated.
8736 * features/mips-linux.c: Re-generated.
8737 * features/nds32.c: Re-generated.
8738 * features/nios2.c: Re-generated.
8739 * features/nios2-linux.c: Re-generated.
8740 * features/rs6000/powerpc-32.c: Re-generated.
8741 * features/rs6000/powerpc-32l.c: Re-generated.
8742 * features/rs6000/powerpc-403.c: Re-generated.
8743 * features/rs6000/powerpc-403gc.c : Re-generated.
8744 * features/rs6000/powerpc-405.c: Re-generated.
8745 * features/rs6000/powerpc-505.c: Re-generated.
8746 * features/rs6000/powerpc-601.c: Re-generated.
8747 * features/rs6000/powerpc-602.c: Re-generated.
8748 * features/rs6000/powerpc-603.c: Re-generated.
8749 * features/rs6000/powerpc-604.c: Re-generated.
8750 * features/rs6000/powerpc-64.c: Re-generated.
8751 * features/rs6000/powerpc-64l.c: Re-generated.
8752 * features/rs6000/powerpc-7400.c: Re-generated.
8753 * features/rs6000/powerpc-750.c: Re-generated.
8754 * features/rs6000/powerpc-860.c: Re-generated.
8755 * features/rs6000/powerpc-altivec32.c: Re-generated.
8756 * features/rs6000/powerpc-altivec32l.c: Re-generated.
8757 * features/rs6000/powerpc-altivec64.c: Re-generated.
8758 * features/rs6000/powerpc-altivec64l.c: Re-generated.
8759 * features/rs6000/powerpc-cell32l.c: Re-generated.
8760 * features/rs6000/powerpc-cell64l.c: Re-generated.
8761 * features/rs6000/powerpc-e500.c: Re-generated.
8762 * features/rs6000/powerpc-e500l.c: Re-generated.
8763 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
8764 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
8765 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
8766 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
8767 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
8768 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
8769 * features/rs6000/powerpc-vsx32.c: Re-generated.
8770 * features/rs6000/powerpc-vsx32l.c: Re-generated.
8771 * features/rs6000/powerpc-vsx64.c: Re-generated.
8772 * features/rs6000/powerpc-vsx64l.c: Re-generated.
8773 * features/rs6000/rs6000.c: Re-generated.
8774 * features/s390-linux32.c: Re-generated.
8775 * features/s390-linux32v1.c: Re-generated.
8776 * features/s390-linux32v2.c: Re-generated.
8777 * features/s390-linux64.c: Re-generated.
8778 * features/s390-linux64v1.c: Re-generated.
8779 * features/s390-linux64v2.c: Re-generated.
8780 * features/s390-te-linux64.c: Re-generated.
8781 * features/s390-tevx-linux64.c: Re-generated.
8782 * features/s390-vx-linux64.c: Re-generated.
8783 * features/s390x-linux64.c: Re-generated.
8784 * features/s390x-linux64v1.c: Re-generated.
8785 * features/s390x-linux64v2.c: Re-generated.
8786 * features/s390x-te-linux64.c: Re-generated.
8787 * features/s390x-tevx-linux64.c: Re-generated.
8788 * features/s390x-vx-linux64.c: Re-generated.
8789 * features/sparc/sparc32-solaris.c: Re-generated.
8790 * features/sparc/sparc64-solaris.c: Re-generated.
8791 * features/tic6x-c62x.c: Re-generated.
8792 * features/tic6x-c62x-linux.c: Re-generated.
8793 * features/tic6x-c64x.c: Re-generated.
8794 * features/tic6x-c64x-linux.c: Re-generated.
8795 * features/tic6x-c64xp.c: Re-generated.
8796 * features/tic6x-c64xp-linux.c: Re-generated.
8797
8798 2017-07-26 Yao Qi <yao.qi@linaro.org>
8799
8800 * i386-linux-tdep.c (i386_linux_read_description): New function.
8801 (i386_linux_core_read_description): Call
8802 i386_linux_read_description.
8803 * i386-linux-tdep.h (i386_linux_read_description): Declare.
8804 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
8805 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
8806 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
8807 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
8808 * x86-linux-nat.c (x86_linux_read_description): Call
8809 i386_linux_read_description.
8810
8811 2017-07-26 Yao Qi <yao.qi@linaro.org>
8812
8813 * NEWS: Mention it.
8814 * features/Makefile (%.c: %.xml): Pass the xml file name to
8815 command "maint print c-tdesc".
8816 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
8817 name from 'arg'.
8818
8819 2017-07-26 Yao Qi <yao.qi@linaro.org>
8820
8821 * target-descriptions.c (target_desc): Add ctor and dtor. Do
8822 in-class initialization.
8823 (tdesc_create_feature): Call new instead of XCNEW.
8824 (free_target_description): Ue delete.
8825
8826 2017-07-25 John Baldwin <jhb@FreeBSD.org>
8827
8828 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
8829
8830 2017-07-25 Yao Qi <yao.qi@linaro.org>
8831
8832 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
8833 constant.
8834 (amd64_x32_init_abi): Likewise.
8835 * amd64-tdep.h (amd64_init_abi): Update declaration.
8836 (amd64_x32_init_abi): Likewise.
8837
8838 2017-07-25 Yao Qi <yao.qi@linaro.org>
8839
8840 PR tdep/21717
8841 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
8842 condition for FPSCR.
8843 (arm_linux_store_inferior_registers): Likewise.
8844
8845 2017-07-22 Tom Tromey <tom@tromey.com>
8846
8847 * break-catch-syscall.c (struct catch_syscall_inferior_data)
8848 <syscalls_counts>: Now a std::vector.
8849 (get_catch_syscall_inferior_data): Use "new".
8850 (catch_syscall_inferior_data_cleanup): Use "delete".
8851 (insert_catch_syscall, remove_catch_syscall)
8852 (clear_syscall_counts): Update.
8853
8854 2017-07-22 Tom Tromey <tom@tromey.com>
8855
8856 * break-catch-syscall.c (syscall_catchpoint)
8857 <syscalls_to_be_caught>: Now a std::vector<int>
8858 (~syscall_catchpoint): Remove.
8859 (insert_catch_syscall, remove_catch_syscall)
8860 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
8861 (print_mention_catch_syscall, print_recreate_catch_syscall):
8862 Update.
8863 (create_syscall_event_catchpoint): Change type of "filter"
8864 parameter.
8865 (catch_syscall_split_args): Return a std::vector.
8866 (catch_syscall_command_1, catching_syscall_number_1): Update.
8867
8868 2017-07-22 Tom Tromey <tom@tromey.com>
8869
8870 * break-catch-throw.c (struct exception_catchpoint)
8871 <exception_rx>: Now a std::string.
8872 (~exception_catchpoint): Remove.
8873 (print_one_detail_exception_catchpoint): Update.
8874 (handle_gnu_v3_exceptions): Change type of except_rx.
8875 (extract_exception_regexp): Return a std::string.
8876 (catch_exception_command_1): Update.
8877
8878 2017-07-22 Tom Tromey <tom@tromey.com>
8879
8880 * break-catch-sig.c (gdb_signal_type): Remove typedef.
8881 (struct signal_catchpoint) <signals_to_be_caught>: Now a
8882 std::vector.
8883 <catch_all>: Now a bool.
8884 (~signal_catchpoint): Remove.
8885 (signal_catchpoint_insert_location)
8886 (signal_catchpoint_remove_location)
8887 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
8888 (signal_catchpoint_print_mention)
8889 (signal_catchpoint_print_recreate)
8890 (signal_catchpoint_explains_signal): Update.
8891 (create_signal_catchpoint): Change type of "filter" and
8892 "catch_all".
8893 (catch_signal_split_args): Return a std::vector. Change type of
8894 "catch_all".
8895 (catch_signal_command): Update.
8896
8897 2017-07-20 Pedro Alves <palves@redhat.com>
8898
8899 * ada-lang.c (ada_language_defn): Make extern.
8900 (_initialize_ada_language): Remove add_language call.
8901 * c-lang.c (c_language_defn, cplus_language_defn)
8902 (asm_language_defn, minimal_language_defn): Make extern.
8903 (_initialize_c_language): Delete.
8904 * completer.c (compare_cstrings): Delete, moved to utils.h.
8905 * d-lang.c (d_language_defn): Make extern.
8906 (_initialize_d_language): Remove add_language calls.
8907 * defs.h (enum language): Add comment.
8908 * f-lang.c (f_language_defn): Make extern.
8909 (_initialize_f_language): Remove add_language call.
8910 * go-lang.c (go_language_defn): Make extern.
8911 (_initialize_go_language): Remove add_language call.
8912 * language.c: Include <algorithm>.
8913 (languages): Redefine as const array.
8914 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
8915 (set_language_command): Handle "local". Use for-range loop.
8916 (set_language): Remove loop.
8917 (language_enum): Rewrite.
8918 (language_def, language_str): Remove loops.
8919 (add_language): Delete.
8920 (add_set_language_command): New, based on add_languages.
8921 (skip_language_trampoline): Adjust.
8922 (local_language_defn): Delete.
8923 (language_gdbarch_post_init): Adjust.
8924 (_initialize_language): Remove add_language calls. Call
8925 add_set_language_command.
8926 * language.h (add_language): Delete.
8927 (auto_language_defn)
8928 (unknown_language_defn, minimal_language_defn, ada_language_defn)
8929 (asm_language_defn, c_language_defn, cplus_language_defn)
8930 (d_language_defn, f_language_defn, go_language_defn)
8931 (m2_language_defn, objc_language_defn, opencl_language_defn)
8932 (pascal_language_defn, rust_language_defn): Declare.
8933 * m2-lang.c (m2_language_defn): Make extern.
8934 (_initialize_m2_language): Remove add_language call.
8935 * objc-lang.c (objc_language_defn): Make extern.
8936 (_initialize_objc_language): Remove add_language call.
8937 * opencl-lang.c (opencl_language_defn): Make extern.
8938 (_initialize_opencl_language): Remove add_language call.
8939 * p-lang.c (pascal_language_defn): Make extern.
8940 (_initialize_pascal_language): Delete.
8941 * rust-lang.c (rust_language_defn): Make extern.
8942 (_initialize_rust_language): Delete.
8943 * utils.h (compare_cstrings): New static inline function.
8944
8945 2017-07-20 Pedro Alves <palves@redhat.com>
8946
8947 * ada-lang.c (ada_to_fixed_type_1): Adjust.
8948 (get_var_value): Constify parameters.
8949 (get_int_var_value): Change prototype.
8950 (to_fixed_range_type): Adjust.
8951 * ada-lang.h (get_int_var_value): Change prototype.
8952
8953 2017-07-20 Pedro Alves <palves@redhat.com>
8954
8955 * dwarf2read.c (dw2_lookup_symbol): Use
8956 SYMBOL_MATCHES_SEARCH_NAME.
8957 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
8958
8959 2017-07-20 Pedro Alves <palves@redhat.com>
8960
8961 * block.c (block_iter_name_step, block_iter_name_first)
8962 (block_iter_name_next): Delete.
8963 (block_lookup_symbol_primary): Adjust to use
8964 dict_iter_match_first/dict_iter_match_next.
8965 * block.h (block_iter_name_first, block_iter_name_next): Delete
8966 declarations.
8967 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
8968 dict_iter_match_first/dict_iter_match_next.
8969
8970 2017-07-20 Pedro Alves <palves@redhat.com>
8971
8972 * cp-support.c (cp_find_first_component_aux): Add missing case for
8973 end of string.
8974
8975 2017-07-18 David Blaikie <dblaikie@gmail.com>
8976
8977 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
8978 of dwo_cu's dwo_file.
8979
8980 2017-07-18 Yao Qi <yao.qi@linaro.org>
8981
8982 * remote.c (store_registers_using_G): Remove one line comment.
8983
8984 2017-07-18 Yao Qi <yao.qi@linaro.org>
8985
8986 * regcache.c (regcache_cpy): Simplify it.
8987 (regcache::cpy_no_passthrough): Remove it.
8988 * regcache.h (cpy_no_passthrough): Remove it.
8989 (regcache_dup, regcache_cpy): Update comments.
8990
8991 2017-07-18 Pedro Alves <palves@redhat.com>
8992
8993 * remote-sim.c (sim_command_completer): Adjust to work with a
8994 completion_tracker instead of a VEC.
8995
8996 2017-07-17 Pedro Alves <palves@redhat.com>
8997
8998 * completer.c (complete_source_filenames): New function.
8999 (complete_address_and_linespec_locations): New function.
9000 (location_completer): Use complete_address_and_linespec_locations.
9001 (completion_tracker::build_completion_result): Honor the tracker's
9002 request to suppress append.
9003 * completer.h (completion_tracker::suppress_append_ws)
9004 (completion_tracker::set_suppress_append_ws): New methods.
9005 (completion_tracker::m_suppress_append_ws): New field.
9006 (complete_source_filenames): New declaration.
9007 * linespec.c (linespec_complete_what): New.
9008 (struct ls_parser) <complete_what, completion_word,
9009 completion_quote_char, completion_quote_end, completion_tracker>:
9010 New fields.
9011 (string_find_incomplete_keyword_at_end): New.
9012 (linespec_lexer_lex_string): Record quote char. If in completion
9013 mode, don't throw.
9014 (linespec_lexer_consume_token): Advance the completion word point.
9015 (linespec_lexer_peek_token): Save/restore completion info.
9016 (save_stream_and_consume_token): New.
9017 (set_completion_after_number): New.
9018 (linespec_parse_basic): Set what to complete next depending on
9019 token. Handle function and label completions specially.
9020 (parse_linespec): Disable objc shortcut in completion mode. Set
9021 what to complete next depending on token type. Skip keyword if in
9022 completion mode.
9023 (complete_linespec_component, linespec_complete): New.
9024 * linespec.h (linespec_complete): Declare.
9025
9026 2017-07-17 Pedro Alves <palves@redhat.com>
9027
9028 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
9029 Handle 'operator<' / 'operator<<'.
9030
9031 2017-07-17 Pedro Alves <palves@redhat.com>
9032
9033 * completer.c (collect_explicit_location_matches): Handle
9034 MATCH_LABEL.
9035 (convert_explicit_location_to_linespec): New, factored out from
9036 ...
9037 (convert_explicit_location_to_sals): ... this.
9038 (complete_label): New.
9039 (linespec_complete_label, find_label_symbols_in_block): New.
9040 (find_label_symbols): Add completion_mode parameter and adjust to
9041 call find_label_symbols_in_block.
9042 * linespec.h (linespec_complete_label): Declare.
9043
9044 2017-07-17 Pedro Alves <palves@redhat.com>
9045
9046 * ada-lang.c (ada_collect_symbol_completion_matches): Add
9047 complete_symbol_mode parameter.
9048 * cli/cli-cmds.c (complete_command): Get the completion result out
9049 of the handle_brkchars tracker if used a custom word point.
9050 * completer.c: Include "linespec.h".
9051 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
9052 (advance_to_expression_complete_word_point): New.
9053 (completion_tracker::completes_to_completion_word): New.
9054 (complete_files_symbols): Pass down
9055 complete_symbol_mode::EXPRESSION.
9056 (explicit_options, probe_options): New.
9057 (collect_explicit_location_matches): Complete on the
9058 explictit_loc->foo instead of word. Use
9059 linespec_complete_function. Handle MATCH_LINE. Handle offering
9060 keyword and options completions.
9061 (backup_text_ptr): Delete.
9062 (skip_keyword): New.
9063 (complete_explicit_location): Remove 'word' parameter. Add
9064 language, quoted_arg_start and quoted_arg_end parameters.
9065 Rewrite, parsing left to right.
9066 (location_completer): Rewrite.
9067 (location_completer_handle_brkchars): New function.
9068 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
9069 (enum complete_line_internal_reason): Adjust comments.
9070 (completion_tracker::discard_completions): New.
9071 (completer_handle_brkchars_func_for_completer): Handle
9072 location_completer.
9073 (gdb_custom_word_point_brkchars)
9074 (gdb_org_rl_basic_quote_characters): New.
9075 (gdb_completion_word_break_characters_throw)
9076 (completion_find_completion_word): Handle trackers that use a
9077 custom word point.
9078 (completion_tracker::advance_custom_word_point_by): New.
9079 (completion_tracker::build_completion_result): Don't rely on
9080 readline appending the quote char.
9081 (gdb_rl_attempted_completion_function_throw): Handle trackers that
9082 use a custom word point.
9083 (gdb_rl_attempted_completion_function): Restore
9084 rl_basic_quote_characters.
9085 * completer.h (class completion_tracker): Extend intro comment.
9086 (completion_tracker::set_quote_char)
9087 (completion_tracker::quote_char)
9088 (completion_tracker::set_use_custom_word_point)
9089 (completion_tracker::use_custom_word_point)
9090 (completion_tracker::custom_word_point)
9091 (completion_tracker::set_custom_word_point)
9092 (completion_tracker::advance_custom_word_point_by)
9093 (completion_tracker::completes_to_completion_word)
9094 (completion_tracker::discard_completions): New methods.
9095 (completion_tracker::m_quote_char)
9096 (completion_tracker::m_use_custom_word_point)
9097 (completion_tracker::m_custom_word_point): New fields.
9098 (advance_to_expression_complete_word_point): Declare.
9099 * f-lang.c (f_collect_symbol_completion_matches): Add
9100 complete_symbol_mode parameter.
9101 * language.h (struct language_defn)
9102 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
9103 parameter.
9104 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
9105 (linespec_complete_function): New function.
9106 (linespec_lexer_lex_keyword): Adjust.
9107 * linespec.h (linespec_keywords, linespec_complete_function): New
9108 declarations.
9109 * location.c (find_end_quote): New function.
9110 (explicit_location_lex_one): Add explicit_completion_info
9111 parameter. Save quoting info. Don't throw if being called for
9112 completion. Don't handle Ada operators here.
9113 (is_cp_operator, skip_op_false_positives, first_of)
9114 (explicit_location_lex_one_function): New function.
9115 (string_to_explicit_location): Replace 'dont_throw' parameter with
9116 an explicit_completion_info pointer parameter. Handle it. Don't
9117 use explicit_location_lex_one to lex function names. Use
9118 explicit_location_lex_one_function instead.
9119 * location.h (struct explicit_completion_info): New.
9120 (string_to_explicit_location): Replace 'dont_throw' parameter with
9121 an explicit_completion_info pointer parameter.
9122 * symtab.c (default_collect_symbol_completion_matches_break_on):
9123 Add complete_symbol_mode parameter. Handle LINESPEC mode.
9124 (default_collect_symbol_completion_matches)
9125 (collect_symbol_completion_matches): Add complete_symbol_mode
9126 parameter.
9127 (collect_symbol_completion_matches_type): Pass down
9128 complete_symbol_mode::EXPRESSION.
9129 (collect_file_symbol_completion_matches): Add complete_symbol_mode
9130 parameter. Handle LINESPEC mode.
9131 * symtab.h (complete_symbol_mode): New.
9132 (default_collect_symbol_completion_matches_break_on)
9133 (default_collect_symbol_completion_matches)
9134 (collect_symbol_completion_matches)
9135 (collect_file_symbol_completion_matches): Add complete_symbol_mode
9136 parameter.
9137
9138 2017-07-17 Pedro Alves <palves@redhat.com>
9139
9140 * utils.c (enum class strncmp_iw_mode): New.
9141 (strcmp_iw): Rename to ...
9142 (strncmp_iw_with_mode): ... this. Add string2_len and mode
9143 parameters. Handle them.
9144 (strncmp_iw): New.
9145 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
9146 * utils.h (strncmp_iw): Declare.
9147 (strcmp_iw): Move describing comments here.
9148
9149 2017-07-17 Pedro Alves <palves@redhat.com>
9150
9151 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
9152 CP_OPERATOR_STR.
9153 * c-typeprint.c (is_type_conversion_operator): Use
9154 CP_OPERATOR_STR.
9155 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
9156 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
9157 CP_OPERATOR_LEN.
9158 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
9159 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
9160 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
9161 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
9162 CP_OPERATOR_STR.
9163 * location.c: Include "cp-support.h".
9164 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
9165 CP_OPERATOR_STR.
9166 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
9167 CP_OPERATOR_LEN.
9168
9169 2017-07-17 Pedro Alves <palves@redhat.com>
9170
9171 * cli/cli-cmds.c (complete_command): Use a completion tracker
9172 along with completion_find_completion_word for handle_brkchars
9173 phase.
9174 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
9175 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
9176 (struct gdb_rl_completion_word_info): New.
9177 (gdb_rl_find_completion_word): New.
9178 (completion_find_completion_word): New.
9179 * completer.h (completion_find_completion_word): Declare.
9180
9181 2017-07-17 Pedro Alves <palves@redhat.com>
9182
9183 * ada-lang.c (symbol_completion_match): Adjust comments.
9184 (symbol_completion_add): Replace vector parameter with
9185 completion_tracker parameter. Use it.
9186 (ada_make_symbol_completion_list): Rename to...
9187 (ada_collect_symbol_completion_matches): ... this. Add
9188 completion_tracker parameter and use it.
9189 (ada_language_defn): Adjust.
9190 * break-catch-syscall.c (catch_syscall_completer): Adjust
9191 prototype and work with completion_tracker instead of VEC.
9192 * breakpoint.c (condition_completer): Adjust prototype and work
9193 with completion_tracker instead of VEC.
9194 * c-lang.c (c_language_defn, cplus_language_defn)
9195 (asm_language_defn, minimal_language_defn): Adjust to renames.
9196 * cli/cli-cmds.c (complete_command): Rework using
9197 completion_tracker. Catch exceptions when completing.
9198 * cli/cli-decode.c (integer_unlimited_completer)
9199 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
9200 with completion_tracker instead of VEC.
9201 * command.h (struct completion_tracker): Forward declare.
9202 (completer_ftype, completer_handle_brkchars_ftype): Change
9203 types.
9204 (complete_on_cmdlist, complete_on_enum): Adjust.
9205 * completer.c: Include <algorithm>.
9206 (struct gdb_completer_state): New.
9207 (current_completion): New global.
9208 (readline_line_completion_function): Delete.
9209 (noop_completer, filename_completer)
9210 (filename_completer_handle_brkchars, complete_files_symbols)
9211 (linespec_location_completer): Adjust to work with a
9212 completion_tracker instead of a VEC.
9213 (string_or_empty): New.
9214 (collect_explicit_location_matches): Adjust to work with a
9215 completion_tracker instead of a VEC.
9216 (explicit_location_completer): Rename to ...
9217 (complete_explicit_location): ... this and adjust to work with a
9218 completion_tracker instead of a VEC.
9219 (location_completer): Adjust to work with a completion_tracker
9220 instead of a VEC.
9221 (add_struct_fields): Adjust to work with a completion_list instead
9222 of VEC.
9223 (expression_completer): Rename to ...
9224 (complete_expression): ... this and adjust to work with a
9225 completion_tracker instead of a VEC. Use complete_files_symbols.
9226 (expression_completer): Reimplement on top of complete_expression.
9227 (symbol_completer): Adjust to work with a completion_tracker
9228 instead of a VEC.
9229 (enum complete_line_internal_reason): Add describing comments.
9230 (complete_line_internal_normal_command): Adjust to work with a
9231 completion_tracker instead of a VEC.
9232 (complete_line_internal): Rename to ...
9233 (complete_line_internal_1): ... this and adjust to work with a
9234 completion_tracker instead of a VEC. Assert TEXT is NULL in the
9235 handle_brkchars phase.
9236 (new_completion_tracker): Delete.
9237 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
9238 complete_line_internal_1.
9239 (free_completion_tracker): Delete.
9240 (INITIAL_COMPLETION_HTAB_SIZE): New.
9241 (completion_tracker::completion_tracker)
9242 (completion_tracker::~completion_tracker): New.
9243 (maybe_add_completion): Delete.
9244 (completion_tracker::maybe_add_completion)
9245 (completion_tracker::add_completion)
9246 (completion_tracker::add_completions): New.
9247 (throw_max_completions_reached_error): Delete.
9248 (complete_line): Adjust to work with a completion_tracker instead
9249 of a VEC. Don't create a completion_tracker_t or check for max
9250 completions here.
9251 (command_completer, command_completer_handle_brkchars)
9252 (signal_completer, reg_or_group_completer_1)
9253 (reg_or_group_completer, default_completer_handle_brkchars):
9254 Adjust to work with a completion_tracker.
9255 (gdb_completion_word_break_characters_throw): New.
9256 (gdb_completion_word_break_characters): Reimplement.
9257 (line_completion_function): Delete.
9258 (completion_tracker::recompute_lowest_common_denominator)
9259 (expand_preserving_ws)
9260 (completion_tracker::build_completion_result)
9261 (completion_result::completion_result)
9262 (completion_result::completion_result)
9263 (completion_result::~completion_result)
9264 (completion_result::completion_result)
9265 (completion_result::release_match_list, compare_cstrings)
9266 (completion_result::sort_match_list)
9267 (completion_result::reset_match_list)
9268 (gdb_rl_attempted_completion_function_throw)
9269 (gdb_rl_attempted_completion_function): New.
9270 * completer.h (completion_list, struct completion_result)
9271 (class completion_tracker): New.
9272 (complete_line): Add completion_tracker parameter.
9273 (readline_line_completion_function): Delete.
9274 (gdb_rl_attempted_completion_function): New.
9275 (noop_completer, filename_completer, expression_completer)
9276 (location_completer, symbol_completer, command_completer)
9277 (signal_completer, reg_or_group_completer): Update prototypes.
9278 (completion_tracker_t, new_completion_tracker)
9279 (make_cleanup_free_completion_tracker): Delete.
9280 (enum maybe_add_completion_enum): Delete.
9281 (maybe_add_completion): Delete.
9282 (throw_max_completions_reached_error): Delete.
9283 * corefile.c (complete_set_gnutarget): Adjust to work with a
9284 completion_tracker instead of a VEC.
9285 * cp-abi.c (cp_abi_completer): Adjust to work with a
9286 completion_tracker instead of a VEC.
9287 * d-lang.c (d_language_defn): Adjust.
9288 * disasm.c (disassembler_options_completer): Adjust to work with a
9289 completion_tracker instead of a VEC.
9290 * f-lang.c (f_make_symbol_completion_list): Rename to ...
9291 (f_collect_symbol_completion_matches): ... this. Adjust to work
9292 with a completion_tracker instead of a VEC.
9293 (f_language_defn): Adjust.
9294 * go-lang.c (go_language_defn): Adjust.
9295 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
9296 Adjust to work with a completion_tracker instead of a VEC.
9297 * infrun.c (handle_completer): Likewise.
9298 * interps.c (interpreter_completer): Likewise.
9299 * interps.h (interpreter_completer): Likewise.
9300 * language.c (unknown_language_defn, auto_language_defn)
9301 (local_language_defn): Adjust.
9302 * language.h (language_defn::la_make_symbol_completion_list):
9303 Rename to ...
9304 (language_defn::la_collect_symbol_completion_matches): ... this
9305 and adjust to work with a completion_tracker instead of a VEC.
9306 * m2-lang.c (m2_language_defn): Adjust.
9307 * objc-lang.c (objc_language_defn): Adjust.
9308 * opencl-lang.c (opencl_language_defn): Adjust.
9309 * p-lang.c (pascal_language_defn): Adjust.
9310 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
9311 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
9312 with a completion_tracker.
9313 * rust-lang.c (rust_language_defn): Adjust.
9314 * symtab.c (free_completion_list, do_free_completion_list)
9315 (return_val, completion_tracker): Delete.
9316 (completion_list_add_name, completion_list_add_symbol)
9317 (completion_list_add_msymbol, completion_list_objc_symbol)
9318 (completion_list_add_fields, add_symtab_completions): Add
9319 completion_tracker parameter and use it.
9320 (default_make_symbol_completion_list_break_on_1): Rename to...
9321 (default_collect_symbol_completion_matches_break_on): ... this.
9322 Add completion_tracker parameter and use it instead of allocating
9323 a completion tracker here.
9324 (default_make_symbol_completion_list_break_on): Delete old
9325 implementation.
9326 (default_make_symbol_completion_list): Delete.
9327 (default_collect_symbol_completion_matches): New.
9328 (make_symbol_completion_list): Delete.
9329 (collect_symbol_completion_matches): New.
9330 (make_symbol_completion_type): Rename to ...
9331 (collect_symbol_completion_matches_type): ... this. Add
9332 completion_tracker parameter and use it instead of VEC.
9333 (make_file_symbol_completion_list_1): Rename to...
9334 (collect_file_symbol_completion_matches): ... this. Add
9335 completion_tracker parameter and use it instead of VEC.
9336 (make_file_symbol_completion_list): Delete.
9337 (add_filename_to_list): Use completion_list instead of a VEC.
9338 (add_partial_filename_data::list): Now a completion_list.
9339 (make_source_files_completion_list): Work with a completion_list
9340 instead of a VEC.
9341 * symtab.h: Include "completer.h".
9342 (default_make_symbol_completion_list_break_on)
9343 (default_make_symbol_completion_list, make_symbol_completion_list)
9344 (make_symbol_completion_type, make_file_symbol_completion_list)
9345 (make_source_files_completion_list): Delete.
9346 (default_collect_symbol_completion_matches_break_on)
9347 (default_collect_symbol_completion_matches)
9348 (collect_symbol_completion_matches)
9349 (collect_symbol_completion_matches_type)
9350 (collect_file_symbol_completion_matches)
9351 (make_source_files_completion_list): New.
9352 * top.c (init_main): Don't install a rl_completion_entry_function
9353 hook. Install a rl_attempted_completion_function hook instead.
9354 * tui/tui-layout.c (layout_completer): Adjust to work with a
9355 completion_tracker.
9356 * tui/tui-regs.c (tui_reggroup_completer):
9357 * tui/tui-win.c (window_name_completer, focus_completer)
9358 (winheight_completer): Adjust to work with a completion_tracker.
9359 * value.c: Include "completer.h".
9360 (complete_internalvar): Adjust to work with a completion_tracker.
9361 * value.h (complete_internalvar): Likewise.
9362
9363 2017-07-17 Pedro Alves <palves@redhat.com>
9364
9365 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
9366 renames.
9367 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
9368 comments to completer_ftype's declaration.
9369 <completer_handle_brkchars>: Change type to
9370 completer_handle_brkchars_ftype.
9371 * command.h (completer_ftype): Add describing comment and give
9372 names to parameters.
9373 (completer_ftype_void): Rename to ...
9374 (completer_handle_brkchars_ftype) ... this. Add describing comment.
9375 (set_cmd_completer_handle_brkchars): Adjust.
9376 * completer.c (filename_completer_handle_brkchars): New function.
9377 (complete_line_internal_normal_command): New function, factored
9378 out from ...
9379 (complete_line_internal): ... here.
9380 (command_completer_handle_brkchars)
9381 (default_completer_handle_brkchars)
9382 (completer_handle_brkchars_func_for_completer): New functions.
9383 * completer.h (set_gdb_completion_word_break_characters): Delete
9384 declaration.
9385 (completer_handle_brkchars_func_for_completer): New declaration.
9386 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
9387 completer_handle_brkchars_func_for_completer.
9388
9389 2017-07-17 Pedro Alves <palves@redhat.com>
9390
9391 * completer.c (symbol_completer): New function, based on
9392 make_symbol_completion_list_fn.
9393 * completer.h (symbol_completer): New declaration.
9394 * guile/scm-cmd.c (cmdscm_completers): Adjust.
9395 * python/py-cmd.c (completers): Adjust.
9396 * symtab.c (make_symbol_completion_list_fn): Delete.
9397 * symtab.h (make_symbol_completion_list_fn): Delete.
9398 * cli/cli-decode.c (add_cmd): Adjust.
9399
9400 2017-07-17 Pedro Alves <palves@redhat.com>
9401
9402 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
9403 * dwarf2read.c: Include "filename-seen-cache.h".
9404 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
9405 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
9406 * filename-seen-cache.c: New file.
9407 * filename-seen-cache.h: New file.
9408 * symtab.c: Include "filename-seen-cache.h".
9409 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
9410 (create_filename_seen_cache, clear_filename_seen_cache)
9411 (delete_filename_seen_cache, filename_seen): Delete, parts moved
9412 to filename-seen-cache.h/filename-seen-cache.c.
9413 (output_source_filename, sources_info)
9414 (maybe_add_partial_symtab_filename)
9415 (make_source_files_completion_list): Adjust to use
9416 filename_seen_cache.
9417
9418 2017-07-17 Pedro Alves <palves@redhat.com>
9419
9420 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
9421 fields.
9422 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
9423 dwarf2_debug_sections*)): New.
9424 (dwarf2_per_objfile::dwarf2_per_objfile(const
9425 dwarf2_per_objfile&)): Declare as deleted.
9426 (dwarf2_per_objfile::operator=): Declare as deleted.
9427 (dwarf2_per_objfile::dwarf2_per_objfile)
9428 (dwarf2_per_objfile::~dwarf2_per_objfile)
9429 (dwarf2_per_objfile::free_cached_comp_units): New.
9430 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
9431 ctor. Call dwarf2_per_objfile's ctor manually.
9432 (dwarf2_locate_sections): Deleted/refactored as ...
9433 (dwarf2_per_objfile::locate_sections): ... this new method.
9434 (free_cached_comp_units): Defer to
9435 dwarf2_per_objfile::free_cached_comp_units.
9436 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
9437
9438 2017-07-14 Tom Tromey <tom@tromey.com>
9439
9440 PR rust/21764:
9441 * rust-exp.y (convert_ast_to_expression): Add "want_type"
9442 parameter.
9443 <UNOP_SIZEOF>: Split into separate case.
9444 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
9445
9446 2017-07-14 Tom Tromey <tom@tromey.com>
9447
9448 PR rust/21763:
9449 * symtab.c (symbol_matches_domain): Add language_rust to special
9450 case.
9451 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
9452 treat LOC_TYPEDEF symbols as variables.
9453
9454 2017-07-14 Pedro Alves <palves@redhat.com>
9455
9456 * symtab.c (make_file_symbol_completion_list_1): Iterate over
9457 symtabs matching all symtabs with SRCFILE as file name instead of
9458 only considering the first hit, with lookup_symtab.
9459
9460 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9461
9462 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
9463 operator_name parameters.
9464 (gen_expr): Update function call.
9465
9466 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9467
9468 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
9469 parameter.
9470 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
9471 Likewise.
9472 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
9473 parameter, use agent_expr::gdbarch instead, update function
9474 calls.
9475 (locexpr_tracepoint_var_ref): Likewise.
9476 (loclist_tracepoint_var_ref): Likewise.
9477 * ax-gdb.c (gen_trace_static_fields): Likewise.
9478 (gen_traced_pop): Likewise.
9479 (gen_frame_args_address): Likewise.
9480 (gen_frame_locals_address): Likewise.
9481 (gen_var_ref): Likewise.
9482 (gen_struct_ref_recursive): Likewise.
9483 (gen_static_field): Likewise.
9484 (gen_maybe_namespace_elt): Likewise.
9485 (gen_expr): Likewise.
9486 (gen_trace_for_var): Likewise.
9487 (gen_trace_for_expr): Likewise.
9488 (gen_trace_for_return_address): Likewise.
9489
9490 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9491
9492 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
9493 parameter.
9494 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
9495
9496 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9497
9498 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
9499 from ax, update calls.
9500 (gen_usual_arithmetic): Likewise.
9501 (gen_integral_promotions): Likewise.
9502 (gen_bitfield_ref): Likewise.
9503 (gen_primitive_field): Likewise.
9504 (gen_struct_ref_recursive): Likewise.
9505 (gen_struct_ref): Likewise.
9506 (gen_maybe_namespace_elt): Likewise.
9507 (gen_struct_elt_for_reference): Likewise.
9508 (gen_namespace_elt): Likewise.
9509 (gen_aggregate_elt_ref): Likewise.
9510 (gen_expr): Get gdbarch from ax, update calls.
9511 (gen_expr_binop_rest): Likewise.
9512
9513 2017-07-13 Pedro Alves <palves@redhat.com>
9514
9515 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
9516 as default tdesc.
9517 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
9518 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
9519 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
9520 tdesc_amd64_linux as default tdesc. Get final tdesc from the
9521 tdep.
9522 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
9523 Get final tdesc from the tdep.
9524 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
9525 default tdesc.
9526 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
9527 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
9528 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
9529 Use it as default tdesc.
9530 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
9531 down to amd_init_abi. No longer handle fallback tdesc here.
9532 * amd64-tdep.h (tdesc_x32): Declare.
9533 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
9534 parameter.
9535 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
9536 as default tdesc.
9537
9538 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9539
9540 * s390-linux-tdep.c (s390_process_record): Add support for
9541 instructions new in arch12.
9542
9543 2017-07-11 John Baldwin <jhb@FreeBSD.org>
9544
9545 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
9546 PT_GETFSBASE and PT_GETGSBASE.
9547 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
9548 PT_SETGSBASE.
9549
9550 2017-07-11 John Baldwin <jhb@FreeBSD.org>
9551
9552 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
9553 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
9554 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
9555 those rules.
9556 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
9557 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
9558 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
9559 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
9560 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
9561 * features/i386/amd64.xml: Add 64bit-segments.xml.
9562 * features/i386/amd64-avx-avx512.c: Regenerated.
9563 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
9564 * features/i386/amd64-avx-mpx.c: Regenerated.
9565 * features/i386/amd64-avx.c: Regenerated.
9566 * features/i386/amd64-mpx.c: Regenerated.
9567 * features/i386/amd64.c: Regenerated.
9568 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
9569 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
9570 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
9571 * regformats/i386/amd64-avx.dat: Regenerated.
9572 * regformats/i386/amd64-mpx.dat: Regenerated.
9573 * regformats/i386/amd64.dat: Regenerated.
9574
9575 2017-07-10 Yao Qi <yao.qi@linaro.org>
9576
9577 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
9578 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
9579
9580 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
9581
9582 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
9583 unsetenv.
9584 * gnulib/aclocal.m4: Regenerate.
9585 * gnulib/config.in: Regenerate.
9586 * gnulib/configure: Regenerate.
9587 * gnulib/import/Makefile.am: Regenerate.
9588 * gnulib/import/Makefile.in: Regenerate.
9589 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
9590 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
9591 * gnulib/import/m4/environ.m4: New file.
9592 * gnulib/import/m4/setenv.m4: New file.
9593 * gnulib/import/setenv.c: New file.
9594 * gnulib/import/unsetenv.c: New file.
9595
9596 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
9597
9598 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
9599 address when op is DW_OP_addr.
9600
9601 2017-07-09 Tom Tromey <tom@tromey.com>
9602
9603 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
9604 check and apply to outer type.
9605
9606 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9607
9608 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
9609 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
9610 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
9611 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
9612
9613 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9614
9615 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
9616
9617 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9618
9619 * corelow.c (get_core_siginfo): Remove.
9620 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
9621 instead of get_core_siginfo.
9622 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
9623 * gdbarch.h: Re-generate.
9624 * gdbarch.c: Re-generate.
9625 * linux-tdep.c (linux_core_xfer_siginfo): New.
9626 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
9627
9628 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9629
9630 * corelow.c (thread_section_name): Move to ...
9631 * gdbcore.h (thread_section_name): ... here.
9632
9633 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9634
9635 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
9636 (struct siginfo32): New.
9637 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
9638 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
9639 via ptrace(PT_LWPINFO).
9640
9641 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9642
9643 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
9644 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
9645 (fbsd_get_siginfo_type): New.
9646 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
9647 (_initialize_fbsd_tdep): New.
9648
9649 2017-07-06 David Blaikie <dblaikie@gmail.com>
9650
9651 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
9652 a singular dwo_unit*) to support multiple CUs in the same way that
9653 multiple TUs are supported.
9654 (create_cus_hash_table): Replace create_dwo_cu with a function for
9655 parsing multiple CUs from a DWO file.
9656 (open_and_init_dwo_file): Use create_cus_hash_table rather than
9657 create_dwo_cu.
9658 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
9659 htab_find, rather than comparing the signature to a singleton CU in
9660 the dwo_file.
9661
9662 2017-07-06 Pedro Alves <palves@redhat.com>
9663
9664 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
9665
9666 2017-07-04 Pedro Alves <palves@redhat.com>
9667
9668 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
9669 * gdbtypes.h (TYPE_STATIC): Delete.
9670 (struct fn_field) <is_public, is_abstract, is_static, is_final,
9671 is_synchronized, is_native>: Delete.
9672 <dummy>: Bump.
9673 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
9674 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
9675 (TYPE_FN_FIELD_ABSTRACT): Delete.
9676
9677 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
9678
9679 * buffer.h (buffer_finish): Fix spelling mistakes.
9680
9681 2017-07-01 Eli Zaretskii <eliz@gnu.org>
9682
9683 * .dir-locals.el: Automatically switch to C-style comments in
9684 versions of Emacs that support the feature.
9685
9686 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
9687 Pedro Alves <palves@redhat.com>
9688
9689 PR cli/21688
9690 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
9691 (process_next_line): New variable 'inline_cmd'.
9692 Adjust 'if' clauses for "python", "compile" and "guile" to use
9693 'command_name_equals' and check for '!inline_cmd'.
9694
9695 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
9696
9697 PR cli/21688
9698 * cli/cli-script.c (command_name_equals_not_inline): New function.
9699 (process_next_line): Adjust 'if' clauses for "python", "compile"
9700 and "guile" to use command_name_equals_not_inline.
9701
9702 2017-06-29 Pedro Alves <palves@redhat.com>
9703
9704 * completer.c (expression_completer): Call
9705 linespec_location_completer instead of location_completer.
9706
9707 2017-06-29 Pedro Alves <palves@redhat.com>
9708
9709 * completer.c (expression_completer): Remove code that recomputes
9710 'text' from 'word'.
9711
9712 2017-06-29 Yao Qi <yao.qi@linaro.org>
9713
9714 * regformats/regdat.sh: Generate code with
9715 "ifndef IN_PROCESS_AGENT".
9716
9717 2017-06-28 Pedro Alves <palves@redhat.com>
9718
9719 * command.h: Include "common/scoped_restore.h".
9720
9721 2017-06-28 Yao Qi <yao.qi@linaro.org>
9722
9723 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
9724 instead of obstack_grow.
9725
9726 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
9727
9728 PR gdb/21337
9729 * symfile.c (reread_symbols): Call objfiles_changed just before
9730 read_symbols.
9731
9732 2017-06-27 Pedro Alves <palves@redhat.com>
9733
9734 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
9735 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
9736 (completion_list_add_symbol, completion_list_add_msymbol):
9737 ... these new functions.
9738 (add_symtab_completions)
9739 (default_make_symbol_completion_list_break_on_1): Adjust.
9740
9741 2017-06-27 Pedro Alves <palves@redhat.com>
9742
9743 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
9744 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
9745 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
9746 dtor.
9747 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
9748 'storage_obstack' field an auto_obstack. In-class initialize all
9749 non-bitfield fields. Make minsyms_read bool.
9750 * symfile.c (read_symbols): Adjust.
9751
9752 2017-06-27 Alan Hayward <alan.hayward@arm.com>
9753
9754 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
9755 (gdbsim_store_register): Likewise.
9756
9757 2017-06-27 Pedro Alves <palves@redhat.com>
9758
9759 * c-exp.y (name_obstack): Now an auto_obstack.
9760 (yylex): Use auto_obstack::clear.
9761 (c_parse): Use auto_obstack::clear instead of reinitializing and
9762 freeing the obstack.
9763 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
9764 * d-exp.y (name_obstack): Now an auto_obstack.
9765 (yylex): Use auto_obstack::clear.
9766 (d_parse): Use auto_obstack::clear instead of reinitializing and
9767 freeing the obstack.
9768 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
9769 auto_obstack.
9770 * dwarf2read.c (create_addrmap_from_index)
9771 (dwarf2_build_psymtabs_hard)
9772 (update_enumeration_type_from_children): Likewise.
9773 * gdb_obstack.h (auto_obstack): New type.
9774 * go-exp.y (name_obstack): Now an auto_obstack.
9775 (build_packaged_name): Use auto_obstack::clear.
9776 (go_parse): Use auto_obstack::clear instead of reinitializing and
9777 freeing the obstack.
9778 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
9779 auto_obstack.
9780 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
9781 * rust-exp.y (work_obstack): Now an auto_obstack.
9782 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
9783 reinitializing and freeing the obstack.
9784 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
9785 (host_char_to_target): Use auto_obstack.
9786 * utils.h (make_cleanup_obstack_free): Delete declaration.
9787 * valprint.c (generic_emit_char, generic_printstr): Use
9788 auto_obstack.
9789
9790 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
9791
9792 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
9793 thread.
9794 (darwin_init_thread_list): Don't update dummy thread.
9795 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
9796
9797 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
9798
9799 * record-full.c (netorder16): Remove.
9800
9801 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
9802
9803 * common/diagnostics.h: Define macros for GCC.
9804 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
9805 * common/vec.h: Include diagnostics.h.
9806 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
9807 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
9808 warning.
9809
9810 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
9811
9812 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
9813 New macro.
9814 * ada-lex.l: Ignore deprecated register warnings.
9815
9816 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
9817
9818 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
9819 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
9820
9821 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
9822
9823 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
9824 its own line.
9825
9826 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
9827
9828 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
9829
9830 2017-06-23 Alan Hayward <alan.hayward@arm.com>
9831
9832 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
9833 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
9834 (xtensa_register_read_masked): Likewise.
9835
9836 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
9837
9838 * common/environ.c (gdb_environ::unset): Update comment.
9839
9840 2017-06-22 Alan Hayward <alan.hayward@arm.com>
9841
9842 * python/py-unwind.c (pyuw_sniffer): Allocate space for
9843 registers.
9844
9845 2017-06-22 Alan Hayward <alan.hayward@arm.com>
9846
9847 * record-full.c (record_full_exec_insn): Use byte_vector.
9848
9849 2017-06-22 Yao Qi <yao.qi@linaro.org>
9850
9851 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
9852 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
9853
9854 2017-06-22 Alan Hayward <alan.hayward@arm.com>
9855
9856 * remote.c (cached_reg): Move from here...
9857 * regcache.h (cached_reg): ...to here.
9858 * python/py-unwind.c (struct reg_info): Remove.
9859 (cached_frame_info): Use cached_reg_t.
9860 (pyuw_prev_register): Likewise.
9861 (pyuw_sniffer): Use cached_reg_t and allocate registers.
9862 (pyuw_dealloc_cache): Free all registers.
9863
9864 2017-06-22 Pedro Alves <palves@redhat.com>
9865 Simon Marchi <simon.marchi@ericsson.com>
9866
9867 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
9868 warning.
9869 * common/diagnostics.h: New file.
9870
9871 2017-06-22 Pedro Alves <palves@redhat.com>
9872
9873 * common/agent.h: Add include guards.
9874
9875 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
9876
9877 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
9878 talk about addressable units instead of bytes.
9879
9880 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
9881
9882 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
9883 of '::const_iterator'.
9884
9885 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
9886
9887 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9888 'unittests/environ-selftests.c'.
9889 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
9890 * charset.c (find_charset_names): Declare object 'iconv_env'.
9891 Update code to use 'iconv_env' object. Remove call to
9892 'free_environ'.
9893 * common/environ.c: Include <utility>.
9894 (make_environ): Delete function.
9895 (free_environ): Delete function.
9896 (gdb_environ::clear): New function.
9897 (gdb_environ::operator=): New function.
9898 (gdb_environ::get): Likewise.
9899 (environ_vector): Delete function.
9900 (set_in_environ): Delete function.
9901 (gdb_environ::set): New function.
9902 (unset_in_environ): Delete function.
9903 (gdb_environ::unset): New function.
9904 (gdb_environ::envp): Likewise.
9905 * common/environ.h: Include <vector>.
9906 (struct gdb_environ): Delete; transform into...
9907 (class gdb_environ): ... this class.
9908 (free_environ): Delete prototype.
9909 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
9910 environ_vector): Likewise.
9911 * infcmd.c (run_command_1): Update code to call
9912 'envp' from 'gdb_environ' class.
9913 (environment_info): Update code to call methods from 'gdb_environ'
9914 class.
9915 (unset_environment_command): Likewise.
9916 (path_info): Likewise.
9917 (path_command): Likewise.
9918 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
9919 (inferior::inferior): Initialize 'environment' using the host's
9920 information.
9921 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
9922 Include "environ.h".
9923 (class inferior) <environment>: Change type from 'struct
9924 gdb_environ' to 'gdb_environ'.
9925 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
9926 methods from 'gdb_environ' class.
9927 * solib.c (solib_find_1): Likewise
9928 * unittests/environ-selftests.c: New file.
9929
9930 2017-06-20 Yao Qi <yao.qi@linaro.org>
9931
9932 * features/i386/i386-linux.xml: Exchange the order of including
9933 32bit-linux.xml and 32bit-sse.xml.
9934 * features/i386/i386-linux.c: Regenerated.
9935
9936 2017-06-20 Yao Qi <yao.qi@linaro.org>
9937
9938 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
9939 Delete copy ctor and assignment operator.
9940 (tdesc_type): Likewise.
9941 (tdesc_feature): Likewise.
9942 (tdesc_free_reg): Remove.
9943 (tdesc_create_reg): Use new.
9944 (tdesc_free_type): Remove.
9945 (tdesc_create_vector): Use new.
9946 (tdesc_create_union): Likewise.
9947 (tdesc_create_flags): Likewise.
9948 (tdesc_create_enum): Likewise.
9949 (tdesc_free_feature): Delete.
9950 (free_target_description): Use delete.
9951
9952 2017-06-19 John Baldwin <jhb@FreeBSD.org>
9953
9954 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
9955 registers.
9956
9957 2017-06-19 Pedro Alves <palves@redhat.com>
9958
9959 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
9960 after gdb::unlinker.
9961
9962 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
9963
9964 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
9965 gdb_environ to access an environment variable.
9966
9967 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
9968
9969 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
9970 gdb_byte*.
9971
9972 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9973
9974 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
9975
9976 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9977
9978 * configure: Re-generate.
9979 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
9980
9981 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9982
9983 * configure: Re-generate.
9984 * warning.m4: Pass -Werror to compiler when checking for
9985 supported warning flags.
9986
9987 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9988
9989 * Makefile.in (COMPILE.pre): Add "-x c++".
9990
9991 2017-06-16 Alan Hayward <alan.hayward@arm.com>
9992 Pedro Alves <palves@redhat.com>
9993 Yao Qi <yao.qi@linaro.org>
9994
9995 * defs.h (RequireLongest): New.
9996 (extract_integer): Declare function template.
9997 (extract_signed_integer): Remove the declaration, but define it
9998 static inline.
9999 (extract_unsigned_integer): Likewise.
10000 (store_integer): Declare function template.
10001 (store_signed_integer): Remove the declaration, but define it
10002 static inline.
10003 (store_unsigned_integer): Likewise.
10004 * findvar.c (extract_integer): New function template.
10005 (extract_signed_integer): Remove.
10006 (extract_unsigned_integer): Remove.
10007 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
10008 instantiations.
10009 (store_integer): New function template.
10010 (store_signed_integer): Remove.
10011 (store_unsigned_integer): Remove.
10012 (store_integer): Explicit instantiations.
10013 * regcache.c (regcache_raw_read_signed): Update.
10014 (regcache::raw_read): New function.
10015 (regcache::raw_read_signed): Remove.
10016 (regcache::raw_read_unsigned): Remove.
10017 (regcache_raw_read_unsigned): Update.
10018 (regcache_raw_write_unsigned): Update.
10019 (regcache::raw_write_signed): Remove.
10020 (regcache::raw_write): New function.
10021 (regcache_cooked_read_signed): Update.
10022 (regcache::raw_write_unsigned): Remove.
10023 (regcache::cooked_read_signed): Remove.
10024 (regcache_cooked_read_unsigned): Update.
10025 (regcache::cooked_read_unsigned): Remove.
10026 (regcache_cooked_write_signed): Update.
10027 (regcache_cooked_write_unsigned): Update.
10028 * regcache.h (regcache) <raw_read_signed>: Remove.
10029 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
10030 <raw_read, raw_write>: New.
10031 <cooked_read_signed, cooked_write_signed>: Remove.
10032 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
10033 <cooked_read, cooked_write>: New.
10034 * sh64-tdep.c (sh64_pseudo_register_read): Update.
10035 (sh64_pseudo_register_write): Update.
10036
10037 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
10038
10039 * arc-tdep.c (arc_disassembler_options): New variable.
10040 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
10041 of default_print_insn.
10042 (arc_delayed_print_insn): Set info->section when needed,
10043 use default_print_insn to retrieve a disassembler.
10044
10045 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
10046
10047 PR gdb/21574
10048 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
10049 to mention $SHELL and startup-with-shell.
10050
10051 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
10052
10053 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
10054
10055 2017-06-14 Yao Qi <yao.qi@linaro.org>
10056
10057 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
10058 default_print_insn instead of print_insn_aarch64.
10059 * arm-tdep.c (gdb_print_insn_arm): Call
10060 default_print_insn instead of print_insn_big_arm
10061 and print_insn_little_arm.
10062 * i386-tdep.c (i386_print_insn): Call default_print_insn
10063 instead of print_insn_i386.
10064 * ia64-tdep.c (ia64_print_insn): Call
10065 default_print_insn instead of print_insn_ia64.
10066 * mips-tdep.c (gdb_print_insn_mips): Call
10067 default_print_insn instead of print_insn_big_mips
10068 and print_insn_little_mips.
10069 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
10070 instead of print_insn_spu.
10071
10072 2017-06-14 Pedro Alves <palves@redhat.com>
10073
10074 * ada-lang.c: Include "common/byte-vector.h".
10075 (ada_value_primitive_packed_val): Use gdb::byte_vector.
10076 * charset.c (wchar_iterator::iterate): Resize the vector instead
10077 of reserving it.
10078 * common/byte-vector.h: Include "common/def-vector.h".
10079 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
10080 * cli/cli-dump.c: Include "common/byte-vector.h".
10081 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
10082 * common/byte-vector.h: New file.
10083 * common/def-vector.h: New file.
10084 * common/default-init-alloc.h: New file.
10085 * dwarf2loc.c: Include "common/byte-vector.h".
10086 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
10087 instead of reserving it.
10088 * dwarf2read.c: Include "common/byte-vector.h".
10089 (data_buf::m_vec): Now a gdb::byte_vector.
10090 * gdb_regex.c: Include "common/def-vector.h".
10091 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
10092 * mi/mi-main.c: Include "common/byte-vector.h".
10093 (mi_cmd_data_read_memory): Use gdb::byte_vector.
10094 * printcmd.c: Include "common/byte-vector.h".
10095 (print_scalar_formatted): Use gdb::byte_vector.
10096 * valprint.c: Include "common/byte-vector.h".
10097 (maybe_negate_by_bytes, print_decimal_chars): Use
10098 gdb::byte_vector.
10099
10100 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10101
10102 * darwin-nat.c: Include "nat/fork-inferior.h".
10103
10104 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10105
10106 * configure.nat: Factor out Darwin bits that are not
10107 architecture-specific. Add fork-inferior.o.
10108
10109 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10110
10111 * configure.nat: Factor out AIX bits that are not
10112 architecture-specific. Add fork-inferior.o.
10113
10114 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10115
10116 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
10117 (read_pieced_value, write_pieced_value): ...here. Reduce to
10118 wrappers that just call rw_pieced_value.
10119
10120 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10121
10122 * dwarf2loc.c (write_pieced_value): When writing the data for a
10123 memory piece, use write_memory_with_notification instead of
10124 write_memory.
10125
10126 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10127
10128 * valops.c (read_value_memory): Change embedded_offset to
10129 represent a bit offset instead of a byte offset.
10130 * value.h (read_value_memory): Adjust comment.
10131
10132 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10133
10134 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
10135 dest_offset_bits and source_offset_bits.
10136 (write_pieced_value): Likewise.
10137
10138 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10139
10140 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
10141 given by DW_OP_bit_piece.
10142 (write_pieced_value): Likewise.
10143
10144 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10145
10146 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
10147 some other preparations to the places where sufficient information
10148 is available.
10149 (write_pieced_value): Likewise.
10150
10151 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10152
10153 * dwarf2loc.c (bits_to_bytes): New function.
10154 (read_pieced_value): Fix offset calculations for register pieces
10155 on big-endian targets.
10156 (write_pieced_value): Likewise.
10157
10158 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10159
10160 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
10161 (write_pieced_value): Likewise.
10162
10163 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10164
10165 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
10166 transfer the source value's least significant bits, instead of its
10167 lowest-addressed ones. Rename type_len to max_offset.
10168 (read_pieced_value): Mirror above changes to write_pieced_value as
10169 applicable.
10170
10171 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10172
10173 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
10174 truncate full bytes from dest_offset_bits before using it as an
10175 offset into the buffer.
10176
10177 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10178
10179 * dwarf2loc.c (write_pieced_value): Include transfer size in
10180 byte-wise check.
10181
10182 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10183
10184 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
10185 calculation of this_size.
10186
10187 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10188
10189 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
10190 when targeting a bit-field.
10191 (write_pieced_value): Likewise.
10192
10193 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10194
10195 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
10196 (allocate_piece_closure): Drop addr_size parameter.
10197 (dwarf2_evaluate_loc_desc_full): Adjust call to
10198 allocate_piece_closure.
10199
10200 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10201
10202 PR gdb/21226
10203 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
10204 the LSB end, independent of endianness.
10205
10206 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10207
10208 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
10209 size capping.
10210
10211 2017-06-13 Yao Qi <yao.qi@linaro.org>
10212
10213 * mips-linux-nat.c: Move include features/mips*-linux.c to
10214 mips-linux-tdep.c.
10215 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
10216 to mips-linux-tdep.c.
10217 * mips-linux-tdep.c: Include features/mips*-linux.c
10218 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
10219 functions.
10220 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
10221 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
10222 (tdesc_mips64_dsp_linux): Declare.
10223
10224 2017-06-12 Tom Tromey <tom@tromey.com>
10225
10226 * valprint.h (val_print_type_code_int): Remove.
10227 * valprint.c (generic_val_print_int): Always call
10228 val_print_scalar_formatted.
10229 (val_print_type_code_int): Remove.
10230 * printcmd.c (print_scalar_formatted): Handle options->format==0.
10231 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
10232 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
10233 * ada-valprint.c (ada_val_print_num): Use
10234 val_print_scalar_formatted.
10235
10236 2017-06-12 Tom Tromey <tom@tromey.com>
10237
10238 * printcmd.c (print_scalar_formatted): Unify the two switches.
10239 Don't convert scalars to LONGEST.
10240
10241 2017-06-12 Tom Tromey <tom@tromey.com>
10242
10243 PR exp/16225:
10244 * valprint.h (print_decimal_chars): Update.
10245 * valprint.c (maybe_negate_by_bytes): New function.
10246 (print_decimal_chars): Add "is_signed" argument.
10247 * printcmd.c (print_scalar_formatted): Update.
10248
10249 2017-06-12 Tom Tromey <tom@tromey.com>
10250
10251 PR exp/16225:
10252 * valprint.h (print_binary_chars, print_hex_chars): Update.
10253 * valprint.c (val_print_type_code_int): Update.
10254 (print_binary_chars): Add "zero_pad" argument.
10255 (emit_octal_digit): New function.
10256 (print_octal_chars): Don't zero-pad.
10257 (print_decimal_chars): Likewise.
10258 (print_hex_chars): Add "zero_pad" argument.
10259 * sh64-tdep.c (sh64_do_fp_register): Update.
10260 * regcache.c (regcache::dump): Update.
10261 * printcmd.c (print_scalar_formatted): Update.
10262 * infcmd.c (default_print_one_register_info): Update.
10263
10264 2017-06-12 Pedro Alves <palves@redhat.com>
10265 Alan Hayward <alan.hayward@arm.com>
10266
10267 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
10268 (mips_eabi_push_dummy_call): Rename local 'regsize' to
10269 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
10270 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
10271 Assert that abi_regsize bytes fit in 'ref_valbuf'.
10272
10273 2017-06-12 Pedro Alves <palves@redhat.com>
10274
10275 * dwarf2read.c (mapped_symtab::data): Now a vector of
10276 symtab_index_entry instead of vector of
10277 std::unique_ptr<symtab_index_entry>. All users adjusted to check
10278 whether an element's name is NULL instead of checking whether the
10279 element itself is NULL.
10280 (find_slot): Change return type. Adjust.
10281 (hash_expand, , add_index_entry, uniquify_cu_indices)
10282 (write_hash_table): Adjust.
10283
10284 2017-06-12 Pedro Alves <palves@redhat.com>
10285
10286 * dwarf2read.c (recursively_count_psymbols): New function.
10287 (write_psymtabs_to_index): Call it to compute number of psyms and
10288 pass estimate size of psyms_seen to unordered_set's ctor.
10289
10290 2017-06-12 Pedro Alves <palves@redhat.com>
10291
10292 * dwarf2read.c (write_hash_table): Check if key already exists
10293 before emplacing.
10294
10295 2017-06-12 Pedro Alves <palves@redhat.com>
10296
10297 * dwarf2read.c (data_buf::append_space): Rename to...
10298 (data_buf::grow): ... this, and make private. Adjust all callers.
10299 (data_buf::append_uint): New method.
10300 (add_address_entry, write_one_signatured_type)
10301 (write_psymtabs_to_index): Use it.
10302
10303 2017-06-12 Pedro Alves <palves@redhat.com>
10304
10305 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
10306 (file_write (FILE *, const std::vector<Elem>&)): Delete.
10307 (data_buf::file_write): Call ::fwrite directly.
10308
10309 2017-06-12 Pedro Alves <palves@redhat.com>
10310
10311 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
10312 std::vector::erase.
10313
10314 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
10315
10316 Code cleanup: C++ify .gdb_index producer.
10317 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
10318 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
10319 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
10320 (create_strtab, add_string): Remove.
10321 (file_write, data_buf): New.
10322 (struct symtab_index_entry): Use std::vector for cu_indices.
10323 (struct mapped_symtab): Use std::vector for data.
10324 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
10325 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
10326 Remove.
10327 (find_slot): Change return type. Update it to the new data structures.
10328 (hash_expand, add_index_entry): Update it to the new data structures.
10329 (offset_type_compare): Remove.
10330 (uniquify_cu_indices): Update it to the new data structures.
10331 (c_str_view, c_str_view_hasher, vector_hasher): New.
10332 (add_indices_to_cpool): Remove.
10333 (write_hash_table): Update it to the new data structures.
10334 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
10335 (eq_psymtab_cu_index): Remove.
10336 (psym_index_map): New typedef.
10337 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
10338 reference and std::unordered_map for cu_index_htab.
10339 (add_address_entry, add_address_entry_worker, write_address_map)
10340 (write_psymbols): Update it to the new data structures.
10341 (write_obstack): Remove.
10342 (struct signatured_type_index_data): Change types_list to a data_buf
10343 reference and psyms_seen to a std::unordered_set reference.
10344 (write_one_signatured_type, recursively_write_psymbols)
10345 (write_psymtabs_to_index): Update it to the new data structures.
10346
10347 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
10348
10349 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
10350 separate-debug-file commands.
10351 * symfile.h (separate_debug_file_debug): New global.
10352 * symfile.c (separate_debug_file_debug): New global.
10353 (separate_debug_file_exists, find_separate_debug_file): Add
10354 debug output.
10355 (_initialize_symfile): Add "set debug separate-debug-file"
10356 command.
10357 * build-id.c (build_id_to_debug_bfd,
10358 find_separate_debug_file_by_buildid): Add debug output.
10359
10360 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
10361
10362 * gdbarch.sh (displaced_step_free_closure): Remove.
10363 * gdbarch.h, gdbarch.c: Re-generate.
10364 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
10365 displaced_step_free_closure.
10366 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
10367 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
10368 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
10369 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
10370 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
10371 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
10372 * arch-utils.h (simple_displaced_step_free_closure): Remove.
10373 * arch-utils.c (simple_displaced_step_free_closure): Remove.
10374 * infrun.c (displaced_step_clear): Call xfree instead of
10375 gdbarch_displaced_step_free_closure.
10376
10377 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
10378
10379 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
10380 NULL".
10381
10382 2017-06-08 Alan Hayward <alan.hayward@arm.com>
10383
10384 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
10385 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
10386 (mn10300_push_dummy_call): Likewise.
10387
10388 2017-06-08 Alan Hayward <alan.hayward@arm.com>
10389
10390 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
10391
10392 2017-06-08 Alan Hayward <alan.hayward@arm.com>
10393
10394 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
10395
10396 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10397
10398 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
10399 able to start inferiors using a shell.
10400 (New remote packets): Announce new packet "QStartupWithShell".
10401 * remote.c: Add PACKET_QStartupWithShell.
10402 (extended_remote_create_inferior): Handle new
10403 PACKET_QStartupWithShell.
10404 (remote_protocol_features) <QStartupWithShell>: New entry for
10405 PACKET_QStartupWithShell.
10406 (_initialize_remote): Call "add_packet_config_cmd" for
10407 QStartupShell.
10408
10409 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10410 Pedro Alves <palves@redhat.com>
10411
10412 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
10413 and "nat/fork-inferior.h".
10414 * common/common-inferior.h: New file, with contents from
10415 "gdb/inferior.h".
10416 * commom/common-utils.c: Include "common-utils.h".
10417 (stringify_argv): New function.
10418 * common/common-utils.h (stringify_argv): New prototype.
10419 * configure.nat: Add "fork-inferior.o" as a dependency for
10420 "*linux*", "fbsd*" and "nbsd*" hosts.
10421 * corefile.c (get_exec_file): Update comment.
10422 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
10423 instead of "startup_inferior".
10424 (darwin_create_inferior): Call "add_thread_silent" after
10425 "fork_inferior".
10426 * fork-child.c: Cleanup unnecessary includes.
10427 (SHELL_FILE): Move to "common/common-fork-child.c".
10428 (environ): Likewise.
10429 (exec_wrapper): Initialize.
10430 (get_exec_wrapper): New function.
10431 (breakup_args): Move to "common/common-fork-child.c"; rename to
10432 "breakup_args_for_exec".
10433 (escape_bang_in_quoted_argument): Move to
10434 "common/common-fork-child.c".
10435 (saved_ui): New variable.
10436 (prefork_hook): New function.
10437 (postfork_hook): Likewise.
10438 (postfork_child_hook): Likewise.
10439 (gdb_startup_inferior): Likewise.
10440 (fork_inferior): Move to "common/common-fork-child.c". Update
10441 function to support gdbserver.
10442 (startup_inferior): Likewise.
10443 * gdbcore.h (get_exec_file): Remove declaration.
10444 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
10445 instead of "startup_inferior". Call "add_thread_silent" after
10446 "fork_inferior".
10447 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
10448 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
10449 instead of "startup_inferior". Call "add_thread_silent" after
10450 "fork_inferior".
10451 * inferior.h: Include "common-inferior.h".
10452 (trace_start_error): Move to "common/common-utils.h".
10453 (trace_start_error_with_name): Likewise.
10454 (fork_inferior): Move prototype to "nat/fork-inferior.h".
10455 (startup_inferior): Likewise.
10456 (gdb_startup_inferior): New prototype.
10457 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
10458 * nat/fork-inferior.h: New file.
10459 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
10460 instead of "startup_inferior". Call "add_thread_silent" after
10461 "fork_inferior".
10462 * target.h (target_terminal_init): Move prototype to
10463 "target/target.h".
10464 (target_terminal_inferior): Likewise.
10465 (target_terminal_ours): Likewise.
10466 * target/target.h (target_terminal_init): New prototype, moved
10467 from "target.h".
10468 (target_terminal_inferior): Likewise.
10469 (target_terminal_ours): Likewise.
10470 * utils.c (gdb_flush_out_err): New function.
10471
10472 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10473
10474 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
10475 * common/common-gdbthread.h: New file, with parts from
10476 "gdb/gdbthread.h".
10477 * gdbthread.h: Include "common-gdbthread.h".
10478 (switch_to_thread): Moved to "common/common-gdbthread.h".
10479
10480 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10481
10482 * Makefile.in (SFILES): Add "common/job-control.c".
10483 (HFILES_NO_SRCDIR): Add "common/job-control.h".
10484 (COMMON_OBS): Add "job-control.o".
10485 * common/job-control.c: New file, with contents from
10486 "gdb/inflow.c".
10487 * common/job-control.h: New file, with contents from "terminal.h".
10488 * fork-child.c: Include "job-control.h".
10489 * inflow.c: Include "job-control.h".
10490 (gdb_setpgid): Move to "common/common-inflow.c".
10491 (_initialize_inflow): Move setting of "job_control" to
10492 "handle_job_control".
10493 * terminal.h (job_control): Moved to "common/common-terminal.h".
10494 (gdb_setpgid): Likewise.
10495 * top.c: Include "job_control.h".
10496 * utils.c: Likewise.
10497 (job_control): Moved to "job-control.c".
10498
10499 2017-06-07 Pedro Alves <palves@redhat.com>
10500
10501 * Makefile.in (SFILES): Add gdb_regex.c.
10502 (COMMON_OBS): Add gdb_regex.o.
10503 * ada-lang.c (ada_add_standard_exceptions)
10504 (ada_add_exceptions_from_frame, name_matches_regex)
10505 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
10506 parameter type to compiled_regex. Adjust.
10507 (ada_exceptions_list): Use compiled_regex.
10508 * break-catch-throw.c (exception_catchpoint::pattern): Now a
10509 std::unique_ptr<compiled_regex>.
10510 (exception_catchpoint::~exception_catchpoint): Remove regfree
10511 call.
10512 (check_status_exception_catchpoint): Adjust to use compiled_regex.
10513 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
10514 * breakpoint.c (solib_catchpoint::compiled): Now a
10515 std::unique_ptr<compiled_regex>.
10516 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
10517 (check_status_catch_solib): Adjust to use compiled_regex.
10518 (add_solib_catchpoint): Adjust to use compiled_regex.
10519 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
10520 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
10521 compiled_regex reference. Adjust to use it.
10522 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
10523 declaration. Include "gdb_regex.h".
10524 (apropos_cmd): Change regex parameter to compiled_regex reference.
10525 * gdb_regex.c: New file.
10526 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
10527 declarations.
10528 (class compiled_regex): New.
10529 * linux-tdep.c: Include "common/gdb_optional.h".
10530 (struct mapping_regexes): New, factored out from
10531 mapping_is_anonymous_p, and adjusted to use compiled_regex.
10532 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
10533 gdb::optional and remove cleanups. Adjust to compiled_regex.
10534 * probe.c: Include "common/gdb_optional.h".
10535 (collect_probes): Use compiled_regex and gdb::optional and remove
10536 cleanups.
10537 * skip.c: Include "common/gdb_optional.h".
10538 (skiplist_entry::compiled_function_regexp): Now a
10539 gdb::optional<compiled_regex>.
10540 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
10541 (free_skiplist_entry): Remove regfree call.
10542 (compile_skip_regexp, skip_rfunction_p): Adjust to use
10543 compiled_regex and gdb::optional.
10544 * symtab.c: Include "common/gdb_optional.h".
10545 (search_symbols): Use compiled_regex and gdb::optional.
10546 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
10547 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
10548 to gdb_regex.c.
10549
10550 2017-06-07 Alan Hayward <alan.hayward@arm.com>
10551
10552 * regcache.c (regcache::save): Avoid buffer use.
10553 (regcache::dump): Likewise.
10554
10555 2017-06-07 Alan Hayward <alan.hayward@arm.com>
10556
10557 * sh-tdep.c (sh_pseudo_register_read): Remove
10558 MAX_REGISTER_SIZE.
10559 (sh_pseudo_register_write): Likewise.
10560 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
10561 (sh64_pseudo_register_write): Likewise
10562
10563 2017-06-07 Alan Hayward <alan.hayward@arm.com>
10564
10565 * aarch64-tdep.c (aarch64_store_return_value): Use
10566 V_REGISTER_SIZE.
10567 (aarch64_pseudo_read_value): Likewise.
10568 (aarch64_pseudo_write): Likewise.
10569
10570 2017-06-06 Yao Qi <yao.qi@linaro.org>
10571
10572 * regformats/regdef.h (set_register_cache): Remove the
10573 declaration.
10574
10575 2017-06-06 Alan Hayward <alan.hayward@arm.com>
10576
10577 * frame.c (frame_unwind_register_signed): Use
10578 frame_unwind_register_value.
10579
10580 2017-06-06 Pedro Alves <palves@redhat.com>
10581
10582 PR breakpoints/21553
10583 * breakpoint.c (create_breakpoints_sal_default)
10584 (init_breakpoint_sal, create_breakpoint_sal): Use
10585 gdb::unique_xmalloc_ptr for string parameters.
10586 (create_breakpoint): Constify 'extra_string' and 'cond_string'
10587 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
10588 (base_breakpoint_create_breakpoints_sal)
10589 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
10590 (strace_marker_create_breakpoints_sal)
10591 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
10592 string parameters.
10593 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
10594 gdb::unique_xmalloc_ptr for string parameters.
10595 (create_breakpoint): Constify 'extra_string' and 'cond_string'
10596 parameters.
10597
10598 2017-06-06 Alan Hayward <alan.hayward@arm.com>
10599
10600 * alpha-tdep.c (alpha_register_to_value): Use
10601 get_frame_register_value.
10602 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
10603
10604 2017-06-06 Alan Hayward <alan.hayward@arm.com>
10605
10606 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
10607 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
10608 (ia64_value_to_register): Likewise.
10609 (ia64_extract_return_value): Likewise.
10610 (ia64_store_return_value): Likewise.
10611 (ia64_push_dummy_call): Likewise.
10612
10613 2017-06-04 Joel Brobecker <brobecker@adacore.com>
10614
10615 GDB 8.0 released.
10616
10617 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
10618
10619 * x86-linux-nat.c (struct arch_lwp_info): Remove.
10620
10621 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
10622
10623 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
10624 parameter.
10625 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
10626
10627 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
10628
10629 * event-loop.c (poll_timers): Unallocate timer using delete
10630 instead of xfree.
10631
10632 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
10633
10634 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
10635 (struct breakpoint) <~breakpoint>: New.
10636 (struct watchpoint): Inherit from breakpoint.
10637 <~watchpoint>: New.
10638 <base>: Remove.
10639 (struct tracepoint): Inherit from breakpoint.
10640 <base>: Remove.
10641 * breakpoint.c (longjmp_breakpoint_ops): Remove.
10642 (struct longjmp_breakpoint): Inherit from breakpoint.
10643 <~longjmp_breakpoint>: New.
10644 <base>: Remove.
10645 (new_breakpoint_from_type): Remove casts.
10646 (watchpoint_in_thread_scope): Remove reference to base field.
10647 (watchpoint_del_at_next_stop): Likewise.
10648 (update_watchpoint): Likewise.
10649 (watchpoint_check): Likewise.
10650 (bpstat_check_watchpoint): Likewise.
10651 (set_longjmp_breakpoint): Likewise.
10652 (struct fork_catchpoint): Inherit from breakpoint.
10653 <base>: Remove.
10654 (struct solib_catchpoint): Inherit from breakpoint.
10655 <~solib_catchpoint>: New.
10656 <base>: Remove.
10657 (dtor_catch_solib): Change to ...
10658 (solib_catchpoint::~solib_catchpoint): ... this.
10659 (breakpoint_hit_catch_solib): Remove reference to base field.
10660 (add_solib_catchpoint): Likewise.
10661 (create_fork_vfork_event_catchpoint): Likewise.
10662 (struct exec_catchpoint): Inherit from breakpoint.
10663 <~exec_catchpoint>: New.
10664 <base>: Remove.
10665 (dtor_catch_exec): Change to ...
10666 (exec_catchpoint::~exec_catchpoint): ... this.
10667 (dtor_watchpoint): Change to ...
10668 (watchpoint::~watchpoint): ... this.
10669 (watch_command_1): Remove reference to base field.
10670 (catch_exec_command_1): Likewise.
10671 (base_breakpoint_dtor): Change to ...
10672 (breakpoint::~breakpoint): ... this.
10673 (base_breakpoint_ops): Remove dtor field value.
10674 (longjmp_bkpt_dtor): Change to ...
10675 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
10676 (strace_marker_create_breakpoints_sal): Remove reference to base
10677 field.
10678 (delete_breakpoint): Don't manually call breakpoint destructor.
10679 (create_tracepoint_from_upload): Remove reference to base field.
10680 (trace_pass_set_count): Likewise.
10681 (initialize_breakpoint_ops): Don't initialize
10682 momentary_breakpoint_ops, don't set dtors.
10683 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
10684 <~ada_catchpoint>: New.
10685 <base>: Remove.
10686 (create_excep_cond_exprs): Remove reference to base field.
10687 (dtor_exception): Change to ...
10688 (ada_catchpoint::~ada_catchpoint): ... this.
10689 (dtor_catch_exception): Remove.
10690 (dtor_catch_exception_unhandled): Remove.
10691 (dtor_catch_assert): Remove.
10692 (create_ada_exception_catchpoint): Remove reference to base
10693 field.
10694 (initialize_ada_catchpoint_ops): Don't set dtors.
10695 * break-catch-sig.c (struct signal_catchpoint): Inherit from
10696 breakpoint.
10697 <~signal_catchpoint>: New.
10698 <base>: Remove.
10699 (signal_catchpoint_dtor): Change to ...
10700 (signal_catchpoint::~signal_catchpoint): ... this.
10701 (create_signal_catchpoint): Remove reference to base field.
10702 (initialize_signal_catchpoint_ops): Don't set dtor.
10703 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
10704 from breakpoint.
10705 <~syscall_catchpoint>: New.
10706 <base>: Remove.
10707 (dtor_catch_syscall): Change to ...
10708 (syscall_catchpoint::~syscall_catchpoint): ... this.
10709 (create_syscall_event_catchpoint): Remove reference to base
10710 field.
10711 (initialize_syscall_catchpoint_ops): Don't set dtor.
10712 * break-catch-throw.c (struct exception_catchpoint): Inherit
10713 from breakpoint.
10714 <~exception_catchpoint>: New.
10715 <base>: Remove.
10716 (dtor_exception_catchpoint): Change to ...
10717 (exception_catchpoint::~exception_catchpoint): ... this.
10718 (handle_gnu_v3_exceptions): Remove reference to base field.
10719 (initialize_throw_catchpoint_ops): Don't set dtor.
10720 * ctf.c (ctf_get_traceframe_address): Remove reference to base
10721 field.
10722 * remote.c (remote_get_tracepoint_status): Likewise.
10723 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
10724 * tracefile.c (tracefile_fetch_registers): Likewise.
10725 * tracepoint.c (actions_command): Likewise.
10726 (validate_actionline): Likewise.
10727 (tfind_1): Likewise.
10728 (get_traceframe_location): Likewise.
10729 (find_matching_tracepoint_location): Likewise.
10730 (parse_tracepoint_status): Likewise.
10731 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
10732
10733 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
10734
10735 * breakpoint.c (struct longjmp_breakpoint): New struct.
10736 (is_tracepoint_type): Change return type to bool.
10737 (is_longjmp_type): New function.
10738 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
10739 (set_raw_breakpoint_without_location): Use
10740 new_breakpoint_from_type.
10741 (set_raw_breakpoint): Likewise.
10742
10743 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
10744
10745 * breakpoint.c (new_breakpoint_from_type): New function.
10746 (create_breakpoint_sal): Use new_breakpoint_from_type and
10747 unique_ptr.
10748 (create_breakpoint): Likewise.
10749
10750 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
10751
10752 * memattr.c (mem_info_command): Rename to ...
10753 (info_mem_command): ... this.
10754 (mem_enable_command): Rename to ...
10755 (enable_mem_command): ... this.
10756 (mem_disable_command): Rename to ...
10757 (disable_mem_command): ... this.
10758 (mem_delete_command): Rename to ...
10759 (delete_mem_command): ... this.
10760 (_initialize_mem): Adjust function names.
10761
10762 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
10763
10764 * btrace.c (handle_pt_insn_events): New.
10765 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
10766 STATUS. Split into this and ...
10767 (handle_pt_insn_event_flags): ... this.
10768
10769 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
10770
10771 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
10772 and struct pt_insn.resynced.
10773 * configure: Regenerated.
10774 * config.in: Regenerated.
10775
10776 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10777
10778 * btrace.c (ftrace_find_call_by_number): New function.
10779 (ftrace_new_function): Store objects, not pointers.
10780 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
10781 ftrace_new_gap, ftrace_update_function,
10782 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
10783 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
10784 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
10785 btrace_ends_with_single_insn, btrace_call_get): Account for
10786 btrace_thread_info::functions now storing objects.
10787 * btrace.h (struct btrace_thread_info): Add constructor.
10788 (struct btrace_thread_info) <functions>: Make std::vector.
10789 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
10790 Initialize with default values.
10791 * record-btrace.c (record_btrace_frame_sniffer): Account for
10792 btrace_thread_info::functions now storing objects.
10793
10794 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10795
10796 * btrace.c: Remove typedef bfun_s.
10797 (ftrace_new_gap): Directly add gaps to the list of gaps.
10798 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
10799 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
10800 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
10801 instead of gdb VEC.
10802
10803 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10804
10805 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
10806 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
10807 with btrace_thread_info::next_segment and
10808 btrace_thread_info::prev_segment.
10809 * btrace.h: Remove struct btrace_func_link.
10810 (struct btrace_function): Replace pair of function segment pointers
10811 with pair of indices.
10812 * python/py-record-btrace.c (btpy_call_prev_sibling,
10813 btpy_call_next_sibling): Replace references to
10814 btrace_thread_info::segment with btrace_thread_info::next_segment and
10815 btrace_thread_info::prev_segment.
10816 * record-btrace.c (record_btrace_frame_this_id): Use
10817 btrace_find_call_by_number.
10818
10819 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10820
10821 * btrace.c (ftrace_new_function, ftrace_fixup_level,
10822 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
10823 btrace_insn_next, btrace_insn_prev): Remove references to
10824 btrace_thread_info::flow.
10825 * btrace.h (struct btrace_function): Remove FLOW.
10826
10827 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10828
10829 * btrace.c (ftrace_find_call_by_number): New function.
10830 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
10831 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
10832 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
10833 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
10834 index.
10835 * btrace.h (struct btrace_function): Turn UP into an index.
10836 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
10837 as an index.
10838 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
10839 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
10840 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
10841
10842 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10843
10844 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
10845 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
10846 ftrace_update_function, ftrace_compute_global_level_offset,
10847 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
10848 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
10849 btrace_insn_end, btrace_is_empty): Remove references to
10850 btrace_thread_info::begin and btrace_thread_info::end.
10851 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
10852 (struct btrace_thread_info) <functions>: Adjust comment.
10853 * record-btrace.c (record_btrace_start_replaying): Remove reference to
10854 btrace_thread_info::begin.
10855
10856 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10857
10858 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
10859 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
10860 ftrace_update_function): Remove arguments that implicitly were always
10861 BTINFO->END.
10862 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
10863 Don't pass BTINFO->END.
10864
10865 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10866
10867 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
10868 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
10869 btrace_find_insn_by_number): Replace function segment pointer with
10870 index.
10871 (btrace_insn_cmp): Simplify.
10872 * btrace.h: (struct btrace_insn_iterator) Rename index to
10873 insn_index. Replace function segment pointer with index into function
10874 segment vector.
10875 * record-btrace.c (record_btrace_call_history): Replace function
10876 segment pointer use with index.
10877 (record_btrace_frame_sniffer): Retrieve function call segment through
10878 vector.
10879 (record_btrace_set_replay): Remove defunc't safety check.
10880
10881 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10882
10883 * btrace.c (btrace_ends_with_single_insn): New function.
10884 (btrace_call_get, btrace_call_number, btrace_call_begin,
10885 btrace_call_end, btrace_call_next, btrace_call_prev,
10886 btrace_find_call_by_number): Use index into call segment vector
10887 instead of pointer.
10888 (btrace_call_cmp): Simplify.
10889 * btrace.h (struct btrace_call_iterator): Replace function call segment
10890 pointer with index into vector.
10891 * record-btrace.c (record_btrace_call_history): Use index instead of
10892 pointer.
10893
10894 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10895
10896 * btrace.c (btrace_insn_begin, btrace_insn_end,
10897 btrace_find_insn_by_number): Add btinfo to iterator.
10898 * btrace.h (struct btrace_insn_iterator): Add btinfo.
10899
10900 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10901
10902 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
10903 and save pointers directly.
10904 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
10905 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
10906 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
10907 changed signature of functions.
10908 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
10909 (btrace_fetch): Remove code that adds btrace_function pointers to
10910 vector of btrace_functions.
10911 (btrace_clear): Simplify freeing vector of btrace_functions.
10912
10913 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10914
10915 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
10916 Replace VEC_* with std::vector functions.
10917 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
10918 (struct btrace_thread_info)<functions>: Change type to std::vector.
10919
10920 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
10921
10922 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
10923 "Removed targets and native configurations" up. Merge duplicate
10924 "New commands" sub-sections. Add "New options" sub-sections.
10925
10926 2017-05-26 Alan Hayward <alan.hayward@arm.com>
10927
10928 * defs.h (copy_integer_to_size): New declaration.
10929 * findvar.c (copy_integer_to_size): New function.
10930 (do_cint_test): New selftest function.
10931 (copy_integer_to_size_test): Likewise.
10932 (_initialize_findvar): Likewise.
10933 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
10934 (mips_fbsd_collect_reg): Use raw_collect_integer.
10935 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
10936 (mips64_fill_gregset): Use raw_collect_integer
10937 (mips64_fill_fpregset): Use raw_supply_integer.
10938 * regcache.c (regcache::raw_supply_integer): New function.
10939 (regcache::raw_collect_integer): Likewise.
10940 * regcache.h: (regcache::raw_supply_integer): New declaration.
10941 (regcache::raw_collect_integer): Likewise.
10942
10943 2017-05-24 Yao Qi <yao.qi@linaro.org>
10944
10945 * Makefile.in (SFILES): Add gdbarch-selftests.c.
10946 (COMMON_OBS): Add gdbarch-selftests.o.
10947 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
10948 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
10949 * gdbarch-selftests.c: New file.
10950 * regcache.h (regcache) <~regcache>: Mark it virtual if
10951 GDB_SELF_TEST.
10952 <raw_write>: Likewise.
10953
10954 2017-05-24 Yao Qi <yao.qi@linaro.org>
10955
10956 * regcache.c (current_regcache): Change it to
10957 regcache::current_regcache.
10958 (regcache_observer_target_changed): Update.
10959 (regcache_thread_ptid_changed): Make it a regcache static
10960 method.
10961 (regcache_thread_ptid_changed): Update.
10962 (class regcache_access): New.
10963 (current_regcache_test): Update.
10964 (_initialize_regcache): Update.
10965 * regcache.h: Include forward_list.
10966 (regcache): Declare regcache_thread_ptid_changed and declare
10967 registers_changed_ptid as friend.
10968
10969 2017-05-24 Yao Qi <yao.qi@linaro.org>
10970
10971 * i387-tdep.c (i387_register_to_value): Use register_size
10972 instead of TYPE_LENGTH.
10973 * m68k-tdep.c (m68k_register_to_value): Likewise.
10974
10975 2017-05-24 Yao Qi <yao.qi@linaro.org>
10976
10977 * i387-tdep.c (i387_convert_register_p): Return false if type
10978 code isn't TYPE_CODE_FLT.
10979
10980 2017-05-24 Yao Qi <yao.qi@linaro.org>
10981
10982 * alpha-tdep.c (alpha_convert_register_p): Return true if type
10983 length is 4.
10984 (alpha_register_to_value): Remove type length check.
10985 (alpha_value_to_register): Likewise.
10986
10987 2017-05-24 Yao Qi <yao.qi@linaro.org>
10988
10989 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
10990 TYPE_CODE_FLT.
10991
10992 2017-05-24 Yao Qi <yao.qi@linaro.org>
10993
10994 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
10995 TYPE_CODE_FLT or not.
10996
10997 2017-05-24 Yao Qi <yao.qi@linaro.org>
10998
10999 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
11000 * avr-tdep.c (avr_gdbarch_init): Likewise.
11001 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
11002 * cris-tdep.c (cris_gdbarch_init): Likewise.
11003 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
11004 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
11005 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11006 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
11007 * mep-tdep.c (mep_gdbarch_init): Likewise.
11008 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
11009 * mips-tdep.c (mips_gdbarch_init): Likewise.
11010 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
11011 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11012 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
11013 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
11014 * v850-tdep.c (v850_gdbarch_init): Likewise.
11015
11016 2017-05-24 Yao Qi <yao.qi@linaro.org>
11017
11018 * selftest-arch.c (tests_with_arch): Call registers_changed
11019 and reinit_frame_cache.
11020 * selftest.c (run_self_tests): Likewise.
11021
11022 2017-05-24 Yao Qi <yao.qi@linaro.org>
11023
11024 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
11025 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
11026
11027 2017-05-24 Yao Qi <yao.qi@linaro.org>
11028
11029 * rl78-tdep.c (rl78_gdbarch_init): Don't call
11030 set_gdbarch_print_insn.
11031
11032 2017-05-24 Yao Qi <yao.qi@linaro.org>
11033
11034 * h8300-tdep.c (h8300_gdbarch_init): Don't call
11035 set_gdbarch_print_insn.
11036
11037 2017-05-24 Yao Qi <yao.qi@linaro.org>
11038
11039 * alpha-tdep.c (alpha_gdbarch_init): Don't call
11040 set_gdbarch_print_insn.
11041 * arc-tdep.c (arc_gdbarch_init): Likewise.
11042 * arch-utils.c: include dis-asm.h.
11043 (default_print_insn): New function.
11044 * arch-utils.h (default_print_insn): Declare.
11045 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
11046 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
11047 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
11048 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
11049 * frv-tdep.c (frv_gdbarch_init): Likewise.
11050 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
11051 * gdbarch.sh (print_insn): Use default_print_insn.
11052 * gdbarch.c: Regenerated.
11053 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
11054 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
11055 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
11056 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
11057 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11058 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
11059 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
11060 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
11061 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
11062 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
11063 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
11064 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11065 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
11066 * mt-tdep.c (mt_gdbarch_init): Likewise.
11067 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
11068 * nios2-tdep.c (nios2_print_insn): Remove.
11069 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
11070 * rx-tdep.c (rx_gdbarch_init): Likewise.
11071 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
11072 * score-tdep.c (score_print_insn): Remove.
11073 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
11074 * sh-tdep.c (sh_gdbarch_init): Likewise.
11075 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
11076 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
11077 * tic6x-tdep.c (tic6x_print_insn): Remove.
11078 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
11079 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
11080 * v850-tdep.c (v850_gdbarch_init): Likewise.
11081 * vax-tdep.c (vax_gdbarch_init): Likewise.
11082 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
11083 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
11084
11085 2017-05-23 John Baldwin <jhb@FreeBSD.org>
11086
11087 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
11088 (MIPS_FP0_REGNUM): Remove.
11089 (MIPS_FSR_REGNUM): Remove.
11090 (mips_fbsd_supply_fpregs): Use mips_regnum.
11091 (mips_fbsd_supply_gregs): Likewise.
11092 (mips_fbsd_collect_fpregs): Likewise.
11093 (mips_fbsd_collect_gregs): Likewise.
11094
11095 2017-05-23 John Baldwin <jhb@FreeBSD.org>
11096
11097 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
11098 (getpfpregs_supplies): New function.
11099 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
11100 getfpregs_supplies.
11101 (mips_fbsd_store_inferior_registers): Likewise.
11102
11103 2017-05-22 Pedro Alves <palves@redhat.com>
11104
11105 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
11106 maintainer.
11107
11108 2017-05-22 Alan Hayward <alan.hayward@arm.com>
11109
11110 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
11111 (store_register): Likewise.
11112 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
11113 (get_decimal_float_return_value): Likewise.
11114 (do_ppc_sysv_return_value): Likewise.
11115 (ppc64_sysv_abi_push_integer): Likewise.
11116 (ppc64_sysv_abi_push_freg): Likewise.
11117 (ppc64_sysv_abi_return_value_base): Likewise.
11118 (ppc64_sysv_abi_return_value): Likewise.
11119 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
11120 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
11121 * rs6000-nat.c: Likewise.
11122 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
11123 (rs6000_value_to_register): Likewise.
11124 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
11125
11126 2017-05-21 Tom Tromey <tom@tromey.com>
11127
11128 PR rust/21466:
11129 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
11130 arrays as "[T]", not "[T; ]".
11131
11132 2017-05-19 Tom Tromey <tom@tromey.com>
11133
11134 PR rust/21484:
11135 * rust-lang.c (exp_descriptor_rust): New function.
11136 (rust_language_defn): Use it.
11137 * p-lang.c (pascal_language_defn): Update.
11138 * opencl-lang.c (opencl_language_defn): Update.
11139 * objc-lang.c (objc_language_defn): Update.
11140 * m2-lang.c (m2_language_defn): Update.
11141 * language.h (struct language_defn)
11142 <la_watch_location_expression>: New member.
11143 * language.c (unknown_language_defn, auto_language_defn)
11144 (local_language_defn): Update.
11145 * go-lang.c (go_language_defn): Update.
11146 * f-lang.c (f_language_defn): Update.
11147 * d-lang.c (d_language_defn): Update.
11148 * c-lang.h (c_watch_location_expression): Declare.
11149 * c-lang.c (c_watch_location_expression): New function.
11150 (c_language_defn, cplus_language_defn, asm_language_defn)
11151 (minimal_language_defn): Use it.
11152 * breakpoint.c (watch_command_1): Call
11153 la_watch_location_expression.
11154 * ada-lang.c (ada_language_defn): Update.
11155
11156 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11157
11158 PR tui/21482
11159 * gdb_curses.h (NOMACROS): Define.
11160 (NCURSES_NOMACROS): Define.
11161
11162 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11163
11164 PR tui/21482
11165 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
11166 arg to char *.
11167 * tui/tui-wingeneral.c (box_win): Likewise.
11168 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
11169 (tui_show_source_line): Likewise.
11170 (tui_show_exec_info_content): Likewise.
11171
11172 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
11173
11174 * sparc-tdep.c (sparc_structure_return_p)
11175 (sparc_arg_on_registers_p): New functions.
11176 (sparc32_store_arguments): Use them.
11177 * sparc64-tdep.c (sparc64_16_byte_align_p)
11178 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
11179 Handle TYPE_CODE_ARRAY.
11180
11181 2017-05-17 Yao Qi <yao.qi@linaro.org>
11182
11183 * cli/cli-decode.c (add_alias_cmd): New function.
11184 * command.h (add_alias_cmd): Declare.
11185 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
11186 instead call add_alias_cmd.
11187
11188 2017-05-17 Pedro Alves <palves@redhat.com>
11189
11190 * Makefile.in (nat_extra_makefile_frag): Rename to ...
11191 (nat_makefile_frag): ... this. All references updated.
11192 * configure.ac: Likewise.
11193 * configure.nat: Likewise. Enhance comments.
11194 * configure: Regenerate.
11195
11196 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11197
11198 * procfs.c (procfs_create_inferior): Change prototype to match
11199 definition.
11200
11201 2017-05-13 Eli Zaretskii <eliz@gnu.org>
11202
11203 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
11204 C++ compiler warning.
11205
11206 2017-05-12 Tom Tromey <tom@tromey.com>
11207
11208 PR rust/21483:
11209 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
11210 recurse, just call value_struct_elt directly.
11211
11212 2017-05-12 Tom Tromey <tom@tromey.com>
11213
11214 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
11215 OP_RUST_ARRAY>: Fix.
11216
11217 2017-05-12 Tom Tromey <tom@tromey.com>
11218
11219 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
11220
11221 2017-05-09 Yao Qi <yao.qi@linaro.org>
11222
11223 * regcache.c: Include <forward_list>.
11224 (struct regcache_list): Remove.
11225 (current_regcache): Update.
11226 (get_thread_arch_aspace_regcache): Update for std::forward_list.
11227 (regcache_thread_ptid_changed): Likewise.
11228 (registers_changed_ptid): Likewise.
11229 (current_regcache_size): Likewise.
11230
11231 2017-05-09 Yao Qi <yao.qi@linaro.org>
11232
11233 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
11234 (current_regcache_size): New function.
11235 (current_regcache_test): New function.
11236 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
11237
11238 2017-05-08 Alan Hayward <alan.hayward@arm.com>
11239
11240 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
11241 (print_gp_register_row): Use get_frame_register_value.
11242
11243 2017-05-08 Alan Hayward <alan.hayward@arm.com>
11244
11245 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
11246 (mips_supply_fpregset): Likewise.
11247 (mips64_supply_gregset): Likewise.
11248
11249 2017-05-08 Alan Hayward <alan.hayward@arm.com>
11250
11251 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
11252 regcache->raw_supply_zeroed.
11253
11254 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
11255
11256 * configure.nat: Rearrange 'case' statements to match
11257 host before cpu.
11258
11259 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
11260
11261 * Makefile.in: Remove "@host_makefile_frag@". Add variables
11262 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
11263 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
11264 "@nat_extra_makefile_frag@".
11265 (Makefile): Remove dependency on "@frags@".
11266 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
11267 (data-directory/Makefile): Likewise.
11268 * config/aarch64/linux.mh: Deleted; moved contents to
11269 "gdb/configure.nat".
11270 * config/alpha/alpha-linux.mh: Likewise.
11271 * config/alpha/nbsd.mh: Likewise.
11272 * config/arm/linux.mh: Likewise.
11273 * config/arm/nbsdelf.mh: Likewise.
11274 * config/i386/cygwin.mh: Likewise.
11275 * config/i386/cygwin64.mh: Likewise.
11276 * config/i386/darwin.mh: Likewise.
11277 * config/i386/fbsd.mh: Likewise.
11278 * config/i386/fbsd64.mh: Likewise.
11279 * config/i386/go32.mh: Likewise.
11280 * config/i386/i386gnu.mh: Likewise.
11281 * config/i386/i386sol2.mh: Likewise.
11282 * config/i386/linux.mh: Likewise.
11283 * config/i386/linux64.mh: Likewise.
11284 * config/i386/mingw.mh: Likewise.
11285 * config/i386/mingw64.mh: Likewise.
11286 * config/i386/nbsd64.mh: Likewise.
11287 * config/i386/nbsdelf.mh: Likewise.
11288 * config/i386/nto.mh: Likewise.
11289 * config/i386/obsd.mh: Likewise.
11290 * config/i386/obsd64.mh: Likewise.
11291 * config/i386/sol2-64.mh: Likewise.
11292 * config/ia64/linux.mh: Likewise.
11293 * config/m32r/linux.mh: Likewise.
11294 * config/m68k/linux.mh: Likewise.
11295 * config/m68k/nbsdelf.mh: Likewise.
11296 * config/m68k/obsd.mh: Likewise.
11297 * config/m88k/obsd.mh: Likewise.
11298 * config/mips/fbsd.mh: Likewise.
11299 * config/mips/linux.mh: Likewise.
11300 * config/mips/nbsd.mh: Likewise.
11301 * config/mips/obsd64.mh: Likewise.
11302 * config/pa/linux.mh: Likewise.
11303 * config/pa/nbsd.mh: Likewise.
11304 * config/pa/obsd.mh: Likewise.
11305 * config/powerpc/aix.mh: Likewise.
11306 * config/powerpc/fbsd.mh: Likewise.
11307 * config/powerpc/linux.mh: Likewise.
11308 * config/powerpc/nbsd.mh: Likewise.
11309 * config/powerpc/obsd.mh: Likewise.
11310 * config/powerpc/ppc64-linux.mh: Likewise.
11311 * config/powerpc/spu-linux.mh: Likewise.
11312 * config/s390/linux.mh: Likewise.
11313 * config/sh/nbsd.mh: Likewise.
11314 * config/sparc/fbsd.mh: Likewise.
11315 * config/sparc/linux.mh: Likewise.
11316 * config/sparc/linux64.mh: Likewise.
11317 * config/sparc/nbsd64.mh: Likewise.
11318 * config/sparc/nbsdelf.mh: Likewise.
11319 * config/sparc/obsd64.mh: Likewise.
11320 * config/sparc/sol2.mh: Likewise.
11321 * config/tilegx/linux.mh: Likewise.
11322 * config/vax/nbsdelf.mh: Likewise.
11323 * config/vax/obsd.mh: Likewise.
11324 * config/xtensa/linux.mh: Likewise.
11325 * config/i386/i386gnu.mn: New file, with excerpts from
11326 "config/i386/i386gnu.mh".
11327 * configure: Regenerate.
11328 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
11329 *.mh files under "gdb/config".
11330 * configure.nat: New file, with contents from the
11331 "gdb/config/*/*.mh" files.
11332
11333 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
11334
11335 * btrace.c (btrace_clear): Free insn vector.
11336
11337 2017-05-05 Pedro Alves <palves@redhat.com>
11338
11339 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
11340 * configure: Regenerate.
11341
11342 2017-05-04 Pedro Alves <palves@redhat.com>
11343
11344 * Makefile.in (SFILES): Add progspace-and-thread.c.
11345 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
11346 (COMMON_OBS): Add progspace-and-thread.o.
11347 * breakpoint.c: Include "progspace-and-thread.h".
11348 (update_inserted_breakpoint_locations)
11349 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
11350 Use scoped_restore_current_pspace_and_thread.
11351 (create_std_terminate_master_breakpoint): Use
11352 scoped_restore_current_program_space.
11353 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
11354 (print_breakpoint_location): Use
11355 scoped_restore_current_program_space.
11356 (bp_loc_is_permanent): Use
11357 scoped_restore_current_pspace_and_thread.
11358 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
11359 (download_tracepoint_locations): Use
11360 scoped_restore_current_pspace_and_thread.
11361 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
11362 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
11363 (enum step_over_calls_kind): Moved from inferior.h.
11364 (class scoped_restore_current_thread): New class.
11365 * gdbthread.h (make_cleanup_restore_current_thread): Delete
11366 declaration.
11367 (scoped_restore_current_thread): New class.
11368 * infcmd.c: Include "common/gdb_optional.h".
11369 (continue_1, proceed_after_attach): Use
11370 scoped_restore_current_thread.
11371 (notice_new_inferior): Use scoped_restore_current_thread.
11372 * inferior.c: Include "progspace-and-thread.h".
11373 (restore_inferior, save_current_inferior): Delete.
11374 (add_inferior_command, clone_inferior_command): Use
11375 scoped_restore_current_pspace_and_thread.
11376 * inferior.h (scoped_restore_current_inferior): New class.
11377 * infrun.c: Include "progspace-and-thread.h" and
11378 "common/gdb_optional.h".
11379 (follow_fork_inferior): Use
11380 scoped_restore_current_pspace_and_thread.
11381 (scoped_restore_exited_inferior): New class.
11382 (handle_vfork_child_exec_or_exit): Use
11383 scoped_restore_exited_inferior,
11384 scoped_restore_current_pspace_and_thread,
11385 scoped_restore_current_thread and scoped_restore.
11386 (fetch_inferior_event): Use scoped_restore_current_thread.
11387 * linespec.c (decode_line_full, decode_line_1): Use
11388 scoped_restore_current_program_space.
11389 * mi/mi-main.c: Include "progspace-and-thread.h".
11390 (exec_continue): Use scoped_restore_current_thread.
11391 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
11392 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
11393 * proc-service.c (ps_pglobal_lookup): Use
11394 scoped_restore_current_program_space.
11395 * progspace-and-thread.c: New file.
11396 * progspace-and-thread.h: New file.
11397 * progspace.c (release_program_space, clone_program_space): Use
11398 scoped_restore_current_program_space.
11399 (restore_program_space, save_current_program_space)
11400 (save_current_space_and_thread): Delete.
11401 (switch_to_program_space_and_thread): Moved to
11402 progspace-and-thread.c.
11403 * progspace.h (save_current_program_space)
11404 (save_current_space_and_thread): Delete declarations.
11405 (scoped_restore_current_program_space): New class.
11406 * remote.c (remote_btrace_maybe_reopen): Use
11407 scoped_restore_current_thread.
11408 * symtab.c: Include "progspace-and-thread.h".
11409 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
11410 * thread.c (print_thread_info_1): Use
11411 scoped_restore_current_thread.
11412 (struct current_thread_cleanup): Delete.
11413 (do_restore_current_thread_cleanup)
11414 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
11415 (scoped_restore_current_thread::~scoped_restore_current_thread):
11416 ... this new dtor.
11417 (make_cleanup_restore_current_thread): Rename/convert to ...
11418 (scoped_restore_current_thread::scoped_restore_current_thread):
11419 ... this new ctor.
11420 (thread_apply_all_command): Use scoped_restore_current_thread.
11421 (thread_apply_command): Use scoped_restore_current_thread.
11422 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
11423 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
11424
11425 2017-05-04 Pedro Alves <palves@redhat.com>
11426
11427 * thread.c (make_cleanup_restore_current_thread): Move
11428 find_thread_ptid call before the is_stopped call. Assert that the
11429 thread is found. Replace is_stopped call by checking the thread's
11430 state directly. Remove unnecessary NULL-thread check.
11431
11432 2017-05-04 Pedro Alves <palves@redhat.com>
11433
11434 * corelow.c (thread_section_name): New class.
11435 (get_core_register_section, get_core_siginfo): Use it.
11436
11437 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
11438
11439 * corelow.c (sniff_core_bfd): Remove extra semicolon.
11440 (get_core_register_section): Remove xfree of NULL pointer.
11441
11442 2017-05-03 Alan Hayward <alan.hayward@arm.com>
11443
11444 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
11445 * regcache.c (regcache::raw_supply_zeroed): New function.
11446 * regcache.h (regcache::raw_supply_zeroed): New declaration.
11447
11448 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
11449
11450 * gdbarch.sh: Remove commented out definition of
11451 TARGET_CHAR_BIT.
11452 * gdbarch.h: Re-generate.
11453
11454 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
11455
11456 * configure: Regenerate.
11457
11458 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
11459
11460 * solib-target.c (solib_target_relocate_section_addresses):
11461 Remove num_section_bases, num_bases, segment_bases variables.
11462
11463 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11464
11465 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
11466
11467 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11468
11469 * solib-target.c: Include <vector>
11470 (struct lm_info_target) <~lm_info_target>: Remove.
11471 <segment_bases, section_bases>: Change type to
11472 std::vector<CORE_ADDR>.
11473 (library_list_start_segment, library_list_start_section,
11474 library_list_end_library,
11475 solib_target_relocate_section_addresses): Adjust.
11476
11477 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11478
11479 * gdbarch.sh (software_single_step): Change return type to
11480 std::vector<CORE_ADDR>.
11481 * gdbarch.c, gdbarch.h: Re-generate.
11482 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
11483 Adjust.
11484 (arm_deal_with_atomic_sequence_raw): Adjust.
11485 (thumb_get_next_pcs_raw): Adjust.
11486 (arm_get_next_pcs_raw): Adjust.
11487 (arm_get_next_pcs): Adjust.
11488 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
11489 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
11490 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
11491 (alpha_software_single_step): Adjust.
11492 * alpha-tdep.h (alpha_software_single_step): Adjust.
11493 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
11494 * arm-tdep.c (arm_software_single_step): Adjust.
11495 (arm_breakpoint_kind_from_current_state): Adjust.
11496 * arm-tdep.h (arm_software_single_step): Adjust.
11497 * breakpoint.c (insert_single_step_breakpoint): Adjust.
11498 * cris-tdep.c (cris_software_single_step): Adjust.
11499 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
11500 (micromips_deal_with_atomic_sequence): Adjust.
11501 (deal_with_atomic_sequence): Adjust.
11502 (mips_software_single_step): Adjust.
11503 * mips-tdep.h (mips_software_single_step): Adjust.
11504 * moxie-tdep.c (moxie_software_single_step): Adjust.
11505 * nios2-tdep.c (nios2_software_single_step): Adjust.
11506 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
11507 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
11508 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
11509 * s390-linux-tdep.c (s390_software_single_step): Adjust.
11510 * sparc-tdep.c (sparc_software_single_step): Adjust.
11511 * spu-tdep.c (spu_software_single_step): Adjust.
11512 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
11513
11514 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11515
11516 * gdbarch.sh: Use semi-colon as field separator instead of colon.
11517 * gdbarch.h: Re-generate.
11518
11519 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11520
11521 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
11522 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
11523 * python/py-instruction.c, python/py-instruction.h: New file.
11524 * python/py-record.c: Add py-instruction.h include.
11525 (gdbpy_initialize_record): Make gdb.Instruction a super class of
11526 gdb.RecordInstruction.
11527 * python/python-internal.h: Add gdbpy_initialize_instruction
11528 declaration.
11529 * python/python.c (do_start_initialization): Add
11530 gdbpy_initialize_instruction.
11531
11532 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11533
11534 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
11535 Remove.
11536 (btrace_func_from_recpy_func): New function.
11537 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
11538 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
11539 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
11540 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
11541 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
11542 Also, use new helper functions.
11543 (btpy_list_item): Use new helper functions.
11544 (recpy_bt_function_call_history): Use new type name.
11545 (btpy_call_getset): Remove.
11546 (gdbpy_initialize_btrace): Remove code to initialize
11547 gdb.BtraceFunctionCall.
11548 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
11549 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
11550 recpy_bt_func_prev, recpy_bt_func_next): New export.
11551 * python/py-record.c (recpy_func_type): New static object.
11552 (recpy_func_new, recpy_func_level, recpy_func_symbol,
11553 recpy_func_instructions, recpy_func_up, recpy_func_prev,
11554 recpy_func_next): New function.
11555 (recpy_element_hash, recpy_element_richcompare): Updated comment.
11556 (recpy_func_getset): New static object.
11557 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
11558 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
11559
11560 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11561
11562 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
11563 (btpy_object, btpy_insn_type, btpy_new): Remove.
11564 (btpy_list_object): Use gdb.RecordInstruction type instead of
11565 gdb.BtraceInstruction type.
11566 (btrace_insn_from_recpy_insn): New function.
11567 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
11568 btpy_new.
11569 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
11570 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
11571 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
11572 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
11573 instead of btpy_object.
11574 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
11575 btpy_insn_data, btpy_insn_decode): Rename to ...
11576 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
11577 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
11578 recpy_bt_insn_decode): This. Also, use new helper functions.
11579 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
11580 recpy_insn_type.
11581 (btpy_insn_getset): Remove.
11582 (gdbpy_initialize_btrace): Remove code to initialize
11583 gdb.BtraceInstruction. Use recpy_element_object.
11584 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
11585 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
11586 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
11587 * python/py-record.c (recpy_insn_type): New static object.
11588 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
11589 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
11590 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
11591 New function.
11592 (recpy_insn_getset): New static object.
11593 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
11594 * python/py-record.h (recpy_element_object): New typedef.
11595 (recpy_insn_type, recpy_insn_new): New export.
11596
11597 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11598
11599 * py-record-btrace.c (btpy_insn_new): Removed.
11600 (btpy_insn_or_gap_new): New function.
11601 (btpy_insn_error): Removed.
11602 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
11603 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
11604 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
11605 btpy_insn_or_gap_new instead of btpy_insn_new.
11606 (btpy_insn_getset): Remove btpy_insn_error.
11607 * py-record.c (recpy_gap_type): New static object.
11608 (recpy_gap_object): New typedef.
11609 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
11610 recpy_gap_reason_string): New function.
11611 (recpy_gap_getset): New static object.
11612 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
11613 * py-record.h (recpy_gap_new): New export.
11614
11615 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11616
11617 * python/py-record.c (recpy_ptid): Remove.
11618 (recpy_record_getset): Remove recpy_ptid.
11619
11620 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11621
11622 * btrace.c (btrace_fetch): Set inferior_ptid.
11623 * python/py-record-btrace.c: Add "py-record.h" include.
11624 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
11625 recpy_bt_end, recpy_bt_instruction_history,
11626 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
11627 in gdb.Record object instead of current ptid.
11628 * python/py-record.c: Include new "py-record.h" file.
11629 (recpy_record_object): Moved to py-record.h.
11630 * python/py-record.h: New file.
11631
11632 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11633
11634 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
11635 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
11636 indentation.
11637
11638 2017-05-01 Joel Brobecker <brobecker@adacore.com>
11639
11640 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
11641 the past maintainers section.
11642
11643 2017-04-28 Yao Qi <yao.qi@linaro.org>
11644
11645 * infcmd.c (get_return_value): Use regcache ctor, and remove
11646 cleanup.
11647
11648 2017-04-28 Yao Qi <yao.qi@linaro.org>
11649 Pedro Alves <palves@redhat.com>
11650
11651 * regcache.c (regcache::regcache): New tag dispatch ctor.
11652 (do_cooked_read): Moved above.
11653 (regcache_dup): Use the tag dispatch ctor..
11654 * regcache.h (regcache): Declare ctor, delete copy ctor and
11655 assignment operator, remove friend regcache_dup.
11656
11657 2017-04-28 Yao Qi <yao.qi@linaro.org>
11658
11659 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
11660 call method save instead of regcache_cpy.
11661 * regcache.h (struct regcache): Make regcache_dup a friend.
11662
11663 2017-04-28 Yao Qi <yao.qi@linaro.org>
11664
11665 * regcache.c (struct regcache): Move to regcache.h
11666 (regcache::arch): New method.
11667 (regcache_get_ptid): Update.
11668 (get_regcache_arch): Call arch method.
11669 (get_regcache_aspace): Call method aspace.
11670 (register_buffer): Change it to method.
11671 (regcache_save): Change it to regcache::save.
11672 (regcache_restore): Likewise.
11673 (regcache_cpy_no_passthrough): Remove the declaration.
11674 (regcache_cpy): Call methods restore and cpy_no_passthrough.
11675 (regcache_cpy_no_passthrough): Change it to method
11676 cpy_no_passthrough.
11677 (regcache_register_status): Change it to method
11678 get_register_status.
11679 (regcache_invalidate): Change it to method invalidate.
11680 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
11681 (regcache_raw_update): Change it to method raw_update.
11682 (regcache_raw_read): Likewise.
11683 (regcache_raw_read_signed): Likewise.
11684 (regcache_raw_read_unsigned): Likewise.
11685 (regcache_raw_write_signed): Likewise.
11686 (regcache_raw_write_unsigned): Likewise.
11687 (regcache_cooked_read): Likewise.
11688 (regcache_cooked_read_value): Likewise.
11689 (regcache_cooked_read_signed): Likewise.
11690 (regcache_cooked_read_unsigned): Likewise.
11691 (regcache_cooked_write_signed): Likewise.
11692 (regcache_cooked_write_unsigned): Likewise.
11693 (regcache_raw_set_cached_value): Likewise.
11694 (regcache_raw_write): Likewise.
11695 (regcache_cooked_write): Likewise.
11696 (regcache_xfer_part): Likewise.
11697 (regcache_raw_read_part): Likewise.
11698 (regcache_raw_write_part): Likewise.
11699 (regcache_cooked_read_part): Likewise.
11700 (regcache_cooked_write_part): Likewise.
11701 (regcache_raw_supply): Likewise.
11702 (regcache_raw_collect): Likewise.
11703 (regcache_transfer_regset): Likewise.
11704 (regcache_supply_regset): Likewise.
11705 (regcache_collect_regset): Likewise.
11706 (regcache_debug_print_register): Likewise.
11707 (enum regcache_dump_what): Move it to regcache.h.
11708 (regcache_dump): Change it to method dump.
11709 * regcache.h (enum regcache_dump_what): New.
11710 (class regcache): New.
11711 * target.c (target_fetch_registers): Call method
11712 debug_print_register.
11713 (target_store_registers): Likewise.
11714
11715 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11716
11717 * windows-nat.c (struct lm_info_windows): Initialize field.
11718 (windows_make_so): Allocate lm_info_windows with new.
11719 (windows_free_so): Free lm_info_windows with delete.
11720
11721 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11722
11723 * solib-darwin.c (struct lm_info_darwin): Initialize field.
11724 (darwin_current_sos): Allocate lm_info_darwin with new, remove
11725 cleanup.
11726 (darwin_free_so): Free lm_info_darwin with delete.
11727
11728 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11729
11730 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
11731 <l_addr_p>: Change type to bool.
11732 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
11733 (svr4_free_so): Free lm_info_svr4 with delete.
11734 (svr4_copy_library_list): Replace memcpy with call to copy
11735 constructor.
11736 (library_list_start_library, svr4_default_sos): Allocate
11737 lm_info_svr4 with new.
11738
11739 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11740
11741 * solib-target.c (struct lm_info_target): Add destructor,
11742 initialize fields.
11743 <name>: Change type to std::string.
11744 (library_list_start_library): Allocate lm_info_target with new.
11745 (solib_target_free_library_list): Free lm_info_target with
11746 delete.
11747 (solib_target_current_sos): Adapt to std::string.
11748 (solib_target_free_so): Free lm_info_target with delete.
11749
11750 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11751
11752 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
11753 fields.
11754 (frv_current_sos): Allocate lm_info_frv with new.
11755 (frv_relocate_main_executable): Free lm_info_frv with delete,
11756 allocate with new.
11757 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
11758
11759 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11760
11761 * solib-frv.c (struct lm_info_frv): Fix indentation.
11762
11763 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11764
11765 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
11766 map field.
11767 (dsbt_current_sos): Allocate lm_info_dsbt with new.
11768 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
11769 and allocate with new.
11770 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
11771
11772 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11773
11774 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
11775 <filename, member_name>: Change type to std::string.
11776 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
11777 (library_list_start_library): Allocate lm_info_aix with new.
11778 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
11779 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
11780 with copy constructor.
11781
11782 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11783
11784 * solist.h (struct lm_info): Remove.
11785 (struct lm_info_base): New class.
11786 (struct so_list) <lm_info>: Change type to lm_info_base *.
11787 * nto-tdep.c (struct lm_info): Remove.
11788 (lm_addr): Adjust.
11789 * solib-aix.c (struct lm_info): Rename to ...
11790 (struct lm_info_aix): ... this. Extend lm_info_base.
11791 (lm_info_p): Rename to ...
11792 (lm_info_aix_p): ... this, and adjust.
11793 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
11794 solib_aix_parse_libraries, library_list_start_library,
11795 solib_aix_free_library_list, solib_aix_parse_libraries,
11796 solib_aix_get_library_list,
11797 solib_aix_relocate_section_addresses, solib_aix_free_so,
11798 solib_aix_get_section_offsets,
11799 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
11800 Adjust.
11801 (struct solib_aix_inferior_data) <library_list>: Adjust.
11802 * solib-darwin.c (struct lm_info): Rename to ...
11803 (struct lm_info_darwin): ... this. Extend lm_info_base.
11804 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
11805 * solib-dsbt.c (struct lm_info): Rename to ...
11806 (struct lm_info_dsbt): ... this. Extend lm_info_base.
11807 (struct dsbt_info) <main_executable_lm_info): Adjust.
11808 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
11809 dsbt_relocate_section_addresses): Adjust.
11810 * solib-frv.c (struct lm_info): Rename to ...
11811 (struct lm_info_frv): ... this. Extend lm_info_base.
11812 (main_executable_lm_info): Adjust.
11813 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
11814 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
11815 find_canonical_descriptor_in_load_object,
11816 frv_fdpic_find_canonical_descriptor): Adjust.
11817 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
11818 to lm_info_svr4.
11819 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
11820 svr4_clear_so, svr4_copy_library_list,
11821 library_list_start_library, svr4_default_sos, svr4_read_so_list,
11822 svr4_current_sos, svr4_fetch_objfile_link_map,
11823 solist_update_incremental): Adjust.
11824 * solib-svr4.h (struct lm_info_svr4): Move here from
11825 solib-svr4.c.
11826 * solib-target.c (struct lm_info): Rename to ...
11827 (struct lm_info_target): ... this. Extend lm_info_base.
11828 (lm_info_p): Rename to ...
11829 (lm_info_target_p): ... this.
11830 (solib_target_parse_libraries, library_list_start_segment,
11831 library_list_start_section, library_list_start_library,
11832 library_list_end_library, solib_target_free_library_list,
11833 solib_target_current_sos, solib_target_free_so,
11834 solib_target_relocate_section_addresses): Adjust.
11835 * windows-nat.c (struct lm_info): Rename to ...
11836 (struct lm_info_windows): ... this. Extend lm_info_base.
11837 (windows_make_so, handle_load_dll, handle_unload_dll,
11838 windows_xfer_shared_libraries): Adjust.
11839
11840 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11841
11842 * solib-darwin.c (struct darwin_so_list): Remove.
11843 (darwin_current_sos): Allocate an so_list object instead of a
11844 darwin_so_list, separately allocate an lm_info object.
11845 (darwin_free_so): Free lm_info.
11846
11847 2017-04-28 John Baldwin <jhb@FreeBSD.org>
11848
11849 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
11850 with fprintf_filtered.
11851
11852 2017-04-28 Yao Qi <yao.qi@linaro.org>
11853
11854 * regcache.c (regcache::regcache): New function.
11855 (regcache::~regcache): New function.
11856 (regcache_xmalloc_1): Remove.
11857 (regcache_xmalloc): Call new regcache.
11858 (regcache_xfree): Call delete regcache.
11859 (get_thread_arch_aspace_regcache): Call new regcache.
11860
11861 2017-04-28 Yao Qi <yao.qi@linaro.org>
11862
11863 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
11864 lwp instead of ptid_get_lwp.
11865
11866 2017-04-28 Yao Qi <yao.qi@linaro.org>
11867
11868 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
11869 lwp_info instead of getting from inferior_ptid.
11870
11871 2017-04-27 Keith Seitz <keiths@redhat.com>
11872
11873 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
11874 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
11875 (CV_CONVERSION_BADNESS): Define.
11876 (rank_one_type): Remove overly restrictive rvalue reference
11877 rank checks.
11878 Add cv-qualifier checks and subranks for type equality.
11879 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
11880 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
11881 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
11882
11883 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
11884
11885 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
11886 count when creating the object.
11887
11888 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
11889 Ulrich Weigand <uweigand@de.ibm.com>
11890
11891 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
11892 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
11893 is used in AIX.
11894 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
11895 (process_xcoff_symbol): Likewise.
11896 (scan_xcoff_symtab): Likewise.
11897
11898 2017-04-26 Alan Hayward <alan.hayward@arm.com>
11899
11900 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
11901 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
11902 (ia64_access_reg): Use get_frame_register_unsigned.
11903 (ia64_access_rse_reg): Likewise.
11904 (ia64_libunwind_frame_prev_register): Likewise.
11905
11906 2017-04-26 Jiong Wang <jiong.wang@arm.com>
11907
11908 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
11909 * gdbarch.c: Regenerated.
11910 * gdbarch.h: Regenerated.
11911 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
11912 visibility external.
11913 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
11914 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
11915 (enum cfa_how_kind): Move to ...
11916 (struct dwarf2_frame_state_reg_info): Likewise.
11917 (struct dwarf2_frame_state): Likewise.
11918 * dwarf2-frame.h: ... here.
11919 (dwarf2_frame_state_alloc_regs): New declaration.
11920 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
11921 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
11922
11923 2017-04-26 Alan Hayward <alan.hayward@arm.com>
11924
11925 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
11926 regcache_raw_read_unsigned.
11927 (xtensa_pseudo_register_write): Likewise.
11928
11929 2017-04-26 Alan Hayward <alan.hayward@arm.com>
11930
11931 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
11932 (nds32_pseudo_register_write): Likewise.
11933
11934 2017-04-25 Yao Qi <yao.qi@linaro.org>
11935
11936 * regcache.c (struct regcache) <readonly_p>: Change its type
11937 to bool.
11938 (regcache_xmalloc_1): Update parameter type and callers update.
11939
11940 2017-04-25 Yao Qi <yao.qi@linaro.org>
11941
11942 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
11943 set_gdbarch_wchar_bit.
11944 * arm-tdep.c (arm_gdbarch_init): Likewise.
11945
11946 2017-04-25 Pedro Alves <palves@redhat.com>
11947
11948 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
11949 (BothAreRelocatable, memcopy, memmove): Don't define.
11950 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
11951 macros.
11952
11953 2017-04-25 Pedro Alves <palves@redhat.com>
11954
11955 * common/common-defs.h: Include "common/poison.h".
11956 * common/function-view.h: (Not, Or, Requires): Move to traits.h
11957 and adjust.
11958 * common/poison.h: New file.
11959 * common/traits.h: Include <type_traits>.
11960 (Not, Or, Requires): New, moved from common/function-view.h.
11961
11962 2017-04-25 Pedro Alves <palves@redhat.com>
11963
11964 * breakpoint.h (struct breakpoint): In-class initialize all
11965 fields. Make boolean fields "bool".
11966 * breakpoint.c (init_raw_breakpoint_without_location): Remove
11967 memset call and initializations no longer necessary.
11968
11969 2017-04-25 Pedro Alves <palves@redhat.com>
11970
11971 * btrace.c (pt_btrace_insn_flags): Change parameter type to
11972 reference.
11973 (pt_btrace_insn): New function.
11974 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
11975
11976 2017-04-25 Pedro Alves <palves@redhat.com>
11977
11978 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
11979 "base" field and inherit from "bp_location" instead. Add
11980 non-default ctor.
11981 (allocate_location_exception): Use new non-default ctor.
11982 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
11983 (init_bp_location): Convert to ...
11984 (bp_location::bp_location): ... this new ctor, and remove memset
11985 call.
11986 (base_breakpoint_allocate_location): Use the new non-default ctor.
11987 * breakpoint.h (bp_location): Now a class. Declare default and
11988 non-default ctors. In-class initialize all members.
11989 (init_bp_location): Remove declaration.
11990
11991 2017-04-25 Pedro Alves <palves@redhat.com>
11992
11993 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
11994 assignment operator.
11995
11996 2017-04-24 Yao Qi <yao.qi@linaro.org>
11997
11998 * doublest.c (convert_doublest_to_floatformat): Call
11999 floatformat_totalsize_bytes.
12000
12001 2017-04-22 Tom Tromey <tom@tromey.com>
12002
12003 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
12004 ui_out_emit_list.
12005 * stack.c (print_frame): Use ui_out_emit_list.
12006 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
12007 ui_out_emit_list.
12008 * mi/mi-main.c (print_one_inferior)
12009 (mi_cmd_data_list_register_names)
12010 (mi_cmd_data_list_register_values, mi_cmd_list_features)
12011 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
12012 ui_out_emit_list.
12013 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
12014 (mi_output_solib_attribs): Use ui_out_emit_list,
12015 ui_out_emit_tuple.
12016 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
12017 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
12018 (mi_cmd_stack_list_args, list_args_or_locals): Use
12019 ui_out_emit_list.
12020 * disasm.c (do_assembly_only): Use ui_out_emit_list.
12021 * breakpoint.c (print_solib_event, output_thread_groups): Use
12022 ui_out_emit_list.
12023
12024 2017-04-22 Tom Tromey <tom@tromey.com>
12025
12026 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
12027 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
12028 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
12029
12030 2017-04-22 Tom Tromey <tom@tromey.com>
12031
12032 * tracepoint.c (tvariables_info_1)
12033 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
12034
12035 2017-04-22 Tom Tromey <tom@tromey.com>
12036
12037 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
12038 annotate_arg_emitter.
12039 * breakpoint.c (print_mention_watchpoint)
12040 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
12041 * annotate.h (struct annotate_arg_emitter): New.
12042
12043 2017-04-22 Tom Tromey <tom@tromey.com>
12044
12045 * record-btrace.c (record_btrace_insn_history)
12046 (record_btrace_insn_history_range, record_btrace_call_history)
12047 (record_btrace_call_history_range): Use ui_out_emit_tuple.
12048 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
12049 ui_out_emit_tuple.
12050 * stack.c (print_frame_info): Use ui_out_emit_tuple.
12051 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
12052 * skip.c (skip_info): Use ui_out_emit_tuple.
12053 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
12054 * progspace.c (print_program_space): Use ui_out_emit_tuple.
12055 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
12056 * osdata.c (info_osdata): Use ui_out_emit_tuple.
12057 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
12058 ui_out_emit_tuple.
12059 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
12060 (output_register, mi_cmd_data_read_memory)
12061 (mi_cmd_data_read_memory_bytes, mi_load_progress)
12062 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
12063 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
12064 Use ui_out_emit_tuple.
12065 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
12066 ui_out_emit_tuple.
12067 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
12068 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
12069 * linux-thread-db.c (info_auto_load_libthread_db): Use
12070 ui_out_emit_tuple.
12071 * inferior.c (print_inferior): Use ui_out_emit_tuple.
12072 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
12073 * disasm.c (do_mixed_source_and_assembly_deprecated)
12074 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
12075 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
12076 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
12077 * breakpoint.c (print_one_breakpoint_location)
12078 (print_one_breakpoint): Use ui_out_emit_tuple.
12079 * auto-load.c (print_script, info_auto_load_cmd): Use
12080 ui_out_emit_tuple.
12081 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
12082
12083 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
12084
12085 * thread.c (print_thread_info_1): Remove dead code.
12086
12087 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12088
12089 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
12090 GDB_SELF_TEST.
12091 * arm-tdep.c (selftests::arm_record_test): Likewise.
12092
12093 2017-04-21 Yao Qi <yao.qi@linaro.org>
12094
12095 * regcache.c (regcache_restore): Remove argument 2. Replace
12096 argument 3 with regcache. Get register status from
12097 src->register_status and get register contents from
12098 register_buffer (src, regnum).
12099 (regcache_cpy): Update.
12100
12101 2017-04-19 Pedro Alves <palves@redhat.com>
12102
12103 * gdbthread.h (thread): Add missing closing parenthesis in
12104 comment.
12105
12106 2017-04-19 Pedro Alves <palves@redhat.com>
12107
12108 * common/refcounted-object.h: New file.
12109 * gdbthread.h: Include "common/refcounted-object.h".
12110 (thread_info): Inherit from refcounted_object and add comments.
12111 (thread_info::incref, thread_info::decref)
12112 (thread_info::m_refcount): Delete.
12113 (thread_info::deletable): Use the refcounted_object::refcount()
12114 method.
12115 * inferior.c (current_inferior_): Add comment.
12116 (set_current_inferior): Increment/decrement refcounts.
12117 (prune_inferiors, remove_inferior_command): Skip inferiors marked
12118 not-deletable instead of comparing with the current inferior.
12119 (initialize_inferiors): Increment the initial inferior's refcount.
12120 * inferior.h (struct inferior): Forward declare.
12121 Include "common/refcounted-object.h".
12122 (current_inferior, set_current_inferior): Move declaration to
12123 before struct inferior's definition, and fix comment.
12124 (inferior): Inherit from refcounted_object. Add comments.
12125 * thread.c (switch_to_thread_no_regs): Reference the thread's
12126 inferior pointer directly instead of doing a ptid lookup.
12127 (switch_to_no_thread): New function.
12128 (switch_to_thread(thread_info *)): New function, factored out
12129 from ...
12130 (switch_to_thread(ptid_t)): ... this.
12131 (restore_current_thread): Delete.
12132 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
12133 fields, and add 'inf' field.
12134 (do_restore_current_thread_cleanup): Check whether old->inf is
12135 alive instead of looking up an inferior by ptid. Use
12136 switch_to_thread and switch_to_no_thread.
12137 (restore_current_thread_cleanup_dtor): Use old->inf directly
12138 instead of lookup up an inferior by id. Decref the inferior.
12139 Don't restore 'removable'.
12140 (make_cleanup_restore_current_thread): Same the inferior pointer
12141 in old, instead of the inferior number. Incref the inferior.
12142 Don't save/clear 'removable'.
12143
12144 2017-04-19 Pedro Alves <palves@redhat.com>
12145
12146 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12147 unittests/scoped_restore-selftests.c.
12148 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
12149 * common/scoped_restore.h (scoped_restore_base): Make "class".
12150 (scoped_restore_base::release): New public method.
12151 (scoped_restore_base::scoped_restore_base): New protected ctor.
12152 (scoped_restore_base::m_saved_var): New protected field.
12153 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
12154 scoped_restore_base base class instead of m_saved_var directly.
12155 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
12156 (scoped_restore_tmpl::scoped_restore_tmpl(const
12157 scoped_restore_tmpl<T>&)): Likewise.
12158 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
12159 method.
12160 (scoped_restore_tmpl::saved_var): New method.
12161 (scoped_restore_tmpl::m_saved_var): Delete.
12162 * inferior.h (inferior::detaching): Now a bool.
12163 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
12164 cleanup.
12165 * unittests/scoped_restore-selftests.c: New file.
12166
12167 2017-04-19 Pedro Alves <palves@redhat.com>
12168
12169 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
12170 Re-sort in alphabetic order.
12171
12172 2017-04-18 Pedro Alves <palves@redhat.com>
12173
12174 * xml-support.c (obstack_xml_printf): Delete.
12175 * xml-support.h (obstack_xml_printf): Delete.
12176
12177 2017-04-18 Pedro Alves <palves@redhat.com>
12178
12179 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
12180 vdebug, verror, body_text, start_element, end_element, name,
12181 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
12182 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
12183 is_xinclude>: Make private and add m_ prefix.
12184 (gdb_xml_parser::body_text): New method, based on ...
12185 (gdb_xml_body_text): ... this. Adjust.
12186 (gdb_xml_parser::vdebug): New method, based on ...
12187 (gdb_xml_debug): ... this. Adjust.
12188 (gdb_xml_parser::verror): New method, based on ...
12189 (gdb_xml_error): ... this. Adjust.
12190 (gdb_xml_parser::start_element): New method, based on ...
12191 (gdb_xml_start_element): ... this. Adjust.
12192 (gdb_xml_start_element_wrapper): Defer to
12193 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
12194 (gdb_xml_parser::end_element): New method, based on ...
12195 (gdb_xml_end_element_wrapper): ... this. Adjust.
12196 (gdb_xml_parser::~gdb_xml_parser): Adjust.
12197 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
12198 (gdb_xml_parser::use_dtd): New method, based on ...
12199 (gdb_xml_use_dtd): ... this. Adjust.
12200 (gdb_xml_parser::parse): New method, based on ...
12201 (gdb_xml_parse): ... this. Adjust.
12202 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
12203 (xinclude_start_include): Adjust to call the parser's name method.
12204 (xml_xinclude_default, xml_xinclude_start_doctype)
12205 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
12206 method.
12207 (xml_process_xincludes): Adjust to call parser methods.
12208 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
12209 declarations.
12210
12211 2017-04-18 Pedro Alves <palves@redhat.com>
12212
12213 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
12214 gdb::optional<std::string>.
12215 * xml-support.c: Include <string>.
12216 (scope_level::scope_level(scope_level &&))
12217 (scope_level::~scope_level): Delete.
12218 (scope_level::body): Now a std::string.
12219 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
12220 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
12221 parameter.
12222 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
12223 (xinclude_parsing_data::output): Now a std::string reference.
12224 (xinclude_start_include): Adjust.
12225 (xml_xinclude_default): Adjust.
12226 (xml_process_xincludes): Add 'output' parameter, and return bool.
12227 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
12228 and return bool.
12229 * xml-tdesc.c: Include <unordered_map> and <string>.
12230 (tdesc_xml_cache): Delete.
12231 (tdesc_xml_cache_s): Delete.
12232 (xml_cache): Now an std::unordered_map.
12233 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
12234 (target_fetch_description_xml): Change return type to
12235 gdb::optional<std::string>, and adjust.
12236 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
12237 (target_fetch_description_xml): Change return type to
12238 gdb::optional<std::string>.
12239
12240 2017-04-18 Pedro Alves <palves@redhat.com>
12241
12242 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12243 unittests/optional-selftests.c.
12244 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
12245 * unittests/optional-selftests.c: New file.
12246 * unittests/optional/assignment/1.cc: New file.
12247 * unittests/optional/assignment/2.cc: New file.
12248 * unittests/optional/assignment/3.cc: New file.
12249 * unittests/optional/assignment/4.cc: New file.
12250 * unittests/optional/assignment/5.cc: New file.
12251 * unittests/optional/assignment/6.cc: New file.
12252 * unittests/optional/assignment/7.cc: New file.
12253 * unittests/optional/cons/copy.cc: New file.
12254 * unittests/optional/cons/default.cc: New file.
12255 * unittests/optional/cons/move.cc: New file.
12256 * unittests/optional/cons/value.cc: New file.
12257 * unittests/optional/in_place.cc: New file.
12258 * unittests/optional/observers/1.cc: New file.
12259 * unittests/optional/observers/2.cc: New file.
12260
12261 2017-04-18 Pedro Alves <palves@redhat.com>
12262
12263 * common/gdb_optional.h: Include common/traits.h.
12264 (in_place_t): New type.
12265 (in_place): New constexpr variable.
12266 (optional::optional): Remove member initialization of
12267 m_instantiated.
12268 (optional::optional(in_place_t...)): New constructor.
12269 (optional::~optional): Use reset.
12270 (optional::optional(const optional&)): New.
12271 (optional::optional(const optional&&)): New.
12272 (optional::optional(T &)): New.
12273 (optional::optional(T &&)): New.
12274 (operator::operator=(const optional &)): New.
12275 (operator::operator=(optional &&)): New.
12276 (operator::operator= (const T &))
12277 (operator::operator= (T &&))
12278 (operator::emplace (Args &&... args)): Return a T&. Use reset.
12279 (operator::reset): New.
12280 (operator::m_instantiated):: Add in-class initializer.
12281 * common/traits.h: Include <type_traits>.
12282 (struct And): New types.
12283
12284 2017-04-18 Pedro Alves <palves@redhat.com>
12285
12286 * xml-support.c: Include <vector>.
12287 (scope_level::scope_level(const gdb_xml_element *))
12288 (scope_level::scope_level(scope_level&&)): New.
12289 (scope_level::~scope_level): New.
12290 (scope_level_s): Delete.
12291 (gdb_xml_parser::scopes): Now a std::vector.
12292 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
12293 Use std::vector.
12294 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
12295 scope cleanup code.
12296 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
12297 of the scopes member. Use std::vector::emplace_back.
12298
12299 2017-04-18 Pedro Alves <palves@redhat.com>
12300
12301 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
12302 a bool.
12303 (gdb_xml_end_element): Change type of first parameter.
12304 (gdb_xml_cleanup): Rename to ...
12305 (gdb_xml_parser::~gdb_xml_parser): ... this.
12306 (gdb_xml_create_parser_and_cleanup): Delete with ...
12307 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
12308 to this new ctor.
12309 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
12310 using gdb_xml_create_parser_and_cleanup.
12311 (xinclude_parsing_data): Add ctor/dtor.
12312 (xml_xinclude_cleanup): Delete.
12313 (xml_process_xincludes): Create a local xinclude_parsing_data
12314 instead of heap-allocating one. Create a local gdb_xml_parser
12315 instead of heap-allocating one with
12316 gdb_xml_create_parser_and_cleanup.
12317
12318 2017-04-18 John Baldwin <jhb@FreeBSD.org>
12319
12320 PR threads/20743
12321 * fbsd-nat.c (resume_one_thread_cb): Remove.
12322 (resume_all_threads_cb): Remove.
12323 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
12324 iterate_over_threads.
12325
12326 2017-04-17 Joel Brobecker <brobecker@adacore.com>
12327
12328 * NEWS: Create a new section for the next release branch.
12329 Rename the section of the current branch, now that it has
12330 been cut.
12331
12332 2017-04-17 Joel Brobecker <brobecker@adacore.com>
12333
12334 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
12335 * version.in: Bump version to 8.0.50.DATE-git.
12336
12337 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
12338
12339 PR gdb/21385
12340 * windows-nat.c (windows_create_inferior): Declare 'allargs'
12341 independently of the host, and fix build breakage on Cygwin.
12342
12343 2017-04-13 Pedro Alves <palves@redhat.com>
12344
12345 * inferior.c (free_inferior): Convert to ...
12346 (inferior::~inferior): ... this dtor.
12347 (inferior::inferior): New ctor, factored out from ...
12348 (add_inferior_silent): ... here. Allocate the inferior with a new
12349 expression.
12350 (delete_inferior): Call delete instead of free_inferior.
12351 * inferior.h (gdb_environ, continuation): Forward declare.
12352 (inferior): Now a class. Add in-class initialization to all
12353 members. Make boolean fields bool, except 'detaching'.
12354 (inferior::inferior): New explicit ctor.
12355 (inferior::~inferior): New.
12356
12357 2017-04-13 Pedro Alves <palves@redhat.com>
12358
12359 * inferior.c (init_inferior_list): Delete.
12360 * inferior.h (init_inferior_list): Delete.
12361
12362 2017-04-13 Pedro Alves <palves@redhat.com>
12363
12364 PR threads/13217
12365 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
12366 (top level): Call it twice, with different thread sets.
12367
12368 2017-04-13 Pedro Alves <palves@redhat.com>
12369
12370 * thread.c: Include <algorithm>.
12371 (thread_array_cleanup): Delete.
12372 (scoped_inc_dec_ref): New class.
12373 (live_threads_count): New function.
12374 (set_thread_refcount): Delete.
12375 (tp_array_compar_ascending): Now a bool.
12376 (tp_array_compar): Convert to a std::sort comparison function.
12377 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
12378 and live_threads_count.
12379
12380 2017-04-13 Pedro Alves <palves@redhat.com>
12381
12382 * infrun.c (follow_fork_inferior): Also switch the current
12383 inferior.
12384
12385 2017-04-13 Pedro Alves <palves@redhat.com>
12386
12387 * breakpoint.c (watch_command_1): Save watchpoint-frame info
12388 before calling create_internal_breakpoint.
12389
12390 2017-04-13 Pedro Alves <palves@redhat.com>
12391
12392 * fork-child.c (execv_argv): New class.
12393 (breakup_args): Refactored as ...
12394 (execv_argv::init_for_no_shell): .. this method of execv_argv.
12395 Copy arguments to storage and replace separators with NULL
12396 terminators in place.
12397 (escape_bang_in_quoted_argument): Adjust to return bool.
12398 (execv_argv::execv_argv): New ctor.
12399 (execv_argv::init_for_shell): New method, factored out from
12400 fork_inferior. Don't strdup strings into the vector.
12401 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
12402 Remove free_vector_argv call.
12403
12404 2017-04-13 Yao Qi <yao.qi@linaro.org>
12405
12406 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
12407 tdep->rx_psw_type.
12408
12409 2017-04-13 Yao Qi <yao.qi@linaro.org>
12410
12411 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
12412 * rx-tdep.c (rx_gdbarch_init): Likewise.
12413
12414 2017-04-13 Pedro Alves <palves@redhat.com>
12415
12416 * breakpoint.h (struct breakpoint): Reindent.
12417
12418 2017-04-13 Pedro Alves <palves@redhat.com>
12419
12420 * breakpoint.c (bp_location): Rename to ...
12421 (bp_locations): ... this. All references updated.
12422 (bp_location_count): Rename to ...
12423 (bp_locations_count): ... this. All references updated.
12424 (bp_location_placed_address_before_address_max): Rename to ...
12425 (bp_locations_placed_address_before_address_max): ... this. All
12426 references updated.
12427 (bp_location_shadow_len_after_address_max): Rename to ...
12428 (bp_locations_shadow_len_after_address_max): ... this. All
12429 references updated.
12430 (bp_location_compare_addrs): Rename to ...
12431 (bp_locations_compare_addrs): ... this. All references updated.
12432 (bp_location_compare):Rename to ...
12433 (bp_locations_compare): ... this. All references updated.
12434 (bp_location_target_extensions_update): Rename to ...
12435 (bp_locations_target_extensions_update): ... this. All references
12436 updated.
12437
12438 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
12439
12440 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
12441 * common/common.m4: Check headers 'termios.h', 'termio.h' and
12442 'sgtty.h'.
12443 * common/gdb_termios.h: New file, with parts of "terminal.h".
12444 * inflow.c: Include "gdb_termios.h".
12445 * ser-unix.c: Include "gdb_termios.h".
12446 * terminal.h: Move terminal-related defines to
12447 "common/gdb_termios.h".
12448
12449 2017-04-12 Tom Tromey <tom@tromey.com>
12450
12451 * probe.c (parse_probes): Update.
12452 * location.h (delete_event_location): Don't declare.
12453 (event_location_deleter::operator()): Update.
12454 * location.c (event_location_deleter::operator()): Rename from
12455 delete_event_location.
12456 * linespec.h (linespec_result) <location>: Change type to
12457 event_location_up.
12458 * linespec.c (canonicalize_linespec, event_location_to_sals)
12459 (decode_objc): Update.
12460 (linespec_result): Don't call delete_event_location.
12461 * breakpoint.c (create_breakpoints_sal)
12462 (bkpt_probe_create_sals_from_location)
12463 (strace_marker_create_sals_from_location): Update.
12464
12465 2017-04-12 Tom Tromey <tom@tromey.com>
12466
12467 * linespec.h (struct linespec_result): Add constructor and
12468 destructor.
12469 (init_linespec_result, destroy_linespec_result)
12470 (make_cleanup_destroy_linespec_result): Don't declare.
12471 * linespec.c (init_linespec_result): Remove.
12472 (linespec_result::~linespec_result): Rename from
12473 destroy_linespec_result. Update.
12474 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
12475 Remove.
12476 * breakpoint.c (create_breakpoint, break_range_command)
12477 (decode_location_default): Update.
12478 * ax-gdb.c (agent_command_1): Update.
12479
12480 2017-04-12 Tom Tromey <tom@tromey.com>
12481
12482 * remote.c (remote_download_tracepoint): Update.
12483 * python/py-breakpoint.c (bppy_get_location): Update.
12484 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
12485 (gdbscm_breakpoint_location): Update.
12486 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
12487 * breakpoint.h (struct breakpoint) <location, location_range_end>:
12488 Change type to event_location_up.
12489 * breakpoint.c (create_overlay_event_breakpoint)
12490 (create_longjmp_master_breakpoint)
12491 (create_std_terminate_master_breakpoint)
12492 (create_exception_master_breakpoint)
12493 (breakpoint_event_location_empty_p, print_breakpoint_location)
12494 (print_one_breakpoint_location, create_thread_event_breakpoint)
12495 (init_breakpoint_sal, create_breakpoint)
12496 (print_recreate_ranged_breakpoint, break_range_command)
12497 (init_ada_exception_breakpoint, say_where): Update.
12498 (base_breakpoint_dtor): Don't call delete_event_location.
12499 (bkpt_print_recreate, tracepoint_print_recreate)
12500 (dprintf_print_recreate, update_static_tracepoint)
12501 (breakpoint_re_set_default): Update.
12502
12503 2017-04-12 Tom Tromey <tom@tromey.com>
12504
12505 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
12506 type of "to_do". Update.
12507 (compute_stack_depth): Use std::vector.
12508
12509 2017-04-12 Tom Tromey <tom@tromey.com>
12510
12511 * printcmd.c (find_instruction_backward): Use std::vector.
12512
12513 2017-04-12 Tom Tromey <tom@tromey.com>
12514
12515 * symfile.c (objfilep): Remove typedef.
12516 (reread_symbols): Use a std::vector.
12517
12518 2017-04-12 Tom Tromey <tom@tromey.com>
12519
12520 * mi/mi-main.c (exec_direction_forward): Remove.
12521 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
12522 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
12523 scoped_restore.
12524 * guile/guile.c (guile_repl_command, guile_command)
12525 (gdbscm_execute_gdb_command): Use scoped_restore.
12526 * go-exp.y (go_parse): Use scoped_restore.
12527 * d-exp.y (d_parse): Use scoped_restore.
12528 * cli/cli-decode.c (cmd_func): Use scoped_restore.
12529 * c-exp.y (c_parse): Use scoped_restore.
12530
12531 2017-04-12 Tom Tromey <tom@tromey.com>
12532
12533 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
12534 (mi_parse): Update return type.
12535 (mi_parse_free): Remove.
12536 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
12537 (mi_parse::~mi_parse): Rename from mi_parse_free.
12538 (mi_parse_cleanup): Remove.
12539 (mi_parse): Return a unique_ptr. Use new.
12540 * mi/mi-main.c (mi_execute_command): Update.
12541
12542 2017-04-12 Tom Tromey <tom@tromey.com>
12543
12544 * location.c (explicit_location_lex_one): Return a
12545 unique_xmalloc_ptr.
12546 (string_to_explicit_location): Update. Remove cleanups.
12547
12548 2017-04-12 Tom Tromey <tom@tromey.com>
12549
12550 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
12551 (compare_value_and_voffset): Change type. Update.
12552 (compute_vtable_size): Change type of "offset_vec".
12553 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
12554 (gnuv3_get_typeid): Remove extraneous declaration.
12555
12556 2017-04-12 Tom Tromey <tom@tromey.com>
12557
12558 * charset.h (wchar_iterator): Fix comment.
12559
12560 2017-04-12 Tom Tromey <tom@tromey.com>
12561
12562 * charset.c (iconv_wrapper): New class.
12563 (cleanup_iconv): Remove.
12564 (convert_between_encodings): Use it.
12565
12566 2017-04-12 Tom Tromey <tom@tromey.com>
12567
12568 * symfile.h (increment_reading_symtab): Update type.
12569 * symfile.c (decrement_reading_symtab): Remove.
12570 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
12571 * psymtab.c (psymtab_to_symtab): Update.
12572 * dwarf2read.c (dw2_instantiate_symtab): Update.
12573
12574 2017-04-12 Tom Tromey <tom@tromey.com>
12575
12576 * jit.c (struct jit_reader): Declare separately. Add constructor
12577 and destructor. Change type of "handle".
12578 (loaded_jit_reader): Define separately.
12579 (jit_reader_load): Update. New "new".
12580 (jit_reader_unload_command): Use "delete".
12581 * gdb-dlfcn.h (struct dlclose_deleter): New.
12582 (gdb_dlhandle_up): New typedef.
12583 (gdb_dlopen, gdb_dlsym): Update types.
12584 (gdb_dlclose): Remove.
12585 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
12586 (gdb_dlsym): Change type of "handle".
12587 (make_cleanup_dlclose): Remove.
12588 (dlclose_deleter::operator()): Rename from gdb_dlclose.
12589 * compile/compile-c-support.c (load_libcc): Update.
12590
12591 2017-04-12 Tom Tromey <tom@tromey.com>
12592
12593 * symtab.h (find_pcs_for_symtab_line): Change return type.
12594 * symtab.c (find_pcs_for_symtab_line): Change return type.
12595 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
12596 type of "vec". Update.
12597 (ltpy_get_pcs_for_line): Update.
12598 * linespec.c (decode_digits_ordinary): Update.
12599
12600 2017-04-12 Tom Tromey <tom@tromey.com>
12601
12602 * tracepoint.c (actions_command): Update.
12603 * python/python.c (python_command, python_interactive_command):
12604 Update.
12605 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
12606 * guile/guile.c (guile_command): Update.
12607 * defs.h (read_command_lines, read_command_lines_1): Return
12608 command_line_up.
12609 (command_lines_deleter): New struct.
12610 (command_line_up): New typedef.
12611 * compile/compile.c (compile_code_command)
12612 (compile_print_command): Update.
12613 * cli/cli-script.h (get_command_line, copy_command_lines): Return
12614 command_line_up.
12615 (make_cleanup_free_command_lines): Remove.
12616 * cli/cli-script.c (get_command_line, read_command_lines_1)
12617 (copy_command_lines): Return command_line_up.
12618 (while_command, if_command, read_command_lines, define_command)
12619 (document_command): Update.
12620 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
12621 Remove.
12622 * breakpoint.h (breakpoint_set_commands): Change type of
12623 "commands".
12624 * breakpoint.c (breakpoint_set_commands): Change type of
12625 "commands". Update.
12626 (do_map_commands_command, update_dprintf_command_list)
12627 (create_tracepoint_from_upload): Update.
12628
12629 2017-04-12 Tom Tromey <tom@tromey.com>
12630
12631 * tracepoint.c (scope_info): Update.
12632 * spu-tdep.c (spu_catch_start): Update.
12633 * python/python.c (gdbpy_decode_line): Update.
12634 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
12635 * python/py-breakpoint.c (bppy_init): Update.
12636 * probe.c (parse_probes): Update.
12637 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
12638 * location.h (event_location_deleter): New struct.
12639 (event_location_up): New typedef.
12640 (new_linespec_location, new_address_location, new_probe_location)
12641 (new_explicit_location, copy_event_location)
12642 (string_to_event_location, string_to_event_location_basic)
12643 (string_to_explicit_location): Update return type.
12644 (make_cleanup_delete_event_location): Remove.
12645 * location.c (new_linespec_location, new_address_location)
12646 (new_probe_location, new_explicit_location, copy_event_location):
12647 Return event_location_up.
12648 (delete_event_location_cleanup)
12649 (make_cleanup_delete_event_location): Remove.
12650 (string_to_explicit_location, string_to_event_location_basic)
12651 (string_to_event_location): Return event_location_up.
12652 * linespec.c (canonicalize_linespec, event_location_to_sals)
12653 (decode_line_with_current_source)
12654 (decode_line_with_last_displayed, decode_objc): Update.
12655 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
12656 * completer.c (location_completer): Update.
12657 * cli/cli-cmds.c (edit_command, list_command): Update.
12658 * breakpoint.c (create_overlay_event_breakpoint)
12659 (create_longjmp_master_breakpoint)
12660 (create_std_terminate_master_breakpoint)
12661 (create_exception_master_breakpoint)
12662 (create_thread_event_breakpoint): Update.
12663 (init_breakpoint_sal): Update. Remove some dead code.
12664 (create_breakpoint_sal): Change type of "location". Update.
12665 (create_breakpoints_sal, create_breakpoint, break_command_1)
12666 (dprintf_command, break_range_command, until_break_command)
12667 (init_ada_exception_breakpoint)
12668 (strace_marker_create_sals_from_location)
12669 (update_static_tracepoint, trace_command, ftrace_command)
12670 (strace_command, create_tracepoint_from_upload): Update.
12671 * break-catch-throw.c (re_set_exception_catchpoint): Update.
12672 * ax-gdb.c (agent_command_1): Update.
12673
12674 2017-04-12 Pedro Alves <palves@redhat.com>
12675
12676 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
12677 * configure.tgt: Handle i[34567]86-*-go32* and
12678 i[34567]86-*-msdosdjgpp*.
12679 * i386-tdep.c (i386_svr4_reg_to_regnum):
12680 Make extern.
12681 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
12682 i386-go32-tdep.c.
12683 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
12684 * i386-go32-tdep.c: New file.
12685 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
12686 declarations.
12687
12688 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
12689
12690 * aix-thread.c (pd_status2str): Change return type to const char *.
12691
12692 2017-04-12 Pedro Alves <palves@redhat.com>
12693
12694 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
12695 calls to set_gdbarch_gnu_triplet_regexp.
12696
12697 2017-04-12 Pedro Alves <palves@redhat.com>
12698
12699 PR gdb/21323
12700 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
12701 New enum value.
12702 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
12703 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
12704 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
12705 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
12706 * gdbarch.h, gdbarch.c: Regenerate.
12707 * aarch64-tdep.c (aarch64_gdbarch_init): Override
12708 gdbarch_wchar_bit and gdbarch_wchar_signed.
12709 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
12710 * arm-tdep.c (arm_gdbarch_init): Likewise.
12711 * avr-tdep.c (avr_gdbarch_init): Likewise.
12712 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
12713 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
12714 * i386-tdep.c (i386_go32_init_abi): Likewise.
12715 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12716 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12717 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
12718 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
12719 * sh-tdep.c (sh_gdbarch_init): Likewise.
12720 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
12721 * sparc64-tdep.c (sparc64_init_abi): Likewise.
12722 * windows-tdep.c (windows_init_abi): Likewise.
12723 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
12724
12725 2017-04-12 Pedro Alves <palves@redhat.com>
12726
12727 PR c++/21323
12728 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
12729 cplus_primitive_type_char32_t>: New enum values.
12730 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
12731 and cplus_primitive_type_char32_t.
12732 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
12733 32, use the archtecture's built-in type for char16_t and char32_t,
12734 respectively. Otherwise, fallback to init_integer_type as before,
12735 but make the type unsigned, and issue a complaint.
12736 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
12737
12738 2017-04-12 Alan Hayward <alan.hayward@arm.com>
12739
12740 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
12741 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
12742
12743 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
12744
12745 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
12746 'const char *'.
12747
12748 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
12749
12750 * common/common-utils.c (free_vector_argv): New function.
12751 * common/common-utils.h: Include <vector>.
12752 (free_vector_argv): New prototype.
12753 * darwin-nat.c (darwin_create_inferior): Rewrite function
12754 prototype in order to constify "exec_file" and accept a
12755 "std::string" for "allargs".
12756 * fork-child.c: Include <vector>.
12757 (breakup_args): Rewrite function, using C++.
12758 (fork_inferior): Rewrite function header, constify "exec_file_arg"
12759 and accept "std::string" for "allargs". Update the code to
12760 calculate "argv" based on "allargs". Update calls to "exec_fun"
12761 and "execvp".
12762 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
12763 order to constify "exec_file" and accept a "std::string" for
12764 "allargs".
12765 * go32-nat.c (go32_create_inferior): Likewise.
12766 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
12767 * infcmd.c (run_command_1): Constify "exec_file". Use
12768 "std::string" for inferior arguments.
12769 * inferior.h (fork_inferior): Update prototype.
12770 * linux-nat.c (linux_nat_create_inferior): Rewrite function
12771 prototype in order to constify "exec_file" and accept a
12772 "std::string" for "allargs".
12773 * nto-procfs.c (procfs_create_inferior): Likewise.
12774 * procfs.c (procfs_create_inferior): Likewise.
12775 * remote-sim.c (gdbsim_create_inferior): Likewise.
12776 * remote.c (extended_remote_run): Update code to accept
12777 "std::string" as argument.
12778 (extended_remote_create_inferior): Rewrite function prototype in
12779 order to constify "exec_file" and accept a "std::string" for
12780 "allargs".
12781 * rs6000-nat.c (super_create_inferior): Likewise.
12782 (rs6000_create_inferior): Likewise.
12783 * target.h (struct target_ops) <to_create_inferior>: Likewise.
12784 * windows-nat.c (windows_create_inferior): Likewise.
12785
12786 2017-04-11 Pedro Alves <palves@redhat.com>
12787
12788 * thread.c: Fix whitespace throughout.
12789
12790 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
12791
12792 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
12793
12794 2017-04-11 Alan Hayward <alan.hayward@arm.com>
12795
12796 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
12797
12798 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
12799
12800 PR gdb/21364
12801 * osdata.c (info_osdata): Check if 'type' is an empty string
12802 instead of NULL.
12803
12804 2017-04-10 Pedro Alves <palves@redhat.com>
12805
12806 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
12807 (ptid_to_global_thread_id, in_thread_list)
12808 (do_captured_list_thread_ids, set_resumed, set_running)
12809 (set_executing, set_stop_requested, finish_thread_state)
12810 (validate_registers_access, can_access_registers_ptid)
12811 (print_thread_info_1, switch_to_thread)
12812 (do_restore_current_thread_cleanup)
12813 (make_cleanup_restore_current_thread, thread_command)
12814 (thread_name_command): Use operator== instead of ptid_equal.
12815
12816 2017-04-10 Pedro Alves <palves@redhat.com>
12817
12818 * thread.c (struct current_thread_cleanup) <next>: Delete field.
12819 (current_thread_cleanup_chain): Delete.
12820 (restore_current_thread_cleanup_dtor)
12821 (make_cleanup_restore_current_thread): Remove references to
12822 current_thread_cleanup_chain.
12823
12824 2017-04-10 Alan Hayward <alan.hayward@arm.com>
12825
12826 * msp430-tdep.c (msp430_pseudo_register_read): Never return
12827 REG_UNKNOWN.
12828
12829 2017-04-10 Yao Qi <yao.qi@linaro.org>
12830
12831 PR gdb/19942
12832 * gdbthread.h (thread_info::deletable): New method.
12833 (thread_info::incref): New method.
12834 (thread_info::decref): New method.
12835 (thread_info::refcount): Move it to private.
12836 * infrun.c (save_stop_context): Call inc_refcount.
12837 (release_stop_context_cleanup): Likewise.
12838 * thread.c (set_thread_exited): New function.
12839 (init_thread_list): Delete "tp" only it is deletable, otherwise
12840 call set_thread_exited.
12841 (delete_thread_1): Call set_thread_exited.
12842 (current_thread_cleanup) <inferior_pid>: Remove.
12843 <thread>: New field.
12844 (restore_current_thread_ptid_changed): Removed.
12845 (do_restore_current_thread_cleanup): Adjust.
12846 (restore_current_thread_cleanup_dtor): Don't call
12847 find_thread_ptid.
12848 (set_thread_refcount): Use dec_refcount.
12849 (make_cleanup_restore_current_thread): Adjust.
12850 (thread_apply_all_command): Call inc_refcount.
12851 (_initialize_thread): Don't call
12852 observer_attach_thread_ptid_changed.
12853
12854 2017-04-10 Yao Qi <yao.qi@linaro.org>
12855
12856 * thread.c (delete_thread_1): Hoist code on marking thread as
12857 exited.
12858
12859 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12860
12861 * windows-nat.c (windows_detach): Initialize ptid with
12862 minus_one_ptid.
12863
12864 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
12865
12866 * unittests/ptid-selftests.c: Fix erroneous assert messages.
12867
12868 2017-04-07 Alan Hayward <alan.hayward@arm.com>
12869
12870 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
12871 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
12872 (bfin_pseudo_register_write): Likewise
12873
12874 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
12875
12876 * common/ptid.h (struct ptid): Change to...
12877 (class ptid_t): ... this.
12878 <ptid_t>: New constructors.
12879 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
12880 matches>: New methods.
12881 <make_null, make_minus_one>: New static methods.
12882 <pid>: Rename to...
12883 <m_pid>: ...this.
12884 <lwp>: Rename to...
12885 <m_lwp>: ...this.
12886 <tid>: Rename to...
12887 <m_tid>: ...this.
12888 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
12889 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
12890 as references, move comment to class ptid_t.
12891 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
12892 ptid_t static methods.
12893 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
12894 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
12895 Take ptid arguments as references, implement using ptid_t methods.
12896 * unittests/ptid-selftests.c: New file.
12897 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12898 unittests/ptid-selftests.c.
12899 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
12900
12901 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
12902
12903 * python/python.c (python_run_simple_file): Cast mode literal to
12904 non-const char pointer as expected by PyFile_FromString.
12905
12906 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
12907
12908 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
12909 minus_one_ptid and null_ptid.
12910
12911 2017-04-05 Pedro Alves <palves@redhat.com>
12912
12913 * warning.m4 (build_warnings): Remove -Wno-write-strings.
12914 * configure: Regenerate.
12915
12916 2017-04-05 Pedro Alves <palves@redhat.com>
12917
12918 * ada-exp.y (yyerror): Constify.
12919 * ada-lang.c (bound_name, get_selections)
12920 (ada_variant_discrim_type)
12921 (ada_variant_discrim_name, ada_value_struct_elt)
12922 (ada_lookup_struct_elt_type, is_unchecked_variant)
12923 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
12924 (catch_ada_exception_command_split)
12925 (catch_ada_assert_command_split, catch_assert_command)
12926 (ada_op_name): Constify.
12927 * ada-lang.h (ada_yyerror, get_selections)
12928 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
12929 * arc-tdep.c (arc_print_frame_cache): Constify.
12930 * arm-tdep.c (arm_skip_stub): Constify.
12931 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
12932 (gen_aggregate_elt_ref): Constify.
12933 * bcache.c (print_bcache_statistics): Constify.
12934 * bcache.h (print_bcache_statistics): Constify.
12935 * break-catch-throw.c (catch_exception_command_1):
12936 * breakpoint.c (struct ep_type_description::description):
12937 Constify.
12938 (add_solib_catchpoint): Constify.
12939 (catch_fork_command_1): Add cast.
12940 (add_catch_command): Constify.
12941 * breakpoint.h (add_catch_command, add_solib_catchpoint):
12942 Constify.
12943 * bsd-uthread.c (bsd_uthread_state): Constify.
12944 * buildsym.c (patch_subfile_names): Constify.
12945 * buildsym.h (next_symbol_text_func, patch_subfile_names):
12946 Constify.
12947 * c-exp.y (yyerror): Constify.
12948 (token::oper): Constify.
12949 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
12950 * c-varobj.c (cplus_describe_child): Constify.
12951 * charset.c (find_charset_names): Add cast.
12952 (find_charset_names): Constify array and add const_cast.
12953 * cli/cli-cmds.c (complete_command, cd_command): Constify.
12954 (edit_command): Constify.
12955 * cli/cli-decode.c (lookup_cmd): Constify.
12956 * cli/cli-dump.c (dump_memory_command, dump_value_command):
12957 Constify.
12958 (struct dump_context): Constify.
12959 (add_dump_command, restore_command): Constify.
12960 * cli/cli-script.c (get_command_line): Constify.
12961 * cli/cli-script.h (get_command_line): Constify.
12962 * cli/cli-utils.c (check_for_argument): Constify.
12963 * cli/cli-utils.h (check_for_argument): Constify.
12964 * coff-pe-read.c (struct read_pe_section_data): Constify.
12965 * command.h (lookup_cmd): Constify.
12966 * common/print-utils.c (decimal2str): Constify.
12967 * completer.c (gdb_print_filename): Constify.
12968 * corefile.c (set_gnutarget): Constify.
12969 * cp-name-parser.y (yyerror): Constify.
12970 * cp-valprint.c (cp_print_class_member): Constify.
12971 * cris-tdep.c (cris_register_name, crisv32_register_name):
12972 Constify.
12973 * d-exp.y (yyerror): Constify.
12974 (struct token::oper): Constify.
12975 * d-lang.h (d_yyerror): Constify.
12976 * dbxread.c (struct header_file_location::name): Constify.
12977 (add_old_header_file, add_new_header_file, last_function_name)
12978 (dbx_next_symbol_text, add_bincl_to_list)
12979 (find_corresponding_bincl_psymtab, set_namestring)
12980 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
12981 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
12982 * defs.h (command_line_input, print_address_symbolic)
12983 (deprecated_readline_begin_hook): Constify.
12984 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
12985 Constify.
12986 * event-top.c (handle_line_of_input): Constify and add cast.
12987 * exceptions.c (catch_errors): Constify.
12988 * exceptions.h (catch_errors): Constify.
12989 * expprint.c (print_subexp_standard, op_string, op_name)
12990 (op_name_standard, dump_raw_expression, dump_raw_expression):
12991 * expression.h (op_name, op_string, dump_raw_expression):
12992 Constify.
12993 * f-exp.y (yyerror): Constify.
12994 (struct token::oper): Constify.
12995 (struct f77_boolean_val::name): Constify.
12996 * f-lang.c (f_word_break_characters): Constify.
12997 * f-lang.h (f_yyerror): Constify.
12998 * fork-child.c (fork_inferior): Add cast.
12999 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
13000 (new_variant): Constify.
13001 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
13002 * gdbarch.c: Regenerate.
13003 * gdbcore.h (set_gnutarget): Constify.
13004 * go-exp.y (yyerror): Constify.
13005 (token::oper): Constify.
13006 * go-lang.h (go_yyerror): Constify.
13007 * go32-nat.c (go32_sysinfo): Constify.
13008 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
13009 * guile/scm-cmd.c (cmdscm_function): Constify.
13010 * guile/scm-param.c (pascm_param_value): Constify.
13011 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
13012 (h8300sx_register_name): Constify.
13013 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
13014 Constify.
13015 * ia64-tdep.c (ia64_register_names): Constify.
13016 * infcmd.c (construct_inferior_arguments): Constify.
13017 (path_command, attach_post_wait): Constify.
13018 * language.c (show_range_command, show_case_command)
13019 (unk_lang_error): Constify.
13020 * language.h (language_defn::la_error)
13021 (language_defn::la_name_of_this): Constify.
13022 * linespec.c (decode_line_2): Constify.
13023 * linux-thread-db.c (thread_db_err_str): Constify.
13024 * lm32-tdep.c (lm32_register_name): Constify.
13025 * m2-exp.y (yyerror): Constify.
13026 * m2-lang.h (m2_yyerror): Constify.
13027 * m32r-tdep.c (m32r_register_names): Constify and make static.
13028 * m68hc11-tdep.c (m68hc11_register_names): Constify.
13029 * m88k-tdep.c (m88k_register_name): Constify.
13030 * macroexp.c (appendmem): Constify.
13031 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
13032 (upgrade_type, parse_external, parse_partial_symbols)
13033 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
13034 (new_symbol): Constify.
13035 * memattr.c (mem_info_command): Constify.
13036 * mep-tdep.c (register_name_from_keyword): Constify.
13037 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
13038 Constify.
13039 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
13040 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
13041 * mi/mi-main.c (captured_mi_execute_command): Constify and add
13042 cast.
13043 (mi_execute_async_cli_command): Constify.
13044 * mips-tdep.c (mips_register_name): Constify.
13045 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
13046 (am33_register_name, am33_2_register_name)
13047 * moxie-tdep.c (moxie_register_names): Constify.
13048 * nat/linux-osdata.c (osdata_type): Constify fields.
13049 * nto-tdep.c (nto_parse_redirection): Constify.
13050 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
13051 (lookup_child_selector): Constify.
13052 (objc_methcall::name): Constify.
13053 * objc-lang.h (lookup_objc_class, lookup_child_selector)
13054 (lookup_struct_typedef): Constify.
13055 * objfiles.c (pc_in_section): Constify.
13056 * objfiles.h (pc_in_section): Constify.
13057 * p-exp.y (struct token::oper): Constify.
13058 (yyerror): Constify.
13059 * p-lang.h (pascal_yyerror): Constify.
13060 * parser-defs.h (op_name_standard): Constify.
13061 (op_print::string): Constify.
13062 (exp_descriptor::op_name): Constify.
13063 * printcmd.c (print_address_symbolic): Constify.
13064 * psymtab.c (print_partial_symbols): Constify.
13065 * python/py-breakpoint.c (stop_func): Constify.
13066 (bppy_get_expression): Constify.
13067 * python/py-cmd.c (cmdpy_completer::name): Constify.
13068 (cmdpy_function): Constify.
13069 * python/py-event.c (evpy_add_attribute)
13070 (gdbpy_initialize_event_generic): Constify.
13071 * python/py-event.h (evpy_add_attribute)
13072 (gdbpy_initialize_event_generic): Constify.
13073 * python/py-evts.c (add_new_registry): Constify.
13074 * python/py-finishbreakpoint.c (outofscope_func): Constify.
13075 * python/py-framefilter.c (get_py_iter_from_func): Constify.
13076 * python/py-inferior.c (get_buffer): Add cast.
13077 * python/py-param.c (parm_constant::name): Constify.
13078 * python/py-unwind.c (fprint_frame_id): Constify.
13079 * python/python.c (gdbpy_parameter_value): Constify.
13080 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
13081 * remote.c (memory_packet_config::name): Constify.
13082 (show_packet_config_cmd, remote_write_bytes)
13083 (remote_buffer_add_string):
13084 * reverse.c (exec_reverse_once): Constify.
13085 * rs6000-tdep.c (variant::name, variant::description): Constify.
13086 * rust-exp.y (rustyyerror): Constify.
13087 * rust-lang.c (rust_op_name): Constify.
13088 * rust-lang.h (rustyyerror): Constify.
13089 * serial.h (serial_ops::name): Constify.
13090 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
13091 (sh_sh3e_register_name, sh_sh2e_register_name)
13092 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
13093 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
13094 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
13095 (sh_sh4al_dsp_register_name): Constify.
13096 * sh64-tdep.c (sh64_register_name): Constify.
13097 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
13098 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
13099 * stabsread.c (patch_block_stabs, read_type_number)
13100 (ref_map::stabs, ref_add, process_reference)
13101 (symbol_reference_defined, define_symbol, define_symbol)
13102 (error_type, read_type, read_member_functions, read_cpp_abbrev)
13103 (read_one_struct_field, read_struct_fields, read_baseclasses)
13104 (read_tilde_fields, read_struct_type, read_array_type)
13105 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
13106 (read_huge_number, read_range_type, read_args, common_block_start)
13107 (find_name_end): Constify.
13108 * stabsread.h (common_block_start, define_symbol)
13109 (process_one_symbol, symbol_reference_defined, ref_add):
13110 * symfile.c (get_section_index, add_symbol_file_command):
13111 * symfile.h (get_section_index): Constify.
13112 * target-descriptions.c (tdesc_type::name): Constify.
13113 (tdesc_free_type): Add cast.
13114 * target.c (find_default_run_target):
13115 (add_deprecated_target_alias, find_default_run_target)
13116 (target_announce_detach): Constify.
13117 (do_option): Constify.
13118 * target.h (add_deprecated_target_alias): Constify.
13119 * thread.c (print_thread_info_1): Constify.
13120 * top.c (deprecated_readline_begin_hook, command_line_input):
13121 Constify.
13122 (init_main): Add casts.
13123 * top.h (handle_line_of_input): Constify.
13124 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
13125 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
13126 (tfind_command): Rename to ...
13127 (tfind_command_1): ... this and constify.
13128 (tfind_command): New function.
13129 (tfind_end_command, tfind_start_command): Adjust.
13130 (encode_source_string): Constify.
13131 * tracepoint.h (encode_source_string): Constify.
13132 * tui/tui-data.c (tui_partial_win_by_name): Constify.
13133 * tui/tui-data.h (tui_partial_win_by_name): Constify.
13134 * tui/tui-source.c (tui_set_source_content_nil): Constify.
13135 * tui/tui-source.h (tui_set_source_content_nil): Constify.
13136 * tui/tui-win.c (parse_scrolling_args): Constify.
13137 * tui/tui-windata.c (tui_erase_data_content): Constify.
13138 * tui/tui-windata.h (tui_erase_data_content): Constify.
13139 * tui/tui-winsource.c (tui_erase_source_content): Constify.
13140 * tui/tui.c (tui_enable): Add cast.
13141 * utils.c (defaulted_query): Constify.
13142 (init_page_info): Add cast.
13143 (puts_debug, subset_compare): Constify.
13144 * utils.h (subset_compare): Constify.
13145 * varobj.c (varobj_format_string): Constify.
13146 * varobj.h (varobj_format_string): Constify.
13147 * vax-tdep.c (vax_register_name): Constify.
13148 * windows-nat.c (windows_detach): Constify.
13149 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
13150 * xml-support.c (gdb_xml_end_element): Constify.
13151 * xml-tdesc.c (tdesc_start_reg): Constify.
13152 * xstormy16-tdep.c (xstormy16_register_name): Constify.
13153 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
13154 * xtensa-tdep.h (xtensa_register_t::name): Constify.
13155
13156 2017-04-05 Pedro Alves <palves@redhat.com>
13157
13158 * proc-api.c (struct trans): Constify.
13159 (procfs_note): Constify.
13160 * proc-events.c (struct trans, syscall_table):
13161 * proc-flags.c (struct trans): Constify.
13162 * proc-utils.h (procfs_note): Constify.
13163 * proc-why.c (struct trans): Constify.
13164 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
13165 (procfs_detach): Constify.
13166 * sol-thread.c (struct string_map): Constify.
13167 (td_err_string, td_state_string): Constify.
13168
13169 2017-04-05 Pedro Alves <palves@redhat.com>
13170
13171 * proc-api.c (procfs_filename): Don't initialize
13172 procfs_filename.
13173 (prepare_to_trace): Assume procfs_filename is non-NULL.
13174 (_initialize_proc_api): Give procfs_filename a default value here.
13175
13176 2017-04-05 Pedro Alves <palves@redhat.com>
13177
13178 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
13179 'cond_string' parameter.
13180 (extract_exception_regexp): Constify 'string' parameter.
13181 (catch_exception_command_1): Constify.
13182 * breakpoint.c (init_catchpoint)
13183 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
13184 parameter.
13185 (ep_parse_optional_if_clause, catch_fork_command_1)
13186 (catch_exec_command_1): Constify.
13187 * breakpoint.h (init_catchpoint): Constify 'cond_string'
13188 parameter.
13189 (ep_parse_optional_if_clause): Constify.
13190 * cli/cli-utils.c (remove_trailing_whitespace)
13191 (check_for_argument): Constify.
13192 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
13193 non-const overload.
13194 (check_for_argument): Likewise.
13195
13196 2017-04-05 Pedro Alves <palves@redhat.com>
13197
13198 * event-top.c (command_line_handler): Add cast to execute_command
13199 call.
13200 * record-btrace.c (cmd_record_btrace_bts_start)
13201 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
13202 (cmd_record_btrace_start): Add cast to execute_command call.
13203 * record-full.c (record_full_goto_insn):
13204 * record.c (record_start, record_stop): Add cast to
13205 execute_command_to_string calls.
13206 (cmd_record_start): Add cast to execute_command calls.
13207
13208 2017-04-05 Pedro Alves <palves@redhat.com>
13209
13210 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
13211 static inline function.
13212 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
13213 array and use gdb_PyArg_ParseTupleAndKeywords.
13214 * python/py-cmd.c (cmdpy_init): Likewise.
13215 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
13216 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
13217 (infpy_search_memory): Likewise.
13218 * python/py-objfile.c (objfpy_add_separate_debug_file)
13219 (gdbpy_lookup_objfile): Likewise.
13220 * python/py-symbol.c (gdbpy_lookup_symbol)
13221 (gdbpy_lookup_global_symbol): Likewise.
13222 * python/py-type.c (gdbpy_lookup_type): Likewise.
13223 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
13224 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
13225 Likewise.
13226
13227 2017-04-05 Pedro Alves <palves@redhat.com>
13228
13229 * python/python-internal.h (gdb_PyGetSetDef): New type.
13230 * python/py-block.c (block_object_getset)
13231 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
13232 * python/py-event.c (event_object_getset)
13233 (finish_breakpoint_object_getset): Likewise.
13234 * python/py-inferior.c (inferior_object_getset): Likewise.
13235 * python/py-infthread.c (thread_object_getset): Likewise.
13236 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
13237 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
13238 * python/py-objfile.c (objfile_getset): Likewise.
13239 * python/py-progspace.c (pspace_getset): Likewise.
13240 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
13241 Likewise.
13242 * python/py-record.c (recpy_record_getset): Likewise.
13243 * python/py-symbol.c (symbol_object_getset): Likewise.
13244 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
13245 Likewise.
13246 * python/py-type.c (type_object_getset, field_object_getset):
13247 Likewise.
13248 * python/py-value.c (value_object_getset): Likewise.
13249
13250 2017-04-05 Pedro Alves <palves@redhat.com>
13251
13252 * python/python-internal.h (gdb_PyObject_CallMethod)
13253 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
13254 New functions.
13255 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
13256 (PySys_GetObject, PySys_SetPath): New macros.
13257
13258 2017-04-05 Pedro Alves <palves@redhat.com>
13259
13260 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
13261 info_osdata_command.
13262 * osdata.c (info_osdata_command): Rename to ...
13263 (info_osdata): ... this. Constify 'type' parameter, and remove
13264 the 'from_tty' parameter. Accept NULL TYPE.
13265 (info_osdata_command): New function.
13266 * osdata.h (info_osdata_command): Remove declaration.
13267 (info_osdata): New declaration.
13268
13269 2017-04-05 Pedro Alves <palves@redhat.com>
13270
13271 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
13272 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
13273 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
13274 parameter.
13275 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
13276 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
13277 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
13278 parameter.
13279 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
13280 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
13281 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
13282 (mi_cmd_file_list_exec_source_files)
13283 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
13284 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13285 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
13286 parameter.
13287 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
13288 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
13289 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
13290 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
13291 (mi_cmd_stack_info_frame): Constify 'command' parameter.
13292 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
13293 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
13294 'command' parameter.
13295 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
13296 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
13297 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
13298 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
13299 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
13300 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
13301 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
13302 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
13303 (mi_cmd_var_set_update_range): Constify 'command' parameter.
13304 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
13305 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
13306 parameter.
13307 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
13308 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
13309 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
13310 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
13311 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
13312 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
13313 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
13314 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
13315 (mi_cmd_data_list_changed_registers)
13316 (mi_cmd_data_write_register_values)
13317 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
13318 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
13319 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
13320 (mi_cmd_list_features, mi_cmd_list_target_features)
13321 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
13322 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
13323 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
13324 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
13325 (mi_cmd_trace_frame_collected): Constify 'command'
13326 parameter.
13327 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
13328 'command' parameter.
13329
13330 2017-04-05 Pedro Alves <palves@redhat.com>
13331
13332 * ada-lang.c (ada_completer_word_break_characters): Now a const
13333 array.
13334 (ada_get_gdb_completer_word_break_characters): Constify.
13335 * completer.c (gdb_completer_command_word_break_characters)
13336 (gdb_completer_file_name_break_characters)
13337 (gdb_completer_quote_characters): Now const arrays.
13338 (get_gdb_completer_quote_characters): Constify.
13339 (set_rl_completer_word_break_characters): New function.
13340 (set_gdb_completion_word_break_characters)
13341 (complete_line_internal): Use it.
13342 * completer.h (get_gdb_completer_quote_characters): Constify.
13343 (set_rl_completer_word_break_characters): Declare.
13344 * f-lang.c (f_word_break_characters): Constify.
13345 * language.c (default_word_break_characters): Constify.
13346 * language.h (language_defn::la_word_break_characters): Constify.
13347 (default_word_break_characters): Constify.
13348 * top.c (init_main): Use set_rl_completer_word_break_characters.
13349
13350 2017-04-05 Pedro Alves <palves@redhat.com>
13351
13352 * aix-thread.c (aix_thread_pid_to_str)
13353 (aix_thread_extra_thread_info): Constify.
13354 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
13355 * bsd-uthread.c (bsd_uthread_extra_thread_info)
13356 (bsd_uthread_pid_to_str): Constify.
13357 * corelow.c (core_pid_to_str): Constify.
13358 * darwin-nat.c (darwin_pid_to_str): Constify.
13359 * fbsd-nat.c (fbsd_pid_to_str): Constify.
13360 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
13361 Constify.
13362 * gnu-nat.c (gnu_pid_to_str): Constify.
13363 * go32-nat.c (go32_pid_to_str): Constify.
13364 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
13365 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
13366 * inferior.c (inferior_pid_to_str): Constify.
13367 * linux-nat.c (linux_nat_pid_to_str): Constify.
13368 * linux-tdep.c (linux_core_pid_to_str): Constify.
13369 * linux-thread-db.c (thread_db_pid_to_str)
13370 (thread_db_extra_thread_info): Constify.
13371 * nto-tdep.c (nto_extra_thread_info): Constify.
13372 * nto-tdep.h (nto_extra_thread_info): Constify.
13373 * obsd-nat.c (obsd_pid_to_str): Constify.
13374 * procfs.c (procfs_pid_to_str): Constify.
13375 * ravenscar-thread.c (ravenscar_extra_thread_info)
13376 (ravenscar_pid_to_str): Constify.
13377 * remote-sim.c (gdbsim_pid_to_str): Constify.
13378 * remote.c (remote_threads_extra_info, remote_pid_to_str):
13379 Constify.
13380 * sol-thread.c (solaris_pid_to_str): Constify.
13381 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
13382 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
13383 * target.c (default_pid_to_str, target_pid_to_str)
13384 (normal_pid_to_str, default_pid_to_str): Constify.
13385 * target.h (target_ops::to_pid_to_str)
13386 (target_ops::to_extra_thread_info): Constify.
13387 (target_pid_to_str, normal_pid_to_str): Constify.
13388 * windows-nat.c (windows_pid_to_str): Constify.
13389 * gdbarch.sh (core_pid_to_str): Constify.
13390 * target-delegates.c: Regenerate.
13391 * gdbarch.h, gdbarch.c: Regenerate.
13392
13393 2017-04-05 Pedro Alves <palves@redhat.com>
13394
13395 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
13396 the memory of the temporary warning_pre_print override.
13397 * utils.c (warning_pre_print): Constify.
13398 * utils.h (warning_pre_print): Constify.
13399
13400 2017-04-05 Pedro Alves <palves@redhat.com>
13401
13402 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
13403 (shell_command): New function.
13404 (make_command): Use std::string.
13405 (init_cli_cmds): Register shell_command instead of shell_escape.
13406
13407 2017-04-05 Pedro Alves <palves@redhat.com>
13408
13409 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
13410 * tracepoint.c (default_collect): Don't initialize.
13411
13412 2017-04-05 Pedro Alves <palves@redhat.com>
13413
13414 * macroexp.c (macro_buffer::shared): Now a bool.
13415 (init_buffer): Update.
13416 (init_shared_buffer): Constify 'addr' parameter.
13417 (substitute_args, expand, macro_expand, macro_expand_next): Remove
13418 casts.
13419
13420 2017-04-05 Pedro Alves <palves@redhat.com>
13421
13422 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
13423 * disasm.c (set_disassembler_options): Constify local.
13424 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
13425
13426 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
13427
13428 PR gdb/21352
13429 * tracefile.c (tsave_command): Fix argument parsing for '-r'
13430 option.
13431
13432 2017-04-05 Yao Qi <yao.qi@linaro.org>
13433
13434 * frame.c (frame_unwind_register_unsigned): Call
13435 frame_unwind_register_value.
13436
13437 2017-04-05 Yao Qi <yao.qi@linaro.org>
13438
13439 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
13440 Use gdb_test_multiple, and don't match anchor.
13441
13442 2017-04-05 Pedro Alves <palves@redhat.com>
13443
13444 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
13445 (Write After Approval): Remove Simon Marchi.
13446
13447 2017-04-05 Pedro Alves <palves@redhat.com>
13448
13449 * common/gdb_optional.h (optional::optional): Make constexpr and
13450 initialize m_dummy.
13451
13452 2017-04-04 John Baldwin <jhb@FreeBSD.org>
13453
13454 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
13455 (amd64fbsd_jmp_buf_reg_offset): Remove.
13456 (amd64fbsd_supply_uthread): Remove function.
13457 (amd64fbsd_collect_uthread): Remove function.
13458 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
13459 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
13460 (x86_64-*-freebsd*): Remove bsd-uthread.o.
13461 (fbsd-nat.c): Update comment.
13462 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
13463 (i386fbsd_jmp_buf_reg_offset): Remove.
13464 (i386fbsd_supply_uthread): Remove function.
13465 (i386fbsd_collect_uthread): Remove function.
13466 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
13467
13468 2017-04-04 John Baldwin <jhb@FreeBSD.org>
13469
13470 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
13471 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
13472 * NEWS: Mention that support for FreeBSD/alpha was removed.
13473 * alpha-fbsd-tdep.c: Delete file.
13474 * config/alpha/fbsd.mh: Delete file.
13475 * configure.host: Delete alpha*-*-freebsd* and
13476 alpha*-*-kfreebsd*-gnu.
13477 * configure.tgt: Delete alpha*-*-freebsd* and
13478 alpha*-*-kfreebsd*-gnu.
13479
13480 2017-04-04 John Baldwin <jhb@FreeBSD.org>
13481
13482 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
13483 amd64bsd_store_inferior_registers): Use ptid from regcache.
13484
13485 2017-04-04 Pedro Alves <palves@redhat.com>
13486
13487 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
13488 data fields, make them private and add "m_" prefixes.
13489 (lnp_state_machine::lnp_state_machine): New ctor.
13490 (record_line, check_line_address, handle_set_discriminator)
13491 (handle_set_address, handle_advance_pc, handle_special_opcode)
13492 (handle_advance_line, handle_set_file, handle_negate_stmt)
13493 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
13494 (end_sequence, advance_line): New methods.
13495 (m_gdbarch, m_record_lines_p): New fields.
13496 (lnp_reader_state): Delete.
13497 (dwarf_record_line): Rename to ...
13498 (lnp_state_machine::record_line): ... adjust.
13499 (init_lnp_state_machine): Delete.
13500 (lnp_state_machine::lnp_state_machine): New.
13501 (check_line_address): Rename to ...
13502 (lnp_state_machine::check_line_address): This.
13503 (dwarf_decode_lines_1): Remove reference to "reader_state".
13504 Adjust lnp_state_machine having a non-default ctor. Use bool.
13505 State machine internal state manipulation moved to
13506 lnp_state_machine methods.
13507
13508 2017-04-04 Pedro Alves <palves@redhat.com>
13509
13510 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13511 unittests/offset-type-selftests.c.
13512 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
13513 * common/offset-type.h: New file.
13514 * common/preprocessor.h: New file.
13515 * common/traits.h: New file.
13516 * common/valid-expr.h: New file.
13517 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
13518 sect_offset and cu_offset strong typedefs throughout.
13519 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
13520 typedefs throughout.
13521 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
13522 sect_offset and cu_offset strong typedefs throughout.
13523 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
13524 typedefs throughout.
13525 * gdbtypes.h: Include "common/offset-type.h".
13526 (cu_offset): Now an offset type (strong typedef) instead of a
13527 struct.
13528 (sect_offset): Likewise.
13529 (union call_site_parameter_u): Rename "param_offset" field to
13530 "param_cu_off".
13531 * unittests/offset-type-selftests.c: New file.
13532
13533 2017-04-04 Pedro Alves <palves@redhat.com>
13534
13535 * common/underlying.h: New file.
13536 * dwarf2read.c: Include "common/gdb_optional.h" and
13537 "common/underlying.h".
13538 (dir_index, file_name_index): New types.
13539 (file_entry): Use them.
13540 (file_entry::include): Use to_underlying.
13541 (line_header::add_file_name): Use dir_index.
13542 (read_formatted_entries): Use gdb::optional. Read form before
13543 writting to file_entry.
13544 (dwarf_decode_line_header): Use dir_index.
13545 (lnp_state_machine::current_file): Use to_underlying.
13546 (lnp_state_machine::file): Change type to file_name_index.
13547 (dwarf_record_line): Use to_underlying.
13548 (init_lnp_state_machine): Use file_name_index.
13549 (dwarf_decode_lines_1): Use dir_index and file_name_index.
13550
13551 2017-04-04 Pedro Alves <palves@redhat.com>
13552
13553 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
13554 operator bool, has_value and get methods.
13555
13556 2017-04-04 Pedro Alves <palves@redhat.com>
13557
13558 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
13559 fields.
13560 (line_header): Initialize all data fields. Change type of
13561 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
13562 Change type of include_dirs to std::vector<const char *>. Remove
13563 num_include_dirs, include_dirs_size. Change type of file_names to
13564 std::vector<file_entry>. Remove num_file_names, file_names_size.
13565 (line_header::line_header): New.
13566 (line_header::add_include_dir, line_header::add_file_name): New
13567 methods.
13568 (line_header::include_dir_at): Remove NULL check.
13569 (line_header::file_name_at): Add const overload.
13570 (line_header_up): New unique_ptr typedef.
13571 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
13572 std::vector. Remove free_line_header call.
13573 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
13574 free_line_header call.
13575 (free_cu_line_header): Delete.
13576 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
13577 (setup_type_unit_groups): Use line_header_up instead of cleanups.
13578 Adjust to use std::vector.
13579 (free_line_header): Delete.
13580 (free_line_header_voidp): Use delete.
13581 (add_include_dir): Replace with ...
13582 (line_header::add_include_dir): ... this method. Use std::vector.
13583 (add_file_name): Replace with ...
13584 (line_header::add_file_name): ... this method. Use std::vector.
13585 (add_include_dir_stub): Delete.
13586 (read_formatted_entries): Remove memset.
13587 (dwarf_decode_line_header): Return a line_header_up instead of a
13588 raw pointer. Remove cleanup handling. Pass lambdas to
13589 read_formatted_entries. Adjust to use line_header methods.
13590 (dwarf_decode_lines_1): Adjust to use line_header methods.
13591 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
13592 use std::vector.
13593
13594 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
13595
13596 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
13597 instead of struct ptid.
13598
13599 2017-05-04 Alan Hayward <alan.hayward@arm.com>
13600
13601 * frame.c (get_frame_register_bytes): Unwind using value.
13602 (put_frame_register_bytes): Likewise.
13603
13604 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
13605
13606 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
13607 aggregate-like.
13608
13609 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
13610
13611 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
13612
13613 2017-03-29 Yao Qi <yao.qi@linaro.org>
13614
13615 * gdbthread.h (struct thread_info): Declare constructor and
13616 destructor. Add some in-class member initializers.
13617 * thread.c (free_thread): Remove.
13618 (init_thread_list): Call delete instead of free_thread.
13619 (new_thread): Call thread_info constructor.
13620 (thread_info::thread_info): New function.
13621 (thread_info::~thread_info): New function.
13622 (delete_thread_1): Call delete instead of free_thread.
13623 (make_cleanup_restore_current_thread): Move tp and frame to
13624 inner block.
13625
13626 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13627
13628 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
13629 (arc_skip_prologue): Likewise.
13630 (arc_make_frame_cache): Likewise.
13631 (arc_pv_get_operand): New function.
13632 (arc_is_in_prologue): Likewise.
13633 (arc_analyze_prologue): Likewise.
13634 (arc_print_frame_cache): Likewise.
13635 (MAX_PROLOGUE_LENGTH): New constant.
13636
13637 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13638
13639 * configure.tgt: Add arc-insn.o.
13640 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
13641 (dump_arc_instruction_command): New function.
13642 (arc_fprintf_disasm): Likewise.
13643 (arc_disassemble_info): Likewise.
13644 (arc_insn_get_operand_value): Likewise.
13645 (arc_insn_get_operand_value_signed): Likewise.
13646 (arc_insn_get_memory_base_reg): Likewise.
13647 (arc_insn_get_memory_offset): Likewise.
13648 (arc_insn_get_branch_target): Likewise.
13649 (arc_insn_dump): Likewise.
13650 (arc_insn_get_linear_next_pc): Likewise.
13651 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
13652 (arc_disassemble_info): Likewise.
13653 (arc_insn_get_branch_target): Likewise.
13654 (arc_insn_get_linear_next_pc): Likewise.
13655 * NEWS: Mention new "maint print arc arc-instruction".
13656
13657 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13658
13659 * arc-tdep (maintenance_print_arc_list): New variable.
13660 (maintenance_print_arc_command): New function.
13661
13662 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13663
13664 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
13665 Add "limm" and "reserved".
13666 (arc_cannot_fetch_register, arc_cannot_store_register): Add
13667 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
13668 * arc-tdep.h (arc_regnum): Likewise.
13669
13670 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13671
13672 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
13673 for THREADPTR register.
13674 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
13675 register.
13676 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
13677 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
13678 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
13679
13680 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13681
13682 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
13683 registers above gdbarch_num_regs (gdbarch) as privileged in
13684 call0 ABI.
13685
13686 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13687
13688 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
13689 for a single specified register or for all registers in
13690 a0_base..a0_base + C0_NREGS range.
13691 (supply_gregset_reg): Call regcache_raw_supply for a single
13692 specified register or for all registers in a0_base..a0_base +
13693 C0_NREGS range.
13694
13695 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13696
13697 * arch/xtensa.h (C0_NREGS): Add definition.
13698 * xtensa-tdep.c (C0_NREGS): Remove definition.
13699
13700 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13701
13702 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
13703 Drop xtensa_default_isa initialization.
13704 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
13705
13706 2017-03-27 Pedro Alves <palves@redhat.com>
13707
13708 * dwarf2read.c (file_entry) <dir_index>: Add comment.
13709 (file_entry::include_dir): New method.
13710 (line_header::include_dir_at, line_header::file_name_at): New
13711 methods.
13712 (setup_type_unit_groups, setup_type_unit_groups)
13713 (psymtab_include_file_name): Simplify using the new methods.
13714 (lnp_state_machine) <the_line_header>: New field.
13715 <file>: Add comment.
13716 (lnp_state_machine::current_file): New method.
13717 (dwarf_record_line): Simplify using the new methods.
13718 (init_lnp_state_machine): Initialize the "the_line_header" field.
13719 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
13720 Simplify using the new methods.
13721
13722 2017-03-27 Pedro Alves <palves@redhat.com>
13723
13724 * cp-name-parser.y (make_empty): Delete.
13725 (demangler_special, nested_name, ptr_operator, array_indicator)
13726 (direct_declarator, declarator_1): Use fill_comp instead of
13727 make_empty.
13728
13729 2017-03-27 Pedro Alves <palves@redhat.com>
13730
13731 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
13732 to ATTRIBUTE_PRINTF.
13733 * solib-target.c (library_list_start_list): Print "string" not
13734 "version".
13735 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
13736 gdb_xml_error call.
13737
13738 2017-03-27 Pedro Alves <palves@redhat.com>
13739
13740 * dwarf2read.c (struct file_and_directory): New.
13741 (dwarf2_get_dwz_file): Adjust to use std::string.
13742 (dw2_get_file_names_reader): Adjust to use file_and_directory.
13743 (find_file_and_directory): Adjust to return a file_and_directory
13744 object.
13745 (read_file_scope): Adjust to use file_and_directory. Remove
13746 make_cleanup/do_cleanups calls.
13747 (open_and_init_dwp_file): Adjust to use std::string. Remove
13748 make_cleanup/do_cleanups calls.
13749 * python/python.c (do_start_initialization): Adjust to ldirname
13750 returning a std::string.
13751 * utils.c (ldirname): Now returns a std::string.
13752 * utils.h (ldirname): Change return type to std::string.
13753 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
13754 returning a std::string.
13755 * xml-tdesc.c (file_read_description_xml): Likewise.
13756
13757 2017-03-24 Alan Hayward <alan.hayward@arm.com>
13758
13759 * regcache.c (regcache_debug_print_register): New function.
13760 * regcache.h (regcache_debug_print_register): New declaration.
13761 * target.c (debug_print_register): Remove.
13762 (target_fetch_registers): Call regcache_debug_print_register.
13763 (target_store_registers): Likewise.
13764
13765 2017-03-24 Pádraig Brady <pbrady@fb.com>
13766
13767 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
13768 reference beyond the 'lh->include_dirs' array before accessing to
13769 it.
13770 (psymtab_include_file_name): Likewise.
13771 (dwarf_decode_lines_1): Likewise.
13772 (dwarf_decode_lines): Likewise.
13773 (file_file_name): Likewise.
13774
13775 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
13776
13777 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
13778 inferior_ptid.
13779 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
13780 ps_lsetfpregs): Likewise.
13781 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
13782 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
13783 ps_lsetfpregs): Likewise.
13784 * target.c (target_fetch_registers, target_store_registers):
13785 Remove asserts.
13786
13787 2017-03-23 Alan Hayward <alan.hayward@arm.com>
13788
13789 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
13790
13791 2017-03-23 Yao Qi <yao.qi@linaro.org>
13792
13793 * aarch64-tdep.c (aarch64_process_record_test): Declare.
13794 (_initialize_aarch64_tdep): Register it.
13795 (aarch64_record_load_store): Handle PRFM instruction.
13796 (aarch64_process_record_test): New function.
13797
13798 2017-03-23 Yao Qi <yao.qi@linaro.org>
13799
13800 * aarch64-tdep.c (aarch64_record_load_store): Fix code
13801 indentation.
13802
13803 2017-03-23 Yao Qi <yao.qi@linaro.org>
13804
13805 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
13806
13807 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13808
13809 python/python.c (do_start_initialization): Fix memory leak.
13810
13811 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
13812
13813 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
13814 using get_ptrace_pid.
13815 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
13816 inferior_ptid.
13817 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
13818 inferior_ptid instead of pid.
13819
13820 2017-03-22 Yao Qi <yao.qi@linaro.org>
13821
13822 * aarch64-tdep.c: Wrap locally used classes in anonymous
13823 namespace.
13824 * arm-tdep.c: Likewise.
13825 * linespec.c: Likewise.
13826 * ui-out.c: Likewise.
13827
13828 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
13829
13830 PR gdb/19637
13831 * python/lib/gdb/printer/bound_registers.py: Import sys.
13832
13833 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
13834
13835 * windows-nat.c (do_windows_fetch_inferior_registers): Add
13836 windows_thread_info parameter and use it instead of
13837 current_thread.
13838 (windows_fetch_inferior_registers): Don't set current_thread,
13839 pass the thread to do_windows_fetch_inferior_registers. Use
13840 ptid from regcache instead of inferior_ptid.
13841 (do_windows_store_inferior_registers): Add windows_thread_info
13842 parameter and use it instead of current_thread.
13843 (windows_store_inferior_registers): Don't set current_thread,
13844 pass the thread to do_windows_store_inferior_registers. Use
13845 ptid from regcache instead of inferior_ptid.
13846
13847 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
13848
13849 * ser-mingw.c (ser_windows_raw): Remove reference to
13850 struct serial::current_timeout.
13851
13852 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
13853
13854 PR tdep/20928
13855 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
13856 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
13857 (sparc64_fsr_type): Fix %fsr decoding.
13858
13859 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
13860
13861 * python/py-record-btrace.c (btpy_insn_data): Change return type
13862 for Python 2.
13863
13864 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
13865
13866 * spu-linux-nat.c (spu_fetch_inferior_registers,
13867 spu_store_inferior_registers): Use ptid from regcache, set and
13868 restore inferior_ptid.
13869 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
13870 Likewise.
13871
13872 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
13873
13874 * i386-linux-nat.c (fetch_register, store_register,
13875 i386_linux_fetch_inferior_registers,
13876 i386_linux_store_inferior_registers): Use ptid from regcache.
13877 * ia64-linux-nat.c (ia64_linux_fetch_register,
13878 ia64_linux_store_register): Likewise.
13879 * inf-ptrace.c (inf_ptrace_fetch_register,
13880 inf_ptrace_store_register): Likewise.
13881 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
13882 m32r_linux_store_inferior_registers): Likewise.
13883 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
13884 m68kbsd_store_inferior_registers): Likewise.
13885 * m68k-linux-nat.c (fetch_register, store_register,
13886 m68k_linux_fetch_inferior_registers,
13887 m68k_linux_store_inferior_registers): Likewise.
13888 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
13889 m88kbsd_store_inferior_registers): Likewise.
13890 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
13891 mips_fbsd_store_inferior_registers): Likewise.
13892 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
13893 mips64_linux_regsets_store_registers): Likewise.
13894 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
13895 mipsnbsd_store_inferior_registers): Likewise.
13896 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
13897 mips64obsd_store_inferior_registers): Likewise.
13898 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
13899 Likewise.
13900 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
13901 ppcfbsd_store_inferior_registers): Likewise.
13902 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
13903 ppc_linux_store_inferior_registers): Likewise.
13904 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
13905 ppcnbsd_store_inferior_registers): Likewise.
13906 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
13907 ppcobsd_store_registers): Likewise.
13908 * procfs.c (procfs_fetch_registers, procfs_store_registers):
13909 Likewise.
13910 * ravenscar-thread.c (ravenscar_fetch_registers,
13911 ravenscar_store_registers, ravenscar_prepare_to_store):
13912 Likewise.
13913 * record-btrace.c (record_btrace_fetch_registers,
13914 record_btrace_store_registers, record_btrace_prepare_to_store):
13915 Likewise.
13916 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
13917 Lookup inferior using ptid from regcache, instead of
13918 current_inferior.
13919 * remote.c (remote_fetch_registers, remote_store_registers): Use
13920 ptid from regcache.
13921 * rs6000-nat.c (fetch_register, store_register): Likewise.
13922 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
13923 s390_linux_store_inferior_registers): Likewise.
13924 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
13925 shnbsd_store_inferior_registers): Likewise.
13926 * sol-thread.c (sol_thread_fetch_registers,
13927 sol_thread_store_registers): Likewise.
13928 * sparc-nat.c (sparc_fetch_inferior_registers,
13929 sparc_store_inferior_registers): Likewise.
13930 * tilegx-linux-nat.c (fetch_inferior_registers,
13931 store_inferior_registers): Likewise.
13932 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
13933 vaxbsd_store_inferior_registers): Likewise.
13934 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
13935 store_xtregs): Likewise.
13936
13937 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13938
13939 PR gdb/14441
13940 * NEWS: Mention support for rvalue references in GDB and python.
13941 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
13942 supports both lvalue and rvalue references.
13943
13944 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13945
13946 PR gdb/14441
13947 * gdbtypes.c (rank_one_type): Implement overloading
13948 resolution rules regarding rvalue references.
13949
13950 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13951
13952 PR gdb/14441
13953 * aarch64-tdep.c (aarch64_type_align)
13954 (aarch64_extract_return_value, aarch64_store_return_value): Change
13955 lvalue reference type checks to general reference type checks.
13956 * amd64-tdep.c (amd64_classify): Likewise.
13957 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
13958 Likewise.
13959 * arm-tdep.c (arm_type_align, arm_extract_return_value)
13960 (arm_store_return_value): Likewise.
13961 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
13962 * c-typeprint.c (c_print_type): Likewise.
13963 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
13964 (cplus_number_of_children, cplus_describe_child): Likewise.
13965 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
13966 * completer.c (expression_completer): Likewise.
13967 * cp-support.c (make_symbol_overload_list_adl_namespace):
13968 Likewise.
13969 * darwin-nat-info.c (info_mach_region_command): Likewise.
13970 * dwarf2loc.c (entry_data_value_coerce_ref)
13971 (value_of_dwarf_reg_entry): Likewise.
13972 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
13973 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
13974 Likewise.
13975 * findvar.c (extract_typed_address, store_typed_address):
13976 Likewise.
13977 * gdbtypes.c (rank_one_type): Likewise.
13978 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
13979 * infcall.c (value_arg_coerce): Likewise.
13980 * language.c (pointer_type): Likewise.
13981 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
13982 Likewise.
13983 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
13984 * mn10300-tdep.c (mn10300_type_align): Likewise.
13985 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
13986 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
13987 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
13988 Likewise.
13989 * printcmd.c (print_formatted, x_command): Likewise.
13990 * python/py-type.c (typy_get_composite, typy_template_argument):
13991 Likewise.
13992 * python/py-value.c (valpy_referenced_value)
13993 (valpy_get_dynamic_type, value_has_field): Likewise.
13994 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
13995 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
13996 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
13997 * spu-tdep.c (spu_scalar_value_p): Likewise.
13998 * symtab.c (lookup_symbol_aux): Likewise.
13999 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
14000 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
14001 Likewise.
14002 * valops.c (value_cast_pointers, value_cast)
14003 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
14004 (value_struct_elt, value_struct_elt_bitpos)
14005 (value_find_oload_method_list, find_overload_match)
14006 (value_rtti_indirect_type): Likewise.
14007 * valprint.c (val_print_scalar_type_p, generic_val_print):
14008 Likewise.
14009 * value.c (value_actual_type, value_as_address, unpack_long)
14010 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
14011 (coerce_ref): Likewise.
14012 * varobj.c (varobj_get_value_type): Likewise.
14013
14014 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14015
14016 PR gdb/14441
14017 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
14018 table of constants.
14019 * python/lib/gdb/command/explore.py: Support exploring values
14020 of rvalue reference types.
14021 * python/lib/gdb/types.py: Implement get_basic_type() for
14022 rvalue reference types.
14023 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
14024 constant.
14025 * python/py-value.c (valpy_getitem): Add an rvalue reference
14026 check.
14027 (valpy_reference_value): Add new parameter "refcode".
14028 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
14029 New wrappers for valpy_reference_value().
14030 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
14031 (gdbpy_invoke_xmethod): Likewise.
14032
14033 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14034
14035 PR gdb/14441
14036 * dwarf2read.c (process_die, read_type_die_1): Handle the
14037 DW_TAG_rvalue_reference_type DIE.
14038 (read_tag_reference_type): Add new parameter "refcode".
14039
14040 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14041
14042 PR gdb/14441
14043 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
14044 (c_type_print_modifier, c_type_print_varspec_suffix)
14045 (c_type_print_base): Support printing rvalue reference types.
14046 * c-valprint.c (c_val_print, c_value_print): Support printing
14047 rvalue reference values.
14048
14049 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14050
14051 PR gdb/14441
14052 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
14053 typename.
14054 * cp-support.c (replace_typedefs): Handle
14055 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
14056 * python/py-type.c (typy_lookup_type): Likewise.
14057
14058 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14059
14060 PR gdb/14441
14061 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
14062 * parse.c (insert_type): Change assert statement.
14063 (follow_types): Handle rvalue reference types.
14064 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
14065 constant.
14066
14067 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14068
14069 PR gdb/14441
14070 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
14071 value_ref() interface.
14072 * c-valprint.c (c_value_print): Likewise.
14073 * infcall.c (value_arg_coerce): Likewise.
14074 * python/py-value.c (valpy_reference_value): Likewise.
14075 * valops.c (value_cast, value_reinterpret_cast)
14076 (value_dynamic_cast, typecmp): Likewise.
14077 (value_ref): Parameterize by kind of return value reference type.
14078 * value.h (value_ref): Add new parameter "refcode".
14079
14080 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14081
14082 PR gdb/14441
14083 * dwarf2read.c (read_tag_reference_type): Use
14084 lookup_lvalue_reference_type() instead of lookup_reference_type().
14085 * eval.c (evaluate_subexp_standard): Likewise.
14086 * f-exp.y: Likewise.
14087 * gdbtypes.c (make_reference_type, lookup_reference_type):
14088 Generalize with rvalue reference types.
14089 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
14090 convenience wrappers for lookup_reference_type().
14091 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
14092 reference kind parameter.
14093 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
14094 wrappers for lookup_reference_type().
14095 * guile/scm-type.c (gdbscm_type_reference): Use
14096 lookup_lvalue_reference_type() instead of lookup_reference_type().
14097 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
14098 * parse.c (follow_types): Likewise.
14099 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
14100 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
14101 Likewise.
14102 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
14103 (gdbpy_invoke_xmethod): Likewise.
14104 * stabsread.c: Provide extra argument to make_reference_type()
14105 call.
14106 * valops.c (value_ref, value_rtti_indirect_type): Use
14107 lookup_lvalue_reference_type() instead of lookup_reference_type().
14108
14109 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14110
14111 PR gdb/14441
14112 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
14113 (TYPE_IS_REFERENCE): New macro.
14114 (struct type): Add rvalue_reference_type field.
14115 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
14116
14117 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
14118
14119 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
14120 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
14121 New function definition.
14122 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
14123 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
14124 New function declaration.
14125 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
14126 * mi/mi-interp.h: New file.
14127 * solib.c (info_sharedlibrary_command): Replace for loop with
14128 ALL_SO_LIBS macro
14129 * solib.h (update_solib_list): New function declaration.
14130 (so_list_head): Move macro.
14131 * solist.h (ALL_SO_LIBS): New macro.
14132
14133 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
14134
14135 * infcmd.c (post_create_inferior): Remove unused argument in
14136 call to solib_add.
14137 * remote.c (remote_start_remote): Likewise.
14138 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
14139 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
14140 (enable_break): Likewise.
14141 * solib.c (update_solib_list): Remove unused target argument
14142 and its documentation.
14143 (solib_add): Remove unused target argument. Remove unused
14144 argument in call to update_solib_list.
14145 (info_sharedlibrary_command): Remove unused argument in call
14146 to update_solib_list.
14147 (sharedlibrary_command): Remove unused argument in call to
14148 solib_add.
14149 (handle_solib_event): Likewise.
14150 (reload_shared_libraries): Likewise.
14151 * solib.h (solib_add): Remove unused target argument.
14152
14153 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
14154
14155 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
14156 (s390_displaced_step_fixup): Cover relative branches with the
14157 default fixup handling. This fixes lack of support for some
14158 relative branch instructions.
14159
14160 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14161
14162 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
14163 ptid from regcache.
14164
14165 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14166
14167 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
14168 i386_darwin_store_inferior_registers): Use ptid from regcache.
14169
14170 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14171
14172 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
14173 i386bsd_store_inferior_registers): Use ptid from regcache.
14174
14175 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14176
14177 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
14178 hppaobsd_store_registers): Use ptid from regcache.
14179
14180 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14181
14182 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
14183 hppanbsd_store_registers): Use ptid from regcache.
14184
14185 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14186
14187 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
14188 from regcache. Use get_ptrace_pid.
14189
14190 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14191
14192 * corelow.c (get_core_register_section): Use ptid from regcache,
14193 update doc.
14194
14195 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14196
14197 * bsd-uthread.c (bsd_uthread_fetch_registers,
14198 bsd_uthread_store_registers): Use ptid from regcache, set and
14199 restore inferior_ptid.
14200
14201 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14202
14203 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
14204 fetch_fp_regs, store_register, store_regs, store_fp_register,
14205 store_fp_regs): Use ptid from regcache.
14206
14207 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14208
14209 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
14210 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
14211 store_vfp_regs): Use ptid from regcache.
14212
14213 2017-03-17 Pedro Alves <palves@redhat.com>
14214
14215 PR remote/21188
14216 * ser-base.c (ser_base_wait_for): Add comment.
14217 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
14218 version.
14219 * ser-unix.c (hardwire_raw): Remove reference to
14220 scb->current_timeout.
14221 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
14222 (hardwire_ops): Install ser_base_readchar instead of
14223 hardwire_readchar.
14224 * serial.h (struct serial) <current_timeout, timeout_remaining>:
14225 Remove fields.
14226
14227 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
14228
14229 PR gdb/19637
14230 * python/lib/gdb/printer/bound_registers.py: Add support for
14231 Python 3.
14232
14233 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
14234
14235 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
14236 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
14237 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
14238 byte_offset to subobj_byte_offset. Fix the handling of
14239 DWARF_VALUE_STACK on big-endian targets when coming via an
14240 implicit pointer.
14241 (dwarf2_evaluate_loc_desc): Adjust call to
14242 dwarf2_evaluate_loc_desc_full.
14243 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
14244 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
14245
14246 2017-03-16 Yao Qi <yao.qi@linaro.org>
14247
14248 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
14249 and REVSH instructions.
14250
14251 2017-03-16 Yao Qi <yao.qi@linaro.org>
14252
14253 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
14254 (arm_record_test): Declare.
14255 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
14256 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
14257 align with the manual.
14258 (thumb_record_misc): Adjust the code order to align with the
14259 manual.
14260 (thumb2_record_decode_insn_handler): Fix instruction matching.
14261 (instruction_reader_thumb): New class.
14262 (arm_record_test): New function.
14263
14264 2017-03-16 Yao Qi <yao.qi@linaro.org>
14265
14266 * arm-tdep.c (abstract_memory_reader): New class.
14267 (instruction_reader): New class.
14268 (extract_arm_insn): Add argument 'reader'. Callers updated.
14269 (decode_insn): Likewise.
14270
14271 2017-03-16 Doug Evans <dje@google.com>
14272
14273 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
14274 member. Change type of TYPE member to SCM. All uses updated.
14275 (lsscm_make_lazy_string_smob): Add assert.
14276 (lsscm_make_lazy_string): Flag bad length values.
14277 (lsscm_elt_type): New function.
14278 (gdbscm_lazy_string_to_value): Rewrite to use
14279 lsscm_safe_lazy_string_to_value.
14280 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
14281 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
14282 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
14283 in incoming type.
14284 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
14285 * guile/scm-type.c (tyscm_scm_to_type): New function.
14286
14287 2017-03-15 Doug Evans <dje@google.com>
14288
14289 PR python/17728, python/18439, python/18779
14290 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
14291 member. Change type of TYPE member to PyObject *. All uses updated.
14292 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
14293 (gdbpy_create_lazy_string_object): Flag bad length values.
14294 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
14295 Handle typedefs in incoming type.
14296 (stpy_lazy_string_elt_type): New function.
14297 (gdbpy_extract_lazy_string): Call it.
14298 * python/py-value.c (valpy_lazy_string): Flag bad length values.
14299 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
14300 typedefs in incoming type.
14301
14302 2017-03-16 Doug Evans <dje@google.com>
14303
14304 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
14305 * guile/scm-type.c (tyscm_scm_to_type): New function.
14306
14307 2017-03-16 Jiong Wang <jiong.wang@arm.com>
14308
14309 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
14310 "ULONGEST" for "skip".
14311
14312 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
14313
14314 PR gdb/21220
14315 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
14316 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
14317 (inf_ptrace_peek_poke): ...here. New function. Now also loop
14318 over ptrace peek/poke until end of buffer or error.
14319
14320 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
14321
14322 * parse.c (length_of_subexp): Make static.
14323 * parser-defs.h (length_of_subexp): Remove.
14324
14325 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
14326
14327 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
14328 as well.
14329
14330 2017-03-14 Pedro Alves <palves@redhat.com>
14331
14332 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
14333 (main): Use std::unique_ptr. Remove calls to
14334 cp_demangled_name_parse_free.
14335
14336 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14337
14338 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
14339 alphabsd_store_inferior_registers): Use regcache->ptid instead
14340 of inferior_ptid.
14341
14342 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14343
14344 * aix-thread.c (aix_thread_fetch_registers,
14345 aix_thread_store_registers): Use regcache->ptid instead of
14346 inferior_ptid.
14347
14348 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14349
14350 * aarch64-linux-nat.c (fetch_gregs_from_thread,
14351 store_gregs_to_thread, fetch_fpregs_from_thread,
14352 store_fpregs_to_thread): Use regcache->ptid instead of
14353 inferior_ptid.
14354
14355 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14356
14357 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
14358 amd64_linux_fetch_inferior_registers): Use regcache->ptid
14359 instead of inferior_ptid.
14360
14361 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14362
14363 * target.c (target_fetch_registers, target_store_registers): Add
14364 assert.
14365
14366 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14367
14368 * regcache.h (regcache_get_ptid): New function.
14369 * regcache.c (regcache_get_ptid): New function.
14370
14371 2017-03-13 Mark Wielaard <mark@klomp.org>
14372
14373 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
14374
14375 2017-03-10 Keith Seitz <keiths@redhat.com>
14376
14377 PR c++/8218
14378 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
14379
14380 2017-03-08 Pedro Alves <palves@redhat.com>
14381
14382 PR gdb/18360
14383 * infrun.c (start_step_over, do_target_resume, resume)
14384 (restart_threads): Assert we're not resuming a thread that is
14385 meant to be stopped.
14386 (infrun_thread_stop_requested_callback): Delete.
14387 (infrun_thread_stop_requested): If the thread is internally
14388 stopped, queue a pending stop event and clear the thread's
14389 inline-frame state.
14390 (handle_stop_requested): New function.
14391 (handle_syscall_event, handle_inferior_event_1): Use
14392 handle_stop_requested.
14393 (handle_stop_requested): New function.
14394 (handle_signal_stop): Set the thread's stop_signal here instead of
14395 at caller.
14396 (finish_step_over): Clear step over info unconditionally.
14397 (handle_signal_stop): If the user had interrupted the event
14398 thread, consider the stop a random signal.
14399 (handle_signal_stop) <signal arrived while stepping over
14400 breakpoint>: Don't restart threads here.
14401 (stop_waiting): Don't clear step-over info here.
14402
14403 2017-03-08 Pedro Alves <palves@redhat.com>
14404
14405 PR 21206
14406 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
14407 goes to argument 2, not 1.
14408
14409 2017-03-08 Pedro Alves <palves@redhat.com>
14410
14411 PR cli/21218
14412 * top.c (gdb_readline_wrapper): Avoid passing NULL to
14413 display_gdb_prompt.
14414 (command_line_input): Add comment.
14415
14416 2017-03-08 Pedro Alves <palves@redhat.com>
14417
14418 PR tui/21216
14419 * tui/tui-file.c (tui_file::write): New.
14420 * tui/tui-file.h (tui_file): Override "write".
14421 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
14422 factored out from ...
14423 (tui_puts): ... here.
14424 (tui_putc): Use them.
14425 (tui_write): New function.
14426 * tui/tui-io.h (tui_write): Declare.
14427
14428 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
14429
14430 * Makefile.in (SFILES): Replace "environ.c" with
14431 "common/environ.c".
14432 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
14433 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
14434 to...
14435 * common/environ.c: ... here.
14436 * environ.h: Moved to...
14437 * common/environ.h: ... here.
14438
14439 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
14440
14441 * gdbarch.sh (pstring_ptr): New static function.
14442 (gdbarch_disassembler_options): Use it.
14443 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
14444 not valid_disassembler_option->name.
14445 * gdbarch.c: Regenerate.
14446
14447 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
14448
14449 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
14450
14451 2017-03-07 Pedro Alves <palves@redhat.com>
14452
14453 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
14454
14455 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
14456
14457 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
14458 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
14459 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
14460 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
14461
14462 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
14463
14464 * xtensa-linux-nat.c (fetch_gregs): Remove const.
14465
14466 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
14467
14468 * remote.c (remote_add_target_side_commands): Use range-based
14469 for loop.
14470
14471 2017-03-03 Yao Qi <yao.qi@linaro.org>
14472
14473 PR gdb/21165
14474 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
14475 value is lazy.
14476 * valprint.c (common_val_print): Likewise.
14477
14478 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
14479
14480 * NEWS: Mention new set/show disassembler-options commands.
14481 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
14482 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
14483 (prospective_options): New static variable.
14484 (gdb_disassembler::gdb_disassembler): Initialize
14485 m_di.disassembler_options.
14486 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
14487 (get_disassembler_options): New function.
14488 (set_disassembler_options): Likewise.
14489 (set_disassembler_options_sfunc): Likewise.
14490 (show_disassembler_options_sfunc): Likewise.
14491 (disassembler_options_completer): Likewise.
14492 (_initialize_disasm): Likewise.
14493 * disasm.h (get_disassembler_options): New prototype.
14494 (set_disassembler_options): Likewise.
14495 * gdbarch.sh (gdbarch_disassembler_options): New variable.
14496 (gdbarch_verify_disassembler_options): Likewise.
14497 * gdbarch.c: Regenerate.
14498 * gdbarch.h: Likewise.
14499 * arm-tdep.c (num_disassembly_options): Delete.
14500 (set_disassembly_style): Likewise.
14501 (arm_disassembler_options): New static variable.
14502 (set_disassembly_style_sfunc): Convert short style name into long
14503 option name. Call set_disassembler_options.
14504 (show_disassembly_style_sfunc): New function.
14505 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
14506 set_gdbarch_verify_disassembler_options.
14507 (_initialize_arm_tdep): Delete regnames variable and update callers.
14508 (arm_disassembler_options): Initialize.
14509 (disasm_options): New variable.
14510 (num_disassembly_options): Rename from this...
14511 (num_disassembly_styles): ...to this. Compute by scanning through
14512 disasm_options.
14513 (valid_disassembly_styles): Initialize using disasm_options.
14514 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
14515 set_arm_regname_option.
14516 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
14517 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
14518 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
14519 set_gdbarch_verify_disassembler_options.
14520 * s390-tdep.c (s390_disassembler_options): New static variable.
14521 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
14522 set_gdbarch_verify_disassembler_options.
14523
14524 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
14525
14526 * remote.c (remote_add_target_side_condition): Remove "struct"
14527 keyword from range-based for loop.
14528
14529 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
14530
14531 * remote.c (remote_add_target_side_condition): Use range-based
14532 for loop. Update comment.
14533
14534 2017-02-27 Yao Qi <yao.qi@linaro.org>
14535
14536 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
14537
14538 2017-02-26 Alan Hayward <alan.hayward@arm.com>
14539
14540 * regcache.c (regcache_raw_update): New function.
14541 (regcache_raw_read): Move code to regcache_raw_update.
14542 * regcache.h (regcache_raw_update): New declaration.
14543 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
14544
14545 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
14546
14547 * dwarf2read.c (create_debug_type_hash_table): Initialize
14548 header.signature and header.type_offset_in_tu.
14549
14550 2017-02-24 Pedro Alves <palves@redhat.com>
14551
14552 * symtab.c (make_file_symbol_completion_list_1): Use
14553 add_symtab_completions.
14554
14555 2017-02-24 Alan Hayward <alan.hayward@arm.com>
14556
14557 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
14558
14559 2017-02-24 Alan Hayward <alan.hayward@arm.com>
14560
14561 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
14562 I386_MAX_REGISTER_SIZE.
14563 (i386_pseudo_register_write): Likewise.
14564 (i386_process_record): Likewise.
14565 * i387-tdep.c (i387_supply_xsave): Likewise.
14566 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
14567 (store_register): Likewise.
14568
14569 2017-02-23 Pedro Alves <palves@redhat.com>
14570
14571 * ada-lang.c: Include "common/function-view.h".
14572 (ada_iterate_over_symbols): Adjust to use function_view as
14573 callback type.
14574 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
14575 (ada_make_symbol_completion_list): Use a lambda.
14576 (ada_exc_search_name_matches): Delete.
14577 (name_matches_regex): New.
14578 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
14579 * compile/compile-c-support.c: Include "common/function-view.h".
14580 (print_one_macro): Change prototype to accept a ui_file pointer.
14581 (write_macro_definitions): Use a lambda.
14582 * dwarf2read.c: Include "common/function-view.h".
14583 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
14584 (dw2_expand_symtabs_matching): Adjust to use function_view as
14585 callback type.
14586 * language.h: Include "common/function-view.h".
14587 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
14588 function_view as callback type.
14589 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
14590 * linespec.c: Include "common/function-view.h".
14591 (collect_info::add_symbol): New method.
14592 (struct symbol_and_data_callback, iterate_inline_only, struct
14593 symbol_matcher_data, iterate_name_matcher): Delete.
14594 (iterate_over_all_matching_symtabs): Adjust to use function_view
14595 as callback type and lambdas.
14596 (iterate_over_file_blocks): Adjust to use function_view as
14597 callback type.
14598 (decode_compound_collector): Now a class with private fields.
14599 (decode_compound_collector::release_symbols): New method.
14600 (collect_one_symbol): Rename to...
14601 (decode_compound_collector::operator()): ... this and adjust.
14602 (lookup_prefix_sym): decode_compound_collector construction bits
14603 move to decode_compound_collector ctor. Pass the
14604 decode_compound_collector object directly as callback. Remove
14605 cleanups and use decode_compound_collector::release_symbols
14606 instead.
14607 (symtab_collector): Now a class with private fields.
14608 (symtab_collector::release_symtabs): New method.
14609 (add_symtabs_to_list): Rename to...
14610 (symtab_collector::operator()): ... this and adjust.
14611 (collect_symtabs_from_filename): symtab_collector construction
14612 bits move to symtab_collector ctor. Pass the symtab_collector
14613 object directly as callback. Remove cleanups and use
14614 symtab_collector::release_symtabs instead.
14615 (collect_symbols): Delete.
14616 (add_matching_symbols_to_info): Use lambdas.
14617 * macrocmd.c (print_macro_callback): Delete.
14618 (info_macro_command): Use a lambda.
14619 (info_macros_command): Pass print_macro_definition as callable
14620 directly.
14621 (print_one_macro): Remove 'ignore' parameter.
14622 (macro_list_command): Adjust.
14623 * macrotab.c (macro_for_each_data::fn): Now a function_view.
14624 (macro_for_each_data::user_data): Delete field.
14625 (foreach_macro): Adjust to call the function_view.
14626 (macro_for_each): Adjust to use function_view as callback type.
14627 (foreach_macro_in_scope): Adjust to call the function_view.
14628 (macro_for_each_in_scope): Adjust to use function_view as callback
14629 type.
14630 * macrotab.h: Include "common/function-view.h".
14631 (macro_callback_fn): Declare a prototype instead of a pointer.
14632 Remove "user_data" parameter.
14633 (macro_for_each, macro_for_each_in_scope): Adjust to use
14634 function_view as callback type.
14635 * psymtab.c (partial_map_expand_apply)
14636 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
14637 Adjust to use function_view as callback type and to return bool.
14638 (psym_expand_symtabs_matching): Adjust to use function_view as
14639 callback types.
14640 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
14641 to use function_view as callback type and to return bool.
14642 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
14643 callback types.
14644 * symfile.c (expand_symtabs_matching): Adjust to use function_view
14645 as callback types.
14646 * symfile.h: Include "common/function-view.h".
14647 (expand_symtabs_file_matcher_ftype)
14648 (expand_symtabs_symbol_matcher_ftype)
14649 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
14650 return bool.
14651 (quick_symbol_functions::map_symtabs_matching_filename)
14652 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
14653 function_view as callback type and return bool.
14654 (expand_symtabs_matching): Adjust to use function_view as callback
14655 type.
14656 (maintenance_expand_name_matcher)
14657 (maintenance_expand_file_matcher): Delete.
14658 (maintenance_expand_symtabs): Use lambdas.
14659 * symtab.c (iterate_over_some_symtabs): Adjust to use
14660 function_view as callback types and return bool.
14661 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
14662 of a cleanup.
14663 (lookup_symtab_callback): Delete.
14664 (lookup_symtab): Use a lambda.
14665 (iterate_over_symbols): Adjust to use function_view as callback
14666 type.
14667 (struct search_symbols_data, search_symbols_file_matches)
14668 (search_symbols_name_matches): Delete.
14669 (search_symbols): Use a pair of lambdas.
14670 (struct add_name_data, add_macro_name, symbol_completion_matcher)
14671 (symtab_expansion_callback): Delete.
14672 (default_make_symbol_completion_list_break_on_1): Use lambdas.
14673 * symtab.h: Include "common/function-view.h".
14674 (iterate_over_some_symtabs): Adjust to use function_view as
14675 callback type and return bool.
14676 (iterate_over_symtabs): Adjust to use function_view as callback
14677 type.
14678 (symbol_found_callback_ftype): Remove 'data' parameter and return
14679 bool.
14680 (iterate_over_symbols): Adjust to use function_view as callback
14681 type.
14682
14683 2017-02-23 Pedro Alves <palves@redhat.com>
14684
14685 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
14686 (%.o) <unittests/%.c>: New pattern.
14687 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
14688 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
14689 * common/function-view.h: New file.
14690 * unittests/function-view-selftests.c: New file.
14691 * configure: Regenerate.
14692
14693 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
14694
14695 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
14696 inferior_ptid.
14697 * go32-nat.c (go32_thread_alive): Likewise.
14698
14699 2017-02-23 Yao Qi <yao.qi@linaro.org>
14700
14701 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
14702 delete.
14703
14704 2017-02-23 Yao Qi <yao.qi@linaro.org>
14705
14706 * varobj.c (varobj_clear_saved_item): Use delete instead of
14707 xfree.
14708 (update_dynamic_varobj_children): Likewise.
14709
14710 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
14711
14712 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
14713
14714 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
14715
14716 * common/enum-flags.h (enum_flags::enum_flags): Initialize
14717 m_enum_value to 0 in default constructor.
14718
14719 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
14720
14721 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
14722 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
14723 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
14724 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
14725 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
14726 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
14727 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
14728 IS_STORE_CONDITIONAL_INSN.
14729
14730 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
14731
14732 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
14733
14734 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14735
14736 * NEWS (Changes since GDB 7.12): Add DWARF-5.
14737
14738 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14739
14740 * dwarf2read.c (skip_one_die, read_attribute_value)
14741 (dwarf2_const_value_attr, dump_die_shallow)
14742 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
14743 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
14744
14745 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14746
14747 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
14748 (dwarf_parse_macro_header): Accept DWARF version 5.
14749 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
14750
14751 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14752
14753 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
14754 DW_AT_GNU_*.
14755 * common/common-exceptions.h (enum errors): Likewise.
14756 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
14757 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
14758 (dwarf_expr_context::execute_stack_op): Likewise.
14759 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
14760 Likewise.
14761 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
14762 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
14763 (show_entry_values_debug, call_site_to_target_addr)
14764 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
14765 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
14766 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
14767 (value_of_dwarf_block_entry, indirect_pieced_value)
14768 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
14769 (disassemble_dwarf_expression): Likewise.
14770 * dwarf2read.c (process_die, inherit_abstract_dies)
14771 (read_call_site_scope): Likewise.
14772 * gdbtypes.h (struct func_type, struct call_site_parameter)
14773 (struct call_site): Likewise.
14774 * stack.c (read_frame_arg): Likewise.
14775 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
14776
14777 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14778
14779 * defs.h (read_unsigned_leb128): New declaration.
14780 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
14781 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
14782 (dwarf2_find_location_expression): Call also
14783 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
14784 * dwarf2loc.h (dwarf2_version): New declaration.
14785 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
14786 rnglists.
14787 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
14788 .debug_rnglists.
14789 (struct dwop_section_names): Add loclists_dwo.
14790 (dwop_section_names): Add .debug_loclists.dwo.
14791 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
14792 (struct dwarf2_per_cu_data): Add dwarf_version.
14793 (struct dwo_sections): Add loclists.
14794 (struct attr_abbrev): Add implicit_const.
14795 (read_indirect_line_string): New declaration.
14796 (read_unsigned_leb128): Delete declaration.
14797 (rcuh_kind): New definition.
14798 (read_and_check_comp_unit_head): Change parameter
14799 is_debug_types_section to section_kind.
14800 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
14801 (read_comp_unit_head): Change parameter abfd to section, add parameter
14802 section_kind. Handle DWARF-5.
14803 (error_check_comp_unit_head): Accept also DWARF version 5.
14804 (read_and_check_comp_unit_head): Change parameter
14805 is_debug_types_section to section_kind.
14806 (read_and_check_type_unit_head): Delete function.
14807 (read_abbrev_offset): Handle DWARF-5.
14808 (create_debug_type_hash_table): Add parameter section_kind. Process
14809 only DW_UT_type. Use signature and type_offset_in_tu from struct
14810 comp_unit_head.
14811 (create_debug_types_hash_table): Update create_debug_type_hash_table
14812 caller.
14813 (create_all_type_units): Call create_debug_type_hash_table.
14814 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
14815 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
14816 caller.
14817 (skip_one_die): Handle DW_FORM_implicit_const.
14818 (dwarf2_rnglists_process): New function.
14819 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
14820 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
14821 (read_attribute_value): Handle DW_FORM_implicit_const,
14822 DW_FORM_line_strp.
14823 (read_attribute): Handle DW_FORM_implicit_const.
14824 (read_indirect_string_at_offset_from): New function from
14825 read_indirect_string_at_offset.
14826 (read_indirect_string_at_offset): Call
14827 read_indirect_string_at_offset_from.
14828 (read_indirect_line_string_at_offset): New function.
14829 (read_indirect_string): New function comment.
14830 (read_indirect_line_string): New function.
14831 (read_unsigned_leb128): Make it global.
14832 (dwarf2_string_attr): Handle DWARF-5.
14833 (add_include_dir_stub, read_formatted_entries): New functions.
14834 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
14835 Handle DWARF-5.
14836 (per_cu_header_read_in): Update read_comp_unit_head caller.
14837 (dwarf2_version): New function.
14838 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
14839 rnglists.
14840 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
14841 fields.
14842
14843 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14844
14845 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
14846
14847 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14848
14849 * dwarf2read.c (dwarf2_ranges_process): New function from
14850 dwarf2_ranges_read.
14851 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
14852 dwarf2_ranges_process.
14853
14854 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14855
14856 * dwarf2read.c (create_debug_type_hash_table): New function from
14857 create_debug_types_hash_table.
14858 (create_debug_types_hash_table): Call create_debug_type_hash_table.
14859 (create_all_type_units, open_and_init_dwo_file): Update
14860 create_debug_types_hash_table callers.
14861
14862 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
14863
14864 PR gdb/16188
14865 * fork-child.c (trace_start_error): Fix thinko. va_end should
14866 refer to 'ap', not 'args'.
14867
14868 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
14869 Pedro Alves <palves@redhat.com>
14870
14871 PR gdb/16188
14872 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
14873 calls succeeded.
14874 * fork-child.c (trace_start_error): New function.
14875 (trace_start_error_with_name): Likewise.
14876 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
14877 * inf-ptrace.c (inf_ptrace_me): Likewise.
14878 * inferior.h (trace_start_error): New prototype.
14879 (trace_start_error_with_name): Likewise.
14880
14881 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
14882
14883 PR gdb/21164
14884 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
14885 NULL before using it.
14886 * symmisc.c (maintenance_print_symbols): Likewise.
14887 (maintenance_print_msymbols): Likewise.
14888
14889 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14890
14891 * NEWS: Add record Python bindings entry.
14892
14893 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14894
14895 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
14896 py-record-full.o.
14897 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
14898 * python/py-record-btrace.c, python/py-record-btrace.h,
14899 python/py-record-full.c, python/py-record-full.h: New file.
14900 * python/py-record.c: Add include for py-record-btrace.h and
14901 py-record-full.h.
14902 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
14903 recpy_instruction_history, recpy_function_call_history, recpy_begin,
14904 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
14905 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
14906 New definition.
14907 (gdbpy_initialize_btrace): New export.
14908 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
14909
14910 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14911
14912 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
14913 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
14914 * python/py-record.c: New file.
14915 * python/python-internal.h (gdbpy_start_recording,
14916 gdbpy_current_recording, gdpy_stop_recording,
14917 gdbpy_initialize_record): New export.
14918 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
14919 (python_GdbMethods): Add gdbpy_start_recording,
14920 gdbpy_current_recording and gdbpy_stop_recording.
14921
14922 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14923
14924 * record-btrace.c (record_btrace_record_method): New function.
14925 (init_record_btrace_ops): Initialize to_record_method.
14926 * record-full.c (record_full_record_method): New function.
14927 (init_record_full_ops, init_record_full_core_ops): Add
14928 record_full_record_method.
14929 * record.h (enum record_method): New enum.
14930 * target-debug.h (target_debug_print_enum_record_method: New define.
14931 * target-delegates.c: Regenerate.
14932 * target.c (target_record_method): New function.
14933 * target.h: Include record.h.
14934 (struct target_ops) <to_record_method>: New field.
14935 (target_record_method): New export.
14936
14937 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14938
14939 * record.h (record_start, record_stop): New export.
14940 * record.c (record_start, record_stop): New function.
14941
14942 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14943
14944 * btrace.c (btrace_fetch): Copy function call segments pointer
14945 into a vector.
14946 (btrace_clear): Clear the vector.
14947 (btrace_find_insn_by_number): Use binary search to find the correct
14948 function call segment.
14949 * btrace.h (brace_fun_p): New typedef.
14950 (struct btrace_thread_info) <functions>: New field.
14951
14952 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14953
14954 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
14955 * btrace.c (btrace_decode_error): ... here. New function.
14956 * btrace.h (btrace_decode_error): New export.
14957
14958 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14959
14960 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
14961 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
14962 btrace_find_insn_by_number): Remove special case for gaps.
14963 * btrace.h (btrace_insn_get_error): New export.
14964 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
14965 * record-btrace.c (btrace_insn_history): Print number for gaps.
14966 (record_btrace_info, record_btrace_goto): Handle gaps.
14967
14968 2017-02-14 Tom Tromey <tom@tromey.com>
14969
14970 PR python/13598:
14971 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
14972 event.
14973 * python/py-evts.c (gdbpy_initialize_py_events): Add
14974 before_prompt registry.
14975 * python/py-events.h (events_object) <before_prompt>: New field.
14976
14977 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
14978
14979 * btrace.c (ftrace_new_switch): Preserve up link and flags.
14980
14981 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
14982
14983 * symfile (_initialize_symfile): Add usage text to the load command's
14984 help text.
14985
14986 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
14987
14988 * utils.c (defaulted_query): Don't query on secondary UIs.
14989
14990 2017-02-10 Tom Tromey <tom@tromey.com>
14991
14992 * rust-lang.c (rust_get_disr_info): Remove unused variable.
14993
14994 2017-02-10 Tom Tromey <tom@tromey.com>
14995
14996 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
14997 "cleanup" local.
14998 * python/py-type.c (typy_legacy_template_argument): Remove
14999 unnecessary "cleanup" local.
15000
15001 2017-02-10 Tom Tromey <tom@tromey.com>
15002
15003 * python/python.c (do_start_initialization): New function, from
15004 _initialize_python.
15005 (_initialize_python): Call do_start_initialization.
15006 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
15007 goto.
15008
15009 2017-02-10 Tom Tromey <tom@tromey.com>
15010
15011 * python/py-prettyprint.c (pretty_print_one_value): Use
15012 gdbpy_ref.
15013
15014 2017-02-10 Tom Tromey <tom@tromey.com>
15015
15016 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
15017 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
15018 gdbpy_ref.
15019 * python/py-type.c (field_new): Use gdbpy_ref.
15020 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
15021 gdbpy_ref.
15022 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
15023 (py_free_pspace): Likewise.
15024 (pspace_to_pspace_object): Likewise.
15025 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
15026 (py_free_objfile): Likewise.
15027 (objfile_to_objfile_object): Likewise.
15028 * python/py-inferior.c (delete_thread_object): Use
15029 gdbpy_ref.
15030 (infpy_read_memory): Likewise.
15031 (py_free_inferior): Likewise.
15032 * python/py-evtregistry.c (create_eventregistry_object): Use
15033 gdbpy_ref.
15034 * python/py-event.c (create_event_object): Use gdbpy_ref.
15035
15036 2017-02-10 Tom Tromey <tom@tromey.com>
15037
15038 * python/py-ref.h (gdbpy_ref_policy): Now a template.
15039 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
15040 used.
15041 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
15042 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
15043 python/py-exitedevent.c, python/py-finishbreakpoint.c,
15044 python/py-framefilter.c, python/py-function.c,
15045 python/py-inferior.c, python/py-infevents.c,
15046 python/py-linetable.c, python/py-newobjfileevent.c,
15047 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
15048 python/py-signalevent.c, python/py-stopevent.c,
15049 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
15050 python/py-unwind.c, python/py-utils.c, python/py-value.c,
15051 python/py-varobj.c, python/py-xmethods.c, python/python.c,
15052 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
15053
15054 2017-02-10 Tom Tromey <tom@tromey.com>
15055
15056 * ui-out.h (ui_out_emit_type): New class.
15057 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
15058 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
15059 and ui_out_emit_tuple.
15060 (enumerate_locals): Likewise.
15061 (py_mi_print_variables, py_print_locals, py_print_args): Use
15062 ui_out_emit_list.
15063 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
15064 ui_out_emit_list.
15065 * common/gdb_optional.h: New file.
15066
15067 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
15068
15069 * MAINTAINERS (Write After Approval): Update my e-mail address.
15070
15071 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
15072
15073 PR gdb/21122
15074 * breakpoint.c (_initialize_breakpoint): Update the help description
15075 of the 'commands' command to indicate that it takes a list argument.
15076
15077 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
15078
15079 * interps.c (current_interp_set_logging): Remove "return".
15080
15081 2017-02-09 Gary Benson <gbenson@redhat.com>
15082
15083 * symtab.c (add_symtab_completions): Prevent NULL pointer
15084 dereference.
15085
15086 2017-02-08 Pedro Alves <palves@redhat.com>
15087
15088 * interps.c (interp::interp): Remove reference to quiet_p.
15089 (interp_set): Make static. Remove dead "Switching to" output
15090 code.
15091 (interp_quiet_p, interp_set_quiet): Delete.
15092 (interpreter_exec_cmd): Don't set the interpreter quiet.
15093 * interps.h (interp_quiet_p): Make static.
15094 (class interp) <quiet_p>: Remove field
15095
15096 2017-02-08 Jerome Guitton <guitton@adacore.com>
15097
15098 * cli/cli-decode.c (find_command_name_length): Make it extern.
15099 * cli/cli-decode.h (find_command_name_length): Declare.
15100 * cli/cli-script.c (command_name_equals, line_first_arg):
15101 New functions.
15102 (process_next_line): Use cli-decode to parse command names.
15103 (build_command_line): Make args a constant pointer.
15104
15105 2017-02-08 Jerome Guitton <guitton@adacore.com>
15106
15107 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
15108 Remove case-insensitive search.
15109
15110 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
15111
15112 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
15113 at the end of the line. Avoids an ARI warning.
15114
15115 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
15116
15117 * NEWS: Mention support for record/replay of Intel 64 rdrand and
15118 rdseed instructions.
15119 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
15120
15121 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
15122
15123 PR tdep/20936
15124 Provide and use sparc32 and sparc64 target description XML files.
15125 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
15126 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
15127 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
15128 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
15129 * features/sparc/sparc32-solaris.xml: New file.
15130 * features/sparc/sparc64-solaris.xml: New file.
15131 * features/sparc/sparc32-solaris.c: Generated.
15132 * features/sparc/sparc64-solaris.c: Generated.
15133 * sparc-tdep.h: Account for differences in target descriptions.
15134 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
15135 (sparc32_register_type): Use target provided registers.
15136 (validate_tdesc_registers): New function.
15137 (sparc32_gdbarch_init): Use tdesc_has_registers.
15138 Set pseudoregister functions.
15139 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
15140 (sparc64_register_type): Use target provided registers.
15141 (sparc64_init_abi): Set pseudoregister functions.
15142
15143 2017-02-03 Tom Tromey <tom@tromey.com>
15144
15145 PR rust/21097:
15146 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
15147 with a single member.
15148
15149 2017-02-03 Pedro Alves <palves@redhat.com>
15150
15151 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
15152 (cli_interp_base::~cli_interp_base): New.
15153 (cli_interp): New struct.
15154 (as_cli_interp): Cast the interp itself to cli_interp.
15155 (cli_interpreter_pre_command_loop): Rename to ...
15156 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
15157 parameter.
15158 (cli_interpreter_init): Rename to ...
15159 (cli_interp::init): ... this. Remove 'self' parameter. Use
15160 boolean. Make extern.
15161 (cli_interpreter_resume): Rename to ...
15162 (cli_interp::resume): ... this. Remove 'data' parameter. Make
15163 extern.
15164 (cli_interpreter_suspend): Rename to ...
15165 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
15166 extern.
15167 (cli_interpreter_exec): Rename to ...
15168 (cli_interp::exec): ... this. Remove 'data' parameter. Make
15169 extern.
15170 (cli_interpreter_supports_command_editing): Rename to ...
15171 (cli_interp_base::supports_command_editing): ... this. Remove
15172 'interp' parameter. Make extern.
15173 (cli_ui_out): Rename to ...
15174 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
15175 Make extern.
15176 (cli_set_logging): Rename to ...
15177 (cli_interp_base::set_logging): ... this. Remove 'interp'
15178 parameter. Make extern.
15179 (cli_interp_procs): Delete.
15180 (cli_interp_factory): Adjust to use "new".
15181 * cli/cli-interp.h: Include "interps.h".
15182 (struct cli_interp_base): New struct.
15183 * interps.c (struct interp): Delete. Fields moved to interps.h.
15184 (interp_new): Delete.
15185 (interp::interp, interp::~interp): New.
15186 (interp_set): Use bool, and return void. Assume the interpreter
15187 has suspend, init and resume methods, and that the all return
15188 void.
15189 (set_top_level_interpreter): interp_set returns void.
15190 (interp_ui_out): Adapt.
15191 (current_interp_set_logging): Adapt.
15192 (interp_data): Delete.
15193 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
15194 (interp_exec): Adapt.
15195 (top_level_interpreter_data): Delete.
15196 * interps.h (interp_init_ftype, interp_resume_ftype)
15197 (interp_suspend_ftype, interp_exec_ftype)
15198 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
15199 (class interp): New.
15200 (interp_new): Delete.
15201 (interp_set): Now returns void. Use bool.
15202 (interp_data, top_level_interpreter_data): Delete.
15203 * mi/mi-common.h: Include interps.h.
15204 (class mi_interp): Inherit from interp. Define a ctor. Declare
15205 init, resume, suspect, exec, interp_ui_out, set_logging and
15206 pre_command_loop methods.
15207 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
15208 (mi_interpreter_init): Rename to ...
15209 (mi_interp::init): ... this. Remove the 'interp' parameter, use
15210 bool, return void and make extern. Adjust.
15211 (mi_interpreter_resume): ... Rename to ...
15212 (mi_interp::resume): ... this. Remove the 'data' parameter,
15213 return void and make extern. Adjust.
15214 (mi_interpreter_suspend): ... Rename to ...
15215 (mi_interp::suspend): ... this. Remove the 'data' parameter,
15216 return void and make extern. Adjust.
15217 (mi_interpreter_exec): ... Rename to ...
15218 (mi_interp::exec): ... this. Remove the 'data' parameter and make
15219 extern. Adjust.
15220 (mi_interpreter_pre_command_loop): ... Rename to ...
15221 (mi_interp::pre_command_loop): ... this. Remove the 'self'
15222 parameter and make extern.
15223 (mi_on_normal_stop_1): Adjust.
15224 (mi_ui_out): Rename to ...
15225 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
15226 parameter and make extern. Adjust.
15227 (mi_set_logging): Rename to ...
15228 (mi_interp::set_logging): ... this. Remove the 'interp'
15229 parameter and make extern. Adjust.
15230 (mi_interp_procs): Delete.
15231 (mi_interp_factory): Adjust to use 'new'.
15232 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
15233 (mi_print_exception, mi_execute_command, mi_load_progress):
15234 Adjust.
15235 * tui/tui-interp.c (tui_interp): New class.
15236 (as_tui_interp): Return a tui_interp pointer.
15237 (tui_on_normal_stop, tui_on_signal_received)
15238 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
15239 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
15240 to use interp::interp_ui_out.
15241 (tui_init): Rename to ...
15242 (tui_interp::init): ... this. Remove the 'self' parameter, use
15243 bool, return void and make extern. Adjust.
15244 (tui_resume): Rename to ...
15245 (tui_interp::resume): ... this. Remove the 'data' parameter,
15246 return void and make extern. Adjust.
15247 (tui_suspend): Rename to ...
15248 (tui_interp::suspend): ... this. Remove the 'data' parameter,
15249 return void and make extern. Adjust.
15250 (tui_ui_out): Rename to ...
15251 (tui_interp::interp_ui_out): ... this. Remove the 'self'
15252 parameter, and make extern. Adjust.
15253 (tui_exec): Rename to ...
15254 (tui_interp::exec): ... this. Remove the 'data' parameter and
15255 make extern.
15256 (tui_interp_procs): Delete.
15257 (tui_interp_factory): Use "new".
15258
15259 2017-02-02 Tom Tromey <tom@tromey.com>
15260
15261 * rust-exp.y (ends_raw_string, space_then_number)
15262 (rust_identifier_start_p): Return bool.
15263 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
15264 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
15265 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
15266 (rust_chartype_p): Return bool.
15267 (val_print_struct, rust_print_struct_def, rust_print_type):
15268 Update.
15269 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
15270 Return bool.
15271
15272 2017-02-02 Tom Tromey <tom@tromey.com>
15273
15274 * rust-lang.c: Reindent.
15275
15276 2017-02-02 Tom Tromey <tom@tromey.com>
15277
15278 * rust-lang.h (rust_crate_for_block): Update.
15279 * rust-lang.c (rust_crate_for_block): Return std::string.
15280 (rust_get_disr_info): Use std:;string, not
15281 gdb::unique_xmalloc_ptr.
15282 * rust-exp.y (crate_name): Update.
15283
15284 2017-02-02 Pedro Alves <palves@redhat.com>
15285
15286 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
15287 field out of gdb_disassembler_test and make it static.
15288
15289 2017-02-02 Pedro Alves <palves@redhat.com>
15290
15291 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
15292 mi1_interp and mi_interp fields.
15293
15294 2017-02-02 Pedro Alves <palves@redhat.com>
15295
15296 * cli/cli-interp.c (struct saved_output_files, saved_output):
15297 Moved from cli/cli-logging.c.
15298 (cli_set_logging): New function.
15299 (cli_interp_procs): Install cli_set_logging.
15300 * cli/cli-interp.h (make_logging_output, cli_set_logging):
15301 Declare.
15302 * cli/cli-logging.c (struct saved_output_files, saved_output):
15303 Moved to cli/cli-interp.c.
15304 (pop_output_files): Don't save outputs here.
15305 (make_logging_output): New function.
15306 (handle_redirections): Don't build tee nor save previous outputs
15307 here.
15308 * interps.c (current_interp_set_logging): Change prototype.
15309 Assume there's always a set_logging_proc method installed.
15310 * interps.h (interp_set_logging_ftype): Change prototype.
15311 (current_interp_set_logging): Change prototype and adjust comment.
15312 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
15313 use make_logging_output.
15314 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
15315 2017-02-02 Pedro Alves <palves@redhat.com>
15316
15317 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
15318 from ...
15319 (set_logging_overwrite): ... here.
15320 (logging_no_redirect_file): Delete.
15321 (set_logging_redirect): Don't handle redirection on the fly.
15322 Instead warn that "logging off" / "logging on" is necessary.
15323 (pop_output_files): Delete references to logging_no_redirect_file.
15324 (show_logging_command): Always speak in terms of what will happen
15325 once logging is reenabled.
15326
15327 2017-02-02 Pedro Alves <palves@redhat.com>
15328
15329 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
15330
15331 2017-02-02 Pedro Alves <palves@redhat.com>
15332
15333 * disasm.c (gdb_pretty_print_insn): Rename to ...
15334 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
15335 Remove gdbarch parameter. Adapt to clear the object's buffers
15336 instead of allocating new buffers, and to print using the object's
15337 gdb_disassembler instead of calling gdb_print_insn.
15338 (dump_insns): Use gdb_pretty_print_disassembler.
15339 * disasm.h (gdb_pretty_print_insn): Delete declaration.
15340 (gdb_pretty_print_disassembler): New class.
15341 * record-btrace.c (btrace_insn_history): Use
15342 gdb_pretty_print_disassembler.
15343
15344 2017-02-02 Pedro Alves <palves@redhat.com>
15345
15346 * ada-lang.c (type_as_string): Use string_file.
15347 * ada-valprint.c (ada_print_floating): Use string_file.
15348 * ada-varobj.c (ada_varobj_scalar_image)
15349 (ada_varobj_get_value_image): Use string_file.
15350 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
15351 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
15352 * breakpoint.c (update_inserted_breakpoint_locations)
15353 (insert_breakpoint_locations, reattach_breakpoints)
15354 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
15355 (print_it_watchpoint): Use string_file.
15356 (save_breakpoints): Use stdio_file.
15357 * c-exp.y (oper): Use string_file.
15358 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
15359 tee_file.
15360 (pop_output_files): Use delete.
15361 (handle_redirections): Use stdio_file and tee_file.
15362 * cli/cli-setshow.c (do_show_command): Use string_file.
15363 * compile/compile-c-support.c (c_compute_program): Use
15364 string_file.
15365 * compile/compile-c-symbols.c (generate_vla_size): Take a
15366 'string_file &' instead of a 'ui_file *'.
15367 (generate_c_for_for_one_variable): Take a 'string_file &' instead
15368 of a 'ui_file *'. Use string_file.
15369 (generate_c_for_variable_locations): Take a 'string_file &'
15370 instead of a 'ui_file *'.
15371 * compile/compile-internal.h (generate_c_for_for_one_variable):
15372 Take a 'string_file &' instead of a 'ui_file *'.
15373 * compile/compile-loc2c.c (push, pushf, unary, binary)
15374 (print_label, pushf_register_address, pushf_register)
15375 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
15376 'ui_file *'. Adjust.
15377 * compile/compile.c (compile_to_object): Use string_file.
15378 * compile/compile.h (compile_dwarf_expr_to_c)
15379 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
15380 'ui_file *'.
15381 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
15382 (replace_typedefs_qualified_name): Use string_file and
15383 obstack_copy0.
15384 * disasm.c (gdb_pretty_print_insn): Use string_file.
15385 (gdb_disassembly): Adjust reference the null_stream global.
15386 (do_ui_file_delete): Delete.
15387 (gdb_insn_length): Use null_stream.
15388 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
15389 * dwarf2loc.c (dwarf2_compile_property_to_c)
15390 (locexpr_generate_c_location, loclist_generate_c_location): Take a
15391 'string_file &' instead of a 'ui_file *'.
15392 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
15393 * dwarf2read.c (do_ui_file_peek_last): Delete.
15394 (dwarf2_compute_name): Use string_file.
15395 * event-top.c (gdb_setup_readline): Use stdio_file.
15396 * gdbarch.sh (verify_gdbarch): Use string_file.
15397 * gdbtypes.c (safe_parse_type): Use null_stream.
15398 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
15399 string_file.
15400 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
15401 'string_file *' instead of a 'ui_file *'.
15402 (gdbscm_arch_disassemble): Use string_file.
15403 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
15404 * guile/scm-ports.c (class ioscm_file_port): Now a class that
15405 inherits from ui_file.
15406 (ioscm_file_port_delete, ioscm_file_port_rewind)
15407 (ioscm_file_port_put): Delete.
15408 (ioscm_file_port_write): Rename to ...
15409 (ioscm_file_port::write): ... this. Remove file_port_magic
15410 checks.
15411 (ioscm_file_port_new): Delete.
15412 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
15413 ui_file_up.
15414 * guile/scm-type.c (tyscm_type_name): Use string_file.
15415 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
15416 Use string_file.
15417 * infcmd.c (print_return_value_1): Use string_file.
15418 * infrun.c (print_target_wait_results): Use string_file.
15419 * language.c (add_language): Use string_file.
15420 * location.c (explicit_to_string_internal): Use string_file.
15421 * main.c (captured_main_1): Use null_file.
15422 * maint.c (maintenance_print_architecture): Use stdio_file.
15423 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
15424 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
15425 event_channel>: Change type to mi_console_file pointer.
15426 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
15427 (mi_console_file_delete): Delete.
15428 (struct mi_console_file): Delete.
15429 (mi_console_file_magic): Delete.
15430 (mi_console_file_new): Delete.
15431 (mi_console_file::mi_console_file): New.
15432 (mi_console_file_delete): Delete.
15433 (mi_console_file_fputs): Delete.
15434 (mi_console_file::write): New.
15435 (mi_console_raw_packet): Delete.
15436 (mi_console_file::flush): New.
15437 (mi_console_file_flush): Delete.
15438 (mi_console_set_raw): Rename to ...
15439 (mi_console_file::set_raw): ... this.
15440 * mi/mi-console.h (class mi_console_file): New class.
15441 (mi_console_file_new, mi_console_set_raw): Delete.
15442 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
15443 (mi_set_logging): Use delete and tee_file. Adjust.
15444 * mi/mi-main.c (output_register): Use string_file.
15445 (mi_cmd_data_evaluate_expression): Use string_file.
15446 (mi_cmd_data_read_memory): Use string_file.
15447 (mi_cmd_execute, print_variable_or_computed): Use string_file.
15448 * mi/mi-out.c (mi_ui_out::main_stream): New.
15449 (mi_ui_out::rewind): Use main_stream and
15450 string_file.
15451 (mi_ui_out::put): Use main_stream and string_file.
15452 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
15453 Allocate a 'string_file' instead.
15454 (mi_out_new): Don't allocate a mem_fileopen stream here.
15455 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
15456 (mi_ui_out::main_stream): Declare method.
15457 * printcmd.c (eval_command): Use string_file.
15458 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
15459 * python/py-arch.c (archpy_disassemble): Use string_file.
15460 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
15461 * python/py-frame.c (frapy_str): Use string_file.
15462 * python/py-framefilter.c (py_print_type, py_print_single_arg):
15463 Use string_file.
15464 * python/py-type.c (typy_str): Use string_file.
15465 * python/py-unwind.c (unwind_infopy_str): Use string_file.
15466 * python/py-value.c (valpy_str): Use string_file.
15467 * record-btrace.c (btrace_insn_history): Use string_file.
15468 * regcache.c (regcache_print): Use stdio_file.
15469 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
15470 * remote.c (escape_buffer): Use string_file.
15471 * rust-lang.c (rust_get_disr_info): Use string_file.
15472 * serial.c (serial_open_ops_1): Use stdio_file.
15473 (do_serial_close): Use delete.
15474 * stack.c (print_frame_arg): Use string_file.
15475 (print_frame_args): Remove local mem_fileopen stream, not used.
15476 (print_frame): Use string_file.
15477 * symmisc.c (maintenance_print_symbols): Use stdio_file.
15478 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
15479 Take a 'string_file *' instead of a 'ui_file *'.
15480 * top.c (new_ui): Use stdio_file and stderr_file.
15481 (free_ui): Use delete.
15482 (execute_command_to_string): Use string_file.
15483 (quit_confirm): Use string_file.
15484 * tracepoint.c (collection_list::append_exp): Use string_file.
15485 * tui/tui-disasm.c (tui_disassemble): Use string_file.
15486 * tui/tui-file.c: Don't include "ui-file.h".
15487 (enum streamtype, struct tui_stream): Delete.
15488 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
15489 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
15490 (tui_file::tui_file): New method.
15491 (tui_file_fputs): Delete.
15492 (tui_file_get_strbuf): Delete.
15493 (tui_file::puts): New method.
15494 (tui_file_adjust_strbuf): Delete.
15495 (tui_file_flush): Delete.
15496 (tui_file::flush): New method.
15497 * tui/tui-file.h: Tweak intro comment.
15498 Include ui-file.h.
15499 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
15500 (tui_file_adjust_strbuf): Delete declarations.
15501 (class tui_file): New class.
15502 * tui/tui-io.c (tui_initialize_io): Use tui_file.
15503 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
15504 (tui_register_format): Use string_stream.
15505 * tui/tui-stack.c (tui_make_status_line): Use string_file.
15506 (tui_get_function_from_frame): Use string_file.
15507 * typeprint.c (type_to_string): Use string_file.
15508 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
15509 (null_stream): New global.
15510 (ui_file_delete): Delete.
15511 (ui_file::ui_file): New.
15512 (null_file_isatty): Delete.
15513 (ui_file::~ui_file): New.
15514 (null_file_rewind): Delete.
15515 (ui_file::printf): New.
15516 (null_file_put): Delete.
15517 (null_file_flush): Delete.
15518 (ui_file::putstr): New.
15519 (null_file_write): Delete.
15520 (ui_file::putstrn): New.
15521 (null_file_read): Delete.
15522 (ui_file::putc): New.
15523 (null_file_fputs): Delete.
15524 (null_file_write_async_safe): Delete.
15525 (ui_file::vprintf): New.
15526 (null_file_delete): Delete.
15527 (null_file::write): New.
15528 (null_file_fseek): Delete.
15529 (null_file::puts): New.
15530 (ui_file_data): Delete.
15531 (null_file::write_async_safe): New.
15532 (gdb_flush, ui_file_isatty): Adjust.
15533 (ui_file_put, ui_file_rewind): Delete.
15534 (ui_file_write): Adjust.
15535 (ui_file_write_for_put): Delete.
15536 (ui_file_write_async_safe, ui_file_read): Adjust.
15537 (ui_file_fseek): Delete.
15538 (fputs_unfiltered): Adjust.
15539 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
15540 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
15541 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
15542 (set_ui_file_data): Delete.
15543 (string_file::~string_file, string_file::write)
15544 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
15545 (do_ui_file_as_string, ui_file_as_string): Delete.
15546 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
15547 (struct mem_file): Delete.
15548 (mem_file_new): Delete.
15549 (stdio_file::stdio_file): New.
15550 (mem_file_delete): Delete.
15551 (stdio_file::stdio_file): New.
15552 (mem_fileopen): Delete.
15553 (stdio_file::~stdio_file): New.
15554 (mem_file_rewind): Delete.
15555 (stdio_file::set_stream): New.
15556 (mem_file_put): Delete.
15557 (stdio_file::open): New.
15558 (mem_file_write): Delete.
15559 (stdio_file_magic, struct stdio_file): Delete.
15560 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
15561 (stdio_file::flush): New.
15562 (stdio_file_read): Rename to ...
15563 (stdio_file::read): ... this. Adjust.
15564 (stdio_file_write): Rename to ...
15565 (stdio_file::write): ... this. Adjust.
15566 (stdio_file_write_async_safe): Rename to ...
15567 (stdio_file::write_async_safe) ... this. Adjust.
15568 (stdio_file_fputs): Rename to ...
15569 (stdio_file::puts) ... this. Adjust.
15570 (stdio_file_isatty): Delete.
15571 (stdio_file_fseek): Delete.
15572 (stdio_file::isatty): New.
15573 (stderr_file_write): Rename to ...
15574 (stderr_file::write) ... this. Adjust.
15575 (stderr_file_fputs): Rename to ...
15576 (stderr_file::puts) ... this. Adjust.
15577 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
15578 (stderr_file::stderr_file): New.
15579 (tee_file_magic): Delete.
15580 (struct tee_file): Delete.
15581 (tee_file::tee_file): New.
15582 (tee_file_new): Delete.
15583 (tee_file::~tee_file): New.
15584 (tee_file_delete): Delete.
15585 (tee_file_flush): Rename to ...
15586 (tee_file::flush): ... this. Adjust.
15587 (tee_file_write): Rename to ...
15588 (tee_file::write): ... this. Adjust.
15589 (tee_file::write_async_safe): New.
15590 (tee_file_fputs): Rename to ...
15591 (tee_file::puts): ... this. Adjust.
15592 (tee_file_isatty): Rename to ...
15593 (tee_file::isatty): ... this. Adjust.
15594 * ui-file.h (struct obstack, struct ui_file): Don't
15595 forward-declare.
15596 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
15597 (ui_file_write_ftype)
15598 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
15599 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
15600 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
15601 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
15602 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
15603 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
15604 (set_ui_file_fseek): Delete.
15605 (ui_file_data, ui_file_delete, ui_file_rewind)
15606 (struct ui_file): New.
15607 (ui_file_up): New.
15608 (class null_file): New.
15609 (null_stream): Declare.
15610 (ui_file_write_for_put, ui_file_put): Delete.
15611 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
15612 Delete.
15613 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
15614 (gdb_fopen, tee_file_new): Delete.
15615 (struct string_file): New.
15616 (struct stdio_file): New.
15617 (stdio_file_up): New.
15618 (struct stderr_file): New.
15619 (class tee_file): New.
15620 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
15621 of a 'ui_file *'. Adjust.
15622 * ui-out.h (class ui_out) <field_stream>: Likewise.
15623 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
15624 (null_stream): Delete.
15625 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
15626 Adjust.
15627 * utils.h (struct ui_file): Delete forward declaration..
15628 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
15629 (error_stream): Take a 'string_file &' instead of a
15630 'ui_file *'.
15631 * varobj.c (varobj_value_get_print_value): Use string_file.
15632 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
15633 * gdbarch.c: Regenerate.
15634
15635 2017-02-02 Pedro Alves <palves@redhat.com>
15636
15637 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
15638 (gdb_pretty_print_insn): ... this. Now a free function. Add back
15639 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
15640 Adjust to call gdb_print_insn instead of
15641 gdb_disassembler::print_insn.
15642 (dump_insns, do_mixed_source_and_assembly_deprecated)
15643 (do_mixed_source_and_assembly, do_assembly_only): Add back a
15644 'gdbarch' parameter. Remove gdb_disassembler parameter.
15645 (gdb_disassembly): Don't allocate a gdb_disassembler here.
15646 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
15647 declaration.
15648 (gdb_pretty_print_insn): Re-add declaration.
15649 * record-btrace.c (btrace_insn_history): Don't allocate a
15650 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
15651
15652 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
15653
15654 * disasm.h (gdb_disassembly): Remove file_string parameter.
15655 * disasm.c (gdb_disassembly): Likewise.
15656 * cli/cli-cmds.c (print_disassembly): Adapt.
15657 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
15658 * stack.c (do_gdb_disassembly): Likewise.
15659
15660 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
15661
15662 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
15663 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
15664 targets. And if the implicit value is longer than needed, extract
15665 the first bytes instead of the "least significant" ones.
15666
15667 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
15668
15669 * btrace.c (btrace_enable): Do not call btrace_add_pc for
15670 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
15671 (btrace_fetch): Assert can_access_registers_ptid.
15672 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
15673 validate_registers_access.
15674
15675 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
15676
15677 * gdbthread.h (can_access_registers_ptid): New.
15678 * thread.c (can_access_registers_ptid): New.
15679
15680 2017-02-01 Pedro Alves <palves@redhat.com>
15681
15682 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
15683
15684 2017-01-31 Pedro Alves <palves@redhat.com>
15685
15686 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
15687 Fix typos.
15688
15689 2017-01-31 Pedro Alves <palves@redhat.com>
15690
15691 * stack.c (print_frame_args): Remove local mem_fileopen stream,
15692 not used.
15693
15694 2017-01-31 Pedro Alves <palves@redhat.com>
15695
15696 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
15697
15698 2017-01-31 Pedro Alves <palves@redhat.com>
15699
15700 * common/scoped_restore.h
15701 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
15702 change the value's parameter type to T2.
15703 (make_scoped_restore): Likewise.
15704
15705 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
15706 Richard Henderson <rth@redhat.com>
15707
15708 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
15709 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
15710 GS_BASE for older kernels.
15711 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
15712 GS_BASE for older kernels.
15713 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
15714 and GS_BASE to the offset table.
15715 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
15716 system register group.
15717 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
15718 for older kernels.
15719 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
15720 amd64 ABI.
15721 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
15722 AMD64_GSBASE_REGNUM.
15723 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
15724 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
15725 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
15726 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
15727 i386/64bit-segments.xml in those rules.
15728 * features/i386/64bit-segments.xml: New file.
15729 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
15730 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
15731 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
15732 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
15733 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
15734 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
15735 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
15736 * features/i386/amd64-avx-linux.c: Regenerated.
15737 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
15738 * features/i386/amd64-avx-mpx.c: Regenerated.
15739 * features/i386/amd64-avx512-linux.c: Regenerated.
15740 * features/i386/amd64-linux.c: Regenerated.
15741 * features/i386/amd64-mpx-linux.c: Regenerated.
15742 * features/i386/i386-avx-mpx-linux.c: Regenerated.
15743 * features/i386/i386-avx-mpx.c: Regenerated.
15744 * features/i386/x32-avx-linux.c: Regenerated.
15745 * features/i386/x32-avx512-linux.c: Regenerated.
15746 * regformats/i386/amd64-avx-linux.dat: Regenerated.
15747 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
15748 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
15749 * regformats/i386/amd64-linux.dat: Regenerated.
15750 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
15751 * regformats/i386/x32-avx-linux.dat: Regenerated.
15752 * regformats/i386/x32-avx512-linux.dat: Regenerated.
15753 * regformats/i386/x32-linux.dat: Regenerated.
15754
15755 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
15756
15757 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
15758 Set to AMD64_NUM_REGS.
15759
15760 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
15761
15762 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
15763 that checks validity of a register number.
15764
15765 2017-01-27 Kees Cook <keescook@google.com>
15766
15767 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
15768 fetch_fpregs if target has fpa registers.
15769 (arm_linux_store_inferior_registers): Call store_fpregs if target
15770 has fpa registers.
15771
15772 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
15773
15774 * cris-tdep.c (cris_gdbarch_init): Remove check for
15775 info.byte_order and force it to BFD_ENDIAN_LITTLE.
15776
15777 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
15778
15779 * corelow.c (get_core_register_section): Check for regset
15780 existence before checking for REGSET_VARIABLE_SIZE.
15781
15782 2017-01-26 Yao Qi <yao.qi@linaro.org>
15783 Pedro Alves <palves@redhat.com>
15784
15785 PR gdb/20939
15786 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
15787 call memory_error, save memaddr instead.
15788 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
15789 negative, cal memory_error.
15790 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
15791
15792 2017-01-26 Yao Qi <yao.qi@linaro.org>
15793
15794 * disasm-selftests.c (memory_error_test): New function.
15795 (_initialize_disasm_selftests): Register memory_error_test.
15796
15797 2017-01-26 Yao Qi <yao.qi@linaro.org>
15798
15799 * Makefile.in (SFILES): Add disasm-selftests.c and
15800 selftest-arch.c.
15801 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
15802 * disasm-selftests.c: New file.
15803 * selftest-arch.c: New file.
15804 * selftest-arch.h: New file.
15805
15806 2017-01-26 Yao Qi <yao.qi@linaro.org>
15807
15808 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
15809 to bfd_arch_mep. Don't return 0 if section is not
15810 found. Call print_insn_mep.
15811
15812 2017-01-26 Pedro Alves <palves@redhat.com>
15813 Yao Qi <yao.qi@linaro.org>
15814
15815 * arm-tdep.c: Include "disasm.h".
15816 (gdb_print_insn_arm): Update code to get gdbarch.
15817 * disasm.c (dis_asm_read_memory): Change it to
15818 gdb_disassembler::dis_asm_read_memory.
15819 (dis_asm_memory_error): Likewise.
15820 (dis_asm_print_address): Likewise.
15821 (gdb_pretty_print_insn): Change it to
15822 gdb_disassembler::pretty_print_insn.
15823 (dump_insns): Add one argument gdb_disassemlber. All
15824 callers updated.
15825 (do_mixed_source_and_assembly_deprecated): Likewise.
15826 (do_mixed_source_and_assembly): Likewise.
15827 (do_assembly_only): Likewise.
15828 (gdb_disassembler::gdb_disassembler): New.
15829 (gdb_disassembler::print_insn): New.
15830 * disasm.h (class gdb_disassembler): New.
15831 (gdb_pretty_print_insn): Remove declaration.
15832 (gdb_disassemble_info): Likewise.
15833 * guile/scm-disasm.c (class gdbscm_disassembler): New.
15834 (gdbscm_disasm_read_memory_worker): Update.
15835 (gdbscm_disasm_read_memory): Update.
15836 (gdbscm_disasm_memory_error): Remove.
15837 (gdbscm_disasm_print_address): Remove.
15838 (gdbscm_disassembler::gdbscm_disassembler): New.
15839 (gdbscm_print_insn_from_port): Update.
15840 * mips-tdep.c: Include disasm.h.
15841 (gdb_print_insn_mips): Update code to get gdbarch.
15842 * record-btrace.c (btrace_insn_history): Update.
15843 * spu-tdep.c: Include disasm.h.
15844 (struct spu_dis_asm_data): Remove.
15845 (struct spu_dis_asm_info): New.
15846 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
15847 SPU id.
15848 (gdb_print_insn_spu): Cast disassemble_info to
15849 spu_dis_asm_info.
15850
15851 2017-01-26 Yao Qi <yao.qi@linaro.org>
15852
15853 * disasm.c (do_ui_file_delete): Delete.
15854 (gdb_insn_length): Move code creating stream to ...
15855 * utils.c (null_stream): ... here. New function.
15856 * utils.h (null_stream): Declare.
15857
15858 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
15859
15860 * python/py-inferior.c (find_thread_object): Return directly
15861 from the loop. Remove "found" variable.
15862
15863 2017-01-21 Joel Brobecker <brobecker@adacore.com>
15864
15865 GDB 7.12.1 released.
15866
15867 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
15868
15869 * python/py-function.c (fnpy_call): Reorder declarations to have
15870 the gdbpy_enter object declared first.
15871 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
15872
15873 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
15874
15875 PR python/21068
15876 * python/python-internal.h (PyMem_RawMalloc): Define for
15877 Python < 3.4.
15878 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
15879 PyMem_RawMalloc instead of PyMem_Malloc.
15880
15881 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
15882 Luis Machado <lgustavo@codesourcery.com>
15883
15884 * NEWS (New commands): Mention flash-erase.
15885 (New MI commands): Mention target-flash-erase.
15886 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
15887 command.
15888 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
15889 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
15890 * target.c (flash_erase_command): New function.
15891 (initialize_targets): Add new flash-erase command.
15892 * target.h (flash_erase_command): New declaration.
15893
15894 2017-01-20 Joel Brobecker <brobecker@adacore.com>
15895
15896 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
15897 HAVE_SYS_PROCFS_H is defined.
15898
15899 2017-01-18 Alan Hayward <alan.hayward@arm.com>
15900
15901 * remote.c (struct cached_reg): Change data into a pointer.
15902 * (stop_reply_dtr): Free data pointers before deleting vector.
15903 (process_stop_reply): Likewise.
15904 (remote_parse_stop_reply): Allocate space for data
15905
15906 2017-01-18 Alan Hayward <alan.hayward@arm.com>
15907
15908 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
15909 MAX_REGISTER_SIZE.
15910 (amd64_pseudo_register_read_value): Likewise.
15911 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
15912 (store_register_using_P): Likewise.
15913 * regcache.c (regcache_xfer_part): Likewise.
15914
15915 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
15916
15917 Split real and pseudo registers.
15918 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
15919 (sparc32_pseudo_regnum): New enum.
15920 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
15921 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
15922 (SPARC32_CP0_REGISTERS): New macro.
15923 (sparc32_pseudo_register_name): New function.
15924 (sparc32_register_name): Use sparc32_pseudo_register_name.
15925 (sparc32_pseudo_register_type): New function.
15926 (sparc32_register_type): Use sparc32_pseudo_register_type.
15927 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
15928 pseudo register numbers.
15929 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
15930 (SPARC64_CP0_REGISTERS): New macro.
15931 (sparc64_pseudo_register_name): New function.
15932 (sparc64_register_name): Use sparc64_pseudo_register_name.
15933 (sparc64_pseudo_register_type): New function.
15934 (sparc64_register_type): Use sparc64_pseudo_register_type.
15935 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
15936 pseudo register numbers.
15937 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
15938 sparc64_store_arguments): Handle pseudo register numbers.
15939
15940 2017-01-13 Yao Qi <yao.qi@linaro.org>
15941
15942 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
15943 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
15944 output.
15945 (getpkt_or_notif_sane_1): Likewise.
15946
15947 2017-01-13 Yao Qi <yao.qi@linaro.org>
15948
15949 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
15950 of CC. Pass "-x c++-header" instead of "-x c".
15951
15952 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15953
15954 * remote.c (remote_can_async_p): Update comment.
15955
15956 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15957
15958 * linux-nat.c (linux_nat_can_async_p): Update comment.
15959
15960 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15961
15962 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
15963
15964 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
15965
15966 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
15967
15968 2017-01-10 Tom Tromey <tom@tromey.com>
15969
15970 * python/py-type.c (typy_legacy_template_argument): Update.
15971 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
15972 ~demangle_parse_info): Declare new members.
15973 (cp_demangled_name_to_comp): Return unique_ptr.
15974 (cp_demangled_name_parse_free)
15975 (make_cleanup_cp_demangled_name_parse_free)
15976 (cp_new_demangle_parse_info): Remove.
15977 * cp-support.c (do_demangled_name_parse_free_cleanup)
15978 (make_cleanup_cp_demangled_name_parse_free): Remove.
15979 (inspect_type, cp_canonicalize_string_full)
15980 (cp_canonicalize_string): Update.
15981 (mangled_name_to_comp): Change return type.
15982 (cp_class_name_from_physname, method_name_from_physname)
15983 (cp_func_name, cp_remove_params): Update.
15984 * cp-name-parser.y (demangle_parse_info): New constructor, from
15985 cp_new_demangle_parse_info.
15986 (~demangle_parse_info): New destructor, from
15987 cp_demangled_name_parse_free.
15988 (cp_merge_demangle_parse_infos): Update.
15989 (cp_demangled_name_to_comp): Change return type.
15990
15991 2017-01-10 Tom Tromey <tom@tromey.com>
15992
15993 * top.c (prevent_dont_repeat): Change return type.
15994 * python/python.c (execute_gdb_command): Use std::string.
15995 Update.
15996 * guile/guile.c (gdbscm_execute_gdb_command): Update.
15997 * command.h (prevent_dont_repeat): Change return type.
15998 * breakpoint.c (bpstat_do_actions_1): Update.
15999
16000 2017-01-10 Tom Tromey <tom@tromey.com>
16001
16002 * value.h (scoped_value_mark::~scoped_value_mark): Call
16003 free_to_mark.
16004 (scoped_value_mark::free_to_mark): New method.
16005 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
16006 scoped_value_mark.
16007
16008 2017-01-10 Tom Tromey <tom@tromey.com>
16009
16010 * python/py-value.c (valpy_dereference, valpy_referenced_value)
16011 (valpy_reference_value, valpy_const_value, valpy_get_address)
16012 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
16013 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
16014 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
16015 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
16016 scoped_value_mark.
16017 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
16018 * value.h (scoped_value_mark): New class.
16019
16020 2017-01-10 Tom Tromey <tom@tromey.com>
16021
16022 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
16023 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
16024 * psymtab.c (discard_psymtabs_upto): Remove.
16025 (make_cleanup_discard_psymtabs): Remove.
16026 (struct psymtab_state): Remove.
16027
16028 2017-01-10 Tom Tromey <tom@tromey.com>
16029
16030 * record-full.c (record_full_save_cleanups): Remove.
16031 (record_full_save): Use gdb::unlinker.
16032 * gcore.c (do_bfd_delete_cleanup): Remove.
16033 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
16034 cleanups.
16035 * dwarf2read.c (unlink_if_set): Remove.
16036 (write_psymtabs_to_index): Use gdb::unlinker.
16037 * common/gdb_unlinker.h: New file.
16038
16039 2017-01-10 Tom Tromey <tom@tromey.com>
16040
16041 * windows-tdep.c (windows_xfer_shared_library): Update.
16042 * windows-nat.c (windows_make_so): Update.
16043 * utils.h (make_cleanup_bfd_unref): Remove.
16044 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
16045 * symfile.h (symfile_bfd_open)
16046 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
16047 * symfile.c (read_symbols, symbol_file_add)
16048 (separate_debug_file_exists): Update.
16049 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
16050 (generic_load, reread_symbols): Update.
16051 * symfile-mem.c (symbol_file_add_from_memory): Update.
16052 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
16053 (spu_symbol_file_add_from_memory): Update.
16054 * solist.h (struct target_so_ops) <bfd_open>: Return
16055 gdb_bfd_ref_ptr.
16056 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
16057 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
16058 gdb_bfd_ref_ptr.
16059 (solib_map_sections, reload_shared_libraries_1): Update.
16060 * solib-svr4.c (enable_break): Update.
16061 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
16062 * solib-frv.c (enable_break2): Update.
16063 * solib-dsbt.c (enable_break): Update.
16064 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
16065 gdb_bfd_ref_ptr.
16066 (darwin_solib_get_all_image_info_addr_at_init): Update.
16067 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
16068 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
16069 * record-full.c (record_full_save): Update.
16070 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
16071 * procfs.c (insert_dbx_link_bpt_in_file): Update.
16072 * minidebug.c (find_separate_debug_file_in_section): Return
16073 gdb_bfd_ref_ptr.
16074 * machoread.c (macho_add_oso_symfile): Change abfd to
16075 gdb_bfd_ref_ptr.
16076 (macho_symfile_read_all_oso): Update.
16077 (macho_check_dsym): Return gdb_bfd_ref_ptr.
16078 (macho_symfile_read): Update.
16079 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
16080 (jit_bfd_try_read_symtab): Update.
16081 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
16082 (gdb_bfd_openw, gdb_bfd_openr_iovec)
16083 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
16084 gdb_bfd_ref_ptr.
16085 (gdb_bfd_ref_policy): New struct.
16086 (gdb_bfd_ref_ptr): New typedef.
16087 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
16088 (gdb_bfd_openw, gdb_bfd_openr_iovec)
16089 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
16090 gdb_bfd_ref_ptr.
16091 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
16092 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
16093 (gcore_command): Update.
16094 * exec.c (exec_file_attach): Update.
16095 * elfread.c (elf_symfile_read): Update.
16096 * dwarf2read.c (dwarf2_get_dwz_file): Update.
16097 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
16098 (open_and_init_dwo_file): Update.
16099 (open_dwp_file): Return gdb_bfd_ref_ptr.
16100 (open_and_init_dwp_file): Update.
16101 * corelow.c (core_open): Update.
16102 * compile/compile-object-load.c (compile_object_load): Update.
16103 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
16104 * coffread.c (coff_symfile_read): Update.
16105 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
16106 gdb_bfd_ref_ptr. Rename.
16107 (dump_bfd_file, restore_command): Update.
16108 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
16109 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
16110 (find_separate_debug_file_by_buildid): Update.
16111
16112 2017-01-10 Tom Tromey <tom@tromey.com>
16113
16114 * common/gdb_ref_ptr.h: New file.
16115 * python/py-ref.h (struct gdbpy_ref_policy): New.
16116 (gdbpy_ref): Now a typedef.
16117
16118 2017-01-10 Tom Tromey <tom@tromey.com>
16119
16120 * utils.h (make_cleanup_htab_delete): Don't declare.
16121 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
16122 Remove.
16123 * linespec.c (decode_compound_collector): Add constructor,
16124 destructor.
16125 (lookup_prefix_sym): Remove cleanup.
16126 (symtab_collector): Add constructor, destructor.
16127 (collect_symtabs_from_filename): Remove cleanup.
16128 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
16129 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
16130 Use htab_up.
16131 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
16132 * dwarf2read.c (dw2_expand_symtabs_matching)
16133 (dw2_map_symbol_filenames, dwarf_decode_macros)
16134 (write_psymtabs_to_index): Use htab_up.
16135 * dwarf2loc.c (func_verify_no_selftailcall)
16136 (call_site_find_chain_1, func_verify_no_selftailcall)
16137 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
16138 std::vector, gdb::unique_xmalloc_ptr.
16139 (call_sitep): Remove typedef.
16140 (dwarf2_locexpr_baton_eval): Remove unused variable.
16141
16142 2017-01-10 Tom Tromey <tom@tromey.com>
16143
16144 * python/python-internal.h (make_cleanup_py_decref)
16145 (make_cleanup_py_xdecref): Don't declare.
16146 * python/py-utils.c (py_decref, make_cleanup_py_decref)
16147 (py_xdecref, make_cleanup_py_xdecref): Remove.
16148
16149 2017-01-10 Tom Tromey <tom@tromey.com>
16150
16151 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
16152 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
16153
16154 2017-01-10 Tom Tromey <tom@tromey.com>
16155
16156 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
16157
16158 2017-01-10 Tom Tromey <tom@tromey.com>
16159
16160 * python/py-utils.c (unicode_to_encoded_string)
16161 (python_string_to_target_string)
16162 (python_string_to_target_python_string)
16163 (python_string_to_host_string, gdbpy_obj_to_string)
16164 (get_addr_from_python): Use gdbpy_ref.
16165
16166 2017-01-10 Tom Tromey <tom@tromey.com>
16167
16168 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
16169 gdbpy_ref.
16170
16171 2017-01-10 Tom Tromey <tom@tromey.com>
16172
16173 * python/python.c (eval_python_command, gdbpy_decode_line)
16174 (gdbpy_run_events, gdbpy_start_type_printers)
16175 (gdbpy_apply_type_printers): Use gdbpy_ref.
16176
16177 2017-01-10 Tom Tromey <tom@tromey.com>
16178
16179 * python/py-param.c (get_doc_string, compute_enum_values): Use
16180 gdbpy_ref.
16181
16182 2017-01-10 Tom Tromey <tom@tromey.com>
16183
16184 * python/py-inferior.c (find_thread_object, build_inferior_list):
16185 Use gdbpy_ref.
16186
16187 2017-01-10 Tom Tromey <tom@tromey.com>
16188
16189 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
16190
16191 2017-01-10 Tom Tromey <tom@tromey.com>
16192
16193 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
16194 gdbpy_ref.
16195
16196 2017-01-10 Tom Tromey <tom@tromey.com>
16197
16198 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
16199 extra incref.
16200 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
16201 Use gdbpy_ref.
16202
16203 2017-01-10 Tom Tromey <tom@tromey.com>
16204
16205 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
16206 gdbpy_ref.
16207
16208 2017-01-10 Tom Tromey <tom@tromey.com>
16209
16210 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
16211 decref results of PyArg_ParseTupleAndKeywords.
16212
16213 2017-01-10 Tom Tromey <tom@tromey.com>
16214
16215 * python/python.c (python_run_simple_file): Use
16216 unique_xmalloc_ptr, gdbpy_ref.
16217
16218 2017-01-10 Tom Tromey <tom@tromey.com>
16219
16220 * python/py-prettyprint.c (print_stack_unless_memory_error)
16221 (print_string_repr, print_children): Use gdbpy_ref.
16222 (dummy_python_frame): New class.
16223 (dummy_python_frame::dummy_python_frame): Rename from
16224 push_dummy_python_frame.
16225 (py_restore_tstate): Remove.
16226
16227 2017-01-10 Tom Tromey <tom@tromey.com>
16228
16229 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
16230
16231 2017-01-10 Tom Tromey <tom@tromey.com>
16232
16233 * python/python.c (ensure_python_env, restore_python_env):
16234 Remove.
16235 * python/python-internal.h (ensure_python_env): Don't declare.
16236 * varobj.h (varobj_ensure_python_env): Don't declare.
16237 * varobj.c (varobj_ensure_python_env): Remove.
16238
16239 2017-01-10 Tom Tromey <tom@tromey.com>
16240
16241 * varobj.c (varobj_value_get_print_value): Use
16242 gdbpy_enter_varobj.
16243
16244 2017-01-10 Tom Tromey <tom@tromey.com>
16245
16246 * python/py-prettyprint.c (print_string_repr, print_children):
16247 Update.
16248 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
16249 of "encoding".
16250 * varobj.c (varobj_value_get_print_value): Update.
16251 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
16252
16253 2017-01-10 Tom Tromey <tom@tromey.com>
16254
16255 * varobj.c (varobj_get_display_hint)
16256 (dynamic_varobj_has_child_method, install_new_value_visualizer)
16257 (varobj_set_visualizer, free_variable): Use
16258 gdbpy_enter_varobj.
16259
16260 2017-01-10 Tom Tromey <tom@tromey.com>
16261
16262 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
16263 (do_finish_initialization): New function. Use gdbpy_ref.
16264 (gdbpy_finish_initialization): Use gdbpy_enter. Call
16265 do_finish_initialization.
16266
16267 2017-01-10 Tom Tromey <tom@tromey.com>
16268
16269 * python/py-param.c (get_set_value, get_show_value): Use
16270 gdbpy_enter, gdbpy_ref.
16271
16272 2017-01-10 Tom Tromey <tom@tromey.com>
16273
16274 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
16275
16276 2017-01-10 Tom Tromey <tom@tromey.com>
16277
16278 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
16279
16280 2017-01-10 Tom Tromey <tom@tromey.com>
16281
16282 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
16283 Use gdbpy_enter_varobj.
16284
16285 2017-01-10 Tom Tromey <tom@tromey.com>
16286
16287 * varobj.c (gdbpy_enter_varobj): New constructor.
16288 * python/python-internal.h (gdbpy_enter_varobj): New class.
16289 * python/py-varobj.c (py_varobj_get_iterator): Use
16290 gdbpy_enter_varobj.
16291
16292 2017-01-10 Tom Tromey <tom@tromey.com>
16293
16294 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
16295 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
16296 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
16297 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
16298 unique_xmalloc_ptr.
16299 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
16300
16301 2017-01-10 Tom Tromey <tom@tromey.com>
16302
16303 * python/py-xmethods.c (invoke_match_method): Use
16304 gdbpy_ref.
16305
16306 2017-01-10 Tom Tromey <tom@tromey.com>
16307
16308 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
16309 gdbpy_enter, gdbpy_ref.
16310
16311 2017-01-10 Tom Tromey <tom@tromey.com>
16312
16313 * python/python.c (python_interactive_command): Use gdbpy_enter.
16314
16315 2017-01-10 Tom Tromey <tom@tromey.com>
16316
16317 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
16318 gdbpy_ref.
16319
16320 2017-01-10 Tom Tromey <tom@tromey.com>
16321
16322 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
16323 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
16324
16325 2017-01-10 Tom Tromey <tom@tromey.com>
16326
16327 * utils.h (htab_deleter): New struct.
16328 (htab_up): New typedef.
16329 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
16330 gdbpy_enter, gdbpy_ref, htab_up.
16331
16332 2017-01-10 Tom Tromey <tom@tromey.com>
16333
16334 * python/py-unwind.c (pending_frame_invalidate): Remove.
16335 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
16336
16337 2017-01-10 Tom Tromey <tom@tromey.com>
16338
16339 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
16340 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
16341
16342 2017-01-10 Tom Tromey <tom@tromey.com>
16343
16344 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
16345
16346 2017-01-10 Tom Tromey <tom@tromey.com>
16347
16348 * python/python.c (gdbpy_eval_from_control_command)
16349 (gdbpy_source_script, gdbpy_run_events)
16350 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
16351 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
16352 gdbpy_enter.
16353
16354 2017-01-10 Tom Tromey <tom@tromey.com>
16355
16356 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
16357
16358 2017-01-10 Tom Tromey <tom@tromey.com>
16359
16360 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
16361
16362 2017-01-10 Tom Tromey <tom@tromey.com>
16363
16364 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
16365 (python_on_inferior_call_pre, python_on_inferior_call_post)
16366 (python_on_memory_change, python_on_register_change)
16367 (python_inferior_exit, python_new_objfile, add_thread_object)
16368 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
16369
16370 2017-01-10 Tom Tromey <tom@tromey.com>
16371
16372 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
16373 (bpfinishpy_handle_exit): Use gdbpy_enter.
16374
16375 2017-01-10 Tom Tromey <tom@tromey.com>
16376
16377 * python/py-cmd.c (cmdpy_destroyer)
16378 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
16379 gdbpy_enter.
16380
16381 2017-01-10 Tom Tromey <tom@tromey.com>
16382
16383 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
16384 gdbpy_enter.
16385 (gdbpy_breakpoint_has_cond): Likewise.
16386
16387 2017-01-10 Tom Tromey <tom@tromey.com>
16388
16389 * python/python.c (gdbpy_enter): New constructor.
16390 (~gdbpy_enter): New destructor.
16391 (restore_python_env, ensure_python_env): Rewrite.
16392 * python/python-internal.h (gdbpy_enter): New class.
16393
16394 2017-01-10 Tom Tromey <tom@tromey.com>
16395
16396 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
16397
16398 2017-01-10 Tom Tromey <tom@tromey.com>
16399
16400 * python/py-value.c (value_has_field, get_field_flag)
16401 (get_field_type, valpy_getitem, convert_value_from_python): Use
16402 gdbpy_ref.
16403
16404 2017-01-10 Tom Tromey <tom@tromey.com>
16405
16406 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
16407 gdbpy_ref.
16408
16409 2017-01-10 Tom Tromey <tom@tromey.com>
16410
16411 * python/py-prettyprint.c (search_pp_list)
16412 (find_pretty_printer_from_objfiles)
16413 (find_pretty_printer_from_progspace)
16414 (find_pretty_printer_from_gdb, find_pretty_printer)
16415 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
16416 gdbpy_ref.
16417
16418 2017-01-10 Tom Tromey <tom@tromey.com>
16419
16420 * python/py-param.c (call_doc_function): Use gdbpy_ref.
16421
16422 2017-01-10 Tom Tromey <tom@tromey.com>
16423
16424 * python/py-linetable.c (build_line_table_tuple_from_pcs)
16425 (ltpy_get_all_source_lines): Use gdbpy_ref.
16426
16427 2017-01-10 Tom Tromey <tom@tromey.com>
16428
16429 * python/py-framefilter.c (extract_sym, extract_value)
16430 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
16431 gdbpy_ref.
16432
16433 2017-01-10 Tom Tromey <tom@tromey.com>
16434
16435 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
16436
16437 2017-01-10 Tom Tromey <tom@tromey.com>
16438
16439 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
16440
16441 2017-01-10 Tom Tromey <tom@tromey.com>
16442
16443 * python/py-function.c (convert_values_to_python, fnpy_init): Use
16444 gdbpy_ref.
16445
16446 2017-01-10 Tom Tromey <tom@tromey.com>
16447
16448 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
16449
16450 2017-01-10 Tom Tromey <tom@tromey.com>
16451
16452 * python/py-type.c (convert_field, make_fielditem, typy_fields)
16453 (typy_range): Use gdbpy_ref.
16454
16455 2017-01-10 Tom Tromey <tom@tromey.com>
16456
16457 * python/py-threadevent.c (create_thread_event_object): Use
16458 gdbpy_ref.
16459 * python/py-stopevent.c (create_stop_event_object): Simplify.
16460 (emit_stop_event): Use gdbpy_ref.
16461 * python/py-signalevent.c (create_signal_event_object): Use
16462 gdbpy_ref.
16463 * python/py-newobjfileevent.c (create_new_objfile_event_object)
16464 (emit_new_objfile_event, create_clear_objfiles_event_object)
16465 (emit_clear_objfiles_event): Use gdbpy_ref.
16466 * python/py-infevents.c (create_inferior_call_event_object)
16467 (create_register_changed_event_object)
16468 (create_memory_changed_event_object, emit_inferior_call_event)
16469 (emit_memory_changed_event, emit_register_changed_event): Use
16470 gdbpy_ref.
16471 * python/py-exitedevent.c (create_exited_event_object)
16472 (emit_exited_event): Use gdbpy_ref.
16473 * python/py-event.h (evpy_emit_event): Remove
16474 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
16475 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
16476 * python/py-continueevent.c (emit_continue_event): Use
16477 gdbpy_ref.
16478 * python/py-breakpoint.c (gdbpy_breakpoint_created)
16479 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
16480 gdbpy_ref.
16481 * python/py-bpevent.c (create_breakpoint_event_object): Use
16482 gdbpy_ref.
16483
16484 2017-01-10 Tom Tromey <tom@tromey.com>
16485
16486 * python/py-ref.h: New file.
16487
16488 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
16489
16490 * cli-out.c (cli_ui_out::do_redirect): Change return type to
16491 void.
16492 * cli-out.h (cli_ui_out::do_redirect): Likewise.
16493 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
16494 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
16495 * ui-out.c (ui_out::redirect): Likewise.
16496 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
16497 * cli/cli-logging.c (set_logging_redirect): Update call site of
16498 ui_out::redirect.
16499 (handle_redirections): Likewise.
16500 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
16501 * top.c (execute_command_to_string): Likewise.
16502 * utils.c (do_ui_out_redirect_pop): Likewise.
16503
16504 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
16505
16506 * stack.c (_initialize_stack): Update "frame" command help message.
16507
16508 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
16509
16510 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
16511
16512 2017-01-06 Yao Qi <yao.qi@linaro.org>
16513
16514 * x86-linux-nat.h: Include gdb_proc_service.h.
16515
16516 2017-01-06 Yao Qi <yao.qi@linaro.org>
16517
16518 * ser-base.h: Include serial.h.
16519
16520 2017-01-06 Yao Qi <yao.qi@linaro.org>
16521
16522 * ppc-linux-tdep.h: Include ppc-tdep.h.
16523
16524 2017-01-06 Yao Qi <yao.qi@linaro.org>
16525
16526 * nat/amd64-linux-siginfo.h: Include signal.h.
16527
16528 2017-01-06 Yao Qi <yao.qi@linaro.org>
16529
16530 * nat/aarch64-linux-hw-point.h: Include break-common.h.
16531
16532 2017-01-06 Yao Qi <yao.qi@linaro.org>
16533
16534 * mi/mi-parse.h: Include mi-cmds.h.
16535
16536 2017-01-06 Yao Qi <yao.qi@linaro.org>
16537
16538 * inf-loop.c: Don't include "target.h".
16539 * inf-loop.h: Include it here.
16540
16541 2017-01-06 Yao Qi <yao.qi@linaro.org>
16542
16543 * dfp.h: Include "dboulest.h" and "expression.h".
16544
16545 2017-01-06 Yao Qi <yao.qi@linaro.org>
16546
16547 * ax-gdb.h: Include "ax.h".
16548
16549 2017-01-06 Yao Qi <yao.qi@linaro.org>
16550
16551 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
16552 with nat/gdb_ptrace.h.
16553
16554 2017-01-05 Yao Qi <yao.qi@linaro.org>
16555
16556 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
16557 new line.
16558 (mips64_fbsd_sigframe_init): Likewise.
16559
16560 2017-01-04 John Baldwin <jhb@FreeBSD.org>
16561
16562 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
16563 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
16564
16565 2017-01-04 John Baldwin <jhb@FreeBSD.org>
16566
16567 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
16568 * NEWS: Mention new FreeBSD/mips native configuration.
16569 * config/mips/fbsd.mh: New file.
16570 * configure.host: Add mips*-*-freebsd*.
16571 * mips-fbsd-nat.c: New file.
16572
16573 2017-01-04 John Baldwin <jhb@FreeBSD.org>
16574
16575 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
16576 (ALLDEPFILES): Add mips-fbsd-tdep.c.
16577 * NEWS: Mention new FreeBSD/mips target.
16578 * configure.tgt: Add mips*-*-freebsd*.
16579 * mips-fbsd-tdep.c: New file.
16580 * mips-fbsd-tdep.h: New file.
16581
16582 2017-01-04 Yao Qi <yao.qi@linaro.org>
16583
16584 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
16585 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
16586
16587 2017-01-01 Joel Brobecker <brobecker@adacore.com>
16588
16589 Update copyright year range in all GDB files.
16590
16591 2017-01-01 Joel Brobecker <brobecker@adacore.com>
16592
16593 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
16594
16595 For older changes see ChangeLog-2016.
16596 \f
16597 Local Variables:
16598 mode: change-log
16599 left-margin: 8
16600 fill-column: 74
16601 version-control: never
16602 coding: utf-8
16603 End:
This page took 0.40821 seconds and 4 git commands to generate.