	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function get_scale_factor
_get_scale_factor:                      ## @get_scale_factor
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %r13
	movq	8(%rdi), %rax
	movq	(%rax), %rax
	movslq	%ecx, %rbx
	shlq	$4, %rbx
	movl	(%rax,%rbx), %r12d
	subl	%r12d, %edx
	movl	%edx, %edi
	callq	_av_clip_int8
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movl	%eax, %r15d
	movq	8(%r13), %rax
	movq	(%rax), %rax
	movq	8(%rax,%rbx), %rax
	cmpq	$0, (%rax)
	je	LBB0_3
LBB0_2:
	movl	$256, %eax                      ## imm = 0x100
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	subl	%r12d, %r14d
	movl	%r14d, %edi
	callq	_av_clip_int8
	movl	%eax, %ebx
	movl	%r15d, %edi
	callq	_FFABS
	sarl	%eax
	addl	$16384, %eax                    ## imm = 0x4000
	cltd
	idivl	%r15d
	imull	%eax, %ebx
	addl	$32, %ebx
	sarl	$6, %ebx
	movl	%ebx, %edi
	movl	$10, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_av_clip_intp2                  ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_LOG_DEBUG,4,2               ## @AV_LOG_DEBUG
	.no_dead_strip	_get_scale_factor
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function get_scale_factor
_get_scale_factor:                      ; @get_scale_factor
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x21, x3
	mov	x20, x1
	mov	x22, x0
	ldr	x8, [x0, #8]
	ldr	x8, [x8]
	sbfiz	x9, x21, #4, #32
	ldr	w23, [x8, x9]
	sub	w0, w2, w23
	bl	_av_clip_int8
	cbz	w0, LBB0_2
; %bb.1:
	sxtw	x8, w21
	ldr	x9, [x22, #8]
	ldr	x9, [x9]
	add	x8, x9, x8, lsl #4
	ldr	x8, [x8, #8]
	ldr	x8, [x8]
	cbz	x8, LBB0_3
LBB0_2:
	mov	w0, #256
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_3:
	mov	x19, x0
	sub	w0, w20, w23
	bl	_av_clip_int8
	mov	x20, x0
	mov	x0, x19
	bl	_FFABS
	asr	w8, w0, #1
	add	w8, w8, #4, lsl #12             ; =16384
	sdiv	w8, w8, w19
	orr	w9, wzr, #0x20
	madd	w8, w8, w20, w9
	asr	w0, w8, #6
	mov	w1, #10
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_av_clip_intp2
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_LOG_DEBUG,4,2               ; @AV_LOG_DEBUG
	.no_dead_strip	_get_scale_factor
.subsections_via_symbols
