mirror of
git://sourceware.org/git/glibc.git
synced 2025-03-06 20:58:33 +01:00
mips: Use builtins for ffs and ffsll
__builtin_ffs{,ll} basically on __builtin_ctz{,ll} in MIPS GCC compiler. The hardware ctz instructions were available after MIPS{32,64} Release1. By using builtin ctz. It can also reduce code size of ffs/ffsll. Checked on mips o32. mips64. Signed-off-by: Junxian Zhu <zhujunxian@oss.cipunited.com> Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org> Reviewed-by: Maxim Kuvyrkov <maxim.kuvyrkov@linaro.org>
This commit is contained in:
parent
491e55beab
commit
545480506f
1 changed files with 3 additions and 0 deletions
3
sysdeps/mips/math-use-builtins-ffs.h
Normal file
3
sysdeps/mips/math-use-builtins-ffs.h
Normal file
|
@ -0,0 +1,3 @@
|
|||
#include <sysdep.h>
|
||||
#define USE_FFS_BUILTIN (__mips_isa_rev >= 1)
|
||||
#define USE_FFSLL_BUILTIN (__mips_isa_rev >= 1)
|
Loading…
Add table
Reference in a new issue