Commit Graph

796 Commits

Author SHA1 Message Date
Yao Qi 7255706c3e gdb/gdbserver/
PR remote/14161.

	* server.h: Declare gdb_agent_about_to_close.
	* target.c (kill_inferior): Include "agent.h".
	New.  Send command 'kill'.
	* target.h (kill_inferior): Removed macro.
	* tracepoint.c (gdb_agent_about_to_close): New.
	(gdb_agent_helper_thread): Handle command 'close'.
	Wait endlessly until the inferior stops.
	Install gdb_agent_remove_socket to atexit hook.
	(agent_socket_name): New static variable.
	(gdb_agent_socket_init): Replace local variable 'name' with
	'agent_socket_name'.
	(gdb_agent_remove_socket): New.

gdb/doc/
	* gdb.texinfo (IPA Protocol Commands): Document new command
	'close'.

gdb/testsuite/
	KFAIL for PR remote/14161.
	* gdb.trace/strace.exp (strace_remove_socket): kfail for native.
	Cleanup socket files.
	(strace_info_marker): Detach inferior.
2012-07-27 08:09:14 +00:00
Yao Qi 5a3f286f45 gdb/gdbserver/
* server.c (process_point_options): Stop at 'X' when parsing.
2012-07-27 00:56:32 +00:00
Michael Eager 961bd387ba 2012-07-19 Michael Eager <eager@eagercon.com>
* i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
	to hw_execute.
	* linux-x86-low.c (x86_insert_point, x86_remove_point):
	Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
	hardware breakpoint.
2012-07-19 18:27:17 +00:00
Jan Kratochvil aa7c744796 gdb/
* common/linux-ptrace.c: Include gdb_assert.h.
	<__i386__> (linux_ptrace_test_ret_to_nx_instr): New declaration.
	<__i386__>: Include sys/reg.h, sys/mman.h, signal.h, sys/wait.h and
	stdint.h.
	(linux_ptrace_test_ret_to_nx, linux_ptrace_init_warnings): New
	functions.
	* common/linux-ptrace.h (linux_ptrace_init_warnings): New declarations.
	* linux-nat.c (linux_child_post_attach)
	(linux_child_post_startup_inferior): Call linux_ptrace_init_warnings.

gdb/gdbserver/
	* gdbserver/linux-low.c (initialize_low): Call
	linux_ptrace_init_warnings.
2012-07-07 12:13:57 +00:00
Doug Evans 657c4e8cc6 (gdb_no_commands_at_breakpoint): Tweak previous patch for win64 where
sizeof (long) < sizeof (void*).
2012-07-02 17:37:35 +00:00
Doug Evans 7f216e7c7c * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
pointer to int.
2012-07-02 17:11:36 +00:00
Stan Shebs d3ce09f5bf Add target-side support for dynamic printf.
* NEWS: Mention the additional style.
	* breakpoint.h (struct bp_target_info): New fields tcommands, persist.
	(struct bp_location): New field cmd_bytecode.
	* breakpoint.c: Include format.h.
	(disconnected_dprintf): New global.
	(parse_cmd_to_aexpr): New function.
	(build_target_command_list): New function.
	(insert_bp_location): Call it.
	(remove_breakpoints_pid): Skip dprintf breakpoints.
	(print_one_breakpoint_location): Ditto.
	(dprintf_style_agent): New global.
	(dprintf_style_enums): Add dprintf_style_agent.
	(update_dprintf_command_list): Add agent case.
	(agent_printf_command): New function.
	(_initialize_breakpoint): Add new commands.
	* common/ax.def (printf): New bytecode.
	* ax.h (ax_string): Declare.
	* ax-gdb.h (gen_printf): Declare.
	* ax-gdb.c: Include cli-utils.h, format.h.
	(gen_printf): New function.
	(maint_agent_print_command): New function.
	(_initialize_ax_gdb): Add maint agent-printf command.
	* ax-general.c (ax_string): New function.
	(ax_print): Add printf disassembly.
	* Makefile.in (SFILES): Add format.c
	(COMMON_OBS): Add format.o.
	* common/format.h: New file.
	* common/format.c: New file.
	* printcmd.c: Include format.h.
	(ui_printf): Call parse_format_string.
	* remote.c (remote_state): New field breakpoint_commands.
	(PACKET_BreakpointCommands): New enum.
	(remote_breakpoint_commands_feature): New function.
	(remote_protocol_features): Add new BreakpointCommands entry.
	(remote_can_run_breakpoint_commands): New function.
	(remote_add_target_side_commands): New function.
	(remote_insert_breakpoint): Call it.
	(remote_insert_hw_breakpoint): Ditto.
	(_initialize_remote): Add new packet configuration for
	target-side breakpoint commands.
	* target.h (struct target_ops): New field
	to_can_run_breakpoint_commands.
	(target_can_run_breakpoint_commands): New macro.
	* target.c (update_current_target): Handle
	to_can_run_breakpoint_commands.

	[gdbserver]
	* Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
	(ax.o): Add it to build rule.
	(ax-ipa.o): Ditto.
	(OBS): Add format.o.
	(IPA_OBS): Add format.o.
	* server.c (handle_query): Claim support for breakpoint commands.
	(process_point_options): Add command case.
	(process_serial_event): Leave running if there are printfs in
	effect.
	* mem-break.h (any_persistent_commands): Declare.
	(add_breakpoint_commands): Declare.
	(gdb_no_commands_at_breakpoint): Declare.
	(run_breakpoint_commands): Declare.
	* mem-break.c (struct point_command_list): New struct.
	(struct breakpoint): New field command_list.
	(any_persistent_commands): New function.
	(add_commands_to_breakpoint): New function.
	(add_breakpoint_commands): New function.
	(gdb_no_commands_at_breakpoint): New function.
	(run_breakpoint_commands): New function.
	* linux-low.c (linux_wait_1): Test for and run breakpoint commands
	locally.
	* ax.c: Include format.h.
	(ax_printf): New function.
	(gdb_eval_agent_expr): Add printf opcode.

	[doc]
	* gdb.texinfo (Dynamic Printf): Mention agent style and
	disconnected dprintf.
	(Maintenance Commands): Describe maint agent-printf.
	(General Query Packets): Mention BreakpointCommands feature.
	(Packets): Document commands extension to Z0 packet.
	* agentexpr.texi (Bytecode Descriptions): Document printf
	bytecode.

	[testsuite]
	* gdb.base/dprintf.exp: Add agent style tests.
2012-07-02 15:29:39 +00:00
Yao Qi 2f8f6aed0e gdb/gdbserver:
* server.c (start_inferior): Remove duplicated writes to fields
	'last_resume_kind' and 'last_status' of 'current_inferior'.
2012-06-13 02:35:01 +00:00
Yao Qi 0c9070b30a gdb/gdbserver:
* linux-low.c (linux_set_resume_request): Simplify predicate.  Add
        comment.
        * server.c (handle_v_cont): Extend comment.
2012-06-12 14:02:15 +00:00
Yao Qi c52daf705d gdb/gdbserver:
* linux-low.c (linux_attach): Add 'static'.
2012-06-11 07:24:15 +00:00
Yao Qi d38bbb0a50 gdb/gdbserver/
* ax.c (gdb_eval_agent_expr): Print `top' in hex.
2012-06-06 08:31:31 +00:00
Jan Kratochvil 89dc0afdc9 gdb/gdbserver/
Fix gcc -flto compilation warning.
	* server.c (main): Make variable multi_mode and attach volatile.
2012-06-01 16:50:11 +00:00
Thiago Jung Bauermann 75f62ce7b7 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
if the platform doesn't know about it.
2012-05-30 19:51:38 +00:00
Pedro Alves 65f479b6ef 2012-05-30 Jeff Kenton <jkenton@tilera.com>
* Makefile.in (SFILES): Add linux-tile-low.c.
	(linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
	* configure.srv: Handle tilegx-*-linux*.
	* linux-tile-low.c: New file.
2012-05-30 19:43:15 +00:00
Jan Kratochvil 0c5bf5a97d gdb/
* solib-svr4.c (svr4_current_sos): New comment on
	svr4_current_sos_via_xfer_libraries fall back.

gdb/gdbserver/
	* linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.

gdb/testsuite/
	* gdb.server/solib-list-lib.c: New file.
	* gdb.server/solib-list-main.c: New file.
	* gdb.server/solib-list.exp: New file.
2012-05-28 20:37:29 +00:00
Pedro Alves a493e3e2e4 gdb/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

gdb/gdbserver/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

include/gdb/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        * gdb/signals.def: Replace TARGET_SIGNAL_ with GDB_SIGNAL_
	throughout.

sim/arm/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

sim/avr/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

sim/common/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

sim/cr16/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

sim/d10v/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

sim/erc32/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

sim/m32c/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

sim/ppc/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

sim/rl78/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.

sim/rx/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

        Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
2012-05-24 16:51:47 +00:00
Pedro Alves 2ea286498f gdb/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

	Replace target_signal with gdb_signal throughout.

gdb/gdbserver/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

	Replace target_signal with gdb_signal throughout.

include/gdb/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

	Replace target_signal with gdb_signal throughout.

sim/common/
2012-05-24  Pedro Alves  <palves@redhat.com>

	PR gdb/7205

	Replace target_signal with gdb_signal throughout.
2012-05-24 16:39:15 +00:00
Maciej W. Rozycki 8d409d16dd * linux-low.c (linux_store_registers): Avoid the copying sequence
when no data has been retrieved by ptrace.
2012-05-22 23:17:51 +00:00
Matthew Gretton-Dann 23512c015e 2012-05-22 Will Deacon <will.deacon@arm.com>
* linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
	Include asm/ptrace.h.
	(PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
	already defined.
2012-05-22 13:50:50 +00:00
Maciej W. Rozycki 4934b29e91 * linux-low.c (linux_store_registers): Don't re-retrieve data
with ptrace that has already been obtained from /proc.  Always
	copy any data retrieved with ptrace to the buffer supplied.
2012-05-21 23:50:25 +00:00
Pedro Alves bde24c0a34 2012-05-11 Yao Qi <yao@codesourcery.com>
Pedro Alves  <palves@redhat.com>

	* linux-low.c (enum stopping_threads_kind): New.
	(stopping_threads): Change type to `enum stopping_threads_kind'.
	(handle_extended_wait): If stopping and suspending threads, leave
	the new_lwp suspended too.
	(linux_wait_for_event): Adjust.
	(stop_all_lwps): Set `stopping_threads' to
	STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
	whether we're suspending threads or just stopping them.  Assert no
	recursion happens.
2012-05-11 13:34:34 +00:00
Yao Qi 623b6bdf12 gdb/gdbserver:
* server.h: Move some code to ...
	* gdbthread.h: ... here.  New.
	* Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
	(remote-utils.o, server.o, target.o tracepoint.o): Likewise.
	(nto-low.o, win32-low.o): Likewise.
	* inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
	* regcache.c, remote-utils.c, server.c: Likewise.
	* target.c, tracepoint.c, win32-low.c: Likewise.
2012-04-29 06:28:30 +00:00
Thiago Jung Bauermann f15f99484e * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
(PTRACE_ARG4_TYPE): Likewise.
	(PTRACE_XFER_TYPE): Likewise.
	* linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
	ptrace to PTRACE_ARG3_TYPE.
	* linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
	(PTRACE_ARG4_TYPE): Likewise.
	(PTRACE_XFER_TYPE): Likewise.
	(linux_detach_one_lwp): Cast fourth argument of
	ptrace to long then PTRACE_ARG4_TYPE.
	(regsets_fetch_inferior_registers): Cast third argument of
	ptrace to long then PTRACE_ARG3_TYPE.
	(regsets_store_inferior_registers): Likewise.
2012-04-24 15:03:43 +00:00
Pedro Alves 38ea300a20 2012-04-20 Pedro Alves <palves@redhat.com>
gdb/
	* acx_configure_dir.m4 (ACX_CONFIGURE_DIR): Handle absolute
	$srcdir.
	* configure: Regenerate.

	gdb/gdbserver/
	* configure: Regenerate.
2012-04-20 17:58:49 +00:00
Pedro Alves c971b7fa72 2012-04-19 Pedro Alves <palves@redhat.com>
gdb/
	* Makefile.in (GNULIB_BUILDDIR): New.
	(LIBGNU, INCGNU, GNULIB_H): Adjust.
	(SUBDIRS): Add $(GNULIB_BUILDDIR).
	(CLEANDIRS). Remove gnulib/import.
	(REQUIRED_SUBDIRS): Replace gnulib/import with $(GNULIB_BUILDDIR).
	(all-lib): Ditto.
	(distclean): Remove the $(GNULIB_BUILDDIR) directory.
	(gnulib/import/Makefile): Replace gnulib/import with
	$(GNULIB_BUILDDIR).  Set CONFIG_FILES to just Makefile.
	(ACLOCAL_AMFLAGS): Remove '-I gnulib/import/m4'.
	(aclocal_m4_deps): Remove the gnulib dependencies.  Add
	acx_configure_dir.m4.
	* acinclude.m4: Include acx_configure_dir.m4.
	* acx_configure_dir.m4: New file.
	* aclocal.m4: Regenerate.
        * configure.ac: Remove gl_EARLY, gl_INIT and AM_INIT_AUTOMAKE
        calls.  Configure gnulib using ACX_CONFIGURE_DIR.
        (GNULIB): New variable.
        (GNULIB_STDINT_H): Adjust.
        (AC_OUTPUT): Don't output gnulib/Makefile.
        * gdb/defs.h: Include build-gnulib/config.h.
        * aclocal.m4: Regenerate.
        * config.in: Regenerate.
        * configure: Regenerate.

        * gnulib/Makefile.in: New file.
        * gnulib/configure.ac: New file.
        * gnulib/aclocal.m4: New file.
        * gnulib/config.in: New file.
        * gnulib/configure: New file.
	* gnulib/: Re-run gnulib-tool to adjust.

        gdb/gdbserver/
        * Makefile.in (GNULIB_BUILDDIR): New.
	(LIBGNU, INCGNU, GNULIB_H): Adjust.
        (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
        (all, install-only, uninstall, clean-info, all-lib, clean): No
        longer pass GNULIB_FLAGS_TO_PASS.  Use subdir_do.
        (maintainer-clean realclean distclean): Use subdir_do.
        (subdir_do): New.
        (gnulib/import/Makefile): Adjust.  Replace gnulib/import with
	$(GNULIB_BUILDDIR).  Don't pass argument to config.status.
        * acinclude.m4: Include acx_configure_dir.m4.
        * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
        calls.  Call AC_PROG_RANLIB.  Configure gnulib using
        ACX_CONFIGURE_DIR.
        (GNULIB): New.
        (GNULIB_STDINT_H): Adjust.
        (AC_OUTPUT): Don't output gnulib/Makefile anymore.
        * gdbreplay.c: Include build-gnulib/config.h.
        * server.h: Likewise.
        * aclocal.m4: Regenerate.
        * config.in: Regenerate.
        * configure: Regenerate.
2012-04-19 19:34:52 +00:00
Pedro Alves 809277f8ce 2012-04-19 Pedro Alves <palves@redhat.com>
gdb/
	* gnulib/: Move whole directory ...
	* gnulib/import/: ... here, and re-rerun gnulib-tool to adjust.
	* Makefile.in (LIBGNU, INCGNU, GNULIB_H, CLEANDIRS)
	(REQUIRED_SUBDIRS, all-lib, gnulib/Makefile, ACLOCAL_AMFLAGS)
	(aclocal_m4_deps): Adjust.
	* aclocal.m4: Regenerate.
	* configure: Regenerate.
	* configure.ac: Adjust AC_OUTPUT output.

	gdbserver/
	* Makefile.in (LIBGNU, INCGNU): Adjust.
	(GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
	(all, install-only, uninstall, clean-info, all-lib, clean)
	(maintainer-clean, Makefile, gnulib/Makefile): Adjust.
	* configure.ac: Adjust AC_OUTPUT output.
	* aclocal.m4: Regenerate.
	* configure: Regenerate.
2012-04-19 15:27:52 +00:00
Pedro Alves fd9bb8b878 2012-04-19 Pedro Alves <palves@redhat.com>
* Makefile.in (generated_files): New.
	(server_h): Remove the explicit dependency on config.h, and depend
	on $generated_files.
2012-04-19 13:26:25 +00:00
Pedro Alves 1c298c6671 2012-04-19 Pedro Alves <palves@redhat.com>
* Makefile.in (INCGNU): Add -Ignulib.
2012-04-19 12:10:06 +00:00
Pedro Alves 57c4b50b88 2012-04-19 Pedro Alves <palves@redhat.com>
* Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
	(INCGNU): ... this, and spell out -I here.
	(GNULIB_LIB): Rename to ...
	(LIBGNU): ... this.
	(INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
2012-04-19 12:02:56 +00:00
Pedro Alves 1030e047aa 2012-04-19 Pedro Alves <palves@redhat.com>
* config.in: Regenerate.
2012-04-19 11:58:57 +00:00
Pedro Alves 71622373ce Move entries to right place. Drop config.in entry, as I forgot to
actually do what it says.
2012-04-19 11:57:39 +00:00
Pedro Alves 447d431953 2012-04-19 Pedro Alves <palves@redhat.com>
* configure.ac: Remove AC_CHECK_DECLS check for memmem.
	* server.h (memmem): Remove declaration.
	* config.in: Regenerate.
	* configure: Regenerate.
2012-04-19 10:23:03 +00:00
Yao Qi aad9eab9f2 gdb:
* Makefile.in (SFILES): Add common/vec.c and remove vec.c.
        (vec.o): New rule.
        * vec.c: Move it ...
        * common/vec.c: ... here.
        * vec.h: Move it ...
        * common/vec.h: ... here.

gdb/gdbserver:

        * Makefile.in (SFILES): Add common/vec.c.
        (OBS): Add vec.o.
        (vec.o): New rule.
2012-04-19 05:58:52 +00:00
Yao Qi 3e10640f3c gdb/gdbserver/
* remote-utils.c (prepare_resume_reply): Replace with macro
	target_core_of_thread.
	* server.c (handle_qxfer_threads_proper): Likewise.
	* target.h (traget_core_of_thread): New macro.
2012-04-19 05:05:11 +00:00
Pedro Alves 770d76d7b2 2012-04-18 Pedro Alves <palves@redhat.com>
Update gnulib from latest git.
	(639ea5ae15e39fe48d43e04864b2997301e4b969)

	* gnulib/Makefile.am: Update.
	* gnulib/dummy.c: Update.
	* gnulib/extra/arg-nonnull.h: Update.
	* gnulib/extra/c++defs.h: Update.
	* gnulib/extra/update-copyright: Update.
	* gnulib/extra/warn-on-use.h: Update.
	* gnulib/inttypes.in.h: Update.
	* gnulib/m4/00gnulib.m4: Update.
	* gnulib/m4/extensions.m4: Update.
	* gnulib/m4/gnulib-cache.m4: Update.
	* gnulib/m4/gnulib-common.m4: Update.
	* gnulib/m4/gnulib-comp.m4: Update.
	* gnulib/m4/gnulib-tool.m4: Update.
	* gnulib/m4/include_next.m4: Update.
	* gnulib/m4/inttypes-pri.m4: Update.
	* gnulib/m4/inttypes.m4: Update.
	* gnulib/m4/longlong.m4: Update.
	* gnulib/m4/memchr.m4: Update.
	* gnulib/m4/memmem.m4: Update.
	* gnulib/m4/mmap-anon.m4: Update.
	* gnulib/m4/multiarch.m4: Update.
	* gnulib/m4/onceonly.m4: Update.
	* gnulib/m4/stddef_h.m4: Update.
	* gnulib/m4/stdint.m4: Update.
	* gnulib/m4/string_h.m4: Update.
	* gnulib/m4/warn-on-use.m4: Update.
	* gnulib/m4/wchar_h.m4: Update.
	* gnulib/m4/wchar_t.m4: Update.
	* gnulib/m4/wint_t.m4: Update.
	* gnulib/memchr.c: Update.
	* gnulib/memmem.c: Update.
	* gnulib/stddef.in.h: Update.
	* gnulib/stdint.in.h: Update.
	* gnulib/str-two-way.h: Update.
	* gnulib/string.in.h: Update.
	* gnulib/wchar.in.h: Update.

	* gnulib/extra/arg-nonnull.h: Delete.
	* gnulib/extra/c++defs.h: Delete.
	* gnulib/extra/warn-on-use.h: Delete.
	* gnulib/m4/wchar_h.m4: Delete.
	* gnulib/m4/wint_t.m4: Delete.
	* gnulib/wchar.in.h: Delete.

	* gnulib/extra/snippets/arg-nonnull.h: New.
	* gnulib/extra/snippets/c++defs.h: New.
	* gnulib/extra/snippets/warn-on-use.h: New.

	* aclocal.m4: Regenerate.
	* config.in: Regenerate.
	* configure: Regenerate.
	* gnulib/Makefile.in: Regenerate.

	* gdbserver/aclocal.m4: Regenerate.
	* gdbserver/config.in: Regenerate.
	* gdbserver/configure: Regenerate.
2012-04-18 20:45:25 +00:00
Yao Qi 80d269391b gdb/gdbserver/
* tracepoint.c (cmd_qtstart): Download tracepoints even when they are
	duplicated on address.
2012-04-16 15:38:53 +00:00
Yao Qi 42476b702c gdb/
* common/agent.c (agent_run_command): Add one more parameter `len'.
	Update callers.
	* common/agent.h: Update declaration.
	* linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
	Update.
	(linux_child_static_tracepoint_markers_by_strid): Ditto.

gdb/gdbserver/

	* tracepoint.c (COPY_FIELD_TO_BUF): New macro.
	(struct tracepoint_action_ops) <send>: New field.
	(m_tracepoint_action_send, r_tracepoint_action_send): New.
	(agent_expr_send, x_tracepoint_action_send): New.
	(l_tracepoint_action_send): New.
	(cmd_qtdp): Download and install tracepoint
	according to `use_agent'.
	(run_inferior_command): Add one more parameter `len'.
	Update callers.
	(tracepoint_send_agent): New.
	(cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
2012-04-16 11:24:47 +00:00
Yao Qi 7bc8363907 gdb/gdbserver/
* tracepoint.c (download_tracepoints): Moved to ...
	(cmd_qtstart): ... here.
2012-04-16 11:16:30 +00:00
Yao Qi 5f18041e78 gdb/gdbserver/
* tracepoint.c: Include inttypes.h.
	(struct collect_memory_action): Use sized types.
	(struct tracepoint): Likewise.
	(cmd_qtdp, stop_tracing): Update print specifiers.
	(cmd_qtp, response_tracepoint): Likewise.
	(collect_data_at_tracepoint): Likewise.
	(collect_data_at_step): Likewise.
2012-04-14 05:36:24 +00:00
Yao Qi 55a8c0761d gdb/
Import gnulib module inttypes from git
	(250b80067c1e1d8faa0c42fb572f721975b929c5)
	* Makefile.in (HFILES_NO_SRCDIR): Add gnulib/inttypes.in.h.
	(aclocal_m4_deps): Add gnulib/m4/inttypes.m4 and gnulib/m4/inttypes-pri.m4
	* aclocal.m4, config.in, configure: Regenerated.
	* gnulib/Makefile.am: Update.
	* gnulib/Makefile.in: Update.
	* gnulib/m4/gnulib-cache.m4: Update.
	* gnulib/m4/gnulib-comp.m4: Update.
	* gnulib/inttypes.in.h: New.
	* gnulib/m4/inttypes-pri.m4: New.
 	* gnulib/m4/inttypes.m4: New.

gdb/gdbserver/
	Import gnulib module inttypes.
	* aclocal.m4, config.in, configure: Regenerated.
2012-04-14 05:24:57 +00:00
Yao Qi dc750257de gdb/gdbserver/
* Makefile.in (maintainer-clean, realclean, distclean): Remove
	Makefile and config.status at last.
2012-04-14 04:14:04 +00:00
Yao Qi 0ab5faf998 gdb/gdbserver/
* tracepoint.c: Include stdint.h unconditionally.
2012-04-14 04:10:04 +00:00
Thiago Jung Bauermann 18f5fd8146 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
on BFD_HAVE_SYS_PROCFS_TYPE.
	* configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
	* configure: Regenerate.
	* config.in: Likewise.
2012-04-13 19:56:05 +00:00
H.J. Lu 4d47af5cf2 Enable x32 support in gdbserver
* Makefile.in (clean): Also remove x32.c x32-linux.c
	x32-avx.c x32-avx-linux.c.
	(x32.o): New target.
	(x32.c): Likewise.
	(x32-linux.o): Likewise.
	(x32-linux.c): Likewise.
	(x32-avx.o): Likewise.
	(x32-avx.c): Likewise.
	(x32-avx-linux.o): Likewise.
	(x32-avx-linux.c): Likewise.

	* configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
	(srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
	(srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
	(srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
	(srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
	i386/x32-avx-linux.xml.

	* linux-x86-low.c (init_registers_x32_linux): New prototype.
	(init_registers_x32_avx_linux): Likwise.
	(x86_linux_update_xmltarget): Call init_registers_x32_linux
	or init_registers_x32_avx_linux if linux_is_elf64 is false.
2012-04-13 14:39:41 +00:00
Pedro Alves ecedbe5852 2012-04-13 Pedro Alves <palves@redhat.com>
* Makefile.in (GNULIB_FLAGS_TO_PASS): New.
	(FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
	(all, uninstall, clean-info, all-lib, clean, maintainer-clean)
	(realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
	the sub-make.
2012-04-13 13:12:33 +00:00
H.J. Lu c92b51775c Convert siginfo for x32 in gdbserver
* linux-x86-low.c (compat_x32_clock_t): New.
	(compat_x32_siginfo_t): Likewise.
	(compat_x32_siginfo_from_siginfo): Likewise.
	(siginfo_from_compat_x32_siginfo): Likewise.
	(linux_is_elf64): Likewise.
	(x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
	and siginfo_from_compat_x32_siginfo for x32.
	(x86_arch_setup): Set linux_is_elf64.
2012-04-12 21:06:12 +00:00
H.J. Lu 214d508ee1 Check if GDBserver is compatible with process
PR gdb/13969
	* linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
	e_machine field.
	(linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
	* linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
	* linux-x86-low.c (x86_arch_setup): Check if GDBserver is
	compatible with process.
2012-04-12 15:35:32 +00:00
Yao Qi c9a1864ab2 gdb/gdbserver/
* Makefile.in: Define abs_top_srcdir and abs_srcdir.
	(INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
	(install-only, install-info, clean): Handle sub dir gnulib.
	(all-lib, am--refresh): New targets.
	(memmem.o): Remove target.
	* configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
	Invoke gl_EARLY.  Invoke AC_CHECK_PROGS for make.
	(AC_REPLACE_FUNCS): Remove memmem.
	Invoke gl_INIT and AM_INIT_AUTOMAKE.
	(AC_OUTPUT): Generate Makefile in gnulib/.
	* aclocal.m4, config.in, configure: Regenerated.
2012-04-12 11:11:01 +00:00
Maciej W. Rozycki 367ba2c262 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP. 2012-04-10 22:33:13 +00:00
Pedro Alves 9d236627e7 2012-04-05 Pedro Alves <palves@redhat.com>
-Werror=strict-aliasing

	* spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
	pointer.
2012-04-05 11:20:50 +00:00