Skip to content

Instantly share code, notes, and snippets.

@miniharryc
Created December 18, 2014 15:08
Show Gist options
  • Save miniharryc/e9b24eab7221c6ae4333 to your computer and use it in GitHub Desktop.
Save miniharryc/e9b24eab7221c6ae4333 to your computer and use it in GitHub Desktop.
Optimized quiz.c
a.out:
(__TEXT,__text) section
_main:
0000000100000ea0 pushq %rbp
0000000100000ea1 movq %rsp, %rbp
0000000100000ea4 pushq %rbx
0000000100000ea5 pushq %rax
0000000100000ea6 leaq 0xdd(%rip), %rbx
0000000100000ead movl $0x5, %esi
0000000100000eb2 movl $0x9, %edx
0000000100000eb7 xorl %eax, %eax
0000000100000eb9 movq %rbx, %rdi
0000000100000ebc callq 0x100000f6a
0000000100000ec1 movl $0x5, %esi
0000000100000ec6 movl $0x8, %edx
0000000100000ecb xorl %eax, %eax
0000000100000ecd movq %rbx, %rdi
0000000100000ed0 callq 0x100000f6a
0000000100000ed5 movl $0x5, %esi
0000000100000eda movl $0x7, %edx
0000000100000edf xorl %eax, %eax
0000000100000ee1 movq %rbx, %rdi
0000000100000ee4 callq 0x100000f6a
0000000100000ee9 movl $0x5, %esi
0000000100000eee movl $0x6, %edx
0000000100000ef3 xorl %eax, %eax
0000000100000ef5 movq %rbx, %rdi
0000000100000ef8 callq 0x100000f6a
0000000100000efd movl $0x5, %esi
0000000100000f02 movl $0x5, %edx
0000000100000f07 xorl %eax, %eax
0000000100000f09 movq %rbx, %rdi
0000000100000f0c callq 0x100000f6a
0000000100000f11 movl $0x5, %esi
0000000100000f16 movl $0x4, %edx
0000000100000f1b xorl %eax, %eax
0000000100000f1d movq %rbx, %rdi
0000000100000f20 callq 0x100000f6a
0000000100000f25 movl $0x5, %esi
0000000100000f2a movl $0x3, %edx
0000000100000f2f xorl %eax, %eax
0000000100000f31 movq %rbx, %rdi
0000000100000f34 callq 0x100000f6a
0000000100000f39 movl $0x5, %esi
0000000100000f3e movl $0x2, %edx
0000000100000f43 xorl %eax, %eax
0000000100000f45 movq %rbx, %rdi
0000000100000f48 callq 0x100000f6a
0000000100000f4d movl $0x5, %esi
0000000100000f52 movl $0x1, %edx
0000000100000f57 xorl %eax, %eax
0000000100000f59 movq %rbx, %rdi
0000000100000f5c callq 0x100000f6a
0000000100000f61 xorl %eax, %eax
0000000100000f63 addq $0x8, %rsp
0000000100000f67 popq %rbx
0000000100000f68 popq %rbp
0000000100000f69 retq
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment