// File: /workspace/github_c_makefile_star2_O0/lucvoo[P]sparse-dev/graph.c
// Function: graph_ep
static void graph_ep(struct entrypoint *ep)
{
	struct basic_block *bb;
	struct instruction *insn;

	const char *fname, *sname;

	fname = show_ident(ep->name->ident);
	sname = stream_name(ep->entry->bb->pos.stream);

	printf("subgraph cluster%p {\n"
	       "    color=blue;\n"
	       "    label=<<TABLE BORDER=\"0\" CELLBORDER=\"0\">\n"
	       "             <TR><TD>%s</TD></TR>\n"
	       "             <TR><TD><FONT POINT-SIZE=\"21\">%s()</FONT></TD></TR>\n"
	       "           </TABLE>>;\n"
	       "    file=\"%s\";\n"
	       "    fun=\"%s\";\n"
	       "    ep=bb%p;\n",
	       ep, sname, fname, sname, fname, ep->entry->bb);

	FOR_EACH_PTR(ep->bbs, bb) {
		struct basic_block *child;
		int ret = 0;
		const char * s = ", ls=\"[";

		/* Node for the bb */
		printf("    bb%p [shape=ellipse,label=%d,line=%d,col=%d",
		       bb, bb->pos.line, bb->pos.line, bb->pos.pos);


		/* List loads and stores */
		FOR_EACH_PTR(bb->insns, insn) {
			if (!insn->bb)
				continue;
			switch(insn->opcode) {
			case OP_STORE:
				if (insn->src->type == PSEUDO_SYM) {
				  printf("%s store(%s)", s, show_ident(insn->src->sym->ident));
				  s = ",";
				}
				break;

			case OP_LOAD:
				if (insn->src->type == PSEUDO_SYM) {
				  printf("%s load(%s)", s, show_ident(insn->src->sym->ident));
				  s = ",";
				}
				break;

			case OP_RET:
				ret = 1;
				break;

			}
		} END_FOR_EACH_PTR(insn);
		if (s[1] == 0)
			printf("]\"");
		if (ret)
			printf(",op=ret");
		printf("];\n");

		/* Edges between bbs; lower weight for upward edges */
		FOR_EACH_PTR(bb->children, child) {
			printf("    bb%p -> bb%p [op=br, %s];\n", bb, child,
			       (bb->pos.line > child->pos.line) ? "weight=5" : "weight=10");
		} END_FOR_EACH_PTR(child);
	} END_FOR_EACH_PTR(bb);

	printf("}\n");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rdi
callq 0x44b40
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq 0x28(%rax), %rax
movq 0x8(%rax), %rax
movq (%rax), %rax
shrq $0x6, %rax
andq $0x3fff, %rax           # imm = 0x3FFF
movl %eax, %edi
callq 0x44a20
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rsi
movq -0x28(%rbp), %rdx
movq -0x20(%rbp), %rcx
movq -0x28(%rbp), %r8
movq -0x20(%rbp), %r9
movq -0x8(%rbp), %rax
movq 0x28(%rax), %rax
movq 0x8(%rax), %rax
leaq 0x5079f(%rip), %rdi     # 0x6201d
movq %rax, (%rsp)
movb $0x0, %al
callq 0x110f0
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x40(%rbp)
cmpq $0x0, -0x30(%rbp)
jne 0x118b1
jmp 0x11c85
jmp 0x118b3
movl $0x0, -0x44(%rbp)
movl -0x44(%rbp), %eax
movq -0x38(%rbp), %rcx
movw (%rcx), %cx
shlw $0x8, %cx
sarw $0x8, %cx
movswl %cx, %ecx
cmpl %ecx, %eax
jge 0x11c6d
movq -0x38(%rbp), %rax
movslq -0x44(%rbp), %rcx
movq 0x18(%rax,%rcx,8), %rax
movq %rax, -0x10(%rbp)
movq -0x38(%rbp), %rax
movw (%rax), %ax
sarw $0x8, %ax
cwtl
cmpl $0x0, %eax
je 0x11905
cmpq $0x0, -0x10(%rbp)
jne 0x11905
jmp 0x11c5f
movl $0x0, -0x54(%rbp)
leaq 0x50800(%rip), %rax     # 0x62113
movq %rax, -0x60(%rbp)
movq -0x10(%rbp), %rsi
movq -0x10(%rbp), %rax
movq (%rax), %rax
shrq $0x20, %rax
andq $0x7fffffff, %rax       # imm = 0x7FFFFFFF
movl %eax, %edx
movq -0x10(%rbp), %rax
movq (%rax), %rax
shrq $0x20, %rax
andq $0x7fffffff, %rax       # imm = 0x7FFFFFFF
movl %eax, %ecx
movq -0x10(%rbp), %rax
movq (%rax), %rax
shrq $0x16, %rax
andq $0x3ff, %rax            # imm = 0x3FF
movl %eax, %r8d
leaq 0x507bf(%rip), %rdi     # 0x6211b
movb $0x0, %al
callq 0x110f0
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rax
movq %rax, -0x68(%rbp)
movq -0x68(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x68(%rbp), %rax
movq %rax, -0x78(%rbp)
cmpq $0x0, -0x68(%rbp)
jne 0x1198b
jmp 0x11afc
jmp 0x1198d
movl $0x0, -0x7c(%rbp)
movl -0x7c(%rbp), %eax
movq -0x70(%rbp), %rcx
movw (%rcx), %cx
shlw $0x8, %cx
sarw $0x8, %cx
movswl %cx, %ecx
cmpl %ecx, %eax
jge 0x11ae4
movq -0x70(%rbp), %rax
movslq -0x7c(%rbp), %rcx
movq 0x18(%rax,%rcx,8), %rax
movq %rax, -0x18(%rbp)
movq -0x70(%rbp), %rax
movw (%rax), %ax
sarw $0x8, %ax
cwtl
cmpl $0x0, %eax
je 0x119df
cmpq $0x0, -0x18(%rbp)
jne 0x119df
jmp 0x11ad6
movq -0x18(%rbp), %rax
cmpq $0x0, 0x8(%rax)
jne 0x119ef
jmp 0x11ad6
movq -0x18(%rbp), %rax
movl (%rax), %eax
andl $0x7f, %eax
movl %eax, -0xa0(%rbp)
subl $0x2, %eax
je 0x11acd
jmp 0x11a09
movl -0xa0(%rbp), %eax
subl $0x43, %eax
je 0x11a7a
jmp 0x11a16
movl -0xa0(%rbp), %eax
subl $0x44, %eax
jne 0x11ad4
jmp 0x11a27
movq -0x18(%rbp), %rax
movq 0x30(%rax), %rax
cmpl $0x5, 0x4(%rax)
jne 0x11a78
movq -0x60(%rbp), %rax
movq %rax, -0xa8(%rbp)
movq -0x18(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x18(%rax), %rax
movq 0x18(%rax), %rdi
callq 0x44b40
movq -0xa8(%rbp), %rsi
movq %rax, %rdx
leaq 0x506e5(%rip), %rdi     # 0x6214b
movb $0x0, %al
callq 0x110f0
leaq 0x506e4(%rip), %rax     # 0x62158
movq %rax, -0x60(%rbp)
jmp 0x11ad4
movq -0x18(%rbp), %rax
movq 0x30(%rax), %rax
cmpl $0x5, 0x4(%rax)
jne 0x11acb
movq -0x60(%rbp), %rax
movq %rax, -0xb0(%rbp)
movq -0x18(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x18(%rax), %rax
movq 0x18(%rax), %rdi
callq 0x44b40
movq -0xb0(%rbp), %rsi
movq %rax, %rdx
leaq 0x506a1(%rip), %rdi     # 0x6215a
movb $0x0, %al
callq 0x110f0
leaq 0x50691(%rip), %rax     # 0x62158
movq %rax, -0x60(%rbp)
jmp 0x11ad4
movl $0x1, -0x54(%rbp)
jmp 0x11ad6
movl -0x7c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x7c(%rbp)
jmp 0x11994
jmp 0x11ae6
movq -0x70(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x70(%rbp)
cmpq -0x68(%rbp), %rax
jne 0x1198d
movq -0x60(%rbp), %rax
movsbl 0x1(%rax), %eax
cmpl $0x0, %eax
jne 0x11b17
leaq 0x50656(%rip), %rdi     # 0x62166
movb $0x0, %al
callq 0x110f0
cmpl $0x0, -0x54(%rbp)
je 0x11b2b
leaq 0x50645(%rip), %rdi     # 0x62169
movb $0x0, %al
callq 0x110f0
leaq 0x506b2(%rip), %rdi     # 0x621e4
movb $0x0, %al
callq 0x110f0
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x88(%rbp)
movq -0x88(%rbp), %rax
movq %rax, -0x90(%rbp)
movq -0x88(%rbp), %rax
movq %rax, -0x98(%rbp)
cmpq $0x0, -0x88(%rbp)
jne 0x11b73
jmp 0x11c5d
jmp 0x11b75
movl $0x0, -0x9c(%rbp)
movl -0x9c(%rbp), %eax
movq -0x90(%rbp), %rcx
movw (%rcx), %cx
shlw $0x8, %cx
sarw $0x8, %cx
movswl %cx, %ecx
cmpl %ecx, %eax
jge 0x11c3c
movq -0x90(%rbp), %rax
movslq -0x9c(%rbp), %rcx
movq 0x18(%rax,%rcx,8), %rax
movq %rax, -0x50(%rbp)
movq -0x90(%rbp), %rax
movw (%rax), %ax
sarw $0x8, %ax
cwtl
cmpl $0x0, %eax
je 0x11bd6
cmpq $0x0, -0x50(%rbp)
jne 0x11bd6
jmp 0x11c28
movq -0x10(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq -0x10(%rbp), %rax
movq (%rax), %rax
shrq $0x20, %rax
andq $0x7fffffff, %rax       # imm = 0x7FFFFFFF
movl %eax, %edi
movq -0x50(%rbp), %rax
movq (%rax), %rax
shrq $0x20, %rax
andq $0x7fffffff, %rax       # imm = 0x7FFFFFFF
movl %eax, %r8d
leaq 0x5058d(%rip), %rcx     # 0x62199
leaq 0x5057d(%rip), %rax     # 0x62190
cmpl %r8d, %edi
cmovgq %rax, %rcx
leaq 0x50550(%rip), %rdi     # 0x62171
movb $0x0, %al
callq 0x110f0
movl -0x9c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x9c(%rbp)
jmp 0x11b7f
jmp 0x11c3e
movq -0x90(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x90(%rbp)
cmpq -0x88(%rbp), %rax
jne 0x11b75
jmp 0x11c5f
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
jmp 0x118ba
jmp 0x11c6f
movq -0x38(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x38(%rbp)
cmpq -0x30(%rbp), %rax
jne 0x118b3
leaq 0x5038e(%rip), %rdi     # 0x6201a
movb $0x0, %al
callq 0x110f0
addq $0xc0, %rsp
popq %rbp
retq
nopl (%rax)