Skip to content

Instantly share code, notes, and snippets.

@vext01
Created December 14, 2022 12:53
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 vext01/670ff408042fb73cb4966fd824522e69 to your computer and use it in GitHub Desktop.
Save vext01/670ff408042fb73cb4966fd824522e69 to your computer and use it in GitHub Desktop.
sem_destroy()
00000000000106d0 <sem_destroy@@GLIBC_2.2.5>:
106d0: 31 c0 xor %eax,%eax
106d2: c3 retq
0000000000005870 <sem_destroy>:
5870: 4c 8b 1d c1 4d 00 00 mov 19905(%rip),%r11 # a638 <__retguard_2855>
5877: 4c 33 1c 24 xor (%rsp),%r11
587b: 55 push %rbp
587c: 48 89 e5 mov %rsp,%rbp
587f: 41 53 push %r11
5881: 41 56 push %r14
5883: 49 89 fe mov %rdi,%r14
5886: 83 3d ef 64 00 00 00 cmpl $0x0,25839(%rip) # bd7c <_threads_ready>
588d: 74 07 je 5896 <sem_destroy+0x26>
588f: 4d 85 f6 test %r14,%r14
5892: 75 0c jne 58a0 <sem_destroy+0x30>
5894: eb 3b jmp 58d1 <sem_destroy+0x61>
5896: e8 a5 10 00 00 callq 6940 <_rthread_init>
589b: 4d 85 f6 test %r14,%r14
589e: 74 31 je 58d1 <sem_destroy+0x61>
58a0: 49 8b 3e mov (%r14),%rdi
58a3: 48 85 ff test %rdi,%rdi
58a6: 74 29 je 58d1 <sem_destroy+0x61>
58a8: 83 7f 04 00 cmpl $0x0,0x4(%rdi)
58ac: 74 52 je 5900 <sem_destroy+0x90>
58ae: 48 8d 35 cf d4 ff ff lea -11057(%rip),%rsi # 2d84 <atexit-0x24cc>
58b5: ba 27 00 00 00 mov $0x27,%edx
58ba: bf 02 00 00 00 mov $0x2,%edi
58bf: e8 dc 36 00 00 callq 8fa0 <unlink@plt>
58c4: e8 57 36 00 00 callq 8f20 <snprintf@plt>
58c9: c7 00 10 00 00 00 movl $0x10,(%rax)
58cf: eb 0b jmp 58dc <sem_destroy+0x6c>
58d1: e8 4a 36 00 00 callq 8f20 <snprintf@plt>
58d6: c7 00 16 00 00 00 movl $0x16,(%rax)
58dc: b8 ff ff ff ff mov $0xffffffff,%eax
58e1: 41 5e pop %r14
58e3: 41 5b pop %r11
58e5: 5d pop %rbp
58e6: 4c 33 1c 24 xor (%rsp),%r11
58ea: 4c 3b 1d 47 4d 00 00 cmp 19783(%rip),%r11 # a638 <__retguard_2855>
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment