aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.trace/actions.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@ericsson.com>2015-11-23 18:47:09 -0500
committerSimon Marchi <simon.marchi@ericsson.com>2015-11-23 18:47:09 -0500
commitc93e8391bf595de7adde64d1b3f1d564da6f3aee (patch)
tree702b8affbc88020c0b8298f481ad8ebe9cb9a4a1 /gdb/testsuite/gdb.trace/actions.c
parent045ccf910b4345a1cfa9f3d3af20ae4d8d1defa2 (diff)
downloadgdb-c93e8391bf595de7adde64d1b3f1d564da6f3aee.zip
gdb-c93e8391bf595de7adde64d1b3f1d564da6f3aee.tar.gz
gdb-c93e8391bf595de7adde64d1b3f1d564da6f3aee.tar.bz2
Fix internal error when saving fast tracepoint definitions
When trying to save fast tracepoints to file, gdb returns internal failure: gdb/breakpoint.c:13446: internal-error: unhandled tracepoint type 27 A problem internal to GDB has been detected, further debugging may prove unreliable. And no file including the fast tracepoints definition is created. The patch also extends save-trace.exp to test saving tracepoint with a fast tracepoint in there. Note that because this test doesn't actually inserts the tracepoints in the program, we can run it with targets that don't actually support fast tracepoints (or tracepoints at all). gdb/ChangeLog: * breakpoint.c (tracepoint_print_recreate): Fix logic error if -> else if. gdb/testsuite/ChangeLog: * gdb.trace/actions.c: Include trace-common.h. (main): Add a location for a fast tracepoint. * gdb.trace/save-trace.exp: Set a fast tracepoint in addition to the normal tracepoints. (gdb_verify_tracepoints): Adjust number of expected tracepoints.
Diffstat (limited to 'gdb/testsuite/gdb.trace/actions.c')
-rw-r--r--gdb/testsuite/gdb.trace/actions.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/gdb/testsuite/gdb.trace/actions.c b/gdb/testsuite/gdb.trace/actions.c
index 4b7b887..e728635 100644
--- a/gdb/testsuite/gdb.trace/actions.c
+++ b/gdb/testsuite/gdb.trace/actions.c
@@ -21,6 +21,8 @@
#include <string.h>
+#include "trace-common.h"
+
static char gdb_char_test;
static short gdb_short_test;
static long gdb_long_test;
@@ -136,6 +138,8 @@ main (argc, argv, envp)
int i;
unsigned long myparms[10];
+ FAST_TRACEPOINT_LABEL (fast_tracepoint_loc);
+
begin ();
for (i = 0; i < sizeof (myparms) / sizeof (myparms[0]); i++)
myparms[i] = i;