LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: NoWadTextures()
bool NoWadTextures ()
{
	// copied from loadtextures.cpp
	int numtextures = g_texdatasize? ((dmiptexlump_t *)g_dtexdata)->nummiptex: 0;
	for (int i = 0; i < numtextures; i++)
	{
		int offset = ((dmiptexlump_t *)g_dtexdata)->dataofs[i];
		int size = g_texdatasize - offset;
		if (offset < 0 || size < (int)sizeof (miptex_t))
		{
			// missing textures have ofs -1
			continue;
		}
		miptex_t *mt = (miptex_t *)&g_dtexdata[offset];
		if (!mt->offsets[0])
		{
			return false;
		}
	}
	return true;
}

// Assembly:
movl 0x8297e5(%rip), %ecx    # 0x82f4c4
xorl %eax, %eax
movq 0x8297e0(%rip), %rdx    # 0x82f4c8
movl $0x0, %esi
testl %ecx, %ecx
je 0x5cf3
movl (%rdx), %esi
testl %esi, %esi
movl $0x0, %edi
cmovgl %esi, %edi
cmpq %rax, %rdi
je 0x5d31
movl 0x4(%rdx,%rax,4), %r8d
movl %ecx, %r9d
subl %r8d, %r9d
testl %r8d, %r8d
sets %r10b
cmpl $0x28, %r9d
setl %r9b
orb %r10b, %r9b
jne 0x5d2c
movl %r8d, %r8d
cmpl $0x0, 0x18(%rdx,%r8)
je 0x5d31
incq %rax
jmp 0x5cfd
movslq %esi, %rcx
cmpq %rcx, %rax
setge %al
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: GlobUsage(char const*, int, int)
static int      GlobUsage(const char* const szItem, const int itemstorage, const int maxstorage)
{
    float           percentage = maxstorage ? itemstorage * 100.0 / maxstorage : 0.0;

#ifdef ZHLT_MAX_MAP_LEAFS
    Log("%-13s    [variable]   %8i/%-8i (%4.1f%%)\n", szItem, itemstorage, maxstorage, percentage);
#else
    Log("%-12s     [variable]    %7i/%-7i  (%4.1f%%)\n", szItem, itemstorage, maxstorage, percentage);
#endif

    return itemstorage;
}

// Assembly:
pushq %rbx
movl %edx, %ecx
movl %esi, %ebx
movq %rdi, %rsi
testl %edx, %edx
je 0x62a0
cvtsi2sd %ebx, %xmm0
mulsd 0x12dea(%rip), %xmm0    # 0x19078
cvtsi2sd %ecx, %xmm1
divsd %xmm1, %xmm0
cvtsd2ss %xmm0, %xmm0
cvtss2sd %xmm0, %xmm0
jmp 0x62a3
xorps %xmm0, %xmm0
leaq 0x134b2(%rip), %rdi     # 0x1975c
movl %ebx, %edx
movb $0x1, %al
callq 0x89dc
movl %ebx, %eax
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: ParseImplicitTexinfoFromTexture(int)
int	ParseImplicitTexinfoFromTexture (int miptex)
{
	int texinfo;
	int numtextures = g_texdatasize? ((dmiptexlump_t *)g_dtexdata)->nummiptex: 0;
	int offset;
	int size;
	miptex_t *mt;
	char name[16];
	
	if (miptex < 0 || miptex >= numtextures)
	{
		Warning ("ParseImplicitTexinfoFromTexture: internal error: invalid texture number %d.", miptex);
		return -1;
	}
	offset = ((dmiptexlump_t *)g_dtexdata)->dataofs[miptex];
	size = g_texdatasize - offset;
	if (offset < 0 || g_dtexdata + offset < (byte *)&((dmiptexlump_t *)g_dtexdata)->dataofs[numtextures] ||
		size < (int)sizeof (miptex_t))
	{
		return -1;
	}

	mt = (miptex_t *)&g_dtexdata[offset];
	safe_strncpy (name, mt->name, 16);
	
	if (!(strlen (name) >= 6 && !strncasecmp (&name[1], "_rad", 4) && '0' <= name[5] && name[5] <= '9'))
	{
		return -1;
	}

	texinfo = atoi (&name[5]);
	if (texinfo < 0 || texinfo >= g_numtexinfo)
	{
		Warning ("Invalid index of original texinfo: %d parsed from texture name '%s'.", texinfo, name);
		return -1;
	}

	return texinfo;
}

// Assembly:
movl %edi, %eax
movl 0x829205(%rip), %ecx    # 0x82f4c4
testl %ecx, %ecx
je 0x62ce
movq 0x8291fe(%rip), %rdx    # 0x82f4c8
movl (%rdx), %edx
jmp 0x62d0
xorl %edx, %edx
pushq %r14
pushq %rbx
subq $0x18, %rsp
testl %eax, %eax
setns %sil
cmpl %eax, %edx
setg %dil
testb %dil, %sil
je 0x637d
movq 0x8291d5(%rip), %rsi    # 0x82f4c8
movl %eax, %eax
movslq 0x4(%rsi,%rax,4), %rax
pushq $-0x1
popq %rbx
testq %rax, %rax
js 0x6390
leaq 0x4(%rsi), %rdi
subl %eax, %ecx
addq %rax, %rsi
movl %edx, %eax
leaq (%rdi,%rax,4), %rax
cmpq %rax, %rsi
setb %al
cmpl $0x28, %ecx
setl %cl
orb %al, %cl
jne 0x6390
movq %rsp, %r14
pushq $0x10
popq %rdx
movq %r14, %rdi
callq 0x796d
movq %r14, %rdi
callq 0x4190
cmpq $0x6, %rax
jb 0x6390
leaq 0x1(%rsp), %rdi
leaq 0x130c0(%rip), %rsi     # 0x1940d
pushq $0x4
popq %rdx
callq 0x4420
testl %eax, %eax
jne 0x6390
movb 0x5(%rsp), %al
addb $-0x30, %al
cmpb $0x9, %al
ja 0x6390
leaq 0x5(%rsp), %rdi
callq 0x4520
testl %eax, %eax
js 0x639a
cmpl 0x11890a5(%rip), %eax   # 0x118f41c
jge 0x639a
movl %eax, %ebx
jmp 0x6390
leaq 0x1303d(%rip), %rdi     # 0x193c1
movl %eax, %esi
xorl %eax, %eax
callq 0x90f1
pushq $-0x1
popq %rbx
movl %ebx, %eax
addq $0x18, %rsp
popq %rbx
popq %r14
retq
leaq 0x13071(%rip), %rdi     # 0x19412
movq %rsp, %rdx
movl %eax, %esi
xorl %eax, %eax
callq 0x90f1
jmp 0x6390
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: ParseEpair()
epair_t*        ParseEpair()
{
    epair_t*        e;

    e = (epair_t*)Alloc(sizeof(epair_t));

    if (strlen(g_token) >= MAX_KEY - 1)
        Error("ParseEpair: Key token too long (%i > MAX_KEY)", (int)strlen(g_token));

    e->key = _strdup(g_token);
    GetToken(false);

    if (strlen(g_token) >= MAX_VAL - 1) //MAX_VALUE //vluzacn
        Error("ParseEpar: Value token too long (%i > MAX_VALUE)", (int)strlen(g_token));

    e->value = _strdup(g_token);

    return e;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
pushq $0x18
popq %rdi
callq 0x4842
movq %rax, %rbx
leaq 0x20badf3(%rip), %rdi   # 0x20c14b0
callq 0x4190
cmpq $0x7f, %rax
jb 0x66d8
leaq 0x12dda(%rip), %rdi     # 0x194a9
movl %eax, %esi
xorl %eax, %eax
callq 0x8d7b
leaq 0x20badd1(%rip), %r14   # 0x20c14b0
movq %r14, %rdi
callq 0x45d0
movq %rax, 0x8(%rbx)
xorl %edi, %edi
callq 0x9b47
movq %r14, %rdi
callq 0x4190
cmpq $0xfff, %rax            # imm = 0xFFF
jb 0x6712
leaq 0x12dce(%rip), %rdi     # 0x194d7
movl %eax, %esi
xorl %eax, %eax
callq 0x8d7b
leaq 0x20bad97(%rip), %rdi   # 0x20c14b0
callq 0x45d0
movq %rax, 0x10(%rbx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: ValueForKey(entity_t const*, char const*)
const char*     ValueForKey(const entity_t* const ent, const char* const key)
{
    epair_t*        ep;

    for (ep = ent->epairs; ep; ep = ep->next)
    {
        if (!strcmp(ep->key, key))
        {
            return ep->value;
        }
    }
    return "";
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r15
movq %rdi, %r14
addq $0x20, %r14
leaq 0x14258(%rip), %rbx     # 0x1ac19
movq (%r14), %r14
testq %r14, %r14
je 0x69dd
movq 0x8(%r14), %rdi
movq %r15, %rsi
callq 0x4480
testl %eax, %eax
jne 0x69c1
movq 0x10(%r14), %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: SetKeyValue(entity_t*, char const*, char const*)
void            SetKeyValue(entity_t* ent, const char* const key, const char* const value)
{
    epair_t*        ep;

#ifdef ZHLT_DELETEKEY
	if (!value[0])
	{
		DeleteKey (ent, key);
		return;
	}
#endif
    for (ep = ent->epairs; ep; ep = ep->next)
    {
        if (!strcmp(ep->key, key))
        {
#ifdef ZHLT_DELETEKEY
			char *value2 = strdup (value);
			Free (ep->value);
			ep->value = value2;
#else
            Free(ep->value);
            ep->value = strdup(value);
#endif
            return;
        }
    }
    ep = (epair_t*)Alloc(sizeof(*ep));
    ep->next = ent->epairs;
    ent->epairs = ep;
    ep->key = strdup(key);
    ep->value = strdup(value);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %r15
cmpb $0x0, (%rdx)
je 0x6a39
movq %rdx, %rbx
addq $0x20, %r15
movq %r15, %r12
movq (%r12), %r12
testq %r12, %r12
je 0x6a4f
movq 0x8(%r12), %rdi
movq %r14, %rsi
callq 0x4480
testl %eax, %eax
jne 0x6a03
movq %rbx, %rdi
callq 0x45d0
movq %rax, %rbx
movq 0x10(%r12), %rdi
callq 0x4847
movq %rbx, 0x10(%r12)
jmp 0x6a7e
movq %r15, %rdi
movq %r14, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x6a8a
pushq $0x18
popq %rdi
callq 0x4842
movq %rax, %r12
movq (%r15), %rax
movq %rax, (%r12)
movq %r12, (%r15)
movq %r14, %rdi
callq 0x45d0
movq %rax, 0x8(%r12)
movq %rbx, %rdi
callq 0x45d0
movq %rax, 0x10(%r12)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: DeleteKey(entity_t*, char const*)
void			DeleteKey(entity_t* ent, const char* const key)
{
	epair_t **pep;
	for (pep = &ent->epairs; *pep; pep = &(*pep)->next)
	{
		if (!strcmp ((*pep)->key, key))
		{
			epair_t *ep = *pep;
			*pep = ep->next;
			Free(ep->key);
			Free(ep->value);
			Free(ep);
			return;
		}
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
addq $0x20, %rbx
movq %rbx, %r15
movq (%rbx), %rbx
testq %rbx, %rbx
je 0x6ad9
movq 0x8(%rbx), %rdi
movq %r14, %rsi
callq 0x4480
testl %eax, %eax
jne 0x6a99
movq (%rbx), %rax
movq %rax, (%r15)
movq 0x8(%rbx), %rdi
callq 0x4847
movq 0x10(%rbx), %rdi
callq 0x4847
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x4847
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: anglesforvector(float*, float const*)
int anglesforvector (float angles[3], const float vector[3])
{
	float z = vector[2], r = sqrt (vector[0] * vector[0] + vector[1] * vector[1]);
	float tmp;
	if (sqrt (z*z + r*r) < NORMAL_EPSILON)
	{
		return -1;
	}
	else
	{
		tmp = sqrt (z*z + r*r);
		z /= tmp, r /= tmp;
		if (r < NORMAL_EPSILON)
		{
			if (z < 0)
			{
				angles[0] = -90, angles[1] = 0;
			}
			else
			{
				angles[0] = 90, angles[1] = 0;
			}
		}
		else
		{
			angles[0] = atan (z / r) / Q_PI * 180;
			float x = vector[0], y = vector[1];
			tmp = sqrt (x*x + y*y);
			x /= tmp, y /= tmp;
			if (x < -1 + NORMAL_EPSILON)
			{
				angles[1] = -180;
			}
			else
			{
				if (y >= 0)
				{
					angles[1] = 2 * atan (y / (1+x)) / Q_PI * 180;
				}
				else
				{
					angles[1] = 2 * atan (y / (1+x)) / Q_PI * 180 + 360;
				}
			}
		}
	}
	angles[2] = 0;
	return 0;
}

// Assembly:
movss 0x8(%rsi), %xmm0
movss (%rsi), %xmm1
movss 0x4(%rsi), %xmm2
mulss %xmm2, %xmm2
mulss %xmm1, %xmm1
addss %xmm2, %xmm1
sqrtss %xmm1, %xmm1
movaps %xmm1, %xmm2
mulss %xmm1, %xmm2
movaps %xmm0, %xmm3
mulss %xmm0, %xmm3
addss %xmm2, %xmm3
sqrtss %xmm3, %xmm2
cvtss2sd %xmm2, %xmm4
movsd 0x1252d(%rip), %xmm3    # 0x19080
ucomisd %xmm4, %xmm3
jbe 0x6b5d
pushq $-0x1
popq %rax
retq
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
divss %xmm2, %xmm0
divss %xmm2, %xmm1
cvtss2sd %xmm1, %xmm2
ucomisd %xmm2, %xmm3
jbe 0x6b88
xorps %xmm1, %xmm1
ucomiss %xmm0, %xmm1
jbe 0x6bf0
movss 0x124e6(%rip), %xmm0    # 0x1906c
jmp 0x6bf8
movq %rsi, %r14
divss %xmm1, %xmm0
callq 0x4290
cvtss2sd %xmm0, %xmm0
divsd 0x124e8(%rip), %xmm0    # 0x19088
mulsd 0x124e8(%rip), %xmm0    # 0x19090
cvtsd2ss %xmm0, %xmm0
movss %xmm0, (%rbx)
movss (%r14), %xmm1
movss 0x4(%r14), %xmm4
movaps %xmm4, %xmm0
mulss %xmm4, %xmm0
movaps %xmm1, %xmm2
mulss %xmm1, %xmm2
addss %xmm0, %xmm2
sqrtss %xmm2, %xmm0
divss %xmm0, %xmm1
cvtss2sd %xmm1, %xmm2
movsd 0x124b7(%rip), %xmm3    # 0x19098
ucomisd %xmm2, %xmm3
jbe 0x6bfd
movl $0xc3340000, 0x4(%rbx)  # imm = 0xC3340000
jmp 0x6c52
movss 0x12470(%rip), %xmm0    # 0x19068
movlps %xmm0, (%rbx)
jmp 0x6c52
divss %xmm0, %xmm4
movss %xmm4, 0x4(%rsp)
addss 0x12455(%rip), %xmm1    # 0x19064
movaps %xmm4, %xmm0
divss %xmm1, %xmm0
callq 0x4290
xorps %xmm1, %xmm1
movss 0x4(%rsp), %xmm2
ucomiss %xmm1, %xmm2
addss %xmm0, %xmm0
cvtss2sd %xmm0, %xmm0
divsd 0x12451(%rip), %xmm0    # 0x19088
mulsd 0x12451(%rip), %xmm0    # 0x19090
jae 0x6c49
addsd 0x12457(%rip), %xmm0    # 0x190a0
cvtsd2ss %xmm0, %xmm0
movss %xmm0, 0x4(%rbx)
andl $0x0, 0x8(%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: FindTargetEntity(char const*)
entity_t *FindTargetEntity(const char* const target)
{
    int             i;
    const char*     n;

    for (i = 0; i < g_numentities; i++)
    {
        n = ValueForKey(&g_entities[i], "targetname");
        if (!strcmp(n, target))
        {
            return &g_entities[i];
        }
    }

    return NULL;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movslq 0x20160bb(%rip), %r12   # 0x201d454
leaq 0x20160c0(%rip), %rdi   # 0x201d460
pushq $-0x1
popq %r13
xorl %ebx, %ebx
leaq 0x1230b(%rip), %r15     # 0x196b8
incq %r13
cmpq %r12, %r13
jge 0x73da
leaq 0x28(%rdi), %rbp
movq %r15, %rsi
callq 0x69ab
movq %rax, %rdi
movq %r14, %rsi
callq 0x4480
movq %rbp, %rdi
testl %eax, %eax
jne 0x73ad
addq $-0x28, %rbp
movq %rbp, %rbx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: GetVectorForKey(entity_t const*, char const*, double*)
void            GetVectorForKey(const entity_t* const ent, const char* const key, vec3_t vec)
{
    const char*     k;
    double          v1, v2, v3;

    k = ValueForKey(ent, key);
    // scanf into doubles, then assign, so it is vec_t size independent
    v1 = v2 = v3 = 0;
    sscanf(k, "%lf %lf %lf", &v1, &v2, &v3);
    vec[0] = v1;
    vec[1] = v2;
    vec[2] = v3;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, %rbx
callq 0x69ab
movq %rsp, %r14
andq $0x0, (%r14)
leaq 0x8(%rsp), %r15
andq $0x0, (%r15)
leaq 0x10(%rsp), %r12
andq $0x0, (%r12)
leaq 0x15ba9(%rip), %rsi     # 0x1cfc9
movq %rax, %rdi
movq %r12, %rdx
movq %r15, %rcx
movq %r14, %r8
xorl %eax, %eax
callq 0x42f0
movsd (%r12), %xmm0
movsd %xmm0, (%rbx)
movsd (%r15), %xmm0
movsd %xmm0, 0x8(%rbx)
movsd (%r14), %xmm0
movsd %xmm0, 0x10(%rbx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: dtexdata_init()
void            dtexdata_init()
{
    g_dtexdata = (byte*)AllocBlock(g_max_map_miptex);
    hlassume(g_dtexdata != NULL, assume_NoMemory);
	g_dlightdata = (byte*)AllocBlock(g_max_map_lightdata);
	hlassume(g_dlightdata != NULL, assume_NoMemory);
}

// Assembly:
pushq %rbx
movslq 0x1eedb(%rip), %rdi     # 0x26340
callq 0x47fc
movq %rax, 0x828057(%rip)    # 0x82f4c8
xorl %edi, %edi
testq %rax, %rax
setne %dil
pushq $0x1
popq %rbx
movl %ebx, %esi
callq 0x9517
movslq 0x1eeb9(%rip), %rdi     # 0x26344
callq 0x47fc
movq %rax, 0x828021(%rip)    # 0x82f4b8
xorl %edi, %edi
testq %rax, %rax
setne %dil
movl %ebx, %esi
popq %rbx
jmp 0x9517
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: dtexdata_free()
void CDECL      dtexdata_free()
{
    FreeBlock(g_dtexdata);
    g_dtexdata = NULL;
	FreeBlock(g_dlightdata);
	g_dlightdata = NULL;
}

// Assembly:
pushq %rax
movq 0x828018(%rip), %rdi    # 0x82f4c8
callq 0x481f
andq $0x0, 0x82800b(%rip)    # 0x82f4c8
movq 0x827ff4(%rip), %rdi    # 0x82f4b8
callq 0x481f
andq $0x0, 0x827fe7(%rip)    # 0x82f4b8
popq %rax
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/bspfile.cpp
// Function: EntityForModel(int)
entity_t*       EntityForModel(const int modnum)
{
    int             i;
    const char*     s;
    char            name[16];

    sprintf(name, "*%i", modnum);
    // search the entities for one using modnum
    for (i = 0; i < g_numentities; i++)
    {
        s = ValueForKey(&g_entities[i], "model");
        if (!strcmp(s, name))
        {
            return &g_entities[i];
        }
    }

    return &g_entities[0];
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %edi, %edx
leaq 0x12230(%rip), %rsi     # 0x1971a
movq %rsp, %rbx
movq %rbx, %rdi
xorl %eax, %eax
callq 0x40c0
movslq 0x2015f56(%rip), %r12   # 0x201d454
leaq 0x2015f5b(%rip), %r14   # 0x201d460
pushq $-0x1
popq %r13
leaq 0x15990(%rip), %r15     # 0x1cea0
movq %r14, %rdi
incq %r13
cmpq %r12, %r13
jge 0x7540
leaq 0x28(%rdi), %rbp
movq %r15, %rsi
callq 0x69ab
movq %rax, %rdi
movq %rbx, %rsi
callq 0x4480
movq %rbp, %rdi
testl %eax, %eax
jne 0x7513
addq $-0x28, %rbp
movq %rbp, %r14
movq %r14, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlib.cpp
// Function: strupr(char*)
char*           strupr(char* string)
{
    int             i;
    int             len = strlen(string);

    for (i = 0; i < len; i++)
    {
        string[i] = toupper(string[i]);
    }
    return string;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
callq 0x4190
movq %rax, %r14
xorl %r15d, %r15d
testl %r14d, %r14d
cmovlel %r15d, %r14d
cmpq %r15, %r14
je 0x75e4
movsbl (%rbx,%r15), %edi
callq 0x4600
movb %al, (%rbx,%r15)
incq %r15
jmp 0x75cc
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlib.cpp
// Function: strlwr(char*)
char*           strlwr(char* string)
{
    int             i;
    int             len = strlen(string);

    for (i = 0; i < len; i++)
    {
        string[i] = tolower(string[i]);
    }
    return string;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
callq 0x4190
movq %rax, %r14
xorl %r15d, %r15d
testl %r14d, %r14d
cmovlel %r15d, %r14d
cmpq %r15, %r14
je 0x761f
movsbl (%rbx,%r15), %edi
callq 0x44c0
movb %al, (%rbx,%r15)
incq %r15
jmp 0x7607
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlib.cpp
// Function: stristr(char const*, char const*)
const char*     stristr(const char* const string, const char* const substring)
{
    char*           string_copy;
    char*           substring_copy;
    const char*     match;

    string_copy = _strdup(string);
    _strlwr(string_copy);

    substring_copy = _strdup(substring);
    _strlwr(substring_copy);

    match = strstr(string_copy, substring_copy);
    if (match)
    {
        match = (string + (match - string_copy));
    }

    free(string_copy);
    free(substring_copy);
    return match;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
callq 0x45d0
movq %rax, %r15
movq %rax, %rdi
callq 0x75ed
movq %rbx, %rdi
callq 0x45d0
movq %rax, %rbx
movq %rax, %rdi
callq 0x75ed
movq %r15, %rdi
movq %rbx, %rsi
callq 0x4100
movq %rax, %r12
subq %r15, %rax
addq %r14, %rax
testq %r12, %r12
cmovneq %rax, %r12
movq %r15, %rdi
callq 0x43b0
movq %rbx, %rdi
callq 0x43b0
movq %r12, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlib.cpp
// Function: FlipSlashes(char*)
char* FlipSlashes(char* string)
{
	char* ptr = string;
	if(SYSTEM_SLASH_CHAR == '\\')
	{
		while(ptr = strchr(ptr,'/'))
		{ *ptr = SYSTEM_SLASH_CHAR; }
	}
	else
	{
		while(ptr = strchr(ptr,'\\'))
		{ *ptr = SYSTEM_SLASH_CHAR; }
	}
	return string;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
pushq $0x5c
popq %rbp
movq %rdi, %rax
movq %rax, %rdi
movl %ebp, %esi
callq 0x4160
testq %rax, %rax
je 0x76b3
movb $0x2f, (%rax)
jmp 0x769f
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlib.cpp
// Function: ExtractFilePath(char const*, char*)
void ExtractFilePath(const char* const path, char* dest)
{
	int extension_pos, directory_pos;
	getFilePositions(path,&extension_pos,&directory_pos);
	if(directory_pos != -1)
	{
	    memcpy(dest,path,directory_pos+1); //include directory slash
	    dest[directory_pos+1] = 0;
	}
	else
	{ dest[0] = 0; }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0xc(%rsp), %rsi
leaq 0x8(%rsp), %r15
movq %r15, %rdx
callq 0x79e0
movslq (%r15), %r15
cmpq $-0x1, %r15
je 0x7795
leaq 0x1(%r15), %rdx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4280
addq %r15, %rbx
incq %rbx
movb $0x0, (%rbx)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlib.cpp
// Function: ExtractFile(char const*, char*)
void ExtractFile(const char* const path, char* dest)
{
	int extension_pos, directory_pos;
	getFilePositions(path,&extension_pos,&directory_pos);

	int length = strlen(path);

#ifdef ZHLT_FILE_FUNCTIONS_FIX
	length -= directory_pos + 1;
#else
	if(directory_pos == -1)	{ directory_pos = 0; }
	else { length -= directory_pos + 1; }
#endif

    memcpy(dest,path+directory_pos+1,length); //exclude directory slash
    dest[length] = 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0xc(%rsp), %rsi
leaq 0x8(%rsp), %r15
movq %r15, %rdx
callq 0x79e0
movq %r14, %rdi
callq 0x4190
movslq (%r15), %rcx
leaq (%r14,%rcx), %rsi
incq %rsi
notl %ecx
addl %eax, %ecx
movslq %ecx, %r14
movq %rbx, %rdi
movq %r14, %rdx
callq 0x4280
movb $0x0, (%rbx,%r14)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlib.cpp
// Function: ExtractFileBase(char const*, char*)
void ExtractFileBase(const char* const path, char* dest)
{
	int extension_pos, directory_pos;
	getFilePositions(path,&extension_pos,&directory_pos);
	int length = extension_pos == -1 ? strlen(path) : extension_pos;

#ifdef ZHLT_FILE_FUNCTIONS_FIX
	length -= directory_pos + 1;
#else
	if(directory_pos == -1)	{ directory_pos = 0; }
	else { length -= directory_pos + 1; }
#endif

    memcpy(dest,path+directory_pos+1,length); //exclude directory slash
    dest[length] = 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0xc(%rsp), %r15
leaq 0x8(%rsp), %rdx
movq %r15, %rsi
callq 0x79e0
movl (%r15), %eax
cmpl $-0x1, %eax
jne 0x7827
movq %r14, %rdi
callq 0x4190
movslq 0x8(%rsp), %rcx
leaq (%r14,%rcx), %rsi
incq %rsi
notl %ecx
addl %eax, %ecx
movslq %ecx, %r14
movq %rbx, %rdi
movq %r14, %rdx
callq 0x4280
movb $0x0, (%rbx,%r14)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlib.cpp
// Function: ExtractFileExtension(char const*, char*)
void ExtractFileExtension(const char* const path, char* dest)
{
	int extension_pos, directory_pos;
	getFilePositions(path,&extension_pos,&directory_pos);
	if(extension_pos != -1)
	{
		int length = strlen(path) - extension_pos;
	    memcpy(dest,path+extension_pos,length); //include extension '.'
	    dest[length] = 0;
	}
	else
	{ dest[0] = 0; }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
leaq 0xc(%rsp), %r15
leaq 0x8(%rsp), %rdx
movq %r15, %rsi
callq 0x79e0
movslq (%r15), %r15
cmpq $-0x1, %r15
je 0x78a0
movq %r14, %rdi
callq 0x4190
subl %r15d, %eax
addq %r15, %r14
movslq %eax, %r15
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x4280
addq %r15, %rbx
movb $0x0, (%rbx)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlib.cpp
// Function: safe_strncat(char*, char const*, unsigned long)
bool            safe_strncat(char* const dest, const char* const src, const size_t count)
{
    if (count)
    {
        strncat(dest, src, count);

        dest[count - 1] = 0;                               // Ensure it is null terminated
        return true;
    }
    else
    {
        Warning("safe_strncat passed empty count");
        return false;
    }
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
testq %rdx, %rdx
je 0x79a3
movq %rdi, %r14
movq %rbx, %rdx
callq 0x4230
movb $0x0, -0x1(%r14,%rbx)
jmp 0x79b1
leaq 0x11eae(%rip), %rdi     # 0x19858
xorl %eax, %eax
callq 0x90f1
testq %rbx, %rbx
setne %al
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlib.cpp
// Function: getFilePositions(char const*, int*, int*)
inline void getFilePositions(const char* path, int* extension_position, int* directory_position)
{
	const char* ptr = strrchr(path,'.');
	if(ptr == 0)
	{ *extension_position = -1; }
	else
	{ *extension_position = ptr - path; }

	ptr = qmax(strrchr(path,'/'),strrchr(path,'\\'));
	if(ptr == 0)
	{ *directory_position = -1; }
	else
	{ 
		*directory_position = ptr - path;
		if(*directory_position > *extension_position)
		{ *extension_position = -1; }
		
		//cover the case where we were passed a directory - get 2nd-to-last slash
		if(*directory_position == (int)strlen(path) - 1)
		{
			do
			{
				--(*directory_position);
			}
			while(*directory_position > -1 && path[*directory_position] != '/' && path[*directory_position] != '\\');
		}
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
pushq $0x2e
popq %rsi
callq 0x4360
movl %eax, %ecx
subl %r14d, %ecx
xorl %edx, %edx
cmpq $0x1, %rax
sbbl %edx, %edx
orl %ecx, %edx
movl %edx, (%r15)
pushq $0x2f
popq %rsi
movq %r14, %rdi
callq 0x4360
movq %rax, %r13
pushq $0x5c
popq %rsi
movq %r14, %rdi
callq 0x4360
movq %rax, %r12
cmpq %rax, %r13
cmovaq %r13, %r12
testq %r12, %r12
je 0x7a77
subl %r14d, %r12d
movl %r12d, (%rbx)
cmpl %r12d, (%r15)
jge 0x7a46
orl $-0x1, (%r15)
movl (%rbx), %r12d
movq %r14, %rdi
callq 0x4190
decl %eax
cmpl %eax, %r12d
jne 0x7a7a
movl %r12d, %eax
movq %rax, %rcx
decq %rax
movl %eax, (%rbx)
testl %ecx, %ecx
jle 0x7a7a
movl %eax, %ecx
movzbl (%r14,%rcx), %ecx
cmpl $0x5c, %ecx
je 0x7a7a
cmpl $0x2f, %ecx
jne 0x7a58
jmp 0x7a7a
orl $-0x1, (%rbx)
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlinecfg.cpp
// Function: pmatch(char const*, char const*)
bool pmatch (const char *cmdlineparam, const char *param)
{
	int cl, cstart, cend, pl, pstart, pend, k;
	cl = plen (cmdlineparam);
	pl = plen (param);
	if (cl < 0 || pl < 0)
		return false;
	bool anystart = (pl > 0 && param[0] == '*');
	bool anyend = (pl > 0 && param[pl-1] == '*');
	pstart = anystart ? 1 : 0;
	pend = anyend ? pl-1 : pl;
	if (pend < pstart) pend = pstart;
	for (cstart = 0; cstart <= cl; ++cstart)
	{
		for (cend = cl; cend >= cstart; --cend)
		{
			if (cend - cstart == pend - pstart)
			{
				for (k = 0; k < cend - cstart; ++k)
					if (tolower (cmdlineparam[k+cstart]) != tolower (param[k+pstart]))
						break;
				if (k == cend - cstart)
					return true;
			}
			if (!anyend)
				break;
		}
		if (!anystart)
			break;
	}
	return false;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %rbx
movq %rdi, %r14
callq 0x7a84
movl %eax, %ebp
movq %rbx, %rdi
callq 0x7a84
movl %eax, %ecx
orl %ebp, %ecx
js 0x7b8a
testl %eax, %eax
jle 0x7aee
cmpb $0x2a, (%rbx)
sete %sil
movl %eax, %ecx
cmpb $0x2a, -0x1(%rbx,%rcx)
sete %dil
jmp 0x7af2
xorl %esi, %esi
xorl %edi, %edi
movzbl %sil, %edx
movzbl %dil, %ecx
subl %ecx, %eax
cmpl %edx, %eax
cmovlel %edx, %eax
subl %edx, %eax
movslq %ebp, %r15
addq %rdx, %rbx
xorl %ecx, %ecx
movq %rax, 0x18(%rsp)
movl %esi, 0x8(%rsp)
movl %edi, 0xc(%rsp)
movq %r15, 0x10(%rsp)
cmpq %r15, %rcx
jg 0x7b8a
movq %rcx, 0x20(%rsp)
movq %r15, %r13
subq %rcx, %r13
jl 0x7b76
cmpl %r13d, %eax
jne 0x7b6e
xorl %r12d, %r12d
cmpq %r13, %r12
jge 0x7b5b
movsbl (%r14,%r12), %edi
callq 0x44c0
movl %eax, %ebp
movsbl (%rbx,%r12), %edi
callq 0x44c0
cmpl %eax, %ebp
jne 0x7b5b
incq %r12
jmp 0x7b37
movq 0x18(%rsp), %rax
cmpl %r12d, %eax
movl 0xc(%rsp), %edi
movq 0x20(%rsp), %rcx
je 0x7b8e
decq %r15
testb %dil, %dil
jne 0x7b27
incq %rcx
incq %r14
movl 0x8(%rsp), %esi
testb %sil, %sil
movq 0x10(%rsp), %r15
jne 0x7b1d
xorl %eax, %eax
jmp 0x7b90
movb $0x1, %al
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlinecfg.cpp
// Function: findparams(char*, char*)
char * findparams (char *cmdlineparams, char *params)
{
	char *c1, *c, *p;
	for (c1 = cmdlineparams; pvalid (c1); c1 = pnext (c1))
	{
		for (c = c1, p = params; pvalid (p); c = pnext (c), p = pnext (p))
			if (!pvalid (c) || !pmatch (c, p))
				break;
		if (!pvalid (p))
			return c1;
	}
	return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq %rbx, %rdi
callq 0x7a9c
testb %al, %al
je 0x7c1e
movq %rbx, %r15
movq %r14, %r12
movq %r12, %rdi
callq 0x7a9c
testb %al, %al
je 0x7c20
movq %r15, %rdi
callq 0x7a9c
testb %al, %al
je 0x7c11
movq %r15, %rdi
movq %r12, %rsi
callq 0x7aa9
testb %al, %al
je 0x7c11
movq %r15, %rdi
callq 0x7b9f
movq %rax, %r15
movq %r12, %rdi
callq 0x7b9f
movq %rax, %r12
jmp 0x7bd2
movq %rbx, %rdi
callq 0x7b9f
movq %rax, %rbx
jmp 0x7bc0
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlinecfg.cpp
// Function: delparams(char*, char*)
void delparams (char *cmdline, char *params)
{
	char *c, *p;
	if (!pvalid (params)) //avoid infinite loop
		return;
	while (cmdline = findparams (cmdline, params), cmdline != NULL)
	{
		for (c = cmdline, p = params; pvalid (p); c = pnext (c), p = pnext (p))
			;
		memmove (cmdline, c, strlen (c) + 1);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq %rsi, %rdi
callq 0x7a9c
testb %al, %al
je 0x7cf2
movq %r14, %rdi
movq %rbx, %rsi
callq 0x7bb2
testq %rax, %rax
je 0x7cf2
movq %rax, %r14
movq %rax, %r15
movq %rbx, %r12
movq %r12, %rdi
callq 0x7a9c
testb %al, %al
je 0x7cd9
movq %r15, %rdi
callq 0x7b9f
movq %rax, %r15
movq %r12, %rdi
callq 0x7b9f
movq %rax, %r12
jmp 0x7cb5
movq %r15, %rdi
callq 0x4190
leaq 0x1(%rax), %rdx
movq %r14, %rdi
movq %r15, %rsi
callq 0x4550
jmp 0x7c9c
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlinecfg.cpp
// Function: parsecommand(execute_t&, char*, char*, unsigned int)
void parsecommand (execute_t &e, char *cmdline, char *words, unsigned int n)
{
	command_t t;
	if (!pvalid (words))
		return;
	if (pmatch (words, "#ifdef" SEPSTR))
		t = IFDEF;
	else if (pmatch (words, "#ifndef" SEPSTR))
		t = IFNDEF;
	else if (pmatch (words, "#else" SEPSTR))
		t = ELSE;
	else if (pmatch (words, "#endif" SEPSTR))
		t = ENDIF;
	else if (pmatch (words, "#define" SEPSTR))
		t = DEFINE;
	else if (pmatch (words, "#undef" SEPSTR))
		t = UNDEF;
	else
		return;
	if (t == IFDEF || t == IFNDEF)
	{
		e.stack ++;
		if (!e.skip)
		{
			if (t == IFDEF && findparams (cmdline, pnext (words)) ||
				t == IFNDEF && !findparams (cmdline, pnext (words)))
				e.skip = false;
			else
			{
				e.skipstack = e.stack;
				e.skip = true;
			}
		}
	}
	else if (t == ELSE)
	{
		if (e.skip)
		{
			if (e.stack == e.skipstack)
				e.skip = false;
		}
		else
		{
			e.skipstack = e.stack;
			e.skip = true;
		}
	}
	else if (t == ENDIF)
	{
		if (e.skip)
		{
			if (e.stack == e.skipstack)
				e.skip = false;
		}
		e.stack --;
	}
	else
	{
		if (!e.skip)
		{
			if (t == DEFINE)
				addparams (cmdline, pnext(words), n);
			if (t == UNDEF)
				delparams (cmdline, pnext(words));
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %ecx, %ebp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movq %rdx, %rdi
callq 0x7a9c
testb %al, %al
je 0x7dd2
leaq 0x11b50(%rip), %rsi     # 0x19878
movq %r15, %rdi
callq 0x7aa9
movl %eax, %r12d
testb %al, %al
jne 0x7d4a
leaq 0x11b42(%rip), %rsi     # 0x19880
movq %r15, %rdi
callq 0x7aa9
testb %al, %al
je 0x7d7a
movl (%rbx), %ebp
incl %ebp
movl %ebp, (%rbx)
cmpb $0x0, 0x4(%rbx)
jne 0x7dd2
movq %r15, %rdi
callq 0x7b9f
movq %r14, %rdi
movq %rax, %rsi
callq 0x7bb2
testq %rax, %rax
sete %al
cmpb %al, %r12b
je 0x7d9c
movb $0x0, 0x4(%rbx)
jmp 0x7dd2
leaq 0x11b08(%rip), %rsi     # 0x19889
movq %r15, %rdi
callq 0x7aa9
testb %al, %al
je 0x7da1
movl (%rbx), %eax
cmpb $0x1, 0x4(%rbx)
jne 0x7dcb
cmpl 0x8(%rbx), %eax
je 0x7d74
jmp 0x7dd2
movl %ebp, 0x8(%rbx)
jmp 0x7dce
leaq 0x11ae8(%rip), %rsi     # 0x19890
movq %r15, %rdi
callq 0x7aa9
testb %al, %al
je 0x7ddb
movl (%rbx), %eax
cmpb $0x1, 0x4(%rbx)
jne 0x7dc5
cmpl 0x8(%rbx), %eax
jne 0x7dc5
movb $0x0, 0x4(%rbx)
decl %eax
movl %eax, (%rbx)
jmp 0x7dd2
movl %eax, 0x8(%rbx)
movb $0x1, 0x4(%rbx)
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x11ab6(%rip), %rsi     # 0x19898
movq %r15, %rdi
callq 0x7aa9
testb %al, %al
je 0x7e11
cmpb $0x0, 0x4(%rbx)
jne 0x7dd2
movq %r15, %rdi
callq 0x7b9f
movq %r14, %rdi
movq %rax, %rsi
movl %ebp, %edx
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x7c2f
leaq 0x11a89(%rip), %rsi     # 0x198a1
movq %r15, %rdi
callq 0x7aa9
testb %al, %al
je 0x7dd2
cmpb $0x0, 0x4(%rbx)
jne 0x7dd2
movq %r15, %rdi
callq 0x7b9f
movq %r14, %rdi
movq %rax, %rsi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x7c82
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlinecfg.cpp
// Function: nextword(char const*, char*, unsigned int)
const char * nextword (const char *s, char *token, unsigned int n)
{
	unsigned int i;
	const char *c;
	bool quote, comment, content;
	for (c=s, i=0, quote=false, comment=false, content=false; c[0] != '\0'; c++)
	{
		if (c[0]=='\"')
			quote = !quote;
		if (c[0]=='\n')
			quote = false;
		if (c[0]=='\n')
			comment = false;
		if (!quote && c[0]=='/' && c[1]=='/')
			comment = true;
		if (!comment && !(c[0]=='\n' || isspace (c[0])))
			content = true;
		if (!quote && !comment && content && (c[0]=='\n' || isspace (c[0])))
			break;
		if (content && c[0]!='\"')
			if (i<n-1)
				token[i++] = c[0];
			else
				error = true;
	}
	token[i] = '\0';
	return content? c: NULL;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, 0x10(%rsp)
movq %rdi, %rbx
decl %edx
movl %edx, 0xc(%rsp)
xorl %r12d, %r12d
xorl %r14d, %r14d
xorl %eax, %eax
xorl %r13d, %r13d
movzbl (%rbx), %ebp
movl %r12d, %esi
cmpl $0x22, %ebp
je 0x7e80
testl %ebp, %ebp
jne 0x7e84
jmp 0x7f41
xorb $0x1, %r14b
movl %r14d, %ecx
cmpb $0xa, %bpl
setne %r14b
andb %cl, %r14b
cmpb $0x2f, %bpl
setne %dl
orb %cl, %dl
testb $0x1, %dl
je 0x7eaf
cmpb $0xa, %bpl
setne %cl
testb %al, %cl
je 0x7ec1
movb $0x1, %al
jmp 0x7f11
cmpb $0x2f, 0x1(%rbx)
sete %cl
orb %al, %cl
movb $0x1, %al
testb $0x1, %cl
je 0x7ec7
jmp 0x7f11
cmpb $0xa, %bpl
je 0x7f09
movq %rsi, (%rsp)
movsbl %bpl, %r15d
movl %r15d, %edi
callq 0x4080
testl %eax, %eax
movzbl %r13b, %r13d
pushq $0x1
popq %rax
cmovel %eax, %r13d
testb %r14b, %r14b
jne 0x7f01
testb $0x1, %r13b
je 0x7f01
cmpb $0xa, %bpl
je 0x7f4d
movl %r15d, %edi
callq 0x4080
testl %eax, %eax
jne 0x7f4d
xorl %eax, %eax
movq (%rsp), %rsi
jmp 0x7f11
testb $0x1, %r13b
jne 0x7f51
xorl %eax, %eax
cmpb $0x22, %bpl
je 0x7f39
testb $0x1, %r13b
je 0x7f39
cmpl 0xc(%rsp), %r12d
jae 0x7f32
incl %r12d
movq 0x10(%rsp), %rcx
movb %bpl, (%rcx,%rsi)
jmp 0x7f39
movb $0x1, 0x20b552f(%rip)   # 0x20bd468
incq %rbx
jmp 0x7e6c
xorl %eax, %eax
testb $0x1, %r13b
cmoveq %rax, %rbx
jmp 0x7f51
movq (%rsp), %rsi
movq 0x10(%rsp), %rax
movb $0x0, (%rax,%rsi)
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlinecfg.cpp
// Function: parsearg(int, char**, char*, unsigned int)
void parsearg (int argc, char ** argv, char *cmdline, unsigned int n)
{
	int i;
	strcpy (cmdline, "");
	strcat (cmdline, "<");
	strcat (cmdline, g_Program);
	strcat (cmdline, ">");
	strcat (cmdline, SEPSTR);
	for (i=1; i<argc; ++i)
	{
		if (strlen (cmdline) + strlen (argv[i]) + strlen (SEPSTR) + 1 <= n)
		{
			strcat (cmdline, argv[i]);
			strcat (cmdline, SEPSTR);
		}
		else
			error = true;
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %ebp
movq %rdx, %rbx
movq %rsi, (%rsp)
movl %edi, %r15d
movb $0x0, (%rdx)
movq %rdx, %rdi
callq 0x4190
movw $0x3c, (%rbx,%rax)
leaq 0x1e3b5(%rip), %rax     # 0x26350
movq (%rax), %rsi
movq %rbx, %rdi
callq 0x45a0
movq %rbx, %rdi
callq 0x4190
movw $0x3e, (%rbx,%rax)
movq %rbx, %rdi
callq 0x4190
movw $0xa, (%rbx,%rax)
movl %ebp, %r13d
movslq %r15d, %rbp
pushq $0x1
popq %r14
cmpq %rbp, %r14
jge 0x801f
movq %rbx, %rdi
callq 0x4190
movq %rax, %r12
movq (%rsp), %rax
movq (%rax,%r14,8), %r15
movq %r15, %rdi
callq 0x4190
addq %r12, %rax
addq $0x2, %rax
cmpq %r13, %rax
jbe 0x8001
movb $0x1, 0x20b5469(%rip)   # 0x20bd468
jmp 0x801a
movq %rbx, %rdi
movq %r15, %rsi
callq 0x45a0
movq %rbx, %rdi
callq 0x4190
movw $0xa, (%rbx,%rax)
incq %r14
jmp 0x7fcc
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/cmdlinecfg.cpp
// Function: unparsearg(int&, char**&, char*)
void unparsearg (int &argc, char **&argv, char *cmdline)
{
	char *c;
	int i, j;
	i = 0;
	for (c = cmdline; pvalid (c); c = pnext (c))
		i++;
	argc = i;
	argv = (char **)malloc (argc * sizeof (char *));
	if (!argv)
	{
		error = true;
		return;
	}
	for (c = cmdline, i = 0; pvalid (c); c = pnext (c), i++)
	{
		argv[i] = (char *)malloc (plen (c) + 1);
		if (!argv[i])
		{
			error = true;
			return;
		}
		for (j = 0; j < plen (c); j++)
			argv[i][j] = c[j];
		argv[i][j] = '\0';
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %rbx
movq %rdi, %r12
xorl %r15d, %r15d
movq %rdx, %r13
xorl %ebp, %ebp
movq %r13, %rdi
callq 0x7a9c
testb %al, %al
je 0x8069
incl %ebp
movq %r13, %rdi
callq 0x7b9f
movq %rax, %r13
addq $0x8, %r15
jmp 0x804a
movl %ebp, (%r12)
movq %r15, %rdi
callq 0x4450
movq %rax, (%rbx)
testq %rax, %rax
je 0x80f1
xorl %r15d, %r15d
movq %r14, %rdi
callq 0x7a9c
testb %al, %al
je 0x80f8
movq %r14, %rdi
callq 0x7a84
incl %eax
movslq %eax, %rdi
callq 0x4450
movq (%rbx), %rcx
movq %rax, (%rcx,%r15,8)
movq (%rbx), %rax
cmpq $0x0, (%rax,%r15,8)
je 0x80f1
xorl %r12d, %r12d
movq %r14, %rdi
callq 0x7a84
cltq
cmpq %rax, %r12
jge 0x80d5
movb (%r14,%r12), %al
movq (%rbx), %rcx
movq (%rcx,%r15,8), %rcx
movb %al, (%rcx,%r12)
incq %r12
jmp 0x80b2
movq (%rbx), %rax
movq (%rax,%r15,8), %rax
movb $0x0, (%rax,%r12)
movq %r14, %rdi
callq 0x7b9f
movq %rax, %r14
incq %r15
jmp 0x8080
movb $0x1, 0x20b5370(%rip)   # 0x20bd468
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/filelib.cpp
// Function: getfiletime(char const*)
time_t          getfiletime(const char* const filename)
{
    time_t          filetime = 0;
    struct stat     filestat;

    if (stat(filename, &filestat) == 0)
        filetime = qmax(filestat.st_mtime, filestat.st_ctime);

    return filetime;
}

// Assembly:
subq $0x98, %rsp
leaq 0x8(%rsp), %rsi
callq 0x42c0
testl %eax, %eax
je 0x839b
xorl %eax, %eax
addq $0x98, %rsp
retq
movq 0x60(%rsp), %rcx
movq 0x70(%rsp), %rax
cmpq %rax, %rcx
cmovgq %rcx, %rax
addq $0x98, %rsp
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/filelib.cpp
// Function: getfiledata(char const*, char*, int)
long            getfiledata(const char* const filename, char* buffer, const int buffersize)
{
    long            size = 0;
    int             handle;
    time_t            start, end;

    time(&start);

    if ((handle = _open(filename, O_RDONLY)) != -1)
    {
        int             bytesread;

        Log("%-20s Restoring [%-13s - ", "BuildVisMatrix:", filename);
        while ((bytesread = _read(handle, buffer, qmin(32 * 1024, buffersize - size))) > 0)
        {
            size += bytesread;
            buffer += bytesread;
        }
        _close(handle);
        time(&end);
        Log("%10.3fMB] (%d)\n", size / (1024.0 * 1024.0), (int)(end - start));
    }

    if (buffersize != size)
    {
        Warning("Invalid file [%s] found.  File will be rebuilt!\n", filename);
        _unlink(filename);
    }

    return size;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %edx, %r12d
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x8(%rsp), %rdi
callq 0x42d0
movq %rbx, %rdi
xorl %esi, %esi
xorl %eax, %eax
callq 0x4250
cmpl $-0x1, %eax
je 0x8496
movl %eax, %ebp
leaq 0x1249f(%rip), %rdi     # 0x1a8b8
leaq 0x124b2(%rip), %rsi     # 0x1a8d2
xorl %r14d, %r14d
movq %rbx, %rdx
xorl %eax, %eax
callq 0x89dc
movslq %r12d, %r12
movl $0x8000, %r13d          # imm = 0x8000
movq %r12, %rdx
subq %r14, %rdx
cmpq %r13, %rdx
cmovgeq %r13, %rdx
movl %ebp, %edi
movq %r15, %rsi
callq 0x44b0
testl %eax, %eax
jle 0x845e
andl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
addq %rax, %r14
addq %rax, %r15
jmp 0x8436
movl %ebp, %edi
callq 0x4650
leaq 0x10(%rsp), %r15
movq %r15, %rdi
callq 0x42d0
cvtsi2sd %r14, %xmm0
mulsd 0x12431(%rip), %xmm0    # 0x1a8b0
movl (%r15), %esi
subl 0x8(%rsp), %esi
leaq 0x12455(%rip), %rdi     # 0x1a8e2
movb $0x1, %al
callq 0x89dc
jmp 0x849c
movslq %r12d, %r12
xorl %r14d, %r14d
cmpq %r12, %r14
je 0x84ba
leaq 0x1244a(%rip), %rdi     # 0x1a8f2
movq %rbx, %rsi
xorl %eax, %eax
callq 0x90f1
movq %rbx, %rdi
callq 0x41b0
movq %r14, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/filelib.cpp
// Function: q_filelength(_IO_FILE*)
int             q_filelength(FILE* f)
{
    int             pos;
    int             end;

    pos = ftell(f);
    fseek(f, 0, SEEK_END);
    end = ftell(f);
    fseek(f, pos, SEEK_SET);

    return end;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
callq 0x4030
movq %rax, %r14
pushq $0x2
popq %rdx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x4370
movq %rbx, %rdi
callq 0x4030
movq %rax, %r15
movslq %r14d, %rsi
movq %rbx, %rdi
xorl %edx, %edx
callq 0x4370
movl %r15d, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/filelib.cpp
// Function: SafeOpenWrite(char const*)
FILE*           SafeOpenWrite(const char* const filename)
{
    FILE*           f;

    f = fopen(filename, "wb");

    if (!f)
        Error("Error opening %s: %s", filename, strerror(errno));

    return f;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x123e9(%rip), %rsi     # 0x1a926
callq 0x43a0
movq %rax, %r14
testq %rax, %rax
jne 0x856a
callq 0x4060
movl (%rax), %edi
callq 0x4140
leaq 0x10bae(%rip), %rdi     # 0x1910b
movq %rbx, %rsi
movq %rax, %rdx
xorl %eax, %eax
callq 0x8d7b
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/filelib.cpp
// Function: SafeOpenRead(char const*)
FILE*           SafeOpenRead(const char* const filename)
{
    FILE*           f;

    f = fopen(filename, "rb");

    if (!f)
        Error("Error opening %s: %s", filename, strerror(errno));

    return f;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x123a0(%rip), %rsi     # 0x1a923
callq 0x43a0
movq %rax, %r14
testq %rax, %rax
jne 0x85b0
callq 0x4060
movl (%rax), %edi
callq 0x4140
leaq 0x10b68(%rip), %rdi     # 0x1910b
movq %rbx, %rsi
movq %rax, %rdx
xorl %eax, %eax
callq 0x8d7b
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/filelib.cpp
// Function: LoadFile(char const*, char**)
int             LoadFile(const char* const filename, char** bufferptr)
{
    FILE*           f;
    int             length;
    char*           buffer;

    f = SafeOpenRead(filename);
    length = q_filelength(f);
    buffer = (char*)Alloc(length + 1);
    SafeRead(f, buffer, length);
    fclose(f);

    *bufferptr = buffer;
    return length;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
callq 0x8575
movq %rax, %r14
movq %rax, %rdi
callq 0x84cc
movl %eax, %r15d
leal 0x1(%r15), %eax
movslq %eax, %rdi
callq 0x4842
movq %rax, %r12
movq %r14, %rdi
movq %rax, %rsi
movl %r15d, %edx
callq 0x85bb
movq %r14, %rdi
callq 0x4300
movq %r12, (%rbx)
movl %r15d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/log.cpp
// Function: CheckForErrorLog()
void            CheckForErrorLog()
{
    if (g_log)
    {
        char            logfilename[_MAX_PATH];

        safe_snprintf(logfilename, _MAX_PATH, "%s.err", g_Mapname);
        if (q_exists(logfilename))
        {
            Log(">> There was a problem compiling the map.\n"
                ">> Check the file %s.log for the cause.\n",
                 g_Mapname);
            exit(1);
        }
    }
}

// Assembly:
pushq %rbx
subq $0x1000, %rsp           # imm = 0x1000
cmpb $0x1, 0x1e9d8(%rip)     # 0x27360
jne 0x89b6
leaq 0x1207c(%rip), %rdx     # 0x1aa0d
leaq 0x1d9c8(%rip), %rcx     # 0x26360
movq %rsp, %rbx
movl $0x1000, %esi           # imm = 0x1000
movq %rbx, %rdi
xorl %eax, %eax
callq 0x78cb
movq %rbx, %rdi
callq 0x850a
testb %al, %al
jne 0x89bf
addq $0x1000, %rsp           # imm = 0x1000
popq %rbx
retq
leaq 0x1204e(%rip), %rdi     # 0x1aa14
leaq 0x1d993(%rip), %rsi     # 0x26360
xorl %eax, %eax
callq 0x89dc
pushq $0x1
popq %rdi
callq 0x43c0
// File: /workspace/github_cpp_makefile_star2_O2/FreeSlave[P]vhlt/common/log.cpp
// Function: Log(char const*, ...)
void CDECL FORMAT_PRINTF(1,2)      Log(const char* const warning, ...)
{
    char            message[MAX_MESSAGE];

    va_list         argptr;

    va_start(argptr, warning);
#ifdef ZHLT_LANGFILE
    vsnprintf(message, MAX_MESSAGE, Localize (warning), argptr);
#else
    vsnprintf(message, MAX_MESSAGE, warning, argptr);
#endif
    va_end(argptr);

    WriteLog(message);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x8d8, %rsp            # imm = 0x8D8
leaq 0x20(%rsp), %r10
movq %rsi, 0x8(%r10)
movq %rdx, 0x10(%r10)
movq %rcx, 0x18(%r10)
movq %r8, 0x20(%r10)
movq %r9, 0x28(%r10)
testb %al, %al
je 0x8a3a
movaps %xmm0, 0x50(%rsp)
movaps %xmm1, 0x60(%rsp)
movaps %xmm2, 0x70(%rsp)
movaps %xmm3, 0x80(%rsp)
movaps %xmm4, 0x90(%rsp)
movaps %xmm5, 0xa0(%rsp)
movaps %xmm6, 0xb0(%rsp)
movaps %xmm7, 0xc0(%rsp)
movq %rsp, %rbx
movq %r10, 0x10(%rbx)
leaq 0x8f0(%rsp), %rax
movq %rax, 0x8(%rbx)
movabsq $0x3000000008, %rax     # imm = 0x3000000008
movq %rax, (%rbx)
callq 0x8b86
leaq 0xd0(%rsp), %r14
movl $0x800, %esi            # imm = 0x800
movq %r14, %rdi
movq %rax, %rdx
movq %rbx, %rcx
callq 0x4200
movq %r14, %rdi
callq 0x8cf4
addq $0x8d8, %rsp            # imm = 0x8D8
popq %rbx
popq %r14
retq