	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function btreeDropTable
_btreeDropTable:                        ## @btreeDropTable
	.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, %r15
	movl	%esi, %r13d
	movq	%rdi, %r12
	movq	$0, -56(%rbp)
	movq	8(%rdi), %r14
	callq	_sqlite3BtreeHoldsMutex
	movl	%eax, %edi
	callq	_assert
	movq	(%r12), %rax
	movq	_TRANS_WRITE@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_assert
	xorl	%edi, %edi
	cmpl	$2, %r13d
	setge	%dil
	callq	_assert
	movq	%r14, %rdi
	callq	_btreePagecount
	cmpl	%r13d, %eax
	jge	LBB0_2
## %bb.1:
	movq	_SQLITE_CORRUPT_BKPT@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_16
LBB0_2:
	leaq	-56(%rbp), %rdx
	movq	%r14, %rdi
	movl	%r13d, %esi
	xorl	%ecx, %ecx
	callq	_btreeGetPage
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_16
## %bb.3:
	movq	%r12, %rdi
	movl	%r13d, %esi
	xorl	%edx, %edx
	callq	_sqlite3BtreeClearTable
	movl	%eax, -48(%rbp)
	testl	%eax, %eax
	je	LBB0_5
## %bb.4:
	movl	%eax, %ebx
	movq	-56(%rbp), %rdi
	callq	_releasePage
LBB0_16:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movl	$0, (%r15)
	cmpq	$0, (%r14)
	je	LBB0_15
## %bb.6:
	movq	_BTREE_LARGEST_ROOT_PAGE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-44(%rbp), %rdx
	movq	%r12, %rdi
	callq	_sqlite3BtreeGetMeta
	cmpl	%r13d, -44(%rbp)
	jne	LBB0_8
## %bb.7:
	movq	-56(%rbp), %rdi
	leaq	-48(%rbp), %rsi
	callq	_freePage
	movq	-56(%rbp), %rdi
	callq	_releasePage
	movl	-48(%rbp), %ebx
	movq	_SQLITE_OK@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_16
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movl	-44(%rbp), %ebx
	decl	%ebx
	movl	%ebx, -44(%rbp)
	movq	%r14, %rdi
	callq	_PENDING_BYTE_PAGE
	cmpl	%eax, %ebx
	je	LBB0_12
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	movl	-44(%rbp), %esi
	movq	%r14, %rdi
	callq	_PTRMAP_ISPAGE
	testq	%rax, %rax
	jne	LBB0_12
## %bb.14:
	movl	-44(%rbp), %ebx
	movq	%r14, %rdi
	callq	_PENDING_BYTE_PAGE
	xorl	%edi, %edi
	cmpl	%eax, %ebx
	setne	%dil
	callq	_assert
	movl	-44(%rbp), %edx
	movq	%r12, %rdi
	movl	$4, %esi
	callq	_sqlite3BtreeUpdateMeta
	movl	%eax, %ebx
	jmp	LBB0_16
LBB0_15:
	movq	-56(%rbp), %rdi
	leaq	-48(%rbp), %rsi
	callq	_freePage
	movq	-56(%rbp), %rdi
	callq	_releasePage
	movl	-48(%rbp), %ebx
	jmp	LBB0_16
LBB0_8:
	movq	-56(%rbp), %rdi
	callq	_releasePage
	movl	-44(%rbp), %esi
	leaq	-64(%rbp), %rdx
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	callq	_btreeGetPage
	movl	%eax, %ebx
	movl	%eax, -48(%rbp)
	movq	_SQLITE_OK@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_16
## %bb.9:
	movq	-64(%rbp), %rsi
	movq	_PTRMAP_ROOTPAGE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	movl	%r13d, %r8d
	xorl	%r9d, %r9d
	callq	_relocatePage
	movl	%eax, %ebx
	movl	%eax, -48(%rbp)
	movq	-64(%rbp), %rdi
	callq	_releasePage
	movq	_SQLITE_OK@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_16
## %bb.10:
	movq	$0, -64(%rbp)
	movl	-44(%rbp), %esi
	leaq	-64(%rbp), %rdx
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	movq	%rax, %r13
	callq	_btreeGetPage
	movl	%eax, -48(%rbp)
	movq	-64(%rbp), %rdi
	leaq	-48(%rbp), %rsi
	callq	_freePage
	movq	-64(%rbp), %rdi
	callq	_releasePage
	movl	-48(%rbp), %ebx
	cmpl	(%r13), %ebx
	jne	LBB0_16
## %bb.11:
	movl	-44(%rbp), %eax
	movl	%eax, (%r15)
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_TRANS_WRITE,8,3                ## @TRANS_WRITE
	.comm	_SQLITE_CORRUPT_BKPT,4,2        ## @SQLITE_CORRUPT_BKPT
	.comm	_BTREE_LARGEST_ROOT_PAGE,4,2    ## @BTREE_LARGEST_ROOT_PAGE
	.comm	_SQLITE_OK,4,2                  ## @SQLITE_OK
	.comm	_PTRMAP_ROOTPAGE,4,2            ## @PTRMAP_ROOTPAGE
	.no_dead_strip	_btreeDropTable
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function btreeDropTable
_btreeDropTable:                        ; @btreeDropTable
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x21, x2
	mov	x22, x1
	mov	x19, x0
	str	xzr, [sp, #16]
	ldr	x20, [x0, #8]
	bl	_sqlite3BtreeHoldsMutex
	bl	_assert
	ldr	x8, [x19]
Lloh0:
	adrp	x9, _TRANS_WRITE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _TRANS_WRITE@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, eq
	bl	_assert
	cmp	w22, #1
	cset	w0, gt
	bl	_assert
	mov	x0, x20
	bl	_btreePagecount
	cmp	w0, w22
	b.ge	LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _SQLITE_CORRUPT_BKPT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SQLITE_CORRUPT_BKPT@GOTPAGEOFF]
Lloh5:
	ldr	w23, [x8]
	b	LBB0_5
LBB0_2:
	add	x2, sp, #16
	mov	x0, x20
	mov	x1, x22
	mov	w3, #0
	bl	_btreeGetPage
	mov	x23, x0
	cbnz	w0, LBB0_5
; %bb.3:
	mov	x0, x19
	mov	x1, x22
	mov	w2, #0
	bl	_sqlite3BtreeClearTable
	str	w0, [sp, #28]
	cbz	w0, LBB0_6
; %bb.4:
	mov	x23, x0
	ldr	x0, [sp, #16]
	bl	_releasePage
LBB0_5:
	mov	x0, x23
	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
	add	sp, sp, #96
	ret
LBB0_6:
	str	wzr, [x21]
	ldr	x8, [x20]
	cbz	x8, LBB0_12
; %bb.7:
Lloh6:
	adrp	x8, _BTREE_LARGEST_ROOT_PAGE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _BTREE_LARGEST_ROOT_PAGE@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	add	x2, sp, #12
	mov	x0, x19
	bl	_sqlite3BtreeGetMeta
	ldr	w8, [sp, #12]
	cmp	w8, w22
	b.ne	LBB0_13
; %bb.8:
	ldr	x0, [sp, #16]
	add	x1, sp, #28
	bl	_freePage
	ldr	x0, [sp, #16]
	bl	_releasePage
	ldr	w23, [sp, #28]
Lloh9:
	adrp	x8, _SQLITE_OK@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SQLITE_OK@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	cmp	w23, w8
	b.ne	LBB0_5
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [sp, #12]
	sub	w21, w8, #1
	str	w21, [sp, #12]
	mov	x0, x20
	bl	_PENDING_BYTE_PAGE
	cmp	w21, w0
	b.eq	LBB0_9
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w1, [sp, #12]
	mov	x0, x20
	bl	_PTRMAP_ISPAGE
	cbnz	x0, LBB0_9
; %bb.11:
	ldr	w21, [sp, #12]
	mov	x0, x20
	bl	_PENDING_BYTE_PAGE
	cmp	w21, w0
	cset	w0, ne
	bl	_assert
	ldr	w2, [sp, #12]
	mov	x0, x19
	mov	w1, #4
	bl	_sqlite3BtreeUpdateMeta
	mov	x23, x0
	b	LBB0_5
LBB0_12:
	ldr	x0, [sp, #16]
	add	x1, sp, #28
	bl	_freePage
	ldr	x0, [sp, #16]
	bl	_releasePage
	ldr	w23, [sp, #28]
	b	LBB0_5
LBB0_13:
	ldr	x0, [sp, #16]
	bl	_releasePage
	ldr	w1, [sp, #12]
	mov	x2, sp
	mov	x0, x20
	mov	w3, #0
	bl	_btreeGetPage
	mov	x23, x0
	str	w0, [sp, #28]
Lloh12:
	adrp	x24, _SQLITE_OK@GOTPAGE
Lloh13:
	ldr	x24, [x24, _SQLITE_OK@GOTPAGEOFF]
	ldr	w8, [x24]
	cmp	w0, w8
	b.ne	LBB0_5
; %bb.14:
	ldr	x1, [sp]
Lloh14:
	adrp	x8, _PTRMAP_ROOTPAGE@GOTPAGE
Lloh15:
	ldr	x8, [x8, _PTRMAP_ROOTPAGE@GOTPAGEOFF]
Lloh16:
	ldr	w2, [x8]
	mov	x0, x20
	mov	w3, #0
	mov	x4, x22
	mov	w5, #0
	bl	_relocatePage
	mov	x23, x0
	str	w0, [sp, #28]
	ldr	x0, [sp]
	bl	_releasePage
	ldr	w8, [x24]
	cmp	w23, w8
	b.ne	LBB0_5
; %bb.15:
	str	xzr, [sp]
	ldr	w1, [sp, #12]
	mov	x2, sp
	mov	x0, x20
	mov	w3, #0
	bl	_btreeGetPage
	str	w0, [sp, #28]
	ldr	x0, [sp]
	add	x1, sp, #28
	bl	_freePage
	ldr	x0, [sp]
	bl	_releasePage
	ldr	w23, [sp, #28]
	ldr	w8, [x24]
	cmp	w23, w8
	b.ne	LBB0_5
; %bb.16:
	ldr	w8, [sp, #12]
	str	w8, [x21]
	b	LBB0_9
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_TRANS_WRITE,8,3                ; @TRANS_WRITE
	.comm	_SQLITE_CORRUPT_BKPT,4,2        ; @SQLITE_CORRUPT_BKPT
	.comm	_BTREE_LARGEST_ROOT_PAGE,4,2    ; @BTREE_LARGEST_ROOT_PAGE
	.comm	_SQLITE_OK,4,2                  ; @SQLITE_OK
	.comm	_PTRMAP_ROOTPAGE,4,2            ; @PTRMAP_ROOTPAGE
	.no_dead_strip	_btreeDropTable
.subsections_via_symbols
