// File: /workspace/github_c_makefile_star2_O3/oridb[P]mc/parse/infer.c
// Function: ctxstr
static char *
ctxstr(Node *n)
{
	char *t, *t1, *t2, *t3;
	char *s, *d;
	size_t nargs;
	Node **args;
	char buf[512];

	if (!n)
		return strdup("???");
	switch (n->type) {
	default:
		s = strdup(nodestr[n->type]);
		break;
	case Ndecl:
		 d = declname(n);
		 t = nodetystr(n);
		 bprintf(buf, sizeof buf, "%s:%s", d, t);
		 s = strdup(buf);
		 free(t);
		 break;
	case Nname:	s = strdup(namestr(n));	break;
	case Nexpr:
		args = n->expr.args;
		nargs = n->expr.nargs;
		t1 = NULL;
		t2 = NULL;
		t3 = NULL;
		if (exprop(n) == Ovar)
			d = namestr(args[0]);
		else
			d = opstr[exprop(n)];
		t = nodetystr(n);
		if (nargs >= 1)
			t1 = nodetystr(args[0]);
		if (nargs >= 2)
			t2 = nodetystr(args[1]);
		if (nargs >= 3)
			t3 = nodetystr(args[2]);

		switch (opclass[exprop(n)]) {
		case OTpre:	bprintf(buf, sizeof buf, "%s<e:%s>", oppretty[exprop(n)], t1);	break;
		case OTpost:	bprintf(buf, sizeof buf, "<e:%s>%s", t1, oppretty[exprop(n)]);	break;
		case OTzarg:	bprintf(buf, sizeof buf, "%s", oppretty[exprop(n)]);	break;
		case OTbin:
			bprintf(buf, sizeof buf, "<e1:%s> %s <e2:%s>", t1, oppretty[exprop(n)], t2);
			break;
		case OTmisc:
			switch (exprop(n)) {
			case Ovar:	bprintf(buf, sizeof buf, "%s:%s", namestr(args[0]), t);	break;
			case Ocall:	ctxstrcall(buf, sizeof buf,n);	break;
			case Oidx:
				if (exprop(args[0]) == Ovar)
					bprintf(buf, sizeof buf, "%s[<e1:%s>]", namestr(args[0]->expr.args[0]), t2);
				else
					bprintf(buf, sizeof buf, "<sl:%s>[<e1%s>]", t1, t2);
				break;
			case Oslice:
				if (exprop(args[0]) == Ovar)
					bprintf(buf, sizeof buf, "%s[<e1:%s>:<e2:%s>]", namestr(args[0]->expr.args[0]), t2, t3);
				else
					bprintf( buf, sizeof buf, "<sl:%s>[<e1%s>:<e2:%s>]", t1, t2, t3);
				break;
			case Omemb:
				bprintf(buf, sizeof buf, "<%s>.%s", t1, namestr(args[1]));
				break;
			case Otupmemb:
				bprintf(buf, sizeof buf, "<%s>.%llu", t1, args[1]->lit.intval);
				break;
			default:
				bprintf(buf, sizeof buf, "%s:%s", d, t);
				break;
			}
			break;
		default: bprintf(buf, sizeof buf, "%s", d); break;
		}
		free(t);
		free(t1);
		free(t2);
		free(t3);
		s = strdup(buf);
		break;
	}
	return s;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x218, %rsp            # imm = 0x218
testq %rdi, %rdi
je 0x198d7
movq %rdi, %r13
movl 0x8(%rdi), %eax
cmpq $0x8, %rax
je 0x198ed
cmpl $0xa, %eax
je 0x198e0
cmpl $0xb, %eax
jne 0x1990f
movq %r13, %rdi
callq 0x1e2ed
movq %rax, %rbx
movq %r13, %rdi
callq 0x19c40
movq %rax, %r14
leaq 0x1d9e5(%rip), %rdx     # 0x3728a
leaq 0x10(%rsp), %r15
movl $0x200, %esi            # imm = 0x200
movq %r15, %rdi
movq %rbx, %rcx
movq %rax, %r8
xorl %eax, %eax
callq 0x2dfae
movq %r15, %rdi
callq 0x4340
movq %rax, %rbx
movq %r14, %rdi
callq 0x4040
jmp 0x19b2d
leaq 0x1c632(%rip), %rdi     # 0x35f10
jmp 0x1991a
movq %r13, %rdi
callq 0x1e4eb
movq %rax, %rdi
jmp 0x1991a
movq 0x40(%r13), %r12
movq 0x50(%r13), %rbx
movq %r13, %rdi
callq 0x1d422
cmpl $0x33, %eax
jne 0x19930
movq (%rbx), %rdi
callq 0x1e4eb
movq %rax, %rbp
jmp 0x19945
leaq 0x4738a(%rip), %rcx     # 0x60ca0
movq (%rcx,%rax,8), %rdi
addq $0x218, %rsp            # imm = 0x218
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x4340
movq %r13, %rdi
callq 0x1d422
movl %eax, %eax
leaq 0x46a5f(%rip), %rcx     # 0x603a0
movq (%rcx,%rax,8), %rbp
movq %r13, %rdi
callq 0x19c40
movq %rax, 0x8(%rsp)
testq %r12, %r12
je 0x1996d
movq (%rbx), %rdi
callq 0x19c40
movq %rax, %r14
cmpq $0x1, %r12
jne 0x19975
xorl %r15d, %r15d
jmp 0x19995
xorl %r15d, %r15d
xorl %r14d, %r14d
jmp 0x19995
movq 0x8(%rbx), %rdi
callq 0x19c40
movq %rax, %r15
cmpq $0x3, %r12
jb 0x19995
movq 0x10(%rbx), %rdi
callq 0x19c40
movq %rax, %r12
jmp 0x19998
xorl %r12d, %r12d
movq %r13, %rdi
callq 0x1d422
movl %eax, %eax
leaq 0x47177(%rip), %rcx     # 0x60b20
movl (%rcx,%rax,4), %eax
cmpq $0x4, %rax
ja 0x19ae0
leaq 0x1c0a3(%rip), %rcx     # 0x35a60
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq %r13, %rdi
callq 0x1d422
addl $-0x28, %eax
cmpl $0xb, %eax
ja 0x19b85
leaq 0x1c093(%rip), %rcx     # 0x35a74
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq (%rbx), %rdi
callq 0x1d422
cmpl $0x33, %eax
jne 0x19c05
movq (%rbx), %rax
movq 0x50(%rax), %rax
movq (%rax), %rdi
callq 0x1e4eb
leaq 0x1c528(%rip), %rdx     # 0x35f39
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %rax, %rcx
jmp 0x19c19
movq %r13, %rdi
callq 0x1d422
movl %eax, %eax
leaq 0x46c6c(%rip), %rcx     # 0x606a0
movq (%rcx,%rax,8), %rcx
leaq 0x1d08e(%rip), %rdx     # 0x36acd
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
jmp 0x19af4
movq %r13, %rdi
callq 0x1d422
movl %eax, %eax
leaq 0x46c41(%rip), %rcx     # 0x606a0
movq (%rcx,%rax,8), %r8
leaq 0x1c4b3(%rip), %rdx     # 0x35f1d
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %r14, %rcx
jmp 0x19ad7
movq %r13, %rdi
callq 0x1d422
movl %eax, %eax
leaq 0x46c16(%rip), %rcx     # 0x606a0
movq (%rcx,%rax,8), %r8
leaq 0x1c491(%rip), %rdx     # 0x35f26
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %r14, %rcx
movq %r15, %r9
xorl %eax, %eax
callq 0x2dfae
jmp 0x19afb
movq %r13, %rdi
callq 0x1d422
movl %eax, %eax
leaq 0x46be1(%rip), %rcx     # 0x606a0
movq (%rcx,%rax,8), %rcx
leaq 0x1c44a(%rip), %rdx     # 0x35f14
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %r14, %r8
xorl %eax, %eax
callq 0x2dfae
jmp 0x19afb
leaq 0x1cfe6(%rip), %rdx     # 0x36acd
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %rbp, %rcx
xorl %eax, %eax
callq 0x2dfae
movq 0x8(%rsp), %rbx
movq %rbx, %rdi
callq 0x4040
movq %r14, %rdi
callq 0x4040
movq %r15, %rdi
callq 0x4040
movq %r12, %rdi
callq 0x4040
leaq 0x10(%rsp), %rdi
callq 0x4340
movq %rax, %rbx
movq %rbx, %rax
addq $0x218, %rsp            # imm = 0x218
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x8(%rbx), %rdi
callq 0x1e4eb
leaq 0x1c42f(%rip), %rdx     # 0x35f81
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %r14, %rcx
movq %rax, %r8
jmp 0x19ad7
movq (%rbx), %rdi
callq 0x1e4eb
leaq 0x1d714(%rip), %rdx     # 0x3728a
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %rax, %rcx
jmp 0x19b99
leaq 0x1d6fe(%rip), %rdx     # 0x3728a
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %rbp, %rcx
movq 0x8(%rsp), %rbx
movq %rbx, %r8
xorl %eax, %eax
callq 0x2dfae
jmp 0x19b00
movq (%rbx), %rdi
callq 0x1d422
cmpl $0x33, %eax
jne 0x19c21
movq (%rbx), %rax
movq 0x50(%rax), %rax
movq (%rax), %rdi
callq 0x1e4eb
leaq 0x1c385(%rip), %rdx     # 0x35f55
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %rax, %rcx
jmp 0x19c35
movq 0x8(%rbx), %rax
movq 0x30(%rax), %r8
leaq 0x1c39b(%rip), %rdx     # 0x35f89
jmp 0x19a6a
leaq 0x10(%rsp), %rdi
movq %r13, %rsi
callq 0x19cdf
jmp 0x19afb
leaq 0x1c339(%rip), %rdx     # 0x35f45
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %r14, %rcx
movq %r15, %r8
jmp 0x19ad7
leaq 0x1c341(%rip), %rdx     # 0x35f69
leaq 0x10(%rsp), %rdi
movl $0x200, %esi            # imm = 0x200
movq %r14, %rcx
movq %r15, %r8
movq %r12, %r9
jmp 0x19aa5