	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function zr36060_set_video
_zr36060_set_video:                     ## @zr36060_set_video
	.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	%rcx, %r12
	movq	%rdx, %r14
	movq	%rsi, %r15
	movq	(%rdi), %r13
	movl	20(%r13), %edx
	movl	(%r14), %ecx
	movl	4(%r14), %r8d
	movl	8(%r14), %r9d
	movl	12(%r14), %eax
	movl	16(%r14), %ebx
	leaq	L_.str(%rip), %rsi
	movl	$2, %edi
	pushq	%rbx
	pushq	%rax
	callq	_dprintk
	addq	$16, %rsp
	movl	8(%r14), %eax
	movl	16(%r14), %ecx
	movzbl	%cl, %esi
	cltd
	idivl	%esi
	movl	%eax, (%r13)
	movl	12(%r14), %eax
	sarl	$8, %ecx
	cltd
	idivl	%ecx
	movl	%eax, 4(%r13)
	movq	_ZR060_LOAD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_ZR060_LOAD_SyncRst@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	xorl	%ebx, %ebx
	cmpl	$0, 52(%r12)
	movl	$0, %eax
	jne	LBB0_2
## %bb.1:
	movq	_ZR060_VPR_VSPol@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_2:
	cmpl	$0, 48(%r12)
	movl	$0, %edx
	jne	LBB0_4
## %bb.3:
	movq	_ZR060_VPR_HSPol@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
LBB0_4:
	cmpq	$0, 40(%r12)
	movl	$0, %ecx
	je	LBB0_6
## %bb.5:
	movq	_ZR060_VPR_FIPol@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
LBB0_6:
	cmpq	$0, 32(%r12)
	movl	$0, %edi
	je	LBB0_8
## %bb.7:
	movq	_ZR060_VPR_BLPol@GOTPCREL(%rip), %rsi
	movl	(%rsi), %edi
LBB0_8:
	cmpq	$0, 24(%r12)
	movl	$0, %esi
	je	LBB0_10
## %bb.9:
	movq	_ZR060_VPR_SImgPol@GOTPCREL(%rip), %rsi
	movl	(%rsi), %esi
LBB0_10:
	orl	%eax, %edx
	orl	%edi, %ecx
	cmpq	$0, 16(%r12)
	movl	$0, %eax
	je	LBB0_12
## %bb.11:
	movq	_ZR060_VPR_PoePol@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_12:
	orl	%eax, %esi
	orl	%ecx, %edx
	cmpq	$0, 8(%r12)
	movl	$0, %eax
	je	LBB0_14
## %bb.13:
	movq	_ZR060_VPR_PValPol@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_14:
	orl	%eax, %esi
	orl	%esi, %edx
	cmpq	$0, (%r12)
	movl	$0, %eax
	je	LBB0_16
## %bb.15:
	movq	_ZR060_VPR_VCLKPol@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_16:
	orl	%eax, %edx
	movq	_ZR060_VPR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	16(%r14), %eax
	cmpb	$4, %al
	je	LBB0_19
## %bb.17:
	cmpb	$2, %al
	jne	LBB0_21
## %bb.18:
	movq	_ZR060_SR_HScale2@GOTPCREL(%rip), %rcx
	jmp	LBB0_20
LBB0_19:
	movq	_ZR060_SR_HScale4@GOTPCREL(%rip), %rcx
LBB0_20:
	movl	(%rcx), %ebx
LBB0_21:
	andl	$-256, %eax
	movl	$0, %edx
	cmpl	$512, %eax                      ## imm = 0x200
	jne	LBB0_23
## %bb.22:
	movq	_ZR060_SR_VScale@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
LBB0_23:
	orl	%ebx, %edx
	movq	_ZR060_SR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_BCR_Y@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_zr36060_write
	movq	_ZR060_BCR_U@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$128, %edx
	callq	_zr36060_write
	movq	_ZR060_BCR_V@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$128, %edx
	callq	_zr36060_write
	movl	(%r15), %ebx
	decl	%ebx
	movq	_ZR060_SGR_VTOTAL_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_SGR_VTOTAL_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	4(%r15), %ebx
	decl	%ebx
	movq	_ZR060_SGR_HTOTAL_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_SGR_HTOTAL_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_SGR_VSYNC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$5, %edx
	callq	_zr36060_write
	movq	_ZR060_SGR_HSYNC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	$68, %edx
	callq	_zr36060_write
	movl	8(%r15), %ebx
	leal	-1(%rbx), %edx
	movq	_ZR060_SGR_BVSTART@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	12(%r15), %eax
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%eax, %ecx
	sarl	%ecx
	addl	%ecx, %ebx
	decl	%ebx
	movq	_ZR060_SGR_BVEND_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_SGR_BVEND_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	16(%r15), %ebx
	decl	%ebx
	movq	_ZR060_SGR_BHSTART@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	%ebx, %edx
	callq	_zr36060_write
	addl	24(%r15), %ebx
	movq	_ZR060_SGR_BHEND_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_SGR_BHEND_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	8(%r15), %ebx
	addl	4(%r14), %ebx
	movq	_ZR060_AAR_VSTART_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_AAR_VSTART_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	addl	12(%r14), %ebx
	movq	_ZR060_AAR_VEND_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_AAR_VEND_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	16(%r15), %ebx
	addl	(%r14), %ebx
	movq	_ZR060_AAR_HSTART_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_AAR_HSTART_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	addl	8(%r14), %ebx
	movq	_ZR060_AAR_HEND_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_AAR_HEND_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	8(%r15), %r12d
	leal	-4(%r12), %ebx
	movq	_ZR060_SWR_VSTART_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_SWR_VSTART_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	12(%r15), %eax
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%eax, %ecx
	sarl	%ecx
	leal	(%r12,%rcx), %ebx
	addl	$4, %ebx
	movq	_ZR060_SWR_VEND_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_SWR_VEND_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	16(%r15), %r12d
	leal	-4(%r12), %ebx
	movq	_ZR060_SWR_HSTART_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_SWR_HSTART_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	24(%r15), %eax
	leal	(%r12,%rax), %ebx
	addl	$4, %ebx
	movq	_ZR060_SWR_HEND_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bh, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movq	_ZR060_SWR_HEND_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzbl	%bl, %edx
	movq	%r13, %rdi
	callq	_zr36060_write
	movl	(%r13), %eax
	movl	8(%r13), %ecx
	imull	4(%r13), %eax
	imull	20(%r14), %eax
	shll	$4, %eax
	movq	_low_bitrate@GOTPCREL(%rip), %rdx
	cmpq	$0, (%rdx)
	movl	$200, %edx
	movl	$400, %esi                      ## imm = 0x190
	cmovel	%edx, %esi
	cltd
	idivl	%esi
	cmpl	$8193, %eax                     ## imm = 0x2001
	movl	$8192, %edx                     ## imm = 0x2000
	cmovgel	%eax, %edx
	leal	(,%rcx,8), %eax
	subl	%ecx, %eax
	cmpl	%eax, %edx
	cmovll	%edx, %eax
	sarl	$3, %eax
	movl	%eax, 12(%r13)
	movl	16(%r13), %edx
	movq	_ZR060_MBCVR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_zr36060_write
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s: set_video %d/%d-%dx%d (%%%d) call\n"

	.comm	_ZR060_LOAD,4,2                 ## @ZR060_LOAD
	.comm	_ZR060_LOAD_SyncRst,4,2         ## @ZR060_LOAD_SyncRst
	.comm	_ZR060_VPR_VSPol,4,2            ## @ZR060_VPR_VSPol
	.comm	_ZR060_VPR_HSPol,4,2            ## @ZR060_VPR_HSPol
	.comm	_ZR060_VPR_FIPol,4,2            ## @ZR060_VPR_FIPol
	.comm	_ZR060_VPR_BLPol,4,2            ## @ZR060_VPR_BLPol
	.comm	_ZR060_VPR_SImgPol,4,2          ## @ZR060_VPR_SImgPol
	.comm	_ZR060_VPR_PoePol,4,2           ## @ZR060_VPR_PoePol
	.comm	_ZR060_VPR_PValPol,4,2          ## @ZR060_VPR_PValPol
	.comm	_ZR060_VPR_VCLKPol,4,2          ## @ZR060_VPR_VCLKPol
	.comm	_ZR060_VPR,4,2                  ## @ZR060_VPR
	.comm	_ZR060_SR_HScale2,4,2           ## @ZR060_SR_HScale2
	.comm	_ZR060_SR_HScale4,4,2           ## @ZR060_SR_HScale4
	.comm	_ZR060_SR_VScale,4,2            ## @ZR060_SR_VScale
	.comm	_ZR060_SR,4,2                   ## @ZR060_SR
	.comm	_ZR060_BCR_Y,4,2                ## @ZR060_BCR_Y
	.comm	_ZR060_BCR_U,4,2                ## @ZR060_BCR_U
	.comm	_ZR060_BCR_V,4,2                ## @ZR060_BCR_V
	.comm	_ZR060_SGR_VTOTAL_HI,4,2        ## @ZR060_SGR_VTOTAL_HI
	.comm	_ZR060_SGR_VTOTAL_LO,4,2        ## @ZR060_SGR_VTOTAL_LO
	.comm	_ZR060_SGR_HTOTAL_HI,4,2        ## @ZR060_SGR_HTOTAL_HI
	.comm	_ZR060_SGR_HTOTAL_LO,4,2        ## @ZR060_SGR_HTOTAL_LO
	.comm	_ZR060_SGR_VSYNC,4,2            ## @ZR060_SGR_VSYNC
	.comm	_ZR060_SGR_HSYNC,4,2            ## @ZR060_SGR_HSYNC
	.comm	_ZR060_SGR_BVSTART,4,2          ## @ZR060_SGR_BVSTART
	.comm	_ZR060_SGR_BVEND_HI,4,2         ## @ZR060_SGR_BVEND_HI
	.comm	_ZR060_SGR_BVEND_LO,4,2         ## @ZR060_SGR_BVEND_LO
	.comm	_ZR060_SGR_BHSTART,4,2          ## @ZR060_SGR_BHSTART
	.comm	_ZR060_SGR_BHEND_HI,4,2         ## @ZR060_SGR_BHEND_HI
	.comm	_ZR060_SGR_BHEND_LO,4,2         ## @ZR060_SGR_BHEND_LO
	.comm	_ZR060_AAR_VSTART_HI,4,2        ## @ZR060_AAR_VSTART_HI
	.comm	_ZR060_AAR_VSTART_LO,4,2        ## @ZR060_AAR_VSTART_LO
	.comm	_ZR060_AAR_VEND_HI,4,2          ## @ZR060_AAR_VEND_HI
	.comm	_ZR060_AAR_VEND_LO,4,2          ## @ZR060_AAR_VEND_LO
	.comm	_ZR060_AAR_HSTART_HI,4,2        ## @ZR060_AAR_HSTART_HI
	.comm	_ZR060_AAR_HSTART_LO,4,2        ## @ZR060_AAR_HSTART_LO
	.comm	_ZR060_AAR_HEND_HI,4,2          ## @ZR060_AAR_HEND_HI
	.comm	_ZR060_AAR_HEND_LO,4,2          ## @ZR060_AAR_HEND_LO
	.comm	_ZR060_SWR_VSTART_HI,4,2        ## @ZR060_SWR_VSTART_HI
	.comm	_ZR060_SWR_VSTART_LO,4,2        ## @ZR060_SWR_VSTART_LO
	.comm	_ZR060_SWR_VEND_HI,4,2          ## @ZR060_SWR_VEND_HI
	.comm	_ZR060_SWR_VEND_LO,4,2          ## @ZR060_SWR_VEND_LO
	.comm	_ZR060_SWR_HSTART_HI,4,2        ## @ZR060_SWR_HSTART_HI
	.comm	_ZR060_SWR_HSTART_LO,4,2        ## @ZR060_SWR_HSTART_LO
	.comm	_ZR060_SWR_HEND_HI,4,2          ## @ZR060_SWR_HEND_HI
	.comm	_ZR060_SWR_HEND_LO,4,2          ## @ZR060_SWR_HEND_LO
	.comm	_low_bitrate,8,3                ## @low_bitrate
	.comm	_ZR060_MBCVR,4,2                ## @ZR060_MBCVR
	.no_dead_strip	_zr36060_set_video
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function zr36060_set_video
_zr36060_set_video:                     ; @zr36060_set_video
	.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
	mov	x22, x3
	mov	x20, x2
	mov	x21, x1
	ldr	x19, [x0]
	ldr	w2, [x19, #20]
	ldp	w3, w4, [x20]
	ldp	w5, w6, [x20, #8]
	ldr	w7, [x20, #16]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #2
	bl	_dprintk
	ldp	w11, w8, [x20, #12]
	and	w9, w8, #0xff
	ldr	w10, [x20, #8]
	sdiv	w9, w10, w9
	asr	w8, w8, #8
	sdiv	w8, w11, w8
	stp	w9, w8, [x19]
Lloh2:
	adrp	x8, _ZR060_LOAD@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ZR060_LOAD@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	adrp	x8, _ZR060_LOAD_SyncRst@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ZR060_LOAD_SyncRst@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_zr36060_write
Lloh8:
	adrp	x8, _ZR060_VPR_VSPol@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ZR060_VPR_VSPol@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	ldp	w10, w9, [x22, #48]
	cmp	w9, #0
	csel	w8, w8, wzr, eq
Lloh11:
	adrp	x9, _ZR060_VPR_HSPol@GOTPAGE
Lloh12:
	ldr	x9, [x9, _ZR060_VPR_HSPol@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	cmp	w10, #0
	csel	w9, w9, wzr, eq
	orr	w8, w9, w8
Lloh14:
	adrp	x9, _ZR060_VPR_FIPol@GOTPAGE
Lloh15:
	ldr	x9, [x9, _ZR060_VPR_FIPol@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	ldp	x11, x10, [x22, #32]
	cmp	x10, #0
	csel	w9, wzr, w9, eq
Lloh17:
	adrp	x10, _ZR060_VPR_BLPol@GOTPAGE
Lloh18:
	ldr	x10, [x10, _ZR060_VPR_BLPol@GOTPAGEOFF]
	orr	w8, w8, w9
Lloh19:
	ldr	w9, [x10]
	cmp	x11, #0
	csel	w9, wzr, w9, eq
	orr	w8, w8, w9
	ldp	x10, x9, [x22, #16]
	cmp	x9, #0
Lloh20:
	adrp	x9, _ZR060_VPR_SImgPol@GOTPAGE
Lloh21:
	ldr	x9, [x9, _ZR060_VPR_SImgPol@GOTPAGEOFF]
Lloh22:
	ldr	w9, [x9]
	csel	w9, wzr, w9, eq
	orr	w8, w8, w9
Lloh23:
	adrp	x9, _ZR060_VPR_PoePol@GOTPAGE
Lloh24:
	ldr	x9, [x9, _ZR060_VPR_PoePol@GOTPAGEOFF]
Lloh25:
	ldr	w9, [x9]
	cmp	x10, #0
	csel	w9, wzr, w9, eq
	orr	w8, w8, w9
Lloh26:
	adrp	x9, _ZR060_VPR_PValPol@GOTPAGE
Lloh27:
	ldr	x9, [x9, _ZR060_VPR_PValPol@GOTPAGEOFF]
Lloh28:
	ldr	w9, [x9]
	ldp	x11, x10, [x22]
	cmp	x10, #0
	csel	w9, wzr, w9, eq
	orr	w8, w8, w9
Lloh29:
	adrp	x9, _ZR060_VPR_VCLKPol@GOTPAGE
Lloh30:
	ldr	x9, [x9, _ZR060_VPR_VCLKPol@GOTPAGEOFF]
Lloh31:
	ldr	w9, [x9]
	cmp	x11, #0
	csel	w9, wzr, w9, eq
	orr	w2, w8, w9
Lloh32:
	adrp	x8, _ZR060_VPR@GOTPAGE
Lloh33:
	ldr	x8, [x8, _ZR060_VPR@GOTPAGEOFF]
Lloh34:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_zr36060_write
	ldr	w8, [x20, #16]
	and	w10, w8, #0xff
	cmp	w10, #4
	b.eq	LBB0_3
; %bb.1:
	mov	w9, #0
	cmp	w10, #2
	b.ne	LBB0_5
; %bb.2:
Lloh35:
	adrp	x9, _ZR060_SR_HScale2@GOTPAGE
Lloh36:
	ldr	x9, [x9, _ZR060_SR_HScale2@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:
Lloh37:
	adrp	x9, _ZR060_SR_HScale4@GOTPAGE
Lloh38:
	ldr	x9, [x9, _ZR060_SR_HScale4@GOTPAGEOFF]
LBB0_4:
	ldr	w9, [x9]
LBB0_5:
	and	w8, w8, #0xffffff00
Lloh39:
	adrp	x10, _ZR060_SR_VScale@GOTPAGE
Lloh40:
	ldr	x10, [x10, _ZR060_SR_VScale@GOTPAGEOFF]
Lloh41:
	ldr	w10, [x10]
	cmp	w8, #512
	csel	w8, w10, wzr, eq
	orr	w2, w8, w9
Lloh42:
	adrp	x8, _ZR060_SR@GOTPAGE
Lloh43:
	ldr	x8, [x8, _ZR060_SR@GOTPAGEOFF]
Lloh44:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_zr36060_write
Lloh45:
	adrp	x8, _ZR060_BCR_Y@GOTPAGE
Lloh46:
	ldr	x8, [x8, _ZR060_BCR_Y@GOTPAGEOFF]
Lloh47:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_zr36060_write
Lloh48:
	adrp	x8, _ZR060_BCR_U@GOTPAGE
Lloh49:
	ldr	x8, [x8, _ZR060_BCR_U@GOTPAGEOFF]
Lloh50:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #128
	bl	_zr36060_write
Lloh51:
	adrp	x8, _ZR060_BCR_V@GOTPAGE
Lloh52:
	ldr	x8, [x8, _ZR060_BCR_V@GOTPAGEOFF]
Lloh53:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #128
	bl	_zr36060_write
	ldr	w8, [x21]
	sub	w22, w8, #1
Lloh54:
	adrp	x8, _ZR060_SGR_VTOTAL_HI@GOTPAGE
Lloh55:
	ldr	x8, [x8, _ZR060_SGR_VTOTAL_HI@GOTPAGEOFF]
Lloh56:
	ldr	w1, [x8]
	ubfx	w2, w22, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh57:
	adrp	x8, _ZR060_SGR_VTOTAL_LO@GOTPAGE
Lloh58:
	ldr	x8, [x8, _ZR060_SGR_VTOTAL_LO@GOTPAGEOFF]
Lloh59:
	ldr	w1, [x8]
	and	w2, w22, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldr	w8, [x21, #4]
	sub	w22, w8, #1
Lloh60:
	adrp	x8, _ZR060_SGR_HTOTAL_HI@GOTPAGE
Lloh61:
	ldr	x8, [x8, _ZR060_SGR_HTOTAL_HI@GOTPAGEOFF]
Lloh62:
	ldr	w1, [x8]
	ubfx	w2, w22, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh63:
	adrp	x8, _ZR060_SGR_HTOTAL_LO@GOTPAGE
Lloh64:
	ldr	x8, [x8, _ZR060_SGR_HTOTAL_LO@GOTPAGEOFF]
Lloh65:
	ldr	w1, [x8]
	and	w2, w22, #0xff
	mov	x0, x19
	bl	_zr36060_write
Lloh66:
	adrp	x8, _ZR060_SGR_VSYNC@GOTPAGE
Lloh67:
	ldr	x8, [x8, _ZR060_SGR_VSYNC@GOTPAGEOFF]
Lloh68:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #5
	bl	_zr36060_write
Lloh69:
	adrp	x8, _ZR060_SGR_HSYNC@GOTPAGE
Lloh70:
	ldr	x8, [x8, _ZR060_SGR_HSYNC@GOTPAGEOFF]
Lloh71:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #68
	bl	_zr36060_write
	ldr	w8, [x21, #8]
	sub	w22, w8, #1
Lloh72:
	adrp	x8, _ZR060_SGR_BVSTART@GOTPAGE
Lloh73:
	ldr	x8, [x8, _ZR060_SGR_BVSTART@GOTPAGEOFF]
Lloh74:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x22
	bl	_zr36060_write
	ldr	w8, [x21, #12]
	cmp	w8, #0
	cinc	w8, w8, lt
	add	w22, w22, w8, asr #1
Lloh75:
	adrp	x8, _ZR060_SGR_BVEND_HI@GOTPAGE
Lloh76:
	ldr	x8, [x8, _ZR060_SGR_BVEND_HI@GOTPAGEOFF]
Lloh77:
	ldr	w1, [x8]
	ubfx	w2, w22, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh78:
	adrp	x8, _ZR060_SGR_BVEND_LO@GOTPAGE
Lloh79:
	ldr	x8, [x8, _ZR060_SGR_BVEND_LO@GOTPAGEOFF]
Lloh80:
	ldr	w1, [x8]
	and	w2, w22, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldr	w8, [x21, #16]
	sub	w22, w8, #1
Lloh81:
	adrp	x8, _ZR060_SGR_BHSTART@GOTPAGE
Lloh82:
	ldr	x8, [x8, _ZR060_SGR_BHSTART@GOTPAGEOFF]
Lloh83:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x22
	bl	_zr36060_write
	ldr	w8, [x21, #24]
	add	w22, w22, w8
Lloh84:
	adrp	x8, _ZR060_SGR_BHEND_HI@GOTPAGE
Lloh85:
	ldr	x8, [x8, _ZR060_SGR_BHEND_HI@GOTPAGEOFF]
Lloh86:
	ldr	w1, [x8]
	ubfx	w2, w22, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh87:
	adrp	x8, _ZR060_SGR_BHEND_LO@GOTPAGE
Lloh88:
	ldr	x8, [x8, _ZR060_SGR_BHEND_LO@GOTPAGEOFF]
Lloh89:
	ldr	w1, [x8]
	and	w2, w22, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldr	w8, [x20, #4]
	ldr	w9, [x21, #8]
	add	w22, w9, w8
Lloh90:
	adrp	x8, _ZR060_AAR_VSTART_HI@GOTPAGE
Lloh91:
	ldr	x8, [x8, _ZR060_AAR_VSTART_HI@GOTPAGEOFF]
Lloh92:
	ldr	w1, [x8]
	ubfx	w2, w22, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh93:
	adrp	x8, _ZR060_AAR_VSTART_LO@GOTPAGE
Lloh94:
	ldr	x8, [x8, _ZR060_AAR_VSTART_LO@GOTPAGEOFF]
Lloh95:
	ldr	w1, [x8]
	and	w2, w22, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldr	w8, [x20, #12]
	add	w22, w8, w22
Lloh96:
	adrp	x8, _ZR060_AAR_VEND_HI@GOTPAGE
Lloh97:
	ldr	x8, [x8, _ZR060_AAR_VEND_HI@GOTPAGEOFF]
Lloh98:
	ldr	w1, [x8]
	ubfx	w2, w22, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh99:
	adrp	x8, _ZR060_AAR_VEND_LO@GOTPAGE
Lloh100:
	ldr	x8, [x8, _ZR060_AAR_VEND_LO@GOTPAGEOFF]
Lloh101:
	ldr	w1, [x8]
	and	w2, w22, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldr	w8, [x20]
	ldr	w9, [x21, #16]
	add	w22, w9, w8
Lloh102:
	adrp	x8, _ZR060_AAR_HSTART_HI@GOTPAGE
Lloh103:
	ldr	x8, [x8, _ZR060_AAR_HSTART_HI@GOTPAGEOFF]
Lloh104:
	ldr	w1, [x8]
	ubfx	w2, w22, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh105:
	adrp	x8, _ZR060_AAR_HSTART_LO@GOTPAGE
Lloh106:
	ldr	x8, [x8, _ZR060_AAR_HSTART_LO@GOTPAGEOFF]
Lloh107:
	ldr	w1, [x8]
	and	w2, w22, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldr	w8, [x20, #8]
	add	w22, w8, w22
Lloh108:
	adrp	x8, _ZR060_AAR_HEND_HI@GOTPAGE
Lloh109:
	ldr	x8, [x8, _ZR060_AAR_HEND_HI@GOTPAGEOFF]
Lloh110:
	ldr	w1, [x8]
	ubfx	w2, w22, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh111:
	adrp	x8, _ZR060_AAR_HEND_LO@GOTPAGE
Lloh112:
	ldr	x8, [x8, _ZR060_AAR_HEND_LO@GOTPAGEOFF]
Lloh113:
	ldr	w1, [x8]
	and	w2, w22, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldr	w22, [x21, #8]
	sub	w23, w22, #4
Lloh114:
	adrp	x8, _ZR060_SWR_VSTART_HI@GOTPAGE
Lloh115:
	ldr	x8, [x8, _ZR060_SWR_VSTART_HI@GOTPAGEOFF]
Lloh116:
	ldr	w1, [x8]
	ubfx	w2, w23, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh117:
	adrp	x8, _ZR060_SWR_VSTART_LO@GOTPAGE
Lloh118:
	ldr	x8, [x8, _ZR060_SWR_VSTART_LO@GOTPAGEOFF]
Lloh119:
	ldr	w1, [x8]
	and	w2, w23, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldr	w8, [x21, #12]
	cmp	w8, #0
	cinc	w8, w8, lt
	add	w8, w22, w8, asr #1
	add	w22, w8, #4
Lloh120:
	adrp	x8, _ZR060_SWR_VEND_HI@GOTPAGE
Lloh121:
	ldr	x8, [x8, _ZR060_SWR_VEND_HI@GOTPAGEOFF]
Lloh122:
	ldr	w1, [x8]
	ubfx	w2, w22, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh123:
	adrp	x8, _ZR060_SWR_VEND_LO@GOTPAGE
Lloh124:
	ldr	x8, [x8, _ZR060_SWR_VEND_LO@GOTPAGEOFF]
Lloh125:
	ldr	w1, [x8]
	and	w2, w22, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldr	w22, [x21, #16]
	sub	w23, w22, #4
Lloh126:
	adrp	x8, _ZR060_SWR_HSTART_HI@GOTPAGE
Lloh127:
	ldr	x8, [x8, _ZR060_SWR_HSTART_HI@GOTPAGEOFF]
Lloh128:
	ldr	w1, [x8]
	ubfx	w2, w23, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh129:
	adrp	x8, _ZR060_SWR_HSTART_LO@GOTPAGE
Lloh130:
	ldr	x8, [x8, _ZR060_SWR_HSTART_LO@GOTPAGEOFF]
Lloh131:
	ldr	w1, [x8]
	and	w2, w23, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldr	w8, [x21, #24]
	add	w8, w22, w8
	add	w21, w8, #4
Lloh132:
	adrp	x8, _ZR060_SWR_HEND_HI@GOTPAGE
Lloh133:
	ldr	x8, [x8, _ZR060_SWR_HEND_HI@GOTPAGEOFF]
Lloh134:
	ldr	w1, [x8]
	ubfx	w2, w21, #8, #8
	mov	x0, x19
	bl	_zr36060_write
Lloh135:
	adrp	x8, _ZR060_SWR_HEND_LO@GOTPAGE
Lloh136:
	ldr	x8, [x8, _ZR060_SWR_HEND_LO@GOTPAGEOFF]
Lloh137:
	ldr	w1, [x8]
	and	w2, w21, #0xff
	mov	x0, x19
	bl	_zr36060_write
	ldp	w8, w9, [x19]
	ldr	w10, [x20, #20]
	mul	w8, w8, w9
	mul	w8, w8, w10
	lsl	w8, w8, #4
Lloh138:
	adrp	x9, _low_bitrate@GOTPAGE
Lloh139:
	ldr	x9, [x9, _low_bitrate@GOTPAGEOFF]
Lloh140:
	ldr	x9, [x9]
	cmp	x9, #0
	mov	w9, #400
	mov	w10, #200
	csel	w9, w10, w9, eq
	sdiv	w8, w8, w9
	mov	w9, #8192
	cmp	w8, #2, lsl #12                 ; =8192
	csel	w8, w8, w9, gt
	ldr	w9, [x19, #8]
	lsl	w10, w9, #3
	sub	w9, w10, w9
	cmp	w8, w9
	csel	w8, w8, w9, lt
	asr	w8, w8, #3
	str	w8, [x19, #12]
	ldr	w2, [x19, #16]
Lloh141:
	adrp	x8, _ZR060_MBCVR@GOTPAGE
Lloh142:
	ldr	x8, [x8, _ZR060_MBCVR@GOTPAGEOFF]
Lloh143:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_zr36060_write
	mov	w0, #0
	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
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpLdrGot	Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh141, Lloh142, Lloh143
	.loh AdrpLdrGotLdr	Lloh138, Lloh139, Lloh140
	.loh AdrpLdrGotLdr	Lloh135, Lloh136, Lloh137
	.loh AdrpLdrGotLdr	Lloh132, Lloh133, Lloh134
	.loh AdrpLdrGotLdr	Lloh129, Lloh130, Lloh131
	.loh AdrpLdrGotLdr	Lloh126, Lloh127, Lloh128
	.loh AdrpLdrGotLdr	Lloh123, Lloh124, Lloh125
	.loh AdrpLdrGotLdr	Lloh120, Lloh121, Lloh122
	.loh AdrpLdrGotLdr	Lloh117, Lloh118, Lloh119
	.loh AdrpLdrGotLdr	Lloh114, Lloh115, Lloh116
	.loh AdrpLdrGotLdr	Lloh111, Lloh112, Lloh113
	.loh AdrpLdrGotLdr	Lloh108, Lloh109, Lloh110
	.loh AdrpLdrGotLdr	Lloh105, Lloh106, Lloh107
	.loh AdrpLdrGotLdr	Lloh102, Lloh103, Lloh104
	.loh AdrpLdrGotLdr	Lloh99, Lloh100, Lloh101
	.loh AdrpLdrGotLdr	Lloh96, Lloh97, Lloh98
	.loh AdrpLdrGotLdr	Lloh93, Lloh94, Lloh95
	.loh AdrpLdrGotLdr	Lloh90, Lloh91, Lloh92
	.loh AdrpLdrGotLdr	Lloh87, Lloh88, Lloh89
	.loh AdrpLdrGotLdr	Lloh84, Lloh85, Lloh86
	.loh AdrpLdrGotLdr	Lloh81, Lloh82, Lloh83
	.loh AdrpLdrGotLdr	Lloh78, Lloh79, Lloh80
	.loh AdrpLdrGotLdr	Lloh75, Lloh76, Lloh77
	.loh AdrpLdrGotLdr	Lloh72, Lloh73, Lloh74
	.loh AdrpLdrGotLdr	Lloh69, Lloh70, Lloh71
	.loh AdrpLdrGotLdr	Lloh66, Lloh67, Lloh68
	.loh AdrpLdrGotLdr	Lloh63, Lloh64, Lloh65
	.loh AdrpLdrGotLdr	Lloh60, Lloh61, Lloh62
	.loh AdrpLdrGotLdr	Lloh57, Lloh58, Lloh59
	.loh AdrpLdrGotLdr	Lloh54, Lloh55, Lloh56
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s: set_video %d/%d-%dx%d (%%%d) call\n"

	.comm	_ZR060_LOAD,4,2                 ; @ZR060_LOAD
	.comm	_ZR060_LOAD_SyncRst,4,2         ; @ZR060_LOAD_SyncRst
	.comm	_ZR060_VPR_VSPol,4,2            ; @ZR060_VPR_VSPol
	.comm	_ZR060_VPR_HSPol,4,2            ; @ZR060_VPR_HSPol
	.comm	_ZR060_VPR_FIPol,4,2            ; @ZR060_VPR_FIPol
	.comm	_ZR060_VPR_BLPol,4,2            ; @ZR060_VPR_BLPol
	.comm	_ZR060_VPR_SImgPol,4,2          ; @ZR060_VPR_SImgPol
	.comm	_ZR060_VPR_PoePol,4,2           ; @ZR060_VPR_PoePol
	.comm	_ZR060_VPR_PValPol,4,2          ; @ZR060_VPR_PValPol
	.comm	_ZR060_VPR_VCLKPol,4,2          ; @ZR060_VPR_VCLKPol
	.comm	_ZR060_VPR,4,2                  ; @ZR060_VPR
	.comm	_ZR060_SR_HScale2,4,2           ; @ZR060_SR_HScale2
	.comm	_ZR060_SR_HScale4,4,2           ; @ZR060_SR_HScale4
	.comm	_ZR060_SR_VScale,4,2            ; @ZR060_SR_VScale
	.comm	_ZR060_SR,4,2                   ; @ZR060_SR
	.comm	_ZR060_BCR_Y,4,2                ; @ZR060_BCR_Y
	.comm	_ZR060_BCR_U,4,2                ; @ZR060_BCR_U
	.comm	_ZR060_BCR_V,4,2                ; @ZR060_BCR_V
	.comm	_ZR060_SGR_VTOTAL_HI,4,2        ; @ZR060_SGR_VTOTAL_HI
	.comm	_ZR060_SGR_VTOTAL_LO,4,2        ; @ZR060_SGR_VTOTAL_LO
	.comm	_ZR060_SGR_HTOTAL_HI,4,2        ; @ZR060_SGR_HTOTAL_HI
	.comm	_ZR060_SGR_HTOTAL_LO,4,2        ; @ZR060_SGR_HTOTAL_LO
	.comm	_ZR060_SGR_VSYNC,4,2            ; @ZR060_SGR_VSYNC
	.comm	_ZR060_SGR_HSYNC,4,2            ; @ZR060_SGR_HSYNC
	.comm	_ZR060_SGR_BVSTART,4,2          ; @ZR060_SGR_BVSTART
	.comm	_ZR060_SGR_BVEND_HI,4,2         ; @ZR060_SGR_BVEND_HI
	.comm	_ZR060_SGR_BVEND_LO,4,2         ; @ZR060_SGR_BVEND_LO
	.comm	_ZR060_SGR_BHSTART,4,2          ; @ZR060_SGR_BHSTART
	.comm	_ZR060_SGR_BHEND_HI,4,2         ; @ZR060_SGR_BHEND_HI
	.comm	_ZR060_SGR_BHEND_LO,4,2         ; @ZR060_SGR_BHEND_LO
	.comm	_ZR060_AAR_VSTART_HI,4,2        ; @ZR060_AAR_VSTART_HI
	.comm	_ZR060_AAR_VSTART_LO,4,2        ; @ZR060_AAR_VSTART_LO
	.comm	_ZR060_AAR_VEND_HI,4,2          ; @ZR060_AAR_VEND_HI
	.comm	_ZR060_AAR_VEND_LO,4,2          ; @ZR060_AAR_VEND_LO
	.comm	_ZR060_AAR_HSTART_HI,4,2        ; @ZR060_AAR_HSTART_HI
	.comm	_ZR060_AAR_HSTART_LO,4,2        ; @ZR060_AAR_HSTART_LO
	.comm	_ZR060_AAR_HEND_HI,4,2          ; @ZR060_AAR_HEND_HI
	.comm	_ZR060_AAR_HEND_LO,4,2          ; @ZR060_AAR_HEND_LO
	.comm	_ZR060_SWR_VSTART_HI,4,2        ; @ZR060_SWR_VSTART_HI
	.comm	_ZR060_SWR_VSTART_LO,4,2        ; @ZR060_SWR_VSTART_LO
	.comm	_ZR060_SWR_VEND_HI,4,2          ; @ZR060_SWR_VEND_HI
	.comm	_ZR060_SWR_VEND_LO,4,2          ; @ZR060_SWR_VEND_LO
	.comm	_ZR060_SWR_HSTART_HI,4,2        ; @ZR060_SWR_HSTART_HI
	.comm	_ZR060_SWR_HSTART_LO,4,2        ; @ZR060_SWR_HSTART_LO
	.comm	_ZR060_SWR_HEND_HI,4,2          ; @ZR060_SWR_HEND_HI
	.comm	_ZR060_SWR_HEND_LO,4,2          ; @ZR060_SWR_HEND_LO
	.comm	_low_bitrate,8,3                ; @low_bitrate
	.comm	_ZR060_MBCVR,4,2                ; @ZR060_MBCVR
	.no_dead_strip	_zr36060_set_video
.subsections_via_symbols
