	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nouveau_connector_mode_valid
_nouveau_connector_mode_valid:          ## @nouveau_connector_mode_valid
	.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	%rsi, %r14
	movq	%rdi, %r15
	callq	_nouveau_connector
	movq	%rax, %r12
	movq	8(%rax), %rbx
	movq	%rbx, %rdi
	callq	_to_drm_encoder
	movq	%rax, %r13
	movq	8(%rbx), %rax
	movl	(%rax), %ecx
	addl	$-128, %ecx
	cmpl	$4, %ecx
	ja	LBB0_9
## %bb.1:
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movl	(%r14), %r14d
	leaq	LJTI0_0(%rip), %rdx
	movslq	(%rdx,%rcx,4), %rcx
	addq	%rdx, %rcx
	jmpq	*%rcx
LBB0_7:
	movq	%r13, %rdi
	callq	_get_slave_funcs
	movq	(%rax), %rax
	movq	%r13, %rdi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmpq	*%rax                           ## TAILCALL
LBB0_9:
	xorl	%eax, %eax
	callq	_BUG
	movq	_MODE_BAD@GOTPCREL(%rip), %rax
	jmp	LBB0_17
LBB0_10:
	movq	%r15, %rdi
	callq	_get_tmds_link_bandwidth
	jmp	LBB0_11
LBB0_2:
	movq	(%r12), %rcx
	movl	$400000, %eax                   ## imm = 0x61A80
	xorl	%edx, %edx
	testq	%rcx, %rcx
	je	LBB0_12
## %bb.3:
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movl	12(%rsi), %esi
	cmpl	4(%rcx), %esi
	jg	LBB0_5
## %bb.4:
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movl	8(%rsi), %esi
	cmpl	(%rcx), %esi
	jle	LBB0_12
LBB0_5:
	movq	_MODE_PANEL@GOTPCREL(%rip), %rax
	jmp	LBB0_17
LBB0_8:
	movl	4(%rbx), %eax
	imull	(%rbx), %eax
	imull	(%r15), %r14d
	leal	(%r14,%r14,2), %ecx
	movl	$3435973837, %r14d              ## imm = 0xCCCCCCCD
	imulq	%rcx, %r14
	shrq	$35, %r14
	jmp	LBB0_11
LBB0_6:
	movl	4(%rax), %ecx
	testl	%ecx, %ecx
	movl	$350000, %eax                   ## imm = 0x55730
	cmovnel	%ecx, %eax
LBB0_11:
	movl	$25000, %edx                    ## imm = 0x61A8
LBB0_12:
	movq	_DRM_MODE_FLAG_3D_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	andl	4(%rsi), %ecx
	movq	_DRM_MODE_FLAG_3D_FRAME_PACKING@GOTPCREL(%rip), %rsi
	cmpl	(%rsi), %ecx
	sete	%cl
	shll	%cl, %r14d
	cmpl	%edx, %r14d
	jae	LBB0_14
## %bb.13:
	movq	_MODE_CLOCK_LOW@GOTPCREL(%rip), %rax
	jmp	LBB0_17
LBB0_14:
	cmpl	%eax, %r14d
	jbe	LBB0_16
## %bb.15:
	movq	_MODE_CLOCK_HIGH@GOTPCREL(%rip), %rax
	jmp	LBB0_17
LBB0_16:
	movq	_MODE_OK@GOTPCREL(%rip), %rax
LBB0_17:
	movl	(%rax), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_7, LBB0_7-LJTI0_0
.set L0_0_set_10, LBB0_10-LJTI0_0
.set L0_0_set_2, LBB0_2-LJTI0_0
.set L0_0_set_8, LBB0_8-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
LJTI0_0:
	.long	L0_0_set_7
	.long	L0_0_set_10
	.long	L0_0_set_2
	.long	L0_0_set_8
	.long	L0_0_set_6
	.end_data_region
                                        ## -- End function
	.comm	_MODE_PANEL,4,2                 ## @MODE_PANEL
	.comm	_MODE_BAD,4,2                   ## @MODE_BAD
	.comm	_DRM_MODE_FLAG_3D_MASK,4,2      ## @DRM_MODE_FLAG_3D_MASK
	.comm	_DRM_MODE_FLAG_3D_FRAME_PACKING,4,2 ## @DRM_MODE_FLAG_3D_FRAME_PACKING
	.comm	_MODE_CLOCK_LOW,4,2             ## @MODE_CLOCK_LOW
	.comm	_MODE_CLOCK_HIGH,4,2            ## @MODE_CLOCK_HIGH
	.comm	_MODE_OK,4,2                    ## @MODE_OK
	.no_dead_strip	_nouveau_connector_mode_valid
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nouveau_connector_mode_valid
_nouveau_connector_mode_valid:          ; @nouveau_connector_mode_valid
	.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	x19, x1
	mov	x20, x0
	bl	_nouveau_connector
	mov	x21, x0
	ldr	x22, [x0, #8]
	mov	x0, x22
	bl	_to_drm_encoder
	ldr	x8, [x22, #8]
	ldr	w9, [x8]
	sub	w9, w9, #128
	cmp	w9, #4
	b.hi	LBB0_3
; %bb.1:
	ldr	w24, [x19]
Lloh0:
	adrp	x10, lJTI0_0@PAGE
Lloh1:
	add	x10, x10, lJTI0_0@PAGEOFF
	adr	x11, LBB0_2
	ldrb	w12, [x10, x9]
	add	x11, x11, x12, lsl #2
	br	x11
LBB0_2:
	mov	x23, x0
	bl	_get_slave_funcs
	ldr	x2, [x0]
	mov	x0, x23
	mov	x1, x19
	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
	br	x2
LBB0_3:
	bl	_BUG
Lloh2:
	adrp	x8, _MODE_BAD@GOTPAGE
Lloh3:
	ldr	x8, [x8, _MODE_BAD@GOTPAGEOFF]
	b	LBB0_17
LBB0_4:
	mov	x0, x20
	bl	_get_tmds_link_bandwidth
	b	LBB0_11
LBB0_5:
	mov	w0, #6784
	movk	w0, #6, lsl #16
	ldr	x8, [x21]
	cbz	x8, LBB0_12
; %bb.6:
	ldr	w9, [x19, #12]
	ldr	w10, [x8, #4]
	cmp	w9, w10
	b.gt	LBB0_8
; %bb.7:
	ldr	w9, [x19, #8]
	ldr	w8, [x8]
	cmp	w9, w8
	b.le	LBB0_18
LBB0_8:
Lloh4:
	adrp	x8, _MODE_PANEL@GOTPAGE
Lloh5:
	ldr	x8, [x8, _MODE_PANEL@GOTPAGEOFF]
	b	LBB0_17
LBB0_9:
	ldp	w8, w9, [x22]
	mul	w0, w9, w8
	ldr	w8, [x20]
	mul	w8, w24, w8
	add	w8, w8, w8, lsl #1
	mov	w9, #52429
	movk	w9, #52428, lsl #16
	umull	x8, w8, w9
	lsr	x24, x8, #35
	b	LBB0_11
LBB0_10:
	ldr	w8, [x8, #4]
	mov	w9, #22320
	movk	w9, #5, lsl #16
	cmp	w8, #0
	csel	w0, w9, w8, eq
LBB0_11:
	mov	w8, #25000
LBB0_12:
	ldr	w9, [x19, #4]
Lloh6:
	adrp	x10, _DRM_MODE_FLAG_3D_MASK@GOTPAGE
Lloh7:
	ldr	x10, [x10, _DRM_MODE_FLAG_3D_MASK@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
Lloh9:
	adrp	x11, _DRM_MODE_FLAG_3D_FRAME_PACKING@GOTPAGE
Lloh10:
	ldr	x11, [x11, _DRM_MODE_FLAG_3D_FRAME_PACKING@GOTPAGEOFF]
	and	w9, w10, w9
Lloh11:
	ldr	w10, [x11]
	cmp	w9, w10
	cset	w9, eq
	lsl	w9, w24, w9
	cmp	w9, w8
	b.hs	LBB0_14
; %bb.13:
Lloh12:
	adrp	x8, _MODE_CLOCK_LOW@GOTPAGE
Lloh13:
	ldr	x8, [x8, _MODE_CLOCK_LOW@GOTPAGEOFF]
	b	LBB0_17
LBB0_14:
	cmp	w9, w0
	b.ls	LBB0_16
; %bb.15:
Lloh14:
	adrp	x8, _MODE_CLOCK_HIGH@GOTPAGE
Lloh15:
	ldr	x8, [x8, _MODE_CLOCK_HIGH@GOTPAGEOFF]
	b	LBB0_17
LBB0_16:
Lloh16:
	adrp	x8, _MODE_OK@GOTPAGE
Lloh17:
	ldr	x8, [x8, _MODE_OK@GOTPAGEOFF]
LBB0_17:
	ldr	w0, [x8]
	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_18:
	mov	w8, #0
	b	LBB0_12
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_4-LBB0_2)>>2
	.byte	(LBB0_5-LBB0_2)>>2
	.byte	(LBB0_9-LBB0_2)>>2
	.byte	(LBB0_10-LBB0_2)>>2
                                        ; -- End function
	.comm	_MODE_PANEL,4,2                 ; @MODE_PANEL
	.comm	_MODE_BAD,4,2                   ; @MODE_BAD
	.comm	_DRM_MODE_FLAG_3D_MASK,4,2      ; @DRM_MODE_FLAG_3D_MASK
	.comm	_DRM_MODE_FLAG_3D_FRAME_PACKING,4,2 ; @DRM_MODE_FLAG_3D_FRAME_PACKING
	.comm	_MODE_CLOCK_LOW,4,2             ; @MODE_CLOCK_LOW
	.comm	_MODE_CLOCK_HIGH,4,2            ; @MODE_CLOCK_HIGH
	.comm	_MODE_OK,4,2                    ; @MODE_OK
	.no_dead_strip	_nouveau_connector_mode_valid
.subsections_via_symbols
