2024-09-05 19:42:07 -05:00
|
|
|
main:
|
|
|
|
ADDI64 r254, r254, -16d
|
|
|
|
ST r31, r254, 0a, 16h
|
|
|
|
LI64 r2, 0d
|
|
|
|
LI64 r3, 1000d
|
|
|
|
JAL r31, r0, :integer_range
|
|
|
|
CP r32, r1
|
|
|
|
LD r31, r254, 0a, 16h
|
|
|
|
ADDI64 r254, r254, 16d
|
|
|
|
JALA r0, r31, 0a
|
|
|
|
integer_range:
|
2024-09-09 18:15:18 -05:00
|
|
|
ADDI64 r254, r254, -32d
|
|
|
|
ST r31, r254, 0a, 32h
|
2024-09-05 19:42:07 -05:00
|
|
|
CP r32, r2
|
|
|
|
CP r33, r3
|
|
|
|
LI64 r2, 3d
|
|
|
|
LI64 r3, 4d
|
|
|
|
ECA
|
2024-09-12 11:42:21 -05:00
|
|
|
CP r34, r1
|
2024-09-09 18:15:18 -05:00
|
|
|
SUB64 r33, r33, r32
|
2024-09-05 19:42:07 -05:00
|
|
|
ADDI64 r33, r33, 1d
|
2024-09-12 11:42:21 -05:00
|
|
|
DIRU64 r0, r34, r34, r33
|
2024-09-09 18:15:18 -05:00
|
|
|
ADD64 r1, r34, r32
|
|
|
|
LD r31, r254, 0a, 32h
|
|
|
|
ADDI64 r254, r254, 32d
|
2024-09-05 19:42:07 -05:00
|
|
|
JALA r0, r31, 0a
|
2024-09-13 11:23:00 -05:00
|
|
|
code size: 210
|
2024-09-05 19:42:07 -05:00
|
|
|
ret: 42
|
|
|
|
status: Ok(())
|