	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_putpkt                         ## -- Begin function putpkt
	.p2align	4, 0x90
_putpkt:                                ## @putpkt
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	callq	_strlen
	movl	%eax, %ebx
	movq	_PBUFSIZ@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_malloc
	movq	%rax, %r14
	movb	$36, (%rax)
	leaq	1(%rax), %rcx
	testl	%ebx, %ebx
	jle	LBB0_3
## %bb.1:
	movl	%ebx, %esi
	leaq	-1(%rsi), %rdx
	movl	%esi, %eax
	andl	$3, %eax
	cmpq	$3, %rdx
	jae	LBB0_4
## %bb.2:
	xorl	%edx, %edx
                                        ## implicit-def: $r12
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jne	LBB0_7
	jmp	LBB0_10
LBB0_3:
	xorl	%ebx, %ebx
	movq	%r14, %r12
	jmp	LBB0_10
LBB0_4:
	andl	$-4, %esi
	xorl	%edx, %edx
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movzbl	(%r15,%rdx), %ecx
	addl	%ecx, %ebx
	movb	%cl, 1(%r14,%rdx)
	movzbl	1(%r15,%rdx), %ecx
	addl	%ecx, %ebx
	movb	%cl, 2(%r14,%rdx)
	movzbl	2(%r15,%rdx), %ecx
	addl	%ecx, %ebx
	movb	%cl, 3(%r14,%rdx)
	movzbl	3(%r15,%rdx), %ecx
	addl	%ecx, %ebx
	movb	%cl, 4(%r14,%rdx)
	addq	$4, %rdx
	movzbl	%bl, %ebx
	cmpq	%rdx, %rsi
	jne	LBB0_5
## %bb.6:
	leaq	(%r14,%rdx), %r12
	leaq	(%r14,%rdx), %rcx
	incq	%rcx
	testq	%rax, %rax
	je	LBB0_10
LBB0_7:
	addq	%rdx, %r15
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movzbl	(%r15,%rdx), %esi
	addl	%esi, %ebx
	movb	%sil, (%rcx,%rdx)
	movzbl	%bl, %ebx
	incq	%rdx
	cmpq	%rdx, %rax
	jne	LBB0_8
## %bb.9:
	leaq	(%rcx,%rdx), %r12
	decq	%r12
	addq	%rdx, %rcx
LBB0_10:
	movb	$35, (%rcx)
	movl	%ebx, %eax
	shrl	$4, %eax
	movzbl	%al, %edi
	callq	_tohex
	movb	%al, 2(%r12)
	andl	$15, %ebx
	movl	%ebx, %edi
	callq	_tohex
	leaq	4(%r12), %r15
	movb	%al, 3(%r12)
	movb	$0, 4(%r12)
	subq	%r14, %r15
	movq	_remote_desc@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	jmp	LBB0_13
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_13 Depth=1
	movq	_the_target@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_SIGINT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	callq	*(%rax)
LBB0_12:                                ##   in Loop: Header=BB0_13 Depth=1
	movq	%r13, %rbx
	movl	(%r13), %edi
LBB0_13:                                ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rsi
	movl	%r15d, %edx
	callq	_write
	cltq
	cmpq	%rax, %r15
	jne	LBB0_27
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	_remote_debug@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_16
## %bb.15:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	_stderr@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdx
	xorl	%eax, %eax
	callq	_fprintf
	movl	(%r12), %edi
	callq	_fflush
LBB0_16:                                ##   in Loop: Header=BB0_13 Depth=1
	movq	%rbx, %r13
	movl	(%rbx), %edi
	leaq	-41(%rbp), %rsi
	movl	$1, %edx
	callq	_read
	movl	%eax, %r12d
	movq	_remote_debug@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_18
## %bb.17:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	_stderr@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	movsbl	-41(%rbp), %ecx
	leaq	L_.str.2(%rip), %rsi
	movl	%ecx, %edx
	xorl	%eax, %eax
	callq	_fprintf
	movl	(%rbx), %edi
	callq	_fflush
LBB0_18:                                ##   in Loop: Header=BB0_13 Depth=1
	testl	%r12d, %r12d
	jle	LBB0_22
## %bb.19:                              ##   in Loop: Header=BB0_13 Depth=1
	movzbl	-41(%rbp), %eax
	cmpb	$3, %al
	je	LBB0_11
## %bb.20:                              ##   in Loop: Header=BB0_13 Depth=1
	cmpb	$43, %al
	jne	LBB0_12
## %bb.21:
	movq	%r14, %rdi
	callq	_free
	movl	$1, %eax
	jmp	LBB0_26
LBB0_22:
	jne	LBB0_28
## %bb.23:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.3(%rip), %rsi
	xorl	%eax, %eax
	callq	_fprintf
LBB0_24:
	movq	%r14, %rdi
	callq	_free
LBB0_25:
	movl	$-1, %eax
LBB0_26:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_27:
	leaq	L_.str(%rip), %rdi
	callq	_perror
	jmp	LBB0_25
LBB0_28:
	leaq	L_.str.4(%rip), %rdi
	callq	_perror
	jmp	LBB0_24
	.cfi_endproc
                                        ## -- End function
	.comm	_PBUFSIZ,4,2                    ## @PBUFSIZ
	.comm	_remote_desc,4,2                ## @remote_desc
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"putpkt(write)"

	.comm	_remote_debug,8,3               ## @remote_debug
	.comm	_stderr,4,2                     ## @stderr
L_.str.1:                               ## @.str.1
	.asciz	"putpkt (\"%s\"); [looking for ack]\n"

L_.str.2:                               ## @.str.2
	.asciz	"[received '%c' (0x%x)]\n"

L_.str.3:                               ## @.str.3
	.asciz	"putpkt(read): Got EOF\n"

L_.str.4:                               ## @.str.4
	.asciz	"putpkt(read)"

	.comm	_the_target,8,3                 ## @the_target
	.comm	_SIGINT,4,2                     ## @SIGINT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_putpkt                         ; -- Begin function putpkt
	.p2align	2
_putpkt:                                ; @putpkt
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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	x20, x0
	bl	_strlen
	mov	x21, x0
Lloh0:
	adrp	x8, _PBUFSIZ@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PBUFSIZ@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_malloc
	mov	x19, x0
	mov	w9, #36
	mov	x8, x0
	strb	w9, [x8], #1
	cmp	w21, #1
	b.lt	LBB0_4
; %bb.1:
	mov	w22, #0
	mov	w9, w21
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldrb	w10, [x20], #1
	add	w11, w22, w10
	strb	w10, [x8], #1
	and	w22, w11, #0xff
	subs	x9, x9, #1
	b.ne	LBB0_2
; %bb.3:
	sub	x20, x8, #1
	b	LBB0_5
LBB0_4:
	mov	w22, #0
	mov	x20, x19
LBB0_5:
	mov	w9, #35
	strb	w9, [x8]
	lsr	w0, w22, #4
	bl	_tohex
	strb	w0, [x20, #2]
	and	w0, w22, #0xf
	bl	_tohex
	strb	wzr, [x20, #4]!
	sturb	w0, [x20, #-1]
	sub	x20, x20, x19
Lloh3:
	adrp	x24, _remote_desc@GOTPAGE
Lloh4:
	ldr	x24, [x24, _remote_desc@GOTPAGEOFF]
	ldr	w0, [x24]
	mov	x1, x19
	mov	x2, x20
	bl	_write
	cmp	x20, w0, sxtw
	b.ne	LBB0_22
; %bb.6:
Lloh5:
	adrp	x25, _remote_debug@GOTPAGE
Lloh6:
	ldr	x25, [x25, _remote_debug@GOTPAGEOFF]
Lloh7:
	adrp	x27, _the_target@GOTPAGE
Lloh8:
	ldr	x27, [x27, _the_target@GOTPAGEOFF]
Lloh9:
	adrp	x21, l_.str.2@PAGE
Lloh10:
	add	x21, x21, l_.str.2@PAGEOFF
Lloh11:
	adrp	x28, _SIGINT@GOTPAGE
Lloh12:
	ldr	x28, [x28, _SIGINT@GOTPAGEOFF]
Lloh13:
	adrp	x26, _stderr@GOTPAGE
Lloh14:
	ldr	x26, [x26, _stderr@GOTPAGEOFF]
Lloh15:
	adrp	x22, l_.str.1@PAGE
Lloh16:
	add	x22, x22, l_.str.1@PAGEOFF
	b	LBB0_9
LBB0_7:                                 ;   in Loop: Header=BB0_9 Depth=1
	ldr	x8, [x27]
	ldr	x8, [x8]
	ldr	w0, [x28]
	blr	x8
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	ldr	w0, [x24]
	mov	x1, x19
	mov	x2, x20
	bl	_write
	cmp	x20, w0, sxtw
	b.ne	LBB0_22
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x25]
	cbz	x8, LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w0, [x26]
	str	x19, [sp]
	mov	x1, x22
	bl	_fprintf
	ldr	w0, [x26]
	bl	_fflush
LBB0_11:                                ;   in Loop: Header=BB0_9 Depth=1
	ldr	w0, [x24]
	add	x1, sp, #31
	mov	w2, #1
	bl	_read
	mov	x23, x0
	ldr	x8, [x25]
	cbz	x8, LBB0_13
; %bb.12:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w0, [x26]
	ldrsb	x8, [sp, #31]
	stp	x8, x8, [sp]
	mov	x1, x21
	bl	_fprintf
	ldr	w0, [x26]
	bl	_fflush
LBB0_13:                                ;   in Loop: Header=BB0_9 Depth=1
	cmp	w23, #0
	b.le	LBB0_17
; %bb.14:                               ;   in Loop: Header=BB0_9 Depth=1
	ldrb	w8, [sp, #31]
	cmp	w8, #3
	b.eq	LBB0_7
; %bb.15:                               ;   in Loop: Header=BB0_9 Depth=1
	cmp	w8, #43
	b.ne	LBB0_8
; %bb.16:
	mov	x0, x19
	bl	_free
	mov	w0, #1
	b	LBB0_21
LBB0_17:
	cbnz	w23, LBB0_23
; %bb.18:
	ldr	w0, [x26]
Lloh17:
	adrp	x1, l_.str.3@PAGE
Lloh18:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_fprintf
LBB0_19:
	mov	x0, x19
	bl	_free
LBB0_20:
	mov	w0, #-1
LBB0_21:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_22:
Lloh19:
	adrp	x0, l_.str@PAGE
Lloh20:
	add	x0, x0, l_.str@PAGEOFF
	bl	_perror
	b	LBB0_20
LBB0_23:
Lloh21:
	adrp	x0, l_.str.4@PAGE
Lloh22:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_perror
	b	LBB0_19
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_PBUFSIZ,4,2                    ; @PBUFSIZ
	.comm	_remote_desc,4,2                ; @remote_desc
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"putpkt(write)"

	.comm	_remote_debug,8,3               ; @remote_debug
	.comm	_stderr,4,2                     ; @stderr
l_.str.1:                               ; @.str.1
	.asciz	"putpkt (\"%s\"); [looking for ack]\n"

l_.str.2:                               ; @.str.2
	.asciz	"[received '%c' (0x%x)]\n"

l_.str.3:                               ; @.str.3
	.asciz	"putpkt(read): Got EOF\n"

l_.str.4:                               ; @.str.4
	.asciz	"putpkt(read)"

	.comm	_the_target,8,3                 ; @the_target
	.comm	_SIGINT,4,2                     ; @SIGINT
.subsections_via_symbols
