	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fdp1_try_fmt_capture
_fdp1_try_fmt_capture:                  ## @fdp1_try_fmt_capture
	.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	%rdx, %rbx
	movq	%rsi, -56(%rbp)                 ## 8-byte Spill
	movq	%rdi, %r14
	movl	(%rdi), %r12d
	movl	4(%rdi), %r13d
	movq	_V4L2_YCBCR_ENC_DEFAULT@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r13d
	jne	LBB0_2
## %bb.1:
	movl	%r12d, %edi
	callq	_V4L2_MAP_YCBCR_ENC_DEFAULT
	movl	%eax, %r13d
LBB0_2:
	movl	8(%r14), %r15d
	movq	_V4L2_QUANTIZATION_DEFAULT@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r15d
	jne	LBB0_4
## %bb.3:
	xorl	%edi, %edi
	movl	%r12d, %esi
	movl	%r13d, %edx
	callq	_V4L2_MAP_QUANTIZATION_DEFAULT
	movl	%eax, %r15d
LBB0_4:
	movq	_V4L2_YCBCR_ENC_601@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r13d
	jne	LBB0_5
## %bb.16:
	movl	32(%rbx), %edi
	callq	_fdp1_find_format
	movq	%rax, %r12
	testq	%rax, %rax
	jne	LBB0_10
	jmp	LBB0_9
LBB0_5:
	movq	_V4L2_YCBCR_ENC_709@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	_V4L2_QUANTIZATION_LIM_RANGE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	32(%rbx), %edi
	callq	_fdp1_find_format
	testq	%rax, %rax
	je	LBB0_9
## %bb.6:
	movq	%rax, %r12
	cmpl	-48(%rbp), %r13d                ## 4-byte Folded Reload
	jne	LBB0_8
## %bb.7:
	cmpl	-44(%rbp), %r15d                ## 4-byte Folded Reload
	je	LBB0_10
LBB0_8:
	movq	%r12, %rdi
	callq	_fdp1_fmt_is_rgb
	testq	%rax, %rax
	je	LBB0_10
LBB0_9:
	movq	_V4L2_PIX_FMT_YUYV@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_fdp1_find_format
	movq	%rax, %r12
LBB0_10:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:
	movq	%r12, (%rax)
LBB0_12:
	movl	4(%r12), %eax
	movl	%eax, 32(%rbx)
	movl	(%r12), %eax
	movl	%eax, 28(%rbx)
	movq	_V4L2_FIELD_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%rbx)
	movl	(%r14), %eax
	movl	%eax, (%rbx)
	movl	32(%r14), %eax
	movl	%eax, 20(%rbx)
	movq	%r12, %rdi
	callq	_fdp1_fmt_is_rgb
	testq	%rax, %rax
	movq	_V4L2_YCBCR_ENC_DEFAULT@GOTPCREL(%rip), %rcx
	je	LBB0_13
## %bb.14:
	movq	_V4L2_QUANTIZATION_DEFAULT@GOTPCREL(%rip), %rax
	jmp	LBB0_15
LBB0_13:
	leaq	4(%r14), %rcx
	leaq	8(%r14), %rax
LBB0_15:
	movl	(%rax), %eax
	movl	(%rcx), %ecx
	movl	%ecx, 4(%rbx)
	movl	%eax, 8(%rbx)
	movl	28(%r14), %eax
	movl	%eax, 16(%rbx)
	movq	16(%r14), %rax
	movq	_V4L2_FIELD_ALTERNATE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	sete	%cl
	movl	24(%r14), %eax
	shll	%cl, %eax
	movl	%eax, 12(%rbx)
	movq	%rbx, %rdi
	movq	%r12, %rsi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_fdp1_compute_stride            ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_V4L2_YCBCR_ENC_DEFAULT,4,2     ## @V4L2_YCBCR_ENC_DEFAULT
	.comm	_V4L2_QUANTIZATION_DEFAULT,4,2  ## @V4L2_QUANTIZATION_DEFAULT
	.comm	_V4L2_YCBCR_ENC_601,4,2         ## @V4L2_YCBCR_ENC_601
	.comm	_V4L2_YCBCR_ENC_709,4,2         ## @V4L2_YCBCR_ENC_709
	.comm	_V4L2_QUANTIZATION_LIM_RANGE,4,2 ## @V4L2_QUANTIZATION_LIM_RANGE
	.comm	_V4L2_PIX_FMT_YUYV,4,2          ## @V4L2_PIX_FMT_YUYV
	.comm	_V4L2_FIELD_NONE,4,2            ## @V4L2_FIELD_NONE
	.comm	_V4L2_FIELD_ALTERNATE,8,3       ## @V4L2_FIELD_ALTERNATE
	.no_dead_strip	_fdp1_try_fmt_capture
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fdp1_try_fmt_capture
_fdp1_try_fmt_capture:                  ; @fdp1_try_fmt_capture
	.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
	mov	x19, x2
	mov	x21, x1
	mov	x20, x0
	ldr	w22, [x0]
	mov	x25, x0
	ldr	w23, [x25, #4]!
Lloh0:
	adrp	x8, _V4L2_YCBCR_ENC_DEFAULT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _V4L2_YCBCR_ENC_DEFAULT@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w23, w8
	b.ne	LBB0_2
; %bb.1:
	mov	x0, x22
	bl	_V4L2_MAP_YCBCR_ENC_DEFAULT
	mov	x23, x0
LBB0_2:
	mov	x27, x20
	ldr	w24, [x27, #8]!
Lloh3:
	adrp	x8, _V4L2_QUANTIZATION_DEFAULT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _V4L2_QUANTIZATION_DEFAULT@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w24, w8
	b.ne	LBB0_4
; %bb.3:
	mov	w0, #0
	mov	x1, x22
	mov	x2, x23
	bl	_V4L2_MAP_QUANTIZATION_DEFAULT
	mov	x24, x0
LBB0_4:
Lloh6:
	adrp	x8, _V4L2_YCBCR_ENC_601@GOTPAGE
Lloh7:
	ldr	x8, [x8, _V4L2_YCBCR_ENC_601@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	cmp	w23, w8
	b.ne	LBB0_6
; %bb.5:
	ldr	w0, [x19, #32]
	bl	_fdp1_find_format
	mov	x22, x0
	cbnz	x0, LBB0_10
	b	LBB0_9
LBB0_6:
Lloh9:
	adrp	x8, _V4L2_YCBCR_ENC_709@GOTPAGE
Lloh10:
	ldr	x8, [x8, _V4L2_YCBCR_ENC_709@GOTPAGEOFF]
Lloh11:
	ldr	w26, [x8]
Lloh12:
	adrp	x8, _V4L2_QUANTIZATION_LIM_RANGE@GOTPAGE
Lloh13:
	ldr	x8, [x8, _V4L2_QUANTIZATION_LIM_RANGE@GOTPAGEOFF]
Lloh14:
	ldr	w28, [x8]
	ldr	w0, [x19, #32]
	bl	_fdp1_find_format
	cbz	x0, LBB0_9
; %bb.7:
	mov	x22, x0
	cmp	w23, w26
	ccmp	w24, w28, #0, eq
	b.eq	LBB0_10
; %bb.8:
	mov	x0, x22
	bl	_fdp1_fmt_is_rgb
	cbz	x0, LBB0_10
LBB0_9:
Lloh15:
	adrp	x8, _V4L2_PIX_FMT_YUYV@GOTPAGE
Lloh16:
	ldr	x8, [x8, _V4L2_PIX_FMT_YUYV@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
	bl	_fdp1_find_format
	mov	x22, x0
LBB0_10:
	cbz	x21, LBB0_12
; %bb.11:
	str	x22, [x21]
LBB0_12:
	ldp	w9, w8, [x22]
	stp	w9, w8, [x19, #28]
Lloh18:
	adrp	x8, _V4L2_FIELD_NONE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _V4L2_FIELD_NONE@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	ldr	w9, [x20]
	str	w9, [x19]
	ldr	w9, [x20, #32]
	stp	w9, w8, [x19, #20]
	mov	x0, x22
	bl	_fdp1_fmt_is_rgb
	cmp	x0, #0
Lloh21:
	adrp	x8, _V4L2_YCBCR_ENC_DEFAULT@GOTPAGE
Lloh22:
	ldr	x8, [x8, _V4L2_YCBCR_ENC_DEFAULT@GOTPAGEOFF]
	csel	x8, x25, x8, eq
Lloh23:
	adrp	x9, _V4L2_QUANTIZATION_DEFAULT@GOTPAGE
Lloh24:
	ldr	x9, [x9, _V4L2_QUANTIZATION_DEFAULT@GOTPAGEOFF]
	csel	x9, x27, x9, eq
	ldr	w9, [x9]
	ldr	w8, [x8]
	stp	w8, w9, [x19, #4]
	ldr	x8, [x20, #16]
Lloh25:
	adrp	x9, _V4L2_FIELD_ALTERNATE@GOTPAGE
Lloh26:
	ldr	x9, [x9, _V4L2_FIELD_ALTERNATE@GOTPAGEOFF]
Lloh27:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w8, eq
	ldp	w10, w9, [x20, #24]
	lsl	w8, w10, w8
	stp	w8, w9, [x19, #12]
	mov	x0, x19
	mov	x1, 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
	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	_fdp1_compute_stride
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_V4L2_YCBCR_ENC_DEFAULT,4,2     ; @V4L2_YCBCR_ENC_DEFAULT
	.comm	_V4L2_QUANTIZATION_DEFAULT,4,2  ; @V4L2_QUANTIZATION_DEFAULT
	.comm	_V4L2_YCBCR_ENC_601,4,2         ; @V4L2_YCBCR_ENC_601
	.comm	_V4L2_YCBCR_ENC_709,4,2         ; @V4L2_YCBCR_ENC_709
	.comm	_V4L2_QUANTIZATION_LIM_RANGE,4,2 ; @V4L2_QUANTIZATION_LIM_RANGE
	.comm	_V4L2_PIX_FMT_YUYV,4,2          ; @V4L2_PIX_FMT_YUYV
	.comm	_V4L2_FIELD_NONE,4,2            ; @V4L2_FIELD_NONE
	.comm	_V4L2_FIELD_ALTERNATE,8,3       ; @V4L2_FIELD_ALTERNATE
	.no_dead_strip	_fdp1_try_fmt_capture
.subsections_via_symbols
