12.0.1-0.12
This commit is contained in:
parent
ef299b80e9
commit
967fa9b141
10
gcc.spec
10
gcc.spec
@ -120,7 +120,7 @@
|
|||||||
Summary: Various compilers (C, C++, Objective-C, ...)
|
Summary: Various compilers (C, C++, Objective-C, ...)
|
||||||
Name: gcc
|
Name: gcc
|
||||||
Version: %{gcc_version}
|
Version: %{gcc_version}
|
||||||
Release: %{gcc_release}.11%{?dist}
|
Release: %{gcc_release}.12%{?dist}
|
||||||
# libgcc, libgfortran, libgomp, libstdc++ and crtstuff have
|
# libgcc, libgfortran, libgomp, libstdc++ and crtstuff have
|
||||||
# GCC Runtime Exception.
|
# GCC Runtime Exception.
|
||||||
License: GPLv3+ and GPLv3+ with exceptions and GPLv2+ with exceptions and LGPLv2+ and BSD
|
License: GPLv3+ and GPLv3+ with exceptions and GPLv2+ with exceptions and LGPLv2+ and BSD
|
||||||
@ -271,6 +271,8 @@ Patch9: gcc12-Wno-format-security.patch
|
|||||||
Patch10: gcc12-rh1574936.patch
|
Patch10: gcc12-rh1574936.patch
|
||||||
Patch11: gcc12-d-shared-libphobos.patch
|
Patch11: gcc12-d-shared-libphobos.patch
|
||||||
Patch12: gcc12-pr104781.patch
|
Patch12: gcc12-pr104781.patch
|
||||||
|
Patch13: gcc12-pr104777.patch
|
||||||
|
Patch14: gcc12-pr104839.patch
|
||||||
|
|
||||||
Patch100: gcc12-fortran-fdec-duplicates.patch
|
Patch100: gcc12-fortran-fdec-duplicates.patch
|
||||||
Patch101: gcc12-fortran-flogical-as-integer.patch
|
Patch101: gcc12-fortran-flogical-as-integer.patch
|
||||||
@ -793,6 +795,8 @@ to NVidia PTX capable devices if available.
|
|||||||
%endif
|
%endif
|
||||||
%patch11 -p0 -b .d-shared-libphobos~
|
%patch11 -p0 -b .d-shared-libphobos~
|
||||||
%patch12 -p0 -b .pr104781~
|
%patch12 -p0 -b .pr104781~
|
||||||
|
%patch13 -p0 -b .pr104777~
|
||||||
|
%patch14 -p0 -b .pr104839~
|
||||||
|
|
||||||
%if 0%{?rhel} >= 9
|
%if 0%{?rhel} >= 9
|
||||||
%patch100 -p1 -b .fortran-fdec-duplicates~
|
%patch100 -p1 -b .fortran-fdec-duplicates~
|
||||||
@ -3166,6 +3170,10 @@ end
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Mar 8 2022 Jakub Jelinek <jakub@redhat.com> 12.0.1-0.12
|
||||||
|
- fix up promoted SUBREG handling (#2045160, PR rtl-optimization/104839)
|
||||||
|
- fix up check for asm goto (PR rtl-optimization/104777)
|
||||||
|
|
||||||
* Tue Mar 8 2022 Jakub Jelinek <jakub@redhat.com> 12.0.1-0.11
|
* Tue Mar 8 2022 Jakub Jelinek <jakub@redhat.com> 12.0.1-0.11
|
||||||
- update from trunk
|
- update from trunk
|
||||||
- PRs analyzer/101983, fortran/99585, fortran/104430, libstdc++/104807,
|
- PRs analyzer/101983, fortran/99585, fortran/104430, libstdc++/104807,
|
||||||
|
61
gcc12-pr104777.patch
Normal file
61
gcc12-pr104777.patch
Normal file
@ -0,0 +1,61 @@
|
|||||||
|
2022-03-08 Marek Polacek <polacek@redhat.com>
|
||||||
|
|
||||||
|
PR rtl-optimization/104777
|
||||||
|
* rtl.cc (classify_insn): For ASM_OPERANDS, return JUMP_INSN only if
|
||||||
|
ASM_OPERANDS_LABEL_VEC has at least one element.
|
||||||
|
|
||||||
|
* gcc.dg/torture/tls/pr104777.c: New test.
|
||||||
|
|
||||||
|
--- gcc/rtl.cc
|
||||||
|
+++ gcc/rtl.cc
|
||||||
|
@@ -765,7 +765,7 @@ classify_insn (rtx x)
|
||||||
|
return CALL_INSN;
|
||||||
|
if (ANY_RETURN_P (x))
|
||||||
|
return JUMP_INSN;
|
||||||
|
- if (GET_CODE (x) == ASM_OPERANDS && ASM_OPERANDS_LABEL_VEC (x))
|
||||||
|
+ if (GET_CODE (x) == ASM_OPERANDS && ASM_OPERANDS_LABEL_LENGTH (x))
|
||||||
|
return JUMP_INSN;
|
||||||
|
if (GET_CODE (x) == SET)
|
||||||
|
{
|
||||||
|
@@ -794,7 +794,7 @@ classify_insn (rtx x)
|
||||||
|
if (has_return_p)
|
||||||
|
return JUMP_INSN;
|
||||||
|
if (GET_CODE (XVECEXP (x, 0, 0)) == ASM_OPERANDS
|
||||||
|
- && ASM_OPERANDS_LABEL_VEC (XVECEXP (x, 0, 0)))
|
||||||
|
+ && ASM_OPERANDS_LABEL_LENGTH (XVECEXP (x, 0, 0)))
|
||||||
|
return JUMP_INSN;
|
||||||
|
}
|
||||||
|
#ifdef GENERATOR_FILE
|
||||||
|
--- gcc/testsuite/gcc.dg/torture/tls/pr104777.c
|
||||||
|
+++ gcc/testsuite/gcc.dg/torture/tls/pr104777.c
|
||||||
|
@@ -0,0 +1,30 @@
|
||||||
|
+/* PR rtl-optimization/104777 */
|
||||||
|
+/* { dg-do compile } */
|
||||||
|
+/* { dg-require-effective-target tls } */
|
||||||
|
+
|
||||||
|
+int savestate_r;
|
||||||
|
+int savestate_ssb;
|
||||||
|
+extern void abort();
|
||||||
|
+__thread int loop;
|
||||||
|
+void f (void)
|
||||||
|
+{
|
||||||
|
+ int savestate_r0_5;
|
||||||
|
+ int savestate_r1_6;
|
||||||
|
+
|
||||||
|
+ __asm__("" : "=m" (savestate_ssb), "=r" (savestate_r));
|
||||||
|
+ savestate_r0_5 = savestate_r;
|
||||||
|
+ if (savestate_r0_5 == 0)
|
||||||
|
+ {
|
||||||
|
+ __asm__ __volatile__("" : : "m" (loop));
|
||||||
|
+ abort ();
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ __asm__("" : "=m" (savestate_ssb), "=r" (savestate_r));
|
||||||
|
+ savestate_r1_6 = savestate_r;
|
||||||
|
+ if (savestate_r1_6 != 0)
|
||||||
|
+ return;
|
||||||
|
+
|
||||||
|
+ __asm__ __volatile__("" : : "m" (loop));
|
||||||
|
+ abort ();
|
||||||
|
+
|
||||||
|
+}
|
70
gcc12-pr104839.patch
Normal file
70
gcc12-pr104839.patch
Normal file
@ -0,0 +1,70 @@
|
|||||||
|
2022-03-08 Jakub Jelinek <jakub@redhat.com>
|
||||||
|
|
||||||
|
PR rtl-optimization/104839
|
||||||
|
* simplify-rtx.cc (simplify_unary_operation_1) <case SIGN_EXTEND>:
|
||||||
|
Use SRP_SIGNED instead of incorrect 1 in SUBREG_PROMOTED_SET.
|
||||||
|
(simplify_unary_operation_1) <case ZERO_EXTEND>: Use SRP_UNSIGNED
|
||||||
|
instead of incorrect 0 in SUBREG_PROMOTED_SET.
|
||||||
|
|
||||||
|
* gcc.c-torture/execute/pr104839.c: New test.
|
||||||
|
|
||||||
|
--- gcc/simplify-rtx.cc.jj 2022-02-23 09:17:04.000000000 +0100
|
||||||
|
+++ gcc/simplify-rtx.cc 2022-03-08 16:31:20.823246404 +0100
|
||||||
|
@@ -1527,7 +1527,7 @@ simplify_context::simplify_unary_operati
|
||||||
|
if (partial_subreg_p (temp))
|
||||||
|
{
|
||||||
|
SUBREG_PROMOTED_VAR_P (temp) = 1;
|
||||||
|
- SUBREG_PROMOTED_SET (temp, 1);
|
||||||
|
+ SUBREG_PROMOTED_SET (temp, SRP_SIGNED);
|
||||||
|
}
|
||||||
|
return temp;
|
||||||
|
}
|
||||||
|
@@ -1662,7 +1662,7 @@ simplify_context::simplify_unary_operati
|
||||||
|
if (partial_subreg_p (temp))
|
||||||
|
{
|
||||||
|
SUBREG_PROMOTED_VAR_P (temp) = 1;
|
||||||
|
- SUBREG_PROMOTED_SET (temp, 0);
|
||||||
|
+ SUBREG_PROMOTED_SET (temp, SRP_UNSIGNED);
|
||||||
|
}
|
||||||
|
return temp;
|
||||||
|
}
|
||||||
|
--- gcc/testsuite/gcc.c-torture/execute/pr104839.c.jj 2022-03-08 16:46:51.418440078 +0100
|
||||||
|
+++ gcc/testsuite/gcc.c-torture/execute/pr104839.c 2022-03-08 16:46:27.044774203 +0100
|
||||||
|
@@ -0,0 +1,37 @@
|
||||||
|
+/* PR rtl-optimization/104839 */
|
||||||
|
+
|
||||||
|
+__attribute__((noipa)) short
|
||||||
|
+foo (void)
|
||||||
|
+{
|
||||||
|
+ return -1;
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+__attribute__((noipa)) int
|
||||||
|
+bar (void)
|
||||||
|
+{
|
||||||
|
+ short i = foo ();
|
||||||
|
+ if (i == -2)
|
||||||
|
+ return 2;
|
||||||
|
+ long k = i;
|
||||||
|
+ int j = -1;
|
||||||
|
+ volatile long s = 300;
|
||||||
|
+ if (k < 0)
|
||||||
|
+ {
|
||||||
|
+ k += s;
|
||||||
|
+ if (k < 0)
|
||||||
|
+ j = 0;
|
||||||
|
+ }
|
||||||
|
+ else if (k >= s)
|
||||||
|
+ j = 0;
|
||||||
|
+ if (j != -1)
|
||||||
|
+ return 1;
|
||||||
|
+ return 0;
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+int
|
||||||
|
+main ()
|
||||||
|
+{
|
||||||
|
+ if (bar () != 0)
|
||||||
|
+ __builtin_abort ();
|
||||||
|
+ return 0;
|
||||||
|
+}
|
Loading…
Reference in New Issue
Block a user