Comprehensive study of nasm covering fundamental concepts and advanced applications.
System calls are special requests your program makes to the operating system (OS) to do things like print text, read files, or exit.
On Linux, you:
eax
, ebx
, ecx
)int 0x80
instruction to ask the OS to helpmov eax, 4 ; syscall number for write
mov ebx, 1 ; file descriptor 1 = stdout
mov ecx, message ; pointer to your message
mov edx, 13 ; message length
int 0x80 ; make the call
System calls connect your NASM programs to the real world: files, screens, keyboards, and more!
Learning to use them is essential for any non-trivial app.
Writing text to the terminal using a Linux system call.
Exiting a program cleanly with a system call.
System calls enable NASM programs to interact with the operating system.