	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sbc_calc_scalefactors
_sbc_calc_scalefactors:                 ## @sbc_calc_scalefactors
	.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	%r8d, -44(%rbp)                 ## 4-byte Spill
	movl	%edx, -48(%rbp)                 ## 4-byte Spill
	movq	%rsi, -88(%rbp)                 ## 8-byte Spill
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	testl	%ecx, %ecx
	jle	LBB0_10
## %bb.1:
	movl	%ecx, %eax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	movl	-48(%rbp), %r15d                ## 4-byte Reload
	shlq	$6, %r15
	movq	_SCALE_OUT_BITS@GOTPCREL(%rip), %rdx
	xorl	%eax, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	incq	%rcx
	addq	$32, -64(%rbp)                  ## 8-byte Folded Spill
	movq	%rcx, %rax
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	cmpq	-72(%rbp), %rcx                 ## 8-byte Folded Reload
	je	LBB0_10
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
                                        ##       Child Loop BB0_6 Depth 3
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	jle	LBB0_9
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-64(%rbp), %r12                 ## 8-byte Reload
	xorl	%r13d, %r13d
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_4 Depth=2
	movl	%ebx, %edi
	callq	_ff_clz
	addl	%r14d, %eax
	movl	$31, %ecx
	subl	%eax, %ecx
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	shlq	$5, %rax
	addq	-88(%rbp), %rax                 ## 8-byte Folded Reload
	movl	%ecx, (%rax,%r13,4)
	incq	%r13
	addq	$4, %r12
	cmpq	-80(%rbp), %r13                 ## 8-byte Folded Reload
	movq	_SCALE_OUT_BITS@GOTPCREL(%rip), %rdx
	je	LBB0_9
LBB0_4:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Loop Header: Depth=2
                                        ##       Child Loop BB0_6 Depth 3
	movl	(%rdx), %r14d
	movl	$1, %ebx
	movl	%r14d, %ecx
	shll	%cl, %ebx
	cmpl	$0, -48(%rbp)                   ## 4-byte Folded Reload
	jle	LBB0_8
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=2
	movq	%r13, -96(%rbp)                 ## 8-byte Spill
	xorl	%r14d, %r14d
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_6:                                 ##   Parent Loop BB0_2 Depth=1
                                        ##     Parent Loop BB0_4 Depth=2
                                        ## =>    This Inner Loop Header: Depth=3
	movl	(%r12,%r13), %edi
	callq	_FFABS
	subl	$1, %eax
	cmovbl	%r14d, %eax
	orl	%eax, %ebx
	addq	$64, %r13
	cmpq	%r13, %r15
	jne	LBB0_6
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=2
	movq	_SCALE_OUT_BITS@GOTPCREL(%rip), %r14
	movl	(%r14), %r14d
	movq	-96(%rbp), %r13                 ## 8-byte Reload
	jmp	LBB0_8
LBB0_10:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SCALE_OUT_BITS,4,2             ## @SCALE_OUT_BITS
	.no_dead_strip	_sbc_calc_scalefactors
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sbc_calc_scalefactors
_sbc_calc_scalefactors:                 ; @sbc_calc_scalefactors
	.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
	str	w4, [sp, #12]                   ; 4-byte Folded Spill
	str	x0, [sp, #16]                   ; 8-byte Folded Spill
	cmp	w3, #1
	b.lt	LBB0_10
; %bb.1:
	mov	x20, x2
	mov	x21, x1
	mov	x24, #0
	mov	w8, w3
	str	x8, [sp]                        ; 8-byte Folded Spill
Lloh0:
	adrp	x26, _SCALE_OUT_BITS@GOTPAGE
Lloh1:
	ldr	x26, [x26, _SCALE_OUT_BITS@GOTPAGEOFF]
	ldr	w8, [sp, #12]                   ; 4-byte Folded Reload
	mov	w19, w8
	mov	w8, w2
	str	x8, [sp, #24]                   ; 8-byte Folded Spill
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x24, x24, #1
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	add	x8, x8, #32
	str	x8, [sp, #16]                   ; 8-byte Folded Spill
	ldr	x8, [sp]                        ; 8-byte Folded Reload
	cmp	x24, x8
	b.eq	LBB0_10
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_6 Depth 2
                                        ;       Child Loop BB0_8 Depth 3
	ldr	w8, [sp, #12]                   ; 4-byte Folded Reload
	cmp	w8, #1
	b.lt	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x22, #0
	ldr	x28, [sp, #16]                  ; 8-byte Folded Reload
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=2
	mov	x0, x23
	bl	_ff_clz
	add	w8, w25, w0
	mov	w9, #31
	sub	w8, w9, w8
	add	x9, x21, x24, lsl #5
	str	w8, [x9, x22, lsl #2]
	add	x22, x22, #1
	add	x28, x28, #4
	cmp	x22, x19
	b.eq	LBB0_2
LBB0_6:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Loop Header: Depth=2
                                        ;       Child Loop BB0_8 Depth 3
	ldr	w25, [x26]
	mov	w8, #1
	lsl	w23, w8, w25
	cmp	w20, #1
	b.lt	LBB0_5
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=2
	ldr	x25, [sp, #24]                  ; 8-byte Folded Reload
	mov	x27, x28
LBB0_8:                                 ;   Parent Loop BB0_3 Depth=1
                                        ;     Parent Loop BB0_6 Depth=2
                                        ; =>    This Inner Loop Header: Depth=3
	ldr	w0, [x27], #64
	bl	_FFABS
	sub	w8, w0, #1
	cmp	w0, #0
	csel	w8, wzr, w8, eq
	orr	w23, w8, w23
	subs	x25, x25, #1
	b.ne	LBB0_8
; %bb.9:                                ;   in Loop: Header=BB0_6 Depth=2
	ldr	w25, [x26]
	b	LBB0_5
LBB0_10:
	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
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_SCALE_OUT_BITS,4,2             ; @SCALE_OUT_BITS
	.no_dead_strip	_sbc_calc_scalefactors
.subsections_via_symbols
