	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ff_v4l2_m2m_codec_init         ## -- Begin function ff_v4l2_m2m_codec_init
	.p2align	4, 0x90
_ff_v4l2_m2m_codec_init:                ## @ff_v4l2_m2m_codec_init
	.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
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
	movl	%eax, %ebx
	movq	_PATH_MAX@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r12
	movq	%r14, -56(%rbp)                 ## 8-byte Spill
	movq	(%r14), %r15
	leaq	L_.str(%rip), %rdi
	callq	_opendir
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_readdir
	testq	%rax, %rax
	je	LBB0_10
## %bb.4:
	movq	%rax, %r13
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_5 Depth=1
	movq	%r14, %rdi
	callq	_readdir
	movq	%rax, %r13
	testq	%rax, %rax
	je	LBB0_10
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r13), %rdi
	leaq	L_.str.1(%rip), %rsi
	movl	$5, %edx
	callq	_strncmp
	testq	%rax, %rax
	jne	LBB0_9
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	(%r13), %rcx
	movq	%r12, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	leaq	L_.str.2(%rip), %rdx
	callq	_snprintf
	movq	_AV_LOG_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	leaq	L_.str.3(%rip), %rdx
	movq	%r12, %rcx
	xorl	%eax, %eax
	callq	_av_log
	movl	(%r15), %ebx
	movq	%r12, %rdi
	callq	_strlen
	leaq	1(%rax), %rdx
	movl	%ebx, %edi
	movq	%r12, %rsi
	callq	_strncpy
	movq	%r15, %rdi
	callq	_v4l2_probe_driver
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_9
## %bb.7:
	movq	%r14, %rdi
	callq	_closedir
	jmp	LBB0_8
LBB0_10:
	movq	%r14, %rdi
	callq	_closedir
	testl	%ebx, %ebx
	je	LBB0_8
## %bb.11:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.4(%rip), %rdx
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_av_log
	movl	(%r15), %edi
	xorl	%esi, %esi
	movl	$4, %edx
	callq	_memset
	jmp	LBB0_12
LBB0_1:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_14
## %bb.2:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_AVERROR                        ## TAILCALL
LBB0_8:
	movq	_AV_LOG_INFO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.5(%rip), %rdx
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	%r12, %rcx
	xorl	%eax, %eax
	callq	_av_log
	movq	%r15, %rdi
	callq	_v4l2_configure_contexts
	movl	%eax, %ebx
LBB0_12:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_14
## %bb.13:
	movl	%ebx, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_PATH_MAX,4,2                   ## @PATH_MAX
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"/dev"

	.comm	_errno,4,2                      ## @errno
L_.str.1:                               ## @.str.1
	.asciz	"video"

L_.str.2:                               ## @.str.2
	.asciz	"/dev/%s"

	.comm	_AV_LOG_DEBUG,4,2               ## @AV_LOG_DEBUG
L_.str.3:                               ## @.str.3
	.asciz	"probing device %s\n"

	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
L_.str.4:                               ## @.str.4
	.asciz	"Could not find a valid device\n"

	.comm	_AV_LOG_INFO,4,2                ## @AV_LOG_INFO
L_.str.5:                               ## @.str.5
	.asciz	"Using device %s\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ff_v4l2_m2m_codec_init         ; -- Begin function ff_v4l2_m2m_codec_init
	.p2align	2
_ff_v4l2_m2m_codec_init:                ; @ff_v4l2_m2m_codec_init
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	sub	sp, sp, #16
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _EINVAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	bl	_AVERROR
	mov	x22, x0
Lloh6:
	adrp	x8, _PATH_MAX@GOTPAGE
Lloh7:
	ldr	x8, [x8, _PATH_MAX@GOTPAGEOFF]
Lloh8:
	ldr	w23, [x8]
	mov	x9, x23
Lloh9:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh10:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	add	x9, x23, #15
	and	x9, x9, #0x1fffffff0
	sub	x21, x8, x9
	mov	sp, x21
	ldr	x20, [x19]
Lloh11:
	adrp	x0, l_.str@PAGE
Lloh12:
	add	x0, x0, l_.str@PAGEOFF
	bl	_opendir
	cbz	x0, LBB0_9
; %bb.1:
	mov	x24, x0
	bl	_readdir
	cbz	x0, LBB0_7
; %bb.2:
	mov	x28, x0
Lloh13:
	adrp	x25, l_.str.1@PAGE
Lloh14:
	add	x25, x25, l_.str.1@PAGEOFF
Lloh15:
	adrp	x26, _AV_LOG_DEBUG@GOTPAGE
Lloh16:
	ldr	x26, [x26, _AV_LOG_DEBUG@GOTPAGEOFF]
Lloh17:
	adrp	x27, l_.str.3@PAGE
Lloh18:
	add	x27, x27, l_.str.3@PAGEOFF
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x24
	bl	_readdir
	mov	x28, x0
	cbz	x0, LBB0_7
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x28]
	mov	x1, x25
	mov	w2, #5
	bl	_strncmp
	cbnz	x0, LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x3, [x28]
	mov	x0, x21
	mov	x1, x23
Lloh19:
	adrp	x2, l_.str.2@PAGE
Lloh20:
	add	x2, x2, l_.str.2@PAGEOFF
	bl	_snprintf
	ldr	w1, [x26]
	str	x21, [sp, #-16]!
	mov	x0, x19
	mov	x2, x27
	bl	_av_log
	add	sp, sp, #16
	ldr	w22, [x20]
	mov	x0, x21
	bl	_strlen
	add	x2, x0, #1
	mov	x0, x22
	mov	x1, x21
	bl	_strncpy
	mov	x0, x20
	bl	_v4l2_probe_driver
	mov	x22, x0
	cbnz	w0, LBB0_3
; %bb.6:
	mov	x0, x24
	bl	_closedir
	b	LBB0_11
LBB0_7:
	mov	x0, x24
	bl	_closedir
	cbz	w22, LBB0_11
; %bb.8:
Lloh21:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh22:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
Lloh24:
	adrp	x2, l_.str.4@PAGE
Lloh25:
	add	x2, x2, l_.str.4@PAGEOFF
	mov	x0, x19
	bl	_av_log
	ldr	w0, [x20]
	mov	w1, #0
	mov	w2, #4
	bl	_memset
	b	LBB0_12
LBB0_9:
Lloh26:
	adrp	x8, _errno@GOTPAGE
Lloh27:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh28:
	ldr	w0, [x8]
	ldur	x8, [x29, #-88]
Lloh29:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh30:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh31:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.10:
	sub	sp, x29, #80
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_AVERROR
LBB0_11:
Lloh32:
	adrp	x8, _AV_LOG_INFO@GOTPAGE
Lloh33:
	ldr	x8, [x8, _AV_LOG_INFO@GOTPAGEOFF]
Lloh34:
	ldr	w1, [x8]
	str	x21, [sp, #-16]!
Lloh35:
	adrp	x2, l_.str.5@PAGE
Lloh36:
	add	x2, x2, l_.str.5@PAGEOFF
	mov	x0, x19
	bl	_av_log
	add	sp, sp, #16
	mov	x0, x20
	bl	_v4l2_configure_contexts
	mov	x22, x0
LBB0_12:
	ldur	x8, [x29, #-88]
Lloh37:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh38:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh39:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.13:
	mov	x0, x22
	sub	sp, x29, #80
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_14:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_PATH_MAX,4,2                   ; @PATH_MAX
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"/dev"

	.comm	_errno,4,2                      ; @errno
l_.str.1:                               ; @.str.1
	.asciz	"video"

l_.str.2:                               ; @.str.2
	.asciz	"/dev/%s"

	.comm	_AV_LOG_DEBUG,4,2               ; @AV_LOG_DEBUG
l_.str.3:                               ; @.str.3
	.asciz	"probing device %s\n"

	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
l_.str.4:                               ; @.str.4
	.asciz	"Could not find a valid device\n"

	.comm	_AV_LOG_INFO,4,2                ; @AV_LOG_INFO
l_.str.5:                               ; @.str.5
	.asciz	"Using device %s\n"

.subsections_via_symbols
