	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function shell_path
_shell_path:                            ## @shell_path
	.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
	movq	%rdx, %r14
	movq	%rsi, %r15
	movq	%rdi, %r12
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	testq	%rdx, %rdx
	je	LBB0_3
## %bb.1:
	movb	(%r14), %al
	testb	%al, %al
	je	LBB0_17
## %bb.2:
	cmpb	$47, %al
	je	LBB0_17
LBB0_3:
	movq	%rsp, -56(%rbp)                 ## 8-byte Spill
	movq	__UC_MAXLINE@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	%r13, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %rbx
	movq	%rbx, %rdi
	movq	%r12, %rsi
	movl	%r13d, %edx
	callq	_strlcpy
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	callq	_strtok
	testq	%rax, %rax
	je	LBB0_10
## %bb.4:
	movq	%rax, %r13
	leaq	_shell_path.shellpath(%rip), %rbx
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_5 Depth=1
	movq	%rbx, %rdi
	movl	$256, %esi                      ## imm = 0x100
	leaq	L_.str.1(%rip), %rdx
	movq	%r13, %rcx
	movq	%r14, %r8
	callq	_snprintf
	movq	_X_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_access
	testq	%rax, %rax
	je	LBB0_16
LBB0_9:                                 ##   in Loop: Header=BB0_5 Depth=1
	xorl	%edi, %edi
	leaq	L_.str(%rip), %rsi
	callq	_strtok
	movq	%rax, %r13
	testq	%rax, %rax
	je	LBB0_10
LBB0_5:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_14 Depth 2
	testq	%r14, %r14
	jne	LBB0_8
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	__UC_MAXSHELLS@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	jle	LBB0_9
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=1
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_14:                                ##   Parent Loop BB0_5 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	(%r15,%r12,8), %r8
	testq	%r8, %r8
	je	LBB0_9
## %bb.15:                              ##   in Loop: Header=BB0_14 Depth=2
	movq	%rbx, %rdi
	movl	$256, %esi                      ## imm = 0x100
	leaq	L_.str.1(%rip), %rdx
	movq	%r13, %rcx
	callq	_snprintf
	movq	_X_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_access
	testq	%rax, %rax
	je	LBB0_16
## %bb.13:                              ##   in Loop: Header=BB0_14 Depth=2
	incq	%r12
	movq	__UC_MAXSHELLS@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	cmpq	%rax, %r12
	jl	LBB0_14
	jmp	LBB0_9
LBB0_10:
	testq	%r14, %r14
	jne	LBB0_12
## %bb.11:
	movq	_EX_OSFILE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%edx, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_12:
	movq	_EX_CONFIG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.3(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_errx
LBB0_16:
	movq	-56(%rbp), %rsp                 ## 8-byte Reload
	movq	%rbx, %r14
LBB0_17:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_19
## %bb.18:
	movq	%r14, %rax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_19:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	__UC_MAXLINE,4,2                ## @_UC_MAXLINE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	": \t\r\n"

.zerofill __DATA,__bss,_shell_path.shellpath,256,4 ## @shell_path.shellpath
L_.str.1:                               ## @.str.1
	.asciz	"%s/%s"

	.comm	_X_OK,4,2                       ## @X_OK
	.comm	__UC_MAXSHELLS,4,2              ## @_UC_MAXSHELLS
	.comm	_EX_OSFILE,4,2                  ## @EX_OSFILE
L_.str.2:                               ## @.str.2
	.asciz	"can't find shell `%s' in shell paths"

	.comm	_EX_CONFIG,4,2                  ## @EX_CONFIG
L_.str.3:                               ## @.str.3
	.asciz	"no default shell available or defined"

	.no_dead_strip	_shell_path
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function shell_path
_shell_path:                            ; @shell_path
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	sub	sp, sp, #16
	mov	x19, x2
	mov	x20, x1
	mov	x1, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
	cbz	x2, LBB0_3
; %bb.1:
	ldrb	w8, [x19]
	cbz	w8, LBB0_18
; %bb.2:
	cmp	w8, #47
	b.eq	LBB0_18
LBB0_3:
	mov	x25, sp
Lloh3:
	adrp	x8, __UC_MAXLINE@GOTPAGE
Lloh4:
	ldr	x8, [x8, __UC_MAXLINE@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x9, x2
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	add	x9, x2, #15
	and	x9, x9, #0x1fffffff0
	sub	x21, x8, x9
	mov	sp, x21
	mov	x0, x21
                                        ; kill: def $w2 killed $w2 killed $x2
	bl	_strlcpy
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x21
	bl	_strtok
	cbz	x0, LBB0_13
; %bb.4:
	mov	x24, x0
Lloh10:
	adrp	x26, __UC_MAXSHELLS@GOTPAGE
Lloh11:
	ldr	x26, [x26, __UC_MAXSHELLS@GOTPAGEOFF]
Lloh12:
	adrp	x21, _shell_path.shellpath@PAGE
Lloh13:
	add	x21, x21, _shell_path.shellpath@PAGEOFF
Lloh14:
	adrp	x22, l_.str.1@PAGE
Lloh15:
	add	x22, x22, l_.str.1@PAGEOFF
Lloh16:
	adrp	x27, _X_OK@GOTPAGE
Lloh17:
	ldr	x27, [x27, _X_OK@GOTPAGEOFF]
Lloh18:
	adrp	x23, l_.str@PAGE
Lloh19:
	add	x23, x23, l_.str@PAGEOFF
	b	LBB0_7
LBB0_5:                                 ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x21
	mov	w1, #256
	mov	x2, x22
	mov	x3, x24
	mov	x4, x19
	bl	_snprintf
	ldr	w1, [x27]
	mov	x0, x21
	bl	_access
	cbz	x0, LBB0_16
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, #0
	mov	x1, x23
	bl	_strtok
	mov	x24, x0
	cbz	x0, LBB0_13
LBB0_7:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_10 Depth 2
	cbnz	x19, LBB0_5
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	w8, [x26]
	cmp	w8, #1
	b.lt	LBB0_6
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	x28, #0
LBB0_10:                                ;   Parent Loop BB0_7 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x4, [x20, x28, lsl #3]
	cbz	x4, LBB0_6
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=2
	mov	x0, x21
	mov	w1, #256
	mov	x2, x22
	mov	x3, x24
	bl	_snprintf
	ldr	w1, [x27]
	mov	x0, x21
	bl	_access
	cbz	x0, LBB0_16
; %bb.12:                               ;   in Loop: Header=BB0_10 Depth=2
	add	x28, x28, #1
	ldrsw	x8, [x26]
	cmp	x28, x8
	b.lt	LBB0_10
	b	LBB0_6
LBB0_13:
	cbnz	x19, LBB0_15
; %bb.14:
Lloh20:
	adrp	x8, _EX_OSFILE@GOTPAGE
Lloh21:
	ldr	x8, [x8, _EX_OSFILE@GOTPAGEOFF]
Lloh22:
	ldr	w0, [x8]
	str	xzr, [sp, #-16]!
Lloh23:
	adrp	x1, l_.str.2@PAGE
Lloh24:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_errx
	add	sp, sp, #16
LBB0_15:
Lloh25:
	adrp	x8, _EX_CONFIG@GOTPAGE
Lloh26:
	ldr	x8, [x8, _EX_CONFIG@GOTPAGEOFF]
Lloh27:
	ldr	w0, [x8]
Lloh28:
	adrp	x1, l_.str.3@PAGE
Lloh29:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_errx
	mov	x19, #0
	b	LBB0_17
LBB0_16:
	mov	x19, x21
LBB0_17:
	mov	sp, x25
LBB0_18:
	ldur	x8, [x29, #-88]
Lloh30:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh31:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh32:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_20
; %bb.19:
	mov	x0, x19
	sub	sp, x29, #80
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_20:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.comm	__UC_MAXLINE,4,2                ; @_UC_MAXLINE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	": \t\r\n"

.zerofill __DATA,__bss,_shell_path.shellpath,256,0 ; @shell_path.shellpath
l_.str.1:                               ; @.str.1
	.asciz	"%s/%s"

	.comm	_X_OK,4,2                       ; @X_OK
	.comm	__UC_MAXSHELLS,4,2              ; @_UC_MAXSHELLS
	.comm	_EX_OSFILE,4,2                  ; @EX_OSFILE
l_.str.2:                               ; @.str.2
	.asciz	"can't find shell `%s' in shell paths"

	.comm	_EX_CONFIG,4,2                  ; @EX_CONFIG
l_.str.3:                               ; @.str.3
	.asciz	"no default shell available or defined"

	.no_dead_strip	_shell_path
.subsections_via_symbols
