	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function FreePageBtreeRemove
_FreePageBtreeRemove:                   ## @FreePageBtreeRemove
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	(%rsi), %rax
	movq	_FREE_PAGE_LEAF_MAGIC@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_Assert
	xorl	%edi, %edi
	cmpq	%r15, 8(%rbx)
	seta	%dil
	callq	_Assert
	movq	8(%rbx), %rdx
	cmpq	$1, %rdx
	jne	LBB0_1
## %bb.6:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_FreePageBtreeRemovePage        ## TAILCALL
LBB0_1:
	decq	%rdx
	movq	%rdx, 8(%rbx)
	cmpq	%r15, %rdx
	jbe	LBB0_3
## %bb.2:
	movq	16(%rbx), %rax
	leaq	(%rax,%r15,4), %rdi
	leaq	(%rax,%r15,4), %rsi
	addq	$4, %rsi
	subl	%r15d, %edx
	shll	$2, %edx
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_memmove
LBB0_3:
	testq	%r15, %r15
	jne	LBB0_5
## %bb.4:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_FreePageBtreeAdjustAncestorKeys
LBB0_5:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_FreePageBtreeConsolidate       ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_FREE_PAGE_LEAF_MAGIC,8,3       ## @FREE_PAGE_LEAF_MAGIC
	.no_dead_strip	_FreePageBtreeRemove
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function FreePageBtreeRemove
_FreePageBtreeRemove:                   ; @FreePageBtreeRemove
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x21, x2
	mov	x19, x1
	mov	x20, x0
	ldr	x8, [x1]
Lloh0:
	adrp	x9, _FREE_PAGE_LEAF_MAGIC@GOTPAGE
Lloh1:
	ldr	x9, [x9, _FREE_PAGE_LEAF_MAGIC@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, eq
	bl	_Assert
	ldr	x8, [x19, #8]
	cmp	x8, x21
	cset	w0, hi
	bl	_Assert
	ldr	x8, [x19, #8]
	subs	x8, x8, #1
	b.ne	LBB0_2
; %bb.1:
	mov	x0, x20
	mov	x1, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_FreePageBtreeRemovePage
LBB0_2:
	str	x8, [x19, #8]
	cmp	x8, x21
	b.ls	LBB0_4
; %bb.3:
	ldr	x9, [x19, #16]
	add	x0, x9, x21, lsl #2
	add	x1, x0, #4
	sub	w8, w8, w21
	lsl	w2, w8, #2
	bl	_memmove
LBB0_4:
	cbnz	x21, LBB0_6
; %bb.5:
	mov	x0, x20
	mov	x1, x19
	bl	_FreePageBtreeAdjustAncestorKeys
LBB0_6:
	mov	x0, x20
	mov	x1, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_FreePageBtreeConsolidate
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_FREE_PAGE_LEAF_MAGIC,8,3       ; @FREE_PAGE_LEAF_MAGIC
	.no_dead_strip	_FreePageBtreeRemove
.subsections_via_symbols
