	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ff_mpv_common_frame_size_change ## -- Begin function ff_mpv_common_frame_size_change
	.p2align	4, 0x90
_ff_mpv_common_frame_size_change:       ## @ff_mpv_common_frame_size_change
	.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
	cmpl	$0, 80(%rdi)
	je	LBB0_36
## %bb.1:
	movq	%rdi, %r12
	cmpl	$2, (%rdi)
	jl	LBB0_7
## %bb.2:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	32(%r12), %rax
	movq	(%rax,%rbx,8), %rdi
	callq	_free_duplicate_context
	incq	%rbx
	movslq	(%r12), %rax
	cmpq	%rax, %rbx
	jl	LBB0_3
## %bb.4:
	cmpl	$2, %eax
	jl	LBB0_8
## %bb.5:
	movl	$1, %r14d
	movl	$8, %ebx
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	32(%r12), %rdi
	addq	%rbx, %rdi
	callq	_av_freep
	incq	%r14
	movslq	(%r12), %rax
	addq	$8, %rbx
	cmpq	%rax, %r14
	jl	LBB0_6
	jmp	LBB0_8
LBB0_36:
	movq	_EINVAL@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_7:
	movq	%r12, %rdi
	callq	_free_duplicate_context
LBB0_8:
	movq	%r12, %rdi
	callq	_free_context_frame
	movq	72(%r12), %rax
	testq	%rax, %rax
	je	LBB0_12
## %bb.9:
	movq	_MAX_PICTURE_COUNT@GOTPCREL(%rip), %rcx
	cmpl	$0, (%rcx)
	jle	LBB0_12
## %bb.10:
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movl	$1, (%rax,%rdx,4)
	incq	%rdx
	movslq	(%rcx), %rsi
	cmpq	%rsi, %rdx
	jl	LBB0_11
LBB0_12:
	xorps	%xmm0, %xmm0
	movups	%xmm0, 56(%r12)
	movq	8(%r12), %rax
	movq	_AV_CODEC_ID_MPEG2VIDEO@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_15
## %bb.13:
	cmpl	$0, 52(%r12)
	je	LBB0_14
LBB0_15:
	movl	20(%r12), %esi
	leal	15(%rsi), %ecx
	leal	30(%rsi), %eax
	testl	%ecx, %ecx
	cmovnsl	%ecx, %eax
	sarl	$4, %eax
LBB0_16:
	movl	%eax, 16(%r12)
	movq	40(%r12), %rdi
	testq	%rdi, %rdi
	jne	LBB0_18
## %bb.17:
	testl	%esi, %esi
	je	LBB0_19
LBB0_18:
	movl	48(%r12), %ecx
                                        ## kill: def $esi killed $esi killed $rsi
	xorl	%edx, %edx
	callq	_av_image_check_size
	testl	%eax, %eax
	js	LBB0_30
LBB0_19:
	movq	%r12, %rdi
	callq	_init_context_frame
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_31
## %bb.20:
	movq	32(%r12), %rdi
	xorl	%r14d, %r14d
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movq	32(%r12), %rax
	movq	%r12, (%rax)
	cmpq	$0, 40(%r12)
	je	LBB0_35
## %bb.21:
	cmpl	$0, 20(%r12)
	je	LBB0_35
## %bb.22:
	movl	(%r12), %r15d
	cmpl	$2, %r15d
	jl	LBB0_32
## %bb.23:
	movl	%r15d, %ebx
	shrl	%ebx
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_24:                                ## =>This Inner Loop Header: Depth=1
	testq	%r13, %r13
	je	LBB0_25
## %bb.28:                              ##   in Loop: Header=BB0_24 Depth=1
	movq	%r12, %rdi
	movl	$88, %esi
	callq	_av_memdup
	movq	32(%r12), %rcx
	movq	%rax, (%rcx,%r13,8)
	movq	32(%r12), %rax
	movq	(%rax,%r13,8), %rdi
	testq	%rdi, %rdi
	jne	LBB0_26
	jmp	LBB0_29
LBB0_25:                                ##   in Loop: Header=BB0_24 Depth=1
	movq	32(%r12), %rax
	movq	(%rax), %rdi
LBB0_26:                                ##   in Loop: Header=BB0_24 Depth=1
	callq	_init_duplicate_context
	testl	%eax, %eax
	js	LBB0_30
## %bb.27:                              ##   in Loop: Header=BB0_24 Depth=1
	movl	16(%r12), %ecx
	movl	%r13d, %eax
	imull	%ecx, %eax
	addl	%ebx, %eax
	cltd
	idivl	%r15d
	movq	32(%r12), %rdx
	movq	(%rdx,%r13,8), %rsi
	movl	%eax, 24(%rsi)
	incq	%r13
	movl	%r13d, %eax
	imull	%ecx, %eax
	addl	%ebx, %eax
	cltd
	idivl	%r15d
	movl	%eax, 28(%rsi)
	cmpq	%r13, %r15
	jne	LBB0_24
	jmp	LBB0_34
LBB0_14:
	movl	20(%r12), %esi
	leal	31(%rsi), %ecx
	leal	62(%rsi), %eax
	testl	%ecx, %ecx
	cmovnsl	%ecx, %eax
	sarl	$5, %eax
	addl	%eax, %eax
	jmp	LBB0_16
LBB0_32:
	movq	%r12, %rdi
	callq	_init_duplicate_context
	testl	%eax, %eax
	js	LBB0_30
## %bb.33:
	movl	$0, 24(%r12)
	movl	16(%r12), %eax
	movl	%eax, 28(%r12)
LBB0_34:
	movl	%r15d, (%r12)
	jmp	LBB0_35
LBB0_29:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
LBB0_30:
	movl	%eax, %r14d
LBB0_31:
	movq	%r12, %rdi
	callq	_ff_mpv_common_end
LBB0_35:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_MAX_PICTURE_COUNT,4,2          ## @MAX_PICTURE_COUNT
	.comm	_AV_CODEC_ID_MPEG2VIDEO,8,3     ## @AV_CODEC_ID_MPEG2VIDEO
	.comm	_ENOMEM,4,2                     ## @ENOMEM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ff_mpv_common_frame_size_change ; -- Begin function ff_mpv_common_frame_size_change
	.p2align	2
_ff_mpv_common_frame_size_change:       ; @ff_mpv_common_frame_size_change
	.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	w8, [x0, #80]
	cbz	w8, LBB0_7
; %bb.1:
	mov	x19, x0
	ldr	w8, [x0]
	cmp	w8, #2
	b.lt	LBB0_8
; %bb.2:
	mov	x20, #0
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #32]
	ldr	x0, [x8, x20, lsl #3]
	bl	_free_duplicate_context
	add	x20, x20, #1
	ldrsw	x8, [x19]
	cmp	x20, x8
	b.lt	LBB0_3
; %bb.4:
	cmp	w8, #2
	b.lt	LBB0_9
; %bb.5:
	mov	w20, #1
	mov	w21, #8
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #32]
	add	x0, x8, x21
	bl	_av_freep
	add	x20, x20, #1
	ldrsw	x8, [x19]
	add	x21, x21, #8
	cmp	x20, x8
	b.lt	LBB0_6
	b	LBB0_9
LBB0_7:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	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_8:
	mov	x0, x19
	bl	_free_duplicate_context
LBB0_9:
	mov	x0, x19
	bl	_free_context_frame
	ldr	x8, [x19, #72]
Lloh3:
	adrp	x9, _MAX_PICTURE_COUNT@GOTPAGE
Lloh4:
	ldr	x9, [x9, _MAX_PICTURE_COUNT@GOTPAGEOFF]
	ldr	w10, [x9]
	cmp	x8, #0
	ccmp	w10, #1, #8, ne
	b.lt	LBB0_12
; %bb.10:
	mov	x10, #0
	mov	w11, #1
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	str	w11, [x8, x10, lsl #2]
	add	x10, x10, #1
	ldrsw	x12, [x9]
	cmp	x10, x12
	b.lt	LBB0_11
LBB0_12:
	stp	xzr, xzr, [x19, #56]
	ldr	x8, [x19, #8]
Lloh5:
	adrp	x9, _AV_CODEC_ID_MPEG2VIDEO@GOTPAGE
Lloh6:
	ldr	x9, [x9, _AV_CODEC_ID_MPEG2VIDEO@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_14
; %bb.13:
	ldr	w8, [x19, #52]
	cbz	w8, LBB0_28
LBB0_14:
	ldr	w1, [x19, #20]
	add	w8, w1, #15
	add	w9, w1, #30
	cmp	w8, #0
	csel	w8, w9, w8, lt
	asr	w8, w8, #4
LBB0_15:
	str	w8, [x19, #16]
	ldr	x0, [x19, #40]
	cbnz	x0, LBB0_17
; %bb.16:
	cbz	w1, LBB0_18
LBB0_17:
	ldr	w3, [x19, #48]
	mov	w2, #0
	bl	_av_image_check_size
	tbnz	w0, #31, LBB0_34
LBB0_18:
	mov	x0, x19
	bl	_init_context_frame
	mov	x20, x0
	cbnz	w0, LBB0_35
; %bb.19:
	ldr	x0, [x19, #32]
	mov	w1, #0
	mov	w2, #8
	bl	_memset
	ldp	x8, x9, [x19, #32]
	str	x19, [x8]
	cbz	x9, LBB0_29
; %bb.20:
	ldr	w8, [x19, #20]
	cbz	w8, LBB0_29
; %bb.21:
	ldr	w21, [x19]
	cmp	w21, #2
	b.lt	LBB0_30
; %bb.22:
	mov	x22, #0
	lsr	w23, w21, #1
LBB0_23:                                ; =>This Inner Loop Header: Depth=1
	cbz	x22, LBB0_26
; %bb.24:                               ;   in Loop: Header=BB0_23 Depth=1
	mov	x0, x19
	mov	w1, #88
	bl	_av_memdup
	ldr	x8, [x19, #32]
	lsl	x9, x22, #3
	str	x0, [x8, x9]
	ldr	x8, [x19, #32]
	ldr	x0, [x8, x9]
	cbz	x0, LBB0_33
; %bb.25:                               ;   in Loop: Header=BB0_23 Depth=1
	bl	_init_duplicate_context
	tbz	w0, #31, LBB0_27
	b	LBB0_34
LBB0_26:                                ;   in Loop: Header=BB0_23 Depth=1
	ldr	x8, [x19, #32]
	ldr	x0, [x8]
	bl	_init_duplicate_context
	tbnz	w0, #31, LBB0_34
LBB0_27:                                ;   in Loop: Header=BB0_23 Depth=1
	ldr	w8, [x19, #16]
	madd	w9, w8, w22, w23
	sdiv	w9, w9, w21
	ldr	x10, [x19, #32]
	ldr	x10, [x10, x22, lsl #3]
	add	x22, x22, #1
	madd	w8, w8, w22, w23
	sdiv	w8, w8, w21
	stp	w9, w8, [x10, #24]
	cmp	x21, x22
	b.ne	LBB0_23
	b	LBB0_32
LBB0_28:
	ldr	w1, [x19, #20]
	add	w8, w1, #31
	add	w9, w1, #62
	cmp	w8, #0
	csel	w8, w9, w8, lt
	asr	w8, w8, #5
	lsl	w8, w8, #1
	b	LBB0_15
LBB0_29:
	mov	w20, #0
	b	LBB0_36
LBB0_30:
	mov	x0, x19
	bl	_init_duplicate_context
	tbnz	w0, #31, LBB0_34
; %bb.31:
	ldr	w8, [x19, #16]
	stp	wzr, w8, [x19, #24]
LBB0_32:
	mov	w20, #0
	str	w21, [x19]
	b	LBB0_36
LBB0_33:
Lloh8:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	bl	_AVERROR
LBB0_34:
	mov	x20, x0
LBB0_35:
	mov	x0, x19
	bl	_ff_mpv_common_end
LBB0_36:
	mov	x0, x20
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_MAX_PICTURE_COUNT,4,2          ; @MAX_PICTURE_COUNT
	.comm	_AV_CODEC_ID_MPEG2VIDEO,8,3     ; @AV_CODEC_ID_MPEG2VIDEO
	.comm	_ENOMEM,4,2                     ; @ENOMEM
.subsections_via_symbols
