// File: /workspace/github_c_makefile_star2_O3/pwelke[P]GraphMiningTools/poset_pathCover.c
// Function: latticeLongestWeightedPathEmbeddingForLocalEasy
struct IntSet* latticeLongestWeightedPathEmbeddingForLocalEasy(struct Graph* g, struct EvaluationPlan p, int sampleSize, int databaseSize, struct GraphPool* gp, struct ShallowGraphPool* sgp) {

	struct SpanningtreeTree spTree = getSampledSpanningtreeTree(getBlockTreeT(g, sgp), sampleSize, 1, gp, sgp);

	int nEvaluations = 0;
	cleanEvaluationPlan(p);
	for (int i=1; i<p.poset->n; ++i) {
		if (!embeddingValueKnown(p.poset->vertices[i])) {
			int* path = getLongestPathInDAG(p.poset->vertices[i], p.poset, sgp);
			double* weights = getWeightsOfPath(p.poset, path, databaseSize);
			nEvaluations += weightedBinarySearchEvaluationLE(&spTree, p, path, weights, gp);
			free(path);
			free(weights);
		}
	}

	dumpSpanningtreeTree(spTree, gp);

	fprintf(stderr, "%i\n", nEvaluations);
	return patternPosetInfoToFeatureSet(p);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xf8, %rsp
movq %r8, %r12
movq %rcx, %rbx
movl %edx, 0x44(%rsp)
movl %esi, %ebp
movq %rdi, %rsi
leaq 0x130(%rsp), %r15
leaq 0xd0(%rsp), %r14
movq %r14, %rdi
movq %r8, %rdx
callq 0xe7b8
movq 0x20(%r14), %rax
movq %rax, 0x20(%rsp)
movups (%r14), %xmm0
movups 0x10(%r14), %xmm1
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
leaq 0x68(%rsp), %rdi
pushq $0x1
popq %rdx
movl %ebp, %esi
movq %rbx, 0x48(%rsp)
movq %rbx, %rcx
movq %r12, 0x50(%rsp)
movq %r12, %r8
callq 0xefc8
movapd (%r15), %xmm0
movapd 0x10(%r15), %xmm1
movapd 0x20(%r15), %xmm2
movupd %xmm2, 0x20(%rsp)
movupd %xmm1, 0x10(%rsp)
movupd %xmm0, (%rsp)
callq 0x15298
movq (%r15), %rax
xorl %r14d, %r14d
cmpl $0x2, (%rax)
jl 0x2e06
xorl %r14d, %r14d
pushq $0x1
popq %r12
movq 0x10(%rax), %rax
movq (%rax,%r12,8), %rdi
callq 0x152d3
testl %eax, %eax
jne 0x2df4
movq (%r15), %rsi
movq 0x10(%rsi), %rax
movq (%rax,%r12,8), %rdi
movq 0x50(%rsp), %rdx
callq 0x189fd
movq %rax, %rbx
movq (%r15), %rdi
movq %rax, %rsi
movl 0x44(%rsp), %edx
callq 0x18b15
movq %rax, %rbp
movupd (%r15), %xmm0
movupd 0x10(%r15), %xmm1
movupd 0x20(%r15), %xmm2
movapd %xmm2, 0xc0(%rsp)
movapd %xmm1, 0xb0(%rsp)
movapd %xmm0, 0xa0(%rsp)
movq %rbx, 0x38(%rsp)
movslq (%rbx), %rbx
decq %rbx
je 0x2ddc
movq %r12, 0x58(%rsp)
movq %r14, 0x60(%rsp)
movsd (%rbp), %xmm0
xorl %r12d, %r12d
movq %rbx, %rax
movsd 0x1e0d6(%rip), %xmm1    # 0x20d38
pushq $0x1
popq %rcx
movsd 0x1e0d3(%rip), %xmm3    # 0x20d40
movapd 0x1e0db(%rip), %xmm4    # 0x20d50
movsd (%rbp,%rcx,8), %xmm2
divsd %xmm0, %xmm2
addsd %xmm3, %xmm2
andpd %xmm4, %xmm2
ucomisd %xmm2, %xmm1
cmovaq %rcx, %r12
cmovaq %rbx, %rax
minsd %xmm1, %xmm2
incq %rcx
movapd %xmm2, %xmm1
cmpq %rax, %rcx
jbe 0x2c75
xorl %r13d, %r13d
movq 0x38(%rsp), %r15
movq 0xa0(%rsp), %rax
movq 0x10(%rax), %rax
movslq (%r15,%r12,4), %r14
movq (%rax,%r14,8), %rdi
callq 0x152d3
movq 0xa0(%rsp), %rcx
movq 0x10(%rcx), %rcx
movq (%rcx,%r14,8), %rdi
testl %eax, %eax
je 0x2ce2
callq 0x152dd
jmp 0x2d69
movq (%rdi), %rsi
leaq 0x68(%rsp), %rdi
movq 0x48(%rsp), %rdx
callq 0xfa92
movl %eax, %r15d
movq 0x98(%rsp), %rax
movq %rax, 0x30(%rsp)
movups 0x68(%rsp), %xmm0
movups 0x78(%rsp), %xmm1
movups 0x88(%rsp), %xmm2
movups %xmm2, 0x20(%rsp)
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
callq 0xf3f1
incl %r13d
movapd 0xa0(%rsp), %xmm0
movapd 0xb0(%rsp), %xmm1
movapd 0xc0(%rsp), %xmm2
movupd %xmm2, 0x20(%rsp)
movupd %xmm1, 0x10(%rsp)
movupd %xmm0, (%rsp)
movsbl %r15b, %esi
movq 0x38(%rsp), %r15
movl %r14d, %edi
callq 0x152e7
leaq 0x1(%r12), %rax
cmpq %rbx, %rax
movsd 0x1dfc7(%rip), %xmm3    # 0x20d40
movapd 0x1dfcf(%rip), %xmm4    # 0x20d50
ja 0x2dc8
movsd (%rbp,%r12,8), %xmm0
movq %rbx, %rcx
movsd 0x1dfa3(%rip), %xmm1    # 0x20d38
movsd (%rbp,%rax,8), %xmm2
divsd %xmm0, %xmm2
addsd %xmm3, %xmm2
andpd %xmm4, %xmm2
ucomisd %xmm2, %xmm1
cmovaq %rax, %r12
cmovaq %rbx, %rcx
minsd %xmm1, %xmm2
incq %rax
movapd %xmm2, %xmm1
cmpq %rcx, %rax
jbe 0x2d95
jmp 0x2cab
leaq 0x130(%rsp), %r15
movq 0x60(%rsp), %r14
movq 0x58(%rsp), %r12
jmp 0x2ddf
xorl %r13d, %r13d
addl %r13d, %r14d
movq 0x38(%rsp), %rdi
callq 0x1030
movq %rbp, %rdi
callq 0x1030
incq %r12
movq (%r15), %rax
movslq (%rax), %rcx
cmpq %rcx, %r12
jl 0x2bc9
movq 0x98(%rsp), %rax
movq %rax, 0x30(%rsp)
movups 0x68(%rsp), %xmm0
movups 0x78(%rsp), %xmm1
movups 0x88(%rsp), %xmm2
movups %xmm2, 0x20(%rsp)
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
movq 0x48(%rsp), %rdi
callq 0xf470
movq 0x2a1b4(%rip), %rax     # 0x2cff8
movq (%rax), %rdi
leaq 0x1d1e8(%rip), %rsi     # 0x20036
movl %r14d, %edx
xorl %eax, %eax
callq 0x1160
movups (%r15), %xmm0
movups 0x10(%r15), %xmm1
movups 0x20(%r15), %xmm2
movups %xmm2, 0x20(%rsp)
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
callq 0x1543e
addq $0xf8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nopl (%rax,%rax)