	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_do_store                       ## -- Begin function do_store
	.p2align	4, 0x90
_do_store:                              ## @do_store
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %ebx
	movq	%rsi, %r14
	movq	%rdi, %r12
	movq	_guest@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_2
## %bb.1:
	movq	%r12, %rdi
	callq	_filename_check
	testq	%rax, %rax
	jne	LBB0_26
LBB0_2:
	testl	%ebx, %ebx
	movl	%ebx, -52(%rbp)                 ## 4-byte Spill
	je	LBB0_6
## %bb.3:
	leaq	-56(%rbp), %rsi
	movq	%r12, %rdi
	callq	_stat
	testq	%rax, %rax
	jne	LBB0_5
## %bb.4:
	movq	%r12, %rdi
	callq	_gunique
	movq	%rax, %r12
	testq	%rax, %rax
	je	LBB0_26
LBB0_5:
	cmpb	$119, (%r14)
	leaq	L_.str(%rip), %rax
	leaq	L_.str.1(%rip), %rdi
	cmoveq	%rax, %rdi
	movq	%r12, %rsi
	callq	_LOGCMD
LBB0_6:
	movq	_restart_point@GOTPCREL(%rip), %r15
	cmpq	$0, (%r15)
	leaq	L_.str.2(%rip), %rbx
	cmoveq	%r14, %rbx
	movq	%r12, %rdi
	movq	%rbx, %rsi
	callq	_fopen
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:
	movq	%rax, %r13
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	_byte_count@GOTPCREL(%rip), %rax
	movl	$-1, (%rax)
	movq	(%r15), %r14
	testq	%r14, %r14
	je	LBB0_17
## %bb.9:
	movq	_type@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_TYPE_A@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_27
## %bb.10:
	testq	%r14, %r14
	jle	LBB0_15
## %bb.11:
	xorl	%ebx, %ebx
	movq	_EOF@GOTPCREL(%rip), %r15
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	callq	_getc
	cmpl	(%r15), %eax
	je	LBB0_13
## %bb.14:                              ##   in Loop: Header=BB0_12 Depth=1
	xorl	%ecx, %ecx
	cmpl	$10, %eax
	sete	%cl
	addq	%rcx, %rbx
	incq	%rbx
	cmpq	%r14, %rbx
	jl	LBB0_12
LBB0_15:
	movq	_SEEK_CUR@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_fseek
	testq	%rax, %rax
	jns	LBB0_17
LBB0_13:
	movl	$550, %edi                      ## imm = 0x226
	movq	%r12, %rsi
	callq	_perror_reply
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	jmp	LBB0_25
LBB0_7:
	movl	$553, %edi                      ## imm = 0x229
	movq	%r12, %rsi
	callq	_perror_reply
	cmpb	$119, (%rbx)
	leaq	L_.str(%rip), %rax
	leaq	L_.str.1(%rip), %rdi
	cmoveq	%rax, %rdi
	movq	%r12, %rsi
	callq	_LOGCMD
	jmp	LBB0_26
LBB0_27:
	movq	%r13, %rdi
	callq	_fileno
	movq	(%r15), %rsi
	movq	_SEEK_SET@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%eax, %edi
	callq	_lseek
	testq	%rax, %rax
	js	LBB0_13
LBB0_17:
	leaq	L_.str.3(%rip), %rdx
	movq	%r12, %rdi
	movq	$-1, %rsi
	callq	_dataconn
	testq	%rax, %rax
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	je	LBB0_25
## %bb.18:
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_fileno
	movl	%eax, %edi
	movl	$1, %esi
	callq	_set_buffer_size
	movq	%rbx, %rdi
	movq	%r13, %rsi
	callq	_receive_data
	movq	%rax, %r15
	movq	%r13, %rdi
	callq	_fclose
	testq	%r15, %r15
	je	LBB0_19
LBB0_24:
	movq	%rbx, %rdi
	callq	_fclose
	movq	_data@GOTPCREL(%rip), %rax
	movl	$-1, (%rax)
	movq	_pdata@GOTPCREL(%rip), %rax
	movl	$-1, (%rax)
LBB0_25:
	cmpb	$119, (%r14)
	leaq	L_.str(%rip), %rax
	leaq	L_.str.1(%rip), %rdi
	cmoveq	%rax, %rdi
	movq	_byte_count@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rsi
	callq	_LOGBYTES
LBB0_26:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_19:
	testl	%eax, %eax
	js	LBB0_20
## %bb.21:
	cmpl	$0, -52(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_23
## %bb.22:
	leaq	L_.str.4(%rip), %rsi
	movl	$226, %edi
	movq	%r12, %rdx
	xorl	%eax, %eax
	callq	_reply
	jmp	LBB0_24
LBB0_20:
	movl	$552, %edi                      ## imm = 0x228
	movq	%r12, %rsi
	callq	_perror_reply
	jmp	LBB0_24
LBB0_23:
	leaq	L_.str.5(%rip), %rsi
	movl	$226, %edi
	xorl	%eax, %eax
	callq	_reply
	jmp	LBB0_24
	.cfi_endproc
                                        ## -- End function
	.comm	_guest,8,3                      ## @guest
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"put"

L_.str.1:                               ## @.str.1
	.asciz	"append"

	.comm	_restart_point,8,3              ## @restart_point
L_.str.2:                               ## @.str.2
	.asciz	"r+"

	.comm	_byte_count,4,2                 ## @byte_count
	.comm	_type,8,3                       ## @type
	.comm	_TYPE_A,8,3                     ## @TYPE_A
	.comm	_EOF,4,2                        ## @EOF
	.comm	_SEEK_CUR,4,2                   ## @SEEK_CUR
	.comm	_SEEK_SET,4,2                   ## @SEEK_SET
L_.str.3:                               ## @.str.3
	.asciz	"r"

L_.str.4:                               ## @.str.4
	.asciz	"Transfer complete (unique file name:%s)."

L_.str.5:                               ## @.str.5
	.asciz	"Transfer complete."

	.comm	_data,4,2                       ## @data
	.comm	_pdata,4,2                      ## @pdata
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_do_store                       ; -- Begin function do_store
	.p2align	2
_do_store:                              ; @do_store
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x21, x2
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _guest@GOTPAGE
Lloh1:
	ldr	x8, [x8, _guest@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cbz	x8, LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_filename_check
	cbnz	x0, LBB0_28
LBB0_2:
Lloh3:
	adrp	x25, l_.str.1@PAGE
Lloh4:
	add	x25, x25, l_.str.1@PAGEOFF
Lloh5:
	adrp	x26, l_.str@PAGE
Lloh6:
	add	x26, x26, l_.str@PAGEOFF
	cbz	w21, LBB0_6
; %bb.3:
	add	x1, sp, #8
	mov	x0, x19
	bl	_stat
	cbnz	x0, LBB0_5
; %bb.4:
	mov	x0, x19
	bl	_gunique
	mov	x19, x0
	cbz	x0, LBB0_28
LBB0_5:
	ldrb	w8, [x20]
	cmp	w8, #119
	csel	x0, x26, x25, eq
	mov	x1, x19
	bl	_LOGCMD
LBB0_6:
Lloh7:
	adrp	x24, _restart_point@GOTPAGE
Lloh8:
	ldr	x24, [x24, _restart_point@GOTPAGEOFF]
	ldr	x8, [x24]
Lloh9:
	adrp	x9, l_.str.2@PAGE
Lloh10:
	add	x9, x9, l_.str.2@PAGEOFF
	cmp	x8, #0
	csel	x20, x20, x9, eq
	mov	x0, x19
	mov	x1, x20
	bl	_fopen
	cbz	x0, LBB0_15
; %bb.7:
	mov	x22, x0
Lloh11:
	adrp	x27, _byte_count@GOTPAGE
Lloh12:
	ldr	x27, [x27, _byte_count@GOTPAGEOFF]
	mov	w8, #-1
	str	w8, [x27]
	ldr	x23, [x24]
	cbz	x23, LBB0_17
; %bb.8:
Lloh13:
	adrp	x8, _type@GOTPAGE
Lloh14:
	ldr	x8, [x8, _type@GOTPAGEOFF]
Lloh15:
	ldr	x8, [x8]
Lloh16:
	adrp	x9, _TYPE_A@GOTPAGE
Lloh17:
	ldr	x9, [x9, _TYPE_A@GOTPAGEOFF]
Lloh18:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_16
; %bb.9:
	cmp	x23, #1
	b.lt	LBB0_13
; %bb.10:
	mov	x24, #0
Lloh19:
	adrp	x28, _EOF@GOTPAGE
Lloh20:
	ldr	x28, [x28, _EOF@GOTPAGEOFF]
	mov	w27, #1
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x22
	bl	_getc
	ldr	w8, [x28]
	cmp	w0, w8
	b.eq	LBB0_22
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	cmp	w0, #10
	cinc	x8, x27, eq
	add	x24, x8, x24
	cmp	x24, x23
	b.lt	LBB0_11
LBB0_13:
Lloh21:
	adrp	x8, _SEEK_CUR@GOTPAGE
Lloh22:
	ldr	x8, [x8, _SEEK_CUR@GOTPAGEOFF]
Lloh23:
	ldr	w2, [x8]
	mov	x0, x22
	mov	x1, #0
	bl	_fseek
Lloh24:
	adrp	x27, _byte_count@GOTPAGE
Lloh25:
	ldr	x27, [x27, _byte_count@GOTPAGEOFF]
	tbz	x0, #63, LBB0_17
LBB0_14:
	mov	w0, #550
	mov	x1, x19
	bl	_perror_reply
	b	LBB0_27
LBB0_15:
	mov	w0, #553
	mov	x1, x19
	bl	_perror_reply
	ldrb	w8, [x20]
	cmp	w8, #119
	csel	x0, x26, x25, eq
	mov	x1, x19
	bl	_LOGCMD
	b	LBB0_28
LBB0_16:
	mov	x0, x22
	bl	_fileno
	ldr	x1, [x24]
Lloh26:
	adrp	x8, _SEEK_SET@GOTPAGE
Lloh27:
	ldr	x8, [x8, _SEEK_SET@GOTPAGEOFF]
Lloh28:
	ldr	w2, [x8]
	bl	_lseek
	tbnz	x0, #63, LBB0_14
LBB0_17:
Lloh29:
	adrp	x2, l_.str.3@PAGE
Lloh30:
	add	x2, x2, l_.str.3@PAGEOFF
	mov	x0, x19
	mov	x1, #-1
	bl	_dataconn
	cbz	x0, LBB0_27
; %bb.18:
	mov	x23, x0
	bl	_fileno
	mov	w1, #1
	bl	_set_buffer_size
	mov	x0, x23
	mov	x1, x22
	bl	_receive_data
	mov	x24, x0
	mov	x0, x22
	bl	_fclose
	cbnz	x24, LBB0_26
; %bb.19:
	tbnz	w0, #31, LBB0_23
; %bb.20:
	cbz	w21, LBB0_24
; %bb.21:
	str	x19, [sp]
Lloh31:
	adrp	x1, l_.str.4@PAGE
Lloh32:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_25
LBB0_22:
	mov	w0, #550
	mov	x1, x19
	bl	_perror_reply
Lloh33:
	adrp	x27, _byte_count@GOTPAGE
Lloh34:
	ldr	x27, [x27, _byte_count@GOTPAGEOFF]
	b	LBB0_27
LBB0_23:
	mov	w0, #552
	mov	x1, x19
	bl	_perror_reply
	b	LBB0_26
LBB0_24:
Lloh35:
	adrp	x1, l_.str.5@PAGE
Lloh36:
	add	x1, x1, l_.str.5@PAGEOFF
LBB0_25:
	mov	w0, #226
	bl	_reply
LBB0_26:
	mov	x0, x23
	bl	_fclose
Lloh37:
	adrp	x8, _data@GOTPAGE
Lloh38:
	ldr	x8, [x8, _data@GOTPAGEOFF]
	mov	w9, #-1
Lloh39:
	str	w9, [x8]
Lloh40:
	adrp	x8, _pdata@GOTPAGE
Lloh41:
	ldr	x8, [x8, _pdata@GOTPAGEOFF]
Lloh42:
	str	w9, [x8]
LBB0_27:
	ldrb	w8, [x20]
	cmp	w8, #119
	csel	x0, x26, x25, eq
	ldr	w2, [x27]
	mov	x1, x19
	bl	_LOGBYTES
LBB0_28:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh33, Lloh34
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGotStr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotStr	Lloh37, Lloh38, Lloh39
	.cfi_endproc
                                        ; -- End function
	.comm	_guest,8,3                      ; @guest
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"put"

l_.str.1:                               ; @.str.1
	.asciz	"append"

	.comm	_restart_point,8,3              ; @restart_point
l_.str.2:                               ; @.str.2
	.asciz	"r+"

	.comm	_byte_count,4,2                 ; @byte_count
	.comm	_type,8,3                       ; @type
	.comm	_TYPE_A,8,3                     ; @TYPE_A
	.comm	_EOF,4,2                        ; @EOF
	.comm	_SEEK_CUR,4,2                   ; @SEEK_CUR
	.comm	_SEEK_SET,4,2                   ; @SEEK_SET
l_.str.3:                               ; @.str.3
	.asciz	"r"

l_.str.4:                               ; @.str.4
	.asciz	"Transfer complete (unique file name:%s)."

l_.str.5:                               ; @.str.5
	.asciz	"Transfer complete."

	.comm	_data,4,2                       ; @data
	.comm	_pdata,4,2                      ; @pdata
.subsections_via_symbols
