	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function splitfs_open
_splitfs_open:                          ## @splitfs_open
	.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	(%rsi), %rax
	movq	_F_READ@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_19
## %bb.1:
	movq	%rsi, %r14
	movq	%rdi, %r15
	movl	$46, %esi
	callq	_strrchr
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rsi
	movq	%rax, %rdi
	callq	_strcmp
	testl	%eax, %eax
	je	LBB0_24
LBB0_3:
	movq	%r15, %rdi
	callq	_strlen
                                        ## kill: def $eax killed $eax def $rax
	leal	7(%rax), %edi
	callq	_malloc
	movq	%rax, %rbx
	leaq	L_.str.1(%rip), %rsi
	movq	%rax, %rdi
	movq	%r15, %rdx
	callq	_sprintf
	movq	_O_RDONLY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_open
	movl	%eax, %r15d
	movq	%rbx, %rdi
	callq	_free
	cmpl	$-1, %r15d
	je	LBB0_24
## %bb.4:
	leaq	-48(%rbp), %rsi
	movl	%r15d, %edi
	callq	_fstat
	testq	%rax, %rax
	js	LBB0_23
## %bb.5:
	movl	-48(%rbp), %edi
	callq	_S_ISREG
	testl	%eax, %eax
	je	LBB0_27
## %bb.6:
	movq	%r14, -56(%rbp)                 ## 8-byte Spill
	movl	$24, %edi
	callq	_malloc
	movq	%rax, %r13
	movq	%rax, %rdi
	movl	$24, %esi
	callq	_bzero
	movq	_CONF_BUF@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	callq	_malloc
	movq	%rax, %r12
	movl	(%rbx), %esi
	movq	%rax, %rdi
	movl	%r15d, %edx
	callq	_fgetstr
	testq	%rax, %rax
	jle	LBB0_20
## %bb.7:
	movq	%r12, %rax
	incq	%rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_10 Depth 2
                                        ##     Child Loop BB0_14 Depth 2
	movb	(%r12), %al
	testb	%al, %al
	je	LBB0_16
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_10:                                ##   Parent Loop BB0_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movsbl	%al, %edi
	callq	_isspace
	testq	%rax, %rax
	jne	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=2
	movzbl	(%rbx), %eax
	incq	%rbx
	testb	%al, %al
	jne	LBB0_10
	jmp	LBB0_16
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_8 Depth=1
	cmpb	$0, -1(%rbx)
	je	LBB0_16
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=1
	movb	$0, -1(%rbx)
	movb	(%rbx), %al
	testb	%al, %al
	je	LBB0_16
	.p2align	4, 0x90
LBB0_14:                                ##   Parent Loop BB0_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movsbl	%al, %edi
	callq	_isspace
	testq	%rax, %rax
	je	LBB0_18
## %bb.15:                              ##   in Loop: Header=BB0_14 Depth=2
	movzbl	1(%rbx), %eax
	incq	%rbx
	testb	%al, %al
	jne	LBB0_14
	.p2align	4, 0x90
LBB0_16:                                ##   in Loop: Header=BB0_8 Depth=1
	movq	%r12, %rbx
LBB0_17:                                ##   in Loop: Header=BB0_8 Depth=1
	movl	(%r13), %eax
	leal	1(%rax), %ecx
	movl	%ecx, (%r13)
	movq	16(%r13), %rdi
	leal	8(,%rax,8), %esi
	callq	_realloc
	movq	%rax, 16(%r13)
	movq	8(%r13), %rdi
	movl	(%r13), %esi
	shll	$3, %esi
	callq	_realloc
	movq	%rax, 8(%r13)
	movq	%r12, %rdi
	callq	_strdup
	movq	16(%r13), %rcx
	movslq	(%r13), %r14
	movq	%rax, -8(%rcx,%r14,8)
	movq	%rbx, %rdi
	callq	_strdup
	movq	8(%r13), %rcx
	movq	%rax, -8(%rcx,%r14,8)
	movq	_CONF_BUF@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	movl	%r15d, %edx
	callq	_fgetstr
	testq	%rax, %rax
	jg	LBB0_8
	jmp	LBB0_20
LBB0_18:                                ##   in Loop: Header=BB0_8 Depth=1
	cmpb	$0, (%rbx)
	jne	LBB0_17
	jmp	LBB0_16
LBB0_19:
	movq	_EPERM@GOTPCREL(%rip), %rax
	jmp	LBB0_25
LBB0_20:
	movq	%r12, %rdi
	callq	_free
	movl	%r15d, %edi
	callq	_close
	cmpl	$0, (%r13)
	je	LBB0_22
## %bb.21:
	movq	%r13, %rdi
	callq	_split_openfile
	movq	_errno@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	testq	%rax, %rax
	je	LBB0_28
LBB0_22:
	movq	%r13, %rdi
	callq	_split_file_destroy
	jmp	LBB0_24
LBB0_23:
	leaq	L_str.4(%rip), %rdi
	callq	_puts
	movl	%r15d, %edi
	callq	_close
LBB0_24:
	movq	_ENOENT@GOTPCREL(%rip), %rax
LBB0_25:
	movl	(%rax), %eax
LBB0_26:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_27:
	leaq	L_str(%rip), %rdi
	callq	_puts
	movl	%r15d, %edi
	callq	_close
	movq	_EISDIR@GOTPCREL(%rip), %rax
	jmp	LBB0_25
LBB0_28:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	%r13, 8(%rax)
	xorl	%eax, %eax
	jmp	LBB0_26
	.cfi_endproc
                                        ## -- End function
	.comm	_F_READ,8,3                     ## @F_READ
	.comm	_EPERM,4,2                      ## @EPERM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	".split"

	.comm	_ENOENT,4,2                     ## @ENOENT
L_.str.1:                               ## @.str.1
	.asciz	"%s.split"

	.comm	_O_RDONLY,4,2                   ## @O_RDONLY
	.comm	_EISDIR,4,2                     ## @EISDIR
	.comm	_CONF_BUF,4,2                   ## @CONF_BUF
	.comm	_errno,8,3                      ## @errno
L_str:                                  ## @str
	.asciz	"splitfs_open: not a file"

L_str.4:                                ## @str.4
	.asciz	"splitfs_open: stat failed"

	.no_dead_strip	_splitfs_open
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function splitfs_open
_splitfs_open:                          ; @splitfs_open
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.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
	ldr	x8, [x1]
Lloh0:
	adrp	x9, _F_READ@GOTPAGE
Lloh1:
	ldr	x9, [x9, _F_READ@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_22
; %bb.1:
	mov	x19, x1
	mov	x20, x0
	mov	w1, #46
	bl	_strrchr
	cbz	x0, LBB0_3
; %bb.2:
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_strcmp
	cbz	w0, LBB0_24
LBB0_3:
	mov	x0, x20
	bl	_strlen
	add	w0, w0, #7
	bl	_malloc
	mov	x21, x0
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x20
	bl	_sprintf
Lloh7:
	adrp	x8, _O_RDONLY@GOTPAGE
Lloh8:
	ldr	x8, [x8, _O_RDONLY@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_open
	mov	x20, x0
	mov	x0, x21
	bl	_free
	cmn	w20, #1
	b.eq	LBB0_24
; %bb.4:
	add	x1, sp, #8
	mov	x0, x20
	bl	_fstat
	tbnz	x0, #63, LBB0_23
; %bb.5:
	ldr	w0, [sp, #8]
	bl	_S_ISREG
	cbz	w0, LBB0_27
; %bb.6:
	mov	w0, #24
	bl	_malloc
	mov	x21, x0
	mov	w1, #24
	bl	_bzero
Lloh10:
	adrp	x24, _CONF_BUF@GOTPAGE
Lloh11:
	ldr	x24, [x24, _CONF_BUF@GOTPAGEOFF]
	ldr	w0, [x24]
	bl	_malloc
	mov	x22, x0
	ldr	w1, [x24]
	mov	x2, x20
	bl	_fgetstr
	cmp	x0, #1
	b.lt	LBB0_19
; %bb.7:
	add	x25, x22, #1
LBB0_8:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_10 Depth 2
                                        ;     Child Loop BB0_14 Depth 2
	ldrb	w8, [x22]
	cbz	w8, LBB0_17
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	mov	x23, x25
LBB0_10:                                ;   Parent Loop BB0_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	sxtb	w0, w8
	bl	_isspace
	cbnz	x0, LBB0_12
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=2
	ldrb	w8, [x23], #1
	cbnz	w8, LBB0_10
	b	LBB0_17
LBB0_12:                                ;   in Loop: Header=BB0_8 Depth=1
	ldurb	w8, [x23, #-1]
	cbz	w8, LBB0_17
; %bb.13:                               ;   in Loop: Header=BB0_8 Depth=1
	sturb	wzr, [x23, #-1]
	ldrb	w8, [x23]
	cbz	w8, LBB0_17
LBB0_14:                                ;   Parent Loop BB0_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	sxtb	w0, w8
	bl	_isspace
	cbz	x0, LBB0_16
; %bb.15:                               ;   in Loop: Header=BB0_14 Depth=2
	ldrb	w8, [x23, #1]!
	cbnz	w8, LBB0_14
	b	LBB0_17
LBB0_16:                                ;   in Loop: Header=BB0_8 Depth=1
	ldrb	w8, [x23]
	cbnz	w8, LBB0_18
LBB0_17:                                ;   in Loop: Header=BB0_8 Depth=1
	mov	x23, x22
LBB0_18:                                ;   in Loop: Header=BB0_8 Depth=1
	ldr	w8, [x21]
	add	w8, w8, #1
	str	w8, [x21]
	ldr	x0, [x21, #16]
	lsl	w1, w8, #3
	bl	_realloc
	str	x0, [x21, #16]
	ldr	x0, [x21, #8]
	ldr	w8, [x21]
	lsl	w1, w8, #3
	bl	_realloc
	str	x0, [x21, #8]
	mov	x0, x22
	bl	_strdup
	ldr	x8, [x21, #16]
	ldrsw	x9, [x21]
	lsl	x9, x9, #3
	sub	x26, x9, #8
	str	x0, [x8, x26]
	mov	x0, x23
	bl	_strdup
	ldr	x8, [x21, #8]
	str	x0, [x8, x26]
	ldr	w1, [x24]
	mov	x0, x22
	mov	x2, x20
	bl	_fgetstr
	cmp	x0, #0
	b.gt	LBB0_8
LBB0_19:
	mov	x0, x22
	bl	_free
	mov	x0, x20
	bl	_close
	ldr	w8, [x21]
	cbz	w8, LBB0_21
; %bb.20:
	mov	x0, x21
	bl	_split_openfile
Lloh12:
	adrp	x8, _errno@GOTPAGE
Lloh13:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh14:
	str	x0, [x8]
	cbz	x0, LBB0_28
LBB0_21:
	mov	x0, x21
	bl	_split_file_destroy
	b	LBB0_24
LBB0_22:
Lloh15:
	adrp	x8, _EPERM@GOTPAGE
Lloh16:
	ldr	x8, [x8, _EPERM@GOTPAGEOFF]
	b	LBB0_25
LBB0_23:
Lloh17:
	adrp	x0, l_str.4@PAGE
Lloh18:
	add	x0, x0, l_str.4@PAGEOFF
	bl	_puts
	mov	x0, x20
	bl	_close
LBB0_24:
Lloh19:
	adrp	x8, _ENOENT@GOTPAGE
Lloh20:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
LBB0_25:
	ldr	w0, [x8]
LBB0_26:
	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
	add	sp, sp, #96
	ret
LBB0_27:
Lloh21:
	adrp	x0, l_str@PAGE
Lloh22:
	add	x0, x0, l_str@PAGEOFF
	bl	_puts
	mov	x0, x20
	bl	_close
Lloh23:
	adrp	x8, _EISDIR@GOTPAGE
Lloh24:
	ldr	x8, [x8, _EISDIR@GOTPAGEOFF]
	b	LBB0_25
LBB0_28:
	str	x21, [x19, #8]
	b	LBB0_26
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotStr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpAdd	Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_F_READ,8,3                     ; @F_READ
	.comm	_EPERM,4,2                      ; @EPERM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	".split"

	.comm	_ENOENT,4,2                     ; @ENOENT
l_.str.1:                               ; @.str.1
	.asciz	"%s.split"

	.comm	_O_RDONLY,4,2                   ; @O_RDONLY
	.comm	_EISDIR,4,2                     ; @EISDIR
	.comm	_CONF_BUF,4,2                   ; @CONF_BUF
	.comm	_errno,8,3                      ; @errno
l_str:                                  ; @str
	.asciz	"splitfs_open: not a file"

l_str.4:                                ; @str.4
	.asciz	"splitfs_open: stat failed"

	.no_dead_strip	_splitfs_open
.subsections_via_symbols
