Skip to content

Instantly share code, notes, and snippets.

@Cee
Created July 26, 2014 13:04
Show Gist options
  • Save Cee/b5dca8183efedd5abf21 to your computer and use it in GitHub Desktop.
Save Cee/b5dca8183efedd5abf21 to your computer and use it in GitHub Desktop.
fun6
0x000000000040106f <+0>: mov 0x8(%rdi),%r8
0x0000000000401073 <+4>: movq $0x0,0x8(%rdi)
0x000000000040107b <+12>: mov %rdi,%rax
0x000000000040107e <+15>: mov %rdi,%rcx
0x0000000000401081 <+18>: test %r8,%r8
0x0000000000401084 <+21>: jne 0x4010c6 <fun6+87>
0x0000000000401086 <+23>: mov %rdi,%rax
0x0000000000401089 <+26>: retq
0x000000000040108a <+27>: mov %rdx,%rcx
0x000000000040108d <+30>: mov 0x8(%rcx),%rdx
0x0000000000401091 <+34>: test %rdx,%rdx
0x0000000000401094 <+37>: je 0x40109f <fun6+48>
0x0000000000401096 <+39>: cmp %esi,(%rdx)
0x0000000000401098 <+41>: jg 0x40108a <fun6+27>
0x000000000040109a <+43>: mov %rcx,%rdi
0x000000000040109d <+46>: jmp 0x4010a2 <fun6+51>
0x000000000040109f <+48>: mov %rcx,%rdi
0x00000000004010a2 <+51>: cmp %rdx,%rdi
0x00000000004010a5 <+54>: je 0x4010ad <fun6+62>
0x00000000004010a7 <+56>: mov %r8,0x8(%rdi)
0x00000000004010ab <+60>: jmp 0x4010b0 <fun6+65>
0x00000000004010ad <+62>: mov %r8,%rax
0x00000000004010b0 <+65>: mov 0x8(%r8),%rcx
0x00000000004010b4 <+69>: mov %rdx,0x8(%r8)
0x00000000004010b8 <+73>: test %rcx,%rcx
0x00000000004010bb <+76>: je 0x4010d7 <fun6+104>
0x00000000004010bd <+78>: mov %rcx,%r8
0x00000000004010c0 <+81>: mov %rax,%rcx
0x00000000004010c3 <+84>: mov %rax,%rdi
0x00000000004010c6 <+87>: mov %rcx,%rdx
0x00000000004010c9 <+90>: test %rcx,%rcx
0x00000000004010cc <+93>: je 0x4010a2 <fun6+51>
0x00000000004010ce <+95>: mov (%r8),%esi
0x00000000004010d1 <+98>: cmp %esi,(%rcx)
0x00000000004010d3 <+100>: jg 0x40108d <fun6+30>
0x00000000004010d5 <+102>: jmp 0x4010a2 <fun6+51>
0x00000000004010d7 <+104>: repz retq
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment