	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_Netchan_Transmit               ## -- Begin function Netchan_Transmit
	.p2align	4, 0x90
_Netchan_Transmit:                      ## @Netchan_Transmit
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, -64(%rbp)                 ## 8-byte Spill
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movq	%rsp, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_MAX_PACKETLEN@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	leaq	(,%r12,4), %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r13
	movq	_MAX_MSGLEN@GOTPCREL(%rip), %rax
	cmpl	%r14d, (%rax)
	jge	LBB0_2
## %bb.1:
	movq	_ERR_DROP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edx
	callq	_Com_Error
LBB0_2:
	movq	$0, 64(%rbx)
	movq	_FRAGMENT_SIZE@GOTPCREL(%rip), %rax
	cmpl	%r14d, (%rax)
	jle	LBB0_3
## %bb.4:
	movq	%r15, -72(%rbp)                 ## 8-byte Spill
	shll	$2, %r12d
	leaq	-56(%rbp), %r15
	movq	%r15, %rdi
	movq	%r13, %rsi
	movl	%r12d, %edx
	callq	_MSG_InitOOB
	movq	24(%rbx), %rsi
	movq	%r15, %rdi
	callq	_MSG_WriteLong
	movq	8(%rbx), %rax
	movq	_NS_CLIENT@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_6
## %bb.5:
	movq	_qport@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax), %esi
	leaq	-56(%rbp), %rdi
	callq	_MSG_WriteShort
LBB0_6:
	movl	44(%rbx), %edi
	movq	24(%rbx), %rsi
	callq	_NETCHAN_GENCHECKSUM
	leaq	-56(%rbp), %r15
	movq	%r15, %rdi
	movq	%rax, %rsi
	callq	_MSG_WriteLong
	incq	24(%rbx)
	movq	%r15, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	movl	%r14d, %edx
	callq	_MSG_WriteData
	movq	8(%rbx), %rdi
	movl	-56(%rbp), %esi
	movl	-52(%rbp), %edx
	movl	40(%rbx), %ecx
	callq	_NET_SendPacket
	xorl	%eax, %eax
	callq	_Sys_Milliseconds
	movl	%eax, 36(%rbx)
	movl	-56(%rbp), %edx
	movl	%edx, 32(%rbx)
	movq	_showpackets@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	$0, (%rax)
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	je	LBB0_8
## %bb.7:
	movq	_netsrcString@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	8(%rbx), %rcx
	movl	(%rax,%rcx,4), %esi
	movq	24(%rbx), %rcx
	decq	%rcx
	movl	16(%rbx), %r8d
	leaq	L_.str.1(%rip), %rdi
	callq	_Com_Printf
	jmp	LBB0_8
LBB0_3:
	movq	_qtrue@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 56(%rbx)
	movl	%r14d, (%rbx)
	movl	52(%rbx), %edi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	movl	%r14d, %edx
	callq	_Com_Memcpy
	movq	%rbx, %rdi
	callq	_Netchan_TransmitNextFragment
LBB0_8:
	movq	%r15, %rsp
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_10
## %bb.9:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_PACKETLEN,4,2              ## @MAX_PACKETLEN
	.comm	_MAX_MSGLEN,4,2                 ## @MAX_MSGLEN
	.comm	_ERR_DROP,4,2                   ## @ERR_DROP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Netchan_Transmit: length = %i"

	.comm	_FRAGMENT_SIZE,4,2              ## @FRAGMENT_SIZE
	.comm	_qtrue,4,2                      ## @qtrue
	.comm	_NS_CLIENT,8,3                  ## @NS_CLIENT
	.comm	_qport,8,3                      ## @qport
	.comm	_showpackets,8,3                ## @showpackets
L_.str.1:                               ## @.str.1
	.asciz	"%s send %4i : s=%i ack=%i\n"

	.comm	_netsrcString,8,3               ## @netsrcString
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_Netchan_Transmit               ; -- Begin function Netchan_Transmit
	.p2align	2
_Netchan_Transmit:                      ; @Netchan_Transmit
	.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
	sub	sp, sp, #16
	mov	x21, x2
	mov	x20, x1
	mov	x19, x0
	mov	x23, sp
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
Lloh3:
	adrp	x8, _MAX_PACKETLEN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MAX_PACKETLEN@GOTPAGEOFF]
Lloh5:
	ldr	w24, [x8]
	lsl	x8, x24, #2
	mov	x9, x8
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0x7fffffff0
	sub	x22, x9, x8
	mov	sp, x22
Lloh8:
	adrp	x8, _MAX_MSGLEN@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MAX_MSGLEN@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	cmp	w8, w1
	b.ge	LBB0_2
; %bb.1:
Lloh11:
	adrp	x8, _ERR_DROP@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ERR_DROP@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
Lloh14:
	adrp	x1, l_.str@PAGE
Lloh15:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_Com_Error
LBB0_2:
	str	xzr, [x19, #64]
Lloh16:
	adrp	x8, _FRAGMENT_SIZE@GOTPAGE
Lloh17:
	ldr	x8, [x8, _FRAGMENT_SIZE@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	cmp	w8, w20
	b.le	LBB0_7
; %bb.3:
	lsl	w2, w24, #2
	sub	x0, x29, #64
	mov	x1, x22
	bl	_MSG_InitOOB
	ldr	x1, [x19, #24]
	sub	x0, x29, #64
	bl	_MSG_WriteLong
	ldr	x8, [x19, #8]
Lloh19:
	adrp	x9, _NS_CLIENT@GOTPAGE
Lloh20:
	ldr	x9, [x9, _NS_CLIENT@GOTPAGEOFF]
Lloh21:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.4:
Lloh22:
	adrp	x8, _qport@GOTPAGE
Lloh23:
	ldr	x8, [x8, _qport@GOTPAGEOFF]
Lloh24:
	ldr	x8, [x8]
	ldr	w1, [x8]
	sub	x0, x29, #64
	bl	_MSG_WriteShort
LBB0_5:
	ldr	w0, [x19, #44]
	ldr	x1, [x19, #24]
	bl	_NETCHAN_GENCHECKSUM
	mov	x1, x0
	sub	x0, x29, #64
	bl	_MSG_WriteLong
	ldr	x8, [x19, #24]
	add	x8, x8, #1
	str	x8, [x19, #24]
	sub	x0, x29, #64
	mov	x1, x21
	mov	x2, x20
	bl	_MSG_WriteData
	ldr	x0, [x19, #8]
	ldp	w1, w2, [x29, #-64]
	ldr	w3, [x19, #40]
	bl	_NET_SendPacket
	bl	_Sys_Milliseconds
	ldur	w2, [x29, #-64]
	stp	w2, w0, [x19, #32]
Lloh25:
	adrp	x8, _showpackets@GOTPAGE
Lloh26:
	ldr	x8, [x8, _showpackets@GOTPAGEOFF]
Lloh27:
	ldr	x8, [x8]
	ldr	x8, [x8]
	cbz	x8, LBB0_8
; %bb.6:
Lloh28:
	adrp	x8, _netsrcString@GOTPAGE
Lloh29:
	ldr	x8, [x8, _netsrcString@GOTPAGEOFF]
Lloh30:
	ldr	x8, [x8]
	ldr	x9, [x19, #8]
	ldr	w1, [x8, x9, lsl #2]
	ldr	x8, [x19, #24]
	sub	x3, x8, #1
	ldr	w4, [x19, #16]
Lloh31:
	adrp	x0, l_.str.1@PAGE
Lloh32:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_Com_Printf
	b	LBB0_8
LBB0_7:
Lloh33:
	adrp	x8, _qtrue@GOTPAGE
Lloh34:
	ldr	x8, [x8, _qtrue@GOTPAGEOFF]
Lloh35:
	ldr	w8, [x8]
	str	w8, [x19, #56]
	str	w20, [x19]
	ldr	w0, [x19, #52]
	mov	x1, x21
	mov	x2, x20
	bl	_Com_Memcpy
	mov	x0, x19
	bl	_Netchan_TransmitNextFragment
LBB0_8:
	mov	sp, x23
	ldur	x8, [x29, #-56]
Lloh36:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh37:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh38:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_10
; %bb.9:
	sub	sp, x29, #48
	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
LBB0_10:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_PACKETLEN,4,2              ; @MAX_PACKETLEN
	.comm	_MAX_MSGLEN,4,2                 ; @MAX_MSGLEN
	.comm	_ERR_DROP,4,2                   ; @ERR_DROP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Netchan_Transmit: length = %i"

	.comm	_FRAGMENT_SIZE,4,2              ; @FRAGMENT_SIZE
	.comm	_qtrue,4,2                      ; @qtrue
	.comm	_NS_CLIENT,8,3                  ; @NS_CLIENT
	.comm	_qport,8,3                      ; @qport
	.comm	_showpackets,8,3                ; @showpackets
l_.str.1:                               ; @.str.1
	.asciz	"%s send %4i : s=%i ack=%i\n"

	.comm	_netsrcString,8,3               ; @netsrcString
.subsections_via_symbols
