	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function v408_encode_frame
_v408_encode_frame:                     ## @v408_encode_frame
	.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
	subq	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r14
	movq	%rdx, -64(%rbp)                 ## 8-byte Spill
	movq	%rdi, %rbx
	movl	(%rdi), %edx
	imull	4(%rdi), %edx
	shll	$2, %edx
	movq	%rsi, -56(%rbp)                 ## 8-byte Spill
	xorl	%ecx, %ecx
	callq	_ff_alloc_packet2
	testl	%eax, %eax
	js	LBB0_13
## %bb.1:
	movq	%r14, -80(%rbp)                 ## 8-byte Spill
	movl	4(%rbx), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	testl	%eax, %eax
	movq	-64(%rbp), %r8                  ## 8-byte Reload
	jle	LBB0_12
## %bb.2:
	movq	%rbx, %r11
	movq	(%r8), %rax
	movq	24(%rax), %rcx
	movq	16(%rax), %r13
	movq	(%rax), %r12
	movq	8(%rax), %r9
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rbx
	movl	(%r11), %r10d
	movq	_AV_CODEC_ID_AYUV@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movl	%r10d, %eax
	andl	$-2, %eax
	xorl	%r14d, %r14d
	movq	%r11, -88(%rbp)                 ## 8-byte Spill
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	8(%r8), %rdx
	movslq	(%rdx), %rsi
	leaq	(%r12,%rsi,8), %r12
	movslq	4(%rdx), %rsi
	leaq	(%r9,%rsi,8), %r9
	movslq	8(%rdx), %rsi
	leaq	(%r13,%rsi,8), %r13
	movslq	12(%rdx), %rdx
	leaq	(%rcx,%rdx,8), %rcx
	incl	%r14d
	cmpl	-44(%rbp), %r14d                ## 4-byte Folded Reload
	je	LBB0_12
LBB0_3:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_7 Depth 2
	testl	%r10d, %r10d
	jle	LBB0_11
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	8(%r11), %rdx
	cmpl	$1, %r10d
	jne	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	xorl	%r15d, %r15d
	testb	$1, %r10b
	je	LBB0_11
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_3 Depth=1
	movq	%rdx, -96(%rbp)                 ## 8-byte Spill
	cmpq	-72(%rbp), %rdx                 ## 8-byte Folded Reload
	movq	%r9, %rdi
	cmoveq	%r13, %rdi
	movq	%r12, %rsi
	cmoveq	%r9, %rsi
	movq	%r13, %r11
	cmoveq	%r12, %r11
	xorl	%r15d, %r15d
	.p2align	4, 0x90
LBB0_7:                                 ##   Parent Loop BB0_3 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	(%rdi,%r15,8), %r8
	movq	%r8, (%rbx)
	movq	(%rsi,%r15,8), %rdx
	movq	%rdx, 8(%rbx)
	movq	(%r11,%r15,8), %rdx
	movq	%rdx, 16(%rbx)
	movq	(%rcx,%r15,8), %rdx
	movq	%rdx, 24(%rbx)
	movq	8(%rdi,%r15,8), %rdx
	movq	%rdx, 32(%rbx)
	movq	8(%rsi,%r15,8), %rdx
	movq	%rdx, 40(%rbx)
	movq	8(%r11,%r15,8), %rdx
	movq	%rdx, 48(%rbx)
	movq	8(%rcx,%r15,8), %rdx
	movq	%rdx, 56(%rbx)
	addq	$64, %rbx
	addq	$2, %r15
	cmpq	%r15, %rax
	jne	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	-64(%rbp), %r8                  ## 8-byte Reload
	movq	-88(%rbp), %r11                 ## 8-byte Reload
	movq	-96(%rbp), %rdx                 ## 8-byte Reload
	testb	$1, %r10b
	je	LBB0_11
LBB0_10:                                ##   in Loop: Header=BB0_3 Depth=1
	cmpq	-72(%rbp), %rdx                 ## 8-byte Folded Reload
	movq	%r9, %rdx
	cmoveq	%r13, %rdx
	movq	%r12, %rsi
	cmoveq	%r9, %rsi
	movq	%r13, %rdi
	cmoveq	%r12, %rdi
	movq	(%rdx,%r15,8), %rdx
	movq	%rdx, (%rbx)
	movq	(%rsi,%r15,8), %rdx
	movq	%rdx, 8(%rbx)
	movq	(%rdi,%r15,8), %rdx
	movq	%rdx, 16(%rbx)
	movq	(%rcx,%r15,8), %rdx
	movq	%rdx, 24(%rbx)
	addq	$32, %rbx
	jmp	LBB0_11
LBB0_12:
	movq	_AV_PKT_FLAG_KEY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	orl	%eax, 8(%rcx)
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	movl	$1, (%rax)
	xorl	%eax, %eax
LBB0_13:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_CODEC_ID_AYUV,8,3           ## @AV_CODEC_ID_AYUV
	.comm	_AV_PKT_FLAG_KEY,4,2            ## @AV_PKT_FLAG_KEY
	.no_dead_strip	_v408_encode_frame
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function v408_encode_frame
_v408_encode_frame:                     ; @v408_encode_frame
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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	x19, x3
	mov	x21, x2
	mov	x20, x1
	mov	x22, x0
	ldp	w8, w9, [x0]
	mul	w8, w8, w9
	lsl	w2, w8, #2
	mov	w3, #0
	bl	_ff_alloc_packet2
	tbnz	w0, #31, LBB0_8
; %bb.1:
	ldr	w8, [x22, #4]
	cmp	w8, #1
	b.lt	LBB0_7
; %bb.2:
	mov	w9, #0
	ldr	x13, [x21]
	ldp	x11, x10, [x13, #16]
	ldp	x13, x12, [x13]
	ldr	x14, [x20]
	ldr	w15, [x22]
Lloh0:
	adrp	x16, _AV_CODEC_ID_AYUV@GOTPAGE
Lloh1:
	ldr	x16, [x16, _AV_CODEC_ID_AYUV@GOTPAGEOFF]
Lloh2:
	ldr	x16, [x16]
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	x17, [x21, #8]
	ldpsw	x0, x1, [x17]
	add	x13, x13, x0, lsl #3
	add	x12, x12, x1, lsl #3
	ldpsw	x0, x17, [x17, #8]
	add	x11, x11, x0, lsl #3
	add	x10, x10, x17, lsl #3
	add	w9, w9, #1
	cmp	w9, w8
	b.eq	LBB0_7
LBB0_4:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_6 Depth 2
	cmp	w15, #1
	b.lt	LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x17, [x22, #8]
	cmp	x17, x16
	csel	x17, x11, x12, eq
	csel	x0, x12, x13, eq
	csel	x1, x13, x11, eq
	mov	x2, x15
	mov	x3, x10
LBB0_6:                                 ;   Parent Loop BB0_4 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x4, [x17], #8
	str	x4, [x14]
	ldr	x4, [x0], #8
	str	x4, [x14, #8]
	ldr	x4, [x1], #8
	str	x4, [x14, #16]
	ldr	x4, [x3], #8
	str	x4, [x14, #24]
	add	x14, x14, #32
	subs	x2, x2, #1
	b.ne	LBB0_6
	b	LBB0_3
LBB0_7:
	mov	w0, #0
Lloh3:
	adrp	x8, _AV_PKT_FLAG_KEY@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AV_PKT_FLAG_KEY@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	ldr	w9, [x20, #8]
	orr	w8, w9, w8
	str	w8, [x20, #8]
	mov	w8, #1
	str	w8, [x19]
LBB0_8:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_CODEC_ID_AYUV,8,3           ; @AV_CODEC_ID_AYUV
	.comm	_AV_PKT_FLAG_KEY,4,2            ; @AV_PKT_FLAG_KEY
	.no_dead_strip	_v408_encode_frame
.subsections_via_symbols
