clarify the purpose of this project
[nyanglibc.git] / nptl / pthread_setcanceltype.s
bloba14e00967f258fb1976adea52a11137ad7dbf829
1 .text
2 .p2align 4,,15
3 .globl __pthread_setcanceltype
4 .type __pthread_setcanceltype, @function
5 __pthread_setcanceltype:
6 cmpl $1, %edi
7 ja .L9
8 subq $24, %rsp
9 movq %fs:16, %r8
10 #APP
11 # 32 "pthread_setcanceltype.c" 1
12 movl %fs:776,%eax
13 # 0 "" 2
14 #NO_APP
15 movl %eax, 12(%rsp)
16 movl 12(%rsp), %ecx
17 .L7:
18 movl %ecx, %eax
19 movl %ecx, %edx
20 orl $2, %eax
21 andl $-3, %edx
22 cmpl $1, %edi
23 cmove %eax, %edx
24 testq %rsi, %rsi
25 je .L5
26 movl %ecx, %eax
27 sarl %eax
28 andl $1, %eax
29 movl %eax, (%rsi)
30 .L5:
31 cmpl %edx, %ecx
32 je .L8
33 movl %ecx, %eax
34 lock cmpxchgl %edx, 776(%r8)
35 cmpl %eax, %ecx
36 jne .L10
37 andl $-69, %edx
38 cmpl $10, %edx
39 je .L19
40 .L8:
41 xorl %eax, %eax
42 addq $24, %rsp
43 ret
44 .p2align 4,,10
45 .p2align 3
46 .L9:
47 movl $22, %eax
48 ret
49 .p2align 4,,10
50 .p2align 3
51 .L10:
52 movl %eax, %ecx
53 jmp .L7
54 .L19:
55 #APP
56 # 58 "pthread_setcanceltype.c" 1
57 movq $-1,%fs:1584
58 # 0 "" 2
59 #NO_APP
60 movq %fs:16, %rax
61 #APP
62 # 304 "pthreadP.h" 1
63 lock;orl $16, 776(%rax)
64 # 0 "" 2
65 # 307 "pthreadP.h" 1
66 movq %fs:768,%rdi
67 # 0 "" 2
68 #NO_APP
69 call __pthread_unwind@PLT
70 .size __pthread_setcanceltype, .-__pthread_setcanceltype
71 .globl pthread_setcanceltype
72 .set pthread_setcanceltype,__pthread_setcanceltype