[gcc-6] 340/401: * Reapply the fix for PR target/55947, and fix PR c++/72813, taken from the trunk.

Ximin Luo infinity0 at debian.org
Wed Apr 5 15:50:35 UTC 2017


This is an automated email from the git hooks/post-receive script.

infinity0 pushed a commit to branch pu/reproducible_builds
in repository gcc-6.

commit 9886d8a116406d9efd7ffed874b6eb32f531b956
Author: doko <doko at 6ca36cf4-e1d1-0310-8c6f-e303bb2178ca>
Date:   Thu Jan 12 12:01:17 2017 +0000

      * Reapply the fix for PR target/55947, and fix PR c++/72813, taken from
        the trunk.
    
    
    git-svn-id: svn://anonscm.debian.org/gcccvs/branches/sid/gcc-6@9220 6ca36cf4-e1d1-0310-8c6f-e303bb2178ca
---
 debian/changelog                   |   2 +
 debian/patches/PR55947-revert.diff | 348 -------------------------------------
 debian/patches/pr72813.diff        |  60 +++++++
 debian/rules.patch                 |   2 +-
 4 files changed, 63 insertions(+), 349 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 0ea8277..1baf723 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -8,6 +8,8 @@ gcc-6 (6.3.0-3) UNRELEASED; urgency=medium
   * Always configure sparc builds --with-cpu-32=ultrasparc (James Clark).
     Closes: #850250.
   * Enable gccgo on m68k (John Paul Adrian Glaubitz). Closes: #850749.
+  * Reapply the fix for PR target/55947, and fix PR c++/72813, taken from
+    the trunk.
 
  -- Matthias Klose <doko at debian.org>  Mon, 09 Jan 2017 13:38:04 +0100
 
diff --git a/debian/patches/PR55947-revert.diff b/debian/patches/PR55947-revert.diff
deleted file mode 100644
index a4861a7..0000000
--- a/debian/patches/PR55947-revert.diff
+++ /dev/null
@@ -1,348 +0,0 @@
-# DP: Revert fix for PR target/55947, causing PR libstdc++/72813
-
-libstdc++-v3/
-
-2013-05-08  Andi Kleen  <ak at linux.intel.com>
-
-	PR target/55947
-	* libstdc++-v3/include/bits/atomic_base.h
-	(_GLIBCXX_ALWAYS_INLINE): Add new macro.
-	(atomic_thread_fence, atomic_signal_fence, test_and_set,
-	clear, store, load, exchange, compare_exchange_weak)
-	compare_exchange_strong, fetch_add, fetch_sub, fetch_and,
-	fetch_or, fetch_xor): Mark _GLIBCXX_ALWAYS_INLINE.
-
---- a/src/libstdc++-v3/include/bits/atomic_base.h	(revision 198733)
-+++ b/src/libstdc++-v3/include/bits/atomic_base.h	(revision 198731)
-@@ -97,11 +97,11 @@
-       | (__m & __memory_order_modifier_mask));
-   }
- 
--  _GLIBCXX_ALWAYS_INLINE void
-+  inline void
-   atomic_thread_fence(memory_order __m) noexcept
-   { __atomic_thread_fence(__m); }
- 
--  _GLIBCXX_ALWAYS_INLINE void
-+  inline void
-   atomic_signal_fence(memory_order __m) noexcept
-   { __atomic_signal_fence(__m); }
- 
-@@ -170,19 +170,19 @@
-       : __atomic_flag_base{ _S_init(__i) }
-     { }
- 
--    _GLIBCXX_ALWAYS_INLINE bool
-+    bool
-     test_and_set(memory_order __m = memory_order_seq_cst) noexcept
-     {
-       return __atomic_test_and_set (&_M_i, __m);
-     }
- 
--    _GLIBCXX_ALWAYS_INLINE bool
-+    bool
-     test_and_set(memory_order __m = memory_order_seq_cst) volatile noexcept
-     {
-       return __atomic_test_and_set (&_M_i, __m);
-     }
- 
--    _GLIBCXX_ALWAYS_INLINE void
-+    void
-     clear(memory_order __m = memory_order_seq_cst) noexcept
-     {
-       memory_order __b = __m & __memory_order_mask;
-@@ -193,7 +193,7 @@
-       __atomic_clear (&_M_i, __m);
-     }
- 
--    _GLIBCXX_ALWAYS_INLINE void
-+    void
-     clear(memory_order __m = memory_order_seq_cst) volatile noexcept
-     {
-       memory_order __b = __m & __memory_order_mask;
-@@ -363,7 +363,7 @@
- 	    reinterpret_cast<void *>(-__alignof(_M_i)));
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE void
-+      void
-       store(__int_type __i, memory_order __m = memory_order_seq_cst) noexcept
-       {
-         memory_order __b = __m & __memory_order_mask;
-@@ -374,7 +374,7 @@
- 	__atomic_store_n(&_M_i, __i, __m);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE void
-+      void
-       store(__int_type __i,
- 	    memory_order __m = memory_order_seq_cst) volatile noexcept
-       {
-@@ -386,7 +386,7 @@
- 	__atomic_store_n(&_M_i, __i, __m);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       load(memory_order __m = memory_order_seq_cst) const noexcept
-       {
-        memory_order __b = __m & __memory_order_mask;
-@@ -396,7 +396,7 @@
- 	return __atomic_load_n(&_M_i, __m);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       load(memory_order __m = memory_order_seq_cst) const volatile noexcept
-       {
-         memory_order __b = __m & __memory_order_mask;
-@@ -406,7 +406,7 @@
- 	return __atomic_load_n(&_M_i, __m);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       exchange(__int_type __i,
- 	       memory_order __m = memory_order_seq_cst) noexcept
-       {
-@@ -414,14 +414,14 @@
-       }
- 
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       exchange(__int_type __i,
- 	       memory_order __m = memory_order_seq_cst) volatile noexcept
-       {
- 	return __atomic_exchange_n(&_M_i, __i, __m);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE bool
-+      bool
-       compare_exchange_weak(__int_type& __i1, __int_type __i2,
- 			    memory_order __m1, memory_order __m2) noexcept
-       {
-@@ -434,7 +434,7 @@
- 	return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 1, __m1, __m2);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE bool
-+      bool
-       compare_exchange_weak(__int_type& __i1, __int_type __i2,
- 			    memory_order __m1,
- 			    memory_order __m2) volatile noexcept
-@@ -448,7 +448,7 @@
- 	return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 1, __m1, __m2);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE bool
-+      bool
-       compare_exchange_weak(__int_type& __i1, __int_type __i2,
- 			    memory_order __m = memory_order_seq_cst) noexcept
-       {
-@@ -456,7 +456,7 @@
- 				     __cmpexch_failure_order(__m));
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE bool
-+      bool
-       compare_exchange_weak(__int_type& __i1, __int_type __i2,
- 		   memory_order __m = memory_order_seq_cst) volatile noexcept
-       {
-@@ -464,7 +464,7 @@
- 				     __cmpexch_failure_order(__m));
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE bool
-+      bool
-       compare_exchange_strong(__int_type& __i1, __int_type __i2,
- 			      memory_order __m1, memory_order __m2) noexcept
-       {
-@@ -477,7 +477,7 @@
- 	return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 0, __m1, __m2);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE bool
-+      bool
-       compare_exchange_strong(__int_type& __i1, __int_type __i2,
- 			      memory_order __m1,
- 			      memory_order __m2) volatile noexcept
-@@ -492,7 +492,7 @@
- 	return __atomic_compare_exchange_n(&_M_i, &__i1, __i2, 0, __m1, __m2);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE bool
-+      bool
-       compare_exchange_strong(__int_type& __i1, __int_type __i2,
- 			      memory_order __m = memory_order_seq_cst) noexcept
-       {
-@@ -500,7 +500,7 @@
- 				       __cmpexch_failure_order(__m));
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE bool
-+      bool
-       compare_exchange_strong(__int_type& __i1, __int_type __i2,
- 		 memory_order __m = memory_order_seq_cst) volatile noexcept
-       {
-@@ -508,52 +508,52 @@
- 				       __cmpexch_failure_order(__m));
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       fetch_add(__int_type __i,
- 		memory_order __m = memory_order_seq_cst) noexcept
-       { return __atomic_fetch_add(&_M_i, __i, __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       fetch_add(__int_type __i,
- 		memory_order __m = memory_order_seq_cst) volatile noexcept
-       { return __atomic_fetch_add(&_M_i, __i, __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       fetch_sub(__int_type __i,
- 		memory_order __m = memory_order_seq_cst) noexcept
-       { return __atomic_fetch_sub(&_M_i, __i, __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       fetch_sub(__int_type __i,
- 		memory_order __m = memory_order_seq_cst) volatile noexcept
-       { return __atomic_fetch_sub(&_M_i, __i, __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       fetch_and(__int_type __i,
- 		memory_order __m = memory_order_seq_cst) noexcept
-       { return __atomic_fetch_and(&_M_i, __i, __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       fetch_and(__int_type __i,
- 		memory_order __m = memory_order_seq_cst) volatile noexcept
-       { return __atomic_fetch_and(&_M_i, __i, __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       fetch_or(__int_type __i,
- 	       memory_order __m = memory_order_seq_cst) noexcept
-       { return __atomic_fetch_or(&_M_i, __i, __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       fetch_or(__int_type __i,
- 	       memory_order __m = memory_order_seq_cst) volatile noexcept
-       { return __atomic_fetch_or(&_M_i, __i, __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       fetch_xor(__int_type __i,
- 		memory_order __m = memory_order_seq_cst) noexcept
-       { return __atomic_fetch_xor(&_M_i, __i, __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __int_type
-+      __int_type
-       fetch_xor(__int_type __i,
- 		memory_order __m = memory_order_seq_cst) volatile noexcept
-       { return __atomic_fetch_xor(&_M_i, __i, __m); }
-@@ -678,7 +678,7 @@
- 	    reinterpret_cast<void *>(-__alignof(_M_p)));
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE void
-+      void
-       store(__pointer_type __p,
- 	    memory_order __m = memory_order_seq_cst) noexcept
-       {
-@@ -691,7 +691,7 @@
- 	__atomic_store_n(&_M_p, __p, __m);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE void
-+      void
-       store(__pointer_type __p,
- 	    memory_order __m = memory_order_seq_cst) volatile noexcept
-       {
-@@ -703,7 +703,7 @@
- 	__atomic_store_n(&_M_p, __p, __m);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE __pointer_type
-+      __pointer_type
-       load(memory_order __m = memory_order_seq_cst) const noexcept
-       {
-         memory_order __b = __m & __memory_order_mask;
-@@ -713,7 +713,7 @@
- 	return __atomic_load_n(&_M_p, __m);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE __pointer_type
-+      __pointer_type
-       load(memory_order __m = memory_order_seq_cst) const volatile noexcept
-       {
-         memory_order __b = __m & __memory_order_mask;
-@@ -723,7 +723,7 @@
- 	return __atomic_load_n(&_M_p, __m);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE __pointer_type
-+      __pointer_type
-       exchange(__pointer_type __p,
- 	       memory_order __m = memory_order_seq_cst) noexcept
-       {
-@@ -731,14 +731,14 @@
-       }
- 
- 
--      _GLIBCXX_ALWAYS_INLINE __pointer_type
-+      __pointer_type
-       exchange(__pointer_type __p,
- 	       memory_order __m = memory_order_seq_cst) volatile noexcept
-       {
- 	return __atomic_exchange_n(&_M_p, __p, __m);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE bool
-+      bool
-       compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
- 			      memory_order __m1,
- 			      memory_order __m2) noexcept
-@@ -752,7 +752,7 @@
- 	return __atomic_compare_exchange_n(&_M_p, &__p1, __p2, 0, __m1, __m2);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE bool
-+      bool
-       compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
- 			      memory_order __m1,
- 			      memory_order __m2) volatile noexcept
-@@ -767,22 +767,22 @@
- 	return __atomic_compare_exchange_n(&_M_p, &__p1, __p2, 0, __m1, __m2);
-       }
- 
--      _GLIBCXX_ALWAYS_INLINE __pointer_type
-+      __pointer_type
-       fetch_add(ptrdiff_t __d,
- 		memory_order __m = memory_order_seq_cst) noexcept
-       { return __atomic_fetch_add(&_M_p, _M_type_size(__d), __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __pointer_type
-+      __pointer_type
-       fetch_add(ptrdiff_t __d,
- 		memory_order __m = memory_order_seq_cst) volatile noexcept
-       { return __atomic_fetch_add(&_M_p, _M_type_size(__d), __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __pointer_type
-+      __pointer_type
-       fetch_sub(ptrdiff_t __d,
- 		memory_order __m = memory_order_seq_cst) noexcept
-       { return __atomic_fetch_sub(&_M_p, _M_type_size(__d), __m); }
- 
--      _GLIBCXX_ALWAYS_INLINE __pointer_type
-+      __pointer_type
-       fetch_sub(ptrdiff_t __d,
- 		memory_order __m = memory_order_seq_cst) volatile noexcept
-       { return __atomic_fetch_sub(&_M_p, _M_type_size(__d), __m); }
diff --git a/debian/patches/pr72813.diff b/debian/patches/pr72813.diff
new file mode 100644
index 0000000..5549f6a
--- /dev/null
+++ b/debian/patches/pr72813.diff
@@ -0,0 +1,60 @@
+# DP: Fix PR c++/72813, taken from the trunk.
+
+gcc/c/
+
+2017-01-11  Jakub Jelinek  <jakub at redhat.com>
+
+	PR c++/72813
+	* c-decl.c (pop_file_scope): Set flag_syntax_only to 1 after writing
+	PCH file.
+
+gcc/
+
+2017-01-11  Jakub Jelinek  <jakub at redhat.com>
+
+	PR c++/72813
+	* gcc.c (default_compilers): Don't add -o %g.s for -S -save-temps
+	of c-header.
+
+gcc/cp/
+
+2017-01-11  Jakub Jelinek  <jakub at redhat.com>
+
+	PR c++/72813
+	* decl2.c (c_parse_final_cleanups): Set flag_syntax_only to 1 after
+	writing PCH file.
+
+ 
+--- a/src/gcc/c/c-decl.c
++++ b/src/gcc/c/c-decl.c
+@@ -1420,6 +1420,8 @@
+   if (pch_file)
+     {
+       c_common_write_pch ();
++      /* Ensure even the callers don't try to finalize the CU.  */
++      flag_syntax_only = 1;
+       return;
+     }
+ 
+--- a/src/gcc/gcc.c
++++ b/src/gcc/gcc.c
+@@ -1328,7 +1328,7 @@
+ 		%(cpp_options) -o %{save-temps*:%b.i} %{!save-temps*:%g.i} \n\
+ 		    cc1 -fpreprocessed %{save-temps*:%b.i} %{!save-temps*:%g.i} \
+ 			%(cc1_options)\
+-			%{!fsyntax-only:-o %g.s \
++			%{!fsyntax-only:%{!S:-o %g.s} \
+ 			    %{!fdump-ada-spec*:%{!o*:--output-pch=%i.gch}\
+ 					       %W{o*:--output-pch=%*}}%V}}\
+ 	  %{!save-temps*:%{!traditional-cpp:%{!no-integrated-cpp:\
+--- a/src/gcc/cp/decl2.c
++++ b/src/gcc/cp/decl2.c
+@@ -4461,6 +4461,8 @@
+ 	  DECL_ASSEMBLER_NAME (node->decl);
+       c_common_write_pch ();
+       dump_tu ();
++      /* Ensure even the callers don't try to finalize the CU.  */
++      flag_syntax_only = 1;
+       return;
+     }
+ 
diff --git a/debian/rules.patch b/debian/rules.patch
index b24a157..aca35ca 100644
--- a/debian/rules.patch
+++ b/debian/rules.patch
@@ -90,7 +90,6 @@ debian_patches += \
 	gcc-SOURCE_DATE_EPOCH-2 \
 	cmd-go-combine-gccgo-s-ld-and-ldShared-methods \
 	libjava-mips64el \
-	PR55947-revert \
 	gccgo-issue16780 \
 	$(if $(with_linaro_branch),,vulcan-cpu) \
 	$(if $(with_linaro_branch),,vulcan-costs) \
@@ -109,6 +108,7 @@ debian_patches += \
 	CVE-2016-9841 \
 	CVE-2016-9842 \
 	CVE-2016-9843 \
+	pr72813 \
 
 ifeq ($(libstdcxx_abi),new)
   debian_patches += libstdc++-functexcept

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/gcc-6.git



More information about the Reproducible-commits mailing list