about summary refs log tree commit diff
path: root/ports/sysdeps/arm/memset.S
diff options
context:
space:
mode:
Diffstat (limited to 'ports/sysdeps/arm/memset.S')
-rw-r--r--ports/sysdeps/arm/memset.S35
1 files changed, 19 insertions, 16 deletions
diff --git a/ports/sysdeps/arm/memset.S b/ports/sysdeps/arm/memset.S
index 9924cb9115..5e055adea8 100644
--- a/ports/sysdeps/arm/memset.S
+++ b/ports/sysdeps/arm/memset.S
@@ -20,6 +20,9 @@
 #define NO_THUMB
 #include <sysdep.h>
 
+	.text
+	.syntax unified
+
 /* void *memset (dstpp, c, len) */
 
 ENTRY(memset)
@@ -29,7 +32,7 @@ ENTRY(memset)
 
 1:
 	tst	r3, #3		@ aligned yet?
-	strneb	r1, [r3], #1
+	strbne	r1, [r3], #1
 	subne	r2, r2, #1
 	bne	1b
 
@@ -40,27 +43,27 @@ ENTRY(memset)
 
 1:
 	subs	r2, r2, #8
-	stmcsia	r3!, {r1, ip}	@ store up to 32 bytes per loop iteration
-	subcss	r2, r2, #8
-	stmcsia	r3!, {r1, ip}
-	subcss	r2, r2, #8
-	stmcsia	r3!, {r1, ip}
-	subcss	r2, r2, #8
-	stmcsia	r3!, {r1, ip}
+	stmiacs	r3!, {r1, ip}	@ store up to 32 bytes per loop iteration
+	subscs	r2, r2, #8
+	stmiacs	r3!, {r1, ip}
+	subscs	r2, r2, #8
+	stmiacs	r3!, {r1, ip}
+	subscs	r2, r2, #8
+	stmiacs	r3!, {r1, ip}
 	bcs	1b
 
 	and	r2, r2, #7
 2:
 	subs	r2, r2, #1	@ store up to 4 bytes per loop iteration
-	strcsb	r1, [r3], #1
-	subcss	r2, r2, #1
-	strcsb	r1, [r3], #1
-	subcss	r2, r2, #1
-	strcsb	r1, [r3], #1
-	subcss	r2, r2, #1
-	strcsb	r1, [r3], #1
+	strbcs	r1, [r3], #1
+	subscs	r2, r2, #1
+	strbcs	r1, [r3], #1
+	subscs	r2, r2, #1
+	strbcs	r1, [r3], #1
+	subscs	r2, r2, #1
+	strbcs	r1, [r3], #1
 	bcs	2b
-	
+
 	DO_RET(lr)
 END(memset)
 libc_hidden_builtin_def (memset)