	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_udplite_prep                   ## -- Begin function udplite_prep
	.p2align	4, 0x90
_udplite_prep:                          ## @udplite_prep
	.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	_outp@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	movq	_ident@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_fixedPort@GOTPCREL(%rip), %r12
	xorl	%ebx, %ebx
	cmpq	$0, (%r12)
	movl	$0, %edi
	je	LBB0_2
## %bb.1:
	movl	(%r14), %edi
LBB0_2:
	addl	%eax, %edi
	callq	_htons
	movq	%rax, 24(%r15)
	movq	_port@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	cmpq	$0, (%r12)
	jne	LBB0_4
## %bb.3:
	movl	(%r14), %ebx
LBB0_4:
	addl	%eax, %ebx
	movl	%ebx, %edi
	callq	_htons
	movq	%rax, 16(%r15)
	movl	$8, %edi
	callq	_htons
	movq	%rax, 8(%r15)
	movl	$0, (%r15)
	movq	_doipcksum@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_6
## %bb.5:
	movq	_outip@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_protlen@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rsi
	movl	$8, %ecx
	callq	_p_cksum
	testl	%eax, %eax
	movl	$65535, %ecx                    ## imm = 0xFFFF
	cmovnel	%eax, %ecx
	movl	%ecx, (%r15)
LBB0_6:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_outp,8,3                       ## @outp
	.comm	_ident,4,2                      ## @ident
	.comm	_fixedPort,8,3                  ## @fixedPort
	.comm	_port,4,2                       ## @port
	.comm	_doipcksum,8,3                  ## @doipcksum
	.comm	_outip,4,2                      ## @outip
	.comm	_protlen,4,2                    ## @protlen
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_udplite_prep                   ; -- Begin function udplite_prep
	.p2align	2
_udplite_prep:                          ; @udplite_prep
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x20, x0
Lloh0:
	adrp	x8, _outp@GOTPAGE
Lloh1:
	ldr	x8, [x8, _outp@GOTPAGEOFF]
Lloh2:
	ldr	x19, [x8]
Lloh3:
	adrp	x8, _ident@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ident@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x21, _fixedPort@GOTPAGE
Lloh7:
	ldr	x21, [x21, _fixedPort@GOTPAGEOFF]
	ldr	x9, [x21]
	cbz	x9, LBB0_2
; %bb.1:
	ldr	w9, [x20]
LBB0_2:
	add	w0, w9, w8
	bl	_htons
	str	x0, [x19, #24]
Lloh8:
	adrp	x8, _port@GOTPAGE
Lloh9:
	ldr	x8, [x8, _port@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	ldr	x9, [x21]
	cbz	x9, LBB0_4
; %bb.3:
	mov	w9, #0
	b	LBB0_5
LBB0_4:
	ldr	w9, [x20]
LBB0_5:
	add	w0, w9, w8
	bl	_htons
	str	x0, [x19, #16]
	mov	w0, #8
	bl	_htons
	str	x0, [x19, #8]
	str	wzr, [x19]
Lloh11:
	adrp	x8, _doipcksum@GOTPAGE
Lloh12:
	ldr	x8, [x8, _doipcksum@GOTPAGEOFF]
Lloh13:
	ldr	x8, [x8]
	cbz	x8, LBB0_7
; %bb.6:
Lloh14:
	adrp	x8, _outip@GOTPAGE
Lloh15:
	ldr	x8, [x8, _outip@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
Lloh17:
	adrp	x8, _protlen@GOTPAGE
Lloh18:
	ldr	x8, [x8, _protlen@GOTPAGEOFF]
Lloh19:
	ldr	w2, [x8]
	mov	x1, x19
	mov	w3, #8
	bl	_p_cksum
	mov	w8, #65535
	cmp	w0, #0
	csel	w8, w8, w0, eq
	str	w8, [x19]
LBB0_7:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_outp,8,3                       ; @outp
	.comm	_ident,4,2                      ; @ident
	.comm	_fixedPort,8,3                  ; @fixedPort
	.comm	_port,4,2                       ; @port
	.comm	_doipcksum,8,3                  ; @doipcksum
	.comm	_outip,4,2                      ; @outip
	.comm	_protlen,4,2                    ; @protlen
.subsections_via_symbols
