	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_av_grow_packet                 ## -- Begin function av_grow_packet
	.p2align	4, 0x90
_av_grow_packet:                        ## @av_grow_packet
	.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	%esi, %r14d
	movq	%rdi, %r12
	movq	_INT_MAX@GOTPCREL(%rip), %rbx
	movl	(%rbx), %eax
	movq	_AV_INPUT_BUFFER_PADDING_SIZE@GOTPCREL(%rip), %r15
	subl	(%r15), %eax
	xorl	%edi, %edi
	cmpl	%eax, (%r12)
	setbe	%dil
	callq	_av_assert0
	movl	(%rbx), %edx
	movl	(%r12), %edi
	addl	(%r15), %edi
	movl	%edx, %eax
	subl	%edi, %eax
	cmpl	%r14d, %eax
	jae	LBB0_1
LBB0_15:
	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
LBB0_1:
	addl	%r14d, %edi
	leaq	16(%r12), %r15
	movq	16(%r12), %rcx
	testq	%rcx, %rcx
	je	LBB0_9
## %bb.2:
	movq	8(%r12), %rbx
	movq	8(%rcx), %rax
	testq	%rbx, %rbx
	je	LBB0_3
## %bb.4:
	movq	%rbx, %r13
	subq	%rax, %r13
	sarq	$2, %r13
	subl	%edi, %edx
	movq	%rbx, %rax
	cmpq	%rdx, %r13
	ja	LBB0_15
	jmp	LBB0_5
LBB0_9:
	callq	_av_buffer_alloc
	movq	%rax, (%r15)
	testq	%rax, %rax
	je	LBB0_15
## %bb.10:
	movl	(%r12), %edx
	testl	%edx, %edx
	je	LBB0_12
## %bb.11:
	movq	8(%rax), %rdi
	movq	8(%r12), %rsi
	callq	_memcpy
	movq	16(%r12), %rax
LBB0_12:
	movq	8(%rax), %rax
	movq	%rax, 8(%r12)
	jmp	LBB0_13
LBB0_3:
	movq	%rax, 8(%r12)
	xorl	%r13d, %r13d
LBB0_5:
	movslq	%edi, %rsi
	addq	%r13, %rsi
	movslq	(%rcx), %rcx
	cmpq	%rcx, %rsi
	jbe	LBB0_13
## %bb.6:
	movq	%r15, %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_av_buffer_realloc
	testl	%eax, %eax
	js	LBB0_8
## %bb.7:
	movq	16(%r12), %rax
	shlq	$2, %r13
	addq	8(%rax), %r13
	movq	%r13, 8(%r12)
	movq	%r13, %rax
LBB0_13:
	addl	(%r12), %r14d
	movl	%r14d, (%r12)
	leaq	(%rax,%r14,4), %rdi
	movq	_AV_INPUT_BUFFER_PADDING_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	xorl	%r15d, %r15d
	xorl	%esi, %esi
	callq	_memset
LBB0_14:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	movl	%eax, %r15d
	movq	%rbx, 8(%r12)
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_INT_MAX,4,2                    ## @INT_MAX
	.comm	_AV_INPUT_BUFFER_PADDING_SIZE,4,2 ## @AV_INPUT_BUFFER_PADDING_SIZE
	.comm	_ENOMEM,4,2                     ## @ENOMEM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_av_grow_packet                 ; -- Begin function av_grow_packet
	.p2align	2
_av_grow_packet:                        ; @av_grow_packet
	.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, x1
	mov	x19, x0
	ldr	w8, [x0]
Lloh0:
	adrp	x21, _INT_MAX@GOTPAGE
Lloh1:
	ldr	x21, [x21, _INT_MAX@GOTPAGEOFF]
	ldr	w9, [x21]
Lloh2:
	adrp	x22, _AV_INPUT_BUFFER_PADDING_SIZE@GOTPAGE
Lloh3:
	ldr	x22, [x22, _AV_INPUT_BUFFER_PADDING_SIZE@GOTPAGEOFF]
	ldr	w10, [x22]
	sub	w9, w9, w10
	cmp	w8, w9
	cset	w0, ls
	bl	_av_assert0
	ldr	w10, [x21]
	ldr	w8, [x19]
	ldr	w9, [x22]
	add	w8, w8, w9
	sub	w9, w10, w8
	cmp	w9, w20
	b.hs	LBB0_2
LBB0_1:
Lloh4:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh5:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh6:
	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
LBB0_2:
	add	w0, w8, w20
	mov	x21, x19
	ldr	x9, [x21, #16]!
	cbz	x9, LBB0_5
; %bb.3:
	ldr	x23, [x19, #8]
	ldr	x8, [x9, #8]
	cbz	x23, LBB0_9
; %bb.4:
	sub	x8, x23, x8
	asr	x24, x8, #2
	sub	w8, w10, w0
	cmp	x24, x8
	mov	x8, x23
	b.hi	LBB0_1
	b	LBB0_10
LBB0_5:
	bl	_av_buffer_alloc
	str	x0, [x21]
	cbz	x0, LBB0_1
; %bb.6:
	ldr	w2, [x19]
	cbz	w2, LBB0_8
; %bb.7:
	ldr	x0, [x0, #8]
	ldr	x1, [x19, #8]
	bl	_memcpy
	ldr	x0, [x19, #16]
LBB0_8:
	ldr	x8, [x0, #8]
	b	LBB0_13
LBB0_9:
	mov	x24, #0
	str	x8, [x19, #8]
LBB0_10:
	add	x1, x24, w0, sxtw
	ldrsw	x9, [x9]
	cmp	x1, x9
	b.ls	LBB0_14
; %bb.11:
	mov	x0, x21
                                        ; kill: def $w1 killed $w1 killed $x1
	bl	_av_buffer_realloc
	tbnz	w0, #31, LBB0_16
; %bb.12:
	ldr	x8, [x19, #16]
	ldr	x8, [x8, #8]
	add	x8, x8, x24, lsl #2
LBB0_13:
	str	x8, [x19, #8]
LBB0_14:
	ldr	w9, [x19]
	add	w9, w9, w20
	str	w9, [x19]
	add	x0, x8, w9, uxtw #2
	ldr	w2, [x22]
	mov	w1, #0
	bl	_memset
	mov	w0, #0
LBB0_15:
	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_16:
	str	x23, [x19, #8]
	b	LBB0_15
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_INT_MAX,4,2                    ; @INT_MAX
	.comm	_AV_INPUT_BUFFER_PADDING_SIZE,4,2 ; @AV_INPUT_BUFFER_PADDING_SIZE
	.comm	_ENOMEM,4,2                     ; @ENOMEM
.subsections_via_symbols
