public inbox for elfutils@sourceware.org
 help / color / mirror / Atom feed
* [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error
@ 2018-11-20 20:26 kurt at roeckx dot be
  2018-11-21 12:25 ` [Bug backends/23902] " mark at klomp dot org
                   ` (11 more replies)
  0 siblings, 12 replies; 13+ messages in thread
From: kurt at roeckx dot be @ 2018-11-20 20:26 UTC (permalink / raw)
  To: elfutils-devel

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

            Bug ID: 23902
           Summary: varlocs dwarf_cfi_addrframe: unknown error
           Product: elfutils
           Version: unspecified
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: backends
          Assignee: unassigned at sourceware dot org
          Reporter: kurt at roeckx dot be
                CC: elfutils-devel at sourceware dot org
  Target Milestone: ---

On at least mips, alpha and hppa, I'm getting something like:
/<<PKGBUILDDIR>>/tests/varlocs: dwarf_cfi_addrframe 0x120002540: unknown error
*** failure in /<<PKGBUILDDIR>>/tests/varlocs -e /<<PKGBUILDDIR>>/src/addr2line

Logs can be found at:
https://buildd.debian.org/status/fetch.php?pkg=elfutils&arch=alpha&ver=0.175-1&stamp=1542672225&raw=0
https://buildd.debian.org/status/fetch.php?pkg=elfutils&arch=mips&ver=0.175-1&stamp=1542667301&raw=0
https://buildd.debian.org/status/fetch.php?pkg=elfutils&arch=hppa&ver=0.175-1&stamp=1542666561&raw=0

The mips and hppa backend are patches that only exist in Debian, but alpha
seems to be part of upstream.

Is this some indication of missing functionality? Any suggestion where to look?

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
@ 2018-11-21 12:25 ` mark at klomp dot org
  2018-11-21 19:16 ` kurt at roeckx dot be
                   ` (10 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: mark at klomp dot org @ 2018-11-21 12:25 UTC (permalink / raw)
  To: elfutils-devel

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

Mark Wielaard <mark at klomp dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mark at klomp dot org

--- Comment #1 from Mark Wielaard <mark at klomp dot org> ---
The common theme might be that these arches don't use standard .eh_frame and/or
have some non-standard section name or type for the unwind tables?

alpha does have an upstream backend, but I am not sure when it was last tested.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
  2018-11-21 12:25 ` [Bug backends/23902] " mark at klomp dot org
@ 2018-11-21 19:16 ` kurt at roeckx dot be
  2018-11-23  9:09 ` mark at klomp dot org
                   ` (9 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: kurt at roeckx dot be @ 2018-11-21 19:16 UTC (permalink / raw)
  To: elfutils-devel

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

--- Comment #2 from Kurt Roeckx <kurt at roeckx dot be> ---
At least on mips I'm seeing an .eh_frame and .eh_frame_hdr section. It also has
some mips specific sections.

But note that various of the other tests say "Unwinding not supported for this
architecture". Is this just a test that also should get skipped?

PS: All arches except amd64 have "Unwinding not supported for this
architecture" in run-backtrace-data.sh, which I find a bit surprising.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
  2018-11-21 12:25 ` [Bug backends/23902] " mark at klomp dot org
  2018-11-21 19:16 ` kurt at roeckx dot be
@ 2018-11-23  9:09 ` mark at klomp dot org
  2018-11-23 17:49 ` kurt at roeckx dot be
                   ` (8 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: mark at klomp dot org @ 2018-11-23  9:09 UTC (permalink / raw)
  To: elfutils-devel

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

--- Comment #3 from Mark Wielaard <mark at klomp dot org> ---
(In reply to Kurt Roeckx from comment #2)
> At least on mips I'm seeing an .eh_frame and .eh_frame_hdr section. It also
> has some mips specific sections.

Assuming they have "normal" types then that part should work because it is
(mostly, except for register mapping) arch independent.

> But note that various of the other tests say "Unwinding not supported for
> this architecture". Is this just a test that also should get skipped?

If it would return that error maybe. But the varlocs test doesn't rely on
unwinding. There is something odd going on because it gives "Unknown Error",
which is not explicitly set anywhere in the code, but is generated when
__libelf_seterrno () is called with an unknown error code (which itself is a
bug). So something doubly odd is going on.

> PS: All arches except amd64 have "Unwinding not supported for this
> architecture" in run-backtrace-data.sh, which I find a bit surprising.

Yes, that is surprising, run-backtrace-data.sh really should just say that it
is only supported on x86_64/amd64. Currently it "abuses" the "Unwinding not
supported for this architecture" message to get a SKIP on any other arch.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
                   ` (2 preceding siblings ...)
  2018-11-23  9:09 ` mark at klomp dot org
@ 2018-11-23 17:49 ` kurt at roeckx dot be
  2018-11-23 20:38 ` mark at klomp dot org
                   ` (7 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: kurt at roeckx dot be @ 2018-11-23 17:49 UTC (permalink / raw)
  To: elfutils-devel

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

--- Comment #4 from Kurt Roeckx <kurt at roeckx dot be> ---
The varlocs test is calling dwarf_errmsg (-1)

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
                   ` (3 preceding siblings ...)
  2018-11-23 17:49 ` kurt at roeckx dot be
@ 2018-11-23 20:38 ` mark at klomp dot org
  2018-11-23 20:45 ` kurt at roeckx dot be
                   ` (6 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: mark at klomp dot org @ 2018-11-23 20:38 UTC (permalink / raw)
  To: elfutils-devel

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

--- Comment #5 from Mark Wielaard <mark at klomp dot org> ---
(In reply to Kurt Roeckx from comment #4)
> The varlocs test is calling dwarf_errmsg (-1)

OK, that will show the last libdw error set on the current thread.
In which case we might actually have a candidate for why it was set.
The only place DWARF_E_UNKNOWN_ERROR is set (returned) is:

libdw/cfi.c (cie_cache_initial_state):

  /* Fetch the ABI's default CFI program.  */
  if (likely (cache->ebl != (void *) -1l)
      && unlikely (ebl_abi_cfi (cache->ebl, &abi_info) < 0))
    return DWARF_E_UNKNOWN_ERROR;

That would explain the issue on alpha at least because that doesn't have a
backend hook for abi_cfi. I suspect your mips and hppa backends also don't have
that hooked.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
                   ` (4 preceding siblings ...)
  2018-11-23 20:38 ` mark at klomp dot org
@ 2018-11-23 20:45 ` kurt at roeckx dot be
  2018-11-26 10:45 ` [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error (missing ebl abi_cfi hook) mark at klomp dot org
                   ` (5 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: kurt at roeckx dot be @ 2018-11-23 20:45 UTC (permalink / raw)
  To: elfutils-devel

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

--- Comment #6 from Kurt Roeckx <kurt at roeckx dot be> ---
Yes, they all 3 seem to be missing that callback.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error (missing ebl abi_cfi hook)
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
                   ` (5 preceding siblings ...)
  2018-11-23 20:45 ` kurt at roeckx dot be
@ 2018-11-26 10:45 ` mark at klomp dot org
  2018-11-28 13:05 ` mark at klomp dot org
                   ` (4 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: mark at klomp dot org @ 2018-11-26 10:45 UTC (permalink / raw)
  To: elfutils-devel

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

Mark Wielaard <mark at klomp dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|varlocs                     |varlocs
                   |dwarf_cfi_addrframe:        |dwarf_cfi_addrframe:
                   |unknown error               |unknown error (missing ebl
                   |                            |abi_cfi hook)

--- Comment #7 from Mark Wielaard <mark at klomp dot org> ---
The ebl abi_cfi hook sets up the initial CFI instructions, default data
alignment factor and return address register for the architecture. These are
normally given in the System V Application Binary Interface Processor
Supplement for a specific architecture which also explain the DWARF register
mappings.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error (missing ebl abi_cfi hook)
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
                   ` (6 preceding siblings ...)
  2018-11-26 10:45 ` [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error (missing ebl abi_cfi hook) mark at klomp dot org
@ 2018-11-28 13:05 ` mark at klomp dot org
  2018-12-30 19:53 ` kurt at roeckx dot be
                   ` (3 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: mark at klomp dot org @ 2018-11-28 13:05 UTC (permalink / raw)
  To: elfutils-devel

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

--- Comment #8 from Mark Wielaard <mark at klomp dot org> ---
(In reply to Mark Wielaard from comment #3)
> (In reply to Kurt Roeckx from comment #2)
> > PS: All arches except amd64 have "Unwinding not supported for this
> > architecture" in run-backtrace-data.sh, which I find a bit surprising.
> 
> Yes, that is surprising, run-backtrace-data.sh really should just say that
> it is only supported on x86_64/amd64. Currently it "abuses" the "Unwinding
> not supported for this architecture" message to get a SKIP on any other arch.

I pushed the following commit which should hopefully make this skip message
more clear:

commit 63160fceaaac2f9bd13da7abf929907a5f723aab
Author: Mark Wielaard <mark@klomp.org>
Date:   Wed Nov 28 13:58:31 2018 +0100

    tests: Improve backtrace-data SKIP message.

    The backtrace-data testcase is x86_64 linux only because it uses its
    own set_initial_registers and scans its own /proc/pid/maps file.
    The SKIP message it gave on other platforms was misleading. It said
    "Unwinding not supported for this architecture". Change it to
    "x86_64 linux only test" to be less confusing.

    Signed-off-by: Mark Wielaard <mark@klomp.org>

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error (missing ebl abi_cfi hook)
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
                   ` (7 preceding siblings ...)
  2018-11-28 13:05 ` mark at klomp dot org
@ 2018-12-30 19:53 ` kurt at roeckx dot be
  2018-12-30 21:53 ` kurt at roeckx dot be
                   ` (2 subsequent siblings)
  11 siblings, 0 replies; 13+ messages in thread
From: kurt at roeckx dot be @ 2018-12-30 19:53 UTC (permalink / raw)
  To: elfutils-devel

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

--- Comment #9 from Kurt Roeckx <kurt at roeckx dot be> ---
I've fixed the issue on mips* in Debian, so it's now working on all Debian's
release architectures. But some others still have this problem.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error (missing ebl abi_cfi hook)
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
                   ` (8 preceding siblings ...)
  2018-12-30 19:53 ` kurt at roeckx dot be
@ 2018-12-30 21:53 ` kurt at roeckx dot be
  2019-02-14 22:11 ` [Bug backends/23902] MIPS " mark at klomp dot org
  2019-07-10 10:44 ` mark at klomp dot org
  11 siblings, 0 replies; 13+ messages in thread
From: kurt at roeckx dot be @ 2018-12-30 21:53 UTC (permalink / raw)
  To: elfutils-devel

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

--- Comment #10 from Kurt Roeckx <kurt at roeckx dot be> ---
In the mean time, I know the patch for mips was wrong, but the test suite seems
to be happy with the current patch. Mips has many different ABIs, and I've
mixed them up. The callee-saved registers aren't the same in all ABIs, there
are small differences.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] MIPS varlocs dwarf_cfi_addrframe: unknown error (missing ebl abi_cfi hook)
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
                   ` (9 preceding siblings ...)
  2018-12-30 21:53 ` kurt at roeckx dot be
@ 2019-02-14 22:11 ` mark at klomp dot org
  2019-07-10 10:44 ` mark at klomp dot org
  11 siblings, 0 replies; 13+ messages in thread
From: mark at klomp dot org @ 2019-02-14 22:11 UTC (permalink / raw)
  To: elfutils-devel

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

Mark Wielaard <mark at klomp dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|varlocs                     |MIPS varlocs
                   |dwarf_cfi_addrframe:        |dwarf_cfi_addrframe:
                   |unknown error (missing ebl  |unknown error (missing ebl
                   |abi_cfi hook)               |abi_cfi hook)

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [Bug backends/23902] MIPS varlocs dwarf_cfi_addrframe: unknown error (missing ebl abi_cfi hook)
  2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
                   ` (10 preceding siblings ...)
  2019-02-14 22:11 ` [Bug backends/23902] MIPS " mark at klomp dot org
@ 2019-07-10 10:44 ` mark at klomp dot org
  11 siblings, 0 replies; 13+ messages in thread
From: mark at klomp dot org @ 2019-07-10 10:44 UTC (permalink / raw)
  To: elfutils-devel

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

Mark Wielaard <mark at klomp dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Blocks|                            |24795


Referenced Bugs:

https://sourceware.org/bugzilla/show_bug.cgi?id=24795
[Bug 24795] eu-unstrip doesn't recognize MIPS_DWARF as debug section
-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2019-07-10 10:44 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-20 20:26 [Bug backends/23902] New: varlocs dwarf_cfi_addrframe: unknown error kurt at roeckx dot be
2018-11-21 12:25 ` [Bug backends/23902] " mark at klomp dot org
2018-11-21 19:16 ` kurt at roeckx dot be
2018-11-23  9:09 ` mark at klomp dot org
2018-11-23 17:49 ` kurt at roeckx dot be
2018-11-23 20:38 ` mark at klomp dot org
2018-11-23 20:45 ` kurt at roeckx dot be
2018-11-26 10:45 ` [Bug backends/23902] varlocs dwarf_cfi_addrframe: unknown error (missing ebl abi_cfi hook) mark at klomp dot org
2018-11-28 13:05 ` mark at klomp dot org
2018-12-30 19:53 ` kurt at roeckx dot be
2018-12-30 21:53 ` kurt at roeckx dot be
2019-02-14 22:11 ` [Bug backends/23902] MIPS " mark at klomp dot org
2019-07-10 10:44 ` mark at klomp dot org

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).