hellplayingwithstacks.asm:7: error: symbol `exit' undefined
global _startsection .text_start: mov rax, 1 call incRax cmp rax, 2 jne exit ;; ;; Do something ;;incRax: inc rax ret
global _startsection .text_start: mov rax, 1 call incRax cmp rax, 2 jne exit ;; ;; Do something ;;exit: ; the missing label mov rax, 60 ; sys_exit number; mov rdi, 0 ; exit code - zero usually indicates no error mov rdi, -1 ; exit code - if this happens something is badly wrong! syscall incRax: inc rax ret
Segmentation fault (core dumped)