	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mtk_jpeg_decide_format
_mtk_jpeg_decide_format:                ## @mtk_jpeg_decide_format
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	8(%rdi), %r9
	movq	16(%rdi), %r8
	movl	(%r9), %edx
	movl	4(%r9), %eax
	shll	$20, %edx
	movl	(%r8), %ecx
	movl	4(%r8), %esi
	shll	$16, %ecx
	orl	%edx, %ecx
	shll	$12, %eax
	shll	$8, %esi
	orl	%eax, %esi
	orl	%ecx, %esi
	movl	8(%r9), %eax
	shll	$4, %eax
	orl	%esi, %eax
	orl	8(%r8), %eax
	movl	%eax, (%rdi)
	movl	$0, 24(%rdi)
	addl	$-128, %eax
	cmpl	$6, %eax
	ja	LBB0_1
## %bb.2:
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_5:
	movl	$1, 24(%rdi)
LBB0_6:
	movq	_V4L2_PIX_FMT_YUV420M@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_1:
	movl	$-1, %eax
	xorl	%ecx, %ecx
	jmp	LBB0_9
LBB0_7:
	movq	_V4L2_PIX_FMT_GREY@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_3:
	movl	$1, 24(%rdi)
LBB0_4:
	movq	_V4L2_PIX_FMT_YUV422M@GOTPCREL(%rip), %rax
LBB0_8:
	movq	(%rax), %rcx
	xorl	%eax, %eax
LBB0_9:
	movq	%rcx, 32(%rdi)
	popq	%rbp
	retq
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_4, LBB0_4-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
LJTI0_0:
	.long	L0_0_set_3
	.long	L0_0_set_4
	.long	L0_0_set_5
	.long	L0_0_set_5
	.long	L0_0_set_4
	.long	L0_0_set_6
	.long	L0_0_set_7
	.end_data_region
                                        ## -- End function
	.comm	_V4L2_PIX_FMT_YUV422M,8,3       ## @V4L2_PIX_FMT_YUV422M
	.comm	_V4L2_PIX_FMT_YUV420M,8,3       ## @V4L2_PIX_FMT_YUV420M
	.comm	_V4L2_PIX_FMT_GREY,8,3          ## @V4L2_PIX_FMT_GREY
	.no_dead_strip	_mtk_jpeg_decide_format
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mtk_jpeg_decide_format
_mtk_jpeg_decide_format:                ; @mtk_jpeg_decide_format
	.cfi_startproc
; %bb.0:
	ldp	x8, x9, [x0, #8]
	ldp	w10, w11, [x9]
	lsl	w10, w10, #16
	ldp	w12, w13, [x8]
	orr	w10, w10, w12, lsl #20
	orr	w10, w10, w13, lsl #12
	orr	w10, w10, w11, lsl #8
	ldr	w8, [x8, #8]
	orr	w8, w10, w8, lsl #4
	ldr	w9, [x9, #8]
	orr	w8, w8, w9
	str	w8, [x0]
	str	wzr, [x0, #24]
	sub	w8, w8, #128
	cmp	w8, #6
	b.hi	LBB0_4
; %bb.1:
Lloh0:
	adrp	x9, lJTI0_0@PAGE
Lloh1:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_2
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_2:
	mov	w8, #0
	b	LBB0_6
LBB0_3:
	mov	w8, #0
	mov	w9, #1
	str	w9, [x0, #24]
	b	LBB0_8
LBB0_4:
	mov	x9, #0
	mov	w8, #-1
	b	LBB0_11
LBB0_5:
	mov	w8, #0
	mov	w9, #1
	str	w9, [x0, #24]
LBB0_6:
Lloh2:
	adrp	x9, _V4L2_PIX_FMT_YUV422M@GOTPAGE
Lloh3:
	ldr	x9, [x9, _V4L2_PIX_FMT_YUV422M@GOTPAGEOFF]
	b	LBB0_10
LBB0_7:
	mov	w8, #0
LBB0_8:
Lloh4:
	adrp	x9, _V4L2_PIX_FMT_YUV420M@GOTPAGE
Lloh5:
	ldr	x9, [x9, _V4L2_PIX_FMT_YUV420M@GOTPAGEOFF]
	b	LBB0_10
LBB0_9:
	mov	w8, #0
Lloh6:
	adrp	x9, _V4L2_PIX_FMT_GREY@GOTPAGE
Lloh7:
	ldr	x9, [x9, _V4L2_PIX_FMT_GREY@GOTPAGEOFF]
LBB0_10:
	ldr	x9, [x9]
LBB0_11:
	str	x9, [x0, #32]
	mov	x0, x8
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_5-LBB0_2)>>2
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_3-LBB0_2)>>2
	.byte	(LBB0_3-LBB0_2)>>2
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_7-LBB0_2)>>2
	.byte	(LBB0_9-LBB0_2)>>2
                                        ; -- End function
	.comm	_V4L2_PIX_FMT_YUV422M,8,3       ; @V4L2_PIX_FMT_YUV422M
	.comm	_V4L2_PIX_FMT_YUV420M,8,3       ; @V4L2_PIX_FMT_YUV420M
	.comm	_V4L2_PIX_FMT_GREY,8,3          ; @V4L2_PIX_FMT_GREY
	.no_dead_strip	_mtk_jpeg_decide_format
.subsections_via_symbols
