	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function shmob_drm_fb_create
_shmob_drm_fb_create:                   ## @shmob_drm_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %rbx
	movq	%rsi, %r15
	movq	%rdi, %r14
	movl	8(%rdx), %edi
	callq	_shmob_drm_format_info
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	(%rbx), %rcx
	movl	(%rcx), %edx
	cmpl	$65535, %edx                    ## imm = 0xFFFF
	jg	LBB0_4
## %bb.3:
	movl	%edx, %esi
	andl	$7, %esi
	jne	LBB0_4
## %bb.7:
	cmpq	$0, 8(%rax)
	je	LBB0_10
## %bb.8:
	xorl	%esi, %esi
	cmpl	$24, (%rax)
	sete	%sil
	incl	%esi
	imull	%edx, %esi
	cmpl	%esi, 4(%rcx)
	jne	LBB0_9
LBB0_10:
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_drm_gem_fb_create              ## TAILCALL
LBB0_1:
	movl	(%r14), %edi
	movl	8(%rbx), %edx
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_5
LBB0_4:
	movl	(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
LBB0_5:
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_dev_dbg
LBB0_6:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	movl	%ebx, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ERR_PTR                        ## TAILCALL
LBB0_9:
	movl	(%r14), %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_dev_dbg
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unsupported pixel format %08x\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.1:                               ## @.str.1
	.asciz	"invalid pitch value %u\n"

L_.str.2:                               ## @.str.2
	.asciz	"luma and chroma pitches do not match\n"

	.no_dead_strip	_shmob_drm_fb_create
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function shmob_drm_fb_create
_shmob_drm_fb_create:                   ; @shmob_drm_fb_create
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x19, x2
	mov	x21, x1
	mov	x20, x0
	ldr	w0, [x2, #8]
	bl	_shmob_drm_format_info
	cbz	x0, LBB0_3
; %bb.1:
	ldr	x9, [x19]
	ldr	w8, [x9]
	and	w10, w8, #0x7
	cmp	w8, #16, lsl #12                ; =65536
	ccmp	w10, #0, #0, lt
	b.eq	LBB0_4
; %bb.2:
	ldr	w0, [x20]
	str	x8, [sp]
Lloh0:
	adrp	x1, l_.str.1@PAGE
Lloh1:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_8
LBB0_3:
	ldr	w0, [x20]
	ldr	w8, [x19, #8]
	str	x8, [sp]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_8
LBB0_4:
	ldr	x10, [x0, #8]
	cbz	x10, LBB0_6
; %bb.5:
	ldr	w10, [x0]
	cmp	w10, #24
	mov	w10, #1
	cinc	w10, w10, eq
	ldr	w9, [x9, #4]
	mul	w8, w10, w8
	cmp	w9, w8
	b.ne	LBB0_7
LBB0_6:
	mov	x0, x20
	mov	x1, x21
	mov	x2, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	b	_drm_gem_fb_create
LBB0_7:
	ldr	w0, [x20]
Lloh4:
	adrp	x1, l_.str.2@PAGE
Lloh5:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_8:
	bl	_dev_dbg
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	b	_ERR_PTR
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unsupported pixel format %08x\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.1:                               ; @.str.1
	.asciz	"invalid pitch value %u\n"

l_.str.2:                               ; @.str.2
	.asciz	"luma and chroma pitches do not match\n"

	.no_dead_strip	_shmob_drm_fb_create
.subsections_via_symbols
