public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
From: "wcohen at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: systemtap@sourceware.org
Subject: [Bug tapsets/26843] print_ubacktrace_fileline is broken on master
Date: Thu, 11 Jan 2024 22:11:50 +0000	[thread overview]
Message-ID: <bug-26843-6586-XloyckeNmT@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-26843-6586@http.sourceware.org/bugzilla/>

https://sourceware.org/bugzilla/show_bug.cgi?id=26843

William Cohen <wcohen at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |wcohen at redhat dot com
   Last reconfirmed|                            |2024-01-11
             Status|UNCONFIRMED                 |NEW
     Ever confirmed|0                           |1

--- Comment #1 from William Cohen <wcohen at redhat dot com> ---
When trying this on x86_64 RHEL8, RHEL9, and Fedora 39 with a current git
checkout of systemtap (023ec371b183c1) the output included the file and line
number:

$ sudo ../install/bin/stap a.stp -c
/home/wcohen/systemtap_write/systemtap/a.out
 0x40110a : main+0x4/0xe at /home/wcohen/systemtap_write/systemtap/a.c:2
[/home/wcohen/systemtap_write/systemtap/a.out]
 0x7f26492ee14a [/usr/lib64/libc.so.6+0x2814a/0x1e2000]
WARNING: Missing unwind data for a module, rerun with 'stap -d
/usr/lib64/libc.so.6'

However, on x86_64 unbuntu 20.04 I do see the issue reported with the same git
checkout of systemtap:

$ sudo ../install/bin/stap a.stp  -c
/home/william/systemtap_write/systemtap/a.out
 0x55facda6a131 : main+0x8/0x17 [/home/william/systemtap_write/systemtap/a.out]
 0x7f3804b72083 [/usr/lib/x86_64-linux-gnu/libc-2.31.so+0x24083/0x1f2000]
WARNING: Missing unwind data for a module, rerun with 'stap -d
/usr/lib/x86_64-linux-gnu/libc-2.31.so'

On RHEL8 dwarf4 is being used and on RHEL9/Fedora 39 dwarf 5.  Ubuntu 20.04 is
using dwarf 4.  I was able to run the unbuntu generated a.out on f39.  The
output is missing the expected filename and line number. Using "llvm-objdump
--line-numbers <object_file>" on f39 it appears that llvm-objdump can find the
line numbers:

f39 generated binary:

0000000000401106 <main>:
; main():
; /home/wcohen/systemtap_write/systemtap/a.c:1
  401106: 55                            pushq   %rbp
  401107: 48 89 e5                      movq    %rsp, %rbp
; /home/wcohen/systemtap_write/systemtap/a.c:2
  40110a: b8 00 00 00 00                movl    $0x0, %eax
; /home/wcohen/systemtap_write/systemtap/a.c:3
  40110f: 5d                            popq    %rbp
  401110: c3                            retq



ubuntu 20.04 generated binary:

0000000000001129 <main>:
; main():
; /home/william/systemtap_write/systemtap/a.c:1
    1129: f3 0f 1e fa                   endbr64
    112d: 55                            pushq   %rbp
    112e: 48 89 e5                      movq    %rsp, %rbp
; /home/william/systemtap_write/systemtap/a.c:2
    1131: b8 00 00 00 00                movl    $0x0, %eax
; /home/william/systemtap_write/systemtap/a.c:3
    1136: 5d                            popq    %rbp
    1137: c3                            retq
    1138: 0f 1f 84 00 00 00 00 00       nopl    (%rax,%rax)

-- 
You are receiving this mail because:
You are the assignee for the bug.

  reply	other threads:[~2024-01-11 22:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-04 21:54 [Bug tapsets/26843] New: " agentzh at gmail dot com
2024-01-11 22:11 ` wcohen at redhat dot com [this message]
2024-01-12 13:20 ` [Bug tapsets/26843] " mcermak 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-26843-6586-XloyckeNmT@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).