	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mxg_update_cache
_mxg_update_cache:                      ## @mxg_update_cache
	.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
	movq	8(%rdi), %rbx
	movq	8(%rbx), %r13
	movq	16(%rbx), %r12
	subq	%r12, %r13
	shrq	$2, %r13
	movl	%r13d, %eax
	addl	%esi, %eax
	jb	LBB0_7
## %bb.1:
	movl	%esi, %r15d
	movq	%rdi, %r14
	movq	24(%rbx), %rcx
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	leaq	32(%rbx), %rsi
	movl	%eax, %edx
	movq	_AV_INPUT_BUFFER_PADDING_SIZE@GOTPCREL(%rip), %rax
	addq	(%rax), %rdx
	movq	%r12, %rdi
	callq	_av_fast_realloc
	testq	%rax, %rax
	je	LBB0_7
## %bb.2:
	movq	%rax, 16(%rbx)
	movl	%r13d, %ecx
	leaq	(%rax,%rcx,4), %rcx
	movq	%rcx, 8(%rbx)
	cmpq	$0, 24(%rbx)
	je	LBB0_4
## %bb.3:
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	subq	%r12, %rdx
	shrq	$2, %rdx
	movl	%edx, %edx
	leaq	(%rax,%rdx,4), %rax
	movq	%rax, 24(%rbx)
LBB0_4:
	movl	(%r14), %edi
	movslq	(%rbx), %rax
	leaq	(%rcx,%rax,4), %rsi
	subl	%eax, %r15d
	movl	%r15d, %edx
	callq	_avio_read
	testl	%eax, %eax
	js	LBB0_6
## %bb.5:
	addl	%eax, (%rbx)
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_AVERROR                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_AV_INPUT_BUFFER_PADDING_SIZE,8,3 ## @AV_INPUT_BUFFER_PADDING_SIZE
	.no_dead_strip	_mxg_update_cache
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mxg_update_cache
_mxg_update_cache:                      ; @mxg_update_cache
	.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
	ldr	x22, [x0, #8]
	ldp	x8, x21, [x22, #8]
	sub	x8, x8, x21
	lsr	x24, x8, #2
	adds	w8, w24, w1
	b.hs	LBB0_7
; %bb.1:
	mov	x19, x1
	mov	x20, x0
	ldr	x23, [x22, #24]
	add	x1, x22, #32
Lloh0:
	adrp	x9, _AV_INPUT_BUFFER_PADDING_SIZE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _AV_INPUT_BUFFER_PADDING_SIZE@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	add	x2, x9, w8, uxtw
	mov	x0, x21
	bl	_av_fast_realloc
	cbz	x0, LBB0_7
; %bb.2:
	add	x8, x0, w24, uxtw #2
	stp	x8, x0, [x22, #8]
	ldr	x9, [x22, #24]
	cbz	x9, LBB0_4
; %bb.3:
	sub	x9, x23, x21
	lsr	x9, x9, #2
	add	x9, x0, w9, uxtw #2
	str	x9, [x22, #24]
LBB0_4:
	ldr	w0, [x20]
	ldrsw	x9, [x22]
	add	x1, x8, x9, lsl #2
	sub	w2, w19, w9
	bl	_avio_read
	tbnz	w0, #31, LBB0_6
; %bb.5:
	ldr	w8, [x22]
	add	w8, w8, w0
	str	w8, [x22]
LBB0_6:
	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
LBB0_7:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	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
	b	_AVERROR
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_AV_INPUT_BUFFER_PADDING_SIZE,8,3 ; @AV_INPUT_BUFFER_PADDING_SIZE
	.no_dead_strip	_mxg_update_cache
.subsections_via_symbols
