diff --git a/display-declaration-fstat-function-make-fstat-call-t.patch b/display-declaration-fstat-function-make-fstat-call-t.patch new file mode 100644 index 0000000000000000000000000000000000000000..d826b9b4a5d7dd57b8585490d3c7761239b013b0 --- /dev/null +++ b/display-declaration-fstat-function-make-fstat-call-t.patch @@ -0,0 +1,29 @@ +From ad0d9690d29f168b261600b5a5849b1ec7b7d9da Mon Sep 17 00:00:00 2001 +From: lijianglin +Date: Thu, 8 Jun 2023 19:40:53 +0800 +Subject: [PATCH] display declaration fstat function, make fstat call the + system fstat function + +the patch(commit 8ed005daf0ab03e142500324a34087ce179ae78) changed the implementation process of interface fstat and used a new system call newfstatat, which resulted in a decrease in the performance of fstat.this patch make fstat call the original system call to restore performance. +--- + sysdeps/unix/sysv/linux/fxstat64.c | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/sysdeps/unix/sysv/linux/fxstat64.c b/sysdeps/unix/sysv/linux/fxstat64.c +index be127982..52775f7e 100644 +--- a/sysdeps/unix/sysv/linux/fxstat64.c ++++ b/sysdeps/unix/sysv/linux/fxstat64.c +@@ -76,6 +76,10 @@ strong_alias (___fxstat64, __fxstat64) + + #if XSTAT_IS_XSTAT64 + strong_alias (___fxstat64, __fxstat) ++int fstat (int __fd, struct stat *__statbuf) ++{ ++ return __fxstat (_STAT_VER, __fd, (struct stat64 *)__statbuf); ++} + #endif + + #endif /* LIB_COMPAT */ +-- +2.33.0 + diff --git a/glibc.spec b/glibc.spec index b0ddf32a7ca00e25e01ce87f3d47f48892a1793b..30bc3e2b290b53d4cd1dca5972942e0feb0fb8bc 100644 --- a/glibc.spec +++ b/glibc.spec @@ -70,7 +70,7 @@ ############################################################################## Name: glibc Version: 2.34 -Release: 123 +Release: 124 Summary: The GNU libc libraries License: %{all_license} URL: http://www.gnu.org/software/glibc/ @@ -317,6 +317,8 @@ Patch9040: add-GB18030-2022-charmap.patch Patch9041: add-Wl-z-noseparate-code-for-so.patch %endif +Patch9042: isplay-declaration-fstat-function-make-fstat-call-t.patch + Provides: ldconfig rtld(GNU_HASH) bundled(gnulib) BuildRequires: audit-libs-devel >= 1.1.3, sed >= 3.95, libcap-devel, gettext @@ -1481,6 +1483,9 @@ fi %endif %changelog +* Thu Jun 8 2023 lijianglin - 2.34-124 +- display declaration fstat function, make fstat call the system fstat function + * Sun Jun 4 2023 Qingqing Li - 2.34-123 - x86: add noseparate-code for bash program performance