	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function qfq_calc_index
_qfq_calc_index:                        ## @qfq_calc_index
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movl	%edi, %r15d
	movl	%esi, %ebx
	imull	%edi, %ebx
	movq	_QFQ_MIN_SLOT_SHIFT@GOTPCREL(%rip), %r12
	movb	(%r12), %cl
	movl	%ebx, %eax
	sarl	%cl, %eax
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	movslq	%eax, %rdi
	callq	___fls
                                        ## kill: def $eax killed $eax def $rax
	movslq	%ebx, %rdx
	movl	%eax, %ecx
	addl	(%r12), %ecx
	movq	$-1, %rsi
                                        ## kill: def $cl killed $cl killed $ecx
	shlq	%cl, %rsi
	xorl	%ecx, %ecx
	addq	%rdx, %rsi
	sete	%cl
	negl	%ecx
	addl	%ecx, %eax
	incl	%eax
	xorl	%ebx, %ebx
	testl	%eax, %eax
	cmovgl	%eax, %ebx
	jmp	LBB0_3
LBB0_1:
	xorl	%ebx, %ebx
LBB0_3:
	movq	_ONE_FP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	cltd
	idivl	%r15d
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	movl	%r14d, %edx
	movl	%ebx, %ecx
	callq	_ND
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_QFQ_MIN_SLOT_SHIFT,4,2         ## @QFQ_MIN_SLOT_SHIFT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"W = %d, L = %d, I = %d\n"

	.comm	_ONE_FP,4,2                     ## @ONE_FP
	.no_dead_strip	_qfq_calc_index
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function qfq_calc_index
_qfq_calc_index:                        ; @qfq_calc_index
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x19, x1
	mov	x20, x0
	mul	w21, w1, w0
Lloh0:
	adrp	x22, _QFQ_MIN_SLOT_SHIFT@GOTPAGE
Lloh1:
	ldr	x22, [x22, _QFQ_MIN_SLOT_SHIFT@GOTPAGEOFF]
	ldr	w8, [x22]
	asr	w8, w21, w8
	cbz	w8, LBB0_2
; %bb.1:
	sxtw	x0, w8
	bl	___fls
	ldr	w8, [x22]
	add	w8, w8, w0
	mov	x9, #-1
	lsl	x8, x9, x8
	cmn	x8, w21, sxtw
	cset	w8, eq
	sub	w8, w0, w8
	add	w9, w8, #1
	cmp	w9, #0
	csinc	w21, wzr, w8, le
	b	LBB0_3
LBB0_2:
	mov	w21, #0
LBB0_3:
Lloh2:
	adrp	x8, _ONE_FP@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ONE_FP@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	sdiv	w1, w8, w20
Lloh5:
	adrp	x0, l_.str@PAGE
Lloh6:
	add	x0, x0, l_.str@PAGEOFF
	mov	x2, x19
	mov	x3, x21
	bl	_ND
	mov	x0, x21
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_QFQ_MIN_SLOT_SHIFT,4,2         ; @QFQ_MIN_SLOT_SHIFT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"W = %d, L = %d, I = %d\n"

	.comm	_ONE_FP,4,2                     ; @ONE_FP
	.no_dead_strip	_qfq_calc_index
.subsections_via_symbols
