	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sctp_set_prsctp_policy
_sctp_set_prsctp_policy:                ## @sctp_set_prsctp_policy
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movl	16(%rdi), %edi
	callq	_PR_SCTP_ENABLED
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movl	16(%rbx), %edi
	jmp	LBB0_4
LBB0_2:
	cmpq	$0, 8(%rbx)
	jle	LBB0_10
## %bb.3:
	movq	_SCTP_PR_SCTP_TTL@GOTPCREL(%rip), %rax
	movl	16(%rbx), %edi
	orl	(%rax), %edi
	movl	%edi, 16(%rbx)
LBB0_4:
	callq	_PR_SCTP_POLICY
	orl	%eax, (%rbx)
	movl	16(%rbx), %edi
	callq	_PR_SCTP_POLICY
	cmpl	$128, %eax
	je	LBB0_9
## %bb.5:
	cmpl	$129, %eax
	je	LBB0_7
## %bb.6:
	cmpl	$130, %eax
	jne	LBB0_8
LBB0_7:
	movq	8(%rbx), %rax
	movq	%rax, 24(%rbx)
	movl	$0, 32(%rbx)
	jmp	LBB0_10
LBB0_9:
	leaq	24(%rbx), %r14
	movq	%r14, %rdi
	callq	_SCTP_GETTIME_TIMEVAL
	movq	8(%rbx), %rcx
	movabsq	$2361183241434822607, %rdx      ## imm = 0x20C49BA5E353F7CF
	movq	%rcx, %rax
	imulq	%rdx
	movq	%rdx, %rax
	shrq	$63, %rax
	shrq	$7, %rdx
	addl	%eax, %edx
	movl	%edx, -24(%rbp)
	imulq	$1000, %rcx, %rcx               ## imm = 0x3E8
	movabsq	$4835703278458516699, %rdx      ## imm = 0x431BDE82D7B634DB
	movq	%rcx, %rax
	imulq	%rdx
	movq	%rdx, %rax
	shrq	$63, %rax
	shrq	$18, %rdx
	addl	%eax, %edx
	imull	$1000000, %edx, %eax            ## imm = 0xF4240
	subl	%eax, %ecx
	movl	%ecx, -20(%rbp)
	leaq	-24(%rbp), %rsi
	movq	%r14, %rdi
	callq	_timevaladd
LBB0_10:
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_8:
	movq	_SCTP_DEBUG_USRREQ1@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	16(%rbx), %edi
	callq	_PR_SCTP_POLICY
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edi
	movl	%eax, %edx
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_SCTPDBG                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_SCTP_PR_SCTP_TTL,4,2           ## @SCTP_PR_SCTP_TTL
	.comm	_SCTP_DEBUG_USRREQ1,4,2         ## @SCTP_DEBUG_USRREQ1
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Unknown PR_SCTP policy %u.\n"

	.no_dead_strip	_sctp_set_prsctp_policy
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sctp_set_prsctp_policy
_sctp_set_prsctp_policy:                ; @sctp_set_prsctp_policy
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldr	w0, [x0, #16]
	bl	_PR_SCTP_ENABLED
	cbz	x0, LBB0_2
; %bb.1:
	ldr	w0, [x19, #16]
	b	LBB0_4
LBB0_2:
	ldr	x8, [x19, #8]
	cmp	x8, #1
	b.lt	LBB0_9
; %bb.3:
Lloh0:
	adrp	x8, _SCTP_PR_SCTP_TTL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SCTP_PR_SCTP_TTL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	w9, [x19, #16]
	orr	w0, w9, w8
	str	w0, [x19, #16]
LBB0_4:
	bl	_PR_SCTP_POLICY
	ldr	w8, [x19]
	orr	w8, w8, w0
	str	w8, [x19]
	ldr	w0, [x19, #16]
	bl	_PR_SCTP_POLICY
	cmp	w0, #128
	b.eq	LBB0_8
; %bb.5:
	cmp	w0, #129
	b.eq	LBB0_7
; %bb.6:
	cmp	w0, #130
	b.ne	LBB0_10
LBB0_7:
	ldr	x8, [x19, #8]
	str	x8, [x19, #24]
	str	wzr, [x19, #32]
	b	LBB0_9
LBB0_8:
	add	x20, x19, #24
	mov	x0, x20
	bl	_SCTP_GETTIME_TIMEVAL
	ldr	x8, [x19, #8]
	mov	w9, #1000
	mul	x9, x8, x9
	mov	x10, #13531
	movk	x10, #55222, lsl #16
	movk	x10, #56962, lsl #32
	movk	x10, #17179, lsl #48
	smulh	x10, x9, x10
	lsr	x11, x10, #63
	lsr	x10, x10, #18
	add	w10, w10, w11
	mov	w11, #16960
	movk	w11, #15, lsl #16
	msub	w9, w10, w11, w9
	mov	x10, #63439
	movk	x10, #58195, lsl #16
	movk	x10, #39845, lsl #32
	movk	x10, #8388, lsl #48
	smulh	x8, x8, x10
	lsr	x10, x8, #63
	lsr	x8, x8, #7
	add	w8, w8, w10
	stp	w8, w9, [sp, #8]
	add	x1, sp, #8
	mov	x0, x20
	bl	_timevaladd
LBB0_9:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_10:
Lloh3:
	adrp	x8, _SCTP_DEBUG_USRREQ1@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SCTP_DEBUG_USRREQ1@GOTPAGEOFF]
Lloh5:
	ldr	w20, [x8]
	ldr	w0, [x19, #16]
	bl	_PR_SCTP_POLICY
	mov	x2, x0
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	b	_SCTPDBG
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_SCTP_PR_SCTP_TTL,4,2           ; @SCTP_PR_SCTP_TTL
	.comm	_SCTP_DEBUG_USRREQ1,4,2         ; @SCTP_DEBUG_USRREQ1
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Unknown PR_SCTP policy %u.\n"

	.no_dead_strip	_sctp_set_prsctp_policy
.subsections_via_symbols
