	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function il3945_get_rate_idx_by_rssi
_il3945_get_rate_idx_by_rssi:           ## @il3945_get_rate_idx_by_rssi
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	_IL_MIN_RSSI_VAL@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_IL_MAX_RSSI_VAL@GOTPCREL(%rip), %rcx
	cmpq	%rdi, (%rcx)
	movq	%rdi, %rbx
	cmovlq	%rax, %rbx
	cmpq	%rdi, %rax
	cmovgq	%rax, %rbx
	cmpl	$129, %esi
	je	LBB0_1
## %bb.2:
	cmpl	$128, %esi
	jne	LBB0_12
## %bb.3:
	movq	_il3945_tpt_table_a@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_1:
	movq	_il3945_tpt_table_g@GOTPCREL(%rip), %rax
LBB0_4:
	movq	(%rax), %r14
	movq	%r14, %rdi
	callq	_ARRAY_SIZE
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:
	movq	%rax, %rsi
	xorl	%edi, %edi
	movq	%r14, %rax
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	(%rax), %rbx
	jge	LBB0_10
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	incq	%rdi
	addq	$16, %rax
	cmpq	%rdi, %rsi
	jne	LBB0_7
## %bb.9:
	movq	%rsi, %rdi
LBB0_10:
	decq	%rsi
	jmp	LBB0_11
LBB0_12:
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_BUG
LBB0_5:
	movq	$-1, %rsi
	xorl	%edi, %edi
LBB0_11:
	callq	_min
	shlq	$4, %rax
	movl	8(%r14,%rax), %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IL_MIN_RSSI_VAL,8,3            ## @IL_MIN_RSSI_VAL
	.comm	_IL_MAX_RSSI_VAL,8,3            ## @IL_MAX_RSSI_VAL
	.comm	_il3945_tpt_table_g,8,3         ## @il3945_tpt_table_g
	.comm	_il3945_tpt_table_a,8,3         ## @il3945_tpt_table_a
	.no_dead_strip	_il3945_get_rate_idx_by_rssi
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function il3945_get_rate_idx_by_rssi
_il3945_get_rate_idx_by_rssi:           ; @il3945_get_rate_idx_by_rssi
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
Lloh0:
	adrp	x8, _IL_MIN_RSSI_VAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IL_MIN_RSSI_VAL@GOTPAGEOFF]
Lloh2:
	adrp	x9, _IL_MAX_RSSI_VAL@GOTPAGE
Lloh3:
	ldr	x9, [x9, _IL_MAX_RSSI_VAL@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
Lloh5:
	ldr	x9, [x9]
	cmp	x9, x0
	ccmp	x8, x0, #0, ge
	csel	x20, x8, x0, gt
	cmp	w1, #129
	b.eq	LBB0_3
; %bb.1:
	cmp	w1, #128
	b.ne	LBB0_10
; %bb.2:
Lloh6:
	adrp	x8, _il3945_tpt_table_a@GOTPAGE
Lloh7:
	ldr	x8, [x8, _il3945_tpt_table_a@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:
Lloh8:
	adrp	x8, _il3945_tpt_table_g@GOTPAGE
Lloh9:
	ldr	x8, [x8, _il3945_tpt_table_g@GOTPAGEOFF]
LBB0_4:
	ldr	x19, [x8]
	mov	x0, x19
	bl	_ARRAY_SIZE
	cbz	x0, LBB0_11
; %bb.5:
	mov	x8, x0
	mov	x0, #0
	mov	x9, x19
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x9]
	cmp	x20, x10
	b.ge	LBB0_9
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	add	x0, x0, #1
	add	x9, x9, #16
	cmp	x8, x0
	b.ne	LBB0_6
; %bb.8:
	mov	x0, x8
LBB0_9:
	sub	x1, x8, #1
	b	LBB0_12
LBB0_10:
	bl	_BUG
	mov	x19, #0
	mov	x0, #0
LBB0_11:
	mov	x1, #-1
LBB0_12:
	bl	_min
	add	x8, x19, x0, lsl #4
	ldr	w0, [x8, #8]
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_IL_MIN_RSSI_VAL,8,3            ; @IL_MIN_RSSI_VAL
	.comm	_IL_MAX_RSSI_VAL,8,3            ; @IL_MAX_RSSI_VAL
	.comm	_il3945_tpt_table_g,8,3         ; @il3945_tpt_table_g
	.comm	_il3945_tpt_table_a,8,3         ; @il3945_tpt_table_a
	.no_dead_strip	_il3945_get_rate_idx_by_rssi
.subsections_via_symbols
