	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function alloc_frame_empty
_alloc_frame_empty:                     ## @alloc_frame_empty
	.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
	movl	%edx, %r14d
	movl	%esi, %r12d
	movl	%edi, %r15d
	xorl	%eax, %eax
	callq	_av_frame_alloc
	movq	%rax, -40(%rbp)
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	movl	%r15d, (%rax)
	movl	%r12d, 4(%rax)
	movl	%r14d, 8(%rax)
	movq	%rax, %rdi
	movl	$32, %esi
	callq	_av_frame_get_buffer
	testq	%rax, %rax
	js	LBB0_3
## %bb.4:
	movq	_AV_PIX_FMT_RGB24@GOTPCREL(%rip), %rax
	cmpl	%r15d, (%rax)
	je	LBB0_6
## %bb.5:
	movq	_AV_PIX_FMT_RGBA@GOTPCREL(%rip), %rax
	cmpl	%r15d, (%rax)
	je	LBB0_6
## %bb.7:
	movq	_AV_PIX_FMT_YUV420P@GOTPCREL(%rip), %rax
	movq	_AV_PIX_FMT_YUVA420P@GOTPCREL(%rip), %rcx
	movl	%r14d, %edx
	shrl	$31, %edx
	addl	%r14d, %edx
	sarl	%edx
	cmpl	%r15d, (%rcx)
	movl	%r14d, %r12d
	cmovel	%edx, %r12d
	cmpl	%r15d, (%rax)
	cmovel	%edx, %r12d
	movq	16(%rbx), %rax
	movq	24(%rbx), %rcx
	movq	(%rcx), %rdi
	movl	(%rax), %edx
	imull	%r14d, %edx
	movl	$16, %esi
	callq	_memset
	movq	16(%rbx), %rax
	movq	24(%rbx), %rcx
	movq	8(%rcx), %rdi
	movl	4(%rax), %edx
	imull	%r12d, %edx
	movl	$128, %esi
	callq	_memset
	movq	16(%rbx), %rax
	movq	24(%rbx), %rcx
	movq	16(%rcx), %rdi
	imull	8(%rax), %r12d
	movl	$128, %esi
	movl	%r12d, %edx
	callq	_memset
	movq	24(%rbx), %rax
	movq	24(%rax), %rdi
	testq	%rdi, %rdi
	je	LBB0_10
## %bb.8:
	movq	16(%rbx), %rax
	imull	12(%rax), %r14d
	jmp	LBB0_9
LBB0_1:
	xorl	%ebx, %ebx
	jmp	LBB0_10
LBB0_3:
	leaq	-40(%rbp), %rdi
	callq	_av_frame_free
	xorl	%ebx, %ebx
	jmp	LBB0_10
LBB0_6:
	movq	16(%rbx), %rax
	movq	24(%rbx), %rcx
	movq	(%rcx), %rdi
	imull	(%rax), %r14d
LBB0_9:
	xorl	%esi, %esi
	movl	%r14d, %edx
	callq	_memset
LBB0_10:
	movq	%rbx, %rax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_PIX_FMT_RGB24,4,2           ## @AV_PIX_FMT_RGB24
	.comm	_AV_PIX_FMT_RGBA,4,2            ## @AV_PIX_FMT_RGBA
	.comm	_AV_PIX_FMT_YUV420P,4,2         ## @AV_PIX_FMT_YUV420P
	.comm	_AV_PIX_FMT_YUVA420P,4,2        ## @AV_PIX_FMT_YUVA420P
	.no_dead_strip	_alloc_frame_empty
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function alloc_frame_empty
_alloc_frame_empty:                     ; @alloc_frame_empty
	.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	x20, x2
	mov	x22, x1
	mov	x21, x0
	bl	_av_frame_alloc
	mov	x19, x0
	str	x0, [sp, #8]
	cbz	x0, LBB0_8
; %bb.1:
	stp	w21, w22, [x19]
	str	w20, [x19, #8]
	mov	x0, x19
	mov	w1, #32
	bl	_av_frame_get_buffer
	tbnz	x0, #63, LBB0_4
; %bb.2:
Lloh0:
	adrp	x8, _AV_PIX_FMT_RGB24@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AV_PIX_FMT_RGB24@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _AV_PIX_FMT_RGBA@GOTPAGE
Lloh4:
	ldr	x9, [x9, _AV_PIX_FMT_RGBA@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	cmp	w8, w21
	ccmp	w9, w21, #4, ne
	b.ne	LBB0_5
; %bb.3:
	ldp	x9, x8, [x19, #16]
	ldr	x0, [x8]
	ldr	w8, [x9]
	b	LBB0_7
LBB0_4:
	add	x0, sp, #8
	bl	_av_frame_free
	mov	x19, #0
	b	LBB0_8
LBB0_5:
Lloh6:
	adrp	x8, _AV_PIX_FMT_YUV420P@GOTPAGE
Lloh7:
	ldr	x8, [x8, _AV_PIX_FMT_YUV420P@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
Lloh9:
	adrp	x9, _AV_PIX_FMT_YUVA420P@GOTPAGE
Lloh10:
	ldr	x9, [x9, _AV_PIX_FMT_YUVA420P@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	cmp	w20, #0
	cinc	w10, w20, lt
	cmp	w9, w21
	ccmp	w8, w21, #4, ne
	asr	w8, w10, #1
	csel	w21, w8, w20, eq
	ldp	x9, x8, [x19, #16]
	ldr	x0, [x8]
	ldr	w8, [x9]
	mul	w2, w8, w20
	mov	w1, #16
	bl	_memset
	ldp	x9, x8, [x19, #16]
	ldr	x0, [x8, #8]
	ldr	w8, [x9, #4]
	mul	w2, w8, w21
	mov	w1, #128
	bl	_memset
	ldp	x9, x8, [x19, #16]
	ldr	x0, [x8, #16]
	ldr	w8, [x9, #8]
	mul	w2, w8, w21
	mov	w1, #128
	bl	_memset
	ldr	x8, [x19, #24]
	ldr	x0, [x8, #24]
	cbz	x0, LBB0_8
; %bb.6:
	ldr	x8, [x19, #16]
	ldr	w8, [x8, #12]
LBB0_7:
	mul	w2, w8, w20
	mov	w1, #0
	bl	_memset
LBB0_8:
	mov	x0, x19
	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	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_PIX_FMT_RGB24,4,2           ; @AV_PIX_FMT_RGB24
	.comm	_AV_PIX_FMT_RGBA,4,2            ; @AV_PIX_FMT_RGBA
	.comm	_AV_PIX_FMT_YUV420P,4,2         ; @AV_PIX_FMT_YUV420P
	.comm	_AV_PIX_FMT_YUVA420P,4,2        ; @AV_PIX_FMT_YUVA420P
	.no_dead_strip	_alloc_frame_empty
.subsections_via_symbols
