	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function open_cached_dir
_open_cached_dir:                       ## @open_cached_dir
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r9d, -44(%rbp)                 ## 4-byte Spill
	movq	%r8, -64(%rbp)                  ## 8-byte Spill
	movq	%rcx, %r15
	movq	%rdx, %r13
	movq	%rsi, %rbx
	movq	%rdi, %r14
	xorl	%r12d, %r12d
	xorl	%esi, %esi
	movl	$16, %edx
	callq	_memset
	movq	%r13, 8(%r14)
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	movq	%r13, %rsi
	movq	%r15, %rdx
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rcx
	movl	-44(%rbp), %r8d                 ## 4-byte Reload
	callq	_valid_cached_dir
	testq	%rax, %rax
	jne	LBB0_9
## %bb.1:
	movq	-56(%rbp), %r12                 ## 8-byte Reload
	cmpq	$0, 8(%rbx)
	je	LBB0_2
## %bb.3:
	movq	(%rbx), %rbx
	jmp	LBB0_4
LBB0_2:
	leaq	L_.str(%rip), %rbx
LBB0_4:
	movq	%rbx, %rdi
	callq	_opendir
	movl	%eax, (%r14)
	testl	%eax, %eax
	jne	LBB0_6
## %bb.5:
	leaq	L_.str.1(%rip), %rdi
	callq	__
	movl	%eax, %edi
	movq	%rbx, %rsi
	callq	_warning_errno
LBB0_6:
	movq	(%r12), %rdi
	testq	%rdi, %rdi
	je	LBB0_8
## %bb.7:
	movq	%r13, %rsi
	callq	_invalidate_directory
	movq	(%r12), %rax
	incl	(%rax)
LBB0_8:
	xorl	%r12d, %r12d
	cmpl	$1, (%r14)
	sbbl	%r12d, %r12d
LBB0_9:
	movl	%r12d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"."

L_.str.1:                               ## @.str.1
	.asciz	"could not open directory '%s'"

	.no_dead_strip	_open_cached_dir
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function open_cached_dir
_open_cached_dir:                       ; @open_cached_dir
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x23, x5
	mov	x22, x4
	mov	x24, x3
	mov	x21, x2
	mov	x20, x1
	mov	x19, x0
	mov	w1, #0
	mov	w2, #16
	bl	_memset
	str	x21, [x19, #8]
	mov	x0, x20
	mov	x1, x21
	mov	x2, x24
	mov	x3, x22
	mov	x4, x23
	bl	_valid_cached_dir
	mov	x8, x0
	mov	w0, #0
	cbnz	x8, LBB0_9
; %bb.1:
	ldr	x8, [x22, #8]
	cbz	x8, LBB0_3
; %bb.2:
	ldr	x22, [x22]
	b	LBB0_4
LBB0_3:
Lloh0:
	adrp	x22, l_.str@PAGE
Lloh1:
	add	x22, x22, l_.str@PAGEOFF
LBB0_4:
	mov	x0, x22
	bl	_opendir
	str	w0, [x19]
	cbnz	w0, LBB0_6
; %bb.5:
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	__
	mov	x1, x22
	bl	_warning_errno
LBB0_6:
	ldr	x0, [x20]
	cbz	x0, LBB0_8
; %bb.7:
	mov	x1, x21
	bl	_invalidate_directory
	ldr	x8, [x20]
	ldr	w9, [x8]
	add	w9, w9, #1
	str	w9, [x8]
LBB0_8:
	ldr	w8, [x19]
	cmp	w8, #0
	csetm	w0, eq
LBB0_9:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"."

l_.str.1:                               ; @.str.1
	.asciz	"could not open directory '%s'"

	.no_dead_strip	_open_cached_dir
.subsections_via_symbols
