	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function editit
_editit:                                ## @editit
	.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	%rdi, -80(%rbp)                 ## 8-byte Spill
	leaq	L_.str(%rip), %rdi
	callq	_getenv
	movq	%rax, %r14
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	leaq	L_.str.1(%rip), %rdi
	callq	_getenv
	movq	%rax, %r14
LBB0_2:
	movq	__PATH_VI@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	_SIGHUP@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	movq	_SIG_IGN@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	callq	_signal
	movl	%eax, -60(%rbp)                 ## 4-byte Spill
	movq	_SIGINT@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	movl	(%r15), %esi
	callq	_signal
	movl	%eax, -56(%rbp)                 ## 4-byte Spill
	movq	_SIGQUIT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r15), %esi
	callq	_signal
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movq	_SIGCHLD@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SIG_DFL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_signal
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	xorl	%eax, %eax
	callq	_fork
	movl	%eax, %r13d
	cmpl	$-1, %eax
	je	LBB0_8
## %bb.3:
	testl	%r13d, %r13d
	je	LBB0_15
## %bb.4:
	movq	%r12, %r15
	leaq	-44(%rbp), %rbx
	movq	_errno@GOTPCREL(%rip), %r14
	movq	_EINTR@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movl	%r13d, %edi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_waitpid
	cmpl	$-1, %eax
	jne	LBB0_9
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	(%r14), %eax
	cmpl	(%r12), %eax
	je	LBB0_5
	jmp	LBB0_12
LBB0_8:
	movq	%r12, %r15
	jmp	LBB0_14
LBB0_9:
	movl	-44(%rbp), %edi
	callq	_WIFEXITED
	testl	%eax, %eax
	je	LBB0_11
## %bb.10:
	movl	-44(%rbp), %edi
	callq	_WEXITSTATUS
	movl	%eax, %r13d
	jmp	LBB0_13
LBB0_11:
	movl	(%r12), %eax
	movl	%eax, (%r14)
LBB0_12:
	movl	$-1, %r13d
LBB0_13:
	movq	_SIGHUP@GOTPCREL(%rip), %rbx
LBB0_14:
	movq	_errno@GOTPCREL(%rip), %r14
	movl	(%r14), %r12d
	movl	(%rbx), %edi
	movl	-60(%rbp), %esi                 ## 4-byte Reload
	callq	_signal
	movl	(%r15), %edi
	movl	-56(%rbp), %esi                 ## 4-byte Reload
	callq	_signal
	movq	_SIGQUIT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	-52(%rbp), %esi                 ## 4-byte Reload
	callq	_signal
	movq	_SIGCHLD@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	-48(%rbp), %esi                 ## 4-byte Reload
	callq	_signal
	movl	%r12d, (%r14)
	movl	%r13d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_15:
	testq	%r14, %r14
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	cmovneq	%r14, %rdi
	movq	%rdi, %rsi
	movq	-80(%rbp), %rdx                 ## 8-byte Reload
	xorl	%ecx, %ecx
	callq	_execlp
	movl	$127, %edi
	callq	__exit
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"VISUAL"

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

	.comm	__PATH_VI,8,3                   ## @_PATH_VI
	.comm	_SIGHUP,4,2                     ## @SIGHUP
	.comm	_SIG_IGN,4,2                    ## @SIG_IGN
	.comm	_SIGINT,4,2                     ## @SIGINT
	.comm	_SIGQUIT,4,2                    ## @SIGQUIT
	.comm	_SIGCHLD,4,2                    ## @SIGCHLD
	.comm	_SIG_DFL,4,2                    ## @SIG_DFL
	.comm	_errno,4,2                      ## @errno
	.comm	_EINTR,4,2                      ## @EINTR
	.no_dead_strip	_editit
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function editit
_editit:                                ; @editit
	.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
	str	x0, [sp]                        ; 8-byte Folded Spill
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_getenv
	mov	x25, x0
	cbnz	x0, LBB0_2
; %bb.1:
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_getenv
	mov	x25, x0
LBB0_2:
Lloh4:
	adrp	x8, __PATH_VI@GOTPAGE
Lloh5:
	ldr	x8, [x8, __PATH_VI@GOTPAGEOFF]
Lloh6:
	ldr	x26, [x8]
Lloh7:
	adrp	x8, _SIGHUP@GOTPAGE
Lloh8:
	ldr	x8, [x8, _SIGHUP@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
Lloh10:
	adrp	x21, _SIG_IGN@GOTPAGE
Lloh11:
	ldr	x21, [x21, _SIG_IGN@GOTPAGEOFF]
	ldr	w1, [x21]
	bl	_signal
	mov	x19, x0
Lloh12:
	adrp	x27, _SIGINT@GOTPAGE
Lloh13:
	ldr	x27, [x27, _SIGINT@GOTPAGEOFF]
	ldr	w0, [x27]
	ldr	w1, [x21]
	bl	_signal
	mov	x20, x0
Lloh14:
	adrp	x28, _SIGQUIT@GOTPAGE
Lloh15:
	ldr	x28, [x28, _SIGQUIT@GOTPAGEOFF]
	ldr	w0, [x28]
	ldr	w1, [x21]
	bl	_signal
	mov	x21, x0
Lloh16:
	adrp	x23, _SIGCHLD@GOTPAGE
Lloh17:
	ldr	x23, [x23, _SIGCHLD@GOTPAGEOFF]
	ldr	w0, [x23]
Lloh18:
	adrp	x8, _SIG_DFL@GOTPAGE
Lloh19:
	ldr	x8, [x8, _SIG_DFL@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	bl	_signal
	mov	x22, x0
	bl	_fork
	mov	x24, x0
	cmn	w0, #1
	b.eq	LBB0_11
; %bb.3:
	cbz	w24, LBB0_12
; %bb.4:
Lloh21:
	adrp	x25, _errno@GOTPAGE
Lloh22:
	ldr	x25, [x25, _errno@GOTPAGEOFF]
Lloh23:
	adrp	x26, _EINTR@GOTPAGE
Lloh24:
	ldr	x26, [x26, _EINTR@GOTPAGEOFF]
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	add	x1, sp, #12
	mov	x0, x24
	mov	w2, #0
	bl	_waitpid
	cmn	w0, #1
	b.ne	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x25]
	ldr	w9, [x26]
	cmp	w8, w9
	b.eq	LBB0_5
	b	LBB0_10
LBB0_7:
	ldr	w0, [sp, #12]
	bl	_WIFEXITED
	cbz	w0, LBB0_9
; %bb.8:
	ldr	w0, [sp, #12]
	bl	_WEXITSTATUS
	mov	x24, x0
	b	LBB0_11
LBB0_9:
	ldr	w8, [x26]
	str	w8, [x25]
LBB0_10:
	mov	w24, #-1
LBB0_11:
Lloh25:
	adrp	x25, _errno@GOTPAGE
Lloh26:
	ldr	x25, [x25, _errno@GOTPAGEOFF]
	ldr	w26, [x25]
Lloh27:
	adrp	x8, _SIGHUP@GOTPAGE
Lloh28:
	ldr	x8, [x8, _SIGHUP@GOTPAGEOFF]
Lloh29:
	ldr	w0, [x8]
	mov	x1, x19
	bl	_signal
	ldr	w0, [x27]
	mov	x1, x20
	bl	_signal
	ldr	w0, [x28]
	mov	x1, x21
	bl	_signal
	ldr	w0, [x23]
	mov	x1, x22
	bl	_signal
	str	w26, [x25]
	mov	x0, x24
	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
LBB0_12:
	cmp	x25, #0
	csel	x0, x26, x25, eq
	mov	x1, x0
	ldr	x2, [sp]                        ; 8-byte Folded Reload
	mov	x3, #0
	bl	_execlp
	mov	w0, #127
	bl	__exit
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"VISUAL"

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

	.comm	__PATH_VI,8,3                   ; @_PATH_VI
	.comm	_SIGHUP,4,2                     ; @SIGHUP
	.comm	_SIG_IGN,4,2                    ; @SIG_IGN
	.comm	_SIGINT,4,2                     ; @SIGINT
	.comm	_SIGQUIT,4,2                    ; @SIGQUIT
	.comm	_SIGCHLD,4,2                    ; @SIGCHLD
	.comm	_SIG_DFL,4,2                    ; @SIG_DFL
	.comm	_errno,4,2                      ; @errno
	.comm	_EINTR,4,2                      ; @EINTR
	.no_dead_strip	_editit
.subsections_via_symbols
