	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function wined3d_guess_card
_wined3d_guess_card:                    ## @wined3d_guess_card
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, %rbx
	movq	%r8, -56(%rbp)                  ## 8-byte Spill
	movq	%rcx, %r15
	callq	_d3d_level_from_caps
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	_card_vendor_table@GOTPCREL(%rip), %r13
	movq	(%r13), %rdi
	callq	_ARRAY_SIZE
	testl	%eax, %eax
	je	LBB0_6
## %bb.1:
	xorl	%r14d, %r14d
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r13), %rdi
	movl	(%rdi,%r14), %eax
	cmpl	(%rbx), %eax
	je	LBB0_3
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	incq	%r12
	callq	_ARRAY_SIZE
	movl	%eax, %eax
	addq	$32, %r14
	cmpq	%rax, %r12
	jb	LBB0_2
LBB0_6:
	movl	(%rbx), %r12d
	movq	%r15, %rdi
	callq	_debugstr_a
	leaq	L_.str.2(%rip), %rdi
	movl	%r12d, %esi
	movl	%eax, %edx
	callq	_FIXME
	movq	_HW_VENDOR_NVIDIA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%rbx)
	movq	_card_fallback_nvidia@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_3:
	movl	24(%rdi,%r14), %esi
	leaq	L_.str(%rip), %rdi
	callq	_TRACE
	movq	(%r13), %rax
	movl	16(%rax,%r14), %esi
	movl	20(%rax,%r14), %edi
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edx
	movq	%r15, %rcx
	callq	_select_card_handler
	movq	_PCI_DEVICE_NONE@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_8
## %bb.4:
	movq	%r15, %rdi
	callq	_debugstr_a
	leaq	L_.str.1(%rip), %rdi
	movl	%eax, %esi
	callq	_TRACE
	movq	(%r13), %rax
	addq	%r14, %rax
	addq	$8, %rax
LBB0_7:
	movq	(%rax), %rax
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	movl	(%rax,%rcx,4), %eax
LBB0_8:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_card_vendor_table,8,3          ## @card_vendor_table
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Applying card selector \"%s\".\n"

	.comm	_PCI_DEVICE_NONE,4,2            ## @PCI_DEVICE_NONE
L_.str.1:                               ## @.str.1
	.asciz	"Unrecognized renderer %s, falling back to default.\n"

L_.str.2:                               ## @.str.2
	.asciz	"No card selector available for card vendor %04x (using GL_RENDERER %s).\n"

	.comm	_HW_VENDOR_NVIDIA,4,2           ## @HW_VENDOR_NVIDIA
	.comm	_card_fallback_nvidia,8,3       ## @card_fallback_nvidia
	.no_dead_strip	_wined3d_guess_card
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function wined3d_guess_card
_wined3d_guess_card:                    ; @wined3d_guess_card
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x21, x5
	mov	x22, x4
	mov	x20, x3
	bl	_d3d_level_from_caps
	mov	x19, x0
Lloh0:
	adrp	x23, _card_vendor_table@GOTPAGE
Lloh1:
	ldr	x23, [x23, _card_vendor_table@GOTPAGEOFF]
	ldr	x0, [x23]
	bl	_ARRAY_SIZE
	cbz	w0, LBB0_4
; %bb.1:
	mov	x24, #0
	mov	x25, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x23]
	ldr	w8, [x0, x24]
	ldr	w9, [x21]
	cmp	w8, w9
	b.eq	LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	add	x25, x25, #1
	bl	_ARRAY_SIZE
	add	x24, x24, #32
	cmp	x25, w0, uxtw
	b.lo	LBB0_2
LBB0_4:
	ldr	w22, [x21]
	mov	x0, x20
	bl	_debugstr_a
	mov	x2, x0
Lloh2:
	adrp	x0, l_.str.2@PAGE
Lloh3:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x1, x22
	bl	_FIXME
Lloh4:
	adrp	x8, _HW_VENDOR_NVIDIA@GOTPAGE
Lloh5:
	ldr	x8, [x8, _HW_VENDOR_NVIDIA@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	str	w8, [x21]
Lloh7:
	adrp	x8, _card_fallback_nvidia@GOTPAGE
Lloh8:
	ldr	x8, [x8, _card_fallback_nvidia@GOTPAGEOFF]
	b	LBB0_7
LBB0_5:
	add	x8, x0, x24
	ldr	w1, [x8, #24]
Lloh9:
	adrp	x0, l_.str@PAGE
Lloh10:
	add	x0, x0, l_.str@PAGEOFF
	bl	_TRACE
	ldr	x8, [x23]
	add	x8, x8, x24
	ldp	w1, w0, [x8, #16]
	ldr	w2, [x22]
	mov	x3, x20
	bl	_select_card_handler
Lloh11:
	adrp	x8, _PCI_DEVICE_NONE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _PCI_DEVICE_NONE@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_8
; %bb.6:
	mov	x0, x20
	bl	_debugstr_a
	mov	x1, x0
Lloh14:
	adrp	x0, l_.str.1@PAGE
Lloh15:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_TRACE
	ldr	x8, [x23]
	add	x8, x8, x24
	add	x8, x8, #8
LBB0_7:
	ldr	x8, [x8]
	ldr	w0, [x8, w19, uxtw #2]
LBB0_8:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_card_vendor_table,8,3          ; @card_vendor_table
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Applying card selector \"%s\".\n"

	.comm	_PCI_DEVICE_NONE,4,2            ; @PCI_DEVICE_NONE
l_.str.1:                               ; @.str.1
	.asciz	"Unrecognized renderer %s, falling back to default.\n"

l_.str.2:                               ; @.str.2
	.asciz	"No card selector available for card vendor %04x (using GL_RENDERER %s).\n"

	.comm	_HW_VENDOR_NVIDIA,4,2           ; @HW_VENDOR_NVIDIA
	.comm	_card_fallback_nvidia,8,3       ; @card_fallback_nvidia
	.no_dead_strip	_wined3d_guess_card
.subsections_via_symbols
