This is the mail archive of the mailing list for the systemtap project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug runtime/17638] Symbol resolution broken for PPC64 ABIv2

Mark Wielaard <mjw at redhat dot com> changed:

           What    |Removed                     |Added
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #5 from Mark Wielaard <mjw at redhat dot com> ---
commit b4c6a4b1cd00fd1681d76de6850a88aa516c4fef
Author: Hemant Kumar <>
Date:   Mon Apr 20 15:59:24 2015 +0530

    Prioritize symbol table lookup for ppc64le

    PPC64 ELF ABI v2 has a Global entry point and a local entry point
    for the functions. We need the Local entry point in order to probe
    these functions. However, the DIE for these functions in debuginfo
    return the function.entrypc which is same as the global entry point.
    The local entry point is not encoded in the debuginfo of the ELFs. The
    offset to local entry point is however encoded in the st_other field
    of these symbols in the symbol table.
    We need to use this field to adjust the sym.st_value to actually point
    to the local entry point instead of the global entry point.

    This patch is in relation to this bug :

    So, while adding symbols to the sym_table, we add an offset of
    PPC64_LOCAL_ENTRY_OFFSET(sym.st_other) to st_value.
    And when the function address is queried in query_dwarf_func(), we give
    priority to the cached sym_table, where we can retrieve the adjusted
    entry address of the function. If we don't get any address from the
    symbol table, then we proceed to get from the debuginfo.

    Macro definition PPC64_LOCAL_ENTRY_OFFSET has been picked up from glibc.
    It won't be defined if we are building systemtap on a machine having
    older elf.h and hence, won't recognize PPC64_LOCAL_ENTRY_OFFSET.

    Signed-off-by: Hemant Kumar <>

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

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]