!425 [Sync] Sync patch from openeuler/gcc
From: @zhenyu--zhao_admin Reviewed-by: @xiongzhou4 Signed-off-by: @xiongzhou4
This commit is contained in:
commit
64c9539b9a
28
0094-BUGFIX-AutoBOLT-function-miss-bind-type.patch
Normal file
28
0094-BUGFIX-AutoBOLT-function-miss-bind-type.patch
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
From 4861c3db991e947060de54a4d20c1a13747a6024 Mon Sep 17 00:00:00 2001
|
||||||
|
From: zhenyu--zhao_admin <zhaozhenyu17@huawei.com>
|
||||||
|
Date: Wed, 15 May 2024 14:41:45 +0800
|
||||||
|
Subject: [PATCH] [BUGFIX] AutoBOLT function miss bind type
|
||||||
|
|
||||||
|
---
|
||||||
|
gcc/final.cc | 4 ++--
|
||||||
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/gcc/final.cc b/gcc/final.cc
|
||||||
|
index af4e529bb..c440846f7 100644
|
||||||
|
--- a/gcc/final.cc
|
||||||
|
+++ b/gcc/final.cc
|
||||||
|
@@ -4272,9 +4272,9 @@ leaf_renumber_regs_insn (rtx in_rtx)
|
||||||
|
|
||||||
|
#define ASM_FDO_CALLER_FLAG ".fdo.caller "
|
||||||
|
#define ASM_FDO_CALLER_SIZE_FLAG ".fdo.caller.size "
|
||||||
|
-#define ASM_FDO_CALLER_BIND_FLAG ".fdo.caller.bind"
|
||||||
|
+#define ASM_FDO_CALLER_BIND_FLAG ".fdo.caller.bind "
|
||||||
|
|
||||||
|
-#define ASM_FDO_CALLEE_FLAG ".fdo.callee"
|
||||||
|
+#define ASM_FDO_CALLEE_FLAG ".fdo.callee "
|
||||||
|
|
||||||
|
/* Return the relative offset address of the start instruction of BB,
|
||||||
|
return -1 if it is empty instruction. */
|
||||||
|
--
|
||||||
|
2.33.0
|
||||||
|
|
||||||
9044
0095-STABS-remove-gstabs-and-gxcoff-functionality.patch
Normal file
9044
0095-STABS-remove-gstabs-and-gxcoff-functionality.patch
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,45 @@
|
|||||||
|
From 06e86b362f74ba0706fb5d8377f78d24b658c300 Mon Sep 17 00:00:00 2001
|
||||||
|
From: zhenyu--zhao_admin <zhaozhenyu17@huawei.com>
|
||||||
|
Date: Sat, 18 May 2024 12:22:23 +0800
|
||||||
|
Subject: [PATCH] [Bugfix] Autofdo use PMU sampling set num eauals den
|
||||||
|
|
||||||
|
---
|
||||||
|
gcc/final.cc | 2 +-
|
||||||
|
gcc/tree-cfg.cc | 8 ++++++++
|
||||||
|
2 files changed, 9 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/gcc/final.cc b/gcc/final.cc
|
||||||
|
index f66c9d155..e4bfceabc 100644
|
||||||
|
--- a/gcc/final.cc
|
||||||
|
+++ b/gcc/final.cc
|
||||||
|
@@ -4604,7 +4604,7 @@ dump_profile_to_elf_sections ()
|
||||||
|
/* Return if no feedback data. */
|
||||||
|
if (!flag_profile_use && !flag_auto_profile)
|
||||||
|
{
|
||||||
|
- error ("-fauto-bolt should use with -profile-use or -fauto-profile");
|
||||||
|
+ error ("-fauto-bolt should use with -fprofile-use or -fauto-profile");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
diff --git a/gcc/tree-cfg.cc b/gcc/tree-cfg.cc
|
||||||
|
index 05fc45147..48b52f785 100644
|
||||||
|
--- a/gcc/tree-cfg.cc
|
||||||
|
+++ b/gcc/tree-cfg.cc
|
||||||
|
@@ -9741,6 +9741,14 @@ execute_fixup_cfg (void)
|
||||||
|
/* Same scaling is also done by ipa_merge_profiles. */
|
||||||
|
profile_count num = node->count;
|
||||||
|
profile_count den = ENTRY_BLOCK_PTR_FOR_FN (cfun)->count;
|
||||||
|
+ /* When autofdo uses PMU as the sampling unit, the number of
|
||||||
|
+ node can not be obtained directly, sometimes it will be zero,
|
||||||
|
+ but the execution number for function should at least be 1. We
|
||||||
|
+ set num be den here to make sure the num will not decrease. */
|
||||||
|
+ if (num == profile_count::zero ().afdo () && den.quality () == profile_quality::AFDO)
|
||||||
|
+ {
|
||||||
|
+ num = den;
|
||||||
|
+ }
|
||||||
|
bool scale = num.initialized_p () && !(num == den);
|
||||||
|
auto_bitmap dce_ssa_names;
|
||||||
|
|
||||||
|
--
|
||||||
|
2.33.0
|
||||||
|
|
||||||
13
gcc.spec
13
gcc.spec
@ -2,7 +2,7 @@
|
|||||||
%global gcc_major 12
|
%global gcc_major 12
|
||||||
# Note, gcc_release must be integer, if you want to add suffixes to
|
# Note, gcc_release must be integer, if you want to add suffixes to
|
||||||
# %%{release}, append them after %%{gcc_release} on Release: line.
|
# %%{release}, append them after %%{gcc_release} on Release: line.
|
||||||
%global gcc_release 29
|
%global gcc_release 30
|
||||||
|
|
||||||
%global _unpackaged_files_terminate_build 0
|
%global _unpackaged_files_terminate_build 0
|
||||||
%global _performance_build 1
|
%global _performance_build 1
|
||||||
@ -203,7 +203,9 @@ Patch90: 0090-double-sized-mul-testsuite-Add-march-armv8.2-a-for-d.patch
|
|||||||
Patch91: 0091-IPA-Bugfix-Fix-fails-in-IPA-prefetch-src-openEuler-g.patch
|
Patch91: 0091-IPA-Bugfix-Fix-fails-in-IPA-prefetch-src-openEuler-g.patch
|
||||||
Patch92: 0092-AES-Bugfix-Change-set_of-to-reg_set_p-and-add-check-.patch
|
Patch92: 0092-AES-Bugfix-Change-set_of-to-reg_set_p-and-add-check-.patch
|
||||||
Patch93: 0093-fix-bugs-within-pointer-compression-and-DFE.patch
|
Patch93: 0093-fix-bugs-within-pointer-compression-and-DFE.patch
|
||||||
|
Patch94: 0094-BUGFIX-AutoBOLT-function-miss-bind-type.patch
|
||||||
|
Patch95: 0095-STABS-remove-gstabs-and-gxcoff-functionality.patch
|
||||||
|
Patch96: 0096-Bugfix-Autofdo-use-PMU-sampling-set-num-eauals-den.patch
|
||||||
|
|
||||||
# Part 3000 ~ 4999
|
# Part 3000 ~ 4999
|
||||||
%ifarch loongarch64
|
%ifarch loongarch64
|
||||||
@ -868,6 +870,9 @@ not stable, so plugins must be rebuilt any time GCC is updated.
|
|||||||
%patch91 -p1
|
%patch91 -p1
|
||||||
%patch92 -p1
|
%patch92 -p1
|
||||||
%patch93 -p1
|
%patch93 -p1
|
||||||
|
%patch94 -p1
|
||||||
|
%patch95 -p1
|
||||||
|
%patch96 -p1
|
||||||
|
|
||||||
%ifarch loongarch64
|
%ifarch loongarch64
|
||||||
%patch3001 -p1
|
%patch3001 -p1
|
||||||
@ -3263,6 +3268,10 @@ end
|
|||||||
%doc rpm.doc/changelogs/libcc1/ChangeLog*
|
%doc rpm.doc/changelogs/libcc1/ChangeLog*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri May 17 2024 Zhenyu Zhao <zhaozhenyu17@huawei.com> - 12.3.1-30
|
||||||
|
- Type: Sync
|
||||||
|
- DESC: Sync bug fix patch from openeuler/gcc
|
||||||
|
|
||||||
* Sat May 11 2024 tiancheng-bao <baotiancheng1@huawei.com> - 12.3.1-29
|
* Sat May 11 2024 tiancheng-bao <baotiancheng1@huawei.com> - 12.3.1-29
|
||||||
- Type: Sync
|
- Type: Sync
|
||||||
- DESC: Sync bug fix patch from openeuler/gcc
|
- DESC: Sync bug fix patch from openeuler/gcc
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user