Program: k-means

x86 assembly:
	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ## -- Begin function calculateNearst
LCPI0_0:
	.quad	0x7fefffffffffffff              ## double 1.7976931348623157E+308
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_calculateNearst
	.p2align	4, 0x90
_calculateNearst:                       ## @calculateNearst
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movl	%edx, -20(%rbp)
	movsd	LCPI0_0(%rip), %xmm0            ## xmm0 = mem[0],zero
	movsd	%xmm0, -32(%rbp)
	xorps	%xmm0, %xmm0
	movsd	%xmm0, -40(%rbp)
	movl	$-1, -44(%rbp)
	movl	$0, -48(%rbp)
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movl	-48(%rbp), %eax
	cmpl	-20(%rbp), %eax
	jge	LBB0_6
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	-16(%rbp), %rax
	movslq	-48(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	(%rax), %xmm0                   ## xmm0 = mem[0],zero
	movq	-8(%rbp), %rax
	subsd	(%rax), %xmm0
	movq	-16(%rbp), %rax
	movslq	-48(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	(%rax), %xmm2                   ## xmm2 = mem[0],zero
	movq	-8(%rbp), %rax
	subsd	(%rax), %xmm2
	movq	-16(%rbp), %rax
	movslq	-48(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm1                  ## xmm1 = mem[0],zero
	movq	-8(%rbp), %rax
	subsd	8(%rax), %xmm1
	movq	-16(%rbp), %rax
	movslq	-48(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm3                  ## xmm3 = mem[0],zero
	movq	-8(%rbp), %rax
	subsd	8(%rax), %xmm3
	mulsd	%xmm3, %xmm1
	mulsd	%xmm2, %xmm0
	addsd	%xmm1, %xmm0
	movsd	%xmm0, -40(%rbp)
	movsd	-40(%rbp), %xmm1                ## xmm1 = mem[0],zero
	movsd	-32(%rbp), %xmm0                ## xmm0 = mem[0],zero
	ucomisd	%xmm1, %xmm0
	jbe	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_1 Depth=1
	movsd	-40(%rbp), %xmm0                ## xmm0 = mem[0],zero
	movsd	%xmm0, -32(%rbp)
	movl	-48(%rbp), %eax
	movl	%eax, -44(%rbp)
LBB0_4:                                 ##   in Loop: Header=BB0_1 Depth=1
	jmp	LBB0_5
LBB0_5:                                 ##   in Loop: Header=BB0_1 Depth=1
	movl	-48(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -48(%rbp)
	jmp	LBB0_1
LBB0_6:
	movl	-44(%rbp), %eax
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function calculateCentroid
LCPI1_0:
	.long	1127219200                      ## 0x43300000
	.long	1160773632                      ## 0x45300000
	.long	0                               ## 0x0
	.long	0                               ## 0x0
LCPI1_1:
	.quad	0x4330000000000000              ## double 4503599627370496
	.quad	0x4530000000000000              ## double 1.9342813113834067E+25
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_calculateCentroid
	.p2align	4, 0x90
_calculateCentroid:                     ## @calculateCentroid
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	%rdx, -24(%rbp)
	movq	$0, -32(%rbp)
	movq	-24(%rbp), %rax
	xorps	%xmm0, %xmm0
	movsd	%xmm0, (%rax)
	movq	-24(%rbp), %rax
	xorps	%xmm0, %xmm0
	movsd	%xmm0, 8(%rax)
	movq	-16(%rbp), %rcx
	movq	-24(%rbp), %rax
	movq	%rcx, 16(%rax)
LBB1_1:                                 ## =>This Inner Loop Header: Depth=1
	movq	-32(%rbp), %rax
	cmpq	-16(%rbp), %rax
	jae	LBB1_4
## %bb.2:                               ##   in Loop: Header=BB1_1 Depth=1
	movq	-8(%rbp), %rax
	imulq	$24, -32(%rbp), %rcx
	addq	%rcx, %rax
	movsd	(%rax), %xmm0                   ## xmm0 = mem[0],zero
	movq	-24(%rbp), %rax
	addsd	(%rax), %xmm0
	movsd	%xmm0, (%rax)
	movq	-8(%rbp), %rax
	imulq	$24, -32(%rbp), %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm0                  ## xmm0 = mem[0],zero
	movq	-24(%rbp), %rax
	addsd	8(%rax), %xmm0
	movsd	%xmm0, 8(%rax)
	movq	-8(%rbp), %rax
	imulq	$24, -32(%rbp), %rcx
	addq	%rcx, %rax
	movl	$0, 16(%rax)
## %bb.3:                               ##   in Loop: Header=BB1_1 Depth=1
	movq	-32(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -32(%rbp)
	jmp	LBB1_1
LBB1_4:
	movq	-24(%rbp), %rax
	movq	16(%rax), %xmm3                 ## xmm3 = mem[0],zero
	movaps	LCPI1_0(%rip), %xmm2            ## xmm2 = [1127219200,1160773632,0,0]
	punpckldq	%xmm2, %xmm3            ## xmm3 = xmm3[0],xmm2[0],xmm3[1],xmm2[1]
	movapd	LCPI1_1(%rip), %xmm0            ## xmm0 = [4.503599627370496E+15,1.9342813113834067E+25]
	subpd	%xmm0, %xmm3
	movaps	%xmm3, %xmm1
	unpckhpd	%xmm3, %xmm3                    ## xmm3 = xmm3[1,1]
	addsd	%xmm1, %xmm3
	movsd	(%rax), %xmm1                   ## xmm1 = mem[0],zero
	divsd	%xmm3, %xmm1
	movsd	%xmm1, (%rax)
	movq	-24(%rbp), %rax
	movq	16(%rax), %xmm1                 ## xmm1 = mem[0],zero
	punpckldq	%xmm2, %xmm1            ## xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
	subpd	%xmm0, %xmm1
	movaps	%xmm1, %xmm0
	unpckhpd	%xmm1, %xmm1                    ## xmm1 = xmm1[1,1]
	addsd	%xmm0, %xmm1
	movq	-24(%rbp), %rax
	movsd	8(%rax), %xmm0                  ## xmm0 = mem[0],zero
	divsd	%xmm1, %xmm0
	movsd	%xmm0, 8(%rax)
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function kMeans
LCPI2_0:
	.long	1127219200                      ## 0x43300000
	.long	1160773632                      ## 0x45300000
	.long	0                               ## 0x0
	.long	0                               ## 0x0
LCPI2_1:
	.quad	0x4330000000000000              ## double 4503599627370496
	.quad	0x4530000000000000              ## double 1.9342813113834067E+25
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_kMeans
	.p2align	4, 0x90
_kMeans:                                ## @kMeans
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	subq	$96, %rsp
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movl	%edx, -20(%rbp)
	movq	$0, -32(%rbp)
	cmpl	$1, -20(%rbp)
	jg	LBB2_2
## %bb.1:
	movl	$24, %edi
	callq	_libmin_malloc
	movq	%rax, -32(%rbp)
	movq	-32(%rbp), %rdi
	xorl	%esi, %esi
	movl	$24, %edx
	callq	_libmin_memset
	movq	-8(%rbp), %rdi
	movq	-16(%rbp), %rsi
	movq	-32(%rbp), %rdx
	callq	_calculateCentroid
	jmp	LBB2_35
LBB2_2:
	movslq	-20(%rbp), %rax
	cmpq	-16(%rbp), %rax
	jae	LBB2_29
## %bb.3:
	movslq	-20(%rbp), %rax
	imulq	$24, %rax, %rdi
	callq	_libmin_malloc
	movq	%rax, -32(%rbp)
	movq	-32(%rbp), %rdi
	movslq	-20(%rbp), %rax
	imulq	$24, %rax, %rdx
	xorl	%esi, %esi
	callq	_libmin_memset
	movq	$0, -40(%rbp)
LBB2_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	-40(%rbp), %rax
	cmpq	-16(%rbp), %rax
	jae	LBB2_7
## %bb.5:                               ##   in Loop: Header=BB2_4 Depth=1
	callq	_libmin_rand
	xorl	%edx, %edx
	divl	-20(%rbp)
	movq	-8(%rbp), %rax
	imulq	$24, -40(%rbp), %rcx
	addq	%rcx, %rax
	movl	%edx, 16(%rax)
## %bb.6:                               ##   in Loop: Header=BB2_4 Depth=1
	movq	-40(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -40(%rbp)
	jmp	LBB2_4
LBB2_7:
	movq	$0, -48(%rbp)
	movq	-16(%rbp), %rax
	movl	$10000, %ecx                    ## imm = 0x2710
	xorl	%edx, %edx
                                        ## kill: def $rdx killed $edx
	divq	%rcx
	movq	%rax, -56(%rbp)
	movl	$0, -60(%rbp)
LBB2_8:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB2_9 Depth 2
                                        ##     Child Loop BB2_13 Depth 2
                                        ##     Child Loop BB2_17 Depth 2
                                        ##     Child Loop BB2_21 Depth 2
	movl	$0, -64(%rbp)
LBB2_9:                                 ##   Parent Loop BB2_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	-64(%rbp), %eax
	cmpl	-20(%rbp), %eax
	jge	LBB2_12
## %bb.10:                              ##   in Loop: Header=BB2_9 Depth=2
	movq	-32(%rbp), %rax
	movslq	-64(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	xorps	%xmm0, %xmm0
	movsd	%xmm0, (%rax)
	movq	-32(%rbp), %rax
	movslq	-64(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	xorps	%xmm0, %xmm0
	movsd	%xmm0, 8(%rax)
	movq	-32(%rbp), %rax
	movslq	-64(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movq	$0, 16(%rax)
## %bb.11:                              ##   in Loop: Header=BB2_9 Depth=2
	movl	-64(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -64(%rbp)
	jmp	LBB2_9
LBB2_12:                                ##   in Loop: Header=BB2_8 Depth=1
	movq	$0, -72(%rbp)
LBB2_13:                                ##   Parent Loop BB2_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	-72(%rbp), %rax
	cmpq	-16(%rbp), %rax
	jae	LBB2_16
## %bb.14:                              ##   in Loop: Header=BB2_13 Depth=2
	movq	-8(%rbp), %rax
	imulq	$24, -72(%rbp), %rcx
	addq	%rcx, %rax
	movl	16(%rax), %eax
	movl	%eax, -60(%rbp)
	movq	-8(%rbp), %rax
	imulq	$24, -72(%rbp), %rcx
	addq	%rcx, %rax
	movsd	(%rax), %xmm0                   ## xmm0 = mem[0],zero
	movq	-32(%rbp), %rax
	movslq	-60(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	addsd	(%rax), %xmm0
	movsd	%xmm0, (%rax)
	movq	-8(%rbp), %rax
	imulq	$24, -72(%rbp), %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm0                  ## xmm0 = mem[0],zero
	movq	-32(%rbp), %rax
	movslq	-60(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	addsd	8(%rax), %xmm0
	movsd	%xmm0, 8(%rax)
	movq	-32(%rbp), %rax
	movslq	-60(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movq	16(%rax), %rcx
	addq	$1, %rcx
	movq	%rcx, 16(%rax)
## %bb.15:                              ##   in Loop: Header=BB2_13 Depth=2
	movq	-72(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -72(%rbp)
	jmp	LBB2_13
LBB2_16:                                ##   in Loop: Header=BB2_8 Depth=1
	movl	$0, -76(%rbp)
LBB2_17:                                ##   Parent Loop BB2_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	-76(%rbp), %eax
	cmpl	-20(%rbp), %eax
	jge	LBB2_20
## %bb.18:                              ##   in Loop: Header=BB2_17 Depth=2
	movq	-32(%rbp), %rax
	movslq	-76(%rbp), %rcx
	leaq	(%rcx,%rcx,2), %rcx
	movq	16(%rax,%rcx,8), %xmm3          ## xmm3 = mem[0],zero
	movaps	LCPI2_0(%rip), %xmm2            ## xmm2 = [1127219200,1160773632,0,0]
	punpckldq	%xmm2, %xmm3            ## xmm3 = xmm3[0],xmm2[0],xmm3[1],xmm2[1]
	movapd	LCPI2_1(%rip), %xmm0            ## xmm0 = [4.503599627370496E+15,1.9342813113834067E+25]
	subpd	%xmm0, %xmm3
	movaps	%xmm3, %xmm1
	unpckhpd	%xmm3, %xmm3                    ## xmm3 = xmm3[1,1]
	addsd	%xmm1, %xmm3
	movsd	(%rax,%rcx,8), %xmm1            ## xmm1 = mem[0],zero
	divsd	%xmm3, %xmm1
	movsd	%xmm1, (%rax,%rcx,8)
	movq	-32(%rbp), %rax
	movslq	-76(%rbp), %rcx
	leaq	(%rcx,%rcx,2), %rcx
	movq	16(%rax,%rcx,8), %xmm1          ## xmm1 = mem[0],zero
	punpckldq	%xmm2, %xmm1            ## xmm1 = xmm1[0],xmm2[0],xmm1[1],xmm2[1]
	subpd	%xmm0, %xmm1
	movaps	%xmm1, %xmm0
	unpckhpd	%xmm1, %xmm1                    ## xmm1 = xmm1[1,1]
	addsd	%xmm0, %xmm1
	movq	-32(%rbp), %rax
	movslq	-76(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm0                  ## xmm0 = mem[0],zero
	divsd	%xmm1, %xmm0
	movsd	%xmm0, 8(%rax)
## %bb.19:                              ##   in Loop: Header=BB2_17 Depth=2
	movl	-76(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -76(%rbp)
	jmp	LBB2_17
LBB2_20:                                ##   in Loop: Header=BB2_8 Depth=1
	movq	$0, -48(%rbp)
	movq	$0, -88(%rbp)
LBB2_21:                                ##   Parent Loop BB2_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	-88(%rbp), %rax
	cmpq	-16(%rbp), %rax
	jae	LBB2_26
## %bb.22:                              ##   in Loop: Header=BB2_21 Depth=2
	movq	-8(%rbp), %rdi
	imulq	$24, -88(%rbp), %rax
	addq	%rax, %rdi
	movq	-32(%rbp), %rsi
	movl	-20(%rbp), %edx
	callq	_calculateNearst
	movl	%eax, -60(%rbp)
	movl	-60(%rbp), %eax
	movq	-8(%rbp), %rcx
	imulq	$24, -88(%rbp), %rdx
	addq	%rdx, %rcx
	cmpl	16(%rcx), %eax
	je	LBB2_24
## %bb.23:                              ##   in Loop: Header=BB2_21 Depth=2
	movq	-48(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -48(%rbp)
	movl	-60(%rbp), %ecx
	movq	-8(%rbp), %rax
	imulq	$24, -88(%rbp), %rdx
	addq	%rdx, %rax
	movl	%ecx, 16(%rax)
LBB2_24:                                ##   in Loop: Header=BB2_21 Depth=2
	jmp	LBB2_25
LBB2_25:                                ##   in Loop: Header=BB2_21 Depth=2
	movq	-88(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -88(%rbp)
	jmp	LBB2_21
LBB2_26:                                ##   in Loop: Header=BB2_8 Depth=1
	jmp	LBB2_27
LBB2_27:                                ##   in Loop: Header=BB2_8 Depth=1
	movq	-48(%rbp), %rax
	cmpq	-56(%rbp), %rax
	ja	LBB2_8
## %bb.28:
	jmp	LBB2_34
LBB2_29:
	movslq	-20(%rbp), %rax
	imulq	$24, %rax, %rdi
	callq	_libmin_malloc
	movq	%rax, -32(%rbp)
	movq	-32(%rbp), %rdi
	movslq	-20(%rbp), %rax
	imulq	$24, %rax, %rdx
	xorl	%esi, %esi
	callq	_libmin_memset
	movl	$0, -92(%rbp)
LBB2_30:                                ## =>This Inner Loop Header: Depth=1
	movslq	-92(%rbp), %rax
	cmpq	-16(%rbp), %rax
	jae	LBB2_33
## %bb.31:                              ##   in Loop: Header=BB2_30 Depth=1
	movq	-8(%rbp), %rax
	movslq	-92(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	(%rax), %xmm0                   ## xmm0 = mem[0],zero
	movq	-32(%rbp), %rax
	movslq	-92(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	%xmm0, (%rax)
	movq	-8(%rbp), %rax
	movslq	-92(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm0                  ## xmm0 = mem[0],zero
	movq	-32(%rbp), %rax
	movslq	-92(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	%xmm0, 8(%rax)
	movq	-32(%rbp), %rax
	movslq	-92(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movq	$1, 16(%rax)
	movl	-92(%rbp), %ecx
	movq	-8(%rbp), %rax
	movslq	-92(%rbp), %rdx
	imulq	$24, %rdx, %rdx
	addq	%rdx, %rax
	movl	%ecx, 16(%rax)
## %bb.32:                              ##   in Loop: Header=BB2_30 Depth=1
	movl	-92(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -92(%rbp)
	jmp	LBB2_30
LBB2_33:
	jmp	LBB2_34
LBB2_34:
	jmp	LBB2_35
LBB2_35:
	movq	-32(%rbp), %rax
	addq	$96, %rsp
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ## -- Begin function printEPS
LCPI3_0:
	.quad	0x3ff0000000000000              ## double 1
LCPI3_1:
	.quad	0x0010000000000000              ## double 2.2250738585072014E-308
LCPI3_2:
	.quad	0x7fefffffffffffff              ## double 1.7976931348623157E+308
LCPI3_3:
	.quad	0x4000000000000000              ## double 2
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_printEPS
	.p2align	4, 0x90
_printEPS:                              ## @printEPS
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	subq	$144, %rsp
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	%rdx, -24(%rbp)
	movl	%ecx, -28(%rbp)
	movl	$400, -32(%rbp)                 ## imm = 0x190
	movl	$400, -36(%rbp)                 ## imm = 0x190
	movsd	LCPI3_2(%rip), %xmm0            ## xmm0 = mem[0],zero
	movsd	%xmm0, -48(%rbp)
	movsd	LCPI3_1(%rip), %xmm0            ## xmm0 = mem[0],zero
	movsd	%xmm0, -56(%rbp)
	movsd	LCPI3_2(%rip), %xmm0            ## xmm0 = mem[0],zero
	movsd	%xmm0, -64(%rbp)
	movsd	LCPI3_1(%rip), %xmm0            ## xmm0 = mem[0],zero
	movsd	%xmm0, -72(%rbp)
	xorps	%xmm0, %xmm0
	movsd	%xmm0, -80(%rbp)
	xorps	%xmm0, %xmm0
	movsd	%xmm0, -88(%rbp)
	xorps	%xmm0, %xmm0
	movsd	%xmm0, -96(%rbp)
	imull	$3, -28(%rbp), %eax
	movslq	%eax, %rdi
	shlq	$3, %rdi
	callq	_libmin_malloc
	movq	%rax, -104(%rbp)
	cvtsi2sdl	-28(%rbp), %xmm0
	movsd	LCPI3_0(%rip), %xmm1            ## xmm1 = mem[0],zero
	mulsd	%xmm1, %xmm0
	movsd	%xmm0, -128(%rbp)
	movl	$0, -108(%rbp)
LBB3_1:                                 ## =>This Inner Loop Header: Depth=1
	movl	-108(%rbp), %eax
	cmpl	-28(%rbp), %eax
	jge	LBB3_4
## %bb.2:                               ##   in Loop: Header=BB3_1 Depth=1
	movl	-108(%rbp), %eax
	addl	$1, %eax
	imull	$3, %eax, %eax
	cltd
	idivl	-28(%rbp)
	cvtsi2sd	%edx, %xmm0
	divsd	-128(%rbp), %xmm0
	movq	-104(%rbp), %rax
	imull	$3, -108(%rbp), %ecx
	movslq	%ecx, %rcx
	movsd	%xmm0, (%rax,%rcx,8)
	imull	$7, -108(%rbp), %eax
	cltd
	idivl	-28(%rbp)
	cvtsi2sd	%edx, %xmm0
	divsd	-128(%rbp), %xmm0
	movq	-104(%rbp), %rax
	imull	$3, -108(%rbp), %ecx
	movslq	%ecx, %rcx
	movsd	%xmm0, 8(%rax,%rcx,8)
	imull	$9, -108(%rbp), %eax
	cltd
	idivl	-28(%rbp)
	cvtsi2sd	%edx, %xmm0
	divsd	-128(%rbp), %xmm0
	movq	-104(%rbp), %rax
	imull	$3, -108(%rbp), %ecx
	movslq	%ecx, %rcx
	movsd	%xmm0, 16(%rax,%rcx,8)
## %bb.3:                               ##   in Loop: Header=BB3_1 Depth=1
	movl	-108(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -108(%rbp)
	jmp	LBB3_1
LBB3_4:
	movq	$0, -120(%rbp)
LBB3_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	-120(%rbp), %rax
	cmpq	-16(%rbp), %rax
	jae	LBB3_16
## %bb.6:                               ##   in Loop: Header=BB3_5 Depth=1
	movsd	-56(%rbp), %xmm1                ## xmm1 = mem[0],zero
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	movsd	(%rax), %xmm0                   ## xmm0 = mem[0],zero
	ucomisd	%xmm1, %xmm0
	jbe	LBB3_8
## %bb.7:                               ##   in Loop: Header=BB3_5 Depth=1
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	movsd	(%rax), %xmm0                   ## xmm0 = mem[0],zero
	movsd	%xmm0, -56(%rbp)
LBB3_8:                                 ##   in Loop: Header=BB3_5 Depth=1
	movsd	-48(%rbp), %xmm0                ## xmm0 = mem[0],zero
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	ucomisd	(%rax), %xmm0
	jbe	LBB3_10
## %bb.9:                               ##   in Loop: Header=BB3_5 Depth=1
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	movsd	(%rax), %xmm0                   ## xmm0 = mem[0],zero
	movsd	%xmm0, -48(%rbp)
LBB3_10:                                ##   in Loop: Header=BB3_5 Depth=1
	movsd	-72(%rbp), %xmm1                ## xmm1 = mem[0],zero
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm0                  ## xmm0 = mem[0],zero
	ucomisd	%xmm1, %xmm0
	jbe	LBB3_12
## %bb.11:                              ##   in Loop: Header=BB3_5 Depth=1
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm0                  ## xmm0 = mem[0],zero
	movsd	%xmm0, -72(%rbp)
LBB3_12:                                ##   in Loop: Header=BB3_5 Depth=1
	movsd	-64(%rbp), %xmm0                ## xmm0 = mem[0],zero
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	ucomisd	8(%rax), %xmm0
	jbe	LBB3_14
## %bb.13:                              ##   in Loop: Header=BB3_5 Depth=1
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm0                  ## xmm0 = mem[0],zero
	movsd	%xmm0, -64(%rbp)
LBB3_14:                                ##   in Loop: Header=BB3_5 Depth=1
	jmp	LBB3_15
LBB3_15:                                ##   in Loop: Header=BB3_5 Depth=1
	movq	-120(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -120(%rbp)
	jmp	LBB3_5
LBB3_16:
	cvtsi2sdl	-32(%rbp), %xmm0
	movsd	-56(%rbp), %xmm1                ## xmm1 = mem[0],zero
	subsd	-48(%rbp), %xmm1
	divsd	%xmm1, %xmm0
	movsd	%xmm0, -80(%rbp)
	movsd	-80(%rbp), %xmm0                ## xmm0 = mem[0],zero
	cvtsi2sdl	-36(%rbp), %xmm1
	movsd	-72(%rbp), %xmm2                ## xmm2 = mem[0],zero
	subsd	-64(%rbp), %xmm2
	divsd	%xmm2, %xmm1
	ucomisd	%xmm1, %xmm0
	jbe	LBB3_18
## %bb.17:
	cvtsi2sdl	-36(%rbp), %xmm0
	movsd	-72(%rbp), %xmm1                ## xmm1 = mem[0],zero
	subsd	-64(%rbp), %xmm1
	divsd	%xmm1, %xmm0
	movsd	%xmm0, -80(%rbp)
LBB3_18:
	movsd	-56(%rbp), %xmm0                ## xmm0 = mem[0],zero
	addsd	-48(%rbp), %xmm0
	movsd	LCPI3_3(%rip), %xmm1            ## xmm1 = mem[0],zero
	divsd	%xmm1, %xmm0
	movsd	%xmm0, -88(%rbp)
	movsd	-72(%rbp), %xmm0                ## xmm0 = mem[0],zero
	addsd	-64(%rbp), %xmm0
	movsd	LCPI3_3(%rip), %xmm1            ## xmm1 = mem[0],zero
	divsd	%xmm1, %xmm0
	movsd	%xmm0, -96(%rbp)
	movl	-32(%rbp), %esi
	addl	$10, %esi
	movl	-36(%rbp), %edx
	addl	$10, %edx
	leaq	L_.str(%rip), %rdi
	movb	$0, %al
	callq	_libmin_printf
	leaq	L_.str.1(%rip), %rdi
	movb	$0, %al
	callq	_libmin_printf
	movl	$0, -132(%rbp)
LBB3_19:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB3_21 Depth 2
	movl	-132(%rbp), %eax
	cmpl	-28(%rbp), %eax
	jge	LBB3_28
## %bb.20:                              ##   in Loop: Header=BB3_19 Depth=1
	movq	-104(%rbp), %rax
	imull	$3, -132(%rbp), %ecx
	movslq	%ecx, %rcx
	movsd	(%rax,%rcx,8), %xmm0            ## xmm0 = mem[0],zero
	movq	-104(%rbp), %rax
	imull	$3, -132(%rbp), %ecx
	movslq	%ecx, %rcx
	movsd	8(%rax,%rcx,8), %xmm1           ## xmm1 = mem[0],zero
	movq	-104(%rbp), %rax
	imull	$3, -132(%rbp), %ecx
	movslq	%ecx, %rcx
	movsd	16(%rax,%rcx,8), %xmm2          ## xmm2 = mem[0],zero
	leaq	L_.str.2(%rip), %rdi
	movb	$3, %al
	callq	_libmin_printf
	movq	$0, -120(%rbp)
LBB3_21:                                ##   Parent Loop BB3_19 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	-120(%rbp), %rax
	cmpq	-16(%rbp), %rax
	jae	LBB3_26
## %bb.22:                              ##   in Loop: Header=BB3_21 Depth=2
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	movl	16(%rax), %eax
	cmpl	-132(%rbp), %eax
	je	LBB3_24
## %bb.23:                              ##   in Loop: Header=BB3_21 Depth=2
	jmp	LBB3_25
LBB3_24:                                ##   in Loop: Header=BB3_21 Depth=2
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	movsd	(%rax), %xmm0                   ## xmm0 = mem[0],zero
	subsd	-88(%rbp), %xmm0
	movsd	-80(%rbp), %xmm2                ## xmm2 = mem[0],zero
	movl	-32(%rbp), %eax
	movl	$2, %ecx
	cltd
	idivl	%ecx
	cvtsi2sd	%eax, %xmm1
	mulsd	%xmm2, %xmm0
	addsd	%xmm1, %xmm0
	movq	-8(%rbp), %rax
	imulq	$24, -120(%rbp), %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm1                  ## xmm1 = mem[0],zero
	subsd	-96(%rbp), %xmm1
	movsd	-80(%rbp), %xmm3                ## xmm3 = mem[0],zero
	movl	-36(%rbp), %eax
	movl	$2, %ecx
	cltd
	idivl	%ecx
	cvtsi2sd	%eax, %xmm2
	mulsd	%xmm3, %xmm1
	addsd	%xmm2, %xmm1
	leaq	L_.str.3(%rip), %rdi
	movb	$2, %al
	callq	_libmin_printf
LBB3_25:                                ##   in Loop: Header=BB3_21 Depth=2
	movq	-120(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -120(%rbp)
	jmp	LBB3_21
LBB3_26:                                ##   in Loop: Header=BB3_19 Depth=1
	movq	-24(%rbp), %rax
	movslq	-132(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	(%rax), %xmm0                   ## xmm0 = mem[0],zero
	subsd	-88(%rbp), %xmm0
	movsd	-80(%rbp), %xmm2                ## xmm2 = mem[0],zero
	movl	-32(%rbp), %eax
	movl	$2, %ecx
	cltd
	idivl	%ecx
	cvtsi2sd	%eax, %xmm1
	mulsd	%xmm2, %xmm0
	addsd	%xmm1, %xmm0
	movq	-24(%rbp), %rax
	movslq	-132(%rbp), %rcx
	imulq	$24, %rcx, %rcx
	addq	%rcx, %rax
	movsd	8(%rax), %xmm1                  ## xmm1 = mem[0],zero
	subsd	-96(%rbp), %xmm1
	movsd	-80(%rbp), %xmm3                ## xmm3 = mem[0],zero
	movl	-36(%rbp), %eax
	movl	$2, %ecx
	cltd
	idivl	%ecx
	cvtsi2sd	%eax, %xmm2
	mulsd	%xmm3, %xmm1
	addsd	%xmm2, %xmm1
	leaq	L_.str.4(%rip), %rdi
	movb	$2, %al
	callq	_libmin_printf
## %bb.27:                              ##   in Loop: Header=BB3_19 Depth=1
	movl	-132(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -132(%rbp)
	jmp	LBB3_19
LBB3_28:
	leaq	L_.str.5(%rip), %rdi
	movb	$0, %al
	callq	_libmin_printf
	movq	-104(%rbp), %rdi
	callq	_libmin_free
	addq	$144, %rsp
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ## -- Begin function test2
LCPI4_0:
	.quad	0x4034000000000000              ## double 20
LCPI4_1:
	.quad	0x401921fb54442d18              ## double 6.2831853071795862
LCPI4_2:
	.quad	0x41dfffffffc00000              ## double 2147483647
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_test2
	.p2align	4, 0x90
_test2:                                 ## @test2
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	subq	$96, %rsp
	movq	$1000000, -8(%rbp)              ## imm = 0xF4240
	imulq	$24, -8(%rbp), %rdi
	callq	_libmin_malloc
	movq	%rax, -16(%rbp)
	movsd	LCPI4_0(%rip), %xmm0            ## xmm0 = mem[0],zero
	movsd	%xmm0, -24(%rbp)
	xorps	%xmm0, %xmm0
	movsd	%xmm0, -32(%rbp)
	xorps	%xmm0, %xmm0
	movsd	%xmm0, -40(%rbp)
	movq	$0, -48(%rbp)
LBB4_1:                                 ## =>This Inner Loop Header: Depth=1
	movq	-48(%rbp), %rax
	cmpq	-8(%rbp), %rax
	jae	LBB4_4
## %bb.2:                               ##   in Loop: Header=BB4_1 Depth=1
	movsd	-24(%rbp), %xmm0                ## xmm0 = mem[0],zero
	movsd	%xmm0, -88(%rbp)                ## 8-byte Spill
	callq	_libmin_rand
	movsd	-88(%rbp), %xmm0                ## 8-byte Reload
                                        ## xmm0 = mem[0],zero
	movl	%eax, %eax
                                        ## kill: def $rax killed $eax
	cvtsi2sd	%rax, %xmm1
	movsd	LCPI4_2(%rip), %xmm2            ## xmm2 = mem[0],zero
	divsd	%xmm2, %xmm1
	mulsd	%xmm1, %xmm0
	movsd	%xmm0, -32(%rbp)
	callq	_libmin_rand
	movl	%eax, %eax
                                        ## kill: def $rax killed $eax
	cvtsi2sd	%rax, %xmm1
	movsd	LCPI4_2(%rip), %xmm0            ## xmm0 = mem[0],zero
	divsd	%xmm0, %xmm1
	movsd	LCPI4_1(%rip), %xmm0            ## xmm0 = mem[0],zero
	mulsd	%xmm1, %xmm0
	movsd	%xmm0, -40(%rbp)
	movsd	-32(%rbp), %xmm0                ## xmm0 = mem[0],zero
	movsd	%xmm0, -80(%rbp)                ## 8-byte Spill
	movsd	-40(%rbp), %xmm0                ## xmm0 = mem[0],zero
	callq	_libmin_cos
	movaps	%xmm0, %xmm1
	movsd	-80(%rbp), %xmm0                ## 8-byte Reload
                                        ## xmm0 = mem[0],zero
	mulsd	%xmm1, %xmm0
	movq	-16(%rbp), %rax
	imulq	$24, -48(%rbp), %rcx
	addq	%rcx, %rax
	movsd	%xmm0, (%rax)
	movsd	-32(%rbp), %xmm0                ## xmm0 = mem[0],zero
	movsd	%xmm0, -72(%rbp)                ## 8-byte Spill
	movsd	-40(%rbp), %xmm0                ## xmm0 = mem[0],zero
	callq	_libmin_sin
	movaps	%xmm0, %xmm1
	movsd	-72(%rbp), %xmm0                ## 8-byte Reload
                                        ## xmm0 = mem[0],zero
	mulsd	%xmm1, %xmm0
	movq	-16(%rbp), %rax
	imulq	$24, -48(%rbp), %rcx
	addq	%rcx, %rax
	movsd	%xmm0, 8(%rax)
## %bb.3:                               ##   in Loop: Header=BB4_1 Depth=1
	movq	-48(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -48(%rbp)
	jmp	LBB4_1
LBB4_4:
	movl	$11, -52(%rbp)
	movq	-16(%rbp), %rdi
	movq	-8(%rbp), %rsi
	movl	-52(%rbp), %edx
	callq	_kMeans
	movq	%rax, -64(%rbp)
	movq	-16(%rbp), %rdi
	movq	-8(%rbp), %rsi
	movq	-64(%rbp), %rdx
	movl	-52(%rbp), %ecx
	callq	_printEPS
	movq	-16(%rbp), %rdi
	callq	_libmin_free
	movq	-64(%rbp), %rdi
	callq	_libmin_free
	addq	$96, %rsp
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.globl	_main                           ## -- Begin function main
	.p2align	4, 0x90
_main:                                  ## @main
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	subq	$16, %rsp
	movl	$0, -4(%rbp)
	movl	$42, %edi
	callq	_libmin_srand
	callq	_test
	callq	_libmin_success
	xorl	%eax, %eax
	addq	$16, %rsp
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ## -- Begin function test
LCPI6_0:
	.quad	0x4034000000000000              ## double 20
LCPI6_1:
	.quad	0x401921fb54442d18              ## double 6.2831853071795862
LCPI6_2:
	.quad	0x41dfffffffc00000              ## double 2147483647
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_test:                                  ## @test
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	subq	$96, %rsp
	movq	$200, -8(%rbp)
	imulq	$24, -8(%rbp), %rdi
	callq	_libmin_malloc
	movq	%rax, -16(%rbp)
	movsd	LCPI6_0(%rip), %xmm0            ## xmm0 = mem[0],zero
	movsd	%xmm0, -24(%rbp)
	xorps	%xmm0, %xmm0
	movsd	%xmm0, -32(%rbp)
	xorps	%xmm0, %xmm0
	movsd	%xmm0, -40(%rbp)
	movq	$0, -48(%rbp)
LBB6_1:                                 ## =>This Inner Loop Header: Depth=1
	movq	-48(%rbp), %rax
	cmpq	-8(%rbp), %rax
	jae	LBB6_4
## %bb.2:                               ##   in Loop: Header=BB6_1 Depth=1
	movsd	-24(%rbp), %xmm0                ## xmm0 = mem[0],zero
	movsd	%xmm0, -88(%rbp)                ## 8-byte Spill
	callq	_libmin_rand
	movsd	-88(%rbp), %xmm0                ## 8-byte Reload
                                        ## xmm0 = mem[0],zero
	movl	%eax, %eax
                                        ## kill: def $rax killed $eax
	cvtsi2sd	%rax, %xmm1
	movsd	LCPI6_2(%rip), %xmm2            ## xmm2 = mem[0],zero
	divsd	%xmm2, %xmm1
	mulsd	%xmm1, %xmm0
	movsd	%xmm0, -32(%rbp)
	callq	_libmin_rand
	movl	%eax, %eax
                                        ## kill: def $rax killed $eax
	cvtsi2sd	%rax, %xmm1
	movsd	LCPI6_2(%rip), %xmm0            ## xmm0 = mem[0],zero
	divsd	%xmm0, %xmm1
	movsd	LCPI6_1(%rip), %xmm0            ## xmm0 = mem[0],zero
	mulsd	%xmm1, %xmm0
	movsd	%xmm0, -40(%rbp)
	movsd	-32(%rbp), %xmm0                ## xmm0 = mem[0],zero
	movsd	%xmm0, -80(%rbp)                ## 8-byte Spill
	movsd	-40(%rbp), %xmm0                ## xmm0 = mem[0],zero
	callq	_libmin_cos
	movaps	%xmm0, %xmm1
	movsd	-80(%rbp), %xmm0                ## 8-byte Reload
                                        ## xmm0 = mem[0],zero
	mulsd	%xmm1, %xmm0
	movq	-16(%rbp), %rax
	imulq	$24, -48(%rbp), %rcx
	addq	%rcx, %rax
	movsd	%xmm0, (%rax)
	movsd	-32(%rbp), %xmm0                ## xmm0 = mem[0],zero
	movsd	%xmm0, -72(%rbp)                ## 8-byte Spill
	movsd	-40(%rbp), %xmm0                ## xmm0 = mem[0],zero
	callq	_libmin_sin
	movaps	%xmm0, %xmm1
	movsd	-72(%rbp), %xmm0                ## 8-byte Reload
                                        ## xmm0 = mem[0],zero
	mulsd	%xmm1, %xmm0
	movq	-16(%rbp), %rax
	imulq	$24, -48(%rbp), %rcx
	addq	%rcx, %rax
	movsd	%xmm0, 8(%rax)
## %bb.3:                               ##   in Loop: Header=BB6_1 Depth=1
	movq	-48(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -48(%rbp)
	jmp	LBB6_1
LBB6_4:
	movl	$5, -52(%rbp)
	movq	-16(%rbp), %rdi
	movq	-8(%rbp), %rsi
	movl	-52(%rbp), %edx
	callq	_kMeans
	movq	%rax, -64(%rbp)
	movq	-16(%rbp), %rdi
	movq	-8(%rbp), %rsi
	movq	-64(%rbp), %rdx
	movl	-52(%rbp), %ecx
	callq	_printEPS
	movq	-16(%rbp), %rdi
	callq	_libmin_free
	movq	-64(%rbp), %rdi
	callq	_libmin_free
	addq	$96, %rsp
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%%!PS-Adobe-3.0 EPSF-3.0\n%%%%BoundingBox: -5 -5 %d %d\n"

L_.str.1:                               ## @.str.1
	.asciz	"/l {rlineto} def /m {rmoveto} def\n/c { .25 sub exch .25 sub exch .5 0 360 arc fill } def\n/s { moveto -2 0 m 2 2 l 2 -2 l -2 -2 l closepath \tgsave 1 setgray fill grestore gsave 3 setlinewidth 1 setgray stroke grestore 0 setgray stroke }def\n"

L_.str.2:                               ## @.str.2
	.asciz	"%g %g %g setrgbcolor\n"

L_.str.3:                               ## @.str.3
	.asciz	"%.3f %.3f c\n"

L_.str.4:                               ## @.str.4
	.asciz	"\n0 setgray %g %g s\n"

L_.str.5:                               ## @.str.5
	.asciz	"\n%%%%EOF\n"

.subsections_via_symbols


ARM64 assembly:
	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function calculateNearst
lCPI0_0:
	.quad	0x7fefffffffffffff              ; double 1.7976931348623157E+308
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_calculateNearst
	.p2align	2
_calculateNearst:                       ; @calculateNearst
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	str	x0, [sp, #40]
	str	x1, [sp, #32]
	str	w2, [sp, #28]
	adrp	x8, lCPI0_0@PAGE
	ldr	d0, [x8, lCPI0_0@PAGEOFF]
	str	d0, [sp, #16]
	movi	d0, #0000000000000000
	str	d0, [sp, #8]
	mov	w8, #-1
	str	w8, [sp, #4]
	str	wzr, [sp]
	b	LBB0_1
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [sp]
	ldr	w9, [sp, #28]
	subs	w8, w8, w9
	cset	w8, ge
	tbnz	w8, #0, LBB0_6
	b	LBB0_2
LBB0_2:                                 ;   in Loop: Header=BB0_1 Depth=1
	ldr	x8, [sp, #32]
	ldrsw	x9, [sp]
	mov	x10, #24
	mul	x9, x9, x10
	ldr	d0, [x8, x9]
	ldr	x8, [sp, #40]
	ldr	d1, [x8]
	fsub	d0, d0, d1
	ldr	x8, [sp, #32]
	ldrsw	x9, [sp]
	mul	x9, x9, x10
	ldr	d1, [x8, x9]
	ldr	x8, [sp, #40]
	ldr	d2, [x8]
	fsub	d1, d1, d2
	ldr	x8, [sp, #32]
	ldrsw	x9, [sp]
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d2, [x8, #8]
	ldr	x8, [sp, #40]
	ldr	d3, [x8, #8]
	fsub	d2, d2, d3
	ldr	x8, [sp, #32]
	ldrsw	x9, [sp]
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d3, [x8, #8]
	ldr	x8, [sp, #40]
	ldr	d4, [x8, #8]
	fsub	d3, d3, d4
	fmul	d2, d2, d3
	fmadd	d0, d0, d1, d2
	str	d0, [sp, #8]
	ldr	d0, [sp, #8]
	ldr	d1, [sp, #16]
	fcmp	d0, d1
	cset	w8, pl
	tbnz	w8, #0, LBB0_4
	b	LBB0_3
LBB0_3:                                 ;   in Loop: Header=BB0_1 Depth=1
	ldr	d0, [sp, #8]
	str	d0, [sp, #16]
	ldr	w8, [sp]
	str	w8, [sp, #4]
	b	LBB0_4
LBB0_4:                                 ;   in Loop: Header=BB0_1 Depth=1
	b	LBB0_5
LBB0_5:                                 ;   in Loop: Header=BB0_1 Depth=1
	ldr	w8, [sp]
	add	w8, w8, #1
	str	w8, [sp]
	b	LBB0_1
LBB0_6:
	ldr	w0, [sp, #4]
	add	sp, sp, #48
	ret
	.cfi_endproc
                                        ; -- End function
	.globl	_calculateCentroid              ; -- Begin function calculateCentroid
	.p2align	2
_calculateCentroid:                     ; @calculateCentroid
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #32
	.cfi_def_cfa_offset 32
	str	x0, [sp, #24]
	str	x1, [sp, #16]
	str	x2, [sp, #8]
	str	xzr, [sp]
	ldr	x8, [sp, #8]
	movi	d0, #0000000000000000
	str	d0, [x8]
	ldr	x8, [sp, #8]
	str	d0, [x8, #8]
	ldr	x8, [sp, #16]
	ldr	x9, [sp, #8]
	str	x8, [x9, #16]
	b	LBB1_1
LBB1_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [sp]
	ldr	x9, [sp, #16]
	subs	x8, x8, x9
	cset	w8, hs
	tbnz	w8, #0, LBB1_4
	b	LBB1_2
LBB1_2:                                 ;   in Loop: Header=BB1_1 Depth=1
	ldr	x8, [sp, #24]
	ldr	x9, [sp]
	mov	x10, #24
	mul	x9, x9, x10
	ldr	d1, [x8, x9]
	ldr	x8, [sp, #8]
	ldr	d0, [x8]
	fadd	d0, d0, d1
	str	d0, [x8]
	ldr	x8, [sp, #24]
	ldr	x9, [sp]
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d1, [x8, #8]
	ldr	x8, [sp, #8]
	ldr	d0, [x8, #8]
	fadd	d0, d0, d1
	str	d0, [x8, #8]
	ldr	x8, [sp, #24]
	ldr	x9, [sp]
	mul	x9, x9, x10
	add	x8, x8, x9
	str	wzr, [x8, #16]
	b	LBB1_3
LBB1_3:                                 ;   in Loop: Header=BB1_1 Depth=1
	ldr	x8, [sp]
	add	x8, x8, #1
	str	x8, [sp]
	b	LBB1_1
LBB1_4:
	ldr	x8, [sp, #8]
	ldr	d0, [x8, #16]
	ucvtf	d1, d0
	ldr	x8, [sp, #8]
	ldr	d0, [x8]
	fdiv	d0, d0, d1
	str	d0, [x8]
	ldr	x8, [sp, #8]
	ldr	d0, [x8, #16]
	ucvtf	d1, d0
	ldr	x8, [sp, #8]
	ldr	d0, [x8, #8]
	fdiv	d0, d0, d1
	str	d0, [x8, #8]
	add	sp, sp, #32
	ret
	.cfi_endproc
                                        ; -- End function
	.globl	_kMeans                         ; -- Begin function kMeans
	.p2align	2
_kMeans:                                ; @kMeans
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	stur	x0, [x29, #-8]
	stur	x1, [x29, #-16]
	stur	w2, [x29, #-20]
                                        ; kill: def $x8 killed $xzr
	stur	xzr, [x29, #-32]
	ldur	w8, [x29, #-20]
	subs	w8, w8, #1
	cset	w8, gt
	tbnz	w8, #0, LBB2_2
	b	LBB2_1
LBB2_1:
	mov	x0, #24
	str	x0, [sp, #24]                   ; 8-byte Folded Spill
	bl	_libmin_malloc
	ldr	x2, [sp, #24]                   ; 8-byte Folded Reload
	stur	x0, [x29, #-32]
	ldur	x0, [x29, #-32]
	mov	w1, #0
	bl	_libmin_memset
	ldur	x0, [x29, #-8]
	ldur	x1, [x29, #-16]
	ldur	x2, [x29, #-32]
	bl	_calculateCentroid
	b	LBB2_35
LBB2_2:
	ldursw	x8, [x29, #-20]
	ldur	x9, [x29, #-16]
	subs	x8, x8, x9
	cset	w8, hs
	tbnz	w8, #0, LBB2_29
	b	LBB2_3
LBB2_3:
	ldursw	x9, [x29, #-20]
	mov	x8, #24
	str	x8, [sp, #16]                   ; 8-byte Folded Spill
	mul	x0, x8, x9
	bl	_libmin_malloc
	ldr	x9, [sp, #16]                   ; 8-byte Folded Reload
	stur	x0, [x29, #-32]
	ldur	x0, [x29, #-32]
	ldursw	x8, [x29, #-20]
	mul	x2, x8, x9
	mov	w1, #0
	bl	_libmin_memset
	stur	xzr, [x29, #-40]
	b	LBB2_4
LBB2_4:                                 ; =>This Inner Loop Header: Depth=1
	ldur	x8, [x29, #-40]
	ldur	x9, [x29, #-16]
	subs	x8, x8, x9
	cset	w8, hs
	tbnz	w8, #0, LBB2_7
	b	LBB2_5
LBB2_5:                                 ;   in Loop: Header=BB2_4 Depth=1
	bl	_libmin_rand
	ldur	w9, [x29, #-20]
	udiv	w8, w0, w9
	mul	w8, w8, w9
	subs	w8, w0, w8
	ldur	x9, [x29, #-8]
	ldur	x10, [x29, #-40]
	mov	x11, #24
	mul	x10, x10, x11
	add	x9, x9, x10
	str	w8, [x9, #16]
	b	LBB2_6
LBB2_6:                                 ;   in Loop: Header=BB2_4 Depth=1
	ldur	x8, [x29, #-40]
	add	x8, x8, #1
	stur	x8, [x29, #-40]
	b	LBB2_4
LBB2_7:
	stur	xzr, [x29, #-48]
	ldur	x8, [x29, #-16]
	mov	x9, #10000
	udiv	x8, x8, x9
	stur	x8, [x29, #-56]
	stur	wzr, [x29, #-60]
	b	LBB2_8
LBB2_8:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB2_9 Depth 2
                                        ;     Child Loop BB2_13 Depth 2
                                        ;     Child Loop BB2_17 Depth 2
                                        ;     Child Loop BB2_21 Depth 2
	str	wzr, [sp, #64]
	b	LBB2_9
LBB2_9:                                 ;   Parent Loop BB2_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w8, [sp, #64]
	ldur	w9, [x29, #-20]
	subs	w8, w8, w9
	cset	w8, ge
	tbnz	w8, #0, LBB2_12
	b	LBB2_10
LBB2_10:                                ;   in Loop: Header=BB2_9 Depth=2
	ldur	x8, [x29, #-32]
	ldrsw	x9, [sp, #64]
	mov	x10, #24
	mul	x9, x9, x10
	movi	d0, #0000000000000000
	str	d0, [x8, x9]
	ldur	x8, [x29, #-32]
	ldrsw	x9, [sp, #64]
	mul	x9, x9, x10
	add	x8, x8, x9
	str	d0, [x8, #8]
	ldur	x8, [x29, #-32]
	ldrsw	x9, [sp, #64]
	mul	x9, x9, x10
	add	x8, x8, x9
	str	xzr, [x8, #16]
	b	LBB2_11
LBB2_11:                                ;   in Loop: Header=BB2_9 Depth=2
	ldr	w8, [sp, #64]
	add	w8, w8, #1
	str	w8, [sp, #64]
	b	LBB2_9
LBB2_12:                                ;   in Loop: Header=BB2_8 Depth=1
	str	xzr, [sp, #56]
	b	LBB2_13
LBB2_13:                                ;   Parent Loop BB2_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [sp, #56]
	ldur	x9, [x29, #-16]
	subs	x8, x8, x9
	cset	w8, hs
	tbnz	w8, #0, LBB2_16
	b	LBB2_14
LBB2_14:                                ;   in Loop: Header=BB2_13 Depth=2
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #56]
	mov	x10, #24
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	w8, [x8, #16]
	stur	w8, [x29, #-60]
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #56]
	mul	x9, x9, x10
	ldr	d1, [x8, x9]
	ldur	x8, [x29, #-32]
	ldursw	x9, [x29, #-60]
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d0, [x8]
	fadd	d0, d0, d1
	str	d0, [x8]
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #56]
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d1, [x8, #8]
	ldur	x8, [x29, #-32]
	ldursw	x9, [x29, #-60]
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d0, [x8, #8]
	fadd	d0, d0, d1
	str	d0, [x8, #8]
	ldur	x8, [x29, #-32]
	ldursw	x9, [x29, #-60]
	mul	x9, x9, x10
	add	x9, x8, x9
	ldr	x8, [x9, #16]
	add	x8, x8, #1
	str	x8, [x9, #16]
	b	LBB2_15
LBB2_15:                                ;   in Loop: Header=BB2_13 Depth=2
	ldr	x8, [sp, #56]
	add	x8, x8, #1
	str	x8, [sp, #56]
	b	LBB2_13
LBB2_16:                                ;   in Loop: Header=BB2_8 Depth=1
	str	wzr, [sp, #52]
	b	LBB2_17
LBB2_17:                                ;   Parent Loop BB2_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w8, [sp, #52]
	ldur	w9, [x29, #-20]
	subs	w8, w8, w9
	cset	w8, ge
	tbnz	w8, #0, LBB2_20
	b	LBB2_18
LBB2_18:                                ;   in Loop: Header=BB2_17 Depth=2
	ldur	x8, [x29, #-32]
	ldrsw	x9, [sp, #52]
	mov	x10, #24
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d0, [x8, #16]
	ucvtf	d1, d0
	ldur	x8, [x29, #-32]
	ldrsw	x9, [sp, #52]
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d0, [x8]
	fdiv	d0, d0, d1
	str	d0, [x8]
	ldur	x8, [x29, #-32]
	ldrsw	x9, [sp, #52]
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d0, [x8, #16]
	ucvtf	d1, d0
	ldur	x8, [x29, #-32]
	ldrsw	x9, [sp, #52]
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d0, [x8, #8]
	fdiv	d0, d0, d1
	str	d0, [x8, #8]
	b	LBB2_19
LBB2_19:                                ;   in Loop: Header=BB2_17 Depth=2
	ldr	w8, [sp, #52]
	add	w8, w8, #1
	str	w8, [sp, #52]
	b	LBB2_17
LBB2_20:                                ;   in Loop: Header=BB2_8 Depth=1
	stur	xzr, [x29, #-48]
	str	xzr, [sp, #40]
	b	LBB2_21
LBB2_21:                                ;   Parent Loop BB2_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [sp, #40]
	ldur	x9, [x29, #-16]
	subs	x8, x8, x9
	cset	w8, hs
	tbnz	w8, #0, LBB2_26
	b	LBB2_22
LBB2_22:                                ;   in Loop: Header=BB2_21 Depth=2
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x10, #24
	str	x10, [sp, #8]                   ; 8-byte Folded Spill
	mul	x9, x9, x10
	add	x0, x8, x9
	ldur	x1, [x29, #-32]
	ldur	w2, [x29, #-20]
	bl	_calculateNearst
	ldr	x11, [sp, #8]                   ; 8-byte Folded Reload
	stur	w0, [x29, #-60]
	ldur	w8, [x29, #-60]
	ldur	x9, [x29, #-8]
	ldr	x10, [sp, #40]
	mul	x10, x10, x11
	add	x9, x9, x10
	ldr	w9, [x9, #16]
	subs	w8, w8, w9
	cset	w8, eq
	tbnz	w8, #0, LBB2_24
	b	LBB2_23
LBB2_23:                                ;   in Loop: Header=BB2_21 Depth=2
	ldur	x8, [x29, #-48]
	add	x8, x8, #1
	stur	x8, [x29, #-48]
	ldur	w8, [x29, #-60]
	ldur	x9, [x29, #-8]
	ldr	x10, [sp, #40]
	mov	x11, #24
	mul	x10, x10, x11
	add	x9, x9, x10
	str	w8, [x9, #16]
	b	LBB2_24
LBB2_24:                                ;   in Loop: Header=BB2_21 Depth=2
	b	LBB2_25
LBB2_25:                                ;   in Loop: Header=BB2_21 Depth=2
	ldr	x8, [sp, #40]
	add	x8, x8, #1
	str	x8, [sp, #40]
	b	LBB2_21
LBB2_26:                                ;   in Loop: Header=BB2_8 Depth=1
	b	LBB2_27
LBB2_27:                                ;   in Loop: Header=BB2_8 Depth=1
	ldur	x8, [x29, #-48]
	ldur	x9, [x29, #-56]
	subs	x8, x8, x9
	cset	w8, hi
	tbnz	w8, #0, LBB2_8
	b	LBB2_28
LBB2_28:
	b	LBB2_34
LBB2_29:
	ldursw	x9, [x29, #-20]
	mov	x8, #24
	str	x8, [sp]                        ; 8-byte Folded Spill
	mul	x0, x8, x9
	bl	_libmin_malloc
	ldr	x9, [sp]                        ; 8-byte Folded Reload
	stur	x0, [x29, #-32]
	ldur	x0, [x29, #-32]
	ldursw	x8, [x29, #-20]
	mul	x2, x8, x9
	mov	w1, #0
	bl	_libmin_memset
	str	wzr, [sp, #36]
	b	LBB2_30
LBB2_30:                                ; =>This Inner Loop Header: Depth=1
	ldrsw	x8, [sp, #36]
	ldur	x9, [x29, #-16]
	subs	x8, x8, x9
	cset	w8, hs
	tbnz	w8, #0, LBB2_33
	b	LBB2_31
LBB2_31:                                ;   in Loop: Header=BB2_30 Depth=1
	ldur	x8, [x29, #-8]
	ldrsw	x9, [sp, #36]
	mov	x11, #24
	mul	x9, x9, x11
	ldr	d0, [x8, x9]
	ldur	x8, [x29, #-32]
	ldrsw	x9, [sp, #36]
	mul	x9, x9, x11
	str	d0, [x8, x9]
	ldur	x8, [x29, #-8]
	ldrsw	x9, [sp, #36]
	mul	x9, x9, x11
	add	x8, x8, x9
	ldr	d0, [x8, #8]
	ldur	x8, [x29, #-32]
	ldrsw	x9, [sp, #36]
	mul	x9, x9, x11
	add	x8, x8, x9
	str	d0, [x8, #8]
	ldur	x8, [x29, #-32]
	ldrsw	x9, [sp, #36]
	mul	x9, x9, x11
	add	x9, x8, x9
	mov	x8, #1
	str	x8, [x9, #16]
	ldr	w8, [sp, #36]
	ldur	x9, [x29, #-8]
	ldrsw	x10, [sp, #36]
	mul	x10, x10, x11
	add	x9, x9, x10
	str	w8, [x9, #16]
	b	LBB2_32
LBB2_32:                                ;   in Loop: Header=BB2_30 Depth=1
	ldr	w8, [sp, #36]
	add	w8, w8, #1
	str	w8, [sp, #36]
	b	LBB2_30
LBB2_33:
	b	LBB2_34
LBB2_34:
	b	LBB2_35
LBB2_35:
	ldur	x0, [x29, #-32]
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function printEPS
lCPI3_0:
	.quad	0x0010000000000000              ; double 2.2250738585072014E-308
lCPI3_1:
	.quad	0x7fefffffffffffff              ; double 1.7976931348623157E+308
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_printEPS
	.p2align	2
_printEPS:                              ; @printEPS
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #176
	.cfi_def_cfa_offset 176
	stp	x29, x30, [sp, #160]            ; 16-byte Folded Spill
	add	x29, sp, #160
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	stur	x0, [x29, #-8]
	stur	x1, [x29, #-16]
	stur	x2, [x29, #-24]
	stur	w3, [x29, #-28]
	mov	w8, #400
	stur	w8, [x29, #-32]
	stur	w8, [x29, #-36]
	adrp	x8, lCPI3_1@PAGE
	ldr	d1, [x8, lCPI3_1@PAGEOFF]
	stur	d1, [x29, #-48]
	adrp	x8, lCPI3_0@PAGE
	ldr	d0, [x8, lCPI3_0@PAGEOFF]
	stur	d0, [x29, #-56]
	stur	d1, [x29, #-64]
	stur	d0, [x29, #-72]
	movi	d0, #0000000000000000
	str	d0, [sp, #80]
	str	d0, [sp, #72]
	str	d0, [sp, #64]
	ldur	w8, [x29, #-28]
	mov	w9, #3
	mul	w9, w8, w9
                                        ; implicit-def: $x8
	mov	x8, x9
	sxtw	x9, w8
	mov	x8, #8
	mul	x0, x8, x9
	bl	_libmin_malloc
	str	x0, [sp, #56]
	ldur	s1, [x29, #-28]
                                        ; implicit-def: $d0
	fmov	s0, s1
	sshll.2d	v0, v0, #0
                                        ; kill: def $d0 killed $d0 killed $q0
	scvtf	d0, d0
	fmov	d1, #1.00000000
	fmul	d0, d0, d1
	str	d0, [sp, #32]
	str	wzr, [sp, #52]
	b	LBB3_1
LBB3_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [sp, #52]
	ldur	w9, [x29, #-28]
	subs	w8, w8, w9
	cset	w8, ge
	tbnz	w8, #0, LBB3_4
	b	LBB3_2
LBB3_2:                                 ;   in Loop: Header=BB3_1 Depth=1
	ldr	w8, [sp, #52]
	add	w8, w8, #1
	mov	w9, #3
	mul	w8, w9, w8
	ldur	w11, [x29, #-28]
	sdiv	w10, w8, w11
	mul	w10, w10, w11
	subs	w8, w8, w10
	scvtf	d0, w8
	ldr	d1, [sp, #32]
	fdiv	d0, d0, d1
	ldr	x8, [sp, #56]
	ldr	w10, [sp, #52]
	mul	w10, w9, w10
	str	d0, [x8, w10, sxtw #3]
	ldr	w10, [sp, #52]
	mov	w8, #7
	mul	w8, w8, w10
	ldur	w11, [x29, #-28]
	sdiv	w10, w8, w11
	mul	w10, w10, w11
	subs	w8, w8, w10
	scvtf	d0, w8
	ldr	d1, [sp, #32]
	fdiv	d0, d0, d1
	ldr	x8, [sp, #56]
	ldr	w10, [sp, #52]
	mul	w10, w9, w10
	add	x8, x8, w10, sxtw #3
	str	d0, [x8, #8]
	ldr	w10, [sp, #52]
	mov	w8, #9
	mul	w8, w8, w10
	ldur	w11, [x29, #-28]
	sdiv	w10, w8, w11
	mul	w10, w10, w11
	subs	w8, w8, w10
	scvtf	d0, w8
	ldr	d1, [sp, #32]
	fdiv	d0, d0, d1
	ldr	x8, [sp, #56]
	ldr	w10, [sp, #52]
	mul	w9, w9, w10
	add	x8, x8, w9, sxtw #3
	str	d0, [x8, #16]
	b	LBB3_3
LBB3_3:                                 ;   in Loop: Header=BB3_1 Depth=1
	ldr	w8, [sp, #52]
	add	w8, w8, #1
	str	w8, [sp, #52]
	b	LBB3_1
LBB3_4:
	str	xzr, [sp, #40]
	b	LBB3_5
LBB3_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [sp, #40]
	ldur	x9, [x29, #-16]
	subs	x8, x8, x9
	cset	w8, hs
	tbnz	w8, #0, LBB3_16
	b	LBB3_6
LBB3_6:                                 ;   in Loop: Header=BB3_5 Depth=1
	ldur	d0, [x29, #-56]
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x10, #24
	mul	x9, x9, x10
	ldr	d1, [x8, x9]
	fcmp	d0, d1
	cset	w8, pl
	tbnz	w8, #0, LBB3_8
	b	LBB3_7
LBB3_7:                                 ;   in Loop: Header=BB3_5 Depth=1
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x10, #24
	mul	x9, x9, x10
	ldr	d0, [x8, x9]
	stur	d0, [x29, #-56]
	b	LBB3_8
LBB3_8:                                 ;   in Loop: Header=BB3_5 Depth=1
	ldur	d0, [x29, #-48]
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x10, #24
	mul	x9, x9, x10
	ldr	d1, [x8, x9]
	fcmp	d0, d1
	cset	w8, le
	tbnz	w8, #0, LBB3_10
	b	LBB3_9
LBB3_9:                                 ;   in Loop: Header=BB3_5 Depth=1
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x10, #24
	mul	x9, x9, x10
	ldr	d0, [x8, x9]
	stur	d0, [x29, #-48]
	b	LBB3_10
LBB3_10:                                ;   in Loop: Header=BB3_5 Depth=1
	ldur	d0, [x29, #-72]
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x10, #24
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d1, [x8, #8]
	fcmp	d0, d1
	cset	w8, pl
	tbnz	w8, #0, LBB3_12
	b	LBB3_11
LBB3_11:                                ;   in Loop: Header=BB3_5 Depth=1
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x10, #24
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d0, [x8, #8]
	stur	d0, [x29, #-72]
	b	LBB3_12
LBB3_12:                                ;   in Loop: Header=BB3_5 Depth=1
	ldur	d0, [x29, #-64]
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x10, #24
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d1, [x8, #8]
	fcmp	d0, d1
	cset	w8, le
	tbnz	w8, #0, LBB3_14
	b	LBB3_13
LBB3_13:                                ;   in Loop: Header=BB3_5 Depth=1
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x10, #24
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	d0, [x8, #8]
	stur	d0, [x29, #-64]
	b	LBB3_14
LBB3_14:                                ;   in Loop: Header=BB3_5 Depth=1
	b	LBB3_15
LBB3_15:                                ;   in Loop: Header=BB3_5 Depth=1
	ldr	x8, [sp, #40]
	add	x8, x8, #1
	str	x8, [sp, #40]
	b	LBB3_5
LBB3_16:
	ldur	s1, [x29, #-32]
                                        ; implicit-def: $d0
	fmov	s0, s1
	sshll.2d	v0, v0, #0
                                        ; kill: def $d0 killed $d0 killed $q0
	scvtf	d0, d0
	ldur	d1, [x29, #-56]
	ldur	d2, [x29, #-48]
	fsub	d1, d1, d2
	fdiv	d0, d0, d1
	str	d0, [sp, #80]
	ldr	d0, [sp, #80]
	ldur	s2, [x29, #-36]
                                        ; implicit-def: $d1
	fmov	s1, s2
	sshll.2d	v1, v1, #0
                                        ; kill: def $d1 killed $d1 killed $q1
	scvtf	d1, d1
	ldur	d2, [x29, #-72]
	ldur	d3, [x29, #-64]
	fsub	d2, d2, d3
	fdiv	d1, d1, d2
	fcmp	d0, d1
	cset	w8, le
	tbnz	w8, #0, LBB3_18
	b	LBB3_17
LBB3_17:
	ldur	s1, [x29, #-36]
                                        ; implicit-def: $d0
	fmov	s0, s1
	sshll.2d	v0, v0, #0
                                        ; kill: def $d0 killed $d0 killed $q0
	scvtf	d0, d0
	ldur	d1, [x29, #-72]
	ldur	d2, [x29, #-64]
	fsub	d1, d1, d2
	fdiv	d0, d0, d1
	str	d0, [sp, #80]
	b	LBB3_18
LBB3_18:
	ldur	d0, [x29, #-56]
	ldur	d1, [x29, #-48]
	fadd	d0, d0, d1
	fmov	d1, #2.00000000
	fdiv	d0, d0, d1
	str	d0, [sp, #72]
	ldur	d0, [x29, #-72]
	ldur	d2, [x29, #-64]
	fadd	d0, d0, d2
	fdiv	d0, d0, d1
	str	d0, [sp, #64]
	ldur	w8, [x29, #-32]
	add	w11, w8, #10
	ldur	w8, [x29, #-36]
	add	w10, w8, #10
	mov	x9, sp
                                        ; implicit-def: $x8
	mov	x8, x11
	str	x8, [x9]
                                        ; implicit-def: $x8
	mov	x8, x10
	str	x8, [x9, #8]
	adrp	x0, l_.str@PAGE
	add	x0, x0, l_.str@PAGEOFF
	bl	_libmin_printf
	adrp	x0, l_.str.1@PAGE
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_libmin_printf
	str	wzr, [sp, #28]
	b	LBB3_19
LBB3_19:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB3_21 Depth 2
	ldr	w8, [sp, #28]
	ldur	w9, [x29, #-28]
	subs	w8, w8, w9
	cset	w8, ge
	tbnz	w8, #0, LBB3_28
	b	LBB3_20
LBB3_20:                                ;   in Loop: Header=BB3_19 Depth=1
	ldr	x8, [sp, #56]
	ldr	w10, [sp, #28]
	mov	w9, #3
	mul	w10, w9, w10
	ldr	d2, [x8, w10, sxtw #3]
	ldr	x8, [sp, #56]
	ldr	w10, [sp, #28]
	mul	w10, w9, w10
	add	x8, x8, w10, sxtw #3
	ldr	d1, [x8, #8]
	ldr	x8, [sp, #56]
	ldr	w10, [sp, #28]
	mul	w9, w9, w10
	add	x8, x8, w9, sxtw #3
	ldr	d0, [x8, #16]
	mov	x8, sp
	str	d2, [x8]
	str	d1, [x8, #8]
	str	d0, [x8, #16]
	adrp	x0, l_.str.2@PAGE
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_libmin_printf
	str	xzr, [sp, #40]
	b	LBB3_21
LBB3_21:                                ;   Parent Loop BB3_19 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [sp, #40]
	ldur	x9, [x29, #-16]
	subs	x8, x8, x9
	cset	w8, hs
	tbnz	w8, #0, LBB3_26
	b	LBB3_22
LBB3_22:                                ;   in Loop: Header=BB3_21 Depth=2
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x10, #24
	mul	x9, x9, x10
	add	x8, x8, x9
	ldr	w8, [x8, #16]
	ldr	w9, [sp, #28]
	subs	w8, w8, w9
	cset	w8, eq
	tbnz	w8, #0, LBB3_24
	b	LBB3_23
LBB3_23:                                ;   in Loop: Header=BB3_21 Depth=2
	b	LBB3_25
LBB3_24:                                ;   in Loop: Header=BB3_21 Depth=2
	ldur	x8, [x29, #-8]
	ldr	x9, [sp, #40]
	mov	x11, #24
	mul	x9, x9, x11
	ldr	d0, [x8, x9]
	ldr	d1, [sp, #72]
	fsub	d0, d0, d1
	ldr	d1, [sp, #80]
	ldur	w8, [x29, #-32]
	mov	w9, #2
	sdiv	w8, w8, w9
	scvtf	d2, w8
	fmadd	d1, d0, d1, d2
	ldur	x8, [x29, #-8]
	ldr	x10, [sp, #40]
	mul	x10, x10, x11
	add	x8, x8, x10
	ldr	d0, [x8, #8]
	ldr	d2, [sp, #64]
	fsub	d0, d0, d2
	ldr	d2, [sp, #80]
	ldur	w8, [x29, #-36]
	sdiv	w8, w8, w9
	scvtf	d3, w8
	fmadd	d0, d0, d2, d3
	mov	x8, sp
	str	d1, [x8]
	str	d0, [x8, #8]
	adrp	x0, l_.str.3@PAGE
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_libmin_printf
	b	LBB3_25
LBB3_25:                                ;   in Loop: Header=BB3_21 Depth=2
	ldr	x8, [sp, #40]
	add	x8, x8, #1
	str	x8, [sp, #40]
	b	LBB3_21
LBB3_26:                                ;   in Loop: Header=BB3_19 Depth=1
	ldur	x8, [x29, #-24]
	ldrsw	x9, [sp, #28]
	mov	x11, #24
	mul	x9, x9, x11
	ldr	d0, [x8, x9]
	ldr	d1, [sp, #72]
	fsub	d0, d0, d1
	ldr	d1, [sp, #80]
	ldur	w8, [x29, #-32]
	mov	w9, #2
	sdiv	w8, w8, w9
	scvtf	d2, w8
	fmadd	d1, d0, d1, d2
	ldur	x8, [x29, #-24]
	ldrsw	x10, [sp, #28]
	mul	x10, x10, x11
	add	x8, x8, x10
	ldr	d0, [x8, #8]
	ldr	d2, [sp, #64]
	fsub	d0, d0, d2
	ldr	d2, [sp, #80]
	ldur	w8, [x29, #-36]
	sdiv	w8, w8, w9
	scvtf	d3, w8
	fmadd	d0, d0, d2, d3
	mov	x8, sp
	str	d1, [x8]
	str	d0, [x8, #8]
	adrp	x0, l_.str.4@PAGE
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_libmin_printf
	b	LBB3_27
LBB3_27:                                ;   in Loop: Header=BB3_19 Depth=1
	ldr	w8, [sp, #28]
	add	w8, w8, #1
	str	w8, [sp, #28]
	b	LBB3_19
LBB3_28:
	adrp	x0, l_.str.5@PAGE
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_libmin_printf
	ldr	x0, [sp, #56]
	bl	_libmin_free
	ldp	x29, x30, [sp, #160]            ; 16-byte Folded Reload
	add	sp, sp, #176
	ret
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function test2
lCPI4_0:
	.quad	0x401921fb54442d18              ; double 6.2831853071795862
lCPI4_1:
	.quad	0x41dfffffffc00000              ; double 2147483647
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_test2
	.p2align	2
_test2:                                 ; @test2
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	mov	x8, #16960
	movk	x8, #15, lsl #16
	stur	x8, [x29, #-8]
	ldur	x9, [x29, #-8]
	mov	x8, #24
	mul	x0, x8, x9
	bl	_libmin_malloc
	stur	x0, [x29, #-16]
	fmov	d0, #20.00000000
	stur	d0, [x29, #-24]
	movi	d0, #0000000000000000
	stur	d0, [x29, #-32]
	stur	d0, [x29, #-40]
	stur	xzr, [x29, #-48]
	b	LBB4_1
LBB4_1:                                 ; =>This Inner Loop Header: Depth=1
	ldur	x8, [x29, #-48]
	ldur	x9, [x29, #-8]
	subs	x8, x8, x9
	cset	w8, hs
	tbnz	w8, #0, LBB4_4
	b	LBB4_2
LBB4_2:                                 ;   in Loop: Header=BB4_1 Depth=1
	ldur	d0, [x29, #-24]
	str	d0, [sp, #8]                    ; 8-byte Folded Spill
	bl	_libmin_rand
	ldr	d0, [sp, #8]                    ; 8-byte Folded Reload
	ucvtf	d1, w0
	adrp	x8, lCPI4_1@PAGE
	ldr	d2, [x8, lCPI4_1@PAGEOFF]
	str	d2, [sp, #16]                   ; 8-byte Folded Spill
	fdiv	d1, d1, d2
	fmul	d0, d0, d1
	stur	d0, [x29, #-32]
	bl	_libmin_rand
	ldr	d1, [sp, #16]                   ; 8-byte Folded Reload
	ucvtf	d0, w0
	fdiv	d1, d0, d1
	adrp	x8, lCPI4_0@PAGE
	ldr	d0, [x8, lCPI4_0@PAGEOFF]
	fmul	d0, d0, d1
	stur	d0, [x29, #-40]
	ldur	d0, [x29, #-32]
	str	d0, [sp, #24]                   ; 8-byte Folded Spill
	ldur	d0, [x29, #-40]
	bl	_libmin_cos
	fmov	d1, d0
	ldr	d0, [sp, #24]                   ; 8-byte Folded Reload
	fmul	d0, d0, d1
	ldur	x8, [x29, #-16]
	ldur	x9, [x29, #-48]
	mov	x10, #24
	str	x10, [sp, #32]                  ; 8-byte Folded Spill
	mul	x9, x9, x10
	str	d0, [x8, x9]
	ldur	d0, [x29, #-32]
	str	d0, [sp, #40]                   ; 8-byte Folded Spill
	ldur	d0, [x29, #-40]
	bl	_libmin_sin
	ldr	x10, [sp, #32]                  ; 8-byte Folded Reload
	fmov	d1, d0
	ldr	d0, [sp, #40]                   ; 8-byte Folded Reload
	fmul	d0, d0, d1
	ldur	x8, [x29, #-16]
	ldur	x9, [x29, #-48]
	mul	x9, x9, x10
	add	x8, x8, x9
	str	d0, [x8, #8]
	b	LBB4_3
LBB4_3:                                 ;   in Loop: Header=BB4_1 Depth=1
	ldur	x8, [x29, #-48]
	add	x8, x8, #1
	stur	x8, [x29, #-48]
	b	LBB4_1
LBB4_4:
	mov	w8, #11
	stur	w8, [x29, #-52]
	ldur	x0, [x29, #-16]
	ldur	x1, [x29, #-8]
	ldur	w2, [x29, #-52]
	bl	_kMeans
	str	x0, [sp, #48]
	ldur	x0, [x29, #-16]
	ldur	x1, [x29, #-8]
	ldr	x2, [sp, #48]
	ldur	w3, [x29, #-52]
	bl	_printEPS
	ldur	x0, [x29, #-16]
	bl	_libmin_free
	ldr	x0, [sp, #48]
	bl	_libmin_free
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.cfi_endproc
                                        ; -- End function
	.globl	_main                           ; -- Begin function main
	.p2align	2
_main:                                  ; @main
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #32
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	mov	w8, #0
	str	w8, [sp, #8]                    ; 4-byte Folded Spill
	stur	wzr, [x29, #-4]
	mov	w0, #42
	bl	_libmin_srand
	bl	_test
	bl	_libmin_success
	ldr	w0, [sp, #8]                    ; 4-byte Folded Reload
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #32
	ret
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function test
lCPI6_0:
	.quad	0x401921fb54442d18              ; double 6.2831853071795862
lCPI6_1:
	.quad	0x41dfffffffc00000              ; double 2147483647
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_test:                                  ; @test
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	mov	x8, #200
	stur	x8, [x29, #-8]
	ldur	x9, [x29, #-8]
	mov	x8, #24
	mul	x0, x8, x9
	bl	_libmin_malloc
	stur	x0, [x29, #-16]
	fmov	d0, #20.00000000
	stur	d0, [x29, #-24]
	movi	d0, #0000000000000000
	stur	d0, [x29, #-32]
	stur	d0, [x29, #-40]
	stur	xzr, [x29, #-48]
	b	LBB6_1
LBB6_1:                                 ; =>This Inner Loop Header: Depth=1
	ldur	x8, [x29, #-48]
	ldur	x9, [x29, #-8]
	subs	x8, x8, x9
	cset	w8, hs
	tbnz	w8, #0, LBB6_4
	b	LBB6_2
LBB6_2:                                 ;   in Loop: Header=BB6_1 Depth=1
	ldur	d0, [x29, #-24]
	str	d0, [sp, #8]                    ; 8-byte Folded Spill
	bl	_libmin_rand
	ldr	d0, [sp, #8]                    ; 8-byte Folded Reload
	ucvtf	d1, w0
	adrp	x8, lCPI6_1@PAGE
	ldr	d2, [x8, lCPI6_1@PAGEOFF]
	str	d2, [sp, #16]                   ; 8-byte Folded Spill
	fdiv	d1, d1, d2
	fmul	d0, d0, d1
	stur	d0, [x29, #-32]
	bl	_libmin_rand
	ldr	d1, [sp, #16]                   ; 8-byte Folded Reload
	ucvtf	d0, w0
	fdiv	d1, d0, d1
	adrp	x8, lCPI6_0@PAGE
	ldr	d0, [x8, lCPI6_0@PAGEOFF]
	fmul	d0, d0, d1
	stur	d0, [x29, #-40]
	ldur	d0, [x29, #-32]
	str	d0, [sp, #24]                   ; 8-byte Folded Spill
	ldur	d0, [x29, #-40]
	bl	_libmin_cos
	fmov	d1, d0
	ldr	d0, [sp, #24]                   ; 8-byte Folded Reload
	fmul	d0, d0, d1
	ldur	x8, [x29, #-16]
	ldur	x9, [x29, #-48]
	mov	x10, #24
	str	x10, [sp, #32]                  ; 8-byte Folded Spill
	mul	x9, x9, x10
	str	d0, [x8, x9]
	ldur	d0, [x29, #-32]
	str	d0, [sp, #40]                   ; 8-byte Folded Spill
	ldur	d0, [x29, #-40]
	bl	_libmin_sin
	ldr	x10, [sp, #32]                  ; 8-byte Folded Reload
	fmov	d1, d0
	ldr	d0, [sp, #40]                   ; 8-byte Folded Reload
	fmul	d0, d0, d1
	ldur	x8, [x29, #-16]
	ldur	x9, [x29, #-48]
	mul	x9, x9, x10
	add	x8, x8, x9
	str	d0, [x8, #8]
	b	LBB6_3
LBB6_3:                                 ;   in Loop: Header=BB6_1 Depth=1
	ldur	x8, [x29, #-48]
	add	x8, x8, #1
	stur	x8, [x29, #-48]
	b	LBB6_1
LBB6_4:
	mov	w8, #5
	stur	w8, [x29, #-52]
	ldur	x0, [x29, #-16]
	ldur	x1, [x29, #-8]
	ldur	w2, [x29, #-52]
	bl	_kMeans
	str	x0, [sp, #48]
	ldur	x0, [x29, #-16]
	ldur	x1, [x29, #-8]
	ldr	x2, [sp, #48]
	ldur	w3, [x29, #-52]
	bl	_printEPS
	ldur	x0, [x29, #-16]
	bl	_libmin_free
	ldr	x0, [sp, #48]
	bl	_libmin_free
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%%!PS-Adobe-3.0 EPSF-3.0\n%%%%BoundingBox: -5 -5 %d %d\n"

l_.str.1:                               ; @.str.1
	.asciz	"/l {rlineto} def /m {rmoveto} def\n/c { .25 sub exch .25 sub exch .5 0 360 arc fill } def\n/s { moveto -2 0 m 2 2 l 2 -2 l -2 -2 l closepath \tgsave 1 setgray fill grestore gsave 3 setlinewidth 1 setgray stroke grestore 0 setgray stroke }def\n"

l_.str.2:                               ; @.str.2
	.asciz	"%g %g %g setrgbcolor\n"

l_.str.3:                               ; @.str.3
	.asciz	"%.3f %.3f c\n"

l_.str.4:                               ; @.str.4
	.asciz	"\n0 setgray %g %g s\n"

l_.str.5:                               ; @.str.5
	.asciz	"\n%%%%EOF\n"

.subsections_via_symbols