// File: It4innovations[P]Handicap/src/GraphLabelings/GraphLabeling.h
// Function: GraphLabeling::GraphLabeling(std::shared_ptr<ExtendedHandicapGraph>&)
explicit GraphLabeling(std::shared_ptr<ExtendedHandicapGraph> & graph) : graph{graph} {
			solutionValidator = std::unique_ptr<SolutionValidator>(new SolutionValidator(graph));
			solutionPrinter = std::unique_ptr<SolutionPrinter>(new SolutionPrinter(graph));
			generator = std::unique_ptr<CombinatorialGenerator>(new CombinatorialGenerator(graph));
			this->solution = std::unique_ptr<LabelingSolution<int>>(
					new LabelingSolution<int>(graph->getRegularConstant(), graph->getVerticesCount() + 2,
					                          graph->getMissingLabel()));

			this->intermediateNSumResults = std::unique_ptr<std::stack<int>[]>(
					new std::stack<int>[graph->getVerticesCount() + 1]);
			this->disabledNumbersArray = std::unique_ptr<int[]>(new int[graph->getRegularConstant()]());

			for (int i = 0; i < graph->getVerticesCount() + 2; i++) {
				this->solution->setMagicWeight(i, (i == 0 || i == graph->getMissingLabel()) ? 0 :
				                                  graph->getMagicConstant() + i);
			}
		}

// Assembly:
subq $0x158, %rsp            # imm = 0x158
movq %rdi, 0x150(%rsp)
movq %rsi, 0x148(%rsp)
movq 0x150(%rsp), %rdi
movq %rdi, 0xf0(%rsp)
movq %rdi, %rax
movq %rax, 0xb8(%rsp)
movq 0x148(%rsp), %rsi
callq 0xed10
movq 0xf0(%rsp), %rdi
addq $0x10, %rdi
movq %rdi, 0xc0(%rsp)
callq 0xed40
movq 0xf0(%rsp), %rdi
addq $0x18, %rdi
movq %rdi, 0xc8(%rsp)
callq 0xed70
movq 0xf0(%rsp), %rdi
addq $0x20, %rdi
movq %rdi, 0xd0(%rsp)
callq 0xeda0
movq 0xf0(%rsp), %rdi
addq $0x28, %rdi
movq %rdi, 0xd8(%rsp)
callq 0xedd0
movq 0xf0(%rsp), %rdi
addq $0x30, %rdi
movq %rdi, 0xe0(%rsp)
callq 0xee00
movq 0xf0(%rsp), %rdi
addq $0x38, %rdi
movq %rdi, 0xe8(%rsp)
callq 0xee30
movq 0xf0(%rsp), %rax
movl $0xffffffff, 0x40(%rax) # imm = 0xFFFFFFFF
movl $0x4, %edi
callq 0x21b0
movq %rax, 0xf8(%rsp)
jmp 0xe538
movq 0xf8(%rsp), %rdi
movq 0x148(%rsp), %rsi
callq 0xee60
jmp 0xe54f
movq 0xf8(%rsp), %rsi
leaq 0x140(%rsp), %rdi
movq %rdi, 0xa8(%rsp)
callq 0xeea0
movq 0xb8(%rsp), %rdi
movq 0xa8(%rsp), %rsi
addq $0x18, %rdi
callq 0xeed0
movq 0xa8(%rsp), %rdi
callq 0xef00
movl $0x8, %edi
callq 0x21b0
movq %rax, 0xb0(%rsp)
jmp 0xe5a6
movq 0xb0(%rsp), %rdi
movq 0x148(%rsp), %rsi
callq 0xef60
jmp 0xe5bd
movq 0xb0(%rsp), %rsi
leaq 0x128(%rsp), %rdi
movq %rdi, 0x98(%rsp)
callq 0xf020
movq 0xb8(%rsp), %rdi
movq 0x98(%rsp), %rsi
addq $0x20, %rdi
callq 0xf050
movq 0x98(%rsp), %rdi
callq 0xf080
movl $0x38, %edi
callq 0x21b0
movq %rax, 0xa0(%rsp)
jmp 0xe614
movq 0xa0(%rsp), %rdi
movq 0x148(%rsp), %rsi
callq 0xf0e0
jmp 0xe62b
movq 0xa0(%rsp), %rsi
leaq 0x120(%rsp), %rdi
movq %rdi, 0x88(%rsp)
callq 0xf240
movq 0xb8(%rsp), %rdi
movq 0x88(%rsp), %rsi
addq $0x28, %rdi
callq 0xf270
movq 0x88(%rsp), %rdi
callq 0xf2a0
movl $0x60, %edi
callq 0x21b0
movq %rax, 0x90(%rsp)
jmp 0xe682
movq 0x148(%rsp), %rdi
callq 0x3f90
movq %rax, %rdi
callq 0x6d20
movl %eax, 0x80(%rsp)
movq 0x148(%rsp), %rdi
callq 0x3f90
movq %rax, %rdi
callq 0x3fa0
addl $0x2, %eax
movl %eax, 0x84(%rsp)
movq 0x148(%rsp), %rdi
callq 0x3f90
movq %rax, %rdi
callq 0x3fb0
movq 0x90(%rsp), %rdi
movl 0x80(%rsp), %esi
movl 0x84(%rsp), %edx
movl %eax, %ecx
callq 0xf300
jmp 0xe6f1
movq 0x90(%rsp), %rsi
leaq 0x118(%rsp), %rdi
movq %rdi, 0x68(%rsp)
callq 0xf480
movq 0xb8(%rsp), %rdi
movq 0x68(%rsp), %rsi
addq $0x10, %rdi
callq 0xf4b0
movq 0x68(%rsp), %rdi
callq 0xf4e0
movq 0x148(%rsp), %rdi
callq 0x3f90
movq %rax, %rdi
callq 0x3fa0
incl %eax
cltq
movq %rax, 0x70(%rsp)
movl $0x50, %ecx
mulq %rcx
movq %rax, %rdi
seto %cl
addq $0x8, %rdi
movq $-0x1, %rax
cmovbq %rax, %rdi
testb %cl, %cl
cmovneq %rax, %rdi
callq 0x2030
movq %rax, 0x78(%rsp)
jmp 0xe778
movq 0x70(%rsp), %rax
movq 0x78(%rsp), %rcx
movq %rax, (%rcx)
addq $0x8, %rcx
movq %rcx, 0x60(%rsp)
cmpq $0x0, %rax
je 0xe7db
movq 0x60(%rsp), %rax
movq 0x70(%rsp), %rcx
imulq $0x50, %rcx, %rdx
movq %rax, %rcx
addq %rdx, %rcx
movq %rcx, 0x50(%rsp)
movq %rax, 0x58(%rsp)
movq 0x58(%rsp), %rdi
movq %rdi, 0x48(%rsp)
callq 0x4020
jmp 0xe7c3
movq 0x50(%rsp), %rcx
movq 0x48(%rsp), %rax
addq $0x50, %rax
cmpq %rcx, %rax
movq %rax, 0x58(%rsp)
jne 0xe7b2
movq 0x60(%rsp), %rsi
leaq 0x110(%rsp), %rdi
movq %rdi, 0x30(%rsp)
callq 0xf540
movq 0xb8(%rsp), %rdi
movq 0x30(%rsp), %rsi
addq $0x30, %rdi
callq 0xf570
movq 0x30(%rsp), %rdi
callq 0xf5a0
movq 0x148(%rsp), %rdi
callq 0x3f90
movq %rax, %rdi
callq 0x6d20
cltq
movl $0x4, %ecx
mulq %rcx
movq %rax, %rdi
movq $-0x1, %rax
cmovoq %rax, %rdi
movq %rdi, 0x38(%rsp)
callq 0x2030
movq %rax, 0x40(%rsp)
jmp 0xe850
movq 0x40(%rsp), %rdi
movq 0x38(%rsp), %rdx
xorl %esi, %esi
callq 0x20f0
movq 0x40(%rsp), %rsi
leaq 0x108(%rsp), %rdi
callq 0x3fc0
movq 0xb8(%rsp), %rdi
addq $0x38, %rdi
leaq 0x108(%rsp), %rsi
callq 0xf600
leaq 0x108(%rsp), %rdi
callq 0x4490
movl $0x0, 0x104(%rsp)
movl 0x104(%rsp), %eax
movl %eax, 0x2c(%rsp)
movq 0x148(%rsp), %rdi
callq 0x3f90
movq %rax, %rdi
callq 0x3fa0
movl %eax, %ecx
movl 0x2c(%rsp), %eax
addl $0x2, %ecx
cmpl %ecx, %eax
jge 0xea8d
movq 0xb8(%rsp), %rdi
addq $0x10, %rdi
callq 0xf630
movq %rax, 0x20(%rsp)
cmpl $0x0, 0x104(%rsp)
je 0xe91f
movl 0x104(%rsp), %eax
movl %eax, 0x1c(%rsp)
movq 0x148(%rsp), %rdi
callq 0x3f90
movq %rax, %rdi
callq 0x3fb0
movl %eax, %ecx
movl 0x1c(%rsp), %eax
cmpl %ecx, %eax
jne 0xe927
xorl %eax, %eax
movl %eax, 0x18(%rsp)
jmp 0xe947
movq 0x148(%rsp), %rdi
callq 0x3f90
movq %rax, %rdi
callq 0x4070
addl 0x104(%rsp), %eax
movl %eax, 0x18(%rsp)
movq 0x20(%rsp), %rdi
movl 0x18(%rsp), %eax
movl %eax, 0x100(%rsp)
leaq 0x104(%rsp), %rsi
leaq 0x100(%rsp), %rdx
callq 0xf640
jmp 0xe96e
jmp 0xe970
movl 0x104(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x104(%rsp)
jmp 0xe8a4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x138(%rsp)
movl %eax, 0x134(%rsp)
jmp 0xea95
movq 0xf8(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x138(%rsp)
movl %eax, 0x134(%rsp)
callq 0x2190
jmp 0xea95
movq 0xb0(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x138(%rsp)
movl %eax, 0x134(%rsp)
callq 0x2190
jmp 0xea95
movq 0xa0(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x138(%rsp)
movl %eax, 0x134(%rsp)
callq 0x2190
jmp 0xea95
movq 0x90(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x138(%rsp)
movl %eax, 0x134(%rsp)
callq 0x2190
jmp 0xea95
movq 0x60(%rsp), %rcx
movq %rax, %rsi
movq 0x48(%rsp), %rax
movq %rsi, 0x138(%rsp)
movl %edx, 0x134(%rsp)
cmpq %rax, %rcx
movq %rax, 0x10(%rsp)
je 0xea81
movq 0x10(%rsp), %rdi
addq $-0x50, %rdi
movq %rdi, 0x8(%rsp)
callq 0x4460
movq 0x60(%rsp), %rcx
movq 0x8(%rsp), %rax
cmpq %rcx, %rax
movq %rax, 0x10(%rsp)
jne 0xea5a
movq 0x78(%rsp), %rdi
callq 0x21e0
jmp 0xea95
addq $0x158, %rsp            # imm = 0x158
retq
movq 0xe8(%rsp), %rdi
callq 0x4490
movq 0xe0(%rsp), %rdi
callq 0xf5a0
movq 0xd8(%rsp), %rdi
callq 0xf2a0
movq 0xd0(%rsp), %rdi
callq 0xf080
movq 0xc8(%rsp), %rdi
callq 0xef00
movq 0xc0(%rsp), %rdi
callq 0xf4e0
movq 0xf0(%rsp), %rdi
callq 0x3e80
movq 0x138(%rsp), %rdi
callq 0x22b0
nopl (%rax)