!371 [Sync] Sync patches from openeuler/gcc.
From: @xiongzhou4 Reviewed-by: @li-yancheng Signed-off-by: @li-yancheng
This commit is contained in:
commit
5a83bc8b75
51
0161-Fix-lost-ftree-fold-phiopt-option-in-tests.patch
Normal file
51
0161-Fix-lost-ftree-fold-phiopt-option-in-tests.patch
Normal file
@ -0,0 +1,51 @@
|
||||
From 885c6fbfa6412a81740a8c806fa82273b7114b24 Mon Sep 17 00:00:00 2001
|
||||
From: Pronin Alexander 00812787 <pronin.alexander@huawei.com>
|
||||
Date: Wed, 13 Dec 2023 18:38:33 +0800
|
||||
Subject: [PATCH 1/2] Fix lost ftree-fold-phiopt option in tests
|
||||
|
||||
---
|
||||
gcc/testsuite/gcc.dg/double_sized_mul-1.c | 2 +-
|
||||
gcc/testsuite/gcc.dg/double_sized_mul-2.c | 2 +-
|
||||
gcc/testsuite/gcc.dg/ifcvt-gimple.c | 2 +-
|
||||
3 files changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/gcc/testsuite/gcc.dg/double_sized_mul-1.c b/gcc/testsuite/gcc.dg/double_sized_mul-1.c
|
||||
index 4d475cc8a..bdb503bc4 100644
|
||||
--- a/gcc/testsuite/gcc.dg/double_sized_mul-1.c
|
||||
+++ b/gcc/testsuite/gcc.dg/double_sized_mul-1.c
|
||||
@@ -1,7 +1,7 @@
|
||||
/* { dg-do compile } */
|
||||
/* fif-conversion-gimple and fuaddsub-overflow-match-all are required for
|
||||
proper overflow detection in some cases. */
|
||||
-/* { dg-options "-O2 -fif-conversion-gimple -fuaddsub-overflow-match-all -fdump-tree-widening_mul-stats" } */
|
||||
+/* { dg-options "-O2 -fif-conversion-gimple -fuaddsub-overflow-match-all -ftree-fold-phiopt -fdump-tree-widening_mul-stats" } */
|
||||
#include <stdint.h>
|
||||
|
||||
typedef unsigned __int128 uint128_t;
|
||||
diff --git a/gcc/testsuite/gcc.dg/double_sized_mul-2.c b/gcc/testsuite/gcc.dg/double_sized_mul-2.c
|
||||
index cc6e5af25..f9d58a2f6 100644
|
||||
--- a/gcc/testsuite/gcc.dg/double_sized_mul-2.c
|
||||
+++ b/gcc/testsuite/gcc.dg/double_sized_mul-2.c
|
||||
@@ -1,7 +1,7 @@
|
||||
/* { dg-do compile } */
|
||||
/* fif-conversion-gimple is required for proper overflow detection
|
||||
in some cases. */
|
||||
-/* { dg-options "-O2 -fif-conversion-gimple -fuaddsub-overflow-match-all -fdump-tree-widening_mul-stats" } */
|
||||
+/* { dg-options "-O2 -fif-conversion-gimple -fuaddsub-overflow-match-all -ftree-fold-phiopt -fdump-tree-widening_mul-stats" } */
|
||||
#include <stdint.h>
|
||||
|
||||
typedef unsigned __int128 uint128_t;
|
||||
diff --git a/gcc/testsuite/gcc.dg/ifcvt-gimple.c b/gcc/testsuite/gcc.dg/ifcvt-gimple.c
|
||||
index 0f7c87e5c..4dc0f9206 100644
|
||||
--- a/gcc/testsuite/gcc.dg/ifcvt-gimple.c
|
||||
+++ b/gcc/testsuite/gcc.dg/ifcvt-gimple.c
|
||||
@@ -1,5 +1,5 @@
|
||||
/* { dg-do compile } */
|
||||
-/* { dg-options "-O2 -fif-conversion-gimple -fdump-tree-optimized" } */
|
||||
+/* { dg-options "-O2 -fif-conversion-gimple -fdump-tree-optimized -ftree-fold-phiopt" } */
|
||||
|
||||
int test_int (int optimizable_int) {
|
||||
if (optimizable_int > 5)
|
||||
--
|
||||
2.33.0
|
||||
|
||||
25
0162-rtl-ifcvt-free-dominance-info-before-cleanup_cfg.patch
Normal file
25
0162-rtl-ifcvt-free-dominance-info-before-cleanup_cfg.patch
Normal file
@ -0,0 +1,25 @@
|
||||
From 126bd5722f96733e7fbe433062861d5c3534911a Mon Sep 17 00:00:00 2001
|
||||
From: vchernon <chernonog.vyacheslav@huawei.com>
|
||||
Date: Wed, 13 Dec 2023 21:52:03 +0800
|
||||
Subject: [PATCH 2/2] [rtl-ifcvt] free dominance info before cleanup_cfg not
|
||||
cleaned dominance info can cause infite loop in cleanup_cfg
|
||||
|
||||
---
|
||||
gcc/ifcvt.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/gcc/ifcvt.c b/gcc/ifcvt.c
|
||||
index 209987ebc..04086c560 100644
|
||||
--- a/gcc/ifcvt.c
|
||||
+++ b/gcc/ifcvt.c
|
||||
@@ -5624,6 +5624,7 @@ if_convert (bool after_combine)
|
||||
df_live_add_problem ();
|
||||
df_live_set_all_dirty ();
|
||||
}
|
||||
+ free_dominance_info (CDI_DOMINATORS);
|
||||
cleanup_cfg (CLEANUP_EXPENSIVE);
|
||||
|
||||
/* Record whether we are after combine pass. */
|
||||
--
|
||||
2.33.0
|
||||
|
||||
12
gcc.spec
12
gcc.spec
@ -61,7 +61,7 @@
|
||||
Summary: Various compilers (C, C++, Objective-C, ...)
|
||||
Name: gcc
|
||||
Version: %{gcc_version}
|
||||
Release: 43
|
||||
Release: 44
|
||||
License: GPLv3+ and GPLv3+ with exceptions and GPLv2+ with exceptions and LGPLv2+ and BSD
|
||||
URL: https://gcc.gnu.org
|
||||
|
||||
@ -268,6 +268,8 @@ Patch157: 0157-Add-split-complex-instructions-pass.patch
|
||||
Patch158: 0158-Implement-IPA-prefetch-optimization.patch
|
||||
Patch159: 0159-Implement-AES-pattern-matching.patch
|
||||
Patch160: 0160-AES-Add-lost-files.patch
|
||||
Patch161: 0161-Fix-lost-ftree-fold-phiopt-option-in-tests.patch
|
||||
Patch162: 0162-rtl-ifcvt-free-dominance-info-before-cleanup_cfg.patch
|
||||
|
||||
%global gcc_target_platform %{_arch}-linux-gnu
|
||||
|
||||
@ -881,6 +883,8 @@ not stable, so plugins must be rebuilt any time GCC is updated.
|
||||
%patch158 -p1
|
||||
%patch159 -p1
|
||||
%patch160 -p1
|
||||
%patch161 -p1
|
||||
%patch162 -p1
|
||||
|
||||
%build
|
||||
|
||||
@ -2905,6 +2909,12 @@ end
|
||||
%doc rpm.doc/changelogs/libcc1/ChangeLog*
|
||||
|
||||
%changelog
|
||||
* Fri Dec 15 2023 Xiong Zhou <xiongzhou4@huawei.com> - 10.3.1-44
|
||||
- Type:Sync
|
||||
- ID:NA
|
||||
- SUG:NA
|
||||
- DESC: Sync patches from openeuler/gcc
|
||||
|
||||
* Tue Dec 12 2023 Xiong Zhou <xiongzhou4@huawei.com> - 10.3.1-43
|
||||
- Type:Spec
|
||||
- ID:NA
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user