	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function zr36057_adjust_vfe
_zr36057_adjust_vfe:                    ## @zr36057_adjust_vfe
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	cmpl	$128, %esi
	jne	LBB0_3
## %bb.1:
	movq	_ZR36057_VFESPFR_ExtFl@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	notl	%edi
	movq	_ZR36057_VFESPFR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_btand
	movq	_ZR36057_VFEHCR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_btread
	movl	%eax, %edi
	testl	$1024, %eax                     ## imm = 0x400
	je	LBB0_11
## %bb.2:
	movl	4(%rbx), %eax
	movq	_LML33R10@GOTPCREL(%rip), %rcx
	leal	1025(%rdi), %edx
	jmp	LBB0_10
LBB0_3:
	movl	(%rbx), %eax
	movq	_V4L2_STD_NTSC@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_4
LBB0_6:
	movq	_ZR36057_VFESPFR_ExtFl@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	notl	%edi
	movq	_ZR36057_VFESPFR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_btand
	jmp	LBB0_8
LBB0_4:
	movl	4(%rbx), %ecx
	movq	_LML33R10@GOTPCREL(%rip), %rdx
	cmpl	(%rdx), %ecx
	jne	LBB0_7
## %bb.5:
	movq	_V4L2_STD_PAL@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_6
LBB0_7:
	movq	_ZR36057_VFESPFR_ExtFl@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_ZR36057_VFESPFR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_btor
LBB0_8:
	movq	_ZR36057_VFEHCR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_btread
	movl	%eax, %edi
	testl	$1024, %eax                     ## imm = 0x400
	jne	LBB0_11
## %bb.9:
	movl	4(%rbx), %eax
	movq	_LML33R10@GOTPCREL(%rip), %rcx
	leal	-1025(%rdi), %edx
LBB0_10:
	cmpl	(%rcx), %eax
	cmovel	%edi, %edx
	movl	%edx, %edi
LBB0_11:
	movq	_ZR36057_VFEHCR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
                                        ## kill: def $edi killed $edi killed $rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	_btwrite                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ZR36057_VFESPFR_ExtFl,4,2      ## @ZR36057_VFESPFR_ExtFl
	.comm	_ZR36057_VFESPFR,4,2            ## @ZR36057_VFESPFR
	.comm	_ZR36057_VFEHCR,4,2             ## @ZR36057_VFEHCR
	.comm	_LML33R10,4,2                   ## @LML33R10
	.comm	_V4L2_STD_NTSC,4,2              ## @V4L2_STD_NTSC
	.comm	_V4L2_STD_PAL,4,2               ## @V4L2_STD_PAL
	.no_dead_strip	_zr36057_adjust_vfe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function zr36057_adjust_vfe
_zr36057_adjust_vfe:                    ; @zr36057_adjust_vfe
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
Lloh0:
	adrp	x20, _ZR36057_VFEHCR@GOTPAGE
Lloh1:
	ldr	x20, [x20, _ZR36057_VFEHCR@GOTPAGEOFF]
	cmp	w1, #128
	b.ne	LBB0_3
; %bb.1:
Lloh2:
	adrp	x8, _ZR36057_VFESPFR_ExtFl@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ZR36057_VFESPFR_ExtFl@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	mvn	w0, w8
Lloh5:
	adrp	x8, _ZR36057_VFESPFR@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ZR36057_VFESPFR@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	bl	_btand
	ldr	w0, [x20]
	bl	_btread
	tbz	w0, #10, LBB0_11
; %bb.2:
	ldr	w8, [x19, #4]
Lloh8:
	adrp	x9, _LML33R10@GOTPAGE
Lloh9:
	ldr	x9, [x9, _LML33R10@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	add	w10, w0, #1025
	b	LBB0_10
LBB0_3:
	ldr	w8, [x19]
Lloh11:
	adrp	x9, _V4L2_STD_NTSC@GOTPAGE
Lloh12:
	ldr	x9, [x9, _V4L2_STD_NTSC@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_5
LBB0_4:
Lloh14:
	adrp	x8, _ZR36057_VFESPFR_ExtFl@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ZR36057_VFESPFR_ExtFl@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	mvn	w0, w8
Lloh17:
	adrp	x8, _ZR36057_VFESPFR@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ZR36057_VFESPFR@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	bl	_btand
	b	LBB0_8
LBB0_5:
	ldr	w9, [x19, #4]
Lloh20:
	adrp	x10, _LML33R10@GOTPAGE
Lloh21:
	ldr	x10, [x10, _LML33R10@GOTPAGEOFF]
Lloh22:
	ldr	w10, [x10]
	cmp	w9, w10
	b.ne	LBB0_7
; %bb.6:
Lloh23:
	adrp	x9, _V4L2_STD_PAL@GOTPAGE
Lloh24:
	ldr	x9, [x9, _V4L2_STD_PAL@GOTPAGEOFF]
Lloh25:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_4
LBB0_7:
Lloh26:
	adrp	x8, _ZR36057_VFESPFR_ExtFl@GOTPAGE
Lloh27:
	ldr	x8, [x8, _ZR36057_VFESPFR_ExtFl@GOTPAGEOFF]
Lloh28:
	ldr	w0, [x8]
Lloh29:
	adrp	x8, _ZR36057_VFESPFR@GOTPAGE
Lloh30:
	ldr	x8, [x8, _ZR36057_VFESPFR@GOTPAGEOFF]
Lloh31:
	ldr	w1, [x8]
	bl	_btor
LBB0_8:
	ldr	w0, [x20]
	bl	_btread
	tbnz	w0, #10, LBB0_11
; %bb.9:
	ldr	w8, [x19, #4]
Lloh32:
	adrp	x9, _LML33R10@GOTPAGE
Lloh33:
	ldr	x9, [x9, _LML33R10@GOTPAGEOFF]
Lloh34:
	ldr	w9, [x9]
	sub	w10, w0, #1025
LBB0_10:
	cmp	w8, w9
	csel	w0, w0, w10, eq
LBB0_11:
	ldr	w1, [x20]
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_btwrite
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_ZR36057_VFESPFR_ExtFl,4,2      ; @ZR36057_VFESPFR_ExtFl
	.comm	_ZR36057_VFESPFR,4,2            ; @ZR36057_VFESPFR
	.comm	_ZR36057_VFEHCR,4,2             ; @ZR36057_VFEHCR
	.comm	_LML33R10,4,2                   ; @LML33R10
	.comm	_V4L2_STD_NTSC,4,2              ; @V4L2_STD_NTSC
	.comm	_V4L2_STD_PAL,4,2               ; @V4L2_STD_PAL
	.no_dead_strip	_zr36057_adjust_vfe
.subsections_via_symbols
