// File: skyshore2001[P]symfind/symfind.cpp
// Function: TestShow()
int TestShow()
{
	// Test code for tranverse objects
	int maxcnt = 40;
	int i;
	char buf[1024];
	printf("=== folders:\n");
	SfFolderIter itFolder(g_repos);
	for (i=0; i<maxcnt && itFolder.Next(); ++i) {
		const SfContext &ctx = itFolder.GetContext();
		printf("%d: %s\n", i+1, GetFullName(buf, ctx.repo->root, ctx.folder->name));
	}
	printf("=== files:\n");
	SfFileIter itFile(g_repos);
	for (i=0; i<maxcnt && itFile.Next(); ++i) {
		const SfContext &ctx = itFile.GetContext();
		printf("%d: %s\n", i+1, GetFullName(buf, ctx.repo->root, ctx.folder->name, ctx.file->name));
	}
	printf("=== symbols:\n");
	SfSymbolIter itSymbol(g_repos);
	for (i=0; i<maxcnt && itSymbol.Next(); ++i) {
		const SfContext &ctx = itSymbol.GetContext();
		printf("%d: %s\t%s\t%s\t%s:%s\n", i+1, ctx.symbol->kind(), ctx.symbol->name(), ctx.symbol->extra(), GetFullName(buf, ctx.repo->root, ctx.folder->name, ctx.file->name), ctx.symbol->line());
	}
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x530, %rsp            # imm = 0x530
movl $0x28, -0x4(%rbp)
leaq 0x6ac8(%rip), %rdi      # 0xb521
movb $0x0, %al
callq 0x2030
movq 0xc879(%rip), %rsi      # 0x112e0
leaq -0x450(%rbp), %rdi
callq 0x6390
movl $0x0, -0x8(%rbp)
movl -0x8(%rbp), %ecx
xorl %eax, %eax
cmpl -0x4(%rbp), %ecx
movb %al, -0x4e9(%rbp)
jge 0x4aa3
leaq -0x450(%rbp), %rdi
callq 0x63c0
cmpq $0x0, %rax
setne %al
movb %al, -0x4e9(%rbp)
movb -0x4e9(%rbp), %al
testb $0x1, %al
jne 0x4aaf
jmp 0x4b1e
leaq -0x450(%rbp), %rdi
callq 0x5bd0
movq %rax, -0x458(%rbp)
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4f0(%rbp)
leaq -0x410(%rbp), %rdi
movq -0x458(%rbp), %rax
movq (%rax), %rax
movq (%rax), %rsi
movq -0x458(%rbp), %rax
movq 0x8(%rax), %rax
movq (%rax), %rdx
xorl %eax, %eax
movl %eax, %ecx
callq 0x31a0
movl -0x4f0(%rbp), %esi
movq %rax, %rdx
leaq 0x6986(%rip), %rdi      # 0xb48f
movb $0x0, %al
callq 0x2030
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
jmp 0x4a7a
leaq 0x6a0a(%rip), %rdi      # 0xb52f
movb $0x0, %al
callq 0x2030
movq 0xc7ad(%rip), %rsi      # 0x112e0
leaq -0x498(%rbp), %rdi
callq 0x5980
movl $0x0, -0x8(%rbp)
movl -0x8(%rbp), %ecx
xorl %eax, %eax
cmpl -0x4(%rbp), %ecx
movb %al, -0x4f1(%rbp)
jge 0x4b6f
leaq -0x498(%rbp), %rdi
callq 0x5b70
cmpq $0x0, %rax
setne %al
movb %al, -0x4f1(%rbp)
movb -0x4f1(%rbp), %al
testb $0x1, %al
jne 0x4b7b
jmp 0x4bf4
leaq -0x498(%rbp), %rdi
callq 0x5bd0
movq %rax, -0x4a0(%rbp)
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4f8(%rbp)
leaq -0x410(%rbp), %rdi
movq -0x4a0(%rbp), %rax
movq (%rax), %rax
movq (%rax), %rsi
movq -0x4a0(%rbp), %rax
movq 0x8(%rax), %rax
movq (%rax), %rdx
movq -0x4a0(%rbp), %rax
movq 0x10(%rax), %rax
movq (%rax), %rcx
callq 0x31a0
movl -0x4f8(%rbp), %esi
movq %rax, %rdx
leaq 0x68b0(%rip), %rdi      # 0xb48f
movb $0x0, %al
callq 0x2030
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
jmp 0x4b46
leaq 0x6940(%rip), %rdi      # 0xb53b
movb $0x0, %al
callq 0x2030
movq 0xc6d7(%rip), %rsi      # 0x112e0
leaq -0x4e0(%rbp), %rdi
callq 0x5ef0
movl $0x0, -0x8(%rbp)
movl -0x8(%rbp), %ecx
xorl %eax, %eax
cmpl -0x4(%rbp), %ecx
movb %al, -0x4f9(%rbp)
jge 0x4c45
leaq -0x4e0(%rbp), %rdi
callq 0x5f20
cmpq $0x0, %rax
setne %al
movb %al, -0x4f9(%rbp)
movb -0x4f9(%rbp), %al
testb $0x1, %al
jne 0x4c54
jmp 0x4d46
leaq -0x4e0(%rbp), %rdi
callq 0x5bd0
movq %rax, -0x4e8(%rbp)
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x524(%rbp)
movq -0x4e8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x5fc0
movq %rax, -0x520(%rbp)
movq -0x4e8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x5fa0
movq %rax, -0x518(%rbp)
movq -0x4e8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x5fe0
movq %rax, -0x510(%rbp)
leaq -0x410(%rbp), %rdi
movq -0x4e8(%rbp), %rax
movq (%rax), %rax
movq (%rax), %rsi
movq -0x4e8(%rbp), %rax
movq 0x8(%rax), %rax
movq (%rax), %rdx
movq -0x4e8(%rbp), %rax
movq 0x10(%rax), %rax
movq (%rax), %rcx
callq 0x31a0
movq %rax, -0x508(%rbp)
movq -0x4e8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x6000
movl -0x524(%rbp), %esi
movq -0x520(%rbp), %rdx
movq -0x518(%rbp), %rcx
movq -0x510(%rbp), %r8
movq -0x508(%rbp), %r9
leaq 0x681c(%rip), %rdi      # 0xb549
movq %rax, (%rsp)
movb $0x0, %al
callq 0x2030
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
jmp 0x4c1c
xorl %eax, %eax
addq $0x530, %rsp            # imm = 0x530
popq %rbp
retq
nopw %cs:(%rax,%rax)