	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amdgpu_connector_dvi_mode_valid
_amdgpu_connector_dvi_mode_valid:       ## @amdgpu_connector_dvi_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	(%rdi), %rax
	movq	(%rax), %r15
	callq	_to_amdgpu_connector
	cmpq	$0, 8(%rax)
	movl	(%r14), %ecx
	je	LBB0_7
## %bb.1:
	cmpl	$165001, %ecx                   ## imm = 0x28489
	jl	LBB0_7
## %bb.2:
	movq	(%rax), %rcx
	movq	_CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_I@GOTPCREL(%rip), %rdx
	movq	_MODE_OK@GOTPCREL(%rip), %rax
	cmpq	(%rdx), %rcx
	je	LBB0_11
## %bb.3:
	movq	_CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_D@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	je	LBB0_11
## %bb.4:
	movq	_CONNECTOR_OBJECT_ID_HDMI_TYPE_B@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	je	LBB0_11
## %bb.5:
	movq	%rbx, %rdi
	callq	_amdgpu_connector_edid
	movl	%eax, %edi
	callq	_drm_detect_hdmi_monitor
	testq	%rax, %rax
	je	LBB0_10
## %bb.6:
	movl	(%r14), %eax
	movl	$340000, %ecx                   ## imm = 0x53020
	cmpl	%ecx, %eax
	jg	LBB0_10
LBB0_9:
	movq	_MODE_OK@GOTPCREL(%rip), %rax
	jmp	LBB0_11
LBB0_7:
	movslq	%ecx, %rax
	imulq	$1717986919, %rax, %rax         ## imm = 0x66666667
	movq	%rax, %rcx
	shrq	$63, %rcx
	sarq	$34, %rax
	addl	%ecx, %eax
	movl	(%r15), %ecx
	cmpl	%ecx, %eax
	jle	LBB0_9
LBB0_10:
	movq	_MODE_CLOCK_HIGH@GOTPCREL(%rip), %rax
LBB0_11:
	movl	(%rax), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_I,8,3 ## @CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_I
	.comm	_CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_D,8,3 ## @CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_D
	.comm	_CONNECTOR_OBJECT_ID_HDMI_TYPE_B,8,3 ## @CONNECTOR_OBJECT_ID_HDMI_TYPE_B
	.comm	_MODE_OK,4,2                    ## @MODE_OK
	.comm	_MODE_CLOCK_HIGH,4,2            ## @MODE_CLOCK_HIGH
	.no_dead_strip	_amdgpu_connector_dvi_mode_valid
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function amdgpu_connector_dvi_mode_valid
_amdgpu_connector_dvi_mode_valid:       ; @amdgpu_connector_dvi_mode_valid
	.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, x1
	mov	x20, x0
	ldr	x8, [x0]
	ldr	x21, [x8]
	bl	_to_amdgpu_connector
	ldr	x9, [x0, #8]
	ldr	w8, [x19]
	cmp	x9, #0
	mov	w9, #33929
	movk	w9, #2, lsl #16
	ccmp	w8, w9, #8, ne
	b.ge	LBB0_2
; %bb.1:
	mov	w9, #26215
	movk	w9, #26214, lsl #16
	smull	x8, w8, w9
	lsr	x9, x8, #63
	asr	x8, x8, #34
	add	w8, w8, w9
	ldr	w9, [x21]
	b	LBB0_6
LBB0_2:
	ldr	x8, [x0]
Lloh0:
	adrp	x9, _CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_I@GOTPAGE
Lloh1:
	ldr	x9, [x9, _CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_I@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
Lloh3:
	adrp	x10, _CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_D@GOTPAGE
Lloh4:
	ldr	x10, [x10, _CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_D@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
Lloh6:
	adrp	x11, _CONNECTOR_OBJECT_ID_HDMI_TYPE_B@GOTPAGE
Lloh7:
	ldr	x11, [x11, _CONNECTOR_OBJECT_ID_HDMI_TYPE_B@GOTPAGEOFF]
Lloh8:
	ldr	x11, [x11]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	ccmp	x8, x11, #4, ne
	b.ne	LBB0_4
; %bb.3:
Lloh9:
	adrp	x8, _MODE_OK@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MODE_OK@GOTPAGEOFF]
	b	LBB0_7
LBB0_4:
	mov	x0, x20
	bl	_amdgpu_connector_edid
	bl	_drm_detect_hdmi_monitor
	cbz	x0, LBB0_8
; %bb.5:
	ldr	w8, [x19]
	mov	w9, #12320
	movk	w9, #5, lsl #16
LBB0_6:
Lloh11:
	adrp	x10, _MODE_OK@GOTPAGE
Lloh12:
	ldr	x10, [x10, _MODE_OK@GOTPAGEOFF]
Lloh13:
	adrp	x11, _MODE_CLOCK_HIGH@GOTPAGE
Lloh14:
	ldr	x11, [x11, _MODE_CLOCK_HIGH@GOTPAGEOFF]
	cmp	w8, w9
	csel	x8, x11, x10, gt
LBB0_7:
	ldr	w0, [x8]
	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
LBB0_8:
Lloh15:
	adrp	x8, _MODE_CLOCK_HIGH@GOTPAGE
Lloh16:
	ldr	x8, [x8, _MODE_CLOCK_HIGH@GOTPAGEOFF]
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_I,8,3 ; @CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_I
	.comm	_CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_D,8,3 ; @CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_D
	.comm	_CONNECTOR_OBJECT_ID_HDMI_TYPE_B,8,3 ; @CONNECTOR_OBJECT_ID_HDMI_TYPE_B
	.comm	_MODE_OK,4,2                    ; @MODE_OK
	.comm	_MODE_CLOCK_HIGH,4,2            ; @MODE_CLOCK_HIGH
	.no_dead_strip	_amdgpu_connector_dvi_mode_valid
.subsections_via_symbols
