	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mjpega_dump_header
_mjpega_dump_header:                    ## @mjpega_dump_header
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %rbx
	leaq	-48(%rbp), %rsi
	callq	_ff_bsf_get_packet
	testl	%eax, %eax
	js	LBB0_20
## %bb.1:
	movq	-48(%rbp), %rax
	movl	(%rax), %esi
	addl	$44, %esi
	movq	%r15, %rdi
	callq	_av_new_packet
	testl	%eax, %eax
	js	LBB0_19
## %bb.2:
	movq	-48(%rbp), %rsi
	movq	%r15, %rdi
	callq	_av_packet_copy_props
	testl	%eax, %eax
	js	LBB0_19
## %bb.3:
	movq	%rbx, -88(%rbp)                 ## 8-byte Spill
	movq	8(%r15), %rax
	movq	%rax, -56(%rbp)
	leaq	-56(%rbp), %rbx
	movq	%rbx, %rdi
	movl	$255, %esi
	callq	_bytestream_put_byte
	movq	_SOI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_bytestream_put_byte
	movq	%rbx, %rdi
	movl	$255, %esi
	callq	_bytestream_put_byte
	movq	%rbx, %rdi
	movl	$132, %esi
	callq	_bytestream_put_byte
	movq	%rbx, %rdi
	movl	$42, %esi
	callq	_bytestream_put_be16
	xorl	%eax, %eax
	movq	%rax, -96(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_bytestream_put_be32
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	movl	$4, %edx
	callq	_bytestream_put_buffer
	movq	-48(%rbp), %rax
	movl	(%rax), %esi
	addl	$44, %esi
	movq	%rbx, %rdi
	callq	_bytestream_put_be32
	movq	-48(%rbp), %rax
	movl	(%rax), %esi
	addl	$44, %esi
	movq	%rbx, %rdi
	callq	_bytestream_put_be32
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_bytestream_put_be32
	movq	-48(%rbp), %rax
	movl	(%rax), %ecx
	cmpl	$2, %ecx
	jl	LBB0_18
## %bb.4:
	movl	$8, %r13d
	movl	$46, %ebx
	movl	$32, %r14d
	leaq	LJTI0_0(%rip), %r9
	xorl	%r12d, %r12d
	xorl	%r8d, %r8d
	xorl	%esi, %esi
	movq	%r15, -80(%rbp)                 ## 8-byte Spill
	jmp	LBB0_5
LBB0_16:                                ##   in Loop: Header=BB0_5 Depth=1
	movl	%ebx, %esi
	.p2align	4, 0x90
LBB0_17:                                ##   in Loop: Header=BB0_5 Depth=1
	incq	%r12
	movslq	(%rax), %rcx
	movq	%rcx, %rdx
	decq	%rdx
	addl	$4, %r13d
	incl	%ebx
	addq	$4, %r14
	cmpq	%rdx, %r12
	jge	LBB0_18
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%rax), %rdi
	cmpl	$255, (%rdi,%r12,4)
	jne	LBB0_17
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	4(%rdi,%r12,4), %edx
	addl	$-128, %edx
	cmpl	$4, %edx
	ja	LBB0_17
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=1
	movslq	(%r9,%rdx,4), %rdx
	addq	%r9, %rdx
	jmpq	*%rdx
LBB0_9:                                 ##   in Loop: Header=BB0_5 Depth=1
	movl	%ebx, %ecx
	movq	%rcx, -96(%rbp)                 ## 8-byte Spill
	jmp	LBB0_17
LBB0_8:                                 ##   in Loop: Header=BB0_5 Depth=1
	movl	%ebx, %r8d
	jmp	LBB0_17
LBB0_11:                                ##   in Loop: Header=BB0_5 Depth=1
	leal	-38(%rbx), %edx
	cmpl	%ecx, %edx
	jge	LBB0_17
## %bb.12:                              ##   in Loop: Header=BB0_5 Depth=1
	movl	%esi, -60(%rbp)                 ## 4-byte Spill
	movl	%r8d, -64(%rbp)                 ## 4-byte Spill
	movq	%r9, %r15
	addq	%r14, %rdi
	callq	_AV_RL32
	movl	%eax, -68(%rbp)                 ## 4-byte Spill
	leaq	L_.str(%rip), %rdi
	callq	_AV_RL32
	cmpl	%eax, -68(%rbp)                 ## 4-byte Folded Reload
	je	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_5 Depth=1
	movq	-48(%rbp), %rax
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	%r15, %r9
	movq	%rcx, %r15
	movl	-64(%rbp), %r8d                 ## 4-byte Reload
	movl	-60(%rbp), %esi                 ## 4-byte Reload
	jmp	LBB0_17
LBB0_18:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.2(%rip), %rdx
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	callq	_av_log
LBB0_19:
	movq	%r15, %rdi
	callq	_av_packet_unref
	leaq	-48(%rbp), %rdi
	callq	_av_packet_free
	movq	_AVERROR_INVALIDDATA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_20:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	leaq	-56(%rbp), %r14
	movq	%r14, %rdi
	movl	%r8d, %r12d
	callq	_bytestream_put_be32
	movq	%r14, %rdi
	movl	%r12d, %esi
	callq	_bytestream_put_be32
	movq	%r14, %rdi
	movq	-96(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_bytestream_put_be32
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_bytestream_put_be32
	movq	-48(%rbp), %rax
	addl	8(%rax), %r13d
	movl	%r13d, %edi
	callq	_AV_RB16
	addl	%eax, %ebx
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_bytestream_put_be32
	movq	-48(%rbp), %rax
	movq	8(%rax), %rsi
	addq	$8, %rsi
	movl	(%rax), %edx
	addl	$-2, %edx
	movq	%r14, %rdi
	callq	_bytestream_put_buffer
	movq	-56(%rbp), %rax
	subq	8(%r15), %rax
	shrq	$2, %rax
	movl	%eax, (%r15)
	jmp	LBB0_15
LBB0_14:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	callq	_av_log
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	callq	_av_packet_unref
	movq	-48(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_av_packet_move_ref
LBB0_15:
	leaq	-48(%rbp), %rdi
	callq	_av_packet_free
	xorl	%eax, %eax
	jmp	LBB0_20
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_10, LBB0_10-LJTI0_0
.set L0_0_set_9, LBB0_9-LJTI0_0
.set L0_0_set_16, LBB0_16-LJTI0_0
.set L0_0_set_8, LBB0_8-LJTI0_0
.set L0_0_set_11, LBB0_11-LJTI0_0
LJTI0_0:
	.long	L0_0_set_10
	.long	L0_0_set_9
	.long	L0_0_set_16
	.long	L0_0_set_8
	.long	L0_0_set_11
	.end_data_region
                                        ## -- End function
	.comm	_SOI,4,2                        ## @SOI
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"mjpg"

	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
L_.str.1:                               ## @.str.1
	.asciz	"bitstream already formatted\n"

L_.str.2:                               ## @.str.2
	.asciz	"could not find SOS marker in bitstream\n"

	.comm	_AVERROR_INVALIDDATA,4,2        ## @AVERROR_INVALIDDATA
	.no_dead_strip	_mjpega_dump_header
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mjpega_dump_header
_mjpega_dump_header:                    ; @mjpega_dump_header
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x1
	mov	x20, x0
	add	x1, sp, #8
	bl	_ff_bsf_get_packet
	tbnz	w0, #31, LBB0_17
; %bb.1:
	ldr	x8, [sp, #8]
	ldr	w8, [x8]
	add	w1, w8, #44
	mov	x0, x19
	bl	_av_new_packet
	tbnz	w0, #31, LBB0_16
; %bb.2:
	ldr	x1, [sp, #8]
	mov	x0, x19
	bl	_av_packet_copy_props
	tbnz	w0, #31, LBB0_16
; %bb.3:
	ldr	x8, [x19, #8]
	str	x8, [sp]
	mov	x0, sp
	mov	w1, #255
	bl	_bytestream_put_byte
Lloh0:
	adrp	x8, _SOI@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SOI@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, sp
	bl	_bytestream_put_byte
	mov	x0, sp
	mov	w1, #255
	bl	_bytestream_put_byte
	mov	x0, sp
	mov	w1, #132
	bl	_bytestream_put_byte
	mov	x0, sp
	mov	w1, #42
	bl	_bytestream_put_be16
	mov	x0, sp
	mov	w1, #0
	bl	_bytestream_put_be32
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, sp
	mov	w2, #4
	bl	_bytestream_put_buffer
	ldr	x8, [sp, #8]
	ldr	w8, [x8]
	add	w1, w8, #44
	mov	x0, sp
	bl	_bytestream_put_be32
	ldr	x8, [sp, #8]
	ldr	w8, [x8]
	add	w1, w8, #44
	mov	x0, sp
	bl	_bytestream_put_be32
	mov	x0, sp
	mov	w1, #0
	bl	_bytestream_put_be32
	ldr	x8, [sp, #8]
	ldr	w9, [x8]
	cmp	w9, #2
	b.lt	LBB0_15
; %bb.4:
	mov	x26, #0
	mov	w21, #0
	mov	w22, #0
	mov	w23, #0
	mov	w27, #8
	mov	w28, #32
Lloh5:
	adrp	x24, lJTI0_0@PAGE
Lloh6:
	add	x24, x24, lJTI0_0@PAGEOFF
	b	LBB0_7
LBB0_5:                                 ;   in Loop: Header=BB0_7 Depth=1
	add	w23, w26, #46
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	add	x26, x26, #1
	ldrsw	x9, [x8]
	sub	x10, x9, #1
	add	w27, w27, #4
	add	x28, x28, #4
	cmp	x26, x10
	b.ge	LBB0_15
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x8, #8]
	ldr	w11, [x10, x26, lsl #2]
	cmp	w11, #255
	b.ne	LBB0_6
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	add	x11, x10, x26, lsl #2
	ldr	w11, [x11, #4]
	sub	w11, w11, #128
	cmp	w11, #4
	b.hi	LBB0_6
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	adr	x12, LBB0_5
	ldrb	w13, [x24, x11]
	add	x12, x12, x13, lsl #2
	br	x12
LBB0_10:                                ;   in Loop: Header=BB0_7 Depth=1
	add	w21, w26, #46
	b	LBB0_6
LBB0_11:                                ;   in Loop: Header=BB0_7 Depth=1
	add	w22, w26, #46
	b	LBB0_6
LBB0_12:                                ;   in Loop: Header=BB0_7 Depth=1
	add	w11, w26, #8
	cmp	w11, w9
	b.ge	LBB0_6
; %bb.13:                               ;   in Loop: Header=BB0_7 Depth=1
	add	x0, x10, x28
	bl	_AV_RL32
	mov	x25, x0
Lloh7:
	adrp	x0, l_.str@PAGE
Lloh8:
	add	x0, x0, l_.str@PAGEOFF
	bl	_AV_RL32
	cmp	w25, w0
	b.eq	LBB0_19
; %bb.14:                               ;   in Loop: Header=BB0_7 Depth=1
	ldr	x8, [sp, #8]
	b	LBB0_6
LBB0_15:
Lloh9:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh10:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
Lloh12:
	adrp	x2, l_.str.2@PAGE
Lloh13:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_av_log
LBB0_16:
	mov	x0, x19
	bl	_av_packet_unref
	add	x0, sp, #8
	bl	_av_packet_free
Lloh14:
	adrp	x8, _AVERROR_INVALIDDATA@GOTPAGE
Lloh15:
	ldr	x8, [x8, _AVERROR_INVALIDDATA@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
LBB0_17:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_18:
	mov	x0, sp
	mov	x1, x23
	bl	_bytestream_put_be32
	mov	x0, sp
	mov	x1, x22
	bl	_bytestream_put_be32
	mov	x0, sp
	mov	x1, x21
	bl	_bytestream_put_be32
	add	w1, w26, #46
	mov	x0, sp
	bl	_bytestream_put_be32
	ldr	x8, [sp, #8]
	ldr	w8, [x8, #8]
	add	w0, w8, w27
	bl	_AV_RB16
	add	w8, w0, w26
	add	w1, w8, #46
	mov	x0, sp
	bl	_bytestream_put_be32
	ldr	x8, [sp, #8]
	ldr	x9, [x8, #8]
	add	x1, x9, #8
	ldr	w8, [x8]
	sub	w2, w8, #2
	mov	x0, sp
	bl	_bytestream_put_buffer
	ldr	x8, [sp]
	ldr	x9, [x19, #8]
	sub	x8, x8, x9
	lsr	x8, x8, #2
	str	w8, [x19]
	b	LBB0_20
LBB0_19:
Lloh17:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh18:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
Lloh20:
	adrp	x2, l_.str.1@PAGE
Lloh21:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_av_log
	mov	x0, x19
	bl	_av_packet_unref
	ldr	x1, [sp, #8]
	mov	x0, x19
	bl	_av_packet_move_ref
LBB0_20:
	add	x0, sp, #8
	bl	_av_packet_free
	mov	w0, #0
	b	LBB0_17
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_18-LBB0_5)>>2
	.byte	(LBB0_10-LBB0_5)>>2
	.byte	(LBB0_5-LBB0_5)>>2
	.byte	(LBB0_11-LBB0_5)>>2
	.byte	(LBB0_12-LBB0_5)>>2
                                        ; -- End function
	.comm	_SOI,4,2                        ; @SOI
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"mjpg"

	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
l_.str.1:                               ; @.str.1
	.asciz	"bitstream already formatted\n"

l_.str.2:                               ; @.str.2
	.asciz	"could not find SOS marker in bitstream\n"

	.comm	_AVERROR_INVALIDDATA,4,2        ; @AVERROR_INVALIDDATA
	.no_dead_strip	_mjpega_dump_header
.subsections_via_symbols
