ok
This commit is contained in:
parent
91fe08a649
commit
be3ea1c230
@ -2,7 +2,7 @@
|
||||
sentence:
|
||||
.ascii "Become a Prograammermmmmmrr\0"
|
||||
match:
|
||||
.ascii "abc \0"
|
||||
.ascii "Babc m\0"
|
||||
out:
|
||||
.space 256, 0
|
||||
|
||||
@ -22,17 +22,19 @@ read_str:
|
||||
la s2, out # Load address of out into s0
|
||||
|
||||
iteruj_match:
|
||||
|
||||
lbu a1, 0(a0)
|
||||
beq a1, zero, done_match
|
||||
|
||||
bne t1, a1, 1f
|
||||
|
||||
lbu s11, 0(s2)
|
||||
lbu s10, 0(s2)
|
||||
addi s10, s10, 1
|
||||
sb s10, 0(s2)
|
||||
|
||||
1:
|
||||
addi s0, s0, 1
|
||||
addi a0, a0, 1
|
||||
addi s2, s2, 1
|
||||
j iteruj_match
|
||||
done_match:
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user