clarify the purpose of this project
[nyanglibc.git] / login / getutid.s
bloba75dcaafcc5191965ac94b4086c1e644a7124637
1 .text
2 #APP
3 .section __libc_freeres_ptrs, "aw", %nobits
4 .previous
5 #NO_APP
6 .p2align 4,,15
7 .globl __getutid
8 .hidden __getutid
9 .type __getutid, @function
10 __getutid:
11 pushq %rbx
12 movq %rdi, %rbx
13 subq $16, %rsp
14 movq buffer(%rip), %rsi
15 testq %rsi, %rsi
16 je .L7
17 .L2:
18 leaq 8(%rsp), %rdx
19 movq %rbx, %rdi
20 call __getutid_r
21 testl %eax, %eax
22 js .L4
23 movq 8(%rsp), %rax
24 .L1:
25 addq $16, %rsp
26 popq %rbx
27 ret
28 .p2align 4,,10
29 .p2align 3
30 .L7:
31 movl $384, %edi
32 call malloc@PLT
33 testq %rax, %rax
34 movq %rax, %rsi
35 movq %rax, buffer(%rip)
36 jne .L2
37 .p2align 4,,10
38 .p2align 3
39 .L4:
40 xorl %eax, %eax
41 jmp .L1
42 .size __getutid, .-__getutid
43 .weak getutid
44 .set getutid,__getutid
45 .section __libc_freeres_ptrs
46 #,"aw",@progbits
47 .align 8
48 .type buffer, @object
49 .size buffer, 8
50 buffer:
51 .zero 8
52 .hidden __getutid_r