You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

69 lines
1.1 KiB

.text
.globl ifWhile
.p2align 2
ifWhile:
.L.ifWhile.0:
stp x29, x30, [sp, #-16]!
mov x29, sp
mov w9, #0
mov w8, #0
cmp w9, w8
b.ne .L.ifWhile.1
b .L.ifWhile.2
.L.ifWhile.1:
mov w8, #3
mov w9, w8
b .L.ifWhile.4
.L.ifWhile.2:
mov w8, #3
mov w9, w8
mov w8, #0
mov w10, w8
b .L.ifWhile.7
.L.ifWhile.3:
mov w0, w8
ldp x29, x30, [sp], #16
ret
.L.ifWhile.4:
mov w8, #2
cmp w9, w8
b.eq .L.ifWhile.5
b .L.ifWhile.6
.L.ifWhile.5:
mov w8, #2
add w8, w9, w8
mov w9, w8
b .L.ifWhile.4
.L.ifWhile.6:
mov w8, #25
add w8, w9, w8
b .L.ifWhile.3
.L.ifWhile.7:
mov w8, #5
cmp w10, w8
b.lt .L.ifWhile.8
b .L.ifWhile.9
.L.ifWhile.8:
mov w8, #2
lsl w9, w9, #1
mov w8, #1
add w8, w10, w8
mov w10, w8
b .L.ifWhile.7
.L.ifWhile.9:
mov w8, w9
b .L.ifWhile.3
.text
.globl main
.p2align 2
main:
.L.main.0:
stp x29, x30, [sp, #-16]!
mov x29, sp
bl ifWhile
mov w8, w0
mov w0, w8
ldp x29, x30, [sp], #16
ret