	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function decode_frame
_decode_frame:                          ## @decode_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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %rbx
	movq	%rsi, %r15
	movq	%rdi, %r13
	movq	16(%rdi), %rax
	cmpq	$0, 24(%rax)
	je	LBB0_9
## %bb.1:
	movq	%rax, %r14
	movq	16(%rax), %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	callq	_avcodec_decode_video2
	movl	%eax, %r12d
	testl	%eax, %eax
	js	LBB0_8
## %bb.2:
	cmpl	$0, (%rbx)
	je	LBB0_8
## %bb.3:
	movl	(%r13), %eax
	cmpl	(%r15), %eax
	jg	LBB0_8
## %bb.4:
	movl	4(%r15), %ebx
	subl	4(%r13), %ebx
	jl	LBB0_8
## %bb.5:
	movl	36(%r15), %edi
	leaq	-68(%rbp), %rsi
	leaq	-52(%rbp), %rdx
	callq	_av_pix_fmt_get_chroma_sub_sample
	movq	8(%r15), %rdx
	movq	24(%r15), %rax
	movslq	(%rdx), %rcx
	movslq	%ebx, %rsi
	imulq	%rcx, %rsi
	addq	%rsi, (%rax)
	movq	16(%rax), %rsi
	testq	%rsi, %rsi
	je	LBB0_7
## %bb.6:
	movb	-52(%rbp), %cl
	sarl	%cl, %ebx
	movq	4(%rdx), %xmm0                  ## xmm0 = mem[0],zero
	movd	%ebx, %xmm1
	pshufd	$80, %xmm1, %xmm1               ## xmm1 = xmm1[0,0,1,1]
	pmulld	%xmm0, %xmm1
	pmovsxdq	%xmm1, %xmm0
	movq	%rsi, %xmm1
	movq	8(%rax), %xmm2                  ## xmm2 = mem[0],zero
	punpcklqdq	%xmm1, %xmm2            ## xmm2 = xmm2[0],xmm1[0]
	paddq	%xmm0, %xmm2
	movdqu	%xmm2, 8(%rax)
LBB0_7:
	movl	(%r13), %eax
	movl	%eax, (%r15)
	movl	4(%r13), %eax
	movl	%eax, 4(%r15)
LBB0_8:
	movq	16(%r14), %rax
	movl	(%rax), %eax
	movl	%eax, 8(%r13)
	jmp	LBB0_21
LBB0_9:
	movq	%rax, %r14
	movl	(%rcx), %r12d
	movl	(%r13), %esi
	addl	%esi, %esi
	movl	%r12d, %eax
	cltd
	idivl	%esi
	imull	4(%r13), %esi
	cmpl	%esi, %r12d
	jge	LBB0_11
## %bb.10:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r13, %rdi
	callq	_av_log
	movq	_AVERROR_INVALIDDATA@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	jmp	LBB0_21
LBB0_11:
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	movq	8(%rcx), %rbx
	movq	%r13, %rdi
	movq	%r15, %rsi
	xorl	%edx, %edx
	callq	_ff_get_buffer
	testl	%eax, %eax
	js	LBB0_12
## %bb.13:
	movq	%rbx, %rsi
	movq	_AV_PICTURE_TYPE_I@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 32(%r15)
	movl	$1, 16(%r15)
	cmpq	$0, 8(%r14)
	movl	4(%r13), %eax
	movl	%r12d, -48(%rbp)                ## 4-byte Spill
	je	LBB0_17
## %bb.14:
	cmpl	$2, %eax
	jl	LBB0_20
## %bb.15:
	movq	%r14, %rbx
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	subl	%eax, %ecx
	movl	(%r13), %edx
	imull	%edx, %ecx
	movslq	%ecx, %rax
	leaq	(%rsi,%rax,4), %r12
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_16:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r15), %rax
	movq	24(%r15), %rcx
	movl	(%rbx), %esi
	addl	%r14d, %esi
	movslq	(%rax), %rax
	movslq	%esi, %rdi
	imulq	%rax, %rdi
	addq	(%rcx), %rdi
	addl	%edx, %edx
	movq	%r12, %rsi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_memcpy
	movq	8(%r15), %rax
	movq	24(%r15), %rcx
	xorl	%edx, %edx
	cmpl	$0, (%rbx)
	sete	%dl
	orl	%r14d, %edx
	movslq	(%rax), %rax
	movslq	%edx, %rdi
	imulq	%rax, %rdi
	addq	(%rcx), %rdi
	movl	(%r13), %edx
	movl	%edx, %eax
	imull	-44(%rbp), %eax                 ## 4-byte Folded Reload
	cltq
	leaq	(%r12,%rax,4), %rsi
	addq	$16, %rsi
	addl	%edx, %edx
	callq	_memcpy
	movslq	(%r13), %rdx
	leaq	(%r12,%rdx,8), %r12
	addl	$2, %r14d
	movl	4(%r13), %eax
	decl	%eax
	cmpl	%eax, %r14d
	jl	LBB0_16
	jmp	LBB0_20
LBB0_12:
	movl	%eax, %r12d
	jmp	LBB0_21
LBB0_17:
	testl	%eax, %eax
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	jle	LBB0_20
## %bb.18:
	movl	(%r13), %edx
	subl	%eax, %ecx
	imull	%edx, %ecx
	addl	%ecx, %ecx
	movslq	%ecx, %rax
	leaq	(%rsi,%rax,4), %r14
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r15), %rax
	movq	24(%r15), %rcx
	movslq	(%rax), %rdi
	movslq	%ebx, %rbx
	imulq	%rbx, %rdi
	addq	(%rcx), %rdi
	addl	%edx, %edx
	movq	%r14, %rsi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_memcpy
	movslq	(%r13), %rdx
	leaq	(%r14,%rdx,8), %r14
	incl	%ebx
	cmpl	4(%r13), %ebx
	jl	LBB0_19
LBB0_20:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	$1, (%rax)
	movl	-48(%rbp), %r12d                ## 4-byte Reload
LBB0_21:
	movl	%r12d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"packet too small\n"

	.comm	_AVERROR_INVALIDDATA,4,2        ## @AVERROR_INVALIDDATA
	.comm	_AV_PICTURE_TYPE_I,4,2          ## @AV_PICTURE_TYPE_I
	.no_dead_strip	_decode_frame
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function decode_frame
_decode_frame:                          ; @decode_frame
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x22, x2
	mov	x21, x1
	mov	x19, x0
	ldr	x24, [x0, #16]
	ldr	x8, [x24, #24]
	cbz	x8, LBB0_9
; %bb.1:
	ldr	x0, [x24, #16]
	mov	x1, x21
	mov	x2, x22
	bl	_avcodec_decode_video2
	mov	x20, x0
	tbnz	w0, #31, LBB0_8
; %bb.2:
	ldr	w8, [x22]
	cbz	w8, LBB0_8
; %bb.3:
	ldr	w8, [x19]
	ldr	w9, [x21]
	cmp	w8, w9
	b.gt	LBB0_8
; %bb.4:
	ldr	w8, [x19, #4]
	ldr	w9, [x21, #4]
	subs	w22, w9, w8
	b.lt	LBB0_8
; %bb.5:
	ldr	w0, [x21, #36]
	add	x1, sp, #12
	add	x2, sp, #8
	bl	_av_pix_fmt_get_chroma_sub_sample
	ldr	x9, [x21, #8]
	ldrsw	x10, [x9]
	sxtw	x11, w22
	ldr	x8, [x21, #24]
	ldr	x12, [x8]
	madd	x10, x10, x11, x12
	str	x10, [x8]
	ldr	x10, [x8, #16]
	cbz	x10, LBB0_7
; %bb.6:
	ldr	w11, [sp, #8]
	asr	w11, w22, w11
	ldur	d0, [x9, #4]
	dup.2s	v1, w11
	mul.2s	v0, v1, v0
	ldr	d1, [x8, #8]
	mov.d	v1[1], x10
	saddw.2d	v0, v1, v0
	stur	q0, [x8, #8]
LBB0_7:
	ldr	d0, [x19]
	str	d0, [x21]
LBB0_8:
	ldr	x8, [x24, #16]
	ldr	w8, [x8]
	str	w8, [x19, #8]
	b	LBB0_21
LBB0_9:
	ldr	w20, [x3]
	ldp	w8, w9, [x19]
	lsl	w25, w8, #1
	mul	w8, w9, w25
	cmp	w20, w8
	b.ge	LBB0_11
; %bb.10:
Lloh0:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x2, l_.str@PAGE
Lloh4:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_av_log
Lloh5:
	adrp	x8, _AVERROR_INVALIDDATA@GOTPAGE
Lloh6:
	ldr	x8, [x8, _AVERROR_INVALIDDATA@GOTPAGEOFF]
Lloh7:
	ldr	w20, [x8]
	b	LBB0_21
LBB0_11:
	ldr	x23, [x3, #8]
	mov	x0, x19
	mov	x1, x21
	mov	w2, #0
	bl	_ff_get_buffer
	tbnz	w0, #31, LBB0_16
; %bb.12:
Lloh8:
	adrp	x8, _AV_PICTURE_TYPE_I@GOTPAGE
Lloh9:
	ldr	x8, [x8, _AV_PICTURE_TYPE_I@GOTPAGEOFF]
	sdiv	w25, w20, w25
Lloh10:
	ldr	w8, [x8]
	str	w8, [x21, #32]
	mov	w8, #1
	str	w8, [x21, #16]
	ldr	x8, [x24, #8]
	ldr	w9, [x19, #4]
	cbz	x8, LBB0_17
; %bb.13:
	cmp	w9, #2
	b.lt	LBB0_20
; %bb.14:
	mov	w26, #0
	sub	w9, w25, w9
	ldr	w8, [x19]
	mul	w9, w9, w8
	add	x23, x23, w9, sxtw #2
LBB0_15:                                ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x21, #24]
	ldr	x9, [x9]
	ldr	w10, [x24]
	add	w10, w26, w10
	ldr	x11, [x21, #8]
	ldrsw	x11, [x11]
	sxtw	x10, w10
	madd	x0, x11, x10, x9
	lsl	w2, w8, #1
	mov	x1, x23
	bl	_memcpy
	ldr	x8, [x21, #24]
	ldr	x8, [x8]
	ldr	w9, [x24]
	cmp	w9, #0
	cset	w9, eq
	orr	w9, w26, w9
	ldr	x10, [x21, #8]
	ldrsw	x10, [x10]
	sxtw	x9, w9
	madd	x0, x9, x10, x8
	ldr	w8, [x19]
	mul	w9, w8, w25
	add	x9, x23, w9, sxtw #2
	add	x1, x9, #16
	lsl	w2, w8, #1
	bl	_memcpy
	ldp	w8, w9, [x19]
                                        ; kill: def $w8 killed $w8 def $x8
	sxtw	x8, w8
	add	x23, x23, x8, lsl #3
	add	w26, w26, #2
	sub	w9, w9, #1
	cmp	w26, w9
	b.lt	LBB0_15
	b	LBB0_20
LBB0_16:
	mov	x20, x0
	b	LBB0_21
LBB0_17:
	cmp	w9, #1
	b.lt	LBB0_20
; %bb.18:
	mov	w24, #0
	ldr	w8, [x19]
	sub	w9, w25, w9
	mul	w9, w8, w9
	lsl	w9, w9, #1
	add	x23, x23, w9, sxtw #2
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x21, #24]
	ldr	x9, [x9]
	ldr	x10, [x21, #8]
	ldrsw	x10, [x10]
	sxtw	x11, w24
	madd	x0, x10, x11, x9
	lsl	w2, w8, #1
	mov	x1, x23
	bl	_memcpy
	ldp	w8, w9, [x19]
                                        ; kill: def $w8 killed $w8 def $x8
	sxtw	x8, w8
	add	x23, x23, x8, lsl #3
	add	w24, w24, #1
	cmp	w24, w9
	b.lt	LBB0_19
LBB0_20:
	mov	w8, #1
	str	w8, [x22]
LBB0_21:
	mov	x0, x20
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"packet too small\n"

	.comm	_AVERROR_INVALIDDATA,4,2        ; @AVERROR_INVALIDDATA
	.comm	_AV_PICTURE_TYPE_I,4,2          ; @AV_PICTURE_TYPE_I
	.no_dead_strip	_decode_frame
.subsections_via_symbols
