cross-toolchain/bye-arm.S

23 lines
327 B
ArmAsm
Raw Permalink Normal View History

#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