	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function try_decode_video_frame
_try_decode_video_frame:                ## @try_decode_video_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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r12d
	movq	%rsi, %r15
	movq	%rdi, %r14
	movl	$0, -44(%rbp)
	movq	$0, -56(%rbp)
	movl	(%rdi), %r13d
	callq	_avcodec_is_open
	xorl	%ebx, %ebx
	testl	%eax, %eax
	movl	%r13d, -48(%rbp)                ## 4-byte Spill
	jne	LBB0_2
## %bb.1:
	movl	8(%r14), %edi
	callq	_avcodec_find_decoder
	movq	%r14, %rdi
	movq	%rax, %rsi
	xorl	%edx, %edx
	callq	_avcodec_open2
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_11
LBB0_2:
	xorl	%eax, %eax
	callq	_av_frame_alloc
	movq	%rax, -56(%rbp)
	testq	%rax, %rax
	je	LBB0_10
## %bb.3:
	movq	%rax, %r13
	testl	%r12d, %r12d
	jne	LBB0_6
## %bb.4:
	movl	4(%r14), %edi
	callq	_avpriv_codec_get_cap_skip_frame_fill_param
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movq	_AVDISCARD_ALL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%r14)
LBB0_6:
	testl	%r12d, %r12d
	setne	%r12b
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movq	%r13, %rsi
	leaq	-44(%rbp), %rdx
	movq	%r15, %rcx
	callq	_avcodec_decode_video2
	cmpl	$0, -44(%rbp)
	movl	%eax, %ebx
	sete	%al
	orb	%r12b, %al
	movzbl	%al, %edi
	callq	_av_assert0
	testl	%ebx, %ebx
	js	LBB0_13
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	addl	%ebx, 8(%r15)
	movl	%ebx, %ecx
	movq	(%r15), %rax
	subq	%rcx, %rax
	movq	%rax, (%r15)
	cmpl	$0, -44(%rbp)
	jne	LBB0_13
## %bb.9:                               ##   in Loop: Header=BB0_7 Depth=1
	testq	%rax, %rax
	jg	LBB0_7
	jmp	LBB0_13
LBB0_10:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	xorl	%edi, %edi
	jmp	LBB0_12
LBB0_11:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r14, %rdi
LBB0_12:
	callq	_av_log
LBB0_13:
	movl	-48(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, (%r14)
	leaq	-56(%rbp), %rdi
	callq	_av_frame_free
	movl	%ebx, %eax
	addq	$24, %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	"Failed to open codec\n"

L_.str.1:                               ## @.str.1
	.asciz	"Failed to allocate frame\n"

	.comm	_AVDISCARD_ALL,4,2              ## @AVDISCARD_ALL
	.no_dead_strip	_try_decode_video_frame
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function try_decode_video_frame
_try_decode_video_frame:                ; @try_decode_video_frame
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x22, x2
	mov	x20, x1
	mov	x19, x0
	str	wzr, [sp, #12]
	str	xzr, [sp]
	ldr	w24, [x0]
	bl	_avcodec_is_open
	mov	w21, #0
	cbnz	w0, LBB0_2
; %bb.1:
	ldr	w0, [x19, #8]
	bl	_avcodec_find_decoder
	mov	x1, x0
	mov	x0, x19
	mov	x2, #0
	bl	_avcodec_open2
	mov	x21, x0
	tbnz	w0, #31, LBB0_10
LBB0_2:
	bl	_av_frame_alloc
	str	x0, [sp]
	cbz	x0, LBB0_9
; %bb.3:
	mov	x23, x0
	cbnz	w22, LBB0_6
; %bb.4:
	ldr	w0, [x19, #4]
	bl	_avpriv_codec_get_cap_skip_frame_fill_param
	cbz	x0, LBB0_6
; %bb.5:
Lloh0:
	adrp	x8, _AVDISCARD_ALL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AVDISCARD_ALL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [x19]
LBB0_6:
	cmp	w22, #0
	cset	w22, ne
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	add	x2, sp, #12
	mov	x0, x19
	mov	x1, x23
	mov	x3, x20
	bl	_avcodec_decode_video2
	mov	x21, x0
	ldr	w8, [sp, #12]
	cmp	w8, #0
	cset	w8, eq
	orr	w0, w22, w8
	bl	_av_assert0
	tbnz	w21, #31, LBB0_12
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	w8, [x20, #8]
	add	w8, w8, w21
	str	w8, [x20, #8]
	ldr	x8, [x20]
	sub	x8, x8, w21, uxtw
	str	x8, [x20]
	ldr	w9, [sp, #12]
	cmp	w9, #0
	ccmp	x8, #0, #4, eq
	b.gt	LBB0_7
	b	LBB0_12
LBB0_9:
Lloh3:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x2, l_.str.1@PAGE
Lloh7:
	add	x2, x2, l_.str.1@PAGEOFF
	b	LBB0_11
LBB0_10:
Lloh8:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh9:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
Lloh11:
	adrp	x2, l_.str@PAGE
Lloh12:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
LBB0_11:
	bl	_av_log
LBB0_12:
	str	w24, [x19]
	mov	x0, sp
	bl	_av_frame_free
	mov	x0, x21
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh11, Lloh12
	.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	"Failed to open codec\n"

l_.str.1:                               ; @.str.1
	.asciz	"Failed to allocate frame\n"

	.comm	_AVDISCARD_ALL,4,2              ; @AVDISCARD_ALL
	.no_dead_strip	_try_decode_video_frame
.subsections_via_symbols
