diff options
author | Yao Qi <yao@codesourcery.com> | 2013-10-24 08:46:07 +0800 |
---|---|---|
committer | Tom Tromey <tromey@sourceware.org> | 2013-10-25 14:03:00 +0000 |
commit | 24a008139eaf7de2890c3e948f3d22eac4e0a9d3 (patch) | |
tree | c7a33a83f09c69645d2b810a1f80c5a39a8ce90f /gdb/tracepoint.c | |
parent | 6ba1f11550257b564f210856ec171f886664e389 (diff) | |
download | gdb-24a008139eaf7de2890c3e948f3d22eac4e0a9d3.zip gdb-24a008139eaf7de2890c3e948f3d22eac4e0a9d3.tar.gz gdb-24a008139eaf7de2890c3e948f3d22eac4e0a9d3.tar.bz2 |
Remove global traceframe_fun and traceframe_sal
I happen to see traceframe_fun and traceframe_sal are static variables,
which are not necessary to me. They are only used in set_traceframe_context,
and they are not stateful. This patch is to remove them.
gdb:
2013-10-24 Yao Qi <yao@codesourcery.com>
* tracepoint.c (traceframe_fun): Remove.
(traceframe_sal): Remove.
(set_traceframe_context): Add local variables.
Diffstat (limited to 'gdb/tracepoint.c')
-rw-r--r-- | gdb/tracepoint.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/gdb/tracepoint.c b/gdb/tracepoint.c index c086587..a7ccb50 100644 --- a/gdb/tracepoint.c +++ b/gdb/tracepoint.c @@ -132,12 +132,6 @@ static int traceframe_number; /* Tracepoint for last traceframe collected. */ static int tracepoint_number; -/* Symbol for function for last traceframe collected. */ -static struct symbol *traceframe_fun; - -/* Symtab and line for last traceframe collected. */ -static struct symtab_and_line traceframe_sal; - /* The traceframe info of the current traceframe. NULL if we haven't yet attempted to fetch it, or if the target does not support fetching this object, or if we're not inspecting a traceframe @@ -268,6 +262,8 @@ static void set_traceframe_context (struct frame_info *trace_frame) { CORE_ADDR trace_pc; + struct symbol *traceframe_fun; + struct symtab_and_line traceframe_sal; /* Save as globals for internal use. */ if (trace_frame != NULL |