	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_freebsd11_readdir              ## -- Begin function freebsd11_readdir
	.p2align	4, 0x90
_freebsd11_readdir:                     ## @freebsd11_readdir
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	___isthreaded@GOTPCREL(%rip), %r15
	cmpq	$0, (%r15)
	je	LBB0_2
## %bb.1:
	movq	%r14, %rdi
	callq	__pthread_mutex_lock
LBB0_2:
	movq	_RDU_SKIP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	__readdir_unlocked
	testq	%rax, %rax
	je	LBB0_7
## %bb.3:
	movq	%rax, %rbx
	movq	8(%r14), %rdi
	testq	%rdi, %rdi
	jne	LBB0_5
## %bb.4:
	movl	$4, %edi
	callq	_malloc
	movq	%rax, %rdi
	movq	%rax, 8(%r14)
LBB0_5:
	movq	%rbx, %rsi
	callq	_freebsd11_cvtdirent
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:
	movq	8(%r14), %rbx
	cmpq	$0, (%r15)
	jne	LBB0_8
	jmp	LBB0_9
LBB0_7:
	xorl	%ebx, %ebx
	cmpq	$0, (%r15)
	je	LBB0_9
LBB0_8:
	movq	%r14, %rdi
	callq	__pthread_mutex_unlock
LBB0_9:
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	___isthreaded,8,3               ## @__isthreaded
	.comm	_RDU_SKIP,4,2                   ## @RDU_SKIP
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_freebsd11_readdir              ; -- Begin function freebsd11_readdir
	.p2align	2
_freebsd11_readdir:                     ; @freebsd11_readdir
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x0
Lloh0:
	adrp	x21, ___isthreaded@GOTPAGE
Lloh1:
	ldr	x21, [x21, ___isthreaded@GOTPAGEOFF]
	ldr	x8, [x21]
	cbz	x8, LBB0_2
; %bb.1:
	mov	x0, x19
	bl	__pthread_mutex_lock
LBB0_2:
Lloh2:
	adrp	x8, _RDU_SKIP@GOTPAGE
Lloh3:
	ldr	x8, [x8, _RDU_SKIP@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x0, x19
	bl	__readdir_unlocked
	mov	x20, x0
	cbz	x0, LBB0_7
; %bb.3:
	ldr	x0, [x19, #8]
	cbnz	x0, LBB0_5
; %bb.4:
	mov	w0, #4
	bl	_malloc
	str	x0, [x19, #8]
LBB0_5:
	mov	x1, x20
	bl	_freebsd11_cvtdirent
	cbz	x0, LBB0_10
; %bb.6:
	ldr	x20, [x19, #8]
LBB0_7:
	ldr	x8, [x21]
	cbz	x8, LBB0_9
LBB0_8:
	mov	x0, x19
	bl	__pthread_mutex_unlock
LBB0_9:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_10:
	mov	x20, #0
	ldr	x8, [x21]
	cbnz	x8, LBB0_8
	b	LBB0_9
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	___isthreaded,8,3               ; @__isthreaded
	.comm	_RDU_SKIP,4,2                   ; @RDU_SKIP
.subsections_via_symbols
