I wrote this assembly code(a program that should print Hello, world! on the screen):
Code:
.data
msg:
.string "Hello, world!\n"
.text
.globl _start
_start:
mov $13,%edx
mov msg,%ecx
mov $1,%ebx
mov $4,%eax
int $0x80
mov $1,%eax
int $0x80
and compiled it using this commands:
Code:
as -o hello.o hello.s
ld -s -o hello hello.o
but when I run it I see nothing on the screen.
Could you help me find the problem and fix it!
Thanks!