	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_khrn_image_get_log2_brcm2_height ## -- Begin function khrn_image_get_log2_brcm2_height
	.p2align	4, 0x90
_khrn_image_get_log2_brcm2_height:      ## @khrn_image_get_log2_brcm2_height
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movl	%edi, %ebx
	callq	_khrn_image_is_brcm1
	movl	$1, %edi
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	movl	%ebx, %edi
	callq	_khrn_image_is_brcm2
	xorl	%edi, %edi
	testq	%rax, %rax
	setne	%dil
LBB0_2:
	callq	_vcos_assert
	movq	_IMAGE_FORMAT_COMP_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	%ebx, %eax
	cmpl	$128, %eax
	je	LBB0_8
## %bb.3:
	cmpl	$130, %eax
	je	LBB0_4
## %bb.5:
	cmpl	$129, %eax
	jne	LBB0_7
## %bb.6:
	movq	_IMAGE_FORMAT_PIXEL_SIZE_MASK@GOTPCREL(%rip), %rax
	andl	(%rax), %ebx
	addl	$-131, %ebx
	cmpl	$5, %ebx
	jae	LBB0_7
## %bb.9:
	movslq	%ebx, %rax
	leaq	l_switch.table.khrn_image_get_log2_brcm2_height(%rip), %rcx
	movl	(%rcx,%rax,4), %ebx
	jmp	LBB0_10
LBB0_7:
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_UNREACHABLE
	jmp	LBB0_10
LBB0_8:
	movl	$2, %ebx
	jmp	LBB0_10
LBB0_4:
	movl	$4, %ebx
LBB0_10:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IMAGE_FORMAT_COMP_MASK,4,2     ## @IMAGE_FORMAT_COMP_MASK
	.comm	_IMAGE_FORMAT_PIXEL_SIZE_MASK,4,2 ## @IMAGE_FORMAT_PIXEL_SIZE_MASK
	.section	__TEXT,__const
	.p2align	2                               ## @switch.table.khrn_image_get_log2_brcm2_height
l_switch.table.khrn_image_get_log2_brcm2_height:
	.long	3                               ## 0x3
	.long	3                               ## 0x3
	.long	2                               ## 0x2
	.long	2                               ## 0x2
	.long	3                               ## 0x3

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_khrn_image_get_log2_brcm2_height ; -- Begin function khrn_image_get_log2_brcm2_height
	.p2align	2
_khrn_image_get_log2_brcm2_height:      ; @khrn_image_get_log2_brcm2_height
	.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_brcm1
	cbz	x0, LBB0_2
; %bb.1:
	mov	w0, #1
	b	LBB0_3
LBB0_2:
	mov	x0, x19
	bl	_khrn_image_is_brcm2
	cmp	x0, #0
	cset	w0, ne
LBB0_3:
	bl	_vcos_assert
Lloh0:
	adrp	x8, _IMAGE_FORMAT_COMP_MASK@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IMAGE_FORMAT_COMP_MASK@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	and	w8, w8, w19
	cmp	w8, #128
	b.eq	LBB0_9
; %bb.4:
	cmp	w8, #130
	b.eq	LBB0_10
; %bb.5:
	cmp	w8, #129
	b.ne	LBB0_8
; %bb.6:
Lloh3:
	adrp	x8, _IMAGE_FORMAT_PIXEL_SIZE_MASK@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IMAGE_FORMAT_PIXEL_SIZE_MASK@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	and	w8, w8, w19
	sub	w8, w8, #131
	cmp	w8, #5
	b.hs	LBB0_8
; %bb.7:
Lloh6:
	adrp	x9, l_switch.table.khrn_image_get_log2_brcm2_height@PAGE
Lloh7:
	add	x9, x9, l_switch.table.khrn_image_get_log2_brcm2_height@PAGEOFF
	ldr	w0, [x9, w8, sxtw #2]
	b	LBB0_11
LBB0_8:
	bl	_UNREACHABLE
	mov	w0, #0
	b	LBB0_11
LBB0_9:
	mov	w0, #2
	b	LBB0_11
LBB0_10:
	mov	w0, #4
LBB0_11:
	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	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_IMAGE_FORMAT_COMP_MASK,4,2     ; @IMAGE_FORMAT_COMP_MASK
	.comm	_IMAGE_FORMAT_PIXEL_SIZE_MASK,4,2 ; @IMAGE_FORMAT_PIXEL_SIZE_MASK
	.section	__TEXT,__const
	.p2align	2                               ; @switch.table.khrn_image_get_log2_brcm2_height
l_switch.table.khrn_image_get_log2_brcm2_height:
	.long	3                               ; 0x3
	.long	3                               ; 0x3
	.long	2                               ; 0x2
	.long	2                               ; 0x2
	.long	3                               ; 0x3

.subsections_via_symbols
