	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function memjrnlCreateFile
_memjrnlCreateFile:                     ## @memjrnlCreateFile
	.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	%rdi, %rbx
	movq	32(%rdi), %rax
	movq	%rax, -64(%rbp)
	movups	(%rdi), %xmm0
	movups	16(%rdi), %xmm1
	movaps	%xmm1, -80(%rbp)
	movaps	%xmm0, -96(%rbp)
	xorl	%esi, %esi
	movl	$40, %edx
	callq	_memset
	movl	-64(%rbp), %edi
	movl	-72(%rbp), %ecx
	movl	-68(%rbp), %esi
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdx
	xorl	%r8d, %r8d
	callq	_sqlite3OsOpen
	movl	%eax, %ebx
	movq	_SQLITE_OK@GOTPCREL(%rip), %r14
	movl	(%r14), %eax
	cmpl	%eax, %ebx
	jne	LBB0_7
## %bb.1:
	movq	-80(%rbp), %r13
	testq	%r13, %r13
	je	LBB0_6
## %bb.2:
	movl	-96(%rbp), %ebx
	movq	-88(%rbp), %r14
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movslq	%ebx, %rbx
	leaq	(%r12,%rbx), %rax
	movl	%r14d, %ecx
	subl	%r12d, %ecx
	cmpq	%r14, %rax
	cmovgl	%ecx, %ebx
	movq	(%r13), %rsi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movl	%ebx, %edx
	movq	%r12, %rcx
	callq	_sqlite3OsWrite
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	movslq	%ebx, %rax
	addq	%rax, %r12
	movq	8(%r13), %r13
	testq	%r13, %r13
	jne	LBB0_3
LBB0_5:
	movq	_SQLITE_OK@GOTPCREL(%rip), %r14
	movl	(%r14), %ebx
	movl	%ebx, %eax
	cmpl	%ebx, %r15d
	jne	LBB0_8
LBB0_6:
	leaq	-96(%rbp), %rdi
	callq	_memjrnlFreeChunks
	movl	(%r14), %eax
LBB0_7:
	movl	%ebx, %r15d
LBB0_8:
	cmpl	%eax, %r15d
	je	LBB0_10
## %bb.9:
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	callq	_sqlite3OsClose
	movaps	-96(%rbp), %xmm0
	movaps	-80(%rbp), %xmm1
	movups	%xmm0, (%rbx)
	movups	%xmm1, 16(%rbx)
	movq	-64(%rbp), %rax
	movq	%rax, 32(%rbx)
LBB0_10:
	movl	%r15d, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SQLITE_OK,4,2                  ## @SQLITE_OK
	.no_dead_strip	_memjrnlCreateFile
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function memjrnlCreateFile
_memjrnlCreateFile:                     ; @memjrnlCreateFile
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	mov	x19, x0
	ldp	q0, q1, [x0]
	stp	q0, q1, [sp]
	ldr	x8, [x0, #32]
	str	x8, [sp, #32]
	mov	w1, #0
	mov	w2, #40
	bl	_memset
	ldp	w1, w0, [sp, #28]
	ldr	w3, [sp, #24]
	mov	x2, x19
	mov	w4, #0
	bl	_sqlite3OsOpen
	mov	x21, x0
Lloh0:
	adrp	x23, _SQLITE_OK@GOTPAGE
Lloh1:
	ldr	x23, [x23, _SQLITE_OK@GOTPAGEOFF]
	ldr	w8, [x23]
	cmp	w0, w8
	b.ne	LBB0_7
; %bb.1:
	ldr	x24, [sp, #16]
	cbz	x24, LBB0_6
; %bb.2:
	mov	x21, #0
	ldr	w22, [sp]
	ldr	x25, [sp, #8]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	add	x8, x21, w22, sxtw
	sub	w9, w25, w21
	cmp	x8, x25
	csel	w22, w9, w22, gt
	ldr	x1, [x24]
	mov	x0, x19
	mov	x2, x22
	mov	x3, x21
	bl	_sqlite3OsWrite
	mov	x20, x0
	cbnz	w0, LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x21, x21, w22, sxtw
	ldr	x24, [x24, #8]
	cbnz	x24, LBB0_3
LBB0_5:
	ldr	w21, [x23]
	mov	x8, x21
	cmp	w20, w21
	b.ne	LBB0_8
LBB0_6:
	mov	x0, sp
	bl	_memjrnlFreeChunks
	ldr	w8, [x23]
LBB0_7:
	mov	x20, x21
LBB0_8:
	cmp	w20, w8
	b.eq	LBB0_10
; %bb.9:
	mov	x0, x19
	bl	_sqlite3OsClose
	ldp	q0, q1, [sp]
	stp	q0, q1, [x19]
	ldr	x8, [sp, #32]
	str	x8, [x19, #32]
LBB0_10:
	mov	x0, x20
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_SQLITE_OK,4,2                  ; @SQLITE_OK
	.no_dead_strip	_memjrnlCreateFile
.subsections_via_symbols
