riscv_asm/hello.s
2024-11-23 00:46:33 -05:00

17 lines
375 B
ArmAsm

.globl _start
_start:
li a0, 1 # file descriptor = 1 (stdout)
la a1, string # buffer
li a2, 19 # size
li a7, 64 # syscall write (64)
ecall
_end:
li a0, 0 # exit code
li a7, 93 # syscall exit
ecall
string: .asciz "Hello! It works!!!\n"