	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tx_policy_build
_tx_policy_build:                       ## @tx_policy_build
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %rbx
	movq	%rdx, %r14
	movq	%rsi, %r13
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	movl	(%rdi), %r15d
	movq	(%rdx), %rdi
	shrq	$63, %rdi
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_BUG_ON
	xorl	%r12d, %r12d
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	$16, %edx
	callq	_memset
	cmpq	$1, %rbx
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	jbe	LBB0_1
## %bb.2:
	leaq	16(%r14), %rcx
	movl	$1, %eax
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_3 Depth=1
	incq	%rax
	addq	$16, %rcx
	cmpq	%rax, %rbx
	je	LBB0_8
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rcx), %rdx
	testq	%rdx, %rdx
	js	LBB0_7
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	cmpq	-16(%rcx), %rdx
	jle	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	movups	-16(%rcx), %xmm0
	movaps	%xmm0, -80(%rbp)
	movups	(%rcx), %xmm0
	movups	%xmm0, -16(%rcx)
	movaps	-80(%rbp), %xmm0
	movups	%xmm0, (%rcx)
	jmp	LBB0_6
LBB0_1:
	leaq	8(%r14), %r8
	movl	8(%r14), %edx
	jmp	LBB0_16
LBB0_7:
	movl	%eax, %ebx
LBB0_8:
	leaq	8(%r14), %r8
	movl	8(%r14), %edx
	cmpq	$2, %rbx
	jb	LBB0_16
## %bb.9:
	leaq	24(%r14), %rax
	xorl	%r12d, %r12d
	movl	$1, %ecx
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_10 Depth=1
	movl	(%rax), %edi
	addl	%edi, 8(%r14,%rsi)
LBB0_15:                                ##   in Loop: Header=BB0_10 Depth=1
	addl	(%rax), %edx
	incq	%rcx
	addq	$16, %rax
	cmpq	%rcx, %rbx
	je	LBB0_16
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	movslq	%r12d, %rsi
	shlq	$4, %rsi
	movq	(%r14,%rsi), %rdi
	cmpq	%rdi, -8(%rax)
	je	LBB0_11
## %bb.12:                              ##   in Loop: Header=BB0_10 Depth=1
	jg	LBB0_16
## %bb.13:                              ##   in Loop: Header=BB0_10 Depth=1
	incl	%r12d
	cmpq	%r12, %rcx
	je	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_10 Depth=1
	movslq	%r12d, %rsi
	shlq	$4, %rsi
	movups	-8(%rax), %xmm0
	movups	%xmm0, (%r14,%rsi)
	jmp	LBB0_15
LBB0_16:
	leal	1(%r12), %r10d
	movslq	%r10d, %rbx
	cmpq	%rbx, %r15
	cmovbl	%r10d, %r15d
	cmpl	%r15d, %edx
	jbe	LBB0_30
## %bb.17:
	testl	%r10d, %r10d
	je	LBB0_30
## %bb.18:
	cmpq	$2, %rbx
	movl	$1, %r9d
	cmovaeq	%rbx, %r9
	cmpl	$2, %r10d
	jae	LBB0_20
## %bb.19:
	xorl	%r14d, %r14d
	testb	$1, %r9b
	jne	LBB0_28
	jmp	LBB0_30
LBB0_20:
	movq	%r8, -56(%rbp)                  ## 8-byte Spill
	movq	%rbx, %r8
	movl	%r12d, %edi
	negl	%edi
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	leaq	24(%rax), %rbx
	movq	%r9, %r11
	andq	$-2, %r11
	negq	%r11
	xorl	%r14d, %r14d
	jmp	LBB0_21
	.p2align	4, 0x90
LBB0_25:                                ##   in Loop: Header=BB0_21 Depth=1
	subl	%ecx, %eax
	addl	$2, %edi
	addq	$32, %rbx
	addq	$-2, %r14
	movl	%eax, %r15d
	cmpq	%r14, %r11
	je	LBB0_26
LBB0_21:                                ## =>This Inner Loop Header: Depth=1
	movl	-16(%rbx), %ecx
	leal	(%r15,%rdi), %esi
	movl	%ecx, %edx
	cmpl	%esi, %ecx
	jbe	LBB0_23
## %bb.22:                              ##   in Loop: Header=BB0_21 Depth=1
	movl	%esi, -16(%rbx)
	movl	%esi, %edx
LBB0_23:                                ##   in Loop: Header=BB0_21 Depth=1
	movl	%r15d, %eax
	subl	%edx, %eax
	cmpl	%esi, %ecx
	cmovbl	%ecx, %esi
	movl	(%rbx), %ecx
	subl	%esi, %r15d
	leal	(%rdi,%r15), %esi
	incl	%esi
	cmpl	%esi, %ecx
	jbe	LBB0_25
## %bb.24:                              ##   in Loop: Header=BB0_21 Depth=1
	movl	%esi, (%rbx)
	movl	%esi, %ecx
	jmp	LBB0_25
LBB0_26:
	negq	%r14
	movl	%eax, %r15d
	movq	%r8, %rbx
	movq	-56(%rbp), %r8                  ## 8-byte Reload
	testb	$1, %r9b
	je	LBB0_30
LBB0_28:
	movl	%r14d, %eax
	subl	%r12d, %eax
	addl	%r15d, %eax
	shlq	$4, %r14
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	cmpl	%eax, 8(%rcx,%r14)
	jbe	LBB0_30
## %bb.29:
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	addq	%r14, %rcx
	addq	$8, %rcx
	movl	%eax, (%rcx)
LBB0_30:
	cmpl	$2, %r10d
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	jne	LBB0_40
## %bb.31:
	movq	_IEEE80211_TX_RC_MCS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	$2, %ebx
	testl	%eax, 12(%rsi)
	jne	LBB0_40
## %bb.32:
	movq	(%rsi), %rcx
	cmpq	$5, %rcx
	jl	LBB0_40
## %bb.33:
	movl	(%r8), %eax
	cmpl	$3, %eax
	jb	LBB0_40
## %bb.34:
	cmpq	$1, 16(%rsi)
	jg	LBB0_40
## %bb.35:
	leaq	16(%rsi), %rdi
	addq	$4, %rcx
	shrq	%rcx
	leal	-2(%rax), %edx
	movl	%edx, (%r8)
	cmpl	$4, %ecx
	jne	LBB0_36
## %bb.38:
	movups	(%rdi), %xmm0
	movups	%xmm0, 32(%rsi)
	movq	$4, 16(%rsi)
	leaq	24(%rsi), %rcx
	movl	$3, %ebx
	jmp	LBB0_39
LBB0_36:
	movups	(%rdi), %xmm0
	movups	%xmm0, 48(%rsi)
	movq	$4, 32(%rsi)
	movl	$1, 40(%rsi)
	movl	28(%rsi), %edi
	movl	%edi, 44(%rsi)
	movslq	%ecx, %rcx
	movq	%rcx, 16(%rsi)
	movl	$1, 24(%rsi)
	movl	$4, %ebx
	cmpl	$3, %edx
	jb	LBB0_40
## %bb.37:
	leaq	40(%rsi), %rcx
	addl	$-3, %eax
	movl	%eax, (%r8)
	movl	$4, %ebx
LBB0_39:
	movl	$2, (%rcx)
LBB0_40:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	callq	_cw1200_get_tx_rate
	movl	(%rax), %eax
	incl	%eax
	movl	%eax, (%r13)
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	testq	%rbx, %rbx
	je	LBB0_45
## %bb.41:
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	jmp	LBB0_42
	.p2align	4, 0x90
LBB0_44:                                ##   in Loop: Header=BB0_42 Depth=1
	movl	%r14d, %edi
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %edi
	callq	___cpu_to_le32
	movq	8(%r13), %rcx
	orl	%eax, (%rcx,%r12,4)
	addl	%r14d, 4(%r13)
	addq	$16, %rbx
	decq	%r15
	je	LBB0_45
LBB0_42:                                ## =>This Inner Loop Header: Depth=1
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	callq	_cw1200_get_tx_rate
	movl	(%rax), %r12d
	leal	(,%r12,4), %ecx
	shrq	$3, %r12
	andl	$28, %ecx
	movl	8(%rbx), %r14d
	cmpl	$16, %r14d
	jb	LBB0_44
## %bb.43:                              ##   in Loop: Header=BB0_42 Depth=1
	movl	$15, 8(%rbx)
	movl	$15, %r14d
	jmp	LBB0_44
LBB0_45:
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movl	(%rsi), %edx
	movl	8(%rsi), %ecx
	movl	16(%rsi), %r8d
	movl	24(%rsi), %r9d
	movl	32(%rsi), %r10d
	movl	40(%rsi), %r11d
	movl	48(%rsi), %eax
	movl	56(%rsi), %ebx
	leaq	L_.str(%rip), %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	pushq	%rbx
	pushq	%rax
	pushq	%r11
	pushq	%r10
	callq	_pr_debug
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IEEE80211_TX_RC_MCS,4,2        ## @IEEE80211_TX_RC_MCS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"[TX policy] Policy (%zu): %d:%d, %d:%d, %d:%d, %d:%d\n"

	.no_dead_strip	_tx_policy_build
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tx_policy_build
_tx_policy_build:                       ; @tx_policy_build
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x22, x3
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
	ldr	w23, [x0]
	ldr	x8, [x2]
	lsr	x0, x8, #63
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_BUG_ON
	mov	x0, x20
	mov	w1, #0
	mov	w2, #16
	bl	_memset
	cmp	x22, #1
	b.ls	LBB0_6
; %bb.1:
	add	x9, x19, #16
	mov	w8, #1
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x8, x8, #1
	add	x9, x9, #16
	cmp	x22, x8
	b.eq	LBB0_8
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x9]
	tbnz	x10, #63, LBB0_7
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldur	x11, [x9, #-16]
	cmp	x10, x11
	b.le	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldp	q0, q1, [x9, #-16]
	stp	q1, q0, [x9, #-16]
	b	LBB0_2
LBB0_6:
	mov	w9, #0
	mov	x8, x19
	ldr	w10, [x8, #8]!
	b	LBB0_17
LBB0_7:
	and	x22, x8, #0xffffffff
LBB0_8:
	mov	x8, x19
	ldr	w10, [x8, #8]!
	cmp	x22, #2
	b.lo	LBB0_16
; %bb.9:
	mov	w9, #0
	add	x11, x19, #24
	mov	w12, #1
	b	LBB0_12
LBB0_10:                                ;   in Loop: Header=BB0_12 Depth=1
	ldr	w14, [x11]
	add	x13, x19, x13, lsl #4
	ldr	w15, [x13, #8]
	add	w14, w15, w14
	str	w14, [x13, #8]
LBB0_11:                                ;   in Loop: Header=BB0_12 Depth=1
	ldr	w13, [x11], #16
	add	w10, w13, w10
	add	x12, x12, #1
	cmp	x22, x12
	b.eq	LBB0_17
LBB0_12:                                ; =>This Inner Loop Header: Depth=1
	ldur	x14, [x11, #-8]
	mov	x15, x9
	sxtw	x13, w15
	sbfiz	x15, x15, #4, #32
	ldr	x15, [x19, x15]
	cmp	x14, x15
	b.eq	LBB0_10
; %bb.13:                               ;   in Loop: Header=BB0_12 Depth=1
	b.gt	LBB0_17
; %bb.14:                               ;   in Loop: Header=BB0_12 Depth=1
	add	x9, x13, #1
	cmp	x12, w9, uxtw
	b.eq	LBB0_11
; %bb.15:                               ;   in Loop: Header=BB0_12 Depth=1
	ldur	q0, [x11, #-8]
	str	q0, [x19, x9, lsl #4]
	b	LBB0_11
LBB0_16:
	mov	w9, #0
LBB0_17:
	add	w12, w9, #1
	sxtw	x22, w12
	cmp	x23, x22
	csinc	w11, w23, w9, hs
	cmp	w10, w11
	ccmp	w12, #0, #4, hi
	b.ne	LBB0_25
LBB0_18:
	cmp	w22, #2
	b.ne	LBB0_30
; %bb.19:
	ldr	w9, [x19, #12]
Lloh0:
	adrp	x10, _IEEE80211_TX_RC_MCS@GOTPAGE
Lloh1:
	ldr	x10, [x10, _IEEE80211_TX_RC_MCS@GOTPAGEOFF]
Lloh2:
	ldr	w10, [x10]
	tst	w10, w9
	b.ne	LBB0_29
; %bb.20:
	ldr	x11, [x19]
	cmp	x11, #5
	b.lt	LBB0_29
; %bb.21:
	ldr	w13, [x8]
	subs	w9, w13, #3
	b.lo	LBB0_29
; %bb.22:
	mov	x10, x19
	ldr	x12, [x10, #16]!
	cmp	x12, #1
	b.gt	LBB0_29
; %bb.23:
	add	x11, x11, #4
	lsr	x12, x11, #1
	sub	w11, w13, #2
	str	w11, [x8]
	cmp	w12, #4
	b.ne	LBB0_36
; %bb.24:
	ldr	q0, [x10]
	str	q0, [x19, #32]
	mov	w8, #4
	str	x8, [x19, #16]
	add	x10, x19, #24
	mov	w22, #3
	b	LBB0_38
LBB0_25:
	cmp	x22, #1
	csinc	x10, x22, xzr, hi
	add	x12, x19, #8
	neg	w9, w9
	b	LBB0_27
LBB0_26:                                ;   in Loop: Header=BB0_27 Depth=1
	sub	w11, w11, w13
	add	x12, x12, #16
	add	w9, w9, #1
	subs	x10, x10, #1
	b.eq	LBB0_18
LBB0_27:                                ; =>This Inner Loop Header: Depth=1
	ldr	w13, [x12]
	add	w14, w11, w9
	cmp	w13, w14
	b.ls	LBB0_26
; %bb.28:                               ;   in Loop: Header=BB0_27 Depth=1
	str	w14, [x12]
	mov	x13, x14
	b	LBB0_26
LBB0_29:
	mov	w22, #2
LBB0_30:
	mov	x0, x21
	mov	x1, x19
	bl	_cw1200_get_tx_rate
	ldr	w8, [x0]
	add	w8, w8, #1
	str	w8, [x20]
	cbz	x22, LBB0_35
; %bb.31:
	mov	x24, x22
	mov	x23, x19
	b	LBB0_33
LBB0_32:                                ;   in Loop: Header=BB0_33 Depth=1
	lsr	x26, x8, #3
	ubfiz	w8, w8, #2, #3
	lsl	w0, w25, w8
	bl	___cpu_to_le32
	ldr	x8, [x20, #8]
	lsl	x9, x26, #2
	ldr	w10, [x8, x9]
	orr	w10, w10, w0
	str	w10, [x8, x9]
	ldr	w8, [x20, #4]
	add	w8, w8, w25
	str	w8, [x20, #4]
	add	x23, x23, #16
	subs	x24, x24, #1
	b.eq	LBB0_35
LBB0_33:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	mov	x1, x23
	bl	_cw1200_get_tx_rate
	ldr	w8, [x0]
	ldr	w25, [x23, #8]
	cmp	w25, #16
	b.lo	LBB0_32
; %bb.34:                               ;   in Loop: Header=BB0_33 Depth=1
	mov	w25, #15
	str	w25, [x23, #8]
	b	LBB0_32
LBB0_35:
	ldr	w2, [x19]
	ldr	w3, [x19, #8]
	ldr	w4, [x19, #16]
	ldr	w5, [x19, #24]
	ldr	w6, [x19, #32]
	ldr	w7, [x19, #40]
	ldr	x8, [x19, #48]
	ldr	w9, [x19, #56]
	stp	w8, w9, [sp]
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x22
	bl	_pr_debug
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_36:
	ldr	q0, [x10]
	mov	w13, #1
	mov	x10, x19
	str	w13, [x10, #40]!
	stur	q0, [x10, #8]
	mov	w22, #4
	stur	x22, [x10, #-8]
	ldur	w14, [x10, #-12]
	str	w14, [x10, #4]
	sxtw	x12, w12
	stur	x12, [x10, #-24]
	stur	w13, [x10, #-16]
	cmp	w11, #3
	b.lo	LBB0_30
; %bb.37:
	str	w9, [x8]
	mov	w22, #4
LBB0_38:
	mov	w8, #2
	str	w8, [x10]
	b	LBB0_30
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_IEEE80211_TX_RC_MCS,4,2        ; @IEEE80211_TX_RC_MCS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"[TX policy] Policy (%zu): %d:%d, %d:%d, %d:%d, %d:%d\n"

	.no_dead_strip	_tx_policy_build
.subsections_via_symbols
