// File: /workspace/github_cpp_makefile_star2_O2/Luthaf[P]zeopp/voro++/src/cell.cc
// Function: voro::voronoicell_base::volume()
double voronoicell_base::volume() {
	const double fe=1/48.0;
	double vol=0;
	int i,j,k,l,m,n;
	double ux,uy,uz,vx,vy,vz,wx,wy,wz;
	for(i=1;i<p;i++) {
		ux=*pts-pts[i<<2];
		uy=pts[1]-pts[(i<<2)+1];
		uz=pts[2]-pts[(i<<2)+2];
		for(j=0;j<nu[i];j++) {
			k=ed[i][j];
			if(k>=0) {
				ed[i][j]=-1-k;
				l=cycle_up(ed[i][nu[i]+j],k);
				vx=pts[k<<2]-*pts;
				vy=pts[(k<<2)+1]-pts[1];
				vz=pts[(k<<2)+2]-pts[2];
				m=ed[k][l];ed[k][l]=-1-m;
				while(m!=i) {
					n=cycle_up(ed[k][nu[k]+l],m);
					wx=pts[(m<<2)]-*pts;
					wy=pts[(m<<2)+1]-pts[1];
					wz=pts[(m<<2)+2]-pts[2];
					vol+=ux*vy*wz+uy*vz*wx+uz*vx*wy-uz*vy*wx-uy*vx*wz-ux*vz*wy;
					k=m;l=n;vx=wx;vy=wy;vz=wz;
					m=ed[k][l];ed[k][l]=-1-m;
				}
			}
		}
	}
	reset_edges();
	return vol*fe;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq 0x30(%rdi), %rax
movq 0x40(%rdi), %rcx
xorpd %xmm0, %xmm0
movsd %xmm0, (%rsp)
pushq $0x1
popq %rdx
xorl %esi, %esi
movslq 0x1c(%rdi), %r8
cmpq %r8, %rdx
jge 0x6c25
leal (,%rdx,4), %r8d
movslq %r8d, %r8
movupd (%rcx), %xmm1
movsd (%rcx,%r8,8), %xmm3
movapd %xmm1, %xmm2
subsd %xmm3, %xmm2
leal 0x1(,%rdx,4), %r8d
movslq %r8d, %r8
movapd %xmm1, %xmm3
unpckhpd %xmm1, %xmm3            # xmm3 = xmm3[1],xmm1[1]
subsd (%rcx,%r8,8), %xmm3
movsd 0x10(%rcx), %xmm4
leal 0x2(,%rdx,4), %r8d
movslq %r8d, %r8
movapd %xmm4, %xmm5
subsd (%rcx,%r8,8), %xmm5
movq 0x28(%rdi), %r8
movapd %xmm5, %xmm6
movapd 0x285c0(%rip), %xmm0    # 0x2f040
xorpd %xmm0, %xmm6
movapd %xmm3, %xmm7
xorpd %xmm0, %xmm7
movapd %xmm2, %xmm8
xorpd %xmm0, %xmm8
xorl %r9d, %r9d
movslq (%rax,%rdx,4), %r10
cmpq %r10, %r9
jge 0x6c1d
movq (%r8,%rdx,8), %r11
movslq (%r11,%r9,4), %r10
testq %r10, %r10
js 0x6c15
movl %r10d, %ebx
notl %ebx
movl %ebx, (%r11,%r9,4)
movslq (%rax,%rdx,4), %rbx
movslq %r9d, %r14
addq %rbx, %r14
movl (%r11,%r14,4), %r11d
movl (%rax,%r10,4), %ebx
decl %ebx
leal 0x1(%r11), %ebp
cmpl %r11d, %ebx
cmovel %esi, %ebp
leal (,%r10,4), %r11d
movslq %r11d, %r11
movupd (%rcx,%r11,8), %xmm10
subpd %xmm1, %xmm10
leal 0x2(,%r10,4), %r11d
movslq %r11d, %r11
movsd (%rcx,%r11,8), %xmm9
subsd %xmm4, %xmm9
movl %r10d, %r11d
movq (%r8,%r10,8), %r10
movslq %ebp, %r14
movl (%r10,%r14,4), %ebx
movl %ebx, %ebp
notl %ebp
movl %ebp, (%r10,%r14,4)
cmpq %rbx, %rdx
je 0x6c15
movslq %ebx, %r10
leal (,%r10,4), %ebp
movslq %ebp, %r15
movupd (%rcx,%r15,8), %xmm0
subpd %xmm1, %xmm0
leal 0x2(,%r10,4), %ebp
movslq %ebp, %r15
movsd (%rcx,%r15,8), %xmm12
subsd %xmm4, %xmm12
movapd %xmm10, %xmm13
unpckhpd %xmm10, %xmm13          # xmm13 = xmm13[1],xmm10[1]
movapd %xmm2, %xmm14
mulsd %xmm13, %xmm14
movapd %xmm3, %xmm15
mulsd %xmm9, %xmm15
mulsd %xmm0, %xmm15
mulsd %xmm12, %xmm14
addsd %xmm15, %xmm14
movapd %xmm5, %xmm15
mulsd %xmm10, %xmm15
movapd %xmm0, %xmm11
unpckhpd %xmm0, %xmm11           # xmm11 = xmm11[1],xmm0[1]
mulsd %xmm11, %xmm15
addsd %xmm14, %xmm15
mulsd %xmm6, %xmm13
mulsd %xmm0, %xmm13
addsd %xmm15, %xmm13
mulsd %xmm7, %xmm10
mulsd %xmm12, %xmm10
addsd %xmm13, %xmm10
mulsd %xmm8, %xmm9
mulsd %xmm11, %xmm9
addsd %xmm10, %xmm9
movslq %r11d, %r11
movq (%r8,%r11,8), %r15
movslq (%rax,%r11,4), %r11
addq %r14, %r11
movl (%r15,%r11,4), %r11d
movl (%rax,%r10,4), %r14d
decl %r14d
leal 0x1(%r11), %ebp
cmpl %r11d, %r14d
cmovel %esi, %ebp
movsd (%rsp), %xmm10
addsd %xmm9, %xmm10
movsd %xmm10, (%rsp)
movl %ebx, %r11d
movapd %xmm12, %xmm9
movapd %xmm0, %xmm10
jmp 0x6b0d
incq %r9
jmp 0x6a99
incq %rdx
jmp 0x6a13
callq 0xe024
movsd (%rsp), %xmm0
mulsd 0x29de1(%rip), %xmm0    # 0x30a18
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq