	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function rtl8723e_phy_iq_calibrate
LCPI0_0:
	.quad	256                             ## 0x100
	.quad	0                               ## 0x0
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_rtl8723e_phy_iq_calibrate
	.p2align	4, 0x90
_rtl8723e_phy_iq_calibrate:             ## @rtl8723e_phy_iq_calibrate
	.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	$312, %rsp                      ## imm = 0x138
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movq	%rdi, %r13
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_rtl_priv
	movq	%rax, %r14
	movq	_ROFDM0_XARXIQIMBALANCE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -352(%rbp)
	movq	_ROFDM0_XBRXIQIMBALANCE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -348(%rbp)
	movq	_ROFDM0_ECCATHRESHOLD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -344(%rbp)
	movq	_ROFDM0_AGCRSSITABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -340(%rbp)
	movq	_ROFDM0_XATXIQIMBALANCE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -336(%rbp)
	movq	_ROFDM0_XBTXIQIMBALANCE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -332(%rbp)
	movq	_ROFDM0_XCTXIQIMBALANCE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -328(%rbp)
	movq	_ROFDM0_XCTXAFE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -324(%rbp)
	movq	_ROFDM0_XDTXAFE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -320(%rbp)
	movq	_ROFDM0_RXIQEXTANTA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -316(%rbp)
	testl	%ebx, %ebx
	je	LBB0_1
## %bb.12:
	movl	32(%r14), %edx
	leaq	-352(%rbp), %rsi
	movq	%r13, %rdi
	movl	$10, %ecx
	callq	_rtl8723_phy_reload_adda_registers
	jmp	LBB0_10
LBB0_1:
	pxor	%xmm0, %xmm0
	movdqa	%xmm0, -64(%rbp)
	movdqa	%xmm0, -80(%rbp)
	movdqa	%xmm0, -96(%rbp)
	movdqa	%xmm0, -112(%rbp)
	movdqa	%xmm0, -128(%rbp)
	movdqa	%xmm0, -144(%rbp)
	movdqa	%xmm0, -160(%rbp)
	movdqa	%xmm0, -176(%rbp)
	movdqa	%xmm0, -192(%rbp)
	movdqa	%xmm0, -208(%rbp)
	movdqa	%xmm0, -224(%rbp)
	movdqa	%xmm0, -240(%rbp)
	movdqa	%xmm0, -256(%rbp)
	movdqa	%xmm0, -272(%rbp)
	movdqa	%xmm0, -288(%rbp)
	movdqa	%xmm0, -304(%rbp)
	leaq	-304(%rbp), %rbx
	xorl	%r12d, %r12d
	movq	%r13, %rdi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	__rtl8723e_phy_iq_calibrate
	movl	$1, %r15d
	movq	%r13, %rdi
	movq	%rbx, %rsi
	movl	$1, %edx
	xorl	%ecx, %ecx
	callq	__rtl8723e_phy_iq_calibrate
	movq	%r13, %rdi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	movl	$1, %ecx
	callq	__rtl8723e_phy_simularity_compare
	testl	%eax, %eax
	jne	LBB0_5
## %bb.2:
	leaq	-304(%rbp), %rbx
	xorl	%r12d, %r12d
	movq	%r13, %rdi
	movq	%rbx, %rsi
	movl	$2, %edx
	xorl	%ecx, %ecx
	callq	__rtl8723e_phy_iq_calibrate
	movq	%r13, %rdi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	movl	$2, %ecx
	callq	__rtl8723e_phy_simularity_compare
	testl	%eax, %eax
	jne	LBB0_5
## %bb.3:
	leaq	-304(%rbp), %rsi
	movl	$1, %r12d
	movq	%r13, %rdi
	movl	$1, %edx
	movl	$2, %ecx
	callq	__rtl8723e_phy_simularity_compare
	testl	%eax, %eax
	jne	LBB0_5
## %bb.4:
	movq	-112(%rbp), %rax
	movq	-96(%rbp), %rcx
	movdqu	-72(%rbp), %xmm0
	movdqu	-88(%rbp), %xmm1
	paddq	%xmm0, %xmm1
	pshufd	$238, %xmm1, %xmm0              ## xmm0 = xmm1[2,3,2,3]
	paddq	%xmm1, %xmm0
	movq	%xmm0, %rdx
	addq	-104(%rbp), %rdx
	addq	%rcx, %rdx
	addq	%rax, %rdx
	movl	$3, %r12d
	addq	-56(%rbp), %rdx
	jne	LBB0_5
## %bb.6:
	movq	$256, 16(%r14)                  ## imm = 0x100
	movdqa	LCPI0_0(%rip), %xmm0            ## xmm0 = [256,0]
	movdqu	%xmm0, (%r14)
	xorl	%edx, %edx
	movl	$255, %r12d
	xorl	%r15d, %r15d
	jmp	LBB0_7
LBB0_5:
	movl	%r12d, %edx
	shlq	$6, %rdx
	movq	-304(%rbp,%rdx), %rax
	movq	%rax, (%r14)
	movq	-296(%rbp,%rdx), %rcx
	movq	%rcx, 8(%r14)
	movq	-288(%rbp,%rdx), %rcx
	movq	-272(%rbp,%rdx), %rsi
	movq	%rsi, 16(%r14)
	movq	-264(%rbp,%rdx), %rdx
LBB0_7:
	movq	%rdx, 24(%r14)
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	xorl	%r8d, %r8d
	testq	%rcx, %rcx
	sete	%r8b
	leaq	-304(%rbp), %rdx
	movq	%r13, %rdi
	movl	%r15d, %esi
	movl	%r12d, %ecx
	callq	_rtl8723_phy_path_a_fill_iqk_matrix
LBB0_9:
	movl	32(%r14), %edx
	leaq	-352(%rbp), %rsi
	movq	%r13, %rdi
	movl	$10, %ecx
	callq	_rtl8723_save_adda_registers
LBB0_10:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_11
## %bb.13:
	addq	$312, %rsp                      ## imm = 0x138
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_ROFDM0_XARXIQIMBALANCE,4,2     ## @ROFDM0_XARXIQIMBALANCE
	.comm	_ROFDM0_XBRXIQIMBALANCE,4,2     ## @ROFDM0_XBRXIQIMBALANCE
	.comm	_ROFDM0_ECCATHRESHOLD,4,2       ## @ROFDM0_ECCATHRESHOLD
	.comm	_ROFDM0_AGCRSSITABLE,4,2        ## @ROFDM0_AGCRSSITABLE
	.comm	_ROFDM0_XATXIQIMBALANCE,4,2     ## @ROFDM0_XATXIQIMBALANCE
	.comm	_ROFDM0_XBTXIQIMBALANCE,4,2     ## @ROFDM0_XBTXIQIMBALANCE
	.comm	_ROFDM0_XCTXIQIMBALANCE,4,2     ## @ROFDM0_XCTXIQIMBALANCE
	.comm	_ROFDM0_XCTXAFE,4,2             ## @ROFDM0_XCTXAFE
	.comm	_ROFDM0_XDTXAFE,4,2             ## @ROFDM0_XDTXAFE
	.comm	_ROFDM0_RXIQEXTANTA,4,2         ## @ROFDM0_RXIQEXTANTA
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ; -- Begin function rtl8723e_phy_iq_calibrate
lCPI0_0:
	.quad	256                             ; 0x100
	.quad	0                               ; 0x0
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_rtl8723e_phy_iq_calibrate
	.p2align	2
_rtl8723e_phy_iq_calibrate:             ; @rtl8723e_phy_iq_calibrate
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #384
	.cfi_def_cfa_offset 384
	stp	x28, x27, [sp, #320]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #336]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #352]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #368]            ; 16-byte Folded Spill
	add	x29, sp, #368
	.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 w27, -56
	.cfi_offset w28, -64
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	bl	_rtl_priv
	mov	x20, x0
Lloh3:
	adrp	x8, _ROFDM0_XARXIQIMBALANCE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ROFDM0_XARXIQIMBALANCE@GOTPAGEOFF]
Lloh5:
	adrp	x9, _ROFDM0_XBRXIQIMBALANCE@GOTPAGE
Lloh6:
	ldr	x9, [x9, _ROFDM0_XBRXIQIMBALANCE@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
Lloh8:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #8]
Lloh9:
	adrp	x8, _ROFDM0_ECCATHRESHOLD@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ROFDM0_ECCATHRESHOLD@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
Lloh12:
	adrp	x9, _ROFDM0_AGCRSSITABLE@GOTPAGE
Lloh13:
	ldr	x9, [x9, _ROFDM0_AGCRSSITABLE@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #16]
Lloh15:
	adrp	x8, _ROFDM0_XATXIQIMBALANCE@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ROFDM0_XATXIQIMBALANCE@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
Lloh18:
	adrp	x9, _ROFDM0_XBTXIQIMBALANCE@GOTPAGE
Lloh19:
	ldr	x9, [x9, _ROFDM0_XBTXIQIMBALANCE@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #24]
Lloh21:
	adrp	x8, _ROFDM0_XCTXIQIMBALANCE@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ROFDM0_XCTXIQIMBALANCE@GOTPAGEOFF]
Lloh23:
	adrp	x9, _ROFDM0_XCTXAFE@GOTPAGE
Lloh24:
	ldr	x9, [x9, _ROFDM0_XCTXAFE@GOTPAGEOFF]
Lloh25:
	ldr	w8, [x8]
Lloh26:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #32]
Lloh27:
	adrp	x8, _ROFDM0_XDTXAFE@GOTPAGE
Lloh28:
	ldr	x8, [x8, _ROFDM0_XDTXAFE@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
Lloh30:
	adrp	x9, _ROFDM0_RXIQEXTANTA@GOTPAGE
Lloh31:
	ldr	x9, [x9, _ROFDM0_RXIQEXTANTA@GOTPAGEOFF]
Lloh32:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #40]
	cbz	w21, LBB0_2
; %bb.1:
	ldr	w2, [x20, #32]
	add	x1, sp, #8
	mov	x0, x19
	mov	w3, #10
	bl	_rtl8723_phy_reload_adda_registers
	b	LBB0_12
LBB0_2:
	add	x8, sp, #48
	movi.2d	v0, #0000000000000000
	stp	q0, q0, [x8, #224]
	stp	q0, q0, [x8, #192]
	stp	q0, q0, [x8, #160]
	stp	q0, q0, [x8, #128]
	stp	q0, q0, [x8, #96]
	stp	q0, q0, [sp, #112]
	stp	q0, q0, [sp, #80]
	stp	q0, q0, [sp, #48]
	add	x22, sp, #48
	add	x1, sp, #48
	mov	x0, x19
	mov	w2, #0
	mov	w3, #0
	bl	__rtl8723e_phy_iq_calibrate
	add	x1, sp, #48
	mov	x0, x19
	mov	w2, #1
	mov	w3, #0
	bl	__rtl8723e_phy_iq_calibrate
	add	x1, sp, #48
	mov	x0, x19
	mov	w2, #0
	mov	w3, #1
	bl	__rtl8723e_phy_simularity_compare
	cbnz	w0, LBB0_8
; %bb.3:
	add	x1, sp, #48
	mov	x0, x19
	mov	w2, #2
	mov	w3, #0
	bl	__rtl8723e_phy_iq_calibrate
	add	x1, sp, #48
	mov	x0, x19
	mov	w2, #0
	mov	w3, #2
	bl	__rtl8723e_phy_simularity_compare
	mov	w21, #0
	cbnz	w0, LBB0_8
; %bb.4:
	mov	w21, #1
	add	x1, sp, #48
	mov	x0, x19
	mov	w2, #1
	mov	w3, #2
	bl	__rtl8723e_phy_simularity_compare
	cbnz	w0, LBB0_8
; %bb.5:
	ldp	x8, x10, [sp, #240]
	ldp	x9, x11, [sp, #256]
	add	x10, x10, x8
	add	x10, x9, x10
	ldp	x12, x13, [sp, #272]
	add	x10, x11, x10
	add	x10, x12, x10
	ldp	x11, x12, [sp, #288]
	add	x10, x13, x10
	add	x10, x11, x10
	cmn	x12, x10
	b.ne	LBB0_7
; %bb.6:
	mov	x10, #0
	mov	w1, #0
	mov	w11, #256
	str	x11, [x20, #16]
Lloh33:
	adrp	x11, lCPI0_0@PAGE
Lloh34:
	ldr	q0, [x11, lCPI0_0@PAGEOFF]
	str	q0, [x20]
	mov	w21, #255
	b	LBB0_9
LBB0_7:
	mov	w21, #3
LBB0_8:
	mov	w8, w21
	add	x10, x22, x8, lsl #6
	ldr	x8, [x10]
	str	x8, [x20]
	ldr	x9, [x10, #8]
	str	x9, [x20, #8]
	ldr	x9, [x10, #16]
	ldr	x11, [x10, #32]
	str	x11, [x20, #16]
	ldr	x10, [x10, #40]
	mov	w1, #1
LBB0_9:
	str	x10, [x20, #24]
	cbz	x8, LBB0_11
; %bb.10:
	cmp	x9, #0
	cset	w4, eq
	add	x2, sp, #48
	mov	x0, x19
	mov	x3, x21
	bl	_rtl8723_phy_path_a_fill_iqk_matrix
LBB0_11:
	ldr	w2, [x20, #32]
	add	x1, sp, #8
	mov	x0, x19
	mov	w3, #10
	bl	_rtl8723_save_adda_registers
LBB0_12:
	ldur	x8, [x29, #-56]
Lloh35:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh36:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh37:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.13:
	ldp	x29, x30, [sp, #368]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #352]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #336]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #320]            ; 16-byte Folded Reload
	add	sp, sp, #384
	ret
LBB0_14:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh25
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdr	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.cfi_endproc
                                        ; -- End function
	.comm	_ROFDM0_XARXIQIMBALANCE,4,2     ; @ROFDM0_XARXIQIMBALANCE
	.comm	_ROFDM0_XBRXIQIMBALANCE,4,2     ; @ROFDM0_XBRXIQIMBALANCE
	.comm	_ROFDM0_ECCATHRESHOLD,4,2       ; @ROFDM0_ECCATHRESHOLD
	.comm	_ROFDM0_AGCRSSITABLE,4,2        ; @ROFDM0_AGCRSSITABLE
	.comm	_ROFDM0_XATXIQIMBALANCE,4,2     ; @ROFDM0_XATXIQIMBALANCE
	.comm	_ROFDM0_XBTXIQIMBALANCE,4,2     ; @ROFDM0_XBTXIQIMBALANCE
	.comm	_ROFDM0_XCTXIQIMBALANCE,4,2     ; @ROFDM0_XCTXIQIMBALANCE
	.comm	_ROFDM0_XCTXAFE,4,2             ; @ROFDM0_XCTXAFE
	.comm	_ROFDM0_XDTXAFE,4,2             ; @ROFDM0_XDTXAFE
	.comm	_ROFDM0_RXIQEXTANTA,4,2         ; @ROFDM0_RXIQEXTANTA
.subsections_via_symbols
