	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function compute_bit_allocation
_compute_bit_allocation:                ## @compute_bit_allocation
	.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	$120, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, -112(%rbp)                ## 8-byte Spill
	movq	%rdx, -96(%rbp)                 ## 8-byte Spill
	movq	%rsi, -88(%rbp)                 ## 8-byte Spill
	movq	%rdi, %r13
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_MPA_MAX_CHANNELS@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	_SBLIMIT@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	imulq	%r12, %r15
	leaq	(%r15,%r15), %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r14
	movq	%r15, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %rbx
	movl	(%r13), %edx
	movq	%r12, -72(%rbp)                 ## 8-byte Spill
	imull	%r12d, %edx
	addl	%edx, %edx
	movq	%r14, -80(%rbp)                 ## 8-byte Spill
	movq	%r14, %rdi
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
	callq	_memcpy
	movq	_SB_NOTALLOCATED@GOTPCREL(%rip), %rax
	movzbl	(%rax), %esi
	movq	_SBLIMIT@GOTPCREL(%rip), %r14
	movl	(%r14), %edx
	imull	(%r13), %edx
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	callq	_memset
	movl	(%r14), %edx
	imull	(%r13), %edx
	xorl	%r15d, %r15d
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	xorl	%esi, %esi
	callq	_memset
	movq	%r13, %r10
	movl	4(%r13), %edi
	movl	8(%r13), %eax
	addl	48(%r13), %eax
	movl	%eax, 8(%r13)
	cmpl	$65536, %eax                    ## imm = 0x10000
	jl	LBB0_2
## %bb.1:
	addl	$-65536, %eax                   ## imm = 0xFFFF0000
	movl	%eax, 8(%r10)
	addl	$8, %edi
	movl	$1, %r15d
LBB0_2:
	movl	%r15d, 12(%r10)
	movl	24(%r10), %r15d
	testl	%r15d, %r15d
	movq	-72(%rbp), %r14                 ## 8-byte Reload
	jle	LBB0_3
## %bb.4:
	movq	16(%r10), %rsi
	movl	(%r10), %r8d
	leal	-1(%r15), %ecx
	movl	%r15d, %r9d
	andl	$3, %r9d
	cmpl	$3, %ecx
	jae	LBB0_23
## %bb.5:
	movl	$32, %r11d
	jmp	LBB0_6
LBB0_3:
	movl	$32, %r11d
	jmp	LBB0_8
LBB0_23:
	andl	$-4, %r15d
	movl	$32, %r11d
	.p2align	4, 0x90
LBB0_24:                                ## =>This Inner Loop Header: Depth=1
	movzbl	(%rsi), %ecx
	movl	%ecx, %ebx
	movl	$1, %eax
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %eax
	imull	%r8d, %ebx
	addl	%r11d, %ebx
	cltq
	leaq	(%rsi,%rax), %rdx
	movzbl	(%rsi,%rax), %ecx
	movl	%ecx, %eax
	imull	%r8d, %eax
	addl	%ebx, %eax
	movl	$1, %esi
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %esi
	movslq	%esi, %rcx
	leaq	(%rdx,%rcx), %rsi
	movzbl	(%rcx,%rdx), %ecx
	movl	%ecx, %edx
	imull	%r8d, %edx
	addl	%eax, %edx
	movl	$1, %eax
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %eax
	cltq
	leaq	(%rsi,%rax), %rbx
	movzbl	(%rax,%rsi), %ecx
	movl	%ecx, %r11d
	imull	%r8d, %r11d
	movl	$1, %eax
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %eax
	addl	%edx, %r11d
	movslq	%eax, %rsi
	addq	%rbx, %rsi
	addl	$-4, %r15d
	jne	LBB0_24
LBB0_6:
	testl	%r9d, %r9d
	je	LBB0_8
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movzbl	(%rsi), %ecx
	movl	%ecx, %eax
	imull	%r8d, %eax
	movl	$1, %ebx
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %ebx
	addl	%eax, %r11d
	movslq	%ebx, %rcx
	addq	%rcx, %rsi
	decl	%r9d
	jne	LBB0_7
LBB0_8:
	movl	(%r10), %ecx
	testl	%ecx, %ecx
	jle	LBB0_46
## %bb.9:
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	addq	$2, %rax
	movq	%rax, -136(%rbp)                ## 8-byte Spill
	leaq	(%r14,%r14), %r13
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	incq	%rax
	movq	%rax, -128(%rbp)                ## 8-byte Spill
	movq	_SB_NOMORE@GOTPCREL(%rip), %r15
	movq	%r10, -120(%rbp)                ## 8-byte Spill
	movl	%edi, -56(%rbp)                 ## 4-byte Spill
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_44:                                ##   in Loop: Header=BB0_10 Depth=1
	movl	%esi, %r11d
LBB0_45:                                ##   in Loop: Header=BB0_10 Depth=1
	movb	(%rcx), %al
	movb	%al, (%r8,%r12)
	movl	(%r10), %ecx
	testl	%ecx, %ecx
	jle	LBB0_46
LBB0_10:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_11 Depth 2
                                        ##       Child Loop BB0_13 Depth 3
                                        ##     Child Loop BB0_35 Depth 2
                                        ##     Child Loop BB0_37 Depth 2
	movl	%r11d, -52(%rbp)                ## 4-byte Spill
	movq	_INT_MIN@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movl	24(%r10), %r9d
	movb	(%r15), %r11b
	movl	%ecx, %r8d
	movl	%r9d, %esi
	andl	$-2, %esi
	movq	-128(%rbp), %rdi                ## 8-byte Reload
	movq	-136(%rbp), %rbx                ## 8-byte Reload
	xorl	%edx, %edx
	movl	$-1, %r10d
	movl	$-1, %r15d
	jmp	LBB0_11
LBB0_22:                                ##   in Loop: Header=BB0_11 Depth=2
	movq	-72(%rbp), %r14                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_27:                                ##   in Loop: Header=BB0_11 Depth=2
	incq	%rdx
	addq	%r13, %rbx
	addq	%r14, %rdi
	cmpq	%r8, %rdx
	je	LBB0_28
LBB0_11:                                ##   Parent Loop BB0_10 Depth=1
                                        ## =>  This Loop Header: Depth=2
                                        ##       Child Loop BB0_13 Depth 3
	testl	%r9d, %r9d
	jle	LBB0_27
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=2
	xorl	%ecx, %ecx
	cmpl	$1, %r9d
	jne	LBB0_13
LBB0_20:                                ##   in Loop: Header=BB0_11 Depth=2
	testb	$1, %r9b
	je	LBB0_27
## %bb.21:                              ##   in Loop: Header=BB0_11 Depth=2
	movq	%r14, %rax
	movq	%rdx, %r14
	imulq	%rax, %r14
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	leaq	(%rax,%r14,2), %rax
	movswl	(%rax,%rcx,2), %eax
	cmpl	%eax, %r12d
	jge	LBB0_22
## %bb.25:                              ##   in Loop: Header=BB0_11 Depth=2
	addq	-64(%rbp), %r14                 ## 8-byte Folded Reload
	cmpb	%r11b, (%r14,%rcx)
	movq	-72(%rbp), %r14                 ## 8-byte Reload
	je	LBB0_27
## %bb.26:                              ##   in Loop: Header=BB0_11 Depth=2
	movl	%ecx, %r15d
	movl	%edx, %r10d
	movl	%eax, %r12d
	jmp	LBB0_27
	.p2align	4, 0x90
LBB0_19:                                ##   in Loop: Header=BB0_13 Depth=3
	addq	$2, %rcx
	cmpq	%rcx, %rsi
	je	LBB0_20
LBB0_13:                                ##   Parent Loop BB0_10 Depth=1
                                        ##     Parent Loop BB0_11 Depth=2
                                        ## =>    This Inner Loop Header: Depth=3
	movswl	-2(%rbx,%rcx,2), %eax
	cmpl	%eax, %r12d
	jge	LBB0_16
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=3
	cmpb	%r11b, -1(%rdi,%rcx)
	je	LBB0_16
## %bb.15:                              ##   in Loop: Header=BB0_13 Depth=3
	movl	%ecx, %r15d
	movl	%edx, %r10d
	movl	%eax, %r12d
LBB0_16:                                ##   in Loop: Header=BB0_13 Depth=3
	movswl	(%rbx,%rcx,2), %eax
	cmpl	%eax, %r12d
	jge	LBB0_19
## %bb.17:                              ##   in Loop: Header=BB0_13 Depth=3
	cmpb	%r11b, (%rdi,%rcx)
	je	LBB0_19
## %bb.18:                              ##   in Loop: Header=BB0_13 Depth=3
	leal	1(%rcx), %r15d
	movl	%edx, %r10d
	movl	%eax, %r12d
	jmp	LBB0_19
	.p2align	4, 0x90
LBB0_28:                                ##   in Loop: Header=BB0_10 Depth=1
	testl	%r15d, %r15d
	js	LBB0_29
## %bb.30:                              ##   in Loop: Header=BB0_10 Depth=1
	movslq	%r10d, %r9
	movq	%r9, %r12
	imulq	%r14, %r12
	movq	-96(%rbp), %rax                 ## 8-byte Reload
	addq	%r12, %rax
	movl	%r15d, %ecx
	movq	%rax, -104(%rbp)                ## 8-byte Spill
	movq	%rcx, -152(%rbp)                ## 8-byte Spill
	movzbl	(%rcx,%rax), %eax
	subq	$8, %rsp
	xorl	%edi, %edi
	leaq	L_.str(%rip), %rsi
	movl	-52(%rbp), %edx                 ## 4-byte Reload
	movl	-56(%rbp), %ecx                 ## 4-byte Reload
	movl	%r15d, %r8d
	movq	%r9, %rbx
	movq	%r9, -144(%rbp)                 ## 8-byte Spill
                                        ## kill: def $r9d killed $r9d killed $r9
	pushq	%rax
	callq	_ff_dlog
	addq	$16, %rsp
	movq	-120(%rbp), %r10                ## 8-byte Reload
	movq	16(%r10), %rax
	testl	%r15d, %r15d
	je	LBB0_31
## %bb.32:                              ##   in Loop: Header=BB0_10 Depth=1
	leal	-1(%r15), %ecx
	movl	%r15d, %edx
	andl	$3, %edx
	cmpl	$3, %ecx
	jae	LBB0_34
## %bb.33:                              ##   in Loop: Header=BB0_10 Depth=1
	movl	-52(%rbp), %r11d                ## 4-byte Reload
	jmp	LBB0_36
	.p2align	4, 0x90
LBB0_31:                                ##   in Loop: Header=BB0_10 Depth=1
	movl	-52(%rbp), %r11d                ## 4-byte Reload
	jmp	LBB0_38
	.p2align	4, 0x90
LBB0_34:                                ##   in Loop: Header=BB0_10 Depth=1
	andl	$-4, %r15d
	movl	-52(%rbp), %r11d                ## 4-byte Reload
	.p2align	4, 0x90
LBB0_35:                                ##   Parent Loop BB0_10 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movzbl	(%rax), %ecx
	movl	$1, %esi
	shll	%cl, %esi
	movslq	%esi, %rsi
	movzbl	(%rax,%rsi), %ecx
	movl	$1, %edi
	shll	%cl, %edi
	addq	%rsi, %rax
	movslq	%edi, %rsi
	movzbl	(%rsi,%rax), %ecx
	movl	$1, %edi
	shll	%cl, %edi
	addq	%rsi, %rax
	movslq	%edi, %rsi
	movzbl	(%rsi,%rax), %ecx
	movl	$1, %edi
	shll	%cl, %edi
	leaq	(%rax,%rsi), %rcx
	movslq	%edi, %rax
	addq	%rcx, %rax
	addl	$-4, %r15d
	jne	LBB0_35
LBB0_36:                                ##   in Loop: Header=BB0_10 Depth=1
	testl	%edx, %edx
	je	LBB0_38
	.p2align	4, 0x90
LBB0_37:                                ##   Parent Loop BB0_10 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movzbl	(%rax), %ecx
	movl	$1, %esi
	shll	%cl, %esi
	movslq	%esi, %rcx
	addq	%rcx, %rax
	decl	%edx
	jne	LBB0_37
LBB0_38:                                ##   in Loop: Header=BB0_10 Depth=1
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movq	%r12, %r9
	leaq	(%rcx,%r12), %r8
	movq	-152(%rbp), %r12                ## 8-byte Reload
	movb	(%r12,%r8), %cl
	movq	_SB_NOTALLOCATED@GOTPCREL(%rip), %rdx
	cmpb	(%rdx), %cl
	movq	_SB_NOMORE@GOTPCREL(%rip), %r15
	movl	-56(%rbp), %edi                 ## 4-byte Reload
	jne	LBB0_40
## %bb.39:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	_nb_scale_factors@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	32(%r10), %rsi
	movq	40(%r10), %rdx
	movq	-144(%rbp), %rbx                ## 8-byte Reload
	movq	(%rsi,%rbx,8), %rsi
	movq	(%rsi,%r12,8), %rsi
	movl	(%rcx,%rsi,4), %ecx
	leal	(%rcx,%rcx,2), %ecx
	movzbl	1(%rax), %esi
	movl	(%rdx,%rsi,4), %esi
	leal	(%rsi,%rcx,2), %esi
	addl	$2, %esi
	jmp	LBB0_41
	.p2align	4, 0x90
LBB0_40:                                ##   in Loop: Header=BB0_10 Depth=1
	movq	-104(%rbp), %rcx                ## 8-byte Reload
	movzbl	(%rcx,%r12), %ecx
	movq	40(%r10), %rdx
	movzbl	1(%rax,%rcx), %esi
	movl	(%rdx,%rsi,4), %esi
	movzbl	(%rax,%rcx), %ecx
	subl	(%rdx,%rcx,4), %esi
LBB0_41:                                ##   in Loop: Header=BB0_10 Depth=1
	addl	%r11d, %esi
	movq	%r15, %rcx
	cmpl	%edi, %esi
	jg	LBB0_45
## %bb.42:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	-104(%rbp), %rdx                ## 8-byte Reload
	movb	(%rdx,%r12), %cl
	incb	%cl
	movb	%cl, (%rdx,%r12)
	movzbl	%cl, %r11d
	movq	-88(%rbp), %rcx                 ## 8-byte Reload
	movq	%r9, %rbx
	leaq	(%rcx,%r9,2), %rcx
	movzwl	(%rcx,%r12,2), %ecx
	movq	_quant_snr@GOTPCREL(%rip), %rdx
	movq	(%rdx), %r9
	movzbl	(%rax,%r11), %edx
	subw	(%r9,%rdx,2), %cx
	movq	-80(%rbp), %rdx                 ## 8-byte Reload
	leaq	(%rdx,%rbx,2), %rdx
	movw	%cx, (%rdx,%r12,2)
	movb	(%rax), %cl
	movl	$-1, %eax
	shll	%cl, %eax
	notl	%eax
	movq	_SB_ALLOCATED@GOTPCREL(%rip), %rcx
	cmpl	%eax, %r11d
	jne	LBB0_44
## %bb.43:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	%r15, %rcx
	jmp	LBB0_44
LBB0_29:
	movl	-56(%rbp), %edi                 ## 4-byte Reload
	movl	-52(%rbp), %r11d                ## 4-byte Reload
LBB0_46:
	subl	%r11d, %edi
	movq	-112(%rbp), %rax                ## 8-byte Reload
	movl	%edi, (%rax)
	notl	%edi
	shrl	$31, %edi
	callq	_av_assert0
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_48
## %bb.47:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_48:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MPA_MAX_CHANNELS,4,2           ## @MPA_MAX_CHANNELS
	.comm	_SBLIMIT,4,2                    ## @SBLIMIT
	.comm	_SB_NOTALLOCATED,1,0            ## @SB_NOTALLOCATED
	.comm	_INT_MIN,4,2                    ## @INT_MIN
	.comm	_SB_NOMORE,1,0                  ## @SB_NOMORE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"current=%d max=%d max_sb=%d max_ch=%d alloc=%d\n"

	.comm	_nb_scale_factors,8,3           ## @nb_scale_factors
	.comm	_quant_snr,8,3                  ## @quant_snr
	.comm	_SB_ALLOCATED,1,0               ## @SB_ALLOCATED
	.no_dead_strip	_compute_bit_allocation
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function compute_bit_allocation
_compute_bit_allocation:                ; @compute_bit_allocation
	.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
	sub	sp, sp, #64
	stur	x3, [x29, #-136]                ; 8-byte Folded Spill
	mov	x21, x2
	mov	x22, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _MPA_MAX_CHANNELS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MPA_MAX_CHANNELS@GOTPAGEOFF]
Lloh5:
	adrp	x20, _SBLIMIT@GOTPAGE
Lloh6:
	ldr	x20, [x20, _SBLIMIT@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	ldr	w19, [x20]
	mul	x8, x19, x8
	lsl	x9, x8, #1
	add	x10, x9, #15
	and	x12, x10, #0xfffffffffffffff0
Lloh8:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh9:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	sub	x0, x9, x12
	mov	sp, x0
	add	x9, x8, #15
	and	x12, x9, #0xfffffffffffffff0
	mov	x9, x8
Lloh10:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh11:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	sub	x28, x8, x12
	mov	sp, x28
	ldr	w8, [x22]
	mul	w8, w19, w8
	lsl	w2, w8, #1
	stur	x0, [x29, #-104]                ; 8-byte Folded Spill
	stur	x1, [x29, #-128]                ; 8-byte Folded Spill
	bl	_memcpy
Lloh12:
	adrp	x8, _SB_NOTALLOCATED@GOTPAGE
Lloh13:
	ldr	x8, [x8, _SB_NOTALLOCATED@GOTPAGEOFF]
	ldrb	w1, [x8]
	ldr	w8, [x22]
	ldr	w9, [x20]
	mul	w2, w9, w8
	mov	x0, x28
	bl	_memset
	ldr	w8, [x22]
	ldr	w9, [x20]
	mul	w2, w9, w8
	stur	x21, [x29, #-112]               ; 8-byte Folded Spill
	mov	x0, x21
	mov	w1, #0
	bl	_memset
	mov	x21, x22
	ldr	w8, [x22, #48]
	ldp	w3, w9, [x22, #4]
	add	w8, w9, w8
	str	w8, [x22, #8]
	subs	w8, w8, #16, lsl #12            ; =65536
	b.lt	LBB0_2
; %bb.1:
	str	w8, [x21, #8]
	add	w3, w3, #8
	mov	w8, #1
	b	LBB0_3
LBB0_2:
	mov	w8, #0
LBB0_3:
	str	w8, [x21, #12]
	ldr	w8, [x21, #24]
	cmp	w8, #1
	b.lt	LBB0_6
; %bb.4:
	ldr	x9, [x21, #16]
	ldr	w10, [x21]
	mov	w26, #32
	mov	w11, #1
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldrb	w12, [x9]
	madd	w26, w10, w12, w26
	lsl	w12, w11, w12
	add	x9, x9, w12, sxtw
	subs	w8, w8, #1
	b.ne	LBB0_5
	b	LBB0_7
LBB0_6:
	mov	w26, #32
LBB0_7:
	ldr	w14, [x21]
	cmp	w14, #1
	b.lt	LBB0_25
; %bb.8:
Lloh14:
	adrp	x17, _SB_NOMORE@GOTPAGE
Lloh15:
	ldr	x17, [x17, _SB_NOMORE@GOTPAGEOFF]
	lsl	x27, x19, #1
	mov	w20, #1
	stur	x28, [x29, #-120]               ; 8-byte Folded Spill
	b	LBB0_10
LBB0_9:                                 ;   in Loop: Header=BB0_10 Depth=1
	ldrb	w8, [x11]
	strb	w8, [x9, x23]
	ldr	w14, [x21]
	cmp	w14, #0
	b.le	LBB0_25
LBB0_10:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_12 Depth 2
                                        ;       Child Loop BB0_15 Depth 3
                                        ;     Child Loop BB0_19 Depth 2
	mov	x8, #0
Lloh16:
	adrp	x9, _INT_MIN@GOTPAGE
Lloh17:
	ldr	x9, [x9, _INT_MIN@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	ldr	w10, [x21, #24]
	mov	w5, #-1
	ldur	x11, [x29, #-104]               ; 8-byte Folded Reload
	mov	x12, x28
	mov	w28, #-1
	ldrb	w13, [x17]
	mov	w14, w14
	b	LBB0_12
LBB0_11:                                ;   in Loop: Header=BB0_12 Depth=2
	add	x8, x8, #1
	add	x12, x12, x19
	add	x11, x11, x27
	cmp	x8, x14
	b.eq	LBB0_17
LBB0_12:                                ;   Parent Loop BB0_10 Depth=1
                                        ; =>  This Loop Header: Depth=2
                                        ;       Child Loop BB0_15 Depth 3
	cmp	w10, #1
	b.lt	LBB0_11
; %bb.13:                               ;   in Loop: Header=BB0_12 Depth=2
	mov	x15, #0
	b	LBB0_15
LBB0_14:                                ;   in Loop: Header=BB0_15 Depth=3
	add	x15, x15, #1
	cmp	x10, x15
	b.eq	LBB0_11
LBB0_15:                                ;   Parent Loop BB0_10 Depth=1
                                        ;     Parent Loop BB0_12 Depth=2
                                        ; =>    This Inner Loop Header: Depth=3
	ldrsh	w16, [x11, x15, lsl #1]
	cmp	w9, w16
	b.ge	LBB0_14
; %bb.16:                               ;   in Loop: Header=BB0_15 Depth=3
	ldrb	w17, [x12, x15]
	cmp	w17, w13
	csel	w28, w28, w15, eq
	csel	w5, w5, w8, eq
	csel	w9, w9, w16, eq
	b	LBB0_14
LBB0_17:                                ;   in Loop: Header=BB0_10 Depth=1
	tbnz	w28, #31, LBB0_25
; %bb.18:                               ;   in Loop: Header=BB0_10 Depth=1
	sxtw	x25, w5
	mul	x9, x25, x19
	ldur	x8, [x29, #-112]                ; 8-byte Folded Reload
	stur	x9, [x29, #-96]                 ; 8-byte Folded Spill
	add	x24, x8, x9
	mov	w23, w28
	ldrb	w6, [x24, x23]
	mov	x0, #0
Lloh19:
	adrp	x1, l_.str@PAGE
Lloh20:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x26
	mov	x22, x3
	mov	x4, x28
                                        ; kill: def $w5 killed $w5 killed $x5
	bl	_ff_dlog
	ldr	x8, [x21, #16]
	cbz	w28, LBB0_20
LBB0_19:                                ;   Parent Loop BB0_10 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldrb	w9, [x8]
	lsl	w9, w20, w9
	add	x8, x8, w9, sxtw
	subs	w28, w28, #1
	b.ne	LBB0_19
LBB0_20:                                ;   in Loop: Header=BB0_10 Depth=1
	ldur	x28, [x29, #-120]               ; 8-byte Folded Reload
	ldur	x13, [x29, #-96]                ; 8-byte Folded Reload
	add	x9, x28, x13
	ldrb	w10, [x9, x23]
Lloh21:
	adrp	x11, _SB_NOTALLOCATED@GOTPAGE
Lloh22:
	ldr	x11, [x11, _SB_NOTALLOCATED@GOTPAGEOFF]
	ldrb	w11, [x11]
	cmp	w10, w11
	mov	x3, x22
Lloh23:
	adrp	x17, _SB_NOMORE@GOTPAGE
Lloh24:
	ldr	x17, [x17, _SB_NOMORE@GOTPAGEOFF]
	b.ne	LBB0_22
; %bb.21:                               ;   in Loop: Header=BB0_10 Depth=1
Lloh25:
	adrp	x10, _nb_scale_factors@GOTPAGE
Lloh26:
	ldr	x10, [x10, _nb_scale_factors@GOTPAGEOFF]
Lloh27:
	ldr	x10, [x10]
	ldp	x11, x12, [x21, #32]
	ldr	x11, [x11, x25, lsl #3]
	ldr	x11, [x11, x23, lsl #3]
	ldr	w10, [x10, x11, lsl #2]
	ldrb	w11, [x8, #1]
	ldr	w11, [x12, x11, lsl #2]
	mov	w12, #6
	madd	w10, w10, w12, w11
	add	w10, w10, #2
	b	LBB0_23
LBB0_22:                                ;   in Loop: Header=BB0_10 Depth=1
	ldrb	w10, [x24, x23]
	ldr	x11, [x21, #40]
	add	x10, x8, x10
	ldrb	w12, [x10, #1]
	ldr	w12, [x11, x12, lsl #2]
	ldrb	w10, [x10]
	ldr	w10, [x11, x10, lsl #2]
	sub	w10, w12, w10
LBB0_23:                                ;   in Loop: Header=BB0_10 Depth=1
	add	w10, w10, w26
	cmp	w10, w3
	mov	x11, x17
	b.gt	LBB0_9
; %bb.24:                               ;   in Loop: Header=BB0_10 Depth=1
	ldrb	w11, [x24, x23]
	add	w11, w11, #1
	strb	w11, [x24, x23]
	lsl	x12, x13, #1
	ldur	x13, [x29, #-128]               ; 8-byte Folded Reload
	add	x13, x13, x12
	lsl	x14, x23, #1
	ldrh	w13, [x13, x14]
Lloh28:
	adrp	x15, _quant_snr@GOTPAGE
Lloh29:
	ldr	x15, [x15, _quant_snr@GOTPAGEOFF]
Lloh30:
	ldr	x15, [x15]
	and	x16, x11, #0xff
	ldrb	w16, [x8, x16]
	ldrh	w15, [x15, x16, lsl #1]
	sub	w13, w13, w15
	ldur	x15, [x29, #-104]               ; 8-byte Folded Reload
	add	x12, x15, x12
	strh	w13, [x12, x14]
	ldrb	w8, [x8]
	mov	w12, #-1
	lsl	w8, w12, w8
	mvn	w8, w8
	cmp	w8, w11, uxtb
Lloh31:
	adrp	x8, _SB_ALLOCATED@GOTPAGE
Lloh32:
	ldr	x8, [x8, _SB_ALLOCATED@GOTPAGEOFF]
	csel	x11, x17, x8, eq
	mov	x26, x10
	b	LBB0_9
LBB0_25:
	sub	w8, w3, w26
	mvn	w9, w8
	ldur	x10, [x29, #-136]               ; 8-byte Folded Reload
	str	w8, [x10]
	lsr	w0, w9, #31
	bl	_av_assert0
	ldur	x8, [x29, #-88]
Lloh33:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh34:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh35:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_27
; %bb.26:
	sub	sp, x29, #80
	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_27:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.cfi_endproc
                                        ; -- End function
	.comm	_MPA_MAX_CHANNELS,4,2           ; @MPA_MAX_CHANNELS
	.comm	_SBLIMIT,4,2                    ; @SBLIMIT
	.comm	_SB_NOTALLOCATED,1,0            ; @SB_NOTALLOCATED
	.comm	_INT_MIN,4,2                    ; @INT_MIN
	.comm	_SB_NOMORE,1,0                  ; @SB_NOMORE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"current=%d max=%d max_sb=%d max_ch=%d alloc=%d\n"

	.comm	_nb_scale_factors,8,3           ; @nb_scale_factors
	.comm	_quant_snr,8,3                  ; @quant_snr
	.comm	_SB_ALLOCATED,1,0               ; @SB_ALLOCATED
	.no_dead_strip	_compute_bit_allocation
.subsections_via_symbols
