Skip to content

Instantly share code, notes, and snippets.

@makubi
Last active October 7, 2016 23:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save makubi/967310b27490cde348d557c2bf704725 to your computer and use it in GitHub Desktop.
Save makubi/967310b27490cde348d557c2bf704725 to your computer and use it in GitHub Desktop.
section .data
...
section .bss
...
section .text
global _start
_start:
; check for two arguments (path + 2 args)
pop rax
cmp rax, 3
jne _exit_error
; ignore path
pop rax
; read two args
pop rax
mov rcx, [rax]
pop rax
mov rbx, [rax]
; compare and jump
cmp rcx, rbx
je equals
jne nequals
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment