	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal4,4byte_literals
	.p2align	2                               ## -- Begin function calc_distr
LCPI0_0:
	.long	0x3f800000                      ## float 1
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4
LCPI0_1:
	.long	0x80000000                      ## float -0
	.long	0x80000000                      ## float -0
	.long	0x80000000                      ## float -0
	.long	0x80000000                      ## float -0
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_calc_distr:                            ## @calc_distr
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movaps	%xmm0, -64(%rbp)                ## 16-byte Spill
	movl	%edx, %r14d
	movl	%esi, %r12d
	movq	%rdi, %r13
	leal	4(,%r14,4), %r15d
	movl	%r15d, %edi
	callq	_palloc
	movq	%rax, %rbx
	movl	%r15d, %edi
	callq	_palloc
	movq	%rax, %r15
	movl	$1065353216, (%rbx)             ## imm = 0x3F800000
	testl	%r12d, %r12d
	jle	LBB0_9
## %bb.1:
	incl	%r12d
	movl	$1, %eax
	movss	LCPI0_0(%rip), %xmm6            ## xmm6 = mem[0],zero,zero,zero
	xorps	%xmm1, %xmm1
	movabsq	$4294967296, %r8                ## imm = 0x100000000
	movq	%rbx, %rdx
	movaps	-64(%rbp), %xmm0                ## 16-byte Reload
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_2:                                 ##   in Loop: Header=BB0_3 Depth=1
	incq	%rax
	movq	%rbx, %rdx
	cmpq	%r12, %rax
	je	LBB0_10
LBB0_3:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_7 Depth 2
	movq	%r15, %rbx
	movq	%rdx, %r15
	cmpl	%eax, %r14d
	movl	%eax, %edx
	cmovbl	%r14d, %edx
	testl	%r14d, %r14d
	js	LBB0_2
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	movss	-4(%r13,%rax,4), %xmm2          ## xmm2 = mem[0],zero,zero,zero
	cmpl	%eax, %r14d
	movl	%eax, %esi
	cmovbl	%r14d, %esi
	movaps	%xmm6, %xmm3
	subss	%xmm2, %xmm3
	movss	(%r15), %xmm4                   ## xmm4 = mem[0],zero,zero,zero
	mulss	%xmm3, %xmm4
	addss	%xmm1, %xmm4
	movss	%xmm4, (%rbx)
	testl	%esi, %esi
	je	LBB0_2
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	incl	%edx
	movl	$1, %esi
	movq	%r8, %rdi
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_7 Depth=2
	movl	%edi, %ecx
	movss	(%r15,%rcx,4), %xmm5            ## xmm5 = mem[0],zero,zero,zero
	mulss	%xmm2, %xmm5
	addss	%xmm4, %xmm5
	movss	%xmm5, (%rbx,%rsi,4)
	incq	%rsi
	incq	%rdi
	cmpq	%rsi, %rdx
	je	LBB0_2
LBB0_7:                                 ##   Parent Loop BB0_3 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	xorps	%xmm4, %xmm4
	cmpq	%rax, %rsi
	jae	LBB0_6
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=2
	movss	(%r15,%rsi,4), %xmm4            ## xmm4 = mem[0],zero,zero,zero
	mulss	%xmm3, %xmm4
	addss	%xmm1, %xmm4
	jmp	LBB0_6
LBB0_9:
	movaps	-64(%rbp), %xmm0                ## 16-byte Reload
LBB0_10:
	movq	_DEFAULT_CONTAIN_SEL@GOTPCREL(%rip), %rax
	ucomiss	(%rax), %xmm0
	jbe	LBB0_31
## %bb.11:
	testl	%r14d, %r14d
	js	LBB0_32
## %bb.12:
	movl	%r14d, %eax
	leaq	4(,%rax,4), %rsi
	movq	%r15, %rdi
	callq	___bzero
	movaps	LCPI0_1(%rip), %xmm0            ## xmm0 = [-0.0E+0,-0.0E+0,-0.0E+0,-0.0E+0]
	xorps	-64(%rbp), %xmm0                ## 16-byte Folded Reload
	callq	_exp
	movaps	-64(%rbp), %xmm7                ## 16-byte Reload
	leal	1(%r14), %r8d
	leaq	48(%r15), %rcx
	leaq	4(%r15), %rdx
	xorl	%r11d, %r11d
	movl	%r8d, %edi
	jmp	LBB0_14
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_14 Depth=1
	incq	%r11
	xorps	%xmm1, %xmm1
	cvtsi2ss	%r11d, %xmm1
	movaps	%xmm7, %xmm2
	divss	%xmm1, %xmm2
	mulss	%xmm2, %xmm0
	decl	%edi
	addq	$4, %rcx
	addq	$4, %rdx
	cmpq	%r8, %r11
	je	LBB0_33
LBB0_14:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_22 Depth 2
                                        ##     Child Loop BB0_30 Depth 2
	movl	%edi, %edi
	cmpl	%r14d, %r11d
	jg	LBB0_13
## %bb.15:                              ##   in Loop: Header=BB0_14 Depth=1
	movl	%r8d, %r10d
	subl	%r11d, %r10d
	cmpl	$8, %r10d
	jb	LBB0_16
## %bb.17:                              ##   in Loop: Header=BB0_14 Depth=1
	leaq	(%r15,%r11,4), %rax
	leaq	(%rbx,%r10,4), %rsi
	cmpq	%rsi, %rax
	jae	LBB0_20
## %bb.18:                              ##   in Loop: Header=BB0_14 Depth=1
	leaq	(%rax,%r10,4), %rax
	cmpq	%rax, %rbx
	jae	LBB0_20
LBB0_16:                                ##   in Loop: Header=BB0_14 Depth=1
	xorl	%esi, %esi
LBB0_27:                                ##   in Loop: Header=BB0_14 Depth=1
	movq	%rsi, %rax
	testb	$1, %dil
	je	LBB0_29
## %bb.28:                              ##   in Loop: Header=BB0_14 Depth=1
	leaq	(%rsi,%r11), %rax
	movss	(%rbx,%rsi,4), %xmm1            ## xmm1 = mem[0],zero,zero,zero
	mulss	%xmm0, %xmm1
	addss	(%r15,%rax,4), %xmm1
	movss	%xmm1, (%r15,%rax,4)
	movq	%rsi, %rax
	orq	$1, %rax
LBB0_29:                                ##   in Loop: Header=BB0_14 Depth=1
	notq	%rsi
	addq	%rdi, %rsi
	je	LBB0_13
	.p2align	4, 0x90
LBB0_30:                                ##   Parent Loop BB0_14 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movss	(%rbx,%rax,4), %xmm1            ## xmm1 = mem[0],zero,zero,zero
	mulss	%xmm0, %xmm1
	addss	-4(%rdx,%rax,4), %xmm1
	movss	%xmm1, -4(%rdx,%rax,4)
	movss	4(%rbx,%rax,4), %xmm1           ## xmm1 = mem[0],zero,zero,zero
	mulss	%xmm0, %xmm1
	addss	(%rdx,%rax,4), %xmm1
	movss	%xmm1, (%rdx,%rax,4)
	addq	$2, %rax
	cmpq	%rax, %rdi
	jne	LBB0_30
	jmp	LBB0_13
LBB0_20:                                ##   in Loop: Header=BB0_14 Depth=1
	movl	%r10d, %eax
	andl	$-8, %eax
	addq	$-8, %rax
	movq	%rax, %r9
	shrq	$3, %r9
	incq	%r9
	movaps	%xmm0, %xmm1
	shufps	$0, %xmm0, %xmm1                ## xmm1 = xmm1[0,0],xmm0[0,0]
	testq	%rax, %rax
	je	LBB0_23
## %bb.21:                              ##   in Loop: Header=BB0_14 Depth=1
	movl	%edi, %esi
	andl	$-8, %esi
	addq	$-8, %rsi
	shrq	$3, %rsi
	incq	%rsi
	andq	$-2, %rsi
	xorl	%eax, %eax
	.p2align	4, 0x90
LBB0_22:                                ##   Parent Loop BB0_14 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movups	(%rbx,%rax,4), %xmm2
	movups	16(%rbx,%rax,4), %xmm3
	mulps	%xmm1, %xmm2
	movups	-48(%rcx,%rax,4), %xmm4
	addps	%xmm2, %xmm4
	movups	-32(%rcx,%rax,4), %xmm2
	movups	-16(%rcx,%rax,4), %xmm5
	movups	(%rcx,%rax,4), %xmm6
	mulps	%xmm1, %xmm3
	addps	%xmm2, %xmm3
	movups	%xmm4, -48(%rcx,%rax,4)
	movups	%xmm3, -32(%rcx,%rax,4)
	movups	32(%rbx,%rax,4), %xmm2
	movups	48(%rbx,%rax,4), %xmm3
	mulps	%xmm1, %xmm2
	addps	%xmm5, %xmm2
	mulps	%xmm1, %xmm3
	addps	%xmm6, %xmm3
	movups	%xmm2, -16(%rcx,%rax,4)
	movups	%xmm3, (%rcx,%rax,4)
	addq	$16, %rax
	addq	$-2, %rsi
	jne	LBB0_22
	jmp	LBB0_24
LBB0_23:                                ##   in Loop: Header=BB0_14 Depth=1
	xorl	%eax, %eax
LBB0_24:                                ##   in Loop: Header=BB0_14 Depth=1
	movl	%r10d, %esi
	andl	$-8, %esi
	testb	$1, %r9b
	je	LBB0_26
## %bb.25:                              ##   in Loop: Header=BB0_14 Depth=1
	movups	(%rbx,%rax,4), %xmm2
	movups	16(%rbx,%rax,4), %xmm3
	addq	%r11, %rax
	movups	(%r15,%rax,4), %xmm4
	movups	16(%r15,%rax,4), %xmm5
	mulps	%xmm1, %xmm2
	addps	%xmm4, %xmm2
	mulps	%xmm1, %xmm3
	addps	%xmm5, %xmm3
	movups	%xmm2, (%r15,%rax,4)
	movups	%xmm3, 16(%r15,%rax,4)
LBB0_26:                                ##   in Loop: Header=BB0_14 Depth=1
	cmpq	%r10, %rsi
	je	LBB0_13
	jmp	LBB0_27
LBB0_31:
	movq	%r15, %rdi
	movq	%rbx, %r15
	jmp	LBB0_34
LBB0_32:
	xorps	LCPI0_1(%rip), %xmm0
	callq	_exp
LBB0_33:
	movq	%rbx, %rdi
LBB0_34:
	callq	_pfree
	movq	%r15, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DEFAULT_CONTAIN_SEL,4,2        ## @DEFAULT_CONTAIN_SEL
	.no_dead_strip	_calc_distr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function calc_distr
_calc_distr:                            ; @calc_distr
	.cfi_startproc
; %bb.0:
	stp	d9, d8, [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 b8, -72
	.cfi_offset b9, -80
	fmov	s8, s0
	mov	x20, x2
	mov	x23, x1
	mov	x22, x0
	lsl	w8, w2, #2
	add	w19, w8, #4
	mov	x0, x19
	bl	_palloc
	mov	x21, x0
	mov	x0, x19
	bl	_palloc
	mov	x19, x0
	mov	w8, #1065353216
	str	w8, [x21]
	cmp	w23, #1
	b.lt	LBB0_9
; %bb.1:
	add	w8, w23, #1
	mov	w9, #1
	fmov	s0, #1.00000000
	movi	d1, #0000000000000000
	mov	x10, x21
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x9, x9, #1
	mov	x10, x21
	cmp	x9, x8
	b.eq	LBB0_9
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_7 Depth 2
	mov	x21, x19
	mov	x19, x10
	cmp	w20, w9
	csel	w10, w20, w9, lo
	tbnz	w20, #31, LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x11, x22, x9, lsl #2
	ldur	s2, [x11, #-4]
	cmp	w20, w9
	csel	w11, w20, w9, lo
	fsub	s3, s0, s2
	ldr	s4, [x19]
	fmadd	s4, s4, s3, s1
	str	s4, [x21]
	cbz	w11, LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x11, #0
	add	w10, w10, #1
	sub	x10, x10, #1
	add	x12, x21, #4
	add	x13, x19, #4
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=2
	ldr	s5, [x19, w11, uxtw #2]
	fmadd	s4, s5, s2, s4
	str	s4, [x12, x11, lsl #2]
	mov	x11, x14
	cmp	x10, x14
	b.eq	LBB0_2
LBB0_7:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	add	x14, x11, #1
	movi	d4, #0000000000000000
	cmp	x14, x9
	b.hs	LBB0_6
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=2
	ldr	s4, [x13, x11, lsl #2]
	fmadd	s4, s4, s3, s1
	b	LBB0_6
LBB0_9:
Lloh0:
	adrp	x8, _DEFAULT_CONTAIN_SEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DEFAULT_CONTAIN_SEL@GOTPAGEOFF]
Lloh2:
	ldr	s0, [x8]
	fcmp	s0, s8
	b.pl	LBB0_23
; %bb.10:
	tbnz	w20, #31, LBB0_24
; %bb.11:
	mov	w8, w20
	lsl	x8, x8, #2
	add	x1, x8, #4
	mov	x0, x19
	bl	_bzero
	fneg	s0, s8
	bl	_exp
                                        ; kill: def $s0 killed $s0 def $q0
	mov	x8, #0
	add	w9, w20, #1
	add	x10, x19, #32
	add	x11, x21, #32
	mov	x12, x9
	b	LBB0_13
LBB0_12:                                ;   in Loop: Header=BB0_13 Depth=1
	add	x8, x8, #1
	scvtf	s1, w8
	fdiv	s1, s8, s1
	fmul	s0, s0, s1
	sub	w12, w12, #1
	add	x10, x10, #4
	cmp	x8, x9
	b.eq	LBB0_25
LBB0_13:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_21 Depth 2
                                        ;     Child Loop BB0_19 Depth 2
	mov	w12, w12
	cmp	w8, w20
	b.gt	LBB0_12
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	sub	w13, w9, w8
	cmp	w13, #16
	b.lo	LBB0_17
; %bb.15:                               ;   in Loop: Header=BB0_13 Depth=1
	add	x14, x19, x8, lsl #2
	lsl	x15, x13, #2
	add	x16, x21, x15
	cmp	x14, x16
	b.hs	LBB0_20
; %bb.16:                               ;   in Loop: Header=BB0_13 Depth=1
	add	x14, x14, x15
	cmp	x21, x14
	b.hs	LBB0_20
LBB0_17:                                ;   in Loop: Header=BB0_13 Depth=1
	mov	x14, #0
LBB0_18:                                ;   in Loop: Header=BB0_13 Depth=1
	add	x13, x14, x8
	add	x13, x19, x13, lsl #2
	add	x15, x21, x14, lsl #2
	sub	x14, x12, x14
LBB0_19:                                ;   Parent Loop BB0_13 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	s1, [x15], #4
	ldr	s2, [x13]
	fmadd	s1, s1, s0, s2
	str	s1, [x13], #4
	subs	x14, x14, #1
	b.ne	LBB0_19
	b	LBB0_12
LBB0_20:                                ;   in Loop: Header=BB0_13 Depth=1
	and	x15, x12, #0xfffffff0
	and	x14, x13, #0xfffffff0
	dup.4s	v1, v0[0]
	mov	x16, x11
	mov	x17, x10
LBB0_21:                                ;   Parent Loop BB0_13 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldp	q2, q3, [x16, #-32]
	ldp	q4, q5, [x16], #64
	ldp	q6, q7, [x17, #-32]
	ldp	q16, q17, [x17]
	fmla.4s	v6, v1, v2
	fmla.4s	v7, v1, v3
	fmla.4s	v16, v1, v4
	fmla.4s	v17, v1, v5
	stp	q6, q7, [x17, #-32]
	stp	q16, q17, [x17], #64
	subs	x15, x15, #16
	b.ne	LBB0_21
; %bb.22:                               ;   in Loop: Header=BB0_13 Depth=1
	cmp	x14, x13
	b.eq	LBB0_12
	b	LBB0_18
LBB0_23:
	mov	x0, x19
	mov	x19, x21
	b	LBB0_26
LBB0_24:
	fneg	s0, s8
	bl	_exp
LBB0_25:
	mov	x0, x21
LBB0_26:
	bl	_pfree
	mov	x0, 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
	ldp	d9, d8, [sp], #80               ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_DEFAULT_CONTAIN_SEL,4,2        ; @DEFAULT_CONTAIN_SEL
	.no_dead_strip	_calc_distr
.subsections_via_symbols
