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

             Bug #: 15371
           Summary: uninitialised ifunc symbol
           Product: binutils
           Version: 2.24 (HEAD)
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ld
        AssignedTo: unassig...@sourceware.org
        ReportedBy: ni...@redhat.com
    Classification: Unclassified


Created attachment 6988
  --> http://sourceware.org/bugzilla/attachment.cgi?id=6988
tarball containing sources necessary to reproduce the problem

The ifunc tests in the prelink testsuite are failing with segmentation faults,
due to what looks like an uninitialised ifunc symbol.  

The problem can be reproduced by compiling and running the uploaded sources as
follows:

  % gcc -O2 -shared -fpic -o ifunc1lib1.so ifunc1lib1.c
  % gcc -O2 -shared -fpic -o ifunc1lib2.so ifunc1lib2.c ifunc1lib1.so
  % gcc -o ifunc1 ifunc1.c -Wl,--rpath-link,. ifunc1lib2.so
ifunc1lib1.so
  % LD_LIBRARY_PATH=. ./ifunc1

The seg-fault happens in ifunc1lib2.c:lib2test() where it calls lib2t1().

I feel that this is either a linker bug, or the inline assembler in ifunc.h is
wrong somehow.  (Note this inline assembler used to work with earlier versions
of the linker).

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

_______________________________________________
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to