commit: 7e2dec9de3d94ad18c2136f9ef8dbd48c1a5bdf4 Author: Sam James <sam <AT> gentoo <DOT> org> AuthorDate: Sat Jan 8 03:06:25 2022 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Sat Jan 8 03:06:50 2022 +0000 URL: https://gitweb.gentoo.org/proj/gcc-patches.git/commit/?id=7e2dec9d
11.3.0: add PR103910 backport (OpenJDK ICE with PCH) Bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103910 Bug: https://bugs.gentoo.org/822690 Signed-off-by: Sam James <sam <AT> gentoo.org> .../gentoo/76_all_all_PR103910_12_ICE-on-PCH.patch | 35 ++++++++++++++++++++++ 11.3.0/gentoo/README.history | 3 ++ 2 files changed, 38 insertions(+) diff --git a/11.3.0/gentoo/76_all_all_PR103910_12_ICE-on-PCH.patch b/11.3.0/gentoo/76_all_all_PR103910_12_ICE-on-PCH.patch new file mode 100644 index 0000000..358b9b3 --- /dev/null +++ b/11.3.0/gentoo/76_all_all_PR103910_12_ICE-on-PCH.patch @@ -0,0 +1,35 @@ +https://bugs.gentoo.org/822690 +https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103910 + +From d243f4009d8071b734df16cd70f4c5d09a373769 Mon Sep 17 00:00:00 2001 +From: Andrew Pinski <[email protected]> +Date: Wed, 5 Jan 2022 22:00:07 +0000 +Subject: [PATCH] Fix target/103910: missing GTY on x86_mfence causing PCH + usage to ICE + +With -O3 -march=opteron, a mfence builtin is added after the loop +to say the nontemporal stores are no longer needed. This all good +without precompiled headers as the function decl that is referneced +by x86_mfence is referenced in another variable but with precompiled +headers, x86_mfence is all messed up and the decl was GC'ed away. +This fixes the problem by marking x86_mfence as GTY to save/restore +during precompiled headers just like most other variables in +the header file. + +Committed as obvious after a bootstrap/test on x86_64-linux-gnu. + +gcc/ChangeLog: + + PR target/103910 + * config/i386/i386.h (x86_mfence): Mark with GTY. +--- a/gcc/config/i386/i386.h ++++ b/gcc/config/i386/i386.h +@@ -486,7 +486,7 @@ extern unsigned char ix86_prefetch_sse; + + /* Fence to use after loop using storent. */ + +-extern tree x86_mfence; ++extern GTY(()) tree x86_mfence; + #define FENCE_FOLLOWING_MOVNT x86_mfence + + /* Once GDB has been enhanced to deal with functions without frame diff --git a/11.3.0/gentoo/README.history b/11.3.0/gentoo/README.history index bd234ed..1faa3d6 100644 --- a/11.3.0/gentoo/README.history +++ b/11.3.0/gentoo/README.history @@ -1,3 +1,6 @@ +3 8 January 2022 + + 76_all_all_PR103910_12_ICE-on-PCH.patch + 2 7 December 2021 + 01_all_default-fortify-source.patch + 02_all_default-warn-format-security.patch
