631 lines
23 KiB
Diff
631 lines
23 KiB
Diff
Index: valgrind/coregrind/m_gdbserver/m_gdbserver.c
|
||
===================================================================
|
||
--- valgrind/coregrind/m_gdbserver/m_gdbserver.c (revision 13036)
|
||
+++ valgrind/coregrind/m_gdbserver/m_gdbserver.c (working copy)
|
||
@@ -33,6 +33,8 @@
|
||
#include "pub_core_libcproc.h"
|
||
#include "pub_core_libcprint.h"
|
||
#include "pub_core_mallocfree.h"
|
||
+#include "pub_tool_libcsetjmp.h"
|
||
+#include "pub_core_threadstate.h"
|
||
#include "pub_core_gdbserver.h"
|
||
#include "pub_core_options.h"
|
||
#include "pub_core_libcsetjmp.h"
|
||
@@ -68,7 +70,8 @@
|
||
core_reason, // gdbserver invocation by core (e.g. error encountered)
|
||
break_reason, // break encountered
|
||
watch_reason, // watchpoint detected by tool
|
||
- signal_reason} // signal encountered
|
||
+ signal_reason, // signal encountered
|
||
+ exit_reason} // process terminated
|
||
CallReason;
|
||
|
||
static char* ppCallReason(CallReason reason)
|
||
@@ -80,6 +83,7 @@
|
||
case break_reason: return "break_reason";
|
||
case watch_reason: return "watch_reason";
|
||
case signal_reason: return "signal_reason";
|
||
+ case exit_reason: return "exit_reason";
|
||
default: vg_assert (0);
|
||
}
|
||
}
|
||
@@ -641,6 +645,14 @@
|
||
VG_(getpid) (), tid, VG_(name_of_ThreadStatus)(tst->status),
|
||
tst->sched_jmpbuf_valid);
|
||
|
||
+ /* If we are about to die, then just run server_main() once to get
|
||
+ the message out and return immediately because most of the state
|
||
+ of this tid and process is about to be torn down. */
|
||
+ if (reason == exit_reason) {
|
||
+ server_main();
|
||
+ return;
|
||
+ }
|
||
+
|
||
vg_assert(VG_(is_valid_tid)(tid));
|
||
saved_pc = VG_(get_IP) (tid);
|
||
|
||
@@ -933,6 +945,29 @@
|
||
}
|
||
}
|
||
|
||
+void VG_(gdbserver_exit) (ThreadId tid, VgSchedReturnCode tids_schedretcode)
|
||
+{
|
||
+ dlog(1, "VG core calling VG_(gdbserver_exit) tid %d will exit\n", tid);
|
||
+ if (remote_connected()) {
|
||
+ /* Make sure vgdb knows we are about to die and why. */
|
||
+ if (tids_schedretcode == VgSrc_ExitThread
|
||
+ || tids_schedretcode == VgSrc_ExitProcess) {
|
||
+ gdbserver_process_exit ('W', VG_(threads)[tid].os_state.exitcode);
|
||
+ call_gdbserver (tid, exit_reason);
|
||
+ }
|
||
+
|
||
+ if (tids_schedretcode == VgSrc_FatalSig) {
|
||
+ gdbserver_process_exit ('X', VG_(threads)[tid].os_state.fatalsig);
|
||
+ call_gdbserver (tid, exit_reason);
|
||
+ }
|
||
+ } else {
|
||
+ dlog(1, "not connected\n");
|
||
+ }
|
||
+
|
||
+ /* Tear down the connection if it still exists. */
|
||
+ VG_(gdbserver) (0);
|
||
+}
|
||
+
|
||
// Check if single_stepping or if there is a break requested at iaddr.
|
||
// If yes, call debugger
|
||
VG_REGPARM(1)
|
||
Index: valgrind/coregrind/m_gdbserver/server.c
|
||
===================================================================
|
||
--- valgrind/coregrind/m_gdbserver/server.c (revision 13036)
|
||
+++ valgrind/coregrind/m_gdbserver/server.c (working copy)
|
||
@@ -765,6 +765,13 @@
|
||
putpkt (own_buf);
|
||
}
|
||
|
||
+ /* If we our status is terminal (exit or fatal signal) get out
|
||
+ as quickly as we can. We won't be able to handle any request
|
||
+ anymore. */
|
||
+ if (status == 'W' || status == 'X') {
|
||
+ return;
|
||
+ }
|
||
+
|
||
packet_len = getpkt (own_buf);
|
||
if (packet_len <= 0)
|
||
break;
|
||
Index: valgrind/coregrind/m_gdbserver/server.h
|
||
===================================================================
|
||
--- valgrind/coregrind/m_gdbserver/server.h (revision 13036)
|
||
+++ valgrind/coregrind/m_gdbserver/server.h (working copy)
|
||
@@ -40,9 +40,9 @@
|
||
#include "pub_tool_libcassert.h"
|
||
#include "pub_tool_libcbase.h"
|
||
#include "pub_tool_options.h"
|
||
-#include "pub_core_gdbserver.h"
|
||
#include "pub_tool_libcsetjmp.h"
|
||
#include "pub_core_threadstate.h"
|
||
+#include "pub_core_gdbserver.h"
|
||
#include "pub_core_aspacemgr.h"
|
||
#include "pub_tool_vki.h"
|
||
#include "valgrind.h"
|
||
@@ -208,6 +208,9 @@
|
||
to ignore the signal, so signal can be delivered to the guest. */
|
||
extern Bool gdbserver_deliver_signal (Int vki_sigNo);
|
||
|
||
+/* Called when a process is about to go with reason ('W' or 'X') and code. */
|
||
+extern void gdbserver_process_exit (unsigned char status, Int code);
|
||
+
|
||
/* To optimise signal handling, gdb can instruct gdbserver to
|
||
not stop on some signals. In the below, a 1 indicates the gdb_nr signal
|
||
has to be passed directly to the guest, without asking gdb.
|
||
Index: valgrind/coregrind/m_gdbserver/target.c
|
||
===================================================================
|
||
--- valgrind/coregrind/m_gdbserver/target.c (revision 13036)
|
||
+++ valgrind/coregrind/m_gdbserver/target.c (working copy)
|
||
@@ -165,6 +165,14 @@
|
||
return vki_sigNo == vki_signal_to_deliver;
|
||
}
|
||
|
||
+static unsigned char exit_status_to_report;
|
||
+static int exit_code_to_report;
|
||
+void gdbserver_process_exit (unsigned char status, Int code)
|
||
+{
|
||
+ exit_status_to_report = status;
|
||
+ exit_code_to_report = code;
|
||
+}
|
||
+
|
||
static
|
||
char* sym (Addr addr)
|
||
{
|
||
@@ -248,6 +256,7 @@
|
||
unsigned long wptid;
|
||
ThreadState *tst;
|
||
enum target_signal sig;
|
||
+ int code;
|
||
|
||
pid = VG_(getpid) ();
|
||
dlog(1, "enter valgrind_wait pid %d\n", pid);
|
||
@@ -255,6 +264,24 @@
|
||
regcache_invalidate();
|
||
valgrind_update_threads(pid);
|
||
|
||
+ /* First see if we are done with this process. */
|
||
+ if (exit_status_to_report != 0) {
|
||
+ *ourstatus = exit_status_to_report;
|
||
+ exit_status_to_report = 0;
|
||
+
|
||
+ if (*ourstatus == 'W') {
|
||
+ code = exit_code_to_report;
|
||
+ exit_code_to_report = 0;
|
||
+ return code;
|
||
+ }
|
||
+
|
||
+ if (*ourstatus == 'X') {
|
||
+ sig = target_signal_from_host(exit_code_to_report);
|
||
+ exit_code_to_report = 0;
|
||
+ return sig;
|
||
+ }
|
||
+ }
|
||
+
|
||
/* in valgrind, we consider that a wait always succeeds with STOPPED 'T'
|
||
and with a signal TRAP (i.e. a breakpoint), unless there is
|
||
a signal to report. */
|
||
Index: valgrind/coregrind/m_libcprint.c
|
||
===================================================================
|
||
--- valgrind/coregrind/m_libcprint.c (revision 13036)
|
||
+++ valgrind/coregrind/m_libcprint.c (working copy)
|
||
@@ -31,7 +31,6 @@
|
||
#include "pub_core_basics.h"
|
||
#include "pub_core_vki.h"
|
||
#include "pub_core_debuglog.h"
|
||
-#include "pub_core_gdbserver.h"
|
||
#include "pub_core_libcbase.h"
|
||
#include "pub_core_libcassert.h"
|
||
#include "pub_core_libcfile.h" // VG_(write)(), VG_(write_socket)()
|
||
Index: valgrind/coregrind/m_main.c
|
||
===================================================================
|
||
--- valgrind/coregrind/m_main.c (revision 13036)
|
||
+++ valgrind/coregrind/m_main.c (working copy)
|
||
@@ -2543,7 +2543,7 @@
|
||
|
||
/* terminate gdbserver if ever it was started. We terminate it here so that it get
|
||
the output above if output was redirected to gdb */
|
||
- VG_(gdbserver) (0);
|
||
+ VG_(gdbserver_exit) (tid, tids_schedretcode);
|
||
|
||
/* Ok, finally exit in the os-specific way, according to the scheduler's
|
||
return code. In short, if the (last) thread exited by calling
|
||
Index: valgrind/coregrind/pub_core_gdbserver.h
|
||
===================================================================
|
||
--- valgrind/coregrind/pub_core_gdbserver.h (revision 13036)
|
||
+++ valgrind/coregrind/pub_core_gdbserver.h (working copy)
|
||
@@ -48,7 +48,10 @@
|
||
// to handle this incoming vgdb request.
|
||
extern Bool VG_(gdbserver_activity) (ThreadId tid);
|
||
|
||
+// Called by low level when the process is about to exit and why.
|
||
+void VG_(gdbserver_exit) (ThreadId, VgSchedReturnCode);
|
||
|
||
+
|
||
/* Called by low level to insert or remove a break or watch point.
|
||
Break or watch point implementation is done using help from the tool.
|
||
break point support implies some (small) specific instrumentation
|
||
Index: valgrind/gdbserver_tests/Makefile.am
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/Makefile.am (revision 13036)
|
||
+++ valgrind/gdbserver_tests/Makefile.am (working copy)
|
||
@@ -100,7 +100,22 @@
|
||
nlsigvgdb.vgtest \
|
||
nlsigvgdb.stderr.exp \
|
||
nlsigvgdb.stderrB.exp \
|
||
- nlsigvgdb.stdinB.gdb
|
||
+ nlsigvgdb.stdinB.gdb \
|
||
+ gone_abrt.stderr.exp \
|
||
+ gone_abrt.stderrB.exp \
|
||
+ gone_abrt.stdinB.gdb \
|
||
+ gone_abrt.stdoutB.exp \
|
||
+ gone_abrt.vgtest \
|
||
+ gone_exit.stderr.exp \
|
||
+ gone_exit.stderrB.exp \
|
||
+ gone_exit.stdinB.gdb \
|
||
+ gone_exit.stdoutB.exp \
|
||
+ gone_exit.vgtest \
|
||
+ gone_return.stderr.exp \
|
||
+ gone_return.stderrB.exp \
|
||
+ gone_return.stdinB.gdb \
|
||
+ gone_return.stdoutB.exp \
|
||
+ gone_return.vgtest
|
||
|
||
check_PROGRAMS = \
|
||
clean_after_fork \
|
||
@@ -109,7 +124,8 @@
|
||
sleepers \
|
||
main_pic \
|
||
t \
|
||
- watchpoints
|
||
+ watchpoints \
|
||
+ gone
|
||
|
||
AM_CFLAGS += $(AM_FLAG_M3264_PRI)
|
||
AM_CXXFLAGS += $(AM_FLAG_M3264_PRI)
|
||
Index: valgrind/gdbserver_tests/filter_gdb
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/filter_gdb (revision 13036)
|
||
+++ valgrind/gdbserver_tests/filter_gdb (working copy)
|
||
@@ -49,6 +51,8 @@
|
||
# a.o. produced by gdb 7.2 on arm (same with standard gdbserver)
|
||
# delete empty lines (the last line (only made of prompts) sometimes
|
||
# finishes with a new line, sometimes not ???).
|
||
+# 'exited with code' and 'exited normally' are printed slightly
|
||
+# differently between gdb versions, normalize to "Program exited...".
|
||
sed -e '/Remote debugging using/,/vgdb launched process attached/d' \
|
||
-e 's/^\[?1034hReading symbols/Reading symbols/' \
|
||
-e '/^Missing separate debuginfo/d' \
|
||
@@ -64,6 +68,8 @@
|
||
-e '/^Loaded symbols for .*$/d' \
|
||
-e '/^Current language.*/d' \
|
||
-e '/^The current source language is.*/d' \
|
||
+ -e 's/^.*\( exited with code [0-9]\+\).$/Program\1\./g' \
|
||
+ -e 's/^.*\( exited normally\).$/Program\1\./g' \
|
||
-e 's/(gdb) //g' \
|
||
-e 's/^>[> ]*//' \
|
||
-e '/^done\.$/d' \
|
||
Index: valgrind/gdbserver_tests/gone.c
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone.c (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone.c (working copy)
|
||
@@ -0,0 +1,33 @@
|
||
+#include <signal.h>
|
||
+#include <stdio.h>
|
||
+#include <stdlib.h>
|
||
+#include <string.h>
|
||
+#include <unistd.h>
|
||
+
|
||
+int
|
||
+main (int argc, char **argv)
|
||
+{
|
||
+ fprintf(stderr, "starting ...\n");
|
||
+
|
||
+ // Three ways of going away...
|
||
+ if (argc > 1)
|
||
+ {
|
||
+ // Explicit exit() with exit code.
|
||
+ if (strcmp (argv[1], "exit") == 0)
|
||
+ {
|
||
+ fprintf(stderr, "exiting ...\n");
|
||
+ exit (1);
|
||
+ }
|
||
+
|
||
+ // Get killed by a signal.
|
||
+ if (strcmp (argv[1], "abort") == 0)
|
||
+ {
|
||
+ fprintf(stderr, "aborting ...\n");
|
||
+ kill(getpid(), SIGABRT);
|
||
+ }
|
||
+ }
|
||
+
|
||
+ // And finally, just return from main with success.
|
||
+ fprintf(stderr, "returning ...\n");
|
||
+ return 0;
|
||
+}
|
||
Index: valgrind/gdbserver_tests/gone_abrt.stderr.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_abrt.stderr.exp (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_abrt.stderr.exp (working copy)
|
||
@@ -0,0 +1,8 @@
|
||
+Nulgrind, the minimal Valgrind tool
|
||
+
|
||
+(action at startup) vgdb me ...
|
||
+
|
||
+
|
||
+starting ...
|
||
+aborting ...
|
||
+
|
||
Index: valgrind/gdbserver_tests/gone_abrt.stderrB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_abrt.stderrB.exp (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_abrt.stderrB.exp (working copy)
|
||
@@ -0,0 +1 @@
|
||
+relaying data between gdb and process ....
|
||
Index: valgrind/gdbserver_tests/gone_abrt.stdinB.gdb
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_abrt.stdinB.gdb (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_abrt.stdinB.gdb (working copy)
|
||
@@ -0,0 +1,9 @@
|
||
+# connect gdb to Valgrind gdbserver:
|
||
+target remote | ./vgdb --wait=60 --vgdb-prefix=./vgdb-prefix-gone-abrt
|
||
+echo vgdb launched process attached\n
|
||
+
|
||
+continue
|
||
+# see process get a fatal signal
|
||
+continue
|
||
+# see program is gone
|
||
+quit
|
||
Index: valgrind/gdbserver_tests/gone_abrt.stdoutB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_abrt.stdoutB.exp (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_abrt.stdoutB.exp (working copy)
|
||
@@ -0,0 +1,7 @@
|
||
+vgdb launched process attached
|
||
+Continuing.
|
||
+Program received signal SIGABRT, Aborted.
|
||
+0x........ in syscall ...
|
||
+Continuing.
|
||
+Program terminated with signal SIGABRT, Aborted.
|
||
+The program no longer exists.
|
||
Index: valgrind/gdbserver_tests/gone_abrt.vgtest
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_abrt.vgtest (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_abrt.vgtest (working copy)
|
||
@@ -0,0 +1,12 @@
|
||
+# test that a fatal SIGABRT signal is properly passed on to gdb.
|
||
+
|
||
+prog: gone
|
||
+args: abort
|
||
+vgopts: --tool=none --vgdb=yes --vgdb-error=0 --vgdb-prefix=./vgdb-prefix-gone-abrt
|
||
+stderr_filter: filter_stderr
|
||
+prereq: test -e gdb
|
||
+progB: gdb
|
||
+argsB: --quiet -l 60 --nx ./gone
|
||
+stdinB: gone_abrt.stdinB.gdb
|
||
+stdoutB_filter: filter_gdb
|
||
+stderrB_filter: filter_gdb
|
||
Index: valgrind/gdbserver_tests/gone_exit.stderr.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_exit.stderr.exp (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_exit.stderr.exp (working copy)
|
||
@@ -0,0 +1,8 @@
|
||
+Nulgrind, the minimal Valgrind tool
|
||
+
|
||
+(action at startup) vgdb me ...
|
||
+
|
||
+
|
||
+starting ...
|
||
+exiting ...
|
||
+
|
||
Index: valgrind/gdbserver_tests/gone_exit.stderrB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_exit.stderrB.exp (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_exit.stderrB.exp (working copy)
|
||
@@ -0,0 +1 @@
|
||
+relaying data between gdb and process ....
|
||
Index: valgrind/gdbserver_tests/gone_exit.stdinB.gdb
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_exit.stdinB.gdb (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_exit.stdinB.gdb (working copy)
|
||
@@ -0,0 +1,7 @@
|
||
+# connect gdb to Valgrind gdbserver:
|
||
+target remote | ./vgdb --wait=60 --vgdb-prefix=./vgdb-prefix-gone-exit
|
||
+echo vgdb launched process attached\n
|
||
+
|
||
+continue
|
||
+# see program is gone with exit code
|
||
+quit
|
||
Index: valgrind/gdbserver_tests/gone_exit.stdoutB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_exit.stdoutB.exp (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_exit.stdoutB.exp (working copy)
|
||
@@ -0,0 +1,3 @@
|
||
+vgdb launched process attached
|
||
+Continuing.
|
||
+Program exited with code 01.
|
||
Index: valgrind/gdbserver_tests/gone_exit.vgtest
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_exit.vgtest (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_exit.vgtest (working copy)
|
||
@@ -0,0 +1,12 @@
|
||
+# test that an exit (with return value) is properly passed on to gdb.
|
||
+
|
||
+prog: gone
|
||
+args: exit
|
||
+vgopts: --tool=none --vgdb=yes --vgdb-error=0 --vgdb-prefix=./vgdb-prefix-gone-exit
|
||
+stderr_filter: filter_stderr
|
||
+prereq: test -e gdb
|
||
+progB: gdb
|
||
+argsB: --quiet -l 60 --nx ./gone
|
||
+stdinB: gone_exit.stdinB.gdb
|
||
+stdoutB_filter: filter_gdb
|
||
+stderrB_filter: filter_gdb
|
||
Index: valgrind/gdbserver_tests/gone_return.stderr.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_return.stderr.exp (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_return.stderr.exp (working copy)
|
||
@@ -0,0 +1,8 @@
|
||
+Nulgrind, the minimal Valgrind tool
|
||
+
|
||
+(action at startup) vgdb me ...
|
||
+
|
||
+
|
||
+starting ...
|
||
+returning ...
|
||
+
|
||
Index: valgrind/gdbserver_tests/gone_return.stderrB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_return.stderrB.exp (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_return.stderrB.exp (working copy)
|
||
@@ -0,0 +1 @@
|
||
+relaying data between gdb and process ....
|
||
Index: valgrind/gdbserver_tests/gone_return.stdinB.gdb
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_return.stdinB.gdb (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_return.stdinB.gdb (working copy)
|
||
@@ -0,0 +1,7 @@
|
||
+# connect gdb to Valgrind gdbserver:
|
||
+target remote | ./vgdb --wait=60 --vgdb-prefix=./vgdb-prefix-gone-return
|
||
+echo vgdb launched process attached\n
|
||
+
|
||
+continue
|
||
+# see program is gone
|
||
+quit
|
||
Index: valgrind/gdbserver_tests/gone_return.stdoutB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_return.stdoutB.exp (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_return.stdoutB.exp (working copy)
|
||
@@ -0,0 +1,3 @@
|
||
+vgdb launched process attached
|
||
+Continuing.
|
||
+Program exited normally.
|
||
Index: valgrind/gdbserver_tests/gone_return.vgtest
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/gone_return.vgtest (revision 0)
|
||
+++ valgrind/gdbserver_tests/gone_return.vgtest (working copy)
|
||
@@ -0,0 +1,12 @@
|
||
+# test that a normal (successful) return is properly passed on to gdb.
|
||
+
|
||
+prog: gone
|
||
+args: return
|
||
+vgopts: --tool=none --vgdb=yes --vgdb-error=0 --vgdb-prefix=./vgdb-prefix-gone-return
|
||
+stderr_filter: filter_stderr
|
||
+prereq: test -e gdb
|
||
+progB: gdb
|
||
+argsB: --quiet -l 60 --nx ./gone
|
||
+stdinB: gone_return.stdinB.gdb
|
||
+stdoutB_filter: filter_gdb
|
||
+stderrB_filter: filter_gdb
|
||
Index: valgrind/gdbserver_tests/mcleak.stderrB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/mcleak.stderrB.exp (revision 13036)
|
||
+++ valgrind/gdbserver_tests/mcleak.stderrB.exp (working copy)
|
||
@@ -95,4 +95,3 @@
|
||
by 0x........: f (leak-delta.c:28)
|
||
by 0x........: main (leak-delta.c:60)
|
||
|
||
-Remote connection closed
|
||
Index: valgrind/gdbserver_tests/mcleak.stdoutB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/mcleak.stdoutB.exp (revision 13036)
|
||
+++ valgrind/gdbserver_tests/mcleak.stdoutB.exp (working copy)
|
||
@@ -45,3 +45,4 @@
|
||
#1 0x........ in f () at leak-delta.c:48
|
||
48 fprintf(stderr, "expecting details 32 (+32) bytes lost, 33 (-32) bytes reachable\n"); fflush(stderr); breakme();
|
||
Continuing.
|
||
+Program exited normally.
|
||
Index: valgrind/gdbserver_tests/mcmain_pic.stderrB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/mcmain_pic.stderrB.exp (revision 13036)
|
||
+++ valgrind/gdbserver_tests/mcmain_pic.stderrB.exp (working copy)
|
||
@@ -1,3 +1,2 @@
|
||
relaying data between gdb and process ....
|
||
vgdb-error value changed from 0 to 999999
|
||
-Remote connection closed
|
||
Index: valgrind/gdbserver_tests/mcmain_pic.stdoutB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/mcmain_pic.stdoutB.exp (revision 13036)
|
||
+++ valgrind/gdbserver_tests/mcmain_pic.stdoutB.exp (working copy)
|
||
@@ -6,3 +6,4 @@
|
||
$2 = (int (*)(int, char **)) 0x........ <main>
|
||
$3 = (void (*)(char *)) 0x........ <another_func>
|
||
Continuing.
|
||
+Program exited normally.
|
||
Index: valgrind/gdbserver_tests/mcwatchpoints.stdoutB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/mcwatchpoints.stdoutB.exp (revision 13036)
|
||
+++ valgrind/gdbserver_tests/mcwatchpoints.stdoutB.exp (working copy)
|
||
@@ -32,3 +32,4 @@
|
||
49 fprintf(stderr, "after writing 8\n");
|
||
Delete all breakpoints? (y or n) [answered Y; input not from terminal]
|
||
Continuing.
|
||
+Program exited normally.
|
||
Index: valgrind/gdbserver_tests/nlcontrolc.stdoutB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/nlcontrolc.stdoutB.exp (revision 13036)
|
||
+++ valgrind/gdbserver_tests/nlcontrolc.stdoutB.exp (working copy)
|
||
@@ -21,3 +21,4 @@
|
||
$6 = 0
|
||
$7 = 0
|
||
Continuing.
|
||
+Program exited normally.
|
||
Index: valgrind/gdbserver_tests/nlpasssigalrm.stderrB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/nlpasssigalrm.stderrB.exp (revision 13036)
|
||
+++ valgrind/gdbserver_tests/nlpasssigalrm.stderrB.exp (working copy)
|
||
@@ -1,3 +1,2 @@
|
||
relaying data between gdb and process ....
|
||
vgdb-error value changed from 0 to 999999
|
||
-Remote connection closed
|
||
Index: valgrind/gdbserver_tests/nlpasssigalrm.stdoutB.exp
|
||
===================================================================
|
||
--- valgrind/gdbserver_tests/nlpasssigalrm.stdoutB.exp (revision 13036)
|
||
+++ valgrind/gdbserver_tests/nlpasssigalrm.stdoutB.exp (working copy)
|
||
@@ -19,3 +19,4 @@
|
||
Program received signal SIG34, Real-time event 34.
|
||
0x........ in syscall ...
|
||
Continuing.
|
||
+Program exited normally.
|
||
--- valgrind-3.8.1/gdbserver_tests/Makefile.in.orig 2012-10-13 16:35:43.846865557 +0200
|
||
+++ valgrind-3.8.1/gdbserver_tests/Makefile.in 2012-10-13 16:36:37.445641004 +0200
|
||
@@ -56,7 +56,7 @@
|
||
|
||
check_PROGRAMS = clean_after_fork$(EXEEXT) fork_chain$(EXEEXT) \
|
||
passsigalrm$(EXEEXT) sleepers$(EXEEXT) main_pic$(EXEEXT) \
|
||
- t$(EXEEXT) watchpoints$(EXEEXT)
|
||
+ t$(EXEEXT) watchpoints$(EXEEXT) gone$(EXEEXT)
|
||
subdir = gdbserver_tests
|
||
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
||
am__aclocal_m4_deps = $(top_srcdir)/configure.in
|
||
@@ -74,6 +74,10 @@
|
||
fork_chain_OBJECTS = fork_chain.$(OBJEXT)
|
||
fork_chain_LDADD = $(LDADD)
|
||
fork_chain_DEPENDENCIES =
|
||
+gone_SOURCES = gone.c
|
||
+gone_OBJECTS = gone.$(OBJEXT)
|
||
+gone_LDADD = $(LDADD)
|
||
+gone_DEPENDENCIES =
|
||
main_pic_SOURCES = main_pic.c
|
||
main_pic_OBJECTS = main_pic-main_pic.$(OBJEXT)
|
||
main_pic_LDADD = $(LDADD)
|
||
@@ -105,9 +109,9 @@
|
||
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
|
||
CCLD = $(CC)
|
||
LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
|
||
-SOURCES = clean_after_fork.c fork_chain.c main_pic.c passsigalrm.c \
|
||
- sleepers.c t.c watchpoints.c
|
||
-DIST_SOURCES = clean_after_fork.c fork_chain.c main_pic.c \
|
||
+SOURCES = clean_after_fork.c fork_chain.c gone.c main_pic.c \
|
||
+ passsigalrm.c sleepers.c t.c watchpoints.c
|
||
+DIST_SOURCES = clean_after_fork.c fork_chain.c gone.c main_pic.c \
|
||
passsigalrm.c sleepers.c t.c watchpoints.c
|
||
ETAGS = etags
|
||
CTAGS = ctags
|
||
@@ -487,7 +491,22 @@
|
||
nlsigvgdb.vgtest \
|
||
nlsigvgdb.stderr.exp \
|
||
nlsigvgdb.stderrB.exp \
|
||
- nlsigvgdb.stdinB.gdb
|
||
+ nlsigvgdb.stdinB.gdb \
|
||
+ gone_abrt.stderr.exp \
|
||
+ gone_abrt.stderrB.exp \
|
||
+ gone_abrt.stdinB.gdb \
|
||
+ gone_abrt.stdoutB.exp \
|
||
+ gone_abrt.vgtest \
|
||
+ gone_exit.stderr.exp \
|
||
+ gone_exit.stderrB.exp \
|
||
+ gone_exit.stdinB.gdb \
|
||
+ gone_exit.stdoutB.exp \
|
||
+ gone_exit.vgtest \
|
||
+ gone_return.stderr.exp \
|
||
+ gone_return.stderrB.exp \
|
||
+ gone_return.stdinB.gdb \
|
||
+ gone_return.stdoutB.exp \
|
||
+ gone_return.vgtest
|
||
|
||
LDADD = -lpthread
|
||
main_pic_LDFLAGS = -pie
|
||
@@ -535,6 +554,9 @@
|
||
fork_chain$(EXEEXT): $(fork_chain_OBJECTS) $(fork_chain_DEPENDENCIES)
|
||
@rm -f fork_chain$(EXEEXT)
|
||
$(LINK) $(fork_chain_OBJECTS) $(fork_chain_LDADD) $(LIBS)
|
||
+gone$(EXEEXT): $(gone_OBJECTS) $(gone_DEPENDENCIES)
|
||
+ @rm -f gone$(EXEEXT)
|
||
+ $(LINK) $(gone_OBJECTS) $(gone_LDADD) $(LIBS)
|
||
main_pic$(EXEEXT): $(main_pic_OBJECTS) $(main_pic_DEPENDENCIES)
|
||
@rm -f main_pic$(EXEEXT)
|
||
$(main_pic_LINK) $(main_pic_OBJECTS) $(main_pic_LDADD) $(LIBS)
|
||
@@ -559,6 +581,7 @@
|
||
|
||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clean_after_fork.Po@am__quote@
|
||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fork_chain.Po@am__quote@
|
||
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gone.Po@am__quote@
|
||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/main_pic-main_pic.Po@am__quote@
|
||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/passsigalrm.Po@am__quote@
|
||
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sleepers.Po@am__quote@
|