	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sctp_autoclose_timer           ## -- Begin function sctp_autoclose_timer
	.p2align	4, 0x90
_sctp_autoclose_timer:                  ## @sctp_autoclose_timer
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %rbx
	movq	%rdi, %r14
	leaq	-40(%rbp), %rdi
	callq	_SCTP_GETTIME_TIMEVAL
	cmpl	$0, 8(%rbx)
	je	LBB0_14
## %bb.1:
	movq	_SCTP_PCB_FLAGS_AUTOCLOSE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_sctp_is_feature_on
	testq	%rax, %rax
	je	LBB0_14
## %bb.2:
	leaq	48(%rbx), %rax
	movq	48(%rbx), %rcx
	leaq	40(%rbx), %rdx
	cmpq	40(%rbx), %rcx
	cmovgq	%rax, %rdx
	movq	-40(%rbp), %rdi
	subq	(%rdx), %rdi
	callq	_SEC_TO_TICKS
	movl	8(%rbx), %r12d
	testl	%eax, %eax
	jle	LBB0_13
## %bb.3:
	cmpl	%eax, %r12d
	jg	LBB0_13
## %bb.4:
	movq	_SCTP_OUTPUT_FROM_AUTOCLOSE_TMR@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_SCTP_SO_NOT_LOCKED@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_sctp_chunk_output
	leaq	36(%rbx), %rdi
	callq	_TAILQ_EMPTY
	testq	%rax, %rax
	je	LBB0_14
## %bb.5:
	leaq	32(%rbx), %rdi
	callq	_TAILQ_EMPTY
	testq	%rax, %rax
	je	LBB0_14
## %bb.6:
	movq	%rbx, %rdi
	callq	_SCTP_GET_STATE
	movq	_SCTP_STATE_SHUTDOWN_SENT@GOTPCREL(%rip), %r14
	cmpq	(%r14), %rax
	je	LBB0_14
## %bb.7:
	movq	%rbx, %rdi
	callq	_SCTP_GET_STATE
	movq	_SCTP_STATE_OPEN@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_9
## %bb.8:
	movq	%rbx, %rdi
	callq	_SCTP_GET_STATE
	movq	_SCTP_STATE_SHUTDOWN_RECEIVED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_10
LBB0_9:
	movq	_sctps_currestab@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_SCTP_STAT_DECR_GAUGE32
LBB0_10:
	movq	(%r14), %rsi
	movq	%rbx, %rdi
	callq	_SCTP_SET_STATE
	movq	%rbx, %rdi
	callq	_sctp_stop_timers_for_shutdown
	movq	24(%rbx), %r14
	testq	%r14, %r14
	jne	LBB0_12
## %bb.11:
	movq	16(%rbx), %r14
LBB0_12:
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	_sctp_send_shutdown
	movq	_SCTP_TIMER_TYPE_SHUTDOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	(%rbx), %rsi
	movq	%rbx, %rdx
	movq	%r14, %rcx
	callq	_sctp_timer_start
	movq	_SCTP_TIMER_TYPE_SHUTDOWNGUARD@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	(%rbx), %rsi
	movq	%rbx, %rdx
	movq	%r14, %rcx
	callq	_sctp_timer_start
	jmp	LBB0_14
LBB0_13:
	movl	%r12d, %ecx
	subl	%eax, %ecx
	movl	%ecx, 8(%rbx)
	movq	_SCTP_TIMER_TYPE_AUTOCLOSE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	movq	%rbx, %rdx
	movq	%r15, %rcx
	callq	_sctp_timer_start
	movl	%r12d, 8(%rbx)
LBB0_14:
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SCTP_PCB_FLAGS_AUTOCLOSE,4,2   ## @SCTP_PCB_FLAGS_AUTOCLOSE
	.comm	_SCTP_OUTPUT_FROM_AUTOCLOSE_TMR,4,2 ## @SCTP_OUTPUT_FROM_AUTOCLOSE_TMR
	.comm	_SCTP_SO_NOT_LOCKED,4,2         ## @SCTP_SO_NOT_LOCKED
	.comm	_SCTP_STATE_SHUTDOWN_SENT,8,3   ## @SCTP_STATE_SHUTDOWN_SENT
	.comm	_SCTP_STATE_OPEN,8,3            ## @SCTP_STATE_OPEN
	.comm	_SCTP_STATE_SHUTDOWN_RECEIVED,8,3 ## @SCTP_STATE_SHUTDOWN_RECEIVED
	.comm	_sctps_currestab,4,2            ## @sctps_currestab
	.comm	_SCTP_TIMER_TYPE_SHUTDOWN,4,2   ## @SCTP_TIMER_TYPE_SHUTDOWN
	.comm	_SCTP_TIMER_TYPE_SHUTDOWNGUARD,4,2 ## @SCTP_TIMER_TYPE_SHUTDOWNGUARD
	.comm	_SCTP_TIMER_TYPE_AUTOCLOSE,4,2  ## @SCTP_TIMER_TYPE_AUTOCLOSE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sctp_autoclose_timer           ; -- Begin function sctp_autoclose_timer
	.p2align	2
_sctp_autoclose_timer:                  ; @sctp_autoclose_timer
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x21, x2
	mov	x19, x1
	mov	x20, x0
	add	x0, sp, #8
	bl	_SCTP_GETTIME_TIMEVAL
	ldr	w8, [x19, #8]
	cbz	w8, LBB0_13
; %bb.1:
Lloh0:
	adrp	x8, _SCTP_PCB_FLAGS_AUTOCLOSE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SCTP_PCB_FLAGS_AUTOCLOSE@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_sctp_is_feature_on
	cbz	x0, LBB0_13
; %bb.2:
	mov	x22, x19
	ldr	x8, [x22, #40]!
	mov	x9, x22
	ldr	x10, [x9, #8]!
	cmp	x10, x8
	csel	x8, x9, x22, gt
	ldr	x9, [sp, #8]
	ldr	x8, [x8]
	sub	x0, x9, x8
	bl	_SEC_TO_TICKS
	ldur	w22, [x22, #-32]
	cmp	w0, #1
	ccmp	w22, w0, #0, ge
	b.le	LBB0_4
; %bb.3:
	sub	w8, w22, w0
	str	w8, [x19, #8]
Lloh3:
	adrp	x8, _SCTP_TIMER_TYPE_AUTOCLOSE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SCTP_TIMER_TYPE_AUTOCLOSE@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	mov	x1, x20
	mov	x2, x19
	mov	x3, x21
	bl	_sctp_timer_start
	str	w22, [x19, #8]
	b	LBB0_13
LBB0_4:
Lloh6:
	adrp	x8, _SCTP_OUTPUT_FROM_AUTOCLOSE_TMR@GOTPAGE
Lloh7:
	ldr	x8, [x8, _SCTP_OUTPUT_FROM_AUTOCLOSE_TMR@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
Lloh9:
	adrp	x8, _SCTP_SO_NOT_LOCKED@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SCTP_SO_NOT_LOCKED@GOTPAGEOFF]
Lloh11:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x19
	bl	_sctp_chunk_output
	add	x0, x19, #36
	bl	_TAILQ_EMPTY
	cbz	x0, LBB0_13
; %bb.5:
	add	x0, x19, #32
	bl	_TAILQ_EMPTY
	cbz	x0, LBB0_13
; %bb.6:
	mov	x0, x19
	bl	_SCTP_GET_STATE
Lloh12:
	adrp	x20, _SCTP_STATE_SHUTDOWN_SENT@GOTPAGE
Lloh13:
	ldr	x20, [x20, _SCTP_STATE_SHUTDOWN_SENT@GOTPAGEOFF]
	ldr	x8, [x20]
	cmp	x0, x8
	b.eq	LBB0_13
; %bb.7:
	mov	x0, x19
	bl	_SCTP_GET_STATE
Lloh14:
	adrp	x8, _SCTP_STATE_OPEN@GOTPAGE
Lloh15:
	ldr	x8, [x8, _SCTP_STATE_OPEN@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	cmp	x0, x8
	b.eq	LBB0_9
; %bb.8:
	mov	x0, x19
	bl	_SCTP_GET_STATE
Lloh17:
	adrp	x8, _SCTP_STATE_SHUTDOWN_RECEIVED@GOTPAGE
Lloh18:
	ldr	x8, [x8, _SCTP_STATE_SHUTDOWN_RECEIVED@GOTPAGEOFF]
Lloh19:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_10
LBB0_9:
Lloh20:
	adrp	x8, _sctps_currestab@GOTPAGE
Lloh21:
	ldr	x8, [x8, _sctps_currestab@GOTPAGEOFF]
Lloh22:
	ldr	w0, [x8]
	bl	_SCTP_STAT_DECR_GAUGE32
LBB0_10:
	ldr	x1, [x20]
	mov	x0, x19
	bl	_SCTP_SET_STATE
	mov	x0, x19
	bl	_sctp_stop_timers_for_shutdown
	ldr	x20, [x19, #24]
	cbnz	x20, LBB0_12
; %bb.11:
	ldr	x20, [x19, #16]
LBB0_12:
	mov	x0, x19
	mov	x1, x20
	bl	_sctp_send_shutdown
Lloh23:
	adrp	x8, _SCTP_TIMER_TYPE_SHUTDOWN@GOTPAGE
Lloh24:
	ldr	x8, [x8, _SCTP_TIMER_TYPE_SHUTDOWN@GOTPAGEOFF]
Lloh25:
	ldr	w0, [x8]
	ldr	x1, [x19]
	mov	x2, x19
	mov	x3, x20
	bl	_sctp_timer_start
Lloh26:
	adrp	x8, _SCTP_TIMER_TYPE_SHUTDOWNGUARD@GOTPAGE
Lloh27:
	ldr	x8, [x8, _SCTP_TIMER_TYPE_SHUTDOWNGUARD@GOTPAGEOFF]
Lloh28:
	ldr	w0, [x8]
	ldr	x1, [x19]
	mov	x2, x19
	mov	x3, x20
	bl	_sctp_timer_start
LBB0_13:
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_SCTP_PCB_FLAGS_AUTOCLOSE,4,2   ; @SCTP_PCB_FLAGS_AUTOCLOSE
	.comm	_SCTP_OUTPUT_FROM_AUTOCLOSE_TMR,4,2 ; @SCTP_OUTPUT_FROM_AUTOCLOSE_TMR
	.comm	_SCTP_SO_NOT_LOCKED,4,2         ; @SCTP_SO_NOT_LOCKED
	.comm	_SCTP_STATE_SHUTDOWN_SENT,8,3   ; @SCTP_STATE_SHUTDOWN_SENT
	.comm	_SCTP_STATE_OPEN,8,3            ; @SCTP_STATE_OPEN
	.comm	_SCTP_STATE_SHUTDOWN_RECEIVED,8,3 ; @SCTP_STATE_SHUTDOWN_RECEIVED
	.comm	_sctps_currestab,4,2            ; @sctps_currestab
	.comm	_SCTP_TIMER_TYPE_SHUTDOWN,4,2   ; @SCTP_TIMER_TYPE_SHUTDOWN
	.comm	_SCTP_TIMER_TYPE_SHUTDOWNGUARD,4,2 ; @SCTP_TIMER_TYPE_SHUTDOWNGUARD
	.comm	_SCTP_TIMER_TYPE_AUTOCLOSE,4,2  ; @SCTP_TIMER_TYPE_AUTOCLOSE
.subsections_via_symbols
