Skip to content

Instantly share code, notes, and snippets.

@kuoyliu
Forked from bananaappletw/practice.asm
Created December 17, 2016 14:04
Show Gist options
  • Save kuoyliu/85943eb3a22b00e31629b31e45097dd7 to your computer and use it in GitHub Desktop.
Save kuoyliu/85943eb3a22b00e31629b31e45097dd7 to your computer and use it in GitHub Desktop.
Bamboofox club lecture
section .text
global _start ;must be declared for linker (ld)
_start: ;tell linker entry point
;You are going to practice system call
;What you should do?
;put system call number in %eax
;put fd number in %ebx
;put string address in %ecx
;put string length in %edx
;interrupt
section .data
msg db 'Hello, world!',0xa ;our dear string
len equ $ - msg ;length of our dear string
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment