	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function get_fr_idx
_get_fr_idx:                            ## @get_fr_idx
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	(%rdi), %rax
	movq	_BRIDGE_TP6800@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_1
## %bb.7:
	movq	_rates@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	callq	_ARRAY_SIZE
	cmpl	$2, %eax
	jl	LBB0_13
## %bb.8:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r14), %rax
	movq	(%r15), %rdi
	cmpq	(%rdi,%rbx,8), %rax
	jge	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	incq	%rbx
	callq	_ARRAY_SIZE
	decl	%eax
	cltq
	cmpq	%rax, %rbx
	jl	LBB0_9
LBB0_11:
	testl	%ebx, %ebx
	je	LBB0_13
## %bb.12:
	movl	$6, %eax
	subl	%ebx, %eax
	jmp	LBB0_16
LBB0_1:
	movq	_rates_6810@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	callq	_ARRAY_SIZE
	cmpl	$2, %eax
	jl	LBB0_14
## %bb.2:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r14), %rax
	movq	(%r15), %rdi
	cmpq	(%rdi,%rbx,8), %rax
	jge	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	incq	%rbx
	callq	_ARRAY_SIZE
	decl	%eax
	cltq
	cmpq	%rax, %rbx
	jl	LBB0_3
LBB0_5:
	testl	%ebx, %ebx
	je	LBB0_14
## %bb.6:
	movl	$7, %eax
	subl	%ebx, %eax
	jmp	LBB0_15
LBB0_13:
	xorl	%ecx, %ecx
	cmpl	$640, (%r14)                    ## imm = 0x280
	sete	%cl
	movl	$6, %eax
	subl	%ecx, %eax
	jmp	LBB0_16
LBB0_14:
	xorl	%eax, %eax
	cmpl	$640, (%r14)                    ## imm = 0x280
	sete	%al
	xorl	$7, %eax
LBB0_15:
	orl	$128, %eax
LBB0_16:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BRIDGE_TP6800,8,3              ## @BRIDGE_TP6800
	.comm	_rates,8,3                      ## @rates
	.comm	_rates_6810,8,3                 ## @rates_6810
	.no_dead_strip	_get_fr_idx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function get_fr_idx
_get_fr_idx:                            ; @get_fr_idx
	.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, x0
	ldr	x8, [x0]
Lloh0:
	adrp	x9, _BRIDGE_TP6800@GOTPAGE
Lloh1:
	ldr	x9, [x9, _BRIDGE_TP6800@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_7
; %bb.1:
Lloh3:
	adrp	x20, _rates@GOTPAGE
Lloh4:
	ldr	x20, [x20, _rates@GOTPAGEOFF]
	ldr	x0, [x20]
	bl	_ARRAY_SIZE
	cmp	w0, #2
	b.lt	LBB0_13
; %bb.2:
	mov	x21, #0
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #8]
	ldr	x0, [x20]
	ldr	x9, [x0, x21, lsl #3]
	cmp	x8, x9
	b.ge	LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x21, x21, #1
	bl	_ARRAY_SIZE
	sub	w8, w0, #1
	cmp	x21, w8, sxtw
	b.lt	LBB0_3
LBB0_5:
	cbz	w21, LBB0_13
; %bb.6:
	mov	w8, #6
	sub	w0, w8, w21
	b	LBB0_16
LBB0_7:
Lloh5:
	adrp	x20, _rates_6810@GOTPAGE
Lloh6:
	ldr	x20, [x20, _rates_6810@GOTPAGEOFF]
	ldr	x0, [x20]
	bl	_ARRAY_SIZE
	cmp	w0, #2
	b.lt	LBB0_14
; %bb.8:
	mov	x21, #0
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #8]
	ldr	x0, [x20]
	ldr	x9, [x0, x21, lsl #3]
	cmp	x8, x9
	b.ge	LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	add	x21, x21, #1
	bl	_ARRAY_SIZE
	sub	w8, w0, #1
	cmp	x21, w8, sxtw
	b.lt	LBB0_9
LBB0_11:
	cbz	w21, LBB0_14
; %bb.12:
	mov	w8, #7
	sub	w8, w8, w21
	b	LBB0_15
LBB0_13:
	ldr	w8, [x19]
	cmp	w8, #640
	mov	w8, #5
	cinc	w0, w8, ne
	b	LBB0_16
LBB0_14:
	ldr	w8, [x19]
	cmp	w8, #640
	mov	w8, #6
	cinc	w8, w8, ne
LBB0_15:
	orr	w0, w8, #0x80
LBB0_16:
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_BRIDGE_TP6800,8,3              ; @BRIDGE_TP6800
	.comm	_rates,8,3                      ; @rates
	.comm	_rates_6810,8,3                 ; @rates_6810
	.no_dead_strip	_get_fr_idx
.subsections_via_symbols
