public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sergei Trofimovich" <slyfox@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/gcc-patches:master commit in: 10.1.0/gentoo/
Date: Tue, 14 Jul 2020 07:17:10 +0000 (UTC)	[thread overview]
Message-ID: <1594710742.6c5ced06c025ddc8b34d02c7597d0f0f0932393f.slyfox@gentoo> (raw)

commit:     6c5ced06c025ddc8b34d02c7597d0f0f0932393f
Author:     Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
AuthorDate: Tue Jul 14 07:12:22 2020 +0000
Commit:     Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
CommitDate: Tue Jul 14 07:12:22 2020 +0000
URL:        https://gitweb.gentoo.org/proj/gcc-patches.git/commit/?id=6c5ced06

10.1.0: use crtendS.o on sparc-linux-pie

This should fix TEXTREL warning when linking most binaries on sparc.

Bug: https://gcc.gnu.org/PR96190
Bug: https://bugs.gentoo.org/619706
Signed-off-by: Sergei Trofimovich <slyfox <AT> gentoo.org>

 10.1.0/gentoo/37_all_sparc_pie_TEXTREL.patch | 49 ++++++++++++++++++++++++++++
 10.1.0/gentoo/README.history                 |  3 ++
 2 files changed, 52 insertions(+)

diff --git a/10.1.0/gentoo/37_all_sparc_pie_TEXTREL.patch b/10.1.0/gentoo/37_all_sparc_pie_TEXTREL.patch
new file mode 100644
index 0000000..059f744
--- /dev/null
+++ b/10.1.0/gentoo/37_all_sparc_pie_TEXTREL.patch
@@ -0,0 +1,49 @@
+https://gcc.gnu.org/PR96190
+https://bugs.gentoo.org/619706
+
+From 6acaa3c1c1e6202af9871aa304ed772939d51311 Mon Sep 17 00:00:00 2001
+From: Sergei Trofimovich <siarheit@google.com>
+Date: Tue, 14 Jul 2020 07:48:42 +0100
+Subject: [PATCH] sparc/sparc64: use PIE_SPEC to select crtendS.o [PR96190]
+
+In --enable-default-pie mode compiler should switch from
+using crtend.o to crtendS.o. On sparc it is especially visible
+because crtend.o contains PIC-unfriendly code.
+
+gcc:
+
+2020-07-14  Sergei Trofimovich  <siarheit@google.com>
+
+	PR driver/96190
+	* config/sparc/linux.h: Use PIE_SPEC to select crtendS.o.
+	* config/sparc/linux64.h: ditto
+---
+ gcc/config/sparc/linux.h   | 2 +-
+ gcc/config/sparc/linux64.h | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+--- a/gcc/config/sparc/linux.h
++++ b/gcc/config/sparc/linux.h
+@@ -35,7 +35,7 @@ along with GCC; see the file COPYING3.  If not see
+ 
+ #undef  ENDFILE_SPEC
+ #define ENDFILE_SPEC \
+-  "%{shared|pie:crtendS.o%s;:crtend.o%s} crtn.o%s\
++  "%{shared|" PIE_SPEC ":crtendS.o%s;:crtend.o%s} crtn.o%s\
+    %{Ofast|ffast-math|funsafe-math-optimizations:crtfastmath.o%s}"
+ 
+ /* -mcpu=native handling only makes sense with compiler running on
+--- a/gcc/config/sparc/linux64.h
++++ b/gcc/config/sparc/linux64.h
+@@ -52,7 +52,7 @@ along with GCC; see the file COPYING3.  If not see
+ 
+ #undef	ENDFILE_SPEC
+ #define ENDFILE_SPEC \
+-  "%{shared|pie:crtendS.o%s;:crtend.o%s} crtn.o%s\
++  "%{shared|" PIE_SPEC ":crtendS.o%s;:crtend.o%s} crtn.o%s\
+    %{Ofast|ffast-math|funsafe-math-optimizations:crtfastmath.o%s}"
+ 
+ /* The default code model.  */
+-- 
+2.27.0
+

diff --git a/10.1.0/gentoo/README.history b/10.1.0/gentoo/README.history
index 6fab577..f081231 100644
--- a/10.1.0/gentoo/README.history
+++ b/10.1.0/gentoo/README.history
@@ -1,3 +1,6 @@
+4 		TODO
+	+ 37_all_sparc_pie_TEXTREL.patch
+
 3		04 July 2020
 	+ 33_all_avx512-scalar-PR95528.patch
 	+ 34_all_cet-cross-x86.patch


             reply	other threads:[~2020-07-14  7:17 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-14  7:17 Sergei Trofimovich [this message]
  -- strict thread matches above, loose matches on Subject: below --
2020-07-23  8:50 [gentoo-commits] proj/gcc-patches:master commit in: 10.1.0/gentoo/ Sergei Trofimovich
2020-07-19 21:35 Sergei Trofimovich
2020-07-04  7:56 Sergei Trofimovich
2020-07-04  7:56 Sergei Trofimovich
2020-07-03 22:12 Sergei Trofimovich
2020-06-24 20:15 Sergei Trofimovich
2020-06-23  6:34 Sergei Trofimovich
2020-06-14 11:07 Sergei Trofimovich
2020-06-11 23:00 Sergei Trofimovich
2020-06-11 22:49 Sergei Trofimovich
2020-06-05 21:02 Sergei Trofimovich
2020-05-19 22:02 Sergei Trofimovich
2020-05-14 17:58 Sergei Trofimovich
2020-05-07 20:51 Sergei Trofimovich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1594710742.6c5ced06c025ddc8b34d02c7597d0f0f0932393f.slyfox@gentoo \
    --to=slyfox@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox