	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fifo_thread_recover
_fifo_thread_recover:                   ## @fifo_thread_recover
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movq	%rsi, %r14
	movq	%rdi, %r12
	movq	16(%rdi), %rax
	movq	(%rax), %r13
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	$0, 16(%r13)
	je	LBB0_2
LBB0_5:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	%r12, %rdi
	movq	%r14, %rsi
	movl	%r15d, %edx
	callq	_fifo_thread_attempt_recovery
	movl	%eax, %ebx
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
	cmpl	%eax, %ebx
	jne	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_1 Depth=1
	cmpq	$0, (%r13)
	je	LBB0_1
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_2:                                 ##   in Loop: Header=BB0_1 Depth=1
	cmpq	$0, (%r12)
	jle	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_1 Depth=1
	xorl	%eax, %eax
	callq	_av_gettime_relative
	movq	8(%r12), %rsi
	subq	%rax, %rsi
	addq	8(%r13), %rsi
	xorl	%edi, %edi
	callq	_FFMAX
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_1 Depth=1
	movl	$10000, %edi                    ## imm = 0x2710
	movq	%rax, %rsi
	callq	_FFMIN
	movl	%eax, %edi
	callq	_av_usleep
	jmp	LBB0_5
LBB0_7:
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
	cmpl	%eax, %ebx
	jne	LBB0_11
## %bb.8:
	cmpq	$0, (%r13)
	je	LBB0_11
## %bb.9:
	movq	(%r14), %rax
	movq	_FIFO_WRITE_PACKET@GOTPCREL(%rip), %rcx
	xorl	%ebx, %ebx
	cmpq	(%rcx), %rax
	jne	LBB0_11
## %bb.10:
	addq	$8, %r14
	movq	%r14, %rdi
	callq	_av_packet_unref
LBB0_11:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EAGAIN,4,2                     ## @EAGAIN
	.comm	_FIFO_WRITE_PACKET,8,3          ## @FIFO_WRITE_PACKET
	.no_dead_strip	_fifo_thread_recover
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fifo_thread_recover
_fifo_thread_recover:                   ; @fifo_thread_recover
	.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	x20, x2
	mov	x19, x1
	mov	x21, x0
	ldr	x8, [x0, #16]
	ldr	x23, [x8]
Lloh0:
	adrp	x24, _EAGAIN@GOTPAGE
Lloh1:
	ldr	x24, [x24, _EAGAIN@GOTPAGEOFF]
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x23, #16]
	cbz	w8, LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_1 Depth=1
	mov	x0, x21
	mov	x1, x19
	mov	x2, x20
	bl	_fifo_thread_attempt_recovery
	mov	x22, x0
	ldr	w0, [x24]
	bl	_AVERROR
	cmp	w22, w0
	b.ne	LBB0_7
; %bb.3:                                ;   in Loop: Header=BB0_1 Depth=1
	ldr	x8, [x23]
	cbz	x8, LBB0_1
	b	LBB0_7
LBB0_4:                                 ;   in Loop: Header=BB0_1 Depth=1
	ldr	x8, [x21]
	cmp	x8, #1
	b.lt	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_1 Depth=1
	bl	_av_gettime_relative
	ldr	x8, [x21, #8]
	ldr	x9, [x23, #8]
	sub	x8, x8, x0
	add	x1, x8, x9
	mov	w0, #0
	bl	_FFMAX
	cbz	x0, LBB0_2
; %bb.6:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	x1, x0
	mov	w0, #10000
	bl	_FFMIN
	bl	_av_usleep
	b	LBB0_2
LBB0_7:
	ldr	w0, [x24]
	bl	_AVERROR
	cmp	w22, w0
	b.ne	LBB0_12
; %bb.8:
	ldr	x8, [x23]
	cbz	x8, LBB0_12
; %bb.9:
	ldr	x8, [x19]
Lloh2:
	adrp	x9, _FIFO_WRITE_PACKET@GOTPAGE
Lloh3:
	ldr	x9, [x9, _FIFO_WRITE_PACKET@GOTPAGEOFF]
Lloh4:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_11
; %bb.10:
	add	x0, x19, #8
	bl	_av_packet_unref
LBB0_11:
	mov	w22, #0
LBB0_12:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_EAGAIN,4,2                     ; @EAGAIN
	.comm	_FIFO_WRITE_PACKET,8,3          ; @FIFO_WRITE_PACKET
	.no_dead_strip	_fifo_thread_recover
.subsections_via_symbols
