	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cbs_h2645_split_fragment
_cbs_h2645_split_fragment:              ## @cbs_h2645_split_fragment
	.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
	movl	%edx, %ebx
	movq	%rsi, %r14
	movq	%rdi, %r15
	movq	16(%rdi), %rax
	xorl	%r12d, %r12d
	cmpq	$0, 16(%rsi)
	je	LBB0_2
## %bb.1:
	cmpq	$0, (%r14)
	sete	%cl
	jmp	LBB0_3
LBB0_2:
	xorl	%ecx, %ecx
LBB0_3:
	movq	8(%r15), %rdx
	movq	%rdx, -56(%rbp)                 ## 8-byte Spill
	movl	(%rax), %r13d
	movzbl	%cl, %edi
	callq	_av_assert0
	movq	8(%r14), %rdx
	testq	%rdx, %rdx
	je	LBB0_47
## %bb.4:
	movq	16(%r14), %rsi
	testl	%ebx, %ebx
	je	LBB0_39
## %bb.5:
	movq	(%rsi), %rax
	testq	%rax, %rax
	je	LBB0_25
## %bb.6:
	movq	_AV_CODEC_ID_H264@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %r13d
	jne	LBB0_25
## %bb.7:
	movq	-56(%rbp), %r12                 ## 8-byte Reload
	movl	$1, (%r12)
	leaq	-44(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_bytestream2_init
	movq	%rbx, %rdi
	callq	_bytestream2_get_bytes_left
	cmpq	$5, %rax
	jbe	LBB0_46
## %bb.8:
	leaq	-44(%rbp), %rdi
	callq	_bytestream2_get_byte
	cmpl	$1, %eax
	jne	LBB0_43
## %bb.9:
	leaq	-44(%rbp), %r13
	movl	$3, %esi
	movq	%r13, %rdi
	callq	_bytestream2_skip
	movq	%r13, %rdi
	callq	_bytestream2_get_byte
	andl	$3, %eax
	incl	%eax
	movl	%eax, 4(%r12)
	movq	%r13, %rdi
	callq	_bytestream2_get_byte
	movl	%eax, %ebx
	movq	%r13, %rdi
	callq	_bytestream2_tell
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	andl	$31, %ebx
	je	LBB0_14
## %bb.10:
	movl	%ebx, %r12d
	addq	%r12, %r12
	leaq	-44(%rbp), %r13
	.p2align	4, 0x90
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	callq	_bytestream2_get_bytes_left
	movslq	%r12d, %rcx
	cmpq	%rcx, %rax
	jb	LBB0_46
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	%r13, %rdi
	callq	_bytestream2_get_be16
	movq	%rax, %rbx
	movq	%r13, %rdi
	callq	_bytestream2_get_bytes_left
	cmpq	%rbx, %rax
	jb	LBB0_46
## %bb.13:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	%r13, %rdi
	movq	%rbx, %rsi
	callq	_bytestream2_skip
	addq	$-2, %r12
	jne	LBB0_11
LBB0_14:
	leaq	-44(%rbp), %rdi
	callq	_bytestream2_tell
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	leaq	(,%rcx,8), %rsi
	addq	16(%r14), %rsi
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	addq	$8, %rbx
	subq	%rcx, %rax
	movl	(%r15), %ecx
	movq	_AV_CODEC_ID_H264@GOTPCREL(%rip), %rdx
	movl	(%rdx), %r10d
	subq	$8, %rsp
	movq	%rbx, %rdi
	movq	%rax, %rdx
	movl	$1, %r8d
	movl	$2, %r9d
	pushq	$1
	pushq	$1
	pushq	%r10
	callq	_ff_h2645_packet_split
	addq	$32, %rsp
	testl	%eax, %eax
	js	LBB0_48
## %bb.15:
	movq	%r15, %rdi
	movq	%r14, %rsi
	movq	%rbx, %rdx
	callq	_cbs_h2645_fragment_add_nals
	testl	%eax, %eax
	js	LBB0_50
## %bb.16:
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	leaq	-44(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_bytestream2_get_byte
	movl	%eax, %r13d
	movq	%rbx, %rdi
	callq	_bytestream2_tell
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	testl	%r13d, %r13d
	jle	LBB0_21
## %bb.17:
	movl	%r13d, %r12d
	addl	%r13d, %r13d
LBB0_18:                                ## =>This Inner Loop Header: Depth=1
	leaq	-44(%rbp), %rdi
	callq	_bytestream2_get_bytes_left
	movslq	%r13d, %rcx
	cmpq	%rcx, %rax
	jb	LBB0_46
## %bb.19:                              ##   in Loop: Header=BB0_18 Depth=1
	leaq	-44(%rbp), %rdi
	callq	_bytestream2_get_be16
	movq	%rax, %rbx
	leaq	-44(%rbp), %rdi
	callq	_bytestream2_get_bytes_left
	cmpq	%rbx, %rax
	jb	LBB0_46
## %bb.20:                              ##   in Loop: Header=BB0_18 Depth=1
	leaq	-44(%rbp), %rdi
	movq	%rbx, %rsi
	callq	_bytestream2_skip
	addl	$-2, %r13d
	decq	%r12
	jne	LBB0_18
LBB0_21:
	leaq	-44(%rbp), %rdi
	callq	_bytestream2_tell
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	leaq	(,%rcx,8), %rsi
	addq	16(%r14), %rsi
	subq	%rcx, %rax
	movl	(%r15), %ecx
	movq	_AV_CODEC_ID_H264@GOTPCREL(%rip), %rdx
	movl	(%rdx), %r10d
	subq	$8, %rsp
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	movq	%rax, %rdx
	movl	$1, %r8d
	movl	$2, %r9d
	pushq	$1
	pushq	$1
	pushq	%r10
	callq	_ff_h2645_packet_split
	addq	$32, %rsp
	testl	%eax, %eax
	js	LBB0_51
## %bb.22:
	movq	%r15, %rdi
	movq	%r14, %rsi
	movq	%rbx, %rdx
	callq	_cbs_h2645_fragment_add_nals
	testl	%eax, %eax
	js	LBB0_50
## %bb.23:
	leaq	-44(%rbp), %rdi
	callq	_bytestream2_get_bytes_left
	testq	%rax, %rax
	movl	$0, %r12d
	je	LBB0_47
## %bb.24:
	movl	(%r15), %r14d
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	leaq	-44(%rbp), %rdi
	callq	_bytestream2_get_bytes_left
	leaq	L_.str.3(%rip), %rdx
	movl	%r14d, %edi
	movl	%ebx, %esi
	movq	%rax, %rcx
	xorl	%eax, %eax
	callq	_av_log
	jmp	LBB0_47
LBB0_25:
	testq	%rax, %rax
	je	LBB0_39
## %bb.26:
	movq	_AV_CODEC_ID_HEVC@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r13d
	jne	LBB0_39
## %bb.27:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	$1, (%rax)
	leaq	-44(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_bytestream2_init
	movq	%rbx, %rdi
	callq	_bytestream2_get_bytes_left
	cmpq	$22, %rax
	jbe	LBB0_46
## %bb.28:
	leaq	-44(%rbp), %rdi
	callq	_bytestream2_get_byte
	cmpl	$1, %eax
	jne	LBB0_44
## %bb.29:
	leaq	-44(%rbp), %rbx
	movl	$20, %esi
	movq	%rbx, %rdi
	callq	_bytestream2_skip
	movq	%rbx, %rdi
	callq	_bytestream2_get_byte
	andl	$3, %eax
	incl	%eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movl	%eax, 4(%rcx)
	movq	%rbx, %rdi
	callq	_bytestream2_get_byte
	movl	%eax, -76(%rbp)                 ## 4-byte Spill
	testl	%eax, %eax
	jle	LBB0_47
## %bb.30:
	addq	$8, -56(%rbp)                   ## 8-byte Folded Spill
	xorl	%eax, %eax
	leaq	-44(%rbp), %r13
LBB0_31:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_33 Depth 2
	movl	%eax, -68(%rbp)                 ## 4-byte Spill
	movq	%r13, %rdi
	callq	_bytestream2_get_byte
	movl	%eax, -72(%rbp)                 ## 4-byte Spill
	movq	%r13, %rdi
	callq	_bytestream2_get_be16
	movq	%rax, %rbx
	movq	%r13, %rdi
	callq	_bytestream2_tell
	movq	%rax, -88(%rbp)                 ## 8-byte Spill
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	testl	%ebx, %ebx
	jle	LBB0_36
## %bb.32:                              ##   in Loop: Header=BB0_31 Depth=1
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	%eax, %r12d
	.p2align	4, 0x90
LBB0_33:                                ##   Parent Loop BB0_31 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	%r13, %rdi
	callq	_bytestream2_get_bytes_left
	cmpq	$1, %rax
	jbe	LBB0_46
## %bb.34:                              ##   in Loop: Header=BB0_33 Depth=2
	movq	%r13, %rdi
	callq	_bytestream2_get_be16
	movq	%rax, %rbx
	movq	%r13, %rdi
	callq	_bytestream2_get_bytes_left
	cmpq	%rbx, %rax
	jb	LBB0_46
## %bb.35:                              ##   in Loop: Header=BB0_33 Depth=2
	movq	%r13, %rdi
	movq	%rbx, %rsi
	callq	_bytestream2_skip
	decl	%r12d
	jne	LBB0_33
LBB0_36:                                ##   in Loop: Header=BB0_31 Depth=1
	movq	%r13, %rdi
	callq	_bytestream2_tell
	movq	-88(%rbp), %rcx                 ## 8-byte Reload
	leaq	(,%rcx,8), %rsi
	addq	16(%r14), %rsi
	subq	%rcx, %rax
	movl	(%r15), %ecx
	movq	_AV_CODEC_ID_HEVC@GOTPCREL(%rip), %rdx
	movl	(%rdx), %r10d
	subq	$8, %rsp
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	movq	%rax, %rdx
	movl	$1, %r8d
	movl	$2, %r9d
	pushq	$1
	pushq	$1
	pushq	%r10
	callq	_ff_h2645_packet_split
	addq	$32, %rsp
	testl	%eax, %eax
	js	LBB0_53
## %bb.37:                              ##   in Loop: Header=BB0_31 Depth=1
	movq	%r15, %rdi
	movq	%r14, %rsi
	movq	%rbx, %rdx
	callq	_cbs_h2645_fragment_add_nals
	testl	%eax, %eax
	movl	$0, %r12d
	js	LBB0_50
## %bb.38:                              ##   in Loop: Header=BB0_31 Depth=1
	movl	-68(%rbp), %eax                 ## 4-byte Reload
	incl	%eax
	cmpl	-76(%rbp), %eax                 ## 4-byte Folded Reload
	jne	LBB0_31
	jmp	LBB0_47
LBB0_39:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	leaq	8(%rax), %rbx
	movl	(%r15), %ecx
	movl	(%rax), %r8d
	movl	4(%rax), %r9d
	subq	$8, %rsp
	movq	%rbx, %rdi
	pushq	$1
	pushq	$1
	pushq	%r13
	callq	_ff_h2645_packet_split
	addq	$32, %rsp
	testl	%eax, %eax
	js	LBB0_50
## %bb.40:
	movq	%r15, %rdi
	movq	%r14, %rsi
	movq	%rbx, %rdx
	callq	_cbs_h2645_fragment_add_nals
	testl	%eax, %eax
	jns	LBB0_47
LBB0_50:
	movl	%eax, %r12d
	jmp	LBB0_47
LBB0_43:
	movl	(%r15), %edi
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str(%rip), %rdx
	jmp	LBB0_45
LBB0_44:
	movl	(%r15), %edi
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.4(%rip), %rdx
LBB0_45:
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_46:
	movq	_AVERROR_INVALIDDATA@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
LBB0_47:
	movl	%r12d, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_48:
	movl	%eax, %r12d
	movl	(%r15), %edi
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
LBB0_49:
	xorl	%eax, %eax
	callq	_av_log
	jmp	LBB0_47
LBB0_51:
	movl	%eax, %r12d
	movl	(%r15), %edi
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.2(%rip), %rdx
	jmp	LBB0_49
LBB0_53:
	movl	%eax, %r12d
	movl	-72(%rbp), %r9d                 ## 4-byte Reload
	andl	$63, %r9d
	movl	(%r15), %edi
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.5(%rip), %rdx
	movl	-68(%rbp), %ecx                 ## 4-byte Reload
	movq	-64(%rbp), %r8                  ## 8-byte Reload
                                        ## kill: def $r8d killed $r8d killed $r8
	xorl	%eax, %eax
	callq	_av_log
	jmp	LBB0_47
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_CODEC_ID_H264,4,2           ## @AV_CODEC_ID_H264
	.comm	_AVERROR_INVALIDDATA,4,2        ## @AVERROR_INVALIDDATA
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Invalid AVCC header: first byte %u."

L_.str.1:                               ## @.str.1
	.asciz	"Failed to split AVCC SPS array.\n"

L_.str.2:                               ## @.str.2
	.asciz	"Failed to split AVCC PPS array.\n"

	.comm	_AV_LOG_WARNING,4,2             ## @AV_LOG_WARNING
L_.str.3:                               ## @.str.3
	.asciz	"%u bytes left at end of AVCC header.\n"

	.comm	_AV_CODEC_ID_HEVC,4,2           ## @AV_CODEC_ID_HEVC
L_.str.4:                               ## @.str.4
	.asciz	"Invalid HVCC header: first byte %u."

L_.str.5:                               ## @.str.5
	.asciz	"Failed to split HVCC array %d (%d NAL units of type %d).\n"

	.no_dead_strip	_cbs_h2645_split_fragment
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cbs_h2645_split_fragment
_cbs_h2645_split_fragment:              ; @cbs_h2645_split_fragment
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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	x22, x2
	mov	x20, x1
	mov	x19, x0
	ldr	x8, [x0, #16]
	ldr	x9, [x1, #16]
	cbz	x9, LBB0_2
; %bb.1:
	ldr	x9, [x20]
	cmp	x9, #0
	cset	w0, eq
	b	LBB0_3
LBB0_2:
	mov	w0, #0
LBB0_3:
	ldr	w21, [x8]
	ldr	x23, [x19, #8]
	bl	_av_assert0
	ldr	x2, [x20, #8]
	cbz	x2, LBB0_9
; %bb.4:
	ldr	x1, [x20, #16]
	cbz	w22, LBB0_7
; %bb.5:
	ldr	x8, [x1]
Lloh0:
	adrp	x24, _AV_CODEC_ID_H264@GOTPAGE
Lloh1:
	ldr	x24, [x24, _AV_CODEC_ID_H264@GOTPAGEOFF]
	ldr	w9, [x24]
	cmp	x8, #0
	ccmp	w21, w9, #0, ne
	b.eq	LBB0_10
; %bb.6:
Lloh2:
	adrp	x27, _AV_CODEC_ID_HEVC@GOTPAGE
Lloh3:
	ldr	x27, [x27, _AV_CODEC_ID_HEVC@GOTPAGEOFF]
	ldr	w9, [x27]
	cmp	x8, #0
	ccmp	w21, w9, #0, ne
	b.eq	LBB0_28
LBB0_7:
	add	x22, x23, #8
	ldr	w3, [x19]
	ldp	w4, w5, [x23]
	mov	w8, #1
	str	w8, [sp]
	mov	x0, x22
	mov	x6, x21
	mov	w7, #1
	bl	_ff_h2645_packet_split
	tbnz	w0, #31, LBB0_40
; %bb.8:
	mov	x0, x19
	mov	x1, x20
	mov	x2, x22
	bl	_cbs_h2645_fragment_add_nals
	tbnz	w0, #31, LBB0_40
LBB0_9:
	mov	w21, #0
	b	LBB0_45
LBB0_10:
	mov	w8, #1
	str	w8, [x23]
	add	x0, sp, #28
	bl	_bytestream2_init
	add	x0, sp, #28
	bl	_bytestream2_get_bytes_left
	cmp	x0, #5
	b.ls	LBB0_44
; %bb.11:
	add	x0, sp, #28
	bl	_bytestream2_get_byte
                                        ; kill: def $w0 killed $w0 def $x0
	cmp	w0, #1
	b.ne	LBB0_41
; %bb.12:
	add	x0, sp, #28
	mov	w1, #3
	bl	_bytestream2_skip
	add	x0, sp, #28
	bl	_bytestream2_get_byte
	and	w8, w0, #0x3
	add	w8, w8, #1
	str	w8, [x23, #4]
	add	x0, sp, #28
	bl	_bytestream2_get_byte
	and	w22, w0, #0x1f
	add	x0, sp, #28
	bl	_bytestream2_tell
	mov	x21, x0
	cbz	w22, LBB0_17
; %bb.13:
	lsl	x25, x22, #1
LBB0_14:                                ; =>This Inner Loop Header: Depth=1
	add	x0, sp, #28
	bl	_bytestream2_get_bytes_left
	cmp	x0, w25, sxtw
	b.lo	LBB0_44
; %bb.15:                               ;   in Loop: Header=BB0_14 Depth=1
	add	x0, sp, #28
	bl	_bytestream2_get_be16
	mov	x22, x0
	add	x0, sp, #28
	bl	_bytestream2_get_bytes_left
	cmp	x0, x22
	b.lo	LBB0_44
; %bb.16:                               ;   in Loop: Header=BB0_14 Depth=1
	add	x0, sp, #28
	mov	x1, x22
	bl	_bytestream2_skip
	subs	x25, x25, #2
	b.ne	LBB0_14
LBB0_17:
	add	x0, sp, #28
	bl	_bytestream2_tell
	add	x22, x23, #8
	ldr	x8, [x20, #16]
	add	x1, x8, x21, lsl #3
	sub	x2, x0, x21
	ldr	w3, [x19]
	ldr	w6, [x24]
	mov	w8, #1
	str	w8, [sp]
	mov	x0, x22
	mov	w4, #1
	mov	w5, #2
	mov	w7, #1
	bl	_ff_h2645_packet_split
	tbnz	w0, #31, LBB0_46
; %bb.18:
	mov	x0, x19
	mov	x1, x20
	mov	x2, x22
	bl	_cbs_h2645_fragment_add_nals
	tbnz	w0, #31, LBB0_40
; %bb.19:
	add	x0, sp, #28
	bl	_bytestream2_get_byte
	mov	x23, x0
	add	x0, sp, #28
	bl	_bytestream2_tell
	mov	x21, x0
	cmp	w23, #1
	b.lt	LBB0_24
; %bb.20:
	lsl	w25, w23, #1
	mov	w26, w23
LBB0_21:                                ; =>This Inner Loop Header: Depth=1
	add	x0, sp, #28
	bl	_bytestream2_get_bytes_left
	cmp	x0, w25, sxtw
	b.lo	LBB0_44
; %bb.22:                               ;   in Loop: Header=BB0_21 Depth=1
	add	x0, sp, #28
	bl	_bytestream2_get_be16
	mov	x23, x0
	add	x0, sp, #28
	bl	_bytestream2_get_bytes_left
	cmp	x0, x23
	b.lo	LBB0_44
; %bb.23:                               ;   in Loop: Header=BB0_21 Depth=1
	add	x0, sp, #28
	mov	x1, x23
	bl	_bytestream2_skip
	sub	w25, w25, #2
	subs	x26, x26, #1
	b.ne	LBB0_21
LBB0_24:
	add	x0, sp, #28
	bl	_bytestream2_tell
	ldr	x8, [x20, #16]
	add	x1, x8, x21, lsl #3
	sub	x2, x0, x21
	ldr	w3, [x19]
	ldr	w6, [x24]
	mov	w8, #1
	str	w8, [sp]
	mov	x0, x22
	mov	w4, #1
	mov	w5, #2
	mov	w7, #1
	bl	_ff_h2645_packet_split
	tbnz	w0, #31, LBB0_47
; %bb.25:
	mov	x0, x19
	mov	x1, x20
	mov	x2, x22
	bl	_cbs_h2645_fragment_add_nals
	tbnz	w0, #31, LBB0_40
; %bb.26:
	add	x0, sp, #28
	bl	_bytestream2_get_bytes_left
	cbz	x0, LBB0_9
; %bb.27:
	ldr	w19, [x19]
Lloh4:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh5:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh6:
	ldr	w20, [x8]
	add	x0, sp, #28
	bl	_bytestream2_get_bytes_left
	str	x0, [sp]
Lloh7:
	adrp	x2, l_.str.3@PAGE
Lloh8:
	add	x2, x2, l_.str.3@PAGEOFF
	mov	x0, x19
	mov	x1, x20
	bl	_av_log
	b	LBB0_9
LBB0_28:
	mov	w8, #1
	str	w8, [x23]
	add	x0, sp, #28
	bl	_bytestream2_init
	add	x0, sp, #28
	bl	_bytestream2_get_bytes_left
	cmp	x0, #22
	b.ls	LBB0_44
; %bb.29:
	add	x0, sp, #28
	bl	_bytestream2_get_byte
                                        ; kill: def $w0 killed $w0 def $x0
	cmp	w0, #1
	b.ne	LBB0_42
; %bb.30:
	add	x0, sp, #28
	mov	w1, #20
	bl	_bytestream2_skip
	add	x0, sp, #28
	bl	_bytestream2_get_byte
	and	w8, w0, #0x3
	add	w8, w8, #1
	str	w8, [x23, #4]
	add	x0, sp, #28
	bl	_bytestream2_get_byte
	cmp	w0, #1
	b.lt	LBB0_9
; %bb.31:
	mov	x22, x0
	mov	w28, #0
	add	x23, x23, #8
LBB0_32:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_34 Depth 2
	add	x0, sp, #28
	bl	_bytestream2_get_byte
	str	w0, [sp, #24]                   ; 4-byte Folded Spill
	add	x0, sp, #28
	bl	_bytestream2_get_be16
	mov	x24, x0
	add	x0, sp, #28
	bl	_bytestream2_tell
	mov	x21, x0
	cmp	w24, #1
	b.lt	LBB0_37
; %bb.33:                               ;   in Loop: Header=BB0_32 Depth=1
	mov	x25, x24
LBB0_34:                                ;   Parent Loop BB0_32 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	add	x0, sp, #28
	bl	_bytestream2_get_bytes_left
	cmp	x0, #1
	b.ls	LBB0_44
; %bb.35:                               ;   in Loop: Header=BB0_34 Depth=2
	add	x0, sp, #28
	bl	_bytestream2_get_be16
	mov	x26, x0
	add	x0, sp, #28
	bl	_bytestream2_get_bytes_left
	cmp	x0, x26
	b.lo	LBB0_44
; %bb.36:                               ;   in Loop: Header=BB0_34 Depth=2
	add	x0, sp, #28
	mov	x1, x26
	bl	_bytestream2_skip
	subs	w25, w25, #1
	b.ne	LBB0_34
LBB0_37:                                ;   in Loop: Header=BB0_32 Depth=1
	add	x0, sp, #28
	bl	_bytestream2_tell
	ldr	x8, [x20, #16]
	add	x1, x8, x21, lsl #3
	sub	x2, x0, x21
	ldr	w3, [x19]
	ldr	w6, [x27]
	mov	w8, #1
	str	w8, [sp]
	mov	x0, x23
	mov	w4, #1
	mov	w5, #2
	mov	w7, #1
	bl	_ff_h2645_packet_split
	tbnz	w0, #31, LBB0_48
; %bb.38:                               ;   in Loop: Header=BB0_32 Depth=1
	mov	x0, x19
	mov	x1, x20
	mov	x2, x23
	bl	_cbs_h2645_fragment_add_nals
	tbnz	w0, #31, LBB0_40
; %bb.39:                               ;   in Loop: Header=BB0_32 Depth=1
	add	w28, w28, #1
	cmp	w28, w22
	b.ne	LBB0_32
	b	LBB0_9
LBB0_40:
	mov	x21, x0
	b	LBB0_45
LBB0_41:
	ldr	w8, [x19]
Lloh9:
	adrp	x9, _AV_LOG_ERROR@GOTPAGE
Lloh10:
	ldr	x9, [x9, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x9]
	str	x0, [sp]
Lloh12:
	adrp	x2, l_.str@PAGE
Lloh13:
	add	x2, x2, l_.str@PAGEOFF
	b	LBB0_43
LBB0_42:
	ldr	w8, [x19]
Lloh14:
	adrp	x9, _AV_LOG_ERROR@GOTPAGE
Lloh15:
	ldr	x9, [x9, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x9]
	str	x0, [sp]
Lloh17:
	adrp	x2, l_.str.4@PAGE
Lloh18:
	add	x2, x2, l_.str.4@PAGEOFF
LBB0_43:
	mov	x0, x8
	bl	_av_log
LBB0_44:
Lloh19:
	adrp	x8, _AVERROR_INVALIDDATA@GOTPAGE
Lloh20:
	ldr	x8, [x8, _AVERROR_INVALIDDATA@GOTPAGEOFF]
Lloh21:
	ldr	w21, [x8]
LBB0_45:
	mov	x0, x21
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_46:
	mov	x21, x0
	ldr	w0, [x19]
Lloh22:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh23:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh24:
	ldr	w1, [x8]
Lloh25:
	adrp	x2, l_.str.1@PAGE
Lloh26:
	add	x2, x2, l_.str.1@PAGEOFF
	bl	_av_log
	b	LBB0_45
LBB0_47:
	mov	x21, x0
	ldr	w0, [x19]
Lloh27:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh28:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh29:
	ldr	w1, [x8]
Lloh30:
	adrp	x2, l_.str.2@PAGE
Lloh31:
	add	x2, x2, l_.str.2@PAGEOFF
	bl	_av_log
	b	LBB0_45
LBB0_48:
	mov	x21, x0
	ldr	w8, [sp, #24]                   ; 4-byte Folded Reload
	and	w8, w8, #0x3f
	ldr	w0, [x19]
Lloh32:
	adrp	x9, _AV_LOG_ERROR@GOTPAGE
Lloh33:
	ldr	x9, [x9, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh34:
	ldr	w1, [x9]
	stp	x24, x8, [sp, #8]
	str	x28, [sp]
Lloh35:
	adrp	x2, l_.str.5@PAGE
Lloh36:
	add	x2, x2, l_.str.5@PAGEOFF
	bl	_av_log
	b	LBB0_45
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_CODEC_ID_H264,4,2           ; @AV_CODEC_ID_H264
	.comm	_AVERROR_INVALIDDATA,4,2        ; @AVERROR_INVALIDDATA
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Invalid AVCC header: first byte %u."

l_.str.1:                               ; @.str.1
	.asciz	"Failed to split AVCC SPS array.\n"

l_.str.2:                               ; @.str.2
	.asciz	"Failed to split AVCC PPS array.\n"

	.comm	_AV_LOG_WARNING,4,2             ; @AV_LOG_WARNING
l_.str.3:                               ; @.str.3
	.asciz	"%u bytes left at end of AVCC header.\n"

	.comm	_AV_CODEC_ID_HEVC,4,2           ; @AV_CODEC_ID_HEVC
l_.str.4:                               ; @.str.4
	.asciz	"Invalid HVCC header: first byte %u."

l_.str.5:                               ; @.str.5
	.asciz	"Failed to split HVCC array %d (%d NAL units of type %d).\n"

	.no_dead_strip	_cbs_h2645_split_fragment
.subsections_via_symbols
