	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_setscript                      ## -- Begin function setscript
	.p2align	4, 0x90
_setscript:                             ## @setscript
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_tipout_pid@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SIGEMT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_kill
	movq	_SCRIPT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_value
	movq	%rax, %rdi
	callq	_boolean
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_fildes@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	4(%rax), %r14d
	movq	_RECORD@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	callq	_value
	movq	%rax, %rbx
	movl	(%r15), %edi
	callq	_value
	movq	%rax, %rdi
	callq	_size
	movl	%r14d, %edi
	movq	%rbx, %rsi
	movl	%eax, %edx
	callq	_write
LBB0_2:
	movq	_fildes@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	4(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movl	$1, %edx
	callq	_write
	movq	_repdes@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax), %edi
	leaq	-25(%rbp), %rsi
	movl	$1, %edx
	callq	_read
	cmpb	$110, -25(%rbp)
	jne	LBB0_3
## %bb.4:
	movq	_RECORD@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_value
	leaq	L_.str.1(%rip), %rdi
	movq	%rax, %rsi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_printf                         ## TAILCALL
LBB0_3:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_tipout_pid,4,2                 ## @tipout_pid
	.comm	_SIGEMT,4,2                     ## @SIGEMT
	.comm	_SCRIPT,4,2                     ## @SCRIPT
	.comm	_fildes,8,3                     ## @fildes
	.comm	_RECORD,4,2                     ## @RECORD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"\n"

	.comm	_repdes,8,3                     ## @repdes
L_.str.1:                               ## @.str.1
	.asciz	"can't create %s\r\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_setscript                      ; -- Begin function setscript
	.p2align	2
_setscript:                             ; @setscript
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
Lloh0:
	adrp	x8, _tipout_pid@GOTPAGE
Lloh1:
	ldr	x8, [x8, _tipout_pid@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x8, _SIGEMT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SIGEMT@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_kill
Lloh6:
	adrp	x8, _SCRIPT@GOTPAGE
Lloh7:
	ldr	x8, [x8, _SCRIPT@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_value
	bl	_boolean
Lloh9:
	adrp	x22, _fildes@GOTPAGE
Lloh10:
	ldr	x22, [x22, _fildes@GOTPAGEOFF]
Lloh11:
	adrp	x21, _RECORD@GOTPAGE
Lloh12:
	ldr	x21, [x21, _RECORD@GOTPAGEOFF]
	cbz	x0, LBB0_2
; %bb.1:
	ldr	x8, [x22]
	ldr	w19, [x8, #4]
	ldr	w0, [x21]
	bl	_value
	mov	x20, x0
	ldr	w0, [x21]
	bl	_value
	bl	_size
	mov	x2, x0
	mov	x0, x19
	mov	x1, x20
	bl	_write
LBB0_2:
	ldr	x8, [x22]
	ldr	w0, [x8, #4]
Lloh13:
	adrp	x1, l_.str@PAGE
Lloh14:
	add	x1, x1, l_.str@PAGEOFF
	mov	w2, #1
	bl	_write
Lloh15:
	adrp	x8, _repdes@GOTPAGE
Lloh16:
	ldr	x8, [x8, _repdes@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
	ldr	w0, [x8]
	add	x1, sp, #15
	mov	w2, #1
	bl	_read
	ldrb	w8, [sp, #15]
	cmp	w8, #110
	b.ne	LBB0_4
; %bb.3:
	ldr	w0, [x21]
	bl	_value
	mov	x1, x0
Lloh18:
	adrp	x0, l_.str.1@PAGE
Lloh19:
	add	x0, x0, l_.str.1@PAGEOFF
	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
	add	sp, sp, #64
	b	_printf
LBB0_4:
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_tipout_pid,4,2                 ; @tipout_pid
	.comm	_SIGEMT,4,2                     ; @SIGEMT
	.comm	_SCRIPT,4,2                     ; @SCRIPT
	.comm	_fildes,8,3                     ; @fildes
	.comm	_RECORD,4,2                     ; @RECORD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"\n"

	.comm	_repdes,8,3                     ; @repdes
l_.str.1:                               ; @.str.1
	.asciz	"can't create %s\r\n"

.subsections_via_symbols
