1
0
Fork 0
forked from koniifer/ableos
ableos-framebuffer/hblang/tests/codegen_tests_arithmetic.txt
2024-09-14 11:26:54 +02:00

29 lines
570 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
LI64 r33, 1d
SLUI64 r33, r33, 0b
ADD64 r32, r32, r33
LI64 r33, 1d
NEG r33, r33
ADD64 r1, r32, r33
LD r31, r254, 0a, 32h
ADDI64 r254, r254, 32d
JALA r0, r31, 0a
code size: 205
ret: 0
status: Ok(())