LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/cbmdosfs.c
// Function: findStartSector
static int findStartSector(CbmdosFs *self,
        uint8_t *trackno, uint8_t *sectno, const CbmdosFsOptions *opts)
{
    uint8_t tn = startTrack(opts, 0);
    do
    {
	for (uint8_t sn = 0;
		sn < Track_sectors(D64_rtrack(self->d64, tn)); ++sn)
	{
	    if (!self->bam[tn-1][sn])
	    {
		*trackno = tn;
		*sectno = sn;
		return 0;
	    }
	}
    } while ((tn = startTrack(opts, tn)));
    return -1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %r14
movq %rdx, 0x10(%rsp)
movq %rsi, 0x8(%rsp)
movq %rdi, %r12
movl (%rcx), %eax
movl %eax, %ecx
notl %ecx
movb $0x12, %bl
testl $0x1002, %ecx           # imm = 0x1002
je 0xb0d8
movb $0x1, %bl
btl $0xa, %eax
jb 0xb0d8
shrl $0xb, %eax
andl $0x1, %eax
addb %al, %al
orb $0x11, %al
movl %eax, %ebx
leaq 0x17(%r12), %rbp
movq %rbp, (%rsp)
movq (%r12), %rdi
movzbl %bl, %r13d
movl %r13d, %esi
callq 0x5060
movq %rax, %rdi
callq 0x5740
testb %al, %al
je 0xb14f
leaq (,%r13,4), %rax
addq %r13, %rax
leaq (,%rax,4), %r15
addq %r13, %r15
addq %rbp, %r15
xorl %ebp, %ebp
cmpb $0x0, (%r15,%rbp)
je 0xb1d8
incq %rbp
movq (%r12), %rdi
movl %r13d, %esi
callq 0x5060
movq %rax, %rdi
callq 0x5740
movzbl %al, %eax
cmpq %rax, %rbp
jb 0xb118
movl (%r14), %edi
testb %bl, %bl
je 0xb198
movq (%rsp), %rbp
jmp 0xb152
movl (%r14), %edi
testl $0xc00, %edi            # imm = 0xC00
je 0xb164
movl %r13d, %esi
callq 0xae7e
jmp 0xb1c7
cmpb $0x28, %bl
setae %cl
testb $0x8, %dil
sete %dl
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testb %dl, %cl
jne 0xb1e9
cmpb $0x23, %bl
jb 0xb18b
testb $0xc, %dil
je 0xb1e9
incb %bl
movl %ebx, %eax
jmp 0xb1c7
movb $0x11, %al
cmpb $0x12, %bl
je 0xb1c7
jae 0xb1c3
movb $0x24, %al
jmp 0xb1c5
movl %edi, %ecx
notl %ecx
movb $0x12, %al
testl $0x1002, %ecx           # imm = 0x1002
movq (%rsp), %rbp
je 0xb1c7
movb $0x1, %al
btl $0xa, %edi
jb 0xb1c7
shrl $0xb, %edi
andl $0x1, %edi
addb %dil, %dil
orb $0x11, %dil
movl %edi, %eax
jmp 0xb1c7
movb $0x23, %al
subb %bl, %al
movl %eax, %ebx
testb %al, %al
jne 0xb0e1
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0xb1e9
movq 0x8(%rsp), %rax
movb %bl, (%rax)
movq 0x10(%rsp), %rax
movb %bpl, (%rax)
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/cbmdosfs.c
// Function: findNextSector
static int findNextSector(CbmdosFs *self,
        uint8_t *trackno, uint8_t *sectno, const CbmdosFsOptions *opts)
{
    uint8_t tn = *trackno;
    uint8_t sn = freeSectorOnTrack(self, tn, *sectno, opts->fileInterleave,
            (opts->flags & CFF_SIMPLEINTERLEAVE));
    do
    {
	if (sn != 0xff)
	{
	    *trackno = tn;
	    *sectno = sn;
	    return 0;
	}
	if ((tn = nextTrack(opts, tn)))
	{
	    if (opts->flags & CFF_TALLOC_CHAININTERLV)
	    {
		sn = freeSectorOnTrack(self, tn, sn, opts->fileInterleave,
                        (opts->flags & CFF_SIMPLEINTERLEAVE));
	    }
	    else
	    {
		sn = freeSectorOnTrack(self, tn, sn, 0, 0);
	    }
	}
    } while (tn);
    return findStartSector(self, trackno, sectno, opts);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r15
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r12
movb (%rsi), %bpl
movzbl (%rdx), %edx
movzbl 0x5(%rcx), %ecx
movl $0x200, %r8d            # imm = 0x200
andl (%r15), %r8d
movzbl %bpl, %esi
callq 0xade0
cmpb $-0x1, %al
jne 0xb276
movl (%r15), %r13d
movzbl %bpl, %esi
movl %r13d, %edi
callq 0xae7e
testb %al, %al
je 0xb28c
movl %eax, %ebp
btl $0xd, %r13d
movzbl %al, %esi
jb 0xb25d
movq %r12, %rdi
movl $0xff, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
jmp 0xb226
movzbl 0x5(%r15), %ecx
andl $0x200, %r13d           # imm = 0x200
movq %r12, %rdi
movl $0xff, %edx
movl %r13d, %r8d
jmp 0xb226
movb %bpl, (%r14)
movb %al, (%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r12, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movq %r15, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xb096
nop
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/cbmdosfsoptions.c
// Function: CbmdosFsOptions_applyOverrides
void CbmdosFsOptions_applyOverrides(CbmdosFsOptions *self,
        const CbmdosFsOptOverrides *overrides)
{
    uint8_t interleave = CbmdosFsOptOverrides_interleave(overrides);
    if (interleave != 0xff) self->fileInterleave = interleave;

    CbmdosFsFlags mask = overrides->mask;
    mask &= ~CFF_OVERRIDE_INTERLEAVE;
    self->flags &= ~mask;
    self->flags |= (overrides->flags & mask);
}

// Assembly:
movl (%rsi), %ecx
movl 0x4(%rsi), %eax
testl $0x1ff, %eax            # imm = 0x1FF
je 0xb2c0
cmpb $-0x1, %cl
je 0xb2c0
movb %cl, 0x5(%rdi)
movl (%rdi), %edx
xorl %edx, %ecx
andl %ecx, %eax
andl $0xfffffe00, %eax       # imm = 0xFFFFFE00
xorl %edx, %eax
movl %eax, (%rdi)
retq
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/cbmdosinode.c
// Function: CbmdosInode_create
SOLOCAL CbmdosInode *CbmdosInode_create(void)
{
    CbmdosInode *self = xmalloc(sizeof *self);
    self->data = FileData_create();
    self->changedEvent = Event_create(0, self);
    self->overrides = CFOO_NONE;
    self->refcount = 0;
    Event_register(FileData_changedEvent(self->data), self, fileDataHandler);
    return self;
}

// Assembly:
pushq %rbx
movl $0x20, %edi
callq 0x585c
movq %rax, %rbx
callq 0x54f0
movq %rax, (%rbx)
xorl %edi, %edi
movq %rbx, %rsi
callq 0x5270
movq %rax, 0x8(%rbx)
movq $0x0, 0x10(%rbx)
movl $0x0, 0x18(%rbx)
movq (%rbx), %rdi
callq 0x5410
leaq 0x10(%rip), %rdx        # 0xb35e
movq %rax, %rdi
movq %rbx, %rsi
callq 0x5550
movq %rbx, %rax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/cbmdosinode.c
// Function: CbmdosInode_clone
SOLOCAL CbmdosInode *CbmdosInode_clone(const CbmdosInode *other)
{
    CbmdosInode *self = xmalloc(sizeof *self);
    self->data = FileData_clone(other->data);
    self->changedEvent = Event_create(0, self);
    self->overrides = other->overrides;
    self->refcount = 0;
    Event_register(FileData_changedEvent(self->data), self, fileDataHandler);
    return self;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movl $0x20, %edi
callq 0x585c
movq %rax, %rbx
movq (%r14), %rdi
callq 0x5150
movq %rax, (%rbx)
xorl %edi, %edi
movq %rbx, %rsi
callq 0x5270
movq %rax, 0x8(%rbx)
movq 0x10(%r14), %rax
movq %rax, 0x10(%rbx)
movl $0x0, 0x18(%rbx)
movq (%rbx), %rdi
callq 0x5410
leaq -0x62(%rip), %rdx       # 0xb35e
movq %rax, %rdi
movq %rbx, %rsi
callq 0x5550
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/cbmdosinode.c
// Function: CbmdosInode_setData
SOEXPORT void CbmdosInode_setData(CbmdosInode *self, FileData *data)
{
    Event_unregister(FileData_changedEvent(self->data), self, fileDataHandler);
    FileData_destroy(self->data);
    self->data = data;
    Event_register(FileData_changedEvent(self->data), self, fileDataHandler);
    CbmdosInodeEventArgs ea = { CIE_DATACHANGED };
    Event_raise(self->changedEvent, &ea);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq (%rdi), %rdi
callq 0x5410
leaq -0x9e(%rip), %r15       # 0xb35e
movq %rax, %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x5330
movq (%rbx), %rdi
callq 0x53d0
movq %r14, (%rbx)
movq %r14, %rdi
callq 0x5410
movq %rax, %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x5550
leaq 0xc(%rsp), %rsi
movl $0x0, (%rsi)
movq 0x8(%rbx), %rdi
callq 0x55e0
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/cbmdosinode.c
// Function: CbmdosInode_blocks
SOEXPORT uint16_t CbmdosInode_blocks(const CbmdosInode *self)
{
    if (!self->data)
    {
	return 0;
    }
    size_t size = FileData_size(self->data);
    uint16_t blocks = size / 254;
    if (size % 254) ++blocks;
    return blocks;
}

// Assembly:
movq (%rdi), %rdi
testq %rdi, %rdi
je 0xb494
pushq %rax
callq 0x5500
movabsq $0x7efdfbf7efdfbf7f, %rcx # imm = 0x7EFDFBF7EFDFBF7F
imulq %rax, %rcx
shrq %rax
movabsq $0x4081020408102041, %rdx # imm = 0x4081020408102041
mulq %rdx
shrl $0x5, %edx
rorq %rcx
movabsq $0x102040810204081, %rsi # imm = 0x102040810204081
xorl %eax, %eax
cmpq %rsi, %rcx
seta %al
addl %edx, %eax
addq $0x8, %rsp
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/cbmdosinode.c
// Function: CbmdosInode_setOptOverrides
SOEXPORT void CbmdosInode_setOptOverrides(
        CbmdosInode *self, CbmdosFsOptOverrides overrides)
{
    if (overrides.mask != self->overrides.mask
	    || overrides.flags != self->overrides.flags)
    {
	self->overrides = overrides;
	CbmdosInodeEventArgs args = { CIE_OPTOVERRIDESCHANGED };
	Event_raise(self->changedEvent, &args);
    }
}

// Assembly:
movq %rsi, %rax
shrq $0x20, %rax
cmpl %eax, 0x14(%rdi)
jne 0xb4ad
cmpl %esi, 0x10(%rdi)
je 0xb4cc
pushq %rax
movl %esi, 0x10(%rdi)
movl %eax, 0x14(%rdi)
leaq 0x4(%rsp), %rsi
movl $0x1, (%rsi)
movq 0x8(%rdi), %rdi
callq 0x55e0
addq $0x8, %rsp
retq
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/cbmdosinode.c
// Function: CbmdosInode_tryDestroy
SOLOCAL void CbmdosInode_tryDestroy(CbmdosInode *self)
{
    if (!self) return;
    if (self->refcount) return;
    Event_destroy(self->changedEvent);
    FileData_destroy(self->data);
    free(self);
}

// Assembly:
pushq %rbx
testq %rdi, %rdi
je 0xb503
movq %rdi, %rbx
cmpl $0x0, 0x18(%rdi)
je 0xb505
popq %rbx
retq
movq 0x8(%rbx), %rdi
callq 0x5170
movq (%rbx), %rdi
callq 0x53d0
movq %rbx, %rdi
popq %rbx
jmp 0x5080
nop
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/lynx.c
// Function: findHeader
static int findHeader(size_t *sigpos, uint8_t *dirblocks, size_t *dirpos,
	const uint8_t *content, size_t size)
{
    size_t pos = 0;
    if (size < 255) return -1;
    size_t base = content[0] | (content[1] << 8);
    size_t next = content[2] | (content[3] << 8);
    if (next <= base) goto lynxhdr;
    pos = next - base + 2;
    if (pos > size - 5)
    {
	pos = 0;
	goto lynxhdr;
    }
    if (content[pos-1])
    {
	pos = 0;
	goto lynxhdr;
    }
    while (content[pos] || content[pos+1])
    {
	size_t nextline = content[pos] | (content[pos+1] << 8);
	if (nextline <= next) return -1;
	next = nextline;
	pos = next - base + 2;
	if (pos > size - 5) return -1;
	if (content[pos-1]) return -1;
    }
    pos += 2;
    if (content[pos++] != 0x0d) return -1;
lynxhdr:
    if (findLynxHeader(&pos, dirblocks, dirpos, content, size) < 0) return -1;
    *sigpos = pos;
    return 0;
}

// Assembly:
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpq $0xff, %r8
jb 0xb6d0
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
movzwl (%rcx), %r10d
movzwl 0x2(%rcx), %ebx
movq %rbx, %r14
subq %r10, %r14
jbe 0xb59e
leaq 0x2(%r14), %r9
leaq -0x5(%r8), %r11
cmpq %r11, %r9
ja 0xb59e
cmpb $0x0, 0x1(%rcx,%r14)
je 0xb5ef
xorl %r9d, %r9d
cmpq %r8, %r9
jae 0xb613
cmpb $0x20, (%rcx,%r9)
jne 0xb613
incq %r9
cmpq %r9, %r8
jne 0xb5a6
jmp 0xb6ca
movzbl %bpl, %r14d
shll $0x8, %r14d
orq %r15, %r14
cmpq %rbx, %r14
jbe 0xb6ca
movq %r14, %rbx
subq %r10, %rbx
leaq 0x2(%rbx), %r9
cmpq %r11, %r9
ja 0xb6ca
cmpb $0x0, 0x1(%rcx,%rbx)
movq %r14, %rbx
jne 0xb6ca
movzbl (%rcx,%r9), %r15d
movb 0x1(%rcx,%r9), %bpl
movl %r15d, %r14d
orb %bpl, %r14b
jne 0xb5ba
cmpb $0xd, 0x2(%rcx,%r9)
jne 0xb6ca
addq $0x3, %r9
jmp 0xb5a1
cmpq %r8, %r9
je 0xb6ca
movb (%rcx,%r9), %r10b
leal -0x3a(%r10), %r11d
cmpb $-0x9, %r11b
jb 0xb6ca
leaq 0x1(%r9), %rbx
cmpq %r8, %rbx
je 0xb6ca
addb $-0x30, %r10b
movb (%rcx,%rbx), %r11b
leal -0x30(%r11), %ebp
cmpb $0x9, %bpl
ja 0xb676
addq $0x2, %r9
cmpq %r8, %r9
je 0xb6ca
movb (%rcx,%r9), %bl
addb $-0x30, %bl
cmpb $0xa, %bl
jb 0xb6ca
movzbl %r10b, %r10d
addl %r10d, %r10d
leal (%r10,%r10,4), %r10d
addb %r11b, %r10b
addb $-0x30, %r10b
jmp 0xb679
movq %rbx, %r9
cmpq %r8, %r9
jae 0xb692
cmpb $0x20, (%rcx,%r9)
jne 0xb692
incq %r9
cmpq %r9, %r8
jne 0xb67e
movq %r8, %r9
jmp 0xb6b0
movq %r9, %r11
cmpq %r8, %r9
jae 0xb6b3
movzbl (%rcx,%r11), %ebx
testl %ebx, %ebx
je 0xb6ca
cmpl $0xd, %ebx
je 0xb6b3
incq %r11
cmpq %r11, %r8
jne 0xb69a
movq %r8, %r11
incq %r11
addq $-0x5, %r8
cmpq %r8, %r11
ja 0xb6ca
movb %r10b, (%rsi)
movq %r11, (%rdx)
movq %r9, (%rdi)
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/lynx.c
// Function: parsePetsciiNum
static int parsePetsciiNum(uint16_t *num, size_t *pos,
	const uint8_t *content, size_t size)
{
    size_t p = *pos;
    while (p < size && content[p] == 0x20) ++p;
    if (content[p] < 0x31 || content[p] > 0x39) return -1;
    uint16_t n = content[p++] - 0x30;
    if (p == size) return -1;
    if (content[p] > 0x2f && content[p] < 0x3a)
    {
	n *= 10;
	n += (content[p++] - 0x30);
	if (p == size) return -1;
    }
    if (content[p] > 0x2f && content[p] < 0x3a)
    {
	n *= 10;
	n += (content[p++] - 0x30);
	if (p == size) return -1;
    }
    if (content[p] > 0x2f && content[p] < 0x3a) return -1;
    while (p < size && content[p] == 0x20) ++p;
    if (p == size) return -1;
    if (content[p] != 0x0d) return -1;
    if (++p == size) return -1;
    *pos = p;
    *num = n;
    return 0;
}

// Assembly:
movq (%rsi), %r8
cmpq %rcx, %r8
jae 0xbcf4
cmpb $0x20, (%rdx,%r8)
jne 0xbcf4
incq %r8
cmpq %r8, %rcx
jne 0xbce2
movq %rcx, %r8
movzbl (%rdx,%r8), %r9d
leal -0x3a(%r9), %r10d
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpb $-0x9, %r10b
jb 0xbdc4
leaq 0x1(%r8), %r10
cmpq %rcx, %r10
je 0xbdc4
pushq %rbx
movzwl %r9w, %r9d
addl $-0x30, %r9d
movzbl (%rdx,%r10), %ebx
leal -0x30(%rbx), %r11d
cmpb $0x9, %r11b
ja 0xbd8d
leaq 0x2(%r8), %r11
cmpq %rcx, %r11
je 0xbdc3
movswl %r9w, %r9d
addl %r9d, %r9d
leal (%r9,%r9,4), %r9d
movzwl %bx, %r10d
addl %r10d, %r9d
addl $-0x30, %r9d
movzbl (%rdx,%r11), %r10d
leal -0x30(%r10), %ebx
cmpb $0x9, %bl
ja 0xbdc5
addq $0x3, %r8
cmpq %rcx, %r8
je 0xbdc3
movb (%rdx,%r8), %r11b
addb $-0x30, %r11b
cmpb $0xa, %r11b
jb 0xbdc3
addl %r9d, %r9d
leal (%r9,%r9,4), %r9d
movzwl %r10w, %r10d
addl %r10d, %r9d
addl $-0x30, %r9d
jmp 0xbd90
movq %r10, %r8
cmpq %rcx, %r8
jae 0xbdab
cmpb $0x20, (%rdx,%r8)
jne 0xbda6
incq %r8
cmpq %r8, %rcx
jne 0xbd95
jmp 0xbdc3
cmpq %r8, %rcx
je 0xbdc3
cmpb $0xd, (%rdx,%r8)
jne 0xbdc3
incq %r8
cmpq %rcx, %r8
je 0xbdc3
movq %r8, (%rsi)
movw %r9w, (%rdi)
xorl %eax, %eax
popq %rbx
retq
movq %r11, %r8
jmp 0xbd90
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/lynx.c
// Function: archiveLynx
SOEXPORT FileData *archiveLynx(const CbmdosVfs *vfs)
{
    unsigned filecount = CbmdosVfs_fileCount(vfs);
    if (!filecount) return 0;
    const CbmdosFile **files = xmalloc(filecount * sizeof *files);
    unsigned realFilecount = 0;
    for (unsigned i = 0; i < filecount; ++i)
    {
	const CbmdosFile *file = CbmdosVfs_rfile(vfs, i);
	if (CbmdosFile_type(file) != CFT_DEL)
	{
	    files[realFilecount++] = file;
	}
    }
    if (!realFilecount)
    {
	free(files);
	return 0;
    }
    FileData *archive = archiveLynxFiles(files, realFilecount);
    free(files);
    return archive;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r15
callq 0x5240
xorl %ebx, %ebx
testl %eax, %eax
je 0xc4c6
movl %eax, %ebp
movl %eax, %edi
shlq $0x3, %rdi
callq 0x585c
movq %rax, %r14
xorl %r12d, %r12d
movq %r15, %rdi
movl %ebx, %esi
callq 0x5340
movq %rax, %r13
movq %rax, %rdi
callq 0x5780
testl %eax, %eax
je 0xc4a1
movl %r12d, %eax
incl %r12d
movq %r13, (%r14,%rax,8)
incl %ebx
cmpl %ebx, %ebp
jne 0xc47e
testl %r12d, %r12d
je 0xc4bc
movq %r14, %rdi
movl %r12d, %esi
callq 0x5450
movq %rax, %rbx
jmp 0xc4be
xorl %ebx, %ebx
movq %r14, %rdi
callq 0x5080
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/excess-c64[P]lib1541img/src/lib/1541img/petscii.c
// Function: appendUtf8
static size_t appendUtf8(
	char *buf, size_t bufsz, size_t *bufpos, const char *chrStr)
{
    size_t chrLen = strlen(chrStr);
    if (bufsz > *bufpos + chrLen + 1)
    {
        strcpy(buf + *bufpos, chrStr);
    }
    *bufpos += chrLen;
    return chrLen;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rcx, %r15
movq %rdx, %rbx
movq %rsi, %r13
movq %rdi, %r12
movq %rcx, %rdi
callq 0x5250
movq %rax, %r14
movq (%rbx), %rax
leaq (%r14,%rax), %rcx
incq %rcx
cmpq %r13, %rcx
jae 0xc718
addq %rax, %r12
movq %r12, %rdi
movq %r15, %rsi
callq 0x5100
movq (%rbx), %rax
addq %r14, %rax
movq %rax, (%rbx)
movq %r14, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/opp.c
// Function: opp_add_module
void opp_add_module(struct Opp_Parser* old, char* fname)
{
	struct Opp_Scan* new_scan = (struct Opp_Scan*)malloc(sizeof(struct Opp_Scan));

	if (new_scan == NULL)
		INTERNAL_ERROR("Malloc fail");

	char* path = fname;
	if (access(path, F_OK) == -1) {
		if (stdheader_path == NULL)
			INTERNAL_ERROR("Unknown path to stdlib");
		path = (char*)malloc(strlen(fname) + strlen(stdheader_path) + 1);
		sprintf(path, "%s%s", stdheader_path, fname);
	}

	opp_init_file(path, new_scan);

	struct Opp_Scan* temp = old->lex;
	old->lex = new_scan;

	opp_parser_begin(old);

	old->lex = temp;
	
	opp_free_lex(new_scan, 1);
	free(path);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movl $0x50, %edi
callq 0x1180
movq %rax, %r15
testq %rax, %rax
jne 0x176b
leaq 0x98c8(%rip), %rdi      # 0xb027
leaq 0x98fb(%rip), %rsi      # 0xb061
callq 0x97b3
movq %rbx, %rdi
xorl %esi, %esi
callq 0x11d0
cmpl $-0x1, %eax
jne 0x17dc
movq 0xea4f(%rip), %r12      # 0x101d0
testq %r12, %r12
jne 0x17a0
leaq 0x98e3(%rip), %rdi      # 0xb070
leaq 0x98cd(%rip), %rsi      # 0xb061
callq 0x97b3
movq 0xea30(%rip), %r12      # 0x101d0
movq %rbx, %rdi
callq 0x10b0
movq %rax, %r13
movq %r12, %rdi
callq 0x10b0
leaq (%rax,%r13), %rdi
incq %rdi
callq 0x1180
movq %rax, %r13
leaq 0x98be(%rip), %rsi      # 0xb087
movq %rax, %rdi
movq %r12, %rdx
movq %rbx, %rcx
xorl %eax, %eax
callq 0x1200
movq %r13, %rbx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x132c
movq (%r14), %r12
movq %r15, (%r14)
movq %r14, %rdi
callq 0x832b
movq %r12, (%r14)
movq %r15, %rdi
movl $0x1, %esi
callq 0x9930
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x1030
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/analysis/analysis.c
// Function: opp_init_analize
struct Opp_Analize* opp_init_analize(struct Opp_Parser* parser, struct Opp_Options* opts)
{
	struct Opp_Analize* ctx = (struct Opp_Analize*)malloc(sizeof(struct Opp_Analize));

	if (ctx == NULL)
		goto err;

	ctx->opts = opts;

	ctx->parser = parser;
	ctx->debug.scope = NULL;
	ctx->debug.ret = 0;

	// Namespace
	ctx->ns = init_namespace(NULL, (void*)alloc);
	ctx->curr_ns = ctx->ns;
	ctx->parser->scope = ctx->ns;

	return ctx;

err:
	INTERNAL_ERROR("Malloc Fail");
	return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r15
movq %rdi, %r14
movl $0x48, %edi
callq 0x1180
movq %rax, %rbx
testq %rax, %rax
je 0x1c48
movq %r15, (%rbx)
movq %r14, 0x8(%rbx)
movq $0x0, 0x20(%rbx)
movb $0x0, 0x28(%rbx)
leaq 0x6234(%rip), %rsi      # 0x7e67
xorl %edi, %edi
callq 0xa1ff
movq %rax, 0x10(%rbx)
movq %rax, 0x18(%rbx)
movq %rax, 0x30(%r14)
jmp 0x1c5b
leaq 0x9941(%rip), %rdi      # 0xb590
leaq 0x9946(%rip), %rsi      # 0xb59c
callq 0x97b3
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/analysis/analysis.c
// Function: opp_semantics_error
static void opp_semantics_error(struct Opp_Analize* ctx, 
		struct Opp_Node* node, const char* str, ...)
{
	va_list ap;
	va_start(ap, str);
	
	printf("%s:%u:%u ", ctx->parser->lex->io.fname, 
			node->debug.line, node->debug.colum);
	#ifdef UNX
		printf(CL_RED);
	#endif

	if (ctx->debug.scope != NULL)
		printf("semantics error: in function \"%s(...)\"\n\t", ctx->debug.scope);
	else
		printf("semantics error: in declaration\n\t");

	#ifdef UNX
		printf(CL_RESET);
	#endif
	vfprintf(stdout, str, ap);
	fprintf(stdout, "\n");
	va_end(ap);
	exit(1);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0xd8, %rsp
movq %rdx, %rbx
movq %rdi, %r14
leaq 0x20(%rsp), %rdx
movq %rcx, 0x18(%rdx)
movq %r8, 0x20(%rdx)
movq %r9, 0x28(%rdx)
testb %al, %al
je 0x22e2
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 %rdx, 0x10(%rsp)
leaq 0xf0(%rsp), %rax
movq %rax, 0x8(%rsp)
movabsq $0x3000000018, %rax     # imm = 0x3000000018
movq %rax, (%rsp)
movq 0x8(%rdi), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl 0x4(%rsi), %edx
movl 0x8(%rsi), %ecx
leaq 0x9332(%rip), %rdi      # 0xb64c
movq %rax, %rsi
xorl %eax, %eax
callq 0x10e0
leaq 0x8ea3(%rip), %rdi      # 0xb1ce
xorl %eax, %eax
callq 0x10e0
movq 0x20(%r14), %rsi
testq %rsi, %rsi
jne 0x234b
leaq 0x933d(%rip), %rdi      # 0xb67f
xorl %eax, %eax
callq 0x10e0
jmp 0x2359
leaq 0x9304(%rip), %rdi      # 0xb656
xorl %eax, %eax
callq 0x10e0
leaq 0x8f2d(%rip), %rdi      # 0xb28d
xorl %eax, %eax
callq 0x10e0
movq 0xdc72(%rip), %r14      # 0xffe0
movq (%r14), %rdi
movq %rsp, %rdx
movq %rbx, %rsi
callq 0x11f0
movq (%r14), %rsi
movl $0xa, %edi
callq 0x1120
movl $0x1, %edi
callq 0x1210
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/analysis/analysis.c
// Function: opp_warning
static void opp_warning(struct Opp_Analize* ctx, 
		struct Opp_Node* node, const char* str, ...)
{
	if (!ctx->opts->warning)
		return;

	if (ctx->opts->wall) {
		opp_semantics_error(ctx, node, str);
		return;
	}

	va_list ap;
	va_start(ap, str);
	
	printf("%s:%u:%u ", ctx->parser->lex->io.fname, 
			node->debug.line, node->debug.colum);
	#ifdef UNX
		printf(CL_YELLOW);
	#endif

	if (ctx->debug.scope != NULL)
		printf("warning: in function \"%s(...)\"\n\t", ctx->debug.scope);
	else 
		printf("warning: in declaration\n\t");

	#ifdef UNX
		printf(CL_RESET);
	#endif 
	vfprintf(stdout, str, ap);
	fprintf(stdout, "\n");
	va_end(ap);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0xd8, %rsp
movq %r9, 0x48(%rsp)
testb %al, %al
je 0x25e2
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 %r8, 0x40(%rsp)
movq %rcx, 0x38(%rsp)
movq (%rdi), %rax
cmpb $0x1, 0x4(%rax)
jne 0x26b5
movq %rdx, %rbx
movq %rdi, %r14
cmpb $0x1, 0x6(%rax)
je 0x26c0
leaq 0x20(%rsp), %rax
movq %rax, 0x10(%rsp)
leaq 0xf0(%rsp), %rax
movq %rax, 0x8(%rsp)
movabsq $0x3000000018, %rax     # imm = 0x3000000018
movq %rax, (%rsp)
movq 0x8(%r14), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl 0x4(%rsi), %edx
movl 0x8(%rsi), %ecx
leaq 0x9006(%rip), %rdi      # 0xb64c
movq %rax, %rsi
xorl %eax, %eax
callq 0x10e0
leaq 0x96d2(%rip), %rdi      # 0xbd29
xorl %eax, %eax
callq 0x10e0
movq 0x20(%r14), %rsi
testq %rsi, %rsi
je 0x2677
leaq 0x96c1(%rip), %rdi      # 0xbd2f
xorl %eax, %eax
callq 0x10e0
jmp 0x2685
leaq 0x96d2(%rip), %rdi      # 0xbd50
xorl %eax, %eax
callq 0x10e0
leaq 0x8c01(%rip), %rdi      # 0xb28d
xorl %eax, %eax
callq 0x10e0
movq 0xd946(%rip), %r14      # 0xffe0
movq (%r14), %rdi
movq %rsp, %rdx
movq %rbx, %rsi
callq 0x11f0
movq (%r14), %rsi
movl $0xa, %edi
callq 0x1120
addq $0xd8, %rsp
popq %rbx
popq %r14
retq
movq %r14, %rdi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x2286
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/analysis/analysis.c
// Function: opp_analize_assign
static Opp_Obj opp_analize_assign(struct Opp_Analize* ctx, struct Opp_Node* node)
{
	if ((node->assign_expr.ident->type != EUNARY 
		|| node->assign_expr.ident->unary_expr.type != TIDENT)
		&& (node->assign_expr.ident->type != EDEREF) 
		&& (node->assign_expr.ident->type != EELEMENT)
		&& (node->assign_expr.ident->type != EDOT))
		opp_semantics_error(ctx, node, "Unexpected expression on lhs of '='");

	Opp_Obj lhs = opp_analize_expr(ctx, node->assign_expr.ident);

	const char* name = ctx->debug.res_name;

	// Global assign error
	if (ctx->curr_ns == ctx->ns)
		opp_semantics_error(ctx, node, "Global assigments are not permited, assiment of '%s'", name);

	// Cannot assign array error
	if (lhs.size > 0)
		opp_semantics_error(ctx, node, "Attempting to assign a value to array '%s'", ctx->debug.res_name);

	Opp_Obj rhs = opp_analize_expr(ctx, node->assign_expr.val);

	// Cannot assign non pointer to array type
	if (rhs.size > 0 && lhs.depth == 0) 
		opp_semantics_error(ctx, node, "Attempting to assign an array type to var '%s'", name);

	// Different depths warning	
	if (rhs.depth != lhs.depth)
		opp_warning(ctx, node, "Assigning var '%s' to incompatible pointer depth", name);

	// Cannot assign non pointer to obj and vise versa
	if ((rhs.decl->t_type == TYPE_STRUCT && rhs.depth == 0)
		|| 
		(lhs.decl->t_type == TYPE_STRUCT && lhs.depth == 0))
		opp_semantics_error(ctx, node, "Assigning var '%s' to a incompatible struct type", name);

	return lhs;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq 0x20(%rsi), %rsi
movl (%rsi), %eax
leal -0x7(%rax), %ecx
cmpl $0x2, %ecx
jb 0x2704
cmpl $0xd, %eax
je 0x2704
cmpl $0x5, %eax
jne 0x27ca
cmpl $0x1, 0x10(%rsi)
jne 0x27ca
movq %r14, %rdi
callq 0x2961
movq %rax, %r13
movq 0x18(%r14), %rax
movq 0x40(%r14), %rcx
movq %rcx, (%rsp)
cmpq 0x10(%r14), %rax
je 0x27a0
movq %rdx, %r12
movq %rdx, %rax
shrq $0x10, %rax
testw %ax, %ax
jne 0x27a9
movq 0x18(%rbx), %rsi
movq %r14, %rdi
callq 0x2961
movq %rax, %rbp
movq %rdx, %rax
shrq $0x10, %rax
testw %ax, %ax
je 0x2750
testl %r12d, %r12d
je 0x27b2
movzwl %dx, %r15d
cmpl %r12d, %r15d
je 0x2771
leaq 0x90e2(%rip), %rdx      # 0xb842
movq %r14, %rdi
movq %rbx, %rsi
movq (%rsp), %rcx
xorl %eax, %eax
callq 0x2598
testl %r15d, %r15d
jne 0x277c
cmpl $0x8, 0x8(%rbp)
je 0x2797
movl 0x8(%r13), %eax
xorl $0x8, %eax
orl %r12d, %eax
je 0x2797
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x90d5(%rip), %rdx      # 0xb873
jmp 0x27b9
leaq 0x900c(%rip), %rdx      # 0xb7b3
jmp 0x27b9
leaq 0x9038(%rip), %rdx      # 0xb7e8
jmp 0x27b9
leaq 0x905a(%rip), %rdx      # 0xb813
movq %r14, %rdi
movq %rbx, %rsi
movq (%rsp), %rcx
xorl %eax, %eax
callq 0x2286
leaq 0x8fbe(%rip), %rdx      # 0xb78f
movq %r14, %rdi
movq %rbx, %rsi
xorl %eax, %eax
callq 0x2286
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/analysis/analysis.c
// Function: opp_analize_unary
static Opp_Obj opp_analize_unary(struct Opp_Analize* ctx, struct Opp_Node* node)
{
	Opp_Obj type;

	switch (node->unary_expr.type)
	{
		case TINTEGER:
			type.decl = int_type;
			type.depth = 0;
			type.size = 0;
			type.unsign = 0;
			break;

		case TSTR:
			type.decl = char_type;
			type.depth = 1;
			type.size = 0;
			type.unsign = 0;
			break;
		

		case TFLOAT:
			type.decl = float_type;
			type.depth = 0;
			type.size = 0;
			type.unsign = 0;
			break;
		
		case TIDENT: {
			struct Opp_Bucket* bucket = env_get_item(ctx->curr_ns, node->unary_expr.val.strval);

			if (bucket == NULL)
				opp_semantics_error(ctx, node, "Use of undeclared variable '%s'",
					node->unary_expr.val.strval);

			if (bucket->type == TYPE_LABEL)
				opp_semantics_error(ctx, node, "Invalid use of label '%s'",
					bucket->key);
			
			node->unary_expr.bidx = bucket;
			ctx->debug.res_name = bucket->key;

			return bucket->sym_type;
		}
		default: break;
	}
	return type;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl 0x10(%rsi), %eax
xorl %edx, %edx
decl %eax
cmpl $0x4, %eax
ja 0x3691
movq %rsi, %rbx
leaq 0x7ef7(%rip), %rcx      # 0xb524
movslq (%rcx,%rax,4), %rsi
addq %rcx, %rsi
jmpq *%rsi
movq %rdi, %r14
movq 0x18(%rdi), %rdi
movq 0x18(%rbx), %rsi
callq 0xa36c
testq %rax, %rax
je 0x3699
movq %rax, %rcx
cmpl $0x3, 0x8(%rax)
je 0x36a6
movq %rcx, 0x20(%rbx)
movq (%rcx), %rax
movq %rax, 0x40(%r14)
movq 0x10(%rcx), %rax
movq 0x18(%rcx), %rdx
jmp 0x3691
leaq 0xcc30(%rip), %rax      # 0x102a0
jmp 0x3679
leaq 0xcc17(%rip), %rax      # 0x10290
movq (%rax), %rax
xorl %edx, %edx
jmp 0x3691
leaq 0xcc01(%rip), %rax      # 0x10288
movq (%rax), %rax
movl $0x1, %edx
jmp 0x3691
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq 0x18(%rbx), %rcx
leaq 0x843c(%rip), %rdx      # 0xbae0
jmp 0x36b0
movq (%rcx), %rcx
leaq 0x8450(%rip), %rdx      # 0xbb00
movq %r14, %rdi
movq %rbx, %rsi
xorl %eax, %eax
callq 0x2286
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/analysis/analysis.c
// Function: opp_get_plain_size
static unsigned int opp_get_plain_size(struct Opp_Type_Decl* type)
{
	if (type->depth > 0 && type->size == 0)
		return 8;
	
	switch (type->decl->t_type)
	{
		case TYPE_VOID:   return 0;
		case TYPE_I8:     return 1;
		case TYPE_I16:    return 2;
		case TYPE_I32:    return 4;
		case TYPE_I64:    return 8;
		case TYPE_FLOAT:  return 4;
		case TYPE_DOUBLE: return 8;
		case TYPE_STRUCT: return type->decl->l_mem;
		default: break;
	}

	return 0;
}

// Assembly:
cmpw $0x0, 0x8(%rdi)
je 0x370c
cmpw $0x0, 0xa(%rdi)
je 0x372f
movq (%rdi), %rdx
movl 0x8(%rdx), %ecx
xorl %eax, %eax
leal -0x1(%rcx), %esi
cmpl $0x7, %esi
ja 0x373e
leaq 0x7e35(%rip), %rdi      # 0xb558
movslq (%rdi,%rsi,4), %rsi
addq %rdi, %rsi
jmpq *%rsi
movl %ecx, %eax
retq
movl $0x8, %eax
retq
movl $0x4, %eax
retq
movl 0x14(%rdx), %eax
retq
nop
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/compiler/compiler.c
// Function: opp_realloc_instrs
void opp_realloc_instrs(struct Opp_Context* opp)
{
	if (opp->ir.instr_idx >= opp->ir.allocated) {
		opp->ir.allocated += 64;
		opp->ir.opcodes = (struct OppIr_Opcode*)realloc(opp->ir.opcodes, 
			(opp->ir.allocated) * sizeof(struct OppIr_Opcode));

		if (opp->ir.opcodes == NULL)
			INTERNAL_ERROR("Realloc Fail");
	}
}

// Assembly:
movq 0x50(%rdi), %rax
cmpq %rax, 0x48(%rdi)
jb 0x380c
pushq %rbx
movq %rdi, %rbx
leaq 0x40(%rax), %rcx
movq %rcx, 0x50(%rdi)
movq 0x58(%rdi), %rdi
leaq 0x200(,%rax,8), %rax
leaq (%rax,%rax,4), %rsi
callq 0x11a0
movq %rax, 0x58(%rbx)
testq %rax, %rax
popq %rbx
je 0x380d
retq
leaq 0x8795(%rip), %rdi      # 0xbfa9
leaq 0x879b(%rip), %rsi      # 0xbfb6
jmp 0x97b3
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/compiler/compiler.c
// Function: opp_type_cast
void opp_type_cast(struct Opp_Context* opp, Opp_Obj* lhs, Opp_Obj* rhs)
{
	/* Cast rules
		1) Always cast based on lhs
		Ex: 
			double a;
			int b;
			b = a; # Cast a to int

		2) Only create a cast if
			- Lhs and Rhs are different floating points
			- Lhs and Rhs are different types 
				not including integer types.
	*/
	enum OppIr_Const_Type lt = opp_type_to_ir(lhs);
	enum OppIr_Const_Type rt = opp_type_to_ir(rhs);

	if (
		((lt == IMM_F64 || lt == IMM_F32) && (rt != IMM_F32 && rt != IMM_F64))
		||
		((lt != IMM_F64 && lt != IMM_F32) && (rt == IMM_F64 || rt == IMM_F32))
		||
		((lt == IMM_F64 && rt == IMM_F32) || (lt == IMM_F32 && rt == IMM_F64))
		) 
	{
		printf("CASTING\n");
		OPCODE_START();
			OPCODE_TYPE(OPCODE_CAST);
			opp->ir.opcodes[opp->ir.instr_idx].cast.type = lt;
		OPCODE_END();
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r15
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x3820
movl %eax, %r14d
movq %r15, %rdi
callq 0x3820
leal -0xb(%r14), %ecx
cmpl $0x2, %ecx
setb %cl
leal -0xd(%rax), %edx
cmpl $-0x2, %edx
setb %dl
testb %dl, %cl
je 0x3909
leaq 0x876d(%rip), %rdi      # 0xc04b
callq 0x1060
movq %rbx, %rdi
callq 0x37d7
movq 0x48(%rbx), %rax
movq 0x58(%rbx), %rcx
leaq (%rax,%rax,4), %rax
movl $0xb, (%rcx,%rax,8)
movl %r14d, 0x8(%rcx,%rax,8)
incq 0x48(%rbx)
jmp 0x394c
movl %r14d, %edx
xorl $0xb, %edx
movl %r14d, %ecx
xorl $0xc, %ecx
leal -0xd(%r14), %esi
cmpl $-0x2, %esi
setb %sil
leal -0xb(%rax), %edi
cmpl $0x2, %edi
setb %dil
movl %eax, %r8d
xorl $0xb, %r8d
orl %ecx, %r8d
sete %cl
xorl $0xc, %eax
orl %edx, %eax
sete %al
testb %dil, %sil
jne 0x38d7
testb %cl, %cl
jne 0x38d7
testb %al, %al
jne 0x38d7
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/compiler/compile_stmt.c
// Function: opp_compile_var
void opp_compile_var(struct Opp_Context* opp, struct Opp_Node* node)
{
	struct Opp_Stmt_Var* var = &node->var_stmt;

	bool assign = var->var->type == EASSIGN ? 1 : 0;
	bool global = var->bidx->type == TYPE_GLOBAL || var->bidx->type == TYPE_EXTERN;
	unsigned int size = opp_type_to_size(&var->type);

	OPCODE_START();
		OPCODE_TYPE(OPCODE_VAR);
		opp->ir.opcodes[opp->ir.instr_idx].var.global = global;
		opp->ir.opcodes[opp->ir.instr_idx].var.size = size;
		opp->ir.opcodes[opp->ir.instr_idx].var.name = var->bidx->key;
	OPCODE_END();

	if (!global) {
		opp->info.stack_offset -= size;
		var->bidx->offset = opp->info.stack_offset;
	}

	if (assign)
		opp_compile_assign(opp, var->var);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x10(%rsi), %rdi
movq 0x20(%rsi), %rax
movq 0x28(%rsi), %rcx
movl (%rax), %r15d
movl 0x8(%rcx), %r12d
callq 0x385b
movl %eax, %ebp
movq %rbx, %rdi
callq 0x37d7
testl $0xfffffffb, %r12d      # imm = 0xFFFFFFFB
movq 0x48(%rbx), %rax
movq 0x58(%rbx), %rcx
leaq (%rax,%rax,4), %rax
movl $0x5, (%rcx,%rax,8)
sete 0x8(%rcx,%rax,8)
movq 0x48(%rbx), %rax
movq 0x58(%rbx), %rcx
leaq (%rax,%rax,4), %rax
movl %ebp, 0x18(%rcx,%rax,8)
movq 0x28(%r14), %rax
movq (%rax), %rax
movq 0x48(%rbx), %rcx
movq 0x58(%rbx), %rdx
leaq (%rcx,%rcx,4), %rcx
movq %rax, 0x10(%rdx,%rcx,8)
incq 0x48(%rbx)
testl $0xfffffffb, %r12d      # imm = 0xFFFFFFFB
je 0x501c
movl 0x20(%rbx), %eax
subl %ebp, %eax
movl %eax, 0x20(%rbx)
movq 0x28(%r14), %rcx
movl %eax, 0x28(%rcx)
cmpl $0x4, %r15d
jne 0x5033
movq 0x20(%r14), %rsi
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x503c
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/compiler/compile_stmt.c
// Function: opp_compile_inifite
static void opp_compile_inifite(struct Opp_Context* opp, struct Opp_Node* node)
{ // might not work with break
	unsigned int start = opp->info.label_loc++;

	OPCODE_START();
		OPCODE_TYPE(OPCODE_LABEL);
		opp->ir.opcodes[opp->ir.instr_idx].constant.val.imm_i32 = start;
	OPCODE_END();

	opp_compile_stmt(opp, node->while_stmt.then);

	OPCODE_START();
		OPCODE_TYPE(OPCODE_JMP);
		opp->ir.opcodes[opp->ir.instr_idx].jmp.type = PURE_JMP;
		opp->ir.opcodes[opp->ir.instr_idx].jmp.loc = start;
	OPCODE_END();
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movl 0x24(%rdi), %r15d
leal 0x1(%r15), %eax
movl %eax, 0x24(%rdi)
callq 0x37d7
movq 0x48(%rbx), %rax
movq 0x58(%rbx), %rcx
leaq (%rax,%rax,4), %rax
movl $0xa, (%rcx,%rax,8)
movl %r15d, 0x10(%rcx,%rax,8)
incq 0x48(%rbx)
movq 0x18(%r14), %rsi
movq %rbx, %rdi
callq 0x4bd0
movq %rbx, %rdi
callq 0x37d7
movq 0x48(%rbx), %rax
movq 0x58(%rbx), %rcx
leaq (%rax,%rax,4), %rax
movl $0x8, (%rcx,%rax,8)
movl $0x0, 0x8(%rcx,%rax,8)
movq 0x48(%rbx), %rax
movq 0x58(%rbx), %rcx
leaq (%rax,%rax,4), %rax
movl %r15d, 0xc(%rcx,%rax,8)
incq 0x48(%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/ir/ir.c
// Function: dump_bytes
void dump_bytes(struct OppIr* ir, OppIO* io)
{
	if (io == NULL) {
		for (size_t i = 0; i < ir->code.idx; i++) { 
			if ((i+1) % 16 == 0) printf("\n");
			else printf("%X ", ir->code.bytes[i]);
		}
		printf("\n");
	}
	else {
		fwrite(ir->code.bytes, sizeof(unsigned char), ir->code.idx, io->file);
		fclose(io->file);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
testq %rsi, %rsi
je 0x5742
movq %rsi, %r14
movq (%rbx), %rdi
movq 0x8(%rbx), %rdx
movq 0x8(%rsi), %rcx
movl $0x1, %esi
callq 0x1220
movq 0x8(%r14), %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x10a0
cmpq $0x0, 0x8(%rbx)
je 0x5782
leaq 0x6c1f(%rip), %r14      # 0xc36f
xorl %eax, %eax
leaq 0x1(%rax), %r15
testb $0xf, %r15b
je 0x576f
movq (%rbx), %rcx
movzbl (%rcx,%rax), %esi
movq %r14, %rdi
xorl %eax, %eax
callq 0x10e0
jmp 0x5779
movl $0xa, %edi
callq 0x1040
movq %r15, %rax
cmpq 0x8(%rbx), %r15
jb 0x5752
movl $0xa, %edi
popq %rbx
popq %r14
popq %r15
jmp 0x1040
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/ir/ir.c
// Function: oppir_eval
void oppir_eval(struct OppIr* ir)
{
	#ifdef LINUX64
		init_strtab();
		init_elf_syms();
		init_reloc();
	#endif

	for (size_t index = 0; index < ir->instr->instr_idx; index++)
		oppir_eval_opcode(ir, &ir->instr->opcodes[index]);

	#ifdef LINUX64
		init_elf_header(DEFAULT_SECT);
		init_text_sect(ir);
		init_data_sect(ir);
		init_symtab_sect();
		init_shstrtab_sect();
		init_strtab_sect();
		init_rela_text_sect();
		elf_offsets(ir);
	#endif

	// dump_data(ir);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
xorl %eax, %eax
callq 0x7833
xorl %eax, %eax
callq 0x78f3
xorl %eax, %eax
callq 0x789d
movq 0x58(%rbx), %rax
cmpq $0x0, (%rax)
je 0x57e7
xorl %r14d, %r14d
xorl %r15d, %r15d
movq 0x10(%rax), %rsi
addq %r14, %rsi
movq %rbx, %rdi
callq 0x582c
incq %r15
movq 0x58(%rbx), %rax
addq $0x28, %r14
cmpq (%rax), %r15
jb 0x57c8
movl $0x7, %edi
xorl %eax, %eax
callq 0x797d
movq %rbx, %rdi
callq 0x7a16
movq %rbx, %rdi
callq 0x7a84
xorl %eax, %eax
callq 0x7b47
xorl %eax, %eax
callq 0x7af7
xorl %eax, %eax
callq 0x7bb4
xorl %eax, %eax
callq 0x7c0b
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x7c78
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/ir/ir.c
// Function: oppir_check_realloc
void oppir_check_realloc(struct OppIr* ir, unsigned int bytes)
{
	if ((ir->code.idx + bytes) >= ir->code.allocated) {

		ir->code.bytes = (unsigned char*)
				realloc(ir->code.bytes, (64+ir->code.allocated));

		if (ir->code.bytes == NULL)
			INTERNAL_ERROR("Malloc Fail");

		ir->code.allocated += 64;
	}
}

// Assembly:
movl %esi, %eax
addq 0x8(%rdi), %rax
movq 0x10(%rdi), %rsi
cmpq %rsi, %rax
jb 0x67d0
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rdi
addq $0x40, %rsi
callq 0x11a0
movq %rax, (%rbx)
testq %rax, %rax
jne 0x67ca
leaq 0x4dd2(%rip), %rdi      # 0xb590
leaq 0x5bae(%rip), %rsi      # 0xc373
callq 0x97b3
addq $0x40, 0x10(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/ir/ir.c
// Function: oppir_check_data
void oppir_check_data(struct OppIr* ir, unsigned int bytes)
{
	if ((ir->data_seg.idx + bytes) >= ir->data_seg.allocated) {

		ir->data_seg.data = (unsigned char*)
				realloc(ir->data_seg.data, (64+ir->data_seg.allocated));

		if (ir->data_seg.data == NULL)
			INTERNAL_ERROR("Malloc Fail");

		ir->data_seg.allocated += 64;
	}
}

// Assembly:
movl %esi, %eax
addq 0x88(%rdi), %rax
movq 0x80(%rdi), %rsi
cmpq %rsi, %rax
jb 0x6822
pushq %rbx
movq %rdi, %rbx
movq 0x90(%rdi), %rdi
addq $0x40, %rsi
callq 0x11a0
movq %rax, 0x90(%rbx)
testq %rax, %rax
jne 0x6819
leaq 0x4d83(%rip), %rdi      # 0xb590
leaq 0x5b73(%rip), %rsi      # 0xc387
callq 0x97b3
addq $0x40, 0x80(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/ir/ir.c
// Function: oppir_eval_ptr_assign
static void oppir_eval_ptr_assign(struct OppIr* ir, struct OppIr_Cast* cast)
{
	struct Register rhs = oppir_pop_reg(ir);
	struct Register lhs = oppir_pop_reg(ir);

	assert(cast->type != IMM_F32 && cast->type != IMM_F64);

	oppir_check_realloc(ir, 3);

	switch (cast->type)
	{
		case IMM_I8:
		case IMM_U8:
			IR_EMIT(0x88);
			break;

		case IMM_I16:
		case IMM_U16:
			IR_EMIT(0x66);
			IR_EMIT(0x89);
			break;

		case IMM_I32:
		case IMM_U32:
			IR_EMIT(0x89);
			break;

		case IMM_I64:
		case IMM_U64:
			IR_EMIT(0x48);
			IR_EMIT(0x89);
			break;

		default: break;
	}

	switch (lhs.reg)
	{
		case REG_RAX:
			IR_EMIT(0x08 * (rhs.reg));
			break;

		case REG_RCX:
			IR_EMIT(rhs.reg == REG_RAX ? 0x1 : 0x11);
			break;

		case REG_RDX:
			IR_EMIT(rhs.reg == REG_RAX ? 0x2 : 0xa);
			break;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r12
movq %rdi, %rbx
callq 0x729c
movq %rax, %r14
movq %rbx, %rdi
callq 0x729c
movq %rax, %r15
movl (%r12), %eax
addl $-0xb, %eax
cmpl $0x1, %eax
jbe 0x6d3a
movq %rbx, %rdi
movl $0x3, %esi
callq 0x6790
movl (%r12), %eax
addl $-0x3, %eax
cmpl $0x7, %eax
ja 0x6ce5
leaq 0x5680(%rip), %rcx      # 0xc31c
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movb $-0x78, %al
jmp 0x6cd3
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
leaq 0x1(%rcx), %rdx
movq %rdx, 0x8(%rbx)
movb $0x66, (%rax,%rcx)
jmp 0x6cd1
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
leaq 0x1(%rcx), %rdx
movq %rdx, 0x8(%rbx)
movb $0x48, (%rax,%rcx)
movb $-0x77, %al
movq (%rbx), %rcx
movq 0x8(%rbx), %rdx
leaq 0x1(%rdx), %rsi
movq %rsi, 0x8(%rbx)
movb %al, (%rcx,%rdx)
cmpl $0x2, %r15d
je 0x6d0c
cmpl $0x1, %r15d
je 0x6cfc
testl %r15d, %r15d
jne 0x6d2e
shlb $0x3, %r14b
jmp 0x6d1b
testl %r14d, %r14d
setne %r14b
shlb $0x4, %r14b
incb %r14b
jmp 0x6d1b
testl %r14d, %r14d
setne %r14b
shlb $0x3, %r14b
orb $0x2, %r14b
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
leaq 0x1(%rcx), %rdx
movq %rdx, 0x8(%rbx)
movb %r14b, (%rax,%rcx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x5719(%rip), %rdi      # 0xc45a
leaq 0x5690(%rip), %rsi      # 0xc3d8
leaq 0x573a(%rip), %rcx      # 0xc489
movl $0x4ae, %edx            # imm = 0x4AE
callq 0x1100
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/ir/ir.c
// Function: oppir_eval_jmp
static void oppir_eval_jmp(struct OppIr* ir, struct OppIr_Jmp* jmp)
{
	if (jmp->loc >= ir->offsets.allocated) {
		printf("LABEL REALLOC NEEDED\n");
	}

	if (jmp->type == PURE_JMP)
		IR_EMIT(0xe9);
	else
		IR_EMIT(0x0f);

	switch (jmp->type)
	{
		case TEQEQ:  IR_EMIT(0x84); break;
		case TNOTEQ: IR_EMIT(0x85); break;
		case TGT:    IR_EMIT(0x8f); break;
		case TLE:    IR_EMIT(0x8e); break;
		case TLT:    IR_EMIT(0x8c); break;
		case TGE:    IR_EMIT(0x8d); break;
	}
	ir->offsets.jmp_table[ir->offsets.jmp_idx].loc = ir->code.idx;
	ir->offsets.jmp_table[ir->offsets.jmp_idx].table_pos = jmp->loc;
	IR_EMIT(0x00);
	IR_EMIT(0x00);
	IR_EMIT(0x00);
	IR_EMIT(0x00);

	ir->offsets.jmp_idx++;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movl 0x4(%rsi), %eax
cmpq %rax, 0x60(%rdi)
ja 0x6d78
leaq 0x5790(%rip), %rdi      # 0xc503
callq 0x1060
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
leaq 0x1(%rcx), %rdx
cmpl $0x0, (%r14)
movq %rdx, 0x8(%rbx)
movl $0xe9, %edx
movl $0xf, %esi
cmovel %edx, %esi
movb %sil, (%rax,%rcx)
movl (%r14), %ecx
addl $-0x9, %ecx
cmpl $0x5, %ecx
ja 0x6dc9
shll $0x3, %ecx
movabsq $0x85848d8c8e8f, %rax   # imm = 0x85848D8C8E8F
shrq %cl, %rax
movq (%rbx), %rcx
movq 0x8(%rbx), %rdx
leaq 0x1(%rdx), %rsi
movq %rsi, 0x8(%rbx)
movb %al, (%rcx,%rdx)
movq 0x8(%rbx), %rax
movq 0x78(%rbx), %rcx
movl 0x68(%rbx), %edx
shlq $0x4, %rdx
movq %rax, (%rcx,%rdx)
movl 0x4(%r14), %esi
movl %esi, 0x8(%rcx,%rdx)
movq (%rbx), %rcx
leaq 0x1(%rax), %rdx
movq %rdx, 0x8(%rbx)
xorl %edx, %edx
movb %dl, (%rcx,%rax)
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
leaq 0x1(%rcx), %rsi
movq %rsi, 0x8(%rbx)
movb %dl, (%rax,%rcx)
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
leaq 0x1(%rcx), %rsi
movq %rsi, 0x8(%rbx)
movb %dl, (%rax,%rcx)
movq (%rbx), %rax
movq 0x8(%rbx), %rcx
leaq 0x1(%rcx), %rsi
movq %rsi, 0x8(%rbx)
movb %dl, (%rax,%rcx)
incl 0x68(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/ir/ir.c
// Function: oppir_push_reg
static enum Regs oppir_push_reg(struct OppIr* ir, enum OppIr_Const_Type type)
{
	int i = (type == IMM_F32 || type == IMM_F64) ? 3 : 0;
	const int max = (i == 3) ? 6 : 3;

	for (i; i < max; i++) {
		if (!regs[i].used) {
			regs[i].used = 1;
			oppir_check_regstack(ir);
			ir->reg_stack.top->reg = regs[i].reg;
			ir->reg_stack.top->type = type;
			ir->reg_stack.top->used = 1;
			ir->reg_stack.top->loc = 0; 
			ir->reg_stack.top->spilled = 0;
			ir->reg_stack.top++;
			return regs[i].reg;
		}
	}

	return oppir_reg_alloc(ir);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movl %esi, %r14d
movq %rdi, %rbx
leal -0xb(%r14), %eax
xorl %ecx, %ecx
cmpl $0x2, %eax
setb %cl
leaq (%rcx,%rcx,2), %rax
leaq (%rcx,%rcx,2), %rcx
addq $0x3, %rcx
movl %eax, %edx
shll $0x4, %edx
leaq 0x92c5(%rip), %rsi      # 0x10130
leaq (%rdx,%rsi), %r15
addq $0xc, %r15
cmpb $0x0, (%r15)
je 0x6eab
incq %rax
addq $0x10, %r15
cmpq %rcx, %rax
jb 0x6e73
movq 0x38(%rbx), %r12
movq 0x40(%rbx), %rax
xorl %r15d, %r15d
cmpq %rax, %r12
jae 0x6edc
cmpb $0x1, 0xc(%r12)
jne 0x6ea5
cmpb $0x0, 0xd(%r12)
je 0x6f1c
addq $0x10, %r12
jmp 0x6e90
movb $0x1, (%r15)
movq %rbx, %rdi
callq 0x70a7
movl -0xc(%r15), %ebp
movq 0x40(%rbx), %rax
movl %ebp, (%rax)
movl %r14d, 0x4(%rax)
movw $0x1, 0xc(%rax)
movl $0x0, 0x8(%rax)
addq $0x10, %rax
movq %rax, 0x40(%rbx)
jmp 0x6f0d
xorl %r14d, %r14d
xorl %ebp, %ebp
leal -0xd(%r15), %eax
cmpl $-0x2, %eax
movl $0x9, %eax
cmovael %r15d, %eax
leaq 0x8(%rsp), %rdx
movl $0x8, (%rdx)
movl %r14d, 0x8(%rdx)
movl %eax, 0x10(%rdx)
movq %rbx, %rdi
movl %ebp, %esi
callq 0x716b
movl %ebp, %eax
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movb $0x1, 0xd(%r12)
movq %rbx, %rdi
callq 0x70ef
movl %eax, %r14d
movl %eax, 0x8(%r12)
movl (%r12), %ebp
movl 0x4(%r12), %r15d
movq %rbx, %rdi
callq 0x70a7
movl (%r12), %eax
movq 0x40(%rbx), %rcx
movl %eax, (%rcx)
movw $0x1, 0xc(%rcx)
movl $0x0, 0x8(%rcx)
movl 0x4(%r12), %eax
movl %eax, 0x4(%rcx)
addq $0x10, %rcx
movq %rcx, 0x40(%rbx)
jmp 0x6ee1
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/ir/ir.c
// Function: oppir_write_const
static void oppir_write_const(struct OppIr* ir, struct OppIr_Value* imm)
{
	switch (imm->type)
	{
		case IMM_U64:
		case IMM_I64: 
		{
			oppir_check_realloc(ir, 8); 
			ir->code.bytes[ir->code.idx++] = imm->imm_i64 & 0xFF;
			for (int i = 8; i <= 56; i += 8) 
				ir->code.bytes[ir->code.idx++] = (imm->imm_i64 >> i) & 0xFF;
			break;
		}

		case IMM_I32: {
			oppir_check_realloc(ir, 4); 
			ir->code.bytes[ir->code.idx++] = imm->imm_i32 & 0xFF;
			for (int i = 8; i <= 24; i += 8) 
				ir->code.bytes[ir->code.idx++] = (imm->imm_i32 >> i) & 0xFF;
			break;
		}

		case IMM_I8: {
			oppir_check_realloc(ir, 1);
			ir->code.bytes[ir->code.idx++] = imm->imm_i8;
			break;
		}

		default: break;
	}
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movl (%rsi), %eax
leal -0x9(%rax), %ecx
cmpl $0x2, %ecx
jb 0x7032
cmpl $0x4, %eax
je 0x707c
cmpl $0x8, %eax
jne 0x709f
movq %rbx, %rdi
movl $0x4, %esi
callq 0x6790
movb 0x8(%r14), %al
movq (%rbx), %rcx
movq 0x8(%rbx), %rdx
leaq 0x1(%rdx), %rsi
movq %rsi, 0x8(%rbx)
movb %al, (%rcx,%rdx)
xorl %ecx, %ecx
addl $0x8, %ecx
movl 0x8(%r14), %eax
sarl %cl, %eax
movq (%rbx), %rdx
movq 0x8(%rbx), %rsi
leaq 0x1(%rsi), %rdi
movq %rdi, 0x8(%rbx)
movb %al, (%rdx,%rsi)
cmpl $0x11, %ecx
jb 0x7010
jmp 0x709f
movq %rbx, %rdi
movl $0x8, %esi
callq 0x6790
movb 0x8(%r14), %al
movq (%rbx), %rcx
movq 0x8(%rbx), %rdx
leaq 0x1(%rdx), %rsi
movq %rsi, 0x8(%rbx)
movb %al, (%rcx,%rdx)
xorl %ecx, %ecx
addq $0x8, %rcx
movq 0x8(%r14), %rax
sarq %cl, %rax
movq (%rbx), %rdx
movq 0x8(%rbx), %rsi
leaq 0x1(%rsi), %rdi
movq %rdi, 0x8(%rbx)
movb %al, (%rdx,%rsi)
cmpq $0x31, %rcx
jb 0x7057
jmp 0x709f
movq %rbx, %rdi
movl $0x1, %esi
callq 0x6790
movb 0x8(%r14), %al
movq (%rbx), %rcx
movq 0x8(%rbx), %rdx
leaq 0x1(%rdx), %rsi
movq %rsi, 0x8(%rbx)
movb %al, (%rcx,%rdx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/Encryptr[P]O-plus-plus/opp/ir/ir.c
// Function: oppir_check_regstack
static void oppir_check_regstack(struct OppIr* ir)
{
	if (ir->reg_stack.top >= (ir->reg_stack.stack + ir->reg_stack.allocated)) {
		ir->reg_stack.stack = (struct Register*)
				realloc(ir->reg_stack.stack, (16+ir->reg_stack.allocated));

		if (ir->reg_stack.stack == NULL)
			INTERNAL_ERROR("Malloc fail");

		ir->reg_stack.allocated += 16;
	}
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq 0x30(%rdi), %rsi
movq 0x38(%rdi), %rdi
movq %rsi, %rax
shlq $0x4, %rax
addq %rdi, %rax
cmpq %rax, 0x40(%rbx)
jb 0x70ed
addq $0x10, %rsi
callq 0x11a0
movq %rax, 0x38(%rbx)
testq %rax, %rax
jne 0x70e8
leaq 0x3f4b(%rip), %rdi      # 0xb027
leaq 0x52b5(%rip), %rsi      # 0xc398
callq 0x97b3
addq $0x10, 0x30(%rbx)
popq %rbx
retq