CSC231 skel.asm

From dftwiki3
Revision as of 14:39, 4 September 2008 by Thiebaut (talk | contribs) (New page: <code><pre> ;;; program_name.asm ;;; your name ;;; ;;; a description of the program ;;; ;;; to assemble and run: ;;; ;;; nasm -f elf -F stabs program.asm ;;; ld -o program progra...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
;;; program_name.asm
;;; your name
;;; 
;;; a description of the program
;;;
;;; to assemble and run:
;;;
;;;     nasm -f elf -F  stabs program.asm
;;;     ld -o program program.o
;;;     ./program
;;; -------------------------------------------------------------------

;%include files here...

EXIT    equ             1
WRITE   equ             4
STDOUT  equ             1
        
      	;; ------------------------------------------------------------
	;; data areas
	;; ------------------------------------------------------------

	section	.data

        
	;; ------------------------------------------------------------
	;; code area
	;; ------------------------------------------------------------

	section	.text
	global	_start

_start:


        ;; (add your code here!!!!)
        

        

	;; exit()

	mov	eax,EXIT
	mov	ebx,0
	int	0x80		; final system call