Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- AREA theRemover, CODE, READONLY
- ENTRY
- pointIncrement EQU 1
- reset EQU 0
- spaceCheck EQU " "
- tCheck EQU "t"
- hCheck EQU "h"
- eCheck EQU "e"
- ADR r0, EoS
- ADR r1, STRING1
- LDRB r2, [r0]
- continue LDRB r3, [r1], #pointIncrement
- CMP r3, #spaceCheck
- BEQ checker
- CMP r3, #tCheck
- MOVEQ r4, r3
- BEQ tChecker
- STRB r3, [r0, #pointIncrement]!
- CMP r3, r2
- BNE continue
- BEQ finish
- checker STRB r3, [r0, #pointIncrement]!
- MOV r4, #reset
- LDRB r4, [r1], #pointIncrement
- tChecker CMP r4, r2
- MOV r5, #reset
- LDRBNE r5, [r1], #pointIncrement
- CMPNE r5, r2
- MOV r6, #reset
- LDRBNE r6, [r1], #pointIncrement
- CMPNE r6, r2
- MOV r7, #reset
- LDRBNE r7, [r1], #pointIncrement
- CMPNE r7, r2
- CMPNE r7, #spaceCheck
- CMPEQ r4, #tCheck
- CMPEQ r5, #hCheck
- CMPEQ r6, #eCheck
- STRBNE r4, [r0, #pointIncrement]!
- STRBNE r5, [r0, #pointIncrement]!
- STRBNE r6, [r0, #pointIncrement]!
- STRB r7, [r0, #pointIncrement]!
- CMP r7, r2
- BNE continue
- finish B finish
- STRING1 DCB "4the the 4the The the the1" ;String1
- EoS DCB 0x00 ;end of String1
- STRING2 SPACE 0x7F ;just allocating 127 bytes
- END
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement