Rename jumps

This commit is contained in:
2026-09-13 16:05:45 -04:00
parent 3b279e25af
commit e18363b38a
3 changed files with 33 additions and 31 deletions
+6 -6
View File
@@ -166,22 +166,22 @@ has_switch:
_str_cmp:
li t2, 0
1:
.LByteCmp:
add t0, a0, t2
add t1, a1, t2
lb t0, 0(t0)
lb t1, 0(t1)
bne t0, t1, 3f # first byte that isn't the same, branch to no match
beqz t0, 2f # jump to ret when null is read
bne t0, t1, .LNoMatch # first byte that isn't the same, branch to no match
beqz t0, .LMatch # jump to ret when null is read
addi t2, t2, 1
j 1b
j .LByteCmp
3: # no match
.LNoMatch: # no match
li a0, 0
li a1, 0
ret
2: # match
.LMatch: # match
li a0, 0
li a1, 1
ret