// File: /workspace/github_c_makefile_star2_O0/oridb[P]mc/parse/infer.c
// Function: tylookup
static Type *
tylookup(Type *t)
{
	Type *lu;
	Stab *ns;

	assert(t != NULL);
	lu = NULL;
	while (1) {
		if (!tytab[t->tid] && t->type == Tyunres) {
			ns = curstab();
			if (t->name->name.ns)
				ns = getns(t->name->name.ns);
			if (!ns)
				fatal(t->name, "no namespace \"%s\"", t->name->name.ns);
			lu = gettype(ns, t->name);
			if (!lu)
				fatal(t->name, "no type %s", tystr(t));
			if (lu && lu != t)
				tytab[t->tid] = lu;
		}

		if (!tytab[t->tid])
			break;
		/* compress paths: shift the link up one level */
		if (tytab[tytab[t->tid]->tid])
			tytab[t->tid] = tytab[tytab[t->tid]->tid];
		t = tytab[t->tid];
	}
	return t;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
cmpq $0x0, -0x8(%rbp)
je 0x2aba5
jmp 0x2abc4
leaq 0x27d1b(%rip), %rdi     # 0x528c7
leaq 0x2767d(%rip), %rsi     # 0x52230
movl $0x250, %edx            # imm = 0x250
leaq 0x276c1(%rip), %rcx     # 0x52280
callq 0x6160
movq $0x0, -0x10(%rbp)
leaq 0x53115(%rip), %rax     # 0x7dce8
movq (%rax), %rax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
cmpq $0x0, (%rax,%rcx,8)
jne 0x2accf
movq -0x8(%rbp), %rax
cmpl $0x1b, (%rax)
jne 0x2accf
callq 0x32d60
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq 0x88(%rax), %rax
cmpq $0x0, 0x18(%rax)
je 0x2ac28
movq -0x8(%rbp), %rax
movq 0x88(%rax), %rax
movq 0x18(%rax), %rdi
callq 0x330b0
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x2ac57
movq -0x8(%rbp), %rax
movq 0x88(%rax), %rdi
movq -0x8(%rbp), %rax
movq 0x88(%rax), %rax
movq 0x18(%rax), %rdx
leaq 0x27647(%rip), %rsi     # 0x52297
movb $0x0, %al
callq 0x1dfe0
movq -0x18(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x88(%rax), %rsi
callq 0x33750
movq %rax, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0x2aca3
movq -0x8(%rbp), %rax
movq 0x88(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rdi
callq 0x38a10
movq -0x20(%rbp), %rdi
movq %rax, %rdx
leaq 0x2760d(%rip), %rsi     # 0x522a9
movb $0x0, %al
callq 0x1dfe0
cmpq $0x0, -0x10(%rbp)
je 0x2accd
movq -0x10(%rbp), %rax
cmpq -0x8(%rbp), %rax
je 0x2accd
movq -0x10(%rbp), %rdx
leaq 0x53029(%rip), %rax     # 0x7dce8
movq (%rax), %rax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
movq %rdx, (%rax,%rcx,8)
jmp 0x2accf
leaq 0x53012(%rip), %rax     # 0x7dce8
movq (%rax), %rax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
cmpq $0x0, (%rax,%rcx,8)
jne 0x2acec
jmp 0x2ad6e
leaq 0x52ff5(%rip), %rax     # 0x7dce8
movq (%rax), %rax
leaq 0x52feb(%rip), %rcx     # 0x7dce8
movq (%rcx), %rcx
movq -0x8(%rbp), %rdx
movl 0x4(%rdx), %edx
movq (%rcx,%rdx,8), %rcx
movl 0x4(%rcx), %ecx
cmpq $0x0, (%rax,%rcx,8)
je 0x2ad50
leaq 0x52fcc(%rip), %rax     # 0x7dce8
movq (%rax), %rax
leaq 0x52fc2(%rip), %rcx     # 0x7dce8
movq (%rcx), %rcx
movq -0x8(%rbp), %rdx
movl 0x4(%rdx), %edx
movq (%rcx,%rdx,8), %rcx
movl 0x4(%rcx), %ecx
movq (%rax,%rcx,8), %rdx
leaq 0x52fa6(%rip), %rax     # 0x7dce8
movq (%rax), %rax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
movq %rdx, (%rax,%rcx,8)
leaq 0x52f91(%rip), %rax     # 0x7dce8
movq (%rax), %rax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, -0x8(%rbp)
jmp 0x2abcc
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)