	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vc4_fb_create
_vc4_fb_create:                         ## @vc4_fb_create
	.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	%r12
	pushq	%rbx
	subq	$32, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %rbx
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	_DRM_MODE_FB_MODIFIERS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rdx)
	jne	LBB0_6
## %bb.1:
	movq	16(%rbx), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_drm_gem_object_lookup
	testq	%rax, %rax
	je	LBB0_7
## %bb.2:
	movq	%rax, %r12
	movq	%rax, %rdi
	callq	_to_vc4_bo
	movq	16(%rbx), %rcx
	movq	%rcx, -48(%rbp)
	movups	(%rbx), %xmm0
	movaps	%xmm0, -64(%rbp)
	cmpq	$0, (%rax)
	jne	LBB0_3
## %bb.4:
	movq	_DRM_FORMAT_MOD_NONE@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_7:
	movq	16(%rbx), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdi
	callq	_DRM_DEBUG
	movq	_ENOENT@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	subl	(%rax), %edi
	addq	$32, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ERR_PTR                        ## TAILCALL
LBB0_3:
	movq	_DRM_FORMAT_MOD_BROADCOM_VC4_T_TILED@GOTPCREL(%rip), %rax
LBB0_5:
	movl	(%rax), %eax
	movq	-56(%rbp), %rcx
	movl	%eax, (%rcx)
	movq	%r12, %rdi
	callq	_drm_gem_object_put_unlocked
	leaq	-64(%rbp), %rbx
LBB0_6:
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	callq	_drm_gem_fb_create
	addq	$32, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DRM_MODE_FB_MODIFIERS,4,2      ## @DRM_MODE_FB_MODIFIERS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to look up GEM BO %d\n"

	.comm	_ENOENT,4,2                     ## @ENOENT
	.comm	_DRM_FORMAT_MOD_BROADCOM_VC4_T_TILED,4,2 ## @DRM_FORMAT_MOD_BROADCOM_VC4_T_TILED
	.comm	_DRM_FORMAT_MOD_NONE,4,2        ## @DRM_FORMAT_MOD_NONE
	.no_dead_strip	_vc4_fb_create
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vc4_fb_create
_vc4_fb_create:                         ; @vc4_fb_create
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x21, x2
	mov	x19, x1
	mov	x20, x0
	ldr	w8, [x2]
Lloh0:
	adrp	x9, _DRM_MODE_FB_MODIFIERS@GOTPAGE
Lloh1:
	ldr	x9, [x9, _DRM_MODE_FB_MODIFIERS@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_3
; %bb.1:
	ldr	x8, [x21, #16]
	ldr	w1, [x8]
	mov	x0, x19
	bl	_drm_gem_object_lookup
	cbz	x0, LBB0_4
; %bb.2:
	mov	x22, x0
	bl	_to_vc4_bo
	ldr	x8, [x21, #16]
	str	x8, [sp, #16]
	ldr	q0, [x21]
	str	q0, [sp]
Lloh3:
	adrp	x8, _DRM_FORMAT_MOD_NONE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _DRM_FORMAT_MOD_NONE@GOTPAGEOFF]
Lloh5:
	adrp	x9, _DRM_FORMAT_MOD_BROADCOM_VC4_T_TILED@GOTPAGE
Lloh6:
	ldr	x9, [x9, _DRM_FORMAT_MOD_BROADCOM_VC4_T_TILED@GOTPAGEOFF]
	ldr	x10, [x0]
	cmp	x10, #0
	csel	x8, x8, x9, eq
	ldr	w8, [x8]
	ldr	x9, [sp, #8]
	str	w8, [x9]
	mov	x0, x22
	bl	_drm_gem_object_put_unlocked
	mov	x21, sp
LBB0_3:
	mov	x0, x20
	mov	x1, x19
	mov	x2, x21
	bl	_drm_gem_fb_create
	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
	add	sp, sp, #80
	ret
LBB0_4:
	ldr	x8, [x21, #16]
	ldr	w1, [x8]
Lloh7:
	adrp	x0, l_.str@PAGE
Lloh8:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG
Lloh9:
	adrp	x8, _ENOENT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	neg	w0, w8
	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
	add	sp, sp, #80
	b	_ERR_PTR
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_DRM_MODE_FB_MODIFIERS,4,2      ; @DRM_MODE_FB_MODIFIERS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to look up GEM BO %d\n"

	.comm	_ENOENT,4,2                     ; @ENOENT
	.comm	_DRM_FORMAT_MOD_BROADCOM_VC4_T_TILED,4,2 ; @DRM_FORMAT_MOD_BROADCOM_VC4_T_TILED
	.comm	_DRM_FORMAT_MOD_NONE,4,2        ; @DRM_FORMAT_MOD_NONE
	.no_dead_strip	_vc4_fb_create
.subsections_via_symbols
