	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function checkList
_checkList:                             ## @checkList
	.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	%esi, %r12d
	movq	%rdi, %r15
	movl	(%rdi), %eax
	movl	%eax, -60(%rbp)                 ## 4-byte Spill
	movl	%ecx, -48(%rbp)                 ## 4-byte Spill
	movl	%ecx, %r13d
	testl	%edx, %edx
	je	LBB0_24
## %bb.1:
	movl	%edx, %r14d
	movl	-48(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, %ebx
	movl	%r12d, -64(%rbp)                ## 4-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_21:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	leaq	L_.str.1(%rip), %rsi
	movl	%r14d, %edx
	xorl	%eax, %eax
	callq	_checkAppendMsg
	addl	$-2, %ebx
	movl	%ebx, %r13d
LBB0_22:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
LBB0_23:                                ##   in Loop: Header=BB0_2 Depth=1
	callq	_get4byte
	movl	%eax, %r14d
	movq	-72(%rbp), %rdi
	callq	_sqlite3PagerUnref
	movl	%r13d, %ebx
	testl	%r14d, %r14d
	je	LBB0_24
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_14 Depth 2
	cmpq	$0, 24(%r15)
	je	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_checkRef
	testq	%rax, %rax
	jne	LBB0_5
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	leal	-1(%rbx), %r13d
	movl	16(%r15), %edi
	movl	%r14d, %esi
	leaq	-72(%rbp), %rdx
	xorl	%ecx, %ecx
	callq	_sqlite3PagerGet
	testq	%rax, %rax
	jne	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-72(%rbp), %rdi
	callq	_sqlite3PagerGetData
	movq	%rax, %rdi
	testl	%r12d, %r12d
	je	LBB0_18
## %bb.9:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	addq	$4, %rdi
	callq	_get4byte
	movl	%eax, %edx
	movq	8(%r15), %rax
	cmpq	$0, 8(%rax)
	je	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	_PTRMAP_FREEPAGE@GOTPCREL(%rip), %rax
	movl	%r13d, -44(%rbp)                ## 4-byte Spill
	movl	%r12d, %r13d
	movl	%edx, %r12d
	movl	(%rax), %edx
	movq	%r15, %rdi
	movl	%r14d, %esi
	xorl	%ecx, %ecx
	callq	_checkPtrmap
	movl	%r12d, %edx
	movl	%r13d, %r12d
	movl	-44(%rbp), %r13d                ## 4-byte Reload
	movq	8(%r15), %rax
LBB0_11:                                ##   in Loop: Header=BB0_2 Depth=1
	movl	(%rax), %eax
	leal	3(%rax), %ecx
	testl	%eax, %eax
	cmovnsl	%eax, %ecx
	sarl	$2, %ecx
	addl	$-2, %ecx
	cmpl	%ecx, %edx
	jg	LBB0_21
## %bb.12:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	testl	%edx, %edx
	jle	LBB0_17
## %bb.13:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	-44(%rbp), %r12d                ## 4-byte Reload
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	addq	$8, %rbx
	jmp	LBB0_14
	.p2align	4, 0x90
LBB0_16:                                ##   in Loop: Header=BB0_14 Depth=2
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_checkRef
	addq	$4, %rbx
	decq	%r12
	je	LBB0_17
LBB0_14:                                ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	%rbx, %rdi
	callq	_get4byte
	movl	%eax, %r14d
	movq	8(%r15), %rax
	cmpq	$0, 8(%rax)
	je	LBB0_16
## %bb.15:                              ##   in Loop: Header=BB0_14 Depth=2
	movq	_PTRMAP_FREEPAGE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	movl	%r14d, %esi
	xorl	%ecx, %ecx
	callq	_checkPtrmap
	jmp	LBB0_16
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	8(%r15), %rax
	cmpq	$0, 8(%rax)
	je	LBB0_23
## %bb.19:                              ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$2, %ebx
	jl	LBB0_23
## %bb.20:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	%rdi, %rbx
	callq	_get4byte
	movq	_PTRMAP_OVERFLOW2@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	%r15, %rdi
	movl	%eax, %esi
	movl	%r14d, %ecx
	callq	_checkPtrmap
	movq	%rbx, %rdi
	jmp	LBB0_23
	.p2align	4, 0x90
LBB0_17:                                ##   in Loop: Header=BB0_2 Depth=1
	subl	-44(%rbp), %r13d                ## 4-byte Folded Reload
	movl	-64(%rbp), %r12d                ## 4-byte Reload
	jmp	LBB0_22
LBB0_3:
	movl	%ebx, %r13d
	testl	%r13d, %r13d
	jne	LBB0_25
	jmp	LBB0_27
LBB0_5:
	movl	%ebx, %r13d
LBB0_24:
	testl	%r13d, %r13d
	je	LBB0_27
LBB0_25:
	movl	-60(%rbp), %eax                 ## 4-byte Reload
	cmpl	(%r15), %eax
	jne	LBB0_27
## %bb.26:
	testl	%r12d, %r12d
	leaq	L_.str.4(%rip), %rax
	leaq	L_.str.3(%rip), %rdx
	cmoveq	%rax, %rdx
	movl	-48(%rbp), %r8d                 ## 4-byte Reload
	movl	%r8d, %ecx
	subl	%r13d, %ecx
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdi
	xorl	%eax, %eax
	callq	_checkAppendMsg
LBB0_27:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	movl	%r14d, %edx
	xorl	%eax, %eax
	callq	_checkAppendMsg
	testl	%r13d, %r13d
	jne	LBB0_25
	jmp	LBB0_27
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to get page %d"

	.comm	_PTRMAP_FREEPAGE,4,2            ## @PTRMAP_FREEPAGE
L_.str.1:                               ## @.str.1
	.asciz	"freelist leaf count too big on page %d"

	.comm	_PTRMAP_OVERFLOW2,4,2           ## @PTRMAP_OVERFLOW2
L_.str.2:                               ## @.str.2
	.asciz	"%s is %d but should be %d"

L_.str.3:                               ## @.str.3
	.asciz	"size"

L_.str.4:                               ## @.str.4
	.asciz	"overflow list length"

	.no_dead_strip	_checkList
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function checkList
_checkList:                             ; @checkList
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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	x20, x3
	mov	x21, x1
	mov	x19, x0
	ldr	w8, [x0]
	str	w8, [sp, #36]                   ; 4-byte Folded Spill
	mov	x28, x3
	cbz	w2, LBB0_21
; %bb.1:
	mov	x24, x2
Lloh0:
	adrp	x22, _PTRMAP_FREEPAGE@GOTPAGE
Lloh1:
	ldr	x22, [x22, _PTRMAP_FREEPAGE@GOTPAGEOFF]
	mov	x26, x20
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	str	x24, [sp]
	mov	x0, x19
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_checkAppendMsg
	sub	w28, w26, #2
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x23
	bl	_get4byte
	mov	x24, x0
	ldr	x0, [sp, #40]
	bl	_sqlite3PagerUnref
	mov	x26, x28
	cbz	w24, LBB0_21
LBB0_4:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_14 Depth 2
	ldr	x8, [x19, #24]
	cbz	x8, LBB0_19
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x19
	mov	x1, x24
	bl	_checkRef
	cbnz	x0, LBB0_20
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	sub	w28, w26, #1
	ldr	w0, [x19, #16]
	add	x2, sp, #40
	mov	x1, x24
	mov	w3, #0
	bl	_sqlite3PagerGet
	cbnz	x0, LBB0_25
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x0, [sp, #40]
	bl	_sqlite3PagerGetData
	mov	x23, x0
	cbz	w21, LBB0_16
; %bb.8:                                ;   in Loop: Header=BB0_4 Depth=1
	add	x0, x23, #4
	bl	_get4byte
	mov	x25, x0
	ldr	x8, [x19, #8]
	ldr	x9, [x8, #8]
	cbz	x9, LBB0_10
; %bb.9:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w2, [x22]
	mov	x0, x19
	mov	x1, x24
	mov	w3, #0
	bl	_checkPtrmap
	ldr	x8, [x19, #8]
LBB0_10:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w8, [x8]
	add	w9, w8, #3
	cmp	w8, #0
	csel	w8, w9, w8, lt
	asr	w8, w8, #2
	sub	w8, w8, #2
	cmp	w25, w8
	b.gt	LBB0_2
; %bb.11:                               ;   in Loop: Header=BB0_4 Depth=1
	cmp	w25, #1
	b.lt	LBB0_18
; %bb.12:                               ;   in Loop: Header=BB0_4 Depth=1
	mov	w27, w25
	add	x24, x23, #8
	b	LBB0_14
LBB0_13:                                ;   in Loop: Header=BB0_14 Depth=2
	mov	x0, x19
	mov	x1, x26
	bl	_checkRef
	add	x24, x24, #4
	subs	x27, x27, #1
	b.eq	LBB0_18
LBB0_14:                                ;   Parent Loop BB0_4 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	mov	x0, x24
	bl	_get4byte
	mov	x26, x0
	ldr	x8, [x19, #8]
	ldr	x8, [x8, #8]
	cbz	x8, LBB0_13
; %bb.15:                               ;   in Loop: Header=BB0_14 Depth=2
	ldr	w2, [x22]
	mov	x0, x19
	mov	x1, x26
	mov	w3, #0
	bl	_checkPtrmap
	b	LBB0_13
LBB0_16:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x19, #8]
	ldr	x8, [x8, #8]
	cmp	x8, #0
	ccmp	w26, #2, #8, ne
	b.lt	LBB0_3
; %bb.17:                               ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x23
	bl	_get4byte
	mov	x1, x0
Lloh4:
	adrp	x8, _PTRMAP_OVERFLOW2@GOTPAGE
Lloh5:
	ldr	x8, [x8, _PTRMAP_OVERFLOW2@GOTPAGEOFF]
Lloh6:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x3, x24
	bl	_checkPtrmap
	b	LBB0_3
LBB0_18:                                ;   in Loop: Header=BB0_4 Depth=1
	sub	w28, w28, w25
	b	LBB0_3
LBB0_19:
	mov	x28, x26
	cbnz	w28, LBB0_22
	b	LBB0_24
LBB0_20:
	mov	x28, x26
LBB0_21:
	cbz	w28, LBB0_24
LBB0_22:
	ldr	w8, [x19]
	ldr	w9, [sp, #36]                   ; 4-byte Folded Reload
	cmp	w9, w8
	b.ne	LBB0_24
; %bb.23:
Lloh7:
	adrp	x8, l_.str.3@PAGE
Lloh8:
	add	x8, x8, l_.str.3@PAGEOFF
Lloh9:
	adrp	x9, l_.str.4@PAGE
Lloh10:
	add	x9, x9, l_.str.4@PAGEOFF
	cmp	w21, #0
	csel	x8, x9, x8, eq
	sub	w9, w20, w28
	stp	x9, x20, [sp, #8]
	str	x8, [sp]
Lloh11:
	adrp	x1, l_.str.2@PAGE
Lloh12:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_checkAppendMsg
LBB0_24:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
LBB0_25:
                                        ; kill: def $w24 killed $w24 killed $x24 def $x24
	str	x24, [sp]
Lloh13:
	adrp	x1, l_.str@PAGE
Lloh14:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_checkAppendMsg
	cbnz	w28, LBB0_22
	b	LBB0_24
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to get page %d"

	.comm	_PTRMAP_FREEPAGE,4,2            ; @PTRMAP_FREEPAGE
l_.str.1:                               ; @.str.1
	.asciz	"freelist leaf count too big on page %d"

	.comm	_PTRMAP_OVERFLOW2,4,2           ; @PTRMAP_OVERFLOW2
l_.str.2:                               ; @.str.2
	.asciz	"%s is %d but should be %d"

l_.str.3:                               ; @.str.3
	.asciz	"size"

l_.str.4:                               ; @.str.4
	.asciz	"overflow list length"

	.no_dead_strip	_checkList
.subsections_via_symbols
