clarify the purpose of this project
[nyanglibc.git] / io / ftw.shared.s
blobc33586b92bb69004c80965046b2a464d0424a588
1 .text
2 #APP
3 memmove = __GI_memmove
4 memset = __GI_memset
5 memcpy = __GI_memcpy
6 .symver __new_nftw,nftw@@GLIBC_2.3.3
7 .symver __old_nftw,nftw@GLIBC_2.2.5
8 .symver __new_nftw64,nftw64@@GLIBC_2.3.3
9 .symver __old_nftw64,nftw64@GLIBC_2.2.5
10 #NO_APP
11 .p2align 4,,15
12 .type object_compare, @function
13 object_compare:
14 .LFB49:
15 movq 8(%rsi), %rdx
16 movq 8(%rdi), %rcx
17 xorl %eax, %eax
18 cmpq %rdx, %rcx
19 setb %dl
20 seta %al
21 movzbl %dl, %edx
22 subl %edx, %eax
23 jne .L1
24 movq (%rsi), %rdx
25 movq (%rdi), %rcx
26 xorl %eax, %eax
27 cmpq %rdx, %rcx
28 setb %dl
29 seta %al
30 movzbl %dl, %edx
31 subl %edx, %eax
32 .L1:
33 rep ret
34 .LFE49:
35 .size object_compare, .-object_compare
36 .p2align 4,,15
37 .type add_object.isra.1, @function
38 add_object.isra.1:
39 .LFB60:
40 pushq %r12
41 pushq %rbp
42 movq %rsi, %r12
43 pushq %rbx
44 movq %rdi, %rbx
45 movl $16, %edi
46 movq %rdx, %rbp
47 call malloc@PLT
48 testq %rax, %rax
49 je .L6
50 movq (%r12), %rdx
51 leaq 80(%rbx), %rsi
52 movq %rax, %rdi
53 movq %rdx, (%rax)
54 movq 0(%rbp), %rdx
55 movq %rdx, 8(%rax)
56 leaq object_compare(%rip), %rdx
57 call __GI___tsearch
58 testq %rax, %rax
59 sete %al
60 movzbl %al, %eax
61 negl %eax
62 .L4:
63 popq %rbx
64 popq %rbp
65 popq %r12
66 ret
67 .p2align 4,,10
68 .p2align 3
69 .L6:
70 movl $-1, %eax
71 jmp .L4
72 .LFE60:
73 .size add_object.isra.1, .-add_object.isra.1
74 .p2align 4,,15
75 .type process_entry.isra.3, @function
76 process_entry.isra.3:
77 .LFB62:
78 pushq %r13
79 pushq %r12
80 movq %rcx, %r13
81 pushq %rbp
82 pushq %rbx
83 movq %rsi, %r12
84 movq %rdi, %rbx
85 movq %rdx, %rbp
86 subq $168, %rsp
87 cmpb $46, (%rdx)
88 je .L53
89 .L9:
90 movslq 40(%rbx), %rax
91 movq 24(%rbx), %rdi
92 leaq 2(%rax,%r13), %rsi
93 cmpq 32(%rbx), %rsi
94 jbe .L13
95 addq %rsi, %rsi
96 movq %rsi, 32(%rbx)
97 call realloc@PLT
98 testq %rax, %rax
99 movq %rax, %rdi
100 je .L20
101 movq %rax, 24(%rbx)
102 movslq 40(%rbx), %rax
103 .L13:
104 addq %rax, %rdi
105 movq %r13, %rdx
106 movq %rbp, %rsi
107 call __GI_mempcpy@PLT
108 movb $0, (%rax)
109 movl 8(%r12), %edi
110 cmpl $-1, %edi
111 jne .L54
112 movl 48(%rbx), %eax
113 testb $4, %al
114 jne .L17
115 movq 24(%rbx), %rbp
116 .L17:
117 leaq 16(%rsp), %r13
118 testb $1, %al
119 movq %rbp, %rdi
120 movq %r13, %rsi
121 je .L18
122 call __lstat@PLT
123 .L16:
124 testl %eax, %eax
125 js .L55
126 .L19:
127 movl 40(%rsp), %eax
128 movl 48(%rbx), %ecx
129 andl $61440, %eax
130 movl %ecx, %edx
131 andl $2, %edx
132 cmpl $16384, %eax
133 je .L26
134 cmpl $40960, %eax
135 sete %al
136 movzbl %al, %eax
137 sall $2, %eax
138 .L27:
139 testl %edx, %edx
140 jne .L34
141 .L52:
142 cltq
143 salq $2, %rax
144 .L29:
145 movq 56(%rbx), %rdx
146 leaq 40(%rbx), %rcx
147 movq 24(%rbx), %rdi
148 movq %r13, %rsi
149 movl (%rdx,%rax), %edx
150 call *64(%rbx)
151 .L31:
152 testb $16, 48(%rbx)
153 je .L8
154 cmpl $2, %eax
155 jne .L8
156 .L12:
157 xorl %eax, %eax
158 .L8:
159 addq $168, %rsp
160 popq %rbx
161 popq %rbp
162 popq %r12
163 popq %r13
165 .p2align 4,,10
166 .p2align 3
167 .L54:
168 movl 48(%rbx), %ecx
169 leaq 16(%rsp), %r13
170 movq %rbp, %rsi
171 movq %r13, %rdx
172 sall $8, %ecx
173 andl $256, %ecx
174 call __fstatat@PLT
175 testl %eax, %eax
176 jns .L19
177 .L55:
178 movq __libc_errno@gottpoff(%rip), %rax
179 movl %fs:(%rax), %eax
180 cmpl $13, %eax
181 je .L37
182 cmpl $2, %eax
183 je .L37
184 .L20:
185 addq $168, %rsp
186 movl $-1, %eax
187 popq %rbx
188 popq %rbp
189 popq %r12
190 popq %r13
192 .p2align 4,,10
193 .p2align 3
194 .L53:
195 movzbl 1(%rdx), %eax
196 testb %al, %al
197 je .L12
198 cmpb $46, %al
199 jne .L9
200 cmpb $0, 2(%rdx)
201 jne .L9
202 jmp .L12
203 .p2align 4,,10
204 .p2align 3
205 .L18:
206 call __stat@PLT
207 jmp .L16
208 .p2align 4,,10
209 .p2align 3
210 .L37:
211 testb $1, 48(%rbx)
212 jne .L22
213 movl 8(%r12), %edi
214 cmpl $-1, %edi
215 je .L23
216 movl $256, %ecx
217 movq %r13, %rdx
218 movq %rbp, %rsi
219 call __fstatat@PLT
220 .L24:
221 testl %eax, %eax
222 jne .L22
223 movl 40(%rsp), %eax
224 andl $61440, %eax
225 cmpl $40960, %eax
226 jne .L22
227 movl 48(%rbx), %edx
228 movl $6, %eax
229 andl $2, %edx
230 jmp .L27
231 .p2align 4,,10
232 .p2align 3
233 .L26:
234 testl %edx, %edx
235 je .L28
236 movq 16(%rsp), %rax
237 cmpq %rax, 72(%rbx)
238 jne .L12
239 .L28:
240 andl $1, %ecx
241 je .L30
242 .L32:
243 movq %r12, %rdx
244 movq %r13, %rsi
245 movq %rbx, %rdi
246 call ftw_dir
247 jmp .L31
248 .p2align 4,,10
249 .p2align 3
250 .L22:
251 movl $12, %eax
252 jmp .L29
253 .p2align 4,,10
254 .p2align 3
255 .L34:
256 movq 72(%rbx), %rcx
257 cmpq %rcx, 16(%rsp)
258 jne .L12
259 jmp .L52
260 .p2align 4,,10
261 .p2align 3
262 .L23:
263 movq %r13, %rsi
264 movq %rbp, %rdi
265 call __lstat@PLT
266 jmp .L24
267 .p2align 4,,10
268 .p2align 3
269 .L30:
270 movq 16(%rsp), %rax
271 leaq 80(%rbx), %rsi
272 leaq object_compare(%rip), %rdx
273 movq %rsp, %rdi
274 movq %rax, (%rsp)
275 movq 24(%rsp), %rax
276 movq %rax, 8(%rsp)
277 call __GI___tfind
278 testq %rax, %rax
279 jne .L12
280 leaq 8(%r13), %rdx
281 movq %r13, %rsi
282 movq %rbx, %rdi
283 call add_object.isra.1
284 testl %eax, %eax
285 je .L32
286 jmp .L31
287 .LFE62:
288 .size process_entry.isra.3, .-process_entry.isra.3
289 .section .rodata.str1.1,"aMS",@progbits,1
290 .LC0:
291 .string "."
292 .section .rodata.str1.8,"aMS",@progbits,1
293 .align 8
294 .LC1:
295 .string "../sysdeps/wordsize-64/../../io/ftw.c"
296 .section .rodata.str1.1
297 .LC2:
298 .string "startp != data->dirbuf"
299 .LC3:
300 .string "dir.content == NULL"
301 .LC4:
302 .string "/"
303 .LC5:
304 .string ".."
305 .text
306 .p2align 4,,15
307 .type ftw_dir, @function
308 ftw_dir:
309 .LFB54:
310 pushq %r15
311 pushq %r14
312 pushq %r13
313 pushq %r12
314 movq %rdi, %r12
315 pushq %rbp
316 pushq %rbx
317 subq $88, %rsp
318 movl 40(%rdi), %ecx
319 testq %rdx, %rdx
320 movq %rsi, 16(%rsp)
321 movq %rdx, 32(%rsp)
322 movl %ecx, 44(%rsp)
323 je .L57
324 movq %rdx, %rax
325 movq 8(%rdi), %rdx
326 addq $8, %rax
327 movq %rax, 24(%rsp)
328 movq (%rdi), %rax
329 movq (%rax,%rdx,8), %rbx
330 testq %rbx, %rbx
331 je .L58
332 .L105:
333 movl $1024, %edi
334 call malloc@PLT
335 testq %rax, %rax
336 movq %rax, %r15
337 je .L62
338 movq (%rbx), %rax
339 xorl %ebp, %ebp
340 movl $1024, %r14d
341 movq %rax, (%rsp)
342 jmp .L60
343 .p2align 4,,10
344 .p2align 3
345 .L63:
346 leaq 19(%rax), %rbx
347 movq %rbx, %rdi
348 call __GI_strlen
349 leaq (%rax,%rbp), %r13
350 movq %rax, %rdx
351 leaq 2(%r13), %rax
352 cmpq %r14, %rax
353 jb .L61
354 leaq (%rdx,%rdx), %rax
355 movl $1024, %ecx
356 movq %r15, %rdi
357 movq %rdx, 8(%rsp)
358 cmpq $1024, %rax
359 cmovb %rcx, %rax
360 addq %rax, %r14
361 movq %r14, %rsi
362 call realloc@PLT
363 testq %rax, %rax
364 movq 8(%rsp), %rdx
365 je .L165
366 movq %rax, %r15
367 .L61:
368 leaq (%r15,%rbp), %rdi
369 movq %rbx, %rsi
370 leaq 1(%r13), %rbp
371 call __GI_mempcpy@PLT
372 movb $0, (%rax)
373 .L60:
374 movq (%rsp), %rdi
375 call __GI___readdir64
376 testq %rax, %rax
377 jne .L63
378 movq 8(%r12), %rdx
379 movq (%r12), %rax
380 leaq 1(%rbp), %rsi
381 movb $0, (%r15,%rbp)
382 movq %r15, %rdi
383 leaq (%rax,%rdx,8), %rbx
384 movq (%rbx), %r13
385 call realloc@PLT
386 movq %rax, 16(%r13)
387 movq (%rbx), %rax
388 cmpq $0, 16(%rax)
389 je .L165
390 movq (%rsp), %rdi
391 call __closedir
392 movq 8(%r12), %rdx
393 movq (%r12), %rax
394 cmpq $0, 24(%rsp)
395 movq 24(%r12), %rdi
396 leaq (%rax,%rdx,8), %rax
397 movq (%rax), %rdx
398 movq $0, (%rdx)
399 movl $-1, 8(%rdx)
400 movq $0, (%rax)
401 jne .L107
402 .p2align 4,,10
403 .p2align 3
404 .L65:
405 testb $4, 48(%r12)
406 je .L68
407 movslq 40(%r12), %rax
408 addq %rax, %rdi
409 leaq .LC0(%rip), %rax
410 cmpb $0, (%rdi)
411 cmove %rax, %rdi
412 .L68:
413 call __opendir
414 movq %rax, 48(%rsp)
415 .L67:
416 testq %rax, %rax
417 je .L62
418 .L66:
419 movq %rax, %rdi
420 leaq 48(%rsp), %rbx
421 call __dirfd@PLT
422 movq (%r12), %rdx
423 movl %eax, 56(%rsp)
424 movq 8(%r12), %rax
425 movq $0, 64(%rsp)
426 movq %rbx, (%rdx,%rax,8)
427 addq $1, %rax
428 cmpq 16(%r12), %rax
429 movq %rax, 8(%r12)
430 jne .L69
431 movq $0, 8(%r12)
432 .L69:
433 movl 48(%r12), %eax
434 testb $8, %al
435 jne .L72
436 leaq 40(%r12), %rcx
437 movq 24(%r12), %rdi
438 movl $1, %edx
439 movq 16(%rsp), %rsi
440 call *64(%r12)
441 testl %eax, %eax
442 movl %eax, %ebp
443 jne .L73
444 movl 48(%r12), %eax
445 .L72:
446 testb $4, %al
447 jne .L75
448 .L78:
449 addl $1, 44(%r12)
450 movq 24(%r12), %rbp
451 xorl %esi, %esi
452 movq %rbp, %rdi
453 call __GI___rawmemchr
454 cmpq %rax, %rbp
455 je .L166
456 cmpb $47, -1(%rax)
457 je .L79
458 movb $47, (%rax)
459 movq 24(%r12), %rbp
460 addq $1, %rax
461 .L79:
462 subq %rbp, %rax
463 movl %eax, 40(%r12)
464 jmp .L80
465 .p2align 4,,10
466 .p2align 3
467 .L168:
468 call __GI___readdir64
469 testq %rax, %rax
470 je .L167
471 leaq 19(%rax), %rbp
472 movq %rbp, %rdi
473 call __GI_strlen
474 movq %rbp, %rdx
475 movq %rax, %rcx
476 movq %rbx, %rsi
477 movq %r12, %rdi
478 call process_entry.isra.3
479 testl %eax, %eax
480 movl %eax, %ebp
481 jne .L81
482 .L80:
483 movq 48(%rsp), %rdi
484 testq %rdi, %rdi
485 jne .L168
486 movq 64(%rsp), %rax
487 movq %rax, %r13
488 .L103:
489 cmpb $0, (%rax)
490 jne .L91
491 .L88:
492 xorl %r13d, %r13d
493 xorl %ebp, %ebp
494 jmp .L90
495 .p2align 4,,10
496 .p2align 3
497 .L165:
498 movq %r15, %rdi
499 call free@PLT
500 .L62:
501 movq __libc_errno@gottpoff(%rip), %rax
502 cmpl $13, %fs:(%rax)
503 jne .L70
504 leaq 40(%r12), %rcx
505 movq 24(%r12), %rdi
506 movl $2, %edx
507 movq 16(%rsp), %rsi
508 call *64(%r12)
509 movl %eax, %ebp
510 .L56:
511 addq $88, %rsp
512 movl %ebp, %eax
513 popq %rbx
514 popq %rbp
515 popq %r12
516 popq %r13
517 popq %r14
518 popq %r15
520 .p2align 4,,10
521 .p2align 3
522 .L58:
523 movq 24(%rdi), %rdi
524 .L107:
525 movq 24(%rsp), %rax
526 movl (%rax), %eax
527 cmpl $-1, %eax
528 je .L65
529 movslq 40(%r12), %rsi
530 movl $67584, %edx
531 addq %rdi, %rsi
532 movl %eax, %edi
533 xorl %eax, %eax
534 call __GI___openat64_nocancel
535 cmpl $-1, %eax
536 movl %eax, %ebx
537 movq $0, 48(%rsp)
538 je .L62
539 movl %eax, %edi
540 call __fdopendir
541 testq %rax, %rax
542 movq %rax, 48(%rsp)
543 jne .L66
544 movl %ebx, %edi
545 call __GI___close_nocancel
546 movq 48(%rsp), %rax
547 jmp .L67
548 .p2align 4,,10
549 .p2align 3
550 .L57:
551 movq 8(%rdi), %rdx
552 movq (%rdi), %rax
553 movq $0, 24(%rsp)
554 movq (%rax,%rdx,8), %rbx
555 testq %rbx, %rbx
556 jne .L105
557 movq 24(%r12), %rdi
558 jmp .L65
559 .p2align 4,,10
560 .p2align 3
561 .L75:
562 movq 48(%rsp), %rdi
563 call __dirfd@PLT
564 movl %eax, %edi
565 call __fchdir
566 testl %eax, %eax
567 jns .L78
568 movl $-1, %ebp
569 .p2align 4,,10
570 .p2align 3
571 .L73:
572 movq __libc_errno@gottpoff(%rip), %rbx
573 movq 48(%rsp), %rdi
574 movl %fs:(%rbx), %r13d
575 call __closedir
576 movq 8(%r12), %rdx
577 movl %r13d, %fs:(%rbx)
578 leaq -1(%rdx), %rax
579 testq %rdx, %rdx
580 movq %rax, 8(%r12)
581 jne .L74
582 movq 16(%r12), %rax
583 subq $1, %rax
584 movq %rax, 8(%r12)
585 .L74:
586 movq (%r12), %rdx
587 movq $0, (%rdx,%rax,8)
588 jmp .L56
589 .p2align 4,,10
590 .p2align 3
591 .L89:
592 cmpb $0, 0(%r13)
593 je .L169
594 .L91:
595 movq %r13, %rdi
596 call __GI_strlen@PLT
597 movq %r13, %rdx
598 movq %rax, %rcx
599 movq %rbx, %rsi
600 movq %r12, %rdi
601 movq %rax, %r14
602 call process_entry.isra.3
603 testl %eax, %eax
604 movl %eax, %ebp
605 leaq 1(%r13,%r14), %r13
606 je .L89
607 cmpl $3, %eax
608 movq 64(%rsp), %rax
609 sete %r13b
610 .L90:
611 movq __libc_errno@gottpoff(%rip), %rbx
612 movq %rax, %rdi
613 movl %fs:(%rbx), %r14d
614 call free@PLT
615 movl %r14d, %fs:(%rbx)
616 jmp .L87
617 .p2align 4,,10
618 .p2align 3
619 .L167:
620 movq 48(%rsp), %rdi
621 movq 64(%rsp), %rax
622 testq %rdi, %rdi
623 movq %rax, %r13
624 je .L103
625 xorl %ebp, %ebp
626 .L104:
627 movq __libc_errno@gottpoff(%rip), %rbx
628 testq %rax, %rax
629 movl %fs:(%rbx), %r13d
630 jne .L170
631 call __closedir
632 movq 8(%r12), %rdx
633 movl $-1, 56(%rsp)
634 movl %r13d, %fs:(%rbx)
635 leaq -1(%rdx), %rax
636 testq %rdx, %rdx
637 movq %rax, 8(%r12)
638 jne .L86
639 movq 16(%r12), %rax
640 subq $1, %rax
641 movq %rax, 8(%r12)
642 .L86:
643 movq (%r12), %rdx
644 cmpl $3, %ebp
645 sete %r13b
646 movq $0, (%rdx,%rax,8)
647 .L87:
648 movslq 40(%r12), %rax
649 testb $16, 48(%r12)
650 movq 24(%r12), %rdx
651 leaq -1(%rdx,%rax), %rax
652 je .L113
653 testb %r13b, %r13b
654 jne .L92
655 .L113:
656 movb $0, (%rax)
657 movl 44(%rsp), %eax
658 subl $1, 44(%r12)
659 testl %ebp, %ebp
660 movl %eax, 40(%r12)
661 je .L102
662 .L94:
663 cmpq $0, 32(%rsp)
664 je .L56
665 movl 48(%r12), %eax
666 testb $4, %al
667 je .L56
668 testl %ebp, %ebp
669 je .L97
670 testb $16, %al
671 je .L56
672 leal 1(%rbp), %eax
673 andl $-3, %eax
674 je .L56
675 .L96:
676 movq 32(%rsp), %rax
677 movq (%rax), %rdi
678 testq %rdi, %rdi
679 je .L101
680 call __dirfd@PLT
681 movl %eax, %edi
682 call __fchdir
683 testl %eax, %eax
684 je .L56
685 .L101:
686 cmpl $1, 40(%r12)
687 je .L171
688 leaq .LC5(%rip), %rdi
689 call __chdir
690 testl %eax, %eax
691 jns .L56
692 .L70:
693 movl $-1, %ebp
694 jmp .L56
695 .L92:
696 movb $0, (%rax)
697 movl 44(%rsp), %eax
698 subl $1, 44(%r12)
699 movl %eax, 40(%r12)
700 .L102:
701 movl 48(%r12), %eax
702 movl %eax, %ebp
703 andl $8, %ebp
704 je .L172
705 leaq 40(%r12), %rcx
706 movq 24(%r12), %rdi
707 movl $5, %edx
708 movq 16(%rsp), %rsi
709 call *64(%r12)
710 movl %eax, %ebp
711 jmp .L94
712 .p2align 4,,10
713 .p2align 3
714 .L81:
715 movq 48(%rsp), %rdi
716 movq 64(%rsp), %rax
717 testq %rdi, %rdi
718 jne .L104
719 cmpl $3, %ebp
720 sete %r13b
721 jmp .L90
722 .p2align 4,,10
723 .p2align 3
724 .L172:
725 cmpq $0, 32(%rsp)
726 je .L56
727 andl $4, %eax
728 movl %eax, %ebp
729 je .L56
730 .L97:
731 xorl %ebp, %ebp
732 jmp .L96
733 .L169:
734 movq 64(%rsp), %rax
735 jmp .L88
736 .L171:
737 leaq .LC4(%rip), %rdi
738 call __chdir
739 testl %eax, %eax
740 jns .L56
741 jmp .L70
742 .L166:
743 leaq __PRETTY_FUNCTION__.9320(%rip), %rcx
744 leaq .LC1(%rip), %rsi
745 leaq .LC2(%rip), %rdi
746 movl $534, %edx
747 call __GI___assert_fail
748 .L170:
749 leaq __PRETTY_FUNCTION__.9320(%rip), %rcx
750 leaq .LC1(%rip), %rsi
751 leaq .LC3(%rip), %rdi
752 movl $556, %edx
753 call __GI___assert_fail
754 .LFE54:
755 .size ftw_dir, .-ftw_dir
756 .p2align 4,,15
757 .type ftw_startup, @function
758 ftw_startup:
759 .LFB55:
760 pushq %r15
761 pushq %r14
762 pushq %r13
763 pushq %r12
764 pushq %rbp
765 pushq %rbx
766 subq $264, %rsp
767 cmpb $0, (%rdi)
768 je .L234
769 testl %ecx, %ecx
770 movl $1, %r13d
771 movl %r8d, %ebx
772 cmovg %ecx, %r13d
773 movq %rdx, %r12
774 movl %esi, %ebp
775 movslq %r13d, %r13
776 movq %rdi, %r14
777 movq $0, 24(%rsp)
778 movq %r13, 32(%rsp)
779 call __GI_strlen
780 addq %rax, %rax
781 movl $4096, %edx
782 cmpq $4096, %rax
783 cmovb %rdx, %rax
784 salq $3, %r13
785 leaq 0(%r13,%rax), %rdi
786 movq %rax, 48(%rsp)
787 call malloc@PLT
788 testq %rax, %rax
789 movq %rax, 16(%rsp)
790 je .L206
791 movq %r13, %rdx
792 xorl %esi, %esi
793 movq %rax, %rdi
794 call __GI_memset@PLT
795 addq %rax, %r13
796 movq %r14, %rsi
797 movq %r13, %rdi
798 movq %r13, 40(%rsp)
799 call __GI_stpcpy@PLT
800 leaq 1(%r13), %rcx
801 movq %rax, %r9
802 cmpq %rcx, %rax
803 jbe .L208
804 cmpb $47, -1(%rax)
805 je .L177
806 jmp .L208
807 .p2align 4,,10
808 .p2align 3
809 .L236:
810 cmpb $47, -1(%r9)
811 jne .L235
812 .L177:
813 subq $1, %r9
814 cmpq %rcx, %r9
815 jne .L236
816 .L176:
817 cmpq %rcx, %r13
818 movb $0, (%rcx)
819 movl $0, 60(%rsp)
820 jb .L233
821 jmp .L178
822 .p2align 4,,10
823 .p2align 3
824 .L237:
825 subq $1, %rcx
826 cmpq %rcx, %r13
827 je .L209
828 .L233:
829 cmpb $47, -1(%rcx)
830 jne .L237
831 .L178:
832 leaq ftw_arr(%rip), %rax
833 leaq nftw_arr(%rip), %rdx
834 subq %r13, %rcx
835 testl %ebp, %ebp
836 movl %ecx, 56(%rsp)
837 movl %ebx, 64(%rsp)
838 cmovne %rdx, %rax
839 testb $4, %bl
840 movq %r12, 80(%rsp)
841 movq %rax, 72(%rsp)
842 movq $0, 96(%rsp)
843 jne .L238
844 movq __libc_errno@gottpoff(%rip), %rbp
845 xorl %r14d, %r14d
846 movl $-1, %r15d
847 .L191:
848 leaq 112(%rsp), %rax
849 testb $1, %bl
850 movq %r13, %rdi
851 movq %rax, 8(%rsp)
852 movq %rax, %rsi
853 je .L192
854 call __lstat@PLT
855 testl %eax, %eax
856 js .L193
857 movl 136(%rsp), %eax
858 andl $61440, %eax
859 cmpl $16384, %eax
860 je .L239
861 .L204:
862 cmpl $40960, %eax
863 movq 72(%rsp), %rdx
864 leaq 56(%rsp), %rcx
865 sete %al
866 movq 8(%rsp), %rsi
867 movq 40(%rsp), %rdi
868 movzbl %al, %eax
869 salq $4, %rax
870 movl (%rdx,%rax), %edx
871 call *80(%rsp)
872 movl %eax, %r13d
873 .L199:
874 andl $16, %ebx
875 movl %fs:0(%rbp), %r12d
876 je .L190
877 leal -2(%r13), %eax
878 cmpl $1, %eax
879 movl $0, %eax
880 cmovbe %eax, %r13d
881 cmpl $-1, %r15d
882 jne .L240
883 .p2align 4,,10
884 .p2align 3
885 .L201:
886 testq %r14, %r14
887 je .L183
888 movq %r14, %rdi
889 call __chdir
890 movq %r14, %rdi
891 call free@PLT
892 movl %r12d, %fs:0(%rbp)
893 jmp .L183
894 .p2align 4,,10
895 .p2align 3
896 .L192:
897 call __stat@PLT
898 testl %eax, %eax
899 jns .L195
900 movl %fs:0(%rbp), %r12d
901 cmpl $2, %r12d
902 jne .L196
903 movq 8(%rsp), %rsi
904 movq %r13, %rdi
905 call __lstat@PLT
906 testl %eax, %eax
907 jne .L193
908 movl 136(%rsp), %eax
909 andl $61440, %eax
910 cmpl $40960, %eax
911 jne .L193
912 movq 72(%rsp), %rax
913 leaq 56(%rsp), %rcx
914 movq 8(%rsp), %rsi
915 movq 40(%rsp), %rdi
916 movl 24(%rax), %edx
917 call *80(%rsp)
918 movl %eax, %r13d
919 jmp .L199
920 .p2align 4,,10
921 .p2align 3
922 .L209:
923 movq %r13, %rcx
924 jmp .L178
925 .p2align 4,,10
926 .p2align 3
927 .L235:
928 movq %r9, %rcx
929 jmp .L176
930 .p2align 4,,10
931 .p2align 3
932 .L238:
933 leaq .LC0(%rip), %rdi
934 xorl %eax, %eax
935 movl $65536, %esi
936 call __GI___open
937 cmpl $-1, %eax
938 movl %eax, %r15d
939 je .L241
940 movq 32(%rsp), %rax
941 cmpq $1, %rax
942 jbe .L213
943 movq __libc_errno@gottpoff(%rip), %rbp
944 subq $1, %rax
945 xorl %r14d, %r14d
946 movq %rax, 32(%rsp)
947 .L184:
948 movslq 56(%rsp), %rax
949 testl %eax, %eax
950 jle .L189
951 cmpl $1, %eax
952 je .L242
953 movq 40(%rsp), %rdx
954 leaq -1(%rdx,%rax), %rax
955 movzbl (%rax), %r12d
956 movb $0, (%rax)
957 movq 40(%rsp), %rdi
958 call __chdir
959 movl %eax, %r13d
960 movslq 56(%rsp), %rax
961 movq 40(%rsp), %rdx
962 movb %r12b, -1(%rdx,%rax)
963 .L188:
964 testl %r13d, %r13d
965 je .L189
966 movl %fs:0(%rbp), %r12d
967 .L190:
968 cmpl $-1, %r15d
969 je .L201
970 .L240:
971 movl %r15d, %edi
972 call __fchdir
973 movl %r15d, %edi
974 call __GI___close_nocancel
975 movl %r12d, %fs:0(%rbp)
976 .L183:
977 movq free@GOTPCREL(%rip), %rsi
978 movq 96(%rsp), %rdi
979 call __GI___tdestroy
980 movq 16(%rsp), %rdi
981 call free@PLT
982 movl %r12d, %fs:0(%rbp)
983 .L173:
984 addq $264, %rsp
985 movl %r13d, %eax
986 popq %rbx
987 popq %rbp
988 popq %r12
989 popq %r13
990 popq %r14
991 popq %r15
993 .p2align 4,,10
994 .p2align 3
995 .L193:
996 movl %fs:0(%rbp), %r12d
997 .L196:
998 movl $-1, %r13d
999 jmp .L190
1000 .p2align 4,,10
1001 .p2align 3
1002 .L195:
1003 movl 136(%rsp), %eax
1004 andl $61440, %eax
1005 cmpl $16384, %eax
1006 jne .L204
1007 movq 8(%rsp), %rsi
1008 movq 112(%rsp), %rax
1009 leaq 16(%rsp), %r12
1010 movq %r12, %rdi
1011 leaq 8(%rsi), %rdx
1012 movq %rax, 88(%rsp)
1013 call add_object.isra.1
1014 testl %eax, %eax
1015 movl %eax, %r13d
1016 jne .L199
1017 jmp .L202
1018 .p2align 4,,10
1019 .p2align 3
1020 .L213:
1021 xorl %r14d, %r14d
1022 movq __libc_errno@gottpoff(%rip), %rbp
1023 jmp .L184
1024 .p2align 4,,10
1025 .p2align 3
1026 .L208:
1027 movq %rax, %rcx
1028 jmp .L176
1029 .p2align 4,,10
1030 .p2align 3
1031 .L241:
1032 movq __libc_errno@gottpoff(%rip), %rbp
1033 xorl %r13d, %r13d
1034 movl %fs:0(%rbp), %r12d
1035 cmpl $13, %r12d
1036 jne .L183
1037 xorl %esi, %esi
1038 xorl %edi, %edi
1039 call __GI___getcwd
1040 testq %rax, %rax
1041 movq %rax, %r14
1042 jne .L184
1043 movl %fs:0(%rbp), %r12d
1044 jmp .L183
1045 .p2align 4,,10
1046 .p2align 3
1047 .L189:
1048 testb $4, 64(%rsp)
1049 movq 40(%rsp), %r13
1050 je .L191
1051 movslq 56(%rsp), %rax
1052 addq %rax, %r13
1053 leaq .LC0(%rip), %rax
1054 cmpb $0, 0(%r13)
1055 cmove %rax, %r13
1056 jmp .L191
1057 .L239:
1058 movq 112(%rsp), %rax
1059 leaq 16(%rsp), %r12
1060 movq %rax, 88(%rsp)
1061 .L202:
1062 movq 8(%rsp), %rsi
1063 xorl %edx, %edx
1064 movq %r12, %rdi
1065 call ftw_dir
1066 movl %eax, %r13d
1067 jmp .L199
1068 .L242:
1069 leaq .LC4(%rip), %rdi
1070 call __chdir
1071 movl %eax, %r13d
1072 jmp .L188
1073 .L234:
1074 movq __libc_errno@gottpoff(%rip), %rax
1075 movl $-1, %r13d
1076 movl $2, %fs:(%rax)
1077 jmp .L173
1078 .L206:
1079 movl $-1, %r13d
1080 jmp .L173
1081 .LFE55:
1082 .size ftw_startup, .-ftw_startup
1083 .p2align 4,,15
1084 .globl ftw
1085 .type ftw, @function
1086 ftw:
1087 .LFB56:
1088 movl %edx, %ecx
1089 xorl %r8d, %r8d
1090 movq %rsi, %rdx
1091 xorl %esi, %esi
1092 jmp ftw_startup
1093 .LFE56:
1094 .size ftw, .-ftw
1095 .weak ftw64
1096 .set ftw64,ftw
1097 .p2align 4,,15
1098 .globl __new_nftw
1099 .type __new_nftw, @function
1100 __new_nftw:
1101 .LFB57:
1102 testl $-32, %ecx
1103 movl %ecx, %r8d
1104 jne .L248
1105 movl %edx, %ecx
1106 movq %rsi, %rdx
1107 movl $1, %esi
1108 jmp ftw_startup
1109 .p2align 4,,10
1110 .p2align 3
1111 .L248:
1112 movq __libc_errno@gottpoff(%rip), %rax
1113 movl $22, %fs:(%rax)
1114 movl $-1, %eax
1116 .LFE57:
1117 .size __new_nftw, .-__new_nftw
1118 .globl __new_nftw64
1119 .set __new_nftw64,__new_nftw
1120 .section .text.compat,"ax",@progbits
1121 .p2align 4,,15
1122 .globl __old_nftw
1123 .type __old_nftw, @function
1124 __old_nftw:
1125 .LFB58:
1126 andl $15, %ecx
1127 movl %ecx, %r8d
1128 movl %edx, %ecx
1129 movq %rsi, %rdx
1130 movl $1, %esi
1131 jmp ftw_startup
1132 .LFE58:
1133 .size __old_nftw, .-__old_nftw
1134 .globl __old_nftw64
1135 .set __old_nftw64,__old_nftw
1136 .section .rodata.str1.8
1137 .align 8
1138 .type __PRETTY_FUNCTION__.9320, @object
1139 .size __PRETTY_FUNCTION__.9320, 8
1140 __PRETTY_FUNCTION__.9320:
1141 .string "ftw_dir"
1142 .section .rodata
1143 .align 16
1144 .type ftw_arr, @object
1145 .size ftw_arr, 28
1146 ftw_arr:
1147 .long 0
1148 .long 1
1149 .long 2
1150 .long 3
1151 .long 0
1152 .long 1
1153 .long 3
1154 .align 16
1155 .type nftw_arr, @object
1156 .size nftw_arr, 28
1157 nftw_arr:
1158 .long 0
1159 .long 1
1160 .long 2
1161 .long 3
1162 .long 4
1163 .long 5
1164 .long 6
1165 .hidden __chdir
1166 .hidden __fchdir
1167 .hidden __fdopendir
1168 .hidden __opendir
1169 .hidden __closedir