1
0
Fork 0
forked from koniifer/ableos
ableos-framebuffer/hblang/tests/codegen_tests_arithmetic.txt
2024-09-10 01:15:18 +02:00

25 lines
495 B
Plaintext

main:
ADDI64 r254, r254, -32d
ST r31, r254, 0a, 32h
LI64 r32, 10d
LI64 r33, 20d
LI64 r34, 2d
DIRS64 r33, r0, r33, r34
SUB64 r32, r32, r33
LI64 r33, 4d
LI64 r34, 2d
ADDI64 r34, r34, 2d
MUL64 r33, r33, r34
ADD64 r32, r32, r33
LI64 r33, 4d
MULI64 r33, r33, 4d
SUB64 r32, r32, r33
ADDI64 r32, r32, 1d
SLUI64 r1, r32, 0b
LD r31, r254, 0a, 32h
ADDI64 r254, r254, 32d
JALA r0, r31, 0a
code size: 185
ret: 1
status: Ok(())