	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dt_aggregate_lquantizedsum
_dt_aggregate_lquantizedsum:            ## @dt_aggregate_lquantizedsum
	.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	%r12
	pushq	%rbx
	subq	$64, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	(%rdi), %r12
	movq	%r12, %rdi
	callq	_DTRACE_LQUANTIZE_BASE
	movl	%eax, %r14d
	movq	%r12, %rdi
	callq	_DTRACE_LQUANTIZE_STEP
	movl	%eax, %ebx
	movq	%r12, %rdi
	callq	_DTRACE_LQUANTIZE_LEVELS
	movq	8(%r15), %rcx
	movq	%rcx, -96(%rbp)
	fildll	-96(%rbp)
	leal	-1(%r14), %ecx
	movl	%ecx, -52(%rbp)
	fimull	-52(%rbp)
	testl	%eax, %eax
	jle	LBB0_8
## %bb.1:
	movl	%eax, %r8d
	movl	$1, %edx
	fldz
	cmpl	$1, %eax
	jne	LBB0_3
## %bb.2:
	movl	%r14d, %esi
	jmp	LBB0_5
LBB0_3:
	fstp	%st(0)
	movl	%r8d, %r9d
	andl	$-2, %r9d
	negq	%r9
	movl	$1, %edx
	movl	%r14d, %esi
	fldz
	fxch	%st(1)
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	fstp	%st(1)
	movq	8(%r15,%rdx,8), %rcx
	movq	16(%r15,%rdx,8), %rdi
	movq	%rcx, -88(%rbp)
	fildll	-88(%rbp)
	movl	%esi, -44(%rbp)
	fimull	-44(%rbp)
	faddp	%st, %st(1)
	addl	%ebx, %esi
	movq	%rdi, -80(%rbp)
	fildll	-80(%rbp)
	movl	%esi, -48(%rbp)
	fimull	-48(%rbp)
	faddp	%st, %st(1)
	addl	%ebx, %esi
	leaq	(%r9,%rdx), %rcx
	addq	$2, %rcx
	addq	$2, %rdx
	fld	%st(0)
	cmpq	$1, %rcx
	fxch	%st(1)
	jne	LBB0_4
LBB0_5:
	imull	%eax, %ebx
	testb	$1, %r8b
	je	LBB0_7
## %bb.6:
	fstp	%st(0)
	movq	8(%r15,%rdx,8), %rcx
	movq	%rcx, -72(%rbp)
	fildll	-72(%rbp)
	movl	%esi, -40(%rbp)
	fimull	-40(%rbp)
	faddp	%st, %st(1)
	fldz
	fxch	%st(1)
LBB0_7:
	fstp	%st(1)
	addl	%ebx, %r14d
LBB0_8:
	cltq
	movq	16(%r15,%rax,8), %rax
	movq	%rax, -64(%rbp)
	fildll	-64(%rbp)
	incl	%r14d
	movl	%r14d, -36(%rbp)
	fimull	-36(%rbp)
	faddp	%st, %st(1)
	addq	$64, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_dt_aggregate_lquantizedsum
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dt_aggregate_lquantizedsum
_dt_aggregate_lquantizedsum:            ; @dt_aggregate_lquantizedsum
	.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, x0
	ldr	x22, [x0]
	mov	x0, x22
	bl	_DTRACE_LQUANTIZE_BASE
	mov	x19, x0
	mov	x0, x22
	bl	_DTRACE_LQUANTIZE_STEP
	mov	x20, x0
	mov	x0, x22
	bl	_DTRACE_LQUANTIZE_LEVELS
	mov	x8, x21
	ldr	d0, [x8, #8]!
	scvtf	d0, d0
	sub	w9, w19, #1
	scvtf	d1, w9
	fmul	d0, d1, d0
	cmp	w0, #1
	b.lt	LBB0_9
; %bb.1:
	mul	w9, w20, w0
	mov	w11, w0
	cmp	w0, #4
	b.hs	LBB0_3
; %bb.2:
	mov	x12, #0
	mov	x10, x19
	b	LBB0_6
LBB0_3:
	and	x12, x11, #0xfffffffc
	madd	w10, w20, w12, w19
	lsl	w13, w20, #1
	add	w14, w13, w20
	lsl	w15, w20, #2
	add	x16, x21, #24
	mov	x17, x12
	mov	x1, x19
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	add	w2, w20, w1
	add	w3, w13, w1
	add	w4, w14, w1
	ldp	d1, d2, [x16, #-8]
	scvtf	d1, d1
	ldp	d3, d4, [x16, #8]
	scvtf	d2, d2
	scvtf	d3, d3
	scvtf	d5, w1
	scvtf	d6, w2
	scvtf	d7, w3
	scvtf	d16, w4
	scvtf	d4, d4
	fmul	d1, d1, d5
	fmul	d2, d2, d6
	fmul	d3, d3, d7
	fmul	d4, d4, d16
	fadd	d0, d0, d1
	fadd	d0, d0, d2
	fadd	d0, d0, d3
	fadd	d0, d0, d4
	add	w1, w1, w15
	add	x16, x16, #32
	subs	x17, x17, #4
	b.ne	LBB0_4
; %bb.5:
	cmp	x12, x11
	b.eq	LBB0_8
LBB0_6:
	sub	x11, x11, x12
	add	x12, x21, x12, lsl #3
	add	x12, x12, #16
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	d1, [x12], #8
	scvtf	d1, d1
	scvtf	d2, w10
	fmadd	d0, d1, d2, d0
	add	w10, w10, w20
	subs	x11, x11, #1
	b.ne	LBB0_7
LBB0_8:
	add	w19, w19, w9
LBB0_9:
	add	w9, w0, #1
	ldr	d1, [x8, w9, sxtw #3]
	scvtf	d1, d1
	add	w8, w19, #1
	scvtf	d2, w8
	fmadd	d0, d1, d2, d0
	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
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_dt_aggregate_lquantizedsum
.subsections_via_symbols
