diff options
| author | Mark Wielaard <mjw@redhat.com> | 2008-12-10 20:39:45 +0100 |
|---|---|---|
| committer | Mark Wielaard <mjw@redhat.com> | 2008-12-10 20:39:45 +0100 |
| commit | d2f4d7286629da6e9f1b844beefb141a4d3ef2c3 (patch) | |
| tree | ffcff9ea678de1196ad1d95a3ee6880eaf39e3df /tapset | |
| parent | e8318a92c7b07579b89da5ff6fef782ce5d2b58c (diff) | |
| download | systemtap-steved-d2f4d7286629da6e9f1b844beefb141a4d3ef2c3.tar.gz systemtap-steved-d2f4d7286629da6e9f1b844beefb141a4d3ef2c3.tar.xz systemtap-steved-d2f4d7286629da6e9f1b844beefb141a4d3ef2c3.zip | |
PR6866: First pass at translating addresses to symbol names through vma.
Diffstat (limited to 'tapset')
| -rw-r--r-- | tapset/ChangeLog | 7 | ||||
| -rw-r--r-- | tapset/context-symbols.stp | 8 | ||||
| -rw-r--r-- | tapset/context-unwind.stp | 3 |
3 files changed, 17 insertions, 1 deletions
diff --git a/tapset/ChangeLog b/tapset/ChangeLog index 626ad67b..30634bcc 100644 --- a/tapset/ChangeLog +++ b/tapset/ChangeLog @@ -1,3 +1,10 @@ +2008-12-10 Mark Wielaard <mjw@redhat.com> + + * context-symbols.stp: Define STP_NEED_TASK_FINDER_VMA. + (symbolname): New function. + * context-unwind.stp (caller): Pass current task to + _stp_symbol_snprint. + 2008-12-09 Frank Ch. Eigler <fche@elastic.org> PR 6961. diff --git a/tapset/context-symbols.stp b/tapset/context-symbols.stp index 79645f4f..fbb51767 100644 --- a/tapset/context-symbols.stp +++ b/tapset/context-symbols.stp @@ -11,6 +11,9 @@ #ifndef STP_NEED_SYMBOL_DATA #define STP_NEED_SYMBOL_DATA 1 #endif +#ifndef STP_NEED_TASK_FINDER_VMA +#define STP_NEED_TASK_FINDER_VMA 1 +#endif %} /** @@ -93,3 +96,8 @@ function probemod:string () %{ /* pure */ THIS->__retvalue[0] = '\0'; } %} + +function symbolname:string (addr:long) %{ /* pure */ + _stp_symbol_snprint(THIS->__retvalue, MAXSTRINGLEN, THIS->addr, + current); +%} diff --git a/tapset/context-unwind.stp b/tapset/context-unwind.stp index 4c5ed34b..59d111ee 100644 --- a/tapset/context-unwind.stp +++ b/tapset/context-unwind.stp @@ -51,7 +51,8 @@ function backtrace:string () %{ /* pure */ function caller:string() %{ /* pure */ if (CONTEXT->pi) _stp_symbol_snprint( THIS->__retvalue, MAXSTRINGLEN, - (unsigned long)_stp_ret_addr_r(CONTEXT->pi)); + (unsigned long)_stp_ret_addr_r(CONTEXT->pi), + current); else strlcpy(THIS->__retvalue,"unknown",MAXSTRINGLEN); %} |
