summaryrefslogtreecommitdiffstats
path: root/lib/libc/arm
diff options
context:
space:
mode:
authorcognet <cognet@FreeBSD.org>2004-09-23 23:10:56 +0000
committercognet <cognet@FreeBSD.org>2004-09-23 23:10:56 +0000
commit35da58a9fd717bf09beadaeb771e5e2844f86f93 (patch)
tree2406fb962c2cc1d7349148ea15c885cc371d5b55 /lib/libc/arm
parent3b0d39587d60e6c933738f6def74836317323600 (diff)
downloadFreeBSD-src-35da58a9fd717bf09beadaeb771e5e2844f86f93.zip
FreeBSD-src-35da58a9fd717bf09beadaeb771e5e2844f86f93.tar.gz
Fix the align-to-32-bits code.
Obtained from: NetBSD
Diffstat (limited to 'lib/libc/arm')
-rw-r--r--lib/libc/arm/string/memcmp.S4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc/arm/string/memcmp.S b/lib/libc/arm/string/memcmp.S
index e52e4f0..5b1a0a5 100644
--- a/lib/libc/arm/string/memcmp.S
+++ b/lib/libc/arm/string/memcmp.S
@@ -83,8 +83,8 @@ ENTRY(memcmp)
bne .Lmemcmp_bytewise2 /* Badly aligned. Do it the slow way */
/* Word-align the addresses, if necessary */
- and r3, r1, #0x03
- rsbs r3, r3, #0x03
+ sub r3, r1, #0x05
+ ands r3, r3, #0x03
add r3, r3, r3, lsl #1
addne pc, pc, r3, lsl #3
nop
OpenPOWER on IntegriCloud