// File: /workspace/github_cpp_makefile_star2_O2/Laakeri[P]Triangulator/src/PMC.cpp
// Function: PMC::findMinSeps(Graph const&, long)
vector<vector<int> > findMinSeps(const Graph& G, int64_t UBcount = -1) {
	vector<vector<int> > minSeps;
	set<vector<int> > ff;
	for (int i = 0; i < G.n; i++) {
		if (G.g[i].size() == 0) continue;
		for (int j = 0; j < G.n; j++) {
			u[j] = 0;
		}
		for (int nx : G.g[i]) {
			u[nx] = 2;
		}
		u[i] = 2;
		for (int nx : G.g[i]) {
			for (int nnx : G.g[nx]) {
				if (u[nnx] == 0) {
					vector<int> nb;
					dfs4(G, nnx, nb);
					assert(nb.size() > 0);
					for (int a : nb) {
						u[a] = 2;
					}
					sort(nb.begin(), nb.end());
					if (!ff.count(nb)) {
						ff.insert(nb);
						minSeps.push_back(nb);
						if (UBcount != -1 && (int64_t)minSeps.size() >= UBcount) {
							sort(minSeps.begin(), minSeps.end());
							return minSeps;
						}
					}
				}
			}
		}
	}
	for (int i = 0; i < (int)minSeps.size(); i++) {
		auto S = minSeps[i];
		for (int x : S) {
			for (int j = 0; j < G.n; j++) {
				u[j] = 0;
			}
			for (int y : S) {
				u[y] = 2;
			}
			for (int nx : G.g[x]) {
				u[nx] = 2;
			}
			for (int nx : G.g[x]) {
				for (int nnx : G.g[nx]) {
					if (u[nnx] == 0) {
						vector<int> nb;
						dfs4(G, nnx, nb);
						assert(nb.size() > 0);
						for (int a : nb) {
							u[a] = 2;
						}
						sort(nb.begin(), nb.end());
						if (!ff.count(nb)) {
							ff.insert(nb);
							minSeps.push_back(nb);
							if (UBcount != -1 && (int64_t)minSeps.size() >= UBcount) {
								sort(minSeps.begin(), minSeps.end());
								return minSeps;
							}
						}
					}
				}
			}
		}
	}
	sort(minSeps.begin(), minSeps.end());
	return minSeps;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movq %rdx, 0x48(%rsp)
movq %rsi, %r8
andq $0x0, 0x10(%rdi)
leaq 0x80(%rsp), %rax
andl $0x0, (%rax)
andq $0x0, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
andq $0x0, 0x20(%rax)
xorps %xmm0, %xmm0
movq %rdi, (%rsp)
movups %xmm0, (%rdi)
xorl %edx, %edx
leaq 0x5d2e53(%rip), %rbp    # 0x5e9020
leaq 0x20(%rsp), %r12
movq $0x0, 0x38(%rsp)
movq %rsi, 0x40(%rsp)
movl 0x50(%r8), %eax
movslq %eax, %rcx
cmpq %rcx, %rdx
jge 0x1638e
movq %rcx, 0x10(%rsp)
movq 0x38(%r8), %rcx
movq %rdx, 0x8(%rsp)
imulq $0x18, %rdx, %rdx
movq (%rcx,%rdx), %rsi
movq 0x8(%rcx,%rdx), %rdi
cmpq %rsi, %rdi
je 0x16371
movq %rbp, %rcx
xorl %edx, %edx
cltq
cmpq %rax, %rdx
jge 0x16230
andl $0x0, (%rcx)
incq %rdx
movl 0x50(%r8), %eax
addq $0x4, %rcx
jmp 0x16219
movq %rsi, %rax
cmpq %rdi, %rax
je 0x16249
movslq (%rax), %rcx
movl $0x2, (%rbp,%rcx,4)
addq $0x4, %rax
jmp 0x16233
movq 0x8(%rsp), %rax
movl $0x2, (%rbp,%rax,4)
movq %rdi, 0x18(%rsp)
cmpq %rdi, %rsi
je 0x16371
movq %rsi, %r15
movslq (%rsi), %rax
movq 0x38(%r8), %rcx
imulq $0x18, %rax, %rax
movq (%rcx,%rax), %rbx
movq 0x8(%rcx,%rax), %r14
cmpq %r14, %rbx
je 0x16360
movslq (%rbx), %rsi
cmpl $0x0, (%rbp,%rsi,4)
jne 0x16303
xorps %xmm0, %xmm0
movaps %xmm0, 0x20(%rsp)
andq $0x0, 0x30(%rsp)
movq %r8, %rdi
movq %r12, %rdx
callq 0x160cc
movq 0x20(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq %rdi, %rax
cmpq %rdi, %rsi
je 0x1660c
cmpq %rsi, %rax
je 0x162d3
movslq (%rax), %rcx
movl $0x2, (%rbp,%rcx,4)
addq $0x4, %rax
jmp 0x162bd
callq 0x8dde
leaq 0x78(%rsp), %rdi
movq %r12, %rsi
callq 0x195e2
movb $0x1, %r13b
testq %rax, %rax
je 0x1630c
movq %r12, %rdi
callq 0x38e4
testb %r13b, %r13b
je 0x1637e
movq 0x40(%rsp), %r8
addq $0x4, %rbx
jmp 0x1627b
leaq 0x78(%rsp), %rdi
movq %r12, %rsi
callq 0x19b96
movq (%rsp), %rdi
movq %r12, %rsi
callq 0x88a4
movq 0x48(%rsp), %rcx
cmpq $-0x1, %rcx
je 0x162ed
movq (%rsp), %rax
movq (%rax), %rdi
movq 0x8(%rax), %rsi
movq %rsi, %rax
subq %rdi, %rax
cqto
pushq $0x18
popq %r8
idivq %r8
cmpq %rcx, %rax
jl 0x162ed
callq 0x9ad1
movb $0x1, %al
movq %rax, 0x38(%rsp)
xorl %r13d, %r13d
jmp 0x162ed
movq %r15, %rsi
addq $0x4, %rsi
movq 0x18(%rsp), %rdi
jmp 0x1625b
movq 0x8(%rsp), %rdx
incq %rdx
jmp 0x161e0
movq 0x8(%rsp), %rax
cmpq 0x10(%rsp), %rax
jl 0x165a6
xorl %r8d, %r8d
leaq 0x5d2c88(%rip), %r12    # 0x5e9020
leaq 0x50(%rsp), %r13
movq (%rsp), %rax
movq (%rax), %rsi
movq 0x8(%rax), %rcx
movq %rcx, %rax
subq %rsi, %rax
cqto
pushq $0x18
popq %rdi
idivq %rdi
cltq
cmpq %rax, %r8
jge 0x165c2
movq %r8, 0x70(%rsp)
imulq $0x18, %r8, %rax
addq %rax, %rsi
leaq 0x20(%rsp), %rdi
callq 0x3896
movq 0x20(%rsp), %r8
movq 0x28(%rsp), %rax
movq 0x40(%rsp), %rdi
movq %rax, 0x10(%rsp)
cmpq %rax, %r8
movq %r8, 0x18(%rsp)
je 0x16584
movslq (%r8), %rax
movq %r12, %rcx
xorl %edx, %edx
movslq 0x50(%rdi), %rsi
cmpq %rsi, %rdx
jge 0x16416
andl $0x0, (%rcx)
incq %rdx
addq $0x4, %rcx
jmp 0x16401
movq 0x20(%rsp), %rcx
movq 0x28(%rsp), %rdx
cmpq %rdx, %rcx
je 0x16436
movslq (%rcx), %rsi
movl $0x2, (%r12,%rsi,4)
addq $0x4, %rcx
jmp 0x16420
movq 0x38(%rdi), %rcx
imulq $0x18, %rax, %rax
movq (%rcx,%rax), %rdx
movq 0x8(%rcx,%rax), %rbx
movq %rdx, %rax
cmpq %rbx, %rax
je 0x16568
movslq (%rax), %rcx
movl $0x2, (%r12,%rcx,4)
addq $0x4, %rax
jmp 0x1644a
movq %rdx, 0x8(%rsp)
movslq (%rdx), %rax
movq 0x38(%rdi), %rcx
imulq $0x18, %rax, %rax
movq (%rcx,%rax), %rbp
movq 0x8(%rcx,%rax), %r14
cmpq %r14, %rbp
je 0x1655f
movslq (%rbp), %rsi
cmpl $0x0, (%r12,%rsi,4)
jne 0x16502
xorps %xmm0, %xmm0
movaps %xmm0, 0x50(%rsp)
andq $0x0, 0x60(%rsp)
movq %r13, %rdx
callq 0x160cc
movq 0x50(%rsp), %rdi
movq 0x58(%rsp), %rsi
movq %rdi, %rax
cmpq %rdi, %rsi
jne 0x164cd
jmp 0x165ed
movslq (%rax), %rcx
movl $0x2, (%r12,%rcx,4)
addq $0x4, %rax
cmpq %rsi, %rax
jne 0x164be
callq 0x8dde
leaq 0x78(%rsp), %rdi
movq %r13, %rsi
callq 0x195e2
movb $0x1, %r15b
testq %rax, %rax
je 0x1650b
movq %r13, %rdi
callq 0x38e4
testb %r15b, %r15b
movq 0x40(%rsp), %rdi
je 0x16584
addq $0x4, %rbp
jmp 0x1647d
leaq 0x78(%rsp), %rdi
movq %r13, %rsi
callq 0x19b96
movq (%rsp), %rdi
movq %r13, %rsi
callq 0x88a4
movq 0x48(%rsp), %rcx
cmpq $-0x1, %rcx
je 0x164ec
movq (%rsp), %rax
movq (%rax), %rdi
movq 0x8(%rax), %rsi
movq %rsi, %rax
subq %rdi, %rax
cqto
pushq $0x18
popq %r8
idivq %r8
cmpq %rcx, %rax
jl 0x164ec
callq 0x9ad1
movb $0x1, %al
movq %rax, 0x38(%rsp)
xorl %r15d, %r15d
jmp 0x164ec
movq 0x8(%rsp), %rdx
addq $0x4, %rdx
cmpq %rbx, %rdx
jne 0x16464
movq 0x18(%rsp), %r8
addq $0x4, %r8
movq 0x10(%rsp), %rax
jmp 0x163eb
leaq 0x20(%rsp), %rdi
callq 0x38e4
movq 0x70(%rsp), %r8
incq %r8
movq 0x10(%rsp), %rax
cmpq %rax, 0x18(%rsp)
je 0x1639d
leaq 0x78(%rsp), %rdi
callq 0x198be
testb $0x1, 0x38(%rsp)
jne 0x165d7
movq (%rsp), %rdi
callq 0x376e
jmp 0x165d7
movq %rsi, %rdi
movq %rcx, %rsi
callq 0x9ad1
leaq 0x78(%rsp), %rdi
callq 0x198be
movq (%rsp), %rax
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xb640(%rip), %rdi      # 0x21c34
leaq 0xb0cb(%rip), %rsi      # 0x216c6
leaq 0xb640(%rip), %rcx      # 0x21c42
movl $0x1c9, %edx            # imm = 0x1C9
callq 0x2150
leaq 0xb621(%rip), %rdi      # 0x21c34
leaq 0xb0ac(%rip), %rsi      # 0x216c6
leaq 0xb621(%rip), %rcx      # 0x21c42
movl $0x1a7, %edx            # imm = 0x1A7
callq 0x2150
jmp 0x1662d
movq %rax, %r14
jmp 0x1664e
movq %rax, %r14
jmp 0x16644
movq %rax, %r14
leaq 0x50(%rsp), %rdi
callq 0x38e4
leaq 0x20(%rsp), %rdi
callq 0x38e4
leaq 0x78(%rsp), %rdi
callq 0x198be
movq (%rsp), %rdi
callq 0x376e
movq %r14, %rdi
callq 0x2340