	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ff_stream_add_bitstream_filter ## -- Begin function ff_stream_add_bitstream_filter
	.p2align	4, 0x90
_ff_stream_add_bitstream_filter:        ## @ff_stream_add_bitstream_filter
	.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	$48, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, %r12
	movq	%rdi, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -40(%rbp)
	movq	%rsi, %rdi
	callq	_av_bsf_get_by_name
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	leaq	-72(%rbp), %rsi
	movq	%rax, %rdi
	callq	_av_bsf_alloc
	testl	%eax, %eax
	js	LBB0_3
## %bb.4:
	movq	(%r15), %rax
	movslq	(%rax), %rcx
	testq	%rcx, %rcx
	je	LBB0_6
## %bb.5:
	movq	8(%rax), %rax
	movq	-8(%rax,%rcx,8), %rax
	leaq	8(%rax), %rcx
	jmp	LBB0_7
LBB0_1:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	xorl	%edi, %edi
	movq	%r12, %rcx
	xorl	%eax, %eax
	callq	_av_log
	movq	_AVERROR_BSF_NOT_FOUND@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_17
LBB0_3:
	movl	%eax, %ebx
	jmp	LBB0_17
LBB0_6:
	leaq	16(%r15), %rcx
	leaq	8(%r15), %rax
LBB0_7:
	movq	-72(%rbp), %rdx
	movq	(%rcx), %rsi
	movl	(%rax), %eax
	movl	%eax, 20(%rdx)
	movl	16(%rdx), %edi
	callq	_avcodec_parameters_copy
	testl	%eax, %eax
	js	LBB0_8
## %bb.9:
	testq	%r14, %r14
	je	LBB0_14
## %bb.10:
	movq	-72(%rbp), %rax
	movq	8(%rax), %rcx
	cmpq	$0, (%rcx)
	je	LBB0_14
## %bb.11:
	movl	(%rax), %edi
	xorl	%esi, %esi
	callq	_av_opt_next
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -64(%rbp)
	testq	%rax, %rax
	je	LBB0_13
## %bb.12:
	movq	(%rax), %rax
	movq	%rax, -64(%rbp)
LBB0_13:
	movq	-72(%rbp), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rcx
	leaq	L_.str.2(%rip), %r8
	leaq	-64(%rbp), %rdx
	movq	%r14, %rsi
	callq	_av_opt_set_from_string
	testl	%eax, %eax
	js	LBB0_8
LBB0_14:
	movq	-72(%rbp), %rdi
	callq	_av_bsf_init
	testl	%eax, %eax
	js	LBB0_8
## %bb.15:
	movq	(%r15), %rsi
	leaq	8(%rsi), %rdi
	movq	-72(%rbp), %rdx
	callq	_av_dynarray_add_nofree
	testl	%eax, %eax
	je	LBB0_16
LBB0_8:
	movl	%eax, %ebx
	leaq	-72(%rbp), %rdi
	callq	_av_bsf_free
LBB0_17:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-40(%rbp), %rax
	jne	LBB0_19
## %bb.18:
	movl	%ebx, %eax
	addq	$48, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_16:
	testq	%r14, %r14
	movq	_AV_LOG_VERBOSE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.4(%rip), %r8
	cmovneq	%r14, %r8
	leaq	L_.str.3(%rip), %rdx
	xorl	%edi, %edi
	movq	%r12, %rcx
	xorl	%eax, %eax
	callq	_av_log
	movl	$1, %ebx
	jmp	LBB0_17
LBB0_19:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Unknown bitstream filter '%s'\n"

	.comm	_AVERROR_BSF_NOT_FOUND,4,2      ## @AVERROR_BSF_NOT_FOUND
L_.str.1:                               ## @.str.1
	.asciz	"="

L_.str.2:                               ## @.str.2
	.asciz	":"

	.comm	_AV_LOG_VERBOSE,4,2             ## @AV_LOG_VERBOSE
L_.str.3:                               ## @.str.3
	.asciz	"Automatically inserted bitstream filter '%s'; args='%s'\n"

L_.str.4:                               ## @.str.4
	.space	1

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ff_stream_add_bitstream_filter ; -- Begin function ff_stream_add_bitstream_filter
	.p2align	2
_ff_stream_add_bitstream_filter:        ; @ff_stream_add_bitstream_filter
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x20, x2
	mov	x19, x1
	mov	x21, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #40]
	mov	x0, x1
	bl	_av_bsf_get_by_name
	cbz	x0, LBB0_4
; %bb.1:
	add	x1, sp, #16
	bl	_av_bsf_alloc
	tbnz	w0, #31, LBB0_5
; %bb.2:
	ldr	x8, [x21]
	ldr	w9, [x8]
	cbz	w9, LBB0_6
; %bb.3:
	ldr	x8, [x8, #8]
	sub	w9, w9, #1
	ldr	x8, [x8, w9, sxtw #3]
	add	x9, x8, #8
	b	LBB0_7
LBB0_4:
Lloh3:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x2, l_.str@PAGE
Lloh7:
	add	x2, x2, l_.str@PAGEOFF
	mov	x3, x19
	bl	_av_log
Lloh8:
	adrp	x8, _AVERROR_BSF_NOT_FOUND@GOTPAGE
Lloh9:
	ldr	x8, [x8, _AVERROR_BSF_NOT_FOUND@GOTPAGEOFF]
Lloh10:
	ldr	w22, [x8]
	b	LBB0_16
LBB0_5:
	mov	x22, x0
	b	LBB0_16
LBB0_6:
	add	x9, x21, #16
	add	x8, x21, #8
LBB0_7:
	ldr	x10, [sp, #16]
	ldr	x1, [x9]
	ldr	w8, [x8]
	str	w8, [x10, #20]
	ldr	w0, [x10, #16]
	bl	_avcodec_parameters_copy
	tbnz	w0, #31, LBB0_15
; %bb.8:
	cbz	x20, LBB0_13
; %bb.9:
	ldr	x8, [sp, #16]
	ldr	x9, [x8, #8]
	ldr	x9, [x9]
	cbz	x9, LBB0_13
; %bb.10:
	ldr	w0, [x8]
	mov	x1, #0
	bl	_av_opt_next
	stp	xzr, xzr, [sp, #24]
	cbz	x0, LBB0_12
; %bb.11:
	ldr	x8, [x0]
	str	x8, [sp, #24]
LBB0_12:
	ldr	x8, [sp, #16]
	ldr	w0, [x8]
Lloh11:
	adrp	x3, l_.str.1@PAGE
Lloh12:
	add	x3, x3, l_.str.1@PAGEOFF
Lloh13:
	adrp	x4, l_.str.2@PAGE
Lloh14:
	add	x4, x4, l_.str.2@PAGEOFF
	add	x2, sp, #24
	mov	x1, x20
	bl	_av_opt_set_from_string
	tbnz	w0, #31, LBB0_15
LBB0_13:
	ldr	x0, [sp, #16]
	bl	_av_bsf_init
	tbnz	w0, #31, LBB0_15
; %bb.14:
	ldr	x1, [x21]
	add	x0, x1, #8
	ldr	x2, [sp, #16]
	bl	_av_dynarray_add_nofree
	cbz	w0, LBB0_18
LBB0_15:
	mov	x22, x0
	add	x0, sp, #16
	bl	_av_bsf_free
LBB0_16:
	ldr	x8, [sp, #40]
Lloh15:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh16:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_19
; %bb.17:
	mov	x0, x22
	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
	add	sp, sp, #96
	ret
LBB0_18:
Lloh18:
	adrp	x8, _AV_LOG_VERBOSE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _AV_LOG_VERBOSE@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
Lloh21:
	adrp	x8, l_.str.4@PAGE
Lloh22:
	add	x8, x8, l_.str.4@PAGEOFF
	cmp	x20, #0
	csel	x8, x8, x20, eq
	str	x8, [sp]
Lloh23:
	adrp	x2, l_.str.3@PAGE
Lloh24:
	add	x2, x2, l_.str.3@PAGEOFF
	mov	x0, #0
	mov	x3, x19
	bl	_av_log
	mov	w22, #1
	b	LBB0_16
LBB0_19:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Unknown bitstream filter '%s'\n"

	.comm	_AVERROR_BSF_NOT_FOUND,4,2      ; @AVERROR_BSF_NOT_FOUND
l_.str.1:                               ; @.str.1
	.asciz	"="

l_.str.2:                               ; @.str.2
	.asciz	":"

	.comm	_AV_LOG_VERBOSE,4,2             ; @AV_LOG_VERBOSE
l_.str.3:                               ; @.str.3
	.asciz	"Automatically inserted bitstream filter '%s'; args='%s'\n"

l_.str.4:                               ; @.str.4
	.space	1

.subsections_via_symbols
