	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sd_pkt_scan
_sd_pkt_scan:                           ## @sd_pkt_scan
	.cfi_startproc
## %bb.0:
	cmpl	$6, %edx
	jge	LBB0_1
## %bb.13:
	retq
LBB0_1:
	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
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r12
	movq	%rdi, %r15
	jne	LBB0_3
## %bb.2:
	movl	$6, %r14d
LBB0_12:
	movq	_INTER_PACKET@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movq	%r12, %rdx
	movl	%r14d, %ecx
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_gspca_frame_add                ## TAILCALL
LBB0_3:
	movl	%edx, %r14d
	leal	-6(%r14), %eax
	xorl	%ebx, %ebx
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_4 Depth=1
	incq	%rbx
	cmpq	%rbx, %rax
	je	LBB0_12
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	$255, (%r12,%rbx,4)
	jne	LBB0_11
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$255, 4(%r12,%rbx,4)
	jne	LBB0_11
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$0, 8(%r12,%rbx,4)
	jne	LBB0_11
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$255, 12(%r12,%rbx,4)
	jne	LBB0_11
## %bb.8:                               ##   in Loop: Header=BB0_4 Depth=1
	cmpl	$150, 16(%r12,%rbx,4)
	jne	LBB0_11
## %bb.9:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	20(%r12,%rbx,4), %ecx
	andl	$-4, %ecx
	cmpl	$100, %ecx
	jne	LBB0_11
## %bb.10:
	movq	_D_PACK@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r15, %rdi
	movl	%ebx, %ecx
	movl	%r14d, %r8d
	callq	_gspca_dbg
	movq	_LAST_PACKET@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movq	%r12, %rdx
	movl	%ebx, %ecx
	callq	_gspca_frame_add
	movq	_FIRST_PACKET@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	(%r15), %rdx
	movq	_JPEG_HDR_SZ@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r15, %rdi
	callq	_gspca_frame_add
	leal	16(%rbx), %eax
	leaq	(%r12,%rax,4), %r12
	subl	%ebx, %r14d
	addl	$-16, %r14d
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_D_PACK,4,2                     ## @D_PACK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"sof offset: %d len: %d\n"

	.comm	_LAST_PACKET,4,2                ## @LAST_PACKET
	.comm	_FIRST_PACKET,4,2               ## @FIRST_PACKET
	.comm	_JPEG_HDR_SZ,4,2                ## @JPEG_HDR_SZ
	.comm	_INTER_PACKET,4,2               ## @INTER_PACKET
	.no_dead_strip	_sd_pkt_scan
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sd_pkt_scan
_sd_pkt_scan:                           ; @sd_pkt_scan
	.cfi_startproc
; %bb.0:
	subs	w8, w2, #6
	b.ge	LBB0_2
; %bb.1:
	ret
LBB0_2:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x20, x1
	mov	x21, x0
	b.ne	LBB0_5
; %bb.3:
	mov	w19, #6
LBB0_4:
Lloh0:
	adrp	x8, _INTER_PACKET@GOTPAGE
Lloh1:
	ldr	x8, [x8, _INTER_PACKET@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x21
	mov	x2, x20
	mov	x3, 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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_gspca_frame_add
LBB0_5:
	mov	x19, x2
	add	x9, x20, #12
	mov	w23, #16
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	add	w23, w23, #1
	add	x9, x9, #4
	subs	x8, x8, #1
	b.eq	LBB0_4
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldur	w10, [x9, #-12]
	cmp	w10, #255
	b.ne	LBB0_6
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	ldur	w10, [x9, #-8]
	cmp	w10, #255
	b.ne	LBB0_6
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	ldur	w10, [x9, #-4]
	cbnz	w10, LBB0_6
; %bb.10:                               ;   in Loop: Header=BB0_7 Depth=1
	ldr	w10, [x9]
	cmp	w10, #255
	b.ne	LBB0_6
; %bb.11:                               ;   in Loop: Header=BB0_7 Depth=1
	ldr	w10, [x9, #4]
	cmp	w10, #150
	b.ne	LBB0_6
; %bb.12:                               ;   in Loop: Header=BB0_7 Depth=1
	ldr	w10, [x9, #8]
	and	w10, w10, #0xfffffffc
	cmp	w10, #100
	b.ne	LBB0_6
; %bb.13:
	sub	w22, w23, #16
Lloh3:
	adrp	x8, _D_PACK@GOTPAGE
Lloh4:
	ldr	x8, [x8, _D_PACK@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x2, l_.str@PAGE
Lloh7:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x21
	mov	x3, x22
	mov	x4, x19
	bl	_gspca_dbg
Lloh8:
	adrp	x8, _LAST_PACKET@GOTPAGE
Lloh9:
	ldr	x8, [x8, _LAST_PACKET@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x0, x21
	mov	x2, x20
	mov	x3, x22
	bl	_gspca_frame_add
Lloh11:
	adrp	x8, _FIRST_PACKET@GOTPAGE
Lloh12:
	ldr	x8, [x8, _FIRST_PACKET@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	ldr	x2, [x21]
Lloh14:
	adrp	x8, _JPEG_HDR_SZ@GOTPAGE
Lloh15:
	ldr	x8, [x8, _JPEG_HDR_SZ@GOTPAGEOFF]
Lloh16:
	ldr	w3, [x8]
	mov	x0, x21
	bl	_gspca_frame_add
	add	x20, x20, w23, uxtw #2
	sub	w19, w19, w23
	b	LBB0_4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_D_PACK,4,2                     ; @D_PACK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"sof offset: %d len: %d\n"

	.comm	_LAST_PACKET,4,2                ; @LAST_PACKET
	.comm	_FIRST_PACKET,4,2               ; @FIRST_PACKET
	.comm	_JPEG_HDR_SZ,4,2                ; @JPEG_HDR_SZ
	.comm	_INTER_PACKET,4,2               ; @INTER_PACKET
	.no_dead_strip	_sd_pkt_scan
.subsections_via_symbols
