	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function d3d12_get_closest_match
LCPI0_0:
	.space	16
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_d3d12_get_closest_match
	.p2align	4, 0x90
_d3d12_get_closest_match:               ## @d3d12_get_closest_match
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r12
	movl	%edi, %r14d
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	(%rsi), %rdi
	movq	%rdi, -64(%rbp)
	movq	_DXGI_FORMAT_UNKNOWN@GOTPCREL(%rip), %r15
	movq	(%r15), %rax
	movq	%rax, -56(%rbp)
	callq	_dxgi_get_format_fallback_list
	testq	%rax, %rax
	leaq	-64(%rbp), %rbx
	cmovneq	%rax, %rbx
	movq	(%rbx), %rdi
	cmpq	(%r15), %rdi
	jne	LBB0_1
LBB0_7:
	callq	_assert
	movq	(%rbx), %rax
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-48(%rbp), %rcx
	jne	LBB0_9
## %bb.8:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	_D3D12_FEATURE_FORMAT_SUPPORT@GOTPCREL(%rip), %r13
	leaq	-88(%rbp), %r15
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	8(%rbx), %rdi
	addq	$8, %rbx
	movq	_DXGI_FORMAT_UNKNOWN@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdi
	je	LBB0_7
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rdi, -88(%rbp)
	leaq	-80(%rbp), %rax
	xorps	%xmm0, %xmm0
	movups	%xmm0, (%rax)
	movl	(%r13), %esi
	movl	%r14d, %edi
	movq	%r15, %rdx
	movl	$24, %ecx
	callq	_D3D12CheckFeatureSupport
	movl	%eax, %edi
	callq	_SUCCEEDED
	testq	%rax, %rax
	je	LBB0_6
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	-72(%rbp), %eax
	notl	%eax
	testl	%eax, 16(%r12)
	jne	LBB0_6
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	-68(%rbp), %eax
	notl	%eax
	testl	%eax, 20(%r12)
	jne	LBB0_6
## %bb.5:
	movq	(%rbx), %rdi
	jmp	LBB0_7
LBB0_9:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_DXGI_FORMAT_UNKNOWN,8,3        ## @DXGI_FORMAT_UNKNOWN
	.comm	_D3D12_FEATURE_FORMAT_SUPPORT,4,2 ## @D3D12_FEATURE_FORMAT_SUPPORT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_d3d12_get_closest_match        ; -- Begin function d3d12_get_closest_match
	.p2align	2
_d3d12_get_closest_match:               ; @d3d12_get_closest_match
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #40]
	ldr	x0, [x1]
Lloh3:
	adrp	x22, _DXGI_FORMAT_UNKNOWN@GOTPAGE
Lloh4:
	ldr	x22, [x22, _DXGI_FORMAT_UNKNOWN@GOTPAGEOFF]
	ldr	x8, [x22]
	stp	x0, x8, [sp, #24]
	bl	_dxgi_get_format_fallback_list
	add	x8, sp, #24
	cmp	x0, #0
	csel	x21, x8, x0, eq
	ldr	x0, [x21]
	ldr	x8, [x22]
	cmp	x0, x8
	b.ne	LBB0_3
LBB0_1:
	bl	_assert
	ldr	x0, [x21]
	ldr	x8, [sp, #40]
Lloh5:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh6:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_9
; %bb.2:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_3:
	mov	x8, sp
	add	x23, x8, #8
Lloh8:
	adrp	x24, _D3D12_FEATURE_FORMAT_SUPPORT@GOTPAGE
Lloh9:
	ldr	x24, [x24, _D3D12_FEATURE_FORMAT_SUPPORT@GOTPAGEOFF]
	b	LBB0_5
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	x0, [x21, #8]!
	ldr	x8, [x22]
	cmp	x0, x8
	b.eq	LBB0_1
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	str	x0, [sp]
	stp	xzr, xzr, [x23]
	ldr	w1, [x24]
	mov	x2, sp
	mov	x0, x20
	mov	w3, #24
	bl	_D3D12CheckFeatureSupport
	bl	_SUCCEEDED
	cbz	x0, LBB0_4
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [sp, #16]
	ldr	w9, [x19, #16]
	bics	wzr, w9, w8
	b.ne	LBB0_4
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [sp, #20]
	ldr	w9, [x19, #20]
	bics	wzr, w9, w8
	b.ne	LBB0_4
; %bb.8:
	ldr	x0, [x21]
	b	LBB0_1
LBB0_9:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_DXGI_FORMAT_UNKNOWN,8,3        ; @DXGI_FORMAT_UNKNOWN
	.comm	_D3D12_FEATURE_FORMAT_SUPPORT,4,2 ; @D3D12_FEATURE_FORMAT_SUPPORT
.subsections_via_symbols
