	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function find_video
_find_video:                            ## @find_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	%r14
	pushq	%rbx
	subq	$64, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdx, %r14
	movl	%edi, %ebx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -24(%rbp)
	movq	_ACPI_VIDEO_HID@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -64(%rbp)
	movl	$0, -56(%rbp)
	leaq	L_.str(%rip), %rax
	movq	%rax, -48(%rbp)
	movl	$0, -40(%rbp)
	leaq	-72(%rbp), %rsi
	callq	_acpi_bus_get_device
	testq	%rax, %rax
	jne	LBB0_4
## %bb.1:
	movq	-72(%rbp), %rdi
	leaq	-64(%rbp), %rsi
	callq	_acpi_match_device_ids
	testl	%eax, %eax
	jne	LBB0_4
## %bb.2:
	movl	%ebx, %edi
	callq	_acpi_get_pci_dev
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	%rax, %rdi
	callq	_pci_dev_put
	movq	-72(%rbp), %rdi
	callq	_acpi_is_video_device
	orq	%rax, (%r14)
LBB0_4:
	movq	_AE_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-24(%rbp), %rcx
	jne	LBB0_6
## %bb.5:
	addq	$64, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_6:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_ACPI_VIDEO_HID,8,3             ## @ACPI_VIDEO_HID
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.space	1

	.comm	_AE_OK,4,2                      ## @AE_OK
	.no_dead_strip	_find_video
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function find_video
_find_video:                            ; @find_video
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x2
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-24]
Lloh3:
	adrp	x8, _ACPI_VIDEO_HID@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ACPI_VIDEO_HID@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	str	x8, [sp, #8]
	str	wzr, [sp, #16]
Lloh6:
	adrp	x8, l_.str@PAGE
Lloh7:
	add	x8, x8, l_.str@PAGEOFF
	str	x8, [sp, #24]
	str	wzr, [sp, #32]
	mov	x1, sp
	bl	_acpi_bus_get_device
	cbnz	x0, LBB0_4
; %bb.1:
	ldr	x0, [sp]
	add	x1, sp, #8
	bl	_acpi_match_device_ids
	cbnz	w0, LBB0_4
; %bb.2:
	mov	x0, x20
	bl	_acpi_get_pci_dev
	cbz	x0, LBB0_4
; %bb.3:
	bl	_pci_dev_put
	ldr	x0, [sp]
	bl	_acpi_is_video_device
	ldr	x8, [x19]
	orr	x8, x8, x0
	str	x8, [x19]
LBB0_4:
Lloh8:
	adrp	x8, _AE_OK@GOTPAGE
Lloh9:
	ldr	x8, [x8, _AE_OK@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	ldur	x8, [x29, #-24]
Lloh11:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh12:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_6
; %bb.5:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_6:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_ACPI_VIDEO_HID,8,3             ; @ACPI_VIDEO_HID
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.space	1

	.comm	_AE_OK,4,2                      ; @AE_OK
	.no_dead_strip	_find_video
.subsections_via_symbols
