bug-binutils
[Top][All Lists]
Advanced

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

[Bug ld/22001] -z nocopyreloc doesn't work right


From: cvs-commit at gcc dot gnu.org
Subject: [Bug ld/22001] -z nocopyreloc doesn't work right
Date: Thu, 24 Aug 2017 13:35:29 +0000

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

--- Comment #1 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot 
gnu.org> ---
The master branch has been updated by H.J. Lu <address@hidden>:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=7073b5b9edc9e06974bd733b7e4b3845d6d6f690

commit 7073b5b9edc9e06974bd733b7e4b3845d6d6f690
Author: H.J. Lu <address@hidden>
Date:   Thu Aug 24 06:34:19 2017 -0700

    x86-64: Check relocations with -z nocopyreloc

    On x86-64, when -z nocopyreloc is used to build executable, relocations
    may overflow at run-time or may not be resolved without PIC.  This patch
    checks these conditions and issues an error with suggestion for -fPIC.

    bfd/

        PR ld/22001
        * elf64-x86-64.c (elf_x86_64_relocate_section): Check for
        R_X86_64_PC32 relocation run-time overflow and unresolvable
        R_X86_64_32S relocation with -z nocopyreloc.

    ld/

        PR ld/22001
        * testsuite/ld-i386/i386.exp: Run -z nocopyreloc tests.
        * testsuite/ld-x86-64/x86-64.exp: Likewise.
        * ld/testsuite/ld-i386/pr22001-1a.c: New file.
        * ld/testsuite/ld-i386/pr22001-1b.c: Likewise.
        * ld/testsuite/ld-i386/pr22001-1c.S: Likewise.
        * ld/testsuite/ld-x86-64/pr22001-1a.c: Likewise.
        * ld/testsuite/ld-x86-64/pr22001-1a.err: Likewise.
        * ld/testsuite/ld-x86-64/pr22001-1b.c: Likewise.
        * ld/testsuite/ld-x86-64/pr22001-1b.err: Likewise.
        * ld/testsuite/ld-x86-64/pr22001-1c.c: Likewise.

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