diff options
Diffstat (limited to 'firmware/target/coldfire/strlen-coldfire.S')
-rw-r--r-- | firmware/target/coldfire/strlen-coldfire.S | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/firmware/target/coldfire/strlen-coldfire.S b/firmware/target/coldfire/strlen-coldfire.S index f1e5aca981..765969da04 100644 --- a/firmware/target/coldfire/strlen-coldfire.S +++ b/firmware/target/coldfire/strlen-coldfire.S | |||
@@ -31,21 +31,14 @@ strlen: | |||
31 | move.l %a0, %a1 /* %a1 = start address */ | 31 | move.l %a0, %a1 /* %a1 = start address */ |
32 | move.l %a0, %d0 | 32 | move.l %a0, %d0 |
33 | andi.l #3, %d0 /* %d0 = %a0 & 3 */ | 33 | andi.l #3, %d0 /* %d0 = %a0 & 3 */ |
34 | jmp.l (2,%pc,%d0.l*2) | 34 | beq.b 1f /* already aligned */ |
35 | bra.b .bytes0 | 35 | jmp.l (-2,%pc,%d0.l*4) |
36 | bra.b .bytes3 | ||
37 | bra.b .bytes2 | ||
38 | bra.b .bytes1 | ||
39 | .bytes3: | ||
40 | tst.b (%a0)+ | 36 | tst.b (%a0)+ |
41 | beq.b .done | 37 | beq.b .done |
42 | .bytes2: | ||
43 | tst.b (%a0)+ | 38 | tst.b (%a0)+ |
44 | beq.b .done | 39 | beq.b .done |
45 | .bytes1: | ||
46 | tst.b (%a0)+ | 40 | tst.b (%a0)+ |
47 | beq.b .done | 41 | beq.b .done |
48 | .bytes0: | ||
49 | 42 | ||
50 | 1: | 43 | 1: |
51 | move.l (%a0)+, %d0 /* load %d0 increment %a0 */ | 44 | move.l (%a0)+, %d0 /* load %d0 increment %a0 */ |