	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function relocatePage
_relocatePage:                          ## @relocatePage
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r9d, -72(%rbp)                 ## 4-byte Spill
	movl	%r8d, %r13d
	movl	%ecx, -52(%rbp)                 ## 4-byte Spill
	movl	%edx, %ebx
	movq	%rsi, %r14
	movq	%rdi, %r12
	movl	(%rsi), %r15d
	movq	8(%rdi), %rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	movq	_PTRMAP_OVERFLOW2@GOTPCREL(%rip), %rax
	cmpl	%edx, (%rax)
	sete	%al
	movq	_PTRMAP_OVERFLOW1@GOTPCREL(%rip), %rcx
	cmpl	%edx, (%rcx)
	sete	%cl
	orb	%al, %cl
	movq	_PTRMAP_BTREE@GOTPCREL(%rip), %rax
	cmpl	%edx, (%rax)
	sete	%al
	movq	_PTRMAP_ROOTPAGE@GOTPCREL(%rip), %rdx
	cmpl	%ebx, (%rdx)
	sete	%dl
	orb	%al, %dl
	orb	%cl, %dl
	movzbl	%dl, %edi
	callq	_assert
	movl	(%r12), %edi
	callq	_sqlite3_mutex_held
	movl	%eax, %edi
	callq	_assert
	xorl	%edi, %edi
	cmpq	%r12, 16(%r14)
	sete	%dil
	callq	_assert
	movl	%r15d, -68(%rbp)                ## 4-byte Spill
	cmpl	$2, %r15d
	jg	LBB0_2
## %bb.1:
	movq	_SQLITE_CORRUPT_BKPT@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	jmp	LBB0_15
LBB0_2:
	movslq	%ebx, %rdi
	callq	_TRACE
	movl	4(%r14), %esi
	movq	-80(%rbp), %rdi                 ## 8-byte Reload
	movl	%r13d, %edx
	movl	-72(%rbp), %ecx                 ## 4-byte Reload
	callq	_sqlite3PagerMovepage
	movl	%eax, %r15d
	movl	%eax, -44(%rbp)
	movq	_SQLITE_OK@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r15d
	jne	LBB0_15
## %bb.3:
	movl	%r13d, (%r14)
	movq	_PTRMAP_BTREE@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	movl	%r13d, -48(%rbp)                ## 4-byte Spill
	je	LBB0_5
## %bb.4:
	movq	_PTRMAP_ROOTPAGE@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	je	LBB0_5
## %bb.6:
	movl	8(%r14), %edi
	callq	_get4byte
	testl	%eax, %eax
	movq	_SQLITE_OK@GOTPCREL(%rip), %r14
	je	LBB0_8
## %bb.7:
	movq	_PTRMAP_OVERFLOW2@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	leaq	-44(%rbp), %r8
	movq	%r12, %rdi
	movl	%eax, %esi
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	callq	_ptrmapPut
	movl	-44(%rbp), %r15d
	cmpl	(%r14), %r15d
	je	LBB0_8
	jmp	LBB0_15
LBB0_5:
	movq	%r14, %rdi
	callq	_setChildPtrmaps
	movl	%eax, %r15d
	movl	%eax, -44(%rbp)
	movq	_SQLITE_OK@GOTPCREL(%rip), %r14
	cmpl	(%r14), %eax
	jne	LBB0_15
LBB0_8:
	movq	_PTRMAP_ROOTPAGE@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	je	LBB0_15
## %bb.9:
	leaq	-64(%rbp), %rdx
	movq	%r12, %rdi
	movl	-52(%rbp), %esi                 ## 4-byte Reload
	xorl	%ecx, %ecx
	callq	_btreeGetPage
	movl	%eax, %r15d
	movl	%eax, -44(%rbp)
	cmpl	(%r14), %eax
	jne	LBB0_15
## %bb.10:
	movq	-64(%rbp), %rax
	movl	4(%rax), %edi
	callq	_sqlite3PagerWrite
	movl	%eax, -44(%rbp)
	movq	-64(%rbp), %rdi
	cmpl	(%r14), %eax
	jne	LBB0_11
## %bb.12:
	movl	-68(%rbp), %esi                 ## 4-byte Reload
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movl	%ebx, %ecx
	callq	_modifyPagePointer
	movl	%eax, -44(%rbp)
	movq	-64(%rbp), %rdi
	callq	_releasePage
	movl	-44(%rbp), %r15d
	cmpl	(%r14), %r15d
	jne	LBB0_15
## %bb.13:
	leaq	-44(%rbp), %r8
	movq	%r12, %rdi
	movl	-48(%rbp), %esi                 ## 4-byte Reload
	movl	%ebx, %edx
	movl	-52(%rbp), %ecx                 ## 4-byte Reload
	callq	_ptrmapPut
	jmp	LBB0_14
LBB0_11:
	callq	_releasePage
LBB0_14:
	movl	-44(%rbp), %r15d
LBB0_15:
	movl	%r15d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PTRMAP_OVERFLOW2,4,2           ## @PTRMAP_OVERFLOW2
	.comm	_PTRMAP_OVERFLOW1,4,2           ## @PTRMAP_OVERFLOW1
	.comm	_PTRMAP_BTREE,4,2               ## @PTRMAP_BTREE
	.comm	_PTRMAP_ROOTPAGE,4,2            ## @PTRMAP_ROOTPAGE
	.comm	_SQLITE_CORRUPT_BKPT,4,2        ## @SQLITE_CORRUPT_BKPT
	.comm	_SQLITE_OK,4,2                  ## @SQLITE_OK
	.no_dead_strip	_relocatePage
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function relocatePage
_relocatePage:                          ; @relocatePage
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x24, x5
	mov	x20, x4
	str	w3, [sp]                        ; 4-byte Folded Spill
	mov	x21, x2
	mov	x25, x1
	mov	x22, x0
	ldr	w23, [x1]
	ldr	x26, [x0, #8]
Lloh0:
	adrp	x28, _PTRMAP_OVERFLOW2@GOTPAGE
Lloh1:
	ldr	x28, [x28, _PTRMAP_OVERFLOW2@GOTPAGEOFF]
	ldr	w8, [x28]
Lloh2:
	adrp	x9, _PTRMAP_OVERFLOW1@GOTPAGE
Lloh3:
	ldr	x9, [x9, _PTRMAP_OVERFLOW1@GOTPAGEOFF]
	cmp	w8, w2
Lloh4:
	ldr	w8, [x9]
	ccmp	w8, w2, #4, ne
Lloh5:
	adrp	x19, _PTRMAP_BTREE@GOTPAGE
Lloh6:
	ldr	x19, [x19, _PTRMAP_BTREE@GOTPAGEOFF]
	ldr	w8, [x19]
	ccmp	w8, w2, #4, ne
Lloh7:
	adrp	x27, _PTRMAP_ROOTPAGE@GOTPAGE
Lloh8:
	ldr	x27, [x27, _PTRMAP_ROOTPAGE@GOTPAGEOFF]
	ldr	w8, [x27]
	ccmp	w8, w2, #4, ne
	cset	w0, eq
	bl	_assert
	ldr	w0, [x22]
	bl	_sqlite3_mutex_held
	bl	_assert
	ldr	x8, [x25, #16]
	cmp	x8, x22
	cset	w0, eq
	bl	_assert
	cmp	w23, #2
	b.gt	LBB0_2
; %bb.1:
Lloh9:
	adrp	x8, _SQLITE_CORRUPT_BKPT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SQLITE_CORRUPT_BKPT@GOTPAGEOFF]
Lloh11:
	ldr	w24, [x8]
	b	LBB0_15
LBB0_2:
	sxtw	x0, w21
	bl	_TRACE
	ldr	w1, [x25, #4]
	mov	x0, x26
	mov	x2, x20
	mov	x3, x24
	bl	_sqlite3PagerMovepage
	mov	x24, x0
	str	w0, [sp, #4]
Lloh12:
	adrp	x26, _SQLITE_OK@GOTPAGE
Lloh13:
	ldr	x26, [x26, _SQLITE_OK@GOTPAGEOFF]
	ldr	w8, [x26]
	cmp	w0, w8
	b.ne	LBB0_15
; %bb.3:
	str	w20, [x25]
	ldr	w8, [x19]
	cmp	w8, w21
	b.eq	LBB0_7
; %bb.4:
	ldr	w8, [x27]
	cmp	w8, w21
	b.eq	LBB0_7
; %bb.5:
	ldr	w0, [x25, #8]
	bl	_get4byte
	cbz	w0, LBB0_8
; %bb.6:
	mov	x1, x0
	ldr	w2, [x28]
	add	x4, sp, #4
	mov	x0, x22
	mov	x3, x20
	bl	_ptrmapPut
	ldr	w24, [sp, #4]
	ldr	w8, [x26]
	cmp	w24, w8
	b.eq	LBB0_8
	b	LBB0_15
LBB0_7:
	mov	x0, x25
	bl	_setChildPtrmaps
	mov	x24, x0
	str	w0, [sp, #4]
	ldr	w8, [x26]
	cmp	w0, w8
	b.ne	LBB0_15
LBB0_8:
	ldr	w8, [x27]
	cmp	w8, w21
	b.eq	LBB0_15
; %bb.9:
	add	x2, sp, #8
	mov	x0, x22
	ldr	w1, [sp]                        ; 4-byte Folded Reload
	mov	w3, #0
	bl	_btreeGetPage
	mov	x24, x0
	str	w0, [sp, #4]
	ldr	w8, [x26]
	cmp	w0, w8
	b.ne	LBB0_15
; %bb.10:
	ldr	x8, [sp, #8]
	ldr	w0, [x8, #4]
	bl	_sqlite3PagerWrite
	mov	x8, x0
	str	w0, [sp, #4]
	ldr	w9, [x26]
	ldr	x0, [sp, #8]
	cmp	w8, w9
	b.ne	LBB0_13
; %bb.11:
	mov	x1, x23
	mov	x2, x20
	mov	x3, x21
	bl	_modifyPagePointer
	str	w0, [sp, #4]
	ldr	x0, [sp, #8]
	bl	_releasePage
	ldr	w24, [sp, #4]
	ldr	w8, [x26]
	cmp	w24, w8
	b.ne	LBB0_15
; %bb.12:
	add	x4, sp, #4
	mov	x0, x22
	mov	x1, x20
	mov	x2, x21
	ldr	w3, [sp]                        ; 4-byte Folded Reload
	bl	_ptrmapPut
	b	LBB0_14
LBB0_13:
	bl	_releasePage
LBB0_14:
	ldr	w24, [sp, #4]
LBB0_15:
	mov	x0, x24
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_PTRMAP_OVERFLOW2,4,2           ; @PTRMAP_OVERFLOW2
	.comm	_PTRMAP_OVERFLOW1,4,2           ; @PTRMAP_OVERFLOW1
	.comm	_PTRMAP_BTREE,4,2               ; @PTRMAP_BTREE
	.comm	_PTRMAP_ROOTPAGE,4,2            ; @PTRMAP_ROOTPAGE
	.comm	_SQLITE_CORRUPT_BKPT,4,2        ; @SQLITE_CORRUPT_BKPT
	.comm	_SQLITE_OK,4,2                  ; @SQLITE_OK
	.no_dead_strip	_relocatePage
.subsections_via_symbols
