My first "Hello World" program in assembly language (shell code) .
#------------------start--------------------------------------
Let compile it
Let link it.
Let run it.
Voila!!!!
#------------------start--------------------------------------
.data#------------------end--------------------------------------
HelloWorldString:
.ascii "Hello World\n"
.text
.globl _start
_start:
movl $4, %eax
movl $1, %ebx
movl $HelloWorldString, %ecx
movl $12, %edx
int $0x80
movl $1, %eax
movl $0, %ebx
int $0x80
Let compile it
$ as -o Helloword.o Helloword.s
Let link it.
$ ld -o Helloword Helloword.o
Let run it.
$ ./Helloword
Hello World Voila!!!!
No comments:
Post a Comment