	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_VIDEO_GetPreferredMode         ## -- Begin function VIDEO_GetPreferredMode
	.p2align	4, 0x90
_VIDEO_GetPreferredMode:                ## @VIDEO_GetPreferredMode
	.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	%rdi, %r15
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_VIDEO_GetCurrentTvMode
	movl	%eax, %ebx
	xorl	%eax, %eax
	callq	_VIDEO_HaveComponentCable
	addl	$-128, %ebx
	cmpl	$3, %ebx
	ja	LBB0_2
## %bb.1:
	testq	%rax, %rax
	leaq	l_switch.table.VIDEO_GetPreferredMode.1(%rip), %rax
	leaq	l_switch.table.VIDEO_GetPreferredMode(%rip), %rcx
	cmoveq	%rax, %rcx
	movslq	%ebx, %rax
	movq	(%rcx,%rax,8), %r14
LBB0_2:
	testq	%r15, %r15
	je	LBB0_3
## %bb.4:
	movq	%r15, %rdi
	movq	%r14, %rsi
	movl	$4, %edx
	callq	_memcpy
	jmp	LBB0_5
LBB0_3:
	movq	%r14, %r15
LBB0_5:
	movq	%r15, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_TVNtsc480Prog,4,2              ## @TVNtsc480Prog
	.comm	_TVPal576ProgScale,4,2          ## @TVPal576ProgScale
	.comm	_TVMpal480Prog,4,2              ## @TVMpal480Prog
	.comm	_TVEurgb60Hz480Prog,4,2         ## @TVEurgb60Hz480Prog
	.comm	_TVNtsc480IntDf,4,2             ## @TVNtsc480IntDf
	.comm	_TVPal576IntDfScale,4,2         ## @TVPal576IntDfScale
	.comm	_TVMpal480IntDf,4,2             ## @TVMpal480IntDf
	.comm	_TVEurgb60Hz480IntDf,4,2        ## @TVEurgb60Hz480IntDf
	.section	__DATA,__const
	.p2align	3                               ## @switch.table.VIDEO_GetPreferredMode
l_switch.table.VIDEO_GetPreferredMode:
	.quad	_TVPal576ProgScale
	.quad	_TVNtsc480Prog
	.quad	_TVMpal480Prog
	.quad	_TVEurgb60Hz480Prog

	.p2align	3                               ## @switch.table.VIDEO_GetPreferredMode.1
l_switch.table.VIDEO_GetPreferredMode.1:
	.quad	_TVPal576IntDfScale
	.quad	_TVNtsc480IntDf
	.quad	_TVMpal480IntDf
	.quad	_TVEurgb60Hz480IntDf

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_VIDEO_GetPreferredMode         ; -- Begin function VIDEO_GetPreferredMode
	.p2align	2
_VIDEO_GetPreferredMode:                ; @VIDEO_GetPreferredMode
	.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
	bl	_VIDEO_GetCurrentTvMode
	mov	x20, x0
	bl	_VIDEO_HaveComponentCable
	sub	w8, w20, #128
	cmp	w8, #3
	b.hi	LBB0_3
; %bb.1:
Lloh0:
	adrp	x9, l_switch.table.VIDEO_GetPreferredMode@PAGE
Lloh1:
	add	x9, x9, l_switch.table.VIDEO_GetPreferredMode@PAGEOFF
Lloh2:
	adrp	x10, l_switch.table.VIDEO_GetPreferredMode.1@PAGE
Lloh3:
	add	x10, x10, l_switch.table.VIDEO_GetPreferredMode.1@PAGEOFF
	cmp	x0, #0
	csel	x9, x10, x9, eq
	ldr	x1, [x9, w8, sxtw #3]
	cbz	x19, LBB0_4
LBB0_2:
	mov	x0, x19
	mov	w2, #4
	bl	_memcpy
	b	LBB0_5
LBB0_3:
	mov	x1, #0
	cbnz	x19, LBB0_2
LBB0_4:
	mov	x19, x1
LBB0_5:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_TVNtsc480Prog,4,2              ; @TVNtsc480Prog
	.comm	_TVPal576ProgScale,4,2          ; @TVPal576ProgScale
	.comm	_TVMpal480Prog,4,2              ; @TVMpal480Prog
	.comm	_TVEurgb60Hz480Prog,4,2         ; @TVEurgb60Hz480Prog
	.comm	_TVNtsc480IntDf,4,2             ; @TVNtsc480IntDf
	.comm	_TVPal576IntDfScale,4,2         ; @TVPal576IntDfScale
	.comm	_TVMpal480IntDf,4,2             ; @TVMpal480IntDf
	.comm	_TVEurgb60Hz480IntDf,4,2        ; @TVEurgb60Hz480IntDf
	.section	__DATA,__const
	.p2align	3                               ; @switch.table.VIDEO_GetPreferredMode
l_switch.table.VIDEO_GetPreferredMode:
	.quad	_TVPal576ProgScale
	.quad	_TVNtsc480Prog
	.quad	_TVMpal480Prog
	.quad	_TVEurgb60Hz480Prog

	.p2align	3                               ; @switch.table.VIDEO_GetPreferredMode.1
l_switch.table.VIDEO_GetPreferredMode.1:
	.quad	_TVPal576IntDfScale
	.quad	_TVNtsc480IntDf
	.quad	_TVMpal480IntDf
	.quad	_TVEurgb60Hz480IntDf

.subsections_via_symbols
