	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function intel_dsm_detect
_intel_dsm_detect:                      ## @intel_dsm_detect
	.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
	subq	$280, %rsp                      ## imm = 0x118
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	xorps	%xmm0, %xmm0
	movups	%xmm0, -65(%rbp)
	movaps	%xmm0, -80(%rbp)
	movaps	%xmm0, -96(%rbp)
	movaps	%xmm0, -112(%rbp)
	movaps	%xmm0, -128(%rbp)
	movaps	%xmm0, -144(%rbp)
	movaps	%xmm0, -160(%rbp)
	movaps	%xmm0, -176(%rbp)
	movaps	%xmm0, -192(%rbp)
	movaps	%xmm0, -208(%rbp)
	movaps	%xmm0, -224(%rbp)
	movaps	%xmm0, -240(%rbp)
	movaps	%xmm0, -256(%rbp)
	movaps	%xmm0, -272(%rbp)
	movaps	%xmm0, -288(%rbp)
	movaps	%xmm0, -304(%rbp)
	movl	$255, -320(%rbp)
	leaq	-304(%rbp), %rax
	movq	%rax, -312(%rbp)
	movq	_PCI_CLASS_DISPLAY_VGA@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	shll	$8, %edi
	xorl	%r14d, %r14d
	xorl	%esi, %esi
	callq	_pci_get_class
	testq	%rax, %rax
	je	LBB0_6
## %bb.1:
	movq	%rax, %r13
	xorl	%r12d, %r12d
	movl	$2, %ebx
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	callq	_intel_dsm_pci_probe
	orl	%eax, %r12d
	movl	(%r15), %edi
	shll	$8, %edi
	movq	%r13, %rsi
	callq	_pci_get_class
	movq	%rax, %r13
	decl	%ebx
	testq	%rax, %rax
	jne	LBB0_2
## %bb.3:
	xorl	%r14d, %r14d
	testl	%ebx, %ebx
	jne	LBB0_6
## %bb.4:
	testl	%r12d, %r12d
	je	LBB0_6
## %bb.5:
	movq	_intel_dsm_priv@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_ACPI_FULL_PATHNAME@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-320(%rbp), %rdx
	callq	_acpi_get_name
	leaq	L_.str(%rip), %rdi
	leaq	-304(%rbp), %rsi
	callq	_DRM_DEBUG_DRIVER
	movl	$1, %r14d
LBB0_6:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_8
## %bb.7:
	movl	%r14d, %eax
	addq	$280, %rsp                      ## imm = 0x118
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_PCI_CLASS_DISPLAY_VGA,4,2      ## @PCI_CLASS_DISPLAY_VGA
	.comm	_intel_dsm_priv,4,2             ## @intel_dsm_priv
	.comm	_ACPI_FULL_PATHNAME,4,2         ## @ACPI_FULL_PATHNAME
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"VGA switcheroo: detected DSM switching method %s handle\n"

	.no_dead_strip	_intel_dsm_detect
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function intel_dsm_detect
_intel_dsm_detect:                      ; @intel_dsm_detect
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #352
	.cfi_def_cfa_offset 352
	stp	x28, x27, [sp, #288]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #304]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #320]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #336]            ; 16-byte Folded Spill
	add	x29, sp, #336
	.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 w27, -56
	.cfi_offset w28, -64
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	movi.2d	v0, #0000000000000000
	stur	q0, [sp, #255]
	stp	q0, q0, [sp, #224]
	stp	q0, q0, [sp, #192]
	stp	q0, q0, [sp, #160]
	stp	q0, q0, [sp, #128]
	stp	q0, q0, [sp, #96]
	stp	q0, q0, [sp, #64]
	str	q0, [sp, #48]
	mov	w8, #255
	str	w8, [sp]
	add	x8, sp, #16
	str	x8, [sp, #8]
Lloh3:
	adrp	x20, _PCI_CLASS_DISPLAY_VGA@GOTPAGE
Lloh4:
	ldr	x20, [x20, _PCI_CLASS_DISPLAY_VGA@GOTPAGEOFF]
	ldr	w8, [x20]
	lsl	w0, w8, #8
	stp	q0, q0, [sp, #16]
	mov	x1, #0
	bl	_pci_get_class
	cbz	x0, LBB0_6
; %bb.1:
	mov	x19, x0
	mov	w21, #0
	mov	w22, #2
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_intel_dsm_pci_probe
	orr	w21, w0, w21
	ldr	w8, [x20]
	lsl	w0, w8, #8
	mov	x1, x19
	bl	_pci_get_class
	mov	x19, x0
	sub	w22, w22, #1
	cbnz	x0, LBB0_2
; %bb.3:
	cbnz	w22, LBB0_6
; %bb.4:
	cbz	w21, LBB0_6
; %bb.5:
Lloh5:
	adrp	x8, _intel_dsm_priv@GOTPAGE
Lloh6:
	ldr	x8, [x8, _intel_dsm_priv@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
Lloh8:
	adrp	x8, _ACPI_FULL_PATHNAME@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ACPI_FULL_PATHNAME@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x2, sp
	bl	_acpi_get_name
Lloh11:
	adrp	x0, l_.str@PAGE
Lloh12:
	add	x0, x0, l_.str@PAGEOFF
	add	x1, sp, #16
	bl	_DRM_DEBUG_DRIVER
	mov	w0, #1
LBB0_6:
	ldur	x8, [x29, #-56]
Lloh13:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh14:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh15:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_8
; %bb.7:
	ldp	x29, x30, [sp, #336]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #320]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #304]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #288]            ; 16-byte Folded Reload
	add	sp, sp, #352
	ret
LBB0_8:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_PCI_CLASS_DISPLAY_VGA,4,2      ; @PCI_CLASS_DISPLAY_VGA
	.comm	_intel_dsm_priv,4,2             ; @intel_dsm_priv
	.comm	_ACPI_FULL_PATHNAME,4,2         ; @ACPI_FULL_PATHNAME
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"VGA switcheroo: detected DSM switching method %s handle\n"

	.no_dead_strip	_intel_dsm_detect
.subsections_via_symbols
