clarify the purpose of this project
[nyanglibc.git] / libio / iofwrite.shared.s
blob7a2f287f637d91760c4c1b1fca40c7be9182221e
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__IO_fwrite
9 .hidden __GI__IO_fwrite
10 .type __GI__IO_fwrite, @function
11 __GI__IO_fwrite:
12 .LFB68:
13 pushq %r15
14 pushq %r14
15 pushq %r13
16 pushq %r12
17 pushq %rbp
18 movq %rsi, %rbp
19 pushq %rbx
20 imulq %rdx, %rbp
21 subq $8, %rsp
22 testq %rbp, %rbp
23 je .L1
24 movq %rdx, %r13
25 movl (%rcx), %edx
26 movq %rcx, %rbx
27 movq %rsi, %r12
28 movq %rdi, %r14
29 andl $32768, %edx
30 jne .L3
31 movq 136(%rcx), %rdi
32 movq %fs:16, %r15
33 cmpq %r15, 8(%rdi)
34 je .L4
35 #APP
36 # 37 "iofwrite.c" 1
37 movl %fs:24,%eax
38 # 0 "" 2
39 #NO_APP
40 testl %eax, %eax
41 jne .L5
42 movl $1, %edx
43 #APP
44 # 47 "../sysdeps/unix/sysv/linux/x86/lowlevellock.h" 1
45 cmpxchgl %edx, (%rdi)
46 # 0 "" 2
47 #NO_APP
48 .L6:
49 movq 136(%rbx), %rdi
50 movq %r15, 8(%rdi)
51 .L4:
52 addl $1, 4(%rdi)
53 .L3:
54 movl 192(%rbx), %eax
55 testl %eax, %eax
56 jne .L9
57 movl $-1, 192(%rbx)
58 .L10:
59 movq 216(%rbx), %r15
60 leaq __start___libc_IO_vtables(%rip), %rdx
61 leaq __stop___libc_IO_vtables(%rip), %rax
62 subq %rdx, %rax
63 movq %r15, %rcx
64 subq %rdx, %rcx
65 cmpq %rcx, %rax
66 jbe .L12
67 .L14:
68 movq %rbp, %rdx
69 movq %r14, %rsi
70 movq %rbx, %rdi
71 .LEHB0:
72 call *56(%r15)
73 cmpq $-1, %rax
74 movq %rax, %r8
75 sete %r9b
76 testl $32768, (%rbx)
77 jne .L15
78 movq 136(%rbx), %rdi
79 subl $1, 4(%rdi)
80 jne .L15
81 jmp .L22
82 .p2align 4,,10
83 .p2align 3
84 .L9:
85 cmpl $-1, %eax
86 je .L10
87 testl $32768, (%rbx)
88 jne .L23
89 movq 136(%rbx), %rdi
90 subl $1, 4(%rdi)
91 jne .L23
92 xorl %r9d, %r9d
93 xorl %r8d, %r8d
94 .L22:
95 movq $0, 8(%rdi)
96 #APP
97 # 885 "libioP.h" 1
98 movl %fs:24,%eax
99 # 0 "" 2
100 #NO_APP
101 testl %eax, %eax
102 jne .L16
103 subl $1, (%rdi)
104 .L15:
105 cmpq %r8, %rbp
106 je .L24
107 testb %r9b, %r9b
108 je .L33
109 .L24:
110 movq %r13, %rbp
111 .L1:
112 addq $8, %rsp
113 movq %rbp, %rax
114 popq %rbx
115 popq %rbp
116 popq %r12
117 popq %r13
118 popq %r14
119 popq %r15
121 .p2align 4,,10
122 .p2align 3
123 .L23:
124 xorl %ebp, %ebp
125 jmp .L1
126 .p2align 4,,10
127 .p2align 3
128 .L12:
129 call _IO_vtable_check
130 jmp .L14
131 .p2align 4,,10
132 .p2align 3
133 .L33:
134 movq %r8, %rax
135 xorl %edx, %edx
136 divq %r12
137 movq %rax, %rbp
138 jmp .L1
139 .p2align 4,,10
140 .p2align 3
141 .L5:
142 movl $1, %ecx
143 movl %edx, %eax
144 lock cmpxchgl %ecx, (%rdi)
145 je .L6
146 call __lll_lock_wait_private
147 .LEHE0:
148 jmp .L6
149 .p2align 4,,10
150 .p2align 3
151 .L16:
152 xorl %eax, %eax
153 #APP
154 # 885 "libioP.h" 1
155 xchgl %eax, (%rdi)
156 # 0 "" 2
157 #NO_APP
158 cmpl $1, %eax
159 jle .L15
160 xorl %r10d, %r10d
161 movl $1, %edx
162 movl $129, %esi
163 movl $202, %eax
164 #APP
165 # 885 "libioP.h" 1
166 syscall
168 # 0 "" 2
169 #NO_APP
170 jmp .L15
171 .L26:
172 testl $32768, (%rbx)
173 movq %rax, %r8
174 jne .L18
175 movq 136(%rbx), %rdi
176 movl 4(%rdi), %eax
177 subl $1, %eax
178 testl %eax, %eax
179 movl %eax, 4(%rdi)
180 jne .L18
181 movq $0, 8(%rdi)
182 #APP
183 # 885 "libioP.h" 1
184 movl %fs:24,%edx
185 # 0 "" 2
186 #NO_APP
187 testl %edx, %edx
188 jne .L19
189 subl $1, (%rdi)
190 .L18:
191 movq %r8, %rdi
192 .LEHB1:
193 call _Unwind_Resume@PLT
194 .LEHE1:
195 .L19:
196 #APP
197 # 885 "libioP.h" 1
198 xchgl %eax, (%rdi)
199 # 0 "" 2
200 #NO_APP
201 subl $1, %eax
202 jle .L18
203 xorl %r10d, %r10d
204 movl $1, %edx
205 movl $129, %esi
206 movl $202, %eax
207 #APP
208 # 885 "libioP.h" 1
209 syscall
211 # 0 "" 2
212 #NO_APP
213 jmp .L18
214 .LFE68:
215 .globl __gcc_personality_v0
216 .section .gcc_except_table,"a",@progbits
217 .LLSDA68:
218 .byte 0xff
219 .byte 0xff
220 .byte 0x1
221 .uleb128 .LLSDACSE68-.LLSDACSB68
222 .LLSDACSB68:
223 .uleb128 .LEHB0-.LFB68
224 .uleb128 .LEHE0-.LEHB0
225 .uleb128 .L26-.LFB68
226 .uleb128 0
227 .uleb128 .LEHB1-.LFB68
228 .uleb128 .LEHE1-.LEHB1
229 .uleb128 0
230 .uleb128 0
231 .LLSDACSE68:
232 .text
233 .size __GI__IO_fwrite, .-__GI__IO_fwrite
234 .globl _IO_fwrite
235 .set _IO_fwrite,__GI__IO_fwrite
236 .weak __GI_fwrite
237 .hidden __GI_fwrite
238 .set __GI_fwrite,_IO_fwrite
239 .weak fwrite
240 .set fwrite,__GI_fwrite
241 .hidden DW.ref.__gcc_personality_v0
242 .weak DW.ref.__gcc_personality_v0
243 .section .data.DW.ref.__gcc_personality_v0,"awG",@progbits,DW.ref.__gcc_personality_v0,comdat
244 .align 8
245 .type DW.ref.__gcc_personality_v0, @object
246 .size DW.ref.__gcc_personality_v0, 8
247 DW.ref.__gcc_personality_v0:
248 .quad __gcc_personality_v0
249 .hidden __lll_lock_wait_private
250 .hidden _IO_vtable_check
251 .hidden __stop___libc_IO_vtables
252 .hidden __start___libc_IO_vtables