From: "wcohen at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: systemtap@sourceware.org
Subject: [Bug translator/27984] stap skipping partially-inlined instance, but it is not inline function actually
Date: Fri, 16 Jul 2021 14:49:32 +0000 [thread overview]
Message-ID: <bug-27984-6586-QIChAivZYN@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-27984-6586@http.sourceware.org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=27984
--- Comment #8 from William Cohen <wcohen at redhat dot com> ---
To better check what was going on I added the following patch to see what
offsets were being used and found that the libssl.so.1.1 library had a bias of
0x10000 for the addresses:
diff --git a/tapsets.cxx b/tapsets.cxx
index 20e0cb68f..251e2a4b6 100644
--- a/tapsets.cxx
+++ b/tapsets.cxx
@@ -2280,9 +2280,14 @@ query_dwarf_func (Dwarf_Die * func, dwarf_query * q)
// up the ELF symbol name and rely on a heuristic.
GElf_Sym sym;
GElf_Off off = 0;
- const char *name = dwfl_module_addrinfo (q->dw.module, entrypc,
+ Dwarf_Addr bias = 0x10000;
+
+ const char *name = dwfl_module_addrinfo (q->dw.module, entrypc +
bias,
&off, &sym, NULL, NULL,
NULL);
+ if (q->sess.verbose>2)
+ clog << _F("%s = dwfl_module_addrinfo(entrypc=%p,
off=%p)\n",
+ name, (void*)entrypc, (void*) off);
if (name != NULL && strstr(name, ".part.") != NULL)
{
if (q->sess.verbose>2)
With this patch see that the code is finding the correct function names for the
library functions:
focused on module
'/tmp/stap-job1/sysroot/usr/local/openresty/openssl/lib/libssl.so.1.1'
selected function BIO_new_ssl
BIO_new_ssl = dwfl_module_addrinfo(entrypc=0x1f760, off=(nil))
selected function BIO_new_ssl_connect
BIO_new_ssl_connect = dwfl_module_addrinfo(entrypc=0x1f7e0, off=(nil))
selected function ssl_puts
ssl_puts = dwfl_module_addrinfo(entrypc=0x1ed10, off=(nil))
selected function ssl_new
ssl_new = dwfl_module_addrinfo(entrypc=0x1ed40, off=(nil))
selected function BIO_ssl_shutdown
BIO_ssl_shutdown = dwfl_module_addrinfo(entrypc=0x1f960, off=(nil))
selected function ssl_callback_ctrl
ssl_callback_ctrl = dwfl_module_addrinfo(entrypc=0x1ecd0, off=(nil))
--
You are receiving this mail because:
You are the assignee for the bug.
next prev parent reply other threads:[~2021-07-16 14:49 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-16 2:26 [Bug translator/27984] New: " zhuizhuhaomeng at gmail dot com
2021-07-14 19:48 ` [Bug translator/27984] " wcohen at redhat dot com
2021-07-14 20:37 ` wcohen at redhat dot com
2021-07-15 0:39 ` lijunlong at openresty dot com
2021-07-15 1:37 ` lijunlong at openresty dot com
2021-07-15 14:34 ` wcohen at redhat dot com
2021-07-15 15:28 ` wcohen at redhat dot com
2021-07-15 16:22 ` wcohen at redhat dot com
2021-07-16 14:49 ` wcohen at redhat dot com [this message]
2021-07-16 18:39 ` wcohen at redhat dot com
2021-07-16 19:07 ` mark at klomp dot org
2021-07-17 0:25 ` lijunlong at openresty dot com
2021-07-17 22:05 ` wcohen at redhat dot com
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bug-27984-6586-QIChAivZYN@http.sourceware.org/bugzilla/ \
--to=sourceware-bugzilla@sourceware.org \
--cc=systemtap@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).