summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog6
-rwxr-xr-xdtrace1
-rw-r--r--runtime/sdt.h2
-rw-r--r--tapsets.cxx13
4 files changed, 15 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index 712df04c..b447be08 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2009-01-26 Stan Cox <scox@redhat.com>
+
+ * tapsets.cxx (find_variable_and_frame_base): Allow for disjoint
+ pc and scope_die.
+ * runtime/sdt.h: Change label prefix.
+
2009-01-26 Mark Wielaard <mjw@redhat.com>
* configure.ac: Check for version.h.in before installing.
diff --git a/dtrace b/dtrace
index 1eb53bf9..2b261f5a 100755
--- a/dtrace
+++ b/dtrace
@@ -117,7 +117,6 @@ while (i < len (sys.argv)):
elif (sys.argv[i] == "-G"):
build_source = True
i += 1
-# print build_header == False and build_source == False
if (build_header == False and build_source == False):
usage()
sys.exit(1)
diff --git a/runtime/sdt.h b/runtime/sdt.h
index 6db23288..88183461 100644
--- a/runtime/sdt.h
+++ b/runtime/sdt.h
@@ -32,7 +32,7 @@ static volatile struct _probe_ ## probe _probe_ ## probe __attribute__ ((section
#define STAP_CONCAT(a,b) a ## b
#define STAP_LABEL(p,n) \
- STAP_CONCAT(_probe_ ## p ## _, n)
+ STAP_CONCAT(_stapprobe1_ ## p ## _, n)
// The goto _probe_ prevents the label from "drifting"
#ifdef USE_STAP_PROBE
diff --git a/tapsets.cxx b/tapsets.cxx
index d87ef5b2..a06d9fb4 100644
--- a/tapsets.cxx
+++ b/tapsets.cxx
@@ -1709,10 +1709,14 @@ struct dwflpp
assert (cu);
- if (scope_die && pc == 0)
- nscopes = dwarf_getscopes_die (scope_die, &scopes);
- else
- nscopes = dwarf_getscopes (cu, pc, &scopes);
+ nscopes = dwarf_getscopes (cu, pc, &scopes);
+ int sidx;
+ // if pc and scope_die are disjoint then we need dwarf_getscopes_die
+ for (sidx = 0; sidx < nscopes; sidx++)
+ if (scopes[sidx].addr == scope_die->addr)
+ break;
+ if (sidx == nscopes)
+ nscopes = dwarf_getscopes_die (scope_die, &scopes);
if (nscopes == 0)
{
@@ -5348,7 +5352,6 @@ dwarf_builder::build(systemtap_session & sess,
if (probe_scn_offset % (sizeof(__uint64_t)))
probe_scn_offset += sizeof(__uint64_t) - (probe_scn_offset % sizeof(__uint64_t));
- // pdata->d_buf + *(long*)(pdata->d_buf + probe_scn_offset) - probe_scn_addr
probe_name = ((char*)((long)(pdata->d_buf) + (long)(*((int*)((long)pdata->d_buf + probe_scn_offset)) - probe_scn_addr)));
probe_scn_offset += sizeof(void*);
if (probe_scn_offset % (sizeof(__uint64_t)))