	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vpif_update_resolution
_vpif_update_resolution:                ## @vpif_update_resolution
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	32(%rdi), %r14
	movq	_VPIF_VIDEO_INDEX@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	cmpq	$0, 16(%rdi)
	je	LBB0_1
## %bb.3:
	movq	%rbx, %rdi
	callq	_vpif_update_std_info
	testq	%rax, %rax
	je	LBB0_4
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_11
LBB0_1:
	cmpl	$0, 24(%rbx)
	je	LBB0_2
LBB0_4:
	movq	_V4L2_PIX_FMT_YUV422P@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	shlq	$5, %r15
	movl	%eax, 28(%r14,%r15)
	movl	(%rbx), %ecx
	movl	%ecx, 8(%r14,%r15)
	movl	4(%rbx), %r8d
	movl	%r8d, 12(%r14,%r15)
	movq	_debug@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movl	$1, %edi
	callq	_vpif_dbg
	movl	4(%rbx), %eax
	movl	%eax, (%r14,%r15)
	movl	(%rbx), %ecx
	movl	%ecx, 4(%r14,%r15)
	imull	%ecx, %eax
	addl	%eax, %eax
	movl	%eax, 16(%r14,%r15)
	cmpq	$0, 16(%rbx)
	jne	LBB0_5
## %bb.6:
	movq	_V4L2_COLORSPACE_REC709@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_5:
	movq	_V4L2_COLORSPACE_SMPTE170M@GOTPCREL(%rip), %rax
LBB0_7:
	movl	(%rax), %eax
	movl	%eax, 24(%r14,%r15)
	cmpq	$0, 8(%rbx)
	je	LBB0_9
## %bb.8:
	movq	_V4L2_FIELD_NONE@GOTPCREL(%rip), %rax
	jmp	LBB0_10
LBB0_9:
	movq	_V4L2_FIELD_INTERLACED@GOTPCREL(%rip), %rax
LBB0_10:
	movl	(%rax), %eax
	movl	%eax, 20(%r14,%r15)
	xorl	%eax, %eax
LBB0_11:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_VPIF_VIDEO_INDEX,8,3           ## @VPIF_VIDEO_INDEX
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_V4L2_PIX_FMT_YUV422P,4,2       ## @V4L2_PIX_FMT_YUV422P
	.comm	_debug,4,2                      ## @debug
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Pixel details: Width = %d,Height = %d\n"

	.comm	_V4L2_COLORSPACE_SMPTE170M,4,2  ## @V4L2_COLORSPACE_SMPTE170M
	.comm	_V4L2_COLORSPACE_REC709,4,2     ## @V4L2_COLORSPACE_REC709
	.comm	_V4L2_FIELD_NONE,4,2            ## @V4L2_FIELD_NONE
	.comm	_V4L2_FIELD_INTERLACED,4,2      ## @V4L2_FIELD_INTERLACED
	.no_dead_strip	_vpif_update_resolution
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vpif_update_resolution
_vpif_update_resolution:                ; @vpif_update_resolution
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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	x19, x0
	ldr	x20, [x0, #32]
Lloh0:
	adrp	x8, _VPIF_VIDEO_INDEX@GOTPAGE
Lloh1:
	ldr	x8, [x8, _VPIF_VIDEO_INDEX@GOTPAGEOFF]
Lloh2:
	ldr	x21, [x8]
	ldr	x8, [x0, #16]
	cbz	x8, LBB0_3
; %bb.1:
	mov	x0, x19
	bl	_vpif_update_std_info
	cbz	x0, LBB0_4
LBB0_2:
Lloh3:
	adrp	x8, _EINVAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_8
LBB0_3:
	ldr	w8, [x19, #24]
	cbz	w8, LBB0_2
LBB0_4:
Lloh6:
	adrp	x8, _V4L2_PIX_FMT_YUV422P@GOTPAGE
Lloh7:
	ldr	x8, [x8, _V4L2_PIX_FMT_YUV422P@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	add	x20, x20, x21, lsl #5
	str	w8, [x20, #28]
	ldp	w3, w4, [x19]
	stp	w3, w4, [x20, #8]
Lloh9:
	adrp	x8, _debug@GOTPAGE
Lloh10:
	ldr	x8, [x8, _debug@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
Lloh12:
	adrp	x2, l_.str@PAGE
Lloh13:
	add	x2, x2, l_.str@PAGEOFF
	mov	w0, #1
	bl	_vpif_dbg
	ldp	w9, w8, [x19]
	stp	w8, w9, [x20]
	mul	w8, w8, w9
	lsl	w8, w8, #1
	str	w8, [x20, #16]
Lloh14:
	adrp	x8, _V4L2_COLORSPACE_REC709@GOTPAGE
Lloh15:
	ldr	x8, [x8, _V4L2_COLORSPACE_REC709@GOTPAGEOFF]
Lloh16:
	adrp	x9, _V4L2_COLORSPACE_SMPTE170M@GOTPAGE
Lloh17:
	ldr	x9, [x9, _V4L2_COLORSPACE_SMPTE170M@GOTPAGEOFF]
	ldr	x10, [x19, #16]
	cmp	x10, #0
	csel	x8, x8, x9, eq
	ldr	w8, [x8]
	str	w8, [x20, #24]
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_6
; %bb.5:
	mov	w0, #0
Lloh18:
	adrp	x8, _V4L2_FIELD_NONE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _V4L2_FIELD_NONE@GOTPAGEOFF]
	b	LBB0_7
LBB0_6:
	mov	w0, #0
Lloh20:
	adrp	x8, _V4L2_FIELD_INTERLACED@GOTPAGE
Lloh21:
	ldr	x8, [x8, _V4L2_FIELD_INTERLACED@GOTPAGEOFF]
LBB0_7:
	ldr	w8, [x8]
	str	w8, [x20, #20]
LBB0_8:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_VPIF_VIDEO_INDEX,8,3           ; @VPIF_VIDEO_INDEX
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_V4L2_PIX_FMT_YUV422P,4,2       ; @V4L2_PIX_FMT_YUV422P
	.comm	_debug,4,2                      ; @debug
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Pixel details: Width = %d,Height = %d\n"

	.comm	_V4L2_COLORSPACE_SMPTE170M,4,2  ; @V4L2_COLORSPACE_SMPTE170M
	.comm	_V4L2_COLORSPACE_REC709,4,2     ; @V4L2_COLORSPACE_REC709
	.comm	_V4L2_FIELD_NONE,4,2            ; @V4L2_FIELD_NONE
	.comm	_V4L2_FIELD_INTERLACED,4,2      ; @V4L2_FIELD_INTERLACED
	.no_dead_strip	_vpif_update_resolution
.subsections_via_symbols
