	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wlc_phy_rssi_compute_nphy      ## -- Begin function wlc_phy_rssi_compute_nphy
	.p2align	4, 0x90
_wlc_phy_rssi_compute_nphy:             ## @wlc_phy_rssi_compute_nphy
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movl	(%rsi), %eax
	movq	_PRXS1_nphy_PWR0_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	%eax, %ecx
	movq	_PRXS1_nphy_PWR1_MASK@GOTPCREL(%rip), %rdx
	andl	(%rdx), %eax
	movl	%eax, %edx
	sarl	$8, %edx
	leal	-256(%rcx), %r8d
	cmpl	$127, %ecx
	cmovlel	%ecx, %r8d
	leal	-256(%rdx), %ecx
	cmpl	$32768, %eax                    ## imm = 0x8000
	cmovll	%edx, %ecx
	movzbl	8(%rsi), %eax
	xorl	%edx, %edx
	cmpl	$128, %eax
	setb	%dl
	shll	$8, %edx
	leal	-16(%r8), %esi
	testl	$-17, %esi
	cmovel	%ecx, %r8d
	leal	-256(%rdx,%rax), %eax
	cmovnel	%ecx, %eax
	movq	(%rdi), %rcx
	movq	(%rcx), %rsi
	movq	_RSSI_ANT_MERGE_MAX@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rsi
	jne	LBB0_1
## %bb.5:
	cmpl	%eax, %r8d
	cmovgl	%r8d, %eax
	popq	%rbp
	retq
LBB0_1:
	movq	_RSSI_ANT_MERGE_MIN@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rsi
	jne	LBB0_2
## %bb.6:
	cmpl	%eax, %r8d
	cmovll	%r8d, %eax
	popq	%rbp
	retq
LBB0_2:
	movq	_RSSI_ANT_MERGE_AVG@GOTPCREL(%rip), %rdx
	xorl	%ecx, %ecx
	cmpq	(%rdx), %rsi
	jne	LBB0_4
## %bb.3:
	addl	%r8d, %eax
	sarl	%eax
	movl	%eax, %ecx
LBB0_4:
	movl	%ecx, %eax
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PRXS1_nphy_PWR0_MASK,4,2       ## @PRXS1_nphy_PWR0_MASK
	.comm	_PRXS1_nphy_PWR1_MASK,4,2       ## @PRXS1_nphy_PWR1_MASK
	.comm	_RSSI_ANT_MERGE_MAX,8,3         ## @RSSI_ANT_MERGE_MAX
	.comm	_RSSI_ANT_MERGE_MIN,8,3         ## @RSSI_ANT_MERGE_MIN
	.comm	_RSSI_ANT_MERGE_AVG,8,3         ## @RSSI_ANT_MERGE_AVG
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wlc_phy_rssi_compute_nphy      ; -- Begin function wlc_phy_rssi_compute_nphy
	.p2align	2
_wlc_phy_rssi_compute_nphy:             ; @wlc_phy_rssi_compute_nphy
	.cfi_startproc
; %bb.0:
Lloh0:
	adrp	x8, _PRXS1_nphy_PWR0_MASK@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PRXS1_nphy_PWR0_MASK@GOTPAGEOFF]
	ldr	w9, [x1]
Lloh2:
	ldr	w8, [x8]
	and	w8, w8, w9
Lloh3:
	adrp	x10, _PRXS1_nphy_PWR1_MASK@GOTPAGE
Lloh4:
	ldr	x10, [x10, _PRXS1_nphy_PWR1_MASK@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
	and	w9, w10, w9
	asr	w10, w9, #8
	sub	w11, w8, #256
	cmp	w8, #127
	csel	w8, w11, w8, gt
	sub	w11, w10, #256
	cmp	w9, #8, lsl #12                 ; =32768
	csel	w9, w11, w10, ge
	ldrb	w10, [x1, #8]
	mov	w11, #-256
	cmp	w10, #127
	csel	w11, w11, wzr, hi
	orr	w10, w11, w10
	cmp	w8, #16
	mov	w11, #32
	ccmp	w8, w11, #4, ne
	csel	w8, w9, w8, eq
	csel	w9, w10, w9, eq
	ldr	x10, [x0]
	ldr	x10, [x10]
Lloh6:
	adrp	x11, _RSSI_ANT_MERGE_MAX@GOTPAGE
Lloh7:
	ldr	x11, [x11, _RSSI_ANT_MERGE_MAX@GOTPAGEOFF]
Lloh8:
	ldr	x11, [x11]
	cmp	x10, x11
	b.ne	LBB0_2
; %bb.1:
	cmp	w8, w9
	csel	w0, w8, w9, gt
	ret
LBB0_2:
Lloh9:
	adrp	x11, _RSSI_ANT_MERGE_MIN@GOTPAGE
Lloh10:
	ldr	x11, [x11, _RSSI_ANT_MERGE_MIN@GOTPAGEOFF]
Lloh11:
	ldr	x11, [x11]
	cmp	x10, x11
	b.ne	LBB0_4
; %bb.3:
	cmp	w8, w9
	csel	w0, w8, w9, lt
	ret
LBB0_4:
Lloh12:
	adrp	x11, _RSSI_ANT_MERGE_AVG@GOTPAGE
Lloh13:
	ldr	x11, [x11, _RSSI_ANT_MERGE_AVG@GOTPAGEOFF]
Lloh14:
	ldr	x11, [x11]
	cmp	x10, x11
	b.ne	LBB0_6
; %bb.5:
	add	w8, w9, w8
	asr	w0, w8, #1
	ret
LBB0_6:
	mov	w0, #0
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_PRXS1_nphy_PWR0_MASK,4,2       ; @PRXS1_nphy_PWR0_MASK
	.comm	_PRXS1_nphy_PWR1_MASK,4,2       ; @PRXS1_nphy_PWR1_MASK
	.comm	_RSSI_ANT_MERGE_MAX,8,3         ; @RSSI_ANT_MERGE_MAX
	.comm	_RSSI_ANT_MERGE_MIN,8,3         ; @RSSI_ANT_MERGE_MIN
	.comm	_RSSI_ANT_MERGE_AVG,8,3         ; @RSSI_ANT_MERGE_AVG
.subsections_via_symbols
