From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id A016A3857403; Fri, 30 Apr 2021 12:31:12 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A016A3857403 From: "n2knqf5ogu at bsogq dot anonbox.net" To: elfutils-devel@sourceware.org Subject: [Bug libdw/27805] New: libdwfl: Unable to extract source line information for RISC-V binary Date: Fri, 30 Apr 2021 12:31:12 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: elfutils X-Bugzilla-Component: libdw X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: n2knqf5ogu at bsogq dot anonbox.net X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter cc target_milestone attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: elfutils-devel@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Elfutils-devel mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 30 Apr 2021 12:31:12 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D27805 Bug ID: 27805 Summary: libdwfl: Unable to extract source line information for RISC-V binary Product: elfutils Version: unspecified Status: UNCONFIRMED Severity: normal Priority: P2 Component: libdw Assignee: unassigned at sourceware dot org Reporter: n2knqf5ogu at bsogq dot anonbox.net CC: elfutils-devel at sourceware dot org Target Milestone: --- Created attachment 13416 --> https://sourceware.org/bugzilla/attachment.cgi?id=3D13416&action=3Ded= it RV32IMC binary to reproduce the outlined issue For the attached RV32IMC (i.e. RISC-V) binary, libdwfl from elfutlis 0.183 = is incapable of extracting source line information from provided DWARF debuggi= ng information. This can be easily reproduced by comparing the behavior of elfutils's addr2line with binutils's addr2line program. With binutils: $ addr2line --version GNU addr2line (GNU Binutils) 2.35.2 $ addr2line -e /tmp/elfutils-srcline-bug.elf 20400058 /home/john/src/RIOT/examples/hello-world/main.c:26 With elfutils: $ addr2line --version addr2line (elfutils) 0.183 $ addr2line -e /tmp/elfutils-srcline-bug.elf 20400058 ??:0 Briefly debugging this, it seems to me that dwfl_module_getsrc seems to ret= urn NULL and error out with DWARF_E_INVALID_OFFSET for this given binary. --=20 You are receiving this mail because: You are on the CC list for the bug.=