	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function snd_interval_ratden
_snd_interval_ratden:                   ## @snd_interval_ratden
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r8, -80(%rbp)                  ## 8-byte Spill
	movq	%rcx, -72(%rbp)                 ## 8-byte Spill
	testl	%esi, %esi
	je	LBB0_11
## %bb.1:
	movq	%rdx, %r15
	movl	%esi, %eax
	shlq	$4, %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	xorl	%r13d, %r13d
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
	movl	$0, -52(%rbp)                   ## 4-byte Folded Spill
	movl	$0, -48(%rbp)                   ## 4-byte Folded Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%r12, %rdi
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	addq	$16, %r13
	cmpq	%r13, -64(%rbp)                 ## 8-byte Folded Reload
	je	LBB0_10
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r15,%r13), %r14d
	movq	%rdi, %r12
	movl	(%rdi), %ebx
	movl	%ebx, %edi
	movl	%r14d, %esi
	callq	_mul
	movl	4(%r15,%r13), %esi
	cmpl	%esi, %eax
	ja	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, %ecx
	subl	8(%r15,%r13), %eax
	jb	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	12(%r15,%r13), %esi
	xorl	%edx, %edx
	divl	%esi
	subl	%edx, %esi
	testl	%edx, %edx
	cmovel	%edx, %esi
	addl	%ecx, %esi
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	imull	%r14d, %ebx
	movl	%esi, %eax
	subl	%ebx, %eax
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	movq	%r12, %rdi
	je	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, %ecx
	imull	-48(%rbp), %ecx                 ## 4-byte Folded Reload
	movl	%r14d, %edx
	imull	-52(%rbp), %edx                 ## 4-byte Folded Reload
	cmpl	%edx, %ecx
	jae	LBB0_9
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%r14d, -48(%rbp)                ## 4-byte Spill
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	jmp	LBB0_9
LBB0_10:
	movl	-48(%rbp), %ebx                 ## 4-byte Reload
	testl	%ebx, %ebx
	je	LBB0_11
## %bb.13:
	movl	-44(%rbp), %r13d                ## 4-byte Reload
	movl	%r13d, %edi
	movl	%ebx, %esi
	callq	_div_down
	movl	%eax, -112(%rbp)
	xorl	%r14d, %r14d
	movl	%r13d, %eax
	xorl	%edx, %edx
	divl	%ebx
	xorl	%eax, %eax
	testl	%edx, %edx
	setne	%al
	movl	%eax, -104(%rbp)
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
	movl	$0, -52(%rbp)                   ## 4-byte Folded Spill
	movl	$0, -48(%rbp)                   ## 4-byte Folded Spill
	jmp	LBB0_14
	.p2align	4, 0x90
LBB0_19:                                ##   in Loop: Header=BB0_14 Depth=1
	movl	%ebx, -48(%rbp)                 ## 4-byte Spill
	movl	%r13d, -52(%rbp)                ## 4-byte Spill
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
LBB0_20:                                ##   in Loop: Header=BB0_14 Depth=1
	addq	$16, %r14
	cmpq	%r14, -64(%rbp)                 ## 8-byte Folded Reload
	je	LBB0_21
LBB0_14:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r15,%r14), %ebx
	movl	12(%r12), %r13d
	movl	%r13d, %edi
	movl	%ebx, %esi
	callq	_mul
	movl	%eax, %ecx
	subl	8(%r15,%r14), %eax
	jb	LBB0_20
## %bb.15:                              ##   in Loop: Header=BB0_14 Depth=1
	movl	4(%r15,%r14), %edx
	cmpl	%edx, %ecx
	ja	LBB0_17
## %bb.16:                              ##   in Loop: Header=BB0_14 Depth=1
	xorl	%edx, %edx
	divl	12(%r15,%r14)
	subl	%edx, %ecx
	movl	%ecx, %edx
LBB0_17:                                ##   in Loop: Header=BB0_14 Depth=1
	imull	%ebx, %r13d
	subl	%edx, %r13d
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_19
## %bb.18:                              ##   in Loop: Header=BB0_14 Depth=1
	movl	%r13d, %eax
	imull	-48(%rbp), %eax                 ## 4-byte Folded Reload
	movl	%ebx, %ecx
	imull	-52(%rbp), %ecx                 ## 4-byte Folded Reload
	cmpl	%ecx, %eax
	jb	LBB0_19
	jmp	LBB0_20
LBB0_11:
	movl	$1, 4(%rdi)
LBB0_12:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_29:
	movl	%ebx, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_21:
	movl	-48(%rbp), %r15d                ## 4-byte Reload
	testl	%r15d, %r15d
	je	LBB0_22
## %bb.23:
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	movl	%ebx, %edi
	movl	%r15d, %esi
	callq	_div_up
	movl	%eax, -100(%rbp)
	movl	%ebx, %eax
	xorl	%edx, %edx
	divl	%r15d
	xorl	%eax, %eax
	testl	%edx, %edx
	setne	%al
	movl	%eax, -96(%rbp)
	movq	$0, -88(%rbp)
	leaq	-112(%rbp), %rsi
	movq	%r12, %rdi
	callq	_snd_interval_refine
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_29
## %bb.24:
	movq	%r12, %rdi
	callq	_snd_interval_single
	testq	%rax, %rax
	je	LBB0_29
## %bb.25:
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	testq	%rax, %rax
	je	LBB0_27
## %bb.26:
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	movl	%ecx, (%rax)
LBB0_27:
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	testq	%rax, %rax
	je	LBB0_29
## %bb.28:
	movl	%r15d, (%rax)
	jmp	LBB0_29
LBB0_22:
	movl	$1, 4(%r12)
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_snd_interval_ratden
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function snd_interval_ratden
_snd_interval_ratden:                   ; @snd_interval_ratden
	.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
	stp	x3, x4, [sp]                    ; 16-byte Folded Spill
	mov	x21, x0
	cbz	w1, LBB0_25
; %bb.1:
	mov	x24, x2
	mov	w26, #0
	mov	w19, #0
	mov	w25, #0
	mov	w20, w1
	add	x28, x2, #8
	mov	x27, x20
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x25, x22
	mov	x19, x9
	mov	x26, x8
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	add	x28, x28, #16
	subs	x27, x27, #1
	b.eq	LBB0_9
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldur	w22, [x28, #-8]
	ldr	w23, [x21]
	mov	x0, x23
	mov	x1, x22
	bl	_mul
	ldur	w8, [x28, #-4]
	cmp	w0, w8
	b.hi	LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w9, [x28]
	subs	w9, w0, w9
	b.lo	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w8, [x28, #4]
	udiv	w10, w9, w8
	msub	w9, w10, w8, w9
	sub	w8, w8, w9
	cmp	w9, #0
	csel	w8, wzr, w8, eq
	add	w8, w8, w0
LBB0_7:                                 ;   in Loop: Header=BB0_4 Depth=1
	msub	w9, w23, w22, w8
	cbz	w26, LBB0_2
; %bb.8:                                ;   in Loop: Header=BB0_4 Depth=1
	mul	w10, w9, w25
	mul	w11, w22, w19
	cmp	w10, w11
	b.lo	LBB0_2
	b	LBB0_3
LBB0_9:
	cbz	w25, LBB0_25
; %bb.10:
	mov	x0, x26
	mov	x1, x25
	bl	_div_down
	mov	w23, #0
	mov	w28, #0
	mov	w22, #0
	udiv	w8, w26, w25
	msub	w8, w8, w25, w26
	cmp	w8, #0
	cset	w8, ne
	str	w0, [sp, #16]
	str	w8, [sp, #24]
	add	x19, x24, #8
	b	LBB0_13
LBB0_11:                                ;   in Loop: Header=BB0_13 Depth=1
	mov	x22, x24
	mov	x28, x9
	mov	x23, x8
LBB0_12:                                ;   in Loop: Header=BB0_13 Depth=1
	add	x19, x19, #16
	subs	x20, x20, #1
	b.eq	LBB0_18
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldur	w24, [x19, #-8]
	ldr	w25, [x21, #12]
	mov	x0, x25
	mov	x1, x24
	bl	_mul
	ldr	w8, [x19]
	subs	w9, w0, w8
	b.lo	LBB0_12
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	ldur	w8, [x19, #-4]
	cmp	w0, w8
	b.hi	LBB0_16
; %bb.15:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	w8, [x19, #4]
	udiv	w10, w9, w8
	neg	w9, w9
	madd	w8, w10, w8, w9
	add	w8, w0, w8
LBB0_16:                                ;   in Loop: Header=BB0_13 Depth=1
	neg	w9, w8
	madd	w9, w25, w24, w9
	cbz	w23, LBB0_11
; %bb.17:                               ;   in Loop: Header=BB0_13 Depth=1
	mul	w10, w9, w22
	mul	w11, w24, w28
	cmp	w10, w11
	b.lo	LBB0_11
	b	LBB0_12
LBB0_18:
	cbz	w22, LBB0_25
; %bb.19:
	mov	x0, x23
	mov	x1, x22
	bl	_div_up
	udiv	w8, w23, w22
	msub	w8, w8, w22, w23
	cmp	w8, #0
	cset	w8, ne
	stp	w0, w8, [sp, #28]
	str	xzr, [sp, #40]
	add	x1, sp, #16
	mov	x0, x21
	bl	_snd_interval_refine
	mov	x24, x0
	tbnz	w0, #31, LBB0_26
; %bb.20:
	mov	x0, x21
	bl	_snd_interval_single
	cbz	x0, LBB0_26
; %bb.21:
	ldr	x8, [sp]                        ; 8-byte Folded Reload
	cbz	x8, LBB0_23
; %bb.22:
	str	w23, [x8]
LBB0_23:
	ldr	x8, [sp, #8]                    ; 8-byte Folded Reload
	cbz	x8, LBB0_26
; %bb.24:
	str	w22, [x8]
	b	LBB0_26
LBB0_25:
	mov	w8, #1
	str	w8, [x21, #4]
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w24, w8
LBB0_26:
	mov	x0, x24
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_snd_interval_ratden
.subsections_via_symbols
