summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrank Ch. Eigler <fche@elastic.org>2008-10-26 08:41:49 -0400
committerFrank Ch. Eigler <fche@elastic.org>2008-10-26 08:41:49 -0400
commit5ae317319bf3249df2e94a23e81d5881cb28716e (patch)
tree414b966487c1a3b545b6fdbaaa0647c86ef14ef8
parent212a566e493f285d89ebcc08961f44485dc55db0 (diff)
downloadsystemtap-steved-5ae317319bf3249df2e94a23e81d5881cb28716e.tar.gz
systemtap-steved-5ae317319bf3249df2e94a23e81d5881cb28716e.tar.xz
systemtap-steved-5ae317319bf3249df2e94a23e81d5881cb28716e.zip
partial revert of 212a56
-rw-r--r--elaborate.cxx12
-rw-r--r--testsuite/systemtap.base/global_end.exp8
2 files changed, 11 insertions, 9 deletions
diff --git a/elaborate.cxx b/elaborate.cxx
index 38ce014e..6e01e813 100644
--- a/elaborate.cxx
+++ b/elaborate.cxx
@@ -1147,8 +1147,9 @@ semantic_pass_symbols (systemtap_session& s)
// Keep unread global variables for probe end value display.
void add_global_var_display (systemtap_session& s)
{
- if (s.listing_mode || s.guru_mode) return; // avoid end probe
- //in listings_mode or guru_mode
+ // Don't generate synthetic end probes when in listings mode;
+ // it would clutter up the list of probe points with "end ...".
+ if (s.listing_mode) return;
varuse_collecting_visitor vut;
for (unsigned i=0; i<s.probes.size(); i++)
@@ -1166,6 +1167,13 @@ void add_global_var_display (systemtap_session& s)
|| vut.written.find (l) == vut.written.end())
continue;
+ // Don't generate synthetic end probes for unread globals
+ // declared only within tapsets. (RHBZ 468139), but rather
+ // only within the end-user script.
+
+ // XXX: for example, search s.library_files[]->globals->name
+ // for a matching with l->name, then "continue;" to skip it.
+
print_format* pf = new print_format;
probe* p = new probe;
probe_point* pl = new probe_point;
diff --git a/testsuite/systemtap.base/global_end.exp b/testsuite/systemtap.base/global_end.exp
index 9935629e..b6b9fd30 100644
--- a/testsuite/systemtap.base/global_end.exp
+++ b/testsuite/systemtap.base/global_end.exp
@@ -23,10 +23,4 @@ expect {
eof { }
}
wait
-spawn stap -g $srcdir/$subdir/global_end.stp
-# above should not do any global variable display so `ok' should only change by one
-expect {
- -timeout 180
- -re {one,0x1.*one,0x2.*two,0x1.*two,0x2} { incr ok; exp_continue }
-}
-if {$ok == 12} { pass "$test ($ok)" } { fail "$test ($ok)" }
+if {$ok == 11} { pass "$test ($ok)" } { fail "$test ($ok)" }