!240 [sync] PR-229: [Sync] Sync patch from openeuler/gcc and fix wrong date
From: @openeuler-sync-bot Reviewed-by: @li-yancheng Signed-off-by: @li-yancheng
This commit is contained in:
commit
9a577e6bdc
64
0084-MULL64-Disable-mull64-transformation-by-default.patch
Normal file
64
0084-MULL64-Disable-mull64-transformation-by-default.patch
Normal file
@ -0,0 +1,64 @@
|
||||
From fb86109ebb10cdb82e1e3ffa37bb7e770fb7c066 Mon Sep 17 00:00:00 2001
|
||||
From: eastb233 <xiezhiheng@huawei.com>
|
||||
Date: Wed, 7 Dec 2022 09:43:15 +0800
|
||||
Subject: [PATCH] [MULL64] Disable mull64 transformation by default
|
||||
|
||||
This commit disables mull64 transformation by default since
|
||||
it shows some runtime failure in workloads.
|
||||
---
|
||||
gcc/match.pd | 2 +-
|
||||
gcc/opts.c | 1 -
|
||||
gcc/testsuite/g++.dg/tree-ssa/mull64.C | 2 +-
|
||||
gcc/testsuite/gcc.dg/pr107190.c | 2 +-
|
||||
4 files changed, 3 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/gcc/match.pd b/gcc/match.pd
|
||||
index 433682afb..01f81b063 100644
|
||||
--- a/gcc/match.pd
|
||||
+++ b/gcc/match.pd
|
||||
@@ -3393,7 +3393,7 @@ DEFINE_INT_AND_FLOAT_ROUND_FN (RINT)
|
||||
(simplify
|
||||
(cond @0 (op:s @1 integer_pow2p@2) @1)
|
||||
/* powerof2cst */
|
||||
- (if (INTEGRAL_TYPE_P (type))
|
||||
+ (if (flag_merge_mull && INTEGRAL_TYPE_P (type))
|
||||
(with {
|
||||
tree shift = build_int_cst (integer_type_node, tree_log2 (@2));
|
||||
}
|
||||
diff --git a/gcc/opts.c b/gcc/opts.c
|
||||
index 751965e46..f12b13599 100644
|
||||
--- a/gcc/opts.c
|
||||
+++ b/gcc/opts.c
|
||||
@@ -511,7 +511,6 @@ static const struct default_options default_options_table[] =
|
||||
{ OPT_LEVELS_2_PLUS, OPT_fvect_cost_model_, NULL, VECT_COST_MODEL_CHEAP },
|
||||
{ OPT_LEVELS_2_PLUS, OPT_finline_functions, NULL, 1 },
|
||||
{ OPT_LEVELS_2_PLUS, OPT_ftree_loop_distribute_patterns, NULL, 1 },
|
||||
- { OPT_LEVELS_2_PLUS, OPT_fmerge_mull, NULL, 1 },
|
||||
|
||||
/* -O2 and above optimizations, but not -Os or -Og. */
|
||||
{ OPT_LEVELS_2_PLUS_SPEED_ONLY, OPT_falign_functions, NULL, 1 },
|
||||
diff --git a/gcc/testsuite/g++.dg/tree-ssa/mull64.C b/gcc/testsuite/g++.dg/tree-ssa/mull64.C
|
||||
index f61cf5e6f..cad891e62 100644
|
||||
--- a/gcc/testsuite/g++.dg/tree-ssa/mull64.C
|
||||
+++ b/gcc/testsuite/g++.dg/tree-ssa/mull64.C
|
||||
@@ -1,5 +1,5 @@
|
||||
/* { dg-do compile } */
|
||||
-/* { dg-options "-O2 -Wno-psabi -fdump-tree-forwprop1-details -fdump-tree-forwprop4-details" } */
|
||||
+/* { dg-options "-O2 -fmerge-mull -Wno-psabi -fdump-tree-forwprop1-details -fdump-tree-forwprop4-details" } */
|
||||
|
||||
# define BN_BITS4 32
|
||||
# define BN_MASK2 (0xffffffffffffffffL)
|
||||
diff --git a/gcc/testsuite/gcc.dg/pr107190.c b/gcc/testsuite/gcc.dg/pr107190.c
|
||||
index 235b2761a..d1e72e5df 100644
|
||||
--- a/gcc/testsuite/gcc.dg/pr107190.c
|
||||
+++ b/gcc/testsuite/gcc.dg/pr107190.c
|
||||
@@ -1,5 +1,5 @@
|
||||
/* { dg-do compile } */
|
||||
-/* { dg-options "-O2 -fexpensive-optimizations -fdump-tree-phiopt2-details" } */
|
||||
+/* { dg-options "-O2 -fmerge-mull -fexpensive-optimizations -fdump-tree-phiopt2-details" } */
|
||||
|
||||
# define BN_BITS4 32
|
||||
# define BN_MASK2 (0xffffffffffffffffL)
|
||||
--
|
||||
2.25.1
|
||||
|
||||
12
gcc.spec
12
gcc.spec
@ -61,7 +61,7 @@
|
||||
Summary: Various compilers (C, C++, Objective-C, ...)
|
||||
Name: gcc
|
||||
Version: %{gcc_version}
|
||||
Release: 17
|
||||
Release: 18
|
||||
License: GPLv3+ and GPLv3+ with exceptions and GPLv2+ with exceptions and LGPLv2+ and BSD
|
||||
URL: https://gcc.gnu.org
|
||||
|
||||
@ -197,6 +197,7 @@ Patch80: 0080-Struct-Reorg-Add-Unsafe-Structure-Pointer-Compressio.patch
|
||||
Patch81: 0081-Loop-distribution-Insert-temp-arrays-built-from-isom.patch
|
||||
Patch82: 0082-Revert-Backport-tree-optimization-102880-make-PHI-OP.patch
|
||||
Patch83: 0083-Struct-reorg-Add-struct-semi-relayout-optimize.patch
|
||||
Patch84: 0084-MULL64-Disable-mull64-transformation-by-default.patch
|
||||
|
||||
%global gcc_target_platform %{_arch}-linux-gnu
|
||||
|
||||
@ -734,6 +735,7 @@ not stable, so plugins must be rebuilt any time GCC is updated.
|
||||
%patch81 -p1
|
||||
%patch82 -p1
|
||||
%patch83 -p1
|
||||
%patch84 -p1
|
||||
|
||||
%build
|
||||
|
||||
@ -2753,7 +2755,13 @@ end
|
||||
%doc rpm.doc/changelogs/libcc1/ChangeLog*
|
||||
|
||||
%changelog
|
||||
* Thu Dec 6 2022 benniaobufeijiushiji <linda7@huawei.com> - 10.3.1-17
|
||||
* Thu Dec 8 2022 liyancheng <412998149@qq.com> - 10.3.1-18
|
||||
- Type:Sync
|
||||
- ID:NA
|
||||
- SUG:NA
|
||||
- DESC:Sync patch from openeuler/gcc, fix wrong date
|
||||
|
||||
* Thu Dec 1 2022 benniaobufeijiushiji <linda7@huawei.com> - 10.3.1-17
|
||||
- Type:Sync
|
||||
- ID:NA
|
||||
- SUG:NA
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user