2024-09-05 04:16:11 -05:00
|
|
|
fib:
|
2024-11-17 03:06:10 -06:00
|
|
|
ADDI64 r254, r254, -32d
|
|
|
|
ST r31, r254, 0a, 32h
|
2024-11-15 15:35:03 -06:00
|
|
|
CP r32, r2
|
|
|
|
LI64 r33, 1d
|
|
|
|
LI64 r34, 2d
|
|
|
|
JGTU r32, r34, :0
|
|
|
|
CP r1, r33
|
2024-09-05 04:16:11 -05:00
|
|
|
JMP :1
|
2024-11-15 15:35:03 -06:00
|
|
|
0: SUB64 r33, r32, r33
|
|
|
|
CP r2, r33
|
2024-09-05 04:16:11 -05:00
|
|
|
JAL r31, r0, :fib
|
2024-11-15 15:35:03 -06:00
|
|
|
CP r33, r1
|
|
|
|
SUB64 r32, r32, r34
|
|
|
|
CP r2, r32
|
2024-09-20 04:01:10 -05:00
|
|
|
JAL r31, r0, :fib
|
2024-11-15 15:35:03 -06:00
|
|
|
CP r32, r1
|
|
|
|
ADD64 r32, r32, r33
|
|
|
|
CP r1, r32
|
2024-11-17 03:06:10 -06:00
|
|
|
1: LD r31, r254, 0a, 32h
|
|
|
|
ADDI64 r254, r254, 32d
|
2024-09-05 04:16:11 -05:00
|
|
|
JALA r0, r31, 0a
|
2024-09-20 04:01:10 -05:00
|
|
|
main:
|
2024-11-17 03:06:10 -06:00
|
|
|
ADDI64 r254, r254, -16d
|
|
|
|
ST r31, r254, 0a, 16h
|
2024-11-15 15:35:03 -06:00
|
|
|
LI64 r32, 10d
|
|
|
|
CP r2, r32
|
2024-09-20 04:01:10 -05:00
|
|
|
JAL r31, r0, :fib
|
2024-11-15 15:35:03 -06:00
|
|
|
CP r32, r1
|
|
|
|
CP r1, r32
|
2024-11-17 03:06:10 -06:00
|
|
|
LD r31, r254, 0a, 16h
|
|
|
|
ADDI64 r254, r254, 16d
|
2024-09-20 04:01:10 -05:00
|
|
|
JALA r0, r31, 0a
|
2024-11-15 15:35:03 -06:00
|
|
|
code size: 229
|
2024-09-05 04:16:11 -05:00
|
|
|
ret: 55
|
|
|
|
status: Ok(())
|