glibc/sysdeps
Lexi Shao 59b64f9cbb aarch64: fix strcpy and strnlen for big-endian [BZ #25824]
This patch fixes the optimized implementation of strcpy and strnlen
on a big-endian arm64 machine.

The optimized method uses neon, which can process 128bit with one
instruction. On a big-endian machine, the bit order should be reversed
for the whole 128-bits double word. But with instuction
	rev64	datav.16b, datav.16b
it reverses 64bits in the two halves rather than reversing 128bits.
There is no such instruction as rev128 to reverse the 128bits, but we
can fix this by loading the data registers accordingly.

Fixes 0237b61526e7("aarch64: Optimized implementation of strcpy") and
2911cb68ed3d("aarch64: Optimized implementation of strnlen").

Signed-off-by: Lexi Shao <shaolexi@huawei.com>
Reviewed-by: Szabolcs Nagy  <szabolcs.nagy@arm.com>
2020-05-15 12:15:56 +01:00
..
aarch64 aarch64: fix strcpy and strnlen for big-endian [BZ #25824] 2020-05-15 12:15:56 +01:00
alpha Update alpha libm-test-ulps 2020-04-08 13:52:45 -03:00
arm arm: XFAIL string/tst-memmove-overflow due to bug 25620 2020-05-13 16:48:26 +02:00
csky semaphore: consolidate arch headers into a generic one 2020-05-06 13:07:12 -07:00
generic elf: Implement __libc_early_init 2020-04-24 22:32:09 +02:00
gnu Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
hppa semaphore: consolidate arch headers into a generic one 2020-05-06 13:07:12 -07:00
htl pthread: Move robust mutex tests from nptl to sysdeps/pthread 2020-02-16 14:43:54 +00:00
hurd C11 threads: Move implementation to sysdeps/pthread 2020-02-09 13:56:48 +01:00
i386 Remove most gmp-mparam.h headers. 2020-04-24 22:08:59 +00:00
ia64 semaphore: consolidate arch headers into a generic one 2020-05-06 13:07:12 -07:00
ieee754 float128: use builtin_signbitf128 always 2020-05-04 13:18:45 -05:00
m68k math: Remove inline math tests 2020-03-19 11:45:44 -03:00
mach y2038: hurd: Provide __clock_gettime64 function 2020-05-05 18:45:14 +02:00
microblaze semaphore: consolidate arch headers into a generic one 2020-05-06 13:07:12 -07:00
mips Rename __LONG_DOUBLE_USES_FLOAT128 to __LDOUBLE_REDIRECTS_TO_FLOAT128_ABI 2020-04-30 08:52:08 -05:00
nios2 semaphore: consolidate arch headers into a generic one 2020-05-06 13:07:12 -07:00
nptl Linux: set_robust_list syscall number is always available 2020-03-03 12:49:44 +01:00
posix posix: Fix system error return value [BZ #25715] 2020-03-23 18:00:38 -03:00
powerpc powerpc64le/power9: guard power9 strcmp against rtld usage [BZ# 25905] 2020-05-04 13:27:31 -05:00
pthread pthread: Fix building tst-robust8 with nptl 2020-02-16 23:53:45 +01:00
riscv semaphore: consolidate arch headers into a generic one 2020-05-06 13:07:12 -07:00
s390 semaphore: consolidate arch headers into a generic one 2020-05-06 13:07:12 -07:00
sh semaphore: consolidate arch headers into a generic one 2020-05-06 13:07:12 -07:00
sparc semaphore: consolidate arch headers into a generic one 2020-05-06 13:07:12 -07:00
unix Add arch-syscall.h dependency for generating sysd-syscalls file 2020-05-14 18:40:58 +02:00
wordsize-32 Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
wordsize-64 Update copyright dates with scripts/update-copyrights. 2020-01-01 00:14:33 +00:00
x86 semaphore: consolidate arch headers into a generic one 2020-05-06 13:07:12 -07:00
x86_64 x86-64: Use RDX_LP on __x86_shared_non_temporal_threshold [BZ #25966] 2020-05-09 12:28:15 -07:00