bug-binutils
[Top][All Lists]
Advanced

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

[Bug ld/14956] New: Unnecessary R_X86_64_NONE


From: hjl.tools at gmail dot com
Subject: [Bug ld/14956] New: Unnecessary R_X86_64_NONE
Date: Thu, 13 Dec 2012 17:59:36 +0000

http://sourceware.org/bugzilla/show_bug.cgi?id=14956

             Bug #: 14956
           Summary: Unnecessary R_X86_64_NONE
           Product: binutils
           Version: 2.24 (HEAD)
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ld
        AssignedTo: address@hidden
        ReportedBy: address@hidden
    Classification: Unclassified


address@hidden ifunc-none]$ cat bar.c
extern int foo (void) __attribute__ ((weak, visibility ("hidden")));

int
bar (void)
{
  return foo ();
}
address@hidden ifunc-none]$ cat foo.c
static int
one (void)
{
  return -30;
}

void * foo_ifunc (void) __asm__ ("foo") __attribute__ ((visibility
("hidden")));
__asm__(".type foo, %gnu_indirect_function");

void * 
foo_ifunc (void)
{
  return one;
}
address@hidden ifunc-none]$ make
gcc -fPIC   -c -o bar.o bar.c
gcc -fPIC   -c -o foo.o foo.c
./ld --shared -o libfoo.so -z nocombreloc bar.o foo.o
readelf -r --wide libfoo.so

Relocation section '.rela.ifunc' at offset 0x200 contains 1 entries:
    Offset             Info             Type               Symbol's Value 
Symbol's Name + Addend
0000000000000000  0000000000000000 R_X86_64_NONE                             0

Relocation section '.rela.plt' at offset 0x218 contains 1 entries:
    Offset             Info             Type               Symbol's Value 
Symbol's Name + Addend
0000000000200450  0000000000000025 R_X86_64_IRELATIVE                       
267
address@hidden ifunc-none]$

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- 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]