// File: /workspace/github_c_makefile_star2_O0/nimble-code[P]Modex/Src/xtract.c
// Function: handle_fct
static void
handle_fct(treenode *node, int tabs)
{
	if (!node->lnode)
		return;

	if (allprocs)
	{	visu = 1;			// no output before first procedure
		if (strchr(wanttype, '[')	// more than one instantiation
		&&  extended
		&&  (strcmp(nmestr(((leafnode *)(node->lnode))->data.sval), "main") == 0
#ifdef SV_COMP
		 ||  strstr(nmestr(((leafnode *)(node->lnode))->data.sval), "__VERIFIER_atomic_") != NULL
#endif
		 ||  strcmp(nmestr(((leafnode *)(node->lnode))->data.sval), "modex_main") == 0)
		&&  strstr(wanttype, "active")	// active proctypes
		&&  strstr(wanttype, "proctype"))
		{	sprintf(tbuf, "\n\nactive proctype p_%s(",
				nmestr(((leafnode *)(node->lnode))->data.sval));
			vis_direct(tbuf);
		} else
		{	char *a = tbuf;
			sprintf(tbuf, "\n\n%s p_%s(", wanttype,
				nmestr(((leafnode *)(node->lnode))->data.sval));

			if (dynamic
			&&  !strstr(tbuf, "p_main(")
			&&  !strstr(tbuf, "p_modex_main(") )
			{	a = strstr(tbuf, "active ");
				if (a != NULL)
				{	a += strlen("active ");
				} else
				{	a = tbuf;
			}	}
			vis_direct(a);
		}

		nreturns = 0;
	} else
	{	vis_print("FctDecl:\n");	/* visu is 0 here */

		if (node->lnode->hdr.which == LEAF_T
		&&  node->lnode->hdr.type == TN_IDENT	/* fct-name */
		&& !strcmp(want, nmestr(((leafnode *)(node->lnode))->data.sval))
		&&  strlen(want) == strlen(nmestr(((leafnode *)(node->lnode))->data.sval)))
		{	visu = 1;
			taboffset = tabs-1;
			strcpy(fct_name, nmestr(((leafnode *)(node->lnode))->data.sval));
			if (strcmp(wanttype, "body") != 0)
			{	sprintf(tbuf, "\n\n%s p_%s(", wanttype, want);
				vis_direct(tbuf);
			}
			nreturns = 0;
		} else
		{	doreturn(2);	/* needed? */
			taboffset = 0;
			if (!allprocs) visu = 0;
		}
	}
	strcpy(fct_name, nmestr(((leafnode *)(node->lnode))->data.sval));
	strcpy(derproc, fct_name);
	if (visu && show_funcs)
		set_fbase(node->hdr.line, fct_name);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rax
cmpq $0x0, 0x30(%rax)
jne 0x1a74f
jmp 0x1ab14
leaq 0x2d4e2(%rip), %rax     # 0x47c38
cmpl $0x0, (%rax)
je 0x1a951
leaq 0x2d43a(%rip), %rax     # 0x47ba0
movl $0x1, (%rax)
leaq 0x2aa15(%rip), %rax     # 0x45188
movq (%rax), %rdi
movl $0x5b, %esi
callq 0x4110
cmpq $0x0, %rax
je 0x1a87c
leaq 0x2d6d3(%rip), %rax     # 0x47e64
cmpl $0x0, (%rax)
je 0x1a87c
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x4870
movq %rax, %rdi
leaq 0x1b0e3(%rip), %rsi     # 0x35898
callq 0x4180
cmpl $0x0, %eax
je 0x1a80a
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x4870
movq %rax, %rdi
leaq 0x1ce06(%rip), %rsi     # 0x375e0
callq 0x4280
cmpq $0x0, %rax
jne 0x1a80a
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x4870
movq %rax, %rdi
leaq 0x1b092(%rip), %rsi     # 0x35892
callq 0x4180
cmpl $0x0, %eax
jne 0x1a87c
leaq 0x2a977(%rip), %rax     # 0x45188
movq (%rax), %rdi
leaq 0x1cdd8(%rip), %rsi     # 0x375f3
callq 0x4280
cmpq $0x0, %rax
je 0x1a87c
leaq 0x2a95b(%rip), %rax     # 0x45188
movq (%rax), %rdi
leaq 0x19bae(%rip), %rsi     # 0x343e5
callq 0x4280
cmpq $0x0, %rax
je 0x1a87c
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x4870
movq %rax, %rdx
leaq 0x31f73(%rip), %rdi     # 0x4c7d0
leaq 0x1cd96(%rip), %rsi     # 0x375fa
movb $0x0, %al
callq 0x4260
leaq 0x31f5e(%rip), %rdi     # 0x4c7d0
callq 0x10b40
jmp 0x1a942
leaq 0x31f4d(%rip), %rax     # 0x4c7d0
movq %rax, -0x18(%rbp)
leaq 0x2a8fa(%rip), %rax     # 0x45188
movq (%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x4870
movq -0x20(%rbp), %rdx
movq %rax, %rcx
leaq 0x31f1c(%rip), %rdi     # 0x4c7d0
leaq 0x1cd57(%rip), %rsi     # 0x37612
movb $0x0, %al
callq 0x4260
leaq 0x2d337(%rip), %rax     # 0x47c00
cmpl $0x0, (%rax)
je 0x1a939
leaq 0x31efb(%rip), %rdi     # 0x4c7d0
leaq 0x1cd41(%rip), %rsi     # 0x3761d
callq 0x4280
cmpq $0x0, %rax
jne 0x1a939
leaq 0x31ee2(%rip), %rdi     # 0x4c7d0
leaq 0x1cd30(%rip), %rsi     # 0x37625
callq 0x4280
cmpq $0x0, %rax
jne 0x1a939
leaq 0x31ec9(%rip), %rdi     # 0x4c7d0
leaq 0x1cd25(%rip), %rsi     # 0x37633
callq 0x4280
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
je 0x1a92c
movq -0x18(%rbp), %rax
addq $0x7, %rax
movq %rax, -0x18(%rbp)
jmp 0x1a937
leaq 0x31e9d(%rip), %rax     # 0x4c7d0
movq %rax, -0x18(%rbp)
jmp 0x1a939
movq -0x18(%rbp), %rdi
callq 0x10b40
movl $0x0, 0x39a24(%rip)     # 0x54370
jmp 0x1aab6
leaq 0x1cce3(%rip), %rdi     # 0x3763b
callq 0x15790
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
cmpl $0x1, (%rax)
jne 0x1aa85
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
cmpl $0x2d, 0x1c(%rax)
jne 0x1aa85
leaq 0x2a7f1(%rip), %rax     # 0x45178
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x4870
movq -0x28(%rbp), %rdi
movq %rax, %rsi
callq 0x4180
cmpl $0x0, %eax
jne 0x1aa85
leaq 0x2a7bd(%rip), %rax     # 0x45178
movq (%rax), %rdi
callq 0x40f0
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x4870
movq %rax, %rdi
callq 0x40f0
movq %rax, %rcx
movq -0x30(%rbp), %rax
cmpq %rcx, %rax
jne 0x1aa85
leaq 0x2d1a9(%rip), %rax     # 0x47ba0
movl $0x1, (%rax)
movl -0xc(%rbp), %eax
subl $0x1, %eax
movl %eax, 0x374e3(%rip)     # 0x51eec
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x4870
movq %rax, %rsi
leaq 0x2a93c(%rip), %rdi     # 0x45360
callq 0x40a0
leaq 0x2a758(%rip), %rax     # 0x45188
movq (%rax), %rdi
leaq 0x199bb(%rip), %rsi     # 0x343f5
callq 0x4180
cmpl $0x0, %eax
je 0x1aa79
leaq 0x2a73d(%rip), %rax     # 0x45188
movq (%rax), %rdx
leaq 0x2a723(%rip), %rax     # 0x45178
movq (%rax), %rcx
leaq 0x31d71(%rip), %rdi     # 0x4c7d0
leaq 0x1cbac(%rip), %rsi     # 0x37612
movb $0x0, %al
callq 0x4260
leaq 0x31d5c(%rip), %rdi     # 0x4c7d0
callq 0x10b40
movl $0x0, 0x398ed(%rip)     # 0x54370
jmp 0x1aab4
movl $0x2, %edi
callq 0x17090
movl $0x0, 0x37453(%rip)     # 0x51eec
leaq 0x2d198(%rip), %rax     # 0x47c38
cmpl $0x0, (%rax)
jne 0x1aab2
leaq 0x2d0f4(%rip), %rax     # 0x47ba0
movl $0x0, (%rax)
jmp 0x1aab4
jmp 0x1aab6
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq 0x30(%rax), %rdi
callq 0x4870
movq %rax, %rsi
leaq 0x2a88f(%rip), %rdi     # 0x45360
callq 0x40a0
leaq 0x37e53(%rip), %rdi     # 0x52930
leaq 0x2a87c(%rip), %rsi     # 0x45360
callq 0x40a0
leaq 0x2d0b0(%rip), %rax     # 0x47ba0
cmpl $0x0, (%rax)
je 0x1ab14
leaq 0x2d148(%rip), %rax     # 0x47c44
cmpl $0x0, (%rax)
je 0x1ab14
movq -0x8(%rbp), %rax
movl 0x10(%rax), %edi
leaq 0x2a851(%rip), %rsi     # 0x45360
callq 0x2e240
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)