	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_khrn_image_get_stencil_size    ## -- Begin function khrn_image_get_stencil_size
	.p2align	4, 0x90
_khrn_image_get_stencil_size:           ## @khrn_image_get_stencil_size
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movl	%edi, %ebx
	callq	_khrn_image_is_depth
	xorl	%r14d, %r14d
	testq	%rax, %rax
	je	LBB0_5
## %bb.1:
	movq	_IMAGE_FORMAT_STENCIL@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_5
## %bb.2:
	movq	_DEPTH_32_TLBD@GOTPCREL(%rip), %rax
	movl	$8, %r14d
	cmpl	%ebx, (%rax)
	je	LBB0_5
## %bb.3:
	movq	_DEPTH_COL_64_TLBD@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	je	LBB0_5
## %bb.4:
	movq	_IMAGE_FORMAT_PIXEL_SIZE_MASK@GOTPCREL(%rip), %rax
	andl	(%rax), %ebx
	movq	_IMAGE_FORMAT_32@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpl	(%rax), %ebx
	sete	%dil
	callq	_vcos_assert
LBB0_5:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IMAGE_FORMAT_STENCIL,4,2       ## @IMAGE_FORMAT_STENCIL
	.comm	_DEPTH_32_TLBD,4,2              ## @DEPTH_32_TLBD
	.comm	_DEPTH_COL_64_TLBD,4,2          ## @DEPTH_COL_64_TLBD
	.comm	_IMAGE_FORMAT_PIXEL_SIZE_MASK,4,2 ## @IMAGE_FORMAT_PIXEL_SIZE_MASK
	.comm	_IMAGE_FORMAT_32,4,2            ## @IMAGE_FORMAT_32
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_khrn_image_get_stencil_size    ; -- Begin function khrn_image_get_stencil_size
	.p2align	2
_khrn_image_get_stencil_size:           ; @khrn_image_get_stencil_size
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	bl	_khrn_image_is_depth
	cbz	x0, LBB0_6
; %bb.1:
Lloh0:
	adrp	x8, _IMAGE_FORMAT_STENCIL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IMAGE_FORMAT_STENCIL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	tst	w8, w19
	b.eq	LBB0_5
; %bb.2:
Lloh3:
	adrp	x8, _DEPTH_32_TLBD@GOTPAGE
Lloh4:
	ldr	x8, [x8, _DEPTH_32_TLBD@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _DEPTH_COL_64_TLBD@GOTPAGE
Lloh7:
	ldr	x9, [x9, _DEPTH_COL_64_TLBD@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	cmp	w8, w19
	ccmp	w9, w19, #4, ne
	b.eq	LBB0_4
; %bb.3:
Lloh9:
	adrp	x8, _IMAGE_FORMAT_PIXEL_SIZE_MASK@GOTPAGE
Lloh10:
	ldr	x8, [x8, _IMAGE_FORMAT_PIXEL_SIZE_MASK@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	and	w8, w8, w19
Lloh12:
	adrp	x9, _IMAGE_FORMAT_32@GOTPAGE
Lloh13:
	ldr	x9, [x9, _IMAGE_FORMAT_32@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	cmp	w8, w9
	cset	w0, eq
	bl	_vcos_assert
LBB0_4:
	mov	w0, #8
	b	LBB0_6
LBB0_5:
	mov	w0, #0
LBB0_6:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_IMAGE_FORMAT_STENCIL,4,2       ; @IMAGE_FORMAT_STENCIL
	.comm	_DEPTH_32_TLBD,4,2              ; @DEPTH_32_TLBD
	.comm	_DEPTH_COL_64_TLBD,4,2          ; @DEPTH_COL_64_TLBD
	.comm	_IMAGE_FORMAT_PIXEL_SIZE_MASK,4,2 ; @IMAGE_FORMAT_PIXEL_SIZE_MASK
	.comm	_IMAGE_FORMAT_32,4,2            ; @IMAGE_FORMAT_32
.subsections_via_symbols
