	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lsmergesort
_lsmergesort:                           ## @lsmergesort
	.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	%ecx, %r13d
	movq	%rdx, %rbx
	movq	%rsi, %r15
	movq	%rdi, %r14
	movl	%ecx, %r12d
	shrl	$31, %r12d
	addl	%ecx, %r12d
	sarl	%r12d
	cmpl	$4, %ecx
	jl	LBB0_2
## %bb.1:
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	movl	%r12d, %ecx
	callq	_lsmergesort
LBB0_2:
	movl	%r13d, %ecx
	subl	%r12d, %ecx
	movslq	%r12d, %r9
	cmpl	$2, %ecx
	jl	LBB0_4
## %bb.3:
	leaq	(%r15,%r9,8), %rsi
	leaq	(%rbx,%r9,8), %rdx
	movq	%r14, %rdi
	movq	%r13, -48(%rbp)                 ## 8-byte Spill
	movq	%r14, %r13
	movq	%r9, %r14
	callq	_lsmergesort
	movq	%r14, %r9
	movq	%r13, %r14
	movq	-48(%rbp), %r13                 ## 8-byte Reload
LBB0_4:
	movl	%r12d, %r10d
	cmpl	$2, %r13d
	jl	LBB0_10
## %bb.5:
	movl	%r12d, %eax
	movq	%r13, %r8
	leal	-2(%r13), %ecx
	cmpl	$-3, %ecx
	movq	%rax, %r13
	sbbq	$0, %r13
	incq	%r13
	cmpq	$4, %r13
	jae	LBB0_21
LBB0_6:
	movq	%r8, %r13
LBB0_7:
	incq	%rax
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	leal	-2(%rax), %ecx
	movq	(%r15,%rcx,8), %rdx
	movq	%rdx, (%rbx,%rcx,8)
	decq	%rax
	cmpq	$1, %rax
	ja	LBB0_8
## %bb.9:
	xorl	%r10d, %r10d
LBB0_10:
	leal	-1(%r12), %edx
	cmpl	%r13d, %r12d
	jge	LBB0_18
## %bb.11:
	leal	-1(%r13), %r8d
	movslq	%edx, %rax
	cmpl	%r8d, %r12d
	movl	%r8d, %edx
	cmovgl	%r12d, %edx
	movslq	%edx, %r11
	movq	%r11, %rdi
	subq	%r9, %rdi
	leaq	1(%rdi), %rcx
	cmpq	$4, %rcx
	jae	LBB0_25
LBB0_12:
	movl	%r11d, %esi
	subl	%eax, %esi
	movq	%rax, %r8
	notq	%r8
	addq	%r11, %r8
	andq	$3, %rsi
	je	LBB0_15
## %bb.13:
	leal	(%r12,%r13), %edi
	subl	%eax, %edi
	addl	$-2, %edi
	.p2align	4, 0x90
LBB0_14:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r15,%rax,8), %rcx
	incq	%rax
	movslq	%edi, %rdi
	movq	%rcx, (%rbx,%rdi,8)
	decl	%edi
	decq	%rsi
	jne	LBB0_14
LBB0_15:
	cmpq	$3, %r8
	jb	LBB0_18
## %bb.16:
	movq	%rax, %r8
	subq	%r11, %r8
	leaq	(%r15,%rax,8), %rsi
	addq	$32, %rsi
	addl	%r13d, %r12d
	subl	%eax, %r12d
	leal	-5(%r12), %r9d
	leal	-4(%r12), %r13d
	leal	-2(%r12), %r11d
	addl	$-3, %r12d
	xorl	%edi, %edi
	.p2align	4, 0x90
LBB0_17:                                ## =>This Inner Loop Header: Depth=1
	movq	-24(%rsi), %rcx
	leal	(%r11,%rdi), %eax
	cltq
	movq	%rcx, (%rbx,%rax,8)
	movq	-16(%rsi), %rax
	leal	(%r12,%rdi), %ecx
	movslq	%ecx, %rcx
	movq	%rax, (%rbx,%rcx,8)
	movq	-8(%rsi), %rax
	leal	(%r13,%rdi), %ecx
	movslq	%ecx, %rcx
	movq	%rax, (%rbx,%rcx,8)
	movq	(%rsi), %rax
	leal	(%r9,%rdi), %ecx
	movslq	%ecx, %rcx
	movq	%rax, (%rbx,%rcx,8)
	addq	$-4, %rdi
	addq	$32, %rsi
	cmpq	%rdi, %r8
	jne	LBB0_17
LBB0_18:
	movq	%rbx, %r13
	cmpl	%edx, %r10d
	jge	LBB0_20
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movslq	%r10d, %r12
	movq	(%r13,%r12,8), %rdi
	movslq	%edx, %rbx
	movq	(%r13,%rbx,8), %rsi
	callq	*%r14
	movl	%eax, %ecx
	shrl	$31, %ecx
	leal	(%r12,%rcx), %r10d
	movl	%eax, %edx
	notl	%edx
	sarl	$31, %edx
	addl	%ebx, %edx
	testl	%eax, %eax
	cmovsq	%r12, %rbx
	movq	(%r13,%rbx,8), %rax
	movq	%rax, (%r15)
	addq	$8, %r15
	cmpl	%edx, %r10d
	jl	LBB0_19
LBB0_20:
	movslq	%r10d, %rax
	movq	(%r13,%rax,8), %rax
	movq	%rax, (%r15)
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_21:
	cmpl	$-3, %ecx
	movq	%rax, %rdx
	sbbq	$0, %rdx
	leal	-1(%r12), %ecx
	cmpl	%edx, %ecx
	jb	LBB0_6
## %bb.22:
	shrq	$32, %rdx
	jne	LBB0_6
## %bb.23:
	leaq	(%r15,%rcx,8), %rdx
	leaq	(%rbx,%rcx,8), %rcx
	subq	%rcx, %rdx
	cmpq	$32, %rdx
	jb	LBB0_6
## %bb.38:
	movq	%r9, -48(%rbp)                  ## 8-byte Spill
	movq	%r13, %rdx
	andq	$-4, %rdx
	leaq	-4(%rdx), %rcx
	movq	%rcx, %r9
	shrq	$2, %r9
	incq	%r9
	testq	%rcx, %rcx
	je	LBB0_46
## %bb.39:
	movq	%rdx, %r10
	movq	%r9, %rcx
	andq	$-2, %rcx
	movl	$4294967291, %esi               ## imm = 0xFFFFFFFB
	addq	%rax, %rsi
	leaq	-1(%rax), %rdx
	movl	$1, %r11d
	.p2align	4, 0x90
LBB0_40:                                ## =>This Inner Loop Header: Depth=1
	movl	%edx, %edi
	shlq	$3, %rdi
	movups	-24(%r15,%rdi), %xmm0
	movups	-8(%r15,%rdi), %xmm1
	movups	%xmm1, -8(%rbx,%rdi)
	movups	%xmm0, -24(%rbx,%rdi)
	movl	%esi, %edi
	shlq	$3, %rdi
	movdqu	-24(%r15,%rdi), %xmm0
	movdqu	-8(%r15,%rdi), %xmm1
	movdqu	%xmm1, -8(%rbx,%rdi)
	movdqu	%xmm0, -24(%rbx,%rdi)
	addq	$8, %r11
	addq	$-8, %rsi
	addq	$-8, %rdx
	addq	$-2, %rcx
	jne	LBB0_40
## %bb.41:
	negq	%r11
	movq	%r10, %rdx
	testb	$1, %r9b
	je	LBB0_43
LBB0_42:
	addl	%eax, %r11d
	movdqu	-24(%r15,%r11,8), %xmm0
	movdqu	-8(%r15,%r11,8), %xmm1
	movdqu	%xmm1, -8(%rbx,%r11,8)
	movdqu	%xmm0, -24(%rbx,%r11,8)
LBB0_43:
	xorl	%r10d, %r10d
	cmpq	%rdx, %r13
	movq	%r8, %r13
	movq	-48(%rbp), %r9                  ## 8-byte Reload
	je	LBB0_10
## %bb.44:
	subq	%rdx, %rax
	jmp	LBB0_7
LBB0_25:
	movl	%r8d, %esi
	subl	%edi, %esi
	cmpl	%r8d, %esi
	jg	LBB0_12
## %bb.26:
	shrq	$32, %rdi
	jne	LBB0_12
## %bb.27:
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	leaq	(%r15,%r9,8), %rcx
	movslq	%r8d, %rsi
	leaq	(%rbx,%rsi,8), %rdi
	addq	$8, %rdi
	cmpq	%rdi, %rcx
	jae	LBB0_29
## %bb.28:
	leaq	(%r15,%r11,8), %rdi
	addq	$8, %rdi
	addq	%r9, %rsi
	subq	%r11, %rsi
	leaq	(%rbx,%rsi,8), %rsi
	cmpq	%rdi, %rsi
	jb	LBB0_12
LBB0_29:
	movq	%r11, -72(%rbp)                 ## 8-byte Spill
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	andq	$-4, %rcx
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	leaq	-4(%rcx), %rsi
	movq	%rsi, %r11
	shrq	$2, %r11
	incq	%r11
	testq	%rsi, %rsi
	movq	%r11, -56(%rbp)                 ## 8-byte Spill
	je	LBB0_45
## %bb.30:
	andq	$-2, %r11
	leal	-5(%r13), %r8d
	leaq	(%r15,%r9,8), %rcx
	addq	$48, %rcx
	xorl	%edi, %edi
	.p2align	4, 0x90
LBB0_31:                                ## =>This Inner Loop Header: Depth=1
	movdqu	-48(%rcx,%rdi,8), %xmm0
	movdqu	-32(%rcx,%rdi,8), %xmm1
	leal	4(%r8), %r9d
	movslq	%r9d, %rsi
	pshufd	$78, %xmm0, %xmm0               ## xmm0 = xmm0[2,3,0,1]
	movdqu	%xmm0, -8(%rbx,%rsi,8)
	pshufd	$78, %xmm1, %xmm0               ## xmm0 = xmm1[2,3,0,1]
	movdqu	%xmm0, -24(%rbx,%rsi,8)
	movdqu	-16(%rcx,%rdi,8), %xmm0
	movdqu	(%rcx,%rdi,8), %xmm1
	movslq	%r8d, %r8
	pshufd	$78, %xmm0, %xmm0               ## xmm0 = xmm0[2,3,0,1]
	movdqu	%xmm0, -8(%rbx,%r8,8)
	pshufd	$78, %xmm1, %xmm0               ## xmm0 = xmm1[2,3,0,1]
	movdqu	%xmm0, -24(%rbx,%r8,8)
	addq	$8, %rdi
	addl	$-8, %r8d
	addq	$-2, %r11
	jne	LBB0_31
## %bb.32:
	testb	$1, -56(%rbp)                   ## 1-byte Folded Reload
	je	LBB0_34
LBB0_33:
	leal	(%r12,%r13), %r8d
	addl	$-2, %r8d
	subl	%eax, %r8d
	subl	%edi, %r8d
	addq	%rax, %rdi
	movdqu	8(%r15,%rdi,8), %xmm0
	movdqu	24(%r15,%rdi,8), %xmm1
	movslq	%r8d, %rsi
	pshufd	$78, %xmm0, %xmm0               ## xmm0 = xmm0[2,3,0,1]
	movdqu	%xmm0, -8(%rbx,%rsi,8)
	pshufd	$78, %xmm1, %xmm0               ## xmm0 = xmm1[2,3,0,1]
	movdqu	%xmm0, -24(%rbx,%rsi,8)
LBB0_34:
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	cmpq	%rcx, -48(%rbp)                 ## 8-byte Folded Reload
	movq	-72(%rbp), %r11                 ## 8-byte Reload
	je	LBB0_18
## %bb.35:
	addq	%rcx, %rax
	jmp	LBB0_12
LBB0_46:
	movq	$-1, %r11
	testb	$1, %r9b
	jne	LBB0_42
	jmp	LBB0_43
LBB0_45:
	xorl	%edi, %edi
	testb	$1, -56(%rbp)                   ## 1-byte Folded Reload
	jne	LBB0_33
	jmp	LBB0_34
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_lsmergesort
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lsmergesort
_lsmergesort:                           ; @lsmergesort
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x22, x3
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
	cmp	w3, #0
	cinc	w8, w3, lt
	asr	w24, w8, #1
	mov	x23, x24
	cmp	w3, #4
	b.lt	LBB0_2
; %bb.1:
	mov	x0, x21
	mov	x1, x20
	mov	x2, x19
	mov	x3, x23
	bl	_lsmergesort
LBB0_2:
	sub	w3, w22, w24
	cmp	w3, #2
	b.lt	LBB0_4
; %bb.3:
	mov	x8, x24
	sbfiz	x8, x8, #3, #32
	add	x1, x20, x8
	add	x2, x19, x8
	mov	x0, x21
	bl	_lsmergesort
LBB0_4:
	subs	w9, w22, #2
	b.lt	LBB0_13
; %bb.5:
	cmn	w9, #3
	cset	w8, lo
	sub	x8, x24, x8
	add	x8, x8, #1
	cmp	x8, #8
	b.lo	LBB0_9
; %bb.6:
	cmn	w9, #3
	cset	w10, lo
	sub	w9, w24, #1
	sub	x10, x24, x10
	cmp	w9, w10
	b.lo	LBB0_9
; %bb.7:
	lsr	x10, x10, #32
	cbnz	x10, LBB0_9
; %bb.8:
	lsl	x9, x9, #3
	add	x10, x9, x20
	add	x9, x9, x19
	sub	x9, x10, x9
	cmp	x9, #64
	b.hs	LBB0_26
LBB0_9:
	mov	x9, x24
LBB0_10:
	add	x8, x9, #1
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	sub	w9, w8, #2
	lsl	x9, x9, #3
	ldr	x10, [x20, x9]
	str	x10, [x19, x9]
	sub	x8, x8, #1
	cmp	x8, #1
	b.hi	LBB0_11
LBB0_12:
	mov	w23, #0
LBB0_13:
	sub	w25, w24, #1
	cmp	w24, w22
	b.ge	LBB0_24
; %bb.14:
	sub	w10, w22, #1
                                        ; kill: def $w25 killed $w25 killed $x25 def $x25
	sxtw	x8, w25
	cmp	w24, w10
	csel	w25, w24, w10, gt
	mov	x9, x25
	sxtw	x9, w9
	mov	x11, x24
	sxtw	x13, w11
	sub	x11, x9, x13
	add	x11, x11, #1
	cmp	x11, #8
	b.lo	LBB0_21
; %bb.15:
	sub	x12, x9, w24, sxtw
	sub	w14, w10, w12
	cmp	w14, w10
	lsr	x12, x12, #32
	ccmp	x12, #0, #0, le
	b.ne	LBB0_21
; %bb.16:
	add	x12, x20, w24, sxtw #3
	add	x14, x19, w10, sxtw #3
	add	x14, x14, #8
	cmp	x12, x14
	b.hs	LBB0_18
; %bb.17:
	mov	x12, x24
	sxtw	x12, w12
	add	x14, x20, x9, lsl #3
	add	x14, x14, #8
	add	x12, x12, w10, sxtw
	sub	x12, x12, x9
	add	x12, x19, x12, lsl #3
	cmp	x12, x14
	b.lo	LBB0_21
LBB0_18:
	and	x12, x11, #0xfffffffffffffff8
	add	x8, x12, x8
	add	x13, x20, x13, lsl #3
	add	x13, x13, #32
	mov	x14, x12
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	ldp	q0, q1, [x13, #-32]
	ldp	q2, q3, [x13], #64
	add	x15, x19, w10, sxtw #3
	ext.16b	v0, v0, v0, #8
	stur	q0, [x15, #-8]
	ext.16b	v0, v1, v1, #8
	stur	q0, [x15, #-24]
	ext.16b	v0, v2, v2, #8
	stur	q0, [x15, #-40]
	ext.16b	v0, v3, v3, #8
	stur	q0, [x15, #-56]
	sub	w10, w10, #8
	subs	x14, x14, #8
	b.ne	LBB0_19
; %bb.20:
	cmp	x11, x12
	b.eq	LBB0_24
LBB0_21:
	add	w10, w24, w22
	sub	w10, w10, w8
	sub	w10, w10, #2
	sub	x9, x9, x8
	add	x8, x20, x8, lsl #3
	add	x8, x8, #8
LBB0_22:                                ; =>This Inner Loop Header: Depth=1
	ldr	x11, [x8], #8
	str	x11, [x19, w10, sxtw #3]
	sub	w10, w10, #1
	subs	x9, x9, #1
	b.ne	LBB0_22
	b	LBB0_24
LBB0_23:                                ;   in Loop: Header=BB0_24 Depth=1
	sxtw	x22, w23
	ldr	x0, [x19, w23, sxtw #3]
	sxtw	x24, w25
	ldr	x1, [x19, w25, sxtw #3]
	blr	x21
	add	w23, w23, w0, lsr #31
	mvn	w8, w0
	add	w25, w25, w8, asr #31
	cmp	w0, #0
	csel	x8, x22, x24, lt
	ldr	x8, [x19, x8, lsl #3]
	str	x8, [x20], #8
LBB0_24:                                ; =>This Inner Loop Header: Depth=1
	cmp	w23, w25
	b.lt	LBB0_23
; %bb.25:
	ldr	x8, [x19, w23, sxtw #3]
	str	x8, [x20]
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_26:
	and	x10, x8, #0xfffffffffffffff8
	sub	x9, x24, x10
	sub	x11, x24, #1
	mov	x12, x10
LBB0_27:                                ; =>This Inner Loop Header: Depth=1
	ubfiz	x13, x11, #3, #32
	add	x14, x20, x13
	ldur	q0, [x14, #-8]
	ldur	q1, [x14, #-24]
	ldur	q2, [x14, #-40]
	ldur	q3, [x14, #-56]
	add	x13, x19, x13
	stur	q0, [x13, #-8]
	stur	q1, [x13, #-24]
	stur	q2, [x13, #-40]
	stur	q3, [x13, #-56]
	sub	x11, x11, #8
	subs	x12, x12, #8
	b.ne	LBB0_27
; %bb.28:
	cmp	x8, x10
	b.eq	LBB0_12
	b	LBB0_10
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_lsmergesort
.subsections_via_symbols
