	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sun4i_tcon0_mode_set_dithering
_sun4i_tcon0_mode_set_dithering:        ## @sun4i_tcon0_mode_set_dithering
	.cfi_startproc
## %bb.0:
	testq	%rsi, %rsi
	je	LBB0_7
## %bb.1:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movl	(%rdi), %edi
	movq	_SUN4I_TCON0_FRM_SEED_PR_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$286331153, %edx                ## imm = 0x11111111
	callq	_regmap_write
	movl	(%rbx), %edi
	movq	_SUN4I_TCON0_FRM_SEED_PG_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$286331153, %edx                ## imm = 0x11111111
	callq	_regmap_write
	movl	(%rbx), %edi
	movq	_SUN4I_TCON0_FRM_SEED_PB_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$286331153, %edx                ## imm = 0x11111111
	callq	_regmap_write
	movl	(%rbx), %edi
	movq	_SUN4I_TCON0_FRM_SEED_LR_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$286331153, %edx                ## imm = 0x11111111
	callq	_regmap_write
	movl	(%rbx), %edi
	movq	_SUN4I_TCON0_FRM_SEED_LG_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$286331153, %edx                ## imm = 0x11111111
	callq	_regmap_write
	movl	(%rbx), %edi
	movq	_SUN4I_TCON0_FRM_SEED_LB_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$286331153, %edx                ## imm = 0x11111111
	callq	_regmap_write
	movl	(%rbx), %edi
	movq	_SUN4I_TCON0_FRM_TBL0_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$16842752, %edx                 ## imm = 0x1010000
	callq	_regmap_write
	movl	(%rbx), %edi
	movq	_SUN4I_TCON0_FRM_TBL1_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$353702161, %edx                ## imm = 0x15151111
	callq	_regmap_write
	movl	(%rbx), %edi
	movq	_SUN4I_TCON0_FRM_TBL2_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1465341269, %edx               ## imm = 0x57575555
	callq	_regmap_write
	movl	(%rbx), %edi
	movq	_SUN4I_TCON0_FRM_TBL3_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$2139060087, %edx               ## imm = 0x7F7F7777
	callq	_regmap_write
	xorl	%edx, %edx
	cmpl	$6, (%r14)
	movq	_SUN4I_TCON0_FRM_CTL_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	cmovel	%eax, %edx
	cmpl	$1, 4(%r14)
	jne	LBB0_6
## %bb.2:
	movq	8(%r14), %rcx
	movl	(%rcx), %ecx
	leal	-128(%rcx), %esi
	cmpl	$2, %esi
	jb	LBB0_5
## %bb.3:
	cmpl	$130, %ecx
	jne	LBB0_6
## %bb.4:
	movq	_SUN4I_TCON0_FRM_CTL_MODE_R@GOTPCREL(%rip), %rcx
	orl	(%rcx), %edx
	movq	_SUN4I_TCON0_FRM_CTL_MODE_B@GOTPCREL(%rip), %rcx
	orl	(%rcx), %edx
LBB0_5:
	orl	%eax, %edx
LBB0_6:
	movl	(%rbx), %edi
	movq	_SUN4I_TCON_FRM_CTL_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_regmap_write                   ## TAILCALL
LBB0_7:
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SUN4I_TCON0_FRM_SEED_PR_REG,4,2 ## @SUN4I_TCON0_FRM_SEED_PR_REG
	.comm	_SUN4I_TCON0_FRM_SEED_PG_REG,4,2 ## @SUN4I_TCON0_FRM_SEED_PG_REG
	.comm	_SUN4I_TCON0_FRM_SEED_PB_REG,4,2 ## @SUN4I_TCON0_FRM_SEED_PB_REG
	.comm	_SUN4I_TCON0_FRM_SEED_LR_REG,4,2 ## @SUN4I_TCON0_FRM_SEED_LR_REG
	.comm	_SUN4I_TCON0_FRM_SEED_LG_REG,4,2 ## @SUN4I_TCON0_FRM_SEED_LG_REG
	.comm	_SUN4I_TCON0_FRM_SEED_LB_REG,4,2 ## @SUN4I_TCON0_FRM_SEED_LB_REG
	.comm	_SUN4I_TCON0_FRM_TBL0_REG,4,2   ## @SUN4I_TCON0_FRM_TBL0_REG
	.comm	_SUN4I_TCON0_FRM_TBL1_REG,4,2   ## @SUN4I_TCON0_FRM_TBL1_REG
	.comm	_SUN4I_TCON0_FRM_TBL2_REG,4,2   ## @SUN4I_TCON0_FRM_TBL2_REG
	.comm	_SUN4I_TCON0_FRM_TBL3_REG,4,2   ## @SUN4I_TCON0_FRM_TBL3_REG
	.comm	_SUN4I_TCON0_FRM_CTL_EN,4,2     ## @SUN4I_TCON0_FRM_CTL_EN
	.comm	_SUN4I_TCON0_FRM_CTL_MODE_R,4,2 ## @SUN4I_TCON0_FRM_CTL_MODE_R
	.comm	_SUN4I_TCON0_FRM_CTL_MODE_B,4,2 ## @SUN4I_TCON0_FRM_CTL_MODE_B
	.comm	_SUN4I_TCON_FRM_CTL_REG,4,2     ## @SUN4I_TCON_FRM_CTL_REG
	.no_dead_strip	_sun4i_tcon0_mode_set_dithering
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sun4i_tcon0_mode_set_dithering
_sun4i_tcon0_mode_set_dithering:        ; @sun4i_tcon0_mode_set_dithering
	.cfi_startproc
; %bb.0:
	cbz	x1, LBB0_7
; %bb.1:
	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	x20, x1
	mov	x19, x0
	ldr	w0, [x0]
Lloh0:
	adrp	x8, _SUN4I_TCON0_FRM_SEED_PR_REG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_SEED_PR_REG@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w2, #286331153
	bl	_regmap_write
	ldr	w0, [x19]
Lloh3:
	adrp	x8, _SUN4I_TCON0_FRM_SEED_PG_REG@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_SEED_PG_REG@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	w2, #286331153
	bl	_regmap_write
	ldr	w0, [x19]
Lloh6:
	adrp	x8, _SUN4I_TCON0_FRM_SEED_PB_REG@GOTPAGE
Lloh7:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_SEED_PB_REG@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	w2, #286331153
	bl	_regmap_write
	ldr	w0, [x19]
Lloh9:
	adrp	x8, _SUN4I_TCON0_FRM_SEED_LR_REG@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_SEED_LR_REG@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	w2, #286331153
	bl	_regmap_write
	ldr	w0, [x19]
Lloh12:
	adrp	x8, _SUN4I_TCON0_FRM_SEED_LG_REG@GOTPAGE
Lloh13:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_SEED_LG_REG@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	w2, #286331153
	bl	_regmap_write
	ldr	w0, [x19]
Lloh15:
	adrp	x8, _SUN4I_TCON0_FRM_SEED_LB_REG@GOTPAGE
Lloh16:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_SEED_LB_REG@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	mov	w2, #286331153
	bl	_regmap_write
	ldr	w0, [x19]
Lloh18:
	adrp	x8, _SUN4I_TCON0_FRM_TBL0_REG@GOTPAGE
Lloh19:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_TBL0_REG@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	mov	w2, #16842752
	bl	_regmap_write
	ldr	w0, [x19]
Lloh21:
	adrp	x8, _SUN4I_TCON0_FRM_TBL1_REG@GOTPAGE
Lloh22:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_TBL1_REG@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
	mov	w2, #4369
	movk	w2, #5397, lsl #16
	bl	_regmap_write
	ldr	w0, [x19]
Lloh24:
	adrp	x8, _SUN4I_TCON0_FRM_TBL2_REG@GOTPAGE
Lloh25:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_TBL2_REG@GOTPAGEOFF]
Lloh26:
	ldr	w1, [x8]
	mov	w2, #21845
	movk	w2, #22359, lsl #16
	bl	_regmap_write
	ldr	w0, [x19]
Lloh27:
	adrp	x8, _SUN4I_TCON0_FRM_TBL3_REG@GOTPAGE
Lloh28:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_TBL3_REG@GOTPAGEOFF]
Lloh29:
	ldr	w1, [x8]
	mov	w2, #30583
	movk	w2, #32639, lsl #16
	bl	_regmap_write
Lloh30:
	adrp	x8, _SUN4I_TCON0_FRM_CTL_EN@GOTPAGE
Lloh31:
	ldr	x8, [x8, _SUN4I_TCON0_FRM_CTL_EN@GOTPAGEOFF]
Lloh32:
	ldr	w8, [x8]
	ldp	w9, w10, [x20]
	cmp	w9, #6
	csel	w2, w8, wzr, eq
	cmp	w10, #1
	b.ne	LBB0_6
; %bb.2:
	ldr	x9, [x20, #8]
	ldr	w9, [x9]
	sub	w10, w9, #128
	cmp	w10, #2
	b.lo	LBB0_5
; %bb.3:
	cmp	w9, #130
	b.ne	LBB0_6
; %bb.4:
Lloh33:
	adrp	x9, _SUN4I_TCON0_FRM_CTL_MODE_R@GOTPAGE
Lloh34:
	ldr	x9, [x9, _SUN4I_TCON0_FRM_CTL_MODE_R@GOTPAGEOFF]
Lloh35:
	ldr	w9, [x9]
	orr	w9, w9, w2
Lloh36:
	adrp	x10, _SUN4I_TCON0_FRM_CTL_MODE_B@GOTPAGE
Lloh37:
	ldr	x10, [x10, _SUN4I_TCON0_FRM_CTL_MODE_B@GOTPAGEOFF]
Lloh38:
	ldr	w10, [x10]
	orr	w2, w9, w10
LBB0_5:
	orr	w2, w2, w8
LBB0_6:
	ldr	w0, [x19]
Lloh39:
	adrp	x8, _SUN4I_TCON_FRM_CTL_REG@GOTPAGE
Lloh40:
	ldr	x8, [x8, _SUN4I_TCON_FRM_CTL_REG@GOTPAGEOFF]
Lloh41:
	ldr	w1, [x8]
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_regmap_write
LBB0_7:
	.cfi_def_cfa wsp, 0
	.cfi_same_value w30
	.cfi_same_value w29
	.cfi_same_value w19
	.cfi_same_value w20
	ret
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.cfi_endproc
                                        ; -- End function
	.comm	_SUN4I_TCON0_FRM_SEED_PR_REG,4,2 ; @SUN4I_TCON0_FRM_SEED_PR_REG
	.comm	_SUN4I_TCON0_FRM_SEED_PG_REG,4,2 ; @SUN4I_TCON0_FRM_SEED_PG_REG
	.comm	_SUN4I_TCON0_FRM_SEED_PB_REG,4,2 ; @SUN4I_TCON0_FRM_SEED_PB_REG
	.comm	_SUN4I_TCON0_FRM_SEED_LR_REG,4,2 ; @SUN4I_TCON0_FRM_SEED_LR_REG
	.comm	_SUN4I_TCON0_FRM_SEED_LG_REG,4,2 ; @SUN4I_TCON0_FRM_SEED_LG_REG
	.comm	_SUN4I_TCON0_FRM_SEED_LB_REG,4,2 ; @SUN4I_TCON0_FRM_SEED_LB_REG
	.comm	_SUN4I_TCON0_FRM_TBL0_REG,4,2   ; @SUN4I_TCON0_FRM_TBL0_REG
	.comm	_SUN4I_TCON0_FRM_TBL1_REG,4,2   ; @SUN4I_TCON0_FRM_TBL1_REG
	.comm	_SUN4I_TCON0_FRM_TBL2_REG,4,2   ; @SUN4I_TCON0_FRM_TBL2_REG
	.comm	_SUN4I_TCON0_FRM_TBL3_REG,4,2   ; @SUN4I_TCON0_FRM_TBL3_REG
	.comm	_SUN4I_TCON0_FRM_CTL_EN,4,2     ; @SUN4I_TCON0_FRM_CTL_EN
	.comm	_SUN4I_TCON0_FRM_CTL_MODE_R,4,2 ; @SUN4I_TCON0_FRM_CTL_MODE_R
	.comm	_SUN4I_TCON0_FRM_CTL_MODE_B,4,2 ; @SUN4I_TCON0_FRM_CTL_MODE_B
	.comm	_SUN4I_TCON_FRM_CTL_REG,4,2     ; @SUN4I_TCON_FRM_CTL_REG
	.no_dead_strip	_sun4i_tcon0_mode_set_dithering
.subsections_via_symbols
