	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function htcp_recalc_alpha
_htcp_recalc_alpha:                     ## @htcp_recalc_alpha
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	(%rdi), %r12
	movq	_ticks@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r12), %eax
	cmpl	%eax, %edi
	jge	LBB0_2
## %bb.1:
	movq	_HTCP_DELTA_L@GOTPCREL(%rip), %rcx
	movl	%edi, %eax
	subl	(%rcx), %eax
	movl	%eax, (%r12)
LBB0_2:
	movq	_HTCP_DELTA_L@GOTPCREL(%rip), %rcx
	addl	(%rcx), %eax
	subl	%eax, %edi
	movq	_htcp_max_diff@GOTPCREL(%rip), %rax
	cmpl	(%rax), %edi
	jge	LBB0_10
## %bb.3:
	testl	%edi, %edi
	jle	LBB0_4
## %bb.5:
	callq	_HTCP_CALC_ALPHA
	movl	%eax, %ebx
	movq	_V_htcp_adaptive_backoff@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_7
## %bb.6:
	movq	_HTCP_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	movl	$1, %eax
	shll	%cl, %eax
	subl	4(%r12), %eax
	imull	%eax, %ebx
	addl	%ebx, %ebx
	sarl	%cl, %ebx
	movl	$1, %edi
	movl	%ebx, %esi
	callq	_max
	movl	%eax, %ebx
LBB0_7:
	movq	_V_htcp_rtt_scaling@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_9
## %bb.8:
	movq	_HTCP_MINROWE@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	_t_srtt@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_CCV
	movq	_HTCP_SHIFT@GOTPCREL(%rip), %r14
	movb	(%r14), %cl
	shll	%cl, %eax
	movq	_htcp_rtt_ref@GOTPCREL(%rip), %rcx
	cltd
	idivl	(%rcx)
	movl	%r15d, %edi
	movl	%eax, %esi
	callq	_max
	movq	_HTCP_MAXROWE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	%eax, %edi
	callq	_min
	imull	%eax, %ebx
	movb	(%r14), %cl
	sarl	%cl, %ebx
	movl	$1, %edi
	movl	%ebx, %esi
	callq	_max
	movl	%eax, %ebx
	jmp	LBB0_9
LBB0_4:
	movl	$1, %ebx
LBB0_9:
	movl	%ebx, 8(%r12)
LBB0_10:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ticks,4,2                      ## @ticks
	.comm	_HTCP_DELTA_L,4,2               ## @HTCP_DELTA_L
	.comm	_htcp_max_diff,4,2              ## @htcp_max_diff
	.comm	_V_htcp_adaptive_backoff,8,3    ## @V_htcp_adaptive_backoff
	.comm	_HTCP_SHIFT,4,2                 ## @HTCP_SHIFT
	.comm	_V_htcp_rtt_scaling,8,3         ## @V_htcp_rtt_scaling
	.comm	_HTCP_MINROWE,4,2               ## @HTCP_MINROWE
	.comm	_t_srtt,4,2                     ## @t_srtt
	.comm	_htcp_rtt_ref,4,2               ## @htcp_rtt_ref
	.comm	_HTCP_MAXROWE,4,2               ## @HTCP_MAXROWE
	.no_dead_strip	_htcp_recalc_alpha
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function htcp_recalc_alpha
_htcp_recalc_alpha:                     ; @htcp_recalc_alpha
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, _ticks@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ticks@GOTPAGEOFF]
	ldr	x22, [x0]
Lloh2:
	ldr	w8, [x8]
	ldr	w9, [x22]
Lloh3:
	adrp	x10, _HTCP_DELTA_L@GOTPAGE
Lloh4:
	ldr	x10, [x10, _HTCP_DELTA_L@GOTPAGEOFF]
	cmp	w8, w9
	b.ge	LBB0_2
; %bb.1:
	ldr	w9, [x10]
	sub	w9, w8, w9
	str	w9, [x22]
LBB0_2:
	ldr	w10, [x10]
	add	w9, w9, w10
	sub	w0, w8, w9
Lloh5:
	adrp	x8, _htcp_max_diff@GOTPAGE
Lloh6:
	ldr	x8, [x8, _htcp_max_diff@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ge	LBB0_10
; %bb.3:
	cmp	w0, #1
	b.lt	LBB0_8
; %bb.4:
	bl	_HTCP_CALC_ALPHA
	mov	x20, x0
Lloh8:
	adrp	x8, _V_htcp_adaptive_backoff@GOTPAGE
Lloh9:
	ldr	x8, [x8, _V_htcp_adaptive_backoff@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
Lloh11:
	adrp	x23, _HTCP_SHIFT@GOTPAGE
Lloh12:
	ldr	x23, [x23, _HTCP_SHIFT@GOTPAGEOFF]
	cbz	x8, LBB0_6
; %bb.5:
	ldr	w8, [x23]
	mov	w9, #1
	lsl	w9, w9, w8
	ldr	w10, [x22, #4]
	sub	w9, w9, w10
	mul	w9, w20, w9
	lsl	w9, w9, #1
	asr	w1, w9, w8
	mov	w0, #1
	bl	_max
	mov	x20, x0
LBB0_6:
Lloh13:
	adrp	x8, _V_htcp_rtt_scaling@GOTPAGE
Lloh14:
	ldr	x8, [x8, _V_htcp_rtt_scaling@GOTPAGEOFF]
Lloh15:
	ldr	x8, [x8]
	cbz	x8, LBB0_9
; %bb.7:
Lloh16:
	adrp	x8, _HTCP_MINROWE@GOTPAGE
Lloh17:
	ldr	x8, [x8, _HTCP_MINROWE@GOTPAGEOFF]
Lloh18:
	ldr	w21, [x8]
Lloh19:
	adrp	x8, _t_srtt@GOTPAGE
Lloh20:
	ldr	x8, [x8, _t_srtt@GOTPAGEOFF]
Lloh21:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_CCV
	ldr	w8, [x23]
	lsl	w8, w0, w8
Lloh22:
	adrp	x9, _htcp_rtt_ref@GOTPAGE
Lloh23:
	ldr	x9, [x9, _htcp_rtt_ref@GOTPAGEOFF]
Lloh24:
	ldr	w9, [x9]
	sdiv	w1, w8, w9
	mov	x0, x21
	bl	_max
Lloh25:
	adrp	x8, _HTCP_MAXROWE@GOTPAGE
Lloh26:
	ldr	x8, [x8, _HTCP_MAXROWE@GOTPAGEOFF]
Lloh27:
	ldr	w1, [x8]
	bl	_min
	mul	w8, w0, w20
	ldr	w9, [x23]
	asr	w1, w8, w9
	mov	w0, #1
	bl	_max
	mov	x20, x0
	b	LBB0_9
LBB0_8:
	mov	w20, #1
LBB0_9:
	str	w20, [x22, #8]
LBB0_10:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_ticks,4,2                      ; @ticks
	.comm	_HTCP_DELTA_L,4,2               ; @HTCP_DELTA_L
	.comm	_htcp_max_diff,4,2              ; @htcp_max_diff
	.comm	_V_htcp_adaptive_backoff,8,3    ; @V_htcp_adaptive_backoff
	.comm	_HTCP_SHIFT,4,2                 ; @HTCP_SHIFT
	.comm	_V_htcp_rtt_scaling,8,3         ; @V_htcp_rtt_scaling
	.comm	_HTCP_MINROWE,4,2               ; @HTCP_MINROWE
	.comm	_t_srtt,4,2                     ; @t_srtt
	.comm	_htcp_rtt_ref,4,2               ; @htcp_rtt_ref
	.comm	_HTCP_MAXROWE,4,2               ; @HTCP_MAXROWE
	.no_dead_strip	_htcp_recalc_alpha
.subsections_via_symbols
