	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function decode_residues
_decode_residues:                       ## @decode_residues
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	cmpl	%edx, (%rdi)
	jl	LBB0_1
## %bb.2:
	movl	%edx, %ebx
	movq	%rsi, %r14
	leaq	16(%rdi), %r12
	movq	%rdi, %r15
	movq	%r12, %rdi
	callq	_get_bits1
	testl	%eax, %eax
	je	LBB0_22
## %bb.3:
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	movl	4(%r15), %ecx
	movl	%ebx, %eax
	cltd
	idivl	%ecx
	movl	%eax, %ebx
	movl	%ecx, %esi
	shrl	$31, %esi
	addl	%ecx, %esi
	sarl	%esi
	xorl	%edi, %edi
	xorl	%eax, %eax
	cmpl	%esi, %edx
	setge	%al
	cmovll	%ecx, %edi
	leal	(%rbx,%rax), %ecx
	addl	$-129, %ecx
	cmpl	$-128, %ecx
	ja	LBB0_4
LBB0_1:
	movq	_AVERROR_INVALIDDATA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_24
LBB0_22:
	movq	%r12, %rdi
	movl	$6, %esi
	callq	_get_bits
	movq	%r15, %rdi
	movl	%eax, %esi
	movq	%r14, %rdx
	movl	%ebx, %ecx
	callq	_decode_segment
	testl	%eax, %eax
	js	LBB0_24
LBB0_23:
	xorl	%eax, %eax
LBB0_24:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movq	%r14, -80(%rbp)                 ## 8-byte Spill
	addl	%eax, %ebx
	addl	%edx, %edi
	movl	%edi, -68(%rbp)                 ## 4-byte Spill
	movq	%r15, -48(%rbp)                 ## 8-byte Spill
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movl	$6, %esi
	callq	_get_bits
	movq	%rbx, %rcx
	movl	%eax, %ebx
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	8(%rax), %rax
	movl	%ebx, (%rax)
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	movl	%ecx, %r13d
	movl	$1, %r14d
	leaq	LJTI0_0(%rip), %r12
	jmp	LBB0_5
LBB0_10:                                ##   in Loop: Header=BB0_5 Depth=1
	decl	%ebx
LBB0_11:                                ##   in Loop: Header=BB0_5 Depth=1
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	movq	-56(%rbp), %r15                 ## 8-byte Reload
LBB0_12:                                ##   in Loop: Header=BB0_5 Depth=1
	movq	8(%r8), %rax
	movl	%ebx, (%rax,%r14,4)
	incq	%r14
	cmpq	%r14, %r13
	je	LBB0_13
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r15, %rdi
	movl	$1, %esi
	movl	$6, %edx
	callq	_get_unary
	movl	%eax, %r15d
	decl	%r15d
	cmpl	$5, %r15d
	ja	LBB0_11
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movslq	(%r12,%r15,4), %rax
	addq	%r12, %rax
	jmpq	*%rax
LBB0_8:                                 ##   in Loop: Header=BB0_5 Depth=1
	movq	%r13, %r12
	movq	-56(%rbp), %r13                 ## 8-byte Reload
	movq	%r13, %rdi
	callq	_get_bits1
	addl	%eax, %ebx
	negl	%eax
	xorl	%eax, %r15d
	addl	%r15d, %ebx
	movq	%r13, %r15
	movq	%r12, %r13
	leaq	LJTI0_0(%rip), %r12
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	jmp	LBB0_12
LBB0_9:                                 ##   in Loop: Header=BB0_5 Depth=1
	incl	%ebx
	jmp	LBB0_11
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movl	$6, %esi
	callq	_get_bits
	movl	%eax, %ebx
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	jmp	LBB0_12
LBB0_13:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	leal	-1(%rax), %r14d
	movslq	%r14d, %r15
	xorl	%r13d, %r13d
	jmp	LBB0_14
	.p2align	4, 0x90
LBB0_19:                                ##   in Loop: Header=BB0_14 Depth=1
	movq	-64(%rbp), %r13                 ## 8-byte Reload
                                        ## kill: def $r13d killed $r13d killed $r13 def $r13
LBB0_21:                                ##   in Loop: Header=BB0_14 Depth=1
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	-80(%rbp), %r12                 ## 8-byte Reload
	movq	%r12, %rdx
	movl	%ebx, %ecx
	callq	_decode_segment
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	movslq	%ebx, %rcx
	leaq	(%r12,%rcx,4), %r12
	movq	%r12, -80(%rbp)                 ## 8-byte Spill
	testl	%eax, %eax
	js	LBB0_24
LBB0_14:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_16 Depth 2
	cmpl	-64(%rbp), %r13d                ## 4-byte Folded Reload
	jge	LBB0_23
## %bb.15:                              ##   in Loop: Header=BB0_14 Depth=1
	movq	8(%r8), %rax
	movslq	%r13d, %rcx
	movl	(%rax,%rcx,4), %esi
	xorl	%ebx, %ebx
	movl	-68(%rbp), %edi                 ## 4-byte Reload
	.p2align	4, 0x90
LBB0_16:                                ##   Parent Loop BB0_14 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	%edi, %edx
	cmpq	%r15, %rcx
	jge	LBB0_18
## %bb.17:                              ##   in Loop: Header=BB0_16 Depth=2
	movl	4(%r8), %edx
LBB0_18:                                ##   in Loop: Header=BB0_16 Depth=2
	addl	%edx, %ebx
	cmpl	%ecx, %r14d
	je	LBB0_19
## %bb.20:                              ##   in Loop: Header=BB0_16 Depth=2
	leaq	1(%rcx), %r13
	cmpl	%esi, 4(%rax,%rcx,4)
	movq	%r13, %rcx
	je	LBB0_16
	jmp	LBB0_21
	.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_8, LBB0_8-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
LJTI0_0:
	.long	L0_0_set_10
	.long	L0_0_set_9
	.long	L0_0_set_8
	.long	L0_0_set_8
	.long	L0_0_set_8
	.long	L0_0_set_7
	.end_data_region
                                        ## -- End function
	.comm	_AVERROR_INVALIDDATA,4,2        ## @AVERROR_INVALIDDATA
	.no_dead_strip	_decode_residues
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function decode_residues
_decode_residues:                       ; @decode_residues
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x21, x0
	ldr	w8, [x21], #16
	cmp	w8, w2
	b.lt	LBB0_3
; %bb.1:
	mov	x22, x2
	mov	x19, x1
	mov	x20, x0
	mov	x0, x21
	bl	_get_bits1
	cbz	w0, LBB0_4
; %bb.2:
	ldr	w9, [x20, #4]
	sdiv	w10, w22, w9
	msub	w8, w10, w9, w22
	cmp	w9, #0
	cinc	w11, w9, lt
	cmp	w8, w11, asr #1
	cinc	w23, w10, ge
	csel	w9, w9, wzr, lt
	sub	w10, w23, #129
	cmn	w10, #128
	b.hi	LBB0_7
LBB0_3:
Lloh0:
	adrp	x8, _AVERROR_INVALIDDATA@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AVERROR_INVALIDDATA@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	b	LBB0_6
LBB0_4:
	mov	x0, x21
	mov	w1, #6
	bl	_get_bits
	mov	x1, x0
	mov	x0, x20
	mov	x2, x19
	mov	x3, x22
	bl	_decode_segment
	tbnz	w0, #31, LBB0_6
LBB0_5:
	mov	w0, #0
LBB0_6:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_7:
	add	w24, w9, w8
	mov	x0, x21
	mov	w1, #6
	bl	_get_bits
	mov	x22, x0
	ldr	x8, [x20, #8]
	str	w0, [x8]
	mov	w25, #1
Lloh3:
	adrp	x26, lJTI0_0@PAGE
Lloh4:
	add	x26, x26, lJTI0_0@PAGEOFF
	b	LBB0_10
LBB0_8:                                 ;   in Loop: Header=BB0_10 Depth=1
	sub	w22, w22, #1
LBB0_9:                                 ;   in Loop: Header=BB0_10 Depth=1
	ldr	x8, [x20, #8]
	str	w22, [x8, x25, lsl #2]
	add	x25, x25, #1
	cmp	x23, x25
	b.eq	LBB0_15
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	mov	w1, #1
	mov	w2, #6
	bl	_get_unary
	sub	w27, w0, #1
	cmp	w27, #5
	b.hi	LBB0_9
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=1
	adr	x8, LBB0_8
	ldrb	w9, [x26, x27]
	add	x8, x8, x9, lsl #2
	br	x8
LBB0_12:                                ;   in Loop: Header=BB0_10 Depth=1
	mov	x0, x21
	bl	_get_bits1
	neg	w8, w0
	eor	w8, w27, w8
	add	w9, w0, w22
	add	w22, w9, w8
	b	LBB0_9
LBB0_13:                                ;   in Loop: Header=BB0_10 Depth=1
	add	w22, w22, #1
	b	LBB0_9
LBB0_14:                                ;   in Loop: Header=BB0_10 Depth=1
	mov	x0, x21
	mov	w1, #6
	bl	_get_bits
	mov	x22, x0
	b	LBB0_9
LBB0_15:
	mov	w25, #0
	sub	w8, w23, #1
	sxtw	x22, w8
	b	LBB0_18
LBB0_16:                                ;   in Loop: Header=BB0_18 Depth=1
	mov	x25, x23
LBB0_17:                                ;   in Loop: Header=BB0_18 Depth=1
	mov	x0, x20
	mov	x2, x19
	mov	x3, x21
	bl	_decode_segment
	add	x19, x19, w21, sxtw #2
	tbnz	w0, #31, LBB0_6
LBB0_18:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_20 Depth 2
	cmp	w25, w23
	b.ge	LBB0_5
; %bb.19:                               ;   in Loop: Header=BB0_18 Depth=1
	mov	w21, #0
	ldr	x9, [x20, #8]
	sxtw	x8, w25
	ldr	w1, [x9, w25, sxtw #2]
	add	x9, x9, #4
LBB0_20:                                ;   Parent Loop BB0_18 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	mov	x10, x24
	cmp	x8, x22
	b.ge	LBB0_22
; %bb.21:                               ;   in Loop: Header=BB0_20 Depth=2
	ldr	w10, [x20, #4]
LBB0_22:                                ;   in Loop: Header=BB0_20 Depth=2
	add	w21, w10, w21
	cmp	w22, w8
	b.eq	LBB0_16
; %bb.23:                               ;   in Loop: Header=BB0_20 Depth=2
	ldr	w10, [x9, x8, lsl #2]
	add	x8, x8, #1
	cmp	w10, w1
	b.eq	LBB0_20
; %bb.24:                               ;   in Loop: Header=BB0_18 Depth=1
	mov	x25, x8
	b	LBB0_17
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_8-LBB0_8)>>2
	.byte	(LBB0_13-LBB0_8)>>2
	.byte	(LBB0_12-LBB0_8)>>2
	.byte	(LBB0_12-LBB0_8)>>2
	.byte	(LBB0_12-LBB0_8)>>2
	.byte	(LBB0_14-LBB0_8)>>2
                                        ; -- End function
	.comm	_AVERROR_INVALIDDATA,4,2        ; @AVERROR_INVALIDDATA
	.no_dead_strip	_decode_residues
.subsections_via_symbols
