LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/cs_Parsing.c
// Function: parseCString
struct ShallowGraph* parseCString(FILE* stream, char* buffer, struct ShallowGraphPool* sgp) {
	struct ShallowGraph* string = getShallowGraph(sgp);
	struct VertexList* e;
	
	while (__notDone(stream)) {
		__readLabel(stream, buffer);
		e = getVertexList(sgp->listPool);
		if (strcmp(buffer, termString) == 0) {
			e->label = termString;
		} else {
			if (strcmp(buffer, initString) == 0) {
				e->label = initString;
			} else {
				int length = strlen(buffer) + 1;
				char* label = malloc(length * sizeof(char));
				strcpy(label, buffer);
				e->label = label;
				e->isStringMaster = 1;
			}
		}
		appendEdge(string, e);
	}
	return string;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movq %rdx, %rdi
callq 0x117e9
movq %rax, %r12
movq %r15, %rdi
callq 0x50be
testb %al, %al
je 0x51ce
movq %r15, %rdi
movq %r14, %rsi
callq 0x50f1
movq 0x10(%rbx), %rdi
callq 0x11307
movq %rax, %r13
movq 0x24fe1(%rip), %rbp     # 0x2a148
movq %r14, %rdi
movq %rbp, %rsi
callq 0x1130
testl %eax, %eax
je 0x51ba
movq 0x24fc3(%rip), %rbp     # 0x2a140
movq %r14, %rdi
movq %rbp, %rsi
callq 0x1130
testl %eax, %eax
je 0x51ba
movq %r14, %rdi
callq 0x10a0
incl %eax
movslq %eax, %rdi
callq 0x1180
movq %rax, %rbp
movq %rax, %rdi
movq %r14, %rsi
callq 0x1050
movq %rbp, (%r13)
movl $0x1, 0x28(%r13)
jmp 0x51be
movq %rbp, (%r13)
movq %r12, %rdi
movq %r13, %rsi
callq 0x6620
jmp 0x5139
movq %r12, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/cs_Parsing.c
// Function: string2cstring
struct ShallowGraph* string2cstring(char* str, struct ShallowGraphPool* sgp) {
	FILE* f = str2stream(str);
	char x[20];
	struct ShallowGraph* cstr = parseCString(f, x, sgp);
	fclose(f);
	return cstr;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x17efa(%rip), %r15     # 0x1d0f2
leaq 0x19474(%rip), %rsi     # 0x1e673
movq %r15, %rdi
callq 0x11c0
movq %rax, %r12
movq %r14, %rdi
movq %rax, %rsi
callq 0x10c0
movq %r12, %rdi
callq 0x1090
leaq 0x17ed9(%rip), %rsi     # 0x1d0fd
movq %r15, %rdi
callq 0x11c0
movq %rax, %r14
movq %rsp, %rsi
movq %rax, %rdi
movq %rbx, %rdx
callq 0x511a
movq %rax, %rbx
movq %r14, %rdi
callq 0x1090
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/cs_Tree.c
// Function: canonicalStringOfLevelTree
struct ShallowGraph* canonicalStringOfLevelTree(struct ShallowGraph* vertexList, int maxDepth, struct ShallowGraphPool* sgp) {

	struct VertexList* idx;
	struct ShallowGraph* canonicalString = NULL;

	/* compute the canonical string of the unique tree rooted at vertex i and save it at the correct position of the
	canonicalStrings array */
	for (idx=vertexList->edges; idx && (idx->endPoint->visited <= maxDepth); idx=idx->next) {

		/* compute the canonical string */
		struct ShallowGraph *cs = canonicalStringOfRootedLevelTree(idx->endPoint, NULL, maxDepth, sgp);

		/* keep the string if its the first one, computed for this component or lexicograhically smaller
			than the saved string */
		if (canonicalString) {
			if (compareCanonicalStrings(canonicalString, cs) > 0) {
				dumpShallowGraph(sgp, canonicalString);
				canonicalString = cs;
			} else {
				dumpShallowGraph(sgp, cs);
			}
		} else {
			canonicalString = cs;
		}

	}

	return canonicalString;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r14
xorl %r15d, %r15d
movq (%r14), %r14
testq %r14, %r14
je 0x564b
movq 0x18(%r14), %rdi
cmpl %ebp, 0x1c(%rdi)
jg 0x564b
xorl %esi, %esi
movl %ebp, %edx
movq %rbx, %rcx
callq 0x5401
movq %rax, %r12
testq %r15, %r15
je 0x5642
movq %r15, %rdi
movq %r12, %rsi
callq 0x3b32
movq %rbx, %rdi
testl %eax, %eax
jle 0x5637
movq %r15, %rsi
callq 0x1184e
jmp 0x5642
movq %r12, %rsi
callq 0x1184e
movq %r15, %r12
addq $0x8, %r14
movq %r12, %r15
jmp 0x55f6
movq %r15, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/cs_Tree.c
// Function: canonicalStringOfTree
struct ShallowGraph* canonicalStringOfTree(struct Graph* tree, struct ShallowGraphPool* sgp) {
	struct ShallowGraph* cString;
	int* center = treeCenter(tree);

	cString = canonicalStringOfRootedTree(tree->vertices[center[1]], tree->vertices[center[1]], sgp);
	
	if (center[0] == 3) {
		struct ShallowGraph* cString2 = canonicalStringOfRootedTree(tree->vertices[center[2]], tree->vertices[center[2]], sgp);
		if (compareCanonicalStrings(cString, cString2) < 0) {
			dumpShallowGraph(sgp, cString2);
		} else {
			dumpShallowGraph(sgp, cString);
			cString = cString2;
		}
	}
	free(center);
	return cString;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %r12
callq 0x1a82a
movq %rax, %rbx
movq 0x10(%r12), %rax
movslq 0x4(%rbx), %rcx
movq (%rax,%rcx,8), %rdi
movq %rdi, %rsi
movq %r14, %rdx
callq 0x5258
movq %rax, %r15
cmpl $0x3, (%rbx)
jne 0x5810
movq 0x10(%r12), %rax
movslq 0x8(%rbx), %rcx
movq (%rax,%rcx,8), %rdi
movq %rdi, %rsi
movq %r14, %rdx
callq 0x5258
movq %rax, %r12
movq %r15, %rdi
movq %rax, %rsi
callq 0x3b32
testl %eax, %eax
movq %r15, %rsi
cmovsq %r12, %rsi
cmovnsq %r12, %r15
movq %r14, %rdi
callq 0x1184e
movq %rbx, %rdi
callq 0x1030
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/cs_Tree.c
// Function: _canonicalString2GraphRec
int __canonicalString2GraphRec(struct Graph* g, int current, int parent, struct ShallowGraph* suffix, struct VertexList* initEdge, struct VertexList* termEdge, struct GraphPool* gp) {

	/* for all children of parent */
	while (suffix->edges != NULL) {
		char* edgeLabel;

		if (strcmp(suffix->edges->label, termEdge->label) == 0) {
			suffix->edges = suffix->edges->next;
			return current;
		}
		
		/* first comes edge label */
		suffix->edges = suffix->edges->next;
		edgeLabel = suffix->edges->label;

		/* now comes the vertex label */
		suffix->edges = suffix->edges->next;
		g->vertices[current]->label = suffix->edges->label;

		addEdgeBetweenVertices(parent, current, edgeLabel, g, gp);

		/* recursive call */
		suffix->edges = suffix->edges->next;
		current = __canonicalString2GraphRec(g, current + 1, current, suffix, initEdge, termEdge, gp);
	}

	/* return position of next free vertex in g */
	return current;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, %rbx
movq %r8, 0x10(%rsp)
movq %rcx, %r14
movl %edx, 0xc(%rsp)
movl %esi, %r15d
movq %rdi, %r12
movq 0x50(%rsp), %r13
movq (%r14), %rbp
testq %rbp, %rbp
je 0x58c9
movq (%rbp), %rdi
movq (%rbx), %rsi
callq 0x1130
movq 0x8(%rbp), %rcx
testl %eax, %eax
je 0x58c6
movq (%rcx), %rdx
movq 0x8(%rcx), %rax
movq %rax, (%r14)
movq (%rax), %rax
movq 0x10(%r12), %rcx
movslq %r15d, %r15
movq (%rcx,%r15,8), %rcx
movq %rax, (%rcx)
movl 0xc(%rsp), %edi
movl %r15d, %esi
movq %r12, %rcx
movq %r13, %r8
callq 0x6200
movq (%r14), %rax
movq 0x8(%rax), %rax
movq %rax, (%r14)
leal 0x1(%r15), %esi
movq %r13, (%rsp)
movq %r12, %rdi
movl %r15d, %edx
movq %r14, %rcx
movq 0x10(%rsp), %r8
movq %rbx, %r9
callq 0x5827
movl %eax, %r15d
jmp 0x584f
movq %rcx, (%r14)
movl %r15d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/cs_Tree.c
// Function: treeCanonicalString2Graph
struct Graph* treeCanonicalString2Graph(struct ShallowGraph* pattern, struct GraphPool* gp) {
	struct VertexList* initEdge = getInitialisatorEdge(gp->listPool);
	struct VertexList* termEdge = getTerminatorEdge(gp->listPool);
	struct VertexList* e;
	int n = 0;
	struct Graph* g;
	struct VertexList* head = pattern->edges;

	/* find number of vertices, create graph */
	for (e=pattern->edges; e!=NULL; e=e->next) {
		if (strcmp(e->label, initEdge->label) == 0) {
			++n;
		}
	}
	g = createGraph(n + 1, gp);

	/* create tree from canonical string recursively */
	g->vertices[0]->label = pattern->edges->label;
	pattern->edges = pattern->edges->next;
	__canonicalString2GraphRec(g, 1, 0, pattern, initEdge, termEdge, gp);
	pattern->edges = head;

	/* cleanup */
	dumpVertexList(gp->listPool, initEdge);
	dumpVertexList(gp->listPool, termEdge);

	return g;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movq 0x18(%rsi), %rdi
callq 0x4fac
movq %rax, %r15
movq 0x18(%rbx), %rdi
callq 0x4f9a
movq %rax, 0x10(%rsp)
movq (%r14), %r12
xorl %ebp, %ebp
movq %r12, %r13
testq %r13, %r13
je 0x592e
movq (%r13), %rdi
movq (%r15), %rsi
callq 0x1130
cmpl $0x1, %eax
adcl $0x0, %ebp
movq 0x8(%r13), %r13
jmp 0x5911
incl %ebp
movl %ebp, %edi
movq %rbx, %rsi
callq 0x630e
movq %rax, %r13
movq (%r14), %rax
movq (%rax), %rcx
movq 0x10(%r13), %rdx
movq (%rdx), %rdx
movq %rcx, (%rdx)
movq 0x8(%rax), %rax
movq %rax, (%r14)
movq %rbx, (%rsp)
pushq $0x1
popq %rsi
movq %r13, %rdi
xorl %edx, %edx
movq %r14, %rcx
movq %r15, %r8
movq 0x10(%rsp), %rbp
movq %rbp, %r9
callq 0x5827
movq %r12, (%r14)
movq 0x18(%rbx), %rdi
movq %r15, %rsi
callq 0x11364
movq 0x18(%rbx), %rdi
movq %rbp, %rsi
callq 0x11364
movq %r13, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/cs_Tree.c
// Function: treeCanonicalString2ExistingGraph
void treeCanonicalString2ExistingGraph(struct ShallowGraph* pattern, struct Graph* g, struct GraphPool* gp) {
	struct VertexList* initEdge = getInitialisatorEdge(gp->listPool);
	struct VertexList* termEdge = getTerminatorEdge(gp->listPool);
	struct VertexList* head = pattern->edges;

	/* create tree from canonical string recursively */
	g->vertices[0]->label = pattern->edges->label;
	pattern->edges = pattern->edges->next;
	__canonicalString2GraphRec(g, 1, 0, pattern, initEdge, termEdge, gp);
	pattern->edges = head;

	/* cleanup */
	dumpVertexList(gp->listPool, initEdge);
	dumpVertexList(gp->listPool, termEdge);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movq 0x18(%rdx), %rdi
callq 0x4fac
movq %rax, %r12
movq 0x18(%rbx), %rdi
callq 0x4f9a
movq %rax, %r13
movq (%r14), %rbp
movq (%rbp), %rax
movq 0x10(%r15), %rcx
movq (%rcx), %rcx
movq %rax, (%rcx)
movq 0x8(%rbp), %rax
movq %rax, (%r14)
movq %rbx, (%rsp)
pushq $0x1
popq %rsi
movq %r15, %rdi
xorl %edx, %edx
movq %r14, %rcx
movq %r12, %r8
movq %r13, %r9
callq 0x5827
movq %rbp, (%r14)
movq 0x18(%rbx), %rdi
movq %r12, %rsi
callq 0x11364
movq 0x18(%rbx), %rdi
movq %r13, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x11364
nop
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: shallowCopyEdge
struct VertexList* shallowCopyEdge(struct VertexList* e, struct ListPool* p) {
	struct VertexList* f = getVertexList(p);
	f->startPoint = e->startPoint;
	f->endPoint = e->endPoint;
	f->label = e->label;
	/* f does not manage its string but refers to a different lists string, thus it is no stringMaster */
	return f;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x11307
movups 0x10(%rbx), %xmm0
movups %xmm0, 0x10(%rax)
movq (%rbx), %rcx
movq %rcx, (%rax)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: inverseEdge
struct VertexList* inverseEdge(struct VertexList* e, struct ListPool* p) {
	struct VertexList* f = getVertexList(p);
	f->startPoint = e->endPoint;
	f->endPoint = e->startPoint;
	f->label = e->label;
	/* f does not manage its string but refers to a different lists string, thus it is no stringMaster */
	return f;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x11307
movq 0x18(%rbx), %rcx
movq %rcx, 0x10(%rax)
movq 0x10(%rbx), %rcx
movq %rcx, 0x18(%rax)
movq (%rbx), %rcx
movq %rcx, (%rax)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: shallowCopyVertex
struct Vertex* shallowCopyVertex(struct Vertex *v, struct VertexPool *p) {
	struct Vertex *new = getVertex(p);
	new->number = v->number;
	new->label = v->label;
	return new;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x114a5
movl 0x18(%rbx), %ecx
movl %ecx, 0x18(%rax)
movq (%rbx), %rcx
movq %rcx, (%rax)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: commonNeighborCount
int commonNeighborCount(struct Vertex* v, struct Vertex* w) {
	struct VertexList* e;
	int count = 0;

	for (e=v->neighborhood; e; e=e->next) {
		e->endPoint->visited = 1;
	}
	for (e=w->neighborhood; e; e=e->next) {
		/* if the endpoint is visited, then there is a triangle
		 * if there are more than two triangles, break */
		if (e->endPoint->visited) {
			++count;
		}
	}
	for (e=v->neighborhood; e; e=e->next) {
		e->endPoint->visited = 0;
	}
	return count;
}

// Assembly:
addq $0x8, %rdi
movq %rdi, %rax
movq (%rax), %rax
testq %rax, %rax
je 0x5ace
movq 0x18(%rax), %rcx
movl $0x1, 0x1c(%rcx)
addq $0x8, %rax
jmp 0x5ab5
xorl %eax, %eax
movq 0x8(%rsi), %rsi
testq %rsi, %rsi
je 0x5af2
movq 0x18(%rsi), %rcx
cmpl $0x1, 0x1c(%rcx)
sbbl $-0x1, %eax
jmp 0x5ad0
movq 0x18(%rdi), %rcx
andl $0x0, 0x1c(%rcx)
addq $0x8, %rdi
movq (%rdi), %rdi
testq %rdi, %rdi
jne 0x5ae6
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: removeEdge
void removeEdge(struct Vertex* v, struct Vertex* w, struct ListPool* p) {
	struct VertexList* idx, *tmp;

	if (v->neighborhood->endPoint == w) {
		tmp = v->neighborhood;
		v->neighborhood = v->neighborhood->next;
		dumpVertexList(p, tmp);
		return;
	}

	tmp = v->neighborhood;
	for (idx=tmp->next; idx; idx=idx->next, tmp=tmp->next) {
		if (idx->endPoint == w) {
			tmp->next = idx->next;
			dumpVertexList(p, idx);
			return;
		}
	}
}

// Assembly:
movq %rsi, %rax
movq 0x8(%rdi), %rsi
cmpq %rax, 0x18(%rsi)
je 0x5b5e
movq %rsi, %rcx
movq 0x8(%rsi), %rsi
testq %rsi, %rsi
je 0x5b68
cmpq %rax, 0x18(%rsi)
je 0x5b69
movq 0x8(%rcx), %rcx
jmp 0x5b49
movq 0x8(%rsi), %rax
movq %rax, 0x8(%rdi)
jmp 0x5b71
retq
movq 0x8(%rsi), %rax
movq %rax, 0x8(%rcx)
movq %rdx, %rdi
jmp 0x11364
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: snatchEdge
struct VertexList* snatchEdge(struct Vertex* v, struct Vertex* w) {
	struct VertexList* idx, *tmp;

	if (v->neighborhood->endPoint == w) {
		tmp = v->neighborhood;
		v->neighborhood = v->neighborhood->next;	
		tmp->next = NULL;
		return tmp;
	}

	tmp = v->neighborhood;
	for (idx=tmp->next; idx; idx=idx->next, tmp=tmp->next) {
		if (idx->endPoint == w) {
			tmp->next = idx->next;
			idx->next = NULL;
			return idx;
		}
	}
	return NULL;
}

// Assembly:
movq 0x8(%rdi), %rax
cmpq %rsi, 0x18(%rax)
je 0x5b9b
movq %rax, %rcx
movq 0x8(%rax), %rax
testq %rax, %rax
je 0x5ba5
cmpq %rsi, 0x18(%rax)
je 0x5ba8
movq 0x8(%rcx), %rcx
jmp 0x5b86
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rdi)
jmp 0x5bb0
xorl %eax, %eax
retq
movq 0x8(%rax), %rdx
movq %rdx, 0x8(%rcx)
andq $0x0, 0x8(%rax)
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: mergeGraphs
struct Graph* mergeGraphs(struct Graph* g, struct GraphPool* gp) {
	int n = 0;
	int m = 0;
	int i = 0;
	struct Graph* current;
	struct Graph* bigGraph = getGraph(gp);

	for (current=g; current!=NULL; current=current->next) {
		n += current->n;
		m += current->m;
	}
	setVertexNumber(bigGraph, n);
	bigGraph->m = m;

	for (current=g; current!=NULL; current=current->next) {
		int v;
		for (v=0; v<current->n; ++v, ++i) {
			bigGraph->vertices[i] = current->vertices[v];
			bigGraph->vertices[i]->number = i;
			current->vertices[v] = NULL;
		}
	}
	for (current=g; current!=NULL; ) {
		struct Graph* tmp = current;
		current = current->next;
		tmp->next = NULL;
		dumpGraph(gp, tmp);
	}
	return bigGraph;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x11619
movq %rax, %r15
xorl %ebp, %ebp
movq %r14, %rax
xorl %esi, %esi
testq %rax, %rax
je 0x5be6
addl (%rax), %esi
addl 0x4(%rax), %ebp
movq 0x18(%rax), %rax
jmp 0x5bd6
movq %r15, %rdi
callq 0x5c80
movl %ebp, 0x4(%r15)
xorl %eax, %eax
xorl %edx, %edx
movq %r14, %rcx
testq %rcx, %rcx
je 0x5c6f
movl (%rcx), %edi
movslq %edx, %rsi
testl %edi, %edi
cmovlel %eax, %edi
leaq (,%rsi,8), %r9
xorl %r8d, %r8d
cmpq %r8, %rdi
je 0x5c4c
movq 0x10(%rcx), %r10
movq (%r10,%r8,8), %r10
movq 0x10(%r15), %r11
addq %r9, %r11
movq %r10, (%r11,%r8,8)
movq 0x10(%r15), %r10
addq %r9, %r10
movq (%r10,%r8,8), %r10
leal (%rdx,%r8), %r11d
movl %r11d, 0x18(%r10)
movq 0x10(%rcx), %r10
andq $0x0, (%r10,%r8,8)
incq %r8
jmp 0x5c13
movq 0x18(%rcx), %rcx
addq %r8, %rsi
movq %rsi, %rdx
jmp 0x5bf9
movq 0x18(%r14), %r12
andq $0x0, 0x18(%r14)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1166e
movq %r12, %r14
testq %r14, %r14
jne 0x5c58
movq %r15, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: setVertexNumber
struct Vertex** setVertexNumber(struct Graph* g, int n) {
	int i;
	
	if (n<0) {
		printf("Error allocating memory for array of negative size %i\n", n);
		return NULL;
	}
	
	g->n = n;
	g->vertices = malloc(n * sizeof(struct Vertex*));

	for (i=0; i<n; ++i) {
		g->vertices[i] = NULL;
	}

	return g->vertices;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testl %esi, %esi
js 0x5cb7
movq %rdi, %rbx
movl %esi, (%rdi)
movl %esi, %r15d
leaq (,%r15,8), %rdi
callq 0x1180
movq %rax, 0x10(%rbx)
xorl %eax, %eax
movq 0x10(%rbx), %r14
cmpq %rax, %r15
je 0x5cc8
andq $0x0, (%r14,%rax,8)
incq %rax
jmp 0x5ca4
leaq 0x174e5(%rip), %rdi     # 0x1d1a3
xorl %r14d, %r14d
xorl %eax, %eax
callq 0x10b0
movq %r14, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: deleteEdge
struct VertexList* deleteEdge(struct Graph* g, int v, int w) {
	struct VertexList* e = g->vertices[v]->neighborhood;
	struct VertexList* f = e->next;

	if (e->endPoint->number == w) {
		g->vertices[v]->neighborhood = e->next;
		e->next = NULL;
		return e;
	}

	for ( ; f!=NULL; e=f, f=f->next) {
		if (f->endPoint->number == w) {
			e->next = f->next;
			f->next = NULL;
			return f;
		}
	}
	/* returns NULL, if there is no edge between v and w */
	return NULL;
}

// Assembly:
movq 0x10(%rdi), %rax
movslq %esi, %rcx
movq (%rax,%rcx,8), %rsi
movq 0x8(%rsi), %rax
movq 0x8(%rax), %rcx
movq 0x18(%rax), %rdi
cmpl %edx, 0x18(%rdi)
jne 0x5cf3
movq %rcx, 0x8(%rsi)
jmp 0x5d16
testq %rcx, %rcx
je 0x5d1c
movq %rcx, %rsi
movq %rax, %rdi
movq 0x8(%rcx), %rcx
movq 0x18(%rsi), %r8
movq %rsi, %rax
cmpl %edx, 0x18(%r8)
jne 0x5cf3
movq %rcx, 0x8(%rdi)
movq %rsi, %rax
andq $0x0, 0x8(%rax)
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: deleteEdgeBetweenVertices
void deleteEdgeBetweenVertices(struct Graph* g, struct VertexList* idx, struct GraphPool* gp) {
	struct VertexList* tmp = deleteEdge(g, idx->startPoint->number, idx->endPoint->number);
	dumpVertexList(gp->listPool, tmp);
	tmp = deleteEdge(g, idx->endPoint->number, idx->startPoint->number);
	if (tmp != NULL) {
		--(g->m);
	}
	dumpVertexList(gp->listPool, tmp);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movq 0x10(%rsi), %rax
movq 0x18(%rsi), %rcx
movl 0x18(%rax), %esi
movl 0x18(%rcx), %edx
callq 0x5cd1
movq 0x18(%rbx), %rdi
movq %rax, %rsi
callq 0x11364
movq 0x10(%r15), %rax
movq 0x18(%r15), %rcx
movl 0x18(%rcx), %esi
movl 0x18(%rax), %edx
movq %r14, %rdi
callq 0x5cd1
testq %rax, %rax
je 0x5d6b
decl 0x4(%r14)
movq 0x18(%rbx), %rdi
movq %rax, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x11364
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: cloneGraph
struct Graph* cloneGraph(struct Graph* g, struct GraphPool* gp) {
	struct Graph* copy = getGraph(gp);
	int i;

	copy->activity = g->activity;
	copy->m = g->m;
	copy->n = g->n;
	copy->number = g->number;

	copy->vertices = malloc(g->n * sizeof(struct Vertex*));

	/* copy vertices */
	for (i=0; i<g->n; ++i) {
		if (g->vertices[i]) {
			copy->vertices[i] = shallowCopyVertex(g->vertices[i], gp->vertexPool);
		}
	}

	/* copy edges */
	for (i=0; i<g->n; ++i) {
		if (g->vertices[i]) {
			struct VertexList* e;
			for (e=g->vertices[i]->neighborhood; e; e=e->next) {
				struct VertexList* tmp = getVertexList(gp->listPool);
				tmp->endPoint = copy->vertices[e->endPoint->number];
				tmp->startPoint = copy->vertices[e->startPoint->number];
				tmp->label = e->label;

				/* add the shallow copy to the new graph */
				tmp->next = copy->vertices[e->startPoint->number]->neighborhood;
				copy->vertices[e->startPoint->number]->neighborhood = tmp;
			}
		}
	}
	return copy;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x11619
movq %rax, %r15
movslq (%r14), %r12
movups (%r14), %xmm0
movups %xmm0, (%rax)
movq %r12, %rdi
shlq $0x3, %rdi
callq 0x1180
movq %rax, 0x10(%r15)
xorl %r13d, %r13d
movslq %r12d, %rax
cmpq %rax, %r13
jge 0x5e13
movq 0x10(%r14), %rax
movq (%rax,%r13,8), %rdi
testq %rdi, %rdi
je 0x5e0e
movq 0x10(%rbx), %rsi
callq 0x5a70
movq 0x10(%r15), %rcx
movq %rax, (%rcx,%r13,8)
movl (%r14), %r12d
incq %r13
jmp 0x5de5
xorl %r13d, %r13d
movslq %r12d, %rax
cmpq %rax, %r13
jge 0x5e8e
movq 0x10(%r14), %rax
movq (%rax,%r13,8), %rbp
testq %rbp, %rbp
jne 0x5e7d
jmp 0x5e89
movq 0x18(%rbx), %rdi
callq 0x11307
movq 0x10(%r15), %rcx
movq 0x18(%rbp), %rdx
movslq 0x18(%rdx), %rdx
movq (%rcx,%rdx,8), %rdx
movq %rdx, 0x18(%rax)
movq 0x10(%rbp), %rdx
movslq 0x18(%rdx), %rdx
movq (%rcx,%rdx,8), %rdx
movq %rdx, 0x10(%rax)
movq (%rbp), %rdx
movq %rdx, (%rax)
movq 0x10(%rbp), %rdx
movslq 0x18(%rdx), %rdx
movq (%rcx,%rdx,8), %rsi
movq 0x8(%rsi), %rsi
movq %rsi, 0x8(%rax)
movq (%rcx,%rdx,8), %rcx
movq %rax, 0x8(%rcx)
movq 0x8(%rbp), %rbp
testq %rbp, %rbp
jne 0x5e2d
movl (%r14), %r12d
incq %r13
jmp 0x5e16
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: isNeighbor
char isNeighbor(struct Graph* g, int v, int w) {
	struct VertexList* e;
	if ((g->vertices[v]) && (g->vertices[v]->neighborhood)) {
		for (e=g->vertices[v]->neighborhood; e!=NULL; e=e->next) {
			if (e->endPoint->number == w) {
				return 1;
			}
		}
	}
	/* if there is no vertex, or no neighborhood at all, or w does not occur
	as endpoint of any edge incident to v, return false */
	return 0;
}

// Assembly:
movq 0x10(%rdi), %rax
movslq %esi, %rcx
movq (%rax,%rcx,8), %rax
testq %rax, %rax
je 0x616c
movq 0x8(%rax), %rax
testq %rax, %rax
je 0x616c
testq %rax, %rax
je 0x616c
movq 0x18(%rax), %rcx
cmpl %edx, 0x18(%rcx)
je 0x616f
movq 0x8(%rax), %rax
jmp 0x6158
xorl %eax, %eax
retq
movb $0x1, %al
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: getGraphEdges
struct ShallowGraph* getGraphEdges(struct Graph *g, struct ShallowGraphPool* sgp) {
	int i;
	struct ShallowGraph* edges = getShallowGraph(sgp);
	for (i=0; i<g->n; ++i) {
		if (g->vertices[i]) {
			struct VertexList *idx;
			for (idx = g->vertices[i]->neighborhood; idx; idx = idx->next) {
				if (idx->endPoint->number > i) {
					pushEdge(edges, shallowCopyEdge(idx, sgp->listPool));
				}
			}
		}
	}

	return edges;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x117e9
movq %rax, %r15
xorl %r13d, %r13d
movslq (%r14), %rax
cmpq %rax, %r13
jge 0x61da
movq 0x10(%r14), %rax
movq (%rax,%r13,8), %r12
testq %r12, %r12
jne 0x61cb
jmp 0x61d5
movq 0x18(%r12), %rax
movslq 0x18(%rax), %rax
cmpq %rax, %r13
jge 0x61cb
movq 0x10(%rbx), %rsi
movq %r12, %rdi
callq 0x5a28
movq %r15, %rdi
movq %rax, %rsi
callq 0x61e7
movq 0x8(%r12), %r12
testq %r12, %r12
jne 0x61a6
incq %r13
jmp 0x618f
movq %r15, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: pushEdge
void pushEdge(struct ShallowGraph *g, struct VertexList *e) {

	g->edges = push(g->edges, e);
	if (g->lastEdge == NULL) {
		g->lastEdge = e;
	}
	++g->m;
}

// Assembly:
movq (%rdi), %rax
movq %rax, 0x8(%rsi)
movq %rsi, (%rdi)
cmpq $0x0, 0x8(%rdi)
jne 0x61fc
movq %rsi, 0x8(%rdi)
incl 0x10(%rdi)
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: addEdgeBetweenVertices
void addEdgeBetweenVertices(int v, int w, char* label, struct Graph* g, struct GraphPool* gp) {
	struct VertexList* e = getVertexList(gp->listPool);
	e->startPoint = g->vertices[v];
	e->endPoint = g->vertices[w];
	e->label = label;

	addEdge(g->vertices[v], e);
	addEdge(g->vertices[w], inverseEdge(e, gp->listPool));

	++(g->m);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %r8, %r14
movq %rcx, %rbx
movq %rdx, %r15
movl %esi, %ebp
movl %edi, %r12d
movq 0x18(%r8), %rdi
callq 0x11307
movq 0x10(%rbx), %rcx
movslq %r12d, %rdx
movq (%rcx,%rdx,8), %rsi
movq %rsi, 0x10(%rax)
movslq %ebp, %rsi
movq (%rcx,%rsi,8), %rdi
movq %rdi, 0x18(%rax)
movq %r15, (%rax)
movq (%rcx,%rdx,8), %rdx
movq 0x8(%rdx), %rdi
movq %rdi, 0x8(%rax)
movq %rax, 0x8(%rdx)
movq (%rcx,%rsi,8), %r15
movq 0x18(%r14), %rsi
movq %rax, %rdi
callq 0x5a44
movq 0x8(%r15), %rcx
movq %rcx, 0x8(%rax)
movq %rax, 0x8(%r15)
incl 0x4(%rbx)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: emptyGraph
struct Graph* emptyGraph(struct Graph* g, struct GraphPool* gp) {
	struct Graph* empty = getGraph(gp);
	int v;
	setVertexNumber(empty, g->n);

	for (v=0; v<g->n; ++v) {
		empty->vertices[v] = shallowCopyVertex(g->vertices[v], gp->vertexPool);
	}
	return empty;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x11619
movq %rax, %r15
movl (%r14), %esi
movq %rax, %rdi
callq 0x5c80
xorl %r12d, %r12d
movslq (%r14), %rax
cmpq %rax, %r12
jge 0x62ff
movq 0x10(%r14), %rax
movq (%rax,%r12,8), %rdi
movq 0x10(%rbx), %rsi
callq 0x5a70
movq 0x10(%r15), %rcx
movq %rax, (%rcx,%r12,8)
incq %r12
jmp 0x62d9
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: createGraph
struct Graph* createGraph(int n, struct GraphPool* gp) {
	struct Graph* empty = getGraph(gp);
	int v;
	setVertexNumber(empty, n);

	for (v=0; v<n; ++v) {
		empty->vertices[v] = getVertex(gp->vertexPool);
		empty->vertices[v]->number = v;
	}
	return empty;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movl %edi, %r14d
movq %rsi, %rdi
callq 0x11619
movq %rax, %r15
movq %rax, %rdi
movl %r14d, %esi
callq 0x5c80
xorl %r12d, %r12d
testl %r14d, %r14d
cmovlel %r12d, %r14d
cmpq %r12, %r14
je 0x6363
movq 0x10(%rbx), %rdi
callq 0x114a5
movq 0x10(%r15), %rcx
movq %rax, (%rcx,%r12,8)
movq 0x10(%r15), %rax
movq (%rax,%r12,8), %rax
movl %r12d, 0x18(%rax)
incq %r12
jmp 0x633c
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: getMaxDegree
int getMaxDegree(struct Graph* g) {
	int max = -1;
	int v;
	for (v=0; v<g->n; ++v) {
		if (g->vertices[v] != NULL) {
			int deg = degree(g->vertices[v]);
			if (max < deg) {
				max = deg;
			}
		}
	}
	return max;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl (%rdi), %r14d
xorl %r15d, %r15d
testl %r14d, %r14d
cmovlel %r15d, %r14d
pushq $-0x1
popq %rbp
cmpq %r15, %r14
je 0x63ad
movq 0x10(%rbx), %rax
movq (%rax,%r15,8), %rdi
testq %rdi, %rdi
je 0x63a8
callq 0x5a8a
cmpl %eax, %ebp
cmovlel %eax, %ebp
incq %r15
jmp 0x638c
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: getMinDegree
int getMinDegree(struct Graph* g) {
	int min = INT_MAX;
	int v;
	for (v=0; v<g->n; ++v) {
		if (g->vertices[v] != NULL) {
			int deg = degree(g->vertices[v]);
			if (min > deg) {
				min = deg;
			}
		}
	}
	return min;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl (%rdi), %r14d
xorl %r15d, %r15d
testl %r14d, %r14d
cmovlel %r15d, %r14d
movl $0x7fffffff, %ebp       # imm = 0x7FFFFFFF
cmpq %r15, %r14
je 0x63f7
movq 0x10(%rbx), %rax
movq (%rax,%r15,8), %rdi
testq %rdi, %rdi
je 0x63f2
callq 0x5a8a
cmpl %eax, %ebp
cmovgel %eax, %ebp
incq %r15
jmp 0x63d6
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: popGraph
struct Graph* popGraph(struct Graph** list) {
	struct Graph* head = *list;
	if (head != NULL) {
		*list = head->next;
		head->next = NULL;
	}
	return head;
}

// Assembly:
movq (%rdi), %rax
testq %rax, %rax
je 0x6418
movq 0x18(%rax), %rcx
movq %rcx, (%rdi)
andq $0x0, 0x18(%rax)
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: canonicalizeShallowGraphCached
void canonicalizeShallowGraphCached(struct ShallowGraph* g, struct VertexList** edgePointers) {
	int i=0;
	for (struct VertexList* e=g->edges; e!=NULL; e=e->next) {
		edgePointers[i] = e;
		++i;
	}

	qsort(edgePointers, sizeof(struct VertexList*), g->m, edgeCmp);

	for (i=0; i<g->m-1; ++i) {
		edgePointers[i]->next = edgePointers[i+1];
	}
	edgePointers[g->m-1]->next = NULL;
	g->edges = edgePointers[0];

}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rax
movq %rdi, %rcx
movq (%rcx), %rcx
testq %rcx, %rcx
je 0x643e
movq %rcx, (%rax)
addq $0x8, %rcx
addq $0x8, %rax
jmp 0x6429
movslq 0x10(%rbx), %rdx
leaq 0x48(%rip), %rcx        # 0x6491
pushq $0x8
popq %rsi
movq %r14, %rdi
callq 0x1080
movslq 0x10(%rbx), %rax
leal -0x1(%rax), %ecx
xorl %edx, %edx
testl %ecx, %ecx
cmovlel %edx, %ecx
cmpq %rdx, %rcx
je 0x6479
movq (%r14,%rdx,8), %rsi
movq 0x8(%r14,%rdx,8), %rdi
incq %rdx
movq %rdi, 0x8(%rsi)
jmp 0x6462
movq -0x8(%r14,%rax,8), %rax
andq $0x0, 0x8(%rax)
movq (%r14), %rax
movq %rax, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: rebaseShallowGraphs
void rebaseShallowGraphs(struct ShallowGraph* list, struct Graph* newBase) {
	struct ShallowGraph* idx;
	struct VertexList* e;

	for (idx=list; idx!=NULL; idx=idx->next) {
		for (e=idx->edges; e!=NULL; e=e->next) {
			e->startPoint = newBase->vertices[e->startPoint->number];
			e->endPoint = newBase->vertices[e->endPoint->number];
		}
	}
}

// Assembly:
testq %rdi, %rdi
je 0x6528
movq %rdi, %rax
movq (%rax), %rax
testq %rax, %rax
je 0x6522
movq 0x10(%rsi), %rcx
movq 0x10(%rax), %rdx
movq 0x18(%rax), %r8
movslq 0x18(%rdx), %rdx
movq (%rcx,%rdx,8), %rdx
movq %rdx, 0x10(%rax)
movslq 0x18(%r8), %rdx
movq (%rcx,%rdx,8), %rcx
movq %rcx, 0x18(%rax)
addq $0x8, %rax
jmp 0x64f0
movq 0x18(%rdi), %rdi
jmp 0x64e8
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: rebaseShallowGraphsOnLowPoints
void rebaseShallowGraphsOnLowPoints(struct ShallowGraph* list, struct Graph* newBase) {
	struct ShallowGraph* idx;
	struct VertexList* e;

	for (idx=list; idx!=NULL; idx=idx->next) {
		for (e=idx->edges; e!=NULL; e=e->next) {
			e->startPoint = newBase->vertices[e->startPoint->lowPoint];
			e->endPoint = newBase->vertices[e->endPoint->lowPoint];
		}
	}
}

// Assembly:
testq %rdi, %rdi
je 0x6569
movq %rdi, %rax
movq (%rax), %rax
testq %rax, %rax
je 0x6563
movq 0x10(%rsi), %rcx
movq 0x10(%rax), %rdx
movq 0x18(%rax), %r8
movslq 0x20(%rdx), %rdx
movq (%rcx,%rdx,8), %rdx
movq %rdx, 0x10(%rax)
movslq 0x20(%r8), %rdx
movq (%rcx,%rdx,8), %rcx
movq %rcx, 0x18(%rax)
addq $0x8, %rax
jmp 0x6531
movq 0x18(%rdi), %rdi
jmp 0x6529
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: addComponent
struct ShallowGraph* addComponent(struct ShallowGraph* g, struct ShallowGraph* h) {
	/* if g and h are both cycles, concatenate them */
	if (g && h) {	
		struct ShallowGraph* tmp = g->prev;
	
		g->prev->next = h;
		g->prev = h->prev;
		h->prev->next = g;
		h->prev = tmp;
		return g;
	} else {
		/* if one of the two inputs is NULL, return the other without change */
		return (g) ? g : h;
	}
}

// Assembly:
movq %rdi, %rax
testq %rdi, %rdi
sete %cl
testq %rsi, %rsi
sete %dl
orb %cl, %dl
jne 0x6596
movq 0x20(%rax), %rcx
movq %rsi, 0x18(%rcx)
movq 0x20(%rsi), %rdx
movq %rdx, 0x20(%rax)
movq %rax, 0x18(%rdx)
movq %rcx, 0x20(%rsi)
retq
testq %rax, %rax
cmoveq %rsi, %rax
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: cloneShallowGraph
struct ShallowGraph* cloneShallowGraph(struct ShallowGraph* g, struct ShallowGraphPool* sgp) {
	struct ShallowGraph* copy = getShallowGraph(sgp);
	struct VertexList* edgeList = NULL;
	struct VertexList* e;
	int m = 0;
	for (e=g->edges; e!=NULL; e=e->next) {
		if (edgeList == NULL) {
			edgeList = shallowCopyEdge(e, sgp->listPool);
			copy->edges = edgeList;
		} else {
			edgeList->next = shallowCopyEdge(e, sgp->listPool);
			edgeList = edgeList->next;
		}
		++m;
	}
	copy->lastEdge = edgeList;
	copy->m = m;

	return copy;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x117e9
movq %rax, %r15
xorl %r12d, %r12d
xorl %ebp, %ebp
movq (%r14), %r14
testq %r14, %r14
je 0x65ea
movq 0x10(%rbx), %rsi
movq %r14, %rdi
callq 0x5a28
leaq 0x8(%r12), %rcx
testq %r12, %r12
cmoveq %r15, %rcx
movq %rax, (%rcx)
incl %ebp
addq $0x8, %r14
movq %rax, %r12
jmp 0x65bc
movq %r12, 0x8(%r15)
movl %ebp, 0x10(%r15)
movq %r15, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: appendEdge
void appendEdge(struct ShallowGraph *g, struct VertexList *e) {

	if (g->lastEdge == NULL) {
		g->edges = push(g->edges, e);
		g->lastEdge = e;
	} else {
		g->lastEdge->next = e;
		e->next = NULL;
		g->lastEdge = e;
	}
	++g->m;
}

// Assembly:
movq 0x8(%rdi), %rax
testq %rax, %rax
je 0x6631
addq $0x8, %rax
xorl %ecx, %ecx
jmp 0x6637
movq (%rdi), %rcx
movq %rdi, %rax
movq %rsi, (%rax)
movq %rcx, 0x8(%rsi)
movq %rsi, 0x8(%rdi)
incl 0x10(%rdi)
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graph.c
// Function: inverseCycle
struct ShallowGraph* inverseCycle(struct ShallowGraph* cycle, struct ShallowGraphPool *sgp) {
	struct VertexList *index;
	struct ShallowGraph* inverse = getShallowGraph(sgp);


	for (index=cycle->edges; index; index=index->next) {
		struct VertexList* e = inverseEdge(index, sgp->listPool);
		pushEdge(inverse, e);

		/* set lastEdge pointer to the correct value */
		if (index == cycle->edges) {
			inverse->lastEdge = e;
		}
	}

	return inverse;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x117e9
movq %rax, %r15
movq %r14, %r12
movq (%r12), %r12
testq %r12, %r12
je 0x66bb
movq 0x10(%rbx), %rsi
movq %r12, %rdi
callq 0x5a44
movq %rax, %r13
movq %r15, %rdi
movq %rax, %rsi
callq 0x61e7
cmpq (%r14), %r12
jne 0x66b5
movq %r13, 0x8(%r15)
addq $0x8, %r12
jmp 0x6689
movq %r15, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graphPrinting.c
// Function: printGraphAidsFormat
void printGraphAidsFormat(struct Graph* g, FILE* out) {
	int i;
	// print header line
	fprintf(out, "# %i %i %i %i\n", g->number, g->activity, g->n, g->m);

	// print vertex labels
	for (i=0; i<g->n; ++i) {
		fprintf(out, "%s ", g->vertices[i]->label);
	}
	fputc('\n', out);

	// print edges
	for (i=0; i<g->n; ++i) {
		struct VertexList* e;
		for (e=g->vertices[i]->neighborhood; e!=NULL; e=e->next) {
			if (e->startPoint->number < e->endPoint->number) {
				fprintf(out, "%i %i %s ", e->startPoint->number + 1, e->endPoint->number + 1, e->label);
			}
		}
	}
	fputc('\n', out);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movl 0x8(%rdi), %edx
movl 0xc(%rdi), %ecx
movl (%rdi), %r8d
movl 0x4(%rdi), %r9d
leaq 0x16aef(%rip), %rsi     # 0x1d1da
movq %rbx, %rdi
xorl %eax, %eax
callq 0x1150
leaq 0x16af3(%rip), %r15     # 0x1d1ef
xorl %r12d, %r12d
movslq (%r14), %rax
cmpq %rax, %r12
jge 0x6724
movq 0x10(%r14), %rax
movq (%rax,%r12,8), %rax
movq (%rax), %rdx
movq %rbx, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0x1150
incq %r12
jmp 0x66ff
pushq $0xa
popq %rdi
movq %rbx, %rsi
callq 0x1100
leaq 0x16ab3(%rip), %r15     # 0x1d1e9
xorl %r12d, %r12d
movslq (%r14), %rax
cmpq %rax, %r12
jge 0x6780
movq 0x10(%r14), %rax
movq (%rax,%r12,8), %r13
movq 0x8(%r13), %r13
testq %r13, %r13
je 0x677b
movq 0x10(%r13), %rax
movq 0x18(%r13), %rcx
movl 0x18(%rax), %edx
movl 0x18(%rcx), %ecx
cmpl %ecx, %edx
jge 0x6749
incl %edx
incl %ecx
movq (%r13), %r8
movq %rbx, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0x1150
jmp 0x6749
incq %r12
jmp 0x6739
pushq $0xa
popq %rdi
movq %rbx, %rsi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x1100
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graphPrinting.c
// Function: printShallowGraph
void printShallowGraph(struct ShallowGraph* g) {
	
	struct ShallowGraph* index = g;
	int i = 0;
	do {
		if (index) {
			printf("Graph %i has %i edges:\n", i, index->m);
			printVertexList(index->edges);
			printf("\n");
			index = index->next;
			++i;
		} else {
			/* if index is NULL, the input pointed to a list and not to a cycle */
			break;
		}
	} while (index != g);
	fflush(stdout);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
testq %rdi, %rdi
je 0x67e8
movq %rdi, %rbx
leaq 0x16a48(%rip), %r14     # 0x1d1f3
pushq $0xa
popq %rbp
movq %rdi, %r12
xorl %r15d, %r15d
movl 0x10(%r12), %edx
movq %r14, %rdi
movl %r15d, %esi
xorl %eax, %eax
callq 0x10b0
movq (%r12), %rdi
callq 0x67ff
movl %ebp, %edi
callq 0x1040
movq 0x18(%r12), %r12
cmpq %rbx, %r12
je 0x67e8
incl %r15d
testq %r12, %r12
jne 0x67b4
movq 0x237d9(%rip), %rax     # 0x29fc8
movq (%rax), %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x1190
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graphPrinting.c
// Function: printVertexList
void printVertexList(struct VertexList *f) {
	struct VertexList* e;
	for (e=f; e; e=e->next) {
		printf("(%i, %i)", e->startPoint->number, e->endPoint->number);
		fflush(stdout);
		printf(" %s\n", e->label);
	}
	fflush(stdout);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x16b11(%rip), %r14     # 0x1d322
movq 0x237b0(%rip), %r12     # 0x29fc8
leaq 0x17766(%rip), %r15     # 0x1df85
testq %rbx, %rbx
je 0x6858
movq 0x10(%rbx), %rax
movq 0x18(%rbx), %rcx
movl 0x18(%rax), %esi
movl 0x18(%rcx), %edx
movq %r14, %rdi
xorl %eax, %eax
callq 0x10b0
movq (%r12), %rdi
callq 0x1190
movq (%rbx), %rsi
movq %r15, %rdi
xorl %eax, %eax
callq 0x10b0
movq 0x8(%rbx), %rbx
jmp 0x681f
movq (%r12), %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x1190
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graphPrinting.c
// Function: printLabelledShallowGraph
void printLabelledShallowGraph(struct ShallowGraph* g) {
	
	struct ShallowGraph* index = g;
	int i = 0;
	do {
		if (index) {
			struct VertexList* e;
			printf("Graph %i has %i edges:\n", i, index->m);
			for (e=index->edges; e!=NULL; e=e->next) {
				printf("(%s)%s(%s)\n",e->startPoint->label, e->label, e->endPoint->label);
			}
			printf("\n");
			index = index->next;
			++i;
		} else {
			/* if index is NULL, the input pointed to a list and not to a cycle */
			break;
		}
	} while (index != g);
	fflush(stdout);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0x68e9
movq %rdi, %r14
pushq $0xa
popq %rbp
leaq 0x16982(%rip), %r15     # 0x1d20b
movq %rdi, %rbx
xorl %r12d, %r12d
movl 0x10(%rbx), %edx
leaq 0x1695a(%rip), %rdi     # 0x1d1f3
movl %r12d, %esi
xorl %eax, %eax
callq 0x10b0
movq %rbx, %r13
movq (%r13), %r13
testq %r13, %r13
je 0x68d1
movq (%r13), %rdx
movq 0x10(%r13), %rax
movq (%rax), %rsi
movq 0x18(%r13), %rax
movq (%rax), %rcx
movq %r15, %rdi
xorl %eax, %eax
callq 0x10b0
addq $0x8, %r13
jmp 0x68a6
movl %ebp, %edi
callq 0x1040
movq 0x18(%rbx), %rbx
cmpq %r14, %rbx
je 0x68e9
incl %r12d
testq %rbx, %rbx
jne 0x688f
movq 0x236d8(%rip), %rax     # 0x29fc8
movq (%rax), %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x1190
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graphPrinting.c
// Function: printShallowGraphCount
int printShallowGraphCount(struct ShallowGraph* g, char silent) {

	struct ShallowGraph* index = g;
	int i = 0;
	do {
		if (index) {
			index = index->next;
			++i;
		} else {
			/* if index is NULL, the input pointed to a list and not to a cycle */
			break;
		}
	} while (index != g);

	if (!silent) {
		printf("Result contains %i structures\n", i);
		fflush(stdout);
	}
	
	return i;

}

// Assembly:
pushq %rbx
xorl %ebx, %ebx
testq %rdi, %rdi
je 0x6921
movq %rdi, %rax
movq 0x18(%rax), %rax
incl %ebx
cmpq %rdi, %rax
je 0x6921
testq %rax, %rax
jne 0x6911
testb %sil, %sil
jne 0x6945
leaq 0x168ea(%rip), %rdi     # 0x1d217
movl %ebx, %esi
xorl %eax, %eax
callq 0x10b0
movq 0x2368b(%rip), %rax     # 0x29fc8
movq (%rax), %rdi
callq 0x1190
movl %ebx, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graphPrinting.c
// Function: printGraph
void printGraph(struct Graph* g) {
	
	struct Graph* index = g;
	int i= 0,j;

	do {
		if (index) {
			printf("Graph %i has id %i, %i vertices, and %i edges:\n", i, index->number, index->n, index->m);
			for (j=0; j<index->n; ++j) {
				if (index->vertices[j]) {
					printf("Vertex %i has label %s and the following neighbors:\n", index->vertices[j]->number, index->vertices[j]->label);
					printVertexList(index->vertices[j]->neighborhood);
				} else {
					printf("Vertex %i is not used by the current (induced) graph\n", j);
				}
				
			}
			printf("\n");
			index = index->next;
			++i;
		} else {
			/* if index is NULL, the input pointed to a list and not to a cycle */
			break;
		}
	} while (index != g);
	fflush(stdout);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0x69f4
movq %rdi, %rbp
leaq 0x16934(%rip), %r15     # 0x1d29b
leaq 0x168f8(%rip), %r12     # 0x1d266
movq %rdi, %rbx
xorl %r13d, %r13d
movl 0x8(%rbx), %edx
movl (%rbx), %ecx
movl 0x4(%rbx), %r8d
leaq 0x168b2(%rip), %rdi     # 0x1d236
movl %r13d, %esi
xorl %eax, %eax
callq 0x10b0
xorl %r14d, %r14d
movslq (%rbx), %rax
cmpq %rax, %r14
jge 0x69db
movq 0x10(%rbx), %rax
movq (%rax,%r14,8), %rax
testq %rax, %rax
je 0x69c9
movl 0x18(%rax), %esi
movq (%rax), %rdx
movq %r12, %rdi
xorl %eax, %eax
callq 0x10b0
movq 0x10(%rbx), %rax
movq (%rax,%r14,8), %rax
movq 0x8(%rax), %rdi
callq 0x67ff
jmp 0x69d6
movq %r15, %rdi
movl %r14d, %esi
xorl %eax, %eax
callq 0x10b0
incq %r14
jmp 0x6991
pushq $0xa
popq %rdi
callq 0x1040
movq 0x18(%rbx), %rbx
cmpq %rbp, %rbx
je 0x69f4
incl %r13d
testq %rbx, %rbx
jne 0x6974
movq 0x235cd(%rip), %rax     # 0x29fc8
movq (%rax), %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x1190
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graphPrinting.c
// Function: printGraphEdges
void printGraphEdges(struct Graph *g) {
	int i;
	printf("Graph has %i vertices and %i edges:\n", g->n, g->m);
	for (i=0; i<g->n; ++i) {
		if (g->vertices[i]) {
			struct VertexList *idx;
			for (idx = g->vertices[i]->neighborhood; idx; idx = idx->next) {
				if (idx->endPoint->number > i) {
					printf("(%i, %i) %s d: (%i, %i) visited: (%i,  %i)\n", idx->startPoint->number, idx->endPoint->number, idx->label, idx->startPoint->d, idx->endPoint->d, idx->startPoint->visited, idx->endPoint->visited);
				}
			}
		}
	}
	fflush(stdout);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl (%rdi), %esi
movl 0x4(%rdi), %edx
leaq 0x168a9(%rip), %rdi     # 0x1d2d1
xorl %eax, %eax
callq 0x10b0
leaq 0x168c0(%rip), %r14     # 0x1d2f6
xorl %r15d, %r15d
movslq (%rbx), %rax
cmpq %rax, %r15
jge 0x6a99
movq 0x10(%rbx), %rax
movq (%rax,%r15,8), %r12
testq %r12, %r12
jne 0x6a8a
jmp 0x6a94
movq 0x18(%r12), %rax
movslq 0x18(%rax), %rdx
cmpq %rdx, %r15
jge 0x6a8a
movq (%r12), %rcx
movq 0x10(%r12), %rdi
movl 0x28(%rdi), %r8d
movl 0x1c(%rax), %r10d
movl 0x28(%rax), %r9d
movl 0x18(%rdi), %esi
movl 0x1c(%rdi), %r11d
movq %r14, %rdi
xorl %eax, %eax
pushq %r10
pushq %r11
callq 0x10b0
popq %rcx
popq %rdx
movq 0x8(%r12), %r12
testq %r12, %r12
jne 0x6a50
incq %r15
jmp 0x6a39
movq 0x23528(%rip), %rax     # 0x29fc8
movq (%rax), %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x1190
// File: /workspace/github_c_makefile_star2_O2/pwelke[P]GraphMiningTools/graphPrinting.c
// Function: printGraphEdgesOfTwoGraphs
void printGraphEdgesOfTwoGraphs(char* name, struct Graph *g, struct Graph* h) {
	int i;
	printf("%s 1 has %i vertices and %i edges:\n", name, g->n, g->m);
	printf("%s 2 has %i vertices and %i edges:\n", name, h->n, h->m);
	for (i=0; i<g->n; ++i) {
		printf("%i: ", i);
		if (g->vertices[i]) {
			struct VertexList *idx;
			for (idx = g->vertices[i]->neighborhood; idx; idx = idx->next) {
				printf("%i ", idx->endPoint->number);	
			}
		}
		printf("\n%i: ", i);
		if (h->vertices[i]) {
			struct VertexList *idx;
			for (idx = h->vertices[i]->neighborhood; idx; idx = idx->next) {
				printf("%i ", idx->endPoint->number);	
			}
		}
		printf("\n\n");
	}
	fflush(stdout);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movl (%rsi), %edx
movl 0x4(%rsi), %ecx
leaq 0x16817(%rip), %rdi     # 0x1d32b
movq %r15, %rsi
xorl %eax, %eax
callq 0x10b0
movl (%rbx), %edx
movl 0x4(%rbx), %ecx
leaq 0x16825(%rip), %rdi     # 0x1d34f
movq %r15, %rsi
xorl %eax, %eax
callq 0x10b0
leaq 0x16d10(%rip), %r13     # 0x1d84b
leaq 0x17437(%rip), %rbp     # 0x1df79
xorl %r15d, %r15d
movslq (%r14), %rax
cmpq %rax, %r15
jge 0x6bd9
leaq 0x1681c(%rip), %rdi     # 0x1d374
movl %r15d, %esi
xorl %eax, %eax
callq 0x10b0
movq 0x10(%r14), %rax
movq (%rax,%r15,8), %r12
testq %r12, %r12
jne 0x6b83
jmp 0x6b8d
movq 0x18(%r12), %rax
movl 0x18(%rax), %esi
movq %rbp, %rdi
xorl %eax, %eax
callq 0x10b0
movq 0x8(%r12), %r12
testq %r12, %r12
jne 0x6b71
leaq 0x167df(%rip), %rdi     # 0x1d373
movl %r15d, %esi
xorl %eax, %eax
callq 0x10b0
movq 0x10(%rbx), %rax
movq (%rax,%r15,8), %r12
testq %r12, %r12
jne 0x6bbf
jmp 0x6bc9
movq 0x18(%r12), %rax
movl 0x18(%rax), %esi
movq %rbp, %rdi
xorl %eax, %eax
callq 0x10b0
movq 0x8(%r12), %r12
testq %r12, %r12
jne 0x6bad
movq %r13, %rdi
callq 0x1070
incq %r15
jmp 0x6b45
movq 0x233e8(%rip), %rax     # 0x29fc8
movq (%rax), %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x1190