Projects
Mega:24.03:SP1:Everything
glibc
_service:tar_scm:0001-LoongArch-Use-builtins-fo...
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:tar_scm:0001-LoongArch-Use-builtins-for-ffs-and-ffsll.patch of Package glibc
From 288d144301d20104e1b79fe5695f09af336574eb Mon Sep 17 00:00:00 2001 From: Xi Ruoyao <xry111@xry111.site> Date: Sun, 4 Feb 2024 08:27:50 +0800 Subject: [PATCH 01/15] LoongArch: Use builtins for ffs and ffsll On LoongArch GCC compiles __builtin_ffs{,ll} to basically `(x ? __builtin_ctz (x) : -1) + 1`. Since a hardware ctz instruction is available, this is much better than the table-driven generic implementation. Tested on loongarch64. Signed-off-by: Xi Ruoyao <xry111@xry111.site> Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org> --- sysdeps/loongarch/math-use-builtins-ffs.h | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 sysdeps/loongarch/math-use-builtins-ffs.h diff --git a/sysdeps/loongarch/math-use-builtins-ffs.h b/sysdeps/loongarch/math-use-builtins-ffs.h new file mode 100644 index 00000000..a83bb154 --- /dev/null +++ b/sysdeps/loongarch/math-use-builtins-ffs.h @@ -0,0 +1,2 @@ +#define USE_FFS_BUILTIN 1 +#define USE_FFSLL_BUILTIN 1 -- 2.43.0
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2