Sync from SUSE:SLFO:Main binutils revision 8972e46073eeb2e8338846b2a89adb90
This commit is contained in:
parent
f17d6f9c5c
commit
c30d02862d
@ -1,207 +0,0 @@
|
||||
This is for userspace live patching, adding some space into
|
||||
shared libs or executable (in the .ulp section) when one of the
|
||||
input files contains a section named .ulp.track.
|
||||
|
||||
diff --git a/bfd/elf-bfd.h b/bfd/elf-bfd.h
|
||||
index 101c2fdf50d..f5d9e201fdb 100644
|
||||
--- a/bfd/elf-bfd.h
|
||||
+++ b/bfd/elf-bfd.h
|
||||
@@ -1487,6 +1487,10 @@ struct elf_backend_data
|
||||
(const bfd *ibfd, bfd *obfd, const Elf_Internal_Shdr *isection,
|
||||
Elf_Internal_Shdr *osection);
|
||||
|
||||
+ bool (*elf_backend_is_ulp_enabled) (bfd *abfd);
|
||||
+
|
||||
+ bool (*elf_backend_setup_ulp) (struct bfd_link_info *);
|
||||
+
|
||||
/* Used to handle bad SHF_LINK_ORDER input. */
|
||||
void (*link_order_error_handler) (const char *, ...);
|
||||
|
||||
diff --git a/bfd/elflink.c b/bfd/elflink.c
|
||||
index ce1407fa2dc..5c70bcf6c07 100644
|
||||
--- a/bfd/elflink.c
|
||||
+++ b/bfd/elflink.c
|
||||
@@ -7260,6 +7260,13 @@ bfd_elf_size_dynamic_sections (bfd *output_bfd,
|
||||
s = bfd_get_linker_section (dynobj, ".gnu.version");
|
||||
s->flags |= SEC_EXCLUDE;
|
||||
}
|
||||
+
|
||||
+ if (bed->elf_backend_is_ulp_enabled != NULL
|
||||
+ && bed->elf_backend_setup_ulp != NULL
|
||||
+ && (*bed->elf_backend_is_ulp_enabled) (info->input_bfds))
|
||||
+ {
|
||||
+ (*bed->elf_backend_setup_ulp)(info);
|
||||
+ }
|
||||
}
|
||||
return true;
|
||||
}
|
||||
diff --git a/bfd/elfxx-target.h b/bfd/elfxx-target.h
|
||||
index 4c6b1f20340..1f54509cd08 100644
|
||||
--- a/bfd/elfxx-target.h
|
||||
+++ b/bfd/elfxx-target.h
|
||||
@@ -771,6 +771,14 @@
|
||||
#define elf_backend_copy_special_section_fields _bfd_elf_copy_special_section_fields
|
||||
#endif
|
||||
|
||||
+#ifndef elf_backend_is_ulp_enabled
|
||||
+#define elf_backend_is_ulp_enabled NULL
|
||||
+#endif
|
||||
+
|
||||
+#ifndef elf_backend_setup_ulp
|
||||
+#define elf_backend_setup_ulp NULL
|
||||
+#endif
|
||||
+
|
||||
#ifndef elf_backend_compact_eh_encoding
|
||||
#define elf_backend_compact_eh_encoding NULL
|
||||
#endif
|
||||
@@ -904,6 +912,8 @@ static const struct elf_backend_data elfNN_bed =
|
||||
elf_backend_maybe_function_sym,
|
||||
elf_backend_get_reloc_section,
|
||||
elf_backend_copy_special_section_fields,
|
||||
+ elf_backend_is_ulp_enabled,
|
||||
+ elf_backend_setup_ulp,
|
||||
elf_backend_link_order_error_handler,
|
||||
elf_backend_relplt_name,
|
||||
ELF_MACHINE_ALT1,
|
||||
diff --git a/bfd/elfxx-x86.c b/bfd/elfxx-x86.c
|
||||
index 62d516aab8d..c0fb718d85c 100644
|
||||
--- a/bfd/elfxx-x86.c
|
||||
+++ b/bfd/elfxx-x86.c
|
||||
@@ -29,6 +29,8 @@
|
||||
#define ELF64_DYNAMIC_INTERPRETER "/lib/ld64.so.1"
|
||||
#define ELFX32_DYNAMIC_INTERPRETER "/lib/ldx32.so.1"
|
||||
|
||||
+#define ULP_ENTRY_LEN 16
|
||||
+
|
||||
bool
|
||||
_bfd_x86_elf_mkobject (bfd *abfd)
|
||||
{
|
||||
@@ -984,6 +986,64 @@ _bfd_elf_x86_valid_reloc_p (asection *input_section,
|
||||
return valid_p;
|
||||
}
|
||||
|
||||
+/* Check if input bfds are ulp-enabled by containing .ulp.track section */
|
||||
+
|
||||
+bool
|
||||
+_bfd_x86_elf_is_ulp_enabled (struct bfd *input_bfd)
|
||||
+{
|
||||
+ while (input_bfd != NULL)
|
||||
+ for (; input_bfd != NULL; input_bfd = input_bfd->link.next)
|
||||
+ {
|
||||
+ if (input_bfd->section_count == 0) continue;
|
||||
+ if (bfd_get_section_by_name (input_bfd, ".ulp.track")) return true;
|
||||
+ }
|
||||
+ return false;
|
||||
+}
|
||||
+
|
||||
+/* To be used by elf_link_hash_traverse when computing the ulp length */
|
||||
+
|
||||
+static bool
|
||||
+bfd_x86_elf_link_compute_ulp (struct elf_link_hash_entry *h, void *data)
|
||||
+{
|
||||
+ unsigned long *ulp_length = (unsigned long *) data;
|
||||
+
|
||||
+ if (h->dynindx != -1 && h->type == STT_FUNC && !h->def_dynamic)
|
||||
+ {
|
||||
+ ++(*ulp_length);
|
||||
+ }
|
||||
+ return true;
|
||||
+}
|
||||
+
|
||||
+/* Fill the user-space live patching section */
|
||||
+
|
||||
+bool
|
||||
+_bfd_x86_elf_setup_ulp (struct bfd_link_info *info)
|
||||
+{
|
||||
+ struct elf_x86_link_hash_table *htab;
|
||||
+ asection *ulp;
|
||||
+ unsigned int ulp_length = 0;
|
||||
+
|
||||
+ htab = elf_x86_hash_table (info, X86_64_ELF_DATA);
|
||||
+
|
||||
+ elf_link_hash_traverse (elf_hash_table (info),
|
||||
+ bfd_x86_elf_link_compute_ulp,
|
||||
+ &ulp_length);
|
||||
+
|
||||
+ ulp = htab->ulp;
|
||||
+
|
||||
+ ulp->size = ulp_length * ULP_ENTRY_LEN;
|
||||
+
|
||||
+ ulp->contents = (bfd_byte *) bfd_malloc (ulp->size);
|
||||
+ if (ulp->contents == NULL)
|
||||
+ return false;
|
||||
+
|
||||
+ if (!ulp->contents)
|
||||
+ return false;
|
||||
+
|
||||
+ memset(ulp->contents, 0x00, ulp->size);
|
||||
+ return true;
|
||||
+}
|
||||
+
|
||||
/* Set the sizes of the dynamic sections. */
|
||||
|
||||
bool
|
||||
@@ -3030,7 +3090,26 @@ _bfd_x86_elf_link_setup_gnu_properties
|
||||
|
||||
htab->plt_second = sec;
|
||||
}
|
||||
- }
|
||||
+
|
||||
+ /* create sections to support user-space live patching */
|
||||
+ if (_bfd_x86_elf_is_ulp_enabled(info->input_bfds))
|
||||
+ {
|
||||
+ flagword flags = (bed->dynamic_sec_flags
|
||||
+ | SEC_ALLOC
|
||||
+ | SEC_CODE
|
||||
+ | SEC_LOAD
|
||||
+ | SEC_READONLY);
|
||||
+
|
||||
+ sec = bfd_make_section_anyway_with_flags (dynobj, ".ulp", flags);
|
||||
+ if (sec == NULL)
|
||||
+ info->callbacks->einfo (_("%F%P: failed to create ULP section\n"));
|
||||
+
|
||||
+ if (!bfd_set_section_alignment (sec, plt_alignment))
|
||||
+ goto error_alignment;
|
||||
+
|
||||
+ htab->ulp = sec;
|
||||
+ }
|
||||
+ }
|
||||
|
||||
if (!info->no_ld_generated_unwind_info)
|
||||
{
|
||||
diff --git a/bfd/elfxx-x86.h b/bfd/elfxx-x86.h
|
||||
index db11327e96f..89f51382216 100644
|
||||
--- a/bfd/elfxx-x86.h
|
||||
+++ b/bfd/elfxx-x86.h
|
||||
@@ -607,6 +607,7 @@ struct elf_x86_link_hash_table
|
||||
asection *plt_second_eh_frame;
|
||||
asection *plt_got;
|
||||
asection *plt_got_eh_frame;
|
||||
+ asection *ulp;
|
||||
|
||||
sframe_encoder_ctx *plt_cfe_ctx;
|
||||
asection *plt_sframe;
|
||||
@@ -694,6 +695,12 @@ extern void _bfd_x86_elf_link_report_relative_reloc
|
||||
(struct bfd_link_info *, asection *, struct elf_link_hash_entry *,
|
||||
Elf_Internal_Sym *, const char *, const void *);
|
||||
|
||||
+extern bool _bfd_x86_elf_is_ulp_enabled
|
||||
+ (struct bfd *);
|
||||
+
|
||||
+extern bool _bfd_x86_elf_setup_ulp
|
||||
+ (struct bfd_link_info *);
|
||||
+
|
||||
#define bfd_elf64_mkobject \
|
||||
_bfd_x86_elf_mkobject
|
||||
#define bfd_elf32_mkobject \
|
||||
@@ -907,6 +914,10 @@ extern void _bfd_x86_elf_link_report_relative_reloc
|
||||
_bfd_elf_x86_size_relative_relocs
|
||||
#define elf_backend_finish_relative_relocs \
|
||||
_bfd_elf_x86_finish_relative_relocs
|
||||
+#define elf_backend_is_ulp_enabled \
|
||||
+ _bfd_x86_elf_is_ulp_enabled
|
||||
+#define elf_backend_setup_ulp \
|
||||
+ _bfd_x86_elf_setup_ulp
|
||||
|
||||
#define ELF_P_ALIGN ELF_MINPAGESIZE
|
||||
|
BIN
binutils-2.41-branch.diff.gz
(Stored with Git LFS)
BIN
binutils-2.41-branch.diff.gz
(Stored with Git LFS)
Binary file not shown.
BIN
binutils-2.41.tar.bz2
(Stored with Git LFS)
BIN
binutils-2.41.tar.bz2
(Stored with Git LFS)
Binary file not shown.
@ -1,16 +0,0 @@
|
||||
-----BEGIN PGP SIGNATURE-----
|
||||
|
||||
iQIzBAABCAAdFiEEOiS8Ho+0CfqfFDcYE/zvid2ePE8FAmTGcUQACgkQE/zvid2e
|
||||
PE94TRAAsAGH/rarx1cyAxa8x0yKjcQxERag3KE3NXN+OnRvw2bCOfVx62UA68Dt
|
||||
nTCsJ46MTSECdMnMj+b6wGNXr4JDv57r4lkJxJN8TjAS+gWrouqbjvaTPOkros3L
|
||||
1uElw3JLBznDktYvv2aJxBTLSPRXxaD2gMSjVYSZ5X43/ITbNx8mSToevZf2erXB
|
||||
ev+FY5ROyjPwFZyXTEYqqbbdJ4A6+Fkp1UO9UiQv3leZde29ZSiBbNZUU4u5FH3x
|
||||
qNq9zTd4Wlk72X1IEK/HFIVAcFbV2bV38V/r64tw5WRndYReXejtEQMm4kvzFZP4
|
||||
tcgzlTNViTN8FmVNI3P3pByFxC4VmNEbnNCGTDzltuC/RxypqMHWdkBIFU2Zpk4p
|
||||
oAuRMx+7MJ0MqbZjV+VklZAqbl71oDAtUEi7gwKL/UFsRnmUbjRV00YQrXv1kmm8
|
||||
FAuK3UJbfX95MkMV9RSB4kwAdGTLv9CpWix+NGIQs17bnYXyuZPQ0OFuYM6xBDlo
|
||||
IXTS3kvAgKLRni7EQ0xAh3CqQaE5vsLHf7WwTYvi4rWdt0B1hVpFJtpkAhWRrF/N
|
||||
5Hey/pJgOaS2CqEpbijkfG6mGh/xNYK0T8HnHse1pKjl1U1QEgOtluVI3UF2C/H/
|
||||
FkrlClxbExTt9+UmuF/wdvttVj7hDooI7Hh11uvOVBabtlUc66E=
|
||||
=6jCW
|
||||
-----END PGP SIGNATURE-----
|
BIN
binutils-2.42-branch.diff.gz
(Stored with Git LFS)
Normal file
BIN
binutils-2.42-branch.diff.gz
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
binutils-2.42.tar.bz2
(Stored with Git LFS)
Normal file
BIN
binutils-2.42.tar.bz2
(Stored with Git LFS)
Normal file
Binary file not shown.
16
binutils-2.42.tar.bz2.sig
Normal file
16
binutils-2.42.tar.bz2.sig
Normal file
@ -0,0 +1,16 @@
|
||||
-----BEGIN PGP SIGNATURE-----
|
||||
|
||||
iQIzBAABCAAdFiEEOiS8Ho+0CfqfFDcYE/zvid2ePE8FAmW3wiYACgkQE/zvid2e
|
||||
PE+HQBAAgC3yZJvJBx/0EtNESazNRpUG8G4pnd0505QYiibf+5243xXusDySXVu3
|
||||
iBt2UltDPauPu6eIUC7qY0xaZHhPuxqPHp6oSrB73iHZ7ovTdbZUX2060Ro8KXha
|
||||
xN6+SPBHQGxP8XZw+ezexYNpwHBGM8CUos7UeeLpskuSBRGQC4bEhCOR8wuvU1w9
|
||||
gHTFuOY5zKgzzNMr1fPp/tRqUqZr8A7R1HN6tAs+4N2QWLk9Z/oF7h7Rkrzqe8gY
|
||||
vmaakulfBTiqNIZJyTQhbhPiWrtLdElKyohBa/enqtTrktXoX/gwX21+LMqU+Oh3
|
||||
qE7CicjEZKGK/e8gl0BjcwgMeuUYYpZRUI1+A++YAu+YPSzLQL9iPy1FUovrYhHO
|
||||
Fr/qV156MtnhkoaI7RVDLKl2s3CP451yjHSDcAsB51wq+QophC3z6yoTXKuKW8h6
|
||||
v2yW5ZaG5GfiPmRw+E46qsZWeb2pOUaGVU8ovaYWfLjrZ20WFZwZKLn55ZwZ35eW
|
||||
g3RSff4f0lqr8x7jWDkf+KQMC2K0O6Sl0sgFoFE6PMPFcGe4r6oSIekNygaFgxBv
|
||||
DrL0IA8y1prpmpnJrGbIg1+ciguAJKEBfcV9pNyq1IAHWu3aOMbWKb5pF0ukb0PY
|
||||
OueuuH06uaBa7vgZxvbTiw0j5+PuTlGHa3Bsf4rlkChK2N/6deQ=
|
||||
=5bYR
|
||||
-----END PGP SIGNATURE-----
|
25
binutils-disable-code-arch-error.diff
Normal file
25
binutils-disable-code-arch-error.diff
Normal file
@ -0,0 +1,25 @@
|
||||
Index: binutils-2.42/gas/config/tc-i386.c
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/config/tc-i386.c 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/config/tc-i386.c 2024-02-05 17:54:33.515139672 +0100
|
||||
@@ -2992,13 +2992,17 @@ set_cpu_arch (int dummy ATTRIBUTE_UNUSED
|
||||
{
|
||||
check_cpu_arch_compatible (string, cpu_arch[j].enable);
|
||||
|
||||
+ /* XXX code in the wild calls 'as --64' (to generate ELF64),
|
||||
+ but then does '.arch i386' first and only then '.code32' or
|
||||
+ '.code16'. This checking here would require swapping these
|
||||
+ two directives, so just warn for the time being. */
|
||||
if (flag_code == CODE_64BIT && !cpu_arch[j].enable.bitfield.cpu64 )
|
||||
{
|
||||
- as_bad (_("64bit mode not supported on `%s'."),
|
||||
+ as_warn (_("64bit mode not supported on `%s' (consider swapping .arch and .code directives)."),
|
||||
cpu_arch[j].name);
|
||||
- (void) restore_line_pointer (e);
|
||||
+ /*(void) restore_line_pointer (e);
|
||||
ignore_rest_of_line ();
|
||||
- return;
|
||||
+ return;*/
|
||||
}
|
||||
|
||||
if (flag_code == CODE_32BIT && !cpu_arch[j].enable.bitfield.cpui386)
|
@ -1,176 +0,0 @@
|
||||
This reverts 8bb23cdbb498ff645bb0937bc8c0cb89e9e5ebd8 which
|
||||
requires newer makeinfo that we don't have in SLE12.
|
||||
|
||||
diff --git a/bfd/doc/bfd.texi b/bfd/doc/bfd.texi
|
||||
index d8cc1ecca48..f348710845f 100644
|
||||
--- a/bfd/doc/bfd.texi
|
||||
+++ b/bfd/doc/bfd.texi
|
||||
@@ -75,7 +75,7 @@ Copyright @copyright{} 1991-2023 Free Software Foundation, Inc.
|
||||
@end iftex
|
||||
@contents
|
||||
|
||||
-@node Top
|
||||
+@node Top, Overview, (dir), (dir)
|
||||
@ifinfo
|
||||
This file documents the binary file descriptor library libbfd.
|
||||
@end ifinfo
|
||||
@@ -88,7 +88,7 @@ This file documents the binary file descriptor library libbfd.
|
||||
* BFD Index:: BFD Index
|
||||
@end menu
|
||||
|
||||
-@node Overview
|
||||
+@node Overview, BFD front end, Top, Top
|
||||
@chapter Introduction
|
||||
@cindex BFD
|
||||
@cindex what is it?
|
||||
@@ -114,7 +114,7 @@ their own use, for greater efficiency.
|
||||
* What BFD Version 2 Can Do:: What BFD Version 2 Can Do
|
||||
@end menu
|
||||
|
||||
-@node History
|
||||
+@node History, How It Works, Overview, Overview
|
||||
@section History
|
||||
|
||||
One spur behind BFD was the desire, on the part of the GNU 960 team at
|
||||
@@ -137,7 +137,7 @@ and David Henkel-Wallace (@code{gumby@@cygnus.com}).
|
||||
|
||||
|
||||
|
||||
-@node How It Works
|
||||
+@node How It Works, What BFD Version 2 Can Do, History, Overview
|
||||
@section How To Use BFD
|
||||
|
||||
To use the library, include @file{bfd.h} and link with @file{libbfd.a}.
|
||||
@@ -188,11 +188,11 @@ and contain subordinate BFDs. This approach is fine for a.out and coff,
|
||||
but loses efficiency when applied to formats such as S-records and
|
||||
IEEE-695.
|
||||
|
||||
-@node What BFD Version 2 Can Do
|
||||
+@node What BFD Version 2 Can Do, , How It Works, Overview
|
||||
@section What BFD Version 2 Can Do
|
||||
@include bfdsumm.texi
|
||||
|
||||
-@node BFD front end
|
||||
+@node BFD front end, BFD back ends, Overview, Top
|
||||
@chapter BFD Front End
|
||||
|
||||
@menu
|
||||
@@ -219,7 +219,7 @@ IEEE-695.
|
||||
@include bfdt.texi
|
||||
@include bfdio.texi
|
||||
|
||||
-@node Memory Usage
|
||||
+@node Memory Usage, Sections, Miscellaneous, BFD front end
|
||||
@section Memory Usage
|
||||
BFD keeps all of its internal structures in obstacks. There is one obstack
|
||||
per open BFD file, into which the current state is stored. When a BFD is
|
||||
@@ -242,46 +242,46 @@ select the greediest open BFD, close it to reclaim the memory, perform
|
||||
some operation and reopen the BFD again, to get a fresh copy of the data
|
||||
structures.
|
||||
|
||||
-@node Sections
|
||||
+@node Sections, Symbols, Memory Usage, BFD front end
|
||||
@include section.texi
|
||||
|
||||
-@node Symbols
|
||||
+@node Symbols, Archives, Sections, BFD front end
|
||||
@include syms.texi
|
||||
|
||||
-@node Archives
|
||||
+@node Archives, Formats, Symbols, BFD front end
|
||||
@include archive.texi
|
||||
|
||||
-@node Formats
|
||||
+@node Formats, Relocations, Archives, BFD front end
|
||||
@include format.texi
|
||||
|
||||
-@node Relocations
|
||||
+@node Relocations, Core Files, Formats, BFD front end
|
||||
@include reloc.texi
|
||||
|
||||
-@node Core Files
|
||||
+@node Core Files, Targets, Relocations, BFD front end
|
||||
@include corefile.texi
|
||||
|
||||
-@node Targets
|
||||
+@node Targets, Architectures, Core Files, BFD front end
|
||||
@include targets.texi
|
||||
|
||||
-@node Architectures
|
||||
+@node Architectures, Opening and Closing, Targets, BFD front end
|
||||
@include archures.texi
|
||||
|
||||
-@node Opening and Closing
|
||||
+@node Opening and Closing, Internal, Architectures, BFD front end
|
||||
@include opncls.texi
|
||||
|
||||
-@node Internal
|
||||
+@node Internal, File Caching, Opening and Closing, BFD front end
|
||||
@include libbfd.texi
|
||||
|
||||
-@node File Caching
|
||||
+@node File Caching, Linker Functions, Internal, BFD front end
|
||||
@include cache.texi
|
||||
|
||||
-@node Linker Functions
|
||||
+@node Linker Functions, Hash Tables, File Caching, BFD front end
|
||||
@include linker.texi
|
||||
|
||||
-@node Hash Tables
|
||||
+@node Hash Tables, , Linker Functions, BFD front end
|
||||
@include hash.texi
|
||||
|
||||
-@node BFD back ends
|
||||
+@node BFD back ends, GNU Free Documentation License, BFD front end, Top
|
||||
@chapter BFD back ends
|
||||
@menu
|
||||
* What to Put Where::
|
||||
@@ -293,28 +293,28 @@ structures.
|
||||
* srecord :: s-record backend
|
||||
@end ignore
|
||||
@end menu
|
||||
-@node What to Put Where
|
||||
+@node What to Put Where, aout, BFD back ends, BFD back ends
|
||||
@section What to Put Where
|
||||
All of BFD lives in one directory.
|
||||
|
||||
-@node aout
|
||||
+@node aout, coff, What to Put Where, BFD back ends
|
||||
@include aoutx.texi
|
||||
|
||||
-@node coff
|
||||
+@node coff, elf, aout, BFD back ends
|
||||
@include coffcode.texi
|
||||
|
||||
-@node elf
|
||||
+@node elf, mmo, coff, BFD back ends
|
||||
@include elf.texi
|
||||
@c Leave this out until the file has some actual contents...
|
||||
@c @include elfcode.texi
|
||||
|
||||
-@node mmo
|
||||
+@node mmo, , elf, BFD back ends
|
||||
@include mmo.texi
|
||||
|
||||
-@node GNU Free Documentation License
|
||||
+@node GNU Free Documentation License, BFD Index, BFD back ends, Top
|
||||
@include fdl.texi
|
||||
|
||||
-@node BFD Index
|
||||
+@node BFD Index, , GNU Free Documentation License, Top
|
||||
@unnumbered BFD Index
|
||||
@printindex cp
|
||||
|
||||
diff --git a/bfd/doc/webassembly.texi b/bfd/doc/webassembly.texi
|
||||
index 5a05199d5f7..ad650943a1a 100644
|
||||
--- a/bfd/doc/webassembly.texi
|
||||
+++ b/bfd/doc/webassembly.texi
|
||||
@@ -27,7 +27,7 @@ in some malformed WebAssembly modules being treated as valid.
|
||||
* File layout::
|
||||
@end menu
|
||||
|
||||
-@node File layout
|
||||
+@node File layout, WebAssembly
|
||||
@subsection File layout
|
||||
For a description of the WebAssembly file format, see
|
||||
@url{https://github.com/WebAssembly/design/blob/master/BinaryEncoding.md}.
|
@ -1,20 +0,0 @@
|
||||
Fixes two testsuite fails in the gold plugin tests of LLVM.
|
||||
Aka binutils/PR22868
|
||||
Index: binutils-2.30/gold/resolve.cc
|
||||
===================================================================
|
||||
--- binutils-2.30.orig/gold/resolve.cc 2018-01-13 14:31:16.000000000 +0100
|
||||
+++ binutils-2.30/gold/resolve.cc 2018-03-06 16:58:42.000000000 +0100
|
||||
@@ -265,10 +265,13 @@ Symbol_table::resolve(Sized_symbol<size>
|
||||
return;
|
||||
|
||||
// Likewise for an absolute symbol defined twice with the same value.
|
||||
+ // plugin-symbols are always absolute with same value here, so ignore those
|
||||
if (!is_ordinary
|
||||
&& st_shndx == elfcpp::SHN_ABS
|
||||
&& !to_is_ordinary
|
||||
&& to_shndx == elfcpp::SHN_ABS
|
||||
+ && object->pluginobj() == NULL
|
||||
+ && to->object()->pluginobj() == NULL
|
||||
&& to->value() == sym.get_st_value())
|
||||
return;
|
||||
|
@ -12,118 +12,76 @@ v2: this adjusts the reversion of above commit to care for commit
|
||||
testcases so that it applies again, so it's not a simple revert of
|
||||
above commit anymore.
|
||||
|
||||
v3: Adjust for 9c422a59953 and 3f3c1e513.
|
||||
|
||||
(We leave out the patch to ChangeLog in the reversion)
|
||||
|
||||
Index: binutils-2.38.50/gas/testsuite/gas/s390/esa-g5.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/s390/esa-g5.d
|
||||
===================================================================
|
||||
--- binutils-2.38.50.orig/gas/testsuite/gas/s390/esa-g5.d 2022-05-13 17:56:05.000000000 +0200
|
||||
+++ binutils-2.38.50/gas/testsuite/gas/s390/esa-g5.d 2022-05-13 17:56:06.000000000 +0200
|
||||
@@ -78,14 +78,10 @@ Disassembly of section .text:
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/s390/esa-g5.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/s390/esa-g5.d 2024-01-30 17:37:08.609356666 +0100
|
||||
@@ -78,15 +78,11 @@ Disassembly of section .text:
|
||||
.*: 07 29 [ ]*bhr %r9
|
||||
.*: 07 f9 [ ]*br %r9
|
||||
.*: a7 95 00 00 [ ]*bras %r9,e2 <foo\+0xe2>
|
||||
-.*: a7 65 00 00 [ ]*bras %r6,e6 <foo\+0xe6>
|
||||
-.*: a7 64 00 00 [ ]*jlh ea <foo\+0xea>
|
||||
-.*: a7 66 00 00 [ ]*brct %r6,ee <foo\+0xee>
|
||||
-.*: a7 66 00 00 [ ]*brct %r6,f2 <foo\+0xf2>
|
||||
-.*: 84 69 00 00 [ ]*brxh %r6,%r9,f6 <foo\+0xf6>
|
||||
-.*: 84 69 00 00 [ ]*brxh %r6,%r9,fa <foo\+0xfa>
|
||||
-.*: 85 69 00 00 [ ]*brxle %r6,%r9,fe <foo\+0xfe>
|
||||
-.*: 85 69 00 00 [ ]*brxle %r6,%r9,102 <foo\+0x102>
|
||||
+.*: a7 64 00 00 [ ]*jlh e6 <foo\+0xe6>
|
||||
+.*: a7 66 00 00 [ ]*brct %r6,ea <foo\+0xea>
|
||||
+.*: 84 69 00 00 [ ]*brxh %r6,%r9,ee <foo\+0xee>
|
||||
+.*: 85 69 00 00 [ ]*brxle %r6,%r9,f2 <foo\+0xf2>
|
||||
*([\da-f]+): a7 95 00 00 [ ]*bras %r9,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 65 00 00 [ ]*bras %r6,\1 <foo\+0x\1>
|
||||
*([\da-f]+): a7 64 00 00 [ ]*jlh \1 <foo\+0x\1>
|
||||
*([\da-f]+): a7 64 00 00 [ ]*jlh \1 <foo\+0x\1>
|
||||
*([\da-f]+): a7 66 00 00 [ ]*brct %r6,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 66 00 00 [ ]*brct %r6,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): 84 69 00 00 [ ]*brxh %r6,%r9,\1 <foo\+0x\1>
|
||||
*([\da-f]+): 84 69 00 00 [ ]*brxh %r6,%r9,\1 <foo\+0x\1>
|
||||
*([\da-f]+): 85 69 00 00 [ ]*brxle %r6,%r9,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): 85 69 00 00 [ ]*brxle %r6,%r9,\1 <foo\+0x\1>
|
||||
.*: b2 5a 00 69 [ ]*bsa %r6,%r9
|
||||
.*: b2 58 00 69 [ ]*bsg %r6,%r9
|
||||
.*: 0b 69 [ ]*bsm %r6,%r9
|
||||
@@ -184,49 +180,27 @@ Disassembly of section .text:
|
||||
.*: b2 21 00 69 [ ]*ipte %r6,%r9
|
||||
.*: b2 29 00 69 [ ]*iske %r6,%r9
|
||||
.*: b2 23 00 69 [ ]*ivsk %r6,%r9
|
||||
-.*: a7 f4 00 00 [ ]*j 288 <foo\+0x288>
|
||||
-.*: a7 84 00 00 [ ]*je 28c <foo\+0x28c>
|
||||
-.*: a7 24 00 00 [ ]*jh 290 <foo\+0x290>
|
||||
-.*: a7 a4 00 00 [ ]*jhe 294 <foo\+0x294>
|
||||
-.*: a7 44 00 00 [ ]*jl 298 <foo\+0x298>
|
||||
-.*: a7 c4 00 00 [ ]*jle 29c <foo\+0x29c>
|
||||
-.*: a7 64 00 00 [ ]*jlh 2a0 <foo\+0x2a0>
|
||||
-.*: a7 44 00 00 [ ]*jl 2a4 <foo\+0x2a4>
|
||||
-.*: a7 74 00 00 [ ]*jne 2a8 <foo\+0x2a8>
|
||||
-.*: a7 d4 00 00 [ ]*jnh 2ac <foo\+0x2ac>
|
||||
-.*: a7 54 00 00 [ ]*jnhe 2b0 <foo\+0x2b0>
|
||||
-.*: a7 b4 00 00 [ ]*jnl 2b4 <foo\+0x2b4>
|
||||
-.*: a7 34 00 00 [ ]*jnle 2b8 <foo\+0x2b8>
|
||||
-.*: a7 94 00 00 [ ]*jnlh 2bc <foo\+0x2bc>
|
||||
-.*: a7 b4 00 00 [ ]*jnl 2c0 <foo\+0x2c0>
|
||||
-.*: a7 e4 00 00 [ ]*jno 2c4 <foo\+0x2c4>
|
||||
-.*: a7 d4 00 00 [ ]*jnh 2c8 <foo\+0x2c8>
|
||||
-.*: a7 74 00 00 [ ]*jne 2cc <foo\+0x2cc>
|
||||
-.*: a7 14 00 00 [ ]*jo 2d0 <foo\+0x2d0>
|
||||
-.*: a7 24 00 00 [ ]*jh 2d4 <foo\+0x2d4>
|
||||
-.*: a7 84 00 00 [ ]*je 2d8 <foo\+0x2d8>
|
||||
-.*: a7 04 00 00 [ ]*jnop 2dc <foo\+0x2dc>
|
||||
-.*: a7 14 00 00 [ ]*jo 2e0 <foo\+0x2e0>
|
||||
-.*: a7 24 00 00 [ ]*jh 2e4 <foo\+0x2e4>
|
||||
-.*: a7 24 00 00 [ ]*jh 2e8 <foo\+0x2e8>
|
||||
-.*: a7 34 00 00 [ ]*jnle 2ec <foo\+0x2ec>
|
||||
-.*: a7 44 00 00 [ ]*jl 2f0 <foo\+0x2f0>
|
||||
-.*: a7 44 00 00 [ ]*jl 2f4 <foo\+0x2f4>
|
||||
-.*: a7 54 00 00 [ ]*jnhe 2f8 <foo\+0x2f8>
|
||||
-.*: a7 64 00 00 [ ]*jlh 2fc <foo\+0x2fc>
|
||||
-.*: a7 74 00 00 [ ]*jne 300 <foo\+0x300>
|
||||
-.*: a7 74 00 00 [ ]*jne 304 <foo\+0x304>
|
||||
-.*: a7 84 00 00 [ ]*je 308 <foo\+0x308>
|
||||
-.*: a7 84 00 00 [ ]*je 30c <foo\+0x30c>
|
||||
-.*: a7 94 00 00 [ ]*jnlh 310 <foo\+0x310>
|
||||
-.*: a7 a4 00 00 [ ]*jhe 314 <foo\+0x314>
|
||||
-.*: a7 b4 00 00 [ ]*jnl 318 <foo\+0x318>
|
||||
-.*: a7 b4 00 00 [ ]*jnl 31c <foo\+0x31c>
|
||||
-.*: a7 c4 00 00 [ ]*jle 320 <foo\+0x320>
|
||||
-.*: a7 d4 00 00 [ ]*jnh 324 <foo\+0x324>
|
||||
-.*: a7 d4 00 00 [ ]*jnh 328 <foo\+0x328>
|
||||
-.*: a7 e4 00 00 [ ]*jno 32c <foo\+0x32c>
|
||||
-.*: a7 f4 00 00 [ ]*j 330 <foo\+0x330>
|
||||
+.*: a7 f4 00 00 [ ]*j 278 <foo\+0x278>
|
||||
+.*: a7 84 00 00 [ ]*je 27c <foo\+0x27c>
|
||||
+.*: a7 24 00 00 [ ]*jh 280 <foo\+0x280>
|
||||
+.*: a7 a4 00 00 [ ]*jhe 284 <foo\+0x284>
|
||||
+.*: a7 44 00 00 [ ]*jl 288 <foo\+0x288>
|
||||
+.*: a7 c4 00 00 [ ]*jle 28c <foo\+0x28c>
|
||||
+.*: a7 64 00 00 [ ]*jlh 290 <foo\+0x290>
|
||||
+.*: a7 44 00 00 [ ]*jl 294 <foo\+0x294>
|
||||
+.*: a7 74 00 00 [ ]*jne 298 <foo\+0x298>
|
||||
+.*: a7 d4 00 00 [ ]*jnh 29c <foo\+0x29c>
|
||||
+.*: a7 54 00 00 [ ]*jnhe 2a0 <foo\+0x2a0>
|
||||
+.*: a7 b4 00 00 [ ]*jnl 2a4 <foo\+0x2a4>
|
||||
+.*: a7 34 00 00 [ ]*jnle 2a8 <foo\+0x2a8>
|
||||
+.*: a7 94 00 00 [ ]*jnlh 2ac <foo\+0x2ac>
|
||||
+.*: a7 b4 00 00 [ ]*jnl 2b0 <foo\+0x2b0>
|
||||
+.*: a7 e4 00 00 [ ]*jno 2b4 <foo\+0x2b4>
|
||||
+.*: a7 d4 00 00 [ ]*jnh 2b8 <foo\+0x2b8>
|
||||
+.*: a7 74 00 00 [ ]*jne 2bc <foo\+0x2bc>
|
||||
+.*: a7 14 00 00 [ ]*jo 2c0 <foo\+0x2c0>
|
||||
+.*: a7 24 00 00 [ ]*jh 2c4 <foo\+0x2c4>
|
||||
+.*: a7 84 00 00 [ ]*je 2c8 <foo\+0x2c8>
|
||||
@@ -206,28 +202,6 @@ Disassembly of section .text:
|
||||
*([\da-f]+): a7 14 00 00 [ ]*jo \1 <foo\+0x\1>
|
||||
*([\da-f]+): a7 24 00 00 [ ]*jh \1 <foo\+0x\1>
|
||||
*([\da-f]+): a7 84 00 00 [ ]*je \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 04 00 00 [ ]*jnop \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 14 00 00 [ ]*jo \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 24 00 00 [ ]*jh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 24 00 00 [ ]*jh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 34 00 00 [ ]*jnle \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 44 00 00 [ ]*jl \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 44 00 00 [ ]*jl \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 54 00 00 [ ]*jnhe \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 64 00 00 [ ]*jlh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 74 00 00 [ ]*jne \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 74 00 00 [ ]*jne \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 84 00 00 [ ]*je \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 84 00 00 [ ]*je \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 94 00 00 [ ]*jnlh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 a4 00 00 [ ]*jhe \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 b4 00 00 [ ]*jnl \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 b4 00 00 [ ]*jnl \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 c4 00 00 [ ]*jle \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 d4 00 00 [ ]*jnh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 d4 00 00 [ ]*jnh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 e4 00 00 [ ]*jno \1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 f4 00 00 [ ]*j \1 <foo\+0x\1>
|
||||
.*: ed 65 af ff 00 18 [ ]*kdb %f6,4095\(%r5,%r10\)
|
||||
.*: b3 18 00 69 [ ]*kdbr %f6,%f9
|
||||
.*: ed 65 af ff 00 08 [ ]*keb %f6,4095\(%r5,%r10\)
|
||||
@@ -509,4 +483,4 @@ Disassembly of section .text:
|
||||
@@ -510,4 +484,4 @@ Disassembly of section .text:
|
||||
.*: f8 58 5f ff af ff [ ]*zap 4095\(6,%r5\),4095\(9,%r10\)
|
||||
.*: b2 21 b0 69 [ ]*ipte %r6,%r9,%r11
|
||||
.*: b2 21 bd 69 [ ]*ipte %r6,%r9,%r11,13
|
||||
-.*: 07 07 [ ]*nopr %r7
|
||||
+.*: 07 07 [ ]*nopr %r7
|
||||
Index: binutils-2.38.50/gas/testsuite/gas/s390/esa-g5.s
|
||||
Index: binutils-2.42/gas/testsuite/gas/s390/esa-g5.s
|
||||
===================================================================
|
||||
--- binutils-2.38.50.orig/gas/testsuite/gas/s390/esa-g5.s 2022-05-13 17:56:05.000000000 +0200
|
||||
+++ binutils-2.38.50/gas/testsuite/gas/s390/esa-g5.s 2022-05-13 17:56:06.000000000 +0200
|
||||
@@ -72,14 +72,10 @@ foo:
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/s390/esa-g5.s 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/s390/esa-g5.s 2024-01-30 17:11:14.563730960 +0100
|
||||
@@ -72,15 +72,11 @@ foo:
|
||||
bpr %r9
|
||||
br %r9
|
||||
bras %r9,.
|
||||
- jas %r6,.
|
||||
brc 6,.
|
||||
jc 6,.
|
||||
brct 6,.
|
||||
- jct %r6,.
|
||||
brxh %r6,%r9,.
|
||||
@ -133,7 +91,7 @@ Index: binutils-2.38.50/gas/testsuite/gas/s390/esa-g5.s
|
||||
bsa %r6,%r9
|
||||
bsg %r6,%r9
|
||||
bsm %r6,%r9
|
||||
@@ -199,28 +195,6 @@ foo:
|
||||
@@ -200,28 +196,6 @@ foo:
|
||||
jo .
|
||||
jp .
|
||||
jz .
|
||||
@ -162,110 +120,61 @@ Index: binutils-2.38.50/gas/testsuite/gas/s390/esa-g5.s
|
||||
kdb %f6,4095(%r5,%r10)
|
||||
kdbr %f6,%f9
|
||||
keb %f6,4095(%r5,%r10)
|
||||
Index: binutils-2.38.50/gas/testsuite/gas/s390/esa-z900.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/s390/esa-z900.d
|
||||
===================================================================
|
||||
--- binutils-2.38.50.orig/gas/testsuite/gas/s390/esa-z900.d 2022-05-13 17:56:05.000000000 +0200
|
||||
+++ binutils-2.38.50/gas/testsuite/gas/s390/esa-z900.d 2022-05-13 18:07:33.000000000 +0200
|
||||
@@ -6,56 +6,31 @@
|
||||
Disassembly of section .text:
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/s390/esa-z900.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/s390/esa-z900.d 2024-01-30 17:46:09.638230382 +0100
|
||||
@@ -7,28 +7,6 @@ Disassembly of section .text:
|
||||
|
||||
.* <foo>:
|
||||
-.*: c0 f4 00 00 00 00 [ ]*jg 0 <foo>
|
||||
-.*: c0 04 00 00 00 00 [ ]*jgnop 6 <foo\+0x6>
|
||||
-.*: c0 14 00 00 00 00 [ ]*jgo c <foo\+0xc>
|
||||
-.*: c0 24 00 00 00 00 [ ]*jgh 12 <foo\+0x12>
|
||||
-.*: c0 24 00 00 00 00 [ ]*jgh 18 <foo\+0x18>
|
||||
-.*: c0 34 00 00 00 00 [ ]*jgnle 1e <foo\+0x1e>
|
||||
-.*: c0 44 00 00 00 00 [ ]*jgl 24 <foo\+0x24>
|
||||
-.*: c0 44 00 00 00 00 [ ]*jgl 2a <foo\+0x2a>
|
||||
-.*: c0 54 00 00 00 00 [ ]*jgnhe 30 <foo\+0x30>
|
||||
-.*: c0 64 00 00 00 00 [ ]*jglh 36 <foo\+0x36>
|
||||
-.*: c0 74 00 00 00 00 [ ]*jgne 3c <foo\+0x3c>
|
||||
-.*: c0 74 00 00 00 00 [ ]*jgne 42 <foo\+0x42>
|
||||
-.*: c0 84 00 00 00 00 [ ]*jge 48 <foo\+0x48>
|
||||
-.*: c0 84 00 00 00 00 [ ]*jge 4e <foo\+0x4e>
|
||||
-.*: c0 94 00 00 00 00 [ ]*jgnlh 54 <foo\+0x54>
|
||||
-.*: c0 a4 00 00 00 00 [ ]*jghe 5a <foo\+0x5a>
|
||||
-.*: c0 b4 00 00 00 00 [ ]*jgnl 60 <foo\+0x60>
|
||||
-.*: c0 b4 00 00 00 00 [ ]*jgnl 66 <foo\+0x66>
|
||||
-.*: c0 c4 00 00 00 00 [ ]*jgle 6c <foo\+0x6c>
|
||||
-.*: c0 d4 00 00 00 00 [ ]*jgnh 72 <foo\+0x72>
|
||||
-.*: c0 d4 00 00 00 00 [ ]*jgnh 78 <foo\+0x78>
|
||||
-.*: c0 e4 00 00 00 00 [ ]*jgno 7e <foo\+0x7e>
|
||||
-.*: c0 f4 00 00 00 00 [ ]*jg 84 <foo\+0x84>
|
||||
-.*: c0 14 00 00 00 00 [ ]*jgo 8a <foo\+0x8a>
|
||||
-.*: c0 24 00 00 00 00 [ ]*jgh 90 <foo\+0x90>
|
||||
-.*: c0 24 00 00 00 00 [ ]*jgh 96 <foo\+0x96>
|
||||
-.*: c0 34 00 00 00 00 [ ]*jgnle 9c <foo\+0x9c>
|
||||
-.*: c0 44 00 00 00 00 [ ]*jgl a2 <foo\+0xa2>
|
||||
-.*: c0 44 00 00 00 00 [ ]*jgl a8 <foo\+0xa8>
|
||||
-.*: c0 54 00 00 00 00 [ ]*jgnhe ae <foo\+0xae>
|
||||
-.*: c0 64 00 00 00 00 [ ]*jglh b4 <foo\+0xb4>
|
||||
-.*: c0 74 00 00 00 00 [ ]*jgne ba <foo\+0xba>
|
||||
-.*: c0 74 00 00 00 00 [ ]*jgne c0 <foo\+0xc0>
|
||||
-.*: c0 84 00 00 00 00 [ ]*jge c6 <foo\+0xc6>
|
||||
-.*: c0 84 00 00 00 00 [ ]*jge cc <foo\+0xcc>
|
||||
-.*: c0 94 00 00 00 00 [ ]*jgnlh d2 <foo\+0xd2>
|
||||
-.*: c0 a4 00 00 00 00 [ ]*jghe d8 <foo\+0xd8>
|
||||
-.*: c0 b4 00 00 00 00 [ ]*jgnl de <foo\+0xde>
|
||||
-.*: c0 b4 00 00 00 00 [ ]*jgnl e4 <foo\+0xe4>
|
||||
-.*: c0 c4 00 00 00 00 [ ]*jgle ea <foo\+0xea>
|
||||
-.*: c0 d4 00 00 00 00 [ ]*jgnh f0 <foo\+0xf0>
|
||||
-.*: c0 d4 00 00 00 00 [ ]*jgnh f6 <foo\+0xf6>
|
||||
-.*: c0 e4 00 00 00 00 [ ]*jgno fc <foo\+0xfc>
|
||||
-.*: c0 f4 00 00 00 00 [ ]*jg 102 <foo\+0x102>
|
||||
-.*: c0 65 00 00 00 00 [ ]*brasl %r6,108 <foo\+0x108>
|
||||
-.*: c0 65 00 00 00 00 [ ]*brasl %r6,10e <foo\+0x10e>
|
||||
-.*: c0 65 80 00 00 00 [ ]*brasl %r6,114 <foo\+0x114>
|
||||
-.*: c0 65 80 00 00 00 [ ]*brasl %r6,11a <foo\+0x11a>
|
||||
.*: c0 f4 00 00 00 00 [ ]*jg 0 <foo>
|
||||
- *([\da-f]+): c0 04 00 00 00 00 [ ]*jgnop \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 14 00 00 00 00 [ ]*jgo \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 24 00 00 00 00 [ ]*jgh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 24 00 00 00 00 [ ]*jgh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 34 00 00 00 00 [ ]*jgnle \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 44 00 00 00 00 [ ]*jgl \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 44 00 00 00 00 [ ]*jgl \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 54 00 00 00 00 [ ]*jgnhe \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 64 00 00 00 00 [ ]*jglh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 74 00 00 00 00 [ ]*jgne \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 74 00 00 00 00 [ ]*jgne \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 84 00 00 00 00 [ ]*jge \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 84 00 00 00 00 [ ]*jge \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 94 00 00 00 00 [ ]*jgnlh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 a4 00 00 00 00 [ ]*jghe \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 b4 00 00 00 00 [ ]*jgnl \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 b4 00 00 00 00 [ ]*jgnl \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 c4 00 00 00 00 [ ]*jgle \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 d4 00 00 00 00 [ ]*jgnh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 d4 00 00 00 00 [ ]*jgnh \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 e4 00 00 00 00 [ ]*jgno \1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 f4 00 00 00 00 [ ]*jg \1 <foo\+0x\1>
|
||||
*([\da-f]+): c0 14 00 00 00 00 [ ]*jgo \1 <foo\+0x\1>
|
||||
*([\da-f]+): c0 24 00 00 00 00 [ ]*jgh \1 <foo\+0x\1>
|
||||
*([\da-f]+): c0 24 00 00 00 00 [ ]*jgh \1 <foo\+0x\1>
|
||||
@@ -51,11 +29,8 @@ Disassembly of section .text:
|
||||
*([\da-f]+): c0 e4 00 00 00 00 [ ]*jgno \1 <foo\+0x\1>
|
||||
*([\da-f]+): c0 f4 00 00 00 00 [ ]*jg \1 <foo\+0x\1>
|
||||
*([\da-f]+): c0 65 00 00 00 00 [ ]*brasl %r6,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 65 00 00 00 00 [ ]*brasl %r6,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 65 80 00 00 00 [ ]*brasl %r6,\1 <foo\+0x\1>
|
||||
*([\da-f]+): c0 65 80 00 00 00 [ ]*brasl %r6,\1 <foo\+0x\1>
|
||||
-.*: c0 65 7f ff ff ff [ ]*brasl %r6,11e <foo\+0x11e>
|
||||
-.*: c0 65 7f ff ff ff [ ]*brasl %r6,124 <foo\+0x124>
|
||||
+.*: c0 f4 00 00 00 00 [ ]*jg 0 \<foo\>
|
||||
+.*: c0 14 00 00 00 00 [ ]*jgo 6 \<foo\+0x6>
|
||||
+.*: c0 24 00 00 00 00 [ ]*jgh c \<foo\+0xc>
|
||||
+.*: c0 24 00 00 00 00 [ ]*jgh 12 \<foo\+0x12>
|
||||
+.*: c0 34 00 00 00 00 [ ]*jgnle 18 \<foo\+0x18>
|
||||
+.*: c0 44 00 00 00 00 [ ]*jgl 1e \<foo\+0x1e>
|
||||
+.*: c0 44 00 00 00 00 [ ]*jgl 24 \<foo\+0x24>
|
||||
+.*: c0 54 00 00 00 00 [ ]*jgnhe 2a \<foo\+0x2a>
|
||||
+.*: c0 64 00 00 00 00 [ ]*jglh 30 \<foo\+0x30>
|
||||
+.*: c0 74 00 00 00 00 [ ]*jgne 36 \<foo\+0x36>
|
||||
+.*: c0 74 00 00 00 00 [ ]*jgne 3c \<foo\+0x3c>
|
||||
+.*: c0 84 00 00 00 00 [ ]*jge 42 \<foo\+0x42>
|
||||
+.*: c0 84 00 00 00 00 [ ]*jge 48 \<foo\+0x48>
|
||||
+.*: c0 94 00 00 00 00 [ ]*jgnlh 4e \<foo\+0x4e>
|
||||
+.*: c0 a4 00 00 00 00 [ ]*jghe 54 \<foo\+0x54>
|
||||
+.*: c0 b4 00 00 00 00 [ ]*jgnl 5a \<foo\+0x5a>
|
||||
+.*: c0 b4 00 00 00 00 [ ]*jgnl 60 \<foo\+0x60>
|
||||
+.*: c0 c4 00 00 00 00 [ ]*jgle 66 \<foo\+0x66>
|
||||
+.*: c0 d4 00 00 00 00 [ ]*jgnh 6c \<foo\+0x6c>
|
||||
+.*: c0 d4 00 00 00 00 [ ]*jgnh 72 \<foo\+0x72>
|
||||
+.*: c0 e4 00 00 00 00 [ ]*jgno 78 \<foo\+0x78>
|
||||
+.*: c0 f4 00 00 00 00 [ ]*jg 7e \<foo\+0x7e>
|
||||
+.*: c0 65 00 00 00 00 [ ]*brasl %r6,84 \<foo\+0x84>
|
||||
+.*: c0 65 80 00 00 00 [ ]*brasl %r6,8a <foo\+0x8a>
|
||||
+.*: c0 65 7f ff ff ff [ ]*brasl %r6,8e <foo\+0x8e>
|
||||
.*: 01 0b [ ]*tam
|
||||
.*: 01 0c [ ]*sam24
|
||||
.*: 01 0d [ ]*sam31
|
||||
@@ -66,7 +41,7 @@ Disassembly of section .text:
|
||||
.*: b9 97 00 69 [ ]*dlr %r6,%r9
|
||||
.*: b9 98 00 69 [ ]*alcr %r6,%r9
|
||||
.*: b9 99 00 69 [ ]*slbr %r6,%r9
|
||||
-.*: c0 60 00 00 00 00 [ ]*larl %r6,14e <foo\+0x14e>
|
||||
+.*: c0 60 00 00 00 00 [ ]*larl %r6,b8 <foo\+0xb8>
|
||||
.*: e3 65 af ff 00 1e [ ]*lrv %r6,4095\(%r5,%r10\)
|
||||
.*: e3 65 af ff 00 1f [ ]*lrvh %r6,4095\(%r5,%r10\)
|
||||
.*: e3 65 af ff 00 3e [ ]*strv %r6,4095\(%r5,%r10\)
|
||||
@@ -76,4 +51,3 @@ Disassembly of section .text:
|
||||
.*: e3 65 af ff 00 98 [ ]*alc %r6,4095\(%r5,%r10\)
|
||||
.*: e3 65 af ff 00 99 [ ]*slb %r6,4095\(%r5,%r10\)
|
||||
.*: eb 69 5f ff 00 1d [ ]*rll %r6,%r9,4095\(%r5\)
|
||||
-.*: 07 07 [ ]*nopr %r7
|
||||
Index: binutils-2.38.50/gas/testsuite/gas/s390/esa-z900.s
|
||||
Index: binutils-2.42/gas/testsuite/gas/s390/esa-z900.s
|
||||
===================================================================
|
||||
--- binutils-2.38.50.orig/gas/testsuite/gas/s390/esa-z900.s 2022-05-13 17:56:05.000000000 +0200
|
||||
+++ binutils-2.38.50/gas/testsuite/gas/s390/esa-z900.s 2022-05-13 17:57:59.000000000 +0200
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/s390/esa-z900.s 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/s390/esa-z900.s 2024-01-30 17:05:15.811158036 +0100
|
||||
@@ -1,7 +1,6 @@
|
||||
.text
|
||||
foo:
|
||||
@ -308,28 +217,37 @@ Index: binutils-2.38.50/gas/testsuite/gas/s390/esa-z900.s
|
||||
tam
|
||||
sam24
|
||||
sam31
|
||||
Index: binutils-2.38.50/gas/testsuite/gas/s390/zarch-z900.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/s390/zarch-z900.d
|
||||
===================================================================
|
||||
--- binutils-2.38.50.orig/gas/testsuite/gas/s390/zarch-z900.d 2022-05-13 17:56:05.000000000 +0200
|
||||
+++ binutils-2.38.50/gas/testsuite/gas/s390/zarch-z900.d 2022-05-13 17:56:06.000000000 +0200
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/s390/zarch-z900.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/s390/zarch-z900.d 2024-01-30 17:51:15.809891527 +0100
|
||||
@@ -20,11 +20,8 @@ Disassembly of section .text:
|
||||
.*: e3 95 af ff 00 46 [ ]*bctg %r9,4095\(%r5,%r10\)
|
||||
.*: b9 46 00 96 [ ]*bctgr %r9,%r6
|
||||
.*: a7 97 00 00 [ ]*brctg %r9,40 \<foo\+0x40\>
|
||||
-.*: a7 67 00 00 [ ]*brctg %r6,44 <foo\+0x44>
|
||||
-.*: ec 96 00 00 00 44 [ ]*brxhg %r9,%r6,48 <foo\+0x48>
|
||||
-.*: ec 69 00 00 00 44 [ ]*brxhg %r6,%r9,4e <foo\+0x4e>
|
||||
-.*: ec 96 00 00 00 45 [ ]*brxlg %r9,%r6,54 <foo\+0x54>
|
||||
-.*: ec 69 00 00 00 45 [ ]*brxlg %r6,%r9,5a <foo\+0x5a>
|
||||
+.*: ec 96 00 00 00 44 [ ]*brxhg %r9,%r6,44 <foo\+0x44>
|
||||
+.*: ec 96 00 00 00 45 [ ]*brxlg %r9,%r6,4a <foo\+0x4a>
|
||||
*([\da-f]+): a7 97 00 00 [ ]*brctg %r9,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): a7 67 00 00 [ ]*brctg %r6,\1 <foo\+0x\1>
|
||||
*([\da-f]+): ec 96 00 00 00 44 [ ]*brxhg %r9,%r6,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): ec 69 00 00 00 44 [ ]*brxhg %r6,%r9,\1 <foo\+0x\1>
|
||||
*([\da-f]+): ec 96 00 00 00 45 [ ]*brxlg %r9,%r6,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): ec 69 00 00 00 45 [ ]*brxlg %r6,%r9,\1 <foo\+0x\1>
|
||||
.*: eb 96 5f ff 00 44 [ ]*bxhg %r9,%r6,4095\(%r5\)
|
||||
.*: eb 96 5f ff 00 45 [ ]*bxleg %r9,%r6,4095\(%r5\)
|
||||
.*: b3 a5 00 96 [ ]*cdgbr %f9,%r6
|
||||
Index: binutils-2.38.50/gas/testsuite/gas/s390/zarch-z900.s
|
||||
@@ -151,9 +148,5 @@ Disassembly of section .text:
|
||||
.*: e3 95 af ff 00 82 [ ]*xg %r9,4095\(%r5,%r10\)
|
||||
.*: b9 82 00 96 [ ]*xgr %r9,%r6
|
||||
*([\da-f]+): c0 65 00 00 00 00 [ ]*brasl %r6,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 65 00 00 00 00 [ ]*brasl %r6,\1 <foo\+0x\1>
|
||||
- *([\da-f]+): c0 65 80 00 00 00 [ ]*brasl %r6,ffffffff0+\1 <foo\+0xffffffff0+\1>
|
||||
*([\da-f]+): c0 65 80 00 00 00 [ ]*brasl %r6,ffffffff0+\1 <foo\+0xffffffff0+\1>
|
||||
-.*: c0 65 7f ff ff ff [ ]*brasl %r6,1000002d4 <foo\+0x1000002d4>
|
||||
-.*: c0 65 7f ff ff ff [ ]*brasl %r6,1000002da <foo\+0x1000002da>
|
||||
-.*: 07 07 [ ]*nopr %r7
|
||||
+.*: c0 65 7f ff ff ff [ ]*brasl %r6,1000002b8 <foo\+0x1000002b8>
|
||||
Index: binutils-2.42/gas/testsuite/gas/s390/zarch-z900.s
|
||||
===================================================================
|
||||
--- binutils-2.38.50.orig/gas/testsuite/gas/s390/zarch-z900.s 2022-05-13 17:56:05.000000000 +0200
|
||||
+++ binutils-2.38.50/gas/testsuite/gas/s390/zarch-z900.s 2022-05-13 17:56:06.000000000 +0200
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/s390/zarch-z900.s 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/s390/zarch-z900.s 2024-01-30 17:23:32.652555451 +0100
|
||||
@@ -14,11 +14,8 @@ foo:
|
||||
bctg %r9,4095(%r5,%r10)
|
||||
bctgr %r9,%r6
|
||||
@ -342,10 +260,19 @@ Index: binutils-2.38.50/gas/testsuite/gas/s390/zarch-z900.s
|
||||
bxhg %r9,%r6,4095(%r5)
|
||||
bxleg %r9,%r6,4095(%r5)
|
||||
cdgbr %f9,%r6
|
||||
Index: binutils-2.38.50/ld/testsuite/ld-s390/tlsbin_64.dd
|
||||
@@ -145,8 +142,5 @@ foo:
|
||||
xg %r9,4095(%r5,%r10)
|
||||
xgr %r9,%r6
|
||||
brasl %r6,.
|
||||
- jasl %r6,.
|
||||
brasl %r6,.-0x100000000
|
||||
- jasl %r6,.-0x100000000
|
||||
brasl %r6,.+0xfffffffe
|
||||
- jasl %r6,.+0xfffffffe
|
||||
Index: binutils-2.42/ld/testsuite/ld-s390/tlsbin_64.dd
|
||||
===================================================================
|
||||
--- binutils-2.38.50.orig/ld/testsuite/ld-s390/tlsbin_64.dd 2022-05-13 17:56:05.000000000 +0200
|
||||
+++ binutils-2.38.50/ld/testsuite/ld-s390/tlsbin_64.dd 2022-05-13 17:56:06.000000000 +0200
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-s390/tlsbin_64.dd 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/ld/testsuite/ld-s390/tlsbin_64.dd 2024-01-30 17:05:15.811158036 +0100
|
||||
@@ -87,26 +87,26 @@ Disassembly of section .text:
|
||||
+[0-9a-f]+: 41 22 90 00 la %r2,0\(%r2,%r9\)
|
||||
# GD -> LE with global variable defined in executable
|
||||
@ -378,60 +305,61 @@ Index: binutils-2.38.50/ld/testsuite/ld-s390/tlsbin_64.dd
|
||||
+[0-9a-f]+: 41 32 90 00 la %r3,0\(%r2,%r9\)
|
||||
+[0-9a-f]+: e3 40 d0 48 00 04 lg %r4,72\(%r13\)
|
||||
+[0-9a-f]+: 41 54 30 00 la %r5,0\(%r4,%r3\)
|
||||
Index: binutils-2.38.50/opcodes/s390-opc.txt
|
||||
Index: binutils-2.42/opcodes/s390-opc.txt
|
||||
===================================================================
|
||||
--- binutils-2.38.50.orig/opcodes/s390-opc.txt 2022-05-13 17:56:05.000000000 +0200
|
||||
+++ binutils-2.38.50/opcodes/s390-opc.txt 2022-05-13 17:56:06.000000000 +0200
|
||||
@@ -246,14 +246,10 @@ d7 xc SS_L0RDRD "exclusive OR" g5 esa,za
|
||||
--- binutils-2.42.orig/opcodes/s390-opc.txt 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/opcodes/s390-opc.txt 2024-01-30 17:10:00.085838136 +0100
|
||||
@@ -246,14 +246,10 @@ d7 xc SS_L0RDRD "exclusive or" g5 esa,za
|
||||
f8 zap SS_LLRDRD "zero and add" g5 esa,zarch
|
||||
a70a ahi RI_RI "add halfword immediate" g5 esa,zarch
|
||||
84 brxh RSI_RRP "branch relative on index high" g5 esa,zarch
|
||||
-84 jxh RSI_RRP "branch relative on index high" g5 esa,zarch
|
||||
85 brxle RSI_RRP "branch relative on index low or equal" g5 esa,zarch
|
||||
-85 jxle RSI_RRP "branch relative on index low or equal" g5 esa,zarch
|
||||
a705 bras RI_RP "branch relative and save" g5 esa,zarch
|
||||
-a705 jas RI_RP "branch relative and save" g5 esa,zarch
|
||||
a704 brc RI_UP "branch relative on condition" g5 esa,zarch
|
||||
a706 brct RI_RP "branch relative on count" g5 esa,zarch
|
||||
-a706 jct RI_RP "branch relative on count" g5 esa,zarch
|
||||
84 brxh RSI_RRP "branch relative on index high" g5 esa,zarch condjump
|
||||
-84 jxh RSI_RRP "branch relative on index high" g5 esa,zarch condjump
|
||||
85 brxle RSI_RRP "branch relative on index low or equal" g5 esa,zarch condjump
|
||||
-85 jxle RSI_RRP "branch relative on index low or equal" g5 esa,zarch condjump
|
||||
a705 bras RI_RP "branch relative and save" g5 esa,zarch jumpsr
|
||||
-a705 jas RI_RP "branch relative and save" g5 esa,zarch jumpsr
|
||||
a704 brc RI_UP "branch relative on condition" g5 esa,zarch condjump
|
||||
a706 brct RI_RP "branch relative on count" g5 esa,zarch condjump
|
||||
-a706 jct RI_RP "branch relative on count" g5 esa,zarch condjump
|
||||
b241 cksm RRE_RR "checksum" g5 esa,zarch
|
||||
a70e chi RI_RI "compare halfword immediate" g5 esa,zarch
|
||||
a9 clcle RS_RRRD "compare logical long extended" g5 esa,zarch
|
||||
@@ -272,11 +268,8 @@ a701 tml RI_RU "test under mask low" g5
|
||||
4700 nop RX_0RRD "no operation" g5 esa,zarch optparm
|
||||
@@ -273,11 +269,8 @@ a701 tml RI_RU "test under mask low" g5
|
||||
4700 b*8 RX_0RRD "conditional branch" g5 esa,zarch
|
||||
47f0 b RX_0RRD "unconditional branch" g5 esa,zarch
|
||||
a704 jc RI_UP "conditional jump" g5 esa,zarch condjump
|
||||
-a704 jnop RI_0P "nop jump" g5 esa,zarch
|
||||
a704 j*8 RI_0P "conditional jump" g5 esa,zarch
|
||||
-a704 br*8 RI_0P "conditional jump" g5 esa,zarch
|
||||
a7f4 j RI_0P "unconditional jump" g5 esa,zarch
|
||||
-a7f4 bru RI_0P "unconditional jump" g5 esa,zarch
|
||||
a704 j*8 RI_0P "conditional jump" g5 esa,zarch condjump
|
||||
-a704 br*8 RI_0P "conditional jump" g5 esa,zarch condjump
|
||||
a7f4 j RI_0P "unconditional jump" g5 esa,zarch jump
|
||||
-a7f4 bru RI_0P "unconditional jump" g5 esa,zarch jump
|
||||
b34a axbr RRE_FEFE "add extended bfp" g5 esa,zarch
|
||||
b31a adbr RRE_FF "add long bfp" g5 esa,zarch
|
||||
ed000000001a adb RXE_FRRD "add long bfp" g5 esa,zarch
|
||||
@@ -444,9 +437,7 @@ e3000000001b slgf RXE_RRRD "subtract log
|
||||
@@ -447,9 +440,7 @@ e3000000001b slgf RXE_RRRD "subtract log
|
||||
e3000000000c msg RXE_RRRD "multiply single 64" z900 zarch
|
||||
e3000000001c msgf RXE_RRRD "multiply single 64<32" z900 zarch
|
||||
ec0000000044 brxhg RIE_RRP "branch relative on index high 64" z900 zarch
|
||||
-ec0000000044 jxhg RIE_RRP "branch relative on index high 64" z900 zarch
|
||||
ec0000000045 brxlg RIE_RRP "branch relative on index low or equal 64" z900 zarch
|
||||
-ec0000000045 jxleg RIE_RRP "branch relative on index low or equal 64" z900 zarch
|
||||
ec0000000044 brxhg RIE_RRP "branch relative on index high 64" z900 zarch condjump
|
||||
-ec0000000044 jxhg RIE_RRP "branch relative on index high 64" z900 zarch condjump
|
||||
ec0000000045 brxlg RIE_RRP "branch relative on index low or equal 64" z900 zarch condjump
|
||||
-ec0000000045 jxleg RIE_RRP "branch relative on index low or equal 64" z900 zarch condjump
|
||||
eb0000000044 bxhg RSE_RRRD "branch on index high 64" z900 zarch
|
||||
eb0000000045 bxleg RSE_RRRD "branch on index low or equal 64" z900 zarch
|
||||
eb000000000c srlg RSE_RRRD "shift right single logical 64" z900 zarch
|
||||
@@ -471,15 +462,10 @@ eb0000000080 icmh RSE_RURD "insert chara
|
||||
a702 tmhh RI_RU "test under mask high high" z900 zarch
|
||||
@@ -475,16 +466,11 @@ a702 tmhh RI_RU "test under mask high hi
|
||||
a703 tmhl RI_RU "test under mask high low" z900 zarch
|
||||
c004 brcl RIL_UP "branch relative on condition long" z900 esa,zarch
|
||||
c004 brcl RIL_UP "branch relative on condition long" z900 esa,zarch condjump
|
||||
# jlc omitted due to missing jl* (see jl*8) and not added as non-standard jgc
|
||||
-c004 jgnop RIL_0P "nop jump long" z900 esa,zarch
|
||||
c004 jg*8 RIL_0P "conditional jump long" z900 esa,zarch
|
||||
-c004 br*8l RIL_0P "conditional jump long" z900 esa,zarch
|
||||
c0f4 jg RIL_0P "unconditional jump long" z900 esa,zarch
|
||||
-c0f4 brul RIL_0P "unconditional jump long" z900 esa,zarch
|
||||
c005 brasl RIL_RP "branch relative and save long" z900 esa,zarch
|
||||
-c005 jasl RIL_RP "branch relative and save long" z900 esa,zarch
|
||||
a707 brctg RI_RP "branch relative on count 64" z900 zarch
|
||||
-a707 jctg RI_RP "branch relative on count 64" z900 zarch
|
||||
c004 jg*8 RIL_0P "conditional jump long" z900 esa,zarch condjump
|
||||
# jl*8 omitted due to clash with non-standard j*8 flavors jle and jlh; exists as non-standard jg*8 instead
|
||||
-c004 br*8l RIL_0P "conditional jump long" z900 esa,zarch condjump
|
||||
c0f4 jg RIL_0P "unconditional jump long" z900 esa,zarch jump
|
||||
-c0f4 brul RIL_0P "unconditional jump long" z900 esa,zarch jump
|
||||
c005 brasl RIL_RP "branch relative and save long" z900 esa,zarch jumpsr
|
||||
-c005 jasl RIL_RP "branch relative and save long" z900 esa,zarch jumpsr
|
||||
a707 brctg RI_RP "branch relative on count 64" z900 zarch condjump
|
||||
-a707 jctg RI_RP "branch relative on count 64" z900 zarch condjump
|
||||
a709 lghi RI_RI "load halfword immediate 64" z900 zarch
|
||||
a70b aghi RI_RI "add halfword immediate 64" z900 zarch
|
||||
a70d mghi RI_RI "multiply halfword immediate 64" z900 zarch
|
||||
|
@ -79,11 +79,11 @@ Date: Tue Feb 13 07:34:22 2018 -0800
|
||||
* testsuite/ld-x86-64/pr22791-2c.s: Likewise.
|
||||
* testsuite/ld-x86-64/x86-64.exp: Run PR ld/22791 tests.
|
||||
|
||||
diff --git a/bfd/elf64-x86-64.c b/bfd/elf64-x86-64.c
|
||||
index dc416a7f..b9f96729 100644
|
||||
--- a/bfd/elf64-x86-64.c
|
||||
+++ b/bfd/elf64-x86-64.c
|
||||
@@ -1817,6 +1817,24 @@ elf_x86_64_convert_load_reloc (bfd *abfd,
|
||||
Index: binutils-2.42/bfd/elf64-x86-64.c
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/bfd/elf64-x86-64.c 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/bfd/elf64-x86-64.c 2024-01-30 16:57:58.483994137 +0100
|
||||
@@ -1981,6 +1981,24 @@ elf_x86_64_convert_load_reloc (bfd *abfd
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -108,7 +108,7 @@ index dc416a7f..b9f96729 100644
|
||||
/* Look through the relocs for a section during the first phase, and
|
||||
calculate needed space in the global offset table, and procedure
|
||||
linkage table. */
|
||||
@@ -3159,9 +3177,6 @@ elf_x86_64_relocate_section (bfd *output_bfd,
|
||||
@@ -3337,9 +3355,6 @@ elf_x86_64_relocate_section (bfd *output
|
||||
&& (eh == NULL
|
||||
|| !UNDEFINED_WEAK_RESOLVED_TO_ZERO (info,
|
||||
eh)))
|
||||
@ -118,7 +118,7 @@ index dc416a7f..b9f96729 100644
|
||||
|| (no_copyreloc_p
|
||||
&& h->def_dynamic
|
||||
&& !(h->root.u.def.section->flags & SEC_CODE))))
|
||||
@@ -3170,20 +3185,25 @@ elf_x86_64_relocate_section (bfd *output_bfd,
|
||||
@@ -3348,20 +3363,25 @@ elf_x86_64_relocate_section (bfd *output
|
||||
|| bfd_link_dll (info)))
|
||||
{
|
||||
bool fail = false;
|
||||
@ -148,7 +148,7 @@ index dc416a7f..b9f96729 100644
|
||||
}
|
||||
else if (no_copyreloc_p || bfd_link_dll (info))
|
||||
{
|
||||
@@ -3192,9 +3212,10 @@ elf_x86_64_relocate_section (bfd *output_bfd,
|
||||
@@ -3370,9 +3390,10 @@ elf_x86_64_relocate_section (bfd *output
|
||||
relocations against default and protected
|
||||
symbols since address of protected function
|
||||
and location of protected data may not be in
|
||||
@ -161,11 +161,11 @@ index dc416a7f..b9f96729 100644
|
||||
}
|
||||
|
||||
if (fail)
|
||||
diff --git a/gas/config/tc-i386.c b/gas/config/tc-i386.c
|
||||
index d3441988e34..8f8fb086cd8 100644
|
||||
--- a/gas/config/tc-i386.c
|
||||
+++ b/gas/config/tc-i386.c
|
||||
@@ -8793,55 +8793,12 @@ output_branch (void)
|
||||
Index: binutils-2.42/gas/config/tc-i386.c
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/config/tc-i386.c 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/config/tc-i386.c 2024-01-30 16:58:57.504959847 +0100
|
||||
@@ -10699,55 +10699,12 @@ output_branch (void)
|
||||
frag_var (rs_machine_dependent, 5, i.reloc[0], subtype, sym, off, p);
|
||||
}
|
||||
|
||||
@ -221,7 +221,7 @@ index d3441988e34..8f8fb086cd8 100644
|
||||
|
||||
if (i.tm.opcode_modifier.jump == JUMP_BYTE)
|
||||
{
|
||||
@@ -8990,17 +8947,8 @@ output_jump (void)
|
||||
@@ -10821,17 +10778,8 @@ output_jump (void)
|
||||
abort ();
|
||||
}
|
||||
|
||||
@ -240,22 +240,23 @@ index d3441988e34..8f8fb086cd8 100644
|
||||
|
||||
/* All jumps handled here are signed, but don't unconditionally use a
|
||||
signed limit check for 32 and 16 bit jumps as we want to allow wrap
|
||||
@@ -12299,11 +12247,6 @@ md_estimate_size_before_relax (fragS *fragP, segT segment)
|
||||
@@ -15083,12 +15031,6 @@ md_estimate_size_before_relax (fragS *fr
|
||||
reloc_type = (enum bfd_reloc_code_real) fragP->fr_var;
|
||||
else if (size == 2)
|
||||
reloc_type = BFD_RELOC_16_PCREL;
|
||||
-#if defined (OBJ_ELF) || defined (OBJ_MAYBE_ELF)
|
||||
- else if (fragP->tc_frag_data.code64 && fragP->fr_offset == 0
|
||||
- else if (fragP->tc_frag_data.code == CODE_64BIT
|
||||
- && fragP->fr_offset == 0
|
||||
- && need_plt32_p (fragP->fr_symbol))
|
||||
- reloc_type = BFD_RELOC_X86_64_PLT32;
|
||||
-#endif
|
||||
else
|
||||
reloc_type = BFD_RELOC_32_PCREL;
|
||||
|
||||
diff --git a/gas/testsuite/gas/i386/ilp32/reloc64.d b/gas/testsuite/gas/i386/ilp32/reloc64.d
|
||||
index 78ca3fd9e38..a961679754a 100644
|
||||
--- a/gas/testsuite/gas/i386/ilp32/reloc64.d
|
||||
+++ b/gas/testsuite/gas/i386/ilp32/reloc64.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/ilp32/reloc64.d
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/ilp32/reloc64.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/ilp32/reloc64.d 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -17,7 +17,7 @@ Disassembly of section \.text:
|
||||
.*[ ]+R_X86_64_PC8[ ]+xtrn\+0x0*1
|
||||
.*[ ]+R_X86_64_PC32[ ]+xtrn-0x0*4
|
||||
@ -265,10 +266,10 @@ index 78ca3fd9e38..a961679754a 100644
|
||||
.*[ ]+R_X86_64_PC8[ ]+xtrn-0x0*1
|
||||
.*[ ]+R_X86_64_GOT32[ ]+xtrn
|
||||
.*[ ]+R_X86_64_GOT32[ ]+xtrn
|
||||
diff --git a/gas/testsuite/gas/i386/ilp32/x86-64-branch.d b/gas/testsuite/gas/i386/ilp32/x86-64-branch.d
|
||||
index acf8c42ca97..57845fdc208 100644
|
||||
--- a/gas/testsuite/gas/i386/ilp32/x86-64-branch.d
|
||||
+++ b/gas/testsuite/gas/i386/ilp32/x86-64-branch.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/ilp32/x86-64-branch.d
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/ilp32/x86-64-branch.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/ilp32/x86-64-branch.d 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -20,9 +20,9 @@ Disassembly of section .text:
|
||||
[ ]*[a-f0-9]+: 66 ff 20 data16 jmp \*\(%rax\)
|
||||
[ ]*[a-f0-9]+: e8 00 00 00 00 call (0x)?1f <.*> 1b: R_X86_64_PC32 \*ABS\*\+0x10003c
|
||||
@ -282,10 +283,10 @@ index acf8c42ca97..57845fdc208 100644
|
||||
[ ]*[a-f0-9]+: 66 c3 data16 ret
|
||||
[ ]*[a-f0-9]+: 66 c2 08 00 data16 ret \$0x8
|
||||
[ ]*[a-f0-9]+: 3e 74 03[ ]+je,pt +[0-9a-fx]+ <.*>
|
||||
diff --git a/gas/testsuite/gas/i386/reloc64.d b/gas/testsuite/gas/i386/reloc64.d
|
||||
index 540a9b77d35..ea16c68de4b 100644
|
||||
--- a/gas/testsuite/gas/i386/reloc64.d
|
||||
+++ b/gas/testsuite/gas/i386/reloc64.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/reloc64.d
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/reloc64.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/reloc64.d 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -20,7 +20,7 @@ Disassembly of section \.text:
|
||||
.*[ ]+R_X86_64_PC8[ ]+xtrn\+0x0*1
|
||||
.*[ ]+R_X86_64_PC32[ ]+xtrn-0x0*4
|
||||
@ -295,10 +296,10 @@ index 540a9b77d35..ea16c68de4b 100644
|
||||
.*[ ]+R_X86_64_PC8[ ]+xtrn-0x0*1
|
||||
.*[ ]+R_X86_64_GOT64[ ]+xtrn
|
||||
.*[ ]+R_X86_64_GOT32[ ]+xtrn
|
||||
diff --git a/gas/testsuite/gas/i386/x86-64-branch-2.d b/gas/testsuite/gas/i386/x86-64-branch-2.d
|
||||
index fab75a6394c..e025de90b68 100644
|
||||
--- a/gas/testsuite/gas/i386/x86-64-branch-2.d
|
||||
+++ b/gas/testsuite/gas/i386/x86-64-branch-2.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/x86-64-branch-2.d
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/x86-64-branch-2.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/x86-64-branch-2.d 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -9,12 +9,12 @@ Disassembly of section .text:
|
||||
|
||||
0+ <bar-0xb>:
|
||||
@ -314,10 +315,10 @@ index fab75a6394c..e025de90b68 100644
|
||||
[ ]*[a-f0-9]+: 66 c3 retw
|
||||
[ ]*[a-f0-9]+: 66 c2 08 00 retw \$0x8
|
||||
#pass
|
||||
diff --git a/gas/testsuite/gas/i386/x86-64-jump.d b/gas/testsuite/gas/i386/x86-64-jump.d
|
||||
index 7d2c994ce26..58ad424badb 100644
|
||||
--- a/gas/testsuite/gas/i386/x86-64-jump.d
|
||||
+++ b/gas/testsuite/gas/i386/x86-64-jump.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/x86-64-jump.d
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/x86-64-jump.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/x86-64-jump.d 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -9,7 +9,7 @@ Disassembly of section .text:
|
||||
|
||||
0+ <.text>:
|
||||
@ -336,10 +337,10 @@ index 7d2c994ce26..58ad424badb 100644
|
||||
[ ]*[a-f0-9]+: ff 14 25 00 00 00 00 call \*0x0 3d: R_X86_64_32S xxx
|
||||
[ ]*[a-f0-9]+: ff d7 call \*%rdi
|
||||
[ ]*[a-f0-9]+: ff 17 call \*\(%rdi\)
|
||||
diff --git a/gas/testsuite/gas/i386/x86-64-nop-3.d b/gas/testsuite/gas/i386/x86-64-nop-3.d
|
||||
index 1975481cc59..436487b5a99 100644
|
||||
--- a/gas/testsuite/gas/i386/x86-64-nop-3.d
|
||||
+++ b/gas/testsuite/gas/i386/x86-64-nop-3.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/x86-64-nop-3.d
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/x86-64-nop-3.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/x86-64-nop-3.d 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -18,5 +18,5 @@ Disassembly of section .text:
|
||||
Disassembly of section .altinstr_replacement:
|
||||
|
||||
@ -347,32 +348,32 @@ index 1975481cc59..436487b5a99 100644
|
||||
- +[a-f0-9]+: e9 00 00 00 00 jmp 5 <_start\+0x5> 1: R_X86_64_PLT32 foo-0x4
|
||||
+ +[a-f0-9]+: e9 00 00 00 00 jmp 5 <_start\+0x5> 1: R_X86_64_PC32 foo-0x4
|
||||
#pass
|
||||
diff --git a/gas/testsuite/gas/i386/x86-64-nop-4.d b/gas/testsuite/gas/i386/x86-64-nop-4.d
|
||||
index 2da858db994..e390628b335 100644
|
||||
--- a/gas/testsuite/gas/i386/x86-64-nop-4.d
|
||||
+++ b/gas/testsuite/gas/i386/x86-64-nop-4.d
|
||||
@@ -21,5 +21,5 @@ Disassembly of section .altinstr_replacement:
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/x86-64-nop-4.d
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/x86-64-nop-4.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/x86-64-nop-4.d 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -21,5 +21,5 @@ Disassembly of section .altinstr_replace
|
||||
+[a-f0-9]+: 89 c0 mov %eax,%eax
|
||||
+[a-f0-9]+: 89 c0 mov %eax,%eax
|
||||
+[a-f0-9]+: 89 c0 mov %eax,%eax
|
||||
- +[a-f0-9]+: e9 00 00 00 00 jmp b <_start\+0xb> 7: R_X86_64_PLT32 foo-0x4
|
||||
+ +[a-f0-9]+: e9 00 00 00 00 jmp b <_start\+0xb> 7: R_X86_64_PC32 foo-0x4
|
||||
#pass
|
||||
diff --git a/gas/testsuite/gas/i386/x86-64-nop-5.d b/gas/testsuite/gas/i386/x86-64-nop-5.d
|
||||
index d5c84c1edf8..69820d54de8 100644
|
||||
--- a/gas/testsuite/gas/i386/x86-64-nop-5.d
|
||||
+++ b/gas/testsuite/gas/i386/x86-64-nop-5.d
|
||||
@@ -24,5 +24,5 @@ Disassembly of section .altinstr_replacement:
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/x86-64-nop-5.d
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/x86-64-nop-5.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/x86-64-nop-5.d 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -24,5 +24,5 @@ Disassembly of section .altinstr_replace
|
||||
+[a-f0-9]+: 89 c0 mov %eax,%eax
|
||||
+[a-f0-9]+: 89 c0 mov %eax,%eax
|
||||
+[a-f0-9]+: 89 c0 mov %eax,%eax
|
||||
- +[a-f0-9]+: e9 00 00 00 00 jmp d <_start\+0xd> 9: R_X86_64_PLT32 foo-0x4
|
||||
+ +[a-f0-9]+: e9 00 00 00 00 jmp d <_start\+0xd> 9: R_X86_64_PC32 foo-0x4
|
||||
#pass
|
||||
diff --git a/gas/testsuite/gas/i386/x86-64-relax-2.d b/gas/testsuite/gas/i386/x86-64-relax-2.d
|
||||
index fba47c14850..0949ab23907 100644
|
||||
--- a/gas/testsuite/gas/i386/x86-64-relax-2.d
|
||||
+++ b/gas/testsuite/gas/i386/x86-64-relax-2.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/x86-64-relax-2.d
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/x86-64-relax-2.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/x86-64-relax-2.d 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -11,12 +11,12 @@ Disassembly of section .text:
|
||||
0+ <foo>:
|
||||
[ ]*[a-f0-9]+: eb 24 jmp 26 <local>
|
||||
@ -391,10 +392,10 @@ index fba47c14850..0949ab23907 100644
|
||||
|
||||
0+22 <hidden_def>:
|
||||
[ ]*[a-f0-9]+: c3 ret
|
||||
diff --git a/gas/testsuite/gas/i386/x86-64-relax-3.d b/gas/testsuite/gas/i386/x86-64-relax-3.d
|
||||
index 01df9ef340e..d16e6a55395 100644
|
||||
--- a/gas/testsuite/gas/i386/x86-64-relax-3.d
|
||||
+++ b/gas/testsuite/gas/i386/x86-64-relax-3.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/x86-64-relax-3.d
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/x86-64-relax-3.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/x86-64-relax-3.d 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -12,10 +12,10 @@ Disassembly of section .text:
|
||||
[ ]*[a-f0-9]+: eb 1b jmp 1f <hidden_def>
|
||||
[ ]*[a-f0-9]+: eb 1b jmp 21 <global_def>
|
||||
@ -410,29 +411,26 @@ index 01df9ef340e..d16e6a55395 100644
|
||||
|
||||
0+1f <hidden_def>:
|
||||
[ ]*[a-f0-9]+: c3 ret
|
||||
diff --git a/ld/testsuite/ld-x86-64/pr22791-1.err b/ld/testsuite/ld-x86-64/pr22791-1.err
|
||||
deleted file mode 100644
|
||||
index 8c5565992e7..00000000000
|
||||
--- a/ld/testsuite/ld-x86-64/pr22791-1.err
|
||||
+++ /dev/null
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/pr22791-1.err
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/pr22791-1.err 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
@@ -1,2 +0,0 @@
|
||||
-.*relocation R_X86_64_PC32 against symbol `foo' can not be used when making a PIE object; recompile with -fPIE
|
||||
-#...
|
||||
diff --git a/ld/testsuite/ld-x86-64/pr22791-1a.c b/ld/testsuite/ld-x86-64/pr22791-1a.c
|
||||
deleted file mode 100644
|
||||
index cd0130cacdf..00000000000
|
||||
--- a/ld/testsuite/ld-x86-64/pr22791-1a.c
|
||||
+++ /dev/null
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/pr22791-1a.c
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/pr22791-1a.c 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
@@ -1,4 +0,0 @@
|
||||
-void
|
||||
-foo (void)
|
||||
-{
|
||||
-}
|
||||
diff --git a/ld/testsuite/ld-x86-64/pr22791-1b.s b/ld/testsuite/ld-x86-64/pr22791-1b.s
|
||||
deleted file mode 100644
|
||||
index 9751db49aa5..00000000000
|
||||
--- a/ld/testsuite/ld-x86-64/pr22791-1b.s
|
||||
+++ /dev/null
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/pr22791-1b.s
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/pr22791-1b.s 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
@@ -1,7 +0,0 @@
|
||||
- .text
|
||||
- .globl main
|
||||
@ -441,11 +439,10 @@ index 9751db49aa5..00000000000
|
||||
- movl foo(%rip), %eax
|
||||
- .size main, .-main
|
||||
- .section .note.GNU-stack
|
||||
diff --git a/ld/testsuite/ld-x86-64/pr22791-2.rd b/ld/testsuite/ld-x86-64/pr22791-2.rd
|
||||
deleted file mode 100644
|
||||
index 70deb30d84d..00000000000
|
||||
--- a/ld/testsuite/ld-x86-64/pr22791-2.rd
|
||||
+++ /dev/null
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/pr22791-2.rd
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/pr22791-2.rd 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
@@ -1,6 +0,0 @@
|
||||
-#failif
|
||||
-#...
|
||||
@ -453,11 +450,10 @@ index 70deb30d84d..00000000000
|
||||
-#...
|
||||
-[0-9a-f ]+R_X86_64_NONE.*
|
||||
-#...
|
||||
diff --git a/ld/testsuite/ld-x86-64/pr22791-2a.s b/ld/testsuite/ld-x86-64/pr22791-2a.s
|
||||
deleted file mode 100644
|
||||
index 0a855024d74..00000000000
|
||||
--- a/ld/testsuite/ld-x86-64/pr22791-2a.s
|
||||
+++ /dev/null
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/pr22791-2a.s
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/pr22791-2a.s 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
@@ -1,8 +0,0 @@
|
||||
- .text
|
||||
- .p2align 4,,15
|
||||
@ -467,11 +463,10 @@ index 0a855024d74..00000000000
|
||||
- jmp bar
|
||||
- .size foo, .-foo
|
||||
- .section .note.GNU-stack,"",@progbits
|
||||
diff --git a/ld/testsuite/ld-x86-64/pr22791-2b.c b/ld/testsuite/ld-x86-64/pr22791-2b.c
|
||||
deleted file mode 100644
|
||||
index 79ef27c0857..00000000000
|
||||
--- a/ld/testsuite/ld-x86-64/pr22791-2b.c
|
||||
+++ /dev/null
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/pr22791-2b.c
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/pr22791-2b.c 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
@@ -1,7 +0,0 @@
|
||||
-#include <stdio.h>
|
||||
-
|
||||
@ -480,11 +475,10 @@ index 79ef27c0857..00000000000
|
||||
-{
|
||||
- puts ("PASS");
|
||||
-}
|
||||
diff --git a/ld/testsuite/ld-x86-64/pr22791-2c.s b/ld/testsuite/ld-x86-64/pr22791-2c.s
|
||||
deleted file mode 100644
|
||||
index 1460d1b8288..00000000000
|
||||
--- a/ld/testsuite/ld-x86-64/pr22791-2c.s
|
||||
+++ /dev/null
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/pr22791-2c.s
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/pr22791-2c.s 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
@@ -1,12 +0,0 @@
|
||||
- .text
|
||||
- .p2align 4,,15
|
||||
@ -498,10 +492,10 @@ index 1460d1b8288..00000000000
|
||||
- ret
|
||||
- .size main, .-main
|
||||
- .section .note.GNU-stack,"",@progbits
|
||||
diff --git a/ld/testsuite/ld-x86-64/pr22842b.S b/ld/testsuite/ld-x86-64/pr22842b.S
|
||||
index f0659cd901e..b9dd81345b7 100644
|
||||
--- a/ld/testsuite/ld-x86-64/pr22842b.S
|
||||
+++ b/ld/testsuite/ld-x86-64/pr22842b.S
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/pr22842b.S
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/pr22842b.S 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/ld/testsuite/ld-x86-64/pr22842b.S 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -7,7 +7,7 @@ main:
|
||||
leaq bar(%rip), %rdi
|
||||
addq %rax, %rdi
|
||||
@ -511,15 +505,14 @@ index f0659cd901e..b9dd81345b7 100644
|
||||
xorl %eax, %eax
|
||||
popq %rcx
|
||||
retq
|
||||
diff --git a/ld/testsuite/ld-x86-64/x86-64.exp b/ld/testsuite/ld-x86-64/x86-64.exp
|
||||
index 17fd10ee121..b4ae52ab376 100644
|
||||
--- a/ld/testsuite/ld-x86-64/x86-64.exp
|
||||
+++ b/ld/testsuite/ld-x86-64/x86-64.exp
|
||||
@@ -1264,44 +1264,6 @@ if { [isnative] && [check_compiler_available] } {
|
||||
{readelf -lW pr22393-3b.rd}} \
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/x86-64.exp
|
||||
===================================================================
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/x86-64.exp 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/ld/testsuite/ld-x86-64/x86-64.exp 2024-01-30 16:57:58.487327524 +0100
|
||||
@@ -1235,44 +1235,6 @@ if { [isnative] && [check_compiler_avail
|
||||
"pr22393-3-static" \
|
||||
] \
|
||||
- [list \
|
||||
[list \
|
||||
- "Build pr22791-1.so" \
|
||||
- "-shared" \
|
||||
- "-fPIC -Wa,-mx86-used-note=yes" \
|
||||
@ -557,14 +550,14 @@ index 17fd10ee121..b4ae52ab376 100644
|
||||
- {{readelf -drW pr22791-2.rd}} \
|
||||
- "pr22791-2" \
|
||||
- ] \
|
||||
[list \
|
||||
- [list \
|
||||
"Build pr22842.so" \
|
||||
"-shared" \
|
||||
@@ -1703,15 +1665,6 @@ if { [isnative] && [check_compiler_available] } {
|
||||
"pr22393-3-static" \
|
||||
"-fPIC -Wa,-mx86-used-note=yes" \
|
||||
@@ -1762,15 +1724,6 @@ if { [isnative] && [check_compiler_avail
|
||||
"pass.out" \
|
||||
] \
|
||||
- [list \
|
||||
[list \
|
||||
- "Run pr22791-2" \
|
||||
- "-pie -Wl,--no-as-needed tmpdir/pr22791-2.so" \
|
||||
- "-Wa,-mx86-used-note=yes" \
|
||||
@ -573,6 +566,7 @@ index 17fd10ee121..b4ae52ab376 100644
|
||||
- "pass.out" \
|
||||
- "$NOPIE_CFLAGS" \
|
||||
- ] \
|
||||
[list \
|
||||
- [list \
|
||||
"Run pr22842" \
|
||||
"-pie -Wl,--no-as-needed tmpdir/pr22842.so" \
|
||||
"-Wa,-mx86-used-note=yes" \
|
||||
|
@ -26,10 +26,10 @@ of missing support in ld.so.
|
||||
proper predicate to guard themself)
|
||||
|
||||
|
||||
Index: binutils-2.41/bfd/elf64-x86-64.c
|
||||
Index: binutils-2.42/bfd/elf64-x86-64.c
|
||||
===================================================================
|
||||
--- binutils-2.41.orig/bfd/elf64-x86-64.c 2023-08-16 17:34:14.991069097 +0200
|
||||
+++ binutils-2.41/bfd/elf64-x86-64.c 2023-08-16 17:34:48.295651473 +0200
|
||||
--- binutils-2.42.orig/bfd/elf64-x86-64.c 2024-01-30 16:59:42.442361796 +0100
|
||||
+++ binutils-2.42/bfd/elf64-x86-64.c 2024-01-30 17:54:25.162977883 +0100
|
||||
@@ -48,127 +48,127 @@ static reloc_howto_type x86_64_elf_howto
|
||||
bfd_elf_generic_reloc, "R_X86_64_NONE", false, 0, 0x00000000,
|
||||
false),
|
||||
@ -197,9 +197,9 @@ Index: binutils-2.41/bfd/elf64-x86-64.c
|
||||
- bfd_elf_generic_reloc, "R_X86_64_REX_GOTPCRELX", false, 0, 0xffffffff,
|
||||
+ bfd_elf_generic_reloc, "R_X86_64_REX_GOTPCRELX", false, 0xffffffff, 0xffffffff,
|
||||
true),
|
||||
|
||||
/* We have a gap in the reloc numbers here.
|
||||
@@ -189,7 +189,7 @@ static reloc_howto_type x86_64_elf_howto
|
||||
HOWTO(R_X86_64_CODE_4_GOTPCRELX, 0, 4, 32, true, 0, complain_overflow_signed,
|
||||
bfd_elf_generic_reloc, "R_X86_64_CODE_4_GOTPCRELX", false, 0, 0xffffffff,
|
||||
@@ -198,7 +198,7 @@ static reloc_howto_type x86_64_elf_howto
|
||||
|
||||
/* Use complain_overflow_bitfield on R_X86_64_32 for x32. */
|
||||
HOWTO(R_X86_64_32, 0, 4, 32, false, 0, complain_overflow_bitfield,
|
||||
@ -208,9 +208,9 @@ Index: binutils-2.41/bfd/elf64-x86-64.c
|
||||
false)
|
||||
};
|
||||
|
||||
Index: binutils-2.41/gas/testsuite/gas/i386/rela.d
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/rela.d
|
||||
===================================================================
|
||||
--- binutils-2.41.orig/gas/testsuite/gas/i386/rela.d 2023-07-03 01:00:00.000000000 +0200
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/rela.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
@@ -1,13 +0,0 @@
|
||||
-#name: x86-64 rela relocs w/ non-zero relocated fields
|
||||
@ -226,9 +226,9 @@ Index: binutils-2.41/gas/testsuite/gas/i386/rela.d
|
||||
-
|
||||
-Contents of section .data:
|
||||
- 0+0 11 ?11 ?11 ?11 22 ?22 ?22 ?22 33 ?33 ?33 ?33 44 ?44 ?44 ?44 .*
|
||||
Index: binutils-2.41/gas/testsuite/gas/i386/rela.s
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/rela.s
|
||||
===================================================================
|
||||
--- binutils-2.41.orig/gas/testsuite/gas/i386/rela.s 2023-07-03 01:00:00.000000000 +0200
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/rela.s 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
@@ -1,14 +0,0 @@
|
||||
-# Note: This file is also used by an ld test case.
|
||||
@ -245,9 +245,9 @@ Index: binutils-2.41/gas/testsuite/gas/i386/rela.s
|
||||
-
|
||||
- .reloc l, BFD_RELOC_64, q
|
||||
- .reloc q, BFD_RELOC_32, l
|
||||
Index: binutils-2.41/ld/testsuite/ld-x86-64/rela.d
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/rela.d
|
||||
===================================================================
|
||||
--- binutils-2.41.orig/ld/testsuite/ld-x86-64/rela.d 2023-07-03 01:00:00.000000000 +0200
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/rela.d 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
|
||||
@@ -1,10 +0,0 @@
|
||||
-#name: x86-64 rela relocs w/ non-zero relocated fields
|
||||
@ -260,11 +260,11 @@ Index: binutils-2.41/ld/testsuite/ld-x86-64/rela.d
|
||||
-
|
||||
-Contents of section .data:
|
||||
- *[0-9a-f]*0 .8 ?.. ?.. ?.. 00 ?00 ?00 ?00 .0 ?.. ?.. ?.. 44 ?44 ?44 ?44 .*
|
||||
Index: binutils-2.41/ld/testsuite/ld-x86-64/x86-64.exp
|
||||
Index: binutils-2.42/ld/testsuite/ld-x86-64/x86-64.exp
|
||||
===================================================================
|
||||
--- binutils-2.41.orig/ld/testsuite/ld-x86-64/x86-64.exp 2023-08-16 17:34:14.967068677 +0200
|
||||
+++ binutils-2.41/ld/testsuite/ld-x86-64/x86-64.exp 2023-08-16 17:34:48.295651473 +0200
|
||||
@@ -286,7 +286,6 @@ run_dump_test "apic"
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-x86-64/x86-64.exp 2024-01-30 16:57:58.487327524 +0100
|
||||
+++ binutils-2.42/ld/testsuite/ld-x86-64/x86-64.exp 2024-01-30 17:55:13.480432003 +0100
|
||||
@@ -291,7 +291,6 @@ run_dump_test "apic"
|
||||
run_dump_test "pcrel8"
|
||||
run_dump_test "pcrel16"
|
||||
run_dump_test "pcrel16-2"
|
||||
@ -272,7 +272,7 @@ Index: binutils-2.41/ld/testsuite/ld-x86-64/x86-64.exp
|
||||
run_dump_test "tlsgd2"
|
||||
run_dump_test "tlsgd3"
|
||||
run_dump_test "tlsgd12"
|
||||
@@ -501,10 +500,10 @@ run_dump_test "pr27491-1c"
|
||||
@@ -506,10 +505,10 @@ run_dump_test "pr27491-1c"
|
||||
run_dump_test "pr27491-2"
|
||||
run_dump_test "pr27491-3"
|
||||
run_dump_test "pr27491-4"
|
||||
@ -284,14 +284,14 @@ Index: binutils-2.41/ld/testsuite/ld-x86-64/x86-64.exp
|
||||
+#run_dump_test "dt-relr-1a-x32"
|
||||
+#run_dump_test "dt-relr-1b"
|
||||
+#run_dump_test "dt-relr-1b-x32"
|
||||
|
||||
if { ![skip_sframe_tests] } {
|
||||
run_dump_test "sframe-simple-1"
|
||||
Index: binutils-2.41/binutils/testsuite/lib/binutils-common.exp
|
||||
run_dump_test "pr30787"
|
||||
run_dump_test "pr31047"
|
||||
run_dump_test "pr31047-x32"
|
||||
Index: binutils-2.42/binutils/testsuite/lib/binutils-common.exp
|
||||
===================================================================
|
||||
--- binutils-2.41.orig/binutils/testsuite/lib/binutils-common.exp 2023-07-03 01:00:00.000000000 +0200
|
||||
+++ binutils-2.41/binutils/testsuite/lib/binutils-common.exp 2023-08-16 17:34:48.295651473 +0200
|
||||
@@ -442,6 +442,8 @@ proc supports_persistent_section {} {
|
||||
--- binutils-2.42.orig/binutils/testsuite/lib/binutils-common.exp 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/binutils/testsuite/lib/binutils-common.exp 2024-01-30 17:54:25.166311271 +0100
|
||||
@@ -449,6 +449,8 @@ proc supports_persistent_section {} {
|
||||
|
||||
# Whether a target support DT_RELR sections.
|
||||
proc supports_dt_relr {} {
|
||||
@ -300,10 +300,10 @@ Index: binutils-2.41/binutils/testsuite/lib/binutils-common.exp
|
||||
if { ([istarget x86_64-*-*]
|
||||
|| [istarget i?86-*-*]
|
||||
|| [istarget powerpc64*-*-*])
|
||||
Index: binutils-2.41/ld/emulparams/dt-relr.sh
|
||||
Index: binutils-2.42/ld/emulparams/dt-relr.sh
|
||||
===================================================================
|
||||
--- binutils-2.41.orig/ld/emulparams/dt-relr.sh 2023-07-03 01:00:00.000000000 +0200
|
||||
+++ binutils-2.41/ld/emulparams/dt-relr.sh 2023-08-16 17:34:48.295651473 +0200
|
||||
--- binutils-2.42.orig/ld/emulparams/dt-relr.sh 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/ld/emulparams/dt-relr.sh 2024-01-30 17:54:25.166311271 +0100
|
||||
@@ -1,3 +1,8 @@
|
||||
+if false; then
|
||||
+ # on old codestreams we don't have the DT_RELR support in the dynamic
|
||||
@ -319,10 +319,10 @@ Index: binutils-2.41/ld/emulparams/dt-relr.sh
|
||||
PARSE_AND_LIST_ARGS_CASE_Z="$PARSE_AND_LIST_ARGS_CASE_Z $PARSE_AND_LIST_ARGS_CASE_Z_PACK_RELATIVE_RELOCS"
|
||||
+
|
||||
+fi
|
||||
Index: binutils-2.41/ld/testsuite/ld-i386/i386.exp
|
||||
Index: binutils-2.42/ld/testsuite/ld-i386/i386.exp
|
||||
===================================================================
|
||||
--- binutils-2.41.orig/ld/testsuite/ld-i386/i386.exp 2023-07-03 01:00:00.000000000 +0200
|
||||
+++ binutils-2.41/ld/testsuite/ld-i386/i386.exp 2023-08-16 17:34:48.299651544 +0200
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-i386/i386.exp 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/ld/testsuite/ld-i386/i386.exp 2024-01-30 17:54:25.166311271 +0100
|
||||
@@ -507,8 +507,8 @@ run_dump_test "pr27491-1c"
|
||||
run_dump_test "pr27491-2"
|
||||
run_dump_test "pr27491-3"
|
||||
@ -333,11 +333,11 @@ Index: binutils-2.41/ld/testsuite/ld-i386/i386.exp
|
||||
+#run_dump_test "dt-relr-1b"
|
||||
run_dump_test "pr28870"
|
||||
run_dump_test "pr28894"
|
||||
|
||||
Index: binutils-2.41/ld/testsuite/ld-powerpc/powerpc.exp
|
||||
run_dump_test "pr30787"
|
||||
Index: binutils-2.42/ld/testsuite/ld-powerpc/powerpc.exp
|
||||
===================================================================
|
||||
--- binutils-2.41.orig/ld/testsuite/ld-powerpc/powerpc.exp 2023-08-16 17:34:14.895067416 +0200
|
||||
+++ binutils-2.41/ld/testsuite/ld-powerpc/powerpc.exp 2023-08-16 17:34:48.299651544 +0200
|
||||
--- binutils-2.42.orig/ld/testsuite/ld-powerpc/powerpc.exp 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/ld/testsuite/ld-powerpc/powerpc.exp 2024-01-30 17:54:25.166311271 +0100
|
||||
@@ -378,14 +378,14 @@ set ppc64elftests {
|
||||
"-a64" {abs-reloc.s}
|
||||
{{objdump {-sdr} abs-shared.d}
|
||||
@ -361,11 +361,11 @@ Index: binutils-2.41/ld/testsuite/ld-powerpc/powerpc.exp
|
||||
}
|
||||
|
||||
set ppceabitests {
|
||||
Index: binutils-2.41/gas/testsuite/gas/i386/x86-64.exp
|
||||
Index: binutils-2.42/gas/testsuite/gas/i386/x86-64.exp
|
||||
===================================================================
|
||||
--- binutils-2.41.orig/gas/testsuite/gas/i386/x86-64.exp 2023-07-03 01:00:00.000000000 +0200
|
||||
+++ binutils-2.41/gas/testsuite/gas/i386/x86-64.exp 2023-08-16 17:38:35.023605534 +0200
|
||||
@@ -588,7 +588,6 @@ if [is_elf_format] then {
|
||||
--- binutils-2.42.orig/gas/testsuite/gas/i386/x86-64.exp 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ binutils-2.42/gas/testsuite/gas/i386/x86-64.exp 2024-01-30 17:54:25.166311271 +0100
|
||||
@@ -628,7 +628,6 @@ if [is_elf_format] then {
|
||||
run_list_test "reloc64" "--defsym _bad_=1"
|
||||
run_list_test "x86-64-inval-tls"
|
||||
run_dump_test "mixed-mode-reloc64"
|
||||
|
@ -1,131 +0,0 @@
|
||||
We need this for libQt5WebEngine on i586. (bsc#1216908)
|
||||
|
||||
From 836654b1177ab305c36fe7319f08f0ad5d4fac1b Mon Sep 17 00:00:00 2001
|
||||
From: Michael Matz <matz@suse.de>
|
||||
Date: Tue, 7 Nov 2023 16:54:44 +0100
|
||||
Subject: ld: Avoid overflows in string merging
|
||||
To: binutils@sourceware.org
|
||||
|
||||
as the bug report shows we had an overflow in the test if
|
||||
hash table resizing is needed. Reorder the expression to avoid
|
||||
that. There's still a bug somewhere in gracefully handling
|
||||
failure in resizing (e.g. out of memory), but this pushes the
|
||||
boundary for that occurring somewhen into the future and
|
||||
immediately helps the reporter.
|
||||
|
||||
bfd/
|
||||
|
||||
PR ld/31009
|
||||
* merge.c (NEEDS_RESIZE): New macro avoiding overflow.
|
||||
(sec_merge_maybe_resize): Use it.
|
||||
(sec_merge_hash_insert): Ditto.
|
||||
---
|
||||
bfd/merge.c | 12 ++++++++----
|
||||
1 file changed, 8 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/bfd/merge.c b/bfd/merge.c
|
||||
index 722e6659486..61ffab4d706 100644
|
||||
--- a/bfd/merge.c
|
||||
+++ b/bfd/merge.c
|
||||
@@ -94,6 +94,10 @@ struct sec_merge_hash
|
||||
struct sec_merge_hash_entry **values;
|
||||
};
|
||||
|
||||
+/* True when given NEWCOUNT and NBUCKETS indicate that the hash table needs
|
||||
+ resizing. */
|
||||
+#define NEEDS_RESIZE(newcount, nbuckets) ((newcount) > (nbuckets) / 3 * 2)
|
||||
+
|
||||
struct sec_merge_sec_info;
|
||||
|
||||
/* Information per merged blob. This is the unit of merging and is
|
||||
@@ -167,7 +171,7 @@ static bool
|
||||
sec_merge_maybe_resize (struct sec_merge_hash *table, unsigned added)
|
||||
{
|
||||
struct bfd_hash_table *bfdtab = &table->table;
|
||||
- if (bfdtab->count + added > table->nbuckets * 2 / 3)
|
||||
+ if (NEEDS_RESIZE (bfdtab->count + added, table->nbuckets))
|
||||
{
|
||||
unsigned i;
|
||||
unsigned long newnb = table->nbuckets * 2;
|
||||
@@ -175,7 +179,7 @@ sec_merge_maybe_resize (struct sec_merge_hash *table, unsigned added)
|
||||
uint64_t *newl;
|
||||
unsigned long alloc;
|
||||
|
||||
- while (bfdtab->count + added > newnb * 2 / 3)
|
||||
+ while (NEEDS_RESIZE (bfdtab->count + added, newnb))
|
||||
{
|
||||
newnb *= 2;
|
||||
if (!newnb)
|
||||
@@ -239,8 +243,8 @@ sec_merge_hash_insert (struct sec_merge_hash *table,
|
||||
hashp->alignment = 0;
|
||||
hashp->u.suffix = NULL;
|
||||
hashp->next = NULL;
|
||||
- // We must not need resizing, otherwise _index is wrong
|
||||
- BFD_ASSERT (bfdtab->count + 1 <= table->nbuckets * 2 / 3);
|
||||
+ // We must not need resizing, otherwise the estimation was wrong
|
||||
+ BFD_ASSERT (!NEEDS_RESIZE (bfdtab->count + 1, table->nbuckets));
|
||||
bfdtab->count++;
|
||||
table->key_lens[_index] = (hash << 32) | (uint32_t)len;
|
||||
table->values[_index] = hashp;
|
||||
--
|
||||
2.42.0
|
||||
|
||||
|
||||
From 21160d8a18dc21aafb8ab1026e13e5c524954a46 Mon Sep 17 00:00:00 2001
|
||||
From: Michael Matz <matz@suse.de>
|
||||
Date: Tue, 7 Nov 2023 17:12:46 +0100
|
||||
Subject: bfd: use less memory in string merging
|
||||
To: binutils@sourceware.org
|
||||
|
||||
the offset-to-entry mappings are allocated in blocks, which may
|
||||
become a bit wasteful in case there are extremely many small
|
||||
input files or sections. This made it so that a large project
|
||||
(Qt5WebEngine) didn't build anymore on x86 32bit due to address
|
||||
space limits. It barely fit into address space before the new
|
||||
string merging, and then got pushed over the limit by this.
|
||||
|
||||
So instead of leaving the waste reallocate the maps to their final
|
||||
size once known. Now the link barely fits again.
|
||||
|
||||
bfd/
|
||||
* merge.c (record_section): Reallocate offset maps to their
|
||||
final size.
|
||||
---
|
||||
bfd/merge.c | 14 ++++++++++++++
|
||||
1 file changed, 14 insertions(+)
|
||||
|
||||
diff --git a/bfd/merge.c b/bfd/merge.c
|
||||
index 61ffab4d706..eeaa1a01fe3 100644
|
||||
--- a/bfd/merge.c
|
||||
+++ b/bfd/merge.c
|
||||
@@ -711,6 +711,7 @@ record_section (struct sec_merge_info *sinfo,
|
||||
unsigned int align;
|
||||
bfd_size_type amt;
|
||||
bfd_byte *contents;
|
||||
+ void *tmpptr;
|
||||
|
||||
amt = sec->size;
|
||||
if (sec->flags & SEC_STRINGS)
|
||||
@@ -771,6 +772,19 @@ record_section (struct sec_merge_info *sinfo,
|
||||
|
||||
free (contents);
|
||||
contents = NULL;
|
||||
+
|
||||
+ /* We allocate the ofsmap arrays in blocks of 2048 elements.
|
||||
+ In case we have very many small input files/sections,
|
||||
+ this might waste large amounts of memory, so reallocate these
|
||||
+ arrays here to their true size. */
|
||||
+ amt = secinfo->noffsetmap + 1;
|
||||
+ tmpptr = bfd_realloc (secinfo->map, amt * sizeof(secinfo->map[0]));
|
||||
+ if (tmpptr)
|
||||
+ secinfo->map = tmpptr;
|
||||
+ tmpptr = bfd_realloc (secinfo->map_ofs, amt * sizeof(secinfo->map_ofs[0]));
|
||||
+ if (tmpptr)
|
||||
+ secinfo->map_ofs = tmpptr;
|
||||
+
|
||||
/*printf ("ZZZ %s:%s %u entries\n", sec->owner->filename, sec->name,
|
||||
(unsigned)secinfo->noffsetmap);*/
|
||||
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,3 +1,77 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Jun 13 08:35:38 UTC 2024 - Andreas Schwab <schwab@suse.de>
|
||||
|
||||
- binutils-pr22868.diff: Remove obsolete patch
|
||||
- Undefine _FORTIFY_SOURCE when running checks
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed May 1 09:52:29 UTC 2024 - Bernhard Wiedemann <bwiedemann@suse.com>
|
||||
|
||||
- Allow to disable profiling
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Feb 22 10:11:25 UTC 2024 - Dominique Leuenberger <dimstar@opensuse.org>
|
||||
|
||||
- Use %patch -P N instead of deprecated %patchN.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Feb 21 09:56:08 UTC 2024 - Andreas Schwab <schwab@suse.de>
|
||||
|
||||
- riscv-no-relax.patch: RISC-V: Don't generate branch/jump relocation if
|
||||
symbol is local when no-relax
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Feb 5 16:57:05 UTC 2024 - Michael Matz <matz@suse.com>
|
||||
|
||||
- Add binutils-disable-code-arch-error.diff to demote an
|
||||
error about swapped .arch/.code directives to a warning.
|
||||
It happens in the wild.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Jan 30 13:52:11 UTC 2024 - Michael Matz <matz@suse.com>
|
||||
|
||||
- Update to version 2.42:
|
||||
* Add support for many aarch64 extensions: SVE2.1, SME2.1, B16B16,
|
||||
RASv2, LSE128, GCS, CHK, SPECRES2, LRCPC3, THE, ITE, D128, XS and
|
||||
flags to enable them: '+fcma', '+jscvt', '+frintts', '+flagm2',
|
||||
'+rcpc2' and '+wfxt'
|
||||
* Add experimantal support for GAS to synthesize call-frame-info for
|
||||
some hand-written asm (--scfi=experimental) on x86-64.
|
||||
* Add support for more x86-64 extensions: APX: 32 GPRs, NDD, PUSH2/POP2,
|
||||
PUSHP/POPP; USER_MSR, AVX10.1, PBNDKB, SM4, SM3, SHA512, AVX-VNNI-INT16.
|
||||
* Add support for more RISC-V extensions: T-Head v2.3.0, CORE-V v1.0,
|
||||
SiFive VCIX v1.0.
|
||||
* BPF assembler: ';' separates statements now, and does not introduce
|
||||
line comments anymore (use '#' or '//' for this).
|
||||
* x86-64 ld: Add '-z mark-plt/-z nomark-plt' to mark PLT entries with
|
||||
dynamic tags.
|
||||
* risc-v ld: Add '--[no-]check-uleb128'.
|
||||
* New linker script directive: REVERSE, to be combined with SORT_BY_NAME
|
||||
or SORT_BY_INIT_PRIORITY, reverses the generated order.
|
||||
* New linker options --warn-execstack-objects (warn only about execstack
|
||||
when input object files request it), and --error-execstack plus
|
||||
--error-rxw-segments to convert the existing warnings into errors.
|
||||
* objdump: Add -Z/--decompress to be used with -s/--full-contents to
|
||||
decompress section contents before displaying.
|
||||
* readelf: Add --extra-sym-info to be used with --symbols (currently
|
||||
prints section name of references section index).
|
||||
* objcopy: Add --set-section-flags for x86_64 to include
|
||||
SHF_X86_64_LARGE.
|
||||
* s390 disassembly: add target-specific disasm option 'insndesc',
|
||||
as in "objdump -M insndesc" to display an instruction description
|
||||
as comment along with the disassembly.
|
||||
- Add binutils-2.42-branch.diff.gz.
|
||||
- Rebased s390-biarch.diff.
|
||||
- Adjusted binutils-revert-hlasm-insns.diff,
|
||||
binutils-revert-plt32-in-branches.diff and binutils-revert-rela.diff
|
||||
for upstream changes.
|
||||
- Removed binutils-2.41-branch.diff.gz, binutils-2.41.tar.bz2,
|
||||
binutils-2.41-branch.diff.gz.
|
||||
- Removed binutils-use-less-memory.diff, binutils-old-makeinfo.diff
|
||||
and riscv-relro.patch (all upstreamed).
|
||||
- Removed add-ulp-section.diff, we use a different mechanism
|
||||
for live patching since a long time.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Nov 9 16:51:13 UTC 2023 - Michael Matz <matz@suse.com>
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package binutils
|
||||
#
|
||||
# Copyright (c) 2023 SUSE LLC
|
||||
# Copyright (c) 2024 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -64,7 +64,7 @@ BuildRequires: zlib-devel
|
||||
%if %{suse_version} > 1500
|
||||
BuildRequires: libzstd-devel
|
||||
%endif
|
||||
Version: 2.41
|
||||
Version: 2.42
|
||||
Release: 0
|
||||
|
||||
# disable libalternatives for now until it's changed to not
|
||||
@ -131,7 +131,7 @@ Source: binutils-%{version}.tar.bz2
|
||||
Source2: binutils-%{version}.tar.bz2.sig
|
||||
Source3: binutils.keyring
|
||||
Source4: baselibs.conf
|
||||
Patch1: binutils-2.41-branch.diff.gz
|
||||
Patch1: binutils-2.42-branch.diff.gz
|
||||
Patch3: binutils-skip-rpaths.patch
|
||||
Patch4: s390-biarch.diff
|
||||
Patch5: x86-64-biarch.patch
|
||||
@ -144,7 +144,6 @@ Patch14: binutils-build-as-needed.diff
|
||||
Patch15: binutils-znow.patch
|
||||
Patch22: binutils-bfd_h.patch
|
||||
Patch34: aarch64-common-pagesize.patch
|
||||
Patch36: binutils-pr22868.diff
|
||||
Patch37: binutils-revert-plt32-in-branches.diff
|
||||
Patch38: binutils-fix-invalid-op-errata.diff
|
||||
Patch39: binutils-revert-nm-symversion.diff
|
||||
@ -153,10 +152,8 @@ Patch41: binutils-fix-relax.diff
|
||||
Patch42: binutils-compat-old-behaviour.diff
|
||||
Patch43: binutils-revert-hlasm-insns.diff
|
||||
Patch44: binutils-revert-rela.diff
|
||||
Patch45: binutils-old-makeinfo.diff
|
||||
Patch46: riscv-relro.patch
|
||||
Patch47: binutils-use-less-memory.diff
|
||||
Patch100: add-ulp-section.diff
|
||||
Patch60: binutils-disable-code-arch-error.diff
|
||||
Patch61: riscv-no-relax.patch
|
||||
Patch90: cross-avr-nesc-as.patch
|
||||
Patch92: cross-avr-omit_section_dynsym.patch
|
||||
Patch93: cross-avr-size.patch
|
||||
@ -255,44 +252,39 @@ cp ld/ldgram.y ld/ldgram.y.orig
|
||||
|
||||
# Patch is outside test_vanilla because it's supposed to be the
|
||||
# patch bringing the tarball to the newest upstream version
|
||||
%patch1 -p1
|
||||
%patch -P 1 -p1
|
||||
%if !%{test_vanilla}
|
||||
%patch3 -p1
|
||||
%patch4
|
||||
%patch5
|
||||
%patch6
|
||||
%patch8
|
||||
%patch9
|
||||
%patch10
|
||||
%patch12
|
||||
%patch14
|
||||
%patch15
|
||||
%patch22
|
||||
%patch34 -p1
|
||||
%patch36 -p1
|
||||
%patch -P 3 -p1
|
||||
%patch -P 4
|
||||
%patch -P 5
|
||||
%patch -P 6
|
||||
%patch -P 8
|
||||
%patch -P 9
|
||||
%patch -P 10
|
||||
%patch -P 12
|
||||
%patch -P 14
|
||||
%patch -P 15
|
||||
%patch -P 22
|
||||
%patch -P 34 -p1
|
||||
%if %{suse_version} < 1550
|
||||
%patch37 -p1
|
||||
%patch -P 37 -p1
|
||||
%endif
|
||||
%patch38
|
||||
%patch39 -p1
|
||||
%patch40 -p1
|
||||
%patch41 -p1
|
||||
%patch -P 38
|
||||
%patch -P 39 -p1
|
||||
%patch -P 40 -p1
|
||||
%patch -P 41 -p1
|
||||
%if %{suse_version} < 1550
|
||||
%patch42 -p1
|
||||
%patch43 -p1
|
||||
%patch44 -p1
|
||||
%patch -P 42 -p1
|
||||
%patch -P 43 -p1
|
||||
%patch -P 44 -p1
|
||||
%endif
|
||||
%if %{suse_version} < 1500
|
||||
%patch45 -p1
|
||||
%endif
|
||||
%patch46 -p1
|
||||
%patch47 -p1
|
||||
%patch100 -p1
|
||||
%patch -P 60 -p1
|
||||
%patch -P 61 -p1
|
||||
%if "%{TARGET}" == "avr"
|
||||
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
|
||||
%patch90
|
||||
%patch92
|
||||
%patch93 -p1
|
||||
%patch -P 90
|
||||
%patch -P 92
|
||||
%patch -P 93 -p1
|
||||
%endif
|
||||
#
|
||||
# test_vanilla
|
||||
@ -369,6 +361,7 @@ cd build-dir
|
||||
--enable-threads \
|
||||
%endif
|
||||
%if %{suse_version} <= 1320
|
||||
CXX="g++ -std=gnu++11" \
|
||||
--disable-x86-relax-relocations \
|
||||
--disable-compressed-debug-sections \
|
||||
%endif
|
||||
@ -385,7 +378,7 @@ cd build-dir
|
||||
%endif
|
||||
--enable-shared \
|
||||
%if %{suse_version} > 1500
|
||||
%if %{with bootstrap}
|
||||
%if %{with bootstrap} && 0%{?do_profiling}
|
||||
--enable-pgo-build=lto \
|
||||
%endif
|
||||
--enable-colored-disassembly \
|
||||
@ -499,11 +492,17 @@ make -C gas-nesc %{?make_output_sync} %{?_smp_mflags}
|
||||
|
||||
%check
|
||||
unset SUSE_ASNEEDED
|
||||
# newer distros set this envvar (e.g. to get deterministic archives by default)
|
||||
# but of course that breaks tests that precisely are
|
||||
# designed for checking file replacement in archives based on mtime.
|
||||
# just get rid of it for the binutils testsuite
|
||||
unset SOURCE_DATE_EPOCH
|
||||
cd build-dir
|
||||
%if 0%{?cross:1}
|
||||
make -k check CFLAGS="-O2 -g" CXXFLAGS="-O2 -g" CFLAGS_FOR_TARGET="-O2 -g" CXXFLAGS_FOR_TARGET="-O2 -g" || %{make_check_handling}
|
||||
%else
|
||||
make -k check CFLAGS="-g $RPM_OPT_FLAGS" CXXFLAGS="-g $RPM_OPT_FLAGS" CFLAGS_FOR_TARGET="-g $RPM_OPT_FLAGS" CXXFLAGS_FOR_TARGET="-g $RPM_OPT_FLAGS" || %{make_check_handling}
|
||||
# _FORTIFY_SOURCE does not work with -O0
|
||||
make -k check CFLAGS="-g $RPM_OPT_FLAGS -U_FORTIFY_SOURCE" CXXFLAGS="-g $RPM_OPT_FLAGS -U_FORTIFY_SOURCE" CFLAGS_FOR_TARGET="-g $RPM_OPT_FLAGS -U_FORTIFY_SOURCE" CXXFLAGS_FOR_TARGET="-g $RPM_OPT_FLAGS -U_FORTIFY_SOURCE" || %{make_check_handling}
|
||||
%endif
|
||||
|
||||
%install
|
||||
@ -543,6 +542,7 @@ rm -rf %{buildroot}%{_prefix}/%{HOST}/bin
|
||||
mkdir -p %{buildroot}%{_prefix}/%{HOST}/bin
|
||||
ln -sf ../../bin/{ar,as,ld,nm,ranlib,strip} %{buildroot}%{_prefix}/%{HOST}/bin
|
||||
mv %{buildroot}%{_prefix}/%{HOST}/lib/ldscripts $RPM_BUILD_ROOT%{_libdir}
|
||||
rm -f $RPM_BUILD_ROOT%{_libdir}/ldscripts/stamp
|
||||
ln -sf ../../%{_lib}/ldscripts %{buildroot}%{_prefix}/%{HOST}/lib/ldscripts
|
||||
# Install header files
|
||||
make -C libiberty install_to_libdir target_header_dir=/usr/include DESTDIR=%{buildroot}
|
||||
|
64
riscv-no-relax.patch
Normal file
64
riscv-no-relax.patch
Normal file
@ -0,0 +1,64 @@
|
||||
From af514e5f6d1d0233a251a3ae17f7cb8d9ba8e36b Mon Sep 17 00:00:00 2001
|
||||
From: Nelson Chu <nelson@rivosinc.com>
|
||||
Date: Mon, 29 Jan 2024 21:17:41 +0800
|
||||
Subject: [PATCH] RISC-V: Don't generate branch/jump relocation if symbol is
|
||||
local when no-relax.
|
||||
|
||||
Refer to commit, dff565fcca8137954d6ad571ef39f6aec5c0429c. Theoretically,
|
||||
assembler don't need to generate the pc-relative relocation and the refered
|
||||
local .L symbol when relaxation is disabled. The above commit improved the
|
||||
pcrel_hi/pcrel_lo relocations, and this commit improves branch and jump
|
||||
relocations.
|
||||
|
||||
Passed the gcc/binutils regressions of riscv-gnu-toolchain.
|
||||
|
||||
gas/
|
||||
* config/tc-riscv.c (md_apply_fix): Raise fixP->fx_done for all
|
||||
branch and jump relocations when -mno-relax.
|
||||
---
|
||||
gas/config/tc-riscv.c | 8 ++++++++
|
||||
1 file changed, 8 insertions(+)
|
||||
|
||||
diff --git a/gas/config/tc-riscv.c b/gas/config/tc-riscv.c
|
||||
index a4161420128..cbead954f09 100644
|
||||
--- a/gas/config/tc-riscv.c
|
||||
+++ b/gas/config/tc-riscv.c
|
||||
@@ -4390,6 +4390,8 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
|
||||
bfd_vma target = S_GET_VALUE (fixP->fx_addsy) + *valP;
|
||||
bfd_vma delta = target - md_pcrel_from (fixP);
|
||||
bfd_putl32 (bfd_getl32 (buf) | ENCODE_JTYPE_IMM (delta), buf);
|
||||
+ if (!riscv_opts.relax && S_IS_LOCAL (fixP->fx_addsy))
|
||||
+ fixP->fx_done = 1;
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -4400,6 +4402,8 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
|
||||
bfd_vma target = S_GET_VALUE (fixP->fx_addsy) + *valP;
|
||||
bfd_vma delta = target - md_pcrel_from (fixP);
|
||||
bfd_putl32 (bfd_getl32 (buf) | ENCODE_BTYPE_IMM (delta), buf);
|
||||
+ if (!riscv_opts.relax && S_IS_LOCAL (fixP->fx_addsy))
|
||||
+ fixP->fx_done = 1;
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -4410,6 +4414,8 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
|
||||
bfd_vma target = S_GET_VALUE (fixP->fx_addsy) + *valP;
|
||||
bfd_vma delta = target - md_pcrel_from (fixP);
|
||||
bfd_putl16 (bfd_getl16 (buf) | ENCODE_CBTYPE_IMM (delta), buf);
|
||||
+ if (!riscv_opts.relax && S_IS_LOCAL (fixP->fx_addsy))
|
||||
+ fixP->fx_done = 1;
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -4420,6 +4426,8 @@ md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
|
||||
bfd_vma target = S_GET_VALUE (fixP->fx_addsy) + *valP;
|
||||
bfd_vma delta = target - md_pcrel_from (fixP);
|
||||
bfd_putl16 (bfd_getl16 (buf) | ENCODE_CJTYPE_IMM (delta), buf);
|
||||
+ if (!riscv_opts.relax && S_IS_LOCAL (fixP->fx_addsy))
|
||||
+ fixP->fx_done = 1;
|
||||
}
|
||||
break;
|
||||
|
||||
--
|
||||
2.43.2
|
||||
|
@ -1,57 +0,0 @@
|
||||
From 7345d05aafde53a48d5a587a6d9c1778db78e0f3 Mon Sep 17 00:00:00 2001
|
||||
From: Andreas Schwab <schwab@suse.de>
|
||||
Date: Thu, 21 Sep 2023 16:49:41 +0200
|
||||
Subject: [PATCH] RISC-V: Protect .got with relro
|
||||
|
||||
Move .got before .data so that it can be protected with -zrelro. Also
|
||||
separate .got.plt from .got if -znow is not in effect; the first two words
|
||||
of .got.plt are placed within the relro region.
|
||||
|
||||
ld:
|
||||
PR ld/30877
|
||||
* emulparams/elf32lriscv-defs.sh (DATA_GOT, SEPARATE_GOTPLT):
|
||||
Define.
|
||||
* emulparams/elf64lriscv-defs.sh (SEPARATE_GOTPLT): Define.
|
||||
* testsuite/ld-elf/binutils.exp (binutils_test): Remove riscv*-*-*
|
||||
from relro_got expression.
|
||||
---
|
||||
ld/emulparams/elf32lriscv-defs.sh | 4 ++++
|
||||
ld/emulparams/elf64lriscv-defs.sh | 1 +
|
||||
ld/testsuite/ld-elf/binutils.exp | 1 -
|
||||
3 files changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/ld/emulparams/elf32lriscv-defs.sh b/ld/emulparams/elf32lriscv-defs.sh
|
||||
index b823cedacab..016556168c3 100644
|
||||
--- a/ld/emulparams/elf32lriscv-defs.sh
|
||||
+++ b/ld/emulparams/elf32lriscv-defs.sh
|
||||
@@ -47,3 +47,7 @@ INITIAL_READONLY_SECTIONS="${RELOCATING+${CREATE_SHLIB-${INITIAL_READONLY_SECTIO
|
||||
OTHER_END_SYMBOLS="${CREATE_SHLIB-__BSS_END__ = .;
|
||||
__global_pointer$ = MIN(__SDATA_BEGIN__ + 0x800,
|
||||
MAX(__DATA_BEGIN__ + 0x800, __BSS_END__ - 0x800));}"
|
||||
+
|
||||
+# Put .got before .data
|
||||
+DATA_GOT=" "
|
||||
+SEPARATE_GOTPLT="SIZEOF (.got.plt) >= 8 ? 8 : 0"
|
||||
diff --git a/ld/emulparams/elf64lriscv-defs.sh b/ld/emulparams/elf64lriscv-defs.sh
|
||||
index 84a700a5f58..ca15338428f 100644
|
||||
--- a/ld/emulparams/elf64lriscv-defs.sh
|
||||
+++ b/ld/emulparams/elf64lriscv-defs.sh
|
||||
@@ -1,2 +1,3 @@
|
||||
source_sh ${srcdir}/emulparams/elf32lriscv-defs.sh
|
||||
ELFSIZE=64
|
||||
+SEPARATE_GOTPLT="SIZEOF (.got.plt) >= 16 ? 16 : 0"
|
||||
diff --git a/ld/testsuite/ld-elf/binutils.exp b/ld/testsuite/ld-elf/binutils.exp
|
||||
index 674e8e9a575..b38e29ed6fb 100644
|
||||
--- a/ld/testsuite/ld-elf/binutils.exp
|
||||
+++ b/ld/testsuite/ld-elf/binutils.exp
|
||||
@@ -95,7 +95,6 @@ proc binutils_test { prog_name ld_options test {test_name ""} {readelf_options "
|
||||
|| [istarget "mips*-*-*"] \
|
||||
|| [istarget "nios2*-*-*"] \
|
||||
|| [istarget "or1k-*-*"] \
|
||||
- || [istarget "riscv*-*-*"] \
|
||||
|| [istarget "sh*-*-*"] \
|
||||
|| [istarget "x86_64-*-rdos*"])]
|
||||
# Check if GNU_RELRO segment is generated.
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,11 +1,11 @@
|
||||
Index: ld/emulparams/elf_s390.sh
|
||||
===================================================================
|
||||
--- ld/emulparams/elf_s390.sh.orig 2019-09-09 18:48:59.000000000 +0200
|
||||
+++ ld/emulparams/elf_s390.sh 2019-09-09 18:49:02.000000000 +0200
|
||||
@@ -12,3 +12,18 @@ GENERATE_SHLIB_SCRIPT=yes
|
||||
GENERATE_PIE_SCRIPT=yes
|
||||
--- ld/emulparams/elf_s390.sh.orig 2024-01-29 01:00:00.000000000 +0100
|
||||
+++ ld/emulparams/elf_s390.sh 2024-01-30 14:45:36.996853073 +0100
|
||||
@@ -13,3 +13,18 @@ GENERATE_PIE_SCRIPT=yes
|
||||
NO_SMALL_DATA=yes
|
||||
IREL_IN_PLT=
|
||||
SYMBOL_ABI_ALIGNMENT=2
|
||||
+
|
||||
+# Treat a host that matches the target with the possible exception of "x"
|
||||
+# in the name as if it were native.
|
||||
|
Loading…
Reference in New Issue
Block a user