public inbox for glibc-cvs@sourceware.org
help / color / mirror / Atom feed
* [glibc] aarch64: simplify the DT_AARCH64_VARIANT_PCS handling code
@ 2019-07-10 14:28 Szabolcs Nagy
  0 siblings, 0 replies; only message in thread
From: Szabolcs Nagy @ 2019-07-10 14:28 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=30ba0375464f34e4bf8129f3d3dc14d0c09add17

commit 30ba0375464f34e4bf8129f3d3dc14d0c09add17
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date:   Tue Jul 9 12:11:39 2019 +0100

    aarch64: simplify the DT_AARCH64_VARIANT_PCS handling code
    
    Remove unnecessary variant_pcs field: the dynamic tag can be checked
    directly.
    
    	* sysdeps/aarch64/dl-machine.h (elf_machine_runtime_setup): Remove the
    	DT_AARCH64_VARIANT_PCS check.
    	(elf_machine_lazy_rel): Use l_info[DT_AARCH64 (VARIANT_PCS)].
    	* sysdeps/aarch64/linkmap.h (struct link_map_machine): Remove
    	variant_pcs.

Diff:
---
 ChangeLog                    | 8 ++++++++
 sysdeps/aarch64/dl-machine.h | 6 +-----
 sysdeps/aarch64/linkmap.h    | 1 -
 3 files changed, 9 insertions(+), 6 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index d3c5e29..dd99d98 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2019-07-10  Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+	* sysdeps/aarch64/dl-machine.h (elf_machine_runtime_setup): Remove the
+	DT_AARCH64_VARIANT_PCS check.
+	(elf_machine_lazy_rel): Use l_info[DT_AARCH64 (VARIANT_PCS)].
+	* sysdeps/aarch64/linkmap.h (struct link_map_machine): Remove
+	variant_pcs.
+
 2019-07-10  Andreas Schwab  <schwab@suse.de>
 
 	[BZ #23352]
diff --git a/sysdeps/aarch64/dl-machine.h b/sysdeps/aarch64/dl-machine.h
index 4f27637..9b2e0ff 100644
--- a/sysdeps/aarch64/dl-machine.h
+++ b/sysdeps/aarch64/dl-machine.h
@@ -105,10 +105,6 @@ elf_machine_runtime_setup (struct link_map *l, int lazy, int profile)
 	}
     }
 
-  /* Check if STO_AARCH64_VARIANT_PCS needs to be handled.  */
-  if (l->l_info[DT_AARCH64 (VARIANT_PCS)])
-    l->l_mach.variant_pcs = 1;
-
   return lazy;
 }
 
@@ -402,7 +398,7 @@ elf_machine_lazy_rel (struct link_map *map,
 	  return;
 	}
 
-      if (__glibc_unlikely (map->l_mach.variant_pcs))
+      if (__glibc_unlikely (map->l_info[DT_AARCH64 (VARIANT_PCS)] != NULL))
 	{
 	  /* Check the symbol table for variant PCS symbols.  */
 	  const Elf_Symndx symndx = ELFW (R_SYM) (reloc->r_info);
diff --git a/sysdeps/aarch64/linkmap.h b/sysdeps/aarch64/linkmap.h
index 7f801b1..ba74fe1 100644
--- a/sysdeps/aarch64/linkmap.h
+++ b/sysdeps/aarch64/linkmap.h
@@ -20,5 +20,4 @@ struct link_map_machine
 {
   ElfW(Addr) plt;	  /* Address of .plt */
   void *tlsdesc_table;	  /* Address of TLS descriptor hash table.  */
-  int variant_pcs;	  /* If set, PLT calls may follow a variant PCS.  */
 };


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-07-10 14:28 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-10 14:28 [glibc] aarch64: simplify the DT_AARCH64_VARIANT_PCS handling code Szabolcs Nagy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).