standard Tcl configury bits.
Remove all Tcl, Tk, Itcl, Itk, etc definitions.
* configure.ac: Don't check if ../itcl exists when building
gdbtk. It could be installed.
Rewrite gdbtk configury to allow for using system-supplied
Tcl and Tk. Gdbtk no longer requires build-time access to
itcl and itk.
* Makefile.in: Remove everything related to itcl and itk.
Rewrite the Tcl bits for gdbtk to correspond to rewrite of
configure.ac.
Remove v850ice.o build rule.
(ALL_TCL_CFLAGS): New convenience defintion. Change all
gdbtk sources to use it.
* configure: Regenerate.
* thread.c (enum thread_state): New.
(thread_state main_thread_running): Delete, in favor of...
(thread_state main_thread_state): ... this. Update throughout.
(clear_thread_inferior_resources): New, split from free_thread.
(free_thread): Call clear_thread_inferior_resources.
(init_thread_list): Set main thread to stopped state.
(add_thread_silent): Take care of PTID reuses.
(delete_thread): If deleting inferior_ptid or a thread with
refcount > 0, mark it as exited, but still keep it in the list.
Only notify of thread exits, if we haven't done so yet.
(iterate_over_threads): Make it safe to delete threads while
iterating over them.
(do_captured_list_thread_ids): Don't account for exited threads.
(thread_alive): Check for the THREAD_EXITED state, and don't set
ptid to -1 on exited threads.
(set_running): Update to account for extra possible states.
(is_thread_state): New.
(is_stopped, is_exited): New.
(is_running): Implement in terms of is_thread_state.
(any_running): Update.
(print_thread_info): Update. Account for exited threads. Don't
warn about missed frame restoring here, its done in the cleanup.
(switch_to_thread): Don't read from a thread that has gone.
(restore_current_thread): In non-stop mode, do a full context
switch.
(restore_selected_frame): Add a frame_level argument. Rewrite.
(struct current_thread_cleanup): Add selected_frame_level and
was_stopped members.
(do_restore_current_thread_cleanup): Check if thread was stopped
and still is, and if the target has registers, stack and memory
before restoring the selected frame. Don't delete the cleanup
argument here.
(restore_current_thread_cleanup_dtor): New.
(make_cleanup_restore_current_thread): Remove all arguments.
Rewrite.
(thread_apply_all_command): Update. Prune threads.
(thread_apply_command): Update.
(thread_command): Account for currently selected exited thread.
(do_captured_thread_select): Check for a running thread. Prune
threads.
(_initialize_thread): Make "info threads", "thread", "thread
apply", and "thread apply all" appliable without a selected thread.
* gdbthread.h (struct thread_info): Replace running_ by state_.
Add refcount.
(is_exited, is_stopped): Declare.
(make_cleanup_restore_current_thread): Remove all arguments.
* infrun.c: Include "event-top.h".
(fetch_inferior_event): In non-stop mode, restore selected thread
and frame after handling the event and running breakpoint
commands. Display GDB prompt if needed.
(normal_stop): In non-stop mode, don't print thread switching
notice.
* cli/cli-decode.c (set_cmd_no_selected_thread_ok)
(get_cmd_no_selected_thread_ok): New.
* cli/cli-decode.h (CMD_NO_SELECTED_THREAD_OK): New.
(set_cmd_no_selected_thread_ok, get_cmd_no_selected_thread_ok):
Declare.
* cli/cli-cmds.c: Set "pwd", "help", "info", "show" as
no-selected-thread ok.
* top.c (execute_command): Check for non no-selected-thread-ok
commands.
* linux-nat.c (struct saved_ptids, threads_to_delete)
(record_dead_thread, prune_lwps): Delete.
(exit_lwp): Unconditionally delete thread.
(linux_nat_resume): Remove prune_lwps call.
* infcmd.c (proceed_thread_callback): Check if !is_stopped instead
of is_running. Adjust to make_cleanup_restore_current_thread
interface change.
* mi/mi-main.c (mi_cmd_execute): Only allow a few commands if the
selected thread has exited.
* inf-loop.c (inferior_event_handler): Don't display the prompt
here.
* varobj.c (c_value_of_root): Update.
* defs.h (make_cleanup_dtor): Declare.
* utils.c (make_cleanup_dtor): New.
* Makefile.in (infrun.o): Depend on $(event_top_h).
* infrun.c (resume): In non-stop mode, always resume just one
thread.
(proceed): Don't call prepare_to_proceed in non-stop mode.
(fetch_inferior_event): In non-stop mode, switch context before
handling the event.
(error_is_running, ensure_not_running): New.
(handle_inferior_event): In non-stop mode: Mark only the event
thread as stopped. Require that the target module manages adding
threads to the thread list. Assert that there isn't a
deferred_step_ptid set. Don't switch to infwait_thread_hop_state.
(normal_stop): Only mark not-running if inferior hasn't exited.
In non-stop mode, only mark the event thread.
* thread.c:Include "cli/cli-decode.h".
(print_thread_info): Don't read from a running thread.
Output "(running)" if thread is running.
(switch_to_thread): Don't read stop_pc if thread is executing.
(do_restore_current_thread_cleanup): Don't write to a running
thread.
(thread_apply_all_command): Don't read from a running thread. In
non-stop mode, do a full context-switch instead of just switching
threads.
(thread_apply_command): In non-stop mode, do a full context-switch
instead of just switching threads.
(do_captured_thread_select): Likewise. Inform user if selected
thread is running.
(_initialize_thread): Mark "info threads" and "thread" and
async_ok.
* inf-loop.c (inferior_event_handler): In non-stop mode, don't
unregister the target from the event loop.
* infcmd.c (continue_command, step_1, jump_command)
(signal_command): Ensure the selected thread isn't running.
(interrupt_target_command): In non-stop mode, interrupt only the
selected thread.
* inferior.h (error_is_running, ensure_not_running): Declare.
* target.h (struct target_ops): Add ptid argument to the to_stop
member.
(target_stop): Add ptid_t argument.
* target.c (update_current_target): Add ptid argument to to_stop's
type.
(debug_to_stop): Add ptid_t argument.
(debug_to_rcmd): Set to_stop_ptid.
* remote.c (remote_stop): Add ptid_t argument.
(async_remote_interrupt): Add inferior_ptid to target_stop.
* inf-ptrace.c (inf_ptrace_stop): Add ptid argument.
* Makefile.in (thread.o): Depend on $(cli_decode_h).
* gdbthread.h: Remove unneeded forward declarations.
Include "inferior.h".
(struct thread_info): Add continuations,
intermediate_continuations, proceed_to_finish, step_over_calls,
stop_step, step_multi and stop_signal members.
(save_infrun_state): Add continuations,
intermediate_continuations, proceed_to_finish, step_over_calls,
stop_step, step_multi, stop_signal and stop_bpstat parameters.
(load_infrun_state): Add continuations,
intermediate_continuations, proceed_to_finish, step_over_calls,
stop_step, step_multi, stop_signal and stop_bpstat parameters.
* thread.c (load_infrun_state): In non-stop mode, load
continuations, intermediate_continuations, proceed_to_finish,
step_over_calls, stop_step, step_multi and stop_signal.
(save_infrun_state): Store continuations,
intermediate_continuations, proceed_to_finish, step_over_calls,
stop_step, step_multi, stop_signal and stop_bpstat.
(save_infrun_state): Store continuations,
intermediate_continuations, proceed_to_finish, step_over_calls,
stop_step, step_multi, stop_signal and stop_bpstat.
(free_thread): Clear The thread's stop_bpstat.
* inferior.h (context_switch_to): Declare.
* infrun.c (ecss): New global.
(context_switch): Context switch continuations,
intermediate_continuations, proceed_to_finish, step_over_calls,
stop_step, step_multi, stop_signal and stop_bpstat.
(wait_for_inferior): Use global ecss.
(async_ecss, async_ecs): Delete.
(fetch_inferior_event): Use global ecss.
(context_switch_to): New.
* top.c (execute_command): In non-stop, only check if the current
thread is running, in all-stop, check if there's any thread
running.
* breakpoint.c (bpstat_remove_breakpoint): New.
(bpstat_remove_breakpoint_callback): New.
(delete_breakpoint): Clear the stop_bpstats of all threads.
* mi/mi-main.c (mi_cmd_execute): In non-stop, only check if the
current thread is running, in all-stop, check if there's any
thread running.
* Makefile.in (gdbthread_h): Depend on $(inferior_h).
* inferior.h (target_executing): Delete.
* gdbthread.h (struct thread_info): Add executing_ field.
(set_executing, is_executing): New.
* thread.c (main_thread_executing): New.
(init_thread_list): Clear it and also main_thread_running.
(is_running): Return false if target has no execution.
(any_running, is_executing, set_executing): New.
* top.c: Include "gdbthread.h".
(target_executing): Delete.
(execute_command): Replace target_executing check by any_running.
* event-top.c: Include "gdbthread.h".
(display_gdb_prompt, command_handler): Replace target_executing by
is_running.
* inf-loop.c: Include "gdbthread.h". Don't mark as not executing
here. Replace target_executing by is_running.
* infrun.c (handle_inferior_event): Mark all threads as
not-executing.
* linux-nat.c (linux_nat_resume): Don't mark thread as executing
here.
* stack.c (get_selected_block): Return null if inferior is
executing.
* target.c (target_resume): Mark resumed ptid as executing.
* breakpoint.c (until_break_command): Replace target_executing
check by is_executing.
* remote.c (remote_async_resume): Don't mark inferior as executing
here.
* mi/mi-interp.c (mi_cmd_interpreter_exec): Replace target_executing
by any_running.
* mi/mi-main.c (mi_cmd_exec_interrupt, mi_cmd_execute)
(mi_execute_async_cli_command): Replace target_executing by
is_running.
* frame.c (get_current_frame): Error out if the current thread is
executing.
(has_stack_frames): New.
(get_selected_frame, deprecated_safe_get_selected_frame): Check
has_stack_frames.
* Makefile.in (event-top.o, frame.o, inf-loop.o, top.o): Depend on
$(gdbthread_h).
(remote_sim_ptid): New global.
(gdbsim_create_inferior): Silently add the main task to GDB's
thread list.
(gdbsim_close, gdbsim_mourn_inferior): Silently delete the main
task from GDB's thread list.
(gdbsim_resume): Adjust to use remote_sim_ptid.
(gdbsim_thread_alive, gdbsim_pid_to_str): New.
(init_gdbsim_ops): Register gdbsim_thread_alive and
gdbsim_pid_to_str.
(_initialize_remote_sim): Initialize remote_sim_ptid.
* Makefile.in (remote-sim.o): Depend on $(gdbthread_h).
* monitor.c (monitor_open): Include "gdbthread.h". Clear thread
list here.
* remote.c (record_currthread): Upgrade the main thread and its
entry in the thread list if this is the first time we hear about
threads.
(remote_thread_alive): Consider magic_null_ptid or a ptid without
a tid member always alive.
(remote_find_new_threads): Don't update the main thread here.
(remote_start_remote): Clear thread list here. Always add the
main thread.
(extended_remote_attach_1): Add the main thread here.
(extended_remote_mourn_1): Re-add the main thread here.
(extended_remote_create_inferior_1): Add a main thread.
* Makefile.in (monitor.o): Depend on $(gdbthread_h).
(gdb_stdint_h, gdb_stdint.h, stamp-int): Delete. Remove
all dependencies on $(gdb_stdint_h).
(distclean): Do not delete gdb_stdint.h.
* acinclude.m4: Do not use stdint.m4.
* configure.ac: Set GNULIB_STDINT_H. Remove tests for stdint.h,
uintptr_t, and gdb_stdint.h.
* defs.h: Include <stdint.h>.
* gdb_thread_db.h: Assume stdint.h is already included.
* breakpoint.c, findcmd.c, hppa-tdep.c, inf-ptrace.c, proc-service.c,
rs6000-nat.c, spu-linux-nat.c, target.c, win32-nat.c: Do not
include gdb_stdint.h.
* configure, config.in: Regenerate.
* dwarf2expr.c: New include "gdb_assert.h".
(new_dwarf_expr_context): Initialize MAX_RECURSION_DEPTH.
(dwarf_expr_eval): Sanity check the RECURSION_DEPTH count.
(execute_stack_op): Error out on too large RECURSION_DEPTH.
Increase/decrease RECURSION_DEPTH around the function.
core_regset_sections.
* gdbarch.c: Refreshed.
* gdbarch.h: Refreshed.
* regset.h (core_regset_section): Declared.
* linux-nat.c (linux_nat_do_thread_registers): Added
support for the new gdbarch struct core_regset_sections.
* utils.c (host_address_to_string): New function.
* defs.h (host_address_to_string): New prototype.
* i386-linux-tdep.c (i386_regset_rections): New register
sections list for i386.
(i386_linux_init_abi): Initialized new gdbarch struct
core_regset_sections.
* Makefile.in: Updated to reflect dependency changes.
* ppc-linux-tdep.c (ppc_regset_sections): Register
sections list for ppc.
(ppc_linux_init_abi): Initialized new gdbarch struct
core_regset_sections
(struct alpha_mdebug_unwind_cache): Change type of SAVED_REGS to
struct trad_frame_saved_reg *.
(alpha_mdebug_frame_unwind_cache): Allocate SAVED_REGS using
trad_frame_alloc_saved_regs. Update accesses. Record previous
value of SP as being vfp.
(alpha_mdebug_frame_prev_register): Use trad_frame_get_prev_register.
* Makefile.in (alpha-mdebug-tdep.o): Update dependencies.
* Makefile.in: Update dependencies.
* dwarf2read.c: Include "addrmap.h"
(struct dwarf2_cu): New fields RANGES_OFFSET and HAS_RANGES_OFFSET.
(dwarf2_ranges_read): New prototype.
(dwarf2_build_psymtabs_hard): Initialize and prepare PSYMTABS_ADDRMAP.
Add discontiguous range to PSYMTABS_ADDRMAP by DWARF2_RANGES_READ on
HAS_RANGES_OFFSET, otherwise add there the contiguous range.
(dwarf2_ranges_read): New parameter RANGES_PST, update the function
comment for it. Add the found ranges to RANGES_PST. New variable
BASEADDR, initialize it the common way.
(dwarf2_get_pc_bounds): Update the caller for the new parameter.
(read_partial_die): `DW_AT_ranges' now only sets RANGES_OFFSET and
HAS_RANGES_OFFSET for the later processing.
* objfiles.h (struct objfile): New field PSYMTABS_ADDRMAP.
* symtab.c: Include "addrmap.h"
(find_pc_sect_psymtab): Support reading the field PSYMTABS_ADDRMAP.
Move the psymtab locator into ...
(find_pc_sect_psymtab_closer): ... a new function.
gdb/testsuite/
* gdb.dwarf2/dw2-ranges.S: Merge the secondary section with `.fini'.
* gdb.dwarf2/dw2-ranges.exp: Compile also `dw2-ranges2.S' and
`dw2-ranges3.S' and test also their MAIN2, FUNC2 and MAIN3 symbols.
* gdb.dwarf2/dw2-ranges2.S, gdb.dwarf2/dw2-ranges3.S: New files.
* Makefile.in (ppc_linux_tdep_h): New macro.
(powerpc_32l_c, powerpc_altivec32_c, powerpc_altivec32l_c): Likewise.
(powerpc_64l_c, powerpc_altivec64_c, powerpc_altivec64l_c): Likewise.
(powerpc_e500l_c): Likewise.
(ppc-linux-nat.o): Update dependencies.
(ppc-linux-tdep.o): Update dependencies.
(rs6000-tdep.o): Update dependencies.
* ppc-tdep.h (ppc_linux_memory_remove_breakpoint): Remove.
(ppc_linux_svr4_fetch_link_map_offsets): Remove.
(ppc_linux_gregset, ppc_linux_fpregset): Move to ppc-linux-tdep.h
(ppc_supply_reg, ppc_collect_reg): Add prototypes.
(tdesc_powerpc_e500): Remove.
* rs6000.c: Include "features/rs6000/powerpc-altivec32.c"
and "features/rs6000/powerpc-altivec64.c".
(ppc_supply_reg, ppc_collect_reg): Make global.
(variants): Use tdesc_powerpc_32 for "powerpc" and
tdesc_powerpc_altivec64 for "powerpc64".
(_initialize_rs6000_tdep): Initialize AltiVec descriptions.
* ppc-linux-tdep.h: New file.
* ppc-linux-tdep.c: Include "ppc-linux-tdep.c".
Include "features/rs6000/powerpc-32l.c".
Include "features/rs6000/powerpc-altivec32l.c".
Include "features/rs6000/powerpc-64l.c".
Include "features/rs6000/powerpc-altivec64l.c".
Include "features/rs6000/powerpc-e500l.c".
(ppc_linux_supply_gregset): New function.
(ppc_linux_collect_gregset): Handle orig_r3 and trap registers.
(ppc32_linux_gregset): Use ppc_linux_supply_gregset.
(ppc64_linux_gregset): Likewise.
(ppc_linux_sigtramp_cache): Handle orig_r3 and trap registers.
(ppc_linux_trap_reg_p): New function.
(ppc_linux_write_pc): New function.
(ppc_linux_core_read_description): New function.
(ppc_linux_init_abi): Install ppc_linux_write_pc and
ppc_linux_core_read_description. Install orig_r3 and trap
registers if present in the target description.
(_initialize_ppc_linux_tdep): Initialize Linux target descriptions.
* ppc-linux-nat.c: Include "ppc-linux-tdep.h".
(PT_ORIG_R3, PT_TRAP): Define if necessary.
(ppc_register_u_addr): Handle orig_r3 and trap registers.
(fetch_ppc_registers): Likewise.
(store_ppc_registers): Likewise.
(store_register): Likewise.
(ppc_linux_read_description): Check whether AltiVec is supported.
Check whether inferior is 32-bit or 64-bit. Return the appropriate
Linux target description.
* features/Makefile (WHICH): Use rs6000/powerpc-32l and
rs6000/powerpc-altivec32l instead of rs6000/powerpc-32.
Use rs6000/powerpc-64l and rs6000/powerpc-altivec64l instead
of rs6000/powerpc-64. Use rs6000/powerpc-e500l instead of
rs6000/powerpc-e500. Update -expedite variables accordingly.
* features/rs6000/power-spe.xml: Use regnum 73 for "acc".
* features/rs6000/powerpc-32.xml: Do not include power-altivec.xml.
* features/rs6000/powerpc-64.xml: Do not include power-altivec.xml.
* features/rs6000/powerpc-e500.c: Regenerate.
* features/rs6000/powerpc-32.c: Regenerate.
* features/rs6000/powerpc-64.c: Regenerate.
* features/rs6000/power-linux.xml: New file.
* features/rs6000/power64-linux.xml: New file.
* features/rs6000/powerpc-32l.xml: New file.
* features/rs6000/powerpc-altivec32l.xml: New file.
* features/rs6000/powerpc-64l.xml: New file.
* features/rs6000/powerpc-altivec64l.xml: New file.
* features/rs6000/powerpc-e500l.xml: New file.
* features/rs6000/powerpc-32l.c: New (generated) file.
* features/rs6000/powerpc-altivec32l.c: New (generated) file.
* features/rs6000/powerpc-64l.c: New (generated) file.
* features/rs6000/powerpc-altivec64l.c: New (generated) file.
* features/rs6000/powerpc-e500l.xml: New (generated) file.
* regformats/reg-ppc.dat: Remove.
* regformats/reg-ppc64.dat: Remove.
* regformats/rs6000/powerpc-32.dat: Remove.
* regformats/rs6000/powerpc-64.dat: Remove.
* regformats/rs6000/powerpc-e500.dat: Remove.
* regformats/rs6000/powerpc-32l.dat: New (generated) file.
* regformats/rs6000/powerpc-altivec32l.dat: New (generated) file.
* regformats/rs6000/powerpc-64l.dat: New (generated) file.
* regformats/rs6000/powerpc-altivec64l.dat: New (generated) file.
* regformats/rs6000/powerpc-e500l.dat: New (generated) file.
gdbserver/ChangeLog:
* configure.srv (powerpc*-*-linux*): Set srv_regobj to
powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
powerpc-64l.o, and powerpc-altivec64l.o.
Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
rs6000/power-linux.xml, and rs6000/power64-linux.xml
to srv_xmlfiles.
* Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
(powerpc-32l.o, powerpc-32l.c): ... these new rules.
(powerpc-32.o, powerpc-32.c): Remove, replace by ...
(powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
(powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
(powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
(reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
(powerpc-64l.o, powerpc-64l.c): ... these new rules.
(powerpc-64.o, powerpc-64.c): Remove, replace by ...
(powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
(clean): Update.
* linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
(init_registers_powerpc_32l): ... this new prototype.
(init_registers_powerpc_32): Remove, replace by ...
(init_registers_powerpc_altivec32l): ... this new prototype.
(init_registers_powerpc_e500): Remove, replace by ...
(init_registers_powerpc_e500l): ... this new prototype.
(init_registers_ppc64): Remove, replace by ...
(init_registers_powerpc_64l): ... this new prototype.
(init_registers_powerpc_64): Remove, replace by ...
(init_registers_powerpc_altivec64l): ... this new prototype.
(ppc_num_regs): Set to 73.
(PT_ORIG_R3, PT_TRAP): Define if necessary.
(ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
(ppc_cannot_store_register): Handle orig_r3 and trap.
(ppc_arch_setup): Update init_registers_... calls.
(ppc_fill_gregset): Handle orig_r3 and trap.
* inferiors.c (clear_inferiors): Reset current_inferior.
(minsym_found): Handle minimal symbols pointing to function
descriptors. Use find_function_start_pc.
* minsyms.c (msymbol_objfile): New function.
* parse.c (write_exp_msymbol): Handle minimal symbols pointing
to function descriptors.
* symtab.c (fixup_section): Only use minimal symbol at the same
address to determine section of a symbol.
(find_function_start_pc): New function.
(find_function_start_sal): Use it.
* symtab.h (msymbol_objfile): Add prototype.
(find_function_start_pc): Likewise.
* value.c: Include "objfiles.h".
(value_fn_field): Handle minimal symbols pointing to function
descriptors.
* Makefile.in (linespec.o): Update dependencies.
(value.o): Likewise.
Pedro Alves <pedro@codesourcery.com>
Based on work by Jan Kratochvil <jan.kratochvil@redhat.com> and Jeff
Johnston <jjohnstn@redhat.com>.
* NEWS: Mention attach to stopped process fix.
* infcmd.c (detach_command, disconnect_command): Discard the thread
list.
* infrun.c (handle_inferior_event): Do not ignore non-SIGSTOP while
attaching. Use signal_stop_state.
(signal_stop_state): Check stop_soon.
* linux-nat.c (kill_lwp): Declare earlier.
(pid_is_stopped, linux_nat_post_attach_wait): New.
(lin_lwp_attach_lwp): Use linux_nat_post_attach_wait. Update
comments.
(linux_nat_attach): Use linux_nat_post_attach_wait.
(detach_callback, linux_nat_detach): Improve handling for signalled
processes.
(linux_nat_pid_to_str): Always print out the LWP ID if it differs
from the process ID.
* Makefile.in (infcmd.o): Update.
2008-05-01 Jan Kratochvil <jan.kratochvil@redhat.com>
Daniel Jacobowitz <dan@codesourcery.com>
* gdb.threads/attach-into-signal.c, gdb.threads/attach-into-signal.exp,
gdb.threads/attach-stopped.c, gdb.threads/attach-stopped.exp,
gdb.threads/attachstop-mt.c, gdb.threads/attachstop-mt.exp: New.
* Makefile.in (xtensa-tdep.o): Update dependencies.
* configure.tgt (xtensa*): Update dependencies.
* xtensa-tdep.c (arreg_number): Renamed from areg_number.
Local variable areg renamed to arreg.
(areg_number): New function.
(xtensa_pseudo_register_read, xtensa_pseudo_register_write)
(xtensa_extract_return_value, xtensa_store_return_value): areg_number
replaced by arreg_number.
(xtensa_windowed_frame_cache, struct xtensa_frame_cache): New comments.
(xtensa_alloc_frame_cache): Initialize cache->wd.ws.
(xtensa_scan_prologue): New function.
(xtensa_frame_cache): New local fp_regnum. Handle separately the case,
when ENTRY instraction hasn't been executed yet. Get the frame pointer
value based on prologue analysis. Fix the bugs preventing WS and
AR4-AR7/A11 registers from getting right values for intermediate frames,
whose registers have been already spilled.
(xtensa_frame_prev_register): Fix WS register value. Use are_number
and arreg_number appropriately.
(xtensa_gdbarch_init): Set solib_svr4_fetch_link_map_offsets to
svr4_ilp32_fetch_link_map_offsets.
(set_cmd_async_ok, get_cmd_async_ok): Declare.
* cli/cli-decode.c (set_cmd_async_ok): New function.
(get_cmd_async_ok): New function.
* cli/cli-cmds.c (init_cli_cmds): Mark "pwd", "help", "info", and
"show" as async-ok.
* top.c (execute_command): Use get_cmd_async_ok.
* infcmd.c: Include cli/cli-decode.h.
(_initialize_infcmd): Mark "interrupt" as async-ok.
* Makefile.in (infcmd.o): Depend on cli_decode_h.
2008-04-09 Marc Khouzam <marc.khouzam@ericsson.com>
* mi/mi-cmd-var.c: Include "mi-getopt.h".
(mi_parse_format): New. Factored out from mi_cmd_var_set_format.
(mi_cmd_var_set_format): Use new mi_parse_format.
(mi_cmd_var_evaluate_expression): Support for -f option to specify
format.
* Makefile.in (mi-cmd-var.o): Update dependencies.
* varobj.h (varobj_get_formatted_value): Declare.
* varobj.c (my_value_of_variable): Added format parameter.
(cplus_value_of_variable): Likewise.
(java_value_of_variable): Likewise.
(c_value_of_variable): Likewise. Evaluate expression based
on format parameter.
(struct language_specific): Add format parameter to function member
*value_of_variable.
(varobj_get_formatted_value): New.
(varobj_get_value): Added format parameter to method call.
gdb/doc/ChangeLog
2008-04-09 Marc Khouzam <marc.khouzam@ericsson.com>
* gdb.texinfo (GDB/MI Variable Objects): Add anchor to
-var-set-format. Add -f option to -var-evaluate-expression.
gdb/testsuite/ChangeLog
2008-04-09 Marc Khouzam <marc.khouzam@ericsson.com>
* gdb.mi/mi2-var-display.exp: Added tests for the new -f
option of -var-evaluate-expression.
* gdb.mi/mi2-var-display.exp: Likewise.
* target.h (struct target_ops): Delete to_async_mask_value and add
to_async_mask.
(target_is_async_p, target_async): Formatting.
(target_async_mask_value): Delete.
(target_async_mask): Delete function declaration, and add new
target macro with the same name.
* target.c (update_current_target): Replace to_async_mask_value by
to_async_mask. Default to_async_mask to return_one.
(target_async_mask): Delete.
(find_default_can_async_p, find_default_is_async_p): New.
(init_dummy_target): register find_default_can_async_p and
find_default_is_async_p on the dummy target.
* linux-nat.c: Include inf-loop.h, event-loop.h and event-top.h.
(debug_linux_nat_async): New global.
(show_debug_linux_nat_async): New function.
(linux_nat_async_enabled, linux_nat_async_mask_value)
(linux_nat_event_pipe, linux_nat_num_queued_events)
(linux_nat_async_events_enabled): New globals.
(struct waitpid_result): New struct.
(waitpid_queue): New global.
(queued_waitpid, push_waitpid, drain_queued_events): New.
(my_waitpid): Call queued_waitpid.
(linux_child_follow_fork): Disable async events during the call.
(blocked_mask): Delete.
(sync_sigchld_action, async_sigchld_action): New globals.
(lin_lwp_attach_lwp): In sync mode, don't reblock SIGCHLD. In
async mode, block events during the call.
(linux_nat_create_inferior): New.
(linux_nat_attach): In sync mode, restore the mask states. In
async mode, wake the event loop immediatelly.
(detach_callback): Drain all queued events of the lwp we're
detaching from.
(linux_nat_detach): Block async mode, and drain events of the main
process.
(linux_nat_resume): If in async mode, mask async events during the
call. If short circuiting, force event loop to wake up. If
resuming, set target_executing, and register target events in the
event loop.
(pipe_to_local_event_queue, local_event_queue_to_pipe): New.
(linux_nat_wait): In async mode, block events during the call.
Only enable/disable passing SIGINT to the inferior in sync mode.
Get events from local waitpid queue. If no interesting events was
found, return to events loop. Reregister target events in the
event loop on exit. In sync mode, no need to reblock SIGCHLD.
(linux_nat_kill): Disable events on entry.
(linux_nat_mourn_inferior): In sync mode, don't restore the masks
here. Detach async mode from the event loop if there are no more
forks available, otherwise leave it on.
(sigchld_handler): Assure this is called only in sync mode.
(linux_async_permitted, linux_async_permitted_1): New globals.
(set_maintenance_linux_async_permitted)
(show_maintenance_linux_async_permitted): New functions.
(linux_nat_is_async_p, linux_nat_can_async_p)
(linux_nat_async_mask): New.
(linux_nat_event_pipe_pop, linux_nat_event_pipe_push): New.
(get_pending_events, async_sigchld_handler): New.
(linux_nat_async_events): New.
(async_terminal_is_ours): New global.
(linux_nat_terminal_inferior, linux_nat_terminal_ours): New.
(async_client_callback, async_client_context): New.
(linux_nat_async_file_handler, linux_nat_async)
(linux_nat_disable_async, linux_nat_enable_async): New.
(linux_nat_add_target): Register linux_nat_create_inferior,
linux_nat_can_async_p, linux_nat_is_async_p, linux_nat_async,
linux_nat_async_mask, linux_nat_terminal_inferior and
linux_nat_terminal_ours.
(_initialize_linux_nat): Remove local action variable, and update
code that used it to use sync_sigchld_action. Add new
"lin-lwp-async" debug set/show command. Put the "lin-lwp" debug
set/show command in the maintenance class. Add new "linux-async"
maintenance set/show command. Block SIGCHLD by default. Setup
async_sichld_action, and sync_sigchld_action. Install the default
async mode.
(lin_thread_get_thread_signals): Use a local sigset_t for blocking
the cancel signals.
* linux-thread-db.c (re_check_for_thread_db): New.
(clear_lwpid_callback): Handle TARGET_WAITKIND_IGNORE.
(thread_db_can_async_p, thread_db_is_async_p, thread_db_async)
(thread_db_async_mask): New.
(init_thread_db_ops): Register thread_db_can_async_p,
thread_db_is_async_p, thread_db_async and thread_db_async_mask.
* remote.c (remote_async_mask_value): New.
(remote_return_zero): New.
(init_remote_ops): Register remote_return_zero as callbacks of
to_can_async_p and to_is_async_p.
(remote_can_async_p, remote_is_async_p, remote_async): Update to
use remote_async_mask_value.
(remote_async_mask): New.
(init_remote_async_ops): Remove to_async_mask_value setting and
register remote_async_mask as to_async_mask callback in
remote_async_ops.
* Makefile.in (linux-nat.o): Update.
gdb/doc/
* gdb.texinfo (Debugging Output): Document
"set/show debug lin-lwp-async".
(Maintenance Commands): Document "maint set/show linux-async".
* gdbthread.h (print_thread_info): Declare.
* thread.c (print_thread_info): New, extracted
from info_threads_command and adjusted to
work for CLI and MI.
(info_threads_command): Use print_thread_info.
* Makefile.in: Update dependencies.
* mi/mi-cmds.c (mi_cmds): Specify a handler
for -thread-info.
* mi/mi-cmds.h (mi_cmd_thread_info): Declare.
* mi/mi-main.c (mi_cmd_thread_info): New.
(mi_cmd_list_features): Include 'thread-info'.
* Makefile.in (infcmd.o, inf-loop.o): Update dependencies.
* breakpoint.c (bpstat_do_actions): In async mode,
don't jump to top expecting stop_bpstat to be already
updated.
* event-loop.c (start_event_loop): Call async_enable_stdin
on exception.
* event-top.c (async_enable_stdin): Do nothing if sync_execution
is not set.
(command_handler): Do not setup continuation here.
(command_line_handler_continuation): Move to...
* top.c (command_line_handler_continuation): ... here.
(execute_command): In async mode, register continuation.
Don't check frame's language in running in async mode.
* exceptions.c (throw_exception): Don't do exec_error_cleanups.
* inf-loop.c (complete_execution): Inline into...
(inferior_event_handler): ... here. Clear target_executing before
doing any cleanups. Don't try to show prompt if the target was
resumed.
* infcmd.c (signal_command): Add support for async mode.
(finish_command): Only add continuation if the target was
successfully resumed.
* remote.c (init_async_opts): Register to_get_thread_local_address
handler.
* mi/mi-interp.c (mi_cmd_interpreter_exec): Don't mess
with sync_execution.
* tui/tui-interp.c (tui_command_loop): Call async_enable_stdin
on exception.
* NEWS: Document "set exec-wrapper" and the gdbserver --wrapper
argument. Gather all gdbserver features together.
* fork-child.c (exec_wrapper): New variable.
(fork_inferior): Use it.
(startup_inferior): Skip an extra trap if using "set exec-wrapper".
(unset_exec_wrapper_command, _initialize_fork_child): New.
* gdb.texinfo (Starting): Document "set exec-wrapper".
(Server): Document gdbserver --wrapper.
* server.c (wrapper_argv): New.
(start_inferior): Handle wrapper_argv. If set, expect an extra
trap.
(gdbserver_usage): Document --wrapper.
(main): Parse --wrapper.
Mark Kettenis <kettenis@gnu.org>
* alpha-tdep.c (alpha_heuristic_unwind_cache): Replace saved_regs by
trad_frame_saved_reg.
(trad-frame.h): New include.
(alpha_heuristic_frame_unwind_cache): Use trad_frame_alloc_saved_regs
instead of frame_obstack_zalloc.
(alpha_heuristic_frame_prev_register): Use trad_frame_get_prev_register.
* Makefile.in (alpha-tdep.o): Add dependency to trad_frame_h.
* NEWS (New native configurations): Xtensa GNU/Linux.
(New targets): Xtensa GNU/Linux.
* Makefile.in (ALL_TARGET_OBS): Add xtensa-linux-nat.o and
xtensa-linux-tdep.o
(ALLDEPFILES): Add xtensa-linux-tdep.c and xtensa-linux-nat.c
(xtensa-linux-nat.o, xtensa-linux-tdep.o): New dependencies.
* configure.tgt (xtensa*-*-linux*): New entry.
* xtensa-config.c (xtensa_tdep): New variable.
(xtensa_config_byte_order, xtensa_config_tdep): Removed.
(rmap): Change format based on new macro XTREG.
(XTENSA_CONFIG_INSTANTIATE): Use new macro defined in xtensa-tdep.h.
* xtensa-linux-nat.c: New.
* xtensa-linux-tdep.c: New.
* xtensa-xtregs.c: New.
* xtensa-tdep.h (xtensa_elf_gregset_t): Update.
(XTENSA_ELF_NGREG, XTREG, XTREG_END, XTENSA_GDBARCH_TDEP_INSTANTIATE)
(XCHAL_NUM_CONTEXTS, XCHAL_HAVE_EXCEPTIONS): New macros.
(xtensa_register_t): New field coprocessor.
(XTENSA_REGISTER_FLAGS_PRIVILEGED): Name spelling corrected.
* xtensa-tdep.c (xtensa_config_tdep, xtensa_config_byte_order): Removed.
(xtensa_pseudo_register_read, xtensa_pseudo_register_write):
Update to handle privileged registers.
(xtensa_supply_gregset) Remove exccause and excvaddr registers.
(xtensa_push_dummy_call): Set windowstart register correctly.
(call0_analyze_prologue): Initialize xtensa_default_isa.
(xtensa_derive_tdep): New.
(xtensa_gdbarch_init): Get rid of xtensa_config_byte_order and
xtensa_config_tdep, use XCHAL_HAVE_BE and xtensa_tdep instead.
Call xtensa_derive_tdep().
* config/xtensa/linux.mh: New.
* regformats/reg-xtensa.dat: New.
(ambiguous_names_p): New fn.
(update_breakpoint_locations): When restoring bp enable status, don't
compare function names if any functions have same name.
* Makefile.in (breakpoint.o): Add hashtab.h dependency.
* gdb.cp/mb-inline.exp: New.
* gdb.cp/mb-inline.h: New.
* gdb.cp/mb-inline1.cc: New.
* gdb.cp/mb-inline2.cc: New.
(struct string_vector, new_string_vector, string_vector_append):
Delete.
(char_ptr): New typedef.
(DEF_VEC_P (char_ptr)): New VEC type.
(symbol_completion_add): Update profile to take the new VEC type
instead of the old string_vector structure. Update code accordingly.
(ada_make_symbol_completion_list): Use the new VEC type instead of
the old string_vector structure, and update the code accordingly.
* Makefile.in (ada-lang.o): Add dependency on vec.h.
* NEWS: Mention exec tracing support.
* inf-ttrace.c (inf_ttrace_wait): Return TARGET_WAITKIND_EXECD for
exec events.
* infcmd.c (kill_if_already_running, detach_command)
(disconnect_command): Replace SOLIB_RESTART with no_shared_libraries.
* infrun.c (MAY_FOLLOW_EXEC, may_follow_exec): Delete.
(follow_exec): Do not check may_follow_exec. Do not mourn and push
targets. Apply the sysroot path to the loaded executable. Use
no_shared_libraries.
* linux-nat.c (linux_child_follow_fork): Print fork following
messages if verbose.
(kill_wait_callback): Kill again before waiting a second time.
* symfile.c (symbol_file_clear): Replace SOLIB_RESTART with
no_shared_libraries.
* gdb.base/foll-exec.exp: Update header. Skip on remote targets.
Run on GNU/Linux.
(do_exec_tests): Check for systems which do not support catchpoints.
Do not match START.
* gdb.base/foll-fork.exp: Update header. Skip on remote targets.
Run on GNU/Linux. Enable verbose output.
(check_fork_catchpoints): New.
(explicit_fork_child_follow, catch_fork_child_follow)
(tcatch_fork_parent_follow): Update expected messages.
(do_fork_tests): Use check_fork_catchpoints.
* gdb.base/foll-vfork.exp: Update header. Skip on remote targets.
Run on GNU/Linux. Enable verbose output.
(check_vfork_catchpoints): New.
(vfork_parent_follow_to_bp, tcatch_vfork_then_child_follow): Update
expected messages.
(do_vfork_and_exec_tests): Use check_fork_catchpoints.
* hppabsd-tdep.c (hppabsd_supply_gregset): Move to ...
(hppabsd_gregset): Move to ...
(hppabsd_regset_from_core_section): Rename
hppaobsd_regset_from_core_section and move to ...
(hppabsd_find_global_pointer): Update comment.
(hppabsd_init_abi): Make global. Do not register
hppabsd_regset_from_core_section.
(hppabsd_core_osabi_sniffer): Rename hppaobsd_core_osabi_sniffer and
move to ...
(_initialize_hppabsd_tdep): Move to ...
* hppaobsd-tdep.c: ... here. New file.
* hppnbsd-tdep.c: New file.
* hppnbsd-nat.c: New file.
* Makefile.in (ALL_TARGET_OBS): Add hppanbsd-tdep.o and hppaobsd-tdep.o.
(ALLDEPFILES): Add hppabsd-nat.c and hppabsd-tdep.c.
(hppabsd-nat.o, hppabsd-tdep.o): New dependencies.
(hppabsd-tdep.o, hppaobsd-tdep.o): Update dependencies.
* configure.host (hppa*-*-netbsd*): New entry.
* configure.tgt (hppa*-*-netbsd*): New entry.
(hppa*-*-openbsd*): Update.
* NEWS (New native configuration): Mention NetBSD/hppa.
(New targets): Mention NetBSD/hppa.
(sigtramp_retcode, i386nbsd_sigtramp_offset, i386nbsd_sigtramp_p):
Remove
(i386nbsd_mc_reg_offset): New array.
(i386nbsd_sigtramp_cache_init): New function.
(i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2, i386nbsd_sigtramp_si2)
(i386nbsd_sigtramp_si31, i386nbsd_sigtramp_si4): New signal trampoline
frame descriptions.
(i386nbsd_init_abi): Override ABI sigcontext defaults and register
new signal frame unwinders
* Makefile.in (i386nbsd-tdep.o): Update dependencies.
* tramp-frame.h (struct tramp_frame): Allow for 48 instructions
indicates that addresses should be sign-extended and there are
only 8 hex digits in the address, then do so.
* Makefile.in (utils.o): Depend on $(gdbcore_h).
non-contiguous address ranges.
* addrmap.c, addrmap.h: New files.
* block.h (struct addrmap): New forward declaration.
(struct blockvector): New member, 'map'.
(BLOCKVECTOR_MAP): New accessor macro.
* block.c: #include "addrmap.h"
(blockvector_for_pc_sect): If the blockvector we've found has
an address map, use it instead of searching the blocks.
* buildsym.c: #include "addrmap.h"
(pending_addrmap_obstack, pending_addrmap_interesting): New static
variables.
(really_free_pendings): If we have a pending addrmap, free it too.
(record_block_range): New function.
(make_blockvector): If we have an interesting pending addrmap,
record it in the new blockvector.
(start_symtab, buildsym_init): Assert that there is no pending
addrmap now; we should have cleaned up any addrmaps we'd built
previously.
(end_symtab): If there is a pending addrmap left over that didn't
get included in the blockvector, free it.
* buildsym.h (struct addrmap): New forward declaration.
(record_block_range): New prototype.
* objfiles.c: #include "addrmap.h".
(objfile_relocate): Relocate the blockvector's address map, if
present.
* dwarf2read.c (dwarf2_record_block_ranges): New function.
(read_func_scope, read_lexical_block_scope): Call it.
* Makefile.in (SFILES): Add addrmap.c.
(addrmap_h): New header dependency variable.
(COMMON_OBS): Add addrmap.o.
(addrmap.o): New rule.l
(block.o, objfiles.o, buildsym.o): Depend on $(addrmap_h).
* block.c (blockvector_for_pc, blockvector_for_pc_sect): Return a
pointer to the block, not its index in the blockvector.
(block_for_pc_sect): Use the returned block, instead of looking it
up ourselves.
* block.h (blockvector_for_pc, blockvector_for_pc_sect): Update
declarations.
* breakpoint.c (resolve_sal_pc): Use returned block, instead of
looking it up ourselves.
* stack.c (print_frame_label_vars): Disable function, which
depends on the block's index.
* buildsym.c (finish_block): Return the block we've built.
* buildsym.h (finish_block): Update prototype.
* defs.h (CORE_ADDR_MAX): New constant.
64-bit CORE_ADDR and BFD support, move them to ...
(ALL_64_TARGET_OBS): ... this new variable.
* configure.ac: Check for --enable-64-bit-bfd option. Only add
64-bit targets with --enable-targets=all if BFD supports 64-bit.
* configure: Regenerate.
* i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Do not claim
all elf32-i386 executables, only cygwin core files.
(GDB_XM_FILE, GDB_TM_FILE): Do not define.
(xm_h, tm_h): Likewise.
(DEPRECATED_TM_FILE, XM_FILE): Do not substitute into Makefile.
* configure, config.in: Regenerate.
* Makefile.in (xm_h, tm_h): Remove. Update dependencies.
(TAGS): Do not consider DEPRECATED_TM_FILE or XM_FILE.
(clean, local-maintainer-clean): Do not remove xm.h or tm.h.
* defs.h: Do not include "xm.h" or "tm.h".
* gdbarch.sh (verify_gdbarch): Do not dump GDB_XM_FILE or GDB_TM_FILE.
* gdbarch.c: Regenerate.
* config/score/embed.mt: Remove obsolete comment.
* Makefile.in (breakpoint_h): Update dependency.
* breakpoint.c (clear_command): Do not remove
breakpoints from breakpoint_chain. Collect breakpoints
to delete in a vector.
* breakpoint.h (breakpoint_p): New typedef for pointer to
breakpoint. Register vector of breakpoint_p.
soft float and vector ABIs. Support the generic vector ABI for
AltiVec types.
(do_ppc_sysv_return_value): Likewise. Correct argument types and
casts.
(ppc64_sysv_abi_push_dummy_call): Assert that floating point is
supported.
* ppc-tdep.h (enum powerpc_vector_abi): New.
(struct gdbarch_tdep): Add soft_float and vector_abi.
* rs6000-tdep.c (setpowerpccmdlist, showpowerpccmdlist)
(powerpc_soft_float_global, powerpc_vector_strings)
(powerpc_vector_abi_global, powerpc_vector_abi_string): New.
(rs6000_gdbarch_init): Check for soft-float and vector ABI markings.
(set_powerpc_command, show_powerpc_command, powerpc_set_soft_float)
(powerpc_set_vector_abi): New.
(_initialize_rs6000_tdep): Register "set powerpc" and "show powerpc"
commands.
* Makefile.in (elf_ppc_h): New.
(rs6000-tdep.o): Update.
* gdb.texinfo (PowerPC): Document "set powerpc vector-abi" and "set
powerpc soft-float".
* gdb.arch/altivec-abi.exp: Run multiple times for GCC on GNU/Linux.
Test "set powerpc vector-abi". Skip auto-detection tests for old
toolchains.
Thiago Jung Bauermann <bauerman@br.ibm.com>
* Makefile.in (LIBDECNUMBER_DIR, LIBDECNUMBER, LIBDECNUMBER_SRC
LIBDECNUMBER_CFLAGS): New macros for libdecnumber.
(INTERNAL_CFLAGS_BASE): Add LIBDECNUMBER_CFLAGS in.
(INSTALLED_LIBS): Add -ldecnumber in.
(CLIBS): Add LIBDECNUMBER in.
(decimal128_h, decimal64_h, decimal32_h): New macros for decimal
headers.
(dfp_h): New macros for decimal floating point.
(dfp.o): New target.
(COMMON_OBS): Add dfp.o in.
(c-exp.o): Add dfp_h as dependency.
(valprint.o): Add dfp_h as dependency.
(value.o): Add dfp_h as dependency.
* dfp.h: New header file for decimal floating point support in
GDB.
* dfp.c: New source file for decimal floating point support in
GDB. Implement decimal_from_string and decimal_to_string based
on libdecnumber API.
* configure.ac: Add AC_C_BIGENDIAN test.
* config.in, configure: Regenerate.
* infcmd.c (registers_info): Check for a user register before
calling target's gdbarch_print_registers_info(). If found to be
so, extract the implicit value of user register and call
print_scalar_formatted().
* Makefile.in: (infcmd.o): Add $(user_regs_h).
(arm_wince_init_abi): Call set_solib_ops.
* i386-cygwin-tdep.c: Include "solib.h" and "solib-target.h".
(i386_cygwin_init_abi): Call set_solib_ops.
* solib-target.c: Include "solib-target.h".
(solib_target_so_ops): Make global.
(_initialize_solib_target): Do not set current_target_so_ops.
* solib-target.h: New file.
* Makefile.in: Update dependencies.
(mips_irix_init_abi): Call set_solib_ops.
* solib-irix.c: Include "solib.h" and "solib-irix.h".
(irix_so_ops): Make global.
(_initialize_irix_solib): Do not set current_target_so_ops.
* solib-irix.h: New file.
* Makefile.in: Update dependencies.
(cp_already_canonical): New function.
(cp_canonicalize_string): Use it. Return NULL for already canonical
strings.
(mangled_name_to_comp): Update call to cp_demangled_name_to_comp.
(cp_func_name, remove_params): Likewise.
(cp_find_first_component_aux): Use ISSPACE.
* cp-support.h (cp_demangled_name_to_comp): Correct comment. Remove
MEMORY_P argument.
* cp-name-parser.y (ALLOC_CHUNK): Define.
(struct demangle_info): Add PREV and NEXT. Increase the size of
COMPS.
(d_grab): Convert to a function.
(allocate_info): Rewrite.
(cp_demangled_name_to_comp): Remove MEMORY argument. Do not use
strlen. Update call to allocate_info. Do not free it on failure.
(main): Update calls to cp_demangled_name_to_comp.
* Makefile.in (cp-support.o): Update.
(run_command_1): Always call post_create_inferior with 0 as
from_tty.
* i386-cygwin-tdep.h: New.
* i386-cygwin-tdep.c: Include "i386-cygwin-tdep.h".
(win32_xfer_shared_library): Make it extern.
* win32-nat.c: Include gdb_obstack.h and xml-support.h and
i386-cygwin-tdep.h.
(win32_so_ops): Delete.
(get_relocated_section_addrs): Delete.
(solib_symbols_add): Delete.
(register_loaded_dll): Delete.
(win32_make_so): New.
(handle_load_dll): Use win32_make_so.
(win32_free_so): Free the passed in so.
(win32_relocate_section_addresses): Delete.
(win32_solib_create_inferior_hook): Delete.
(handle_unload_dll): Don't add PE offset here. Free so with
win32_free_so instead of free_so.
(win32_special_symbol_handling): Delete.
(get_win32_debug_event): Remove unneeded calls. Set state to
TARGET_WAITKIND_LOADED on a dll unload.
(do_initial_win32_stuff): Clear cygwin_load_start and
cygwin_load_end.
(map_code_section_args): Delete.
(dll_code_sections_add): Delete.
(core_section_load_dll_symbols): Delete.
(win32_xfer_shared_libraries): New.
(win32_current_sos): Delete.
(win32_xfer_partial): New.
(open_symbol_file_object): Delete.
(in_dynsym_resolve_code): Delete.
(init_win32_ops): Set win32_xfer_partial as to_xfer_partial member
of win32_ops. Remove win32_so_ops settings. Don't set
current_target_so_ops here.
* Makefile.in (i386_cygwin_tdep_h): New variable.
(i386-cygwin-tdep.o): Update dependencies.
(win32-nat.o): Update dependencies.
* symfile.c (symbol_file_add_with_addrs_or_offsets): Initialize the
DEBUGFILE variable. FIND_SEPARATE_DEBUG_FILE called only if !PSYMTABS.
(struct build_id): New structure.
(build_id_bfd_get, build_id_verify, build_id_to_debug_filename): New.
(find_separate_debug_file): New variable BUILD_ID.
Call BUILD_ID_BFD_GET with BUILD_ID_TO_DEBUG_FILENAME as the first try.
* Makefile.in (MAKEHTMLFLAGS): Also search the current directory
for include files.
gdb/doc/:
* Makefile.in (MAKEHTMLFLAGS): Also search the current directory
for include files.
(struct gdbarch_tdep): New fields
float_return, flavour and fpregs_present.
* m68k-tdep.c (m68k_register_type): Use
fpregs_present and conditionalize floating
registers type on flavour.
(m68k_register_names): New.
(m68k_register_name): Use the above.
(m68k_convert_register_p): Consult fpregs_present.
(m68k_register_to_value, m68k_value_to_register):
Use register_type to obtain the type of floating
point registers.
(m68k_svr4_extract_return_value): Check tdep->float_return.
Use register_type to get the type of floating
point regiters.
(m68k_svr4_store_return_value): Likewise.
(m68k_dwarf_reg_to_regnum): Check tdep->fpregs_present.
(m68k_analyze_register_saves): Likewise.
(m68k_gdbarch_init): Extract infromation
from XML description, if present. Guess coldfire by
looking at the file, if present. Conditionalize
setting of long double format. Set decr_pc_after_break
to 2 on coldfire and fido. Enable XML-driven
register description.
* m68kbsd-tdep.c (m68kbsd_fpreg_offset): Use
size of tdep->fpreg_type, as opposed to hardcoded value.
* Makefile.in (m68k-tdep.o): Update dependencies.
* proc-service.c (ps_addr_to_core_addr, core_addr_to_ps_addr): New.
(ps_xfer_memory): Take a psaddr_t. Use ps_addr_to_core_addr.
(ps_pglobal_lookup): Take a psaddr_t *. Use core_addr_to_ps_addr.
(ps_pdread, ps_pdwrite, ps_ptread, ps_ptwrite): Take a psaddr_t.
* sol-thread.c (gdb_ps_addr_t): Use psaddr_t instead of paddr_t.
* Makefile.in (proc-service.o): Update.
* hppa-linux-tdep.c: Likewise.
* hppa-tdep.c: Include "gdb_stdint.h".
(find_unwind_entry): Cast host pointer to uintptr_t before passing
it to paddr_nz.
* Makefile.in: Update dependencies.
* observer.texi (GDB Observers): New observer "new_objfile".
ChangeLog:
* observer.sh: Add "struct objfile" forward declaration.
* target.h (deprecated_target_new_objfile_hook): Remove.
* symfile.c (deprecated_target_new_objfile_hook): Remove.
(clear_symtab_users): Call observer_notify_new_objfile.
(symbol_file_add_with_addrs_or_offsets): Likewise.
* rs6000-nat.c: Include "observer.h".
(vmap_ldinfo): Call observer_notify_new_objfile.
(xcoff_relocate_core): Likewise.
* remote.c (remote_new_objfile_chain): Remove.
(remote_new_objfile): Do not call remote_new_objfile_chain.
(_initialize_remote): Use observer_attach_new_objfile.
* tui/tui-hooks.c (tui_target_new_objfile_chain): Remove.
(tui_new_objfile_hook): Do not call tui_target_new_objfile_chain.
(_initialize_tui_hooks): Use observer_attach_new_objfile.
* aix-thread.c: Include "observer.h".
(target_new_objfile_chain): Remove.
(new_objfile): Do not call target_new_objfile_chain.
(_initialize_aix_thread): Use observer_attach_new_objfile.
* hpux-thread.c: Include "observer.h"
(target_new_objfile_chain): Remove.
(hpux_thread_new_objfile): Make static. Do not call
target_new_objfile_chain.
(_initialize_hpux_thread): Use observer_attach_new_objfile.
* linux-thread-db.c: Include "observer.h".
(target_new_objfile_chain): Remove.
(thread_db_new_objfile): Do not call target_new_objfile_chain.
(_initialize_thread_db): Use observer_attach_new_objfile.
* sol-thread.c: Include "observer.h".
(target_new_objfile_chain): Remove.
(sol_thread_new_objfile): Make static. Do not call
target_new_objfile_chain.
(_initialize_sol_thread): Use observer_attach_new_objfile.
* Makefile.in (aix-thread.o, hpux-thread.o, linux-thread-db.o,
rs6000-nat.o, sol-thread.o, tui-hooks.o): Add dependency on
$(observer_h).
(fetch_ppc_register): Use uint64_t instead of unsigned long long.
(fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
(fetch_ppc_memory, store_ppc_memory): Fix coding style.
(spu_symbol_file_add_from_memory): Use strtoulst instead of sscanf.
(spu_child_wait): Mark up string for translation.
"gdb_string.h".
(rs6000_aix32_reg_offsets, rs6000_aix64_reg_offsets): New variables.
(rs6000_aix_supply_regset, rs6000_aix_collect_regset): New functions.
(rs6000_aix32_regset, rs6000_aix64_regset): New variables.
(rs6000_aix_regset_from_core_section): New function.
(rs6000_aix_init_osabi): Register it.
(_initialize_rs6000_aix_tdep): Register GDB_OSABI_AIX osabi and
sniffer for bfd_arch_powerpc as well as bfd_arch_rs6000.
* rs6000-nat.c (CoreRegs): Do not define type.
(fetch_core_registers, rs6000_core_fns): Remove.
(_initialize_core_rs6000): Do not register it. Rename to ...
(_initialize_rs6000_nat): ... this.
* Makefile.in (rs6000-aix-tdep.o): Update dependencies.
* Makefile.in (gdbtk-wrapper.o): Update dependencies.
(gdbtk-varobj.o, gdbtk-cmds.o, gdbtk-stack.o): Likewise.
gdb/gdbtk/:
* generic/gdbtk-wrapper.c (GDB_varobj_update): New function.
(wrap_varobj_update): Likewise.
* generic/gdbtk-wrapper.h (GDB_varobj_update): New declaration.
* generic/gdbtk-varobj.c (variable_update): Call
GDB_varobj_update() rather than varobj_update() directly. Take
the new semantics of the latter into account.
* generic/gdbtk-cmds.c: Include "varobj.h".
* generic/gdbtk-stack.c: Likewise.
(inf_ptrace_xfer_partial): Use "uintptr_t" instead of "long" as
intermediate type when casting CORE_ADDR to PTRACE_TYPE_ARG3.
(inf_ptrace_fetch_register): Add intermediate cast to "uintptr_t"
before casting CORE_ADDR to PTRACE_TYPE_ARG3.
(inf_ptrace_store_register): Likewise.
* Makefile.in (inf-ptrace.o): Update dependencies.
* m68klinux-tdep.c (m68k_uclinux_sigcontext_reg_offset): New.
(m68k_linux_sigcontext_reg_offset): Fix typo.
(target_is_uclinux): New.
(m68k_linux_inferior_created): New.
(m68k_linux_get_sigtramp_info): Check for uClinux or
normal Linux. Use m68k_uclinux_sigcontext_reg_offset for
uClinux.
(_initialize_m68k_linux_tdep): Register
m68k_linux_inferior_created.
(COMMON_OBS): Remove hpacc-abi.o.
(ALLDEPFILES): Remove hpread.c and $(HPREAD_SOURCE).
(hpacc-abi.o, hpread.o): Delete rules.
* somread.c: Delete extern declarations from hpread.c.
(som_symfile_read): Do not call do_pxdb or hpread_build_psymtabs.
(som_symfile_finish): Do not call hpread_symfile_finish.
(som_symfile_init): Do not call hpread_symfile_init.
* config/pa/hppa64.mt (TDEPFILES): Remove hpread.o.
* config/pa/hppahpux.mt (TDEPFILES): Likewise.
* hpacc-abi.c, hpread.c: Deleted.
* gdbint.texinfo (SOM): Correct location of the SOM reader.
(COMMON_OBS): Add xml-builtin.o.
(xml-builtin.c, stamp-xml): New rules.
(xml-tdesc.o): Update.
* features/feature_to_c.sh: New file.
* xml-support.c (MAX_XINCLUDE_DEPTH): Define.
(struct gdb_xml_parser): Add dtd_name and is_xinclude.
(gdb_xml_start_element): Initialize scope after possibly reallocating
scopes. Move cleanup later. Handle the XInclude description
specially.
(gdb_xml_end_element): Only parse the body if there is a current element.
Call XML_DefaultCurrent if there is no element.
(gdb_xml_fetch_external_entity, gdb_xml_use_dtd): New.
(struct xinclude_parsing_data, xinclude_start_include)
(xinclude_end_include, xml_xinclude_default)
(xml_xinclude_start_doctype, xml_xinclude_end_doctype)
(xml_xinclude_xml_decl, xml_xinclude_cleanup, xinclude_attributes)
(xinclude_elements, xml_process_xincludes, fetch_xml_builtin): New.
* xml-support.h (xml_fetch_another, xml_process_xincludes)
(fetch_xml_builtin, xml_builtin, gdb_xml_use_dtd): New declarations.
* xml-tdesc.c (tdesc_parse_xml): Add fetcher_baton argument. Expand
XInclude directives. Use the compiled in DTD.
(fetch_xml_from_file): Add baton argument. Treat it as a containing
directory name. Do not warn here.
(file_read_description_xml): Update call. Warn here instead. Pass
a dirname as baton.
(fetch_available_features_from_target): New.
(target_read_description_xml): Use it.
* features/gdb-target.dtd: Add copyright notice. Use xinclude.dtd
to handle XInclude.
* features/xinclude.dtd: New file.
* gdb.xml/bad-include.xml, gdb.xml/inc-2.xml, gdb.xml/inc-body.xml,
gdb.xml/includes.xml, gdb.xml/tdesc-xinclude.exp: New files.
* gdb.texinfo (Target Description Format): Add section on XInclude.
(is_known_support_routine): Improve the check verifying that the file
associated to this frame exists.
* Makefile.in (ada-lang.o): Add dependency on source.h.
* eval.c: Include "ui-out.h" and "exceptions.h".
(evaluate_subexp_standard): Use TRY_CATCH around value_of_variable.
Use value_zero if an error occurs when avoiding side effects.
* varobj.c (c_value_of_root): Initialize new_val.
* gdb.mi/mi-var-cmd.exp: Add tests for unreadable varobjs.
* varobj.c: Include "vec.h".
(varobj_p): New typedef, declare vector of those.
(struct varobj): Use vector for the 'children' member.
(child_exists): Remove.
(save_child_in_parent): Remove.
(remove_child_from_parent): Remove.
(struct varobj_child): Remove.
(struct vstack): Remove.
(vpush, vpop): Remove.
(varobj_list_children): Adjust to work work vector.
(varobj_update): Likewise. Use vectors for
working stack and result.
(delete_variable_1): Likewise.
* Makefile.in (varobj.o): Update dependencies.
(ada_exception_catchpoint_p, ada_decode_exception_location)
(ada_decode_assert_location): Add declaration.
* ada-lang.c: Add include of annotate.h and valprint.h.
(exception_catchpoint_kind): New enum.
(function_name_from_pc, is_known_support_routine)
(ada_find_printable_frame, ada_unhandled_exception_name_addr)
(ada_exception_name_addr_1, ada_exception_name_addr)
(print_it_exception, print_one_exception, print_mention_exception)
(print_it_catch_exception, print_one_catch_exception)
(print_mention_catch_exception, catch_exception_breakpoint_ops)
(print_it_catch_exception_unhandled)
(print_one_catch_exception_unhandled)
(print_mention_catch_exception_unhandled, print_it_catch_assert)
(print_one_catch_assert, print_mention_catch_assert)
(ada_exception_catchpoint_p, error_breakpoint_runtime_sym_not_found)
(ada_get_next_arg, catch_ada_exception_command_split)
(ada_exception_sym_name, ada_exception_sym_name)
(ada_exception_breakption_ops, ada_exception_catchpoint_cond_string)
(ada_parse_catchpoint_condition, ada_exception_sal)
(ada_decode_exception_location)
(ada_decode_assert_location): New function.
(catch_exception_unhandled_breakpoint_ops): New global variable.
(catch_assert_breakpoint_ops): New global variable.
* breakpoint.c: Add include of ada-lang.h.
(print_one_breakpoint): Do not print the condition for Ada
exception catchpoints.
(create_ada_exception_breakpoint): New function.
(catch_ada_exception_command, catch_assert_command): New function.
(catch_command_1): Add support for the new "catch exception" and
"catch assert" commands.
(_initialize_breakpoint): Add help description for the new catch
commands.
* Makefile.in (ada-lang.o): Add dependency on annotate.h and
valprint.h.
(breakpoint.o): Add dependency on ada-lang.h.
Daniel Jacobowitz <dan@codesourcery.com>
* Makefile.in (top.o): Update.
* top.c (gdb_readline_wrapper_done, gdb_readline_wrapper_result)
(saved_after_char_processing_hook, gdb_readline_wrapper_line)
(struct gdb_readline_wrapper_cleanup, gdb_readline_wrapper_cleanup):
New.
(gdb_readline_wrapper): Rewrite to use asynchronous readline.
2007-01-03 Jan Kratochvil <jan.kratochvil@redhat.com>
Daniel Jacobowitz <dan@codesourcery.com>
* gdb.base/readline.exp: Set $TERM. Test arrow keys in
secondary prompts.
* Makefile.in (gnu-v3-abi.o): Delete special rule.
(eval.o, gnu-v3-abi.o, ia64-tdep.o): Update.
* ada-valprint.c (ada_print_scalar): Update for new type codes.
* c-typeprint.c (c_print_type): Update for new type codes.
(c_type_print_varspec_prefix, c_type_print_varspec_suffix)
(c_type_print_base): Likewise.
(c_type_print_args): Rewrite.
* c-valprint.c (c_val_print): Update for new type codes. Remove
support for references to members. Treat methods like functions.
* cp-abi.c (cplus_print_method_ptr, cplus_method_ptr_size)
(cplus_make_method_ptr, cplus_method_ptr_to_value): New.
* cp-abi.h (cplus_print_method_ptr, cplus_method_ptr_size)
(cplus_make_method_ptr, cplus_method_ptr_to_value): New prototypes.
(struct cp_abi_ops): Add corresponding members.
* cp-valprint.c (cp_print_class_method): Delete.
(cp_find_class_member): New function.
(cp_print_class_member): Use it. Simplify support for bogus
member pointers.
* dwarf2read.c (quirk_gcc_member_function_pointer): Use
lookup_methodptr_type.
(read_tag_ptr_to_member_type): Likewise, and lookup_memberptr_type.
* eval.c (evaluate_subexp_standard): Implement EVAL_SKIP for
OP_SCOPE. Update call to value_aggregate_elt. Rewrite member
pointer support.
(evaluate_subexp_for_address): Handle OP_SCOPE explicitly. Handle
references returned by user defined operators.
* f-typeprint.c (f_print_type, f_type_print_varspec_prefix)
(f_type_print_varspec_suffix): Remove support for member pointers.
* gdbtypes.c (lookup_memberptr_type): Renamed from lookup_member_type
and adjusted.
(smash_to_memberptr_type): Likewise, from smash_to_member_type.
(lookup_methodptr_type): New.
(rank_one_type): Adjust for TYPE_CODE_MEMBERPTR.
(recursive_dump_type): Update for new types.
* gdbtypes.h (enum type_code): Replace TYPE_CODE_MEMBER with
TYPE_CODE_MEMBERPTR and TYPE_CODE_METHODPTR.
(lookup_memberptr_type, lookup_methodptr_type)
(smash_to_memberptr_type): New prototypes.
(smash_to_method_type): Formatting fix.
(lookup_member_type, smash_to_member_type): Delete prototypes.
* gnu-v3-abi.c (gnuv3_get_vtable, gnuv3_get_virtual_fn): New.
Do not rely on debug information for the vptr or the method's
enclosing type. Handle function descriptors for IA64.
(gnuv3_virtual_fn_field): Rewrite using the new functions.
(gnuv3_find_method_in, gnuv3_print_method_ptr)
(gnuv3_method_ptr_size, gnuv3_make_method_ptr)
(gnuv3_method_ptr_to_value): New.
(init_gnuv3_ops): Set new members of gnu_v3_abi_ops.
* hpread.c (hpread_type_lookup): Update for new types.
* infcall.c (value_arg_coerce): Likewise.
* m2-typeprint.c (m2_print_type): Remove explicit support
for member pointers.
* m2-valprint.c (m2_val_print): Likewise.
* p-typeprint.c (pascal_type_print_varspec_prefix)
(pascal_type_print_varspec_suffix, pascal_type_print_base): Likewise.
* p-valprint.c (pascal_val_print): Likewise.
(pascal_object_print_class_method, pascal_object_print_class_member):
Delete.
* p-lang.h (pascal_object_print_class_method)
(pascal_object_print_class_member): Delete prototypes.
* stabsread.c (read_type): Update for new types.
* typeprint.c (print_type_scalar): Likewise.
* valops.c (value_struct_elt_for_reference, value_namespace_elt)
(value_maybe_namespace_elt, value_aggregate_elt): Add want_address
argument. Construct a pointer to member if the address of a
function or data member is requested.
(value_cast_pointers): Don't modify the input value.
(value_cast): Adjust pointer to member handling for new types.
Allow null pointer to member constants. Don't modify the input
value.
(value_ind): Remove pointer to member check. Handle function
descriptors for function pointers.
(value_struct_elt, value_find_oload_method_list, check_field):
Remove pointer to member checks.
* value.c (unpack_long): Allow pointers to data members.
(value_from_longest): Allow member pointers.
* value.h (value_aggregate_elt): Add want_address.
* varobj.c (c_variable_editable): Remove check for members.
* gdbarch.sh: Add vtable_function_descriptors and vbit_in_delta.
* ia64-tdep.c (ia64_convert_from_func_ptr_addr): Handle descriptors
in virtual tables.
(ia64_gdbarch_init): Call set_gdbarch_vtable_function_descriptors.
* c-lang.h (cp_print_class_method): Delete prototype.
* arm-tdep.c (arm_gdbarch_init): Call set_gdbarch_vbit_in_delta.
* mips-tdep.c (mips_gdbarch_init): Likewise.
* gdbarch.c, gdbarch.h: Regenerated.
* gdb.cp/classes.exp (test_pointers_to_class_members): Update expected
output. Test the types of members and member pointers.
* gdb.cp/inherit.exp (test_print_mi_member_types): Remove KFAILs for
gdb/2092.
* gdb.cp/member-ptr.exp: Search for a comment instead of a
statement. Enable for GCC. Update expected output for some tests
and add new tests. Remove obsolete GCC KFAILs. Allow GCC's class
layout.
* gdb.cp/member-ptr.cc (Padding, Padding::vspacer, Base, Base::get_x)
(Base::vget_base, Left, Left::vget, Right, Right::vget, Diamond)
(Diamond::vget_base): New.
(main): Add new tests.
* gdb.cp/printmethod.exp: Update expected output for member functions.
* gdb.cp/virtfunc.exp (test_virtual_calls): Add a KFAIL for
print pEe->D::vg().
* config/alpha/alpha-linux.mt (DEPRECATED_TM_FILE): Set to tm-alpha.h.
* config/alpha/tm-alphalinux.h: Delete file.
* config/arm/linux.mt (DEPRECATED_TM_FILE): Set to tm-arm.h
* config/arm/tm-linux.h: Delete file.
* config/i386/tm-linux.h: Do not include "config/tm-linux.h".
* config/ia64/tm-linux.h: Do not include "config/tm-linux.h".
* config/m32r/linux.mt (DEPRECATED_TM_FILE): Remove.
* config/mips/tm-linux.h: Do not include "config/tm-linux.h".
* config/pa/linux.mt (DEPRECATED_TM_FILE): Set to tm-hppa.h.
* config/pa/tm-linux.h: Delete file.
* config/powerpc/tm-linux.h: Do not include "config/tm-linux.h".
* config/s390/linux.mt (DEPRECATED_TM_FILE): Remove.
* config/sh/linux.mt (DEPRECATED_TM_FILE): Set to tm-sh.h.
* config/sh/tm-linux.h: Delete file.
* alpha-linux-tdep.c: Include "symtab.h".
(alpha_linux_init_abi): Call set_gdbarch_skip_trampoline_code.
* i386-linux-tdep.c: Include "symtab.h".
(i386_linux_init_abi): Call set_gdbarch_skip_trampoline_code.
* ia64-linux-tdep.c: Include "symtab.h".
(ia64_linux_init_abi): Call set_gdbarch_skip_trampoline_code.
* m32r-linux-tdep.c: Include "symtab.h".
(m32r_linux_init_abi): Call set_gdbarch_skip_trampoline_code.
* mips-linux-tdep.c: Include "symtab.h".
(mips_linux_init_abi): Call set_gdbarch_skip_trampoline_code.
* sh-linux-tdep.c: Include "symtab.h".
(sh_linux_init_abi): Call set_gdbarch_skip_trampoline_code.
* s390-tdep.c (s390_gdbarch_init): Call
set_gdbarch_skip_trampoline_code.
* s390-nat.c: Do not include "tm.h".
* Makefile.in (alpha-linux-tdep.o): Add dependency on $(symtab_h).
(i386-linux-tdep.o): Likewise.
(ia64-linux-tdep.o): Likewise.
(m32r-linux-tdep.o): Likewise.
(mips-linux-tdep.o): Likewise.
(sh-linux-tdep.o): Likewise.
(s390-nat.o): Remove dependency on $(tm_h).
(COMMON_OBS): Add target-memory.o.
* memattr.c (lookup_mem_region): Adjust handling for
the top of memory. Improve comments.
* remote.c (packet_check_result): New function, split out
from packet_ok. Recognize "E." as an error prefix.
(packet_ok): Use it.
(remote_write_bytes_aux): New function, renamed from
remote_write_bytes. Take packet header, packet format,
and length flag as arguments.
(remote_write_bytes): Rewrite to use remote_write_bytes_aux.
(remote_send_printf, restore_remote_timeout)
(remote_flash_timeout, remote_flash_erase, remote_flash_write)
(remote_flash_done): New.
(remote_xfer_partial): Handle flash writes.
(init_remote_ops, init_remote_async_ops): Set to_flash_erase
and to_flash_done.
* symfile.c (struct load_section_data): Include a pointer to
the cumulative stats and a request queue. Move most members
to other types.
(struct load_progress_data, struct load_progress_section_data): New
types.
(load_progress): Handle a NULL baton and zero bytes. Update for
type changes.
(load_section_callback): Create memory write requests instead of
writing to memory. Don't print the progress message here.
(clear_memory_write_data): New function.
(generic_load): Use target_write_memory_blocks.
* target-memory.c: New file.
* target.c (update_current_target): Mention new uninherited methods.
(memory_xfer_partial): Issue an error for flash writes.
(target_flash_erase, target_flash_done): New functions.
(target_write_with_progress): Call the progress callback at the
start also.
* target.h (enum target_object): Add TARGET_OBJECT_FLASH.
(target_write_with_progress): Update comment.
(struct target_ops): Add to_flash_erase and to_flash_done.
(target_flash_erase, target_flash_done, struct memory_write_request)
(memory_write_request_s, enum flash_preserve_mode)
(target_write_memory_blocks): New, including a vector type
for memory_write_request_s.
* memattr.h: Include "vec.h".
(struct mem_region): Remove linked list pointer.
(mem_region_s): New typedef and corresponding vector.
* memattr.c: Include "vec.h".
(mem_region_chain): Delete.
(mem_region_list): New vector pointer.
(mem_region_lessthan): New function.
(create_mem_region): Remove unused return value. Use vector
operations. Remove linear search.
(delete_mem_region): Delete.
(lookup_mem_region): Use vector operations. Add a FIXME.
(mem_info_command): Update to work with vectors.
(mem_enable, mem_enable_command, mem_disable, mem_disable_command)
(mem_free, mem_delete): Likewise.
(substitute_path_rule): New struct.
(substitute_path_rules): New static global variable.
(substitute_path_rule_matches): New function.
(get_substitute_path_rule): New function.
(rewrite_source_path): New function.
(find_and_open_source): Add source path rewriting support.
(strip_trailing_directory_separator): New function.
(find_substitute_path_rule): New function.
(add_substitute_path_rule): New function.
(delete_substitute_path_rule): New function.
(show_substitute_path_command): New function.
(unset_substitute_path_command): New function.
(set_substitute_path_command): New function.
(_initialize_source): Add new substitute-path commands.
* Makefile.in (source.o): Add dependency on gdb_assert.h.
* objfiles.c: Include "expression.h" and "parser-defs.h".
(free_objfile): Clear global blocks.
* symfile.c: Include "parser-defs.h".
(clear_symtab_users): Clear global blocks.
* Makefile.in (ALLDEPFILES): Add armobsd-tdep.c.
(armobsd-tdep.o): New dependency.
* config/arm/obsd.mt: New file.
* configure.tgt: (arm*-*-openbsd*): Set gdb_target to obsd.
* alphanbsd-tdep.c (_initialize_alphanbsd_tdep): Do not register a
handler for GDB_OSABI_OPENBSD_ELF.
* Makefile.in (ALLDEPFILES): Add alphaobsd-tdep.c.
(alphaobsd-tdep.o): New target.
* config/alpha/obsd.mt: New file.
* configure.tgt (alpha*-*-openbsd*): Set gdb_target to obsd.
2006-05-19 Fred Fish <fnf@specifix.com>
* Makefile.in: Fix spelling of 'explicitly' and 'explicit'.
* dwarfread.c: Fix spelling of 'unexpected'.
* mips-tdep.c: Fix spelling of 'possible' and 'Determine'.
* stack.c: Fix spelling of 'RETURN_VALUE'.
* 2006-03-22 Jim Blandy <jimb@redhat.com>
Add support for the Renesas M32C and M16C.
* configure.tgt (m32c-*-*): New entry.
* config/m32c/m32c.mt: New file.
* m32c-tdep.c: New file.
* Makefile.in (elf_m32c_h): New variable.
(m32c-tdep.o): New rule.
* NEWS: Mention new target.
* MAINTAINERS: Designate Jim Blandy as responsible maintainer.
frame sniffer.
* sparc-tdep.c (sparc32_gdbarch_init): Make sure to call
dwarf2_frame_set_init_reg() before gdbarch_init_osabi() so
that the latter can override.
* Makefile.in (sparc64-linux-tdep.o): Update dependencies.
(sparc32_linux_init_abi): Hook it into tdep->step_trap.
* sparc64-linux-tdep.c (sparc64_linux_step_trap): New.
(sparc64_linux_init_abi): Hook it into tdep->step_trap.
* Makefile.in: Update dependencies.