	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ff_hevc_decode_extradata       ## -- Begin function ff_hevc_decode_extradata
	.p2align	4, 0x90
_ff_hevc_decode_extradata:              ## @ff_hevc_decode_extradata
	.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	%r9, -56(%rbp)                  ## 8-byte Spill
	movq	%r8, -64(%rbp)                  ## 8-byte Spill
	movq	%rcx, -96(%rbp)                 ## 8-byte Spill
	movq	%rdx, -88(%rbp)                 ## 8-byte Spill
	movl	%esi, %ebx
	movq	%rdi, %r14
	leaq	-72(%rbp), %rdi
	movq	%r14, %rsi
	movl	%ebx, %edx
	callq	_bytestream2_init
	cmpl	$4, %ebx
	jl	LBB0_17
## %bb.1:
	cmpl	$0, (%r14)
	jne	LBB0_4
## %bb.2:
	cmpl	$0, 4(%r14)
	jne	LBB0_4
## %bb.3:
	cmpl	$2, 8(%r14)
	jl	LBB0_17
LBB0_4:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	$1, (%rax)
	leaq	-72(%rbp), %rbx
	movq	%rbx, %rdi
	movl	$21, %esi
	callq	_bytestream2_skip
	movq	%rbx, %rdi
	callq	_bytestream2_get_byte
	movl	%eax, %r13d
	movq	%rbx, %rdi
	callq	_bytestream2_get_byte
	movl	%eax, %ecx
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	$2, (%rax)
	movl	%ecx, -80(%rbp)                 ## 4-byte Spill
	xorl	%r14d, %r14d
	testl	%ecx, %ecx
	jle	LBB0_16
## %bb.5:
	movb	$1, %bl
	leaq	-72(%rbp), %r15
	xorl	%eax, %eax
	jmp	LBB0_6
LBB0_17:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	$0, (%rax)
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %r9d
	subq	$8, %rsp
	movq	%r14, %rdi
	movl	%ebx, %esi
	movq	-88(%rbp), %rdx                 ## 8-byte Reload
	movq	-96(%rbp), %rcx                 ## 8-byte Reload
	xorl	%r8d, %r8d
	pushq	32(%rbp)
	movl	24(%rbp), %eax
	pushq	%rax
	movl	16(%rbp), %eax
	pushq	%rax
	callq	_hevc_decode_nal_units
	addq	$32, %rsp
	movl	%eax, %r14d
	testl	%eax, %eax
	jns	LBB0_18
	jmp	LBB0_19
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_6 Depth=1
	movl	-48(%rbp), %eax                 ## 4-byte Reload
	incl	%eax
	cmpl	-80(%rbp), %eax                 ## 4-byte Folded Reload
	setl	%bl
	je	LBB0_16
LBB0_6:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_8 Depth 2
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	%r15, %rdi
	callq	_bytestream2_get_byte
	movl	%eax, -76(%rbp)                 ## 4-byte Spill
	movq	%r15, %rdi
	callq	_bytestream2_get_be16
	testl	%eax, %eax
	jle	LBB0_15
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	movl	%eax, %r12d
	movb	%bl, -41(%rbp)                  ## 1-byte Spill
	movl	%r13d, %ebx
	.p2align	4, 0x90
LBB0_8:                                 ##   Parent Loop BB0_6 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	%r15, %rdi
	callq	_bytestream2_peek_be16
	movl	%eax, %r13d
	addl	$2, %r13d
	movq	%r15, %rdi
	callq	_bytestream2_get_bytes_left
	cmpl	%r13d, %eax
	jl	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_8 Depth=2
	movq	-72(%rbp), %rdi
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %r8d
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %r9d
	subq	$8, %rsp
	movl	%r13d, %esi
	movq	-88(%rbp), %rdx                 ## 8-byte Reload
	movq	-96(%rbp), %rcx                 ## 8-byte Reload
	pushq	32(%rbp)
	movl	24(%rbp), %eax
	pushq	%rax
	movl	16(%rbp), %eax
	pushq	%rax
	callq	_hevc_decode_nal_units
	addq	$32, %rsp
	movl	%eax, %r14d
	testl	%eax, %eax
	js	LBB0_11
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=2
	movq	%r15, %rdi
	movl	%r13d, %esi
	callq	_bytestream2_skip
	decl	%r12d
	jne	LBB0_8
## %bb.14:                              ##   in Loop: Header=BB0_6 Depth=1
	movl	%ebx, %r13d
	jmp	LBB0_15
LBB0_16:
	andl	$3, %r13d
	incl	%r13d
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	%r13d, (%rax)
	jmp	LBB0_18
LBB0_11:
	movl	-76(%rbp), %ecx                 ## 4-byte Reload
	andl	$63, %ecx
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	movq	32(%rbp), %rdi
	movl	-48(%rbp), %r8d                 ## 4-byte Reload
	xorl	%eax, %eax
	callq	_av_log
	movl	%r14d, %eax
	jmp	LBB0_12
LBB0_9:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	32(%rbp), %rdi
	xorl	%eax, %eax
	callq	_av_log
	movq	_AVERROR_INVALIDDATA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_12:
	testb	$1, -41(%rbp)                   ## 1-byte Folded Reload
	jne	LBB0_19
LBB0_18:
	movl	%r14d, %eax
LBB0_19:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Invalid NAL unit size in extradata.\n"

	.comm	_AVERROR_INVALIDDATA,4,2        ## @AVERROR_INVALIDDATA
L_.str.1:                               ## @.str.1
	.asciz	"Decoding nal unit %d %d from hvcC failed\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ff_hevc_decode_extradata       ; -- Begin function ff_hevc_decode_extradata
	.p2align	2
_ff_hevc_decode_extradata:              ; @ff_hevc_decode_extradata
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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	x20, x7
	mov	x21, x6
	mov	x22, x5
	mov	x25, x4
	mov	x23, x3
	mov	x24, x2
	mov	x26, x1
	mov	x27, x0
	ldr	x19, [x29, #16]
	add	x0, sp, #40
	mov	x1, x27
	mov	x2, x26
	bl	_bytestream2_init
	cmp	w26, #4
	b.lt	LBB0_6
; %bb.1:
	ldr	w8, [x27]
	cbnz	w8, LBB0_4
; %bb.2:
	ldr	w8, [x27, #4]
	cbnz	w8, LBB0_4
; %bb.3:
	ldr	w8, [x27, #8]
	cmp	w8, #2
	b.lt	LBB0_6
LBB0_4:
	mov	w8, #1
	str	w8, [x25]
	add	x0, sp, #40
	mov	w1, #21
	bl	_bytestream2_skip
	add	x0, sp, #40
	bl	_bytestream2_get_byte
	str	w0, [sp, #16]                   ; 4-byte Folded Spill
	add	x0, sp, #40
	bl	_bytestream2_get_byte
	mov	w8, #2
	str	w8, [x22]
	str	w0, [sp, #28]                   ; 4-byte Folded Spill
	cmp	w0, #1
	b.lt	LBB0_13
; %bb.5:
	mov	w26, #0
	mov	w8, #0
	mov	w28, #1
	b	LBB0_8
LBB0_6:
	str	wzr, [x25]
	ldr	w5, [x22]
	str	x19, [sp]
	mov	x0, x27
	mov	x1, x26
	mov	x2, x24
	mov	x3, x23
	mov	w4, #0
	mov	x6, x21
	mov	x7, x20
	bl	_hevc_decode_nal_units
	mov	x26, x0
	b	LBB0_18
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	ldr	x8, [sp, #32]                   ; 8-byte Folded Reload
	add	w8, w8, #1
	ldr	w9, [sp, #28]                   ; 4-byte Folded Reload
	cmp	w8, w9
	cset	w28, lt
	b.eq	LBB0_14
LBB0_8:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_10 Depth 2
	str	x8, [sp, #32]                   ; 8-byte Folded Spill
	add	x0, sp, #40
	bl	_bytestream2_get_byte
	str	w0, [sp, #24]                   ; 4-byte Folded Spill
	add	x0, sp, #40
	bl	_bytestream2_get_be16
	cmp	w0, #1
	b.lt	LBB0_7
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	mov	x27, x0
	str	w28, [sp, #20]                  ; 4-byte Folded Spill
LBB0_10:                                ;   Parent Loop BB0_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	add	x0, sp, #40
	bl	_bytestream2_peek_be16
	add	w28, w0, #2
	add	x0, sp, #40
	bl	_bytestream2_get_bytes_left
	cmp	w0, w28
	b.lt	LBB0_16
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=2
	ldr	x0, [sp, #40]
	ldr	w4, [x25]
	ldr	w5, [x22]
	str	x19, [sp]
	mov	x1, x28
	mov	x2, x24
	mov	x3, x23
	mov	x6, x21
	mov	x7, x20
	bl	_hevc_decode_nal_units
	mov	x26, x0
	tbnz	w0, #31, LBB0_15
; %bb.12:                               ;   in Loop: Header=BB0_10 Depth=2
	add	x0, sp, #40
	mov	x1, x28
	bl	_bytestream2_skip
	subs	w27, w27, #1
	b.ne	LBB0_10
	b	LBB0_7
LBB0_13:
	mov	w26, #0
LBB0_14:
	ldr	w8, [sp, #16]                   ; 4-byte Folded Reload
	and	w8, w8, #0x3
	add	w8, w8, #1
	str	w8, [x22]
	b	LBB0_18
LBB0_15:
	ldr	w8, [sp, #24]                   ; 4-byte Folded Reload
	and	w8, w8, #0x3f
Lloh0:
	adrp	x9, _AV_LOG_ERROR@GOTPAGE
Lloh1:
	ldr	x9, [x9, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x9]
	ldr	x9, [sp, #32]                   ; 8-byte Folded Reload
	stp	x8, x9, [sp]
Lloh3:
	adrp	x2, l_.str.1@PAGE
Lloh4:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_av_log
	ldr	w8, [sp, #20]                   ; 4-byte Folded Reload
	b	LBB0_18
LBB0_16:
Lloh5:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh6:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
Lloh8:
	adrp	x2, l_.str@PAGE
Lloh9:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_av_log
	ldr	w8, [sp, #20]                   ; 4-byte Folded Reload
	tbz	w8, #0, LBB0_18
; %bb.17:
Lloh10:
	adrp	x8, _AVERROR_INVALIDDATA@GOTPAGE
Lloh11:
	ldr	x8, [x8, _AVERROR_INVALIDDATA@GOTPAGEOFF]
Lloh12:
	ldr	w26, [x8]
LBB0_18:
	mov	x0, x26
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Invalid NAL unit size in extradata.\n"

	.comm	_AVERROR_INVALIDDATA,4,2        ; @AVERROR_INVALIDDATA
l_.str.1:                               ; @.str.1
	.asciz	"Decoding nal unit %d %d from hvcC failed\n"

.subsections_via_symbols
