bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug gold/18846] New: gold PowerPC --emit-relocs differ from ld


From: johan.karlsson at enea dot com
Subject: [Bug gold/18846] New: gold PowerPC --emit-relocs differ from ld
Date: Tue, 18 Aug 2015 10:04:21 +0000

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

            Bug ID: 18846
           Summary: gold PowerPC --emit-relocs differ from ld
           Product: binutils
           Version: 2.25
            Status: NEW
          Severity: normal
          Priority: P2
         Component: gold
          Assignee: ccoutant at gmail dot com
          Reporter: johan.karlsson at enea dot com
                CC: ian at airs dot com
  Target Milestone: ---

Created attachment 8530
  --> https://sourceware.org/bugzilla/attachment.cgi?id=8530&action=edit
gold_ppc_rela_addend.patch

When using --emit-relocs on PowerPC, gold recalculates the addend in the
relocation entry to include the symbol value. When using ld the symbol value is
not added to the addend.

Example: readelf -r test.elf

 Offset     Info    Type            Sym.Value  Sym. Name + Addend
gold
010004e2  00000304 R_PPC_ADDR16_LO   010200c0   .bss + 1020140

ld
010004e2  00000304 R_PPC_ADDR16_LO   010200c0   .bss + 80


I attached a patch that solves this. I don't know if it's a copy past error or
if the changed behavior is intended.

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



reply via email to

[Prev in Thread] Current Thread [Next in Thread]