PKGBUILDs/core/binutils/binutils-2.25-roundup.patch
2015-02-09 04:07:41 +00:00

1660 lines
57 KiB
Diff

diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index f2ee1ba..6d936e2 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,34 @@
+2015-01-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
+
+ Backport from mainline
+ 2015-01-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
+
+ * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Use SYMBOLIC_BIND
+ to check if a symbol should be bound symbolically.
+
+2015-01-20 Chung-Lin Tang <cltang@codesourcery.com>
+
+ Backport from master
+ * elf32-nios2.c (elf_backend_default_execstack): Define as 0.
+
+2015-01-11 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR ld/17827
+ * elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): For PIE,
+ only discard space for pc-relative relocs symbols which turn
+ out to need copy relocs.
+
+2015-01-05 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR ld/17773
+ * elflink.c (bfd_elf_final_link): Assign the file position for
+ the symbol string table only there are symbols to be emitted.
+
+2014-12-23 Tristan Gingold <gingold@adacore.com>
+
+ * version.m4: Bump version to 2.25.0
+ * configure: Regenerate.
+
2014-12-23 Tristan Gingold <gingold@adacore.com>
* version.m4: Bump version to 2.25
diff --git a/bfd/configure b/bfd/configure
index 7016194..85e6b82 100755
--- a/bfd/configure
+++ b/bfd/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.64 for bfd 2.25.
+# Generated by GNU Autoconf 2.64 for bfd 2.25.0.
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
@@ -556,8 +556,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='bfd'
PACKAGE_TARNAME='bfd'
-PACKAGE_VERSION='2.25'
-PACKAGE_STRING='bfd 2.25'
+PACKAGE_VERSION='2.25.0'
+PACKAGE_STRING='bfd 2.25.0'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''
@@ -1349,7 +1349,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures bfd 2.25 to adapt to many kinds of systems.
+\`configure' configures bfd 2.25.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1420,7 +1420,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of bfd 2.25:";;
+ short | recursive ) echo "Configuration of bfd 2.25.0:";;
esac
cat <<\_ACEOF
@@ -1541,7 +1541,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-bfd configure 2.25
+bfd configure 2.25.0
generated by GNU Autoconf 2.64
Copyright (C) 2009 Free Software Foundation, Inc.
@@ -2183,7 +2183,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by bfd $as_me 2.25, which was
+It was created by bfd $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
$ $0 $@
@@ -3991,7 +3991,7 @@ fi
# Define the identity of the package.
PACKAGE='bfd'
- VERSION='2.25'
+ VERSION='2.25.0'
cat >>confdefs.h <<_ACEOF
@@ -16567,7 +16567,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by bfd $as_me 2.25, which was
+This file was extended by bfd $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -16631,7 +16631,7 @@ Report bugs to the package provider."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-bfd config.status 2.25
+bfd config.status 2.25.0
configured by $0, generated by GNU Autoconf 2.64,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
diff --git a/bfd/elf32-nios2.c b/bfd/elf32-nios2.c
index 9b3f436..2739961 100644
--- a/bfd/elf32-nios2.c
+++ b/bfd/elf32-nios2.c
@@ -5307,5 +5307,6 @@ const struct bfd_elf_special_section elf32_nios2_special_sections[] =
#define TARGET_BIG_NAME "elf32-bignios2"
#define elf_backend_got_header_size 12
+#define elf_backend_default_execstack 0
#include "elf32-target.h"
diff --git a/bfd/elf64-x86-64.c b/bfd/elf64-x86-64.c
index fefb08c..706ab5a 100644
--- a/bfd/elf64-x86-64.c
+++ b/bfd/elf64-x86-64.c
@@ -2677,13 +2677,23 @@ elf_x86_64_allocate_dynrelocs (struct elf_link_hash_entry *h, void * inf)
&& ! bfd_elf_link_record_dynamic_symbol (info, h))
return FALSE;
}
- /* For PIE, discard space for relocs against symbols which
- turn out to need copy relocs. */
+ /* For PIE, discard space for pc-relative relocs against
+ symbols which turn out to need copy relocs. */
else if (info->executable
&& (h->needs_copy || eh->needs_copy)
&& h->def_dynamic
&& !h->def_regular)
- eh->dyn_relocs = NULL;
+ {
+ struct elf_dyn_relocs **pp;
+
+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; )
+ {
+ if (p->pc_count != 0)
+ *pp = p->next;
+ else
+ pp = &p->next;
+ }
+ }
}
}
else if (ELIMINATE_COPY_RELOCS)
diff --git a/bfd/elflink.c b/bfd/elflink.c
index 94ab762..e9bd56c 100644
--- a/bfd/elflink.c
+++ b/bfd/elflink.c
@@ -10438,7 +10438,6 @@ bfd_elf_final_link (bfd *abfd, struct bfd_link_info *info)
unsigned int i;
Elf_Internal_Shdr *symtab_hdr;
Elf_Internal_Shdr *symtab_shndx_hdr;
- Elf_Internal_Shdr *symstrtab_hdr;
const struct elf_backend_data *bed = get_elf_backend_data (abfd);
struct elf_outext_info eoinfo;
bfd_boolean merged;
@@ -11139,25 +11138,28 @@ bfd_elf_final_link (bfd *abfd, struct bfd_link_info *info)
}
- /* Finish up and write out the symbol string table (.strtab)
- section. */
- symstrtab_hdr = &elf_tdata (abfd)->strtab_hdr;
- /* sh_name was set in prep_headers. */
- symstrtab_hdr->sh_type = SHT_STRTAB;
- symstrtab_hdr->sh_flags = 0;
- symstrtab_hdr->sh_addr = 0;
- symstrtab_hdr->sh_size = _bfd_stringtab_size (flinfo.symstrtab);
- symstrtab_hdr->sh_entsize = 0;
- symstrtab_hdr->sh_link = 0;
- symstrtab_hdr->sh_info = 0;
- /* sh_offset is set just below. */
- symstrtab_hdr->sh_addralign = 1;
-
- off = _bfd_elf_assign_file_position_for_section (symstrtab_hdr, off, TRUE);
- elf_next_file_pos (abfd) = off;
-
if (bfd_get_symcount (abfd) > 0)
{
+ /* Finish up and write out the symbol string table (.strtab)
+ section. */
+ Elf_Internal_Shdr *symstrtab_hdr;
+
+ symstrtab_hdr = &elf_tdata (abfd)->strtab_hdr;
+ /* sh_name was set in prep_headers. */
+ symstrtab_hdr->sh_type = SHT_STRTAB;
+ symstrtab_hdr->sh_flags = 0;
+ symstrtab_hdr->sh_addr = 0;
+ symstrtab_hdr->sh_size = _bfd_stringtab_size (flinfo.symstrtab);
+ symstrtab_hdr->sh_entsize = 0;
+ symstrtab_hdr->sh_link = 0;
+ symstrtab_hdr->sh_info = 0;
+ /* sh_offset is set just below. */
+ symstrtab_hdr->sh_addralign = 1;
+
+ off = _bfd_elf_assign_file_position_for_section (symstrtab_hdr,
+ off, TRUE);
+ elf_next_file_pos (abfd) = off;
+
if (bfd_seek (abfd, symstrtab_hdr->sh_offset, SEEK_SET) != 0
|| ! _bfd_stringtab_emit (abfd, flinfo.symstrtab))
return FALSE;
diff --git a/bfd/elfnn-aarch64.c b/bfd/elfnn-aarch64.c
index 0879db9..9939fcf 100644
--- a/bfd/elfnn-aarch64.c
+++ b/bfd/elfnn-aarch64.c
@@ -4329,7 +4329,7 @@ elfNN_aarch64_final_link_relocate (reloc_howto_type *howto,
memset (&outrel, 0, sizeof outrel);
else if (h != NULL
&& h->dynindx != -1
- && (!info->shared || !info->symbolic || !h->def_regular))
+ && (!info->shared || !SYMBOLIC_BIND (info, h) || !h->def_regular))
outrel.r_info = ELFNN_R_INFO (h->dynindx, r_type);
else
{
diff --git a/bfd/version.h b/bfd/version.h
index c806928..8a10575 100644
--- a/bfd/version.h
+++ b/bfd/version.h
@@ -1,4 +1,4 @@
-#define BFD_VERSION_DATE 20141223
+#define BFD_VERSION_DATE 20150207
#define BFD_VERSION @bfd_version@
#define BFD_VERSION_STRING @bfd_version_package@ @bfd_version_string@
#define REPORT_BUGS_TO @report_bugs_to@
diff --git a/bfd/version.m4 b/bfd/version.m4
index 4c966bc..57a10f8 100644
--- a/bfd/version.m4
+++ b/bfd/version.m4
@@ -1 +1 @@
-m4_define([BFD_VERSION], [2.25])
+m4_define([BFD_VERSION], [2.25.0])
diff --git a/binutils/ChangeLog b/binutils/ChangeLog
index db0941d..f26c706 100644
--- a/binutils/ChangeLog
+++ b/binutils/ChangeLog
@@ -2,6 +2,10 @@
* configure: Regenerate.
+2014-12-23 Tristan Gingold <gingold@adacore.com>
+
+ * configure: Regenerate.
+
2014-11-17 Nick Clifton <nickc@redhat.com>
Apply trunk patches:
diff --git a/binutils/configure b/binutils/configure
index b31248f..7c5b074 100755
--- a/binutils/configure
+++ b/binutils/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.64 for binutils 2.25.
+# Generated by GNU Autoconf 2.64 for binutils 2.25.0.
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
@@ -556,8 +556,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='binutils'
PACKAGE_TARNAME='binutils'
-PACKAGE_VERSION='2.25'
-PACKAGE_STRING='binutils 2.25'
+PACKAGE_VERSION='2.25.0'
+PACKAGE_STRING='binutils 2.25.0'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''
@@ -1333,7 +1333,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures binutils 2.25 to adapt to many kinds of systems.
+\`configure' configures binutils 2.25.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1404,7 +1404,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of binutils 2.25:";;
+ short | recursive ) echo "Configuration of binutils 2.25.0:";;
esac
cat <<\_ACEOF
@@ -1525,7 +1525,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-binutils configure 2.25
+binutils configure 2.25.0
generated by GNU Autoconf 2.64
Copyright (C) 2009 Free Software Foundation, Inc.
@@ -1935,7 +1935,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by binutils $as_me 2.25, which was
+It was created by binutils $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
$ $0 $@
@@ -3743,7 +3743,7 @@ fi
# Define the identity of the package.
PACKAGE='binutils'
- VERSION='2.25'
+ VERSION='2.25.0'
cat >>confdefs.h <<_ACEOF
@@ -14850,7 +14850,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by binutils $as_me 2.25, which was
+This file was extended by binutils $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -14914,7 +14914,7 @@ Report bugs to the package provider."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-binutils config.status 2.25
+binutils config.status 2.25.0
configured by $0, generated by GNU Autoconf 2.64,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
diff --git a/gas/ChangeLog b/gas/ChangeLog
index de5e997..b4f0eea 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,12 @@
+2015-01-28 Matthew Wahab <matthew.wahab@arm.com>
+
+ * config/tc-arm.c (parse_ifimm_zero): Accept #0x0 as a synonym for #0,
+ restoring previous behaviour.
+
+2014-12-23 Tristan Gingold <gingold@adacore.com>
+
+ * configure: Regenerate.
+
2014-12-23 Tristan Gingold <gingold@adacore.com>
* configure: Regenerate.
diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
index 5077f87..2db6c2d 100644
--- a/gas/config/tc-arm.c
+++ b/gas/config/tc-arm.c
@@ -4959,6 +4959,16 @@ parse_ifimm_zero (char **in)
return FALSE;
++*in;
+
+ /* Accept #0x0 as a synonym for #0. */
+ if (strncmp (*in, "0x", 2) == 0)
+ {
+ int val;
+ if (parse_immediate (in, &val, 0, 0, TRUE) == FAIL)
+ return FALSE;
+ return TRUE;
+ }
+
error_code = atof_generic (in, ".", EXP_CHARS,
&generic_floating_point_number);
diff --git a/gas/configure b/gas/configure
index 76b5f20..e9ba550 100755
--- a/gas/configure
+++ b/gas/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.64 for gas 2.25.
+# Generated by GNU Autoconf 2.64 for gas 2.25.0.
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
@@ -556,8 +556,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='gas'
PACKAGE_TARNAME='gas'
-PACKAGE_VERSION='2.25'
-PACKAGE_STRING='gas 2.25'
+PACKAGE_VERSION='2.25.0'
+PACKAGE_STRING='gas 2.25.0'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''
@@ -1320,7 +1320,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures gas 2.25 to adapt to many kinds of systems.
+\`configure' configures gas 2.25.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1391,7 +1391,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of gas 2.25:";;
+ short | recursive ) echo "Configuration of gas 2.25.0:";;
esac
cat <<\_ACEOF
@@ -1505,7 +1505,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-gas configure 2.25
+gas configure 2.25.0
generated by GNU Autoconf 2.64
Copyright (C) 2009 Free Software Foundation, Inc.
@@ -1915,7 +1915,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by gas $as_me 2.25, which was
+It was created by gas $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
$ $0 $@
@@ -3723,7 +3723,7 @@ fi
# Define the identity of the package.
PACKAGE='gas'
- VERSION='2.25'
+ VERSION='2.25.0'
cat >>confdefs.h <<_ACEOF
@@ -15061,7 +15061,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by gas $as_me 2.25, which was
+This file was extended by gas $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -15125,7 +15125,7 @@ Report bugs to the package provider."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-gas config.status 2.25
+gas config.status 2.25.0
configured by $0, generated by GNU Autoconf 2.64,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index d53d518..cea61aa 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,9 @@
+2015-01-28 Matthew Fortune <matthew.fortune@imgtec.com>
+
+ * gas/arm/ual-vcmp.s: Add vcmp, vcmpe with #0x0 operand.
+ * gas/ual/vcmp.d: Update expected output.
+ * gas/ual/vcmp-zero-bad.l: Likewise
+
2014-12-19 Matthew Fortune <matthew.fortune@imgtec.com>
* gas/mips/r6-64.s: Remove .align directives from LDPC
diff --git a/gas/testsuite/gas/arm/ual-vcmp.d b/gas/testsuite/gas/arm/ual-vcmp.d
index 2e9fb3d..5b1b6ce 100644
--- a/gas/testsuite/gas/arm/ual-vcmp.d
+++ b/gas/testsuite/gas/arm/ual-vcmp.d
@@ -14,11 +14,15 @@ Disassembly of section .text:
0+014 <[^>]*> eeb53a40 vcmp.f32 s6, #0.0
0+018 <[^>]*> eef53ac0 vcmpe.f32 s7, #0.0
0+01c <[^>]*> eeb54ac0 vcmpe.f32 s8, #0.0
-0+020 <[^>]*> eeb50b40 vcmp.f64 d0, #0.0
-0+024 <[^>]*> eeb51b40 vcmp.f64 d1, #0.0
-0+028 <[^>]*> eeb52bc0 vcmpe.f64 d2, #0.0
-0+02c <[^>]*> eeb53bc0 vcmpe.f64 d3, #0.0
-0+030 <[^>]*> eeb54b40 vcmp.f64 d4, #0.0
-0+034 <[^>]*> eeb55b40 vcmp.f64 d5, #0.0
-0+038 <[^>]*> eeb56bc0 vcmpe.f64 d6, #0.0
-0+03c <[^>]*> eeb57bc0 vcmpe.f64 d7, #0.0
\ No newline at end of file
+0+020 <[^>]*> eef54a40 vcmp.f32 s9, #0.0
+0+024 <[^>]*> eeb55ac0 vcmpe.f32 s10, #0.0
+0+028 <[^>]*> eeb50b40 vcmp.f64 d0, #0.0
+0+02c <[^>]*> eeb51b40 vcmp.f64 d1, #0.0
+0+030 <[^>]*> eeb52bc0 vcmpe.f64 d2, #0.0
+0+034 <[^>]*> eeb53bc0 vcmpe.f64 d3, #0.0
+0+038 <[^>]*> eeb54b40 vcmp.f64 d4, #0.0
+0+03c <[^>]*> eeb55b40 vcmp.f64 d5, #0.0
+0+040 <[^>]*> eeb56bc0 vcmpe.f64 d6, #0.0
+0+044 <[^>]*> eeb57bc0 vcmpe.f64 d7, #0.0
+0+048 <[^>]*> eeb58b40 vcmp.f64 d8, #0.0
+0+04c <[^>]*> eeb59bc0 vcmpe.f64 d9, #0.0
\ No newline at end of file
diff --git a/gas/testsuite/gas/arm/ual-vcmp.s b/gas/testsuite/gas/arm/ual-vcmp.s
index 79efa4e..1b9ffa6 100644
--- a/gas/testsuite/gas/arm/ual-vcmp.s
+++ b/gas/testsuite/gas/arm/ual-vcmp.s
@@ -10,6 +10,8 @@ vcmp.f32 s5, #0.0e2
vcmp.f32 s6, #0e-3
vcmpe.f32 s7, #0.0000
vcmpe.f32 s8, #.0
+vcmp.f32 s9, #0x0
+vcmpe.f32 s10, #0x0
vcmp.f64 d0, #0.0
vcmp.f64 d1, #0
@@ -19,3 +21,5 @@ vcmp.f64 d4, #0.0e5
vcmp.f64 d5, #0e-2
vcmpe.f64 d6, #0.00
vcmpe.f64 d7, #.0
+vcmp.f64 d8, #0x0
+vcmpe.f64 d9, #0x0
diff --git a/gas/testsuite/gas/arm/vcmp-zero-bad.l b/gas/testsuite/gas/arm/vcmp-zero-bad.l
index 975d02b..bce8e4a 100644
--- a/gas/testsuite/gas/arm/vcmp-zero-bad.l
+++ b/gas/testsuite/gas/arm/vcmp-zero-bad.l
@@ -4,5 +4,5 @@
[^:]*:7: Error: only floating point zero is allowed as immediate value -- `vcmpe.f32 s3,5'
[^:]*:8: Error: only floating point zero is allowed as immediate value -- `vcmpe.f32 s4,#-0.0'
[^:]*:10: Error: only floating point zero is allowed as immediate value -- `vcmp.f64 d0,#-1'
-[^:]*:11: Error: garbage following instruction -- `vcmpe.f64 d3,#0x35'
+[^:]*:11: Error: only floating point zero is allowed as immediate value -- `vcmpe.f64 d3,#0x35'
[^:]*:12: Error: only floating point zero is allowed as immediate value -- `vcmpe.f64 d4,0xf'
diff --git a/gold/ChangeLog b/gold/ChangeLog
index 2220da2..f10d114 100644
--- a/gold/ChangeLog
+++ b/gold/ChangeLog
@@ -1,3 +1,36 @@
+2015-01-06 H.J. Lu <hongjiu.lu@intel.com>
+ Cary Coutant <ccoutant@google.com>
+
+ PR gold/17729
+ * configure.ac (DEFAULT_TARGET_X86_64): Don't set for x32.
+ (DEFAULT_TARGET_X32): Set for x32.
+ * x86_64.cc (cmp_insn_32): New.
+ (lea_r10_insn_32): Likewise.
+ (lea_r11_insn_32): Likewise.
+ (cmp_insn_64): Likewise.
+ (lea_r10_insn_64): Likewise.
+ (lea_r11_insn_64): Likewise.
+ (Target_x86_64<size>::do_calls_non_split): Handle x32.
+ * testsuite/Makefile.am (check_SCRIPTS): Add split_x32.sh.
+ (check_DATA): Add split_x32 files.
+ (split_x32_[1234n].o): New targets.
+ (split_x32_[124]): New targets.
+ (split_x32_[1234r].stdout): New targets.
+ * testsuite/split_x32.sh: New file.
+ * testsuite/split_x32_1.s: Likewise.
+ * testsuite/split_x32_2.s: Likewise.
+ * testsuite/split_x32_3.s: Likewise.
+ * testsuite/split_x32_4.s: Likewise.
+ * testsuite/split_x32_n.s: Likewise.
+ * configure: Regenerated.
+ * testsuite/Makefile.in: Likewise.
+
+2015-01-06 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR gold/17809
+ * x86_64.cc (Target_x86_64<size>::Relocate::tls_ie_to_le): Handle
+ x32.
+
2014-12-04 Alan Modra <amodra@gmail.com>
* Powerpc.cc (Target_powerpc::Branch_info::make_stub): Ignore
diff --git a/gold/configure b/gold/configure
index 7d7b849..23e4735 100755
--- a/gold/configure
+++ b/gold/configure
@@ -688,6 +688,8 @@ DEFAULT_TARGET_MIPS_FALSE
DEFAULT_TARGET_MIPS_TRUE
DEFAULT_TARGET_TILEGX_FALSE
DEFAULT_TARGET_TILEGX_TRUE
+DEFAULT_TARGET_X32_FALSE
+DEFAULT_TARGET_X32_TRUE
DEFAULT_TARGET_X86_64_FALSE
DEFAULT_TARGET_X86_64_TRUE
DEFAULT_TARGET_SPARC_FALSE
@@ -3475,7 +3477,19 @@ else
DEFAULT_TARGET_SPARC_FALSE=
fi
- if test "$targ_obj" = "x86_64"; then
+ target_x86_64=no
+ target_x32=no
+ if test "$targ_obj" = "x86_64"; then
+ case "$target" in
+ x86_64*-linux-gnux32)
+ target_x32=yes
+ ;;
+ *)
+ target_x86_64=yes
+ ;;
+ esac
+ fi
+ if test "$target_x86_64" = "yes"; then
DEFAULT_TARGET_X86_64_TRUE=
DEFAULT_TARGET_X86_64_FALSE='#'
else
@@ -3483,6 +3497,14 @@ else
DEFAULT_TARGET_X86_64_FALSE=
fi
+ if test "$target_x32" = "yes"; then
+ DEFAULT_TARGET_X32_TRUE=
+ DEFAULT_TARGET_X32_FALSE='#'
+else
+ DEFAULT_TARGET_X32_TRUE='#'
+ DEFAULT_TARGET_X32_FALSE=
+fi
+
if test "$targ_obj" = "tilegx"; then
DEFAULT_TARGET_TILEGX_TRUE=
DEFAULT_TARGET_TILEGX_FALSE='#'
@@ -7811,6 +7833,10 @@ if test -z "${DEFAULT_TARGET_X86_64_TRUE}" && test -z "${DEFAULT_TARGET_X86_64_F
as_fn_error "conditional \"DEFAULT_TARGET_X86_64\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
+if test -z "${DEFAULT_TARGET_X32_TRUE}" && test -z "${DEFAULT_TARGET_X32_FALSE}"; then
+ as_fn_error "conditional \"DEFAULT_TARGET_X32\" was never defined.
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
+fi
if test -z "${DEFAULT_TARGET_TILEGX_TRUE}" && test -z "${DEFAULT_TARGET_TILEGX_FALSE}"; then
as_fn_error "conditional \"DEFAULT_TARGET_TILEGX\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
diff --git a/gold/configure.ac b/gold/configure.ac
index 0478011..64e603a 100644
--- a/gold/configure.ac
+++ b/gold/configure.ac
@@ -204,7 +204,20 @@ for targ in $target $canon_targets; do
AM_CONDITIONAL(DEFAULT_TARGET_I386, test "$targ_obj" = "i386")
AM_CONDITIONAL(DEFAULT_TARGET_POWERPC, test "$targ_obj" = "powerpc")
AM_CONDITIONAL(DEFAULT_TARGET_SPARC, test "$targ_obj" = "sparc")
- AM_CONDITIONAL(DEFAULT_TARGET_X86_64, test "$targ_obj" = "x86_64")
+ target_x86_64=no
+ target_x32=no
+ if test "$targ_obj" = "x86_64"; then
+ case "$target" in
+ x86_64*-linux-gnux32)
+ target_x32=yes
+ ;;
+ *)
+ target_x86_64=yes
+ ;;
+ esac
+ fi
+ AM_CONDITIONAL(DEFAULT_TARGET_X86_64, test "$target_x86_64" = "yes")
+ AM_CONDITIONAL(DEFAULT_TARGET_X32, test "$target_x32" = "yes")
AM_CONDITIONAL(DEFAULT_TARGET_TILEGX, test "$targ_obj" = "tilegx")
AM_CONDITIONAL(DEFAULT_TARGET_MIPS, test "$targ_obj" = "mips")
DEFAULT_TARGET=${targ_obj}
diff --git a/gold/testsuite/Makefile.am b/gold/testsuite/Makefile.am
index 35cd013..e015a3d 100644
--- a/gold/testsuite/Makefile.am
+++ b/gold/testsuite/Makefile.am
@@ -2483,6 +2483,43 @@ MOSTLYCLEANFILES += split_x86_64_1 split_x86_64_2 split_x86_64_3 \
endif DEFAULT_TARGET_X86_64
+if DEFAULT_TARGET_X32
+
+check_SCRIPTS += split_x32.sh
+check_DATA += split_x32_1.stdout split_x32_2.stdout \
+ split_x32_3.stdout split_x32_4.stdout split_x32_r.stdout
+SPLIT_DEFSYMS = --defsym __morestack=0x100 --defsym __morestack_non_split=0x200
+split_x32_1.o: split_x32_1.s
+ $(TEST_AS) -o $@ $<
+split_x32_2.o: split_x32_2.s
+ $(TEST_AS) -o $@ $<
+split_x32_3.o: split_x32_3.s
+ $(TEST_AS) -o $@ $<
+split_x32_4.o: split_x32_4.s
+ $(TEST_AS) -o $@ $<
+split_x32_n.o: split_x32_n.s
+ $(TEST_AS) -o $@ $<
+split_x32_1: split_x32_1.o split_x32_n.o ../ld-new
+ ../ld-new $(SPLIT_DEFSYMS) -o $@ split_x32_1.o split_x32_n.o
+split_x32_1.stdout: split_x32_1
+ $(TEST_OBJDUMP) -d $< > $@
+split_x32_2: split_x32_2.o split_x32_n.o ../ld-new
+ ../ld-new $(SPLIT_DEFSYMS) -o $@ split_x32_2.o split_x32_n.o
+split_x32_2.stdout: split_x32_2
+ $(TEST_OBJDUMP) -d $< > $@
+split_x32_3.stdout: split_x32_3.o split_x32_n.o ../ld-new
+ ../ld-new $(SPLIT_DEFSYMS) -o split_x32_3 split_x32_3.o split_x32_n.o > $@ 2>&1 || exit 0
+split_x32_4: split_x32_4.o split_x32_n.o ../ld-new
+ ../ld-new $(SPLIT_DEFSYMS) -o $@ split_x32_4.o split_x32_n.o
+split_x32_4.stdout: split_x32_4
+ $(TEST_OBJDUMP) -d $< > $@
+split_x32_r.stdout: split_x32_1.o split_x32_n.o ../ld-new
+ ../ld-new -r split_x32_1.o split_x32_n.o -o split_x32_r > $@ 2>&1 || exit 0
+MOSTLYCLEANFILES += split_x32_1 split_x32_2 split_x32_3 \
+ split_x32_4 split_x32_r
+
+endif DEFAULT_TARGET_X32
+
if DEFAULT_TARGET_ARM
check_SCRIPTS += arm_abs_global.sh
diff --git a/gold/testsuite/Makefile.in b/gold/testsuite/Makefile.in
index 8fbb644..befef5f 100644
--- a/gold/testsuite/Makefile.in
+++ b/gold/testsuite/Makefile.in
@@ -623,6 +623,13 @@ check_PROGRAMS = $(am__EXEEXT_1) $(am__EXEEXT_2) $(am__EXEEXT_3) \
@DEFAULT_TARGET_X86_64_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@am__append_83 = split_x86_64_1 split_x86_64_2 split_x86_64_3 \
@DEFAULT_TARGET_X86_64_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ split_x86_64_4 split_x86_64_r
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@am__append_84 = split_x32.sh
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@am__append_85 = split_x32_1.stdout split_x32_2.stdout \
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ split_x32_3.stdout split_x32_4.stdout split_x32_r.stdout
+
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@am__append_86 = split_x32_1 split_x32_2 split_x32_3 \
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ split_x32_4 split_x32_r
+
# ARM1176 workaround test.
@@ -635,7 +642,7 @@ check_PROGRAMS = $(am__EXEEXT_1) $(am__EXEEXT_2) $(am__EXEEXT_3) \
# Check Thumb to Thumb farcall veneers
# Check Thumb to ARM farcall veneers
-@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@am__append_84 = arm_abs_global.sh \
+@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@am__append_87 = arm_abs_global.sh \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_branch_in_range.sh \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_branch_out_of_range.sh \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_fix_v4bx.sh \
@@ -649,7 +656,7 @@ check_PROGRAMS = $(am__EXEEXT_1) $(am__EXEEXT_2) $(am__EXEEXT_3) \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_farcall_arm_thumb.sh \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_farcall_thumb_thumb.sh \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_farcall_thumb_arm.sh
-@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@am__append_85 = arm_abs_global.stdout \
+@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@am__append_88 = arm_abs_global.stdout \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_bl_in_range.stdout \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_bl_out_of_range.stdout \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ thumb_bl_in_range.stdout \
@@ -694,7 +701,7 @@ check_PROGRAMS = $(am__EXEEXT_1) $(am__EXEEXT_2) $(am__EXEEXT_3) \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_farcall_thumb_thumb_6m.stdout \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_farcall_thumb_arm.stdout \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_farcall_thumb_arm_5t.stdout
-@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@am__append_86 = arm_abs_global \
+@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@am__append_89 = arm_abs_global \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_bl_in_range \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_bl_out_of_range \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ thumb_bl_in_range \
@@ -737,10 +744,10 @@ check_PROGRAMS = $(am__EXEEXT_1) $(am__EXEEXT_2) $(am__EXEEXT_3) \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_farcall_thumb_thumb_6m \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_farcall_thumb_arm \
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ arm_farcall_thumb_arm_5t
-@DEFAULT_TARGET_X86_64_TRUE@am__append_87 = *.dwo *.dwp
-@DEFAULT_TARGET_X86_64_TRUE@am__append_88 = dwp_test_1.sh \
+@DEFAULT_TARGET_X86_64_TRUE@am__append_90 = *.dwo *.dwp
+@DEFAULT_TARGET_X86_64_TRUE@am__append_91 = dwp_test_1.sh \
@DEFAULT_TARGET_X86_64_TRUE@ dwp_test_2.sh
-@DEFAULT_TARGET_X86_64_TRUE@am__append_89 = dwp_test_1.stdout \
+@DEFAULT_TARGET_X86_64_TRUE@am__append_92 = dwp_test_1.stdout \
@DEFAULT_TARGET_X86_64_TRUE@ dwp_test_2.stdout
subdir = testsuite
DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am
@@ -2224,7 +2231,8 @@ MOSTLYCLEANFILES = *.so *.syms *.stdout $(am__append_4) \
$(am__append_41) $(am__append_47) $(am__append_63) \
$(am__append_66) $(am__append_69) $(am__append_72) \
$(am__append_74) $(am__append_77) $(am__append_80) \
- $(am__append_83) $(am__append_86) $(am__append_87)
+ $(am__append_83) $(am__append_86) $(am__append_89) \
+ $(am__append_90)
# We will add to these later, for each individual test. Note
# that we add each test under check_SCRIPTS or check_PROGRAMS;
@@ -2233,13 +2241,13 @@ check_SCRIPTS = $(am__append_2) $(am__append_34) $(am__append_38) \
$(am__append_42) $(am__append_45) $(am__append_61) \
$(am__append_64) $(am__append_67) $(am__append_70) \
$(am__append_75) $(am__append_78) $(am__append_81) \
- $(am__append_84) $(am__append_88)
+ $(am__append_84) $(am__append_87) $(am__append_91)
check_DATA = $(am__append_3) $(am__append_27) $(am__append_29) \
$(am__append_35) $(am__append_39) $(am__append_43) \
$(am__append_46) $(am__append_62) $(am__append_65) \
$(am__append_68) $(am__append_71) $(am__append_76) \
$(am__append_79) $(am__append_82) $(am__append_85) \
- $(am__append_89)
+ $(am__append_88) $(am__append_92)
BUILT_SOURCES = $(am__append_25)
TESTS = $(check_SCRIPTS) $(check_PROGRAMS)
@@ -2736,6 +2744,7 @@ LDADD = libgoldtest.a ../libgold.a ../../libiberty/libiberty.a $(LIBINTL) \
@DEFAULT_TARGET_X86_64_TRUE@@GCC_TRUE@@NATIVE_LINKER_TRUE@exception_x86_64_bnd_test_LDFLAGS = $(exception_test_LDFLAGS)
@DEFAULT_TARGET_X86_64_TRUE@@GCC_TRUE@@NATIVE_LINKER_TRUE@exception_x86_64_bnd_test_LDADD = exception_x86_64_bnd_1.o exception_x86_64_bnd_2.o
@DEFAULT_TARGET_I386_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@SPLIT_DEFSYMS = --defsym __morestack=0x100 --defsym __morestack_non_split=0x200
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@SPLIT_DEFSYMS = --defsym __morestack=0x100 --defsym __morestack_non_split=0x200
@DEFAULT_TARGET_X86_64_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@SPLIT_DEFSYMS = --defsym __morestack=0x100 --defsym __morestack_non_split=0x200
all: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) all-am
@@ -4166,6 +4175,8 @@ split_i386.sh.log: split_i386.sh
@p='split_i386.sh'; $(am__check_pre) $(LOG_COMPILE) "$$tst" $(am__check_post)
split_x86_64.sh.log: split_x86_64.sh
@p='split_x86_64.sh'; $(am__check_pre) $(LOG_COMPILE) "$$tst" $(am__check_post)
+split_x32.sh.log: split_x32.sh
+ @p='split_x32.sh'; $(am__check_pre) $(LOG_COMPILE) "$$tst" $(am__check_post)
arm_abs_global.sh.log: arm_abs_global.sh
@p='arm_abs_global.sh'; $(am__check_pre) $(LOG_COMPILE) "$$tst" $(am__check_post)
arm_branch_in_range.sh.log: arm_branch_in_range.sh
@@ -5777,6 +5788,32 @@ uninstall-am:
@DEFAULT_TARGET_X86_64_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ $(TEST_OBJDUMP) -d $< > $@
@DEFAULT_TARGET_X86_64_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x86_64_r.stdout: split_x86_64_1.o split_x86_64_n.o ../ld-new
@DEFAULT_TARGET_X86_64_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ ../ld-new -r split_x86_64_1.o split_x86_64_n.o -o split_x86_64_r > $@ 2>&1 || exit 0
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_1.o: split_x32_1.s
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ $(TEST_AS) -o $@ $<
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_2.o: split_x32_2.s
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ $(TEST_AS) -o $@ $<
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_3.o: split_x32_3.s
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ $(TEST_AS) -o $@ $<
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_4.o: split_x32_4.s
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ $(TEST_AS) -o $@ $<
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_n.o: split_x32_n.s
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ $(TEST_AS) -o $@ $<
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_1: split_x32_1.o split_x32_n.o ../ld-new
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ ../ld-new $(SPLIT_DEFSYMS) -o $@ split_x32_1.o split_x32_n.o
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_1.stdout: split_x32_1
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ $(TEST_OBJDUMP) -d $< > $@
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_2: split_x32_2.o split_x32_n.o ../ld-new
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ ../ld-new $(SPLIT_DEFSYMS) -o $@ split_x32_2.o split_x32_n.o
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_2.stdout: split_x32_2
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ $(TEST_OBJDUMP) -d $< > $@
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_3.stdout: split_x32_3.o split_x32_n.o ../ld-new
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ ../ld-new $(SPLIT_DEFSYMS) -o split_x32_3 split_x32_3.o split_x32_n.o > $@ 2>&1 || exit 0
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_4: split_x32_4.o split_x32_n.o ../ld-new
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ ../ld-new $(SPLIT_DEFSYMS) -o $@ split_x32_4.o split_x32_n.o
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_4.stdout: split_x32_4
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ $(TEST_OBJDUMP) -d $< > $@
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@split_x32_r.stdout: split_x32_1.o split_x32_n.o ../ld-new
+@DEFAULT_TARGET_X32_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ ../ld-new -r split_x32_1.o split_x32_n.o -o split_x32_r > $@ 2>&1 || exit 0
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@arm_abs_lib.o: arm_abs_lib.s
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@ $(TEST_AS) -march=armv7-a -o $@ $<
@DEFAULT_TARGET_ARM_TRUE@@NATIVE_OR_CROSS_LINKER_TRUE@libarm_abs.so: arm_abs_lib.o ../ld-new
diff --git a/gold/testsuite/split_x32.sh b/gold/testsuite/split_x32.sh
new file mode 100755
index 0000000..0bc0cf3
--- /dev/null
+++ b/gold/testsuite/split_x32.sh
@@ -0,0 +1,55 @@
+#!/bin/sh
+
+# split_x32.sh -- test -fstack-split for x32
+
+# Copyright (C) 2014 Free Software Foundation, Inc.
+# Written by Ian Lance Taylor <iant@google.com>.
+# Modified by H.J. Lu <hongjiu.lu@intel.com>.
+
+# This file is part of gold.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
+# MA 02110-1301, USA.
+
+match()
+{
+ if ! egrep "$1" "$2" >/dev/null 2>&1; then
+ echo 1>&2 "could not find '$1' in $2"
+ exit 1
+ fi
+}
+
+nomatch()
+{
+ if egrep "$1" "$2" >/dev/null 2>&1; then
+ echo 1>&2 "found unexpected '$1' in $2"
+ exit 1
+ fi
+}
+
+match 'cmp.*+%fs:[^,]*,%esp' split_x32_1.stdout
+match 'callq.*__morestack>?$' split_x32_1.stdout
+match 'lea.*-0x200\(%rsp\),' split_x32_1.stdout
+
+match 'stc' split_x32_2.stdout
+match 'callq.*__morestack_non_split>?$' split_x32_2.stdout
+nomatch 'callq.*__morestack>?$' split_x32_2.stdout
+match 'lea.*-0x4200\(%rsp\),' split_x32_2.stdout
+
+match 'failed to match' split_x32_3.stdout
+
+match 'callq.*__morestack>?$' split_x32_4.stdout
+
+match 'cannot mix' split_x32_r.stdout
diff --git a/gold/testsuite/split_x32_1.s b/gold/testsuite/split_x32_1.s
new file mode 100644
index 0000000..b78936e
--- /dev/null
+++ b/gold/testsuite/split_x32_1.s
@@ -0,0 +1,33 @@
+# split_x32_1.s: x32 specific test case for -fsplit-stack.
+
+ .text
+
+ .global fn1
+ .type fn1,@function
+fn1:
+ cmp %fs:0x40,%esp
+ jae 1f
+ callq __morestack
+ retq
+1:
+ callq fn2
+ retq
+
+ .size fn1,. - fn1
+
+ .global fn2
+ .type fn2,@function
+fn2:
+ lea -0x200(%rsp),%r10d
+ cmp %fs:0x40,%r10d
+ jae 1f
+ callq __morestack
+ retq
+1:
+ callq fn1
+ retq
+
+ .size fn2,. - fn2
+
+ .section .note.GNU-stack,"",@progbits
+ .section .note.GNU-split-stack,"",@progbits
diff --git a/gold/testsuite/split_x32_2.s b/gold/testsuite/split_x32_2.s
new file mode 100644
index 0000000..b789afd
--- /dev/null
+++ b/gold/testsuite/split_x32_2.s
@@ -0,0 +1,33 @@
+# split_x32_2.s: x32 specific, -fsplit-stack calling non-split
+
+ .text
+
+ .global fn1
+ .type fn1,@function
+fn1:
+ cmp %fs:0x40,%esp
+ jae 1f
+ callq __morestack
+ retq
+1:
+ callq fn3
+ retq
+
+ .size fn1,. - fn1
+
+ .global fn2
+ .type fn2,@function
+fn2:
+ lea -0x200(%rsp),%r10d
+ cmp %fs:0x40,%r10d
+ jae 1f
+ callq __morestack
+ retq
+1:
+ callq fn3
+ retq
+
+ .size fn2,. - fn2
+
+ .section .note.GNU-stack,"",@progbits
+ .section .note.GNU-split-stack,"",@progbits
diff --git a/gold/testsuite/split_x32_3.s b/gold/testsuite/split_x32_3.s
new file mode 100644
index 0000000..d7b09bd
--- /dev/null
+++ b/gold/testsuite/split_x32_3.s
@@ -0,0 +1,22 @@
+# split_x32_3.s: x32 specific, adjustment failure
+
+ .text
+
+ .global fn1
+ .type fn1,@function
+fn1:
+ push %rbp
+ mov %esp,%ebp
+ cmp %fs:0x40,%esp
+ jae 1f
+ callq __morestack
+ retq
+1:
+ callq fn3
+ leaveq
+ retq
+
+ .size fn1,. - fn1
+
+ .section .note.GNU-stack,"",@progbits
+ .section .note.GNU-split-stack,"",@progbits
diff --git a/gold/testsuite/split_x32_4.s b/gold/testsuite/split_x32_4.s
new file mode 100644
index 0000000..1f4eece
--- /dev/null
+++ b/gold/testsuite/split_x32_4.s
@@ -0,0 +1,23 @@
+# split_x32_4.s: x32 specific, permitted adjustment failure
+
+ .text
+
+ .global fn1
+ .type fn1,@function
+fn1:
+ push %rbp
+ mov %esp,%ebp
+ cmp %fs:0x40,%esp
+ jae 1f
+ callq __morestack
+ retq
+1:
+ callq fn3
+ leaveq
+ retq
+
+ .size fn1,. - fn1
+
+ .section .note.GNU-stack,"",@progbits
+ .section .note.GNU-split-stack,"",@progbits
+ .section .note.GNU-no-split-stack,"",@progbits
diff --git a/gold/testsuite/split_x32_n.s b/gold/testsuite/split_x32_n.s
new file mode 100644
index 0000000..54c0db6
--- /dev/null
+++ b/gold/testsuite/split_x32_n.s
@@ -0,0 +1,12 @@
+# split_x32_n.s: x32 specific, -fsplit-stack calling non-split
+
+ .text
+
+ .global fn3
+ .type fn3,@function
+fn3:
+ retq
+
+ .size fn3,. - fn3
+
+ .section .note.GNU-stack,"",@progbits
diff --git a/gold/x86_64.cc b/gold/x86_64.cc
index f58c843..10c75a2 100644
--- a/gold/x86_64.cc
+++ b/gold/x86_64.cc
@@ -4100,6 +4100,8 @@ Target_x86_64<size>::Relocate::tls_ie_to_le(
// movq
if (op1 == 0x4c)
view[-3] = 0x49;
+ else if (size == 32 && op1 == 0x44)
+ view[-3] = 0x41;
view[-2] = 0xc7;
view[-1] = 0xc0 | reg;
}
@@ -4108,6 +4110,8 @@ Target_x86_64<size>::Relocate::tls_ie_to_le(
// Special handling for %rsp.
if (op1 == 0x4c)
view[-3] = 0x49;
+ else if (size == 32 && op1 == 0x44)
+ view[-3] = 0x41;
view[-2] = 0x81;
view[-1] = 0xc0 | reg;
}
@@ -4116,6 +4120,8 @@ Target_x86_64<size>::Relocate::tls_ie_to_le(
// addq
if (op1 == 0x4c)
view[-3] = 0x4d;
+ else if (size == 32 && op1 == 0x44)
+ view[-3] = 0x45;
view[-2] = 0x8d;
view[-1] = 0x80 | reg | (reg << 3);
}
@@ -4457,6 +4463,14 @@ Target_x86_64<size>::do_ehframe_datarel_base() const
// code. We have to change the function so that it always ensures
// that it has enough stack space to run some random function.
+static const unsigned char cmp_insn_32[] = { 0x64, 0x3b, 0x24, 0x25 };
+static const unsigned char lea_r10_insn_32[] = { 0x44, 0x8d, 0x94, 0x24 };
+static const unsigned char lea_r11_insn_32[] = { 0x44, 0x8d, 0x9c, 0x24 };
+
+static const unsigned char cmp_insn_64[] = { 0x64, 0x48, 0x3b, 0x24, 0x25 };
+static const unsigned char lea_r10_insn_64[] = { 0x4c, 0x8d, 0x94, 0x24 };
+static const unsigned char lea_r11_insn_64[] = { 0x4c, 0x8d, 0x9c, 0x24 };
+
template<int size>
void
Target_x86_64<size>::do_calls_non_split(Relobj* object, unsigned int shndx,
@@ -4467,25 +4481,40 @@ Target_x86_64<size>::do_calls_non_split(Relobj* object, unsigned int shndx,
std::string* from,
std::string* to) const
{
+ const char* const cmp_insn = reinterpret_cast<const char*>
+ (size == 32 ? cmp_insn_32 : cmp_insn_64);
+ const char* const lea_r10_insn = reinterpret_cast<const char*>
+ (size == 32 ? lea_r10_insn_32 : lea_r10_insn_64);
+ const char* const lea_r11_insn = reinterpret_cast<const char*>
+ (size == 32 ? lea_r11_insn_32 : lea_r11_insn_64);
+
+ const size_t cmp_insn_len =
+ (size == 32 ? sizeof(cmp_insn_32) : sizeof(cmp_insn_64));
+ const size_t lea_r10_insn_len =
+ (size == 32 ? sizeof(lea_r10_insn_32) : sizeof(lea_r10_insn_64));
+ const size_t lea_r11_insn_len =
+ (size == 32 ? sizeof(lea_r11_insn_32) : sizeof(lea_r11_insn_64));
+ const size_t nop_len = (size == 32 ? 7 : 8);
+
// The function starts with a comparison of the stack pointer and a
// field in the TCB. This is followed by a jump.
// cmp %fs:NN,%rsp
- if (this->match_view(view, view_size, fnoffset, "\x64\x48\x3b\x24\x25", 5)
- && fnsize > 9)
+ if (this->match_view(view, view_size, fnoffset, cmp_insn, cmp_insn_len)
+ && fnsize > nop_len + 1)
{
// We will call __morestack if the carry flag is set after this
// comparison. We turn the comparison into an stc instruction
// and some nops.
view[fnoffset] = '\xf9';
- this->set_view_to_nop(view, view_size, fnoffset + 1, 8);
+ this->set_view_to_nop(view, view_size, fnoffset + 1, nop_len);
}
// lea NN(%rsp),%r10
// lea NN(%rsp),%r11
else if ((this->match_view(view, view_size, fnoffset,
- "\x4c\x8d\x94\x24", 4)
+ lea_r10_insn, lea_r10_insn_len)
|| this->match_view(view, view_size, fnoffset,
- "\x4c\x8d\x9c\x24", 4))
+ lea_r11_insn, lea_r11_insn_len))
&& fnsize > 8)
{
// This is loading an offset from the stack pointer for a
diff --git a/gprof/ChangeLog b/gprof/ChangeLog
index 866eb0d..af2ce55 100644
--- a/gprof/ChangeLog
+++ b/gprof/ChangeLog
@@ -2,6 +2,10 @@
* configure: Regenerate.
+2014-12-23 Tristan Gingold <gingold@adacore.com>
+
+ * configure: Regenerate.
+
2014-11-03 Nick Clifton <nickc@redhat.com>
* po/fi.po: Updated Finnish translation.
diff --git a/gprof/configure b/gprof/configure
index a6f7ac7..b09c8fb 100755
--- a/gprof/configure
+++ b/gprof/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.64 for gprof 2.25.
+# Generated by GNU Autoconf 2.64 for gprof 2.25.0.
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
@@ -556,8 +556,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='gprof'
PACKAGE_TARNAME='gprof'
-PACKAGE_VERSION='2.25'
-PACKAGE_STRING='gprof 2.25'
+PACKAGE_VERSION='2.25.0'
+PACKAGE_STRING='gprof 2.25.0'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''
@@ -1299,7 +1299,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures gprof 2.25 to adapt to many kinds of systems.
+\`configure' configures gprof 2.25.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1370,7 +1370,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of gprof 2.25:";;
+ short | recursive ) echo "Configuration of gprof 2.25.0:";;
esac
cat <<\_ACEOF
@@ -1476,7 +1476,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-gprof configure 2.25
+gprof configure 2.25.0
generated by GNU Autoconf 2.64
Copyright (C) 2009 Free Software Foundation, Inc.
@@ -1841,7 +1841,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by gprof $as_me 2.25, which was
+It was created by gprof $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
$ $0 $@
@@ -3649,7 +3649,7 @@ fi
# Define the identity of the package.
PACKAGE='gprof'
- VERSION='2.25'
+ VERSION='2.25.0'
cat >>confdefs.h <<_ACEOF
@@ -12706,7 +12706,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by gprof $as_me 2.25, which was
+This file was extended by gprof $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -12770,7 +12770,7 @@ Report bugs to the package provider."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-gprof config.status 2.25
+gprof config.status 2.25.0
configured by $0, generated by GNU Autoconf 2.64,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
diff --git a/ld/ChangeLog b/ld/ChangeLog
index 28dd353..3a6e3c3 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -2,6 +2,10 @@
* configure: Regenerate.
+2014-12-23 Tristan Gingold <gingold@adacore.com>
+
+ * configure: Regenerate.
+
2014-11-24 Alan Modra <amodra@gmail.com>
* ld.texinfo: Correct --plt-align documentation.
diff --git a/ld/configure b/ld/configure
index 66d8024..4408b0d 100755
--- a/ld/configure
+++ b/ld/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.64 for ld 2.25.
+# Generated by GNU Autoconf 2.64 for ld 2.25.0.
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
@@ -556,8 +556,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='ld'
PACKAGE_TARNAME='ld'
-PACKAGE_VERSION='2.25'
-PACKAGE_STRING='ld 2.25'
+PACKAGE_VERSION='2.25.0'
+PACKAGE_STRING='ld 2.25.0'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''
@@ -1347,7 +1347,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures ld 2.25 to adapt to many kinds of systems.
+\`configure' configures ld 2.25.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1418,7 +1418,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of ld 2.25:";;
+ short | recursive ) echo "Configuration of ld 2.25.0:";;
esac
cat <<\_ACEOF
@@ -1541,7 +1541,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-ld configure 2.25
+ld configure 2.25.0
generated by GNU Autoconf 2.64
Copyright (C) 2009 Free Software Foundation, Inc.
@@ -2250,7 +2250,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by ld $as_me 2.25, which was
+It was created by ld $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
$ $0 $@
@@ -4059,7 +4059,7 @@ fi
# Define the identity of the package.
PACKAGE='ld'
- VERSION='2.25'
+ VERSION='2.25.0'
cat >>confdefs.h <<_ACEOF
@@ -17594,7 +17594,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by ld $as_me 2.25, which was
+This file was extended by ld $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -17658,7 +17658,7 @@ Report bugs to the package provider."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-ld config.status 2.25
+ld config.status 2.25.0
configured by $0, generated by GNU Autoconf 2.64,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog
index f0344fd..1b1d935 100644
--- a/ld/testsuite/ChangeLog
+++ b/ld/testsuite/ChangeLog
@@ -1,3 +1,29 @@
+2015-01-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
+
+ Backport from mainline
+ 2015-01-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
+
+ * elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Use SYMBOLIC_BIND
+ to check if a symbol should be bound symbolically.
+
+2015-01-11 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR ld/17827
+ * ld-x86-64/pr17689.out: Updated.
+ * ld-x86-64/pr17689b.S: Likewise.
+
+ * ld-x86-64/pr17827.rd: New file.
+
+ * ld-x86-64/x86-64.exp: Run PR ld/17827 test.
+
+2015-01-05 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR ld/17773
+ * ld-elf/binutils.exp (binutils_test): Add an optional
+ readelf_options. Replace -l with $readelf_options. Add a
+ gap test.
+ * ld/testsuite/ld-elf/gap.s: New file.
+
2014-12-19 Matthew Fortune <matthew.fortune@imgtec.com>
* ld-mips-elf/attr-gnu-4-00.d: Relax check for ISA extension.
diff --git a/ld/testsuite/ld-aarch64/aarch64-elf.exp b/ld/testsuite/ld-aarch64/aarch64-elf.exp
index a75e070..c0bd39a 100644
--- a/ld/testsuite/ld-aarch64/aarch64-elf.exp
+++ b/ld/testsuite/ld-aarch64/aarch64-elf.exp
@@ -175,6 +175,7 @@ run_dump_test "ifunc-21"
run_dump_test "ifunc-22"
run_dump_test "relasz"
+run_dump_test "relocs-257-symbolic-func"
set aarch64elflinktests {
{"ld-aarch64/so with global symbol" "-shared" "" "" {copy-reloc-so.s}
diff --git a/ld/testsuite/ld-aarch64/relocs-257-symbolic-func.d b/ld/testsuite/ld-aarch64/relocs-257-symbolic-func.d
new file mode 100644
index 0000000..810fd43
--- /dev/null
+++ b/ld/testsuite/ld-aarch64/relocs-257-symbolic-func.d
@@ -0,0 +1,5 @@
+#source: relocs-257-symbolic-func.s
+#ld: -shared -Bsymbolic-functions
+#readelf: -r --wide
+#...
+.* +R_AARCH64_RELATIVE +.*
diff --git a/ld/testsuite/ld-aarch64/relocs-257-symbolic-func.s b/ld/testsuite/ld-aarch64/relocs-257-symbolic-func.s
new file mode 100644
index 0000000..35d5ba8
--- /dev/null
+++ b/ld/testsuite/ld-aarch64/relocs-257-symbolic-func.s
@@ -0,0 +1,11 @@
+ .text
+ .global tempy
+ .type tempy, %function
+tempy:
+ .size tempy, .-tempy
+ .section .data.rel
+ .align 3
+ .type tempy_ptr, %object
+ .size tempy_ptr, 8
+tempy_ptr:
+ .xword tempy
diff --git a/ld/testsuite/ld-elf/binutils.exp b/ld/testsuite/ld-elf/binutils.exp
index 4ade8cb..37ab6b3 100644
--- a/ld/testsuite/ld-elf/binutils.exp
+++ b/ld/testsuite/ld-elf/binutils.exp
@@ -38,8 +38,9 @@ if { [istarget *-*-linux*aout*]
# to hardwire the test name. This is important if ld_options contains
# absolute path names because the default test name is constructed
# from the prog_name and ld_options and we do not want absolute paths
-# to appear in the test_name.
-proc binutils_test { prog_name ld_options test {test_name ""}} {
+# to appear in the test_name. The optional readelf_options can be
+# used to specify different options for readelf.
+proc binutils_test { prog_name ld_options test {test_name ""} {readelf_options "-l"}} {
global as
global ld
global READELF
@@ -71,8 +72,8 @@ proc binutils_test { prog_name ld_options test {test_name ""}} {
return
}
- send_log "$READELF -l --wide tmpdir/$test > tmpdir/$test.exp\n"
- set got [remote_exec host "$READELF -l --wide tmpdir/$test" "" "/dev/null" "tmpdir/$test.exp"]
+ send_log "$READELF $readelf_options --wide tmpdir/$test > tmpdir/$test.exp\n"
+ set got [remote_exec host "$READELF $readelf_options --wide tmpdir/$test" "" "/dev/null" "tmpdir/$test.exp"]
if { [lindex $got 0] != 0 || ![string match "" [lindex $got 1]] } then {
send_log "$got\n"
unresolved "$test_name"
@@ -111,8 +112,8 @@ proc binutils_test { prog_name ld_options test {test_name ""}} {
return
}
- send_log "$READELF -l --wide tmpdir/$test > tmpdir/$test.out\n"
- set got [remote_exec host "$READELF -l --wide tmpdir/$test" "" "/dev/null" "tmpdir/$test.out"]
+ send_log "$READELF $readelf_options --wide tmpdir/$test > tmpdir/$test.out\n"
+ set got [remote_exec host "$READELF $readelf_options --wide tmpdir/$test" "" "/dev/null" "tmpdir/$test.out"]
if { [lindex $got 0] != 0 || ![string match "" [lindex $got 1]] } then {
send_log "$got\n"
unresolved "$test_name"
@@ -176,3 +177,5 @@ foreach testitem $tls_tests {
binutils_test objcopy $testopt $testitem
}
}
+
+binutils_test strip "-s" gap "" "-lS"
diff --git a/ld/testsuite/ld-elf/gap.s b/ld/testsuite/ld-elf/gap.s
new file mode 100644
index 0000000..039d26b
--- /dev/null
+++ b/ld/testsuite/ld-elf/gap.s
@@ -0,0 +1,4 @@
+ .text
+ .global _start
+_start:
+ .long 0
diff --git a/ld/testsuite/ld-x86-64/pr17689.out b/ld/testsuite/ld-x86-64/pr17689.out
index 7ef22e9..38e0352 100644
--- a/ld/testsuite/ld-x86-64/pr17689.out
+++ b/ld/testsuite/ld-x86-64/pr17689.out
@@ -1 +1,2 @@
PASS
+PASS
diff --git a/ld/testsuite/ld-x86-64/pr17689b.S b/ld/testsuite/ld-x86-64/pr17689b.S
index c95f891..64485c7 100644
--- a/ld/testsuite/ld-x86-64/pr17689b.S
+++ b/ld/testsuite/ld-x86-64/pr17689b.S
@@ -5,8 +5,18 @@ main:
subq $8, %rsp
movq bar_alias(%rip), %rdi
call foo@PLT
+ movq ptr(%rip), %rax
+ movq (%rax), %rdi
+ call foo@PLT
xorl %eax, %eax
addq $8, %rsp
ret
.size main, .-main
+ .globl ptr
+ .section .data.rel,"aw",@progbits
+ .align 8
+ .type ptr, @object
+ .size ptr, 8
+ptr:
+ .quad bar_alias
.section .note.GNU-stack,"",@progbits
diff --git a/ld/testsuite/ld-x86-64/pr17827.rd b/ld/testsuite/ld-x86-64/pr17827.rd
new file mode 100644
index 0000000..d78ea2f
--- /dev/null
+++ b/ld/testsuite/ld-x86-64/pr17827.rd
@@ -0,0 +1,4 @@
+#failif
+#...
+[0-9a-f ]+R_X86_64_NONE.*
+#...
diff --git a/ld/testsuite/ld-x86-64/x86-64.exp b/ld/testsuite/ld-x86-64/x86-64.exp
index 1119133..28e8108 100644
--- a/ld/testsuite/ld-x86-64/x86-64.exp
+++ b/ld/testsuite/ld-x86-64/x86-64.exp
@@ -373,6 +373,14 @@ if { [isnative] && [which $CC] != 0 } {
{{readelf {-Wr} pr17689.rd}} \
"pr17689" \
] \
+ [list \
+ "Build pr17827 with PIE without -fPIE" \
+ "tmpdir/pr17689.so -pie" \
+ "" \
+ { pr17689b.S } \
+ {{readelf {-Wr} pr17827.rd}} \
+ "pr17827" \
+ ] \
]
run_ld_link_exec_tests [] [list \
diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog
index 38de39a..e19e382 100644
--- a/opcodes/ChangeLog
+++ b/opcodes/ChangeLog
@@ -2,6 +2,10 @@
* configure: Regenerate.
+2014-12-23 Tristan Gingold <gingold@adacore.com>
+
+ * configure: Regenerate.
+
2014-12-16 Matthew Fortune <matthew.fortune@imgtec.com>
* mips-opc.c (mips_builtin_opcodes): Add JALRC alias for
diff --git a/opcodes/configure b/opcodes/configure
index 1361ef6..c9c04ce 100755
--- a/opcodes/configure
+++ b/opcodes/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.64 for opcodes 2.25.
+# Generated by GNU Autoconf 2.64 for opcodes 2.25.0.
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software
@@ -556,8 +556,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='opcodes'
PACKAGE_TARNAME='opcodes'
-PACKAGE_VERSION='2.25'
-PACKAGE_STRING='opcodes 2.25'
+PACKAGE_VERSION='2.25.0'
+PACKAGE_STRING='opcodes 2.25.0'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''
@@ -1319,7 +1319,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures opcodes 2.25 to adapt to many kinds of systems.
+\`configure' configures opcodes 2.25.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1390,7 +1390,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of opcodes 2.25:";;
+ short | recursive ) echo "Configuration of opcodes 2.25.0:";;
esac
cat <<\_ACEOF
@@ -1497,7 +1497,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-opcodes configure 2.25
+opcodes configure 2.25.0
generated by GNU Autoconf 2.64
Copyright (C) 2009 Free Software Foundation, Inc.
@@ -1907,7 +1907,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by opcodes $as_me 2.25, which was
+It was created by opcodes $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
$ $0 $@
@@ -3715,7 +3715,7 @@ fi
# Define the identity of the package.
PACKAGE='opcodes'
- VERSION='2.25'
+ VERSION='2.25.0'
cat >>confdefs.h <<_ACEOF
@@ -13209,7 +13209,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by opcodes $as_me 2.25, which was
+This file was extended by opcodes $as_me 2.25.0, which was
generated by GNU Autoconf 2.64. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -13273,7 +13273,7 @@ Report bugs to the package provider."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-opcodes config.status 2.25
+opcodes config.status 2.25.0
configured by $0, generated by GNU Autoconf 2.64,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"