clarify the purpose of this project
[nyanglibc.git] / nptl / msgrcv.s
blob484385f9dae25f240f775957dd8dc6b96d4f4a03
1 .text
2 .p2align 4,,15
3 .globl __libc_msgrcv
4 .type __libc_msgrcv, @function
5 __libc_msgrcv:
6 movq %rcx, %r10
7 #APP
8 # 27 "../sysdeps/unix/sysv/linux/msgrcv.c" 1
9 movl %fs:24,%eax
10 # 0 "" 2
11 #NO_APP
12 testl %eax, %eax
13 jne .L2
14 movl $70, %eax
15 #APP
16 # 27 "../sysdeps/unix/sysv/linux/msgrcv.c" 1
17 syscall
19 # 0 "" 2
20 #NO_APP
21 cmpq $-4096, %rax
22 ja .L9
23 rep ret
24 .p2align 4,,10
25 .p2align 3
26 .L2:
27 pushq %r14
28 pushq %r13
29 movq %rsi, %r14
30 pushq %r12
31 pushq %rbp
32 movl %r8d, %r13d
33 pushq %rbx
34 movq %rcx, %r12
35 movq %rdx, %rbp
36 movl %edi, %ebx
37 subq $16, %rsp
38 call __pthread_enable_asynccancel@PLT
39 movl %r13d, %r8d
40 movl %eax, %r9d
41 movq %r12, %r10
42 movq %rbp, %rdx
43 movq %r14, %rsi
44 movl %ebx, %edi
45 movl $70, %eax
46 #APP
47 # 27 "../sysdeps/unix/sysv/linux/msgrcv.c" 1
48 syscall
50 # 0 "" 2
51 #NO_APP
52 cmpq $-4096, %rax
53 ja .L10
54 .L4:
55 movl %r9d, %edi
56 movq %rax, 8(%rsp)
57 call __pthread_disable_asynccancel@PLT
58 movq 8(%rsp), %rax
59 addq $16, %rsp
60 popq %rbx
61 popq %rbp
62 popq %r12
63 popq %r13
64 popq %r14
65 ret
66 .p2align 4,,10
67 .p2align 3
68 .L9:
69 movq errno@gottpoff(%rip), %rdx
70 negl %eax
71 movl %eax, %fs:(%rdx)
72 movq $-1, %rax
73 ret
74 .L10:
75 movq errno@gottpoff(%rip), %rdx
76 negl %eax
77 movl %eax, %fs:(%rdx)
78 movq $-1, %rax
79 jmp .L4
80 .size __libc_msgrcv, .-__libc_msgrcv
81 .weak msgrcv
82 .set msgrcv,__libc_msgrcv