holey-bytes/hblang/tests/codegen_tests_loops.txt

34 lines
609 B
Plaintext
Raw Normal View History

2024-09-03 15:34:17 -05:00
main:
ADDI64 r254, r254, -8d
ST r31, r254, 0a, 8h
LI64 r2, 10d
JAL r31, r0, :fib
LD r31, r254, 0a, 8h
ADDI64 r254, r254, 8d
JALA r0, r31, 0a
fib:
ADDI64 r254, r254, -48d
ST r31, r254, 0a, 48h
CP r32, r2
LI64 r33, 0d
LI64 r34, 1d
2: LI64 r35, 0d
JNE r32, r35, :0
2024-09-03 15:34:17 -05:00
JMP :1
0: CP r35, r33
CP r36, r34
ADD64 r35, r35, r36
CP r33, r34
CP r34, r35
CP r35, r32
ADDI64 r35, r35, -1d
CP r32, r35
JMP :2
1: CP r1, r33
LD r31, r254, 0a, 48h
ADDI64 r254, r254, 48d
JALA r0, r31, 0a
code size: 227
2024-05-11 11:16:27 -05:00
ret: 55
2024-05-10 15:54:12 -05:00
status: Ok(())