Commit Graph

1509 Commits

Author SHA1 Message Date
Tom Tromey 700b53b17a * cli/cli-decode.h (CMD_ASYNC_OK): New define.
(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-17 00:25:01 +00:00
Daniel Jacobowitz aa11fd3fc4 * Makefile.in (GNULIB_H): New. Trigger all-lib.
(defs_h): Use $(GNULIB_H).
	(all-lib): Depend on gnulib/Makefile.
	(gnulib/Makefile): Regenerate gnulib/Makefile and gnulib/.deps.
	* config.in, gnulib/Makefile.in: Regenerated.
2008-04-14 19:47:29 +00:00
Daniel Jacobowitz e28b33320c * Makefile.in (LIBGNU, INCGNU): Define.
(INTERNAL_CFLAGS_BASE): Add INCGNU.
	(INTERNAL_LIBS, CLIBS, CDEPS): Add LIBGNU.
	(CLEANDIRS): New.
	($(LIBGNU), all-lib): New rules.
	(clean, distclean, do-maintainer-clean): Use CLEANDIRS.
	* configure.ac: Use gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE.
	Simplify AC_CONFIG_AUX_DIR.  Generate gnulib/Makefile.
	* gnulib: New directory, from gnulib-tool.
	* configure, aclocal.m4: Regenerated.

	* Makefile.in (LIBOBJS): New.
	(OBS): Use LIBOBJS.
	(memmem.o): New rule.
	* configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
	* configure: Regenerated.
2008-04-14 18:04:00 +00:00
Marc Khouzam de051565df gdb/ChangeLog
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.
2008-04-09 13:29:55 +00:00
Pedro Alves effa26a936 * alphanbsd-tdep.c: Include "target.h".
* mn10300-tdep.c: Include "target.h".
	* Makefile.in (alphanbsd-tdep.o, mn10300-tdep.o): Update.
2008-04-07 11:45:58 +00:00
Ulrich Weigand 5e2b427df3 * objfiles.h (struct objfile): New GDBARCH member.
(get_objfile_arch): Add prototype.
	* objfiles.c: Include "arch-utils.h".
	(allocate_objfile): Look up gdbarch associated with bfd.
	(get_objfile_arch): New function.
	* Makefile (objfiles.o): Update dependencies.

	* dwarf2-frame.c (decode_frame_entry_1): Replace current_gdbarch
	by objfile arch.
	* dwarf2loc.c (dwarf_expr_read_reg): Replace current_gdbarch
	by frame arch.
	(locexpr_describe_location): Replace current_gdbarch by
	objfile arch.
	* dwarf2read.c (die_type): Replace current_gdbarch by objfile arch.
	(dwarf2_add_field): Likewise.
	(read_tag_pointer_type): Likewise.
	(read_base_type): Likewise.
	(new_symbol): Likewise.

	* coffread.c (decode_type): Add OBJFILE argument.  Update callers.
	(decode_base_type, decode_function_type): Likewise.
	(coff_read_struct_type, coff_read_enum_type): Likewise.
	(coff_symtab_read): Replace current_gdbarch by objfile arch.
	(decode_base_type): Likewise.
	(coff_read_enum_type): Likewise.
	(coff_read_struct_type): Replace current_objfile by OBJFILE argument.
	(coff_read_enum_type): Likewise.

	* dbxread.c (read_dbx_symtab): Replace current_gdbarch by objfile arch.
	(end_psymtab): Likewise.
	(process_one_symbol): Likewise.

	* mdebugread.c (parse_symbol): Replace current_gdbarch by objfile arch.
	(parse_procedure): Likewise.
	(parse_partial_symbols): Likewise.

	* somread.c (som_symtab_read): Replace current_gdbarch by objfile arch.

	* stabsread.c (define_symbol): Replace current_gdbarch by objfile arch.
	Replace static pcc_promotion_type and pcc_unsigned_promotion_type by
	built-in types.
	(read_range_type): Replace current_gdbarch by objfile arch.  Replace
	static range_index_type by built-in type.
	(read_one_struct_field): Replace current_gdbarch by objfile arch.
	(read_enum_type): Likewise.

	* xcoffread.c (read_xcoff_symtab): Replace current_gdbarch by
	objfile arch.
2008-03-26 14:53:28 +00:00
Vladimir Prus 6208b47d6c * thread.c (make_cleanup_restore_current_thread): Make it
globally visible.
	* gdbthread.h (make_cleanup_restore_current_thread): Declare.
	* varobj.c (varobj_update): Don't save/restore frame.
	(c_value_of_root): Save/restore thread and frame here,
	using make_cleanup_restore_current_thread.
	* Makefile.in: Update dependecies.
2008-03-23 09:53:52 +00:00
Pedro Alves b84876c212 gdb/
* 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".
2008-03-21 17:09:35 +00:00
Nick Hudson f01be29bbc * Makefile.in (amd64nbsd-nat.o): New dependency.
* amd64nbsd-nat.c: Include "nbsd-nat.h".
        (_initialize_amd64nbsd_nat): Update target vector to use
        nbsd_pid_to_exec_file.
        * config/i386/nbsd64.mh (NATDEPFILES): Add nbsd-nat.o.
2008-03-16 08:50:43 +00:00
Vladimir Prus 8e8901c5c2 Implement -thread-info.
* 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'.
2008-03-15 13:53:25 +00:00
Vladimir Prus 32c1e744c1 Async mode fixes.
* 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.
2008-03-14 18:57:44 +00:00
Vladimir Prus 683f2885af Implement MI notification for new threads.
* doc/observer.texi (new_thread): Document.
        * observer.sh: Forward declare struct thread_info.
        * thread.c (add_thread): Notify observer.

        * interps.h (interp_init_ftype): New parameter
        top_level.
        (interp_set): Likewise.
        (top_level_interpreter_data): Declare.
        * interps.c (interp_set): New parameter top_level.
        Pass it to interpreter's init function.  Remember
        top level interpreter.
        (interpreter_exec_cmd): Adjust.
        (top_level_interpreter_data): New.
        * main.c (captured_main): Pass 1 for top_level
        parameter of interp_set.
	* cli/cli-interp.c (cli_interpreter_init): New
        parameter top_level.
        * tui/tui-interp.c (tui_init): New parameter top_level.

        * mi/mi-interp.c (mi_new_thread): New.
        (mi_interpreter_init): If top level, register
        observer for new threads.

        * Makefile.in (mi-interp.o, thread.o): Update dependencies.
2008-03-14 17:21:08 +00:00
Daniel Jacobowitz 8defab1af7 * breakpoint.h (breakpoint_restore_shadows): New
declaration.
	* breakpoint.c (breakpoint_restore_shadows): New.
	(read_memory_nobpt): Delete.
	* gdbcore.h (read_memory_nobpt): Delete declaration.
	* target.c (memory_xfer_partial): Call
	breakpoint_restore_shadows.
	(restore_show_memory_breakpoints)
	(make_show_memory_beakpoints_cleanup): New.
	(show_memory_breakpoints): New.
	* target.h (make_show_memory_beakpoints_cleanup): Declare.
	* ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint):
	Make sure we see memory breakpoints when checking if
	breakpoint is still there.
	* alpha-tdep.c, alphanbsd-tdep.c, frame.c, frv-tdep.c,
	hppa-linux-tdep.c, hppa-tdep.c, i386-linux-nat.c, i386-tdep.c,
	m68klinux-tdep.c, mips-tdep.c, mn10300-tdep.c, s390-tdep.c,
	sparc-tdep.c: Use target_read_memory instead of read_memory_nobpt.
2008-03-13 12:22:14 +00:00
Daniel Jacobowitz ccd213ac7e * Makefile.in (fork-child.o): Update.
* 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.
2008-03-10 23:14:06 +00:00
Daniel Jacobowitz b803fb0f0f * Makefile.in (mingw-hdep.o, posix-hdep.o, remote-fileio.o): Update.
* event-loop.c (call_async_signal_handler): New.
	* event-loop.h (call_async_signal_handler)
	(gdb_call_async_signal_handler): Declare.
	(mark_async_signal_handler): Add comments.
	* event-top.c (handle_sigint): Use gdb_call_async_signal_handler.
	* mingw-hdep.c (sigint_event, sigint_handler): New.
	(gdb_select): Use them.  Wait for the readline signal handler
	to finish.
	(gdb_call_async_signal_handler, _initialize_mingw_hdep): New functions.
	* posix-hdep.c (gdb_call_async_signal_handler): New function.
	* remote-fileio.c (sigint_fileio_token, async_remote_fileio_interrupt):
	New.
	(remote_fileio_ctrl_c_signal_handler): Use
	gdb_call_async_signal_handler.
	(initialize_remote_fileio): Initialize sigint_fileio_token.
	* remote.c (initialize_sigint_signal_handler, handle_remote_sigint): Do
	not initialize tokens here.
	(handle_remote_sigint_twice): Likewise.  Reinstall
	handle_remote_sigint.
	(async_remote_interrupt_twice): Just call interrupt_query.
	(cleanup_sigint_signal_handler): Do not delete tokens.
	(remote_interrupt, remote_interrupt_twice): Use
	gdb_call_async_signal_handler.
	(interrupt_query): Reinstall the default signal handler.
	(_initialize_remote): Initialize tokens here.
2008-03-05 17:21:10 +00:00
Daniel Jacobowitz c03374d554 * Makefile.in (i386-nat.o): Update.
* amd64-linux-nat.c (_initialize_amd64_linux_nat): Call
	i386_use_watchpoints.
	* i386-linux-nat.c (_initialize_i386_linux_nat): Call
	i386_use_watchpoints.
	* i386-nat.c (i386_stopped_data_address): Take two arguments.
	(i386_stopped_by_watchpoint): Update call.
	(i386_can_use_hw_breakpoint, i386_use_watchpoints): New.
	* config/i386/nm-i386.h: Conditionalize definitions on
	! I386_WATCHPOINTS_IN_TARGET_VECTOR.
	(i386_use_watchpoints): Declare.
	(i386_stopped_data_address): Update.
	* config/i386/nm-linux.h (I386_WATCHPOINTS_IN_TARGET_VECTOR): Define.
	* config/i386/nm-linux64.h (I386_WATCHPOINTS_IN_TARGET_VECTOR): Define.
2008-03-01 04:39:36 +00:00
Daniel Jacobowitz e25c958c98 * configure.tgt (sh-*-linux*): Match sh*. Add glibc-tdep.o.
* sh-linux-tdep.c (sh_linux_init_abi): Use glibc_skip_solib_resolver
	and svr4_fetch_objfile_link_map.
	* Makefile.in (sh-linux-tdep.o): Update.
2008-02-27 01:06:21 +00:00
Markus Deuling 07ea644b36 2008-02-20 Markus Deuling <deuling@de.ibm.com>
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.
2008-02-20 15:45:20 +00:00
Markus Deuling f6fbcbf926 * Makefile.in (ALL_TARGET_OBS): Remove dependency to xtensa-linux-nat.o. 2008-02-14 04:49:12 +00:00
Maxim Grigoriev 94a0e87711 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
* 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.
2008-02-11 21:58:41 +00:00
Eli Zaretskii f90c07ac03 * corelow.c (core_open): Use IS_ABSOLUTE_PATH.
(filenames.h): New include.
	* Makefile.in (corelow.o): Add dependency for filenames.h.
2008-02-09 13:45:33 +00:00
Doug Evans 776592bf17 * breakpoint.c: #include "hashtab.h".
(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.
2008-02-08 00:42:07 +00:00
Joel Brobecker 2ba95b9b76 * ada-lang.c: #include "vec.h".
(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.
2008-02-07 19:06:51 +00:00
Vladimir Prus d56d46f5c7 Use vector for varobj_list_children interface.
* gdb/varobj.c (varobj_list_children): Return vector
        of varobjs.
        * gdb/varobj.h (varobj_list_children): Adjust
        prototype.
        (varobj_p): Declare.  Declare vector thereof.
        * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust
        for varobj_list_children change.
	* Makefile.in (varobj_h): Update dependencies.
2008-01-30 07:17:31 +00:00
Daniel Jacobowitz e85a822c15 * Makefile.in (symfile.o): Update.
* 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.
2008-01-29 22:47:20 +00:00
Joel Brobecker b4d5ed91ae * nto-tdep.h: Remove #include "defs.h".
* nto-tdep.c: Add #include "defs.h".
        * Makefile.in (nto_tdep_h): Update dependencies.
        (nto-tdep.o): Likewise.
2008-01-29 21:26:04 +00:00
Nick Hudson af5ca30dc3 Add NetBSD/hppa target and host support.
* 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.
2008-01-19 15:03:50 +00:00
Markus Deuling ed49a04fe1 * exec.c: #include "arch-utils.h"
(print_section_info): Use gdbarch_from_bfd to get at the
	current architecture. Replace current_gdbarch. Fix indention.
	Replace deprecated_print_address_numeric by paddress.
	* Makefile.in (exec.o) Add dependency to arch-utils.h.

	* valprint.c (val_print_string): Replace
	deprecated_print_address_numeric.
	* tracepoint.c (trace_mention, scope_info): Likewise.
	* symmisc.c (dump_msymbols, dump_psymtab, dump_symtab_1, print_symbol)
	(print_symbol, print_partial_symbols, maintenance_info_psymtabs)
	(maintenance_check_symtabs): Likewise.
	* symfile.c (list_overlays_command): Likewise.
	* stack.c (frame_info, print_block_frame_labels): Likewise.
	* printcmd.c (print_address, print_address_demangle)
	(address_info): Likewise.
	* corefile.c (memory_error): Likewise.
	* infcmd.c (jump_command): Likewise.
	* breakpoint.c (insert_bp_location, describe_other_breakpoints)
	(mention, delete_breakpoint): Likewise.
	* c-valprint.c (print_function_pointer_address, c_val_print): Likewise.
	* dwarf2read.c (dump_die): Likewise.
	* ada-valprint.c (ada_val_print_1): Likewise.
	* f-valprint.c (f_val_print): Likewise.
	* linux-fork.c (info_forks_command): Likewise.
	* m32r-com.c (m32r_load_section, m32r_load)
	(m32r_upload_command): Likewise.

	* ui-out.c (ui_out_field_core_addr): Remove unnecessary comment.
2008-01-11 13:34:15 +00:00
Joel Brobecker a93c0eb695 * ada-lang.c (ada_convert_actual): Renames convert_actual.
Make non-static.
        (ada_convert_actuals): Delete.
        * ada-lang.h (ada_convert_actual): Add declaration.
        (ada_convert_actuals): Remove declaration.
        * infcall.c: #include "ada-lang.h".
        (value_arg_coerce): Add new parameter sp.  Update function
        documetnation.  Add handling of Ada function call parameters.
        * Makefile.in (infcall.o): Update dependencies.
2008-01-08 19:28:09 +00:00
Thiago Jung Bauermann 4ef30785ea * Makefile.in (dfp.o): Depend on expression.h, gdbtypes.h and value.h.
(valarith.o): Depend on dfp.h.
	(valops.o): Likewise.
	* dfp.c: Include expression.h, gdbtypes.h, value.h and dfp.h.
	(set_decnumber_context): New function.
	(decimal_check_errors): Likewise.
	(decimal_from_number): Likewise.
	(decimal_to_number): Likewise.
	(decimal_from_string): Use set_decnumber_context and
	decimal_check_errors.
	(decimal_from_integral): New function.
	(decimal_from_floating): Likewise.
	(decimal_to_double): Likewise.
	(promote_decimal): Likewise.
	(decimal_binop): Likewise.
	(decimal_is_zero): Likewise.
	(decimal_compare): Likewise.
	(decimal_convert): Likewise.
	* dfp.h (decimal_from_integral): New prototype.
	(decimal_from_floating): Likewise.
	(decimal_to_double): Likewise.
	(decimal_binop): Likewise.
	(decimal_is_zero): Likewise.
	(decimal_compare): Likewise.
	(decimal_convert): Likewise.
	* eval.c (evaluate_subexp_standard): Remove expect_type argument from
	call to value_from_decfloat.
	* valarith.c: Include dfp.h.
	(value_args_as_decimal): New function.
	(value_binop): Add if block to handle TYPE_CODE_DECFLOAT values.
	(value_logical_not): Likewise.
	(value_equal): Likewise.
	(value_less): Likewise.
	(value_pos): Likewise.
	(value_neg): Formatting fix.
	* valops.c: Include dfp.h.
	(value_cast): Add if block to handle TYPE_CODE_DECFLOAT values.
	* value.c (unpack_long): Add case to handle TYPE_CODE_DECFLOAT.
	(unpack_double): Add if block to handle TYPE_CODE_DECFLOAT.
	(value_from_decfloat): Remove expect_type argument.
	* value.h (value_from_decfloat): Update prototype.
2008-01-07 22:33:57 +00:00
Daniel Jacobowitz 9b254dd1ce Updated copyright notices for most files. 2008-01-01 22:53:26 +00:00
Mark Kettenis 70f13f6b00 * i386nbsd-tdep.c: Include "trad-frame.h" and "tramp-frame.h"
(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
2007-12-29 17:01:41 +00:00
Joel Brobecker 3463063964 * rs6000-tdep.h: Remove defs.h #include.
* Makefile.in (rs6000_tdep_h): Update dependencies.
2007-12-21 04:59:00 +00:00
Joel Brobecker 10d00faca9 * symtab.h: Remove "defs.h" #include.
* Makefile.in (symtab_h): Update dependencies.
2007-12-20 05:36:14 +00:00
Joel Brobecker 67cd94cafd * symtab.h: #include "defs.h".
(enum language): Remove opaque declaration.
        * Makefile.in (symtab_h): Update dependencies.
2007-12-19 13:21:32 +00:00
Maciej W. Rozycki 9544c605b6 * utils.c (string_to_core_addr): If the executable format
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).
2007-12-17 17:49:29 +00:00
Pierre Muller 2c6474365f 2007-12-06 Pierre Muller <muller@ics.u-strasbg.fr>
* win32-nat.c: Allow compilation if CORE_ADDR is 8 byte long.
	Add "gdb_stdint.h" dependency required for uintptr_t type use.
	(handle_output_debug_string): Use uintptr_t typecast.
	(handle_exception): Ditto.
	(win32_xfer_memory): Ditto.
	* Makefile.in (win32-nat.o): Add dependency to gdb_stdint header.
2007-12-06 11:17:03 +00:00
Jim Blandy 801e3a5b56 Support lexical blocks and function bodies that occupy
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.
2007-12-04 23:43:57 +00:00
Daniel Jacobowitz a6b151f187 * remote.c (remote_cmdlist): New variable.
(PACKET_vFile_open, PACKET_vFile_pread, PACKET_vFile_pwrite)
	(PACKET_vFile_close, PACKET_vFile_unlink): New constants.
	(remote_buffer_add_string, remote_buffer_add_bytes)
	(remote_buffer_add_int, remote_hostio_parse_result)
	(remote_hostio_send_command, remote_hostio_open, remote_hostio_pwrite)
	(remote_hostio_pread, remote_hostio_close, remote_hostio_unlink)
	(remote_fileio_errno_to_host, remote_hostio_error, fclose_cleanup)
	(remote_hostio_close_cleanup, remote_file_put, remote_file_get)
	(remote_file_delete, remote_put_command, remote_get_command)
	(remote_delete_command, remote_command): New functions.
	(_initialize_remote): Register new packets and commands.
	* Makefile.in (gdb_fileio_h): New variable.
	(remote.o): Update.
	(SUBDIR_MI_OBS): Add mi-cmd-target.o.
	(SUBDIR_MI_SRCS): Add mi/mi-cmd-target.c.
	(mi-cmd-target.o): New rule.
	* mi/mi-cmd-target.c: New file.
	* mi/mi-cmds.c (mi_cmds): Add target-file-delete, target-file-get,
	and target-file-put.
	* mi/mi-cmds.h (mi_cmd_target_file_get, mi_cmd_target_file_put)
	(mi_cmd_target_file_delete): Declare.
	* remote.h (remote_file_put, remote_file_get, remote_file_delete):
	Declare.
	* NEWS: Describe new file transfer support.

	* gdb.texinfo (Debugging Programs with Multiple Processes): Correct
	formatting.
	(Remote Debugging): Add File Transfer section.
	(Remote Configuration): Document Host I/O packets.
	(GDB/MI): Add GDB/MI File Transfer Commands section.
	(Remote Protocol): Add Host I/O Packets section.
	(Packets): Add vFile.

	* Makefile.in (OBS): Add hostio.o.
	(hostio.o): New rule.
	* server.h (handle_vFile): Declare.
	* hostio.c: New file.
	* server.c (handle_v_requests): Take packet_len and new_packet_len
	for binary packets.  Call handle_vFile.
	(main): Update call to handle_v_requests.

	* gdb.server/file-transfer.exp, gdb.server/transfer.txt,
	gdb.mi/mi-file-transfer.exp: New.
2007-11-30 21:50:19 +00:00
Ulrich Weigand c0993dbe92 * Makefile.in (ALL_TARGET_OBS): Remove object files that require
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.
2007-11-27 17:06:12 +00:00
Ulrich Weigand d0c678e6de * configure.ac (--enable-targets): New configure option.
Collect gdb_target_obs of multiple targets into TARGET_OBS.
	Call configure.tgt multiple times, using $targ as operand.
	* configure.tgt: Operate on $targ instead of $target.
	* configure: Regenerate.
	* Makefile.in (ALL_TARGET_OBS): Define.

	* NEWS: Mention --enable-targets option.
2007-11-17 01:02:01 +00:00
Ulrich Weigand ec20a626bd * amd64fsdb-tdep.c (amd64fbsd_sigtramp_start_addr): Use ULL suffix.
(amd64fbsd_sigtramp_end_addr): Likewise.

	* iq2000-tdep.c (iq2000_pointer_to_address): Fix argument type.
	(iq2000_address_to_pointer): Likewise.
	(iq2000_frame_prev_register): Likewise.
	(iq2000_extract_return_value): Use regcache_cooked_read_unsigned
	instead of regcache_cooked_read into CORE_ADDR variable.
	(iq2000_return_value): Fix argument types.

	* m32r-rom.c (m32r_load_section): Fix printf argument type.
	(m32r_load): Likewise.

	* m68kbsd-tdep.c: Include "gdbtypes.h".
	* Makefile.in: Update dependencies.

	* mn10300-tdep.c (mn10300_frame_unwind_cache): Fix aliasing violation.

	* nto-tdep.c (LM_ADDR): Do not refer to no-longer-existing
	lmo->l_addr_size element.

	* remote-m32r-sdi.c (m32r_xfer_memory): Use paddr to print address.
	(m32r_insert_breakpoint): Likewise.
	(m32r_remove_breakpoint): Likewise.
	(m32r_insert_watchpoint): Likewise.
	(m32r_remove_watchpoint): Likewise.
	(m32r_load): Fix printf argument type.

	* xtensa-tdep.c (xtensa_regset_from_core_section): Fix printf
	argument type.
	(xtensa_frame_this_id): Do not cast pointers to "int" for output.
	(xtensa_frame_prev_register): Likewise.
	(xtensa_push_dummy_call): Likewise.
2007-11-17 00:55:29 +00:00
Ulrich Weigand a4ce5b0d02 * config/alpha/alpha-linux.mt: Remove file.
* config/alpha/alpha.mt: Remove file.
	* config/alpha/alpha-osf1.mt: Remove file.
	* config/alpha/fbsd.mt: Remove file.
	* config/alpha/nbsd.mt: Remove file.
	* config/alpha/obsd.mt: Remove file.
	* config/arm/embed.mt: Remove file.
	* config/arm/linux.mt: Remove file.
	* config/arm/nbsd.mt: Remove file.
	* config/arm/obsd.mt: Remove file.
	* config/arm/wince.mt: Remove file.
	* config/avr/avr.mt: Remove file.
	* config/cris/cris.mt: Remove file.
	* config/frv/frv.mt: Remove file.
	* config/h8300/h8300.mt: Remove file.
	* config/i386/cygwin.mt: Remove file.
	* config/i386/fbsd64.mt: Remove file.
	* config/i386/fbsd.mt: Remove file.
	* config/i386/i386gnu.mt: Remove file.
	* config/i386/i386.mt: Remove file.
	* config/i386/i386sol2.mt: Remove file.
	* config/i386/linux64.mt: Remove file.
	* config/i386/linux.mt: Remove file.
	* config/i386/mingw.mt: Remove file.
	* config/i386/nbsd64.mt: Remove file.
	* config/i386/nbsd.mt: Remove file.
	* config/i386/nto.mt: Remove file.
	* config/i386/obsd64.mt: Remove file.
	* config/i386/obsd.mt: Remove file.
	* config/i386/sol2-64.mt: Remove file.
	* config/ia64/ia64.mt: Remove file.
	* config/ia64/linux.mt: Remove file.
	* config/iq2000/iq2000.mt: Remove file.
	* config/m32c/m32c.mt: Remove file.
	* config/m32r/linux.mt: Remove file.
	* config/m32r/m32r.mt: Remove file.
	* config/m68hc11/m68hc11.mt: Remove file.
	* config/m68k/linux.mt: Remove file.
	* config/m68k/monitor.mt: Remove file.
	* config/m68k/nbsd.mt: Remove file.
	* config/m68k/obsd.mt: Remove file.
	* config/m88k/obsd.mt: Remove file.
	* config/mep/mep.mt: Remove file.
	* config/mips/embed.mt: Remove file.
	* config/mips/irix5.mt: Remove file.
	* config/mips/irix6.mt: Remove file.
	* config/mips/linux.mt: Remove file.
	* config/mips/nbsd.mt: Remove file.
	* config/mips/obsd64.mt: Remove file.
	* config/mn10300/linux.mt: Remove file.
	* config/mn10300/mn10300.mt: Remove file.
	* config/mt/mt.mt: Remove file.
	* config/pa/hppahpux.mt: Remove file.
	* config/pa/hppa.mt: Remove file.
	* config/pa/linux.mt: Remove file.
	* config/pa/obsd.mt: Remove file.
	* config/powerpc/aix.mt: Remove file.
	* config/powerpc/linux.mt: Remove file.
	* config/powerpc/nbsd.mt: Remove file.
	* config/powerpc/obsd.mt: Remove file.
	* config/powerpc/ppc-eabi.mt: Remove file.
	* config/s390/s390.mt: Remove file.
	* config/score/embed.mt: Remove file.
	* config/sh/embed.mt: Remove file.
	* config/sh/linux.mt: Remove file.
	* config/sh/nbsd.mt: Remove file.
	* config/sh/obsd.mt: Remove file.
	* config/sh/sh64.mt: Remove file.
	* config/sparc/embed.mt: Remove file.
	* config/sparc/fbsd.mt: Remove file.
	* config/sparc/linux64.mt: Remove file.
	* config/sparc/linux.mt: Remove file.
	* config/sparc/nbsd64.mt: Remove file.
	* config/sparc/nbsd.mt: Remove file.
	* config/sparc/obsd64.mt: Remove file.
	* config/sparc/obsd.mt: Remove file.
	* config/sparc/sol2-64.mt: Remove file.
	* config/sparc/sol2.mt: Remove file.
	* config/sparc/sparc64.mt: Remove file.
	* config/sparc/sparc.mt: Remove file.
	* config/spu/spu.mt: Remove file.
	* config/v850/v850.mt: Remove file.
	* config/vax/nbsd.mt: Remove file.
	* config/vax/obsd.mt: Remove file.
	* config/vax/vax.mt: Remove file.
	* config/xstormy16/xstormy16.mt: Remove file.
	* config/xtensa/xtensa.mt: Remove file.

	* configure.tgt (gdb_target_cpu): Remove.  Do not set anywhere.
	(gdb_target): Likewise.
	(gdb_target_obs): Document.  Set for every target to contents
	of TDEPFILES in former .mt makefile fragment.

	* configure.ac (TARGET_OBS): Define.
	(target_makefile_frag, gdb_target_cpu): Do not define.
	* configure: Regenerate.

	* Makefile.in (MT_FLAGS): Remove.
	(GLOBAL_CFLAGS): Update.
	(TARGET_OBS): Substitute from configure.
	(DEPFILES): Remove TDEPFILES, add TARGET_OBS.
	(@target_makefile_frag@): Remove.

doc/ChangeLog:

	* Makefile.in (Makefile): Do not depend on target_makefile_frag.

testsuite/ChangeLog:

	* Makefile.in (Makefile): Do not depend on target_makefile_frag.
	(target_cpu): Remove.
2007-11-17 00:54:18 +00:00
Ulrich Weigand 9b624dbeed * config/arm/embed.mt (SIM_OBS, SIM): Remove.
* config/avr/avr.mt (SIM_OBS, SIM): Remove.
	* config/frv/frv.mt (SIM_OBS, SIM): Remove.
	* config/h8300/h8300.mt (SIM_OBS, SIM): Remove.
	* config/iq2000/iq2000.mt (SIM_OBS, SIM): Remove.
	* config/m32c/m32c.mt (SIM_OBS, SIM): Remove.
	* config/m32r/linux.mt (SIM_OBS, SIM): Remove.
	* config/m32r/m32r.mt (SIM_OBS, SIM): Remove.
	* config/m68hc11/m68hc11.mt (SIM_OBS, SIM): Remove.
	* config/mips/embed.mt (SIM_OBS, SIM): Remove.
	* config/mips/linux.mt (SIM_OBS, SIM): Remove.
	* config/mips/nbsd.mt (SIM_OBS, SIM): Remove.
	* config/mn10300/mn10300.mt (SIM_OBS, SIM): Remove.
	* config/powerpc/linux.mt (SIM_OBS, SIM): Remove.
	* config/powerpc/nbsd.mt (SIM_OBS, SIM): Remove.
	* config/powerpc/ppc-sim.mt: Remove file.
	* config/sh/embed.mt (SIM_OBS, SIM): Remove.
	* config/sh/linux.mt (SIM_OBS, SIM): Remove.
	* config/sh/nbsd.mt (SIM_OBS, SIM): Remove.
	* config/sh/sh64.mt (SIM_OBS, SIM): Remove.
	* config/sparc/embed.mt (SIM_OBS, SIM): Remove.
	* config/v850/v850.mt (SIM_OBS, SIM): Remove.
	* config/xstormy16/xstormy16.mt (SIM_OBS, SIM): Remove.

	* configure.tgt (gdb_sim): Document variable.
	(arm*-*-* | thumb*-*-* | strongarm*-*-* | xscale-*-*): Set it.
	(avr-*-*): Likewise.
	(frv-*-*): Likewise.
	(h8300-*-*): Likewise.
	(iq2000-*-*): Likewise.
	(m32c-*-*): Likewise.
	(m32r*-*-linux*): Likewise.
	(m32r*-*-*): Likewise.
	(m68hc11*-*-*|m6811*-*-*): Likewise.
	(mips*-*-*): Likewise.
	(mips*-*-linux*): Likewise.
	(mips*-*-netbsd* | mips*-*-knetbsd*-gnu): Likewise.
	(mn10300-*-*): Likewise.
	(powerpc-*-linux* | powerpc64-*-linux*): Likewise.
	(powerpc-*-netbsd* | powerpc-*-knetbsd*-gnu): Likewise.
	(powerpc*-*-*): Use ppc-eabi target.  Conditionally set gdb_sim.
	(sh*): Set gdb_sim.
	(sh-*-linux*): Likewise.
	(sh*-*-netbsdelf* | sh*-*-knetbsd*-gnu): Likewise.
	(sh64-*-elf*): Likewise.
	(sparc-*-rtems*): Likewise.
	(v850*-*-elf): Likewise.
	(xstormy16-*-*): Likewise.

	* configure.ac (IGNORE_SIM, IGNORE_SIM_OBS): Do not set.
	(SIM, SIM_OBS): Set depending on ${ignore_sim} and ${gdb_sim}.
	* configure: Regenerate.
	* Makefile.in (SIM, SIM_OBS): Substitute from configure.
	(@IGNORE_SIM@, @IGNORE_SIM_OBS@): Remove.
2007-11-17 00:44:38 +00:00
Ulrich Weigand db985757a9 * configure.ac (hostfile, targetfile): Remove.
(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.
2007-11-17 00:41:17 +00:00
Vladimir Prus d6e956e5c2 Prevent clear_command from directly modifying breakpoint list.
* 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.
2007-11-15 06:28:19 +00:00
Daniel Jacobowitz 55eddb0f7a * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Check the selected
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.
2007-10-30 19:35:35 +00:00
Thiago Jung Bauermann 9b913628cf 2007-10-25 Wu Zhou <woodzltc@cn.ibm.com>
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.
2007-10-25 17:52:32 +00:00
Maciej W. Rozycki ad84214454 PR exp/1926
* 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).
2007-10-25 11:30:55 +00:00
Ulrich Weigand 8d00578918 * solib-svr4.c (legacy_svr4_fetch_link_map_offsets_hook): Remove.
(solib_svr4_init): Initialize fetch_link_map_offsets to NULL.
	* solib-svr4.h (legacy_svr4_fetch_link_map_offsets_hook): Remove.
	* solib-legacy.c: Remove file.

	* config/alpha/alpha-linux.mt (TDEPFILES): Remove solib-legacy.o.
	* config/arm/linux.mt (TDEPFILES): Likewise.
	* config/i386/i386gnu.mh (NATDEPFILES): Likewise.
	* config/ia64/linux.mt (TDEPFILES): Likewise.
	* config/m32r/linux.mt (TDEPFILES): Likewise.
	* config/powerpc/linux.mt (TDEPFILES): Likewise.
	* config/s390/s390.mt (TDEPFILES): Likewise.

	* alpha-linux-tdep.c (alpha_linux_init_abi): Call
	set_solib_svr4_fetch_link_map_offsets.
	* i386gnu-tdep.c (i386gnu_init_abi): Likewise.
	* ia64-linux-tdep.c (ia64_linux_init_abi): Likewise.

	* i386gnu-tdep.c: Include "solib-svr4.h".
	* Makefile.in: Update dependencies.
2007-10-24 21:21:16 +00:00