mips/test/masm/hello.asm

27 lines
317 B
NASM

# Copyright (c) 2024 Freya Murphy
# file: div.asm
# test: should print hello world
.data
.align 1
hw:
.asciiz "Hello, world!\n"
.text
.align 2
.globl main
main:
# print hello world
li $v0, 1
li $a0, 1 # stdout
la $a1, hw # load string
li $a2, 14 # load length
syscall
# return 1
li $v0, 0
jr $ra
nop