	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function minstrel_update_stats
_minstrel_update_stats:                 ## @minstrel_update_stats
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r13
	movq	%rdi, -88(%rbp)                 ## 8-byte Spill
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_MAX_THR_RATES@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movq	%r14, %rbx
	shlq	$3, %rbx
	movq	%rbx, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %rax
	testl	%r14d, %r14d
	movq	%rax, %r14
	jle	LBB0_2
## %bb.1:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	___bzero
LBB0_2:
	cmpl	$0, (%r13)
	jle	LBB0_3
## %bb.4:
	movq	24(%r13), %r12
	movl	$68, %r15d
	xorl	%eax, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	movq	%r13, -72(%rbp)                 ## 8-byte Spill
	movq	%r14, -64(%rbp)                 ## 8-byte Spill
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_5 Depth=1
	movl	-44(%r12,%r15), %eax
	movq	24(%r13), %r12
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	leaq	(%rbx,%rbx,8), %rcx
	cmpl	24(%r12,%rcx,8), %eax
LBB0_19:                                ##   in Loop: Header=BB0_5 Depth=1
	setl	%al
	testb	%al, %al
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	cmoveq	%rdx, %rbx
	incq	%rdx
	movslq	(%r13), %rax
	addq	$72, %r15
	movq	%rdx, %rcx
	movq	%rdx, -56(%rbp)                 ## 8-byte Spill
	cmpq	%rax, %rdx
	jge	LBB0_20
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, -80(%rbp)                 ## 8-byte Spill
	movl	-68(%r12,%r15), %r14d
	testl	%r14d, %r14d
	movl	$1000000, %eax                  ## imm = 0xF4240
	cmovel	%eax, %r14d
	xorl	%edi, %edi
	cmpq	$0, -60(%r12,%r15)
	setg	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	$0, -12(%r12,%r15)
	movl	-60(%r12,%r15), %esi
	movl	-48(%r12,%r15), %edi
	callq	_MINSTREL_FRAC
	movl	%eax, -52(%r12,%r15)
	movl	-60(%r12,%r15), %ecx
	movl	-48(%r12,%r15), %edx
	addl	%edx, (%r12,%r15)
	addl	%ecx, -4(%r12,%r15)
	movl	-44(%r12,%r15), %edi
	movq	_EWMA_LEVEL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%eax, %esi
	callq	_minstrel_ewma
	movl	%eax, %ebx
	movl	%eax, -44(%r12,%r15)
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	incq	-12(%r12,%r15)
	movl	-44(%r12,%r15), %ebx
LBB0_8:                                 ##   in Loop: Header=BB0_5 Depth=1
	movl	-60(%r12,%r15), %eax
	movl	-48(%r12,%r15), %ecx
	movl	%ecx, -40(%r12,%r15)
	movl	%eax, -36(%r12,%r15)
	movl	$0, -48(%r12,%r15)
	movq	$0, -60(%r12,%r15)
	movl	$10, %edi
	movl	$100, %esi
	callq	_MINSTREL_FRAC
	movl	%eax, %ecx
	xorl	%eax, %eax
	movl	-44(%r12,%r15), %r13d
	cmpl	%ecx, %ebx
	jl	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	$1000000, %eax                  ## imm = 0xF4240
	xorl	%edx, %edx
	idivl	%r14d
	imull	%r13d, %eax
LBB0_10:                                ##   in Loop: Header=BB0_5 Depth=1
	movl	%eax, -32(%r12,%r15)
	movl	$95, %edi
	movl	$100, %esi
	callq	_MINSTREL_FRAC
	cmpl	%eax, %r13d
	jg	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_5 Depth=1
	movl	-44(%r12,%r15), %ebx
	movl	$10, %edi
	movl	$100, %esi
	callq	_MINSTREL_FRAC
	cmpl	%eax, %ebx
	jge	LBB0_13
LBB0_12:                                ##   in Loop: Header=BB0_5 Depth=1
	movl	-24(%r12,%r15), %ecx
	movl	%ecx, %eax
	sarl	%eax
	cmpl	$6, %ecx
	movl	$2, %ecx
	cmovgel	%ecx, %eax
	movl	%eax, -28(%r12,%r15)
	movl	$4, -20(%r12,%r15)
	jmp	LBB0_14
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_5 Depth=1
	movl	$-1, -20(%r12,%r15)
	movl	-24(%r12,%r15), %eax
	movl	%eax, -28(%r12,%r15)
LBB0_14:                                ##   in Loop: Header=BB0_5 Depth=1
	movq	-72(%rbp), %r13                 ## 8-byte Reload
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	testl	%eax, %eax
	jne	LBB0_16
## %bb.15:                              ##   in Loop: Header=BB0_5 Depth=1
	movl	$2, -28(%r12,%r15)
LBB0_16:                                ##   in Loop: Header=BB0_5 Depth=1
	movq	%r13, %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	movq	%r14, %rdx
	callq	_minstrel_sort_best_tp_rates
	movl	-44(%r12,%r15), %ebx
	movl	$95, %edi
	movl	$100, %esi
	callq	_MINSTREL_FRAC
	cmpl	%eax, %ebx
	jl	LBB0_18
## %bb.17:                              ##   in Loop: Header=BB0_5 Depth=1
	movl	-32(%r12,%r15), %eax
	movq	24(%r13), %r12
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	leaq	(%rbx,%rbx,8), %rcx
	cmpl	36(%r12,%rcx,8), %eax
	jmp	LBB0_19
LBB0_3:
	xorl	%ebx, %ebx
LBB0_20:
	movl	20(%r13), %edi
	movq	%r14, %rsi
	movl	$4, %edx
	callq	_memcpy
	movq	%rbx, 8(%r13)
	movq	_jiffies@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%r13)
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	movq	%r13, %rsi
	callq	_minstrel_update_rates
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_22
## %bb.21:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_22:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_THR_RATES,4,2              ## @MAX_THR_RATES
	.comm	_EWMA_LEVEL,4,2                 ## @EWMA_LEVEL
	.comm	_jiffies,4,2                    ## @jiffies
	.no_dead_strip	_minstrel_update_stats
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function minstrel_update_stats
_minstrel_update_stats:                 ; @minstrel_update_stats
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	sub	sp, sp, #16
	mov	x19, x1
	stur	x0, [x29, #-96]                 ; 8-byte Folded Spill
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _MAX_THR_RATES@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MAX_THR_RATES@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	lsl	x1, x8, #3
	mov	x9, x1
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x10, x1, #15
	and	x10, x10, #0xffffffff0
	sub	x21, x9, x10
	mov	sp, x21
	cmp	w8, #1
	b.lt	LBB0_2
; %bb.1:
	mov	x0, x21
	bl	_bzero
LBB0_2:
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_18
; %bb.3:
	mov	x22, #0
	mov	x24, #0
	ldr	x27, [x19, #24]
	mov	w26, #36
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldur	w8, [x20, #-12]
	ldr	x27, [x19, #24]
	mov	w9, #72
	madd	x9, x24, x9, x27
	ldr	w9, [x9, #24]
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	cmp	w8, w9
	cset	w8, lt
	cmp	w8, #0
	csel	x24, x24, x22, ne
	add	x22, x22, #1
	ldrsw	x8, [x19]
	add	x26, x26, #72
	cmp	x22, x8
	b.ge	LBB0_19
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	add	x25, x27, x26
	ldur	w8, [x25, #-36]
	cmp	w8, #0
	mov	w9, #16960
	movk	w9, #15, lsl #16
	csel	w28, w9, w8, eq
	ldur	x8, [x25, #-28]
	cmp	x8, #0
	cset	w0, gt
	bl	_unlikely
	cbz	x0, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	stur	xzr, [x25, #20]
	ldur	w0, [x25, #-16]
	ldur	w1, [x25, #-28]
	bl	_MINSTREL_FRAC
	mov	x1, x0
	stur	w0, [x25, #-20]
	ldp	w9, w8, [x25, #28]
	ldp	w10, w0, [x25, #-16]
	add	w8, w8, w10
	ldur	w10, [x25, #-28]
	add	w9, w9, w10
	stp	w9, w8, [x25, #28]
Lloh8:
	adrp	x8, _EWMA_LEVEL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EWMA_LEVEL@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	bl	_minstrel_ewma
	mov	x23, x0
	stur	w0, [x25, #-12]
	b	LBB0_9
LBB0_8:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldur	x8, [x25, #20]
	add	x8, x8, #1
	stur	x8, [x25, #20]
	ldur	w23, [x25, #-12]
LBB0_9:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x20, x27, x26
	ldur	w8, [x20, #-16]
	ldur	x9, [x25, #-28]
	stp	w8, w9, [x20, #-8]
	stur	wzr, [x20, #-16]
	stur	xzr, [x25, #-28]
	mov	w0, #10
	mov	w1, #100
	bl	_MINSTREL_FRAC
	mov	w8, #0
	ldur	w25, [x20, #-12]
	cmp	w23, w0
	b.lt	LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_6 Depth=1
	mov	w8, #16960
	movk	w8, #15, lsl #16
	sdiv	w8, w8, w28
	mul	w8, w8, w25
LBB0_11:                                ;   in Loop: Header=BB0_6 Depth=1
	str	w8, [x27, x26]
	mov	w0, #95
	mov	w1, #100
	bl	_MINSTREL_FRAC
	cmp	w25, w0
	b.gt	LBB0_13
; %bb.12:                               ;   in Loop: Header=BB0_6 Depth=1
	ldur	w23, [x20, #-12]
	mov	w0, #10
	mov	w1, #100
	bl	_MINSTREL_FRAC
	cmp	w23, w0
	b.ge	LBB0_17
LBB0_13:                                ;   in Loop: Header=BB0_6 Depth=1
	add	x9, x27, x26
	ldr	w8, [x9, #8]
	asr	w10, w8, #1
	cmp	w8, #5
	mov	w8, #2
	csel	w8, w8, w10, gt
	str	w8, [x9, #4]
	mov	w10, #4
	str	w10, [x9, #12]
	cbnz	w8, LBB0_15
LBB0_14:                                ;   in Loop: Header=BB0_6 Depth=1
	add	x8, x27, x26
	mov	w9, #2
	str	w9, [x8, #4]
LBB0_15:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x0, x19
	mov	x1, x22
	mov	x2, x21
	bl	_minstrel_sort_best_tp_rates
	ldur	w23, [x20, #-12]
	mov	w0, #95
	mov	w1, #100
	bl	_MINSTREL_FRAC
	cmp	w23, w0
	b.lt	LBB0_4
; %bb.16:                               ;   in Loop: Header=BB0_6 Depth=1
	ldr	w8, [x27, x26]
	ldr	x27, [x19, #24]
	mov	w9, #72
	madd	x9, x24, x9, x27
	ldr	w9, [x9, #36]
	b	LBB0_5
LBB0_17:                                ;   in Loop: Header=BB0_6 Depth=1
	add	x9, x27, x26
	mov	w8, #-1
	str	w8, [x9, #12]
	ldr	w8, [x9, #8]
	str	w8, [x9, #4]
	cbnz	w8, LBB0_15
	b	LBB0_14
LBB0_18:
	mov	x24, #0
LBB0_19:
	ldr	w0, [x19, #20]
	mov	x1, x21
	mov	w2, #4
	bl	_memcpy
	str	x24, [x19, #8]
Lloh11:
	adrp	x8, _jiffies@GOTPAGE
Lloh12:
	ldr	x8, [x8, _jiffies@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	str	w8, [x19, #16]
	ldur	x0, [x29, #-96]                 ; 8-byte Folded Reload
	mov	x1, x19
	bl	_minstrel_update_rates
	ldur	x8, [x29, #-88]
Lloh14:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh15:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_21
; %bb.20:
	sub	sp, x29, #80
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_21:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_THR_RATES,4,2              ; @MAX_THR_RATES
	.comm	_EWMA_LEVEL,4,2                 ; @EWMA_LEVEL
	.comm	_jiffies,4,2                    ; @jiffies
	.no_dead_strip	_minstrel_update_stats
.subsections_via_symbols
