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

           Summary: Garbage collection for STT_GNU_IFUNC symbols in shared
                    library
           Product: binutils
           Version: 2.22 (HEAD)
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ld
        AssignedTo: unassig...@sources.redhat.com
        ReportedBy: hjl.to...@gmail.com
                CC: hjl.to...@gmail.com, bug-binutils@gnu.org,
                    stephen.cla...@st.com, christian.br...@st.com
        Depends on: 11791
              Host: i686-pc-linux-gnu
            Target: i686-pc-linux-gnu
             Build: i686-pc-linux-gnu


+++ This bug was initially created as a clone of Bug #11791 +++

[...@gnu-6 intel64-2]$ cat foo.s
        .section .text.foo,"ax",@progbits
        .type foo, @function
foo:
        movl if...@gotpcrel(%rip), %eax
        movl ifunc(%rip), %eax
    call if...@plt
    call ifunc
        movl xxx(%rip), %eax
        ret

        .section .text.bar,"ax",@progbits
        .type bar, @function
bar:
        .global bar
        ret

        .section .text.ifunc,"ax",@progbits
        .type ifunc, @gnu_indirect_function
ifunc:
        ret

        .section .data.foo,"aw",@progbits
xxx:
    .quad ifunc 
[...@gnu-6 intel64-2]$ make LD=ld
as  -o foo.o foo.s
ld -shared -e bar --gc-sections -o foo  foo.o
make: *** [foo] Segmentation fault
make: *** Deleting file `foo'

-- 
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
http://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to