	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vdbeSorterMerge
_vdbeSorterMerge:                       ## @vdbeSorterMerge
	.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
	movq	%rsi, %r15
	movq	$0, -48(%rbp)
	leaq	-48(%rbp), %r13
	testq	%rdx, %rdx
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	je	LBB0_1
## %bb.2:
	movq	%rdx, %rbx
	testq	%r15, %r15
	je	LBB0_3
## %bb.4:
	movq	%rdi, %r12
	movq	(%rbx), %r8
	leaq	-48(%rbp), %r13
	leaq	-52(%rbp), %r14
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_5 Depth=1
	movq	%r15, (%r13)
	movq	8(%r15), %rcx
	movq	%rbx, %rax
	movq	%r15, %rbx
	addq	$8, %rbx
	movq	%rcx, %r15
	xorl	%r8d, %r8d
LBB0_10:                                ##   in Loop: Header=BB0_5 Depth=1
	movq	%rbx, %r13
	movq	%rax, %rbx
	testq	%r15, %r15
	je	LBB0_11
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r15), %rdx
	movl	16(%r15), %ecx
	movl	16(%rbx), %r9d
	movq	%r14, (%rsp)
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_vdbeSorterCompare
	cmpl	$0, -52(%rbp)
	jle	LBB0_6
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	%rbx, (%r13)
	movq	8(%rbx), %rax
	addq	$8, %rbx
	testq	%rax, %rax
	je	LBB0_8
## %bb.9:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	(%rax), %r8
	jmp	LBB0_10
LBB0_1:
	xorl	%eax, %eax
	jmp	LBB0_11
LBB0_3:
	movq	%rbx, %rax
	jmp	LBB0_11
LBB0_8:
	xorl	%eax, %eax
	movq	%rbx, %r13
LBB0_11:
	testq	%r15, %r15
	cmovneq	%r15, %rax
	movq	%rax, (%r13)
	movq	-48(%rbp), %rax
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_vdbeSorterMerge
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vdbeSorterMerge
_vdbeSorterMerge:                       ; @vdbeSorterMerge
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x19, x3
	mov	x21, x2
	mov	x20, x1
	str	xzr, [sp, #8]
	cbz	x2, LBB0_7
; %bb.1:
	cbz	x20, LBB0_7
; %bb.2:
	mov	x22, x0
	ldr	x4, [x21]
	add	x23, sp, #8
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x4, #0
	str	x20, [x23]
	ldr	x8, [x20, #8]!
	mov	x23, x20
	mov	x20, x8
	cbz	x20, LBB0_9
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x2, [x20]
	ldr	w3, [x20, #16]
	ldr	w5, [x21, #16]
	add	x6, sp, #4
	mov	x0, x22
	mov	w1, #0
	bl	_vdbeSorterCompare
	ldr	w8, [sp, #4]
	cmp	w8, #0
	b.le	LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	str	x21, [x23]
	ldr	x8, [x21, #8]!
	mov	x23, x21
	cbz	x8, LBB0_8
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x4, [x8]
	mov	x21, x8
	cbnz	x20, LBB0_4
	b	LBB0_9
LBB0_7:
	add	x23, sp, #8
	b	LBB0_9
LBB0_8:
	mov	x21, #0
LBB0_9:
	cmp	x20, #0
	csel	x8, x21, x20, eq
	str	x8, [x23]
	ldr	x8, [sp, #8]
	str	x8, [x19]
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_vdbeSorterMerge
.subsections_via_symbols
