	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__citrus_esdb_open              ## -- Begin function _citrus_esdb_open
	.p2align	4, 0x90
__citrus_esdb_open:                     ## @_citrus_esdb_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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, -88(%rbp)                 ## 8-byte Spill
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	movq	%rsp, -96(%rbp)                 ## 8-byte Spill
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_PATH_MAX@GOTPCREL(%rip), %rbx
	movl	(%rbx), %r14d
	movq	%r14, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, -72(%rbp)                 ## 8-byte Spill
	movl	(%rbx), %r15d
	movq	%r15, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, -80(%rbp)                 ## 8-byte Spill
	movq	%r15, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %rbx
	movq	__PATH_ESDB@GOTPCREL(%rip), %r12
	movq	(%r12), %rcx
	movq	_ESDB_ALIAS@GOTPCREL(%rip), %rax
	movq	(%rax), %r8
	leaq	L_.str(%rip), %rdx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_snprintf
	movq	__LOOKUP_CASE_IGNORE@GOTPCREL(%rip), %r13
	movl	(%r13), %r8d
	movq	%rbx, %rdi
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
	movq	-72(%rbp), %rdx                 ## 8-byte Reload
	movl	%r14d, %ecx
	callq	__lookup_alias
	movq	%rax, %r14
	movq	(%r12), %rcx
	movq	_ESDB_DIR@GOTPCREL(%rip), %rax
	movq	(%rax), %r8
	movq	%rbx, %rdi
	movl	%r15d, %esi
	leaq	L_.str(%rip), %rdx
	callq	_snprintf
	movl	(%r13), %r8d
	movq	%rbx, %rdi
	movq	%r14, %rsi
	movq	-80(%rbp), %rdx                 ## 8-byte Reload
	movl	%r15d, %ecx
	callq	__lookup_simple
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	(%r12), %rcx
	leaq	L_.str(%rip), %rdx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	movq	%rax, %r8
	callq	_snprintf
	leaq	-56(%rbp), %rdi
	movq	%rbx, %rsi
	callq	__map_file
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_4
## %bb.3:
	leaq	-56(%rbp), %r14
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%r14, %rsi
	callq	_conv_esdb
	movl	%eax, %ebx
	movq	%r14, %rdi
	callq	__unmap_file
	jmp	LBB0_4
LBB0_1:
	movq	_ENOENT@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
LBB0_4:
	movq	-96(%rbp), %rsp                 ## 8-byte Reload
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_6
## %bb.5:
	movl	%ebx, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_PATH_MAX,4,2                   ## @PATH_MAX
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s/%s"

	.comm	__PATH_ESDB,8,3                 ## @_PATH_ESDB
	.comm	_ESDB_ALIAS,8,3                 ## @ESDB_ALIAS
	.comm	__LOOKUP_CASE_IGNORE,4,2        ## @_LOOKUP_CASE_IGNORE
	.comm	_ESDB_DIR,8,3                   ## @ESDB_DIR
	.comm	_ENOENT,4,2                     ## @ENOENT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__citrus_esdb_open              ; -- Begin function _citrus_esdb_open
	.p2align	2
__citrus_esdb_open:                     ; @_citrus_esdb_open
	.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, #32
	mov	x22, x1
	stur	x0, [x29, #-104]                ; 8-byte Folded Spill
	mov	x27, sp
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _PATH_MAX@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PATH_MAX@GOTPAGEOFF]
	ldr	w23, [x8]
	mov	x9, x23
Lloh5:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh6:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x10, x23, #15
	and	x10, x10, #0x1fffffff0
	sub	x24, x9, x10
	mov	sp, x24
	ldr	w20, [x8]
	mov	x9, x20
Lloh7:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh8:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	add	x9, x20, #15
	and	x12, x9, #0x1fffffff0
	sub	x25, x8, x12
	mov	sp, x25
	mov	x9, x20
Lloh9:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh10:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	sub	x21, x8, x12
	mov	sp, x21
Lloh11:
	adrp	x28, __PATH_ESDB@GOTPAGE
Lloh12:
	ldr	x28, [x28, __PATH_ESDB@GOTPAGEOFF]
	ldr	x3, [x28]
Lloh13:
	adrp	x8, _ESDB_ALIAS@GOTPAGE
Lloh14:
	ldr	x8, [x8, _ESDB_ALIAS@GOTPAGEOFF]
Lloh15:
	ldr	x4, [x8]
Lloh16:
	adrp	x26, l_.str@PAGE
Lloh17:
	add	x26, x26, l_.str@PAGEOFF
	mov	x0, x21
	mov	x1, x20
	mov	x2, x26
	bl	_snprintf
Lloh18:
	adrp	x19, __LOOKUP_CASE_IGNORE@GOTPAGE
Lloh19:
	ldr	x19, [x19, __LOOKUP_CASE_IGNORE@GOTPAGEOFF]
	ldr	w4, [x19]
	mov	x0, x21
	mov	x1, x22
	mov	x2, x24
	mov	x3, x23
	bl	__lookup_alias
	mov	x22, x0
	ldr	x3, [x28]
Lloh20:
	adrp	x8, _ESDB_DIR@GOTPAGE
Lloh21:
	ldr	x8, [x8, _ESDB_DIR@GOTPAGEOFF]
Lloh22:
	ldr	x4, [x8]
	mov	x0, x21
	mov	x1, x20
	mov	x2, x26
	bl	_snprintf
	ldr	w4, [x19]
	mov	x0, x21
	mov	x1, x22
	mov	x2, x25
	mov	x3, x20
	bl	__lookup_simple
	cbz	x0, LBB0_3
; %bb.1:
	mov	x4, x0
	ldr	x3, [x28]
Lloh23:
	adrp	x2, l_.str@PAGE
Lloh24:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x21
	mov	x1, x20
	bl	_snprintf
	sub	x0, x29, #96
	mov	x1, x21
	bl	__map_file
	mov	x20, x0
	cbnz	w0, LBB0_4
; %bb.2:
	sub	x1, x29, #96
	ldur	x0, [x29, #-104]                ; 8-byte Folded Reload
	bl	_conv_esdb
	mov	x20, x0
	sub	x0, x29, #96
	bl	__unmap_file
	b	LBB0_4
LBB0_3:
Lloh25:
	adrp	x8, _ENOENT@GOTPAGE
Lloh26:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
Lloh27:
	ldr	w20, [x8]
LBB0_4:
	mov	sp, x27
	ldur	x8, [x29, #-88]
Lloh28:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh29:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh30:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_6
; %bb.5:
	mov	x0, x20
	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_6:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.cfi_endproc
                                        ; -- End function
	.comm	_PATH_MAX,4,2                   ; @PATH_MAX
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s/%s"

	.comm	__PATH_ESDB,8,3                 ; @_PATH_ESDB
	.comm	_ESDB_ALIAS,8,3                 ; @ESDB_ALIAS
	.comm	__LOOKUP_CASE_IGNORE,4,2        ; @_LOOKUP_CASE_IGNORE
	.comm	_ESDB_DIR,8,3                   ; @ESDB_DIR
	.comm	_ENOENT,4,2                     ; @ENOENT
.subsections_via_symbols
