	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sum_d
_sum_d:                                 ## @sum_d
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movl	4(%rdi), %eax
	movl	%eax, (%rsi)
	cmpl	$2, %edx
	jl	LBB0_10
## %bb.1:
	movl	%edx, %eax
	leaq	-1(%rax), %r9
	movl	$1, %ecx
	cmpq	$9, %r9
	jb	LBB0_6
## %bb.2:
	leaq	4(%rsi), %r8
	leaq	(%rdi,%rax,8), %rdx
	cmpq	%rdx, %r8
	jae	LBB0_4
## %bb.3:
	leaq	(%rsi,%rax,4), %r8
	leaq	4(%rdi), %rdx
	cmpq	%r8, %rdx
	jb	LBB0_6
LBB0_4:
	movl	%r9d, %ecx
	andl	$7, %ecx
	testq	%rcx, %rcx
	movl	$8, %edx
	cmovneq	%rcx, %rdx
	movq	%r9, %r8
	subq	%rdx, %r8
	negq	%rdx
	leaq	(%r9,%rdx), %rcx
	incq	%rcx
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movups	52(%rdi,%rdx,8), %xmm0
	movups	36(%rdi,%rdx,8), %xmm1
	shufps	$136, %xmm0, %xmm1              ## xmm1 = xmm1[0,2],xmm0[0,2]
	movups	4(%rdi,%rdx,8), %xmm0
	movups	12(%rdi,%rdx,8), %xmm2
	movups	20(%rdi,%rdx,8), %xmm3
	shufps	$136, %xmm3, %xmm0              ## xmm0 = xmm0[0,2],xmm3[0,2]
	movups	28(%rdi,%rdx,8), %xmm3
	shufps	$136, %xmm3, %xmm2              ## xmm2 = xmm2[0,2],xmm3[0,2]
	paddd	%xmm0, %xmm2
	movups	60(%rdi,%rdx,8), %xmm0
	movups	44(%rdi,%rdx,8), %xmm3
	shufps	$136, %xmm0, %xmm3              ## xmm3 = xmm3[0,2],xmm0[0,2]
	paddd	%xmm1, %xmm3
	movdqu	%xmm2, 4(%rsi,%rdx,4)
	movdqu	%xmm3, 20(%rsi,%rdx,4)
	addq	$8, %rdx
	cmpq	%rdx, %r8
	jne	LBB0_5
LBB0_6:
	movl	%eax, %edx
	subl	%ecx, %edx
	movq	%rcx, %r8
	notq	%r8
	testb	$1, %dl
	je	LBB0_8
## %bb.7:
	movl	4(%rdi,%rcx,8), %edx
	addl	-4(%rdi,%rcx,8), %edx
	movl	%edx, (%rsi,%rcx,4)
	incq	%rcx
LBB0_8:
	addq	%rax, %r8
	je	LBB0_10
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movl	4(%rdi,%rcx,8), %edx
	addl	-4(%rdi,%rcx,8), %edx
	movl	%edx, (%rsi,%rcx,4)
	movl	12(%rdi,%rcx,8), %edx
	addl	4(%rdi,%rcx,8), %edx
	movl	%edx, 4(%rsi,%rcx,4)
	addq	$2, %rcx
	cmpq	%rcx, %rax
	jne	LBB0_9
LBB0_10:
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_sum_d
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sum_d
_sum_d:                                 ; @sum_d
	.cfi_startproc
; %bb.0:
	ldr	w8, [x0, #4]
	str	w8, [x1]
	cmp	w2, #2
	b.lt	LBB0_9
; %bb.1:
	mov	w8, w2
	sub	x9, x8, #1
	cmp	x9, #17
	b.lo	LBB0_4
; %bb.2:
	add	x10, x1, #4
	add	x11, x0, x8, lsl #3
	cmp	x10, x11
	b.hs	LBB0_5
; %bb.3:
	add	x10, x1, x8, lsl #2
	add	x11, x0, #4
	cmp	x11, x10
	b.hs	LBB0_5
LBB0_4:
	mov	w9, #1
	b	LBB0_7
LBB0_5:
	ands	x10, x9, #0xf
	mov	w11, #16
	csel	x10, x11, x10, eq
	sub	x10, x9, x10
	add	x9, x10, #1
	add	x11, x1, #36
	add	x12, x0, #68
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	sub	x13, x12, #64
	ld2.4s	{ v0, v1 }, [x13]
	sub	x13, x12, #32
	ld2.4s	{ v2, v3 }, [x13]
	mov	x13, x12
	ld2.4s	{ v4, v5 }, [x13], #32
	ld2.4s	{ v6, v7 }, [x13]
	sub	x13, x12, #56
	ld2.4s	{ v16, v17 }, [x13]
	sub	x13, x12, #24
	ld2.4s	{ v18, v19 }, [x13]
	add	x13, x12, #8
	ld2.4s	{ v20, v21 }, [x13]
	add	x13, x12, #40
	ld2.4s	{ v22, v23 }, [x13]
	add.4s	v0, v16, v0
	add.4s	v1, v18, v2
	add.4s	v2, v20, v4
	add.4s	v3, v22, v6
	stp	q0, q1, [x11, #-32]
	stp	q2, q3, [x11], #64
	add	x12, x12, #128
	subs	x10, x10, #16
	b.ne	LBB0_6
LBB0_7:
	add	x10, x0, x9, lsl #3
	add	x10, x10, #4
	add	x11, x1, x9, lsl #2
	sub	x8, x8, x9
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldur	w9, [x10, #-8]
	ldr	w12, [x10], #8
	add	w9, w12, w9
	str	w9, [x11], #4
	subs	x8, x8, #1
	b.ne	LBB0_8
LBB0_9:
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_sum_d
.subsections_via_symbols
