// Hello world example for AArch64 // Author: illustrissimus // To build and run: // as -o hello.o hello.S // ld -o hello hello.o && strip -s hello // ./hello // To inspect: // objdump -d hello // AArch64 syscall list: // https://github.com/torvalds/linux/blob/v5.8/include/uapi/asm-generic/unistd.h // AArch64 reference: // https://developer.arm.com/documentation/ddi0487/fc/ .data msg: .ascii "Hello AArch64\n" msg_len = . - msg .text .global _start _start: mov w8, #64 // write mov x0, #1 //stdout ldr x1, =msg // buffer ldr x2, =msg_len // buffer length svc #0 mov w8, #93 // exit mov x0, #0 // status code svc #0