	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function MsgCmd
_MsgCmd:                                ## @MsgCmd
	.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
	cmpl	$3, %edi
	jge	LBB0_2
## %bb.1:
	movq	_CMDRTN_USAGE@GOTPCREL(%rip), %rax
	jmp	LBB0_18
LBB0_2:
	movq	%rsi, %r13
	movl	%edi, %r14d
	movq	8(%rsi), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	16(%rsi), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movl	$1, %r12d
	je	LBB0_5
## %bb.3:
	movl	%r14d, %r15d
	movl	$1, %r12d
	movl	$3, %ebx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r13,%rbx,8), %rdi
	callq	_strlen
                                        ## kill: def $eax killed $eax def $rax
	addl	%eax, %r12d
	incl	%r12d
	incq	%rbx
	cmpq	%rbx, %r15
	jne	LBB0_4
LBB0_5:
	movq	%r13, %rbx
	movl	%r12d, %edi
	callq	_malloc
	testq	%rax, %rax
	je	LBB0_6
## %bb.8:
	movq	%rax, %r13
	movb	$0, (%rax)
	cmpl	$4, %r14d
	jl	LBB0_11
## %bb.9:
	movl	%r14d, %eax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movl	$3, %r14d
	.p2align	4, 0x90
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	callq	_strlen
	movslq	%eax, %r15
	addq	%r13, %r15
	movq	%r13, %rdi
	callq	_strlen
	movl	%r12d, %esi
	subl	%eax, %esi
	movq	(%rbx,%r14,8), %rcx
	movq	%r15, %rdi
	leaq	L_.str.1(%rip), %rdx
	callq	_snprintf
	incq	%r14
	cmpq	%r14, -64(%rbp)                 ## 8-byte Folded Reload
	jne	LBB0_10
LBB0_11:
	movq	_csock@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	leaq	L_.str.2(%rip), %rdx
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	%r13, %r8
	callq	_NgSendAsciiMsg
	movq	%rax, %rbx
	movq	%r13, %rdi
	callq	_free
	testq	%rbx, %rbx
	js	LBB0_12
## %bb.13:
	leaq	-76(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_FD_ZERO
	movq	(%r15), %rdi
	movq	%rbx, %rsi
	callq	_FD_SET
	leaq	-72(%rbp), %r14
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	$4, %edx
	callq	_memset
	movq	(%r15), %rdi
	incq	%rdi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	movq	%r14, %r8
	callq	_select
	testl	%eax, %eax
	je	LBB0_17
## %bb.14:
	cmpl	$-1, %eax
	jne	LBB0_16
## %bb.15:
	movq	_EX_OSERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.4(%rip), %rsi
	callq	_err
	jmp	LBB0_17
LBB0_6:
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_7
LBB0_12:
	leaq	L_.str.3(%rip), %rdi
LBB0_7:
	callq	_warn
	movq	_CMDRTN_ERROR@GOTPCREL(%rip), %rax
	jmp	LBB0_18
LBB0_16:
	xorl	%eax, %eax
	callq	_MsgRead
LBB0_17:
	movq	_CMDRTN_OK@GOTPCREL(%rip), %rax
LBB0_18:
	movl	(%rax), %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CMDRTN_USAGE,4,2               ## @CMDRTN_USAGE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"malloc"

	.comm	_CMDRTN_ERROR,4,2               ## @CMDRTN_ERROR
L_.str.1:                               ## @.str.1
	.asciz	" %s"

	.comm	_csock,8,3                      ## @csock
L_.str.2:                               ## @.str.2
	.asciz	"%s%s"

L_.str.3:                               ## @.str.3
	.asciz	"send msg"

	.comm	_EX_OSERR,4,2                   ## @EX_OSERR
L_.str.4:                               ## @.str.4
	.asciz	"select"

	.comm	_CMDRTN_OK,4,2                  ## @CMDRTN_OK
	.no_dead_strip	_MsgCmd
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function MsgCmd
_MsgCmd:                                ; @MsgCmd
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	cmp	w0, #3
	b.ge	LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _CMDRTN_USAGE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CMDRTN_USAGE@GOTPAGEOFF]
	b	LBB0_19
LBB0_2:
	mov	x22, x1
	mov	x23, x0
	ldp	x20, x19, [x1, #8]
	cmp	w0, #3
	b.ne	LBB0_4
; %bb.3:
	mov	w21, #1
	b	LBB0_6
LBB0_4:
	mov	w8, w23
	add	x24, x22, #24
	sub	x25, x8, #3
	mov	w21, #1
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x24], #8
	bl	_strlen
	add	w8, w21, w0
	add	w21, w8, #1
	subs	x25, x25, #1
	b.ne	LBB0_5
LBB0_6:
	mov	x0, x21
	bl	_malloc
	cbz	x0, LBB0_14
; %bb.7:
	mov	x24, x0
	strb	wzr, [x0]
	cmp	w23, #4
	b.lt	LBB0_10
; %bb.8:
	mov	w8, w23
	add	x25, x22, #24
	sub	x26, x8, #3
Lloh2:
	adrp	x22, l_.str.1@PAGE
Lloh3:
	add	x22, x22, l_.str.1@PAGEOFF
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x24
	bl	_strlen
	add	x23, x24, w0, sxtw
	mov	x0, x24
	bl	_strlen
	sub	w1, w21, w0
	ldr	x3, [x25], #8
	mov	x0, x23
	mov	x2, x22
	bl	_snprintf
	subs	x26, x26, #1
	b.ne	LBB0_9
LBB0_10:
Lloh4:
	adrp	x21, _csock@GOTPAGE
Lloh5:
	ldr	x21, [x21, _csock@GOTPAGEOFF]
	ldr	x0, [x21]
Lloh6:
	adrp	x2, l_.str.2@PAGE
Lloh7:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	x1, x20
	mov	x3, x19
	mov	x4, x24
	bl	_NgSendAsciiMsg
	mov	x19, x0
	mov	x0, x24
	bl	_free
	tbnz	x19, #63, LBB0_15
; %bb.11:
	add	x0, sp, #4
	bl	_FD_ZERO
	ldr	x0, [x21]
	add	x1, sp, #4
	bl	_FD_SET
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #4
	bl	_memset
	ldr	x8, [x21]
	add	x0, x8, #1
	add	x1, sp, #4
	add	x4, sp, #8
	mov	x2, #0
	mov	x3, #0
	bl	_select
	cbz	w0, LBB0_18
; %bb.12:
	cmn	w0, #1
	b.ne	LBB0_17
; %bb.13:
Lloh8:
	adrp	x8, _EX_OSERR@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EX_OSERR@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
Lloh11:
	adrp	x1, l_.str.4@PAGE
Lloh12:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_err
	b	LBB0_18
LBB0_14:
Lloh13:
	adrp	x0, l_.str@PAGE
Lloh14:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_16
LBB0_15:
Lloh15:
	adrp	x0, l_.str.3@PAGE
Lloh16:
	add	x0, x0, l_.str.3@PAGEOFF
LBB0_16:
	bl	_warn
Lloh17:
	adrp	x8, _CMDRTN_ERROR@GOTPAGE
Lloh18:
	ldr	x8, [x8, _CMDRTN_ERROR@GOTPAGEOFF]
	b	LBB0_19
LBB0_17:
	bl	_MsgRead
LBB0_18:
Lloh19:
	adrp	x8, _CMDRTN_OK@GOTPAGE
Lloh20:
	ldr	x8, [x8, _CMDRTN_OK@GOTPAGEOFF]
LBB0_19:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_CMDRTN_USAGE,4,2               ; @CMDRTN_USAGE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"malloc"

	.comm	_CMDRTN_ERROR,4,2               ; @CMDRTN_ERROR
l_.str.1:                               ; @.str.1
	.asciz	" %s"

	.comm	_csock,8,3                      ; @csock
l_.str.2:                               ; @.str.2
	.asciz	"%s%s"

l_.str.3:                               ; @.str.3
	.asciz	"send msg"

	.comm	_EX_OSERR,4,2                   ; @EX_OSERR
l_.str.4:                               ; @.str.4
	.asciz	"select"

	.comm	_CMDRTN_OK,4,2                  ; @CMDRTN_OK
	.no_dead_strip	_MsgCmd
.subsections_via_symbols
