	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_git_editor                     ## -- Begin function git_editor
	.p2align	4, 0x90
_git_editor:                            ## @git_editor
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	leaq	L_.str(%rip), %rdi
	callq	_getenv
	movq	%rax, %rbx
	xorl	%eax, %eax
	callq	_is_terminal_dumb
	movl	%eax, %r14d
	movq	_editor_program@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	testq	%rax, %rax
	cmoveq	%rbx, %rax
	testq	%rbx, %rbx
	cmovneq	%rbx, %rax
	testq	%rax, %rax
	jne	LBB0_3
## %bb.1:
	testl	%r14d, %r14d
	jne	LBB0_3
## %bb.2:
	leaq	L_.str.1(%rip), %rdi
	callq	_getenv
LBB0_3:
	testq	%rax, %rax
	jne	LBB0_5
## %bb.4:
	leaq	L_.str.2(%rip), %rdi
	callq	_getenv
LBB0_5:
	movq	%rax, %rdx
	testq	%rax, %rax
	jne	LBB0_7
## %bb.6:
	movq	_DEFAULT_EDITOR@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdx
LBB0_7:
	xorl	%ecx, %ecx
	testl	%r14d, %r14d
	cmoveq	%rdx, %rcx
	testq	%rax, %rax
	cmovneq	%rdx, %rcx
	movq	%rcx, %rax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"GIT_EDITOR"

	.comm	_editor_program,8,3             ## @editor_program
L_.str.1:                               ## @.str.1
	.asciz	"VISUAL"

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

	.comm	_DEFAULT_EDITOR,8,3             ## @DEFAULT_EDITOR
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_git_editor                     ; -- Begin function git_editor
	.p2align	2
_git_editor:                            ; @git_editor
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_getenv
	mov	x20, x0
	bl	_is_terminal_dumb
	mov	x19, x0
Lloh2:
	adrp	x8, _editor_program@GOTPAGE
Lloh3:
	ldr	x8, [x8, _editor_program@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	cmp	x8, #0
	ccmp	x20, #0, #0, ne
	csel	x0, x8, x20, eq
	cmp	x0, #0
	ccmp	w19, #0, #0, eq
	b.ne	LBB0_2
; %bb.1:
Lloh5:
	adrp	x0, l_.str.1@PAGE
Lloh6:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_getenv
LBB0_2:
	cbnz	x0, LBB0_4
; %bb.3:
Lloh7:
	adrp	x0, l_.str.2@PAGE
Lloh8:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_getenv
LBB0_4:
Lloh9:
	adrp	x8, _DEFAULT_EDITOR@GOTPAGE
Lloh10:
	ldr	x8, [x8, _DEFAULT_EDITOR@GOTPAGEOFF]
Lloh11:
	ldr	x8, [x8]
	cmp	x0, #0
	csel	x8, x8, x0, eq
	cmp	w19, #0
	ccmp	x0, #0, #0, ne
	csel	x0, xzr, x8, eq
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"GIT_EDITOR"

	.comm	_editor_program,8,3             ; @editor_program
l_.str.1:                               ; @.str.1
	.asciz	"VISUAL"

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

	.comm	_DEFAULT_EDITOR,8,3             ; @DEFAULT_EDITOR
.subsections_via_symbols
