2008-10-23 Paul Pluzhnikov <ppluzhnikov@google.com>
[external/binutils.git] / gdb / ChangeLog
1 2008-10-23  Paul Pluzhnikov  <ppluzhnikov@google.com>
2
3         * python/python-value (valpy_getitem): Fix heap corruption.
4         
5 2008-10-23  Aleksandar Ristovski  <aristovski@qnx.com>
6
7         * nto-procfs.c (do_attach): Form proper ptid including pid and tid.
8         (procfs_create_inferior): Fetch list of threads.
9
10 2008-10-23  Aleksandar Ristovski  <aristovski@qnx.com>
11
12         * nto-procfs.c (procfs_files_info): Fix a typo.
13         (procfs_create_inferior): Make attach_flag per-inferior.
14
15 2008-10-23  Tom Tromey  <tromey@redhat.com>
16
17         * python/python-value.c (value_to_value_object): Initialize
18         owned_by_gdb field.
19         (valpy_new): Likewise.
20         
21 2008-10-23  Jan Kratochvil  <jan.kratochvil@redhat.com>
22             Joel Brobecker  <brobecker@adacore.com>
23
24         * ada-tasks.c (task_states, long_task_states): Use constant N_()
25         initializer.  Define the strings as const.
26         (short_task_info, info_task): Translate the strings above.
27
28 2008-10-22  Joel Brobecker  <brobecker@adacore.com>
29
30         * NEWS: Add entry for new feature (Ada tasking support).
31
32 2008-10-22  Joel Brobecker  <brobecker@adacore.com>
33
34         * configure.ac: On alpha-osf, error out if enable_tui is set to
35         "yes", and set enable_tui to "no" if previously set to "auto".
36         Check for waddstr only if TUI support was requested. Move the
37         part of the configure script that updates various Makefile
38         variables up, together with the check for waddstr.
39         * configure: Regenerate.
40
41 2008-10-22  Joel brobecker  <brobecker@adacore.com>
42
43         * gdbtypes.c (copy_type): New function.
44         * gdbtypes.h (copy_type): Add declaration.
45         * ada-lang.c (ada_to_fixed_type_1): If there is a parallel XVZ
46         variable, then use it.
47
48 2008-10-22  Joel Brobecker  <brobecker@adacore.com>
49
50         * target.h (struct target_ops): Add new field to_get_ada_task_ptid.
51         (target_get_ada_task_ptid): New macro.
52         * target.c (default_get_ada_task_ptid): New function.
53         (update_current_target): Inherit field default_get_ada_task_ptid.
54         (update_current_target): Make default_get_ada_task_ptid the default
55         value for field to_get_ada_task_ptid.
56         * ada-lang.h (struct task_control_block): Delete. Never used.
57         (struct task_ptid, task_ptid_t, struct task_entry, task_list):
58         Likewise.
59         (struct ada_task_info): New.
60         (ada_task_is_alive, ada_find_printable_frame)
61         (ada_task_list_iterator_ftype, iterate_over_live_ada_tasks): Add
62         declarations.
63         (ada_build_task_list): Update prototype.
64         (init_task_list, ada_is_exception_breakpoint): Remove prototypes.
65         * ada-lang.c (ada_find_printable_frame): Make non-static.
66         * ada-tasks.c: New file.
67         * Makefile.in (SFILES): Add ada-tasks.c.
68         (COMMON_OBS): Add ada-tasks.o.
69         * linux-thread-db.c (thread_db_find_thread_from_tid)
70         (thread_db_get_ada_task_ptid): New functions.
71         (init_thread_db_ops): Set thread_db_ops.to_get_ada_task_ptid.
72
73 2008-10-22  Tom Tromey  <tromey@redhat.com>
74
75         PR gdb/2506:
76         * c-exp.y (string_exp): New production.
77         (exp): Use it.
78
79 2008-10-21  Jan Kratochvil  <jan.kratochvil@redhat.com>
80
81         * mips-tdep.c (mips_n32n64_fp_arg_chunk_p): Update TYPE_FIELD_STATIC
82         removed before.
83
84 2008-10-20  Joel Brobecker  <brobecker@adacore.com>
85
86         * NEWS: Add entry mentioning thread-support on Tru64
87
88 2008-10-19  Joel Brobecker  <brobecker@adacore.com>
89
90         * dec-thread.c: New file.
91         * config/alpha/alpha-osf3.mh (NATDEPFILES): Add dec-thread.o.
92         (NAT_CLIBS): Define.
93
94 2008-10-19  Hui Zhu  <teawater@gmail.com>
95
96         * infrun.c (handle_inferior_event): Set "stop_pc" when
97         TARGET_WAITKIND_NO_HISTORY.
98
99 2008-10-19  Pedro Alves  <pedro@codesourcery.com>
100
101         * python/python-value.c (value_object_methods)
102         (value_object_as_number, value_object_as_mapping): Move to bottom
103         of file.
104         (valpy_dealloc, valpy_new, valpy_length, valpy_getitem)
105         (valpy_setitem, valpy_str, valpy_add, valpy_subtract)
106         (valpy_multiply, valpy_divide, valpy_remainder, valpy_power)
107         (valpy_negative, valpy_positive, valpy_absolute, valpy_nonzero)
108         (valpy_richcompare, valpy_dereference): Don't forward-declare.
109         (valpy_length) [HAVE_LIBPYTHON2_4]: Change return type to `int'.
110
111 2008-10-18  Pedro Alves  <pedro@codesourcery.com>
112
113         * infrun.c (adjust_pc_after_break): Do nothing if executing in
114         reverse.
115
116 2008-10-17  Pedro Alves  <pedro@codesourcery.com>
117
118         * infcmd.c (GO_USAGE): Delete.
119         (go_command): Adjust.
120
121 2008-10-17  Michael Snyder  <msnyder@vmware.com>
122         Target interface for reverse debugging.
123         * target.h (enum target_waitkind): 
124         Add new wait event, TARGET_WAITKIND_NO_HISTORY.
125         (struct target_ops): New method to_can_execute_reverse.
126         (target_can_execute_reverse): New macro.
127         * target.c (update_current_target): Inherit to_can_execute_reverse.
128
129         Remote interface for reverse debugging.
130         * remote.c (remote_can_execute_reverse): New target method.
131         (remote_resume): Check for reverse exec direction, and send 
132         appropriate command to target.
133         (remote_wait_as): Check target response for NO_HISTORY status.
134         Also check for empty reply (target doesn't understand "bs" or "bc).
135         (remote_vcont_resume): Jump out if attempting reverse execution.
136
137         Event handling interface for reverse debugging.
138         * infrun.c (execution_direction): New state variable.
139         (enum inferior_stop_reason): Add NO_HISTORY reason.
140         (handle_inferior_event): Handle TARGET_WAITKIND_NO_HISTORY.
141         Handle stepping over a function call in reverse.
142         Handle stepping thru a line range in reverse.
143         Handle setting a step-resume breakpoint in reverse.
144         Handle stepping into a function in reverse.
145         Handle stepping between line ranges in reverse.
146         (print_stop_reason): Print reason for NO_HISTORY.
147         (step_into_function): Rename to handle_step_into_function.
148         (handle_step_into_function_backward): New function.
149         (set_exec_direction_func, show_exec_direction_func): New funcs.
150         (proceed): No need to singlestep over a breakpoint
151         when resuming in reverse.
152         
153         * inferior.h (enum exec_direction_kind): New enum.
154         (execution_direction): Export new execution state variable.
155
156         * breakpoint.c (make_breakpoint_silent): New function.
157         * breakpoint.h (make_breakpoint_silent): Export.
158         * infcmd.c (finish_command): Check for reverse exec direction.
159         (finish_backward): New function, handle finish cmd in reverse.
160
161         User interface for reverse execution.
162         * Makefile.in (reverse.c): New file.
163         * reverse.c: New file.  User interface for reverse execution.
164
165 2008-10-17  Pedro Alves  <pedro@codesourcery.com>
166
167         * remote.c (record_currthread): Add inferior before child threads.
168         (remote_threads_info): Check for exited threads.  Mention
169         notification order.
170
171 2008-10-16  Joel Brobecker  <brobecker@adacore.com>
172
173         * breakpoint.h (enum bptype): New enum bp_catchpoint.
174         Delete bp_catch_fork and bp_catch_vfork.
175         (struct breakpoint_ops): Add new methods "insert", "remove"
176         and "breakpoint_hit".
177         * breakpoint.c (create_fork_vfork_event_catchpoint)
178         (create_fork_event_catchpoint, create_vfork_event_catchpoint): Remove.
179         (insert_catchpoint): Remove handling of bp_catch_fork and
180         bp_catch_vfork catchpoints, and handle them as bp_catchpoint
181         catchpoints instead.
182         (insert_bp_location, update_breakpoints_after_exec)
183         (remove_breakpoint, bpstat_check_location, bpstat_what)
184         (allocate_bp_location): Likewise.
185         (print_it_typical, print_one_breakpoint_location, mention): Remove
186         handling of bp_catch_fork and bp_catch_vfork breakpoints.
187         (ep_is_catchpoint, user_settable_breakpoint)
188         (breakpoint_address_is_meaningful, adjust_breakpoint_address)
189         (breakpoint_re_set_one, disable_command, enable_command):
190         Remove use of bp_catch_fork and bp_catch_vfork.  Add handling of
191         bp_catchpoint breakpoints.
192         (insert_catch_fork, remove_catch_fork, breakpoint_hit_catch_fork)
193         (print_it_catch_fork, print_one_catch_fork, print_mention_catch_fork):
194         New functions.
195         (catch_fork_breakpoint_ops): New static constant.
196         (insert_catch_vfork, remove_catch_vfork, breakpoint_hit_catch_vfork)
197         (print_it_catch_vfork, print_one_catch_vfork)
198         (print_mention_catch_vfork): New functions.
199         (catch_vfork_breakpoint_ops): New static constant.
200         (create_catchpoint, create_fork_vfork_event_catchpoint): New functions.
201         (catch_fork_command_1): Use create_fork_vfork_event_catchpoint
202         to create the fork and vfork catchpoints.
203         (gnu_v3_exception_catchpoint_ops): Set new breakpoint_ops fields.
204         * ada-lang.c (catch_exception_breakpoint_ops): Set new breakpoint_ops
205         fields.
206         (catch_exception_unhandled_breakpoint_ops): Likewise.
207         (catch_assert_breakpoint_ops): Likewise.
208
209 2008-10-16  Pedro Alves  <pedro@codesourcery.com>
210
211         * remote.c (set_general_process): New.
212         (remote_check_symbols): Use it.
213
214 2008-10-16  Pedro Alves  <pedro@codesourcery.com>
215
216         * remote.c (push_remote_target): Delete.
217         * target.h (push_remote_target): Delete declaration.
218
219 2008-10-15  Pedro Alves  <pedro@codesourcery.com>
220
221         * remote.c (remote_close): Unregister remote_desc from the event
222         loop.  Always restore the SIGINT handler.  Discard all inferiors
223         here.
224         (remote_detach_1, remote_disconnect): Don't unregister the file
225         descriptor from the event loop here.
226         (interrupt_query, readchar, getpkt_sane): Pop the target instead
227         of morning the current inferior.
228         (remote_kill): Don't unregister the file descriptor from the event
229         loop here.
230         (remote_mourn_1): Don't discard inferiors here.
231
232 2008-10-15  Pedro Alves  <pedro@codesourcery.com>
233
234         * breakpoint.c (breakpoint_init_inferior): Clean up the moribund
235         locations list.
236         (moribund_breakpoint_here_p): Record the moribund
237         location in the moribund_locations vector.
238         * breakpoint.h (moribund_breakpoint_here_p): Declare.
239         (displaced_step_fixup): Check if the breakpoint the thread was
240         trying to step over has been removed since having been placed in
241         the displaced stepping queue.
242         (adjust_pc_after_break): In non-stop mode, check for a moribund
243         breakpoint at the stop pc.
244         (handle_inferior_event): Don't retire moribund breakpoints on
245         TARGET_WAITKIND_IGNORE.
246
247 2008-10-15  Pedro Alves  <pedro@codesourcery.com>
248
249         * infrun.c (displaced_step_prepare): Switch thread temporarily
250         while we're here.
251         (displaced_step_fixup): Make sure target_resume sees ptid as
252         inferior_ptid.  Add debug output.
253
254 2008-10-14  Pedro Alves  <pedro@codesourcery.com>
255
256         Remove dead code.
257
258         * breakpoint.c (show_breakpoint_hit_counts): Delete.
259         (print_one_breakpoint_location): Adjust.
260         (breakpoint_clear_ignore_counts): Delete.
261         * breakpoint.h (breakpoint_clear_ignore_counts): Remove
262         declaration.
263         * target.c (generic_mourn_inferior): Don't clear ignore
264         counts (never reached).
265
266 2008-10-10  Doug Evans  <dje@google.com>
267
268         * dwarf2read.c (comp_unit_head): Use unsigned int consistently
269         for dwarf section offsets and sizes.
270         (dwarf2_cu): Ditto.
271         (dwarf2_per_cu_data): Ditto.
272         (create_all_comp_units): Change offset to unsigned int.
273         (load_full_comp_unit,find_partial_die_in_comp_unit,find_partial_die,
274         dwarf2_find_containing_comp_unit,dwarf2_find_comp_unit): Ditto.
275
276         * dwarf2read.c (read_initial_length): Delete cu_header arg.
277         All callers updated.
278         (read_checked_initial_length_and_offset): New function.
279         (read_offset_1): New function.
280         (read_offset): Call it.
281         (dwarf_decode_line_header): Call read_checked_initial_length_and_offset
282         instead of read_initial_length.  Call read_offset_1 instead of
283         read_offset.
284
285         * dwarf2read.c (dwarf2_get_ref_die_offset): Remove unused arg `cu'.
286         All callers updated.
287
288         * dwarf2read.c (dwarf_attr_name): Unconditionally support all
289         DW_AT_MIPS_* except DW_AT_MIPS_fde which collides with
290         DW_AT_HP_block_index.
291
292 2008-10-10  Pedro Alves  <pedro@codesourcery.com>
293
294         * remote.c (remote_start_remote): Always tell the stub if we're in
295         extended-remote.
296
297 2008-10-09  Pedro Alves  <pedro@codesourcery.com>
298
299         * remote.c (remote_wait): Rename to...
300         (remote_wait_as): ... this.  Don't loop here.  If the remote
301         didn't stop, return TARGET_WAITKIND_IGNORE.
302         (remote_wait): New, reimplemented on top of remote_wait_as.
303
304 2008-10-09  Thomas Schwinge  <tschwinge@gnu.org>
305
306         * Makefile.in (gnu-nat.o): Revert the 2008-09-10 change, as the problem
307         is fixed upstream.
308
309         * reply_mig_hack.awk: Use the `BAD_TYPECHECK' macro.
310
311         * MAINTAINERS (Write After Approval): Add myself.
312
313 2008-10-09  Pedro Alves  <pedro@codesourcery.com>
314
315         Make it compile without warnings.
316
317         * procfs.c (create_procinfo): Initialize `parent'.
318         (dead_procinfo): Pass a constant string as format to error.
319         (procfs_address_to_host_pointer): Add cast to gdb_type *.
320         (procfs_find_LDT_entry): Adjust format string to long int
321         ptid.tid.
322         (procfs_xfer_partial): Adjust prototype.  Add gdb_byte* cast.
323         (procfs_xfer_memory): Adjust prototype.
324         (info_mappings_callback, info_proc_mappings): Adjust to not pass a
325         variable as printf_filtered format.
326         (procfs_make_note_section): Change type of auxv local to gdb_byte.
327         * Makefile.in: Remove special rule.
328
329 2008-10-09  Pedro Alves  <pedro@codesourcery.com>
330             Daniel Jacobowitz  <dan@codesourcery.com>
331
332         * remote.c (remote_open_1): Move acknowledging any pending ack,
333         querying supported features, activating noack mode, finding the
334         target description, enabling extended remote, and checking remote
335         symbols from here ...
336         (remote_start_remote): ... to here.
337         (remote_open_1): Don't pop the target if it is already gone.
338         * target.c (unpush_target): Check for the dummy target.
339
340 2008-10-09  Pedro Alves  <pedro@codesourcery.com>
341
342         * ser-mingw.c: Include "command.h".
343         (pipe_windows_open): Declare locals at the beginning of the scope.
344
345 2008-10-08  Pedro Alves  <pedro@codesourcery.com>
346
347         * remote.c (struct remote_state) <waiting_for_stop_reply>: New
348         field.
349         (remote_open_1): Clear waiting_for_stop_reply.
350         (remote_resume): Set waiting_for_stop_reply.
351         (remote_wait): Clear or set waiting_for_stop_reply accordingly.
352         (putpkt_binary): If we're in async mode and waiting for a stop
353         reply, bail out with an error.
354         (extended_remote_mourn_1): Clear waiting_for_stop_reply.
355
356 2008-10-08  Pedro Alves  <pedro@codesourcery.com>
357
358         * remote.c (remote_get_thread_info): If the remote doesn't support
359         the query, bail out.
360
361 2008-10-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
362
363         Convert static_kind into loc_kind enum.
364         * gdbtypes.h (enum field_loc_kind): New.
365         (union field_location): New field dwarf_block.
366         (struct field): Rename static_kind as loc_kind.
367         (FIELD_STATIC_KIND): Rename to ...
368         (FIELD_LOC_KIND): ... here.
369         (TYPE_FIELD_STATIC_KIND): Rename to ...
370         (TYPE_FIELD_LOC_KIND): ... here and use there now new FIELD_LOC_KIND.
371         (TYPE_FIELD_STATIC_HAS_ADDR): Remove.
372         (TYPE_FIELD_STATIC): Remove.
373         (TYPE_FIELD_BITPOS): Reformat.
374         (SET_FIELD_BITPOS): New.
375         (FIELD_PHYSADDR): Rename to ...
376         (FIELD_STATIC_PHYSADDR): ... here.
377         (TYPE_FIELD_STATIC_PHYSADDR): Follow the FIELD_PHYSADDR rename.
378         (SET_FIELD_PHYSADDR): Use new FIELD_LOC_KIND.
379         (FIELD_PHYSNAME): Rename to ...
380         (FIELD_STATIC_PHYSNAME): ... here.
381         (TYPE_FIELD_STATIC_PHYSNAME): Follow the FIELD_PHYSNAME rename.
382         (SET_FIELD_PHYSNAME): Use new FIELD_LOC_KIND.
383         (FIELD_DWARF_BLOCK, TYPE_FIELD_DWARF_BLOCK, SET_FIELD_DWARF_BLOCK): New.
384         (field_is_static): New declaration.
385         * gdbtypes.c (field_is_static): New function.
386         (copy_type_recursive): Update throughout.
387         * amd64-tdep.c, c-typeprint.c, coffread.c, cp-valprint.c, dwarf2read.c,
388         eval.c, jv-typeprint.c, jv-valprint.c, mdebugread.c, p-typeprint.c,
389         p-valprint.c, valops.c, value.c, varobj.c: Update throughout.
390
391 2008-10-07  Thomas Schwinge  <tschwinge@gnu.org>
392             Pedro Alves  <pedro@codesourcery.com>
393
394         * gnu-nat.h: Rename `current_inferior' to `gnu_current_inf' to
395         avoid a name collision.
396         * gnu-nat.c: Likewise.
397         * i386gnu-nat.c: Likewise.
398
399 2008-10-07  Joel Brobecker  <brobecker@adacore.com>
400
401         * ada-lang.c (ada_evaluate_subexp) [OP_ATR_SIZE]: Add handling
402         of arguments that are references.
403
404 2008-10-06  Doug Evans  <dje@google.com>
405
406         * dwarf2read.c (dwarf2_die_debug): New static global.
407         (dump_die_shallow): Renamed from dump_die, New args f, indent.
408         Print to specified file, indented by the specified amount.
409         (dump_die_for_error): New fn.  Point all existing callers of
410         dump_die here.
411         (dump_die_die_1,dump_die): New fns, replaces ...
412         (dump_die_list): ... deleted.
413         (read_die_and_children_1): Old contents of read_die_and_children
414         moved here.
415         (read_die_and_children): Rewrite.
416         (read_die_and_siblings): Call read_die_and_children_1 instead of
417         read_die_and_children.
418         (_initialize_dwarf2_read): New option "debug dwarf2-die".
419         * gdbinit.in (pdie): New macro.
420
421         * dwarf2read.c (offset_in_cu_p): New function.
422         (find_partial_die,follow_die_ref): Use it.
423
424         * symmisc.c (maintenance_info_symtabs): Watch for ^c.
425         (maintenance_info_psymtabs): Ditto.
426
427 2008-10-05  Michael Snyder  <msnyder@vmware.com>
428
429         * infrun.c (handle_inferior_event): Fix typo in comment.
430
431 2008-10-04  Vladimir Prus  <vladimir@codesourcery.com>
432
433         * mi/mi-interp.c (mi_on_resume): Flush raw_stdout.
434
435 2008-10-03  Paul Pluzhnikov  <ppluzhnikov@google.com>
436
437         PR gdb/2384:
438         * gdbtypes.c (get_vptr_fieldno): baseclass and basetype may have
439         different lifetimes.
440         
441 2008-10-03  Joel Brobecker  <brobecker@adacore.com>
442
443         * solib-osf.c: Include "solib.h".
444
445 2008-10-03  Paul Pluzhnikov  <ppluzhnikov@google.com>
446         
447         * utils.c, defs.h (gdb_buildargv): New fn. Wrap buildargv
448         and check for out-of-memory condition.
449         * exec.c (exec_file_command): Call it.
450         * infrun.c (handle_command, xdb_handle_command): Likewise.
451         * interps.c (interpreter_exec_cmd): Likewise.
452         * linux-nat.c (linux_nat_info_proc_cmd): Likewise.
453         * procfs.c (info_proc_cmd): Likewise.
454         * remote-mips.c (common_open): Likewise.
455         * remote-sim.c (gdbsim_kill, gdbsim_create_inferior)
456         (gdbsim_open): Likewise.
457         * remote.c (extended_remote_run, remote_put_command)
458         (remote_get_command, remote_delete_command): Likewise.
459         * ser-mingw.c (pipe_windows_open): Likesise.
460         * source.c (add_path, show_substitute_path_command)
461         (unset_substitute_path_command, set_substitute_path_command):
462         Likewise.
463         * stack.c (backtrace_command): Likewise.
464         * symfile.c (symbol_file_command, generic_load)
465         (add_symbol_file_command): Likesise.
466         * symmisc.c (maintenance_print_symbols, maintenance_print_psymbols)
467         (maintenance_print_msymbols): Likewise.
468
469 2008-10-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
470
471         Replace TYPE_ARRAY_{UPPER,LOWER}_BOUND_TYPE by a bit if {un,}defined.
472         * c-typeprint.c (c_type_print_varspec_suffix), m2-typeprint.c
473         (m2_array), p-typeprint.c (pascal_type_print_varspec_prefix),
474         valops.c (value_cast), varobj.c (c_number_of_children): Replace
475         TYPE_ARRAY_UPPER_BOUND_TYPE compared to BOUND_CANNOT_BE_DETERMINED by
476         TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED.
477         * parse.c (follow_types): Use TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED.
478         * f-valprint.c (f77_get_dynamic_upperbound): Replace with ...
479         (f77_get_upperbound): ... this function handling now only
480         TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED.
481         (f77_get_dynamic_lowerbound): Replace with ...
482         (f77_get_lowerbound): ... this function handling now only
483         TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED.
484         (f77_get_dynamic_length_of_aggregate, f77_create_arrayprint_offset_tbl):
485         Update their callers.
486         * eval.c (evaluate_subexp_standard): Update their callers.
487         * f-lang.h (f77_get_dynamic_upperbound, f77_get_upperbound)
488         (f77_get_dynamic_lowerbound, f77_get_lowerbound): Update their
489         prototypes.
490         (BOUND_FETCH_OK, BOUND_FETCH_ERROR): Remove.
491         * f-typeprint.c (f_type_print_varspec_suffix, f_type_print_base): Remove
492         the lower_bound_was_default variable.  Update the
493         f77_get_dynamic_upperbound, f77_get_upperbound and
494         TYPE_ARRAY_UPPER_BOUND_TYPE calls.
495         * gdbtypes.c (print_bound_type): Remove the function.
496         (recursive_dump_type): Remove its calls printing UPPER_BOUND_TYPE and
497         LOWER_BOUND_TYPE.
498         * gdbtypes.h (enum array_bound_type): Remove.
499         (struct main_type): Remove the fields upper_bound_type and
500         lower_bound_type.  Comment the new overload of the field artificial.
501         (TYPE_ARRAY_UPPER_BOUND_TYPE): Replace by ...
502         (TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED): ... this macro.
503         (TYPE_ARRAY_LOWER_BOUND_TYPE): Replace by ...
504         (TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED): ... this macro.
505
506 2008-10-02  Tom Tromey  <tromey@redhat.com>
507
508         * Makefile.in (HFILES_NO_SRCDIR): Remove gdb-events.h, gstdint.h.
509
510 2008-10-02  Daniel Jacobowitz  <dan@codesourcery.com>
511
512         * mips-linux-tdep.c (mips_linux_in_dynsym_resolve_code): Update
513         comments.
514         (mips_linux_skip_resolver): Also use glibc_skip_solib_resolver.
515         (mips_linux_init_abi): Do not override skip_trampoline_code.
516         * configure.tgt (mips*-*-linux*): Add glibc-tdep.o.
517         * mips-tdep.c (mips32_scan_prologue): Stop scanning at branches.
518         (mips_stub_frame_sniffer): Use the stub frame sniffer for PIC stubs.
519         (mips_skip_mips16_trampoline_code): Rename from
520         mips_skip_trampoline_code.
521         (mips_skip_pic_trampoline_code, mips_skip_trampoline_code): New.
522         * infrun.c (handle_inferior_event): Do not pass zero to
523         in_solib_dynsym_resolve_code.
524
525 2008-10-02  Pierre Muller  <muller@ics.u-strasbg.fr>
526             Pedro Alves  <pedro@codesourcery.com>
527
528         * win32-nat.c (do_initial_win32_stuff): Set inferior_ptid.
529
530
531 2008-10-01  Tom Tromey  <tromey@redhat.com>
532
533         * symtab.c (search_symbols): Update.
534         * symtab.h (domain_enum_tag) <METHODS_DOMAIN>: Remove.
535
536 2008-10-01  Tom Tromey  <tromey@redhat.com>
537
538         * symfile.c (syms_from_objfile): Update.
539         (reread_symbols): Update.
540         * objfiles.h (OBJF_SYMS): Remove.
541         (OBJF_REORDERED): Renumber.
542         (OBJF_SHARED): Likewise.
543         (OBJF_READNOW): Likewise.
544         (OBJF_USERLOADED): Likewise.
545
546 2008-10-01  Tom Tromey  <tromey@redhat.com>
547
548         * symtab.c (find_pc_sect_psymtab): Use MSYMBOL_TYPE.
549         (find_pc_sect_symtab): Likewise.
550         * symmisc.c (dump_msymbols): Use MSYMBOL_TYPE.
551         * solib-som.c (som_solib_desire_dynamic_linker_symbols): Use
552         MSYMBOL_TYPE, not SYMBOL_TYPE.
553         * parse.c (write_exp_msymbol): Use MSYMBOL_TYPE.
554         * objc-lang.c (find_methods): Use MSYMBOL_TYPE.
555         * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Use
556         MSYMBOL_TYPE.
557         * m2-exp.y (yylex): Use SYMBOL_CLASS.
558
559 2008-10-01  Tom Tromey  <tromey@redhat.com>
560
561         * xcoffread.c (RECORD_MINIMAL_SYMBOL): Update.
562         (scan_xcoff_symtab): Update.
563         * mdebugread.c (record_minimal_symbol): Update.
564         (parse_partial_symbols): Update.
565         * elfread.c (record_minimal_symbol): Update.
566         * dbxread.c (record_minimal_symbol): Update.
567         * coffread.c (record_minimal_symbol): Update.
568         * sh64-tdep.c (MSYMBOL_IS_SPECIAL): Redefine.
569         (sh64_elf_make_msymbol_special): Update.
570         * mips-tdep.c (mips_elf_make_msymbol_special): Use
571         MSYMBOL_TARGET_FLAG_1.
572         (mips_elf_make_msymbol_special): Likewise.
573         (msymbol_is_special): Likewise.
574         * minsyms.c (prim_record_minimal_symbol_and_info): Update.
575         (install_minimal_symbols): Likewise.
576         (prim_record_minimal_symbol): Update.
577         (prim_record_minimal_symbol_and_info): Remove 'info' argument.
578         * m68hc11-tdep.c (MSYMBOL_SET_RTC): Redefine.
579         (MSYMBOL_SET_RTI): Redefine.
580         (MSYMBOL_IS_RTC): Redefine.
581         (MSYMBOL_IS_RTI): Redefine.
582         * arm-tdep.c (MSYMBOL_SET_SPECIAL): Redefine.
583         (MSYMBOL_IS_SPECIAL): Redefine.
584         * symtab.h (struct minimal_symbol) <info>: Remove.
585         <target_flag_1, target_flag_2>: New fields.
586         (MSYMBOL_INFO): Remove.
587         (MSYMBOL_TARGET_FLAG_1): New macro.
588         (MSYMBOL_TARGET_FLAG_2): Likewise.
589         (prim_record_minimal_symbol_and_info): Update.
590
591 2008-09-30  Joel Brobecker  <brobecker@adacore.com>
592
593         * ada-lang.c (is_digits_suffix): Delete unused function.
594
595 2008-09-30  Paul Hilfinger  <hilfinger@adacore.com>
596
597         * ada-lang.c (ada_modulus): Correct to avoid sign problem with
598         moduli >= 2**31.
599
600 2008-09-30  Paul Hilfinger  <hilfinger@adacore.com>
601
602         * ada-lang.c (ada_lookup_struct_elt_type): Handle case of a "naked"
603         variant branch.
604         (empty_record): Use INIT_CPLUS_SPECIFIC, since this field is not
605         supposed to be null.  Fixes debugger segfaults.
606         (is_unchecked_variant): New function.
607         (to_fixed_variant_branch_type): Modify to leave unchecked unions
608         untouched.
609         (ada_template_to_fixed_record_type_1): Fix comment.
610
611 2008-09-30  Joel Brobecker  <brobecker@adacore.com>
612
613         * ada-lang.c (standard_exc): New static constant.
614         (ada_exception_catchpoint_cond_string): Add special handling
615         for the predefined exceptions.
616
617 2008-09-30  Joel Brobecker  <brobecker@adacore.com>
618
619         * ada-lang.c (ADA_RETAIN_DOTS): Delete this dead macro.  Update
620         the code accordingly.
621
622 2008-09-30  Joel Brobecker  <brobecker@adacore.com>
623
624         * ada-lang.c (ada_evaluate_subexp) [UNOP_IND]: Remove strange
625         treatment of expect_type. Return the correct type when dereferencing
626         an integer.
627
628 2008-09-30  Tom Tromey  <tromey@redhat.com>
629
630         PR gdb/2484:
631         * symtab.c (struct add_macro_name_data): New struct.
632         (add_macro_name): New function.
633         (default_make_symbol_completion_list): Complete macro names.
634         * scm-lang.c (scm_language_defn): Update.
635         * p-lang.c (pascal_language_defn): Update.
636         * objc-lang.c (objc_language_defn): Update.
637         * macrotab.h (macro_callback_fn): Add user_data argument.
638         (macro_for_each): Likewise.
639         (macro_for_each_in_scope): Declare.
640         * macrotab.c: (struct macro_for_each_data): New struct.
641         (foreach_macro): Use it.
642         (macro_for_each): Likewise.
643         (foreach_macro_in_scope): New function.
644         (macro_for_each_in_scope): Likewise.
645         * macrocmd.c (print_one_macro): Add argument.
646         (macro_list_command): Pass NULL to macro_for_each.
647         * m2-lang.c (m2_language_defn): Update.
648         * language.h (struct language_defn) <la_macro_expansion>: New
649         field.
650         (macro_expansion): New enum.
651         * language.c (unknown_language_defn): Update.  Fix order of
652         initializers.
653         (auto_language_defn): Likewise.
654         (local_language_defn): Update.
655         * jv-lang.c (java_language_defn): Update.
656         * f-lang.c (f_language_defn): Update.
657         * c-lang.c (c_language_defn): Update.
658         (cplus_language_defn): Likewise.
659         (asm_language_defn): Likewise.
660         (minimal_language_defn): Likewise.
661         * ada-lang.c (ada_language_defn): Update.
662
663 2008-09-30  Joel Brobecker  <brobecker@adacore.com>
664
665         * dwarf2read.c (dwarf2_get_subprogram_pc_bounds): New function.
666         (get_scope_pc_bounds): Use it.
667
668 2008-09-27  Tom Tromey  <tromey@redhat.com>
669
670         * NEWS: Update.
671         * macrocmd.c (extract_identifier): Add is_parameter argument.
672         (macro_define_command): Update.
673         (macro_undef_command): Likewise.
674         * macroexp.c (stringify): New function.
675         (find_parameter): Likewise.
676         (gather_arguments): Add nargs argument.  Handle varargs.
677         (substitute_args): Add is_varargs and va_arg_name arguments.
678         Handle varargs, splicing, stringification.  Use find_parameter.
679         (expand): Handle varargs.
680
681 2008-09-27  Tom Tromey  <tromey@redhat.com>
682
683         * scm-lang.c (scm_language_defn): Update.
684         * p-typeprint.c (pascal_print_typedef): New function.
685         * p-lang.h: (pascal_print_typedef): Declare.
686         * p-lang.c (pascal_language_defn): Update.
687         * objc-lang.c (objc_language_defn): Update.
688         * m2-typeprint.c (m2_print_typedef): New function.
689         * m2-lang.h (m2_print_typedef): Declare.
690         * m2-lang.c (m2_language_defn): Update.
691         * language.h (_LANG_c, _LANG_m2, _LANG_fortran, _LANG_pascal):
692         Remove.
693         (struct language_defn) <la_print_typedef>: New field.
694         (default_print_typedef): Declare.
695         (LA_PRINT_TYPEDEF): New define.
696         * language.c (unknown_language_defn): Update.
697         (auto_language_defn): Update.
698         (local_language_defn): Update.
699         * jv-lang.c (java_language_defn): Update.
700         * f-lang.c (f_language_defn): Update.
701         * c-typeprint.c (c_print_typedef): New function.
702         * c-lang.h (c_print_typedef): Declare.
703         * c-lang.c (c_language_defn): Update.
704         (cplus_language_defn): Update.
705         (asm_language_defn): Update.
706         (minimal_language_defn): Update.
707         * ada-lang.c (ada_language_defn): Update.
708         * typeprint.c (default_print_typedef): New function.
709
710 2008-09-27  Tom Tromey  <tromey@redhat.com>
711
712         * jv-exp.y (insert_exp): Define using ISO syntax.
713         (copy_exp): Likewise.
714         (push_expression_name): Likewise.
715         (push_fieldnames): Likewise.
716         (java_type_from_name): Likewise.
717         (yyerror): Likewise.
718         (yylex): Likewise.
719         (parse_number): Likewise.
720
721 2008-09-26  Joel Brobecker  <brobecker@adacore.com>
722
723         * MAINTAINERS (GLOBAL MAINTAINERS): Add Pedro Alves.
724
725 2008-09-25  Stephan Springl  <springl-gdb@bfw-online.de> (tiny change)
726
727         * stack.c (print_frame_args): Fix typos in comments.
728
729 2008-09-25  Sérgio Durigan Júnior  <sergiodj@linux.vnet.ibm.com>
730
731         * linux-nat.c (get_pending_status): Fix argument to WIFSTOPPED.
732
733 2008-09-24  Vladimir Prus  <vladimir@codesourcery.com>
734
735         * remote-sim.c (gdbsim_create_inferior): Fix missing parenthesis.
736         
737 2008-09-24  Andreas Schwab  <schwab@suse.de>
738
739         * frame.c (get_frame_register_bytes): Take pseudo registers into
740         account.  Avoid excessive function calls.
741
742 2008-09-23  Doug Evans  <dje@google.com>
743
744         * dcache.c (state_chars): New static global.
745         (ENTRY_INVALID,ENTRY_VALID): Renamed from ENTRY_BAD,ENTRY_OK.
746         All uses updated.
747         (dcache_info): Print cache state as mnemonically useful letters instead
748         of magic numbers.
749
750         * dwarf2read.c (comp_unit_head): Reorganize for better packing.
751
752 2008-09-22  Tom Tromey  <tromey@redhat.com>
753
754         * symfile.c (symbol_file_add_with_addrs_or_offsets): Don't use
755         printf_filtered.
756
757 2008-09-22  Pedro Alves  <pedro@codesourcery.com>
758
759         * infrun.c (follow_exec): Don't do a generic mourn.  Instead
760         inline the required bits.
761         * breakpoint.h (enum inf_context): Add inf_execd.
762
763 2008-09-22  Pedro Alves  <pedro@codesourcery.com>
764
765         * infrun.c (handle_inferior_event): In the follow exec case,
766         context-switch before doing anything else.
767
768 2008-09-22  Pedro Alves  <pedro@codesourcery.com>
769
770         * top.c (any_thread_of, kill_or_detach): New functions.
771         (quit_target): Iterate over all inferiors, killing or detaching
772         accordingly.
773
774 2008-09-22  Pedro Alves  <pedro@codesourcery.com>
775
776         Remove the attach_flag global, and make it per-inferior.
777
778         * inferior.h (attach_flag): Delete.
779         (inferior_process): Declare.
780         * solib.c (update_solib_list): Adjust.
781         * gnu-nat.c (gnu_create_inferior, gnu_attach): Adjust.
782         * inf-ptrace.c (inf_ptrace_detach): Adjust.
783         (inf_ptrace_files_info): Get it from the current inferior.
784         * inf-ttrace.c (inf_ttrace_attach): Adjust.
785         (inf_ttrace_files_info): Get it from the current
786         inferior.
787         * inflow.c (terminal_inferior, terminal_ours_1, set_sigint_trap)
788         (clear_sigint_trap): Get it from the current process.
789         * remote.c (extended_remote_attach_1)
790         (extended_remote_create_inferior_1): Adjust.
791         * top.c (quit_confirm, quit_target): Get it from the current inferior.
792         * procfs.c (do_detach): Adjust.
793         (procfs_wait): Get it from the event inferior.
794         (procfs_files_info): Get it from the current inferior.
795         * nto-procfs.c (procfs_files_info): Likewise.
796         (procfs_attach): Adjust.  Set the attach_flag here.
797         (do_attach): Don't set it here.
798         (procfs_detach): Don't clear it.
799         (procfs_mourn_inferior): Don't clear it.
800         * solib-osf.c (osf_solib_create_inferior_hook): Adjust.
801         * target.c (attach_flag): Delete.
802         (generic_mourn_inferior): Don't clear it.
803         * win32-nat.c (get_win32_debug_event): Get it from the event
804         process.
805         (do_initial_win32_stuff): Add attaching argument.  Set attach_flag
806         in the inferior accordingly.
807         (win32_attach): Don't set the attach_flag here.  Pass 1 to
808         do_intial_win32_stuff.
809         (win32_files_info): Get it from the current inferior.
810         (win32_create_inferior): Dont clear attach_flag here.  Pass 0 to
811         do_intial_win32_stuff.
812
813 2008-09-22  Pedro Alves  <pedro@codesourcery.com>
814
815         Make the stop_soon global be per-inferior instead.
816
817         * infcmd.c (attach_command_post_wait): Adjust.
818         (attach_command): Likewise.
819
820         * inferior.h (stop_soon): Delete.
821         (struct inferior): Add stop_soon member.
822
823         * infrun.c (stop_soon): Delete.
824         (clear_proceed_status, start_remote)
825         (fetch_inferior_event, handle_inferior_event): Adjust.
826         (signal_stop_state): Don't check stop_soon here.  Check in callers
827         instead.
828         (save_inferior_status, restore_inferior_status): Adjust.
829
830         * linux-nat.c (linux_nat_resume, linux_nat_wait): Always pass
831         signals to common code if starting up the inferior.
832         
833         * inferior.h (struct inferior_info): Added stop_soon member.
834         * inferior.c (add_inferior) Clear stop_soon.
835
836         * mips-tdep.c (heuristic_proc_start): Adjust.
837         * nto-procfs.c (procfs_create_inferior): Adjust.
838         * solib-irix.c (irix_solib_create_inferior_hook): Adjust.
839         * solib-osf.c (osf_solib_create_inferior_hook): Adjust.
840         * solib-sunos.c (sunos_solib_create_inferior_hook): Adjust.
841         * solib-svr4.c (svr4_solib_create_inferior_hook): Adjust.
842
843         * win32-nat.c (do_initial_win32_stuff): Adjust.
844
845         * alpha-tdep.c (alpha_heuristic_proc_start): Adjust.
846
847 2008-09-22  Pedro Alves  <pedro@codesourcery.com>
848
849         Implement remote multi-process extensions.
850
851         * remote.c (struct remote_state): Add extended and
852         multi_process_aware fields.
853         (remote_multi_process_p): New.
854         (PACKET_vKill): New.
855         (record_currthread): Use thread_change_ptid.  Notice new
856         inferiors.
857         (set_thread, remote_thread_alive): Use write_ptid.
858         (write_ptid, read_ptid): New.
859         (remote_current_thread, remote_threads_extra_info): Use them.
860         (remote_threads_info): Likewise.  Detect new inferiors.
861         (remote_start_remote): Add inferior to inferior list.
862         (remote_multi_process_feature): New.
863         (remote_protocol_features): Add "multiprocess" feature.
864         (remote_query_supported): Pass "multiprocess+" as supported
865         features.
866         (remote_open_1): Clear multi_process_aware.  Set extended
867         accordingly.
868         (remote_detach_1): Detach current process.  Use extended packet
869         format for extended-remote multi-process.  Detach process from the
870         inferior list.  Only mourn after printing output.
871         (extended_remote_attach_1): Add process to the inferior list.
872         (remote_vcont_resume): Use write_ptid to pass the thread ids.
873         (remote_wait): Use read_ptid.  Implement the extended
874         multi-process extension format of the 'W' and 'X' reply packets.
875         Remove exited inferiors from inferior list.
876         (remote_xfer_memory): Set general thread.
877         (remote_vkill): New.
878         (extended_remote_kill): New.
879         (remote_mourn_1): Discard all inferiors.
880         (select_new_thread_callback): New.
881         (extended_remote_mourn_1): If there are more processes to debug,
882         switch to a thread in another process, and don't pop the target.
883         (extended_remote_create_inferior_1): Add the new process to the
884         inferior list.
885         (remote_stopped_by_watchpoint): Indenting.
886         (remote_xfer_partial): Set the general thread.
887         (remote_pid_to_str): If the remote is multi-process aware, print
888         the process id as well as the thread id.
889         (remote_get_thread_local_address): Use write_ptid.
890         (init_extended_remote_ops): Register extended_remote_kill.
891         (_initialize_remote): Register new packets.  Change
892         magic_null_ptid's, not_sent_ptid's and any_thread_ptid's pid
893         member to 42000.
894
895         * thread.c (thread_change_ptid): Also account for the inferior pid
896         changing.
897
898         * inferior.h (discard_all_inferiors): Declare.
899         * inferior.c (discard_all_inferiors): New.
900
901 2008-09-22  Pedro Alves  <pedro@codesourcery.com>
902
903         * gnu-nat.c (gnu_attach): Add process to inferiors table.
904         (gnu_detach): Remove it.
905         * go32-nat.c (go32_create_inferior): Add process to gdb's inferior
906         table.
907         * inf-ptrace.c (inf_ptrace_follow_fork): Delete and add inferiors
908         to inferior table accordingly.
909         (inf_ptrace_attach): Add new process to inferior table.
910         (inf_ptrace_detach): Remove it.
911         * inf-ttrace.c (inf_ttrace_follow_fork): Delete and add inferiors
912         to inferior table accordingly.
913         (inf_ttrace_attach): Add process to inferior table.
914         (inf_ttrace_detach): Remove it.
915         * linux-fork.c (init_fork_list): Delete any left over inferior.
916         (linux_fork_mourn_inferior, detach_fork_command): Also delete
917         processes from inferior list.
918         * monitor.c (monitor_open): Add process to inferior list.
919         (monitor_close): Remove it.
920         * nto-procfs.c (procfs_attach): Add process to inferior list.
921         Find threads after pushing the target.
922         (procfs_detach): Remove process from inferior list.
923         (procfs_create_inferior): Add process to inferior list.
924         * procfs.c (procfs_detach): Remove process from inferior list.
925         (do_attach): Add process to inferior list.
926         * remote-sim.c (sim_create_inferior): Add process to inferior list.
927         (gdbsim_close): Remove it.
928         * target.c (generic_mourn_inferior): If inferior_ptid is not
929         null_ptid, remove the corresponding inferior from inferior list.
930         * win32-nat.c (do_initial_win32_stuff): Add process to inferior list.
931         (win32_detach): Remove it.
932         * linux-nat.c (linux_child_follow_fork): Delete and add inferiors
933         to inferior list accordingly.
934         * fork-child.c (fork_inferior): Add process to inferior list.
935         * corelow.c (CORELOW_PID): Define.
936         (core_close): Remove core from inferior list.
937         (core_open): Add it.
938
939 2008-09-22  Pedro Alves  <pedro@codesourcery.com>
940
941         * inferior.h: Forward declare struct ui_out.
942         Forward declare struct private_inferior.
943         (struct inferior): New.
944         (init_inferior_list, add_inferior, add_inferior_silent)
945         (delete_inferior, delete_inferior_silent, detach_inferior)
946         (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
947         (valid_inferior_id, find_inferior_pid): New functions.
948         (inferior_callback_func): New typedef.
949         (iterate_over_inferiors, print_inferior, have_inferiors)
950         (current_inferior): New functions.
951         * inferior.c: New file.
952
953         * Makefile.in (SFILES): Add inferior.c.
954         (COMMON_OBS): Add inferior.o.
955
956 2008-09-22  Jonathan Larmour  <jifl@eCosCentric.com>
957
958         * arm-tdep.c (arm_skip_prologue): Call skip_prologue_using_sal
959         instead of determining symbol and line info directly.
960         * MAINTAINERS: Update my email address.
961
962 2008-09-22  Daniel Jacobowitz  <dan@codesourcery.com>
963
964         * symtab.c (skip_prologue_using_sal): Treat two consecutive lines
965         at the same address as a prologue marker.  Do not skip an entire
966         function.
967
968 2008-09-22  Andrew Stubbs  <ams@codesourcery.com>
969
970         * frame.c (get_frame_register_bytes): Comment improvments.
971
972 2008-09-22  Pedro Alves  <pedro@codesourcery.com>
973
974         * linux-nat.c (linux_nat_wait): Only use set_ignore_sigint in
975         all-stop mode.
976
977 2008-09-19  Andrew Stubbs  <ams@codesourcery.com>
978
979         * MAINTAINERS: Update my email address.
980
981 2008-09-19  Andrew Stubbs  <ams@codesourcery.com>
982
983         * frame.c (get_frame_register_bytes): Detect bad debug info.
984
985 2008-09-17  Jan Kratochvil  <jan.kratochvil@redhat.com>
986
987         Fix a crash on uninitialized ECS->EVENT_THREAD for a newly found thread.
988         * infrun.c (wait_for_inferior): Move this ECS->EVENT_THREAD
989         initialization ...
990         (fetch_inferior_event): ... and this ECS->EVENT_THREAD initialization
991         ...
992         (handle_inferior_event): ... here after the add_thread call together
993         with the local adjust_pc_after_break and reinit_frame_cache calls.
994
995 2008-09-16  David Daney  <ddaney@avtrex.com>
996
997         * breakpoint.c (bpstat_stop_status): Clear breakpoint_at for
998         all hardware bpstats.
999
1000 2008-09-16  Joel Brobecker  <brobecker@adacore.com>
1001
1002         * gstdint.h: Delete.
1003
1004 2008-09-15  Mark Kettenis  <kettenis@gnu.org>
1005
1006         * infcall.c (generic_push_dummy_code): Remove.
1007         (push_dummy_code): Unconditionally call gdbarch_push_dummy_code.
1008
1009 2008-09-15  Doug Evans  <dje@google.com>
1010
1011         * dwarf2read.c (struct abbrev_info): Make members name, form 16 bits.
1012         (struct attribute): Ditto.
1013
1014 2008-09-14  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1015
1016         * hppa-linux-tdep.c (hppa_linux_sigtramp_frame_unwind_cache): Record
1017         HPPA_IPSW_REGNUM and HPPA_SAR_REGNUM values.
1018
1019         * hppa-linux-tdep.c (hppa_dwarf_reg_to_regnum): Remove surrounding
1020         "#if 0" "#endif".  Fix mapping of DWARF DBX registers to GDB registers.
1021         Correct arguments and improve comments.
1022         (hppa_linux_init_abi): Call set_gdbarch_dwarf2_reg_to_regnum.  Delete
1023         disabled code.
1024         * hppa-tdep.c (hppa64_dwarf_reg_to_regnum): Fix check for floating
1025         point DBX register, change error to warning, and improve comments.
1026
1027 2008-09-14  Doug Evans  <dje@google.com>
1028
1029         * dwarf2read.c (struct die_info): Make members tag, num_attrs 16 bits.
1030
1031 2008-09-14  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1032
1033         * hppa-linux-tdep.c (hppa_linux_supply_fpregset): Correct iteration.
1034
1035 2008-09-13  Joel Brobecker  <brobecker@adacore.com>
1036
1037         * defs.h (GCC_GENERATED_STDINT_H): Define.
1038
1039 2008-09-13  Tom Tromey  <tromey@redhat.com>
1040
1041         * varobj.c (varobj_set_display_format): Use xfree.
1042         * tracepoint.c (stringify_collection_list): Use xfree.
1043         * remote-fileio.c (remote_fileio_reset): Use xfree.
1044         * mipsread.c (read_alphacoff_dynamic_symtab): Use xfree.
1045         * dfp.c (decimal_from_floating): Use xfree, xstrprintf.  Don't use
1046         asprintf.
1047         * cp-support.c (mangled_name_to_comp): Use xfree.
1048
1049 2008-09-13  Joel Brobecker  <brobecker@adacore.com>
1050
1051         * ada-lang.c (remove_extra_symbols): Remove stub symbols if
1052         the associated complete symbol is also in the list.
1053         (ada_add_local_symbols, ada_add_non_local_symbols): New functions,
1054         extracted out from ada_lookup_symbol_list.
1055         (ada_lookup_symbol_list): Use them.  Remove the search through
1056         the minimal symbols.
1057
1058 2008-09-13  Joel Brobecker  <brobecker@adacore.com>
1059
1060         * dwarf2read.c (add_partial_subprogram): New procedure.
1061         (scan_partial_symbols): Use it.
1062         (load_partial_dies): Read in children of subprogram and lexical
1063         blocks for Ada compilation units.
1064
1065 2008-09-13  Tom Tromey  <tromey@redhat.com>
1066
1067         * symfile.c (build_id_verify): Free 'found'.
1068         (find_separate_debug_file): Use xfree, not free.
1069
1070 2008-09-12  Doug Evans  <dje@google.com>
1071
1072         * corefile.c (write_memory): Remove unnecessary copying.
1073
1074         * sol-thread.c (_initialize_sol_thread): Add FIXME regarding
1075         order of _initialize_* fns.
1076
1077         * dwarf2read.c (comp_unit_head): Rename first_die_ptr to
1078         first_die_offset.  All uses updated.
1079         Delete unused members cu_head_ptr, next.
1080         Move members base_known, base_address to ...
1081         (dwarf2_cu) ... here.  All uses updated.
1082
1083 2008-09-12  Pedro Alves  <pedro@codesourcery.com>
1084
1085         * Makefile.in (generated_files): Add $(NAT_GENERATED_FILES).
1086         * config/i386/i386gnu.mh (NAT_GENERATED_FILES): New.
1087
1088 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1089
1090         * fork-child.c (startup_inferior): Use target_wait and target_resume
1091         directly instead of calling wait_for_inferior / resume.
1092
1093         * infcmd.c (kill_if_already_running): Do not call no_shared_libraries
1094         or init_wait_for_inferior.
1095         (run_command_1): Call init_wait_for_inferior.
1096
1097 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1098
1099         * gdbtypes.h (builtin_type_void_data_ptr, builtin_type_void_func_ptr,
1100         builtin_type_CORE_ADDR, builtin_type_char, builtin_type_short,
1101         builtin_type_int, builtin_type_long, builtin_type_signed_char,
1102         builtin_type_unsigned_char, builtin_type_unsigned_short,
1103         builtin_type_unsigned_int, builtin_type_unsigned_long,
1104         builtin_type_float, builtin_type_double, builtin_type_long_double,
1105         builtin_type_complex, builtin_type_double_complex, builtin_type_string,
1106         builtin_type_bool, builtin_type_long_long,
1107         builtin_type_unsigned_long_long): Remove macros.
1108
1109         (builtin_type_f_character, builtin_type_f_integer,
1110         builtin_type_f_integer_s2, builtin_type_f_logical,
1111         builtin_type_f_logical_s1, builtin_type_f_logical_s2,
1112         builtin_type_f_real, builtin_type_f_real_s8, builtin_type_f_real_s16,
1113         builtin_type_f_complex_s8, builtin_type_f_complex_s16,
1114         builtin_type_f_complex_s32): Likewise.
1115
1116         (builtin_type_m2_char, builtin_type_m2_int, builtin_type_m2_card,
1117         builtin_type_m2_real, builtin_type_m2_bool): Likewise.
1118
1119         (struct builtin_f_type, builtin_f_type): Move to f-lang.h.
1120         (struct builtin_m2_type, builtin_m2_type): Move to m2-lang.h.
1121
1122         * f-lang.h (struct builtin_f_type, builtin_f_type): Move here.
1123         * m2-lang.h (struct builtin_m2_type, builtin_m2_type): Move here.
1124
1125 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1126
1127         * solib-svr4.c (LM_ADDR_FROM_LINK_MAP): Use builtin types of
1128         target_gdbarch instead of builtin_type_void_data_ptr.
1129         (LM_DYNAMIC_FROM_LINK_MAP, LM_NEXT, LM_NAME,
1130         IGNORE_FIRST_LINK_MAP_ENTRY, scan_dyntag, elf_locate_base,
1131         solib_svr4_r_map, solib_svr4_r_brk, solib_svr4_r_ldsomap,
1132         open_symbol_file_object): Likewise.
1133         * nto-tdep.c (LM_ADDR): Likewise.
1134
1135 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1136
1137         * bsd-uthread.c (bsd_uthread_read_memory_address): New function.
1138         (bsd_uthread_fetch_registers, bsd_uthread_store_registers,
1139         bsd_uthread_wait, bsd_uthread_find_new_threads): Use it.
1140
1141 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1142
1143         * procfs.c (procfs_address_to_host_pointer): Use target_gdbarch
1144         and its associated types to perform pointer conversion.
1145         (procfs_can_use_hw_breakpoint): Likewise.
1146         (procfs_auxv_parse): Remove unused variable.
1147
1148 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1149
1150         * auxv.c (default_auxv_parse): Use gdbarch_ptr_bit (target_gdbarch)
1151         instead of builtin_type_void_data_ptr.
1152         * target.c (default_region_ok_for_hw_watchpoint): Likewise.
1153
1154 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1155
1156         * expprint.c (print_subexp_standard): Compare against builtin type
1157         associated with exp->gdbarch instead of builtin_type_char.
1158
1159         * f-valprint.c (f_val_print): Use extract_unsigned_integer to
1160         extract values of arbitrary logical type.  Handle arbitrary
1161         complex types.
1162
1163         * printcmd.c (float_type_from_length): New function.
1164         (print_scalar_formatted, printf_command): Use it.
1165
1166 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1167
1168         * valops.c: Include "objfiles.h" and "symtab.h".
1169         (find_function_in_inferior): New argument OBJF_P.  Use it to return
1170         objfile where function is defined.  Use per-objfile arch types
1171         instead of builtin_type_ to define default return type.
1172
1173         * linux-fork.c (checkpoint_command): Update calls.  Use per-objfile
1174         architecture to define inferior call argument types.
1175         * gcore.c (derive_heap_segment): Likewise.
1176         * objc-lang.c (value_nsstring): Likewise.
1177         * scm-lang.c (scm_lookup_name): Likewise.
1178         * scm-valprint.c (scm_inferior_print): Likewise.
1179         * valops.c (value_allocate_space_in_inferior): Likewise.
1180
1181         * eval.c (evaluate_subexp_standard): Update calls.
1182         * objc-lang.c (lookup_objc_class, print_object_command): Likewise.
1183
1184         * linux-fork.c: Include "objfiles.h".
1185         * scm-lang.c: Include "objfiles.h".
1186         * scm-valprint.c: Include "objfiles.h".
1187
1188 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1189
1190         * gdbarch.sh (name_of_malloc): Remove.
1191         * gdbarch.c, gdbarch.h: Re-generate.
1192         * valops.c (value_allocate_space_in_inferior): Do not call
1193         gdbarch_name_of_malloc.
1194
1195 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1196
1197         * valarith.c (value_x_unop): Use builtin_type_int8 as type for
1198         UNOP_POSTINCREMENT/UNOP_POSTDECREMENT constant 0 argument.
1199         (value_bit_index): Use extract_unsigned_integer
1200         instead of unpack_long to read single byte.
1201
1202 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1203
1204         * infcall.c (value_arg_coerce): Add GDBARCH parameter.  Use its
1205         associates types instead of builtin_type_ macros.
1206         (find_function_addr): Leave output VALUE_TYPE NULL if unknown.
1207         (call_function_by_hand): Use per-architecture "int" type as
1208         fall-back if find_function_addr returns NULL VALUE_TYPE.
1209         Update call to value_arg_coerce.
1210
1211 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1212
1213         * cp-abi.h (cplus_method_ptr_size): Add TO_TYPE parameter.
1214         (cplus_make_method_ptr): Add TYPE parameter.
1215         * cp-abi.c (cplus_method_ptr_size): Add TO_TYPE parameter.  Pass it
1216         on to current_cp_abi.method_ptr_size callback.
1217         (cplus_make_method_ptr): Add TYPE parameter.  Pass it on to
1218         current_cp_abi.make_method_ptr callback.
1219
1220         * gdbtypes.c (lookup_methodptr_type): Pass target type
1221         argument to cplus_method_ptr_size.
1222         * valops.c (value_cast): Pass type argument to cplus_make_method_ptr.
1223         (value_struct_elt_for_reference): Likewise.
1224
1225         * gnu-v3-abi.c (get_class_arch): New function.
1226         (vtable_address_point_offset): Add GDBARCH parameter.  Use it
1227         instead of current_gdbarch.  Update all callers.
1228         (gnuv3_get_vtable): Likewise.
1229         (gnuv3_get_virtual_fn): Likewise.
1230         (gnuv3_decode_method_ptr): Likewise.
1231         (gnuv3_rtti_type): Call get_class_arch to determine architecture.
1232         Use it instead of current_gdbarch.
1233         (gnuv3_virtual_fn_field): Likewise.
1234         (gnuv3_baseclass_offset): Likewise.
1235         (gnuv3_print_method_ptr): Likewise.
1236         (gnuv3_method_ptr_to_value): Likewise.
1237         (gnuv3_method_ptr_size): Add TYPE parameter.  Use it to determine
1238         class architecture.  Use architecture types instead of builtin types.
1239         (gnuv3_make_method_ptr): Likewise.
1240
1241         * cp-valprint.c (cp_print_class_member): Expect pointer type
1242         instead of class type.  Use its length when extracting value.
1243         * c-valprint.c (c_val_print): Update call to cp_print_class_member.
1244
1245 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1246
1247         * stack.c (return_command): Use frame architecture to determine
1248         default integer return type.
1249
1250         * f-valprint.c (f77_get_dynamic_lowerbound): Use frame architecture
1251         to determine pointer types.
1252         (f77_get_dynamic_upperbound): Likewise.
1253
1254         * objc-lang.c (OBJC_FETCH_POINTER_ARGUMENT): Remove.
1255         (resolve_msgsend): Use architecture of current frame to determine
1256         pointer types.  Inline OBJC_FETCH_POINTER_ARGUMENT.
1257         (resolve_msgsend_stret, resolve_msgsend_super,
1258         resolve_msgsend_super_stret): Likewise.
1259
1260 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1261
1262         * alpha-tdep.c (alpha_register_type): Use builtin_type (gdbarch)
1263         instead of builtin_type_ macros.
1264         * amd64-tdep.c (amd64_register_type): Likewise.
1265         (amd64_get_longjmp_target): Likewise.
1266         * arm-tdep.c (arm_register_type): Likewise.
1267         * avr-tdep.c (avr_register_type): Likewise.
1268         * cris-tdep.c (cris_register_type, crisv32_register_type): Likewise.
1269         * frv-tdep.c (frv_register_type): Likewise.
1270         * h8300-tdep.c (h8300_register_type): Likewise.
1271         * hppa-tdep.c (hppa32_convert_from_func_ptr_addr, 
1272         hppa_skip_trampoline_code): Likewise.
1273         * i386-tdep.c (i386_register_type): Likewise.
1274         (i386_unwind_pc, i386_sse_type): Likewise.
1275         * ia64-tdep.c (ia64_register_type): Likewise.
1276         * m32r-tdep.c (m32r_register_type): Likewise.
1277         * m68k-tdep.c (m68k_register_type, m68k_unwind_pc): Likewise.
1278         * m88k-tdep.c (m88k_register_type): Likewise.
1279         * mep-tdep.c (mep_register_type): Likewise.
1280         * mips-tdep.c (mips_pseudo_register_type): Likewise.
1281         * mn10300-tdep.c (mn10300_register_type): Likewise.
1282         * mt-tdep.c (mt_copro_register_type): Likewise.
1283         * rs6000-tdep.c (rs6000_builtin_type_vec64): Likewise.
1284         (rs6000_convert_register_p, rs6000_register_to_value,
1285         rs6000_value_to_register): Likewise.
1286         * s390-tdep.c (s390_register_type): Likewise.
1287         * sh64-tdep.c (sh64_register_type): Likewise.
1288         (sh64_build_float_register_type, sh64_do_fp_register): Likewise.
1289         * sh-tdep.c (sh_sh2a_register_type, sh_sh3e_register_type,
1290         sh_sh4_build_float_register_type, sh_sh4_register_type,
1291         sh_default_register_type): Likewise.
1292         * sparc64-tdep.c (sparc64_register_type): Likewise.
1293         * sparc-tdep.c (sparc32_register_type): Likewise.
1294         * spu-tdep.c (spu_builtin_type_vec128, spu_register_type): Likewise.
1295         * v850-tdep.c (v850_register_type): Likewise.
1296         * vax-tdep.c (vax_register_type): Likewise.
1297         * xtensa-tdep.c (xtensa_register_type, xtensa_unwind_pc,
1298         xtensa_push_dummy_call): Likewise.
1299
1300         * std-regs.c (value_of_builtin_frame_fp_reg,
1301         value_of_builtin_frame_pc_reg): Likewise.
1302         * target-descriptions.c (tdesc_register_type): Likewise.
1303
1304 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1305
1306         * ada-lang.c (ada_coerce_to_simple_array_type): Use builtin_type_int32
1307         instead of builtin_type_int as default unspecified integral type.
1308         (ada_index_type, ada_array_bound_from_type, ada_variant_discrim_type,
1309         assign_component, to_fixed_range_type): Likewise.
1310         * ada-typeprint.c (print_range, print_range_bound,
1311         print_range_type_named): Likewise.
1312         * ada-valprint.c (print_optional_low_bound, ada_val_print_1): Likewise.
1313         * eval.c (evaluate_subexp_standard): Likewise.
1314         * gnu-v2-abi.c (gnuv2_virtual_fn_field): Likewise.
1315         * gnu-v3-abi.c (gnuv3_get_virtual_fn, gnuv3_baseclass_offset,
1316         build_gdb_vtable_type): Likewise.
1317         * jv-lang.c (java_array_type): Likewise.
1318         * m2-typeprint.c (m2_print_bounds, m2_is_long_set_of_type): Likewise.
1319         * m2-valprint.c (m2_print_long_set): Likewise.
1320         * parse.c (follow_types): Likewise.
1321         * p-typeprint.c (pascal_type_print_base): Likewise.
1322         * valops.c (value_one, value_array, value_string,
1323         value_bitstring): Likewise.
1324         * value.c (allocate_repeat_value, value_from_string): Likewise.
1325         * varobj.c (c_describe_child): Likewise.
1326         * mt-tdep.c (mt_register_type): Likewise.
1327         * sh-tdep.c (sh_sh4_build_float_register_type): Likewise.
1328         * sh64-tdep.c (sh64_build_float_register_type): Likewise.
1329
1330 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1331
1332         * defs.h (struct gdbarch): Add forward declaration.
1333         (set_next_address): Add GDBARCH argument.
1334         * printcmd.c (set_next_address): Use it to find pointer type.
1335         * breakpoint.c (breakpoint_1): Update call.
1336         * source.c (line_info): Likewise.
1337         * findcmd.c (find_command): Use current_gdbarch to find pointer type.
1338
1339         * breakpoint.c (set_breakpoint_count): Use platform-neutral
1340         types for internal variable values.
1341         * infrun.c (handle_inferior_event): Likewise.
1342         * source.c (forward_search_command, reverse_search_command): Likewise.
1343         * tracepoint.c (set_tracepoint_count, set_traceframe_num,
1344         set_tracepoint_num, set_traceframe_context): Likewise.
1345
1346 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1347
1348         * gdbtypes.h (struct builtin_type): Remove builtin_true_char
1349         and builtin_true_unsigned_char.
1350         (builtin_type_true_char): Remove macro, add extern declaration.
1351         (builtin_type_true_unsigned_char): Add extern declaration.
1352         * gdbtypes.c (builtin_type_true_char): New global variable.
1353         (builtin_type_true_unsigned_char): Likewise.
1354         (_initialize_gdbtypes): Initialize them.
1355         (gdbtypes_post_init): Do not initialize builtin_true_char
1356         and builtin_true_unsigned_char members of struct builtin_type.
1357
1358         * printcmd.c (print_scalar_formatted): Do not use builtin_type;
1359         use builtin_type_true_unsigned_char instead.
1360
1361         * ada-valprint.c (ada_val_print_1): Use builtin_type_true_char
1362         instead of builtin_type_char for internal string.
1363
1364 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1365
1366         * gdbtypes.h (builtin_type_void): Remove macro, add declaration.
1367         (builtin_type_f_void): Remove macro.
1368         * gdbtypes.c (builtin_type_void): New global variable.
1369         (_initialize_gdbtypes): Initialize it.
1370
1371         * gnu-v3-abi.c (build_gdb_vtable_type): Do not call
1372         lookup_pointer_type or lookup_function_type on builtin_type_void.
1373         * printcmd.c (set_next_address): Likewise.
1374         * objc-lang.c (value_nsstring): Likewise.
1375         * mt-tdep.c (mt_copro_register_type): Likewise.
1376         * xtensa-tdep.c (xtensa_register_type): Likewise.
1377
1378         * symfile.c (syms_from_objfile): Remove special handling
1379         of builtin_type_void and builtin_type_char.
1380
1381 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1382
1383         * eval.c (evaluate_subexp_standard): Use exp->gdbarch types instead
1384         of builtin_type_ macros when handling OP_OBJC_ operations.
1385         * objc-lang.c (print_object_command): Likewise.
1386
1387 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1388
1389         * ada-valprint.c: Include "objfiles.h".
1390         (ada_val_print_1): Use the gdbarch associated with the objfile whether
1391         a System.Address type is defined to retrieve the proper pointer type
1392         to use to print it.
1393
1394 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1395
1396         * ada-lang.c (value_pos_atr): Add TYPE argument.  Use it as
1397         result type instead of builtin_type_int.
1398         (value_subscript_packed): Use pos_atr instead of value_pos_atr.
1399         (ada_value_subscript): Update call to value_pos_atr.
1400         (ada_value_ptr_subscript): Likewise.
1401         (ada_evaluate_subexp): Likewise.
1402
1403 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1404
1405         * ada-lang.c (cast_to_fixed): Do not cast to builtin_type_double.
1406         (cast_from_fixed_to_double): Rename to ...
1407         (cast_from_fixed): ... this.  Add TYPE parameter.  Use it instead
1408         of builtin_type_double.
1409         (ada_value_cast): Use cast_from_fixed instead of casting result
1410         of cast_from_fixed_to_double.
1411         (ada_evaluate_subexp): Update calls to cast_from_fixed_to_double. 
1412
1413 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1414
1415         * valops.c (value_ind): No longer allow dereferencing an
1416         integer type.
1417         * eval.c (evaluate_subexp_standard): Handle deferencing an
1418         integer type here.
1419         * ada-lang.c (ada_evaluate_subexp): Likewise.
1420
1421 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1422
1423         * ada-valprint.c (ada_val_print_1): When implicitly dereferencing
1424         a reference type, pass the reference type directly to unpack_pointer.
1425         * c-valprint.c (c_val_print): Likewise.
1426         * f-valprint.c (f_val_print): Likewise.
1427         * m2-valprint.c (print_variable_at_address, m2_val_print): Likewise.
1428         * p-valprint.c (pascal_val_print): Likewise.
1429
1430 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1431
1432         * eval.c (evaluate_subexp_standard): Use builtin_type_int8
1433         to construct the EVAL_SKIP dummy return value.
1434         * ada-lang.c (ada_evaluate_subexp): Likewise.
1435         * jv-lang.c (evaluate_subexp_java): Likewise.
1436         * m2-lang.c (evaluate_subexp_modula2): Likewise.
1437         * scm-lang.c (evaluate_exp): Likewise.
1438
1439 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1440
1441         * value.h (coerce_enum, coerce_number): Remove prototypes.
1442         * value.c (coerce_enum, coerce_number): Remove.
1443         * valarith.c (value_x_binop): Do not call coerce_enum.
1444         (value_x_unop): Likewise.
1445         (value_logical_not): Call coerce_array instead of coerce_number.
1446
1447 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1448
1449         * ax-gdb.c: Include "language.h".
1450         (gen_frame_args_address): Add GDBARCH parameter; use it
1451         instead of current_gdbarch.
1452         (gen_frame_locals_address): Likewise.
1453         (gen_var_ref): Add GDBARCH parameter.  Update calls to
1454         gen_frame_args_address and gen_frame_locals_address.  Use
1455         pointer type from gdbarch.
1456         (gen_usual_unary): Add EXP parameter.  Use integer type
1457         from exp->gdbarch.
1458         (gen_usual_arithmetic): Likewise.
1459         (gen_integral_promotions): Likewise.
1460         (gen_add, gen_sub): Remove.
1461         (gen_ptradd, gen_ptrsub, gen_ptrdiff): New functions.
1462         (gen_logical_not): Use passed-in boolean result type
1463         instead of builtin_type_int.
1464         (gen_complement): Do not call gen_usual_unary or
1465         gen_integral_promotions.
1466         (gen_struct_ref): Call require_rvalue instead of gen_usual_unary.
1467         (gen_repeat): Add EXP parameter.  Update call to gen_expr.
1468         Use builtin_type_int32 as internal range type.
1469         (gen_sizeof): Add EXP and SIZE_TYPE parameters.  Use SIZE_TYPE
1470         as result type.  Update call to gen_expr.
1471         (gen_expr): Add EXP parameter.  Update calls to gen_expr,
1472         gen_repeat, gen_var_ref, gen_usual_unary, gen_usual_arithmetic,
1473         and gen_integral_promotions.  Call gen_ptradd, gen_ptrsub,
1474         gen_ptrdiff, or gen_binop instead of gen_add or gen_sub.
1475         Use exp->gdbarch instead of current_gdbarch.
1476         Call language_bool_type to determine result type of UNOP_LOGICAL_NOT.
1477
1478 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1479
1480         * eval.c (evaluate_subexp_standard): Add calls to binop_promote
1481         and unop_promote before calling value_binop et. al.
1482         * ada-lang.c (ada_evaluate_subexp): Add calls to binop_promote
1483         and unop_promote before calling value_binop et. al.
1484
1485         * valarith.c (value_binop): Do not call binop_promote or unop_promote.
1486         (value_pos): Do not call unop_promote.
1487         (value_neg, value_complement): Likewise.
1488
1489 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1490
1491         * value.h (unop_promote, binop_promote): Add prototypes.
1492         * eval.c (unop_promote, binop_promote): New functions.
1493         * valarith.c (unop_result_type, binop_result_type): Remove.
1494         (value_binop): Call binop_promote or unop_promote.
1495         Inline remaining parts of binop_result_type.  Remove special
1496         code to truncate integer values for unsigned operations.
1497         (value_pos): Call unop_promote.  Inline remaining parts of
1498         unop_result_type.
1499         (value_neg, value_complement): Likewise.
1500
1501 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1502
1503         * value.h (value_add, value_sub): Remove.
1504         (value_ptradd, value_ptrsub, value_ptrdiff): Add prototypes.
1505         * valarith.c (value_add, value_sub): Remove.
1506         (value_ptradd, value_ptrsub, value_ptrdiff): New functions.
1507         (find_size_for_pointer_math): Add assertion.  Update comment.
1508         (value_binop): Update comment.
1509
1510         * eval.c (ptrmath_type_p): New function.
1511         (evaluate_subexp_standard): Replace value_add and value_sub
1512         by value_ptradd, value_ptrsub, value_ptrdiff or value_binop.
1513         Use builtin_type_uint8 instead of builtin_type_char to hold
1514         the increment for BINOP_{PRE,POST}{IN,DE}CREMENT operations.
1515         * valarith.c (value_subscript): Replace value_add by
1516         value_ptradd.  Replace value_sub by value_binop.
1517         * ada-lang.c (ada_value_ptr_subscript): Likewise.
1518         (ada_tag_name_2): Replace value_add by value_ptradd.
1519         (ada_evaluate_subexp): Replace value_add and value_sub by
1520         value_binop.
1521         * m2-lang.c (evaluate_subexp_modula2): Replace value_add
1522         by value_ptradd.
1523         * gnu-v2-abi.c (gnuv2_virtual_fn_field): Likewise.
1524         * gnu-v3-abi.c (gnuv3_method_ptr_to_value): Likewise.
1525
1526 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1527
1528         * eval.c (evaluate_subexp_for_sizeof): Use builtin_int type of
1529         the expression architecture instead of builtin_type_int as the
1530         sizeof return type.
1531
1532 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1533
1534         * expression.h (enum exp_opcode): Document OP_COMPLEX to take
1535         a type parameter as expression element.
1536         * eval.c (evaluate_subexp_standard) [OP_COMPLEX]: Retrieve result
1537         type as expression element.
1538         * f-exp.y: Pass in type when buildin OP_COMPLEX expression.
1539         * parse.c (operator_length_standard): Update length of OP_COMPLEX.
1540
1541 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1542
1543         * language.h (struct language_arch_info): New members
1544         bool_type_default and bool_type_symbol.
1545         (lang_bool_type): Remove prototype.
1546         (LA_BOOL_TYPE): Remove macro.
1547         (language_bool_type): Add prototype.
1548         * language.c (lang_bool_type): Remove.
1549         (language_bool_type): New function.
1550
1551         * value.h (value_in): Change return value to int.
1552         * value.c (value_in): Return int instead of struct value *.
1553
1554         * eval.c (evaluate_subexp_standard): Call language_bool_type instead
1555         of using LA_BOOL_TYPE.  Update call to value_in.
1556         * ada-lang.c (ada_evaluate_subexp): Call language_bool_type instead
1557         of using LA_BOOL_TYPE or builtin_type_int for boolean values.
1558
1559         * language.c (unknown_language_arch_info): Set bool_type_default member
1560         of struct language_arch_info.
1561         * ada-lang.c (ada_language_arch_info): Set bool_type_symbol and
1562         bool_type_default members of struct language_arch_info.
1563         * c-lang.c (c_language_arch_info): Set bool_type_default member
1564         of struct language_arch_info.
1565         (cplus_language_arch_info): Set bool_type_symbol and bool_type_default
1566         members of struct language_arch_info.
1567         * f-lang.c (f_language_arch_info): Set bool_type_symbol and
1568         bool_type_default members of struct language_arch_info.
1569         * jv-lang.c (java_language_arch_info): Set bool_type_symbol and
1570         bool_type_default members of struct language_arch_info.
1571         * m2-lang.c (m2_language_arch_info): Set bool_type_symbol and
1572         bool_type_default members of struct language_arch_info.
1573         * p-lang.c (p_language_arch_info): Set bool_type_symbol and
1574         bool_type_default members of struct language_arch_info.
1575
1576 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1577
1578         * jv-lang.c (enum java_primitive_types): New type.
1579         (java_language_arch_info): New function.
1580         (java_language): Use it instead of c_language_arch_info.
1581
1582 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1583
1584         * value.h (value_bitstring_subscript): New prototype.
1585         * valarith.h (value_bitstring_subscript): New function.
1586         (value_subscript): No longer handle TYPE_CODE_BITSTRING.
1587         * eval.c (evaluate_subexp_standard): Call value_bitstring_subscript
1588         instead of value_subscript to handle TYPE_CODE_BITSTRING.
1589
1590 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1591
1592         * expression.h (struct expression): New member GDBARCH.
1593         * parse.c (parse_exp_in_context): Initialize it.
1594         * parser-def.h (parse_gdbarch, parse_language): New macros.
1595
1596         * ada-exp.y (parse_type): New macro.
1597         Replace builtin_type_ macros by using parse_type.
1598         Replace current_language by parse_language.
1599         * ada-lex.l (processInt): Replace current_gdbarch by parse_gdbarch.
1600         Replace builtin_type_ macros.
1601
1602         * c-exp.y (parse_type): New macro.
1603         Replace builtin_type_ macros by using parse_type.
1604         (parse_number): Replace current_gdbarch by parse_gdbarch.
1605         (yylex): Replace current_language by parse_language.
1606
1607         * f-exp.y (parse_type, parse_f_type): New macros.
1608         Replace builtin_type_ macros by using parse_{f_,}type.
1609         (parse_number): Replace current_gdbarch by parse_gdbarch.
1610         (yylex): Replace current_language by parse_language.
1611
1612         * jv-exp.y (parse_type): New macro.
1613         (parse_number): Replace builtin_type_ macros by using parse_type.
1614
1615         * m2-exp.y (parse_type, parse_m2_type): New macros.
1616         Replace builtin_type_ macros by using parse_{m2_,}type.
1617
1618         * objc-exp.y (parse_type): New macro.
1619         Replace builtin_type_ macros by using parse_type.
1620         (parse_number): Replace current_gdbarch by parse_gdbarch.
1621         (yylex): Replace current_language by parse_language.
1622
1623         * p-exp.y (parse_type): New macro.
1624         Replace builtin_type_ macros by using parse_type.
1625         (parse_number): Replace current_gdbarch by parse_gdbarch.
1626         (yylex): Replace current_language by parse_language.
1627
1628 2008-09-11  Ulrich Weigand  <uweigand@de.ibm.com>
1629
1630         * parser-defs.h (write_exp_msymbol): Remove TEXT_SYMBOL_TYPE
1631         and DATA_SYMBOL_TYPE arguments.
1632         * parse.c (write_exp_msymbol): Remove TEXT_SYMBOL_TYPE and
1633         DATA_SYMBOL_TYPE arguments.  Replace use of builtin_type_CORE_ADDR.
1634         (write_dollar_variable): Update call.
1635
1636         * ada-exp.y (write_var_or_type): Update call.
1637         * c-exp.y: Likewise.
1638         * f-exp.y: Likewise.
1639         * jv-exp.y: Likewise.
1640         * m2-exp.y: Likewise.
1641         * objc-exp.y: Likewise.
1642         * p-exp.y: Likewise.
1643
1644 2008-09-10  Joel Brobecker  <brobecker@adacore.com>
1645
1646         * ada-lang.c (ada_parent_type): Add handling of the case where
1647         the _parent field is a pointer and/or has a parallel XVS type.
1648         (ada_evaluate_subexp) [OP_VAR_VALUE]: When doing an
1649         EVAL_AVOID_SIDE_EFFECTS evaluation of a tagged type, return
1650         the type of the tag instead of doing forcing an EVAL_NORMAL
1651         expression evaluation.
1652
1653 2008-09-10  Paul N. Hilfinger  <hilfinger@adacore.com> 
1654             Joel Brobecker  <brobecker@adacore.com>
1655
1656         * ada-lang.c (is_digits_suffix): New function.
1657         (is_dot_digits_suffix): Remove.
1658         (ada_lookup_symbol_list): Remove digits suffix from minimal symbols
1659         before looking up in symbol table, and do not use wild matches on them.
1660         (wild_match): Reimplement for speed and to allow matching of operator
1661         symbols.
1662         (is_valid_name_for_wild_match): Return zero for names that do not
1663         follow the GNAT encoding.
1664
1665         (is_name_suffix): Fix typo in comment.
1666         (to_record_with_fixed_variant_part): Ditto.
1667
1668 2008-09-10  Pedro Alves  <pedro@codesourcery.com>
1669
1670         * Makefile.in (gnu-nat.o): New rule.
1671
1672 2008-09-10  Joel Brobecker  <brobecker@adacore.com>
1673
1674         * ada-lang.c (ada_evaluate_subexp) [OP_ATR_SIZE]: Use
1675         archecture-neutral builtin_type_int32 instead of builtin_type_int.
1676
1677 2008-09-10  Joel Brobecker  <brobecker@adacore.com>
1678
1679         * ada-lang.c (ada_evaluate_subexp) [BINOP_ADD, BINOP_SUB]:
1680         Add special handling for pointer types.
1681
1682 2008-09-10  Pedro Alves  <pedro@codesourcery.com>
1683
1684         * inf-ttrace.c (inf_ttrace_follow_fork): Declare locals at the
1685         right scope level.
1686         (inf_ttrace_resume, inf_ttrace_wait): Typos.
1687
1688 2008-09-10  Ulrich Weigand  <uweigand@de.ibm.com>
1689
1690         * ada-lang.c (ada_array_length): Use builtin_type_int32 instead
1691         of builtin_type_int.
1692         (ada_evaluate_subexp) [UNOP_IN_RANGE]: Use operand range type
1693         instead of builtin_type_int.
1694
1695 2008-09-09  Pedro Alves  <pedro@codesourcery.com>
1696
1697         * infrun.c (normal_stop): Run hook-stop last.
1698
1699 2008-09-09  Pedro Alves  <pedro@codesourcery.com>
1700
1701         * gnu-nat.c (gnu_pid_to_exec_file): Delete.
1702         (init_gnu_ops): Don't register it.
1703
1704 2008-09-09  Pedro Alves  <pedro@codesourcery.com>
1705
1706         * gnu-nat.c (gnu_attach): Push target before fetching the list of
1707         threads.
1708
1709 2008-09-08  Daniel Jacobowitz  <dan@codesourcery.com>
1710
1711         * valops.c (value_cast_structs): Return NULL for failure.
1712         (value_cast): Handle NULL from value_cast_structs.
1713         (value_fetch_lazy): Call check_typedef.  Remove unused variable.
1714
1715 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
1716
1717         * inferior.h (context_switch_to): Delete.
1718         * infrun.c (context_switch): Don't save and load infrun state.
1719         (context_switch_to): Delete.
1720
1721         * infcmd.c (proceed_thread_callback): Replace context_switch_to
1722         calls by switch_to_thread calls.
1723
1724         * gdbthread.h (save_infrun_state, load_infrun_state): Delete.
1725         * thread.c (main_thread_state, main_thread_executing): Delete.
1726         (inferior_thread): Delete references to them.
1727         (add_thread_silent): Fix case where we're adding a thread with the
1728         same ptid as an exited thread.  Remove references to
1729         context-switching.
1730         (load_infrun_state, save_infrun_state): Delete.
1731         (thread_alive, is_thread_state, any_running, is_executing)
1732         (set_executing): Remove the special handling for targets that
1733         don't register any thread.
1734         (restore_current_thread, thread_apply_all_command)
1735         (do_captured_thread_select): Unconditionally call
1736         switch_to_thread.
1737
1738         * mi/mi-main.c (mi_cmd_execute): Check for exited threads.
1739         Call switch_to_thread instead of context_switch_to.
1740
1741 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
1742
1743         Remove global continuations in favour of a per-thread
1744         continuations.
1745
1746         * gdbthread.h (struct thread_info): Add comments around
1747         continuations and intermediate_continuations.
1748         (save_infrun_state, load_infrun_state): Delete continuations and
1749         intermediate_continuations arguments.
1750         * infrun.c (context_switch): Don't context-switch the continuations.
1751         * thread.c (clear_thread_inferior_resources): Discard all
1752         continuations of the thread we're clearing.
1753         (save_infrun_state, load_infrun_state): Delete continuations and
1754         intermediate_continuations arguments, and the code referencing
1755         them.
1756         * utils.c: Include "gdbthread.h".
1757         (cmd_continuation, intermediate_continuation): Delete.
1758         (add_continuation): Add thread_info* argument.  Install the
1759         continuation on it.
1760         (restore_thread_cleanup): New.
1761         (do_all_continuations_ptid, do_all_continuations_thread_callback):
1762         New.
1763         (do_all_continuations): Reimplement.
1764         (discard_all_continuations_thread_callback,
1765         discard_all_continuations_thread): New.
1766         (discard_all_continuations): Reimplement.
1767         (add_intermediate_continuation): Add thread_info* argument.
1768         Install the continuation on it.
1769         (do_all_intermediate_continuations_thread_callback)
1770         (do_all_intermediate_continuations_thread): New.
1771         (do_all_intermediate_continuations): Reimplement.
1772         (discard_all_intermediate_continuations_thread_callback): New.
1773         (discard_all_intermediate_continuations_thread): New.
1774         (discard_all_intermediate_continuations): Reimplement.
1775
1776         * breakpoint.c (until_break_command): Install the continuation on
1777         the current thread.
1778
1779         * defs.h (cmd_continuation, intermediate_continuation): Delete.
1780         (struct thread_info): Forward declare.
1781         (add_continuation, add_intermediate_continuation): Add
1782         thread_info* argument.
1783         (do_all_continuations_thread, discard_all_continuations_thread)
1784         (do_all_intermediate_continuations_thread)
1785         (discard_all_intermediate_continuations_thread): Declare.
1786         * inf-loop.c (inferior_event_handler): In non-stop only run
1787         continuations on the thread that stopped.  In all-stop, run
1788         continuations on all threads.
1789         * infcmd.c (step_once, finish_command): Adjust.
1790
1791 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
1792
1793         Remove the global stop_step in favour of a per-thread
1794         stop_step.
1795
1796         * inferior.h (stop_step): Delete.
1797
1798         * gdbthread.h (struct thread_info): Add comments to stop_step.
1799         (save_infrun_state, load_infrun_state): Remove stop_step argument.
1800         * thread.c (load_infrun_state, save_infrun_state): Remove
1801         stop_step argument, and references to it.
1802
1803         * infrun.c (clear_proceed_status): Clear stop_step.
1804         (fetch_inferior_event): Adjust.
1805         (context_switch): Don't context-switch stop_step.
1806         (handle_inferior_event): Adjust.
1807         (normal_stop): Adjust.
1808         (save_inferior_status, restore_inferior_status): Adjust.
1809
1810         * infcmd.c (stop_step): Delete.
1811         (step_1, step_1_continuation, step_once, until_next_command):
1812         Adjust.
1813
1814 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
1815
1816         Remove the global step_multi in favour of a per-thread
1817         step_multi.
1818
1819         * inferior.h (step_multi): Delete.
1820         * gdbthread.h (struct thread_info): Add comments around
1821         step_multi.
1822         (save_infrun_state, load_infrun_state): Remove step_multi
1823         parameter.
1824         * thread.c (load_infrun_state, save_infrun_state): Remove
1825         step_multi argument, and references to it.
1826         * infcmd.c (step_multi): Delete.
1827         (step_1): Adjust.
1828         (step_1_continuation, until_next_command): Adjust.
1829         * infrun.c (fetch_inferior_event): Adjust.
1830         (context_switch): Don't context-switch step_multi.
1831         (print_stop_reason, normal_stop): Adjust.
1832
1833 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
1834
1835         Remove the global stop_signal in favour of a per-thread
1836         stop_signal.
1837
1838         * inferior.h (stop_signal): Delete.
1839         * gdbthread.h (save_infrun_state, load_infrun_state): Remove
1840         stop_signal argument.
1841         * thread.c (load_infrun_state, save_infrun_state): Remove
1842         stop_signal argument.  Don't reference it.
1843
1844         * infcmd.c (stop_signal): Delete.
1845         (program_info): Adjust.
1846         * infrun.c (resume): Clear stop_signal.
1847         (proceed): Adjust.  Pass the last stop_signal to the thread we're
1848         resuming.
1849         (context_switch): Don't context-switch stop_signal.
1850         (handle_inferior_event, keep_going): Adjust.
1851         (save_inferior_status, restore_inferior_status): Adjust.
1852
1853         * fbsd-nat.c: Include "gdbthread.h".
1854         (find_signalled_thread, find_stop_signal): New.
1855         (fbsd_make_corefile_notes): Use it.
1856         * fork-child.c (startup_inferior): Adjust.
1857
1858         * linux-nat.c (get_pending_status): Adjust.
1859         (linux_nat_do_thread_registers): Adjust.
1860         (find_signalled_thread, find_stop_signal): New.
1861         (linux_nat_do_thread_registers): Add stop_signal parameter.
1862         (struct linux_nat_corefile_thread_data): Add stop_signal member.
1863         (linux_nat_corefile_thread_callback): Pass stop_signal.
1864         (linux_nat_do_registers): Delete.
1865         (linux_nat_make_corefile_notes): Use find_stop_signal.  Assume
1866         there's always a thread.
1867
1868         * procfs.c (find_signalled_thread, find_stop_signal): New.
1869         (find_stop_signal): New.
1870         (procfs_do_thread_registers): Add stop_signal parameter.
1871         (struct procfs_corefile_thread_data): Add stop_signal member.
1872         (procfs_corefile_thread_callback): Pass args->stop_signal.
1873         (procfs_make_note_section): Find the last stop_signal.
1874
1875         * solib-irix.c: Include gdbthread.h.
1876         (irix_solib_create_inferior_hook): Adjust.
1877         * solib-osf.c: Include gdbthread.h.
1878         (osf_solib_create_inferior_hook): Adjust.
1879         * solib-sunos.c: Include gdbthread.h.
1880         (sunos_solib_create_inferior_hook): Adjust.
1881         * solib-svr4.c: Include gdbthread.h.
1882         (svr4_solib_create_inferior_hook): Adjust.
1883
1884         * win32-nat.c (do_initial_win32_stuff): Adjust.
1885
1886 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
1887
1888         * gdbthread.h (struct thread_info): Add comments around
1889         proceed_to_finish.
1890         (save_infrun_state, load_infrun_state): Remove proceed_to_finish
1891         argument.
1892         * thread.c (load_infrun_state, save_infrun_state): Delete
1893         proceed_to_finish argument and references to it.
1894
1895         * infcall.c (call_function_by_hand): Adjust.
1896         * infcmd.c (finish_command): Adjust.
1897         * infrun.c (proceed_to_finish): Delete.
1898         (clear_proceed_status): Adjust.
1899         (context_switch): Don't context-switch proceed_to_finish.
1900         (normal_stop, save_inferior_status, restore_inferior_status):
1901         Adjust.
1902
1903 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
1904
1905         * inferior.h (stop_bpstat): Delete.
1906
1907         * breakpoint.h (bpstat_do_actions): Remove bpstat* argument.
1908         
1909         * breakpoint.c (bpstat_do_actions): Rename to ...
1910         (bpstat_do_actions_1): ... this.  Make static.  Change return type
1911         to int.  Return true if a breakpoint proceeded.
1912         (bpstat_do_actions): New, as wrapper around bpstat_do_actions_1.
1913         (delete_breakpoint): Don't reference the global stop_bpstat; it's
1914         gone.
1915
1916         * gdbthread.h (struct thread_info): Add stop_bpstat.
1917         (save_infrun_state, load_infrun_state): Remove stop_bpstat
1918         argument.
1919         * thread.c (load_infrun_state, save_infrun_state): Remove
1920         stop_bpstat argument, and the code referencing it.
1921
1922         * infcall.c: Include "gdbthread.h".
1923         (call_function_by_hand): Adjust.
1924         * exceptions.c: Include "gdbthread.h".
1925         (throw_exception): Adjust.
1926         * infcmd.c (stop_bpstat): Delete.
1927         (continue_command): In all-stop, set the ignore count on the
1928         thread that reported the stop.  In non-stop, set it on the current
1929         thread.
1930         (finish_command_continuation): Adjust.
1931         (program_info): Adjust.
1932         * infrun.c (clear_proceed_status): Adjust.
1933         (context_switch): Don't context-switch stop_bpstat.
1934         (handle_inferior_event): Adjust.
1935         (normal_stop): Adjust.
1936         (save_inferior_status, restore_inferior_status): Adjust.
1937
1938         * inf-loop.c (inferior_event_handler): Remove parameter to
1939         bpstat_do_actions call.
1940         * top.c (command_loop): Remove parameter to bpstat_do_actions
1941         call.  Call it unconditionally.
1942         * event-top.c (command_handler): Ditto.
1943         * python/python.c (execute_gdb_command): Ditto.
1944
1945 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
1946
1947         * inferior.h (step_over_calls): Delete.
1948
1949         * gdbthread.h (save_infrun_state, load_infrun_state): Remove
1950         step_over_calls argument.
1951         * thread.c (save_infrun_state, load_infrun_state): Remove
1952         step_over_calls argument.  Adjust.
1953
1954         * infcmd.c (step_over_calls): Delete.
1955         (step_1): Adjust.
1956         * infrun.c (clear_proceed_status): Adjust.
1957         (context_switch): Don't context-switch step_over_calls.
1958         (handle_inferior_event, save_inferior_status)
1959         (restore_inferior_status): Adjust.
1960
1961 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
1962
1963         Remove context switching in favour of accessing thread_info fields
1964         directly.
1965
1966         * infrun.c (stepping_over_breakpoint, step_resume_breakpoint):
1967         Delete.
1968         (struct thread_stepping_state): Delete.
1969         (gtss, tss): Delete.
1970         (follow_inferior_reset_breakpoints, follow_exec)
1971         (resume, clear_proceed_status): Adjust.
1972         (prev_pc): Delete.
1973         (proceed, start_remote, init_wait_for_inferior): Adjust.
1974         (struct execution_control_state): Add event_thread member.
1975         (delete_step_resume_breakpoint_callback)
1976         (delete_step_thread_step_resume_breakpoint)
1977         (delete_step_thread_step_resume_breakpoint_cleanup)
1978         (delete_step_thread_step_resume_breakpoint): New.
1979         (wait_for_inferior, init_execution_control_state): Use
1980         delete_step_thread_step_resume_breakpoint_cleanup.
1981         (wait_for_inferior): Set the event_thread.
1982         (fetch_inferior_event): Ditto.  Delete the step-resume breakpoint
1983         with delete_step_thread_step_resume_breakpoint.
1984         (init_thread_stepping_state): Change parameter type to
1985         thread_info.  Adjust.
1986         (context_switch): Don't context switch prev_pc,
1987         stepping_over_breakpoint, step_resume_breakpoint,
1988         step_range_start, step_range_end, step_frame_id,
1989         tss->stepping_over_breakpoint,
1990         tss->stepping_through_solib_after_catch,
1991         tss->stepping_through_solib_catchpoints, tss->current_line, or
1992         tss->current_symtab.
1993         (adjust_pc_after_break, handle_inferior_event)
1994         (currently_stepping, step_into_function)
1995         (insert_step_resume_breakpoint_at_sal)
1996         (insert_longjmp_resume_breakpoint, keep_going): Adjust.
1997         (clear_stepping_state): New.
1998         (normal_stop): Adjust.
1999         (save_inferior_status, restore_inferior_status): Adjust.
2000
2001         * gdbthread.h (struct thread_info): Comments describing the
2002         members moved here.  Add step_after_step_resume_breakpoint.
2003         (delete_step_resume_breakpoint): Add thread_info argument.
2004         (save_infrun_state, load_infrun_state): Remove prev_pc,
2005         trap_expected, step_resume_breakpoint, step_range_start,
2006         step_range_end, step_frame_id, another_trap,
2007         stepping_through_solib_after_catch,
2008         stepping_through_solib_catchpoints, current_line and
2009         current_symtab function arguments.
2010         (inferior_thread): Declare.
2011
2012         * thread.c (inferior_thread): New.
2013         (delete_step_resume_breakpoint): Add a thread_info parameter and
2014         rewrite.
2015         (load_infrun_state, save_infrun_state): Remove prev_pc,
2016         trap_expected, step_resume_breakpoint, step_range_start,
2017         step_range_end, step_frame_id, stepping_over_breakpoint,
2018         stepping_through_solib_after_catch,
2019         stepping_through_solib_catchpoints, current_line and
2020         current_symtab args.  Remove code referencing them.
2021
2022         * infcmd.c (step_range_start, step_range_end, step_frame_id):
2023         Delete.
2024         (step_1, step_once, until_next_command): Adjust.
2025
2026         * inferior.h (step_range_start, step_range_end, step_frame_id):
2027         Delete.
2028
2029         * linux-nat.c (linux_child_follow_fork): If following the child,
2030         move the step state to it.  Adjust.
2031         * inf-ptrace.c (inf_ptrace_follow_fork): Ditto.
2032         * inf-ttrace.c (inf_ttrace_follow_fork): Ditto.
2033
2034 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2035
2036         * bsd-uthread.c (bsd_uthread_find_new_threads): Claim the main
2037         thread.
2038
2039 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2040
2041         * corelow.c (add_to_thread_list): If this is the first time we
2042         hear about thread info, update inferior_ptid.
2043         (core_open): Clear the thread list and set inferior_ptid before
2044         acknowledging a new inferior.  Find threads before fetching
2045         register info.  Give an upper target layer a chance to find and
2046         claim new threads.  Print core generation and stop signal info
2047         after finding new threads.
2048         (get_core_register_section): Look at the lwp member of
2049         inferior_ptid for detecting if we have threads info, instead of
2050         the pid member.
2051         (core_pid_to_str): New.
2052         (init_core_ops): Register core_pid_to_str.
2053
2054 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2055
2056         * spu-linux-nat.c (spu_child_post_startup_inferior)
2057         (spu_child_post_attach): Don't add the main thread here.
2058
2059 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2060
2061         Use ptid_t.tid to store thread ids instead of ptid_t.pid.
2062
2063         * gnu-nat.c (inf_validate_procs): If this is the first time we're
2064         seeing a thread id, extend the main thread's ptid.  If we still
2065         have pending execs, don't be verbose about new threads.
2066         (gnu_wait, gnu_resume, gnu_attach, gnu_thread_alive)
2067         (gnu_pid_to_str, cur_thread, sig_thread_cmd): Adjust.
2068         * i386gnu-nat.c (gnu_fetch_registers, gnu_store_registers):
2069         Adjust.
2070
2071 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2072
2073         * procfs.c (to_attach): Create a procinfo for the current lwp.
2074         Add it to gdb's thread list.
2075         (procfs_fetch_registers, procfs_store_registers): Assume there's
2076         always an lwp.
2077         (procfs_wait): Don't add the main thread here.
2078         (procfs_init_inferior): Create a procinfo for the main lwp here.
2079         Change main thread's ptid with thread_change_ptid.
2080         (procfs_notice_thread): Check for exited threads.
2081         (procfs_corefile_thread_callback): Remove check for the main
2082         process.
2083         (procfs_make_note_section): Assume there is always a thread.
2084
2085         * sol-thread.c (sol_thread_attach): Clear sol_thread_active before
2086         attaching.  Change the main thread ptid with thread_change_ptid.
2087         (sol_thread_detach): Clear sol_thread_active.
2088         (sol_thread_wait): Check for exited threads.
2089         (sol_thread_create_inferior): Clear sol_thread_active before
2090         creating a new inferior.  Change the main thread ptid with
2091         thread_change_ptid.
2092         (sol_thread_mourn_inferior): Clear sol_thread_active.
2093         (sol_find_new_threads_callback): Check for exited threads.
2094
2095 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2096
2097         * inf-ttrace.c (inf_ttrace_wait): On TTEVT_LWP_CREATE and
2098         LWP_TERMINATE, resume the caller thread.  On TTEVT_LWP_CREATE,
2099         TTEVT_LWP_EXIT and TTEVT_LWP_TERMINATE, don't stop the whole
2100         process, and return TARGET_WAITKIND_IGNORE.
2101
2102 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2103
2104         * inf-ttrace.c: Include <signal.h>
2105         (inf_ttrace_delete_dead_threads_callback): New.
2106         (inf_ttrace_resume_lwp): New.
2107         (inf_ttrace_resume_callback, inf_ttrace_resume): Rewrite.  Don't
2108         delete dying threads until they are really dead.
2109         (inf_ttrace_wait): After stopping the whole process, delete any
2110         dying thread that is really dead by now.
2111         (inf_ttrace_thread_alive): Return 1.
2112         (inf_ttrace_extra_thread_info): New.
2113         (inf_ttrace_target): Register inf_ttrace_extra_thread_info.
2114
2115 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2116
2117         * inf-ttrace.c (inf_ttrace_follow_fork): Register the main thread
2118         of the child fork.
2119         (inf_ttrace_attach): Add the main thread.
2120         (inf_ttrace_resume_callback): Check for exited threads.  Adjust
2121         for always a thread.
2122         (inf_ttrace_wait): Decorate the main thread's ptid with lwp info
2123         using thread_change_ptid, and set its private data.  Don't add the
2124         main thread here.
2125         (inf_ttrace_pid_to_str): Adjust.
2126
2127 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2128
2129         * bsd-uthread.c (bsd_uthread_wait): Decorate the main thread with
2130         thread_change_ptid.  Check for exited threads.
2131         (bsd_uthread_find_new_threads): Check for exited threads.
2132
2133 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2134
2135         * inf-ptrace.c: Include "gdbthread.h".
2136         (inf_ptrace_attach): Add the main thread here.
2137         * linux-nat.c (linux_nat_attach): Don't add the main thread here.
2138         Decorate the main thread id with the lwp id.
2139
2140 2008-09-08  Pedro Alves  <pedro@codesourcery.com>
2141
2142         * linux-nat.c (linux_nat_wait): Update inferior_ptid's ptid with
2143         thread_change_ptid.  Don't add or mark the main thread as running
2144         and executing here.
2145         * fork-child.c (fork_inferior): Add the main thread here.
2146
2147 2008-09-08  Jerome Guitton  <guitton@adacore.com>
2148
2149         * rs6000-tdep.c (rs6000_fetch_instruction)
2150         (rs6000_skip_stack_check): New functions.
2151         (skip_prologue): Skip stack check sequence.
2152         
2153 2008-09-08  David Daney  <ddaney@avtrex.com>
2154
2155         * dummy-frame.h (frame.h): Include it.
2156         (struct frame_id): Remove declaration.
2157
2158 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2159
2160         * spu-tdep.c (spu_push_dummy_code): New function.
2161         (spu_gdbarch_init): Install it.
2162
2163 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2164
2165         * gdbarch.sh (gdbarch_dump): Use core_addr_to_string_nz
2166         instead of paddr_nz.
2167         * gdbarch.c: Regenerate.
2168
2169         * target.c (target_xfer_partial, debug_print_register): Use
2170         core_addr_to_string_nz instead of paddr_nz.
2171
2172 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2173
2174         * rs6000-tdep.c (rs6000_gdbarch_init): Setup displaced stepping
2175         *before* calling gdbarch_init_osabi.
2176         (rs6000_aix_init_osabi): Disable displaced stepping.
2177
2178 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2179
2180         * target.c (update_current_target): Do not inherit to_open
2181         or to_close.
2182         (pop_target): Call target_close on target_stack instead
2183         of current_target.
2184         (pop_all_targets_above): Likewise.
2185
2186 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2187
2188         * gnu-v3-abi.c (gnuv3_decode_method_ptr): New function.
2189         (gnuv3_print_method_ptr): Use it.
2190         (gnuv3_method_ptr_to_value): Likewise.
2191
2192 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2193
2194         * nto-tdep.h (struct nto_target_ops): Add gdbarch parameter to
2195         register_area callback function.
2196         * i386-nto-tdep.c (i386nto_register_area): Add gdbarch parameter.
2197         Use it instead of current_gdbarch.
2198         * nto-procfs.c (procfs_store_registers): Update call.
2199
2200 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2201
2202         * mips-tdep.c (deprecated_mips_set_processor_regs_hack): Use
2203         regcache architecture instead of current_gdbarch.
2204
2205 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2206
2207         * mep-tdep.c (struct mep_prologue): Add gdbarch member.
2208         (check_for_saved): Use it instead of current_gdbarch.
2209         (is_arg_spill): Add gdbarch paramter.  Use it instead
2210         of current_gdbarch.
2211         (mep_analyze_prologue): Add gdbarch parameter.  Pass it
2212         to is_arg_spill and check_for_saved.
2213         (mep_skip_prologue, mep_analyze_frame_prologue): Update calls.
2214
2215 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2216
2217         * hppa-tdep.c (internalize_unwinds): Use objfile architecture
2218         instead of current_gdbarch.
2219
2220 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2221
2222         * m68k-tdep.h (m68kbsd_fpreg_offset): Add gdbarch parameter.
2223         * m68kbsd-tdep.c (m68kbsd_fpreg_offset): Add gdbarch paramter.
2224         Use it instead of current_gdbarch.
2225         (m68kbsd_supply_fpregset): Update call.
2226         * m68kbsd-nat.c (m68kbsd_supply_fpregset): Likewise.
2227         (m68kbsd_collect_fpregset): Likewise.
2228
2229 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2230
2231         * cris-tdep.c (cris_version, cris_mode): Remove.
2232         (crisv32_single_step_through_delay): Use tdep->cris_mode.
2233         (cris_breakpoint_from_pc): Likewise.
2234         (cris_frame_unwind_cache): Use tdep->cris_version.
2235         (crisv32_scan_prologue): Likewise.
2236         (cris_spec_reg_applicable): Add gdbarch argument.
2237         Use tdep->cris_version.
2238         (cris_register_size, cris_special_register_name): Update calls.
2239         (cris_special_register_name): Add gdbarch argument.
2240         (cris_register_name, crisv32_register_name): Update calls.
2241
2242 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2243
2244         * m68hc11-tdep.c (gdb_print_insn_m68hc11): Use info->arch
2245         instead of current_gdbarch.
2246
2247         * sh64-tdep.c (gdb_print_insn_sh64): Remove.
2248         (sh64_gdbarch_init): Install print_insn_sh64 directly.
2249         * sh-tdep.c (gdb_print_insn_sh): Remove.
2250         (sh_gdbarch_init): Install print_insn_sh directly.
2251
2252         * mips-tdep.c (gdb_print_insn_mips): Do not check mips_abi
2253         from current_gdbarch.
2254         (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): New functions.
2255         (mips_gdbarch_init): Install them instead of gdb_print_insn_mips
2256         depending on mips_abi.
2257
2258 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2259
2260         * gdbarch.sh (addr_bits_remove): Change type to 'm'.
2261         (smash_text_address): Likewise.
2262         * gdbarch.c, gdbarch.h: Regenerate.
2263
2264         * arch-utils.c (core_addr_identity): Add gdbarch parameter.
2265         * arch-utils.h (core_addr_identity): Likewise.
2266         * arm-tdep.c (arm_addr_bits_remove): Likewise.
2267         (arm_smash_text_address): Likewise.
2268         * hppa-tdep.c (hppa_smash_text_address): Likewise.
2269         * m88k-tdep.c (m88k_addr_bits_remove): Likewise.
2270         * s390-tdep.c (s390_addr_bits_remove): Likewise.
2271
2272         * mips-tdep.c (mips_addr_bits_remove): Add gdbarch parameter.
2273         Use it instead of current_gdbarch.
2274
2275         * arm-tdep.c (arm_prologue_prev_register, arm_unwind_pc,
2276         arm_dwarf2_prev_register): Update calls.
2277         * m88k-tdep.c (m88k_unwind_pc): Update call.
2278
2279 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2280
2281         * dwarf2expr.h (dwarf2_read_address): Add gdbarch argument.
2282         * dwarf2expr.c (dwarf2_read_address): Add gdbarch argument.
2283         Call gdbarch_integer_to_address directly instead of converting
2284         to value and back.  Update comment.
2285         (execute_stack_op): Update call site.
2286         * dwarf2loc.c (find_location_expression): Likewise.
2287         (locexpr_describe_location): Update
2288
2289         * dwarf2expr.h (struct dwarf_expr_context): Add gdbarch member.
2290         * dwarf2-frame.c (execute_stack_op): Initialize ctx->gdbarch.
2291         * dwarf2loc. (dwarf2_evaluate_loc_desc): Likewise.
2292         (dwarf2_loc_desc_needs_frame): Likewise.
2293
2294 2008-09-05  Ulrich Weigand  <uweigand@de.ibm.com>
2295
2296         * breakpoint.h (struct bp_location): Change type of section
2297         member to "struct obj_section *".
2298         * tracepoint.h (struct tracepoint): Likewise.
2299         * symtab.h (struct general_symbol_info): Replace bfd_section
2300         member with obj_section.
2301         (struct symtab_and_line): Change type of section member to
2302         "struct obj_section *".
2303         (SYMBOL_BFD_SECTION): Remove macro, replace by ...
2304         (SYMBOL_OBJ_SECTION): ... this.
2305
2306         * minsym.c (prim_record_minimal_symbol_and_info): Record symbol
2307         section as obj_section instead of bfd_section.
2308
2309         * ada-lang.c (ada_decode_symbol): Use gsymbol->obj_section
2310         directly instead of looking of obj_section from bfd_section.
2311
2312         * objfiles.h (find_pc_sect_section): Remove.
2313         * objfiles.c (find_pc_sect_section): Remove.
2314         (find_pc_section): Inline find_pc_sect_section code.
2315
2316         * symfile.h (find_pc_overlay): Return struct obj_section *.
2317         (find_pc_mapped_section): Likewise.
2318         (section_is_overlay, section_is_mapped): Change type of section
2319         argument to struct obj_section *.
2320         (pc_in_mapped_range, pc_in_unmapped_range): Likewise.
2321         (overlay_mapped_address, overlay_unmapped_address): Likewise.
2322         (symbol_overlayed_address): Likewise.
2323         * symtab.h (symbol_overlayed_address): Likewise.
2324         * symfile.c (overlay_is_mapped): Remove.
2325         (section_is_mapped): Inline overlay_is_mapped code.  Update.
2326         (overlay_invalidate_all): Update.
2327         (section_is_overlay): Change section argument to type
2328         "struct obj_section *".  Use bfd_ methods.
2329         (pc_in_unmapped_range): Likewise.  Handle relocated sections.
2330         (pc_in_mapped_range): Likewise.  Handle relocated sections.
2331         (sections_overlap): Likewise.
2332         (overlay_unmapped_address): Likewise.
2333         (overlay_mapped_address): Likewise.
2334         (symbol_overlayed_address): Likewise.
2335         (find_pc_overlay): Return struct obj_section *.
2336         (find_pc_mapped_section): Likewise.
2337         (list_overlays_command): Update.
2338         (map_overlay_command, unmap_overlay_command): Update.
2339         (simple_overlay_update): Update.
2340
2341         * block.h (blockvector_for_pc_sect): Change section argument
2342         to type "struct obj_section *".
2343         (block_for_pc_sect): Likewise.
2344         * block.c (blockvector_for_pc_sect): Change section argument
2345         to type "struct obj_section *".
2346         (block_for_pc_sect): Likewise.
2347         * symtab.h (find_pc_sect_function, find_pc_sect_psymtab,
2348         find_pc_sect_symtab, find_pc_sect_psymbol, find_pc_sect_line,
2349         lookup_minimal_symbol_by_pc_section, find_function_start_pc): Likewise.
2350         (matching_bfd_sections): Rename to ...
2351         (matching_obj_sections): ... this.  Update argument types.
2352         * blockframe.c (find_pc_sect_function): Likewise.
2353         * breakpoint.c (describe_other_breakpoints): Likewise.
2354         (breakpoint_has_pc, check_duplicates_for): Likewise.
2355         * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Likewise.
2356         (lookup_minimal_symbol_by_pc_section): Likewise.
2357         * symtab.c (find_pc_sect_psymtab_closer): Likewise.
2358         (find_pc_sect_psymtab, find_pc_sect_psymbol, find_pc_sect_symtab,
2359         find_pc_sect_line, find_function_start_pc): Likewise.
2360         (matching_bfd_sections): Rename to ...
2361         (matching_obj_sections): ... this.  Update argument types.
2362
2363         * blockframe.c (find_pc_partial_function): Update to section
2364         type changes.  No longer call find_pc_sect_section.
2365         (cache_pc_function_section): Change to type "struct obj_section *".
2366         * breakpoint.c (resolve_sal_pc): Update to section type changes.
2367         * exec.c (xfer_memory): Likewise.
2368         * findvar.c (read_var_value): Likewise.
2369         * infcmd.c (jump_command): Likewise.
2370         * linespec.c (minsym_found): Likewise.
2371         * maint.c (maintenance_translate_address): Likewise.
2372         * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Likewise.
2373         (lookup_solib_trampoline_symbol_by_pc): Likewise.
2374         * parse.c (write_exp_msymbol): Likewise.
2375         * printcmd.c (build_address_symbolic): Likewise.
2376         (address_info, sym_info): Likewise.
2377         * symmisc.c (dump_msymbols, print_symbol): Likewise.
2378         * symtab.c (fixup_section): Likewise.
2379         (fixup_symbol_section, fixup_psymbol_section): Likewise.
2380         (find_pc_line, find_function_start_sal): Likewise.
2381         * target.c (memory_xfer_partial): Likewise.
2382         * hppa-hpux-tdep.c (hppa64_hpux_in_solib_call_trampoline): Likewise.
2383         * spu-tdep.c (spu_overlay_update): Likewise.
2384
2385 2008-09-04  Doug Evans  <dje@google.com>
2386
2387         * defs.h (plongest,pulongest): Renamed from paddr_u,paddr_d.
2388         Change argument of pulongest from CORE_ADDR to ULONGEST.
2389         All callers updated.
2390         * utils.c (plongest): Renamed from paddr_d.
2391         (pulongest): Renamed from paddr_u, change arg type to ULONGEST.
2392         * remote-mips.c (send_srec): Use paddr_nz instead of paddr_u in
2393         `CORE_ADDR addr' arg of error message.
2394
2395 2008-09-03  Angela Marie Thomas <angela@releasedominatrix.com>
2396
2397         * ser-tcp.c (ser_tcp_send_break): New function.
2398         (_initialize_ser_tcp): Use ser_tcp_send_break.
2399         * ser-tcp.h (ser_tcp_send_break): New prototype.
2400
2401 2008-09-03  Ulrich Weigand  <uweigand@de.ibm.com>
2402
2403         * spu-tdep.c (spu_push_dummy_call): Update all stack pointer slots
2404         when allocating stack frame for inferior call.
2405
2406 2008-09-03  Ulrich Weigand  <uweigand@de.ibm.com>
2407
2408         * spu-tdep.c (spu_frame_unwind_cache): Do not attempt to unwind
2409         SP or return address if we failed to find a valid frame.
2410
2411 2008-09-03  Aleksandar Ristovski  <aristovski@qnx.com>
2412
2413         * breakpoint.c (breakpoint_init_inferior): Mark as not inserted only
2414         non-permanent breakpoints.
2415         (bpstat_stop_status): Change enable_state to bp_disabled only for
2416         non-permanent breakpoints.
2417         (bp_loc_is_permanent): New function.
2418         (create_breakpoint): Check if the location points to a permanent
2419         breakpoint and if it does, make breakpoint permanent.
2420         (update_breakpoint_locations): Make sure new locations of permanent
2421         breakpoints are properly initialized.
2422         * i386-tdep.c (i386_skip_permanent_breakpoint): New function.
2423         (i386_gdbarch_init): Set gdbarch_skip_permanent_breakpoint.
2424
2425 2008-09-02  Pedro Alves  <pedro@codesourcery.com>
2426
2427         * breakpoint.c (insert_breakpoints, update_global_location_list):
2428         Check breakpoints_always_inserted_mode instead of
2429         always_inserted_mode directly.
2430
2431 2008-09-02  Andreas Schwab  <schwab@suse.de>
2432
2433         * ia64-tdep.c (ia64_get_dyn_info_list): Use obj_section_addr.
2434
2435 2008-09-01  Jan Kratochvil  <jan.kratochvil@redhat.com>
2436
2437         Stay compatible after the GCC PR fortran/29635 fix.
2438         * dwarf2read.c (process_die <DW_TAG_imported_module>)
2439         (process_die <DW_TAG_imported_module>): Do not assert anything about
2440         these unsupported tags.
2441
2442 2008-08-29  Tom Tromey  <tromey@redhat.com>
2443
2444         * maint.c (_initialize_maint_cmds): Fix typo.
2445
2446 2008-08-29  Tom Tromey  <tromey@redhat.com>
2447
2448         * dwarf2read.c (dwarf2_build_psymtabs_hard): Copy dirname on
2449         obstack.
2450
2451 2008-08-27  Ulrich Weigand  <uweigand@de.ibm.com>
2452
2453         * remote.c: Include "gdb_stat.h".
2454
2455 2008-08-26  Ulrich Weigand  <uweigand@de.ibm.com>
2456
2457         * dummy-frame.h (dummy_frame_pop): Add prototype.
2458         * dummy-frame.c: Include "observer.h".
2459         (dummy_frame_push): Do not check for stale frames.
2460         (dummy_frame_pop): New function.
2461         (cleanup_dummy_frames): New function.
2462         (_initialize_dummy_frame): Install it as inferior_created observer.
2463
2464         * frame.h (struct frame_id): Update comments.
2465         (frame_id_inner): Remove prototype.
2466         * frame.c (frame_id_inner): Make static.  Add comments.
2467         (frame_find_by_id): Update frame_id_inner safety net check to avoid
2468         false positives for targets using non-contiguous stack ranges.
2469         (get_prev_frame_1): Update frame_id_inner safety net check.
2470         (frame_pop): Call dummy_frame_pop when popping a dummy frame.
2471
2472         * stack.c (return_command): Directly pop the selected frame.
2473         * infrun.c (handle_inferior_event): Remove dead code.
2474         * i386-tdep.c (i386_push_dummy_call): Update comment.
2475
2476 2008-08-26  Ulrich Weigand  <uweigand@de.ibm.com>
2477
2478         * breakpoint.c (remove_breakpoint): Do not fail if unable to remove
2479         breakpoint from shared library.
2480
2481 2008-08-26  Ulrich Weigand  <uweigand@de.ibm.com>
2482
2483         * solib-svr4.c (read_program_header): New function.
2484         (scan_dyntag_auxv): New function.
2485         (elf_locate_base): Use it if scan_dyntag fails.
2486         (find_program_interpreter): New function.
2487         (enable_break): Use it instead of .interp section.
2488
2489 2008-08-26  Ulrich Weigand  <uweigand@de.ibm.com>
2490
2491         * remote.h (remote_filename_p, remote_bfd_open): Add prototypes.
2492         * remote.c (remote_bfd_iovec_open, remote_bfd_iovec_close,
2493         remote_bfd_iovec_pread, remote_bfd_iovec_stat, remote_filename_p,
2494         remote_bfd_open): New functions.
2495         (remote_hostio_send_command): Fail safely if remote connection
2496         is not set up.
2497
2498         * solist.h (solib_open): Remove prototype.
2499         (solib_bfd_open): Add prototype.
2500         * solib.c: Include "remote.h".
2501         (solib_open): Remove, replace by ...
2502         (solib_bfd_open): ... this new function.  Handle remote BFDs.
2503         (solib_map_sections): Replace solib_open by solib_bfd_open.
2504         * solib-frv.c: Include "exceptions.h".
2505         (enable_break2): Replace solib_open by solib_bfd_open.
2506         * solib-svr4.c: Include "exceptions.h".
2507         (enable_break): Replace solib_open by solib_bfd_open.
2508
2509         * symfile.c: Include "remote.h".
2510         (build_id_verify): Handle remote BFDs.
2511         (separate_debug_file_exists): Use BFD to access file.  Handle
2512         remote BFDs.
2513         (symfile_bfd_open): Handle remote BFDs.
2514         (reread_symbols): Handle remote BFDs.
2515
2516         * NEWS: Mention "remote:" argument prefix to "set sysroot".
2517
2518 2008-08-26  Ulrich Weigand  <uweigand@de.ibm.com>
2519
2520         * gdbarch.sh (target_gdbarch): New global variable.
2521         (deprecated_current_gdbarch_select_hack): Set it.
2522         * gdbarch.c, gdbarch.h: Regenerate.
2523
2524         * arch-utils.c (gdbarch_update_p): Use target_gdbarch instead
2525         of current_gdbarch.
2526         * target-descriptions.c (target_find_description): Likewise.
2527         * arm-tdep.c (arm_update_current_architecture): Likewise.
2528         (show_fp_model, arm_show_abi, arm_show_fallback_mode, 
2529         arm_show_force_mode): Likewise.
2530         * mips-tdep.c (show_mask_address, show_mipsfpu_command,
2531         show_mips_abi): Likewise.
2532         * mep-tdep.c (me_module_register_set, current_me_module): Likewise.
2533
2534         * target.c (target_translate_tls_address): Use target_gdbarch
2535         instead of current_gdbarch.
2536         * remote.c (struct packet_reg): Likewise.
2537         (get_remote_arch_state, packet_reg_from_regnum,
2538         packet_reg_from_pnum, remote_check_symbols, remote_wait,
2539         remote_address_masked, remote_insert_breakpoint,
2540         remote_insert_hw_breakpoint, remote_read_description): Likewise.
2541         * remote-m32r-sdi.c (m32r_resume, m32r_wait): Likewise.
2542         * remote-mips.c (mips_open, mips_common_breakpoint): Likewise.
2543         * cris-tdep.c (cris_can_use_hardware_watchpoint): Likewise.
2544
2545         * solib.c (solib_open, solib_map_sections, solib_read_symbols,
2546         solib_add, info_sharedlibrary_command, solib_address, 
2547         solib_create_inferior_hook, in_solib_dynsym_resolve_code,
2548         solib_global_lookup): Likewise.
2549         * solib-frv.c (enable_break2, frv_relocate_main_executable): Likewise.
2550         * solib-irix.c (irix_current_sos, irix_open_symbol_file_object):
2551         Likewise.
2552         * solib-sunos.c (sunos_solib_create_inferior_hook): Likewise.
2553         * solib-svr4.c (exec_entry_point, enable_break, svr4_free_so,
2554         set_solib_svr4_fetch_link_map_offsets, svr4_fetch_link_map_offsets):
2555         Likewise.
2556         * nto-tdep.c (nto_find_and_open_solib, nto_init_solib_absolute_prefix,
2557         nto_truncate_ptr): Likewise.
2558         * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Likewise.
2559
2560 2008-08-26  Luis Machado  <luisgpm@br.ibm.com>
2561
2562         * ppc-linux-tdep.c (ppc_linux_vsx_regset_sections) New structure.
2563         (ppc_linux_vmx_regset_sections): New structure.
2564         (ppc_linux_fp_regset_sections): New structure.
2565         (ppc_linux_init_abi): Select core-file regset  based on target
2566         features.
2567
2568 2008-08-26  Ulrich Weigand  <uweigand@de.ibm.com>
2569
2570         * target.c (debug_print_register): Use regcache_raw_collect
2571         instead of regcache_cooked_read.  Only handle raw registers.
2572
2573 2008-08-25  Pedro Alves  <pedro@codesourcery.com>
2574
2575         * cp-name-parser.y: Include config.h before system headers.
2576
2577 2008-08-25  Ulrich Weigand  <uweigand@de.ibm.com>
2578
2579         * m88k-tdep.c: Update for unwinder changes.
2580
2581 2008-08-24  Tom Tromey  <tromey@redhat.com>
2582
2583         * s390-tdep.c (s390_address_class_type_flags): Use
2584         TYPE_INSTANCE_FLAG_ADDRESS_CLASS_1.
2585         (s390_address_class_type_flags_to_name): Likewise.
2586         (s390_address_class_name_to_type_flags): Likewise.
2587
2588 2008-08-24  Tom Tromey  <tromey@redhat.com>
2589
2590         * rs6000-tdep.c (rs6000_builtin_type_vec128): Don't use
2591         TYPE_FLAGS.
2592         * features/rs6000/powerpc-vsx32l.c
2593         (initialize_tdesc_powerpc_vsx32l): Update.
2594         * features/rs6000/powerpc-vsx32.c
2595         (initialize_tdesc_powerpc_vsx32): Update.
2596         * features/rs6000/powerpc-vsx64.c
2597         (initialize_tdesc_powerpc_vsx64): Update.
2598         * features/rs6000/powerpc-vsx64l.c
2599         (initialize_tdesc_powerpc_vsx64l): Update.
2600         * target-descriptions.c (maint_print_c_tdesc_cmd): Emit
2601         TYPE_VECTOR, not TYPE_FLAGS.
2602
2603 2008-08-24  Tom Tromey  <tromey@redhat.com>
2604
2605         * xml-tdesc.c (tdesc_end_union): Update.
2606         * stabsread.c (define_symbol): Update.
2607         (read_type): Update.
2608         (read_struct_type): Update.
2609         (read_enum_type): Update.
2610         * spu-tdep.c (spu_builtin_type_vec128): Update.
2611         * sh-tdep.c (sh_push_dummy_call_fpu): Update.
2612         (sh_push_dummy_call_nofpu): Update.
2613         * mdebugread.c (parse_symbol): Update.
2614         (parse_symbol): Update.
2615         (parse_symbol): Update.
2616         (upgrade_type): Update.
2617         * jv-lang.c (java_lookup_class): Update.
2618         * iq2000-tdep.c (iq2000_pointer_to_address): Update.
2619         * i386-tdep.c (i386_mmx_type): Update.
2620         (i386_sse_type): Update.
2621         * gdbtypes.h (enum type_flag_value): New enum.
2622         (enum type_instance_flag_value): New enum.
2623         (TYPE_FLAG_UNSIGNED, TYPE_FLAG_NOSIGN, TYPE_FLAG_STUB,
2624         TYPE_FLAG_TARGET_STUB, TYPE_FLAG_STATIC, TYPE_FLAG_PROTOTYPED,
2625         TYPE_FLAG_INCOMPLETE, TYPE_FLAG_VARARGS, TYPE_FLAG_VECTOR,
2626         TYPE_FLAG_FIXED_INSTANCE, TYPE_FLAG_STUB_SUPPORTED,
2627         TYPE_FLAG_NOTTEXT): Now enum constants.
2628         (TYPE_FLAG_CONST, TYPE_FLAG_VOLATILE, TYPE_FLAG_CODE_SPACE,
2629         TYPE_FLAG_DATA_SPACE, TYPE_FLAG_ADDRESS_CLASS_1,
2630         TYPE_FLAG_ADDRESS_CLASS_2): Remove.
2631         (TYPE_INSTANCE_FLAG_CONST, TYPE_INSTANCE_FLAG_VOLATILE,
2632         TYPE_INSTANCE_FLAG_CODE_SPACE, TYPE_INSTANCE_FLAG_DATA_SPACE,
2633         TYPE_INSTANCE_FLAG_ADDRESS_CLASS_1,
2634         TYPE_INSTANCE_FLAG_ADDRESS_CLASS_2): New constants.
2635         (TYPE_UNSIGNED, TYPE_NOSIGN, TYPE_STUB, TYPE_TARGET_STUB,
2636         TYPE_STATIC, TYPE_PROTOTYPED, TYPE_INCOMPLETE, TYPE_VARARGS,
2637         TYPE_VECTOR, TYPE_FIXED_INSTANCE, TYPE_STUB_SUPPORTED,
2638         TYPE_NOTTEXT): Update.
2639         (TYPE_FLAG_ADDRESS_CLASS_ALL): Remove.
2640         (TYPE_INSTANCE_FLAG_ADDRESS_CLASS_ALL): New define.
2641         (TYPE_VOLATILE, TYPE_CODE_SPACE, TYPE_DATA_SPACE,
2642         TYPE_ADDRESS_CLASS_1, TYPE_ADDRESS_CLASS_2,
2643         TYPE_ADDRESS_CLASS_ALL): Update.
2644         (struct main_type) <flags>: Remove.
2645         <flag_unsigned, flag_nosign, flag_stub, flag_target_stub,
2646         flag_static, flag_prototyped, flag_incomplete, flag_varargs,
2647         flag_vector, flag_stub_supported, flag_nottext,
2648         flag_fixed_instance>: New fields.
2649         <nfields, vptr_fieldno>: Move earlier.
2650         (TYPE_FLAGS): Remove.
2651         * gdbtypes.c (make_pointer_type): Update.
2652         (address_space_name_to_int): Update.
2653         (address_space_int_to_name): Update.
2654         (make_type_with_address_space): Update.
2655         (make_cv_type): Update.
2656         (create_range_type): Update.
2657         (get_discrete_bounds): Update.
2658         (create_set_type): Update.
2659         (make_vector_type): Update.
2660         (smash_to_method_type): Update.
2661         (check_typedef): Update.
2662         (check_stub_method): Update.
2663         (init_type): Individually assign flag fields.
2664         (recursive_dump_type): Don't print entire TYPE_FLAGS field.  Do
2665         print TYPE_FIXED_INSTANCE, TYPE_STUB_SUPPORTED, and TYPE_NOTTEXT.
2666         (copy_type_recursive): Copy the entire main type.  Don't use
2667         TYPE_FLAGS.
2668         * features/rs6000/powerpc-altivec64l.c
2669         (initialize_tdesc_powerpc_altivec64l): Update.
2670         * features/rs6000/powerpc-altivec64.c
2671         (initialize_tdesc_powerpc_altivec64): Update.
2672         * features/rs6000/powerpc-altivec32l.c
2673         (initialize_tdesc_powerpc_altivec32l): Update.
2674         * features/rs6000/powerpc-altivec32.c
2675         (initialize_tdesc_powerpc_altivec32): Update.
2676         * features/rs6000/powerpc-7400.c (initialize_tdesc_powerpc_7400):
2677         Update.
2678         * features/arm-with-iwmmxt.c (initialize_tdesc_arm_with_iwmmxt):
2679         Update.
2680         * dwarf2read.c (read_structure_type): Update.
2681         (read_enumeration_type): Likewise.
2682         (process_enumeration_scope): Likewise.
2683         (read_tag_pointer_type): Likewise.
2684         (read_subroutine_type): Likewise.
2685         (read_subroutine_type): Likewise.
2686         (read_base_type): Likewise.
2687         * coffread.c (coff_read_enum_type): Update.
2688         * ada-valprint.c (adjust_type_signedness): Update.
2689         * ada-typeprint.c (print_record_field_types): Update.
2690         * ada-lang.c (packed_array_type): Update.
2691         (empty_record): Don't reset TYPE_FLAGS.
2692         (ada_template_to_fixed_record_type_1): Update.
2693         (ada_template_to_fixed_record_type_1): Likewise.
2694         (template_to_static_fixed_type): Likewise.
2695         (to_record_with_fixed_variant_part): Likewise.
2696         (to_fixed_record_type): Likewise.
2697         (to_fixed_array_type): Likewise.
2698         (to_static_fixed_type): Likewise.
2699
2700 2008-08-23  Jim Blandy  <jimb@redhat.com>
2701
2702         PR macros/607:
2703         * symmisc.c (print_symbol_bcache_statistics): Include statistics
2704         for the macro bcache.
2705
2706 2008-08-23  Tom Tromey  <tromey@redhat.com>
2707
2708         * macrotab.h (struct macro_definition) <kind>: Shrink to one bit.
2709         (argc): Now 31 bits.
2710
2711 2008-08-22  Tom Tromey  <tromey@redhat.com>
2712
2713         * NEWS: Move macro entries back under "New commands".
2714
2715 2008-08-22  Ulrich Weigand  <uweigand@de.ibm.com>
2716
2717         * breakpoint.c (create_overlay_event_breakpoint): Rename to ...
2718         (create_overlay_event_breakpoint_1): ... this.  Add OBJFILE parameter.
2719         (create_overlay_event_breakpoint): Loop over all objfiles to install
2720         multiple instances of the overlay event breakpoint if present.
2721
2722 2008-08-22  Ulrich Weigand  <uweigand@de.ibm.com>
2723
2724         * spu-tdep.c (spu_overlay_new_objfile): Only consider SPU objfiles.
2725         (info_spu_event_command): Command only supported on SPU architecture.
2726         (info_spu_signal_command): Likewise.
2727         (info_spu_mailbox_command): Likewise.
2728         (info_spu_dma_command): Likewise.
2729         (info_spu_proxydma_command): Likewise.
2730
2731 2008-08-22  Ulrich Weigand  <uweigand@de.ibm.com>
2732
2733         * infrun.c (adjust_pc_after_break): Do not call get_thread_regcache
2734         if the thread has already exited.
2735
2736 2008-08-22  Pedro Alves  <pedro@codesourcery.com>
2737
2738         * infrun.c (proceed): Move back setting previous_inferior_ptid
2739         from here ...
2740         (wait_for_inferior): ... to here.
2741         (fetch_inferior_event): ... and here.
2742
2743 2008-08-21  Ulrich Weigand  <uweigand@de.ibm.com>
2744
2745         * gdbarch.sh: Include "regcache.h" into gdbarch.c.
2746         (deprecated_current_gdbarch_select_hack): Call registers_changed
2747         instead of reinit_frame_cache.
2748         * gdbarch.c: Regenerate.
2749
2750 2008-08-21  Ulrich Weigand  <uweigand@de.ibm.com>
2751
2752         * elfread.c (elf_symtab_read): Do not relocate thread-local symbols.
2753
2754 2008-08-21  Daniel Jacobowitz  <dan@codesourcery.com>
2755
2756         * xcoffread.c (SYMNAME_ALLOC): Correct syntax.
2757
2758 2008-08-21  Ulrich Weigand  <uweigand@de.ibm.com>
2759
2760         * findvar.c (locate_var_value): Do not call get_frame_arch
2761         with a NULL frame argument.
2762
2763 2008-08-21  Ulrich Weigand  <uweigand@de.ibm.com>
2764
2765         * frame.h (frame_map_regnum_to_name): Remove prototype.
2766         (frame_map_name_to_regnum): Remove prototype.
2767         * frame.c (frame_map_regnum_to_name): Remove.
2768         (frame_map_name_to_regnum): Remove.
2769         (frame_unwind_register_value): Use user_reg_map_regnum_to_name
2770         instead of frame_map_regnum_to_name.
2771         * ax-gdb.c: Include "user-regs.h".
2772         (gen_expr): Use user_reg_map_name_to_regnum instead of
2773         frame_map_name_to_regnum.
2774         * eval.c:  Include "user-regs.h".
2775         (evaluate_subexp_standard): Use user_reg_map_name_to_regnum
2776         instead of frame_map_name_to_regnum.
2777         * infcmd.c (registers_info): Likewise.
2778         * parse.c: Include "user-regs.h".
2779         (write_dollar_variable): Use user_reg_map_name_to_regnum
2780         instead of frame_map_name_to_regnum.
2781         * tracepoint.c: Include "user-regs.h".
2782         (encode_actions): Use user_reg_map_name_to_regnum
2783         instead of frame_map_name_to_regnum.
2784         * valops.c: Include "user-regs.h".
2785         (value_fetch_lazy): Use user_reg_map_regnum_to_name instead
2786         of frame_map_regnum_to_name.
2787
2788 2008-08-21  Ulrich Weigand  <uweigand@de.ibm.com>
2789
2790         * ppc-linux-tdep.c (ppc64_linux_convert_from_func_ptr_addr): Read
2791         and manually relocate .opd contents from BFD instead of reading
2792         them from target memory.
2793
2794 2008-08-21  Daniel Jacobowitz  <dan@codesourcery.com>
2795
2796         * dwarf2read.c (processing_current_prefix): Delete static
2797         variable.
2798         (process_full_comp_unit): Do not set processing_current_prefix.
2799         (dwarf2_full_name): New function.
2800         (read_func_scope): Do not set processing_current_prefix.  Use
2801         determine_prefix.
2802         (read_structure_type): Do not set processing_current_prefix.  Remove
2803         unused inner cleanup.
2804         (process_structure_scope): Do not set processing_current_prefix.
2805         (read_enumeration_type): Use dwarf2_full_name.
2806         (determine_class_name): Return a const char *.  Put the result
2807         on the objfile obstack.  Use dwarf2_full_name.
2808         (read_namespace_type): New function.
2809         (read_namespace): Do not create the type here.  Use
2810         determine_prefix.
2811         (read_typedef): Use dwarf2_full_name.  Do not pass the name
2812         to init_type.
2813         (read_base_type): Do not pass the name to init_type.  Handle
2814         TYPE_FLAG_NOSIGN.
2815         (read_unspecified_type): Do not pass the name to init_type.
2816         (new_symbol): Use dwarf2_full_name instead of
2817         processing_current_prefix.
2818         (read_type_die): Do not set processing_current_prefix.  Handle
2819         DW_TAG_namespace.
2820         (determine_prefix): Handle specifications.  Return the result
2821         on the objfile obstack.  Handle unions correctly.
2822
2823 2008-08-21  Daniel Jacobowitz  <dan@codesourcery.com>
2824
2825         * buildsym.c (add_symbol_to_list): Do not call
2826         cp_scan_for_anonymous_namespaces here.
2827         (finish_block): Do not call cp_set_block_scope here.
2828         * cp-namespace.c (processing_has_namespace_info)
2829         (processing_current_prefix): Delete.
2830         (cp_initialize_namespace): Do not initialize
2831         processing_has_namespace_info.
2832         (cp_scan_for_anonymous_namespaces): Use SYMBOL_DEMANGLED_NAME.  Do
2833         not check processing_has_namespace_info.
2834         (cp_set_block_scope): Take prefix and namespace info flag as
2835         arguments.  Honor namespaces regardless of a demangled name.
2836         * cp-support.h (processing_has_namespace_info)
2837         (processing_current_prefix): Delete declarations.
2838         (cp_set_block_scope): Update prototype.
2839         * dwarf2read.c (processing_has_namespace_info)
2840         (processing_current_prefix): New static variables.
2841         (read_file_scope): Initialize processing_has_namespace_info.
2842         (read_func_scope): Call cp_set_block_scope for C++.
2843         (new_symbol): Call cp_scan_for_anonymous_namespaces for C++.
2844         * symtab.c (symbol_demangled_name): Accept a const argument.
2845         * symtab.h (symbol_demangled_name): Update prototype.
2846
2847 2008-08-21  Daniel Jacobowitz  <dan@codesourcery.com>
2848
2849         * ax-gdb.c (gen_var_ref): Use SYMBOL_LINKAGE_NAME.
2850         * blockframe.c (find_pc_partial_function): Likewise.
2851         * buildsym.c (find_symbol_in_list): Likewise.
2852         * c-valprint.c (c_val_print): Likewise.
2853         * coffread.c (patch_opaque_types, process_coff_symbol): Likewise.
2854         (coff_read_enum_type): Likewise.  Use SYMBOL_SET_LINKAGE_NAME.
2855         * cp-support.c (cp_remove_params): Renamed from remove_params and
2856         made global.
2857         (overload_list_add_symbol): Update call to remove_params.
2858         * cp-support.h (cp_remove_params): Declare.
2859         * dwarf2read.c (process_enumeration_scope): Use SYMBOL_LINKAGE_NAME.
2860         (dwarf2_const_value): Use SYMBOL_PRINT_NAME.
2861         * expprint.c (dump_subexp_body_standard): Likewise.
2862         * f-valprint.c (info_common_command, there_is_a_visible_common_named):
2863         Use SYMBOL_LINKAGE_NAME to find symbols and SYMBOL_PRINT_NAME
2864         for messages.
2865         * findvar.c (read_var_value): Use SYMBOL_LINKAGE_NAME.
2866         * gnu-v2-abi.c (gnuv2_value_rtti_type): Likewise.
2867         * hppa-hpux-tdep.c (hppa32_hpux_in_solib_call_trampoline)
2868         (hppa_hpux_skip_trampoline_code): Use SYMBOL_LINKAGE_NAME to find
2869         symbols and SYMBOL_PRINT_NAME for messages.
2870         * jv-lang.c (add_class_symbol): Use SYMBOL_SET_LINKAGE_NAME.
2871         * linespec.c (decode_line_2): Use SYMBOL_LINKAGE_NAME.
2872         * mdebugread.c (parse_symbol): Use SYMBOL_LINKAGE_NAME and
2873         SYMBOL_SET_LINKAGE_NAME.
2874         (mylookup_symbol): Use SYMBOL_LINKAGE_NAME.
2875         * minsyms.c (add_minsym_to_demangled_hash_table): Use
2876         SYMBOL_SEARCH_NAME.
2877         (lookup_minimal_symbol): Use SYMBOL_LINKAGE_NAME or
2878         SYMBOL_MATCHES_SEARCH_NAME, depending on the pass.
2879         * objfiles.h (ALL_OBJFILE_MSYMBOLS): Use SYMBOL_LINKAGE_NAME.
2880         * printcmd.c (build_address_symbolic): Use SYMBOL_LINKAGE_NAME.
2881         (address_info): Use SYMBOL_PRINT_NAME for messages and
2882         SYMBOL_LINKAGE_NAME for lookups.
2883         * sol-thread.c (info_cb): Use SYMBOL_PRINT_NAME for messages.
2884         * stabsread.c (patch_block_stabs, define_symbol)
2885         (read_type, read_enum_type, common_block_end)
2886         (cleanup_undefined_types_1, scan_file_globals): Use
2887         SYMBOL_LINKAGE_NAME, SYMBOL_SET_LINKAGE_NAME, ALL_OBJFILE_MSYMBOLS,
2888         and SYMBOL_PRINT_NAME.
2889         * stack.c (print_frame_args): Use SYMBOL_LINKAGE_NAME.
2890         (print_frame, frame_info): Use SYMBOL_PRINT_NAME for output.  Use
2891         cp_remove_params instead of cplus_demangle.
2892         (print_block_frame_labels, print_frame_arg_vars): Use
2893         SYMBOL_LINKAGE_NAME.
2894         * symmisc.c (dump_msymbols): Use ALL_OBJFILE_MSYMBOLS and
2895         SYMBOL_LINKAGE_NAME.
2896         (dump_symtab_1, print_symbol, print_partial_symbols)
2897         (maintenance_check_symtabs): Use SYMBOL_LINKAGE_NAME.
2898         * symtab.h (DEPRECATED_SYMBOL_NAME): Delete.
2899         (SYMBOL_SET_LINKAGE_NAME): New.
2900         (SYMBOL_SET_NAMES): Add a comment.
2901         * tracepoint.c (set_traceframe_context, validate_actionline)
2902         (collect_symbol, scope_info): Use SYMBOL_LINKAGE_NAME for
2903         lookups and SYMBOL_PRINT_NAME for output.
2904         * typeprint.c (typedef_print): Use SYMBOL_LINKAGE_NAME.
2905         * xcoffread.c (process_xcoff_symbol): Use SYMBOL_SET_LINKAGE_NAME.
2906
2907 2008-08-21  Pedro Alves  <pedro@codesourcery.com>
2908
2909         * arm-tdep.c (arm_pc_is_thumb): Use obj_section_addr.
2910         * hppa-hpux-tdep.c (hppa_hpux_find_dummy_bpaddr): Likewise.
2911         * hppa-linux-tdep.c (hppa_linux_find_global_pointer): Use
2912         obj_section_addr and obj_section_endaddr.
2913         * hppa-tdep.c (hppa64_convert_code_addr_to_fptr): Likewise.
2914         * hppabsd-tdep.c (hppabsd_find_global_pointer): Likewise.
2915         * ia64-tdep.c (ia64_find_global_pointer): Likewise.
2916         (find_extant_func_descr): Likewise.
2917         * solib-frv.c (frv_relocate_main_executable): Use
2918         obj_section_addr.
2919         * xstormy16-tdep.c (xstormy16_find_jmp_table_entry): Use
2920         obj_section_addr and obj_section_endaddr.
2921
2922 2008-08-21  Paul N. Hilfinger  <hilfinger@adacore.com>
2923
2924         * NEWS: Amplify last entry on boolean types in Ada.
2925
2926 2008-08-20  Daniel Jacobowitz  <dan@codesourcery.com>
2927
2928         * dwarf2read.c (die_specification, dwarf2_extension, follow_die_ref):
2929         Make the dwarf2_cu * parameter output as well as input.  Update it if
2930         we follow a reference to another CU.
2931         (read_func_scope, determine_class_name, namespace_name, dwarf2_attr)
2932         (die_type, die_containing_type): Update calls to changed functions.
2933         Use the returned CU along with the returned DIE.
2934         (read_namespace): Use dwarf2_attr instead of dwarf2_extension.
2935
2936 2008-08-20  Daniel Jacobowitz  <dan@codesourcery.com>
2937
2938         * dwarf2read.c (queue_comp_unit): Take an objfile argument.  Read
2939         in the DIEs here.
2940         (process_queue): Do not read in the DIEs here.
2941         (psymtab_to_symtab_1): Update call to queue_comp_unit.
2942         (read_full_die): Do not call queue_comp_unit from here.
2943         (maybe_queue_comp_unit): New function.
2944         (follow_die_ref): Use it.
2945
2946 2008-08-20  Daniel Jacobowitz  <dan@codesourcery.com>
2947
2948         * dwarf2read.c (struct attribute): Move earlier.
2949         (struct die_info): Change attrs to a trailing array.
2950         (dwarf_alloc_die): Take the number of attributes.  Allocate space
2951         for them.
2952         (read_full_die): Update call to dwarf_alloc_die.  Do not manually
2953         allocate attributes.
2954
2955 2008-08-20  Daniel Jacobowitz  <dan@codesourcery.com>
2956
2957         * dwarf2read.c (REF_HASH_SIZE): Delete.
2958         (struct dwarf2_cu): Replace die_ref_table with die_hash.
2959         (struct die_info): Remove next_ref.
2960         (store_in_ref_table): Remove offset argument.  Rewrite to use
2961         htab_find_slot_with_hash.
2962         (die_hash, die_eq): New.
2963         (read_comp_unit): Allocate the die_hash.
2964         (read_die_and_children): Update call to store_die_ref.
2965         (follow_die_ref): Rewrite to use htab_find_with_hash.
2966
2967 2008-08-20  Daniel Jacobowitz  <dan@codesourcery.com>
2968
2969         * dwarf2read.c (free_die_list, copy_die): Delete.
2970         (dwarf_alloc_die): Take a CU argument.  Allocate the new DIE
2971         on the obstack.
2972         (read_full_die): Update call to dwarf_alloc_die.  Allocate
2973         attributes on the CU obstack.
2974         (free_one_comp_unit): Do not call free_die_list.
2975
2976 2008-08-20  Daniel Jacobowitz  <dan@codesourcery.com>
2977
2978         * dwarf2read.c (read_die_and_children): Ignore NULL DIEs.
2979         (read_die_and_siblings): Likewise.  Do not add padding DIEs to the
2980         sibling list.
2981         (read_full_die): Do not allocate DIEs for abbrev 0.
2982         (follow_die_ref): Correct error message.
2983
2984 2008-08-20  Pedro Alves  <pedro@codesourcery.com>
2985
2986         * linespec.c (symtab_from_filename): Also throw NOT_FOUND_ERROR if
2987         there are no symbols loaded, instead of throwing a generic error.
2988         (decode_variable): Likewise.
2989
2990 2008-08-20  Pedro Alves  <pedro@codesourcery.com>
2991
2992         * objfiles.h (struct obj_section): Remove addr and endaddr fields.
2993         (obj_section_offset, obj_section_addr, obj_section_endaddr): New
2994         macros.
2995         * objfiles.c (add_to_objfile_sections): Don't set addr, endaddr
2996         and offset.  Use size_t instead of unsigned long.
2997         (build_objfile_section_table): Use size_t instead of unsigned
2998         long.
2999         (objfile_relocate): Don't relocate s->addr and s->endaddr, they're
3000         gone.
3001         (find_pc_sect_section): Use obj_section_addr and
3002         obj_section_endaddr.
3003         * symfile.c (symfile.c): Remove code that maps sections
3004         offsets in "addr" to the object's sections.
3005         * blockframe.c (find_pc_partial_function): Use obj_section_endaddr.
3006         * gcore.c (gcore_create_callback): Use obj_section_addr and
3007         obj_section_endaddr.
3008         * maint.c (print_objfile_section_info): Likewise.
3009         * printcmd.c (sym_info): Use obj_section_addr and
3010         obj_section_endaddr.
3011         * symtab.c (fixup_section): Likewise.
3012
3013 2008-08-20  Mark Kettenis  <kettenis@gnu.org>
3014
3015         * sparc-tdep.c: Make some comments catch up with reality.
3016
3017 2008-08-20  Vladimir Prus  <vladimir@codesourcery.com>
3018
3019         * NEWS: Mention 'set target-async'
3020
3021 2008-08-19  Vladimir Prus  <vladimir@codesourcery.com>
3022
3023         * infrun.c (resume): If the thread is placed to the deferred step
3024         queue, mark it as running.
3025
3026 2008-08-19  Vladimir Prus  <vladimir@codesourcery.com>
3027
3028         Make sure target supports non-stop.
3029         * infcmd.c (run_command_1, attach_command): If non-stop mode
3030         is requested, verify the target supports it.
3031         * linux-nat.c (linux_nat_supports_non_stop): New.
3032         (linux_nat_add_target): Register the above.
3033         * target.c (find_default_supports_non_stop)
3034         (target_supports_non_stop): New.
3035         (init_dummy_target): Register find_default_supports_non_stop.
3036         * target.h (struct target_ops): New field to_supports_non_stop.
3037         (target_supports_non_stop): New.
3038
3039 2008-08-19  Pedro Alves  <pedro@codesourcery.com>
3040             Vladimir Prus  <vladimir@codesourcery.com>
3041
3042         * target.c (target_async_permitted, target_async_permitted_1)
3043         (set_maintenance_target_async_permitted)
3044         (show_maintenance_target_async_permitted): New.
3045         (initialize_targets): Register 'set target-async'.
3046         * target.h (target_async_permitted): Declare.
3047         * linux-nat.c (linux_nat_async_enabled)
3048         (linux_nat_async_permitted, set_maintenance_linux_async_permitted)
3049         (show_maintenance_linux_async_permitted): Remove.
3050         (sigchld_handler, linux_nat_is_async_p, linux_nat_can_async_p)
3051         (get_pending_events, linux_nat_async): Use target_async_permitted.
3052         (linux_nat_set_async_mode): Remove, moving the only used bits
3053         into...
3054         (linux_nat_setup_async): This.
3055         (_initialize_linux_nat): Do not register 'maint set linux-async'.
3056         Use linux_nat_setup_async.
3057         * remote.c (remote_async_permitted, remote_async_permitted_set)
3058         (set_maintenance_remote_async_permitted)
3059         (show_maintenance_remote_async_permitted): Remove.
3060         (remote_open_1, remote_terminal_inferior, remote_can_async_p)
3061         (remote_is_async_p): Use target_async_permitted.
3062         (_initialize_remote): Don't register 'main set remote-async'.
3063         * mi/mi-cmds.c (mi_cmds): Register -list-target-features.
3064         * mi/mi-cmds.h (mi_cmd_list_target_features): New.
3065         * mi/mi-main.c (mi_cmd_list_target_features): New.
3066
3067 2008-08-19  Vladimir Prus  <vladimir@codesourcery.com>
3068
3069         * target.c (maybe_kill_then_attach)
3070         (maybe_kill_then_create_inferior): Remove.
3071         (update_current_target): Do not default to_attach,
3072         to_create_inferiour, to_is_async_p.
3073
3074 2008-08-19  Paul N. Hilfinger  <hilfinger@adacore.com>
3075         
3076         Changes for supporting boolean types in debugging data.
3077         * ada-lang.c (discrete_type_high_bound,discrete_type_low_bound): Change 
3078         API to return LONGEST values rather than struct values.
3079         (ada_evaluate_subexp): Change to use new API of discrete_type_low_bound
3080         and discrete_type_high_bound.
3081         (to_fixed_range_type): Create a range type in cases where 
3082         argument is base type and its limits are representable as ints.
3083         (ada_is_modular_type): Correct so that base type must be integral.
3084         * ada-lex.l (TRUEKEYWORD,FALSEKEYWORD): Make 'true' and 'false' 
3085         keywords when they appear alone, since we are phasing out 
3086         direct representation of these identifiers in debugging data.
3087         * ada-exp.y: Define 'true' and 'false' as primaries.
3088         (type_boolean): New function.
3089         (type_int,type_long,type_long_long,type_floattype_double)
3090         (type_long_double): Remove uses of current_gdbarch for consistency
3091         with type_boolean.
3092         (write_int): Change comment to indicate that it might write boolean 
3093         constant as well.
3094         * ada-typeprint.c (ada_print_type): Print '(false, true)' for boolean
3095         type, since will no longer be represented as enumerated type in 
3096         debugging data.
3097         * ada-valprint.c (print_optional_low_bound): Handle boolean case
3098         as well.
3099         * NEWS: Note support boolean types.
3100         
3101 2008-08-18  Pedro Alves  <pedro@codesourcery.com>
3102
3103         * bsd-uthread.c (bsd_uthread_close): New.
3104         (bsd_uthread_deactivate): Don't cleanup here, just unpush the
3105         target.
3106         (bsd_uthread_solib_loaded): Fix typo.
3107         (bsd_uthread_target): Register bsd_uthread_close.
3108
3109 2008-08-18  Pedro Alves  <pedro@codesourcery.com>
3110
3111         * corelow.c (core_open): Assume there was no upper layer left
3112         behind from a previous inferior.
3113         * target.c (pop_all_targets): Rename to ...
3114         (pop_all_targets_above): ... this.  Add a target stratum
3115         parameter.  Use it instead of hardcoding the dummy_stratum.
3116         (pop_all_targets): New, defer to pop_all_targets_above.
3117         (target_preopen): Use pop_all_targets_above.
3118         * target.h (pop_all_targets_above): Declare.
3119
3120 2008-08-18  Pedro Alves  <pedro@codesourcery.com>
3121
3122         * gdbthread.h (thread_change_ptid): Declare.
3123         * infrun.c (infrun_thread_ptid_changed): New.
3124         (_initialize_infrun): Attach infrun_thread_ptid_changed to the
3125         thread_ptid_changed observer.
3126         * regcache.c (regcache_thread_ptid_changed): New.
3127         (_initialize_regcache): Attach regcache_thread_ptid_changed to the
3128         thread_ptid_changed observer.
3129         * thread.c (thread_change_ptid): New.
3130
3131 2008-08-18  Tom Tromey  <tromey@redhat.com>
3132
3133         * symfile.c (reread_symbols): Update.
3134         * solib-sunos.c (allocate_rt_common_objfile): Update.
3135         * objfiles.c (allocate_objfile): Update.
3136         * objfiles.h (struct objfile) <md, mmfd, deprecated_obj_private>:
3137         Remove.
3138
3139 2008-08-18  Tom Tromey  <tromey@redhat.com>
3140
3141         * gdbtypes.c (copy_type_recursive): Allocate 'stored' on objfile's
3142         obstack.
3143
3144 2008-08-18  Daniel Jacobowitz  <dan@codesourcery.com>
3145
3146         * rs6000-tdep.c (struct rs6000_framedata): Add gpr_mask, used_bl,
3147         lr_register.
3148         (rs6000_in_function_epilogue_p): Check for bctr.
3149         (skip_prologue): Initialize lr_register.  Set lr_reg to a register
3150         number.  Set gpr_mask and used_bl.  Continue scanning while some
3151         expected registers are not saved.  Set lr_register if LR is not
3152         stored.
3153         (rs6000_frame_cache): Handle gpr_mask and lr_register.
3154
3155 2008-08-17  Tom Tromey  <tromey@redhat.com>
3156
3157         PR gdb/1535:
3158         * breakpoint.c (CATCH_PERMANENT, CATCH_TEMPORARY): New macros.
3159         (ep_find_event_name_end): Remove.
3160         (catch_fork_temporary, catch_vfork_temporary,
3161         catch_fork_permanent, catch_vfork_permanent): New constants.
3162         (catch_vfork, catch_fork): Remove.
3163         (catch_fork_command_1): Add 'command' argument.  Remove
3164         'fork_kind' and 'tempflag'.  Handle NULL 'arg'.  Update switch for
3165         all cases.
3166         (catch_exec_command_1): Add 'command' argument; remove
3167         'tempflag'.  Handle NULL 'arg'.
3168         (catch_load_command_1): Likewise.
3169         (catch_unload_command_1): Likewise.
3170         (catch_ada_exception_command): Likewise.
3171         (catch_assert_command): Likewise.
3172         (catch_catch_command): New function.
3173         (catch_throw_command): Likewise.
3174         (catch_command_1): Remove.
3175         (catch_command): Just call error.
3176         (tcatch_command): Likewise.
3177         (catch_cmdlist): New global.
3178         (tcatch_cmdlist): Likewise.
3179         (add_catch_command): New function.
3180         (_initialize_breakpoint): Create "catch" and "tcatch" as prefix
3181         commands.  Create all catch sub-commands.
3182
3183 2008-08-17  Pedro Alves  <pedro@codesourcery.com>
3184
3185         * gdbthread.h: Add comments.
3186         * stack.c (get_selected_block): Return 0 on an exited thread.
3187         * top.c (execute_command): Check for is_stopped, not !is_running.
3188         * event-top.c (command_handler): Likewise.
3189
3190 2008-08-16  Pedro Alves  <pedro@codesourcery.com>
3191
3192         * mi/mi-main.c (mi_cmd_exec_next, mi_cmd_exec_next_instruction)
3193         (mi_cmd_exec_step, mi_cmd_exec_step_instruction)
3194         (mi_cmd_exec_finish): Remove "return".
3195
3196 2008-08-16  Pedro Alves  <pedro@codesourcery.com>
3197
3198         * target.h (pop_all_targets): Declare.
3199         * target.c (pop_all_targets): New.
3200         * top.c (quit_target): Pop all targets instead of just closing the
3201         current.
3202
3203 2008-08-16  Vladimir Prus  <vladimir@codesourcery.com>
3204             Thiago Jung Bauermann  <bauerman@br.ibm.com>
3205
3206         * cli-script.c (read_next_line): Add parse_commands argument.
3207         (recurse_read_control_structure): Adapt to new read_next_line
3208         signature.
3209         (read_command_lines): Add parse_commands argument.
3210         (define_command): Adapt to new read_command_lines signature.
3211         (document_command): Likewise.
3212         * breakpoint.c (commands_command): Likewise.
3213         * defs.h (read_command_lines): Adjust function prototype.
3214
3215 2008-08-16  Paul N. Hilfinger  <hilfinger@adacore.com>
3216
3217         * ada-lang.c (pos_atr): Account for the possibility that the 
3218         argument may be a reference.
3219
3220 2008-08-16  Paul N. Hilfinger  <hilfingr@adacore.com>
3221
3222         * xcoffread.c (scan_xcoff_symtab): Do not include global symbols
3223         ('F' format) for @FIX names generated by the loader, retaining only
3224         the minimal symbols (and no partial symbol tables) for these names.
3225         Fixes warning messages about symbols that are found in partial 
3226         symbol tables, but not full symbol tables.
3227
3228 2008-08-16  Pedro Alves  <pedro@codesourcery.com>
3229
3230         * infrun.c (fetch_inferior_event): Only call normal_stop if not
3231         stopping quietly.
3232
3233 2008-08-15  Luis Machado  <luisgpm@br.ibm.com>
3234
3235         * rs6000-tdep: Include "features/rs6000/powerpc-vsx32.c".
3236         Include "features/rs6000/powerpc-vsx64.c".
3237         (ppc_supply_vsxregset): New function.
3238         (ppc_collect_vsxregset): New function.
3239         (IS_VSX_PSEUDOREG): New macro.
3240         (IS_EFP_PSEUDOREG): New macro.
3241         (vsx_register_p): New function.
3242         (ppc_vsx_support_p): New function.
3243         (rs6000_builtin_type_vec128): New function.
3244         (rs6000_register_name): Hide upper halves of vs0~vs31.  Return
3245         correct names for VSX registers and EFPR registers.
3246         (rs6000_pseudo_register_type): Return correct types for VSX
3247         and EFPR registers.
3248         (rs6000_pseudo_register_reggroup_p): Return correct group for
3249         VSX and EFPR registers.
3250         (ppc_pseudo_register_read): Rename to dfp_pseudo_register_read.
3251         (ppc_pseudo_register_write): Rename to dfp_pseudo_register_write.
3252         (vsx_pseudo_register_read): New function.
3253         (vsx_pseudo_register_write): New function.
3254         (efpr_pseudo_register_read): New function.
3255         (efpr_pseudo_register_write): New function.
3256         (rs6000_pseudo_register_read): Call new VSX and EFPR read functions.
3257         (rs6000_pseudo_register_write): Call new VSX and EFPR write functions.
3258         (rs6000_gdbarch_init): Declare have_vsx.
3259         Initialize new upper half VSX registers.
3260         Initialize VSX-related and EFPR-related pseudo-registers variables.
3261         Adjust the number of pseudo registers accordingly.
3262
3263         * ppc-linux-nat.c: Define PTRACE_GETVSXREGS, PTRACE_SETVSXREGS
3264         and SIZEOF_VSRREGS.
3265         (gdb_vsxregset_t): New type.
3266         (have_ptrace_getsetvsxregs): New variable.
3267         (fetch_vsx_register): New function.
3268         (fetch_register): Handle VSX registers.
3269         (fetch_vsx_registers): New function.
3270         (fetch_ppc_registers): Handle VSX registers.
3271         (store_ppc_registers): Handle VSX registers.
3272         (store_vsx_register): New function.
3273         (store_register): Handle VSX registers.
3274         (store_vsx_registers): New function.
3275         (ppc_linux_read_description): Handle VSX-enabled inferiors.
3276         (gdb_vsxregset_t): New type.
3277         (supply_vsxregset): New function.
3278         (fill_vsxregset): New function.
3279
3280         * ppc-tdep.h (vsx_register_p): New prototype.
3281         (vsx_support_p): New prototype.
3282         (ppc_vsr0_regnum): New variable.
3283         (ppc_vsr0_upper_regnum): Likewise.
3284         (ppc_efpr0_regnum): Likewise.
3285         (ppc_builtin_type_vec128): New type.
3286         (ppc_num_vsrs): New constant.
3287         (ppc_num_vshrs): New constant.
3288         (ppc_num_efprs): Likewise.
3289         Define POWERPC_VEC_VSX PPC_VSR0_UPPER_REGNUM and PPC_VSR31_UPPER_REGNUM.
3290         (ppc_supply_vsxregset): New prototype.
3291         (ppc_collect_vsxregset): New prototype.
3292
3293         * ppc-linux-tdep.c: Include "features/rs6000/powerpc-vsx32l.c"
3294         Include "features/rs6000/powerpc-vsx64l.c".
3295         (_initialize_ppc_linux_tdep): Initialize VSX-enabled targets.
3296         (ppc_linux_regset_sections): Add new ".reg-ppc-vsx" field.
3297         (ppc32_linux_vsxregset): New 32-bit VSX-enabled regset.
3298         (ppc_linux_regset_from_core_section): Handle VSX core section.
3299         (ppc_linux_core_read_description): Support VSX-enabled core files.
3300
3301         * ppc-linux-tdep.h: Declare *tdesc_powerpc_vsx32l
3302         Declare tdesc_powerpc_vsx64l
3303
3304         * corelow.c (get_core_register_section): Support VSX-enabled
3305         core files.
3306
3307         * features/rs6000/power-vsx.xml: New VSX descriptions.
3308         * features/rs6000/powerpc-vsx32.xml: New file.
3309         * features/rs6000/powerpc-vsx32l.xml: New file.
3310         * features/rs6000/powerpc-vsx64.xml: New file.
3311         * features/rs6000/powerpc-vsx64l.xml: New file.
3312         * features/rs6000/powerpc-vsx32.c: New file (generated).
3313         * features/rs6000/powerpc-vsx32l.c: New file (generated).
3314         * features/rs6000/powerpc-vsx64.c: New file (generated).
3315         * features/rs6000/powerpc-vsx64l.c: New file (generated).
3316         * features/Makefile: Updated with new descriptions.
3317         * regformats/rs6000/powerpc-vsx32l.dat: New file (generated).
3318         * regformats/rs6000/powerpc-vsx64l.dat: New file (generated).
3319
3320 2008-08-15  Vladimir Prus  <vladimir@codesourcery.com>
3321
3322         * ia64-linux.nat (_initialize_ia64_linux_nat): Don't
3323         call linux_target twice.
3324
3325 2008-08-14  Aleksandar Ristovski  <aristovski@qnx.com>
3326
3327         * nto-tdep.c (lm_info): Updated struct lm_info definition from
3328         solib-svr4.c
3329         (LM_ADDR): Use l_addr if available; if not, use link map and set 
3330         l_addr.
3331
3332 2008-08-14  Tom Tromey  <tromey@redhat.com>
3333
3334         * macrocmd.c (macro_define_command): Check for NULL argument.
3335         (macro_undef_command): Likewise.
3336
3337 2008-08-14  Pedro Alves  <pedro@codesourcery.com>
3338
3339         * infcmd.c (continue_1): Add an ERROR_NO_INFERIOR call.
3340
3341 2008-08-13  Pedro Alves  <pedro@codesourcery.com>
3342
3343         * breakpoint.c (always_inserted_auto, always_inserted_on)
3344         (always_inserted_off, always_inserted_enums): New.
3345         (always_inserted_mode): Change type to char* and point to
3346         always_inserted_auto.
3347         (show_always_inserted_mode): In auto mode, also show the current
3348         effect of the option.
3349         (breakpoints_always_inserted_mode): Adjust for the new auto mode.
3350         (_initialize_breakpoint): Make the "set breakpoints
3351         always-inserted" command an enum command.  Extend help to describe
3352         the auto mode.
3353
3354 2008-08-13  Ulrich Weigand  <uweigand@de.ibm.com>
3355
3356         * spu-tdep.c (info_spu_dma_command): Respect TSQV (tag status
3357         query valid) bit.  Ignore bits outside the condition field.
3358         (info_spu_proxydma_command): Ignore bits outside the field.
3359
3360 2008-08-12  Michael Snyder  <msnyder@vmware.com>
3361
3362         * MAINTAINERS: Update my email address.
3363
3364 2008-08-12  Ulrich Weigand  <uweigand@de.ibm.com>
3365
3366         * ppc-linux-nat.c (ppc_linux_get_hwcap): Really get AT_HWCAP.
3367
3368 2008-08-12  Pedro Alves  <pedro@codesourcery.com>
3369
3370         Add no-ack mode to the remote protocol --- optionally stop ACKing
3371         packets and responses when we have a reliable communication
3372         medium.
3373
3374         Based on Apple's GDB, by Jason Molenda <jmolenda@apple.com>
3375
3376         * remote.c (struct remote_state): Add noack_mode field.
3377         (PACKET_QStartNoAckMode): New.
3378         (remote_start_remote): Don't any outstanding packet here.
3379         (remote_open_1): Clear noack_mode.  Ack any outstanding packet
3380         here.  Activate noack mode if requested.
3381         (remote_protocol_features): Add QStartNoAckMode.
3382         (remote_open_1):
3383         (putpkt_binary): Don't send ack in noack mode.
3384         (read_frame): Don't recompute the checksum in noack mode.
3385         (getpkt_sane): Skip sending ack if in noack mode.
3386         (_initialize_remote): Add set/show remote noack mode.
3387         * NEWS:  Note the new features.
3388
3389 2008-08-11  Kevin Buettner  <kevinb@redhat.com>
3390
3391         * rs6000-tdep.c (BL_MASK, BL_INSTRUCTION, BL_DISPLACEMENT_MASK):
3392         New macros.
3393         (rs6000_skip_main_prologue): New function.
3394         (rs6000_gdb_arch_init): Register rs6000_skip_main_prologue.
3395
3396 2008-08-11  Sandra Loosemore  <sandra@codesourcery.com>
3397
3398         * MAINTAINERS (Write After Approval):  Add self.
3399
3400 2008-08-11  Stan Shebs  <stan@codesourcery.com>
3401
3402         ARM BE8 support.
3403         * disasm.c (gdb_disassemble_info): Set endian_code.
3404         * gdbarch.sh (gdbarch_info): New field byte_order_for_code.
3405         * gdbarch.h, gdbarch.c: Regenerate.
3406         * arch-utils.c (initialize_current_architecture): Set the
3407         default byte_order_for_code.
3408         (gdbarch_info_init): Ditto.
3409         (gdbarch_info_fill): Ditto.
3410         * arm-tdep.c (SWAP_INT, SWAP_SHORT): New macros.
3411         (thumb_analyze_prologue): Swap halfword if code endianness is
3412         different from general endianness.
3413         (arm_skip_prologue): Similarly.
3414         (arm_scan_prologue): Ditto.
3415         (thumb_get_next_pc): Ditto.
3416         (arm_get_next_pc): Ditto.
3417         (arm_gdbarch_init): Set byte_order_for_code from BE8 flag,
3418         choose correct endianness for breakpoints.
3419
3420 2008-08-10  Pedro Alves  <pedro@codesourcery.com>
3421
3422         * bsd-kvm.c: Include "gdbthread.h".
3423         (bsd_kvm_ptid): New.
3424         (bsd_kvm_open): Add a main thread.
3425         (bsd_kvm_close): Delete it.
3426         (bsd_kvm_thread_alive): New.
3427         (bsd_kvm_pid_to_str): New.
3428         (bsd_kvm_add_target): Register bsd_kvm_thread_alive and
3429         bsd_kvm_pid_to_str.
3430         (bsd_kvm_add_target): Initialize bsd_kvm_ptid.
3431
3432 2008-08-09  Pedro Alves  <pedro@codesourcery.com>
3433
3434         * buildsym.c (start_subfile): Properly cast sentinel in concat
3435         call.
3436         * cp-name-parser.y: Include "config.h".
3437         * xml-tdesc.c (fetch_xml_from_file): Properly cast sentinel in
3438         concat call.
3439         * gdb_select.h: Include sys/time.h if sys/select.h is not
3440         available.
3441
3442 2008-08-09  Pedro Alves  <pedro@codesourcery.com>
3443
3444         * go32-nat.c: Include "gdbthread.h".
3445         (go32_stop, go32_kill_inferior): Delete the main thread.
3446         (go32_create_inferior): Add it.
3447         (go32_thread_alive, go32_pid_to_str): New.
3448         (init_go32_ops): Register go32_thread_alive and go32_pid_to_str.
3449
3450 2008-08-09  Pedro Alves  <pedro@codesourcery.com>
3451
3452         * go32-nat.c (fetch_register, store_register): Pass the regcache
3453         gdbarch to i386_fp_regnum_p and i386_fpc_regnum_p.
3454         (go32_xfer_memory): Change type of myaddr parameter to gdb_byte.
3455         (struct seg_descr, struct seg_descr): pack the whole struct
3456         instead of each member individually.
3457
3458 2008-08-09  Andreas Schwab  <schwab@suse.de>
3459
3460         * python/python.c (_initialize_python): Use unabbreviated commands
3461         in prefix name.
3462
3463 2008-08-09  Daniel Jacobowitz  <dan@codesourcery.com>
3464
3465         * Makefile.in (stamp-h): Also create .deps.
3466
3467 2008-08-09  Tom Tromey  <tromey@redhat.com>
3468
3469         * Makefile.in (generated_files): Add GNULIB_H.
3470
3471 2008-08-09  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
3472
3473         * solib-pa64.c (pa64_solib_create_inferior_hook): Don't set
3474         DT_HP_DEBUG_PRIVATE.  Add warning if DT_HP_DEBUG_PRIVATE is not set.
3475         Revise comment.
3476         (pa64_current_sos): Remove map private warning warning.
3477         * solib-som.c: Include string.h and sys/utsname.h.
3478         (get_hpux_major_release): New function.
3479         (som_solib_create_inferior_hook): Read dynamic linker header.  Warn
3480         about shared library private mapping on HP-UX 11 and later.  Only force
3481         private mapping of shared libraries on HP-UX 10 and earlier.
3482         (link_map_start): Delete warning.
3483
3484 2008-08-09  Xuepeng Guo  <xuepeng.guo@intel.com>
3485             H.J. Lu  <hongjiu.lu@intel.com>
3486             Mark Kettenis <kettenis@gnu.org>
3487
3488         * amd64-tdep.c (amd64_frame_cache): Add saved_sp_reg.
3489         (amd64_init_frame_cache): Initialize saved_sp_reg.
3490         (amd64_analyze_stack_align): New.
3491         (amd64_analyze_prologue): Call it.
3492         (amd64_frame_cache): Use saved_sp_reg if it is invalid.  Don't set
3493         %rip to 8 when halfway aligning the stack.
3494
3495         * amd64-tdep.h (amd64_regnum): Add AMD64_R9_REGNUM to
3496         AMD64_R14_REGNUM.
3497
3498         * i386-tdep.c (i386_frame_cache): Remove stack_align.  Add
3499         saved_sp_reg.
3500         (i386_alloc_frame_cache): Remove stack_align.  Initialize
3501         saved_sp_reg to -1.
3502         (i386_analyze_stack_align): Rewrite.
3503         (i386_frame_cache): Use saved_sp_reg if it is valid.
3504
3505 2008-08-09  Ulrich Weigand  <uweigand@de.ibm.com>
3506
3507         * target.c: Include "solib.h".
3508         (target_pre_inferior): Call no_shared_libraries.
3509         * infcmd.c (run_command_1): Do not call objfile_purge_solibs
3510         or clear_solib.
3511         (attach_command): Do not call clear_solib.
3512
3513 2008-08-09  Mark Kettenis  <kettenis@gnu.org>
3514
3515         * i386obsd-nat.c (i386obsd_supply_pcb): Supply the right bytes for
3516         the %eip register.
3517
3518 2008-08-08  Tom Tromey  <tromey@redhat.com>
3519
3520         * Makefile.in (python.o): Remove dependencies.  Use COMPILE and
3521         POSTCOMPILE.
3522         (python-utils.o): Likewise.
3523
3524 2008-08-08  Andreas Schwab  <schwab@suse.de>
3525
3526         * corefile.c (_initialize_core): Remove spurious paren from set
3527         gnutarget doc string.
3528
3529 2008-08-08  Luis Machado  <luisgpm@br.ibm.com>
3530
3531         * ppc-linux-nat.c: Include "auxv.h" and "elf/common.h".
3532         Define PPC_FEATURE_BOOKE.
3533         (ppc_linux_get_hwcap): New function.
3534         (ppc_linux_region_ok_for_hw_watchpoint): Handle PowerPC 440
3535         4-bytes alignment restrictions.
3536         (ppc_linux_insert_watchpoint): Handle PowerPC 440-specific
3537         positioning of the read/write flags.
3538         (ppc_linux_watchpoint_addr_within_range): Handle PowerPC 440
3539         4-bytes alignment.
3540
3541 2008-08-08  Pedro Alves  <pedro@codesourcery.com>
3542
3543         Use ptid_t.tid to store thread ids instead of ptid_t.pid.
3544
3545         * win32-nat.c (win32_add_thread): Change thread argument type to
3546         ptid_t.  Adjust.
3547         (win32_add_thread): Adjust.
3548         (win32_delete_thread): Change thread argument type to ptid_t.
3549         Adjust.
3550         (win32_fetch_inferior_registers, win32_store_inferior_registers)
3551         (win32_resume, get_win32_debug_event, get_win32_debug_event)
3552         (win32_wait, win32_pid_to_exec_file, win32_pid_to_str): Adjust.
3553         (init_win32_ops): Put to_magic last.
3554         (win32_win32_thread_alive): Adjust.
3555
3556 2008-08-08  Pedro Alves  <pedro@codesourcery.com>
3557
3558         * remote-m32r-sdi.c (m32r_thread_alive, m32r_pid_to_str): New.
3559         (init_m32r_ops): Register m32r_thread_alive and m32r_pid_to_str.
3560
3561 2008-08-08  Pedro Alves  <pedro@codesourcery.com>
3562
3563         * remote-m32r-sdi.c: Include "gdbthread.h".
3564         (remote_m32r_ptid): New.
3565         (m32r_close): Delete the main thread.
3566         (m32r_resume): Set inferior_ptid toA remote_m32r_ptid. Add the
3567         main thread.
3568         (m32r_kill, m32r_load, sdireset_command): Delete the main thread.
3569         (_initialize_remote_m32r): Initialize remote_m32r_ptid.
3570
3571 2008-08-07  Tom Tromey  <tromey@redhat.com>
3572             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3573
3574         * aclocal.m4, configure: Rebuild.
3575         * configure.in: Call ZW_CREATE_DEPDIR,
3576         ZW_PROG_COMPILER_DEPENDENCIES, AC_PROG_MAKE_SET.
3577         (MAKE, GMAKE): New substs.
3578         * acinclude.m4: Include depstand.m4.
3579         * Makefile.in (DEPMODE, DEPDIR, COMPILE.post, COMPILE.pre,
3580         COMPILE, POSTCOMPILE, depcomp): New variables.
3581         Remove all _h variables.
3582         Remove many .o targets.
3583         ($(srcdir)/copying.c): avoid backslash-newline after comment
3584         sign (@maintainer_mode_true@).
3585         (HFILES_NO_SRCDIR): Regenerate.
3586         (generated_files): New variable.
3587         (all_gdbtk_cflags): Likewise.
3588         (.c.o): Rewrote.
3589         (init.o, version.o, copying.o): Remove.
3590         (distclean): Remove DEPDIR.
3591         (test-cp-name-parser.o, hpux-thread.o, main.o, monitor.o,
3592         printcmd.o, procfs.o, v850ice.o): Rewrite.
3593         (cli-cmds.o, cli-decode.o, cli-dump.o, cli-interp.o, cli-logging.o,
3594         cli-script.o, cli-setshow.o, cli-utils.o): Likewise.
3595         (gdbtk.o, gdbtk-bp.o, gdbtk-cmds.o, gdbtk-hooks.o, gdbtk-interp.o,
3596         gdbtk-main.o, gdbtk-register.o, gdbtk-stack.o, gdbtk-varobj.o,
3597         gdbtk-wrapper.o): Likewise.
3598         (mi-cmd-break.o, mi-cmd-disas.o, mi-cmd-env.o, mi-cmd-file.o,
3599         mi-cmds.o, mi-cmd-stack.o, mi-cmd-target.o, mi-cmd-var.o,
3600         mi-console.o, mi-getopt.o, mi-interp.o, mi-main.o, mi-out.o,
3601         mi-parse.o, mi-symbol-cmds.o, mi-common.o, signals.o, tui.o,
3602         tui-command.o, tui-data.o, tui-disasm.o, tui-file.o, tui-hooks.o,
3603         tui-interp.o, tui-io.o, tui-layout.o, tui-main.o, tui-out.o,
3604         tui-regs.o, tui-source.o, tui-stack.o, tui-win.o, tui-windata.o,
3605         tui-wingeneral.o, tui-winsource.o): Likewise.
3606         (all_object_files): New variable.
3607         ($(all_object_files)): New target.
3608         Include dependency files, when using GNU Make.
3609
3610 2008-08-07  Ulrich Weigand  <uweigand@de.ibm.com>
3611
3612         * spu-tdep.c (info_spu_dma_cmdlist): Only show entries with
3613         the valid bit set.  Ensure display order respects partial
3614         order defined by dependency bits.
3615
3616 2008-08-06  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
3617
3618         * solib-pa64.c (read_dld_descriptor): Return zero if load map is not
3619         setup.
3620
3621 2008-08-06  Mark Kettenis  <kettenis@gnu.org>
3622
3623         * i386obsd-nat.c (i386obsd_supply_pcb): Adjust for changes in
3624         OpenBSD 4.3.
3625
3626 2008-08-06  Vladimir Prus  <vladimir@codesourcery.com>
3627             Tom Tromey  <tromey@redhat.com>
3628             Thiago Jung Bauermann  <bauerman@br.ibm.com>
3629             Doug Evans  <dje@google.com>
3630
3631         * Makefile.in (SUBDIR_PYTHON_OBS, SUBDIR_PYTHON_SRCS,
3632         SUBDIR_PYTHON_DEPS, SUBDIR_PYTHON_LDFLAGS, SUBDIR_PYTHON_CFLAGS,
3633         PYTHON_CFLAGS): New.
3634         (python_h, python_internal_h): New.
3635         (cli-script.o): Depend on python.h
3636         (python.o, python-utils.o): New.
3637         * cli/cli-script.c (print_command_lines): Handle python_control.
3638         (execute_control_command): Handle python_control.
3639         (execute_control_command_untraced): New function.
3640         (while_command): Call execute_control_command_untraced.
3641         (if_command): Likewise.
3642         (get_command_line): Remove static attribute.
3643         (read_next_line): Handle "python".
3644         (recurse_read_control_structure): Handle python_control.
3645         (read_command_lines): Handle python_control.
3646         Include python.h.
3647         * cli/cli-script.h (get_command_line): Add prototype.
3648         (execute_control_command_untraced): Likewise.
3649         * configure.ac: Add --with-python.
3650         * defs.h (enum command_control_type) <python_control>: New
3651         constant.
3652         * python/python-internal.h: New file.
3653         * python/python.c: New file.
3654         * python/python.h: New file.
3655         * python/python-utils.c: New file.
3656         * NEWS: Mention Python scripting support and its new commands.
3657
3658 2008-08-06  Ulrich Weigand  <uweigand@de.ibm.com>
3659
3660         * spu-tdep.c (spu_gdbarch_init): Call set_gdbarch_frame_red_zone_size.
3661
3662 2008-08-06  Phil Muldoon  <pmuldoon@redhat.com>
3663
3664         * MAINTAINERS (Write After Approval): Add self.
3665
3666 2008-08-06  Phil Muldoon  <pmuldoon@redhat.com>
3667
3668         * breakpoint.c (hw_breakpoint_used_count): Use breakpoint_enabled.
3669         (insert_breakpoint_locations): Likewise.
3670
3671 2008-08-05  Phil Muldoon  <pmuldoon@redhat.com>
3672
3673         * breakpoint.c (create_longjmp_breakpoint): Remove unused struct
3674         breakpoint.
3675         (set_longjmp_breakpoint): Likewise.
3676
3677 2008-08-04  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
3678
3679         PR build/2490
3680         * solib-pa64.c: Only compile if both HAVE_ELF_HP_H and __LP64__ are
3681         defined.
3682
3683 2008-08-05  Tom Tromey  <tromey@redhat.com>
3684
3685         * bcache.c (deprecated_bcache_added): Initialize obstack.
3686         (bcache_xmalloc): Don't initialize obstack.
3687         (bcache_xfree): Conditionally free obstack.
3688         (bcache_memory_used): Update.
3689
3690 2008-08-05  Tom Tromey  <tromey@redhat.com>
3691
3692         * symfile.c (add_psymbol_to_bcache): Return a const pointer.  Use
3693         bcache_full.
3694         (append_psymbol_to_list): Accept a const pointer.
3695         (add_psymbol_to_list): Fix const correctness.
3696         * bcache.h: (deprecated_bcache_added, deprecated_bcache): Remove.
3697         (bcache_full): Declare.
3698         * bcache.c (bcache_data, deprecated_bcache): Remove.
3699         (bcache): Use bcache_full.
3700         (bcache_full): Rename from deprecated_bcache_added.  Change return
3701         type.
3702
3703 2008-08-04  Stan Shebs  <stan@codesourcery.com>
3704
3705         * solib-svr4.c (BKPT_AT_SYMBOL): Remove, always defined.
3706         (bkpt_names): Remove SOLIB_BKPT_NAME, never defined.
3707         (enable_break): Remove test of BKPT_AT_SYMBOL.
3708
3709 2008-08-02  Keith Seitz  <keiths@redhat.com>
3710
3711         * acinclude.m4: Include ../config/tcl.m4 to pick up
3712         standard Tcl configury bits.
3713         Remove all Tcl, Tk, Itcl, Itk, etc definitions.
3714         * configure.ac: Don't check if ../itcl exists when building
3715         gdbtk. It could be installed.
3716         Rewrite gdbtk configury to allow for using system-supplied
3717         Tcl and Tk. Gdbtk no longer requires build-time access to
3718         itcl and itk.
3719         * Makefile.in: Remove everything related to itcl and itk.
3720         Rewrite the Tcl bits for gdbtk to correspond to rewrite of
3721         configure.ac.
3722         Remove v850ice.o build rule.
3723         (ALL_TCL_CFLAGS): New convenience defintion. Change all
3724         gdbtk sources to use it.
3725         * configure: Regenerate.
3726
3727 2008-07-31  Stan Shebs  <stan@codesourcery.com>
3728
3729         * coffread.c (coff_symtab_read): Remove FUNCTION_EPILOGUE_SIZE.
3730
3731 2008-07-30  Stan Shebs  <stan@codesourcery.com>
3732
3733         * objfiles.c (TARGET_KEEP_SECTION): Remove.
3734         (add_to_objfile_sections): Remove use.
3735
3736 2008-07-29  Tom Tromey  <tromey@redhat.com>
3737
3738         * cli/cli-decode.c (lookup_cmd_1): Use memcpy.
3739         (lookup_cmd_composition): Likewise.
3740
3741 2008-07-29  Tom Tromey  <tromey@redhat.com>
3742
3743         * cli/cli-cmds.c (edit_command): Remove unused variables.  Delete
3744         dead code.  Fix indentation.
3745
3746 2008-07-29  Stan Shebs  <stan@codesourcery.com>
3747
3748         * main.c (captured_main): Remove long-unused #if 0 blocks.
3749
3750 2008-07-28  Tom Tromey  <tromey@redhat.com>
3751
3752         * annotate.h (deprecated_annotate_starting_hook): Remove.
3753         (deprecated_annotate_stopped_hook): Remove.
3754         (deprecated_annotate_exited_hook): Remove.
3755         * Makefile.in (annotate.o): Depend on observer_h.
3756         * top.c (deprecated_delete_breakpoint_hook): Remove.
3757         (deprecated_create_breakpoint_hook): Likewise.
3758         (deprecated_modify_breakpoint_hook): Likewise.
3759         * interps.c (clear_interpreter_hooks): Update for removed hooks.
3760         * breakpoint.c (mention): Don't call removed hook.
3761         (delete_breakpoint): Likewise.
3762         (disable_breakpoint): Likewise.
3763         (do_enable_breakpoint): Likewise.
3764         * annotate.c: Include observer.h.
3765         (breakpoint_changed): Change type of argument.
3766         (_initialize_annotate): Register observers.
3767         (deprecated_annotate_starting_hook): Remove.
3768         (deprecated_annotate_stopped_hook): Remove.
3769         (deprecated_annotate_exited_hook): Remove.
3770         (annotate_starting): Update for hook removal.
3771         (annotate_stopped): Likewise.
3772         (annotate_exited): Likewise.
3773         * defs.h (deprecated_delete_breakpoint_hook): Remove.
3774         (deprecated_create_breakpoint_hook): Likewise.
3775         (deprecated_modify_breakpoint_hook): Likewise.
3776
3777 2008-07-28  Tom Tromey  <tromey@redhat.com>
3778
3779         * main.c (captured_main): Don't use BEFORE_MAIN_LOOP_HOOK.
3780
3781 2008-07-27  Daniel Jacobowitz  <dan@codesourcery.com>
3782
3783         * configure.ac: Check for the GNU/Linux ptrace signature.
3784         * configure: Regenerated.
3785
3786 2008-07-27  Daniel Jacobowitz  <dan@codesourcery.com>
3787
3788         * linux-nat.c (resume_callback): Add more debugging output.
3789         (linux_nat_has_pending_sigint): New function, based on
3790         linux_nat_has_pending.
3791         (set_ignore_sigint, maybe_clear_ignore_sigint): New functions.
3792         (stop_wait_callback): Remove flush_mask handling.  Honor
3793         ignore_sigint.  Call maybe_clear_ignore_sigint.  Pass NULL
3794         to recursive calls.
3795         (linux_nat_has_pending, flush_callback): Remove.
3796         (linux_nat_filter_event): Check for ignore_sigint.
3797         (linux_nat_wait): Remove flush_mask support and call to
3798         flush_callback.  Use set_ignore_sigint and maybe_clear_ignore_sigint.
3799         * linux-nat.h (struct lwp_info): Add ignore_sigint field.
3800
3801 2008-07-27  Daniel Jacobowitz  <dan@codesourcery.com>
3802
3803         * linux-nat.c (count_events_callback, select_event_lwp_callback): Only
3804         report events from resumed threads.
3805
3806 2008-07-27  Daniel Jacobowitz  <dan@codesourcery.com>
3807
3808         * mips-linux-tdep.c (mips_linux_syscall_next_pc): New function.
3809         (mips_linux_init_abi): Set tdep->syscall_next_pc.
3810         * mips-tdep.c (enum mips_fpu_type, struct gdbarch_tdep): Move to
3811         mips-tdep.h.
3812         (mips32_next_pc): Handle the syscall instruction.
3813         * mips-tdep.h (enum mips_fpu_type, struct gdbarch_tdep): New,
3814         from mips-tdep.c.  Add syscall_next_pc to gdbarch_tdep.
3815
3816 2008-07-26  Tom Tromey  <tromey@redhat.com>
3817
3818         PR gdb/1158:
3819         * valops.c (value_struct_elt): Treat function-valued field as a
3820         static method.
3821
3822 2008-07-26  Tom Tromey  <tromey@redhat.com>
3823
3824         PR gdb/1136:
3825         * macroexp.c (get_punctuator) <punctuators>: Rearrange to put
3826         longer tokens first.
3827
3828 2008-07-26  Vladimir Prus  <vladimir@codesourcery.com>
3829
3830         Kill cmd_async_ok.
3831         * cli/cli-decode.h (CMD_ASYNC_OK, set_cmd_async_ok)
3832         (get_cmd_async_ok): Remove.
3833         * cli/cli-decode.c (set_cmd_async_ok, get_cmd_async_ok): Remove.
3834         * cli/cli-cmds.c (init_cli_cmds): Don't use set_cmd_async_ok.
3835         * infcmd.c (_initialize_infcmd): Likewise.
3836         * thread.c (_initialize_thread): Likewise.
3837
3838 2008-07-25  Joseph Myers  <joseph@codesourcery.com>
3839
3840         * mips-tdep.c (mips_n32n64_push_dummy_call): Handle passing
3841         128-bit long doubles in even-odd pairs of FPRs.  Do not
3842         right-align float arguments for big-endian.
3843         (mips_n32n64_return_value): Apply return value convention for
3844         structs containing one or two floating-point values to soft-float
3845         as well as hard-float.  Handle 128-bit long doubles in such
3846         structs.
3847         (mips_o32_push_dummy_call): Only skip one integer register for a
3848         float argument passed in an FPR.
3849
3850 2008-07-25  Tom Tromey  <tromey@redhat.com>
3851
3852         * tui/tui-hooks.c: Include observer.h.
3853         (tui_event_default, tui_old_event_hooks, tui_event_hooks):
3854         Remove.
3855         (tui_bp_created_observer, tui_bp_deleted_observer,
3856         tui_bp_modified_observer): New globals.
3857         (tui_install_hooks): Use observers, not events.
3858         (tui_remove_hooks): Likewise.
3859         * mi/mi-cmd-break.c: Include observer.h, not gdb-events.h.
3860         (mi_breakpoint_observers_installed, mi_can_breakpoint_notify): New
3861         globals.
3862         (breakpoint_notify): Check mi_can_breakpoint_notify.
3863         (breakpoint_hooks): Remove.
3864         (mi_cmd_break_insert): Attach observers.  Don't use events.
3865         * tracepoint.c: Include observer.h, not gdb-events.h.
3866         (tracepoint_operation, trace_pass_command): Notify observer.
3867         * interps.c: Don't include gdb-events.h.
3868         (clear_interpreter_hooks): Don't call clear_gdb_event_hooks.
3869         * gdbarch.c: Rebuild.
3870         * gdbarch.sh: Emit include for observer.h, not gdb-events.h.
3871         (deprecated_current_gdbarch_select_hack): Notify observer.
3872         * breakpoint.h: Don't include gdb-events.h.
3873         * breakpoint.c: Don't include gdb-events.h.
3874         (condition_command): Notify observer.
3875         (commands_command): Likewise.
3876         (commands_from_control_command): Likewise.
3877         (mention, delete_breakpoint, set_ignore_count): Likewise.
3878         (disable_breakpoint, do_enable_breakpoint): Likewise.
3879         * Makefile.in (gdb_events_h): Remove.
3880         (breakpoint_h): Update.
3881         (COMMON_OBS): Remove gdb-events.o.
3882         (gdb-events.o): Remove.
3883         (breakpoint.o, gdbarch.o, interps.o, tracepoint.o, gdbtk-bp.o,
3884         gdbtk-hooks.o, mi-cmd-break.o, tui-hooks.o): Update.
3885         * gdb-events.c: Remove.
3886         * gdb-events.h: Remove.
3887         * gdb-events.sh: Remove.
3888
3889 2008-07-24  Pedro Alves  <pedro@codesourcery.com>
3890
3891         * remote.c (remote_threads_extra_info): Don't query the remote
3892         server about info on the internally added main thread.
3893
3894 2008-07-24  Aleksandar Ristovski  <aristovski@qnx.com>
3895
3896         * nto-procfs.c (procfs_attach): Populate initial thread list.
3897         (procfs_wait): Return new pid, built from the inferior status.
3898
3899 2008-07-23  Thiago Jung Bauermann  <bauerman@br.ibm.com>
3900
3901         * configure.ac (CONFIG_INITS): Delete long obsoleted variable.
3902         * configure: Regenerate.
3903
3904 2008-07-23  Aleksandar Ristovski  <aristovski@qnx.com>
3905
3906         * nto-procfs.c (procfs_xfer_memory): Changed signature.
3907         (procfs_resume): Workaround for dereferencing type-punned pointer
3908         warning.
3909         * nto-tdep.c (nto_parse_redirection): Change signature to be const
3910         correct.
3911         * nto-tdep.h (nto_parse_redirection): Likewise.
3912
3913 2008-07-21  Stan Shebs  <stan@codesourcery.com>
3914
3915         Scrub remnants of IN_SOLIB_DYNSYM_RESOLVE_CODE.
3916         * gdbarch.sh: Adjust comment to refer to
3917         in_solib_dynsym_resolve_code().
3918         * gdbarch.h, gdbarch.c: Update.
3919         * solib-osf.c: Ditto.
3920         * infrun.c: Ditto.
3921         (handle_inferior_event): Use in_solib_dynsym_resolve_code
3922         unconditionally.
3923         * config/mips/nm-irix5.h: Remove undef of
3924         IN_SOLIB_DYNSYM_RESOLVE_CODE.
3925
3926 2008-07-21  Tom Tromey  <tromey@redhat.com>
3927
3928         * symfile.c (reread_symbols): Don't pass argument to observer.
3929         * exec.c (exec_file_attach): Don't pass argument to observer.
3930         * ada-lang.c (ada_executable_changed_observer): Remove argument.
3931         * symtab.c (symtab_observer_executable_changed): Remove argument.
3932         * observer.sh: Handle functions with no arguments.
3933
3934 2008-07-20  Sergei Poselenov  <sposelenov@emcraft.com>
3935             Chris Demetriou  <cgd@google.com>
3936
3937         * elfread.c (elf_symfile_segments): Fix the check that each loadable
3938         section fits within an ELF segment to handle ELF segments that hit
3939         the end of the address space.
3940
3941 2008-07-20  Chris Demetriou  <cgd@google.com>
3942
3943         * MAINTAINERS (Write After Approval): Add self.
3944
3945 2008-07-18  Tom Tromey  <tromey@redhat.com>
3946
3947         PR gdb/855:
3948         * NEWS: Add entry for macro commands.
3949         * Makefile.in (macrocmd.o): Add gdb_string.h.
3950         * macroscope.h (user_macro_scope): Declare.
3951         (default_macro_scope): Update documentation.
3952         (macro_user_macros): Declare.
3953         * c-lang.c (c_preprocess_and_parse): Always attempt macro lookup.
3954         Use user_macro_scope.
3955         (null_macro_lookup): Remove.
3956         * macrotab.h (macro_callback_fn): Declare.
3957         (macro_for_each): Likewise.
3958         (macro_allow_redefinitions): Likewise.
3959         * macrotab.c (foreach_macro): New function
3960         (macro_for_each): Likewise.
3961         (struct macro_table) <redef_ok>: New field.
3962         (macro_allow_redefinitions): New function.
3963         (new_macro_table): Update.
3964         (macro_define_function): Likewise.
3965         (macro_define_object): Likewise.
3966         * macroscope.c (user_macro_scope): New function.
3967         (default_macro_scope): Use it.
3968         (macro_user_macros): New global.
3969         (standard_macro_lookup): Look in macro_user_macros.
3970         (_initialize_macroscope): New function.
3971         * macroexp.h (macro_is_whitespace, macro_is_digit,
3972         macro_is_identifier_nondigit): Declare.
3973         * macroexp.c (macro_is_whitespace): Rename.  No longer static.
3974         (macro_is_digit): Likewise.
3975         (macro_is_identifier_nondigit): Likewise.
3976         (get_identifier): Update.
3977         (get_pp_number): Likewise.
3978         (get_token): Likewise.
3979         * macrocmd.c (skip_ws): New function.
3980         (extract_identifier): Likewise.
3981         (free_macro_definition_ptr): Likewise.
3982         (user_macros): Remove.
3983         (macro_define_command): Implement.
3984         (_initialize_macrocmd): Update.
3985         (macro_undef_command): Implement.
3986         (print_one_macro): New function.
3987         (macro_list_command): Implement.
3988
3989 2008-07-18  Joseph Myers  <joseph@codesourcery.com>
3990
3991         * configure.ac: Put old value of $LIBS after -lbfd -liberty $intl
3992         in BFD ELF check.
3993         * configure: Regenerate.
3994
3995 2008-07-17  Paul Pluzhnikov  <ppluzhnikov@google.com>
3996
3997         * auxv.c (fprint_target_auxv): Stop at AT_NULL.
3998
3999 2008-07-15  Andreas Schwab  <schwab@suse.de>
4000
4001         * valops.c (value_cast_pointers): Follow typedefs when checking
4002         result of coercion.
4003
4004 2008-07-15  Daniel Jacobowitz  <dan@codesourcery.com>
4005
4006         * block.c (block_function): Renamed to ...
4007         (block_linkage_function): ... this.  All callers changed.
4008         * block.h (block_function): Renamed to ...
4009         (block_linkage_function): ... this.
4010
4011 2008-07-15  Daniel Jacobowitz  <dan@codesourcery.com>
4012
4013         * mn10300-tdep.c (set_reg_offsets): Use get_frame_register_unsigned.
4014
4015 2008-07-15  Daniel Jacobowitz  <dan@codesourcery.com>
4016
4017         * frame.c (frame_sp_unwind): Delete.
4018         (get_frame_sp): Do not use it.
4019         * frame.h (frame_sp_unwind): Delete prototype.
4020
4021 2008-07-15  Daniel Jacobowitz  <dan@codesourcery.com>
4022
4023         * ia64-tdep.c (ia64_dummy_id): Use get_frame_pc.
4024
4025 2008-07-15  Daniel Jacobowitz  <dan@codesourcery.com>
4026
4027         * dwarf2-frame.c (dwarf2_frame_cache): Update comment.
4028         * frame.c (frame_unwind_address_in_block): Delete.
4029         (get_frame_address_in_block): Do not use it.  Check the type
4030         of the next frame first.
4031         (frame_cleanup_after_sniffer): Update comment.
4032         * frame.h (frame_unwind_address_in_block): Delete prototype.
4033         * hppa-tdep.c (hppa_find_unwind_entry_in_block): Update comment.
4034
4035 2008-07-15  Daniel Jacobowitz  <dan@codesourcery.com>
4036
4037         * frame.c (frame_func_unwind): Delete.
4038         (get_frame_func): Do not use it.
4039         * frame.h (frame_func_unwind): Delete prototype.
4040         * hppa-tdep.c (hppa_frame_cache): Update comment.
4041         * rs6000-tdep.c (rs6000_frame_cache): Update comment.
4042
4043 2008-07-14  Stan Shebs  <stan@codesourcery.com>
4044
4045         * remote-sim.c (init_gdbsim_ops): Remove
4046         TARGET_REDEFINE_DEFAULT_OPS.
4047
4048 2008-07-15  Daniel Jacobowitz  <dan@codesourcery.com>
4049
4050         * findvar.c (read_var_value): Remove unused variable.
4051
4052 2008-07-15  Luis Machado  <luisgpm@br.ibm.com>
4053
4054         * infrun.c (handle_inferior_event): Tag threads as stopped
4055         before inserting breakpoints.
4056
4057 2008-07-15  Hui Zhu  <teawater@gmail.com>
4058
4059         * MAINTAINERS: Added myself to section Write After Approval.
4060
4061 2008-07-14  Paul Pluzhnikov  <ppluzhnikov@google.com>
4062
4063         PR gdb/2477
4064         * cp-abi.c (value_virtual_fn_field): Handle invalid pointers.
4065
4066 2008-07-14  Pedro Alves  <pedro@codesourcery.com>
4067
4068         * i386-dicos-tdep.c (i386_dicos_frame_align): Delete.
4069         (i386_dicos_push_dummy_code): New.
4070         (i386_dicos_init_abi): Don't register i386_dicos_frame_align.
4071         Register i386_dicos_push_dummy_code.
4072
4073 2008-07-14  Markus Deuling  <deuling@de.ibm.com>
4074
4075         * mips-tdep.c (fp_register_arg_p): Add gdbarch as paramter.
4076         (mips_n32n64_push_dummy_call, mips_o64_return_value)
4077         (mips_eabi_push_dummy_call): Update call to fp_register_arg_p.
4078
4079         (MIPS_FPU_TYPE): Add gdbarch as parameter and replace current_gdbarch.
4080         (fp_register_arg_p, mips_dump_tdep, show_mipsfpu_command)
4081         (mips_n32n64_fp_arg_chunk_p): Update caller.
4082
4083         (mips_n32n64_fp_arg_chunk_p): Add gdbarch as paramter.
4084         (mips_n32n64_push_dummy_call): Update caller.
4085
4086         (MIPS_LAST_ARG_REGNUM): Add gdbarch as parameter and replace
4087         current_gdbarch.
4088         (mips_eabi_push_dummy_call, mips_n32n64_push_dummy_call)
4089         (mips_o32_push_dummy_call, mips_o64_push_dummy_call): Update caller.
4090
4091
4092         (MIPS_LAST_FP_ARG_REGNUM): Add gdbarch as parameter and replace
4093         current_gdbarch.
4094         (mips_eabi_push_dummy_call, mips_o32_push_dummy_call)
4095         (mips_o64_push_dummy_call): Update caller.
4096
4097         (MIPS_EABI): Add gdbarch as parameter and replace current_gdbarch.
4098         (fp_register_arg_p, mips_dump_tdep): Update caller.
4099
4100         (set_reg_offset): Add gdbarch as parameter and replace current_gdbarch.
4101         (mips16_scan_prologue, mips32_scan_prologue): Update caller.
4102
4103         (reset_saved_regs): Make static.  Add gdbarch as parameter.  Replace
4104         current_gdbarch.
4105         (mips32_scan_prologue): Update caller.
4106
4107         (heuristic_proc_start): Add gdbarch as parameter. Replace
4108         current_gdbarch.
4109         (mips_insn16_frame_cache, mips_insn32_frame_cache): Update caller.
4110
4111         * mipsnbsd-nat.c (mipsnbsd_fetch_inferior_registers)
4112         (mipsnbsd_store_inferior_registers): Use get_regcache_arch to get at
4113         the current architecture. Update call to getregs_supplies.
4114         (getregs_supplies): Add gdbarch as parameter and replace
4115         current_gdbarch.
4116
4117         * mipsnbsd-tdep.c (mipsnbsd_get_longjmp_target): Use get_frame_arch to
4118         get at the current architecture. Update call to NBSD_MIPS_JB_OFFSET and
4119         NBSD_MIPS_JB_ELEMENT_SIZE.
4120         (NBSD_MIPS_JB_ELEMENT_SIZE, NBSD_MIPS_JB_OFFSET): Add gdbarch and
4121         replace current_gdbarch.
4122
4123         * remote-mips.c (mips_map_regno): Add gdbarch as parameter and replace
4124         current_gdbarch.
4125         (mips_fetch_registers, mips_store_registers): Update call
4126         to mips_map_regno.
4127         (mips_load): Use get_regcache_arch to get at the current_architecture
4128         and replace current_gdbarch.
4129
4130 2008-07-13  Pedro Alves  <pedro@codesourcery.com>
4131
4132         * thread.c (restore_selected_frame): On fail to restore, select
4133         the innermost frame, and don't crash when warning the user.
4134
4135 2008-07-13  Hui Zhu  <teawater@gmail.com>
4136
4137         * symtab.c (expand_line_sal): Fix a memory leak.
4138
4139 2008-07-13  Pedro Alves  <pedro@codesourcery.com>
4140
4141         * utils.c (struct continuation): Define as inheriting struct
4142         cleanup.
4143         (add_continuation, do_all_continuations)
4144         (discard_all_continuations, add_intermediate_continuation)
4145         (do_all_intermediate_continuations)
4146         (discard_all_intermediate_continuations): Adjust.
4147
4148 2008-07-13  Vladimir Prus  <vladimir@codesourcery.com>
4149
4150         Skip varobj in running threads.
4151         * mi/mi-cmd-var.c (mi_cmd_var_update): If varobj's
4152         thread is not stopped, skip the varobj.
4153         * Makefile.in: Update dependencies.
4154
4155 2008-07-13  Vladimir Prus  <vladimir@codesourcery.com>
4156
4157         Enable all commands while inferiour is running
4158         * mi/mi-main.c (mi_cmd_execute): Don't check if
4159         inferiour is executing.
4160
4161 2008-07-13  Vladimir Prus  <vladimir@codesourcery.com>
4162
4163         Allow all CLI command even if target is executing.
4164         * gdb/top.c (execute_command_1): Don't check if the inferiour
4165         is running.
4166
4167 2008-07-13  Vladimir Prus  <vladimir@codesourcery.com>
4168
4169         * mi/mi-main.c (mi_cmd_execute): Remove unused variable.
4170         Fix printing of frame, when frame is wrong.
4171
4172 2008-07-12  Ulrich Weigand  <uweigand@de.ibm.com>
4173
4174         * spu-tdep.c (spu_frame_unwind_cache): Do not error if
4175         backchain is unreadable.
4176
4177 2008-07-12  Ulrich Weigand  <uweigand@de.ibm.com>
4178
4179         * spu-linux-nat.c: Include "gdbthread.h".
4180         (spu_child_post_startup_inferior): Register main thread.
4181         (spu_child_post_attach): Likewise.
4182         * Makefile.in (spu-linux-nat.o): Update dependencies.
4183
4184 2008-07-12  Pedro Alves  <pedro@codesourcery.com>
4185
4186         Rewrite continuations internals on top of cleanups and plug
4187         continuation arguments leaks.
4188
4189         * defs.h (struct continuation): Make it opaque.
4190         (add_continuation, add_intermediate_continuation): Drop the int
4191         argument of the continuation hook argument.  Add
4192         continuation_free_args argument.
4193         (do_all_continuations, do_all_intermediate_continuations): Drop
4194         the error_p argument.
4195
4196         * utils.c (add_continuation): Drop the int argument of the
4197         continuation hook argument.  Add continuation_free_args argument.
4198         Reimplement on top of cleanups.
4199         (do_all_continuations): Drop error argument.  Reimplement on top
4200         of cleanups.
4201         (discard_all_continuations): Reimplement on top of cleanups.
4202         (add_intermediate_continuation): Drop the int argument of the
4203         continuation hook argument.  Add continuation_free_args argument.
4204         Reimplement on top of cleanups.
4205         (do_all_intermediate_continuations): Drop error argument.
4206         Reimplement on top of cleanups.
4207         (discard_all_intermediate_continuations): Reimplement on top of
4208         cleanups.
4209
4210         * breakpoint.c (until_break_command_continuation): Drop error
4211         argument.  Add xfree as continuation argument deleter.
4212
4213         * inf-loop.c (inferior_event_handler): On error, discard all
4214         continuations.  Adjust to new do_all_intermediate_continuations
4215         and do_all_continuations interfaces.
4216
4217         * infcmd.c (step_1_continuation): Drop error_p argument.  Adjust.
4218         Pass xfree as continuation argument deleter.
4219         (finish_command_continuation): Drop error_p argument.  Adjust.
4220         (finish_command_continuation_free_arg): New.
4221         (finish_command): Pass finish_command_continuation_free_arg as
4222         continuation argument deleter.  Adjust to new do_all_continuations
4223         interfaces.
4224         (attach_command_continuation): Drop error_p argument.
4225         (attach_command_continuation_free_args): New.
4226         (attach_command): Pass attach_command_continuation_free_args as
4227         continuation argument deleter.
4228
4229         * interps.c (interp_set): Adjust to new do_all_continuations
4230         interfaces.
4231
4232         * event-top.c (stdin_event_handler): In error, also discard the
4233         intermediate continuations.
4234
4235 2008-07-12  Pedro Alves  <pedro@codesourcery.com>
4236
4237         Replace struct continuation_args by void* and per command structs.
4238
4239         * top.c (execute_command): Remove unused arg1 and arg2 locals.
4240
4241         * breakpoint.c (struct until_break_command_continuation_args):
4242         New.
4243         (until_break_command_continuation): Take a void* instead of a
4244         continuations_arg.  Adjust.
4245         (until_break_command): Adjust to use struct
4246         until_break_command_continuation_args instead of struct
4247         continuation_arg.
4248
4249         * infcmd.c (struct step_1_continuation_args): New.
4250         (step_1_continuation): Take a void* instead of a
4251         continuations_arg.  Adjust to use struct step_1_continuation_args.
4252         (step_once): Adjust to use struct step_1_continuation_args.
4253
4254         (struct finish_command_continuation_args): New.
4255         (finish_command_continuation): Take a void* instead of a
4256         continuations_arg.  Adjust to use struct
4257         finish_command_continuation_args.
4258         (finish_command): Adjust to use struct
4259         finish_command_continuation_args.
4260         (struct attach_command_continuation_args): New.
4261         (attach_command_continuation): Take a void* instead of a
4262         continuations_arg.  Adjust to use struct
4263         attach_command_continuation_args.
4264         (attach_command): Adjust to use struct
4265         attach_command_continuation_args.
4266
4267         * defs.h (struct continuation_arg): Delete.
4268         (struct continuation): Replace the struct continuation_arg*
4269         parameter of continuation_hook by a void*.  Replace "arg_list"
4270         member by a new "args" member with void* type.
4271         (add_continuation, add_intermediate_continuation): Replace struct
4272         continuation_arg type usages by void* usages.
4273
4274         * utils.c (add_continuation, do_all_continuations)
4275         (add_intermediate_continuation)
4276         (do_all_intermediate_continuations): Replace struct
4277         continuation_arg type usages by void* usages.  Pass "args" instead
4278         of "arg_list".
4279
4280 2008-07-12  Pedro Alves  <pedro@codesourcery.com>
4281
4282         * infrun.c (struct thread_stepping_state): Delete sal member.
4283         (init_thread_stepping_state): Add local sal.  Use it instead of
4284         tss->sal.
4285         (handle_inferior_event): New local stop_pc_sal.  Use it instead of
4286         tss->sal.
4287         (step_into_function): Add local stop_func_sal.  Use it instead of
4288         tss->sal.
4289
4290 2008-07-12  Vladimir Prus  <vladimir@codesourcery.com>
4291
4292         Implement -exec-continue/-exec-interrupt --all.
4293         * infcmd.c (continue_1): New, extracted from
4294         (continue_command): ...here.
4295         (interrupt_target_1): New, extracted from
4296         (interrupt_target_command): ...here.
4297         * inferior.h (continue_1, interrupt_target_1): New.
4298         * mi/mi-main.c (mi_cmd_exec_continue)
4299         (mi_cmd_exec_interrupt): Handle --all.
4300
4301 2008-07-12  Vladimir Prus  <vladimir@codesourcery.com>
4302
4303         Implement --thread and --frame.
4304         * gdbthread.h (find_thread_id): Declare.
4305         * thread.c (find_thread_id): Make non-static.
4306         * mi/mi-main.c (mi_cmd_execute): Switch to the right
4307         thread and frame, if necessary.
4308         * mi/mi-parse.c (mi_parse): Handle --thread and --frame.
4309         * mi/mi-parse.h (strcut mi_parse): New fields thread and frame.
4310
4311 2008-07-12  Vladimir Prus  <vladimir@codesourcery.com>
4312
4313         * infrun.c (resume): Discard cleanups on early exit path.
4314
4315 2008-07-12  Vladimir Prus  <vladimir@codesourcery.com>
4316
4317         * infrun.c (normal_stop): For MI, report which threads
4318         were stopped.
4319
4320 2008-07-12  Vladimir Prus  <vladimir@codesourcery.com>
4321
4322         Report thread state in -thread-info output.
4323         * thread.c (print_thread_info): Add new field "state".
4324
4325 2008-07-11  Pedro Alves  <pedro@codesourcery.com>
4326
4327         * infrun.c (handle_inferior_event): Also ignore a
4328         TARGET_SIGNAL_TRAP on a STOP_QUIETLY_NO_SIGSTOP.
4329
4330 2008-07-11  Tom Tromey  <tromey@redhat.com>
4331
4332         * completer.c (complete_line_internal): New function, from
4333         complete_line.  Add 'for_help' parameter.
4334         (complete_line): Use it.
4335         (command_completer): Move later.  Rewrite.
4336
4337 2008-07-11  Pedro Alves  <pedro@codesourcery.com>
4338
4339         * thread.c (thread_apply_command): Move making the cleanup out of
4340         the loop.
4341
4342 2008-07-11  Pedro Alves  <pedro@codesourcery.com>
4343
4344         Exited threads.
4345
4346         * thread.c (enum thread_state): New.
4347         (thread_state main_thread_running): Delete, in favor of...
4348         (thread_state main_thread_state): ... this.  Update throughout.
4349         (clear_thread_inferior_resources): New, split from free_thread.
4350         (free_thread): Call clear_thread_inferior_resources.
4351         (init_thread_list): Set main thread to stopped state.
4352         (add_thread_silent): Take care of PTID reuses.
4353         (delete_thread): If deleting inferior_ptid or a thread with
4354         refcount > 0, mark it as exited, but still keep it in the list.
4355         Only notify of thread exits, if we haven't done so yet.
4356         (iterate_over_threads): Make it safe to delete threads while
4357         iterating over them.
4358         (do_captured_list_thread_ids): Don't account for exited threads.
4359         (thread_alive): Check for the THREAD_EXITED state, and don't set
4360         ptid to -1 on exited threads.
4361         (set_running): Update to account for extra possible states.
4362         (is_thread_state): New.
4363         (is_stopped, is_exited): New.
4364         (is_running): Implement in terms of is_thread_state.
4365         (any_running): Update.
4366         (print_thread_info): Update.  Account for exited threads.  Don't
4367         warn about missed frame restoring here, its done in the cleanup.
4368         (switch_to_thread): Don't read from a thread that has gone.
4369         (restore_current_thread): In non-stop mode, do a full context
4370         switch.
4371         (restore_selected_frame): Add a frame_level argument.  Rewrite.
4372         (struct current_thread_cleanup): Add selected_frame_level and
4373         was_stopped members.
4374         (do_restore_current_thread_cleanup): Check if thread was stopped
4375         and still is, and if the target has registers, stack and memory
4376         before restoring the selected frame.  Don't delete the cleanup
4377         argument here.
4378         (restore_current_thread_cleanup_dtor): New.
4379         (make_cleanup_restore_current_thread): Remove all arguments.
4380         Rewrite.
4381         (thread_apply_all_command): Update.  Prune threads.
4382         (thread_apply_command): Update.
4383         (thread_command): Account for currently selected exited thread.
4384         (do_captured_thread_select): Check for a running thread.  Prune
4385         threads.
4386         (_initialize_thread): Make "info threads", "thread", "thread
4387         apply", and "thread apply all" appliable without a selected thread.
4388         * gdbthread.h (struct thread_info): Replace running_ by state_.
4389         Add refcount.
4390         (is_exited, is_stopped): Declare.
4391         (make_cleanup_restore_current_thread): Remove all arguments.
4392         * infrun.c: Include "event-top.h".
4393         (fetch_inferior_event): In non-stop mode, restore selected thread
4394         and frame after handling the event and running breakpoint
4395         commands.  Display GDB prompt if needed.
4396         (normal_stop): In non-stop mode, don't print thread switching
4397         notice.
4398         * cli/cli-decode.c (set_cmd_no_selected_thread_ok)
4399         (get_cmd_no_selected_thread_ok): New.
4400         * cli/cli-decode.h (CMD_NO_SELECTED_THREAD_OK): New.
4401         (set_cmd_no_selected_thread_ok, get_cmd_no_selected_thread_ok):
4402         Declare.
4403         * cli/cli-cmds.c: Set "pwd", "help", "info", "show" as
4404         no-selected-thread ok.
4405         * top.c (execute_command): Check for non no-selected-thread-ok
4406         commands.
4407         * linux-nat.c (struct saved_ptids, threads_to_delete)
4408         (record_dead_thread, prune_lwps): Delete.
4409         (exit_lwp): Unconditionally delete thread.
4410         (linux_nat_resume): Remove prune_lwps call.
4411         * infcmd.c (proceed_thread_callback): Check if !is_stopped instead
4412         of is_running.  Adjust to make_cleanup_restore_current_thread
4413         interface change.
4414         * mi/mi-main.c (mi_cmd_execute): Only allow a few commands if the
4415         selected thread has exited.
4416         * inf-loop.c (inferior_event_handler): Don't display the prompt
4417         here.
4418         * varobj.c (c_value_of_root): Update.
4419         * defs.h (make_cleanup_dtor): Declare.
4420         * utils.c (make_cleanup_dtor): New.
4421
4422         * Makefile.in (infrun.o): Depend on $(event_top_h).
4423
4424 2008-07-11  Pedro Alves  <pedro@codesourcery.com>
4425
4426         Add "continue -a" and "interrupt -a" options for non-stop mode.
4427
4428         * infcmd.c (proceed_thread_callback, do_context_switch_to): New.
4429         (continue_command): Add "-a" option.
4430         (interrupt_target_command): Add "-a" option.
4431         (_initialize_infcmd): Add extend help of continue and interrupt
4432         command to mention the new "-a" option.  Mark "continue" async ok.
4433
4434 2008-07-10  Doug Evans  <dje@google.com>
4435
4436         Add "set print symbol-loading on|off".
4437         * NEWS: Document new option.
4438         * symfile.h (print_symbol_loading): Declare.
4439         * symfile.c (print_symbol_loading): New global.
4440         (symbol_file_add_with_addrs_or_offsets): Only print "Reading symbols
4441         from ..." if print_symbol_loading.
4442         (_initialize_symfile): Add set/show print symbol-loading.
4443         * solib.c (solib_read_symbols): Only print "Loaded symbols for ..."
4444         if print_symbol_loading.
4445
4446 2008-07-10  Pedro Alves  <pedro@codesourcery.com>
4447
4448         Non-stop linux native.
4449
4450         * linux-nat.c (linux_test_for_tracefork): Block events while we're
4451         here.
4452         (get_pending_status): Implement non-stop mode.
4453         (linux_nat_detach): Stop threads before detaching.
4454         (linux_nat_resume): In non-stop mode, always resume only a single
4455         PTID.
4456         (linux_handle_extended_wait): On a clone event, in non-stop mode,
4457         add new lwp to GDB's thread table, and mark as running, executing
4458         and stopped appropriately.
4459         (linux_nat_filter_event): Don't assume there are other running
4460         threads when a thread exits.
4461         (linux_nat_wait): Mark the main thread as running and executing.
4462         In non-stop mode, don't stop all lwps.
4463         (linux_nat_kill): Stop lwps before killing them.
4464         (linux_nat_thread_alive): Use signal 0 to detect if a thread is
4465         alive.
4466         (send_sigint_callback): New.
4467         (linux_nat_stop): New.
4468         (linux_nat_add_target): Set to_stop to linux_nat_stop.
4469
4470         * linux-nat.h (thread_db_attach_lwp): Declare.
4471
4472         * linux-thread-db.c (thread_get_info_callback): Check for new
4473         threads if we have none.
4474         (thread_from_lwp, enable_thread_event): Set proc_handle.pid to the
4475         stopped lwp.  Check for new threads if we have none.
4476         (thread_db_attach_lwp): New.
4477         (thread_db_init): Set proc_handle.pid to inferior_ptid.
4478         (check_event): Set proc_handle.pid to the stopped lwp.
4479         (thread_db_find_new_threads): Set proc_handle.pid to any stopped
4480         lwp available, bail out if there is none.
4481
4482         * linux-fork.c (linux_fork_killall): Use SIGKILL instead of
4483         PTRACE_KILL.
4484
4485 2008-07-10  Kevin Buettner  <kevinb@redhat.com>
4486
4487         * rs6000-tdep.c (ppc_displaced_step_fixup): Change type of
4488         `current_pc' from CORE_ADDR to ULONGEST.
4489
4490         * remote-sim.c (gdbsim_cntrl_c): Pass remote_sim_ptid to
4491         gdbsim_stop().
4492
4493 2008-07-10  Jan Kratochvil  <jan.kratochvil@redhat.com>
4494
4495         * NEWS (New commands): Mention "set disable-randomization".
4496         * configure.ac: Add check for HAVE_PERSONALITY and
4497         HAVE_DECL_ADDR_NO_RANDOMIZE.
4498         * configure, config.in: Regenerate.
4499         * linux-nat.c [HAVE_PERSONALITY]: New include <sys/personality.h>.
4500         [HAVE_PERSONALITY] [!HAVE_DECL_ADDR_NO_RANDOMIZE]: Set
4501         ADDR_NO_RANDOMIZE.
4502         (disable_randomization, show_disable_randomization)
4503         (set_disable_randomization): New.
4504         (linux_nat_create_inferior) [HAVE_PERSONALITY]: New variables
4505         PERSONALITY_ORIG and PERSONALITY_SET.  Disable randomization upon the
4506         variable DISABLE_RANDOMIZATION.
4507         (_initialize_linux_nat): Call ADD_SETSHOW_BOOLEAN_CMD for the variable
4508         DISABLE_RANDOMIZATION.
4509
4510 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4511
4512         Adjust all targets to new target_stop interface.
4513
4514         * gnu-nat.c (gnu_stop): Add ptid argument.
4515         * go32-nat.c (go32_stop): Add ptid argument.
4516         (go32_create_inferior): Pass inferior_ptid to go32_stop.
4517         * hpux-thread.c (hpux_thread_stop): Add ptid argument.
4518         * monitor.c (monitor_stop): Add ptid argument.
4519         (monitor_open): Pass inferior_ptid to monitor_stop.
4520         (monitor_interrupt): Pass inferior_ptid to target_stop.
4521         (monitor_stop): Add ptid argument.
4522         * nto-procfs.c (nto_interrupt): Pass inferior_ptid to target_stop.
4523         (procfs_create_inferior): Add ptid argument.
4524         * procfs.c (procfs_stop): Add ptid argument.
4525         * remote-m32r-sdi.c (m32r_stop): Add ptid argument.
4526         * remote-sim.c (gdbsim_stop): Add ptid argument.
4527         * sol-thread.c (sol_thread_stop): Add ptid argument.
4528         * win32-nat.c (win32_stop): Add ptid argument.
4529
4530 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4531
4532         Non-stop inferior control.
4533
4534         * infrun.c (resume): In non-stop mode, always resume just one
4535         thread.
4536         (proceed): Don't call prepare_to_proceed in non-stop mode.
4537         (fetch_inferior_event): In non-stop mode, switch context before
4538         handling the event.
4539         (error_is_running, ensure_not_running): New.
4540         (handle_inferior_event): In non-stop mode: Mark only the event
4541         thread as stopped.  Require that the target module manages adding
4542         threads to the thread list.  Assert that there isn't a
4543         deferred_step_ptid set.  Don't switch to infwait_thread_hop_state.
4544         (normal_stop): Only mark not-running if inferior hasn't exited.
4545         In non-stop mode, only mark the event thread.
4546
4547         * thread.c:Include "cli/cli-decode.h".
4548         (print_thread_info): Don't read from a running thread.
4549         Output "(running)" if thread is running.
4550         (switch_to_thread): Don't read stop_pc if thread is executing.
4551         (do_restore_current_thread_cleanup): Don't write to a running
4552         thread.
4553         (thread_apply_all_command): Don't read from a running thread.  In
4554         non-stop mode, do a full context-switch instead of just switching
4555         threads.
4556         (thread_apply_command): In non-stop mode, do a full context-switch
4557         instead of just switching threads.
4558         (do_captured_thread_select): Likewise.  Inform user if selected
4559         thread is running.
4560         (_initialize_thread): Mark "info threads" and "thread" and
4561         async_ok.
4562
4563         * inf-loop.c (inferior_event_handler): In non-stop mode, don't
4564         unregister the target from the event loop.
4565
4566         * infcmd.c (continue_command, step_1, jump_command)
4567         (signal_command): Ensure the selected thread isn't running.
4568         (interrupt_target_command): In non-stop mode, interrupt only the
4569         selected thread.
4570
4571         * inferior.h (error_is_running, ensure_not_running): Declare.
4572
4573         * target.h (struct target_ops): Add ptid argument to the to_stop
4574         member.
4575         (target_stop): Add ptid_t argument.
4576
4577         * target.c (update_current_target): Add ptid argument to to_stop's
4578         type.
4579         (debug_to_stop): Add ptid_t argument.
4580         (debug_to_rcmd): Set to_stop_ptid.
4581
4582         * remote.c (remote_stop): Add ptid_t argument.
4583         (async_remote_interrupt): Add inferior_ptid to target_stop.
4584         * inf-ptrace.c (inf_ptrace_stop): Add ptid argument.
4585
4586         * Makefile.in (thread.o): Depend on $(cli_decode_h).
4587
4588 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4589
4590         Don't rely on ecs->wait_for_more.
4591
4592         * infrun.c (proceed): Clear the stepping state, set
4593         previous_inferior_ptid and clear infwait state.
4594         (wait_for_inferior): Don't clear the stepping state, set
4595         previous_inferior_ptid, or clear the infwait state here.
4596         (fetch_inferior_event): Don't clear the stepping state, set
4597         previous_inferior_ptid, or clear the infwait state here.  Don't
4598         condition on wait_for_more.
4599
4600 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4601
4602         Refactor infrun a bit.
4603
4604         * infrun.c (currently_stepping): Take a struct
4605         thread_stepping_state instead of an execution_control_state.
4606         (struct thread_stepping_state): New, split from
4607         execution_control_state.
4608         (gtss, tss): New globals.
4609         (proceed): Clear the stepping state, set previous_inferior_ptid
4610         and clear infwait state.
4611         (init_wait_for_inferior): Clear the stepping state,
4612         previous_inferior_ptid and infwait state.
4613         (waiton_ptid, infwait_state): New, split from
4614         execution_control_state.
4615         (struct execution_control_state): Members that persist through
4616         events moved out to either struct thred_stepping_state or made
4617         global.  Deleted unneeded wp, saved_inferior_ptid, tmpstatus.
4618         (wait_for_inferior, fetch_inferior_event): Use local
4619         execution_control_state.  Update to execution_control_state split.
4620         (init_execution_control_state): Adjust.
4621         (init_thread_stepping_state): New, extracted from
4622         init_execution_control_state.
4623         (context_switch): Take a ptid instead of an
4624         execution_control_state.
4625         (context_switch_to): Adjust.
4626         (adjust_pc_after_break): Adjust.
4627         (init_infwait_state): New.
4628         (handle_inferior_event): Adjust.
4629
4630 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4631             Vladimir Prus  <vladimir@codesourcery.com>
4632
4633         Per-thread commands.
4634
4635         * gdbthread.h: Remove unneeded forward declarations.
4636         Include "inferior.h".
4637         (struct thread_info): Add continuations,
4638         intermediate_continuations, proceed_to_finish, step_over_calls,
4639         stop_step, step_multi and stop_signal members.
4640         (save_infrun_state): Add continuations,
4641         intermediate_continuations, proceed_to_finish, step_over_calls,
4642         stop_step, step_multi, stop_signal and stop_bpstat parameters.
4643         (load_infrun_state): Add continuations,
4644         intermediate_continuations, proceed_to_finish, step_over_calls,
4645         stop_step, step_multi, stop_signal and stop_bpstat parameters.
4646
4647         * thread.c (load_infrun_state): In non-stop mode, load
4648         continuations, intermediate_continuations, proceed_to_finish,
4649         step_over_calls, stop_step, step_multi and stop_signal.
4650         (save_infrun_state): Store continuations,
4651         intermediate_continuations, proceed_to_finish, step_over_calls,
4652         stop_step, step_multi, stop_signal and stop_bpstat.
4653         (save_infrun_state): Store continuations,
4654         intermediate_continuations, proceed_to_finish, step_over_calls,
4655         stop_step, step_multi, stop_signal and stop_bpstat.
4656         (free_thread): Clear The thread's stop_bpstat.
4657
4658         * inferior.h (context_switch_to): Declare.
4659
4660         * infrun.c (ecss): New global.
4661         (context_switch): Context switch continuations,
4662         intermediate_continuations, proceed_to_finish, step_over_calls,
4663         stop_step, step_multi, stop_signal and stop_bpstat.
4664         (wait_for_inferior): Use global ecss.
4665         (async_ecss, async_ecs): Delete.
4666         (fetch_inferior_event): Use global ecss.
4667         (context_switch_to): New.
4668
4669         * top.c (execute_command): In non-stop, only check if the current
4670         thread is running, in all-stop, check if there's any thread
4671         running.
4672
4673         * breakpoint.c (bpstat_remove_breakpoint): New.
4674         (bpstat_remove_breakpoint_callback): New.
4675         (delete_breakpoint): Clear the stop_bpstats of all threads.
4676
4677         * mi/mi-main.c (mi_cmd_execute): In non-stop, only check if the
4678         current thread is running, in all-stop, check if there's any
4679         thread running.
4680
4681         * Makefile.in (gdbthread_h): Depend on $(inferior_h).
4682
4683 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4684
4685         Add non_stop global.
4686
4687         * inferior.h (non_stop): Declare.
4688         * infrun.c (non_stop, non_stop_1): New.
4689         (set_non_stop, show_non_stop): New.
4690         (_initialize_infrun): Add "set/show non-stop" command.
4691
4692 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4693
4694         Adjust fork/vfork/exec to pass ptids around.
4695
4696         * target.h (struct target_waitstatus): Store related_pid as a ptid.
4697         (inferior_has_forked, inferior_has_vforked, inferior_has_execd):
4698         Take a ptid_t.
4699         * breakpoint.h (struct breakpoint): Change forked_inferior_pid
4700         type to ptid.
4701         * breakpoint.c (print_it_typical, bpstat_check_location)
4702         (print_one_breakpoint_location, set_raw_breakpoint_without_location)
4703         (create_fork_vfork_event_catchpoint): Adjust.
4704         * infrun.c (fork_event): Change parent_pid and child_pid types to
4705         ptid.
4706         (follow_exec, inferior_has_forked, inferior_has_vforked)
4707         (inferior_has_execd): Take a ptid_t and don't trim it.
4708         * linux-thread-db.c (thread_db_wait): Don't trim the returned ptid.
4709         * linux-nat.c (linux_child_follow_fork): Adjust.
4710         * inf-ptrace.c (inf_ptrace_wait): Adjust.
4711         * inf-ttrace.c (inf_ttrace_wait): Adjust.
4712         * win32-nat.c (get_win32_debug_event): Don't set related_pid.
4713
4714 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4715
4716         Add "executing" property to threads.
4717
4718         * inferior.h (target_executing): Delete.
4719         * gdbthread.h (struct thread_info): Add executing_ field.
4720         (set_executing, is_executing): New.
4721         * thread.c (main_thread_executing): New.
4722         (init_thread_list): Clear it and also main_thread_running.
4723         (is_running): Return false if target has no execution.
4724         (any_running, is_executing, set_executing): New.
4725
4726         * top.c: Include "gdbthread.h".
4727         (target_executing): Delete.
4728         (execute_command): Replace target_executing check by any_running.
4729         * event-top.c: Include "gdbthread.h".
4730         (display_gdb_prompt, command_handler): Replace target_executing by
4731         is_running.
4732         * inf-loop.c: Include "gdbthread.h".  Don't mark as not executing
4733         here.  Replace target_executing by is_running.
4734         * infrun.c (handle_inferior_event): Mark all threads as
4735         not-executing.
4736         * linux-nat.c (linux_nat_resume): Don't mark thread as executing
4737         here.
4738         * stack.c (get_selected_block): Return null if inferior is
4739         executing.
4740         * target.c (target_resume): Mark resumed ptid as executing.
4741         * breakpoint.c (until_break_command): Replace target_executing
4742         check by is_executing.
4743         * remote.c (remote_async_resume): Don't mark inferior as executing
4744         here.
4745         * mi/mi-interp.c (mi_cmd_interpreter_exec): Replace target_executing
4746         by any_running.
4747
4748         * mi/mi-main.c (mi_cmd_exec_interrupt, mi_cmd_execute)
4749         (mi_execute_async_cli_command): Replace target_executing by
4750         is_running.
4751
4752         * frame.c (get_current_frame): Error out if the current thread is
4753         executing.
4754         (has_stack_frames): New.
4755         (get_selected_frame, deprecated_safe_get_selected_frame): Check
4756         has_stack_frames.
4757
4758         * Makefile.in (event-top.o, frame.o, inf-loop.o, top.o): Depend on
4759         $(gdbthread_h).
4760
4761 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4762
4763         * symfile.c (load_command): Reopen the exec file and reread
4764         symbols before anything else.
4765
4766 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4767
4768         * remote-sim.c: Include gdbthread.h.
4769         (remote_sim_ptid): New global.
4770         (gdbsim_create_inferior): Silently add the main task to GDB's
4771         thread list.
4772         (gdbsim_close, gdbsim_mourn_inferior): Silently delete the main
4773         task from GDB's thread list.
4774         (gdbsim_resume): Adjust to use remote_sim_ptid.
4775         (gdbsim_thread_alive, gdbsim_pid_to_str): New.
4776         (init_gdbsim_ops): Register gdbsim_thread_alive and
4777         gdbsim_pid_to_str.
4778         (_initialize_remote_sim): Initialize remote_sim_ptid.
4779         * Makefile.in (remote-sim.o): Depend on $(gdbthread_h).
4780
4781 2008-07-09  Pedro Alves  <pedro@codesourcery.com>
4782
4783         * monitor (monitor_ptid): New global.
4784         (monitor_open): Silently add the main task to GDB's thread list.
4785         (monitor_close, monitor_mourn_inferior): Silently delete the main
4786         task from GDB's thread list.
4787         (monitor_thread_alive, monitor_pid_to_str): New.
4788         (init_base_monitor_ops): Register monitor_thread_alive and
4789         monitor_pid_to_str.
4790         (_initialize_remote_monitors): Initialize monitor_ptid.
4791
4792         * gdbthread.h (delete_thread_silent): Declare.
4793         * thread.c (delete_thread): Rename to ...
4794         (delete_thread_1): ... this.  Add "silent" parameter.  If silent,
4795         don't do exit notifications.
4796         (delete_thread, delete_thread_silent): New, as wrappers to
4797         delete_thread_1.
4798
4799 2008-07-08  Pedro Alves  <pedro@codesourcery.com>
4800
4801         * breakpoint.c (update_global_location_list): Add boolean
4802         "should_insert" argument.  Only insert locations if caller told it
4803         too.
4804         (update_global_location_list_nothrow): Add boolean "should_insert"
4805         argument.  Pass it to update_global_location_list.
4806         (insert_breakpoints, create_longjmp_breakpoint)
4807         (create_overlay_event_breakpoint, enable_overlay_breakpoints)
4808         (create_thread_event_breakpoint, create_solib_event_breakpoint)
4809         (create_fork_vfork_event_catchpoint, create_exec_event_catchpoint)
4810         (enable_watchpoints_after_interactive_call_stop)
4811         (set_momentary_breakpoint, create_breakpoints)
4812         (break_command_really, watch_command_1)
4813         (create_ada_exception_breakpoint, update_breakpoint_locations)
4814         (do_enable_breakpoint, enable_command): Pass true to
4815         update_global_location_list.
4816         (bpstat_stop_status, disable_overlay_breakpoints)
4817         (disable_watchpoints_before_interactive_call_start)
4818         (delete_breakpoint, disable_breakpoint, disable_command): Pass
4819         false to update_global_location_list.
4820         (update_breakpoints_after_exec): Don't temporarily disable
4821         always-inserted mode.
4822
4823 2008-07-08  Pedro Alves  <pedro@codesourcery.com>
4824
4825         * breakpoint.c (mark_breakpoints_out): Make public.
4826         (update_breakpoints_after_exec): Don't call mark_breakpoints_out
4827         here.  Update comment.
4828         * breakpoint.h (mark_breakpoints_out): Declare.
4829
4830         * linux-nat.c (linux_handle_extended_wait): On
4831         TARGET_WAITKIND_EXECD, call mark_breakpoints_out.
4832         * inf-ttrace.c (inf_ttrace_wait): Likewise.
4833
4834 2008-07-08  Pedro Alves  <pedro@codesourcery.com>
4835
4836         * infrun.c (follow_exec): Reset shared libraries before adding the
4837         main exec file.
4838
4839 2008-07-07  Jan Kratochvil  <jan.kratochvil@redhat.com>
4840
4841         * breakpoint.c (bpstat_copy): Call RELEASE_VALUE on the new OLD_VAL.
4842
4843 2008-07-07  Pedro Alves  <pedro@codesourcery.com>
4844
4845         * i386-dicos-tdep.c: Include "inferior.h".
4846         (i386_dicos_frame_align): New.
4847         (i386_dicos_init_abi): Register i386_dicos_frame_align.  Set call
4848         dummy location ON_STACK.
4849         * Makefile.in (i386-dicos-tdep.o): Depend on $(inferior_h).
4850
4851 2008-07-07  Joel Brobecker  <brobecker@adacore.com>
4852
4853         * gstdint.h: New file.
4854
4855 2008-07-05  Vladimir Prus  <vladimir@codesourcery.com>
4856
4857         * mi/mi-interp.c (mi_on_resume): Don't try to report
4858         resumed thread it the thread list is empty.
4859
4860 2008-07-05  Pierre Muller  <muller@ics.u-strasbg.fr>
4861
4862         * cli/cli-decode.c (add_setshow_optional_filename_cmd): Set
4863         completer for set to filename_completer.
4864
4865         NEWS: Mention it.
4866
4867 2008-07-04  Vladimir Prus  <vladimir@codesourcery.com>
4868
4869         Implement -target-attach.
4870         * mi/mi-cmds.c (mi_cmds): Forward -target-attach to CLI attach.
4871
4872 2008-06-21  Hui Zhu  <teawater@gmail.com>
4873
4874         * target-descriptions.c (maint_print_c_tdesc_cmd): Fix a memory leak.
4875
4876 2008-07-03  Pedro Alves  <pedro@codesourcery.com>
4877
4878         * config/i386/nm-cygwin.h (ATTACH_NO_WAIT): Delete.
4879         * config/i386/nm-i386gnu.h (ATTACH_NO_WAIT): Delete.
4880
4881         * target.h (struct target_ops): Add to_attach_no_wait member.
4882         (target_attach_no_wait): New.
4883         * target.c (update_current_target): Inherit to_attach_no_wait.
4884
4885         * infcmd.c: Replace ATTACH_NO_WAIT compile time check by
4886         target_attach_no_wait runtime check.
4887
4888         * gnu-nat.c (init_gnu_ops): Set to_attach_no_wait in gnu_ops.
4889         * win32-nat.c (init_win32_ops): Set to_attach_no_wait in
4890         win32_ops.
4891
4892 2008-07-03  Pedro Alves  <pedro@codesourcery.com>
4893
4894         * i386-tdep.c (i386_displaced_step_fixup): Condition log printing
4895         on debug_displaced being set.
4896
4897 2008-06-30  Daniel Jacobowitz  <dan@codesourcery.com>
4898
4899         * frame.c (get_prev_frame_1): Call frame_unwind_find_by_frame
4900         directly instead of get_frame_id.
4901
4902 2008-06-30  Luis Machado  <luisgpm@br.ibm.com>
4903
4904         * rs6000-tdep.c (ppc_displaced_step_fixup): New function.
4905         (deal_with_atomic_sequence): Update BC masks.
4906         (rs6000_gdbarch_init): Init displaced stepping infra-structure.
4907         Define BRANCH_MASK, B_INSN, BC_INSN, BXL_INSN, BP_MASK and BP_INSN.
4908
4909 2008-06-30  Daniel Jacobowitz  <dan@codesourcery.com>
4910
4911         * cris-tdep.c (crisv32_single_step_through_delay): Get this frame's
4912         register, not the previous frame's.
4913
4914 2008-06-30  Luis Machado  <luisgpm@br.ibm.com>
4915
4916         * source.c (select_source_symtab): Make sure we skip namespace
4917         symtabs when showing cpp source code.
4918
4919 2008-06-30  Hans-Peter Nilsson  <hp@axis.com>
4920
4921         * MAINTAINERS (Authorized committers): Fix my email address.
4922
4923 2008-06-28  Vladimir Prus  <vladimir@codesourcery.com>
4924
4925         * mi/mi-cmds.c (mi_cmds): Route -exec-run, -exec-until,
4926         -target-download and -target-select via CLI, so that
4927         the quoting rules are the same as they were (unfortunately)
4928         in all prior gdb releases.
4929         * mi/mi-cmds.h (mi_cmd_exec_run, mi_cmd_exec_until)
4930         (mi_cmd_target_download, mi_cmd_target_select): Remove.
4931         * mi/mi-main.c (mi_cmd_exec_run, mi_cmd_exec_until)
4932         (mi_cmd_target_download, mi_cmd_target_select): Remove.
4933         (mi_cmd_execute): Set current_token even for commands
4934         routed via CLI.
4935
4936 2008-06-28  Ulrich Weigand  <uweigand@de.ibm.com>
4937
4938         * alphafbsd-tdep.c: Update for unwinder changes.
4939         * alpha-linux-tdep.c: Likewise.
4940         * alphanbsd-tdep.c: Likewise.
4941         * alphaobsd-tdep.c: Likewise.
4942         * avr-tdep.c: Likewise.
4943         * cris-tdep.c: Likewise.
4944         * frv-linux-tdep.c: Likewise.
4945         * frv-tdep.c: Likewise.
4946         * h8300-tdep.c: Likewise.
4947         * hppa-linux-tdep.c: Likewise.
4948         * iq2000-tdep.c: Likewise.
4949         * m32c-tdep.c: Likewise.
4950         * m32r-linux-tdep.c: Likewise.
4951         * m32r-tdep.c: Likewise.
4952         * m68hc11-tdep.c: Likewise.
4953         * mep-tdep.c: Likewise.
4954         * mn10300-tdep.c: Likewise.
4955         * mt-tdep.c: Likewise.
4956         * score-tdep.c: Likewise.
4957         * sh64-tdep.c: Likewise.
4958         * sh-tdep.c: Likewise.
4959         * sparc64fbsd-tdep.c: Likewise.
4960         * sparc64nbsd-tdep.c: Likewise.
4961         * sparc64obsd-tdep.c: Likewise.
4962         * v850-tdep.c: Likewise.
4963         * vaxobsd-tdep.c: Likewise.
4964         * vax-tdep.c: Likewise.
4965         * xstormy16-tdep.c: Likewise.
4966
4967 2008-06-28  Vladimir Prus  <vladimir@codesourcery.com>
4968
4969         * mi/mi-main.c (enum captured_mi_execute_command_actions)
4970         (captured_mi_execute_command_args): Remove.
4971         (captured_mi_execute_command): Cast the closure to mi_parse
4972         pointer, not to captured_mi_execute_command_args, and don't
4973         set the action field thereof.
4974         (mi_execute_command): Pass struct mi_parse, not
4975         captured_mi_execute_command_args to captured_mi_execute_command.
4976         (mi_execute_command): Remove (dead) code for suppressing
4977         printing prompt.
4978
4979 2008-06-28  Pedro Alves  <pedro@codesourcery.com>
4980
4981         * linux-nat.c (enum sigchld_state): New.
4982         (linux_nat_async_events_state): Renamed from
4983         linux_nat_async_events_enabled.
4984         (linux_nat_event_pipe_push, my_waitpid): Adjust.
4985         (sigchld_default_action): New.
4986         (lin_lwp_attach_lwp): Adjust.  Call linux_nat_async_events
4987         unconditionally.
4988         (linux_nat_create_inferior): Set events state to sigchld_default
4989         state.
4990         (linux_nat_resume): Adjust.
4991         (linux_nat_wait): Call linux_nat_async_events unconditionally.
4992         (sigchld_handler): Adjust.
4993         (linux_nat_async_mask): Don't set SIGCHLD actions here.
4994         (get_pending_events): Adjust.
4995         (linux_nat_async_events): Rewrite to handle enum sigchld_state
4996         instead of a boolean.
4997         (linux_nat_async): Adjust.
4998         (_initialize_linux_nat): Capture default SIGCHLD action into
4999         sigchld_default_action.
5000
5001 2008-06-28  Vladimir Prus  <vladimir@codesourcery.com>
5002
5003         * breakpoint.c (moribund_locations): New.
5004         (bpstat_stop_status): Process moribund locations.
5005         (update_global_location_list): Add removed
5006         locations to moribund_locations.
5007         (breakpoint_retire_moribund): New.
5008         * breakpoint.h (struct bp_location): New field
5009         events_till_retirement.
5010         (breakpoint_retire_moribund): Declare.
5011         * thread.c (thread_count): New.
5012         * infrun.c (handle_inferior_event): Call
5013         breakpoint_retire_moribund.
5014         * gdbthread.h (thread_count): Declare.
5015
5016 2008-06-27  Joseph Myers  <joseph@codesourcery.com>
5017
5018         * dfp.c (decimal_convert): Call match_endianness before and after
5019         conversion.
5020
5021 2008-06-27  Jonathan Larmour  <jifl@eCosCentric.com>
5022
5023         * remote.c (remote_insert_breakpoint): Ensure that if Z0
5024         unsupported and we fall back to memory_insert_breakpoint, we
5025         use the unmodified requested address.
5026
5027 2008-06-27  Joel Brobecker  <brobecker@adacore.com>
5028
5029         * dwarf2read.c (read_attribute_value): Issue a complaint when
5030         adjusting size attribute values of 0xffffffff as zero.
5031
5032 2008-06-27  Joseph Myers  <joseph@codesourcery.com>
5033
5034         * i386-tdep.c (i386_16_byte_align_p): New.
5035         (i386_push_dummy_call): Determine stack space required for
5036         arguments going forwards allowing for 16-byte alignment, then push
5037         arguments going forwards.
5038
5039 2008-06-27  Pedro Alves  <pedro@codesourcery.com>
5040
5041         * infrun.c (start_remote): Don't clear thread list here.
5042         * monitor.c (monitor_open): Include "gdbthread.h".  Clear thread
5043         list here.
5044         * remote.c (record_currthread): Upgrade the main thread and its
5045         entry in the thread list if this is the first time we hear about
5046         threads.
5047         (remote_thread_alive): Consider magic_null_ptid or a ptid without
5048         a tid member always alive.
5049         (remote_find_new_threads): Don't update the main thread here.
5050         (remote_start_remote): Clear thread list here.  Always add the
5051         main thread.
5052         (extended_remote_attach_1): Add the main thread here.
5053         (extended_remote_mourn_1): Re-add the main thread here.
5054         (extended_remote_create_inferior_1): Add a main thread.
5055
5056         * Makefile.in (monitor.o): Depend on $(gdbthread_h).
5057
5058 2008-06-27  Pedro Alves  <pedro@codesourcery.com>
5059
5060         Use ptid_t.tid to store thread ids instead of ptid_t.pid.
5061
5062         * remote.c (magic_null_ptid, not_sent_ptid, any_thread_ptid): New
5063         globals.
5064         (general_thread, continue_thread): Change type to ptid_t.
5065         (record_currthread): Take a ptid_t parameter instead of an
5066         integer.
5067         (MAGIC_NULL_PID): Delete.
5068         (set_thread): Take a ptid_t parameter and adjust.
5069         (set_general_thread, set_continue_thread): New.
5070         (remote_thread_alive, remote_newthread_step)
5071         (remote_current_thread, remote_find_new_threads)
5072         (remote_threads_info, remote_start_remote, remote_vcont_resume)
5073         (remote_resume_1, remote_wait, extended_remote_create_inferior_1)
5074         (threadalive_test, remote_pid_to_str)
5075         (remote_get_thread_local_address): Adjust.
5076         (_initialize_remote): Initialize magic_null_ptid, not_sent_ptid
5077         and any_thread_ptid.
5078
5079 2008-06-26  Jan Kratochvil  <jan.kratochvil@redhat.com>
5080
5081         * configure.ac (--enable-tui): AC_MSG_ERROR for explicit --enable-tui.
5082         * configure: Regenerated.
5083
5084 2008-06-26  Joel Brobecker  <brobecker@adacore.com>
5085
5086         * dwarf2read.c (read_attribute_value): Treat size attribute
5087         values of 0xffffffff as if the attribute value was zero.
5088
5089 2008-06-26  Vladimir Prus  <vladimir@codesourcery.com>
5090
5091         * linux-nat.c: Add description of overall logic.
5092
5093 2008-06-26  Daniel Jacobowitz  <dan@codesourcery.com>
5094
5095         * Makefile.in (GNULIB_H): Use GNULIB_STDINT_H.
5096         (gdb_stdint_h, gdb_stdint.h, stamp-int): Delete.  Remove
5097         all dependencies on $(gdb_stdint_h).
5098         (distclean): Do not delete gdb_stdint.h.
5099         * acinclude.m4: Do not use stdint.m4.
5100         * configure.ac: Set GNULIB_STDINT_H.  Remove tests for stdint.h,
5101         uintptr_t, and gdb_stdint.h.
5102         * defs.h: Include <stdint.h>.
5103         * gdb_thread_db.h: Assume stdint.h is already included.
5104         * breakpoint.c, findcmd.c, hppa-tdep.c, inf-ptrace.c, proc-service.c,
5105         rs6000-nat.c, spu-linux-nat.c, target.c, win32-nat.c: Do not
5106         include gdb_stdint.h.
5107         * configure, config.in: Regenerate.
5108
5109 2008-06-26  Joseph Myers  <joseph@codesourcery.com>
5110
5111         * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Handle passing
5112         decimal floating-point values in GPRs for soft-float.
5113         (do_ppc_sysv_return_value): Handle returning decimal
5114         floating-point values in GPRs for soft-float.
5115
5116 2008-06-26  Vladimir Prus  <vladimir@codesourcery.com>
5117
5118         * target.c (target_read_until_error): New.
5119         * target.h (target_read_until_error): Declare.
5120         * mi/mi-main.c (mi_cmd_data_read_memory): Use
5121         target_read_until_error.
5122
5123 2008-06-25  Jan Kratochvil  <jan.kratochvil@redhat.com>
5124
5125         Fix a memory leak found by Hui Zhu <teawater@gmail.com>.
5126         * c-exp.y (parse_number): Move the S and SAVED_CHAR initialization
5127         after the DECFLOAT detection to fix a memory leak.  Remove the
5128         redundant NUM initialization.  Protect the DECFLOAT detection memory
5129         access before the P block.  Restore the P memory content for the
5130         DECFLOAT detection.
5131
5132 2008-06-25  Vladimir Prus  <vladimir@codesourcery.com>
5133
5134         Kill the return value for all MI command functions.
5135         * mi/mi-cmds.h (enum mi_cmd_result): Remove.
5136         (mi_cmd_argv_ftype): Change return type to void.
5137
5138         * mi/mi-main.c: Adjust all function that implement
5139         MI commands to return nothing.
5140         (struct captured_mi_execute_command_actions):
5141         Remove the rc field.
5142         (mi_cmd_execute): Return nothing.
5143         (mi_execute_async_cli_command): Return nothing.
5144         (mi_cmd_exec_interrupt): Don't print ^done here.
5145         (mi_cmd_target_select): Don't print ^connected here.
5146         (captured_mi_execute_command): Don't check for MI_CMD_DONE.
5147         Special-case -target-select and output ^connected, not ^done.
5148
5149         * mi/mi-cmd-break.c: Adjust.
5150         * mi/mi-cmd-disas.c: Adjust.
5151         * mi/mi-cmd-env.c: Adjust.
5152         * mi/mi-cmd-file.c: Adjust.
5153         * mi/mi-cmd-stack.c: Adjust.
5154         * mi/mi-cmd-target.c: Adjust.
5155         * mi/mi-cmd-var.c: Adjust.
5156         * mi/mi-interp.c: Adjust.
5157         * mi/mi-symbol-cmds.c: Adjust.
5158
5159 2008-06-25  Vladimir Prus  <vladimir@codesourcery.com>
5160
5161         Emit ^running via observer.
5162         * mi/mi-interp.c (mi_cmd_interpreter_exec): Do no print
5163         ^running here.
5164         (mi_on_resume): Print ^running if not previously output.
5165         * mi/mi-main.c (running_result_record_printed): New.
5166         (captured_mi_execute_command): Reset
5167         running_result_record_printed.  Use running_result_record_printed
5168         to decide if we should skip ^done.
5169         (mi_execute_async_cli_command): Don't print ^running here.
5170         * mi/mi-main.h (current_token, running_result_record_printed):
5171         Declare.
5172
5173 2008-06-24  Michael Snyder  <msnyder@specifix.com>
5174
5175         * infrun.c (_initialize_infrun): White space and typo fix.
5176
5177 2008-06-23  Christopher Faylor  <me.gdb.changelog@cgf.cx>
5178
5179         * win32-nat.c (safe_symbol_file_add_stub): Remove unused variable.
5180         (do_initial_win32_stuff): Fix problem with inability to set breakpoints
5181         when first loading DLL with "dll" command.
5182
5183 2008-06-19  Pierre Muller  <muller@ics.u-strasbg.fr>
5184
5185         * gnu-nat.c (proc_string): Use capital T for "Thread".
5186
5187 2008-06-19  Pierre Muller  <muller@ics.u-strasbg.fr>
5188
5189         * win32-nat.c (win32_pid_to_str): Use capital T for "Thread".
5190
5191 2008-06-18  Joel Brobecker  <brobecker@adacore.com>
5192
5193         * solib-osf.c (osf_solib_create_inferior_hook): Do nothing if
5194         the target cannot run.
5195
5196 2008-06-18  Joel Brobecker  <brobecker@adacore.com>
5197
5198         * solib-osf.c (osf_solib_create_inferior_hook): Do nothing if
5199         we're attaching to a running process.
5200
5201 2008-06-18  Pierre Muller  <muller@ics.u-strasbg.fr>
5202
5203         * win32-nat.c (handle_load_dll): Give dll name and load address
5204         if debug_events is on.
5205         (handle_unload_dll): Likewise.
5206
5207 2008-06-14  Vladimir Prus  <vladimir@codesourcery.com>
5208
5209         Don't suppress *running when doing finish.
5210         * infcall.c (call_function_by_hand): Set both
5211         suppress_resume_observer and suppress_stop_observer.
5212         * infcmd.c (suppress_run_stop_observers): Split into...
5213         (suppress_resume_observer, suppress_stop_observer): ...those.
5214         (finish_command_continuation): Clear suppress_stop_observer.
5215         (finish_command): Set suppress_stop_observer.
5216         * inferior.h (suppress_run_stop_observers): Split into...
5217         (suppress_resume_observer, suppress_stop_observer): ...those.
5218         * infrun.c (normal_stop): Check for suppress_stop_observer.
5219         * thread.c (set_running): Check for suppress_resume_observer.
5220
5221 2008-06-12  Pedro Alves  <pedro_alves@portugalmail.pt>
5222             Pierre Muller  <muller@ics.u-strasbg.fr>
5223
5224         * gdbarch.sh (gdbarch_skip_main_prologue): New.
5225         * gdbarch.h, gdbarch.c: Regenerate.
5226         * i386-tdep.h (i386_skip_main_prologue): Declare.
5227         * i386-tdep.c (i386_skip_main_prologue): New.
5228         * i386-cygwin-tdep.c (i386_cygwin_init_abi): Register
5229         i386_skip_main_prologue as gdbarch_skip_main_prologue gdbarch callback.
5230         * symtab.c (find_function_start_sal): When pc points at the "main"
5231         function, call gdbarch_skip_main_prologue.
5232
5233 2008-06-11  Daniel Jacobowitz  <dan@codesourcery.com>
5234
5235         * value.c (value_primitive_field): Fetch lazy register values.
5236
5237 2008-06-11  Pedro Alves  <pedro@codesourcery.com>
5238
5239         * NEWS: Mention support removal of undocumented S AA p PID stop
5240         reply packet.
5241
5242         * remote.c (remote_wait): Remove undocumented S AA p PID support.
5243
5244 2008-06-10  Stan Shebs  <stan@codesourcery.com>
5245
5246         * MAINTAINERS: Update my affiliation and address.
5247
5248 2008-06-10  Andreas Schwab  <schwab@suse.de>
5249
5250         * top.c (print_gdb_version): Don't print final newline.
5251
5252 2008-06-10  Vladimir Prus  <vladimir@codesourcery.com>
5253
5254         Implement *running.
5255         * Makefile.in: Update dependencies.
5256         * gdbthread.h (struct thread_info): New field
5257         running_.
5258         (set_running, is_running): New.
5259         * thread.c (set_running, is_running): New.
5260         * inferior.h (suppress_normal_stop_observer): Rename to...
5261         (suppress_run_stop_observers): ..this.
5262         * infcmd.c (suppress_normal_stop_observer): Rename to...
5263         (suppress_run_stop_observers): ..this.
5264         (finish_command_continuation, finish_command): Adjust.
5265         * infcall.c (call_function_by_hand): Adjust.
5266         * infrun.c (normal_stop): Call set_running.
5267         * target.c (target_resume): New.  Call set_running.
5268         * target.h (target_resume): Convert from macro to
5269         a function.
5270
5271         * mi/mi-interp.c (mi_on_resume): New.
5272         (mi_interpreter_init): Register mi_on_resume.
5273
5274 2008-06-10  Vladimir Prus  <vladimir@codesourcery.com>
5275
5276         Use observers to report stop events in MI.
5277         * mi/mi-interp.c (mi_on_normal_stop): New.
5278         (mi_interpreter_init): Register mi_on_normal_stop.
5279         (mi_interpreter_exec_continuation): Remove.
5280         (mi_cmd_interpreter_exec): Don't register the above.
5281         * mi/mi-main.c (captured_mi_execute_command): Don't care
5282         about sync_execution.
5283         (mi_execute_async_cli_command): Don't install continuation.  Don't
5284         print *stopped.
5285         (mi_exec_async_cli_cmd_continuation): Remove.
5286
5287 2008-06-10  Vladimir Prus  <vladimir@codesourcery.com>
5288
5289         Suppress normal stop observer when it's problematic.
5290         * inferior.h (suppress_normal_stop_observer): New.
5291         * infcall.c (call_function_by_hand): Disable stop events when
5292         doing function calls.
5293         * infmcd.c (suppress_normal_stop_observer): New.
5294         (finish_command_continuation): Call normal_stop observer
5295         explicitly.
5296         (finish_command): Disable stop events inside proceed.
5297         * infrun.c (normal_stop): Don't call normal stop observer if
5298         suppressed of if multi-step is in progress.
5299
5300 2008-06-10  Vladimir Prus  <vladimir@codesourcery.com>
5301
5302         Remove stale code.
5303         * infrun.c (finish_command): Don't pass cleanup
5304         to continuation.
5305         (finish_command_continuation): Don't grab cleanup from
5306         the passed data, as we don't use, and cannot, use it anyway.
5307
5308 2008-06-10  Vladimir Prus  <vladimir@codesourcery.com>
5309
5310         Introduce common cleanup for restoring integers.
5311         * defs.h (make_cleanup_restore_integer): New declaration.
5312         (struct cleanup): New field free_arg.
5313         (make_my_cleanup_2): New.
5314         * utils.c (restore_integer_closure, restore_integer)
5315         (make_cleanup_restore_integer): New.
5316         (make_my_cleanup): Initialize the free_arg field and
5317         renamed to make_my_cleanup_2.
5318         (do_my_cleanups): Call free_arg.
5319         (discard_cleanups): Call free_arg.
5320         * breakpoint.c (restore_always_inserted_mode): Remove.
5321         (update_breakpoints_after_exec): Use make_cleanup_restore_integer.
5322
5323 2008-06-09  Doug Evans  <dje@google.com>
5324
5325         * remote.c (remote_wait): Include beginning of malformed packet
5326         in error output.
5327
5328 2008-06-09  Tom Tromey  <tromey@redhat.com>
5329
5330         * completer.c (complete_line): Don't special-case
5331         expression_completer.
5332         (expression_completer): Only pass last word to
5333         location_completer.
5334         * c-exp.y (yylex): Check 'token', not 'operator'.
5335
5336 2008-06-09  Daniel Jacobowitz  <dan@codesourcery.com>
5337
5338         * configure.ac (build_warnings): Add -Wno-format for mingw.
5339         * configure: Regenerated.
5340
5341 2008-06-07  Daniel Jacobowitz  <dan@codesourcery.com>
5342
5343         * NEWS: Make indentation consistent.  Move exec tracing entry out
5344         of remote packet list.
5345
5346 2008-06-06  Tom Tromey  <tromey@redhat.com>
5347
5348         * value.h (evaluate_subexpression_type, extract_field_op):
5349         Declare.
5350         * printcmd.c (_initialize_printcmd): Use expression_completer for
5351         'p', 'inspect', 'call'.
5352         * parser-defs.h (parse_field_expression): Declare.
5353         * parse.c: Include exceptions.h.
5354         (in_parse_field, expout_last_struct): New globals.
5355         (mark_struct_expression): New function.
5356         (prefixify_expression): Return int.
5357         (prefixify_subexp): Return int.  Use expout_last_struct.
5358         (parse_exp_1): Update.
5359         (parse_exp_in_context): Add 'out_subexp' argument.  Handle
5360         in_parse_field.
5361         (parse_field_expression): New function.
5362         * expression.h (parse_field_expression): Declare.
5363         (in_parse_field): Likewise.
5364         * eval.c (evaluate_subexpression_type): New function.
5365         (extract_field_op): Likewise.
5366         * completer.h (expression_completer): Declare.
5367         * completer.c (expression_completer): New function.
5368         (count_struct_fields, add_struct_fields): New functions.
5369         * c-exp.y (yyparse): Redefine.
5370         (COMPLETE): New token.
5371         (exp): New productions.
5372         (saw_name_at_eof, last_was_structop): New globals.
5373         (yylex): Return COMPLETE when needed.  Recognize in_parse_field.
5374         (c_parse): New function.
5375         * breakpoint.c (_initialize_breakpoint): Use expression_completer
5376         for watch, awatch, and rwatch.
5377         * Makefile.in (parse.o): Depend on exceptions_h.
5378
5379 2008-06-06  Paul Pluzhnikov  <ppluzhnikov@google.com>
5380
5381         PR gdb/1147
5382         * gdb/valopts.c (find_overload_match): Handle references
5383         to pointers.
5384
5385 2008-06-06  Paul N. Hilfinger  <hilfinger@adacore.com>
5386
5387         * ada-lang.c (ada_value_assign): Correct big-endian case to take into
5388         account the bitsize of the 'from' operand.
5389
5390 2008-06-06  Pedro Alves  <pedro@codesourcery.com>
5391
5392         * annotate.h (annotate_thread_changed): Declare.
5393
5394 2008-06-06  Nick Roberts  <nickrob@snap.net.nz>
5395
5396         * annotate.c (annotate_thread_changed): New function.
5397         * thread.c (thread_command) : Use it.
5398         * infrun.c (normal_stop): Use it.
5399
5400 2008-06-05  Vladimir Prus  <vladimir@codesourcery.com>
5401             Nathan Sidwell  <nathan@codesourcery.com>
5402             Joseph Myers  <joseph@codesourcery.com>
5403
5404         * acinclude.m4: Include ../config/acx.m4.
5405         * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
5406         * configure, config.in: Regenerate.
5407         * main.c (print_gdb_help): Use REPORT_BUGS_TO for bug-reporting
5408         address.
5409         * top.c (print_gdb_version): Use PKGVERSION and REPORT_BUGS_TO.
5410
5411 2008-06-05  Pedro Alves  <pedro@codesourcery.com>
5412
5413         Replace 'target async' by 'maintenance set remote-async' and
5414         'target remote' combination.
5415
5416         * remote.c (remote_async_wait): Merge into remote_wait, and
5417         remove.
5418         (remote_async_permitted, remote_async_permitted_set): New
5419         variables.
5420         (set_maintenance_remote_async_permitted)
5421         (show_maintenance_remote_async_permitted): New functions.
5422         (remote_async_ops, extended_async_remote_ops): Delete.
5423         (remote_async_open, extended_remote_async_open): Delete.
5424         (remote_open_1): Drop async_p parameter.  Update callers.  Replace
5425         async_p with remote_async_permitted checks.
5426         (extended_async_remote_attach): Delete.
5427         (remote_resume, remote_async_resume): Merge and leave remote_resume.
5428         (remote_async_terminal_inferior): Rename to...
5429         (remote_terminal_inferior): ... this, and add
5430         remote_async_termitted check.
5431         (remote_async_terminal_ours): Rename to...
5432         (remote_terminal_ours): ... this, and add remote_async_termitted
5433         check.
5434         (remote_wait, remote_async_wait): Merge and leave remote_wait
5435         only.
5436         (remote_kill, remote_async_kill): Merge and leave remote_kill
5437         only.
5438         (remote_async_mourn, extended_async_remote_mourn): Delete.
5439         (extended_remote_create_inferior_1): Drop async_p parameter.
5440         Update callers.  Always use extended_remote_ops.
5441         (extended_remote_async_create_inferior): Delete.
5442         (remote_return_zero): Delete.
5443         (init_remote_ops): Register remote_can_async_p, remote_async,
5444         remote_async_mask, remote_terminal_inferior and
5445         remote_terminal_ours.
5446         (remote_can_async_p, remote_is_async_p): Check for
5447         remote_async_permitted.
5448         (init_remote_async_ops, init_extended_async_remote_ops): Remove.
5449         (set_remote_cmd): Don't add async and extended-async targets.
5450         (_initialize_remote): Add set/show remote-async maintenance
5451         commands.
5452
5453 2008-06-05  Pedro Alves  <pedro@codesourcery.com>
5454
5455         * remote.c (kill_kludge): Delete.
5456         (remote_wait, remote_async_wait): Don't set it.
5457         (remote_kill, remote_async_kill): Don't do anything with it.
5458
5459 2008-06-05  Pedro Alves  <pedro@codesourcery.com>
5460
5461         * linux-thread-db.c (thread_db_wait): Don't trim event ptid.
5462
5463 2008-06-05  Aleksandar Ristovski  <aristovski@qnx.com>
5464
5465         * bcache.c (bcache_data): Call deprecated_bcache_added function.
5466         (deprecated_bcache_added): New function name. Body of function
5467         bcache_data is used here with the addition of 'added' argument.
5468         * bcache.h (deprecated_bcache_added): New function.
5469         * symfile.c (add_psymbol_to_bcache): New helper function, takes part of
5470         work from add_psymbol_to_list - initialises partial symbol and stashes
5471         it in objfile's cache.
5472         (append_psymbol_to_list): New helper function, takes other part of
5473         work from add_psymbol_to_list - adds partial symbol to the given list.
5474         (add_psymbol_to_list): Call helper functions instead of doing work
5475         here. If adding to global list, do not duplicate partial symbols in the
5476         partial symtab.
5477
5478 2008-06-05  Aleksandar Ristovski  <aristovski@qnx.com>
5479
5480         * breakpoint.c (print_exception_catchpoint): Put 'exception' back to
5481         'exception caught|thrown' message.
5482
5483 2008-06-05  Jan Kratochvil  <jan.kratochvil@redhat.com>
5484
5485         * Makefile.in: Update dependencies.
5486         * dwarf2expr.c: New include "gdb_assert.h".
5487         (new_dwarf_expr_context): Initialize MAX_RECURSION_DEPTH.
5488         (dwarf_expr_eval): Sanity check the RECURSION_DEPTH count.
5489         (execute_stack_op): Error out on too large RECURSION_DEPTH.
5490         Increase/decrease RECURSION_DEPTH around the function.
5491
5492 2008-06-05  Daniel Jacobowitz  <dan@codesourcery.com>
5493
5494         * remote.c (get_offsets): Handle a single segment.
5495         * symfile.c (symfile_map_offsets_to_segments): Allow more bases
5496         than segments.
5497
5498 2008-06-03  Daniel Jacobowitz  <dan@codesourcery.com>
5499
5500         * solib-svr4.c (struct lm_info): Add lm_addr.
5501         (main_lm_addr): New.
5502         (svr4_default_sos): Set lm_addr.
5503         (svr4_current_sos): Set lm_addr and main_lm_addr.
5504         (svr4_fetch_objfile_link_map): Rewrite.
5505         (svr4_clear_solib): Clear main_lm_addr.
5506
5507 2008-06-03  Michael Snyder  <msnyder@redhat.com>
5508             Joseph Myers  <joseph@codesourcery.com>
5509
5510         * mips-tdep.c (mips_eabi_return_value): Replace stub that always
5511         returned RETURN_VALUE_STRUCT_CONVENTION with a real function.
5512
5513 2008-06-02  Roman Zippel <zippel@linux-m68k.org>
5514
5515         * m68klinux-tdep.c (m68k_linux_pc_in_sigtramp): Fix incorrect test.
5516
5517 2008-06-02  Roman Zippel <zippel@linux-m68k.org>
5518
5519         * m68k-tdep.c (m68k_analyze_prologue): Fix length of lea insn.
5520
5521 2008-06-01  Joel Brobecker  <brobecker@adacore.com>
5522
5523         * rs6000-aix-tdep.c (rs6000_convert_from_func_ptr_addr): Do not
5524         treat pointers in data space as function descriptors if the
5525         target address is also in the data space.
5526
5527 2008-05-30  Joel Brobecker  <brobecker@adacore.com>
5528
5529         * alpha-tdep.c (alpha_heuristic_frame_unwind_cache): Set
5530         the trad-frame register value for the SP register.
5531
5532 2008-05-29  Mark Kettenis  <kettenis@gnu.org>
5533
5534         * sparcnbsd-tdep.c, sparcobsd-tdep.c: Update for unwinder changes.
5535
5536 2008-05-28  Joel Brobecker  <brobecker@adacore.com>
5537
5538         * ia64-tdep.c (ia64_convert_from_func_ptr_addr): Improve the heuristic
5539         that identifies function descriptors outside of the .opd section.
5540
5541 2008-05-28  Aleksandar Ristovski  <aristovski@qnx.com>
5542
5543         * breakpoint.c (print_exception_catchpoint): In CLI add 'Temporary' for
5544         temporary catchpoints.  In MI add missing fields 'reason', 'disp',
5545         'bkptno'.
5546         (print_mention_exception_catchpoint): Add 'Temporary' for temporary
5547         catchpoints.
5548         (handle_gnu_v3_exceptions): Use tempflag.
5549
5550 2008-05-28  Vladimir Prus  <vladimir@codesourcery.com>
5551
5552         Refactor varobj_update interface.
5553         * varobj.c (varobj_update): Report changes as vector.  Also
5554         return not just a list of varobj, but a list of special structures
5555         that tell what exactly has changed.
5556         * varobj.h (enum varobj_update_error): Rename to
5557         varobj_scope_status.
5558         (struct varobj_update_result_t): New.
5559         (varobj_update): Adjust prototype.
5560         * mi/mi-cmd-var.c: Adjust for changes.
5561
5562 2008-05-28  Vladimir Prus  <vladimir@codesourcery.com>
5563
5564         * varobj.c (varobj_update): Fix comment typo.
5565         Fix indentation.
5566
5567 2008-05-26  Joel Brobecker  <brobecker@adacore.com>
5568
5569         Set the symtab field of symbols read from ECOFF debugging entries.
5570         * mdebugread.c (add_symbol): Add new parameter symtab.
5571         (parse_symbol): Update calls to add_symbol throughout.
5572
5573 2008-05-27  Andreas Schwab  <schwab@suse.de>
5574
5575         * symtab.h (enum address_class): Remove LOC_REGPARM and
5576         LOC_COMPUTED_ARG.
5577         (struct symbol): Add is_argument.
5578         (SYMBOL_IS_ARGUMENT): Define.
5579
5580         * ada-lang.c (ada_add_block_symbols): Use SYMBOL_IS_ARGUMENT.
5581         * buildsym.c (finish_block): Likewise.
5582         * stack.c (print_frame_args, print_block_frame_locals)
5583         (print_frame_arg_vars): Likewise.
5584         * symtab.c (lookup_block_symbol): Likewise.
5585         * tracepoint.c (add_local_symbols): Likewise.
5586         * mi/mi-cmd-stack.c (list_args_or_locals): Likewise.
5587
5588         * coffread.c (process_coff_symbol): Set SYMBOL_IS_ARGUMENT.
5589         * dwarf2read.c (new_symbol): Likewise.
5590         * mdebugread.c (parse_symbol): Likewise.
5591         * stabsread.c (define_symbol): Likewise.
5592
5593         * ada-exp.y (select_possible_type_sym): Don't handle LOC_REGPARM
5594         and LOC_COMPUTED_ARG.
5595         * ada-lang.c (resolve_subexp, symtab_for_sym): Likewise.
5596         * ax-gdb.c (gen_var_ref): Likewise.
5597         * eval.c (evaluate_subexp_for_address): Likewise.
5598         * findvar.c (symbol_read_needs_frame, read_var_value): Likewise.
5599         * m2-exp.y (yylex): Likewise.
5600         * printcmd.c (address_info): Likewise.
5601         * symmisc.c (print_symbol, print_partial_symbols): Likewise.
5602         * tracepoint.c (collect_symbol, scope_info): Likewise.
5603
5604 2008-05-24  Carlos Eduardo Seo  <cseo@linux.vnet.ibm.com>
5605
5606         * gdbarch.sh: Added new gdbarch struct
5607         core_regset_sections.
5608         * gdbarch.c: Refreshed.
5609         * gdbarch.h: Refreshed.
5610         * regset.h (core_regset_section): Declared.
5611         * linux-nat.c (linux_nat_do_thread_registers): Added
5612         support for the new gdbarch struct core_regset_sections.
5613         * utils.c (host_address_to_string): New function.
5614         * defs.h (host_address_to_string): New prototype.
5615         * i386-linux-tdep.c (i386_regset_rections): New register
5616         sections list for i386.
5617           (i386_linux_init_abi): Initialized new gdbarch struct
5618           core_regset_sections.
5619         * Makefile.in: Updated to reflect dependency changes.
5620         * ppc-linux-tdep.c (ppc_regset_sections): Register
5621         sections list for ppc.
5622           (ppc_linux_init_abi): Initialized new gdbarch struct
5623           core_regset_sections
5624
5625 2008-05-24  Andreas Schwab  <schwab@suse.de>
5626
5627         * linespec.c (decode_objc): Save current language around call to
5628         get_selected_block.
5629
5630 2008-05-23  Joel Brobecker  <brobecker@adacore.com>
5631
5632         * valprint.h (get_array_bounds): Renames get_array_low_bound.
5633         * valprint.c (get_array_bounds): Renames get_array_low_bound.
5634         Return the proper bound value if the array index type is an
5635         enumerated type. Compute the high bound if requested.
5636         (val_print_array_elements): Handle the case when the array
5637         element has a null size.
5638         * ada-valprint.c (print_optional_low_bound): Add handling
5639         for empty arrays or arrays of zero-size elements.
5640         (ada_val_print_array): New function, extracted out from
5641         ada_val_print_1 case TYPE_CODE_ARRAY, and enhanced to
5642         handle empty arrays and arrays of zero-size elements.
5643         (ada_val_print_1)[case TYPE_CODE_ARRAY]: Replace extracted-out
5644         code by call to ada_val_print_array.
5645         (ada_value_print): Remove handling of null array.  The handling
5646         was incomplete and is now better handled by ada_val_print_array.
5647
5648 2008-05-23 Markus Deuling  <deuling@de.ibm.com>
5649
5650         * annotate.c (annotate_source, annotate_frame_begin): Replace
5651         deprecated_print_address_numeric with paddress.
5652         * cli/cli-cmds.c (list_command, edit_command): Likewise.
5653         * tui/tui-stack.c (tui_make_status_line): Likewise.
5654
5655         * defs.h (deprecated_print_address_numeric): Remove.
5656         * printcmd.c (deprecated_print_address_numeric): Remove.
5657         * maint.c (maint_print_section_info): Fix comment.
5658
5659 2008-05-23 Markus Deuling  <deuling@de.ibm.com>
5660
5661         * valprint.c (print_hex_chars, print_octal_chars, print_decimal_chars,
5662         print_binary_chars, print_char_chars): Add byte_order parameter and
5663         replace gdbarch_byte_order.
5664         (print_decimal_chars): Replace START_P, NOT_END_P and NEXT_P by their
5665         expressions and remove them.  Remove unused TWO_TO_FOURTH.
5666         (val_print_type_code_int): Introduce gdbarch_byte_order to get at the
5667         endianness.  Update call to print_hex_chars.
5668         * valprint.h (print_hex_chars, print_octal_chars, print_decimal_chars,
5669         print_binary_chars, print_char_chars): Add byte_order parameter.
5670         * printcmd.c (print_scalar_formatted): Introduce gdbarch_byte_order to
5671         get at the endianness.  Update print_*_char calls to use byte_order.
5672
5673 2008-05-22  Ulrich Weigand  <uweigand@de.ibm.com>
5674
5675         * symtab.h (struct symbol): Make "aux_value" member a void pointer
5676         instead of a union.
5677         (SYMBOL_LOCATION_BATON): Update.
5678
5679 2008-05-22  Ulrich Weigand  <uweigand@de.ibm.com>
5680
5681         * symtab.h (enum address_class): Remove LOC_BASEREG and
5682         LOC_BASEREG_ARG.
5683         (struct symbol): Remove "basereg" member of "aux_value" union.
5684         (SYMBOL_BASEREG): Remove.
5685
5686         * ada-exp.y (select_possible_type_sym): Do not handle LOC_BASEREG
5687         or LOC_BASEREG_ARG.
5688         * ada-lang.c (resolve_subexp, symtab_for_sym): Likewise.
5689         (ada_add_block_symbols): Likewise.
5690         * ax-gdb.c (gen_var_ref): Likewise.
5691         * buildsym.c (finish_block): Likewise.
5692         * findvar.c (symbol_read_needs_frame, read_var_value): Likewise.
5693         * m2-exp.y (yylex): Likewise.
5694         * mi/mi-cmd-stack.c (list_args_or_locals): Likewise.
5695         * printcmd.c (address_info): Likewise.
5696         * stack.c (print_frame_args, print_block_frame_locals): Likewise.
5697         (print_frame_arg_vars): Likewise.
5698         * symmisc.c (print_symbol): Likewise.
5699         * symtab.c (lookup_block_symbol): Likewise.
5700         * tracepoint.c (collect_symbol, add_local_symbols): Likewise.
5701         (scope_info): Likewise.
5702
5703 2008-05-22  Ulrich Weigand  <uweigand@de.ibm.com>
5704
5705         * symtab.h (enum address_class): Remove LOC_LOCAL_ARG.
5706
5707         * ada-exp.y (select_possible_type_sym): Do not handle LOC_LOCAL_ARG.
5708         * ada-lang.c (resolve_subexp, symtab_for_sym): Likewise.
5709         (ada_add_block_symbols): Likewise.
5710         * ax-gdb.c (gen_var_ref): Likewise.
5711         * buildsyms.c (finish_block): Likewise.
5712         * findvar.c (symbol_read_needs_frame, read_var_value): Likewise.
5713         * m2-exp.y (yylex): Likewise.
5714         * mi/mi-cmd-stack.c (list_args_or_locals): Likewise.
5715         * printcmd.c (address_info): Likewise.
5716         * stack.c (print_frame_args, print_frame_arg_vars): Likewise.
5717         * symmisc.c (print_symbol, print_partial_symbols): Likewise.
5718         * symtab.c (lookup_block_symbol): Likewise.
5719         * tracepoint.c (collect_symbol, add_local_symbols): Likewise.
5720         (scope_info): Likewise.
5721
5722 2008-05-22  Ulrich Weigand  <uweigand@de.ibm.com>
5723
5724         * symtab.h (enum address_class): Remove LOC_INDIRECT and
5725         LOC_HP_THREAD_LOCAL_STATIC.
5726
5727         * findvar.c (symbol_read_needs_frame, read_var_value): Do not
5728         handle LOC_INDIRECT or LOC_HP_THREAD_LOCAL_STATIC.
5729         (read_var_value): Likewise.
5730         * buildsym.c (finish_block): Likewise.
5731         * objfiles.c (objfile_relocate): Likewise.
5732         * printcmd.c (address_info): Likewise.
5733         * symmisc.c (print_symbol, print_partial_symbols): Likewise.
5734         * tracepoint.c (scope_info): Likewise.
5735
5736 2008-05-21 Markus Deuling  <deuling@de.ibm.com>
5737            Maxim Grigoriev  <maxim2405@gmail.com>
5738
5739         * xtensa-tdep.c (xtensa_read_register): Remove.
5740         (xtensa_frame_cache): Get rid of xtensa_read_register. Pass extra
5741         argument litbase to call0_frame_cache().
5742         (call0_track_op, call0_analyze_prologue)
5743         (call0_frame_cache): Use extra argument litbase.
5744
5745 2008-05-21  Joel Brobecker  <brobecker@adacore.com>
5746
5747         * infcmd.c (_initialize_infcmd): Add new "fin" alias for "finish".
5748
5749 2008-05-21  Ulrich Weigand  <uweigand@de.ibm.com>
5750
5751         * frame.h (SIZEOF_FRAME_SAVED_REGS): Remove.
5752
5753 2008-05-21  Ulrich Weigand  <uweigand@de.ibm.com>
5754
5755         * alpha-mdebug-tdep.c: Include "trad-frame.h".
5756         (struct alpha_mdebug_unwind_cache): Change type of SAVED_REGS to
5757         struct trad_frame_saved_reg *.
5758         (alpha_mdebug_frame_unwind_cache): Allocate SAVED_REGS using
5759         trad_frame_alloc_saved_regs.  Update accesses.  Record previous
5760         value of SP as being vfp.
5761         (alpha_mdebug_frame_prev_register): Use trad_frame_get_prev_register.
5762         * Makefile.in (alpha-mdebug-tdep.o): Update dependencies.
5763
5764 2008-05-21  Markus Deuling  <deuling@de.ibm.com>
5765
5766         * score-tdep.c (score_print_insn): Get the current endianess from
5767         disassemble_info instead of gdbarch_byte_order.
5768
5769 2008-05-21  Pedro Alves  <pedro@codesourcery.com>
5770
5771         * frame.c (get_prev_frame_1): Build frame id before setting
5772         this_frame->prev_p, not after.
5773
5774 2008-05-21  Nick Roberts  <nickrob@snap.net.nz>
5775
5776         * annotate.c (annotate_new_thread): New function for new-thread
5777         annotation.
5778         * annotate.h: (annotate_new_thread): New extern.
5779         * thread.c (add_thread_with_info): Use it.
5780         * Makefile.in (thread.o): Add dependency on annotate.h.
5781
5782 2008-05-20  Joel Brobecker  <brobecker@adacore.com>
5783
5784         * win32-nat.c (win32_wait): Block the control-c event while
5785         waiting for a debug event.
5786
5787 2008-05-19  Pedro Alves  <pedro@codesourcery.com>
5788
5789         * symtab.h (lookup_symbol_in_language): Update comment.
5790         * symtab.c (lookup_symbol_aux_block): Update comment.
5791         * ada-lang.c (ada_lookup_symbol_list): Update comment.
5792
5793 2008-05-19  Ulrich Weigand  <uweigand@de.ibm.com>
5794
5795         * symtab.h (lookup_symbol_in_language): Remove SYMTAB parameter.
5796         (lookup_symbol): Likewise.
5797         * symtab.c (lookup_symbol_in_language): Remove SYMTAB parameter.
5798         (lookup_symbol): Likewise.
5799         (search_symbols): Update.
5800
5801         * linespec.c (find_methods, collect_methods): Update.
5802         (add_matching_methods, add_constructors): Update.
5803         (decode_compound, decode_dollar, decode_variable): Update.
5804         (lookup_prefix_sym): Update.
5805
5806         (symbol_found): Remove SYM_SYMTAB parameter.
5807         Use SYMBOL_SYMTAB (sym) instead.
5808
5809         * gdbtypes.c (lookup_typename): Update.
5810         (lookup_struct, lookup_union, lookup_enum): Update.
5811         (lookup_template_type): Update.
5812         (check_typedef): Update.
5813         * language.c (lang_bool_type): Update.
5814         * mdebugread.c (parse_procedure): Update.
5815         * mi/mi-cmd-stack.c (list_args_or_locals): Update.
5816         * parse.c (write_dollar_variable): Update.
5817         * printcmd.c (address_info): Update.
5818         * source.c (select_source_symtab): Update.
5819         * stack.c (print_frame_args, print_frame_arg_vars): Update.
5820         * valops.c (find_function_in_inferior): Update.
5821         (value_struct_elt_for_reference): Update.
5822         * value.c (value_static_field, value_fn_field): Update.
5823
5824         * alpha-mdebug-tdep.c (find_proc_desc): Update.
5825         * arm-tdep.c (arm_skip_prologue): Update.
5826         * mt-tdep.c (mt_skip_prologue): Update.
5827         * xstormy16-tdep.c (xstormy16_skip_prologue): Update.
5828
5829         * ada-lang.h (struct ada_symbol_info): Remove SYMTAB member.
5830         * ada-lang.c (ada_add_block_symbols): Remove SYMTAB parameter.
5831         (add_defn_to_vec): Likewise.
5832         (ada_add_block_symbols): Likewise.
5833         (lookup_cached_symbol, cache_symbol): Likewise.
5834         (standard_lookup): Update.
5835         (ada_lookup_symbol_list): Update.
5836
5837         * c-valprint.c (c_val_print): Update.
5838         * cp-support.c (cp_lookup_rtti_type): Update.
5839         * jv-lang.c (java_lookup_class, get_java_object_type): Update.
5840         * objc-lang.c (lookup_struct_typedef, find_imps): Update.
5841         * p-valprint.c (pascal_val_print): Update.
5842         * scm-lang.c (scm_lookup_name): Update.
5843
5844         * c-exp.y: Update.
5845         * f-exp.y: Update.
5846         * jv-exp.y: Update.
5847         * m2-exp.y: Update.
5848         * objc-exp.y: Update.
5849         * p-exp.y: Update.
5850
5851 2008-05-19  Ulrich Weigand  <uweigand@de.ibm.com>
5852
5853         * language.h (struct language_defn): Remove SYMTAB parameter from
5854         la_lookup_symbol_nonlocal callback function pointer.
5855
5856         * ada-lang.h (ada_lookup_encoded_symbol): Remove SYMTAB parameter.
5857         (ada_lookup_encoded_symbol): Likewise.
5858         * ada-lang.c (ada_lookup_encoded_symbol): Remove SYMTAB parameter.
5859         Always call fixup_symbol_section.
5860         (ada_lookup_symbol): Remove SYMTAB parameter.
5861         (ada_lookup_symbol_nonlocal): Likewise.
5862         * ada-exp.y (write_object_renaming): Update.
5863         (find_primitive_type): Likewise.
5864
5865         * cp-support.h (cp_lookup_symbol_nonlocal): Remove SYMTAB parameter.
5866         (cp_lookup_symbol_namespace): Likewise.
5867         * cp-namespace.c (lookup_namespace_scope): Remove SYMTAB parameter.
5868         (lookup_symbol_file): Likewise.
5869         (lookup_possible_namespace_symbol): Likewise.
5870         (cp_lookup_symbol_nonlocal): Likewise.
5871         (cp_lookup_symbol_namespace): Likewise.
5872         (cp_lookup_nested_type): Update.
5873
5874         * scm-valprint.c (scm_inferior_print): Update.
5875         * valops.c (value_maybe_namespace_elt): Update.
5876
5877         * solist.h (struct target_so_ops): Remove SYMTAB parameter from
5878         lookup_lib_global_symbol callback function pointer.
5879         (solib_global_lookup): Remove SYMTAB parameter.
5880         * solib.c (solib_global_lookup): Remove SYMTAB parameter.
5881         * solib-svr4.c (elf_lookup_lib_symbol): Likewise.
5882
5883         * symtab.h (basic_lookup_symbol_nonlocal): Remove SYMTAB parameter.
5884         (lookup_symbol_static): Likewise.
5885         (lookup_symbol_global): Likewise.
5886         (lookup_symbol_aux_block): Likewise.
5887         (lookup_global_symbol_from_objfile): Likewise.
5888         * symtab.c (lookup_symbol_aux): Remove SYMTAB parameter.
5889         (lookup_symbol_aux_local): Likewise.
5890         (lookup_symbol_aux_block): Likewise.
5891         (lookup_symbol_aux_symtabs): Likewise.
5892         (lookup_symbol_aux_psymtabs): Likewise.
5893         (lookup_global_symbol_from_objfile): Likewise.
5894         (basic_lookup_symbol_nonlocal): Likewise.
5895         (lookup_symbol_static): Likewise.
5896         (lookup_symbol_global): Likewise.
5897
5898         (lookup_symbol_in_language): Do not pass SYMTAB to lookup_symbol_aux.
5899
5900 2008-05-17  Pedro Alves  <pedro@codesourcery.com>
5901
5902         * remote.c (init_extended_remote_ops): Fix typo.
5903
5904 2008-05-16  Pedro Alves  <pedro@codesourcery.com>
5905
5906         * NEWS: Mention new DICOS x86 target configuration.
5907
5908 2008-05-16  Pedro Alves  <pedro@codesourcery.com>
5909             Ulrich Weigand  <uweigand@de.ibm.com>
5910
5911         * minsyms.c (lookup_minimal_symbol_by_pc_name): New function.
5912         * symtab.h (lookup_minimal_symbol_by_pc_name): Add prototype.
5913
5914         * symtab.c (fixup_section): Remove prototype.  Add ADDR parameter;
5915         use it instead of ginfo->value.address.  Look up minimal symbol by
5916         address and name.  Assume OBJFILE is non-NULL.
5917         (fixup_symbol_section): Ensure we always have an objfile to look
5918         into.  Extract and pass to fixup_section the symbol's address that
5919         will match the minimal symbol's address.
5920         (fixup_psymbol_section): Likewise.
5921
5922         (find_pc_sect_psymtab): Fall back to non-addrmap case when debugging
5923         overlays and the addrmap returned the wrong section.
5924
5925         * dwarf2read.c (var_decode_location): Set SYMBOL_CLASS before
5926         calling fixup_symbol_section.
5927
5928 2008-05-16  Ulrich Weigand  <uweigand@de.ibm.com>
5929
5930         * minsyms.c: Include "target.h".
5931         (find_solib_trampoline_target): Handle minimal symbols pointing
5932         to function descriptors as well.
5933         * Makefile.in (minsyms.o): Update dependencies.
5934
5935         * ppc-linux-tdep.c (ppc64_standard_linkage): Rename to ...
5936         (ppc64_standard_linkage1): ... this.  Fix optional instructions.
5937         (PPC64_STANDARD_LINKAGE_LEN): Rename to ...
5938         (PPC64_STANDARD_LINKAGE1_LEN): ... this.
5939         (ppc64_standard_linkage2, ppc64_standard_linkage3): New.
5940         (PPC64_STANDARD_LINKAGE2_LEN, PPC64_STANDARD_LINKAGE3_LEN): New.
5941         (ppc64_standard_linkage_target): Rename to ...
5942         (ppc64_standard_linkage1_target): ... this.
5943         (ppc64_standard_linkage2_target, ppc64_standard_linkage3_target): New.
5944         (ppc64_skip_trampoline_code): Support three variants of standard
5945         linkage stubs.  Call find_solib_trampoline_target to handle
5946         glink stubs.
5947
5948 2008-05-16  Ulrich Weigand  <uweigand@de.ibm.com>
5949
5950         * ppc-linux-tdep.c (ppc_linux_init_abi): Do not install
5951         ppc64_sysv_abi_adjust_breakpoint_address.
5952         * ppc-sysv-tdep.c (ppc64_sysv_abi_adjust_breakpoint_address): Remove.
5953         * ppc-tdep.h (ppc64_sysv_abi_adjust_breakpoint_address): Remove.
5954
5955 2008-05-16  Ulrich Weigand  <uweigand@de.ibm.com>
5956
5957         * ppc-linux-tdep.c (ppc_linux_skip_trampoline_code): Remove.
5958         (ppc_linux_init_abi): Install find_solib_trampoline_target instead
5959         of ppc_linux_skip_trampoline_code.
5960
5961 2008-05-15  Daniel Jacobowitz  <dan@codesourcery.com>
5962
5963         * gdbarch.sh: Delete dwarf_reg_to_regnum.
5964         * gdbarch.c, gdbarch.h: Regenerated.
5965         * amd64-tdep.c, arm-tdep.c, h8300-tdep.c, hppa-linux-tdep.c,
5966         hppa-tdep.c, i386-tdep.c, m32c-tdep.c, m68k-tdep.c, mips-tdep.c,
5967         s390-tdep.c, xtensa-tdep.c: Do not set dwarf_reg_to_regnum.
5968
5969 2008-05-15  Pedro Alves  <pedro@codesourcery.com>
5970
5971         * linux-nat.c (trap_ptid): Delete.
5972         (linux_nat_detach, linux_nat_wait, linux_nat_mourn_inferior):
5973         Adjust.
5974         * linux-thread-db.c (thread_db_wait): Adjust.
5975
5976 2008-05-15  Joel Brobecker  <brobecker@adacore.com>
5977
5978         * linespec.c (decode_line_1): Fix a couple of comments.
5979
5980 2008-05-15  Alan Modra  <amodra@bigpond.net.au>
5981
5982         * dbxread.c: Formatting.
5983         (INTERNALIZE_SYMBOL): Init n_other.
5984         (set_namestring): Take pointer to nlist arg rather than struct
5985         copy.  Update all callers.
5986
5987 2008-05-15  Andreas Schwab  <schwab@suse.de>
5988
5989         * Makefile.in (dwarf2loc.o): Remove $(addrmap_h).
5990         (dwarf2read.o): Add $(addrmap_h).
5991
5992 2008-05-14  Ulrich Weigand  <uweigand@de.ibm.com>
5993
5994         * ppc-linux-tdep.c (ppc_linux_convert_from_func_ptr_addr): Rename ...
5995         (ppc64_linux_convert_from_func_ptr_addr): ... to this.  No longer try
5996         to handle ppc32 PLT entries.
5997         (ppc_linux_init_abi): Install ppc64_linux_convert_from_func_ptr_addr
5998         only on ppc64.
5999
6000 2008-05-14  Daniel Jacobowitz  <dan@codesourcery.com>
6001
6002         * elfread.c (elf_symtab_read): Create trampolines for @plt symbols.
6003         * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Renamed from
6004         lookup_minimal_symbol_by_pc_section.  Prefer trampolines if requested.
6005         (lookup_minimal_symbol_by_pc_section): Use
6006         lookup_minimal_symbol_by_pc_section_1.
6007         (lookup_solib_trampoline_symbol_by_pc): Likewise.
6008
6009 2008-05-13  Joel Brobecker  <brobecker@adacore.com>
6010
6011         * findcmd.c: Add #include "gdb_stdint.h".
6012         * Makefile.in (findcmd.o): Update dependencies.
6013
6014 2008-05-11  David S. Miller  <davem@davemloft.net>
6015
6016         * sparc-linux-tdep.c (sparc32_linux_init_abi): Remove
6017         long double size override, Linux does use 128-bit now.
6018
6019         * sparc-linux-tdep.c (PSR_SYSCALL): Define.
6020         (sparc_linux_write_pc): New function.
6021         (sparc32_linux_init_abi): Register it.
6022         * sparc64-linux-tdep.c (TSTATE_SYSCALL): Define.
6023         (sparc64_linux_write_pc): New function.
6024         (sparc64_linux_init_abi): Register it.
6025
6026         * sparc-linux-tdep.c, sparc64-linux-tdep.c: Use
6027         dwarf2_append_unwinders(), not dwarf2_frame_sniffer.
6028
6029 2008-05-11  Ulrich Weigand  <uweigand@de.ibm.com>
6030
6031         * rs6000-tdep.c (rs6000_gdbarch_init): Set up info.target_desc
6032         and info.tdep_info before calling gdbarch_init_osabi.
6033
6034 2008-05-09  Joel Brobecker  <brobecker@adacore.com>
6035
6036         * ada-lang.c (ada_evaluate_subexp) [BINOP_ASSIGN]: Do not force
6037         the type of the right hand side of the assignment to the type
6038         of the left hand side if the left hand side is a convenience
6039         variable.
6040
6041 2008-05-09  Ulrich Weigand  <uweigand@de.ibm.com>
6042
6043         * NEWS: Mention gdbserver bi-arch capability.
6044
6045 2008-05-09  Doug Evans  <dje@google.com>
6046
6047         New "find" command.
6048         * NEWS: Document find command and qSearch:memory packet.
6049         * Makefile.in (SFILES): Add findcmd.c.
6050         (COMMON_OBJS): Add findcmd.o.
6051         (findcmd.o): New rule.
6052         * findcmd.c: New file.
6053         * target.h (target_ops): New member to_search_memory.
6054         (simple_search_memory): Declare.
6055         (target_search_memory): Declare.
6056         * target.c (simple_search_memory): New fn.
6057         (target_search_memory): New fn.
6058         * remote.c (PACKET_qSearch_memory): New packet kind.
6059         (remote_search_memory): New fn.
6060         (init_remote_ops): Init to_search_memory.
6061         (init_extended_remote_ops): Ditto.
6062         (_initialize_remote): Add qSearch:memory packet config command.
6063
6064 2008-05-09  Eli Zaretskii  <eliz@gnu.org>
6065
6066         * thread.c (_initialize_thread): Don't use commas and periods in
6067         first line of doc string of "set/show print thread-events".
6068
6069 2008-05-08  Joel Brobecker  <brobecker@adacore.com>
6070
6071         * alpha-mdebug-tdep.c, alpha-osf1-tdep.c, alpha-tdep.c:
6072         Update for unwinder changes.
6073
6074 2008-05-08  Joel Brobecker  <brobecker@adacore.com>
6075
6076         * frame.c (get_frame_base_address, get_frame_locals_address)
6077         (get_frame_args_address): Pass the correct frame when calling
6078         frame_base_find_by_frame.
6079
6080 2008-05-08  Ulrich Weigand  <uweigand@de.ibm.com>
6081
6082         * remote.c (extended_remote_attach_1): Call target_find_description.
6083
6084 2008-05-08  Daniel Jacobowitz  <dan@codesourcery.com>
6085
6086         * remote.c (extended_remote_create_inferior_1): Clean up
6087         before marking the target running.
6088
6089 2008-05-08  Joel Brobecker  <brobecker@adacore.com>
6090
6091         * hppa-tdep.h, hppa-tdep.c, hppa-hpux-tdep.c: Update for unwinder
6092         changes.
6093
6094 2008-05-07  Joel Brobecker  <brobecker@adacore.com>
6095
6096         * sparc-tdep.c, sparc-tdep.h, sparc-sol2-tdep.c, sparc64-tdep.c,
6097         sparc64-sol2-tdep.c: Update for unwinder changes.
6098
6099 2008-05-07  Daniel Jacobowitz  <dan@codesourcery.com>
6100
6101         * cp-support.c (mangled_name_to_comp): Initialize storage.
6102         (unqualified_name_from_comp): Likewise.
6103
6104 2008-05-07  Jie Zhang  <jie.zhang@analog.com>
6105
6106         * remote.c (remote_insert_breakpoint): Call get_remote_state
6107         after gdbarch_breakpoint_from_pc is called.
6108         (remote_insert_hw_breakpoint): Likewise.
6109
6110 2008-05-06  Joel Brobecker  <brobecker@adacore.com>
6111
6112         * valprint.c (val_print): Add new language parameter and use it
6113         instead of using the current_language. Update calls to val_print
6114         throughout.
6115         (common_val_print): Add new langauge parameter and pass it to
6116         val_print.
6117         * value.h (struct language_defn): Add opaque declaration.
6118         (val_print, common_val_print): Update declarations.
6119         * stack.c (print_frame_args): Update call to common_val_print
6120         using the appropriate language.
6121         * mi/mi-cmd-stack.c (list_args_or_locals): Likewise.
6122         * c-valprint, f-valprint.c, m2-valprint.c, mt-tdep.c, infcmd.c,
6123         mi/mi-main.c, jv-valprint.c, ada-valprint.c, varobj.c, p-valprint.c,
6124         scm-valprint.c, cp-valprint.c, sh64-tdep.c, printcmd.c:
6125         #include "language.h" if necessary.
6126         Update calls to val_print and common_val_print.
6127         * Makefile.in (mt-tdep.o, sh64-tdep.o, mi-cmds.o, mi-main.o):
6128         Update dependencies.
6129
6130 2008-05-06  Joel Brobecker  <brobecker@adacore.com>
6131
6132         * ia64-tdep.c (ia64_convert_from_func_ptr_addr): Treat addresses
6133         pointing inside a non-executable section as function descriptors.
6134
6135 2008-05-06  Pedro Alves  <pedro@codesourcery.com>
6136
6137         * inf-loop.c (inferior_event_handler): Run all continuations and
6138         print any language change before running the breakpoint commands.
6139
6140 2008-05-06  Joel Brobecker  <brobecker@adacore.com>
6141
6142         * frame-unwind.c (frame_unwind_got_bytes): New function.
6143         * frame-unwind.h (frame_unwind_got_bytes): Add declaration.
6144         * libunwind-frame.h, libunwind-frame.c, ia64-tdep.c: Update
6145         for unwinder changes.
6146
6147 2008-05-05  Doug Evans  <dje@google.com>
6148
6149         * NEWS: Mention new /m modifier for disassemble command.
6150         * cli/cli-cmds.c (print_disassembly): New function.
6151         (disassemble_current_function): New function
6152         (disassemble_command): Recognize /m modifier, print mixed
6153         source+assembly.
6154         (init_cli_cmds): Update disassemble help text.
6155
6156 2008-05-05  Maxim Grigoriev  <maxim2405@gmail.com>
6157
6158         * xtensa-tdep.c: Update for unwinder changes.
6159
6160 2008-05-05  Andreas Schwab  <schwab@suse.de>
6161
6162         Update m68k port for unwinder changes.
6163         * m68k-tdep.c (m68k_frame_cache): Expect this_frame.
6164         (m68k_frame_this_id, m68k_frame_prev_register): Update signature.
6165         (m68k_frame_unwind): Use default_frame_sniffer.
6166         (m68k_frame_sniffer): Remove.
6167         (m68k_frame_base_address): Expect this_frame.
6168         (m68k_dummy_id): Renamed from m68k_unwind_dummy_id.  Expect
6169         this_frame.
6170         (m68k_gdbarch_init): Use set_gdbarch_dummy_id,
6171         dwarf2_append_unwinders, and frame_unwind_append_unwinder.
6172         * m68klinux-tdep.c (m68k_linux_pc_in_sigtramp): Expect frame_info
6173         parameter instead of pc value.
6174         (m68k_linux_get_sigtramp_info, m68k_linux_sigtramp_frame_cache):
6175         Expect this_frame.
6176         (m68k_linux_sigtramp_frame_this_id)
6177         (m68k_linux_sigtramp_frame_prev_register)
6178         (m68k_linux_sigtramp_frame_sniffer): Update signature.
6179         (m68k_linux_sigtramp_frame_unwind): Use
6180         m68k_linux_sigtramp_frame_sniffer.
6181         (m68k_linux_init_abi): Use frame_unwind_append_unwinder.
6182
6183         * m68klinux-nat.c (store_register): Fix typo.
6184
6185 2008-05-05  Pedro Alves  <pedro@codesourcery.com>
6186
6187         * infcmd.c (step_1): Put thread id on the stack to avoid possible
6188         NULL dereferencing.
6189
6190 2008-05-05  Luis Machado  <luisgpm@br.ibm.com>
6191
6192         * symfile.c (reread_symbols): Update objfile's entry point.
6193
6194 2008-05-05  Aleksandar Ristovski  <aristovski@qnx.com>
6195             Joel Brobecker  <brobecker@adacore.com>
6196
6197         * ada-lang.c: Update throughout to use symbol_matches_domain
6198         instead of matching the symbol domain explictly.
6199         * dwarf2read.c (add_partial_symbol): Do not add new psym for
6200         STRUCT_DOMAIN. Make sure you recognize c++ struct and java and ada
6201         class as typedefs. See lookup_partial_symbol function.
6202         (new_symbol): Similar to add_partial_symbol, do not create
6203         symbol for the typedef. See lookup_block_symbol.
6204         * symtab.c (symbol_matches_domain): New function, takes care
6205         of dual meaning of STRUCT_DOMAIN symbol for c++, ada and java.
6206         (lookup_partial_symbol): Use symbol_matches_domain to see if the
6207         found psym domain matches the given domain.
6208         (lookup_block_symbol): Likewise.
6209
6210 2008-05-05  Vladimir Prus  <vladimir@codesourcery.com>
6211
6212         * top.c (command_line_handler_continuation): Remove.
6213         (execute_command): Do not install the above.
6214
6215 2008-05-05  Vladimir Prus  <vladimir@codesourcery.com>
6216
6217         * inf-loop.c (inferior_event_handler): Call bpstat_do_action,
6218         and catch all exceptions from it.
6219         * top.c (command_line_handler_continuation): Don't
6220         call bpstat_do_action here.
6221
6222 2008-05-04  Daniel Jacobowitz  <dan@codesourcery.com>
6223
6224         * dwarf2read.c (struct dwarf2_cu): Add type_hash.
6225         (struct die_info): Remove type.
6226         (read_type_die, read_typedef, read_base_type, read_subrange_type)
6227         (read_structure_type, read_enumeration_type, read_array_type)
6228         (read_tag_pointer_type, read_tag_ptr_to_member_type)
6229         (read_tag_reference_type, read_tag_const_type, read_tag_volatile_type)
6230         (read_tag_string_type, read_subroutine_type, read_set_type)
6231         (read_unspecified_type): Delete prototypes.  Remove check for
6232         already-loaded type.  Return the new type.
6233         (set_die_type): Return the new type.
6234         (reset_die_and_siblings_types): Delete.
6235         (load_comp_unit, load_full_comp_unit): Set type_hash.
6236         (process_queue): Remove call to reset_die_and_siblings_types.
6237         (process_die): Do not read most types here.  Use read_type_die
6238         for others.
6239         (read_func_scope, dwarf2_add_member_fn): Use read_type_die.
6240         (quirk_gcc_member_function_pointer): Return the new type.
6241         (process_structure_scope, process_enumeration_scope): Use
6242         get_die_type and read the DIE's type.
6243         (read_full_die): Do not initialize die->type.
6244         (tag_type_to_type): Use read_type_die.
6245         (read_type_die): Check for already defined types.  Return the
6246         type.
6247         (determine_prefix): Use get_die_type.
6248         (set_die_type): Return the type.
6249         (get_die_type): Take a CU argument.  Check for no type_hash.
6250
6251 2008-05-04  Daniel Jacobowitz  <dan@codesourcery.com>
6252
6253         * dwarf2read.c (dwarf2_ranges_read, read_partial_die): Initialize
6254         locals.
6255
6256 2008-05-04  Pedro Alves  <pedro@codesourcery.com>
6257
6258         * breakpoint.c (update_breakpoints_after_exec): Delete bp_longjmp
6259         and bp_longjmp_resume breakpoints.
6260         (breakpoint_address_is_meaningful): Claim bp_longjmp_resume as
6261         meaningful.
6262         (create_longjmp_breakpoint): Don't create bp_longjmp_resume
6263         breakpoints.  Create bp_longjmp breakpoints as momentary
6264         breakpoints.
6265         (enable_longjmp_breakpoint): Delete.
6266         (set_longjmp_breakpoint): New.
6267         (disable_longjmp_breakpoint): Delete.
6268         (delete_longjmp_breakpoint): New.
6269         (set_longjmp_resume_breakpoint): Delete.
6270         (set_momentary_breakpoint_at_pc): New.
6271         (breakpoint_re_set_one): Don't delete bp_longjmp and
6272         bp_longjmp_resume breakpoints.
6273         (breakpoint_re_set): Don't create longjmp and longjmp-resume
6274         breakpoints.
6275
6276         * infrun.c (step_resume_breakpoint): Add comment.
6277         (struct execution_control_state): Delete handling_longjmp member.
6278         (init_execution_control_state). Don't clear handling_longjmp.
6279         (context_switch): Don't context switch handling_longjmp.
6280         (handle_inferior_event): If handling a bp_longjmp breakpoint,
6281         create a bp_longjmp_resume breakpoint, and set it as current
6282         step_resume_breakpoint, then step over the longjmp breakpoint.  If
6283         handling a bp_longjmp_resume breakpoint, don't delete the longjmp
6284         breakpoint, delete the longjmp-resume breakpoint, and stop
6285         stepping.
6286         (currently_stepping): Remove handling_longjmp from expression.
6287         (insert_step_resume_breakpoint_at_sal): Update comment.
6288         (insert_longjmp_resume_breakpoint): New.
6289
6290         * breakpoint.h (set_momentary_breakpoint_at_pc): Declare.
6291         (enable_longjmp_breakpoint, disable_longjmp_breakpoint): Delete
6292         declarations.
6293         (set_longjmp_breakpoint, delete_longjmp_breakpoint): Declare.
6294         (set_longjmp_resume_breakpoint): Delete declaration.
6295
6296         * gdbthread.h (save_infrun_state): Remove handling_longjmp
6297         parameter.
6298         (load_infrun_state): Delete *handling_longjmp parameter.
6299         * thread.c (save_infrun_state): Remove handling_longjmp parameter.
6300         Update body.
6301         (load_infrun_state): Delete *handling_longjmp parameter.  Update
6302         body.
6303
6304         * infcmd.c (disable_longjmp_breakpoint_cleanup): Delete.
6305         (delete_longjmp_breakpoint_cleanup): New.
6306         (step_1): Call set_longjmp_breakpoint instead of
6307         enable_longjmp_breakpoint.  Use delete_longjmp_breakpoint_cleanup
6308         instead of disable_longjmp_breakpoint_cleanup when making cleanup.
6309         (step_1_continuation): Pass thread id in the continuation args to
6310         step_once.
6311         (step_once): Add thread parameter.  Pass thread id the the
6312         continuation.
6313
6314 2008-05-04  Jan Kratochvil  <jan.kratochvil@redhat.com>
6315
6316         Set CU BASE_ADDRESS already from partial DIEs.
6317         * dwarf2read.c (read_partial_die): New variables BASE_ADDRESS and
6318         BASE_ADDRESS_TYPE.  Set these variables from DW_AT_LOW_PC and
6319         DW_AT_ENTRY_PC.  Set CU->HEADER.BASE_KNOWN and CU->HEADER.BASE_ADDRESS
6320         from these variables if it was still unset.
6321
6322         * Makefile.in: Update dependencies.
6323         * dwarf2read.c: Include "addrmap.h"
6324         (struct dwarf2_cu): New fields RANGES_OFFSET and HAS_RANGES_OFFSET.
6325         (dwarf2_ranges_read): New prototype.
6326         (dwarf2_build_psymtabs_hard): Initialize and prepare PSYMTABS_ADDRMAP.
6327         Add discontiguous range to PSYMTABS_ADDRMAP by DWARF2_RANGES_READ on
6328         HAS_RANGES_OFFSET, otherwise add there the contiguous range.
6329         (dwarf2_ranges_read): New parameter RANGES_PST, update the function
6330         comment for it.  Add the found ranges to RANGES_PST.  New variable
6331         BASEADDR, initialize it the common way.
6332         (dwarf2_get_pc_bounds): Update the caller for the new parameter.
6333         (read_partial_die): `DW_AT_ranges' now only sets RANGES_OFFSET and
6334         HAS_RANGES_OFFSET for the later processing.
6335         * objfiles.h (struct objfile): New field PSYMTABS_ADDRMAP.
6336         * symtab.c: Include "addrmap.h"
6337         (find_pc_sect_psymtab): Support reading the field PSYMTABS_ADDRMAP.
6338         Move the psymtab locator into ...
6339         (find_pc_sect_psymtab_closer): ... a new function.
6340
6341 2008-05-04  Ulrich Weigand  <uweigand@de.ibm.com>
6342
6343         * arch-utils.c (gdbarch_update_p): Use default values for
6344         info.abfd and info.target_desc if they are NULL.
6345         (gdbarch_from_bfd): Remove assertion.
6346         (set_gdbarch_from_file): Call gdbarch_find_by_info directly,
6347         using the current target description.
6348         (gdbarch_info_fill): Do not use default values for info->abfd
6349         and info->target_desc.
6350
6351 2008-05-04  Jan Kratochvil  <jan.kratochvil@redhat.com>
6352
6353         * symfile.c (reread_symbols): Reload EXEC_BFD on its change.
6354
6355 2008-05-04  Ulrich Weigand  <uweigand@de.ibm.com>
6356
6357         * inferior.h (read_pc_pid, write_pc_pid): Remove.
6358         * regcache.h (regcache_read_pc, regcache_write_pc): Add prototypes.
6359
6360         * regcache.c (read_pc_pid): Remove, replace by ...
6361         (regcache_read_pc): ... this function.
6362         (write_pc_pid): Remove, replace by ...
6363         (regcache_write_pc): ... this function.
6364         (read_pc, write_pc): Update.
6365
6366         * infrun.c (displaced_step_prepare): Replace read_pc_pid and
6367         write_pc_pid by regcache_read_pc and regcache_write_pc.
6368         (displaced_step_fixup): Likewise.
6369         (resume): Likewise.  Use regcache arch instead of current_gdbarch.
6370         (prepare_to_proceed): Likewise.
6371         (proceed): Likewise.
6372         (adjust_pc_after_break): Likewise.
6373         (handle_inferior_event): Likewise.
6374
6375         * linux-nat.c (cancel_breakpoint): Likewise.
6376         * linux-thread-db.c (check_event): Likewise.
6377         * aix-thread.c (aix_thread_wait): Likewise.
6378         * tracepoint.c (trace_dump_command): Likewise.
6379
6380 2008-05-04  Jan Kratochvil  <jan.kratochvil@redhat.com>
6381
6382         * dwarf2loc.c (dwarf_expr_frame_base): Error out on missing
6383         SYMBOL_LOCATION_BATON.
6384
6385 2008-05-04  Vladimir Prus  <vladimir@codesourcery.com>
6386
6387         * target.h (struct target_ops): New field to_auxv_parse.
6388         * auxv.c (default_auxv_parse): New, renamed from previous
6389         target_auxv_parse.
6390         (target_auxv_parse): Try to call target method.  Fallback to
6391         default_auxv_parse if not found.
6392         * procfs.c (procfs_auxv_parse): New.
6393         (init_procfs_ops): On Solaris, in 64-bit mode, install
6394         procfs_auxv_parse.
6395
6396 2008-05-03  Adam Nemet  <anemet@caviumnetworks.com>
6397
6398         * symfile.c (add_symbol_file_command):  Use paddress rather than
6399         hex_string to print the address.
6400
6401 2008-05-03  Ulrich Weigand  <uweigand@de.ibm.com>
6402
6403         * rs6000-tdep.c (rs6000_frame_this_id): If info->base is 0,
6404         return the null frame ID to terminate the backtrace.
6405
6406 2008-05-03  Ulrich Weigand  <uweigand@de.ibm.com>
6407
6408         * rs6000-tdep.c: Do not include "rs6000-tdep.h".
6409         (rs6000_find_toc_address_hook): Move to rs6000-aix-tdep.c.
6410         (SIG_FRAME_PC_OFFSET): Likewise.
6411         (SIG_FRAME_LR_OFFSET): Likewise.
6412         (SIG_FRAME_FP_OFFSET): Likewise.
6413         (rs6000_push_dummy_call): Likewise.
6414         (rs6000_return_value): Likewise.
6415         (rs6000_convert_from_func_ptr_addr): Likewise.
6416         (branch_dest, rs6000_software_single_step): Likewise.
6417         (deal_with_atomic_sequence): Rename to ...
6418         (ppc_deal_with_atomic_sequence): ... this.  Adapt all callers.
6419         Do not call branch_dest; inline required parts of that function.
6420         (rs6000_skip_trampoline_code): Replace DEPRECATED_SYMBOL_NAME
6421         with SYMBOL_LINKAGE_NAME.
6422         (struct reg, regsize): Delete.
6423         (read_memory_addr): Delete; inline into callers.
6424         (rs6000_skip_prologue): Move after skip_prologue.
6425         (skip_prologue): Remove prototype.
6426         (rs6000_gdbarch_init): Remove sysv_abi variable; perform all
6427         initialization as if this variable were true.  Do not install
6428         ppc64_sysv_abi_adjust_breakpoint_address.
6429
6430         * rs6000-aix-tdep.c: Include "gdb_assert.h", "gdbtypes.h",
6431         "gdbcore.h", "target.h", "value.h", "infcall.h", "objfiles.h",
6432         and "breakpoint.h".
6433         (rs6000_find_toc_address_hook): Move here from rs6000-tdep.c.
6434         (SIG_FRAME_PC_OFFSET): Likewise.
6435         (SIG_FRAME_LR_OFFSET): Likewise.
6436         (SIG_FRAME_FP_OFFSET): Likewise.
6437         (rs6000_push_dummy_call): Likewise.
6438         (rs6000_return_value): Likewise.
6439         (rs6000_convert_from_func_ptr_addr): Likewise.
6440         (branch_dest, rs6000_software_single_step): Likewise.  Replace
6441         tdep->text_segment_base by AIX_TEXT_SEGMENT_BASE.
6442         (rs6000_aix_init_osabi): Install rs6000_push_dummy_call,
6443         rs6000_return_value, and rs6000_convert_from_func_ptr_addr.
6444         Call set_gdbarch_long_double_bit and set_gdbarch_frame_red_zone_size.
6445         Set tdep->lr_frame_offset.  Do not set tdep->text_segment_base.
6446
6447         * rs6000-tdep.h (rs6000_software_single_step): Remove prototype.
6448         (AIX_TEXT_SEGMENT_BASE): New macro.
6449         * rs6000-nat.c (exec_one_dummy_insn): Replace tdep->text_segment_base
6450         by AIX_TEXT_SEGMENT_BASE.
6451
6452         * ppc-tdep.h (ppc_deal_with_atomic_sequence): Add prototype.
6453         (struct gdbarch_tdep): Remove text_segment_base member.
6454         * ppc-linux-tdep.c (ppc_linux_init_abi): On 64-bit, install
6455         ppc64_sysv_abi_adjust_breakpoint_address.
6456
6457         * Makefile.in (rs6000-tdep.o): Update dependencies.
6458         (rs6000-aix-tdep.o): Likewise.
6459
6460 2008-05-03  Luis Machado  <luisgpm@br.ibm.com>
6461             Thiago Jung Bauermann  <bauerman@br.ibm.com>
6462
6463         * cli/cli-decode.c (lookup_cmd_1): Fix indentation.
6464         * doublest.c (convert_typed_floating): Fix typo in comment.
6465         * dwarf2-frame.c (dwarf2_frame_cache): Likewise.
6466         * frame-unwind.h (frame_sniffer_ftype): Likewise.
6467         * frame.c (frame_unwind_address_in_block): Likewise.
6468         * ppc-sysv-tdep.c (ppc64_sysv_abi_push_dummy_call): Likewise.
6469         * symtab.h (struct symbol): Likewise.
6470         * tramp-frame.h (struct trad_frame_cache): Likewise.
6471         * value.c (allocate_repeat_value): Likewise.
6472
6473 2008-05-03  Ulrich Weigand  <uweigand@de.ibm.com>
6474
6475         * infrun.c (handle_inferior_event): Do not insert breakpoints at
6476         TARGET_WAITKIND_LOADED events during startup (i.e. in the shell).
6477
6478 2008-05-03  Pedro Alves  <pedro@codesourcery.com>
6479
6480         * parse.c (parse_exp_in_context): Don't override
6481         expression_context_pc if get_selected_block returned a valid
6482         block.
6483
6484 2008-05-03  Daniel Jacobowitz  <dan@codesourcery.com>
6485
6486         * alpha-tdep.h (ALPHA_REGISTER_BYTES): Delete.
6487         * arm-tdep.h (STATUS_REGISTER_SIZE): Delete.
6488         * breakpoint.c (args_for_catchpoint_enable, current_exception_event):
6489         Delete.
6490         * c-typeprint.c (c_type_print_base): Delete handling of template
6491         instantiations.
6492         * cp-support.h (METHOD_PTR_IS_VIRTUAL, METHOD_PTR_FROM_VOFFSET)
6493         (METHOD_PTR_TO_VOFFSET): Delete.
6494         * defs.h (QUIT_FIXME): Delete.
6495         * f-lang.h (DEFAULT_DOTMAIN_NAME_IN_MF77, DEFAULT_MAIN_NAME_IN_MF77)
6496         (DEFAULT_DOTMAIN_NAME_IN_XLF_BUGGY, DEFAULT_DOTMAIN_NAME_IN_XLF): Delete.
6497         * gdbtypes.h (struct cplus_struct_type): Delete is_inlined,
6498         ninstantiations, and instantiations.
6499         (TYPE_INSTANTIATIONS, TYPE_NINSTANTIATIONS, TYPE_INSTANTIATION)
6500         (TYPE_FN_FIELD_INLINED): Delete.
6501         * srec.h (SREC_BINARY): Delete.
6502         * symtab.c (symbol_init_demangled_name): Delete.
6503         * symtab.h (SYMBOL_INIT_DEMANGLED_NAME, symbol_init_demangled_name)
6504         (SYMBOL_OBJFILE, struct exception_event_record, CURRENT_EXCEPTION_KIND)
6505         (CURRENT_EXCEPTION_CATCH_SAL, CURRENT_EXCEPTION_CATCH_LINE)
6506         (CURRENT_EXCEPTION_CATCH_FILE, CURRENT_EXCEPTION_CATCH_PC)
6507         (CURRENT_EXCEPTION_THROW_SAL, CURRENT_EXCEPTION_THROW_LINE)
6508         (CURRENT_EXCEPTION_THROW_FILE, CURRENT_EXCEPTION_THROW_PC): Delete.
6509         * target.h (enum thread_control_capabilities): Delete tc_switch.
6510         (target_can_switch_threads): Delete.
6511
6512 2008-05-03  Daniel Jacobowitz  <dan@codesourcery.com>
6513
6514         * Makefile.in (objfiles.o): Update.
6515         * exec.c (exec_set_section_address): Support p->addr != 0.
6516         * objfiles.c (objfile_relocate): Update exec_ops section
6517         addresses.
6518         * symfile.c (place_section): Move exec_set_section_address call...
6519         (default_symfile_offsets): ...to here.
6520
6521 2008-05-03  Ulrich Weigand  <uweigand@de.ibm.com>
6522
6523         * Makefile.in (ppc_linux_tdep_h): New macro.
6524         (powerpc_32l_c, powerpc_altivec32_c, powerpc_altivec32l_c): Likewise.
6525         (powerpc_64l_c, powerpc_altivec64_c, powerpc_altivec64l_c): Likewise.
6526         (powerpc_e500l_c): Likewise.
6527         (ppc-linux-nat.o): Update dependencies.
6528         (ppc-linux-tdep.o): Update dependencies.
6529         (rs6000-tdep.o): Update dependencies.
6530
6531         * ppc-tdep.h (ppc_linux_memory_remove_breakpoint): Remove.
6532         (ppc_linux_svr4_fetch_link_map_offsets): Remove.
6533         (ppc_linux_gregset, ppc_linux_fpregset): Move to ppc-linux-tdep.h
6534         (ppc_supply_reg, ppc_collect_reg): Add prototypes.
6535         (tdesc_powerpc_e500): Remove.
6536
6537         * rs6000.c: Include "features/rs6000/powerpc-altivec32.c"
6538         and "features/rs6000/powerpc-altivec64.c".
6539         (ppc_supply_reg, ppc_collect_reg): Make global.
6540         (variants): Use tdesc_powerpc_32 for "powerpc" and
6541         tdesc_powerpc_altivec64 for "powerpc64".
6542         (_initialize_rs6000_tdep): Initialize AltiVec descriptions.
6543
6544         * ppc-linux-tdep.h: New file.
6545
6546         * ppc-linux-tdep.c: Include "ppc-linux-tdep.c".
6547         Include "features/rs6000/powerpc-32l.c".
6548         Include "features/rs6000/powerpc-altivec32l.c".
6549         Include "features/rs6000/powerpc-64l.c".
6550         Include "features/rs6000/powerpc-altivec64l.c".
6551         Include "features/rs6000/powerpc-e500l.c".
6552         (ppc_linux_supply_gregset): New function.
6553         (ppc_linux_collect_gregset): Handle orig_r3 and trap registers.
6554         (ppc32_linux_gregset): Use ppc_linux_supply_gregset.
6555         (ppc64_linux_gregset): Likewise.
6556         (ppc_linux_sigtramp_cache): Handle orig_r3 and trap registers.
6557         (ppc_linux_trap_reg_p): New function.
6558         (ppc_linux_write_pc): New function.
6559         (ppc_linux_core_read_description): New function.
6560         (ppc_linux_init_abi): Install ppc_linux_write_pc and
6561         ppc_linux_core_read_description.  Install orig_r3 and trap
6562         registers if present in the target description.
6563         (_initialize_ppc_linux_tdep): Initialize Linux target descriptions.
6564
6565         * ppc-linux-nat.c: Include "ppc-linux-tdep.h".
6566         (PT_ORIG_R3, PT_TRAP): Define if necessary.
6567         (ppc_register_u_addr): Handle orig_r3 and trap registers.
6568         (fetch_ppc_registers): Likewise.
6569         (store_ppc_registers): Likewise.
6570         (store_register): Likewise.
6571         (ppc_linux_read_description): Check whether AltiVec is supported.
6572         Check whether inferior is 32-bit or 64-bit.  Return the appropriate
6573         Linux target description.
6574
6575         * features/Makefile (WHICH): Use rs6000/powerpc-32l and
6576         rs6000/powerpc-altivec32l instead of rs6000/powerpc-32.
6577         Use rs6000/powerpc-64l and rs6000/powerpc-altivec64l instead
6578         of rs6000/powerpc-64.  Use rs6000/powerpc-e500l instead of
6579         rs6000/powerpc-e500.  Update -expedite variables accordingly.
6580
6581         * features/rs6000/power-spe.xml: Use regnum 73 for "acc".
6582         * features/rs6000/powerpc-32.xml: Do not include power-altivec.xml.
6583         * features/rs6000/powerpc-64.xml: Do not include power-altivec.xml.
6584         * features/rs6000/powerpc-e500.c: Regenerate.
6585         * features/rs6000/powerpc-32.c: Regenerate.
6586         * features/rs6000/powerpc-64.c: Regenerate.
6587
6588         * features/rs6000/power-linux.xml: New file.
6589         * features/rs6000/power64-linux.xml: New file.
6590         * features/rs6000/powerpc-32l.xml: New file.
6591         * features/rs6000/powerpc-altivec32l.xml: New file.
6592         * features/rs6000/powerpc-64l.xml: New file.
6593         * features/rs6000/powerpc-altivec64l.xml: New file.
6594         * features/rs6000/powerpc-e500l.xml: New file.
6595         * features/rs6000/powerpc-32l.c: New (generated) file.
6596         * features/rs6000/powerpc-altivec32l.c: New (generated) file.
6597         * features/rs6000/powerpc-64l.c: New (generated) file.
6598         * features/rs6000/powerpc-altivec64l.c: New (generated) file.
6599         * features/rs6000/powerpc-e500l.xml: New (generated) file.
6600
6601         * regformats/reg-ppc.dat: Remove.
6602         * regformats/reg-ppc64.dat: Remove.
6603         * regformats/rs6000/powerpc-32.dat: Remove.
6604         * regformats/rs6000/powerpc-64.dat: Remove.
6605         * regformats/rs6000/powerpc-e500.dat: Remove.
6606         * regformats/rs6000/powerpc-32l.dat: New (generated) file.
6607         * regformats/rs6000/powerpc-altivec32l.dat: New (generated) file.
6608         * regformats/rs6000/powerpc-64l.dat: New (generated) file.
6609         * regformats/rs6000/powerpc-altivec64l.dat: New (generated) file.
6610         * regformats/rs6000/powerpc-e500l.dat: New (generated) file.
6611
6612 2008-05-03  Pedro Alves  <pedro@codesourcery.com>
6613
6614         * thread.c (delete_thread): Call observer_notify_thread_exit.
6615         * mi/mi-interp.c (mi_interpreter_init): Register mi_thread_exit as
6616         thread_exit observer.
6617         (mi_thread_exit): New.
6618
6619 2008-05-03  Thiago Jung Bauermann  <bauerman@br.ibm.com>
6620
6621         * breakpoint.c (create_exception_catchpoint): Remove prototype
6622         for already deleted function.
6623         * breakpoint.h (ep_is_exception_catchpoint): Likewise.
6624         * frame.h (show_stack_frame): Remove prototype.
6625         * stack.c (show_stack_frame): Remove empty, unused function.
6626         * source.c (symtab_to_fullname, print_source_lines): Small fix
6627         in comment.
6628         * value.c (show_values): Update comments to mention "show values"
6629         command instead of "info history".
6630
6631 2008-05-02  Ulrich Weigand  <uweigand@de.ibm.com>
6632
6633         * linespec.c: Include "target.h".
6634         (minsym_found): Handle minimal symbols pointing to function
6635         descriptors.  Use find_function_start_pc.
6636         * minsyms.c (msymbol_objfile): New function.
6637         * parse.c (write_exp_msymbol): Handle minimal symbols pointing
6638         to function descriptors.
6639         * symtab.c (fixup_section): Only use minimal symbol at the same
6640         address to determine section of a symbol.
6641         (find_function_start_pc): New function.
6642         (find_function_start_sal): Use it.
6643         * symtab.h (msymbol_objfile): Add prototype.
6644         (find_function_start_pc): Likewise.
6645         * value.c: Include "objfiles.h".
6646         (value_fn_field): Handle minimal symbols pointing to function
6647         descriptors.
6648         * Makefile.in (linespec.o): Update dependencies.
6649         (value.o): Likewise.
6650
6651 2008-05-02  Joel Brobecker  <brobecker@adacore.com>
6652
6653         * ada-lang.c (unwrap_value): Handle the case where the "F" field
6654         inside a PAD type is a bitfield.
6655
6656 2008-05-02  Ulrich Weigand  <uweigand@de.ibm.com>
6657
6658         * ppc-sysv-tdep.c (ppc64_sysv_abi_push_dummy_call): Handle
6659         TYPE_CODE_BOOL and TYPE_CODE_CHAR the same as TYPE_CODE_INT.
6660         Handle TYPE_CODE_REF the same as TYPE_CODE_PTR.
6661         Handle TYPE_CODE_METHOD the same as TYPE_CODE_FUNC.
6662         Allow typedefs when checking for function pointer arguments.
6663         Right-align small structs passed on the stack.
6664         (ppc64_sysv_abi_return_value): Handle TYPE_CODE_BOOL and
6665         TYPE_CODE_CHAR the same as TYPE_CODE_INT.
6666         Handle TYPE_CODE_REF the same as TYPE_CODE_PTR.
6667
6668 2008-05-02  Daniel Jacobowitz  <dan@codesourcery.com>
6669
6670         * Makefile.in (arm-tdep.o): Update.
6671         * arm-tdep.c (arm_objfile_data_key, struct arm_mapping_symbol)
6672         (struct arm_per_objfile, arm_compare_mapping_symbols): New.
6673         (arm_pc_is_thumb): Use mapping symbols.
6674         (arm_objfile_data_cleanup, arm_record_special_symbol): New.
6675         (arm_gdbarch_init): Call set_gdbarch_record_special_symbol.
6676         (_initialize_arm_tdep): Initialize arm_objfile_data_key.
6677         * elfread.c (elf_symtab_read): Use gdbarch_record_special_symbol.
6678         * gdbarch.sh: Add record_special_symbol.
6679         * gdbarch.c, gdbarch.h: Regenerated.
6680         * objfiles.c (struct objfile_data): Add cleanup member.
6681         (register_objfile_data_with_cleanup): New function, from
6682         register_objfile_data.
6683         (register_objfile_data): Use it.
6684         (objfile_free_data): Call clear_objfile_data.
6685         (clear_objfile_data): Call cleanup functions.
6686         * objfiles.h (register_objfile_data_with_cleanup): Declare.
6687
6688 2008-05-02  Daniel Jacobowitz  <dan@codesourcery.com>
6689
6690         * objfiles.c (init_entry_point_info): Handle shared libraries.
6691
6692 2008-05-02  Daniel Jacobowitz  <dan@codesourcery.com>
6693
6694         * arm-tdep.c (arm_prologue_this_id): Compare pc, not func, to
6695         lowest_pc.
6696
6697 2008-05-02  Jim Blandy  <jimb@codesourcery.com>
6698             Pedro Alves  <pedro@codesourcery.com>
6699
6700         Implement displaced stepping.
6701
6702         * gdbarch.sh (max_insn_length): New 'variable'.
6703         (displaced_step_copy, displaced_step_fixup)
6704         (displaced_step_free_closure, displaced_step_location): New
6705         functions.
6706         (struct displaced_step_closure): Add forward declaration.
6707         * gdbarch.c, gdbarch.h: Regenerated.
6708
6709         * arch-utils.c: #include "objfiles.h".
6710         (simple_displaced_step_copy_insn)
6711         (simple_displaced_step_free_closure)
6712         (displaced_step_at_entry_point): New functions.
6713         * arch-utils.h (simple_displaced_step_copy_insn)
6714         (simple_displaced_step_free_closure)
6715         (displaced_step_at_entry_point): New prototypes.
6716
6717         * i386-tdep.c (I386_MAX_INSN_LEN): Rename to...
6718         (I386_MAX_MATCHED_INSN_LEN): ... this.
6719         (i386_absolute_jmp_p, i386_absolute_call_p)
6720         (i386_ret_p, i386_call_p, i386_breakpoint_p, i386_syscall_p)
6721         (i386_displaced_step_fixup): New functions.
6722         (struct i386_insn, i386_match_insn): Update.
6723         (i386_gdbarch_init): Set gdbarch_max_insn_length.
6724         * i386-tdep.h (I386_MAX_INSN_LEN): New.
6725         (i386_displaced_step_fixup): New prototype.
6726         * i386-linux-tdep.c (i386_linux_init_abi): Include "arch-utils.h".
6727         Register gdbarch_displaced_step_copy,
6728         gdbarch_displaced_step_fixup, gdbarch_displaced_step_free_closure,
6729         and gdbarch_displaced_step_location functions.
6730
6731         * infrun.c (debug_displaced): New variable.
6732         (show_debug_displaced): New function.
6733         (struct displaced_step_request): New struct.
6734         (displaced_step_request_queue, displaced_step_ptid)
6735         (displaced_step_gdbarch, displaced_step_closure)
6736         (displaced_step_original, displaced_step_copy)
6737         (displaced_step_saved_copy, can_use_displaced_stepping): New
6738         variables.
6739         (show_can_use_displaced_stepping, use_displaced_stepping)
6740         (displaced_step_clear, cleanup_displaced_step_closure)
6741         (displaced_step_dump_bytes, displaced_step_prepare)
6742         (displaced_step_clear_cleanup, write_memory_ptid)
6743         (displaced_step_fixup): New functions.
6744         (resume): Call displaced_step_prepare.
6745         (proceed): Call read_pc once, and remember the value.  If using
6746         displaced stepping, don't remove breakpoints.
6747         (handle_inferior_event): Call displaced_step_fixup.  Add some
6748         debugging output.  When we try to step over a breakpoint, but get
6749         a signal to deliver to the thread instead, ensure the step-resume
6750         breakpoint is actually inserted.  If a thread hop is needed, and
6751         displaced stepping is enabled, don't remove breakpoints.
6752         (init_wait_for_inferior): Call displaced_step_clear.
6753         (_initialize_infrun): Add "set debug displaced" command.  Add
6754         "maint set can-use-displaced-stepping" command.  Clear
6755         displaced_step_ptid.
6756         * inferior.h (debug_displaced): Declare variable.
6757         (displaced_step_dump_bytes): Declare function.
6758
6759         * Makefile.in (arch-utils.o, i386-linux-tdep.o): Update
6760         dependencies.
6761
6762 2008-05-02  Daniel Jacobowitz  <dan@codesourcery.com>
6763
6764         * arm-tdep.c (arm_mode_strings, arm_fallback_mode_string)
6765         (arm_force_mode_string, arm_show_fallback_mode)
6766         (arm_show_force_mode): New.
6767         (arm_pc_is_thumb): Honor fallback-mode and force-mode.  Use
6768         arm_frame_is_thumb.
6769         (_initialize_arm_tdep): Add "set arm fallback-mode"
6770         and "set arm force-mode".
6771         * NEWS: Document new commands.
6772
6773 2008-05-02  Andrew Stubbs  <andrew.stubbs@st.com>
6774
6775         * main.h (batch_silent): Declare.
6776         * event-top.c: Include main.h.
6777         (gdb_setup_readline): Remove extern batch_silent declaration.
6778         * infrun.c (normal_stop): Don't print source location when running in
6779         --batch-silent mode.
6780         * Makefile.in (event-top.o): Add main.h dependency.
6781
6782 2008-05-02  Andreas Schwab  <schwab@suse.de>
6783
6784         * target.h (struct target_ops): Add
6785         to_watchpoint_addr_within_range.
6786         (target_watchpoint_addr_within_range): New function.
6787         * target.c (update_current_target): Inherit
6788         to_watchpoint_addr_within_range, defaulting to
6789         default_watchpoint_addr_within_range.
6790         (default_watchpoint_addr_within_range): New function.
6791         (debug_to_watchpoint_addr_within_range): New function.
6792         (setup_target_debug): Set to_watchpoint_addr_within_range.
6793         * ppc-linux-nat.c (ppc_linux_watchpoint_addr_within_range):
6794         New function.
6795         (_initialize_ppc_linux_nat): Set to_watchpoint_addr_within_range.
6796         * breakpoint.c (watchpoints_triggered): Use
6797         target_watchpoint_addr_within_range.
6798
6799 2008-05-01  Pedro Alves  <pedro@codesourcery.com>
6800
6801         * configure.tgt: Add i[34567]86-*-dicos* and x86_64-*-dicos*.
6802         (i[34567]86-*-dicos*, x86_64-*-dicos*):
6803         Set gdb_osabi to GDB_OSABI_DICOS.
6804
6805         * defs.h (enum gdb_osabi): Add GDB_OSABI_DICOS.
6806         * osabi.c (gdb_osabi_name): Add "DICOS".
6807
6808         * i386-dicos-tdep.c: New file.
6809
6810         * Makefile.in (ALL_TARGET_OBS): Add i386-dicos-tdep.o.
6811         (ALLDEPFILES): Add i386-dicos-tdep.c.
6812         (i386-dicos-tdep.o): New rule.
6813
6814 2008-05-01  Pedro Alves  <pedro@codesourcery.com>
6815
6816         * linux-nat.c (linux_nat_switch_fork): Reinit GDB's thread list
6817         and register the fork's PTID as a thread.
6818
6819 2008-05-01  Aleksandar Ristovski  <aristovski@qnx.com>
6820
6821         PR gdb/1665
6822         * breakpoint.c (create_breakpoint): Add breakpoint_ops argument and
6823         assign its value to the breakpoint created.
6824         (create_breakpoints): Add breakpoint_ops argument and pass it
6825         to create_breakpoint call.
6826         (break_command_really): Add breakpoint_ops argument and pass/assign
6827         appropriately.
6828         (break_command_1): Pass NULL as ops argument.
6829         (set_breakpoint): Pass NULL as ops argument.
6830         (print_one_exception_catchpoint): Print <PENDING> if no loc available.
6831         (handle_gnu_v3_exceptions): Call generic breakpoint code to insert
6832         catch and throw catchpoints.
6833
6834 2008-05-01  Aleksandar Ristovski  <aristovski@qnx.com>
6835
6836         PR gdb/2343
6837         * corelow.c (core_open): Use gdbarch_target_signal_from_host to
6838         translate signal numeric value from the target to GDB's enum
6839         target_signal.
6840         * gdbarch.c, gdbarch.h: Regenerated.
6841         * gdbarch.sh: Added two new functions target_signal_from_host and
6842         target_signal_to_host.
6843         * target.h (default_target_signal_from_host,
6844         default_target_signal_to_host): New functions - declarations.
6845         * signals/signals.c (struct gdbarch): New declaration.
6846         (default_target_signal_to_host, default_target_signal_from_host): New
6847         functions.
6848
6849 2008-05-01  Daniel Jacobowitz  <dan@codesourcery.com>
6850             Pedro Alves  <pedro@codesourcery.com>
6851
6852         Based on work by Jan Kratochvil <jan.kratochvil@redhat.com> and Jeff
6853         Johnston <jjohnstn@redhat.com>.
6854
6855         * NEWS: Mention attach to stopped process fix.
6856         * infcmd.c (detach_command, disconnect_command): Discard the thread
6857         list.
6858         * infrun.c (handle_inferior_event): Do not ignore non-SIGSTOP while
6859         attaching.  Use signal_stop_state.
6860         (signal_stop_state): Check stop_soon.
6861         * linux-nat.c (kill_lwp): Declare earlier.
6862         (pid_is_stopped, linux_nat_post_attach_wait): New.
6863         (lin_lwp_attach_lwp): Use linux_nat_post_attach_wait.  Update
6864         comments.
6865         (linux_nat_attach): Use linux_nat_post_attach_wait.
6866         (detach_callback, linux_nat_detach): Improve handling for signalled
6867         processes.
6868         (linux_nat_pid_to_str): Always print out the LWP ID if it differs
6869         from the process ID.
6870         * Makefile.in (infcmd.o): Update.
6871
6872 2008-05-01  Daniel Jacobowitz  <dan@codesourcery.com>
6873
6874         * arm-linux-tdep.h (ARM_CPSR_REGNUM): Delete definition.
6875         * arm-tdep.c (arm_frame_is_thumb): New.
6876         (arm_pc_is_thumb): Clarify comment.
6877         (thumb_analyze_prologue): Remove PC special case.
6878         (thumb_scan_prologue): Take a block_addr argument.  Use it for
6879         find_pc_partial_function.  Remove unused variables.
6880         (arm_scan_prologue): Use arm_frame_is_thumb.  Use the block address
6881         for find_pc_partial_function.  Remove PC special case.
6882         (arm_prologue_prev_register): Add special handling for PC and CPSR.
6883         (arm_dwarf2_prev_register, arm_dwarf2_frame_init_reg): New.
6884         (arm_get_next_pc): Use arm_frame_is_thumb.
6885         (arm_write_pc): Use CPSR_T instead of 0x20.
6886         (arm_gdbarch_init): Call dwarf2_frame_set_init_reg.
6887         * arm-tdep.h (enum gdb_regnum): Add ARM_CPSR_REGNUM.
6888         (CPSR_T): Define.
6889         * dwarf2-frame.c (dwarf2_frame_prev_register): Handle
6890         DWARF2_FRAME_REG_FN.
6891         * dwarf2-frame.h (enum dwarf2_frame_reg_rule): Add
6892         DWARF2_FRAME_REG_FN.
6893         (struct dwarf2_frame_state_reg): Add FN to loc union.
6894
6895 2008-05-01  Nick Roberts  <nickrob@snap.net.nz>
6896
6897         * exec.c (print_section_info): Add missing '\n'.
6898
6899 2008-05-01  Vladimir Prus  <vladimir@codesourcery.com>
6900
6901         * thread.c (add_thread): Move observer call to ...
6902         (add_thread_silent): ... here.
6903
6904 2008-04-30  Ulrich Weigand  <uweigand@de.ibm.com>
6905
6906         * rs6000-tdep.c: Update for unwinder changes.
6907         * ppcobsd-tdep.c: Likewise.
6908
6909 2008-04-30  Ulrich Weigand  <uweigand@de.ibm.com>
6910
6911         * s390-tdep.c: Update for unwinder changes.
6912
6913 2008-04-30  Ulrich Weigand  <uweigand@de.ibm.com>
6914
6915         * spu-tdep.c: Update for unwinder changes.
6916
6917 2008-04-30  Daniel Jacobowitz  <dan@codesourcery.com>
6918
6919         * hppanbsd-tdep.c, m68kbsd-tdep.c, mn10300-linux-tdep.c,
6920         ppc-linux-tdep.c, ppcnbsd-tdep.c, sparc-linux-tdep.c,
6921         sparc64-linux-tdep.c: Update for unwinder changes.
6922
6923 2008-04-30  Daniel Jacobowitz  <dan@codesourcery.com>
6924
6925         * mipsnbsd-tdep.c, mips64obsd-tdep.c, mips-linux-tdep.c: Update
6926         for unwinder changes.
6927         * mips-tdep.c: Likewise.
6928         (mips_stub_frame_cache): Unwind the ABI stack pointer, not the
6929         raw one.
6930
6931 2008-04-30  Daniel Jacobowitz  <dan@codesourcery.com>
6932
6933         * arm-linux-tdep.c, arm-tdep.c, armobsd-tdep.c: Update for
6934         unwinder changes.
6935
6936 2008-04-30  Daniel Jacobowitz  <dan@codesourcery.com>
6937
6938         Update i386 and amd64 ports for unwinder changes.
6939
6940         * amd64-tdep.c (amd64_frame_cache): Expect this_frame.
6941         (amd64_frame_this_id, amd64_frame_prev_register): Update signature.
6942         (amd64_frame_unwind): Use default_frame_sniffer.
6943         (amd64_frame_sniffer): Delete.
6944         (amd64_sigtramp_frame_cache): Expect this_frame.
6945         (amd64_sigtramp_frame_this_id, amd64_sigtramp_frame_prev_register)
6946         (amd64_sigtramp_frame_sniffer): Update signature.
6947         (amd64_sigtramp_frame_unwind): Add amd64_sigtramp_frame_sniffer.
6948         (amd64_frame_base_address): Expect this_frame.
6949         (amd64_dummy_id): Renamed from amd64_unwind_dummy_id.  Expect
6950         this_frame.
6951         (amd64_init_abi): Use set_gdbarch_dummy_id and
6952         frame_unwind_append_unwinder.
6953         * i386-tdep.c (i386_frame_cache): Expect this_frame.
6954         (i386_frame_this_id, i386_frame_prev_register): Update signature.
6955         (i386_frame_unwind): Use default_frame_sniffer.
6956         (i386_frame_sniffer): Delete.
6957         (i386_sigtramp_frame_cache): Expect this_frame.
6958         (i386_sigtramp_frame_this_id, i386_sigtramp_frame_prev_register)
6959         (i386_sigtramp_frame_sniffer): Update signature.
6960         (i386_sigtramp_frame_unwind): Use i386_sigtramp_frame_sniffer.
6961         (i386_frame_base_address): Update signature.
6962         (i386_dummy_id): Rename from i386_unwind_dummy_id.  Expect this_frame.
6963         (i386_push_dummy_call): Update comment.
6964         (i386_sigtramp_p, i386_svr4_sigtramp_p, i386_svr4_sigcontext_addr):
6965         Expect this_frame.
6966         (i386_gdbarch_init): Use set_gdbarch_dummy_id, dwarf2_append_unwinders,
6967         and frame_unwind_append_unwinder.
6968         * amd64-linux-tdep.c, amd64-sol2-tdep.c, amd64fbsd-tdep.c,
6969         amd64nbsd-tdep.c, amd64obsd-tdep.c, i386-linux-tdep.c,
6970         i386-nto-tdep.c, i386bsd-tdep.c, i386-sol2-tdep.c, i386obsd-tdep.c,
6971         i386nbsd-tdep.c: Update for unwinder changes.
6972
6973 2008-04-30  Daniel Jacobowitz  <dan@codesourcery.com>
6974
6975         * trad-frame.c (struct trad_frame_cache): Rename next_frame to this_frame.
6976         (trad_frame_cache_zalloc, trad_frame_alloc_saved_regs): Expect
6977         this_frame.
6978         (trad_frame_get_prev_register, trad_frame_get_register): Update signature.
6979         * trad-frame.h (trad_frame_cache_zalloc, trad_frame_get_register)
6980         (trad_frame_alloc_saved_regs, trad_frame_get_prev_register): Update
6981         signature.
6982         * tramp-frame.c (tramp_frame_cache, tramp_frame_start): Expect
6983         this_frame.
6984         (tramp_frame_this_id, tramp_frame_prev_register, tramp_frame_sniffer):
6985         Update signature.
6986         * tramp-frame.h (struct tramp_frame): Update signature of init.
6987         * Makefile.in (trad-frame.o): Update.
6988
6989 2008-04-30  Daniel Jacobowitz  <dan@codesourcery.com>
6990
6991         * dwarf2-frame.c (read_reg): Expect this_frame in the baton.
6992         (execute_stack_op): Put this_frame in the baton.
6993         (execute_cfa_program): Take this_frame.
6994         (struct dwarf2_frame_ops): Update comment for signal_frame_p.
6995         (dwarf2_frame_default_init_reg, dwarf2_frame_init_reg)
6996         (dwarf2_frame_signal_frame_p, dwarf2_frame_cache)
6997         (dwarf2_frame_this_id): Adjust to work on this_frame.
6998         (dwarf2_signal_frame_this_id): Delete.
6999         (dwarf2_frame_prev_register): Update signature.  Use new frame
7000         unwind methods.
7001         (dwarf2_frame_sniffer): Update signature.  Expect this_frame.
7002         (dwarf2_frame_unwind, dwarf2_signal_frame_unwind): Add
7003         dwarf2_frame_sniffer.
7004         (dwarf2_append_unwinders): New.
7005         (dwarf2_frame_base_address, dwarf2_frame_base_sniffer): Expect
7006         this_frame.
7007         * sparc-tdep.c (sparc32_dwarf2_struct_return_p)
7008         (sparc32_dwarf2_frame_init_reg): Expect this_frame.
7009         * cris-tdep.c (cris_dwarf2_frame_init_reg): Likewise.
7010         * rs6000-tdep.c (ppc_dwarf2_frame_init_reg): Likewise.
7011         * s390-tdep.c (s390_dwarf2_frame_init_reg): Likewise.
7012         * sh-tdep.c (sh_dwarf2_frame_init_reg): Likewise.
7013         * sparc64-tdep.c (sparc64_dwarf2_frame_init_reg): Likewise.
7014         * dwarf2-frame.h (dwarf2_frame_sniffer): Delete declaration.
7015         (dwarf2_append_unwinders): Declare.
7016         (dwarf2_frame_base_sniffer): Update declaration.
7017         * i386-linux-tdep.c (i386_linux_dwarf_signal_frame_p): Expect
7018         this_frame.
7019
7020 2008-04-30  Daniel Jacobowitz  <dan@codesourcery.com>
7021
7022         Convert frame unwinders to use the current frame and
7023         "struct value".
7024
7025         * frame.c (frame_debug): Make global.
7026         (get_frame_id): Pass this frame to unwinder routines.
7027         (frame_pc_unwind): Remove unused unwind->prev_pc support.
7028         (do_frame_register_read): Do not discard the return value of
7029         frame_register_read.
7030         (frame_register_unwind): Remove debug messages.  Use
7031         frame_unwind_register_value.
7032         (frame_unwind_register_value, get_frame_register_value): New
7033         functions.
7034         (create_new_frame, get_frame_base_address, get_frame_locals_address)
7035         (get_frame_args_address, get_frame_type): Pass this frame to
7036         unwinder routines.
7037         (frame_cleanup_after_sniffer, frame_prepare_for_sniffer): New
7038         functions.
7039         * frame.h: Update comments.
7040         (frame_debug, frame_unwind_register_value, get_frame_register_value)
7041         (frame_prepare_for_sniffer): Declare.
7042         * frame-unwind.h: Update comments and parameter names.
7043         (default_frame_sniffer): Declare.
7044         (frame_prev_register_ftype): Return a struct value *.
7045         (struct frame_unwind): Remove prev_pc member.
7046         (frame_unwind_sniffer_ftype, frame_unwind_append_sniffer): Delete.
7047         (frame_unwind_append_unwinder, frame_unwind_got_optimized)
7048         (frame_unwind_got_register, frame_unwind_got_memory)
7049         (frame_unwind_got_constant, frame_unwind_got_address): Declare.
7050         * frame-base.h: Update comments and parameter names.
7051         * valops.c (value_fetch_lazy): Use get_frame_register_value.  Iterate
7052         if necessary.  Add debugging output.
7053         * sentinel-frame.c (sentinel_frame_prev_register)
7054         (sentinel_frame_this_id): Update for new signature.
7055         (sentinel_frame_prev_pc): Delete.
7056         (sentinel_frame_unwinder): Remove prev_pc.
7057         * ia64-tdep.c (ia64_libunwind_frame_unwind): Do not initialize
7058         prev_pc.
7059         * libunwind-frame.c (libunwind_frame_unwind): Likewise.
7060         * frame-unwind.c (struct frame_unwind_table_entry): Remove sniffer.
7061         (frame_unwind_append_sniffer): Delete.
7062         (frame_unwind_append_unwinder): New function.
7063         (frame_unwind_find_by_frame): Take this frame.  Only use sniffers
7064         from unwinders.  Use frame_prepare_for_sniffer.
7065         (default_frame_sniffer, frame_unwind_got_optimized)
7066         (frame_unwind_got_register, frame_unwind_got_memory)
7067         (frame_unwind_got_constant, frame_unwind_got_address): New functions.
7068         * dummy-frame.c (dummy_frame_sniffer): Use gdbarch_dummy_id.
7069         (dummy_frame_prev_register, dummy_frame_this_id): Update for new
7070         signature.
7071         * gdbarch.sh: Replace unwind_dummy_id with dummy_id.
7072         * gdbarch.c, gdbarch.c: Regenerated.
7073         * frame-base.c (default_frame_base_address)
7074         (default_frame_locals_address, default_frame_args_address): Update
7075         for new signature.
7076         (frame_base_find_by_frame): Pass this frame to unwinder routines.
7077         * infcall.c (call_function_by_hand): Update comments.
7078         * Makefile.in (frame-unwind.o): Update dependencies.
7079
7080 2008-04-30  Daniel Jacobowitz  <dan@codesourcery.com>
7081
7082         * ada-lang.c (ada_value_primitive_packed_val): Only check
7083         value_lazy for memory lvals.
7084         * findvar.c (value_of_register_lazy): New function.
7085         (locate_var_value): Only check value_lazy for memory lvals.
7086         * valarith.c (value_subscripted_rvalue): Likewise.
7087         * valops.c (value_fetch_lazy): Handle both memory and register
7088         lvals.
7089         (search_struct_field, value_slice): Only check value_lazy for memory
7090         lvals.
7091         * value.c (struct value): Update comment for lazy.
7092         (value_primitive_field): Only check value_lazy for memory lvals.
7093         * value.h (value_lazy): Update comment.
7094         (value_of_register_lazy): Declare.
7095
7096 2008-04-30  Daniel Jacobowitz  <dan@codesourcery.com>
7097
7098         * corefile.c (reopen_exec_file): Close any open files.
7099
7100 2008-04-29  Joel Brobecker  <brobecker@adacore.com>
7101
7102         * ia64-tdep.c (ia64_memory_remove_breakpoint): Set
7103         show_memory_breakpoints to 1 while reading the instruction bundle.
7104
7105 2008-04-29  Joel Brobecker  <brobecker@adacore.com>
7106
7107         * gdbarch.sh: Document the return_value method. Explain that
7108         the FUNCTYPE parameter might be NULL.
7109         * gdbarch.h: Regenerated.
7110         * sparc-tdep.c (sparc32_push_dummy_code): Do not pass the function
7111         type when calling using_struct_return, as this is unnecessary
7112         on this target.
7113
7114 2008-04-28  Joel Brobecker  <brobecker@adacore.com>
7115
7116         * terminal.h (create_tty_session): Fix return type.
7117
7118 2008-04-26  Vladimir Prus  <vladimir@codesourcery.com>
7119
7120         * mi/mi-interp.c (mi_new_thread): Quote the thread id.
7121
7122 2008-04-26  Joel Brobecker  <brobecker@adacore.com>
7123
7124         * breakpoint.c (condition_command, commands_from_control_command)
7125         (break_command_really): Minor reformatting.
7126
7127 2008-04-25  Pedro Alves  <pedro@codesourcery.com>
7128
7129         * dwarf2read.c (dwarf2_const_value): Handle DW_FORM_strp.
7130
7131 2008-04-25  Pedro Alves  <pedro@codesourcery.com>
7132
7133         * amd64-tdep.c (amd64_get_longjmp_target): New.
7134         (amd64_init_abi): Register amd64_get_longjmp_target as
7135         gdbarch_get_longjmp_target callback.
7136         * i386-tdep.c (i386_get_longjmp_target): Remove 64-bit handling.
7137
7138 2008-04-25  Pedro Alves  <pedro@codesourcery.com>
7139
7140         * breakpoint.h (enum bpstat_what_main_action): Delete
7141         BPSTAT_WHAT_CLEAR_LONGJMP_RESUME_SINGLE.
7142
7143         * breakpoint.c (clrs): Delete.
7144         (bpstat_what): Update table.
7145
7146         * infrun.c (handle_inferior_event): Remove
7147         BPSTAT_WHAT_CLEAR_LONGJMP_RESUME_SINGLE handling.
7148
7149 2008-04-24  Vladimir Prus  <vladimir@codesourcery.com>
7150
7151         * mi/mi-cmds.h (mi_cmd_args_ftype): Remove.
7152         Adjust all prototypes using mi_cmd_args_ftype to use
7153         mi_cmd_argv_ftype.
7154         (struct mi_cmd): Remove the args_func field.
7155         * mi/mi-cmds.c: Don't provide value for the args_func field.
7156         * mi/mi-main.c (mi_execute_async_cli_command)
7157         (mi_cmd_exec_run, mi_cmd_exec_next, mi_cmd_exec_next_instruction)
7158         (mi_cmd_exec_step, mi_cmd_exec_step_instruction)
7159         (mi_cmd_exec_finish, mi_cmd_exec_until, mi_cmd_exec_return)
7160         (mi_cmd_exec_continue, mi_cmd_exec_interrupt)
7161         (mi_cmd_target_download): Adjust.
7162         (mi_cmd_target_select): Adjust. Pass 0 for from_tty parameter.
7163         (mi_cmd_execute): Do not check for args_func.
7164         (mi_execute_async_cli_command): Adjust.
7165         * mi/mi-parse.c: Don't check for args_func.
7166
7167 2008-04-24  Vladimir Prus  <vladimir@codesourcery.com>
7168
7169         * breakpoint.c (bpstat_check_location)
7170         (bpstat_check_watchpoint, bpstat_check_breakpoint_conditions):
7171         New, extracted from bpstat_stop_status.
7172         (bpstat_stop_status): Use the above.
7173
7174 2008-04-24  Vladimir Prus  <vladimir@codesourcery.com>
7175
7176         * mi/mi-main.c (last_async_command): Rename to current_token.
7177         (previous_async_command): Remove.
7178         (mi_cmd_gdb_exit): Adjust.
7179         (mi_cmd_exec_interrupt): Don't dance with previous_async_command.
7180         (mi_cmd_target_select): Adjust.
7181         (mi_cmd_execute): Don't set previous_async_command.  Free token
7182         here even in async mode.
7183         (mi_execute_async_cli_command): Adjust.
7184         (mi_exec_async_cli_cmd_continuation): Adjust.  Do not free the
7185         token.
7186         (mi_load_progress): Adjust.
7187
7188 2008-04-24  Vladimir Prus  <vladimir@codesourcery.com>
7189
7190         * infcmd.c (step_1_continuation): Always disable longjmp
7191         breakpoint if we're not going to do another step.
7192
7193 2008-04-24  Vladimir Prus  <vladimir@codesourcery.com>
7194
7195         exec_cleanup murder.
7196         * breakpoint.c (until_break_command_continuation): Add
7197         the 'error' parameter.  Directly delete the breakoint as
7198         opposed to running cleanups.
7199         (until_break_command): Install continuation only
7200         after starting the target.  Don't use exec cleanups,
7201         use ordinary cleanups.  Discard cleanups is successfully
7202         started the target in async mode.
7203         (make_cleanup_delete_breakpoint): Remove.
7204         * breakpoint.h (make_cleanup_delete_breakpoint): Remove
7205         declaration.
7206         * defs.h (do_exec_cleanups, make_exec_cleanup): Remove
7207         declarations.
7208         (struct continations): Add the 'error' parameter to the
7209         continuation_hook field.
7210         (add_continuation, do_all_continuations)
7211         (add_intermediate_continuation)
7212         (do_all_intermediate_continuations): Add the 'error' parameter.
7213         * exceptions.c (throw_exception): Don't call do_exec_cleanups.
7214         * inf-loop.c (inferior_event_handler): Instead of calling
7215         discard_all_continuations, use do_all_continuations with 1 as
7216         'error' parameter.  Pass 0 as 'error' parameter in existing uses
7217         of discard_all_continuations.
7218         * infcmd.c (step_1): Do not use exec cleanup.  For async case, discard
7219         cleanups.
7220         (step_once): Install continuation only after resuming the target.
7221         (step_1_continuation): Disable longjmp breakpoint on error.
7222         (finish_command_continuation): Add the error parameter.  Delete
7223         the finish breakpoint directly, do not use cleanups.
7224         (finish_command): Do not use exec_cleanups. Always setup
7225         continuation.  For sync case, immediately run them.
7226         (attach_command_continuation): Add the error parameter.
7227         * infrun.c (fetch_inferior_event): Do not use exec cleanups to
7228         remove step_resume_breakpoint -- adjust delete it directly.
7229         * interps.c (interp_set): Adjust call to do_all_continations.
7230         * mi/mi-interp.c (mi_interpreter_exec_continuation): Do not
7231         do exec cleanups.
7232         * mi/mi-main.c (mi_cmd_target_select): Do not do exec
7233         cleanups.
7234         (mi_cmd_execute): Do not use exec_cleanup.
7235         (mi_execute_async_cli_command): Simplify the string concatenation
7236         logic.  Do no use exec cleanup.
7237         (mi_exec_async_cli_cmd_continuation): New parameter error.
7238         Free last_async_command.
7239         * top.c (command_line_handler_continuation): New parameter error.
7240         * utils.c (exec_cleanup_chain, make_exec_cleanup)
7241         (do_exec_cleanups): Remove.
7242         (add_continuation, do_all_continations)
7243         (add_intermediate_continuation)
7244         (do_all_intermediate_continuations): New parameter error.
7245
7246 2008-04-24  Vladimir Prus  <vladimir@codesourcery.com>
7247
7248         * breakpoint.h (bp_location_p): New typedef.
7249         Register a vector of bp_location_p.
7250         * breakpoint.c (always_inserted_mode)
7251         (show_always_inserted_mode): New.
7252         (unlink_locations_from_global_list): Remove.
7253         (update_global_location_list)
7254         (update_global_location_list_nothrow): New.
7255         (update_watchpoint): Don't free locations.
7256         (should_insert_location): New.
7257         (insert_bp_location): Use should_insert_location.
7258         (insert_breakpoint_locations): Copied from
7259         insert_breakpoints.
7260         (insert_breakpoint): Use insert_breakpoint_locations.
7261         (bpstat_stop_status): Call update_global_location_list
7262         when disabling breakpoint.
7263         (allocate_bp_location): Don't add to bp_location_chain.
7264         (set_raw_breakpoint)
7265         (create_longjmp_breakpoint, enable_longjmp_breakpoint)
7266         (disable_longjmp_breakpoint, create_overlay_event_breakpoint)
7267         (enable_overlay_breakpoints, disable_overlay_breakpoints)
7268         (set_longjmp_resume_breakpoint)
7269         (enable_watchpoints_after_interactive_call_stop)
7270         (disable_watchpoints_before_interactive_call_start)
7271         (create_internal_breakpoint)
7272         (create_fork_vfork_event_catchpoint)
7273         (create_exec_event_catchpoint, set_momentary_breakpoint)
7274         (create_breakpoints, break_command_1, watch_command_1)
7275         (create_exception_catchpoint)
7276         (handle_gnu_v3_exceptions)
7277         (disable_breakpoint, breakpoint_re_set_one)
7278         (create_thread_event_breakpoint, create_solib_event_breakpoint)
7279         (create_ada_exception_breakpoint): : Don't call check_duplicates.
7280         Call update_global_location_list.
7281         (delete_breakpoint): Don't remove locations and don't
7282         try to reinsert them. Call update_global_location_list.
7283         (update_breakpoint_locations): Likewise.
7284         (restore_always_inserted_mode): New.
7285         (update_breakpoints_after_exec): Temporary disable
7286         always inserted mode.
7287         * Makefile.in: Update dependencies.
7288
7289         * infrun.c (proceed): Remove breakpoints while stepping
7290         over breakpoint.
7291         (handle_inferior_event): Don't remove or insert
7292         breakpoints.
7293         * linux-fork.c (checkpoint_command): Remove breakpoints
7294         before fork and insert after.
7295         (linux_fork_context): Remove breakpoints before switch
7296         and insert after.
7297         * target.c (target_disconnect, target_detach): Remove
7298         breakpoints from target.
7299
7300
7301 2008-04-24  Vladimir Prus  <vladimir@codesourcery.com>
7302
7303         * breakpoint.c (print_one_breakpoint_location): In MI
7304         mode, report the location string the breakpoint was
7305         originally created with.
7306
7307 2008-04-23  Maxim Grigoriev  <maxim2405@gmail.com>
7308
7309         * Makefile.in (xtensa-tdep.o): Update dependencies.
7310         * configure.tgt (xtensa*): Update dependencies.
7311         * xtensa-tdep.c (arreg_number): Renamed from areg_number.
7312         Local variable areg renamed to arreg.
7313         (areg_number): New function.
7314         (xtensa_pseudo_register_read, xtensa_pseudo_register_write)
7315         (xtensa_extract_return_value, xtensa_store_return_value): areg_number
7316         replaced by arreg_number.
7317         (xtensa_windowed_frame_cache, struct xtensa_frame_cache): New comments.
7318         (xtensa_alloc_frame_cache): Initialize cache->wd.ws.
7319         (xtensa_scan_prologue): New function.
7320         (xtensa_frame_cache): New local fp_regnum. Handle separately the case,
7321         when ENTRY instraction hasn't been executed yet. Get the frame pointer
7322         value based on prologue analysis. Fix the bugs preventing WS and
7323         AR4-AR7/A11 registers from getting right values for intermediate frames,
7324         whose registers have been already spilled.
7325         (xtensa_frame_prev_register): Fix WS register value. Use are_number
7326         and arreg_number appropriately.
7327         (xtensa_gdbarch_init): Set solib_svr4_fetch_link_map_offsets to
7328         svr4_ilp32_fetch_link_map_offsets.
7329
7330 2008-04-23  Andrew Stubbs  <andrew.stubbs@st.com>
7331
7332         * printcmd.c: Define USE_PRINTF_I64 and PRINTF_HAS_LONG_LONG on MinGW.
7333         (printf_command): Convert %lld to %I64d when USE_PRINTF_I64 set.
7334
7335 2008-04-23  Paolo Bonzini  <bonzini@gnu.org>
7336
7337         * acinclude.m4: Add override.m4.
7338         * configure: Regenerate.
7339
7340 2008-04-22  Jan Kratochvil  <jan.kratochvil@redhat.com>
7341
7342         * ada-lang.c (get_selections): Variable PROMPT made non-const and
7343         initialized with a trailing space now.  Use PROMPT_ARG of
7344         COMMAND_LINE_INPUT instead of printing it ourselves.
7345
7346 2008-04-22  Joel Brobecker  <brobecker@adacore.com>
7347
7348         * NEWS: Document support for 64-bit core file.
7349
7350 2008-04-22  Corinna Vinschen  <vinschen@redhat.com>
7351
7352         * NEWS: Add information on calling convention and new SH CLI options.
7353
7354         * sh-tdep.c (sh_cc_gcc): New static string.
7355         (sh_cc_renesas): Ditto.
7356         (sh_cc_enum): New static string array.
7357         (sh_active_calling_convention): New static string pointer denoting
7358         active user chosen ABI.
7359         (sh_is_renesas_calling_convention): New function to return function
7360         specific ABI, or user choice if necessary.
7361         (sh_use_struct_convention): Rename first argument and turn around its
7362         meaning.  Check for renesas ABI and return accordingly.
7363         (sh_use_struct_convention_nofpu): New function.
7364         (sh_next_flt_argreg): Get function type as third parameter.  Check
7365         for renesas ABI and choose floating registers accordingly.
7366         (sh_push_dummy_call_fpu): Check for ABI and choose argument slot and
7367         struct return slot accordingly.
7368         (sh_push_dummy_call_nofpu): Ditto.
7369         (sh_return_value_nofpu): Call sh_use_struct_convention_nofpu from here.
7370         Evaluate ABI and give to sh_use_struct_convention_nofpu.
7371         (sh_return_value_fpu):  Evaluate ABI and give to
7372         sh_use_struct_convention.
7373         (show_sh_command): New function.
7374         (set_sh_command): Ditto.
7375         (_initialize_sh_tdep): Initialize `set/show sh calling-convention
7376         CLI command.
7377
7378         * gdbarch.sh (return_value): Add func_type argument.
7379         * gdbarch.c: Regenerate.
7380         * gdbarch.h: Ditto.
7381         * eval.c (evaluate_subexp_standard): Rename local variable value_type to
7382         val_type so as not to collide with value_type function.  Call
7383         using_struct_return with additional function type argument.
7384         * infcall.c (call_function_by_hand): Call using_struct_return and
7385         gdbarch_return_value with additional function type argument.
7386         * infcmd.c (print_return_value): Take addition func_type argument.
7387         Call gdbarch_return_value with additional function type argument.
7388         (finish_command_continuation): Call print_return_value with additional
7389         function type argument.
7390         (finish_command): Ditto.
7391         * sparc-tdep.c (sparc32_push_dummy_code): Call using_struct_return with
7392         additional function type argument.
7393         * stack.c (return_command): Call using_struct_return and
7394         gdbarch_return_value with additional function type argument.
7395         * value.c (using_struct_return): Take additional function type argument.
7396         * value.h (using_struct_return): Accommodate declaration.
7397         * alpha-tdep.c (alpha_return_value): Add func_type argument.
7398         * amd64-tdep.c (amd64_return_value): Ditto.
7399         * arm-tdep.c (arm_return_value): Ditto.
7400         * avr-tdep.c (avr_return_value): Ditto.
7401         * cris-tdep.c (cris_return_value): Ditto.
7402         * frv-tdep.c (frv_return_value): Ditto.
7403         * h8300-tdep.c (h8300_return_value): Ditto.
7404         (h8300h_return_value): Ditto.
7405         * hppa-tdep.c (hppa32_return_value): Ditto.
7406         (hppa64_return_value): Ditto.
7407         * i386-tdep.c (i386_return_value): Ditto.
7408         * ia64-tdep.c (ia64_return_value): Ditto.
7409         * iq2000-tdep.c (iq2000_return_value): Ditto.
7410         * m32c-tdep.c (m32c_return_value): Ditto.
7411         * m32r-tdep.c (m32r_return_value): Ditto.
7412         * m68hc11-tdep.c (m68hc11_return_value): Ditto.
7413         * m68k-tdep.c (m68k_return_value): Ditto.
7414         (m68k_svr4_return_value): Ditto.
7415         * m88k-tdep.c  (m88k_return_value): Ditto.
7416         * mep-tdep.c (mep_return_value): Ditto.
7417         * mips-tdep.c (mips_eabi_return_value): Ditto.
7418         (mips_n32n64_return_value): Ditto.
7419         (mips_o32_return_value): Ditto.
7420         (mips_o64_return_value): Ditto.
7421         * mn10300-tdep.c (mn10300_return_value): Ditto.
7422         * mt-tdep.c (mt_return_value): Ditto.
7423         * ppc-linux-tdep.c (ppc_linux_return_value): Ditto.
7424         * ppc-sysv-tdep.c (ppc_sysv_abi_return_value): Ditto.
7425         (ppc_sysv_abi_broken_return_value): Ditto.
7426         (ppc64_sysv_abi_return_value): Ditto.
7427         * ppc-tdep.h (ppc_sysv_abi_return_value): Ditto.
7428         (ppc_sysv_abi_broken_return_value): Ditto.
7429         (ppc64_sysv_abi_return_value): Ditto.
7430         * ppcnbsd-tdep.c (ppcnbsd_return_value): Ditto.
7431         * rs6000-tdep.c (rs6000_return_value): Ditto.
7432         * s390-tdep.c (s390_return_value): Ditto.
7433         * score-tdep.c (score_return_value): Ditto.
7434         * sh-tdep.c (sh_return_value_nofpu): Ditto.
7435         (sh_return_value_fpu): Ditto.
7436         * sh64-tdep.c (sh64_return_value): Ditto.
7437         * sparc-tdep.c (sparc32_return_value): Ditto.
7438         * sparc64-tdep.c (sparc64_return_value): Ditto.
7439         * spu-tdep.c (spu_return_value): Ditto.
7440         * v850-tdep.c (v850_return_value): Ditto.
7441         * vax-tdep.c (vax_return_value): Ditto.
7442         * xstormy16-tdep.c (xstormy16_return_value): Ditto.
7443         * xtensa-tdep.c (xtensa_return_value): Ditto.
7444
7445         * gdbtypes.h (struct type): Add calling_convention member.
7446         * dwarf2read.c (read_subroutine_type): Add calling convention read
7447         from DW_AT_calling_convention attribute to function type.
7448
7449 2008-04-22  Markus Deuling  <deuling@de.ibm.com>
7450
7451         * eval.c (evaluate_subexp_standard): Use value_subscripted_rvalue for
7452         multi_f77_subscript to support values from registers.
7453         * valarith.c (value_subscripted_rvalue): Remove prototype and static.
7454         * value.h (value_subscripted_rvalue): Add prototype.
7455
7456         * f-typeprint.c (f_type_print_base): Add support for TYPE_CODE_UNION.
7457         Fix output.
7458         * f-valprint.c (f_val_print): Likewise.
7459
7460 2008-04-21  Craig Silverstein  <csilvers@google.com>
7461
7462         * dwarf2read.c (zlib_decompress_section): Define abfd in the
7463         !HAVE_ZLIB_H case.
7464
7465 2008-04-21  Pedro Alves  <pedro@codesourcery.com>
7466
7467         * symfile.c (syms_from_objfile): Don't warn if lowest loadable
7468         section is not a code section.
7469
7470 2008-04-19  Craig Silverstein  <csilvers@google.com>
7471
7472         * NEWS: Add information on compressed debug sections.
7473
7474 2008-04-19  Vladimir Prus  <vladimir@codesourcery.com>
7475
7476         * mi/mi-cmd-var.c (varobj_update_one): Print new
7477         value for variable objects that changed type.
7478
7479 2008-04-19  Vladimir Prus  <vladimir@codesourcery.com>
7480
7481         * varobj.c (varobj_invalidate): Don't touch floating
7482         varobjs.
7483
7484 2008-04-19  Mark Kettenis  <kettenis@gnu.org>
7485
7486         * symtab.c: (multiple_symbols_modes, multiple_symbols_ask)
7487         (multiple_symbols_cancel): Remove extra const.
7488         * symtab.h: Likewise.
7489
7490 2008-04-19  Nick Roberts  <nickrob@snap.net.nz>
7491
7492         * interps.c (top_level_interpreter): Rename static variable...
7493         (top_level_interpreter_ptr): ...to this.
7494         (top_level_interpreter): New function.
7495
7496         * interps.h: New extern for top_level_interpreter.
7497
7498         * linespec.c: Include interps.h and mi/mi-cmds.h.
7499         (decode_line_2): When using MI, always set all breakpoints in menu.
7500
7501         * Makefile.in (linespec.o, mi-interp.o): Add dependencies.
7502
7503 2008-04-18  Craig Silverstein  <csilvers@google.com>
7504
7505         * configure.ac (AC_SEARCH_LIBS): Add check for zlib.
7506         * config.in, configure: Regenerate.
7507         * dwarf2read.c: Include zlib.h if present.
7508         Modified *_SECTION macros.
7509         (section_is_p): New.
7510         (dwarf2_locate_sections): Use section_is_p instead of strcmp
7511         (dwarf2_resize_section): New.
7512         to determine whether a given section has a given name.
7513         (zlib_decompress_section): New.
7514         (dwarf2_read_section): Read the compressed section if present
7515         in the binary.
7516         * MAINTAINERS: Added myself to section Write After Approval.
7517
7518 2008-04-18  Thiago Jung Bauermann  <bauerman@br.ibm.com>
7519
7520         * defs.h (exec_set_section_offsets): Remove prototype.
7521         * exec.c (exec_set_section_offsets): Remove function.
7522
7523 2008-04-18  Joel Brobecker  <brobecker@adacore.com>
7524
7525         * stabsread.c (cleanup_undefined_types_1): Add instance flags check
7526         in the search for the matching symbol.
7527
7528 2008-04-17  Marc Khouzam  <marc.khouzam@ericsson.com>
7529
7530         * breakpoint.c (update_watchpoint): Always reparse
7531         condition.
7532
7533 2008-04-17  Joel Brobecker  <brobecker@adacore.com>
7534
7535         * breakpoint.c (print_one_breakpoint_location): Make sure to print
7536         the breakpoint address only once.
7537
7538 2008-04-17  Dennis Roberts  <dennis.roberts@sunquestinfo.com>
7539
7540         * rs6000-tdep.c (rs6000_gdbarch_init): Use the BFD architecture,
7541         rather than a hard-coded architecture, for xcoff executables.
7542
7543 2008-04-17  Doug Evans  <dje@google.com>
7544
7545         * buildsym.c (watch_main_source_file_lossage): New fn.
7546         (end_symtab): Call it.
7547
7548         * source.c (find_and_open_source): Add some comments clarifying
7549         handling of FULLNAME argument.  Make static.  Remove pointless
7550         xstrdup/xfree.
7551
7552 2008-04-17  Pedro Alves  <pedro@codesourcery.com>
7553
7554         * inf-loop.c (inferior_event_handler): Also run the intermediate
7555         continuations in the INF_EXEC_COMPLETE case.
7556
7557 2008-04-16  Tom Tromey  <tromey@redhat.com>
7558
7559         * cli/cli-decode.h (CMD_ASYNC_OK): New define.
7560         (set_cmd_async_ok, get_cmd_async_ok): Declare.
7561         * cli/cli-decode.c (set_cmd_async_ok): New function.
7562         (get_cmd_async_ok): New function.
7563         * cli/cli-cmds.c (init_cli_cmds): Mark "pwd", "help", "info", and
7564         "show" as async-ok.
7565         * top.c (execute_command): Use get_cmd_async_ok.
7566         * infcmd.c: Include cli/cli-decode.h.
7567         (_initialize_infcmd): Mark "interrupt" as async-ok.
7568         * Makefile.in (infcmd.o): Depend on cli_decode_h.
7569
7570 2008-04-16  Daniel Jacobowitz  <dan@codesourcery.com>
7571
7572         PR gdb/2445
7573         * exec.c: Correct "arch-utils.h" include.
7574
7575 2008-04-15  Aleksandar Ristovski  <aristovski@qnx.com>
7576
7577         PR gdb/2424
7578         * infrun.c (normal_stop) Move breakpoint_auto_delete further down
7579         to allow printing to 'see' real reason of stop. This fixes PR 2424.
7580         * breakpoint.c (bpdisp_texst): New function. The function takes over
7581         the role of bpstats static array in print_one_breakpoint_location.
7582         (print_it_typical): Print "Temporary breakpoint" instead
7583         of just "Breakpoint" when breakpoint is, well, temporary. For mi-like
7584         protocols, print disp field.
7585         (print_one_breakpoint_location): Removed bpdisps static definition.
7586         Call new bpstat_text function to get value for 'disp' field.
7587         (mention): Print "Temporary breakpoint" instead of just "Breakpoint".
7588
7589 2008-04-15  Daniel Jacobowitz  <dan@codesourcery.com>
7590
7591         * gnulib/Makefile.am, gnulib/m4/gnulib-cache.m4,
7592         gnulib/aux/link-warning.h, gnulib/extra/link-warning.h: Adjust
7593         by rerunning gnulib-tool with --aux-dir=gnulib/extra.
7594         * gnulib/Makefile.in: Regenerate.
7595
7596 2008-04-14  Daniel Jacobowitz  <dan@codesourcery.com>
7597
7598         * Makefile.in (GNULIB_H): New.  Trigger all-lib.
7599         (defs_h): Use $(GNULIB_H).
7600         (all-lib): Depend on gnulib/Makefile.
7601         (gnulib/Makefile): Regenerate gnulib/Makefile and gnulib/.deps.
7602         * config.in, gnulib/Makefile.in: Regenerated.
7603
7604 2008-04-14  Daniel Jacobowitz  <dan@codesourcery.com>
7605
7606         * Makefile.in (LIBGNU, INCGNU): Define.
7607         (INTERNAL_CFLAGS_BASE): Add INCGNU.
7608         (INTERNAL_LIBS, CLIBS, CDEPS): Add LIBGNU.
7609         (CLEANDIRS): New.
7610         ($(LIBGNU), all-lib): New rules.
7611         (clean, distclean, do-maintainer-clean): Use CLEANDIRS.
7612         * configure.ac: Use gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE.
7613         Simplify AC_CONFIG_AUX_DIR.  Generate gnulib/Makefile.
7614         * gnulib: New directory, from gnulib-tool.
7615         * configure, aclocal.m4: Regenerated.
7616
7617 2008-04-14  Daniel Jacobowitz  <dan@codesourcery.com>
7618
7619         * linux-thread-db.c (have_threads_callback): Check thread->private.
7620
7621 2008-04-13  Nick Roberts  <nickrob@snap.net.nz>
7622             Vladimir Prus  <vladimir@codesourcery.com>
7623
7624         Fix @-varobjs.
7625         * varobj.c (value_of_root): Update the expression for
7626         floating varobjs.
7627         * mi/mi-cmd-var.c (varobj_update_one): If type has changed,
7628         report that.
7629
7630 2008-04-09  Marc Khouzam  <marc.khouzam@ericsson.com>
7631
7632         * mi/mi-cmd-var.c: Include "mi-getopt.h".
7633         (mi_parse_format): New.  Factored out from mi_cmd_var_set_format.
7634         (mi_cmd_var_set_format): Use new mi_parse_format.
7635         (mi_cmd_var_evaluate_expression): Support for -f option to specify
7636         format.
7637         * Makefile.in (mi-cmd-var.o): Update dependencies.
7638
7639         * varobj.h (varobj_get_formatted_value): Declare.
7640         * varobj.c (my_value_of_variable): Added format parameter.
7641         (cplus_value_of_variable): Likewise.
7642         (java_value_of_variable): Likewise.
7643         (c_value_of_variable): Likewise.  Evaluate expression based
7644         on format parameter.
7645         (struct language_specific): Add format parameter to function member
7646         *value_of_variable.
7647         (varobj_get_formatted_value): New.
7648         (varobj_get_value): Added format parameter to method call.
7649
7650 2008-04-08  Joel Brobecker  <brobecker@adacore.com>
7651
7652         * stabsread.c (cleanup_undefined_types_noname): Manually set the
7653         instance flags of the undefined type before calling replace_type.
7654
7655 2008-04-08  Vladimir Prus  <vladimir@codesourcery.com>
7656
7657         * target.h (enum strata): Remove the download_stratum.
7658
7659 2008-04-07  Doug Evans  <dje@google.com>
7660
7661         * buildsym.h (last_source_file): Add dwarf info to comment.
7662         (last_source_start_addr): Ditto.
7663
7664 2008-04-07  Pedro Alves  <pedro@codesourcery.com>
7665
7666         * alphanbsd-tdep.c: Include "target.h".
7667         * mn10300-tdep.c: Include "target.h".
7668         * Makefile.in (alphanbsd-tdep.o, mn10300-tdep.o): Update.
7669
7670 2008-04-06  Vladimir Prus  <vladimir@codesourcery.com>
7671
7672         Fix breakpoint condition that use member variables.
7673         * valops.c (check_field): Remove.
7674         (check_field_in): Rename to check_field.
7675         (value_of_this): Use la_name_of_this.
7676         * value.h (check_field): Adjust prototype.
7677
7678         * language.h (la_value_of_this): Rename to la_name_of_this.
7679         * language.c (unknown_language_defn): Specify "this" for
7680         name_of_this.
7681         (auto_language_defn): Likewise.
7682         (local_language_defn): Likewise.
7683         * ada-lang.c (ada_language_defn): Adjust comment.
7684         * c-lang.c (c_language_defn): Adjust comment.
7685         (cplus_language_defn): Specify "this" for name_of_this.
7686         (asm_language_defn): Adjust comment.
7687         (minimal_language_defn): Adjust comment.
7688         * f-lang.c (f_language_defn): Specify NULL for name_of_this.
7689         * jv-lang.c (java_language_defn): Specify "this" for name_of_this.
7690         * m2-lang.c (m2_language_defn): Specify "this" for name_of_this.
7691         * objc-lang.c (objc_language_defn): Specify "self" for
7692         name_of_this.
7693         * p-lang.c (pascal_language_defn): Specify "this" for
7694         name_of_this.
7695         * scm-lang.c (scm_language_defn): Specify NULL for name_of_this.
7696
7697         * symtab.c (lookup_symbol_aux): Lookup "this" in the
7698         proper scope, and check for field in type of "this", without
7699         trying to create a value.
7700
7701 2008-04-04  Pedro Alves  <pedro@codesourcery.com>
7702
7703         * mi/mi-cmds.h (enum mi_cmd_result): Delete MI_CMD_ERROR.
7704         (mi_error_message): Delete declaration.
7705         * mi/mi-interp.c (mi_cmd_interpreter_exec): Call error instead of
7706         returning MI_CMD_ERROR.
7707         * mi/mi-main.c (mi_error_message): Delete.
7708         (mi_cmd_exec_interrupt):
7709         (mi_cmd_thread_select, mi_cmd_thread_list_ids)
7710         (mi_cmd_thread_info): Call error instead of returning
7711         MI_CMD_ERROR.
7712         (mi_cmd_data_list_register_values): Call error instead of
7713         returning MI_CMD_ERROR.  Adapt to new get_register interface.
7714         (get_register): Change return typo to void.  Call error instead of
7715         returning MI_CMD_ERROR.
7716         (mi_cmd_data_write_register_values): Call error instead of
7717         returning MI_CMD_ERROR.
7718         (mi_cmd_list_features): Return MI_CMD_DONE.
7719         (captured_mi_execute_command): Remove MI_CMD_ERROR handling.
7720         (mi_execute_command): Always print exceptions with -error.
7721
7722 2008-04-04  Joel Brobecker  <brobecker@adacore.com>
7723
7724         * NEWS: Mention new commands set/show multiple-symbols.
7725
7726 2008-04-03  Joel Brobecker  <brobecker@adacore.com>
7727
7728         * symtab.c (multiple_symbols_ask, multiple_symbols_all)
7729         (multiple_symbols_cancel): New constants.
7730         (multiple_symbols_modes, multiple_symbols_mode): New static globals.
7731         (multiple_symbols_select_mode): New function.
7732         (_initialize_symtab): Add new set/show multiple-symbols commands.
7733         * symtab.h (multiple_symbols_ask, multiple_symbols_all)
7734         (multiple_symbols_cancel, multiple_symbols_select_mode): Declare.
7735         * ada-lang.c (user_select_syms): Add handling of new multiple-symbols
7736         setting.
7737         * linespec.c (decode_line_2): Likewise.
7738
7739 2008-04-03  Doug Evans  <dje@sebabeach.org>
7740
7741         * symtab.h (enum free_code): Delete free_contents, unused.
7742         * symmisc.c (free_symtab_block): Delete.
7743         (free_symtab, case free_code): Delete.
7744
7745 2008-04-01  Aleksandar Ristovski  <aristovski@qnx.com>
7746
7747         * valops.c (value_cast_structs): New function. Cast related
7748         STRUCT types up/down and return cast value. The body of this
7749         function comes mostly from value_cast_pointers.
7750         (value_cast_pointers): Code for actual cast STRUCT-STRUCT moved
7751         to value_cast_structs. Now value_cast_pointers needs only create
7752         appropriate reference after using value_cast_structs for actual
7753         casting.
7754         (value_cast): Handle references.
7755
7756 2008-04-01  Marc Khouzam  <marc.khouzam@ericsson.com>
7757
7758         * MAINTAINERS: Added myself to section Write After Approval.
7759
7760 2008-03-30  Daniel Jacobowitz  <dan@codesourcery.com>
7761
7762         * ia64-tdep.c (examine_prologue): Correct array access.
7763
7764 2008-03-28  Aleksandar Ristovski  <aristovski@qnx.com>
7765
7766         * cp-support.c (first_component_command): Return if no arguments.
7767
7768 2008-03-28  Carlos O'Donell  <carlos@codesourcery.com>
7769
7770         * ser-mingw.c (ser_windows_open): Open requested name.
7771
7772 2008-03-28  Aleksandar Ristovski  <aristovski@qnx.com>
7773
7774         * MAINTAINERS: Added myself.
7775
7776 2008-03-28  Pedro Alves  <pedro@codesourcery.com>
7777
7778         * target.c (find_default_run_target): Allow a NULL `do_mesg'
7779         parameter.  If it is NULL, don't call error.
7780         (find_default_can_async_p, find_default_is_async_p): Pass NULL as
7781         `do_mesg' parameter to find_default_run_target.  If no target was
7782         found, return 0.
7783
7784 2008-03-28  Daniel Jacobowitz  <dan@codesourcery.com>
7785
7786         * mips-linux-tdep.c: Update N32/N64 signal frame comments.
7787         (N64_SIGCONTEXT_LO, N64_SIGCONTEXT_PC, N64_SIGCONTEXT_FPCSR): Update.
7788         (N64_SIGCONTEXT_FIR, N64_SIGCONTEXT_CAUSE, N64_SIGCONTEXT_BADVADDR):
7789         Delete.
7790         (mips_linux_n32n64_sigframe_init): Do not record cause or badvaddr.
7791
7792 2008-03-27  Joel Brobecker  <brobecker@adacore.com>
7793
7794         GDB 6.8 released.
7795
7796 2008-03-27  Ulrich Weigand  <uweigand@de.ibm.com>
7797
7798         * features/Makefile (%.dat): Set xmltarget to the base filename
7799         of the XML source, without subdirectory.
7800         * regformats/rs6000/powerpc-32.dat: Regenerate.
7801         * regformats/rs6000/powerpc-64.dat: Regenerate.
7802         * regformats/rs6000/powerpc-e500.dat: Regenerate.
7803
7804 2008-03-27  Markus Deuling  <deuling@de.ibm.com>
7805
7806         * xcoffread.c (scan_xcoff_symtab): Replace current_gdbarch by
7807         objfile arch.
7808
7809 2008-03-27  Nick Roberts  <nickrob@snap.net.nz>
7810
7811         * mi/mi-main.c (enum captured_mi_execute_command_actions):
7812         Spell suppress in EXECUTE_COMMAND_SUPPRESS_PROMPT correctly.
7813
7814 2008-03-26  Ulrich Weigand  <uweigand@de.ibm.com>
7815
7816         * objfiles.h (struct objfile): New GDBARCH member.
7817         (get_objfile_arch): Add prototype.
7818         * objfiles.c: Include "arch-utils.h".
7819         (allocate_objfile): Look up gdbarch associated with bfd.
7820         (get_objfile_arch): New function.
7821         * Makefile (objfiles.o): Update dependencies.
7822
7823         * dwarf2-frame.c (decode_frame_entry_1): Replace current_gdbarch
7824         by objfile arch.
7825         * dwarf2loc.c (dwarf_expr_read_reg): Replace current_gdbarch
7826         by frame arch.
7827         (locexpr_describe_location): Replace current_gdbarch by
7828         objfile arch.
7829         * dwarf2read.c (die_type): Replace current_gdbarch by objfile arch.
7830         (dwarf2_add_field): Likewise.
7831         (read_tag_pointer_type): Likewise.
7832         (read_base_type): Likewise.
7833         (new_symbol): Likewise.
7834
7835         * coffread.c (decode_type): Add OBJFILE argument.  Update callers.
7836         (decode_base_type, decode_function_type): Likewise.
7837         (coff_read_struct_type, coff_read_enum_type): Likewise.
7838         (coff_symtab_read): Replace current_gdbarch by objfile arch.
7839         (decode_base_type): Likewise.
7840         (coff_read_enum_type): Likewise.
7841         (coff_read_struct_type): Replace current_objfile by OBJFILE argument.
7842         (coff_read_enum_type): Likewise.
7843
7844         * dbxread.c (read_dbx_symtab): Replace current_gdbarch by objfile arch.
7845         (end_psymtab): Likewise.
7846         (process_one_symbol): Likewise.
7847
7848         * mdebugread.c (parse_symbol): Replace current_gdbarch by objfile arch.
7849         (parse_procedure): Likewise.
7850         (parse_partial_symbols): Likewise.
7851
7852         * somread.c (som_symtab_read): Replace current_gdbarch by objfile arch.
7853
7854         * stabsread.c (define_symbol): Replace current_gdbarch by objfile arch.
7855         Replace static pcc_promotion_type and pcc_unsigned_promotion_type by
7856         built-in types.
7857         (read_range_type): Replace current_gdbarch by objfile arch.  Replace
7858         static range_index_type by built-in type.
7859         (read_one_struct_field): Replace current_gdbarch by objfile arch.
7860         (read_enum_type): Likewise.
7861
7862         * xcoffread.c (read_xcoff_symtab): Replace current_gdbarch by
7863         objfile arch.
7864
7865 2008-03-26  Vladimir Prus  <vladimir@codesourcery.com>
7866
7867         * varobj.h (varobj_floating_p): Declare.
7868         * varobj.c (varobj_floating_p): New.
7869         * mi/mi-cmd-var.c (mi_cmd_var_update): When passed
7870         '@' as the name, update all floating varobjs.
7871
7872 2008-03-26  Vladimir Prus  <vladimir@codesourcery.com>
7873
7874         * varobj.c (struct varobj_root): Rename use_selected_frame to
7875         floating, and clarify the meaning.
7876         (varobj_create, varobj_update,  new_root_variable): Adjust.
7877         (value_of_root): Don't use type_changed as in variable,
7878         adjust comment.
7879         (c_value_of_root): Adjust.
7880
7881 2008-03-25  Pedro Alves  <pedro@codesourcery.com>
7882
7883         * linux-nat.c (linux_nat_attach): Add the pid we attached to, to
7884         gdb's thread list.
7885         (linux_nat_wait): Add main lwp to gdb's thread list.
7886         * linux-thread-db.c (find_new_threads_callback): Also attach to
7887         already listed threads which thread_db didn't know about yet.
7888
7889 2008-03-25  Pedro Alves  <pedro@codesourcery.com>
7890
7891         * linux-nat.c (drain_queued_events): Fix comment typo.
7892         (linux_nat_attach): In async mode, don't rely on storing a pending
7893         status.  Instead place the wait status on the pipe.
7894         (linux_nat_resume): Remove unreacheable shortcut code in async
7895         mode.
7896         (stop_wait_callback): In async mode, don't store pending status.
7897         Instead, cancel breakpoints or resend the signal appropriatelly.
7898         (cancel_breakpoint): New, refactored from
7899         cancel_breakpoints_callback.
7900         (cancel_breakpoints_callback): Call cancel_breakpoint.
7901         (pipe_to_local_event_queue): Remove special token processing.
7902         (linux_nat_wait): Issue an internal error if a pending status is
7903         found in async mode.
7904
7905 2008-03-24  Daniel Jacobowitz  <dan@codesourcery.com>
7906
7907         * inflow.c (gdb_has_a_terminal): Guard access to our_process_group.
7908
7909 2008-03-24  Nick Roberts  <nickrob@snap.net.nz>
7910             Vladimir Prus  <vladimir@codesourcery.com>
7911
7912         * varobj.c  (struct varobj_root): New component thread_id.
7913         (varobj_get_thread_id, check_scope): New functions.
7914         (c_value_of_root): Use check_scope.  Switch to the
7915         proper thread if necessary.
7916
7917         * varobj.h (varobj_get_thread_id): New extern.
7918
7919         * mi/mi-cmd-var.c (print_varobj): Add thread-id field.
7920
7921 2008-03-23  Daniel Jacobowitz  <dan@codesourcery.com>
7922
7923         PR gdb/544
7924         * top.c: Revert 2008-03-21 changes.
7925
7926 2008-03-23  Vladimir Prus  <vladimir@codesourcery.com>
7927
7928         * thread.c (make_cleanup_restore_current_thread): Make it
7929         globally visible.
7930         * gdbthread.h (make_cleanup_restore_current_thread): Declare.
7931         * varobj.c (varobj_update): Don't save/restore frame.
7932         (c_value_of_root): Save/restore thread and frame here,
7933         using make_cleanup_restore_current_thread.
7934         * Makefile.in: Update dependecies.
7935
7936 2008-03-23  Vladimir Prus  <vladimir@codesourcery.com>
7937
7938         * varobj.c (struct varobj_root): Clarify
7939         comment on the frame field.
7940         (varobj_create): Don't set frame if we have no
7941         block.
7942
7943 2008-03-21  Daniel Jacobowitz  <dan@codesourcery.com>
7944
7945         PR gdb/544
7946         Suggested by Jan Kratochvil:
7947         * top.c (gdb_rl_operate_and_get_next_completion): Call
7948         rl_redisplay_function.
7949         (gdb_rl_redisplay): New.
7950         (init_main): Set rl_redisplay_function.
7951
7952 2008-03-21  Thomas Mittelstaedt  <T.Mittelstaedt@cadenas.de>  (tiny change)
7953
7954         * aix-thread.c (pdc_read_regs): Fix compiler warning.
7955         (pdc_write_regs, aix_thread_resume, fetch_regs_kernel_thread)
7956         (store_regs_kernel_thread): Likewise.
7957
7958 2008-03-21  Pedro Alves  <pedro@codesourcery.com>
7959
7960         Linux native async support.
7961
7962         * target.h (struct target_ops): Delete to_async_mask_value and add
7963         to_async_mask.
7964         (target_is_async_p, target_async): Formatting.
7965         (target_async_mask_value): Delete.
7966         (target_async_mask): Delete function declaration, and add new
7967         target macro with the same name.
7968
7969         * target.c (update_current_target): Replace to_async_mask_value by
7970         to_async_mask.  Default to_async_mask to return_one.
7971         (target_async_mask): Delete.
7972         (find_default_can_async_p, find_default_is_async_p): New.
7973         (init_dummy_target): register find_default_can_async_p and
7974         find_default_is_async_p on the dummy target.
7975
7976         * linux-nat.c: Include inf-loop.h, event-loop.h and event-top.h.
7977         (debug_linux_nat_async): New global.
7978         (show_debug_linux_nat_async): New function.
7979         (linux_nat_async_enabled, linux_nat_async_mask_value)
7980         (linux_nat_event_pipe, linux_nat_num_queued_events)
7981         (linux_nat_async_events_enabled): New globals.
7982         (struct waitpid_result): New struct.
7983         (waitpid_queue): New global.
7984         (queued_waitpid, push_waitpid, drain_queued_events): New.
7985         (my_waitpid): Call queued_waitpid.
7986         (linux_child_follow_fork): Disable async events during the call.
7987         (blocked_mask): Delete.
7988         (sync_sigchld_action, async_sigchld_action): New globals.
7989         (lin_lwp_attach_lwp): In sync mode, don't reblock SIGCHLD.  In
7990         async mode, block events during the call.
7991         (linux_nat_create_inferior): New.
7992         (linux_nat_attach): In sync mode, restore the mask states.  In
7993         async mode, wake the event loop immediatelly.
7994         (detach_callback): Drain all queued events of the lwp we're
7995         detaching from.
7996         (linux_nat_detach): Block async mode, and drain events of the main
7997         process.
7998         (linux_nat_resume): If in async mode, mask async events during the
7999         call.  If short circuiting, force event loop to wake up.  If
8000         resuming, set target_executing, and register target events in the
8001         event loop.
8002         (pipe_to_local_event_queue, local_event_queue_to_pipe): New.
8003         (linux_nat_wait): In async mode, block events during the call.
8004         Only enable/disable passing SIGINT to the inferior in sync mode.
8005         Get events from local waitpid queue.  If no interesting events was
8006         found, return to events loop.  Reregister target events in the
8007         event loop on exit.  In sync mode, no need to reblock SIGCHLD.
8008         (linux_nat_kill): Disable events on entry.
8009         (linux_nat_mourn_inferior): In sync mode, don't restore the masks
8010         here.  Detach async mode from the event loop if there are no more
8011         forks available, otherwise leave it on.
8012         (sigchld_handler): Assure this is called only in sync mode.
8013         (linux_async_permitted, linux_async_permitted_1): New globals.
8014         (set_maintenance_linux_async_permitted)
8015         (show_maintenance_linux_async_permitted): New functions.
8016         (linux_nat_is_async_p, linux_nat_can_async_p)
8017         (linux_nat_async_mask): New.
8018         (linux_nat_event_pipe_pop, linux_nat_event_pipe_push): New.
8019         (get_pending_events, async_sigchld_handler): New.
8020         (linux_nat_async_events): New.
8021         (async_terminal_is_ours): New global.
8022         (linux_nat_terminal_inferior, linux_nat_terminal_ours): New.
8023         (async_client_callback, async_client_context): New.
8024         (linux_nat_async_file_handler, linux_nat_async)
8025         (linux_nat_disable_async, linux_nat_enable_async): New.
8026         (linux_nat_add_target): Register linux_nat_create_inferior,
8027         linux_nat_can_async_p, linux_nat_is_async_p, linux_nat_async,
8028         linux_nat_async_mask, linux_nat_terminal_inferior and
8029         linux_nat_terminal_ours.
8030         (_initialize_linux_nat): Remove local action variable, and update
8031         code that used it to use sync_sigchld_action.  Add new
8032         "lin-lwp-async" debug set/show command.  Put the "lin-lwp" debug
8033         set/show command in the maintenance class.  Add new "linux-async"
8034         maintenance set/show command.  Block SIGCHLD by default.  Setup
8035         async_sichld_action, and sync_sigchld_action.  Install the default
8036         async mode.
8037         (lin_thread_get_thread_signals): Use a local sigset_t for blocking
8038         the cancel signals.
8039
8040         * linux-thread-db.c (re_check_for_thread_db): New.
8041         (clear_lwpid_callback): Handle TARGET_WAITKIND_IGNORE.
8042         (thread_db_can_async_p, thread_db_is_async_p, thread_db_async)
8043         (thread_db_async_mask): New.
8044         (init_thread_db_ops): Register thread_db_can_async_p,
8045         thread_db_is_async_p, thread_db_async and thread_db_async_mask.
8046
8047         * remote.c (remote_async_mask_value): New.
8048         (remote_return_zero): New.
8049         (init_remote_ops): Register remote_return_zero as callbacks of
8050         to_can_async_p and to_is_async_p.
8051         (remote_can_async_p, remote_is_async_p, remote_async): Update to
8052         use remote_async_mask_value.
8053         (remote_async_mask): New.
8054         (init_remote_async_ops): Remove to_async_mask_value setting and
8055         register remote_async_mask as to_async_mask callback in
8056         remote_async_ops.
8057
8058         * Makefile.in (linux-nat.o): Update.
8059
8060 2008-03-21  Daniel Jacobowitz  <dan@codesourcery.com>
8061
8062         * gdbthread.h (add_thread_with_info): New.
8063         * linux-thread-db.c: Add some documentation.
8064         (GET_LWP, GET_PID, GET_THREAD, is_lwp, is_thread, BUILD_LWP): Delete.
8065         (struct private_thread_info): Remove th_valid and ti_valid.
8066         Replace ti with tid.
8067         (thread_get_info_callback): Do not add TID to the new ptid.  Do
8068         not cache th or ti.
8069         (thread_db_map_id2thr, lwp_from_thread): Delete functions.
8070         (thread_from_lwp): Assert that the LWP is set.  Do not add TID to the
8071         new PTID.
8072         (attach_thread): Handle an already-existing thread.  Use
8073         add_thread_with_info.  Cache the th and tid.
8074         (detach_thread): Verify that private was set.  Remove verbose
8075         argument and printing.  Update caller.
8076         (thread_db_detach): Do not adjust inferior_ptid.
8077         (clear_lwpid_callback, thread_db_resume, thread_db_kill): Delete.
8078         (check_event, find_new_threads_callback): Do not add TID to the new PTID.
8079         (thread_db_wait): Do not use lwp_from_thread.
8080         (thread_db_pid_to_str): Use the cached TID.
8081         (thread_db_extra_thread_info): Check that private is set.
8082         (same_ptid_callback): Delete.
8083         (thread_db_get_thread_local_address): Do not use it or check
8084         is_thread.  Check that private is set.  Assume that the thread
8085         handle is already cached.
8086         (init_thread_db_ops): Remove to_resume and to_kill.
8087         * thread.c (add_thread_with_info): New.
8088         (add_thread): Use it.
8089         * linux-nat.c (find_thread_from_lwp): Delete.
8090         (exit_lwp): Do not use it.  Check print_thread_events.  Print before
8091         deleting the thread.
8092         (GET_PID, GET_LWP, BUILD_LWP, is_lwp): Move to...
8093         * linux-nat.h (GET_PID, GET_LWP, BUILD_LWP, is_lwp): ...here.
8094         * inf-ttrace.c (inf_ttrace_wait): Use print_thread_events and
8095         printf_unfiltered for thread exits.
8096         * procfs.c (procfs_wait): Likewise.
8097
8098 2008-03-21  Chris Demetriou  <cgd@google.com>
8099
8100         * symtab.c (rbreak_command): Quote symbol name before passing
8101         it to break_command.
8102
8103 2008-03-21  Daniel Jacobowitz  <dan@codesourcery.com>
8104
8105         * eval.c (evaluate_subexp_for_address): Clarify error message.
8106         Use value_must_coerce_to_target.
8107         * infcall.c (value_arg_coerce): Call value_coerce_to_target.
8108         * valops.c (value_assign): Call value_coerce_to_target when
8109         assigning to anything but internalvars.  Leave GDB-side arrays
8110         as arrays when assigning to internalvars.
8111         (value_must_coerce_to_target, value_coerce_to_target): New.
8112         (value_coerce_array, value_addr): Call value_coerce_to_target.
8113         (value_array): Create the array in GDB's memory instead of
8114         the inferior's.
8115         * value.h (value_must_coerce_to_target, value_coerce_to_target):
8116         Declare.
8117
8118 2008-03-21  Daniel Jacobowitz  <dan@codesourcery.com>
8119
8120         * top.c (quit_confirm): Warn that we will kill the program.
8121
8122 2008-03-19  Pedro Alves  <pedro@codesourcery.com>
8123
8124         * inflow.c (terminal_ours_1): Guard access to
8125         inferior_process_group with #ifdef PROCESS_GROUP_TYPE.
8126
8127 2008-03-18  Ulrich Weigand  <uweigand@de.ibm.com>
8128             Jim Blandy  <jimb@codesourcery.com>
8129             Daniel Jacobowitz  <drow@false.org>
8130
8131         * dwarf2expr.h (struct dwarf_expr_context): Add ADDR_SIZE member.
8132         (dwarf2_read_address): Update prototype.
8133
8134         * dwarf2expr.c (unsigned_address_type): Add ADDR_SIZE parameter.
8135         (signed_address_type): Likewise.
8136         (dwarf2_read_address): Replace BYTES_READ parameter with ADDR_SIZE.
8137         (execute_stack_op): Update calls to unsigned_address_type,
8138         signed_address_type and dwarf2_read_address.  Fix implementation
8139         of DW_OP_deref_size.
8140
8141         * dwarf2loc.h (dwarf2_per_cu_objfile): Add prototype.
8142         (dwarf2_per_cu_addr_size): Likewise.
8143         (struct dwarf2_locexpr_baton): Replace OBJFILE with PER_CU.
8144         (struct dwarf2_loclist_baton): Likewise.
8145
8146         * dwarf2loc.c (find_location_expression): Update calls to
8147         dwarf2_read_address.  Use dwarf2_per_cu_objfile and
8148         dwarf2_per_cu_addr_size to retrieve PER_CU parameters.
8149         (locexpr_describe_location): Likewise.
8150         (dwarf2_evaluate_loc_desc): Replace OBJFILE with PER_CU parameter.
8151         Set ctx->addr_size to dwarf2_per_cu_addr_size (per_cu).
8152         (dwarf2_loc_desc_needs_frame): Add PER_CU parameter.  Set ctx->addr_size
8153         to dwarf2_per_cu_addr_size (per_cu).
8154         (locexpr_read_variable): Update dwarf2_evaluate_loc_desc call.
8155         (loclist_read_variable): Likewise.
8156         (locexpr_read_needs_frame): Update dwarf2_loc_desc_needs_frame call.
8157
8158         * dwarf2read.c (dwarf2_symbol_mark_computed): Set baton->per_cu
8159         instead of baton->objfile.
8160         (dwarf2_per_cu_obfile): New function.
8161         (dwarf2_per_cu_addr_size): Likewise.
8162
8163         * dwarf2-frame.c (struct comp_unit): Move higher.
8164         (struct dwarf2_cie): Add UNIT and ADDR_SIZE members.
8165         (execute_stack_op): Add ADDR_SIZE parameter; set ctx->addr_size.
8166         (execute_cfa_program): Add FDE parameter.  Replace EH_FRAME_P
8167         parameter by using fde->eh_frame_p.  Use read_encoded_value
8168         to implement DW_CFA_set_loc.
8169         (struct dwarf2_frame_cache): Add ADDR_SIZE member.
8170         (dwarf2_frame_cache): Set cache->addr_size.  Update calls to
8171         execute_stack_op and execute_cfa_program.
8172         (dwarf2_frame_prev_register): Update calls to execute_stack_op.
8173         (size_of_encoded_value): Remove.
8174         (read_encoded_value): Add PTR_LEN and FUNC_BASE parameters.
8175         Remove call to size_of_encoded_value.  Implement DW_EH_PE_funcrel.
8176         (add_cie): Set cie->unit backlink.
8177         (decode_frame_entry_1): Set cie->addr_size.  Update calls to
8178         read_encoded_value.
8179         (dwarf2_build_frame_info): Allocate UNIT on objfile obstack.
8180
8181 2008-03-17  Markus Deuling  <deuling@de.ibm.com>
8182
8183         * i386-tdep.c (i386_print_insn): Remove unnecessary call to
8184         gdbarch_bfd_arch_info.
8185
8186 2008-03-17  Joel Brobecker  <brobecker@adacore.com>
8187
8188         * aix-thread.c (pdc_read_regs): Minor reformatting.
8189
8190 2008-03-17  Vladimir Prus  <vladimir@codesourcery.com>
8191
8192         * thread.c (print_thread_info): Don't insist
8193         on having current thread if there are no
8194         threads at all.
8195
8196 2008-03-17  Pedro Alves  <pedro@codesourcery.com>
8197
8198         * infcmd.c (attach_command_post_wait)
8199         (attach_command_continuation): New.
8200         (attach_command): Support background async execution, and async
8201         execution in synchronous mode.
8202
8203 2008-03-17  Daniel Jacobowitz  <dan@codesourcery.com>
8204
8205         * stack.c (print_stack_frame, print_frame): Use RETURN_MASK_ERROR.
8206         * symmisc.c (dump_symtab_1): Likewise.
8207         * wrapper.c (gdb_value_struct_elt): Likewise.
8208
8209 2008-03-17  Pedro Alves  <pedro@codesourcery.com>
8210
8211         * linux-nat.c (linux_nat_filter_event): Fix comment typo.
8212
8213 2008-03-17  Pedro Alves  <pedro@codesourcery.com>
8214
8215         * linux-nat.c (linux_nat_filter_event): New, refactored from
8216         linux_nat_wait.
8217         (linux_nat_wait): Call linux_nat_filter_event.
8218
8219 2008-03-17  Ulrich Weigand  <uweigand@de.ibm.com>
8220
8221         * top.c (execute_command): Fix uninitialized variable error.
8222
8223 2008-03-16  Nick Hudson  <nick.hudson@dsl.pipex.com>
8224
8225         * Makefile.in (amd64nbsd-nat.o): New dependency.
8226         * amd64nbsd-nat.c: Include "nbsd-nat.h".
8227         (_initialize_amd64nbsd_nat): Update target vector to use
8228         nbsd_pid_to_exec_file.
8229         * config/i386/nbsd64.mh (NATDEPFILES): Add nbsd-nat.o.
8230
8231 2008-03-15  Vladimir Prus  <vladimir@codesourcery.com>
8232
8233         Remove ignoring leading exec events code.
8234         * fork-child.c (startup_inferior): Do not set
8235         inferior_ignoring_leading_exec_events.
8236         * inf-child.c (inf_child_reported_exec_events_per_exec_call): Remove.
8237         (inf_child_target): Do not set to_reported_exec_events_per_exec_call.
8238         * infrun.c (inferior_ignoring_leading_exec_events): Remove.
8239         (handle_inferior_event): Remove code for ignoring leading exec
8240         events.
8241         * target.c (update_current_target): Do not inherit, or default,
8242         to_reported_exec_events_per_exec_call.
8243         (debug_to_reported_exec_events_per_exec_call): Remove.
8244         (setup_target_debug): Do not set to_reported_exec_events_per_exec_call.
8245         * target.h (target_reported_exec_events_per_exec_call): Remove.
8246         (struct target): Remove the to_reported_exec_events_per_exec_call
8247         field.
8248
8249 2008-03-15  Vladimir Prus  <vladimir@codesourcery.com>
8250
8251         Implement -thread-info.
8252         * gdbthread.h (print_thread_info): Declare.
8253
8254         * thread.c (print_thread_info): New, extracted
8255         from info_threads_command and adjusted to
8256         work for CLI and MI.
8257         (info_threads_command): Use print_thread_info.
8258         * Makefile.in: Update dependencies.
8259
8260         * mi/mi-cmds.c (mi_cmds): Specify a handler
8261         for -thread-info.
8262         * mi/mi-cmds.h (mi_cmd_thread_info): Declare.
8263         * mi/mi-main.c (mi_cmd_thread_info): New.
8264         (mi_cmd_list_features): Include 'thread-info'.
8265
8266 2008-03-14  Kevin Buettner  <kevinb@redhat.com>
8267
8268         * mips-tdep.c (mips32_scan_prologue): Use the ABI register size
8269         to decide whether to match instruction patterns using "sw" and "sd".
8270
8271 2008-03-14  Pedro Alves  <pedro@codesourcery.com>
8272
8273         * infcmd.c (jump_command): Postpone disabling stdin until after
8274         the possible query.
8275
8276 2008-03-14  Pedro Alves  <pedro@codesourcery.com>
8277
8278         * inflow.c (gdb_getpgrp): New.
8279         (gdb_has_a_terminal): Use get_getpgrp.
8280         (terminal_ours_1): If attach_flag is set, don't refetch
8281         inferior_process_group.
8282
8283 2008-03-14  Pedro Alves  <pedro@codesourcery.com>
8284
8285         * features/library-list.dtd: Allow "section" elements as children
8286         of "library".  Add "section" element and describe its attributes.
8287
8288         * solib-target.c (struct lm_info): Add section_bases member.
8289         (library_list_start_segment): Error out if seen a section element.
8290         (library_list_start_section): New.
8291         (library_list_end_library): New.
8292         (solib_target_free_library_list): Free section_bases.
8293         (section_attributes): New.
8294         (library_children): Make "segment" optional.  Add "section" child.
8295         (library_list_children): Register library_list_end_library.
8296         (solib_target_relocate_section_addresses): Handle section bases.
8297
8298         * NEWS: Mention new qXfer:libraries:read section offsets support.
8299
8300 2008-03-14  Vladimir Prus  <vladimir@codesourcery.com>
8301
8302         * defs.h (do_exec_error_cleanups, discard_exec_error_cleanups)
8303         (make_exec_error_cleanup): Remove declarations.
8304         * utils.c (exec_error_cleanup_chain): Remove.
8305         (do_exec_error_cleanups, discard_exec_error_cleanups)
8306         (make_exec_error_cleanup): Remove.
8307         * event-loop.c (start_event_loop): Adjust call to
8308         async_enable_stdin.
8309         * event-top.c (async_enable_stdin): Remove the paramater dummy.
8310         (async_disable_stdin): Don't register async_enable_stdin via
8311         cleanup.
8312         * inf-loop.c (inferior_event_handler): Don't
8313         call do_exec_error_cleanups.  Call async_enable_stdin instead.
8314         * event-loop.c (start_event_loop): Adjust call to
8315         async_enable_stdin.
8316         * tui/tui-interp.c (tui_command_loop): Adjust call to
8317         async_enable_stdin.
8318
8319 2008-03-14  Vladimir Prus  <vladimir@codesourcery.com>
8320
8321         Async mode fixes.
8322         * Makefile.in (infcmd.o, inf-loop.o): Update dependencies.
8323         * breakpoint.c (bpstat_do_actions): In async mode,
8324         don't jump to top expecting stop_bpstat to be already
8325         updated.
8326         * event-loop.c (start_event_loop): Call async_enable_stdin
8327         on exception.
8328         * event-top.c (async_enable_stdin): Do nothing if sync_execution
8329         is not set.
8330         (command_handler): Do not setup continuation here.
8331         (command_line_handler_continuation): Move to...
8332         * top.c (command_line_handler_continuation): ... here.
8333         (execute_command): In async mode, register continuation.
8334         Don't check frame's language in running in async mode.
8335         * exceptions.c (throw_exception): Don't do exec_error_cleanups.
8336         * inf-loop.c (complete_execution): Inline into...
8337         (inferior_event_handler): ... here.  Clear target_executing before
8338         doing any cleanups.  Don't try to show prompt if the target was
8339         resumed.
8340         * infcmd.c (signal_command): Add support for async mode.
8341         (finish_command): Only add continuation if the target was
8342         successfully resumed.
8343         * remote.c (init_async_opts): Register to_get_thread_local_address
8344         handler.
8345         * mi/mi-interp.c (mi_cmd_interpreter_exec): Don't mess
8346         with sync_execution.
8347         * tui/tui-interp.c (tui_command_loop): Call async_enable_stdin
8348         on exception.
8349
8350 2008-03-14  Daniel Jacobowitz  <dan@codesourcery.com>
8351
8352         * corefile.c (reopen_exec_file): Use exec_bfd_mtime.
8353         * exec.c (exec_bfd_mtime): Define.
8354         (exec_close): Clear it.
8355         (exec_file_attach): Set it.
8356         * gdbcore.h (exec_bfd_mtime): Declare.
8357         * source.c (find_source_lines): Do not use bfd_get_mtime.
8358
8359 2008-03-14  Vladimir Prus  <vladimir@codesourcery.com>
8360
8361         * top.c (simplified_command_loop): Remove.
8362
8363 2008-03-14  Vladimir Prus  <vladimir@codesourcery.com>
8364
8365         Remove unused remote.c hooks.
8366         * remote.c (deprecated_target_resume_hook)
8367         (deprecated_target_wait_loop_hook): Remove.
8368         (remote_resume): Do not call deprecated_target_resume_hook.
8369         (remote_wait): Do not call deprecated_target_wait_loop_hook.
8370         (remote_async_wait): Likewise.
8371
8372 2008-03-14  Vladimir Prus  <vladimir@codesourcery.com>
8373
8374         Implement MI notification for new threads.
8375         * doc/observer.texi (new_thread): Document.
8376         * observer.sh: Forward declare struct thread_info.
8377         * thread.c (add_thread): Notify observer.
8378
8379         * interps.h (interp_init_ftype): New parameter
8380         top_level.
8381         (interp_set): Likewise.
8382         (top_level_interpreter_data): Declare.
8383         * interps.c (interp_set): New parameter top_level.
8384         Pass it to interpreter's init function.  Remember
8385         top level interpreter.
8386         (interpreter_exec_cmd): Adjust.
8387         (top_level_interpreter_data): New.
8388         * main.c (captured_main): Pass 1 for top_level
8389         parameter of interp_set.
8390         * cli/cli-interp.c (cli_interpreter_init): New
8391         parameter top_level.
8392         * tui/tui-interp.c (tui_init): New parameter top_level.
8393
8394         * mi/mi-interp.c (mi_new_thread): New.
8395         (mi_interpreter_init): If top level, register
8396         observer for new threads.
8397
8398         * Makefile.in (mi-interp.o, thread.o): Update dependencies.
8399
8400 2008-03-14  Pedro Alves  <pedro@codesourcery.com>
8401
8402         * top.c (execute_command): Disable break and stop
8403         commands in async mode.
8404
8405 2008-03-14  Pedro Alves  <pedro@codesourcery.com>
8406
8407         revert:
8408         2008-03-14  Pedro Alves  <pedro@codesourcery.com>
8409         * inf-loop.c (inferior_event_handler): Don't include remote.h.
8410         Call target_stop in the INF_QUIT_REQ case.
8411         * Makefile.in (inf-loop.o): Update.
8412
8413 2008-03-14  Pedro Alves  <pedro@codesourcery.com>
8414
8415         * inf-loop.c (inferior_event_handler): Don't include remote.h.
8416         Call target_stop in the INF_QUIT_REQ case.
8417         * Makefile.in (inf-loop.o): Update.
8418
8419 2008-03-14  Pedro Alves  <pedro@codesourcery.com>
8420
8421         * top.c (execute_command): Enable break, info and interrupt
8422         commands in async mode.
8423
8424 2008-03-13  Vladimir Prus  <vladimir@codesourcery.com>
8425             Daniel Jacobowitz  <dan@codesourcery.com>
8426
8427         * breakpoint.h (breakpoint_restore_shadows): New
8428         declaration.
8429         * breakpoint.c (breakpoint_restore_shadows): New.
8430         (read_memory_nobpt): Delete.
8431         * gdbcore.h (read_memory_nobpt): Delete declaration.
8432         * target.c (memory_xfer_partial): Call
8433         breakpoint_restore_shadows.
8434         (restore_show_memory_breakpoints)
8435         (make_show_memory_beakpoints_cleanup): New.
8436         (show_memory_breakpoints): New.
8437         * target.h (make_show_memory_beakpoints_cleanup): Declare.
8438         * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint):
8439         Make sure we see memory breakpoints when checking if
8440         breakpoint is still there.
8441         * alpha-tdep.c, alphanbsd-tdep.c, frame.c, frv-tdep.c,
8442         hppa-linux-tdep.c, hppa-tdep.c, i386-linux-nat.c, i386-tdep.c,
8443         m68klinux-tdep.c, mips-tdep.c, mn10300-tdep.c, s390-tdep.c,
8444         sparc-tdep.c: Use target_read_memory instead of read_memory_nobpt.
8445
8446 2008-03-12  Pedro Alves  <pedro@codesourcery.com>
8447
8448         * thread.c (add_thread): Use printf_unfiltered to print.
8449
8450 2008-03-12  Joel Brobecker  <brobecker@gnat.com>
8451
8452         * sol-thread.c: Replace use of TM_I386SOL2_H by an expression
8453         that is true only on x86-solaris and x86_64-solaris.
8454         * procfs.c: Likewise. Move procfs_find_LDT_entry up together
8455         with proc_get_LDT_entry.
8456
8457 2008-03-12  Thiago Jung Bauermann  <bauerman@br.ibm.com>
8458
8459         * configure.ac (AC_CHECK_FUNCS): Add check for setsid.
8460         * config.in, configure: Regenerate.
8461         * fork-child.c (fork_inferior): Call create_tty_session.
8462         * inflow.c (new_tty): Set controlling terminal with TIOCSCTTY.
8463         (create_tty_session): New function.
8464         * terminal.h: Declare create_tty_session.
8465
8466 2008-03-12  Alan Modra  <amodra@bigpond.net.au>
8467
8468         PR 5900
8469         * elfread.c (elf_symtab_read): Make shndx an unsigned int.
8470         * mipsread.c: Include elf/internal.h.
8471         (read_alphacoff_dynamic_symtab): Map external reserved sym_shndx
8472         to internal range.
8473
8474 2008-03-11  Markus Deuling  <deuling@de.ibm.com>
8475
8476         * win32-nat.c (do_win32_fetch_inferior_registers): Use get_regcache_arch
8477         to get at the current architecture and at the target specific vector.
8478         Add target specific vector to I387_FISEG_REGNUM and I387_FOP_REGNUM and
8479         remove define of I387_ST0_REGNUM.
8480
8481         * amd64-tdep.c (I387_ST0_REGNUM): Remove define.
8482
8483         (amd64_supply_fxsave, amd64_collect_fxsave): Use get_regcache_arch to
8484         get at the current architecture
8485         (I387_FISEG_REGNUM, I387_FOSEG_REGNUM): Add target specific vector as
8486         parameter.
8487
8488         * i386-tdep.c: Remove various define's and undef's of I387_ST0_REGNUM,
8489         I387_NUM_XMM_REGS and I387_MM0_REGNUM.
8490
8491         (I387_NUM_XMM_REGS, I387_XMM0_REGNUM, I387_MXCSR_REGNUM,
8492         I387_ST0_REGNUM, I387_FCTRL_REGNUM, I387_MM0_REGNUM,
8493         (I387_FSTAT_REGNUM): Add target specific vector as parameter.
8494
8495         (i386_register_name, i386_dbx_reg_to_regnum): Use gdbarch_tdep to get
8496         at the target specific vector.
8497
8498         (i386_get_longjmp_target): Use get_frame_arch to get at the current
8499         architecture. Use gdbarch_tdep to get at the target specific vector.
8500
8501         (i386_fp_regnum_p, i386_fpc_regnum_p): Add gdbarch as parameter and
8502         update caller. Use gdbarch_tdep to get at the target specific vector.
8503
8504         (i386_register_to_value: Use get_frame_arch to get at the current
8505         architecture.
8506
8507         * i386-tdep.h (i386_fp_regnum_p, i386_fpc_regnum_p): Add gdbarch as
8508         parameter.
8509
8510         * i387-tdep.c (I387_FCTRL_REGNUM, I387_FSTAT_REGNUM, I387_FTAG_REGNUM,
8511         I387_FISEG_REGNUM, I387_FIOFF_REGNUM, I387_FOSEG_REGNUM
8512         I387_FOOFF_REGNUM, I387_FOP_REGNUM, I387_ST0_REGNUM, FSAVE_ADDR,
8513         FXSAVE_ADDR, I387_XMM0_REGNUM): Add target specific vector as parameter.
8514
8515         (I387_ST0_REGNUM, I387_NUM_XMM_REGS): Remove various define's and
8516         undef's.
8517
8518         (i387_convert_register_p, i387_register_to_value,
8519         i387_value_to_register): Update call for i386_fp_regnum_p.
8520
8521         * i387-tdep.h: Remove comment.
8522         (I387_ST0_REGNUM, I387_NUM_XMM_REGS, I387_MM0_REGNUM): Add define.
8523         (I387_FCTRL_REGNUM, I387_FSTAT_REGNUM, I387_FTAG_REGNUM,
8524         I387_FISEG_REGNUM, I387_FIOFF_REGNUM, I387_FOSEG_REGNUM,
8525         I387_FOOFF_REGNUM, I387_FOP_REGNUM, I387_XMM0_REGNUM,
8526         I387_MXCSR_REGNUM): Add target specific vector as parameter.
8527
8528 2008-03-10  Daniel Jacobowitz  <dan@codesourcery.com>
8529
8530         * Makefile.in (fork-child.o): Update.
8531         * NEWS: Document "set exec-wrapper" and the gdbserver --wrapper
8532         argument.  Gather all gdbserver features together.
8533         * fork-child.c (exec_wrapper): New variable.
8534         (fork_inferior): Use it.
8535         (startup_inferior): Skip an extra trap if using "set exec-wrapper".
8536         (unset_exec_wrapper_command, _initialize_fork_child): New.
8537
8538 2008-03-10  Hidetaka Takano  <hidetaka.takano@glb.toshiba.co.jp>
8539
8540         * source.c (directory_command): Modify the determination of
8541         condition of terminal "from_tty".
8542
8543 2008-03-10  Matt Rice  <ratmice@gmail.com>
8544
8545         * dwarf2read.c (set_cu_language): Add DW_LANG_ObjC.
8546
8547 2008-03-10  Hidetaka Takano  <hidetaka.takano@glb.toshiba.co.jp>
8548
8549         * spu-tdep.c (info_spu_event_command): Insert a '\0' to the end
8550         of the data passing to strtoulst function.
8551         (info_spu_signal_command): Likewise.
8552
8553 2008-03-08  Vladimir Prus  <vladimir@codesourcery.com>
8554
8555         * mi/mi-interp.c (mi_command_loop): Remove
8556         commented-out code.
8557
8558 2008-03-07  Joel Brobecker  <brobecker@adacore.com>
8559
8560         * remote.c (extended_remote_attach_1): Make local variable pid an int
8561         instead of a pid_t.
8562
8563 2008-03-07  Joel Brobecker  <brobecker@adacore.com>
8564
8565         * solib-svr4.c (svr4_same_1): New function, originally extracted
8566         from svr4_same and expanded to handle the sparc64 case.
8567         (svr4_same): Move up and reimplement using svr4_same_1.
8568         (enable_break): Use svr4_same_1 to do shared library name comparisons.
8569
8570 2008-03-07  Ramana Radhakrishnan  <ramana.r@gmail.com>
8571
8572         * MAINTAINERS: Move self to Paper trail.
8573
8574 2008-03-05  Daniel Jacobowitz  <dan@codesourcery.com>
8575
8576         * Makefile.in (mingw-hdep.o, posix-hdep.o, remote-fileio.o): Update.
8577         * event-loop.c (call_async_signal_handler): New.
8578         * event-loop.h (call_async_signal_handler)
8579         (gdb_call_async_signal_handler): Declare.
8580         (mark_async_signal_handler): Add comments.
8581         * event-top.c (handle_sigint): Use gdb_call_async_signal_handler.
8582         * mingw-hdep.c (sigint_event, sigint_handler): New.
8583         (gdb_select): Use them.  Wait for the readline signal handler
8584         to finish.
8585         (gdb_call_async_signal_handler, _initialize_mingw_hdep): New functions.
8586         * posix-hdep.c (gdb_call_async_signal_handler): New function.
8587         * remote-fileio.c (sigint_fileio_token, async_remote_fileio_interrupt):
8588         New.
8589         (remote_fileio_ctrl_c_signal_handler): Use
8590         gdb_call_async_signal_handler.
8591         (initialize_remote_fileio): Initialize sigint_fileio_token.
8592         * remote.c (initialize_sigint_signal_handler, handle_remote_sigint): Do
8593         not initialize tokens here.
8594         (handle_remote_sigint_twice): Likewise.  Reinstall
8595         handle_remote_sigint.
8596         (async_remote_interrupt_twice): Just call interrupt_query.
8597         (cleanup_sigint_signal_handler): Do not delete tokens.
8598         (remote_interrupt, remote_interrupt_twice): Use
8599         gdb_call_async_signal_handler.
8600         (interrupt_query): Reinstall the default signal handler.
8601         (_initialize_remote): Initialize tokens here.
8602
8603 2008-03-04  Joel Brobecker  <brobecker@adacore.com>
8604
8605         * features/rs6000/power-core.xml, features/rs6000/power64-core.xml,
8606         features/rs6000/powerpc-601.xml, features/rs6000/rs6000.xml:
8607         Change the type of the lr register to code_ptr.
8608         * features/rs6000/powerpc-32.c, features/rs6000/powerpc-403.c,
8609         features/rs6000/powerpc-403gc.c, features/rs6000/powerpc-505.c,
8610         features/rs6000/powerpc-601.c, features/rs6000/powerpc-602.c,
8611         features/rs6000/powerpc-603.c, features/rs6000/powerpc-604.c,
8612         features/rs6000/powerpc-64.c, features/rs6000/powerpc-7400.c,
8613         features/rs6000/powerpc-750.c, features/rs6000/powerpc-860.c,
8614         features/rs6000/powerpc-e500.c, features/rs6000/rs6000.c: Regenerate.
8615
8616 2008-03-03  James E. Wilson  <wilson@tuliptree.org>
8617
8618         * MAINTAINERS: Update my email address.
8619
8620 2008-03-03  Keith Seitz  <keiths@redhat.com>
8621
8622         From Dave Murphy  <davem@devkitpro.org>:
8623         * configure.ac: Set tcl configdir to win under mingw.
8624         * configure: Regenerate.
8625
8626 2008-03-03  Daniel Jacobowitz  <dan@codesourcery.com>
8627
8628         * breakpoint.c (fetch_watchpoint_value): New function.
8629         (update_watchpoint): Set and clear val_valid.  Use
8630         fetch_watchpoint_value.  Handle unreadable values on the
8631         value chain.  Correct check for user-requested array watchpoints.
8632         (breakpoint_init_inferior): Clear val_valid.
8633         (watchpoint_value_print): New function.
8634         (print_it_typical): Use it.  Do not free or clear old_val.  Print
8635         watchpoints even if old_val == NULL.
8636         (watchpoint_check): Use fetch_watchpoint_value.  Check for values
8637         becoming readable or unreadable.
8638         (watch_command_1): Use fetch_watchpoint_value.  Set val_valid.
8639         (do_enable_watchpoint): Likewise.
8640         * breakpoint.h (struct breakpoint): Update comment for val.  Add
8641         val_valid.
8642         * NEWS: Mention watchpoints on inaccessible memory.
8643
8644 2007-02-29  Daniel Jacobowitz  <dan@codesourcery.com>
8645
8646         * Makefile.in (i386-nat.o): Update.
8647         * amd64-linux-nat.c (_initialize_amd64_linux_nat): Call
8648         i386_use_watchpoints.
8649         * i386-linux-nat.c (_initialize_i386_linux_nat): Call
8650         i386_use_watchpoints.
8651         * i386-nat.c (i386_stopped_data_address): Take two arguments.
8652         (i386_stopped_by_watchpoint): Update call.
8653         (i386_can_use_hw_breakpoint, i386_use_watchpoints): New.
8654         * config/i386/nm-i386.h: Conditionalize definitions on
8655         ! I386_WATCHPOINTS_IN_TARGET_VECTOR.
8656         (i386_use_watchpoints): Declare.
8657         (i386_stopped_data_address): Update.
8658         * config/i386/nm-linux.h (I386_WATCHPOINTS_IN_TARGET_VECTOR): Define.
8659         * config/i386/nm-linux64.h (I386_WATCHPOINTS_IN_TARGET_VECTOR): Define.
8660
8661 2008-02-29  Joel Brobecker  <brobecker@adacore.com>
8662
8663         GDB 6.8 branch created (branch timestamp: 2008-02-26 10:00 UTC)
8664         * version.in: Bump version to 6.8.50.20080229-cvs.
8665
8666 2008-02-28  Markus Deuling  <deuling@de.ibm.com>
8667
8668         * f-typeprint.c (f_print_type): Handle NULL pointer in VARSTRING
8669         properly.
8670
8671 2008-02-28  Tom Tromey  <tromey@redhat.com>
8672
8673         * infcmd.c (notice_args_read): Print result of get_inferior_args.
8674
8675 2008-02-28  Daniel Jacobowitz  <dan@codesourcery.com>
8676
8677         * infcmd.c (kill_if_already_running): Make static.  Use
8678         target_require_runnable.
8679         * target.c (target_require_runnable): New.
8680         * target.h (target_require_runnable): Declare.
8681
8682 2008-02-28  Daniel Jacobowitz  <dan@codesourcery.com>
8683
8684         * frame.c (reinit_frame_cache): Only annotate if frames were
8685         previously valid.
8686
8687 2008-02-28  Ulrich Weigand  <uweigand@de.ibm.com>
8688
8689         * regformats/reg-ppc.dat: Rename "ps" to "msr".
8690         * regformats/reg-ppc64.dat: Likewise.
8691
8692 2008-02-28  Ulrich Weigand  <uweigand@de.ibm.com>
8693
8694         * features/Makefile (%.dat): Emit xmltarget statement.
8695
8696         * regformats/regdat.sh: Support xmltarget and xmlarch statments.
8697         Generate code to set gdbserver_xmltarget in init_registers_${name}.
8698
8699         * regformats/arm-with-iwmmxt.dat: Regenerate.
8700         * regformats/mips64-linux.dat: Regenerate.
8701         * regformats/mips-linux.dat: Regenerate.
8702         * regformats/rs6000/powerpc-32.dat: Regenerate.
8703         * regformats/rs6000/powerpc-64.dat: Regenerate.
8704         * regformats/rs6000/powerpc-e500.dat: Regenerate.
8705
8706         * regformats/reg-arm.dat: Add xmlarch statement.
8707         * regformats/reg-i386.dat: Likewise.
8708         * regformats/reg-i386-linux.dat: Likewise.
8709         * regformats/reg-x86-64-linux.dat: Likewise.
8710         * regformats/reg-spu.dat: Likewise.
8711
8712 2008-02-27  Daniel Jacobowitz  <dan@codesourcery.com>
8713
8714         * remote.c (remote_wait, remote_async_wait): Stop if we receive
8715         an error.
8716
8717 2008-02-27  Daniel Jacobowitz  <dan@codesourcery.com>
8718
8719         * utils.c (debug_timestamp): New.
8720         (vfprintf_unfiltered): Print timestamps if requested.
8721         (show_debug_timestamp): New.
8722         (initialize_utils): Register "set debug timestamp".
8723         * NEWS: Mention "set debug timestamp".  Add GDB 6.8 section.
8724
8725 2008-02-27  Joel Brobecker  <brobecker@adacore.com>
8726
8727         * breakpoint.c (skip_prologue_sal): New function.
8728         (resolve_sal_pc): Adjust SAL past prologue if the SAL was
8729         computed from a line number.
8730
8731 2008-02-27  Joel Brobecker  <brobecker@adacore.com>
8732
8733         * features/rs6000/power-core.xml, features/rs6000/power64-core.xml
8734         features/rs6000/powerpc-601.xml, features/rs6000/rs6000.xml:
8735         Set PC register type to "code_ptr".
8736         * features/rs6000/powerpc-32.c, features/rs6000/powerpc-403.c,
8737         features/rs6000/powerpc-403gc.c, features/rs6000/powerpc-505.c,
8738         features/rs6000/powerpc-601.c, features/rs6000/powerpc-602.c,
8739         features/rs6000/powerpc-603.c, features/rs6000/powerpc-604.c,
8740         features/rs6000/powerpc-64.c, features/rs6000/powerpc-7400.c,
8741         features/rs6000/powerpc-750.c, features/rs6000/powerpc-860.c,
8742         features/rs6000/powerpc-e500.c, features/rs6000/rs6000.c:
8743         Regenerate.
8744
8745 2008-02-27  Ulrich Weigand  <uweigand@de.ibm.com>
8746
8747         * regformats/regdat.sh: Rename init_registers function in
8748         generated file to init_registers_${name}.
8749
8750         * regformats/reg-crisv32.dat: Set "name" to crisv32.
8751         * regformats/reg-ppc64.dat: Set "name" to ppc64.
8752         * regformats/reg-s390x.dat: Set "name" to s390x.
8753
8754 2008-02-26  Greg Law  <glaw@undo-software.com>
8755
8756         * regcache.c (registers_changed): Call reinit_frame_cache.
8757
8758 2008-02-26  Daniel Jacobowitz  <dan@codesourcery.com>
8759
8760         * configure.tgt (sh-*-linux*): Match sh*.  Add glibc-tdep.o.
8761         * sh-linux-tdep.c (sh_linux_init_abi): Use glibc_skip_solib_resolver
8762         and svr4_fetch_objfile_link_map.
8763         * Makefile.in (sh-linux-tdep.o): Update.
8764
8765 2008-02-26  Thiago Jung Bauermann  <bauerman@br.ibm.com>
8766
8767         * amd64-tdep.c (amd64_classify): Add support for decimal float
8768         types.
8769         * i386-tdep.c (i386_return_value): Make 128-bit decimal float
8770         use the struct return convention.
8771
8772 2008-02-26  Nick Roberts  <nickrob@snap.net.nz>
8773
8774         * breakpoint.c (print_one_breakpoint_location): Revert Enb field
8775         to old format.  Discard breakpoint address if shared library is
8776         unloaded.
8777         (breakpoint_1): Adjust formatting of table header accordingly.
8778
8779 2008-02-25  Vladimir Prus  <vladimir@codesourcery.com>
8780
8781        * remote.c (remote_get_threadlist): If the response
8782        is empty, don't try to parse it.
8783
8784 2008-02-23  Vladimir Prus  <vladimir@codesourcery.com>
8785
8786         Unbreak 'target async'.
8787         * serial.c (serial_async): Set the
8788         handler function before enabling async
8789         mode.
8790
8791 2008-02-22  Daniel Jacobowitz  <dan@codesourcery.com>
8792
8793         * solib-svr4.c (enable_break): Convert r_brk to a code address.
8794
8795 2008-02-21  Pedro Alves  <pedro@codesourcery.com>
8796
8797         * remote.c (extended_remote_attach_1): Set attach_flag.
8798         (extended_remote_create_inferior_1): Clear attach_flag.
8799
8800 2008-02-20  Daniel Jacobowitz  <dan@codesourcery.com>
8801
8802         * mipsnbsd-tdep.c (mipsnbsd_ilp32_fetch_link_map_offsets): Set
8803         r_brk_offset.
8804         (mipsnbsd_lp64_fetch_link_map_offsets): Likewise.
8805         * solib-svr4.c (solib_svr4_r_brk): New.
8806         (open_symbol_file_object, svr4_current_sos): Always check the
8807         debug base.
8808         (svr4_fetch_objfile_link_map): Do not set debug_base.
8809         (enable_break): Use r_brk if it is set.
8810         (svr4_ilp32_fetch_link_map_offsets): Set r_brk_offset.
8811         (svr4_lp64_fetch_link_map_offsets): Likewise.
8812         * solib-svr4.h (struct link_map_offsets): Add r_brk_offset.
8813
8814 2008-02-20  Markus Deuling  <deuling@de.ibm.com>
8815             Mark Kettenis  <kettenis@gnu.org>
8816
8817         * alpha-tdep.c (alpha_heuristic_unwind_cache): Replace saved_regs by
8818         trad_frame_saved_reg.
8819         (trad-frame.h): New include.
8820
8821         (alpha_heuristic_frame_unwind_cache): Use trad_frame_alloc_saved_regs
8822         instead of frame_obstack_zalloc.
8823         (alpha_heuristic_frame_prev_register): Use trad_frame_get_prev_register.
8824
8825         * Makefile.in (alpha-tdep.o): Add dependency to trad_frame_h.
8826
8827 2008-02-20  Markus Deuling  <deuling@de.ibm.com>
8828
8829         * rs6000-tdep.c (gdb_print_insn_powerpc): Get the current endianess
8830         from disassemble_info instead of gdbarch_byte_order.
8831
8832         * mips-tdep.c (gdb_print_insn_mips): Likewise.
8833         * arm-tdep.c (gdb_print_insn_arm): Likewise.
8834
8835 2008-02-20  Markus Deuling  <deuling@de.ibm.com>
8836
8837         * gdbarch.sh (memory_insert_breakpoint, memory_remove_breakpoint): Add
8838         gdbarch as parameter.
8839
8840         * gdbarch.{c,h}: Regenerate.
8841
8842         * ppc-tdep.h (ppc_linux_memory_remove_breakpoint): Add gdbarch as
8843         parameter.
8844         * mem-break.c (default_memory_insert_breakpoint)
8845         (default_memory_remove_breakpoint): Likewise.
8846         * target.h (default_memory_remove_breakpoint)
8847         (default_memory_insert_breakpoint): Likewise.
8848
8849         * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Add gdbarch as
8850         parameter. Replace current_gdbarch by gdbarch.
8851         * m32r-tdep.c (m32r_memory_insert_breakpoint)
8852         (m32r_memory_remove_breakpoint): Likewise.
8853
8854 2008-02-19  Daniel Jacobowitz  <dan@codesourcery.com>
8855
8856         * MAINTAINERS: Add Vladimir Prus as MI maintainer.
8857
8858 2008-02-19  Joel Brobecker  <brobecker@adacore.com>
8859
8860         * NEWS: Add entry describing Add support improvements.
8861
8862 2008-02-18  Markus Deuling  <deuling@de.ibm.com>
8863
8864         * m68klinux-nat.c (getfpregs_supplies): Replace gdbarch_fp0_regnum by
8865         M68K_FP0_REGNUM.
8866
8867 2008-02-18  Markus Deuling  <deuling@de.ibm.com>
8868
8869         * sentinel-frame.c (sentinel_frame_prev_register): Do not call
8870         register_offset_hack anymore.
8871
8872         * regcache.{c,h} (register_offset_hack): Remove.
8873
8874 2008-02-18  Markus Deuling  <deuling@de.ibm.com>
8875
8876         * hppa-tdep.h (find_global_pointer): Add gdbarch as parameter.
8877
8878         * hppa-hpux-tdep.c (hppa32_hpux_find_global_pointer): Likewise. Replace
8879         current_gdbarch by gdbarch.
8880         (hppa64_hpux_find_global_pointer): Likewise.
8881         * hppa-tdep.c (hppa_find_global_pointer): Likewise.
8882         (hppa32_push_dummy_call, hppa64_push_dummy_call): Update call for
8883         find_global_pointer.
8884
8885         * hppabsd-tdep.c (hppabsd_find_global_pointer): Add gdbarch as
8886         parameter.
8887         * hppa-linux-tdep.c (hppa_linux_find_global_pointer): Likewise.
8888
8889         * hppa-linux-nat.c (hppa_linux_register_addr): Use ARRAY_SIZE instead
8890         of gdbarch_num_regs.
8891
8892         * hppa-hpux-tdep.c (hppa_hpux_sr_for_addr): Add gdbarch as parameter and
8893         replace current_gdbarch by gdbarch.
8894         (hppa_hpux_push_dummy_code): Update call for hppa_hpux_sr_for_addr.
8895
8896 2008-02-18  Markus Deuling  <deuling@de.ibm.com>
8897
8898         * rs6000-nat.c (exec_one_dummy_insn, regmap): Add gdbarch as parameter
8899         and replace current_gdbarch by gdbarch.
8900
8901         (store_register): Update call for exec_one_dummy_insn.
8902         (fetch_register, store_register): Update call of regmap.
8903
8904         * ppcnbsd-nat.c (getregs_supplies, getfpregs_supplies): Add gdbarch as
8905         parameter and replace current_gdbarch by gdbarch.
8906
8907         (ppcnbsd_store_inferior_registers): Use get_regcache_arch to get at
8908         the current architecture. Update call for getregs_supplies and
8909         getfpregs_supplies.
8910         (ppcnbsd_fetch_inferior_registers): Likewise.
8911
8912         * ppcobsd-nat.c (getfpregs_supplies): Add gdbarch as parameter and
8913         replace current_gdbarch by gdbarch.
8914         (ppcobsd_fetch_registers, ppcobsd_store_registers): Use
8915         get_regcache_arch to get at the current architecture. Update call for
8916         getfpregs_supplies.
8917
8918 2008-02-18  Markus Deuling  <deuling@de.ibm.com>
8919
8920         * arch-utils.c (gdbarch_from_bfd): Remove unnecessary {old,new}_gdbarch
8921         variables.
8922
8923 2008-02-15  Markus Deuling  <deuling@de.ibm.com>
8924
8925         * mips-linux-tdep.c (mips_linux_init_abi): Remove internal error.
8926
8927 2008-02-14  Vladimir Prus  <vladimir@codesourcery.com>
8928
8929         * NEWS: Mention pending breakpints in MI.
8930
8931 2008-02-14  Markus Deuling  <deuling@de.ibm.com>
8932
8933         * Makefile.in (ALL_TARGET_OBS): Remove dependency to xtensa-linux-nat.o.
8934
8935 2008-02-13  Markus Deuling  <deuling@de.ibm.com>
8936
8937         Add script to build and test GDB using enable-targets=all.
8938
8939         * gdb_buildall.sh: New file.
8940
8941 2008-02-11  Maxim Grigoriev  <maxim2405@gmail.com>
8942
8943         * NEWS (New native configurations): Xtensa GNU/Linux.
8944         (New targets): Xtensa GNU/Linux.
8945         * Makefile.in (ALL_TARGET_OBS): Add xtensa-linux-nat.o and
8946         xtensa-linux-tdep.o
8947         (ALLDEPFILES): Add xtensa-linux-tdep.c and xtensa-linux-nat.c
8948         (xtensa-linux-nat.o, xtensa-linux-tdep.o): New dependencies.
8949         * configure.tgt (xtensa*-*-linux*): New entry.
8950         * xtensa-config.c (xtensa_tdep): New variable.
8951         (xtensa_config_byte_order, xtensa_config_tdep): Removed.
8952         (rmap): Change format based on new macro XTREG.
8953         (XTENSA_CONFIG_INSTANTIATE): Use new macro defined in xtensa-tdep.h.
8954         * xtensa-linux-nat.c: New.
8955         * xtensa-linux-tdep.c: New.
8956         * xtensa-xtregs.c: New.
8957         * xtensa-tdep.h (xtensa_elf_gregset_t): Update.
8958         (XTENSA_ELF_NGREG, XTREG, XTREG_END, XTENSA_GDBARCH_TDEP_INSTANTIATE)
8959         (XCHAL_NUM_CONTEXTS, XCHAL_HAVE_EXCEPTIONS): New macros.
8960         (xtensa_register_t): New field coprocessor.
8961         (XTENSA_REGISTER_FLAGS_PRIVILEGED): Name spelling corrected.
8962         * xtensa-tdep.c (xtensa_config_tdep, xtensa_config_byte_order): Removed.
8963         (xtensa_pseudo_register_read, xtensa_pseudo_register_write):
8964         Update to handle privileged registers.
8965         (xtensa_supply_gregset) Remove exccause and excvaddr registers.
8966         (xtensa_push_dummy_call): Set windowstart register correctly.
8967         (call0_analyze_prologue): Initialize xtensa_default_isa.
8968         (xtensa_derive_tdep): New.
8969         (xtensa_gdbarch_init): Get rid of xtensa_config_byte_order and
8970         xtensa_config_tdep, use XCHAL_HAVE_BE and xtensa_tdep instead.
8971         Call xtensa_derive_tdep().
8972         * config/xtensa/linux.mh: New.
8973         * regformats/reg-xtensa.dat: New.
8974
8975 2008-02-09  Aleksandar Ristovski  <aristovski@qnx.com>  (tiny change)
8976
8977         * corelow.c (core_open): Use IS_ABSOLUTE_PATH.
8978         (filenames.h): New include.
8979         * Makefile.in (corelow.o): Add dependency for filenames.h.
8980
8981 2008-02-08  Doug Evans  <dje@google.com>
8982
8983         * source.c (find_and_open_source): Always rewrite absolute filenames.
8984
8985 2008-02-07  Doug Evans  <dje@google.com>
8986
8987         * breakpoint.c: #include "hashtab.h".
8988         (ambiguous_names_p): New fn.
8989         (update_breakpoint_locations): When restoring bp enable status, don't
8990         compare function names if any functions have same name.
8991         * Makefile.in (breakpoint.o): Add hashtab.h dependency.
8992
8993 2008-02-07  Joel Brobecker  <brobecker@adacore.com>
8994
8995         * ada-lang.c (symbol_completion_add): Make SV parameter a VEC**
8996         instead of just a VEC*. Update use of SV.
8997         (ada_make_symbol_completion_list): Update symbol_completion_add calls.
8998
8999 2007-02-07  Joel Brobecker  <brobecker@adacore.com>
9000
9001         * NEWS: Put all new commands since gdb-6.7 together.
9002
9003 2007-02-07  Joel Brobecker  <brobecker@adacore.com>
9004
9005         * ada-lang.c: #include "vec.h".
9006         (struct string_vector, new_string_vector, string_vector_append):
9007         Delete.
9008         (char_ptr): New typedef.
9009         (DEF_VEC_P (char_ptr)): New VEC type.
9010         (symbol_completion_add): Update profile to take the new VEC type
9011         instead of the old string_vector structure. Update code accordingly.
9012         (ada_make_symbol_completion_list): Use the new VEC type instead of
9013         the old string_vector structure, and update the code accordingly.
9014         * Makefile.in (ada-lang.o): Add dependency on vec.h.
9015
9016 2008-02-06  Pierre Muller  <muller@ics.u-strasbg.fr>
9017
9018         * p-exp.y: Set current_type in missing places.
9019         (leftdiv_is_integer): New static variable.
9020         Typecast right operand of BINOP_DIV to long_double if both operands
9021         are integers.
9022
9023 2008-02-06  Maciej W. Rozycki  <macro@mips.com>
9024
9025         * remote-mips.c (set_breakpoint): Rename to...
9026         (mips_set_breakpoint): ... this.
9027         (clear_breakpoint): Rename to...
9028         (mips_clear_breakpoint): ... this.
9029         (common_breakpoint): Rename to...
9030         (mips_common_breakpoint): ... this.
9031         (check_lsi_error): Rename to...
9032         (mips_check_lsi_error): ... this.
9033
9034 2007-02-05  Joel Brobecker  <brobecker@adacore.com>
9035
9036         * language.h (struct language_defn): Add new field
9037         la_make_symbol_completion_list.
9038         * symtab.c (default_make_symbol_completion_list): Renames
9039         make_symbol_completion_list.
9040         (make_symbol_completion_list): New function.
9041         * symtab.h (default_make_symbol_completion_list): Add declaration.
9042         * langauge.c (unknown_language): Set la_make_symbol_completion_list.
9043         (auto_language, local_language): Likewise.
9044         * objc-lang.c (objc_language_defn): Likewise.
9045         * scm-lang.c (scm_language_defn): Likewise.
9046         * m2-lang.c (m2_language_defn): Likewise.
9047         * f-lang.c (f_language_defn): Likewise.
9048         * jv-lang.c (java_language_defn): Likewise.
9049         * p-lang.c (pascal_language_defn): Likewise.
9050         * c-lang.c (c_language_defn, cplus_language_defn, asm_language_defn)
9051         (minimal_language_defn): Likewise.
9052         * ada-lang.c (struct string_vector): New structure.
9053         (new_string_vector, string_vector_append, ada_unqualified_name)
9054         (add_angle_brackets, symbol_completion_match, symbol_completion_add)
9055         (ada_make_symbol_completion_list): New functions.
9056         (ada_language_defn): Set la_make_symbol_completion_list.
9057         * ada-lang.h (ada_make_symbol_completion_list): Remove declaration,
9058         this function is static.
9059
9060 2008-02-05  Kevin Buettner  <kevinb@redhat.com>
9061
9062         * mn10300-tdep.c (mn10300_push_dummy_call): Adjust stack pointer
9063         to account for call site optimizations.
9064
9065 2008-02-05  Andrzej Zaborowski  <balrogg@gmail.com>
9066
9067         * tracepoint.c (read_actions): Handle end-of-text indicator
9068         in action list properly.  (Committed by Jim Blandy)
9069
9070 2008-02-05  Jim Blandy  <jimb@red-bean.com>
9071
9072         * ax-gdb.c (gen_expr): Yield ordinary error if asked to trace a
9073         pseudoregister, not an internal error.
9074         Reported by: Andrzej Zaborowski
9075
9076 2008-02-04  Vladimir Prus  <vladimir@codesourcery.com>
9077
9078         * varobj.c (c_value_of_variable): Use xstrdup.
9079
9080 2008-02-04  Vladimir Prus  <vladimir@codesourcery.com>
9081
9082         Update stored rendition of varobj value when format changes.
9083         * varobj.c (varobj_set_display_format): Recomputed
9084         print_value.
9085         (c_value_of_variable): Return print_value.
9086
9087 2008-02-03  Doug Evans  <dje@google.com>
9088
9089         * eval.c (evaluate_subexp_standard): Fix type of result of mixed
9090         integer/float division operations when EVAL_AVOID_SIDE_EFFECTS.
9091         * valops.c (value_one): New function.
9092         * value.h (value_one): Declare.
9093
9094         Fix argument promotion for binary arithmetic ops for C.
9095         * valarith.c (unop_result_type): New fn.
9096         (binop_result_type): New fn.
9097         (value_binop): Move result type computation to binop_result_type.
9098         (value_pos, value_neg, value_complement): Move result type
9099         computation to unop_result_type.
9100
9101         PR 2384
9102         * gdbtypes.c (get_vptr_fieldno): Renamed from fill_in_vptr_fieldno.
9103         Return basetype, fieldno if found.  All callers updated.
9104         Don't cache TYPE_VPTR_FIELDNO, TYPE_VPTR_BASETYPE if from different
9105         objfile.
9106         * gdbtypes.h (get_vptr_fieldno): Renamed from fill_in_vptr_fieldno.
9107         * symfile.h (fill_in_vptr_fieldno): Delete.
9108
9109 2008-02-02  Doug Evans  <dje@google.com>
9110
9111         * valarith.c (value_binop): Handle unsigned BINOP_REM division by zero.
9112
9113         * typeprint.c (*): Whitespace cleanup.
9114
9115 2008-02-02  Mark Kettenis  <kettenis@gnu.org>
9116             Luis Machado  <luisgpm@br.ibm.com>
9117             Thiago Jung Bauermann  <bauerman@br.ibm.com>
9118
9119         * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Pass floats that
9120         don't fit into registerson the stack the way GCC does.
9121
9122 2008-02-01  Joel Brobecker  <brobecker@adacore.com>
9123
9124         * symtab.c (symbol_set_names): Do not add an entry in the demangling
9125         hash table for Ada symbols. Just store the linkage name as is,
9126         and leave the demangled_name as NULL.
9127
9128 2007-02-01  Joel Brobecker  <brobecker@adacore.com>
9129
9130         * dwarf2read.c (add_partial_symbol): Always store all Ada subprograms
9131         in the global scope.
9132         (new_symbol): Likewise.
9133
9134 2008-02-01  Vladimir Prus  <vladimir@codesourcery.com>
9135
9136         * breakpoint.c (break_command_1): Return void.
9137         (break_command_really): Return void.  Rethrow
9138         exceptions instead of returning.
9139         (gdb_breakpoint): Remove the error_message parameter.
9140         Return void.  Rename to set_breakpoint.
9141         * gdb.h (gdb_breakpoint): Rename and move to...
9142         * breakpoint.h (set_breakpoint): ...here.
9143         * mi/mi-cmb-break.c (mi_cmd_break_insert): Restore
9144         event hooks even if exception is thrown.  Adjust to
9145         gdb_breakpoint interface changes.
9146
9147
9148 2008-02-01  Thiago Jung Bauermann  <bauerman@br.ibm.com>
9149
9150         * ppc-sysv-tdep.c (ppc64_sysv_abi_push_dummy_call): Write 32-bit
9151         float in both first and second word in the doubleword, to support
9152         old and new ABIs.
9153
9154 2008-02-01  Vladimir Prus  <vladimir@codesourcery.com>
9155
9156         Properly rethrow exception.  This fixes errors
9157         about non-existent functions for -break-insert.
9158         * breakpoint.c (break_command_really): Use throw_exception
9159         for rethrowing.  If rethrowing, don't print the exception.
9160
9161 2008-01-31  Thiago Jung Bauermann  <bauerman@br.ibm.com>
9162
9163         * NEWS: Mention Decimal Floating Point support.
9164
9165 2008-01-31  Joel Brobecker  <brobecker@adacore.com>
9166
9167         * std-regs.c (value_of_builtin_frame_pc_reg): Change the returned
9168         value type to builtin_type_void_func_ptr.
9169
9170 2008-01-31  Andreas Krebbel  <krebbel1@de.ibm.com>
9171
9172         * s390-tdep.c (is_float_singleton, is_float_like,
9173         alignment_of, s390_return_value): Make checks for
9174         TYPE_CODE_FLT to match TYPE_CODE_DECFLOAT as well.
9175
9176 2008-01-31  Luis Machado  <luisgpm@br.ibm.com>
9177             Thiago Jung Bauermann  <bauerman@br.ibm.com>
9178
9179         * infcmd.c (default_print_registers_info): Also print hex
9180         raw contents for TYPE_CODE_DECFLOAT registers.
9181         * ppc-tdep.h (gdbarch_tdep): Add ppc_dl0_regnum member.
9182         * rs6000-tdep.c (IS_DFP_PSEUDOREG): New macro.
9183         (rs6000_register_name): Add support for DFP pseudo-registers.
9184         (rs6000_pseudo_register_type): Likewise.
9185         rs6000_pseudo_register_reggroup_p): Likewise.
9186         (ppc_pseudo_register_read): New function.
9187         (ppc_pseudo_register_write): Likewise.
9188         (rs6000_pseudo_register_read): Likewise.
9189         (rs6000_pseudo_register_write): Likewise.
9190         (e500_pseudo_register_read): Move checks to
9191         rs6000_pseudo_register_read.
9192         (e500_pseudo_register_write): Move checks to
9193         rs6000_pseudo_register_write.
9194         (rs6000_gdbarch_init): Initialize tdep->ppc_dl0_regnum.  Install
9195         rs6000_pseudo_register_read and rs6000_pseudo_register_write
9196         in gdbarch if SPE or DFP is available.  Adjust gdbarch's
9197         num_pseudo_regs to account for DFP pseudo regs.
9198
9199 2008-01-31  Thiago Jung Bauermann  <bauerman@br.ibm.com>
9200
9201         * ppc-tdep.h (struct gdbarch_tdep): Remove ppc_ev31_regnum member.
9202         * rs6000-tdep.c (IS_SPE_PSEUDOREG): New macro.
9203         (spe_register_p, rs6000_register_name, rs6000_pseudo_register_type,
9204         rs6000_pseudo_register_reggroup_p, e500_move_ev_register,
9205         e500_pseudo_register_read, e500_pseudo_register_write): Use
9206         IS_SPE_PSEUDOREG macro.
9207         (rs6000_frame_cache): Remove use of tdep->ppc_ev31_regnum.
9208         (rs6000_gdbarch_init): Remove unnecessary num_sprs local variable.
9209         Remove initialization of tdep->ppc_ev31_regnum.
9210
9211 2008-01-08  Paul Hilfinger  <hilfinger@adacore.com>
9212
9213         * printcmd.c (print_formatted): Handle references as for unformatted
9214         prints.
9215
9216 2008-01-30  Joel Brobecker  <brobecker@adacore.com>
9217
9218         * eval.c (evaluate_subexp_standard): Add handling of user
9219         registers when in EVAL_AVOID_SIDE_EFFECTS mode.
9220
9221 2008-01-30  Pierre Muller  <muller@ics.u-strasbg.fr>
9222
9223         * eval.c (evaluate_subexp_standard): Support
9224         BINOP_INTDIV opcode.
9225
9226 2008-01-30  Paul N. Hilfinger  <hilfinger@adacore.com>
9227
9228         * valarith.c (value_binop): Add floating-point BINOP_MIN and
9229         BINOP_MAX cases.
9230         For BINOP_EXP, use length and signedness of left operand only for
9231         result, as for shifts.
9232         For integral operands to BINOP_EXP, use new integer_pow and
9233         uinteger_pow functions so as to get full range of results.
9234         (integer_pow): New function.
9235         (uinteger_pow): New function.
9236
9237 2008-01-30  Vladimir Prus  <vladimir@codesourcery.com>
9238
9239         Use vector for varobj_list_children interface.
9240         * gdb/varobj.c (varobj_list_children): Return vector
9241         of varobjs.
9242         * gdb/varobj.h (varobj_list_children): Adjust
9243         prototype.
9244         (varobj_p): Declare.  Declare vector thereof.
9245         * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust
9246         for varobj_list_children change.
9247         * Makefile.in (varobj_h): Update dependencies.
9248
9249 2008-01-30  Thiago Jung Bauermann  <bauerman@br.ibm.com>
9250
9251         * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Add support for
9252         TYPE_CODE_DECFLOAT arguments.
9253         (ppc64_sysv_abi_push_dummy_call) Likewise.
9254         (get_decimal_float_return_value): New function.
9255         (do_ppc_sysv_return_value): Add support for TYPE_CODE_DECFLOAT return
9256         values by calling get_decimal_float_return_value.
9257         (ppc64_sysv_abi_return_value): Likewise.
9258
9259 2008-01-30  Nick Roberts  <nickrob@snap.net.nz>
9260
9261         * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file):  Add field
9262         for preprocessor macro information.  Formatting changes.
9263
9264 2008-01-29  Daniel Jacobowitz  <dan@codesourcery.com>
9265
9266         * remote.c (struct remote_state): Add cached_wait_status.
9267         (remote_exec_file): New variable.
9268         (PACKET_vAttach, PACKET_vRun): New constants.
9269         (extended_remote_restart): Do not query for status.
9270         (struct start_remote_args): New.
9271         (remote_start_remote): Take it as a second argument.  Check
9272         whether the target is running.  Issue an error for non-running
9273         non-extended targets.  Cache the wait status.  Set inferior_ptid
9274         here.
9275         (remote_open_1): Prompt to disconnect non-running targets.  Make
9276         sure the target is marked running.  Do not set inferior_ptid here.
9277         Update call to remote_start_remote.  Do not call remote_check_symbols
9278         if the target is not running.
9279         (remote_detach_1): Rename from remote_detach.  Take an EXTENDED
9280         argument.  Handle a non-running target.
9281         (remote_detach): Use it.
9282         (extended_remote_detach): New.
9283         (remote_disconnect): Fix typo.  Use remoute_mourn_1.
9284         (extended_remote_attach_1, extended_remote_attach)
9285         (extended_async_remote_attach): New.
9286         (remote_vcont_resume): Remove unused variable.
9287         (remote_wait, remote_async_wait): Use any cached wait status.
9288         (putpkt_binary, getpkt): Clear any cached wait status.
9289         (extended_remoute_mourn_1): New.
9290         (extended_remote_mourn): Use it.
9291         (extended_async_remote_mourn, extended_remote_run): New.
9292         (extended_remote_create_inferior_1): New.
9293         (extended_remote_create_inferior): Use it.
9294         (extended_remote_async_create_inferior): Likewise.
9295         (remote_xfer_partial): Skip for non-executing targets.
9296         (init_extended_remote_ops): Set to_detach and to_attach.
9297         (init_extended_async_remote_ops): Likewise.  Use
9298         extended_async_remote_mourn.
9299         (_initialize_remote): Register vAttach, vRun, and
9300         set remote exec-file.
9301         * NEWS: Mention vAttach, vRun, and gdbserver extended-remote support.
9302
9303 2008-01-29  Daniel Jacobowitz  <dan@codesourcery.com>
9304
9305         * Makefile.in (symfile.o): Update.
9306         * NEWS: Mention exec tracing support.
9307         * inf-ttrace.c (inf_ttrace_wait): Return TARGET_WAITKIND_EXECD for
9308         exec events.
9309         * infcmd.c (kill_if_already_running, detach_command)
9310         (disconnect_command): Replace SOLIB_RESTART with no_shared_libraries.
9311         * infrun.c (MAY_FOLLOW_EXEC, may_follow_exec): Delete.
9312         (follow_exec): Do not check may_follow_exec.  Do not mourn and push
9313         targets.  Apply the sysroot path to the loaded executable.  Use
9314         no_shared_libraries.
9315         * linux-nat.c (linux_child_follow_fork): Print fork following
9316         messages if verbose.
9317         (kill_wait_callback): Kill again before waiting a second time.
9318         * symfile.c (symbol_file_clear): Replace SOLIB_RESTART with
9319         no_shared_libraries.
9320
9321 2008-01-29  Joel Brobecker  <brobecker@adacore.com>
9322
9323         * amd64-tdep.c (amd64_classify): Add handling of TYPE_CODE_CHAR.
9324
9325 2008-01-29  Joel Brobecker  <brobecker@adacore.com>
9326
9327         * nto-tdep.h: Remove #include "defs.h".
9328         * nto-tdep.c: Add #include "defs.h".
9329         * Makefile.in (nto_tdep_h): Update dependencies.
9330         (nto-tdep.o): Likewise.
9331
9332 2008-01-29  Joel Brobecker  <brobecker@adacore.com>
9333
9334         * infrun.c (wait_for_inferior): Add treat_exec_as_sigtrap parameter
9335         and use it.
9336         (proceed, start_remote): Update call to wait_for_inferior.
9337         * inferior.h (wait_for_inferior): Update declaration.
9338         * fork-child.c, infcmd.c, solib-irix.c, solib-osf.c, solib-sunos.c,
9339         solib-svr4.c, win32-nat.c: Update calls to wait_for_inferior.
9340         * inf-ttrace.c (inf_ttrace_wait): Report TTEVT_EXEC events as
9341         TARGET_WAITKIND_EXECD instead of TARGET_WAITKIND_STOPPED.
9342
9343 2008-01-29  Aleksandar Ristovski  <aristovski@qnx.com>
9344
9345         * varobj (adjust_value_for_child_access): Added checking for
9346         returned value from gdb_value_ind.
9347         (c_describe_child): Likewise.
9348         (cplus_describe_child): Fixed a typo.
9349
9350 2008-01-29  Jim Blandy  <jimb@red-bean.com>
9351
9352         * MAINTAINERS: Update my info.
9353
9354 2008-01-29  Vladimir Prus  <vladimir@codesourcery.com>
9355
9356         Use multiple locations for hardware watchpoints.
9357         This eliminates the need to traverse value chain, doing
9358         various checks, in three different places.
9359
9360         * breakpoint.h (struct bp_location): New fields
9361         lengths and watchpoint_type.
9362         (struct breakpoint): Remove the val_chain field.
9363         * breakpoint.c (is_hardware_watchpoint): New.
9364         (free_valchain): Remove.
9365         (update_watchpoint): New.
9366         (insert_bp_location): For hardware watchpoint, just
9367         directly insert it.
9368         (insert_breakpoints): Call update_watchpoint_locations
9369         on all watchpoints.  If we have failed to insert
9370         any location of a hardware watchpoint, remove all inserted
9371         locations.
9372         (remove_breakpoint): For hardware watchpoints, directly
9373         remove location.
9374         (watchpoints_triggered): Iterate over locations.
9375         (bpstat_stop_status): Use only first location of
9376         a resource watchpoint.
9377         (delete_breakpoint): Don't call free_valchain.
9378         (print_one_breakpoint): Don't print all
9379         locations for watchpoints.
9380         (breakpoint_re_set_one): Use update_watchpoint for
9381         watchpoints.
9382
9383 2008-01-29  Vladimir Prus  <vladimir@codesourcery.com>
9384
9385         Don't reset watchpoint block on solib load.
9386
9387         * breakpoint.c (insert_bp_location): For watchpoints,
9388         recompute condition.
9389         (breakpoint_re_set_one): Instead of recomputing value
9390         and condition for watchpoints, just reset value and
9391         let insert_breakpoints/insert_bp_location recompute it.
9392         Don't do anything about disabled watchpoint.
9393
9394 2008-01-29  Pierre Muller  <muller@ics.u-strasbg.fr>
9395
9396         * valarith.c (value_binop): Handle unsigned integer
9397         division by zero.
9398
9399 2008-01-28  Kevin Buettner  <kevinb@redhat.com>
9400
9401         * mn10300-tdep.c (mn10300_analyze_prologue): Check for an
9402         instruction pattern that appears frequently in position
9403         independent code.  Fix bug in code which looks for "fmov" and
9404         backtracks if no "fmov" is found.
9405
9406 2008-01-28  Doug Evans  <dje@google.com>
9407
9408         * dbxread.c (read_dbx_symtab): Fix indentation.
9409         Reformat comments to 80 columns.
9410         Move local var def closer to only use.
9411
9412 2008-01-28  Daniel Jacobowitz  <dan@codesourcery.com>
9413
9414         * fork-child.c (SHELL_FILE): Remove #ifndef.
9415         (fork_inferior): Remove SHELL_COMMAND_CONCAT.
9416
9417 2008-01-25  Pierre Muller  <muller@ics.u-strasbg.fr>
9418
9419         * i386-tdep.c (i386_skip_noop): New function.
9420         (i386_analyze_prologue): Call i386_skip_noop function.
9421
9422 2008-01-24  Michael Snyder  <msnyder@specifix.com>
9423
9424         * procfs.c (procfs_xfer_partial): Comment, cut/paste error.
9425         * win32-nat.c (win32_xfer_partial): Ditto.
9426         * target.c (default_xfer_partial): Minor whitespace adjustment.
9427
9428 2008-01-24  Pedro Alves  <pedro@codesourcery.com>
9429
9430         * arm-tdep.c (arm_addr_bits_remove): In non 26-bit mode, don't
9431         strip bit 1 even if pc doesn't point to thumb code.
9432
9433 2008-01-23  Daniel Jacobowitz  <dan@codesourcery.com>
9434
9435         * remote.c (remote_wait): Handle SIGINT between packets.
9436         (remote_async_wait): Likewise.
9437
9438 2008-01-23  Vladimir Prus  <vladimir@codesourcery.com>
9439             Chris Demetriou  <cgd@google.com>
9440
9441         * thread.c (add_thread_silent): Renamed
9442         from add_thread.
9443         (print_thread_events): New variable definition.
9444         (show_print_thread_events): New function.
9445         (_initialize_thread): Add "set print thread-events" and
9446         "show print thread-events" commands.
9447         (add_thread): Announce new thread.
9448         * gdbthread.h (add_thread_silent): Declare.
9449         (print_thread_events): New variable declaration.
9450         * inf-ttrace.c (inf_ttrace_wait): Don't
9451         inform about new thread, as add_thread is always
9452         called too, and will take care of that.
9453         * infrun.c (handle_inferior_event): Likewise.
9454         * procfs.c (procfs_wait): Likewise.
9455         * remote.c (remote_currthread): Likewise.
9456         * sol-thread.c (sol_thread_wait): Likewise.
9457         * win32-nat.c (get_win32_debug_event): Likewise.
9458         * linux-thread-db.c (attach_thread): Likewise.
9459         Remove the verbose parameter.
9460         (check_event): Make detach_thread be verbose
9461         only if print_thread_events is set.
9462         * linux-nat.c (lin_lwp_attach_lwp): Don't inform
9463         about new thread.  This is called only from
9464         linux-thread-db.c:attach_thread, which will take care.
9465         Remove the verbose parameter.
9466         * linux-nat.h (lin_lwp_attach_lwp): Adjust prototype.
9467
9468 2008-01-23  Nick Roberts  <nickrob@snap.net.nz>
9469
9470         * mi/mi-cmd-var.c (mi_cmd_var_set_format): Add value field to output.
9471
9472 2008-01-22  Vladimir Prus  <vladimir@codesourcery.com>
9473
9474         * breakpoint.c (break_command_really): New parameter
9475         ignore_count.
9476         (break_command_1): Pass 0 as
9477         ignore_count to break_command_really.
9478         (gdb_breakpoint): Pass ignore_count to
9479         break_command_really.
9480
9481 2008-01-21  Kevin Buettner  <kevinb@redhat.com>
9482
9483         * mn10300-linux-tdep.c (am33_linux_sigframe_cache_init): Find
9484         sigcontext struct via pointer.
9485         (struct sigframe comment): Update to show new field `psc'.
9486
9487 2008-01-21  Vladimir Prus  <vladimir@codesourcery.com>
9488
9489         * infrun.c (handle_inferior_event): If
9490         we failed to remove breakpoints, error,
9491         don't try to increment PC by hand.
9492
9493 2008-01-18  Nick Hudson  <nick.hudson@dsl.pipex.com>
9494
9495         Add NetBSD/hppa target and host support.
9496
9497         * hppabsd-tdep.c (hppabsd_supply_gregset): Move to ...
9498         (hppabsd_gregset): Move to ...
9499         (hppabsd_regset_from_core_section): Rename
9500         hppaobsd_regset_from_core_section and move to ...
9501         (hppabsd_find_global_pointer): Update comment.
9502         (hppabsd_init_abi): Make global. Do not register
9503         hppabsd_regset_from_core_section.
9504         (hppabsd_core_osabi_sniffer): Rename hppaobsd_core_osabi_sniffer and
9505         move to ...
9506         (_initialize_hppabsd_tdep): Move to ...
9507         * hppaobsd-tdep.c: ... here. New file.
9508         * hppnbsd-tdep.c: New file.
9509         * hppnbsd-nat.c: New file.
9510         * Makefile.in (ALL_TARGET_OBS): Add hppanbsd-tdep.o and hppaobsd-tdep.o.
9511         (ALLDEPFILES): Add hppabsd-nat.c and hppabsd-tdep.c.
9512         (hppabsd-nat.o, hppabsd-tdep.o): New dependencies.
9513         (hppabsd-tdep.o, hppaobsd-tdep.o): Update dependencies.
9514         * configure.host (hppa*-*-netbsd*): New entry.
9515         * configure.tgt (hppa*-*-netbsd*): New entry.
9516         (hppa*-*-openbsd*): Update.
9517         * NEWS (New native configuration): Mention NetBSD/hppa.
9518         (New targets): Mention NetBSD/hppa.
9519
9520 2008-01-18  Markus Deuling  <deuling@de.ibm.com>
9521
9522         * gdbarch.sh (function_list): Add new property bits_big_endian to
9523         gdbarch structure.
9524         * gdbarch.{c,h}: Regenerate.
9525
9526         * value.c (struct value): Replace BITS_BIG_ENDIAN by
9527         gdbarch_bits_big_endian (comment).
9528         (unpack_field_as_long, modify_field): Likewise.
9529         * value.h: Likewise (comment).
9530         * valops.c (value_slice): Likewise.
9531         * valarith.c (value_subscript, value_bit_index): Likewise.
9532         * gdbtypes.h (field): Likewise (comment).
9533         * eval.c (evaluate_subexp_standard): Likewise.
9534         * dwarf2read.c (dwarf2_add_field): Likewise.
9535         * ada-lang.c (decode_packed_array, ada_value_primitive_packed_val)
9536         (move_bits, ada_value_assign, value_assign_to_component): Likewise.
9537
9538         * defs.h (BITS_BIG_ENDIAN): Remove.
9539
9540 2008-01-18  Markus Deuling  <deuling@de.ibm.com>
9541
9542         * jv-exp.y (yylex): Replace DEPRECATED_STREQN with the appropriate
9543         function calls.
9544         * m2-exp.y (yylex): Likewise.
9545         * objc-exp.y (yylex): Likewise.
9546
9547         * defs.h (DEPRECATED_STREQN): Remove.
9548
9549 2008-01-17  H.J. Lu  <hjl.tools@gmail.com>
9550
9551         * MAINTAINERS: Update my email address.
9552
9553 2008-01-17  Jim Blandy  <jimb@codesourcery.com>
9554
9555         * README: Mention gdbserver/README.
9556
9557 2008-01-17  Pierre Muller  <muller@ics.u-strasbg.fr>
9558
9559         * valarith.c (value_binop): Handle BINOP_INTDIV
9560         for unsigned and signed integers.
9561
9562 2008-01-17  Ulrich Weigand  <uweigand@de.ibm.com>
9563
9564         * s390-tdep.c (s390_gdbarch_init): Set default long double
9565         type to 128-bit IEEE quad.
9566
9567 2008-01-17  Joel Brobecker  <brobecker@adacore.com>
9568
9569         * hpux-thread.c (hpux_thread_resume): Delete commented-out code.
9570
9571 2008-01-16  Mark Kettenis  <kettenis@gnu.org>
9572
9573         * auxv.c (fprint_target_auxv): Add support for AT_SUN_AUXFLAGS.
9574
9575         * dfp.c, dfp.h: Rename decimal_to_double to decimal_to_doublest.
9576         * value.c: All callers changed.
9577
9578 2008-01-16  Markus Deuling  <deuling@de.ibm.com>
9579
9580         * rs6000-nat.c (add_vmap, vmap_ldinfo, vmap_exec): Replace
9581         DEPRECATED_STREQ by its expression.
9582         * coffread.c (coff_locate_sections, coff_symtab_read): Likewise.
9583         * xcoffread.c (read_xcoff_symtab, read_symbol_lineno, find_linenos)
9584         (scan_xcoff_symtab): Likewise.
9585         * hppa-hpux-tdep.c (hppa_hpux_skip_trampoline_code): Likewise.
9586         * f-lang.c (find_common_for_function): Likewise.
9587         * objc-exp.y (parse_number): Likewise.
9588
9589         * defs.h (DEPRECATED_STREQ): Remove.
9590
9591 2008-01-16  Markus Deuling  <deuling@de.ibm.com>
9592
9593         * mn10300-tdep.h (AM33_MODE): Add gdbarch as parameter.
9594         * mn10300-tdep.c (set_reg_offsets, mn10300_analyze_prologue): Use
9595         get_frame_arch to get at the current_architecture. Update AM33_MODE
9596         call.
9597         (mn10300_analyze_prologue): Add gdbarch as parameter. Update caller.
9598         (mn10300_frame_unwind_cache): Use get_frame_arch to get at the current
9599         architecture.
9600         (set_reg_offsets, mn10300_analyze_prologue): Fix indentation.
9601
9602 2008-01-16  Markus Deuling  <deuling@de.ibm.com>
9603
9604         * amd64-nat.h (amd64_native_gregset_supplies_p): Add gdbarch as
9605         parameter.
9606         * amd64-nat.c (amd64_native_gregset_supplies_p): Likewise.
9607
9608         (amd64_native_gregset_reg_offset): Add gdbarch as parameter. Replace
9609         current_gdbarch by gdbarch. Update caller.
9610
9611         * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers)
9612         (amd64_linux_store_inferior_registers): Use get_regcache_arch to get at
9613         the current architecture. Update calls of
9614         amd64_native_gregset_supplies_p.
9615         * amd64bsd-nat.c (amd64bsd_fetch_inferior_registers)
9616         (amd64bsd_store_inferior_registers): Likewise.
9617
9618 2008-01-16  Markus Deuling  <deuling@de.ibm.com>
9619
9620         * ppc-linux-nat.c (ppc_register_u_addr): Add gdbarch as parameter.
9621         Replace current_gdbarch by gdbarch. Update caller.
9622
9623 2008-01-16  Markus Deuling  <deuling@de.ibm.com>
9624
9625         * dbxread.c (repeated_header_complaint, dbx_symfile_init)
9626         (read_dbx_dynamic_symtab, function_outside_compilation_unit_complaint)
9627         (read_dbx_symtab, end_psymtab, dbx_psymtab_to_symtab_1)
9628         (dbx_psymtab_to_symtab, read_ofile_symtab, process_one_symbol)
9629         (stabsect_build_psymtabs): Fix indentation.
9630
9631 2008-01-15  Michael Snyder  <msnyder@specifix.com>
9632
9633         * corelow.c (core_xfer_partial): Comment, cut/paste error.
9634
9635 2008-01-14  Pierre Muller  <muller@ics.u-strasbg.fr>
9636
9637         * win32-nat.c (win32_create_inferior): Restore code calling
9638         CloseHandle on ProcessInformation structure.
9639
9640 2008-01-13  Nick Hudson  <nick.hudson@dsl.pipex.com>
9641
9642         * configure.ac: Check for void * as 3 argument of ptrace.
9643         * configure: regenerate.
9644
9645 2008-01-11  Markus Deuling  <deuling@de.ibm.com>
9646
9647         * alpha-tdep.c (alpha_heuristic_proc_start)
9648         (alpha_sigtramp_register_address): Add gdbarch as parameter. Replace
9649         current_gdbarch by gdbarch.
9650
9651         (alpha_heuristic_frame_unwind_cache): Use get_frame_arch to get at the
9652         current architecture by frame_info. Update alpha_heuristic_proc_start
9653         call.
9654
9655         (alpha_sigtramp_frame_this_id, alpha_sigtramp_frame_prev_register): Use
9656         get_frame_arch to get at the current architecture by frame_info. Update
9657         alpha_sigtramp_register_address call.
9658
9659         * arm-tdep.c (thumb_scan_prologue): Add gdbarch as parameter and replace
9660         current_gdbarch by gdbarch. Update caller.
9661         (convert_to_extended, convert_from_extended): Add endianess parameter
9662         for comparison. Update caller.
9663         (arm_extract_return_value, arm_store_return_value): Use
9664         get_regcache_arch to get at the current architecture.
9665
9666         * cris-tdep.c (cris_register_size): Add gdbarch as parameter. Replace
9667         current_gdbarch by gdbarch. Update caller.
9668         (cris_gdb_func, move_to_preg_op, none_reg_mode_move_from_preg_op): Add
9669         gdbarch as parameter. Update caller. Replace current_gdbarch by gdbarch.
9670
9671         * h8300-tdep.c (E_PSEUDO_CCR_REGNUM, E_PSEUDO_EXR_REGNUM, BINWORD): Add
9672         gdbarch as parameter. Update caller.
9673         (h8300_init_frame_cache): Add gdbarch as parameter. Replace
9674         current_gdbarch by gdbarch. Update caller.
9675
9676         * hppa-tdep.c (skip_prologue_hard_way): Add gdbarch as parameter and
9677         update caller. Replace current_gdbarch by gdbarch.
9678
9679         * m32c-tdep.c (m32c_skip_trampoline_code): Use get_frame_arch to get at
9680         the current architecture. Replace current_gdbarch by gdbarch.
9681         * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Likewise.
9682         (STACK_CORRECTION, USE_PAGE_REGISTER): Replace M6811_TDEP by its
9683         expression. Add gdbarch as parameter and replace current_gdbarch with
9684         it. Update caller.
9685         (M6811_TDEP): Remove.
9686         (m68hc11_frame_prev_register): Use get_frame_arch to get at the current
9687         architecture.
9688         (m68hc11_scan_prologue): Add gdbarch as parameter. Replace
9689         current_gdbarch by gdbarch. Update caller.
9690
9691         * m68k-tdep.c (m68k_analyze_prologue): Add gdbarch as parameter and
9692         update caller.
9693         (m68k_analyze_register_saves): Likewise. Also replace current_gdbarch
9694         by gdbarch.
9695
9696         * rs6000-tdep.c (skip_prologue): Add gdbarch as parameter and update
9697         caller. Relace current_gdbarch by gdbarch.
9698         (altivec_register_p, spe_register_p): Likewise.
9699         * ppc-tdep.h (altivec_register_p, spe_register_p): Add gdbarch as
9700         parameter.
9701         * ppc-linux-nat.c (fetch_register, store_register): Update caller of
9702         altivec_register_p and spe_register_p.
9703
9704         * score-tdep.c (score_fetch_inst): Add gdbarch as parameter. Update
9705         caller. Replace current_gdbarch by gdbarch.
9706         (score_analyze_prologue): use get_frame_arch to get at the current
9707         architecture.
9708
9709         * sparc-tdep.h (sparc_analyze_prologue): Add gdbarch as parameter.
9710         * sparc-tdep.c (sparc_analyze_prologue): Likewise. Replace
9711         current_gdbarch by gdbarch. Update caller.
9712         (sparc_frame_cache): Use get_frame_arch to get at the current
9713         architecture.
9714         * sparce64-tdep.c (sparc64_skip_prologue): Update call of
9715         sparc_analyze_prologue.
9716
9717         * mn10300-tdep.c (mn10300_dwarf2_reg_to_regnum): Add gdbarch as
9718         parameter.
9719
9720 2008-01-11  Markus Deuling  <deuling@de.ibm.com>
9721
9722         * exec.c: #include "arch-utils.h"
9723          (print_section_info): Use gdbarch_from_bfd to get at the
9724         current architecture. Replace current_gdbarch. Fix indention. Replace
9725         deprecated_print_address_numeric by paddress.
9726         * Makefile.in (exec.o) Add dependency to arch-utils.h.
9727
9728         * valprint.c (val_print_string): Replace
9729         deprecated_print_address_numeric.
9730         * tracepoint.c (trace_mention, scope_info): Likewise.
9731         * symmisc.c (dump_msymbols, dump_psymtab, dump_symtab_1, print_symbol)
9732         (print_symbol, print_partial_symbols, maintenance_info_psymtabs)
9733         (maintenance_check_symtabs): Likewise.
9734         * symfile.c (list_overlays_command): Likewise.
9735         * stack.c (frame_info, print_block_frame_labels): Likewise.
9736         * printcmd.c (print_address, print_address_demangle)
9737         (address_info): Likewise.
9738         * corefile.c (memory_error): Likewise.
9739         * infcmd.c (jump_command): Likewise.
9740         * breakpoint.c (insert_bp_location, describe_other_breakpoints)
9741         (mention, delete_breakpoint): Likewise.
9742         * c-valprint.c (print_function_pointer_address, c_val_print): Likewise.
9743         * dwarf2read.c (dump_die): Likewise.
9744         * ada-valprint.c (ada_val_print_1): Likewise.
9745         * f-valprint.c (f_val_print): Likewise.
9746         * linux-fork.c (info_forks_command): Likewise.
9747         * m32r-com.c (m32r_load_section, m32r_load)
9748         (m32r_upload_command): Likewise.
9749
9750         * ui-out.c (ui_out_field_core_addr): Remove unnecessary comment.
9751
9752 2008-01-11  Markus Deuling  <deuling@de.ibm.com>
9753
9754         * gdbarch.sh (skip_prologue): Add gdbarch
9755         as parameter.
9756         * gdbarch.{c,h}: Regenerate.
9757
9758         * alpha-tdep.c (alpha_skip_prologue): Add gdbarch as parameter.
9759         * amd64-tdep.c (amd64_skip_prologue): Likewise.
9760         * avr-tdep.c (avr_skip_prologue): Likewise.
9761         * cris-tdep.c (cris_skip_prologue): Likewise.
9762         * frv-tdep.c (frv_skip_prologue): Likewise.
9763         * h8300-tdep.c (h8300_skip_prologue): Likewise.
9764         * hppa-tdep.c (hppa_skip_prologue): Likewise.
9765         * i386-tdep.c (i386_skip_prologue): Likewise.
9766         * ia64-tdep.c (ia64_skip_prologue): Likewise.
9767         * iq2000-tdep.c (iq2000_skip_prologue): Likewise.
9768         * m32r-tdep.c (m32r_skip_prologue): Likewise.
9769         * m68hc11-tdep.c (m68hc11_skip_prologue): Likewise.
9770         * m68k-tdep.c (m68k_skip_prologue): Likewise.
9771         * m88k-tdep.c (m88k_skip_prologue): Likewise.
9772         * mep-tdep.c (mep_skip_prologue): Likewise.
9773         * mips-tdep.c (mips_skip_prologue): Likewise.
9774         * mn10300-tdep.c (mn10300_skip_prologue): Likewise.
9775         * mt-tdep.c (mt_skip_prologue): Likewise.
9776         * rs6000-tdep.c (rs6000_skip_prologue): Likewise.
9777         * score-tdep.c (score_skip_prologue): Likewise.
9778         * sh64-tdep.c (sh64_skip_prologue): Likewise.
9779         * sh-tdep.c (sh_skip_prologue): Likewise.
9780         * sparc64-tdep.c (sparc64_skip_prologue): Likewise.
9781         * sparc-tdep.c (sparc32_skip_prologue): Likewise.
9782         * spu-tdep.c (spu_skip_prologue): Likewise.
9783         * v850-tdep.c (v850_skip_prologue): Likewise.
9784         * vax-tdep.c (vax_skip_prologue): Likewise.
9785         * xstormy16-tdep.c (xstormy16_skip_prologue): Likewise.
9786         * xtensa-tdep.c (xtensa_skip_prologue): Likewise.
9787
9788         * arm-tdep.c (arm_skip_prologue): Add gdbarch as parameter. Replace
9789         current_gdbarch by gdbarch.
9790         * m32c-tdep.c (m32c_skip_prologue): Likewise.
9791         * s390-tdep.c (s390_skip_prologue): Likewise.
9792
9793 2008-01-10  Doug Evans  <dje@google.com>
9794
9795         * defs.h (struct continuation_arg): Fix typo in comment.
9796         * target.c (target_translate_tls_address): Fix comment spelling error.
9797
9798 2008-01-09  Thiago Jung Bauermann  <bauerman@br.ibm.com>
9799
9800         * doublest.h (DOUBLEST_PRINT_FORMAT): Remove % from string.
9801         (DOUBLEST_SCAN_FORMAT): Likewise.
9802         * dfp.c (decimal_from_floating): Use DOUBLEST_PRINT_FORMAT.
9803         * ada-lex.l (processReal): Prepend "%" to use of DOUBLEST_SCAN_FORMAT.
9804         * c-exp.y (parse_number): Likewise.
9805         * jv-exp.y (parse_number): Likewise.
9806         * objc-exp.y (parse_number): Likewise.
9807         * p-exp.y (parse_number): Likewise.
9808
9809 2008-01-09  Joel Brobecker  <brobecker@adacore.com>
9810
9811         * gdbtypes.c (create_array_type): Add handling of null Ada arrays.
9812         (check_typedef): Likewise.
9813
9814 2008-01-09  Luis Machado  <luisgpm@br.ibm.com>
9815
9816         * printcmd.c (printf_command): Add seen_big_h, seen_big_d and
9817         seen_double_big_d, treat the new H, D, and DD modifiers as length
9818         modifiers.
9819
9820 2008-01-08  Joel Brobecker  <brobecker@adacore.com>
9821
9822         * dwarf2read.c (read_enumeration_type): Add comment.
9823
9824 2008-01-08  Thiago Jung Bauermann  <bauerman@br.ibm.com>
9825
9826         * config.in: Regenerate.
9827
9828 2008-01-08  Joel Brobecker  <brobecker@adacore.com>
9829
9830         * ada-lang.c (ada_convert_actual): Renames convert_actual.
9831         Make non-static.
9832         (ada_convert_actuals): Delete.
9833         * ada-lang.h (ada_convert_actual): Add declaration.
9834         (ada_convert_actuals): Remove declaration.
9835         * infcall.c: #include "ada-lang.h".
9836         (value_arg_coerce): Add new parameter sp.  Update function
9837         documetnation.  Add handling of Ada function call parameters.
9838         * Makefile.in (infcall.o): Update dependencies.
9839
9840 2008-01-08  Paul Hilfinger  <hilfinger@adacore.com>
9841
9842         * ada-lang.c (ensure_lval): Fix value lval kind.
9843         (convert_actual): Add handling for arguments passed by reference.
9844
9845 2008-01-08  Doug Evans  <dje@google.com>
9846
9847         * dbxread.c (read_dbx_symtab): Fix indentation.
9848
9849 2008-01-07  Thiago Jung Bauermann  <bauerman@br.ibm.com>
9850
9851         * Makefile.in (dfp.o): Depend on expression.h, gdbtypes.h and value.h.
9852         (valarith.o): Depend on dfp.h.
9853         (valops.o): Likewise.
9854         * dfp.c: Include expression.h, gdbtypes.h, value.h and dfp.h.
9855         (set_decnumber_context): New function.
9856         (decimal_check_errors): Likewise.
9857         (decimal_from_number): Likewise.
9858         (decimal_to_number): Likewise.
9859         (decimal_from_string): Use set_decnumber_context and
9860         decimal_check_errors.
9861         (decimal_from_integral): New function.
9862         (decimal_from_floating): Likewise.
9863         (decimal_to_double): Likewise.
9864         (promote_decimal): Likewise.
9865         (decimal_binop): Likewise.
9866         (decimal_is_zero): Likewise.
9867         (decimal_compare): Likewise.
9868         (decimal_convert): Likewise.
9869         * dfp.h (decimal_from_integral): New prototype.
9870         (decimal_from_floating): Likewise.
9871         (decimal_to_double): Likewise.
9872         (decimal_binop): Likewise.
9873         (decimal_is_zero): Likewise.
9874         (decimal_compare): Likewise.
9875         (decimal_convert): Likewise.
9876         * eval.c (evaluate_subexp_standard): Remove expect_type argument from
9877         call to value_from_decfloat.
9878         * valarith.c: Include dfp.h.
9879         (value_args_as_decimal): New function.
9880         (value_binop): Add if block to handle TYPE_CODE_DECFLOAT values.
9881         (value_logical_not): Likewise.
9882         (value_equal): Likewise.
9883         (value_less): Likewise.
9884         (value_pos): Likewise.
9885         (value_neg): Formatting fix.
9886         * valops.c: Include dfp.h.
9887         (value_cast): Add if block to handle TYPE_CODE_DECFLOAT values.
9888         * value.c (unpack_long): Add case to handle TYPE_CODE_DECFLOAT.
9889         (unpack_double): Add if block to handle TYPE_CODE_DECFLOAT.
9890         (value_from_decfloat): Remove expect_type argument.
9891         * value.h (value_from_decfloat): Update prototype.
9892
9893 2008-01-07  Vladimir Prus  <vladimir@codesourcery.com>
9894
9895         Ignore change in name of dynamic linker during
9896         execution on Solaris.  This also unbreaks pending breakpoints.
9897
9898         * solist.h (struct target_so_ops): New field same.
9899         * solib-svr4.c (svr4_same): New.
9900         (_initialize_svr4_solib): Register svr4_same.
9901         * solib.c (update_solib_list): Use ops->same, if available.
9902
9903 2008-01-06  Christopher Faylor  <me+cygwin@cgf.cx>
9904
9905         * win32-nat.c (win32_make_so): Use cygwin-style path to avoid warnings
9906         when using MS-DOS paths.
9907
9908 2008-01-05  Pedro Alves  <pedro@codesourcery.com>
9909
9910         * NEWS: Mention --pid and --core command line behaviour changes.
9911
9912 2008-01-05  Pedro Alves  <pedro@codesourcery.com>
9913
9914         * main.c (captured_main): Remove 'count' varible and the
9915         ALIGN_STACK_ON_ENTRY block that used it.  Error out if --core and
9916         --pid options were issued simultaneously.  If an explicit pid
9917         option was passed, don't fallback to core file.  Detect extra
9918         arguments better in the presence of explicit pid or core
9919         arguments.
9920
9921 2008-01-05  Joel Brobecker  <brobecker@adacore.com>
9922
9923         * ada-lang.c (ada_which_variant_applies): Correctly compute
9924         the value of the discriminant when the variant record is packed.
9925
9926 2008-01-04  Joel Brobecker  <brobecker@adacore.com>
9927
9928         * ada-lang.c (is_name_suffix): Handle middle-name numeric suffixes
9929         that are used to differentiate homonyms.
9930
9931 2008-01-04  Jerome Guitton  <guitton@adacore.com>
9932
9933         * ada-lang.c (decode_packed_array_type): Avoid a seg fault
9934         when the type is an anonymous pointer type.
9935         (ada_check_typedef): Avoid a seg fault when the type is null.
9936         * ada-typeprint.c (print_array_type): Add support for pointer
9937         to packed arrays.
9938
9939 2008-01-04  Paul N. Hilfinger  <hilfinger@adacore.com>
9940
9941         * ada-exp.y: Allow '{type} ADDRESS' notation on left of assignment.
9942
9943 2008-01-04  Joel Brobecker  <brobecker@adacore.com>
9944
9945         * ada-lang.c (ada_evaluate_subexp): Evaluate tagged types in
9946         EVAL_NORMAL mode when noside is EVAL_AVOID_SIDE_EFFECTS.
9947
9948 2008-01-04  Joel Brobecker  <brobecker@adacore.com>
9949
9950         * ada-exp.y (chop_separator): New function.
9951         (write_selectors): Rewrite to re-use chop_separator.
9952         (ada_nget_field_index, get_symbol_field_type): New functions.
9953         (write_var_or_type): Add support for "ptype TYPENAME.FIELD"
9954         expressions.
9955
9956 2008-01-03  Thiago Jung Bauermann  <bauerman@br.ibm.com>
9957
9958         * symtab.c (find_pc_sect_line): Use SYMBOL_VALUE_ADDRESS instead
9959         of SYMBOL_VALUE when working with function symbols.
9960
9961 2008-01-03  Joel Brobecker  <brobecker@adacore.com>
9962
9963         * ada-lang.c (resolve_subexp): Add handling of OP_REGISTER
9964         expressions.  These expressions do not need to be rewriten.
9965
9966 2008-01-03  Joel Brobecker  <brobecker@adacore.com>
9967
9968         * dwarf2read.c (read_enumeration_type): Flag type as stub if
9969         the given die is a declaration.
9970
9971 2008-01-03  Joel Brobecker  <brobecker@adacore.com>
9972
9973         * ada-lang.c (ada_array_bound_from_type): Make non-static.
9974         Handle properly the case when the index type is an enumerated type.
9975         Do not return the subtype of the bounds type, just return the
9976         bounds type directly - this is not needed and is more consistent
9977         with what we do for arrays when no XA parallel type exists.
9978
9979 2008-01-03  Joel Brobecker  <brobecker@adacore.com>
9980
9981         * ada-lang.c (static_unwrap_type): Add forward declaration.
9982         (template_to_static_fixed_type): Fields of dynamic types sometimes
9983         also need to be unwrapped. Take this into account.
9984         (ada_to_fixed_type_1): Renamed from ada_to_fixed_type.
9985         (ada_to_fixed_type): New wrapper around ada_to_fixed_type_1.
9986         * ada-typeprint.c (ada_print_type): Get the typename from
9987         the original type, not the base type.
9988
9989 2008-01-03  Jerome Guitton  <guitton@adacore.com>
9990
9991         * ada-lang.c (ada_value_struct_elt, to_fixed_array_type)
9992         (to_fixed_array_type, ada_to_fixed_value_create, unwrap_value):
9993         Update calls to ada_to_fixed_type.
9994         (ada_template_to_fixed_record_type_1): Ditto, but without looking
9995         for the tag.
9996         (ada_to_fixed_type): Add check_tag parameter; do not look for
9997         tag if null.  When looking for a tag, use a fixed record type.
9998         * ada-lang.h (ada_to_fixed_type): Add check_tag parameter.
9999         * ada-valprint.c (printable_val_type, ada_value_print): Update
10000         calls to ada_to_fixed_type.
10001
10002 2008-01-03  Luis Machado  <luisgpm@br.ibm.com>
10003
10004         * doublest.c (convert_floatformat_to_doublest): Call
10005         floatformat_to_doublest instead of floatformat_to_double and use
10006         DOUBLEST variables.
10007         (convert_doublest_to_floatformat): Call floatformat_from_doublest
10008         instead of floatformat_from_double and use DOUBLEST variables.
10009
10010 2008-01-03  Nick Hudson  <nick.hudson@dsl.pipex.com>
10011
10012         * MAINTAINERS (Write After Approval): Add self.
10013
10014 2008-01-03  Joel Brobecker  <brobecker@adacore.com>
10015
10016         * symfile.c (set_initial_language): Make non-static.
10017         * symfile.h (set_initial_language): Add declaration.
10018         * language.c: #include "symfile.h".
10019         (set_language): Call set_initial_language if the frame language
10020         could not be determined.
10021
10022 2008-01-03  Paul N. Hilfinger  <hilfinger@adacore.com>
10023
10024         * eval.c (evaluate_subexp_for_address): Provide frame address to
10025         locate_var_value only if it will be needed.
10026
10027 2008-01-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
10028
10029         * linux-nat.c (linux_child_follow_fork): Call also CHECK_FOR_THREAD_DB.
10030
10031 2008-01-02  Joel Brobecker  <brobecker@adacore.com>
10032
10033         * ada-lang.c (ada_evaluate_subexp): Modify the value returned
10034         when noside is EVAL_AVOID_SIDE_EFFECTS to be an lval_memory.
10035         This is needed to make sure that any other treatment applied
10036         to the resulting value does not fail for spurious reason,
10037         such as trying to take the address of this value.
10038
10039 2008-01-02  Joel Brobecker  <brobecker@adacore.com>
10040
10041         * ada-lang.c (ada_value_equal): Dereference reference types when
10042         comparing arrays.
10043
10044 2008-01-01  Daniel Jacobowitz  <dan@codesourcery.com>
10045
10046         Updated copyright notices for most files.
10047
10048 2008-01-01  Christopher Faylor  <me+gdb@cgf.cx>
10049
10050         * win32-nat.c (psapi_module_handle): Remove static.
10051         (get_module_name): Rename from psapi_get_dll_name.  Revamp slightly to
10052         return first module found if base_address is zero.  Don't initialize
10053         psapi function pointers here.  Convert to cygwin paths when
10054         appropriate.
10055         (win32_pid_to_exec_file): Use Cygwin's /proc interface to determine
10056         executable name.  Use get_module_name when that fails or when
10057         !__CYGWIN__.
10058         (_initialize_psapi): New function.  Initialize psapi stuff before it is
10059         needed or issue a warning if it is not found.  Move psapi_module_handle
10060         here.
10061
10062 2008-01-01  Joel Brobecker  <brobecker@adacore.com>
10063
10064         * ada-lang.c (ada_remove_trailing_digits): New function.
10065         (ada_remove_po_subprogram_suffix): New function.
10066         (ada_decode): Improve. Move the description of the algorithm
10067         directly inside the code, instead of in the function global
10068         description.
10069
10070 2008-01-01  Joel Brobecker  <brobecker@adacore.com>
10071
10072         * ada-valprint.c (ada_val_print_1) [TYPE_CODE_REF]: Ignore deref_ref
10073         and always print the dereferenced value.
10074
10075 2008-01-01  Joel Brobecker  <brobecker@adacore.com>
10076
10077         * ada-lang.c (ada_evaluate_subexp, case BINOP_SUB): Add handling
10078         of the case where the first argument is a reference.
10079         (ada_evaluate_subexp, case BINOP_ADD): Likewise.
10080
10081 2008-01-01  Joel Brobecker  <brobecker@adacore.com>
10082
10083         Implement support for Ada interface types.
10084
10085         * ada-lang.c (ada_is_dispatch_table_ptr_type): New function.
10086         (ada_is_ignored_field): Ignore fields that are a dispatch table
10087         of a tagged type.
10088
10089 2008-01-01  Joel Brobecker  <brobecker@adacore.com>
10090
10091         * top.c (print_gdb_version): Update copyright year.
10092
10093 2008-01-01  Joel Brobecker  <brobecker@adacore.com>
10094
10095         * ChangeLog-2007: New ChangeLog rotation.
10096         * ChangeLog: Reset for 2008.
10097         * config/djgpp/fnchange.lst: Add entries for ChangeLog-2006 and
10098         ChangeLog-2007.
10099
10100 For older changes see ChangeLog-2007.
10101 \f
10102 Local Variables:
10103 mode: change-log
10104 left-margin: 8
10105 fill-column: 74
10106 version-control: never
10107 coding: utf-8
10108 End: