	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_avio_open_dir                  ## -- Begin function avio_open_dir
	.p2align	4, 0x90
_avio_open_dir:                         ## @avio_open_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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	$0, -40(%rbp)
	callq	_av_assert0
	movl	$8, %edi
	callq	_av_mallocz
	movq	%rax, %r12
	testq	%rax, %rax
	je	LBB0_1
## %bb.4:
	movq	_AVIO_FLAG_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-40(%rbp), %rdi
	movq	%rbx, %rsi
	xorl	%ecx, %ecx
	callq	_ffurl_alloc
	testl	%eax, %eax
	js	LBB0_2
## %bb.5:
	movq	-40(%rbp), %rdi
	movq	8(%rdi), %rax
	movq	(%rax), %rcx
	testq	%rcx, %rcx
	je	LBB0_13
## %bb.6:
	cmpq	$0, 24(%rax)
	je	LBB0_13
## %bb.7:
	cmpq	$0, 16(%rax)
	je	LBB0_13
## %bb.8:
	testq	%r15, %r15
	je	LBB0_12
## %bb.9:
	cmpq	$0, 8(%rax)
	je	LBB0_12
## %bb.10:
	movl	16(%rdi), %edi
	movq	%r15, %rsi
	callq	_av_opt_set_dict
	testl	%eax, %eax
	js	LBB0_2
## %bb.11:
	movq	-40(%rbp), %rdi
	movq	8(%rdi), %rax
	movq	(%rax), %rcx
LBB0_12:
	callq	*%rcx
	jmp	LBB0_14
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
LBB0_2:
	movl	%eax, %ebx
LBB0_3:
	movq	%r12, %rdi
	callq	_av_free
	movq	$0, (%r14)
	movq	-40(%rbp), %rdi
	callq	_ffurl_close
	jmp	LBB0_16
LBB0_13:
	movq	_ENOSYS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
LBB0_14:
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_3
## %bb.15:
	movq	-40(%rbp), %rax
	movl	$1, (%rax)
	movq	%rax, (%r12)
	movq	%r12, (%r14)
	xorl	%ebx, %ebx
LBB0_16:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_AVIO_FLAG_READ,4,2             ## @AVIO_FLAG_READ
	.comm	_ENOSYS,4,2                     ## @ENOSYS
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_avio_open_dir                  ; -- Begin function avio_open_dir
	.p2align	2
_avio_open_dir:                         ; @avio_open_dir
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x21, x2
	mov	x22, x1
	mov	x19, x0
	str	xzr, [sp, #8]
	bl	_av_assert0
	mov	w0, #8
	bl	_av_mallocz
	mov	x20, x0
	cbz	x0, LBB0_10
; %bb.1:
Lloh0:
	adrp	x8, _AVIO_FLAG_READ@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AVIO_FLAG_READ@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	add	x0, sp, #8
	mov	x1, x22
	mov	x3, #0
	bl	_ffurl_alloc
	tbnz	w0, #31, LBB0_11
; %bb.2:
	ldr	x0, [sp, #8]
	ldr	x9, [x0, #8]
	ldr	x8, [x9]
	cbz	x8, LBB0_13
; %bb.3:
	ldr	x10, [x9, #24]
	cbz	x10, LBB0_13
; %bb.4:
	ldr	x10, [x9, #16]
	cbz	x10, LBB0_13
; %bb.5:
	cbz	x21, LBB0_9
; %bb.6:
	ldr	x9, [x9, #8]
	cbz	x9, LBB0_9
; %bb.7:
	ldr	w0, [x0, #16]
	mov	x1, x21
	bl	_av_opt_set_dict
	tbnz	w0, #31, LBB0_11
; %bb.8:
	ldr	x0, [sp, #8]
	ldr	x8, [x0, #8]
	ldr	x8, [x8]
LBB0_9:
	blr	x8
	mov	x22, x0
	tbz	w0, #31, LBB0_14
	b	LBB0_12
LBB0_10:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	bl	_AVERROR
LBB0_11:
	mov	x22, x0
LBB0_12:
	mov	x0, x20
	bl	_av_free
	str	xzr, [x19]
	ldr	x0, [sp, #8]
	bl	_ffurl_close
	b	LBB0_15
LBB0_13:
Lloh6:
	adrp	x8, _ENOSYS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENOSYS@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_AVERROR
	mov	x22, x0
	tbnz	w0, #31, LBB0_12
LBB0_14:
	mov	w22, #0
	ldr	x8, [sp, #8]
	mov	w9, #1
	str	w9, [x8]
	str	x8, [x20]
	str	x20, [x19]
LBB0_15:
	mov	x0, x22
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_AVIO_FLAG_READ,4,2             ; @AVIO_FLAG_READ
	.comm	_ENOSYS,4,2                     ; @ENOSYS
.subsections_via_symbols
