cross-toolchain/bye-arm.S
Alexey Sheplyakov b034a392ed bye.S: print "bye-bye ..." message
(for now only for aarch64 and armv7)
2022-11-21 16:29:10 +04:00

23 lines
327 B
ArmAsm

#include <sys/syscall.h>
.arch armv7-a
.data
message: .asciz "bye-bye ...\n"
.text
.align 2
.global _start
_start:
mov r7, #__NR_write
mov r0, #1
ldr r1, address_of_message
mov r2, #12
swi #0
mov r0, #0
mov r7, #__NR_exit
swi #0
.align 4
address_of_message: .word message
.section .note.GNU-stack,"",%progbits