	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vpif_check_format
_vpif_check_format:                     ## @vpif_check_format
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	8(%rsi), %rax
	movq	_V4L2_PIX_FMT_YUV422P@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_13
## %bb.1:
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	16(%rdi), %r12
	movq	_VPIF_VIDEO_INDEX@GOTPCREL(%rip), %rax
	movq	(%rax), %r13
	movl	(%rsi), %edi
	callq	_VPIF_VALID_FIELD
	testl	%eax, %eax
	je	LBB0_13
## %bb.2:
	cmpq	$0, 16(%rbx)
	jle	LBB0_14
## %bb.3:
	movq	_V4L2_MEMORY_USERPTR@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	shlq	$4, %r13
	cmpq	(%r12,%r13), %rax
	jne	LBB0_5
## %bb.4:
	leaq	24(%rbx), %rax
	jmp	LBB0_6
LBB0_13:
	leaq	L_.str.2(%rip), %rdi
LBB0_15:
	callq	_vpif_err
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_16:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	_config_params@GOTPCREL(%rip), %rcx
	movq	(%r14), %rax
	shlq	$2, %rax
	addq	(%rcx), %rax
LBB0_6:
	movl	(%rax), %r15d
	movq	%r14, %rdi
	callq	_vpif_get_std_info
	testq	%rax, %rax
	je	LBB0_8
## %bb.7:
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_15
LBB0_8:
	movl	16(%rbx), %edi
	cmpl	%edi, 8(%r14)
	jg	LBB0_14
## %bb.9:
	leal	(%rdi,%rdi), %ecx
	movl	%r15d, %eax
	cltd
	idivl	%ecx
	cmpl	12(%r14), %eax
	jge	LBB0_10
LBB0_14:
	leaq	L_.str.3(%rip), %rdi
	jmp	LBB0_15
LBB0_10:
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_ISALIGNED
	testl	%eax, %eax
	je	LBB0_11
## %bb.12:
	movl	12(%r12,%r13), %eax
	movl	%eax, 32(%rbx)
	movl	8(%r12,%r13), %eax
	movl	%eax, 28(%rbx)
	xorl	%eax, %eax
	jmp	LBB0_16
LBB0_11:
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
	.comm	_VPIF_VIDEO_INDEX,8,3           ## @VPIF_VIDEO_INDEX
	.comm	_V4L2_PIX_FMT_YUV422P,8,3       ## @V4L2_PIX_FMT_YUV422P
	.comm	_V4L2_MEMORY_USERPTR,8,3        ## @V4L2_MEMORY_USERPTR
	.comm	_config_params,8,3              ## @config_params
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Error getting the standard info\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.1:                               ## @.str.1
	.asciz	"invalid pitch alignment\n"

L_.str.2:                               ## @.str.2
	.asciz	"invalid field format\n"

L_.str.3:                               ## @.str.3
	.asciz	"invalid pitch\n"

	.no_dead_strip	_vpif_check_format
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vpif_check_format
_vpif_check_format:                     ; @vpif_check_format
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	ldr	x8, [x1, #8]
Lloh0:
	adrp	x9, _V4L2_PIX_FMT_YUV422P@GOTPAGE
Lloh1:
	ldr	x9, [x9, _V4L2_PIX_FMT_YUV422P@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.1:
	mov	x19, x1
	mov	x20, x0
	ldr	x21, [x0, #16]
Lloh3:
	adrp	x8, _VPIF_VIDEO_INDEX@GOTPAGE
Lloh4:
	ldr	x8, [x8, _VPIF_VIDEO_INDEX@GOTPAGEOFF]
Lloh5:
	ldr	x22, [x8]
	ldr	w0, [x1]
	bl	_VPIF_VALID_FIELD
	cbz	w0, LBB0_5
; %bb.2:
	ldr	x8, [x19, #16]
	cmp	x8, #1
	b.lt	LBB0_13
; %bb.3:
Lloh6:
	adrp	x8, _V4L2_MEMORY_USERPTR@GOTPAGE
Lloh7:
	ldr	x8, [x8, _V4L2_MEMORY_USERPTR@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	lsl	x9, x22, #4
	ldr	x9, [x21, x9]
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.4:
	add	x8, x19, #24
	b	LBB0_9
LBB0_5:
Lloh9:
	adrp	x0, l_.str.2@PAGE
Lloh10:
	add	x0, x0, l_.str.2@PAGEOFF
LBB0_6:
	bl	_vpif_err
Lloh11:
	adrp	x8, _EINVAL@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_7:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_8:
Lloh14:
	adrp	x8, _config_params@GOTPAGE
Lloh15:
	ldr	x8, [x8, _config_params@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	ldr	x9, [x20]
	add	x8, x8, x9, lsl #2
LBB0_9:
	ldr	w23, [x8]
	mov	x0, x20
	bl	_vpif_get_std_info
	cbz	x0, LBB0_11
; %bb.10:
Lloh17:
	adrp	x0, l_.str@PAGE
Lloh18:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_6
LBB0_11:
	ldr	w0, [x19, #16]
	ldr	w8, [x20, #8]
	cmp	w8, w0
	b.gt	LBB0_13
; %bb.12:
	lsl	w8, w0, #1
	sdiv	w8, w23, w8
	ldr	w9, [x20, #12]
	cmp	w8, w9
	b.ge	LBB0_14
LBB0_13:
Lloh19:
	adrp	x0, l_.str.3@PAGE
Lloh20:
	add	x0, x0, l_.str.3@PAGEOFF
	b	LBB0_6
LBB0_14:
	bl	_ISALIGNED
	cbz	w0, LBB0_16
; %bb.15:
	mov	w0, #0
	add	x8, x21, x22, lsl #4
	ldr	d0, [x8, #8]
	stur	d0, [x19, #28]
	b	LBB0_7
LBB0_16:
Lloh21:
	adrp	x0, l_.str.1@PAGE
Lloh22:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_6
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_VPIF_VIDEO_INDEX,8,3           ; @VPIF_VIDEO_INDEX
	.comm	_V4L2_PIX_FMT_YUV422P,8,3       ; @V4L2_PIX_FMT_YUV422P
	.comm	_V4L2_MEMORY_USERPTR,8,3        ; @V4L2_MEMORY_USERPTR
	.comm	_config_params,8,3              ; @config_params
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Error getting the standard info\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.1:                               ; @.str.1
	.asciz	"invalid pitch alignment\n"

l_.str.2:                               ; @.str.2
	.asciz	"invalid field format\n"

l_.str.3:                               ; @.str.3
	.asciz	"invalid pitch\n"

	.no_dead_strip	_vpif_check_format
.subsections_via_symbols
