clarify the purpose of this project
[nyanglibc.git] / signal / sigsuspend.shared.s
blob62078b61ed8d8faae302b8b8a1f13bb17e21be1f
1 .text
2 #APP
3 memmove = __GI_memmove
4 memset = __GI_memset
5 memcpy = __GI_memcpy
6 #NO_APP
7 .p2align 4,,15
8 .globl __GI___sigsuspend
9 .hidden __GI___sigsuspend
10 .type __GI___sigsuspend, @function
11 __GI___sigsuspend:
12 #APP
13 # 26 "../sysdeps/unix/sysv/linux/sigsuspend.c" 1
14 movl %fs:24,%eax
15 # 0 "" 2
16 #NO_APP
17 testl %eax, %eax
18 jne .L2
19 movl $8, %esi
20 movl $130, %eax
21 #APP
22 # 26 "../sysdeps/unix/sysv/linux/sigsuspend.c" 1
23 syscall
25 # 0 "" 2
26 #NO_APP
27 cmpq $-4096, %rax
28 ja .L11
29 rep ret
30 .p2align 4,,10
31 .p2align 3
32 .L2:
33 pushq %rbx
34 movq %rdi, %rbx
35 subq $16, %rsp
36 call __libc_enable_asynccancel
37 movl $8, %esi
38 movl %eax, %edx
39 movq %rbx, %rdi
40 movl $130, %eax
41 #APP
42 # 26 "../sysdeps/unix/sysv/linux/sigsuspend.c" 1
43 syscall
45 # 0 "" 2
46 #NO_APP
47 cmpq $-4096, %rax
48 ja .L12
49 .L6:
50 movl %edx, %edi
51 movl %eax, 12(%rsp)
52 call __libc_disable_asynccancel
53 movl 12(%rsp), %eax
54 addq $16, %rsp
55 popq %rbx
56 ret
57 .p2align 4,,10
58 .p2align 3
59 .L11:
60 movq __libc_errno@gottpoff(%rip), %rdx
61 negl %eax
62 movl %eax, %fs:(%rdx)
63 movl $-1, %eax
64 ret
65 .L12:
66 movq __libc_errno@gottpoff(%rip), %rcx
67 negl %eax
68 movl %eax, %fs:(%rcx)
69 movl $-1, %eax
70 jmp .L6
71 .size __GI___sigsuspend, .-__GI___sigsuspend
72 .globl __sigsuspend
73 .set __sigsuspend,__GI___sigsuspend
74 .globl __libc_sigsuspend
75 .set __libc_sigsuspend,__sigsuspend
76 .weak sigsuspend
77 .set sigsuspend,__sigsuspend
78 .hidden __libc_disable_asynccancel
79 .hidden __libc_enable_asynccancel