LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: getOffsetStr
char* getOffsetStr (int offset)
{	
	if (offset > 0)
		sprintf (offsetStr, " - %d", offset) ;
	else if (offset < 0)
		sprintf (offsetStr, " + %d", -offset) ;
	else
		memset (offsetStr, 0, 10) ;

	return offsetStr ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edi, %edx
testl %edi, %edi
jle 0x15ad
leaq 0x16dd3(%rip), %rdi     # 0x18370
leaq 0xec86(%rip), %rsi      # 0x1022a
xorl %eax, %eax
callq 0x1150
jmp 0x15c3
js 0x15cc
movw $0x0, 0x16dc0(%rip)     # 0x18378
movq $0x0, 0x16dad(%rip) # 0x18370
leaq 0x16da6(%rip), %rax     # 0x18370
popq %rbp
retq
negl %edx
leaq 0x16d9b(%rip), %rdi     # 0x18370
leaq 0xec54(%rip), %rsi      # 0x10230
jmp 0x15a4
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: loadRegLeftLim
void loadRegLeftLim (varST *vst, char *reg)
{
	if (isLeftLimStatic (vst))
		codePrint ("\t\tMOV %s, %s\n", reg, vst->arrayIndices->tokLeft->lexeme) ;
	else
		codePrint ("\t\tMOV %s, [RBP%s]\n", reg, getOffsetStr(vst->offset-10)) ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r15
callq 0xe828
leaq 0x16d1d(%rip), %rcx     # 0x18348
movq (%rcx), %r14
testl %eax, %eax
je 0x1647
movq 0x10(%r15), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax), %rcx
leaq 0xebf1(%rip), %rsi      # 0x10236
jmp 0x1661
movl 0x1c(%r15), %edi
addl $-0xa, %edi
callq 0x158c
leaq 0xf3e2(%rip), %rsi      # 0x10a3c
leaq 0x16d0f(%rip), %rcx     # 0x18370
movq %r14, %rdi
movq %rbx, %rdx
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x1100
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: loadRegRightLim
void loadRegRightLim (varST *vst, char *reg)
{
	if (isRightLimStatic (vst))
		codePrint ("\t\tMOV %s, %s\n", reg, vst->arrayIndices->tokRight->lexeme) ;		
	else
		codePrint ("\t\tMOV %s, [RBP%s]\n", reg, getOffsetStr(vst->offset-8)) ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r15
callq 0xe859
leaq 0x16cb4(%rip), %rcx     # 0x18348
movq (%rcx), %r14
testl %eax, %eax
je 0x16b0
movq 0x10(%r15), %rax
movq 0x10(%rax), %rax
movq 0x8(%rax), %rcx
leaq 0xeb88(%rip), %rsi      # 0x10236
jmp 0x16ca
movl 0x1c(%r15), %edi
addl $-0x8, %edi
callq 0x158c
leaq 0xf379(%rip), %rsi      # 0x10a3c
leaq 0x16ca6(%rip), %rcx     # 0x18370
movq %r14, %rdi
movq %rbx, %rdx
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x1100
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: loadArrBase
void loadArrBase (varST *vst, char *reg)
{
	if (isVarStaticArr (vst))
	{
		if (vst->varType == VAR_LOCAL)
		{
			codePrint ("\t\tMOV %s, RBP\n", reg) ;
			codePrint ("\t\tSUB %s, %d\n", reg, vst->offset) ;			
		}
		else
			codePrint ("\t\tMOV %s, [RBP%s]\n", reg, getOffsetStr (vst->offset)) ;
	}
	else
		codePrint ("\t\tMOV %s, [RBP%s]\n", reg, getOffsetStr(vst->offset)) ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
callq 0xe88a
testl %eax, %eax
je 0x1742
cmpl $0x3, 0x30(%r14)
leaq 0x16c41(%rip), %r12     # 0x18348
movq (%r12), %r15
jne 0x174c
leaq 0xeb30(%rip), %rsi      # 0x10244
movq %r15, %rdi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x1100
movq (%r12), %rdi
movl 0x1c(%r14), %ecx
leaq 0xeb23(%rip), %rsi      # 0x10253
movq %rbx, %rdx
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x1100
leaq 0x16bff(%rip), %rax     # 0x18348
movq (%rax), %r15
movl 0x1c(%r14), %edi
callq 0x158c
leaq 0xf2e0(%rip), %rsi      # 0x10a3c
leaq 0x16c0d(%rip), %rcx     # 0x18370
movq %r15, %rdi
movq %rbx, %rdx
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x1100
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: arrBoundCheck
void arrBoundCheck (astNode *node, moduleST *lst, varST *vst)
{
	varST *indexVar = NULL ;
	if (!isIndexStatic (node))	
		indexVar = searchVar (lst, node->child->tok->lexeme) ;

	tf |= 1 << boundCheck ;

	loadArrBase (vst, "RDI") ;
	loadRegLeftLim (vst, "BX") ;

	if (indexVar == NULL)
		codePrint ("\t\tMOV CX, %s\n", node->child->tok->lexeme) ;
	else
		codePrint ("\t\tMOV CX, [RBP%s]\n", getOffsetStr (indexVar->offset)) ;

	loadRegRightLim (vst, "DX") ;

	codePrint ("\t\tCALL @boundCheck") ;
	codeComment (10, "checking array index bound") ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
callq 0x1180
movq (%rax), %rax
movq 0x30(%r14), %rcx
movq 0x8(%rcx), %rcx
movq 0x8(%rcx), %rsi
movsbq (%rsi), %rcx
testb $0x8, 0x1(%rax,%rcx,2)
jne 0x1806
movq %r15, %rdi
callq 0xc430
movq %rax, %r15
jmp 0x1809
xorl %r15d, %r15d
orb $0x20, 0x16b59(%rip)    # 0x18369
leaq 0xeaf8(%rip), %rsi      # 0x1030f
movq %rbx, %rdi
callq 0x16e1
leaq 0xef34(%rip), %rsi      # 0x1075a
movq %rbx, %rdi
callq 0x160f
leaq 0x16b13(%rip), %r13     # 0x18348
movq (%r13), %r12
testq %r15, %r15
je 0x1857
movl 0x1c(%r15), %edi
callq 0x158c
leaq 0xea21(%rip), %rsi      # 0x1026f
leaq 0x16b1b(%rip), %rdx     # 0x18370
jmp 0x186a
movq 0x30(%r14), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax), %rdx
leaq 0xe9f7(%rip), %rsi      # 0x10261
movq %r12, %rdi
xorl %eax, %eax
callq 0x1100
leaq 0xea07(%rip), %rsi      # 0x10282
movq %rbx, %rdi
callq 0x1678
movq (%r13), %rcx
leaq 0xe9f7(%rip), %rdi      # 0x10285
movl $0x12, %esi
movl $0x1, %edx
callq 0x1170
leaq 0xe9f4(%rip), %rsi      # 0x10298
movl $0xa, %edi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x153a
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: isArrayRHS
int isArrayRHS (astNode *assignNode, moduleST *lst)
{
	varST *searchedVar ;

	if (assignNode->child->next->id == TK_ID)
	{
		searchedVar = searchVar (lst, assignNode->child->next->tok->lexeme) ;
		if (searchedVar->datatype == TK_ARRAY && assignNode->child->next->child == NULL)
			return 1 ;
	}

	return 0 ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq 0x30(%rdi), %rax
movq 0x38(%rax), %rax
cmpl $0x40, (%rax)
jne 0x195a
movq %rdi, %rbx
movq 0x8(%rax), %rax
movq 0x8(%rax), %rax
movq %rsi, %rdi
movq %rax, %rsi
callq 0xc430
cmpl $0x3b, 0x8(%rax)
jne 0x195a
movq 0x30(%rbx), %rax
movq 0x38(%rax), %rax
cmpq $0x0, 0x30(%rax)
je 0x1963
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
movl $0x1, %eax
jmp 0x195c
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: dynAsgnArr
void dynAsgnArr (varST *lhs, varST *rhs)
{
	tf |= 1 << asgnLimERROR ;
	int leftLab, rightLab ;

	leftLab = get_label (LABEL_OTHER) ;
	rightLab = get_label (LABEL_OTHER) ;

	loadRegLeftLim (lhs, "AX") ;
	loadRegLeftLim (rhs, "CX") ;

	codePrint ("\t\tCMP AX, CX\n") ;
	codePrint ("\t\tJE @LABEL%d\n", leftLab) ;
	codePrint ("\t\tCALL @asgnLimERROR\n") ;

	codePrint ("\n\t@LABEL%d:\n", leftLab) ;
	loadRegRightLim (lhs, "BX") ;
	loadRegRightLim (rhs, "DX") ;

	codePrint ("\t\tCMP BX, DX\n") ;
	codePrint ("\t\tJE @LABEL%d\n", rightLab) ;
	codePrint ("\t\tCALL @asgnLimERROR\n") ;

	codePrint ("\n\t@LABEL%d:\n", rightLab) ;
	loadArrBase (rhs, "RDI") ;
	codePrint ("\t\tMOV[RBP%s], RDI", getOffsetStr(lhs->offset)) ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
orb $0x10, 0x169b2(%rip)    # 0x18368
movl 0x1699f(%rip), %r15d    # 0x1835c
leal 0x1(%r15), %r12d
addl $0x2, %r15d
movl %r15d, 0x16990(%rip)    # 0x1835c
leaq 0xe979(%rip), %rsi      # 0x1034c
callq 0x160f
leaq 0xf137(%rip), %rsi      # 0x10b16
movq %r14, %rdi
callq 0x160f
leaq 0x1695a(%rip), %r13     # 0x18348
movq (%r13), %rcx
leaq 0xe8ba(%rip), %rdi      # 0x102b3
movl $0xd, %esi
movl $0x1, %edx
callq 0x1170
movq (%r13), %rdi
leaq 0xe8ae(%rip), %rsi      # 0x102c1
movl %r12d, %edx
xorl %eax, %eax
callq 0x1100
movq (%r13), %rcx
leaq 0xe8a8(%rip), %rdi      # 0x102d0
movl $0x15, %esi
movl $0x1, %edx
callq 0x1170
movq (%r13), %rdi
leaq 0xe8a4(%rip), %rsi      # 0x102e6
movl %r12d, %edx
xorl %eax, %eax
callq 0x1100
leaq 0xed07(%rip), %rsi      # 0x1075a
movq %rbx, %rdi
callq 0x1678
leaq 0xe820(%rip), %rsi      # 0x10282
movq %r14, %rdi
callq 0x1678
movq (%r13), %rcx
leaq 0xe87e(%rip), %rdi      # 0x102f3
movl $0xd, %esi
movl $0x1, %edx
callq 0x1170
movq (%r13), %rdi
leaq 0xe832(%rip), %rsi      # 0x102c1
movl %r15d, %edx
xorl %eax, %eax
callq 0x1100
movq (%r13), %rcx
movl $0x15, %esi
movl $0x1, %edx
leaq 0xe822(%rip), %rdi      # 0x102d0
callq 0x1170
movq (%r13), %rdi
leaq 0xe828(%rip), %rsi      # 0x102e6
movl %r15d, %edx
xorl %eax, %eax
callq 0x1100
leaq 0xe840(%rip), %rsi      # 0x1030f
movq %r14, %rdi
callq 0x16e1
movq (%r13), %r14
movl 0x1c(%rbx), %edi
callq 0x158c
leaq 0xe817(%rip), %rsi      # 0x10301
leaq 0x1687f(%rip), %rdx     # 0x18370
movq %r14, %rdi
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x1100
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: exprAssign
void exprAssign (astNode *node, moduleST *lst, int singleAssign)
{
	if (!singleAssign)
		codePrint ("\t\tPOP AX\n") ;

	if(node->child == NULL)
	{
		varST *searchedVar = searchVar (lst, node->tok->lexeme) ;
		if (node->next->id == TK_MINUS && node->next->child->next == NULL)
			codePrint ("\t\tNEG AX\n") ;

		codePrint ("\t\tMOV [RBP%s], AX", getOffsetStr (searchedVar->offset)) ;
	}
	else
	{
		varST* vst ;
		vst = searchVar (lst,node->tok->lexeme);

		if (isVarStaticArr(vst) && node->child->id == TK_NUM)
		{
			if (node->next->id == TK_MINUS && node->next->child->next == NULL)
				codePrint ("\t\tNEG AX\n") ;

			codePrint ("\t\tMOV [RBP%s], AX" , getOffsetStr(getStaticOffset(vst,node,2))) ;
		}
		else
		{
			if (node->next->id == TK_MINUS && node->next->child->next == NULL)
				codePrint ("\t\tNEG AX\n") ;

			arrBoundCheck (node, lst, vst) ;
			codePrint ("\t\tMOV [RDI + RBX], AX") ;
		}
	}
	codeComment (10, "store variable") ;

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r15
movq %rdi, %r14
testl %edx, %edx
jne 0x1b3e
leaq 0x16823(%rip), %rax     # 0x18348
movq (%rax), %rcx
leaq 0xe7e4(%rip), %rdi      # 0x10313
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
movq 0x30(%r14), %r12
movq 0x8(%r14), %rax
movq 0x8(%rax), %rsi
movq %r15, %rdi
callq 0xc430
movq %rax, %rbx
testq %r12, %r12
je 0x1c42
movq %rbx, %rdi
callq 0xe88a
testl %eax, %eax
je 0x1bde
movq 0x30(%r14), %rax
cmpl $0x71, (%rax)
jne 0x1bde
movq 0x38(%r14), %rax
cmpl $0x58, (%rax)
jne 0x1ba7
movq 0x30(%rax), %rax
cmpq $0x0, 0x38(%rax)
jne 0x1ba7
leaq 0x167ba(%rip), %rax     # 0x18348
movq (%rax), %rcx
leaq 0xe785(%rip), %rdi      # 0x1031d
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
leaq 0x1679a(%rip), %rax     # 0x18348
movq (%rax), %r15
movq %rbx, %rdi
movq %r14, %rsi
movl $0x2, %edx
callq 0x1778
movl %eax, %edi
callq 0x158c
leaq 0xe758(%rip), %rsi      # 0x10327
leaq 0x1679a(%rip), %rdx     # 0x18370
movq %r15, %rdi
jmp 0x1c99
movq 0x38(%r14), %rax
cmpl $0x58, (%rax)
jne 0x1c12
movq 0x30(%rax), %rax
cmpq $0x0, 0x38(%rax)
jne 0x1c12
leaq 0x1674f(%rip), %rax     # 0x18348
movq (%rax), %rcx
leaq 0xe71a(%rip), %rdi      # 0x1031d
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
movq %r14, %rdi
movq %r15, %rsi
movq %rbx, %rdx
callq 0x17c3
leaq 0x16721(%rip), %rax     # 0x18348
movq (%rax), %rcx
leaq 0xe708(%rip), %rdi      # 0x10339
movl $0x15, %esi
movl $0x1, %edx
callq 0x1170
jmp 0x1ca0
movq 0x38(%r14), %rax
cmpl $0x58, (%rax)
jne 0x1c76
movq 0x30(%rax), %rax
cmpq $0x0, 0x38(%rax)
jne 0x1c76
leaq 0x166eb(%rip), %rax     # 0x18348
movq (%rax), %rcx
leaq 0xe6b6(%rip), %rdi      # 0x1031d
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
leaq 0x166cb(%rip), %rax     # 0x18348
movq (%rax), %r14
movl 0x1c(%rbx), %edi
callq 0x158c
leaq 0xe698(%rip), %rsi      # 0x10327
leaq 0x166da(%rip), %rdx     # 0x18370
movq %r14, %rdi
xorl %eax, %eax
callq 0x1100
leaq 0xe6a8(%rip), %rsi      # 0x1034f
movl $0xa, %edi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x153a
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: RSPAlign
void RSPAlign ()
{
	codePrint ("\t\tMOV RAX, RSP") ;
	codeComment (9, "Stack Alignment") ;
	codePrint ("\t\tAND RAX, 15\n") ;
	codePrint ("\t\tADD RAX, 8\n") ;
	codePrint ("\t\tSUB RSP, RAX\n") ;
	codePrint ("\t\tPUSH RAX\n") ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x15f70(%rip), %rbx     # 0x18348
movq (%rbx), %rcx
leaq 0xe16b(%rip), %rdi      # 0x1054d
movl $0xe, %esi
movl $0x1, %edx
callq 0x1170
leaq 0xe1c2(%rip), %rsi      # 0x105ba
movl $0x9, %edi
callq 0x153a
movq (%rbx), %rcx
leaq 0xe150(%rip), %rdi      # 0x1055c
movl $0xe, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xe146(%rip), %rdi      # 0x1056b
movl $0xd, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xe13b(%rip), %rdi      # 0x10579
movl $0xf, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xe132(%rip), %rdi      # 0x10589
movl $0xb, %esi
movl $0x1, %edx
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x1170
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: dynamicDeclarationCheck
void dynamicDeclarationCheck (moduleST *lst, varST *vst)
{
	int start_label , end_label ;
	varST *leftVar , *rightVar ;
	tf |= 1 << dynamicDeclCheck ;

	codePrint ("\n") ;
	if (isLeftLimStatic (vst))
		codePrint ("\t\tMOV AX, %s\n", vst->arrayIndices->tokLeft->lexeme) ;
	else
	{
		leftVar = searchVar (lst, vst->arrayIndices->tokLeft->lexeme) ;
		codePrint ("\t\tMOV AX, [RBP%s]\n", getOffsetStr (leftVar->offset)) ;
	}

	if (isRightLimStatic (vst))
		codePrint ("\t\tMOV BX, %s\n", vst->arrayIndices->tokRight->lexeme) ;
	else
	{
		rightVar = searchVar (lst, vst->arrayIndices->tokRight->lexeme) ;
		codePrint ("\t\tMOV BX, [RBP%s]\n", getOffsetStr(rightVar->offset)) ;
	}

	codePrint ("\t\tCALL @dynamicDeclCheck") ;
	codeComment (10, "checking dynamic array declaration limits") ;

	codePrint ("\n\n") ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
orb $0x40, 0x15cb5(%rip)    # 0x18369
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x15c87(%rip), %r12     # 0x18348
movq (%r12), %rsi
movl $0xa, %edi
callq 0x10e0
movq %r14, %rdi
callq 0xe828
testl %eax, %eax
je 0x26f4
movq (%r12), %rdi
movq 0x10(%r14), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax), %rdx
leaq 0xdfdc(%rip), %rsi      # 0x106ce
jmp 0x2725
movq 0x10(%r14), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax), %rsi
movq %rbx, %rdi
callq 0xc430
movq (%r12), %r15
movl 0x1c(%rax), %edi
callq 0x158c
leaq 0xdfc1(%rip), %rsi      # 0x106dc
leaq 0x15c4e(%rip), %rdx     # 0x18370
movq %r15, %rdi
xorl %eax, %eax
callq 0x1100
movq %r14, %rdi
callq 0xe859
testl %eax, %eax
je 0x2751
movq (%r12), %rdi
movq 0x10(%r14), %rax
movq 0x10(%rax), %rax
movq 0x8(%rax), %rdx
leaq 0xdfa0(%rip), %rsi      # 0x106ef
jmp 0x2782
movq 0x10(%r14), %rax
movq 0x10(%rax), %rax
movq 0x8(%rax), %rsi
movq %rbx, %rdi
callq 0xc430
movq (%r12), %rbx
movl 0x1c(%rax), %edi
callq 0x158c
leaq 0xdf85(%rip), %rsi      # 0x106fd
leaq 0x15bf1(%rip), %rdx     # 0x18370
movq %rbx, %rdi
xorl %eax, %eax
callq 0x1100
movq (%r12), %rcx
leaq 0xdf7c(%rip), %rdi      # 0x10710
movl $0x18, %esi
movl $0x1, %edx
callq 0x1170
leaq 0xdf7f(%rip), %rsi      # 0x10729
movl $0xa, %edi
callq 0x153a
movq (%r12), %rcx
leaq 0xe4cb(%rip), %rdi      # 0x10c8a
movl $0x2, %esi
movl $0x1, %edx
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x1170
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: getCaseCount
int getCaseCount (astNode *statementsNode)
{
	int cnt = 0 ;

	while (statementsNode != NULL)
	{
		cnt++ ;

		if (statementsNode->next != NULL)
		{
			if (statementsNode->next->id == TK_DEFAULT)
				return cnt ;

			statementsNode = statementsNode->next->next->next ;
		}
		else
			statementsNode = NULL ;
	}

	return cnt ;
}

// Assembly:
testq %rdi, %rdi
je 0x2c0e
pushq %rbp
movq %rsp, %rbp
movl $0x1, %ecx
movl %ecx, %eax
movq 0x38(%rdi), %rcx
testq %rcx, %rcx
je 0x2c02
cmpl $0x55, (%rcx)
je 0x2c0c
movq 0x38(%rcx), %rcx
movq 0x38(%rcx), %rdi
jmp 0x2c04
xorl %edi, %edi
leal 0x1(%rax), %ecx
testq %rdi, %rdi
jne 0x2be8
popq %rbp
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: switchDeclareVars
void switchDeclareVars (astNode *statementsNode)
{
	astNode *statementNode ;

	// Reserving space for switch scope variables
	while (statementsNode != NULL)
	{
		statementNode = statementsNode->child ;
		while (statementNode != NULL)
		{
			if (statementNode->child->id == TK_DECLARE)
			{
				moduleGeneration (statementNode->child, statementsNode->localST) ;
				statementNode->child->parent = statementNode->child ;		// tieing a knot
			}
			statementNode = statementNode->next ;
		}

		if (statementsNode->next != NULL)
		{
			if (statementsNode->next->id == TK_DEFAULT)
			{
				statementsNode = statementsNode->next->next ;
				statementNode = statementsNode->child ;
				while (statementNode != NULL)
				{
					if (statementNode->child->id == TK_DECLARE)
					{
						moduleGeneration (statementNode->child, statementsNode->localST) ;
						statementNode->child->parent = statementNode->child ;		// tieing a knot
					}
					statementNode = statementNode->next ;
				}

				break ;
			}
			statementsNode = statementsNode->next->next->next ;
		}
		else
			statementsNode = NULL ;
	}
}

// Assembly:
testq %rdi, %rdi
je 0x2c6c
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
movq 0x30(%rbx), %r14
testq %r14, %r14
je 0x2c49
movq 0x30(%r14), %rdi
cmpl $0x3e, (%rdi)
jne 0x2c43
movq 0x20(%rbx), %rsi
callq 0x2c96
movq 0x30(%r14), %rax
movq %rax, 0x28(%rax)
movq 0x38(%r14), %r14
jmp 0x2c24
movq 0x38(%rbx), %rax
testq %rax, %rax
je 0x2c61
cmpl $0x55, (%rax)
movq 0x38(%rax), %rbx
je 0x2c6d
movq 0x38(%rbx), %rbx
jmp 0x2c63
xorl %ebx, %ebx
testq %rbx, %rbx
jne 0x2c20
popq %rbx
popq %r14
popq %rbp
retq
movq 0x30(%rbx), %r14
testq %r14, %r14
je 0x2c68
movq 0x30(%r14), %rdi
cmpl $0x3e, (%rdi)
jne 0x2c90
movq 0x20(%rbx), %rsi
callq 0x2c96
movq 0x30(%r14), %rax
movq %rax, 0x28(%rax)
movq 0x38(%r14), %r14
jmp 0x2c71
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: pushInputDynamicArr
void pushInputDynamicArr (varST *vst, varSTentry *varEntry, char *reg, pushArrLim flag)
{
	int lab, sub ;

	if (flag == LEFT)
		sub = 10 ;
	else
		sub = 8 ;

	codePrint ("\t\tMOV %s, [RBP%s]\n", reg, getOffsetStr(vst->offset - sub)) ;

	if (isLeftLimStatic(varEntry->thisVarST) && !isLeftLimStatic(vst))
	{
		lab = get_label (LABEL_OTHER) ;
		tf |= 1 << argLimERROR ;

		if (flag == LEFT)
			codePrint ("\t\tMOV CX, %s\n", varEntry->thisVarST->arrayIndices->tokLeft->lexeme) ;
		else
			codePrint ("\t\tMOV CX, %s\n", varEntry->thisVarST->arrayIndices->tokRight->lexeme) ;

		codePrint ("\t\tCMP %s, CX\n", reg) ;
		codePrint ("\t\tJE @LABEL%d\n", lab) ;
		codePrint ("\t\tCALL @argLimERROR\n") ;
		codePrint ("\n\t@LABEL%d:\n", lab) ; 
	}

	if (!isVarStaticArr (varEntry->thisVarST))
		codePrint ("\t\tPUSH %s\n", reg) ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %r15d
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r12
xorl %eax, %eax
testl %ecx, %ecx
setne %al
leaq 0x14a78(%rip), %rcx     # 0x18348
movq (%rcx), %r13
movl 0x1c(%rdi), %ecx
leal (%rcx,%rax,2), %edi
addl $-0xa, %edi
callq 0x158c
leaq 0xd154(%rip), %rsi      # 0x10a3c
leaq 0x14a81(%rip), %rcx     # 0x18370
movq %r13, %rdi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x1100
movq (%r14), %rdi
callq 0xe828
testl %eax, %eax
je 0x39be
movq %r12, %rdi
callq 0xe828
testl %eax, %eax
jne 0x39be
xorl %eax, %eax
testl %r15d, %r15d
setne %al
movl 0x14a31(%rip), %r15d    # 0x1835c
incl %r15d
movl %r15d, 0x14a27(%rip)    # 0x1835c
orb $0x8, 0x14a2c(%rip)     # 0x18368
leaq 0x14a05(%rip), %r12     # 0x18348
movq (%r12), %rdi
movq (%r14), %rcx
movq 0x10(%rcx), %rcx
movq 0x8(%rcx,%rax,8), %rax
movq 0x8(%rax), %rdx
leaq 0xc903(%rip), %rsi      # 0x10261
xorl %eax, %eax
callq 0x1100
movq (%r12), %rdi
leaq 0xd04f(%rip), %rsi      # 0x109bf
movq %rbx, %rdx
xorl %eax, %eax
callq 0x1100
movq (%r12), %rdi
leaq 0xc93c(%rip), %rsi      # 0x102c1
movl %r15d, %edx
xorl %eax, %eax
callq 0x1100
movq (%r12), %rcx
leaq 0xd033(%rip), %rdi      # 0x109cd
movl $0x14, %esi
movl $0x1, %edx
callq 0x1170
movq (%r12), %rdi
leaq 0xc932(%rip), %rsi      # 0x102e6
movl %r15d, %edx
xorl %eax, %eax
callq 0x1100
movq (%r14), %rdi
callq 0xe88a
testl %eax, %eax
je 0x39d9
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x14968(%rip), %rax     # 0x18348
movq (%rax), %rdi
leaq 0xc999(%rip), %rsi      # 0x10383
movq %rbx, %rdx
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x1100
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: pushInput
void pushInput (astNode *inputEnd, varSTentry *varEntry, moduleST *lst)
{
	varST *searchedVar ;

	while (varEntry->thisVarST->varType == VAR_PLACEHOLDER)
		varEntry = varEntry->next ;

	while (inputEnd != NULL)
	{
		searchedVar = searchVar (lst, inputEnd->tok->lexeme) ;

		if (searchedVar->datatype == TK_INTEGER || searchedVar->datatype == TK_BOOLEAN)
		{
			codePrint ("\t\tMOV AX, [RBP%s]\n", getOffsetStr(searchedVar->offset)) ;
			codePrint ("\t\tPUSH AX\n") ;
		}
		else if (isVarStaticArr (searchedVar))
		{
			loadArrBase (searchedVar, "RAX") ;
			codePrint ("\t\tPUSH RAX\n") ;
		}
		else
		{
			pushInputDynamicArr (searchedVar, varEntry, "AX", LEFT) ;
			pushInputDynamicArr (searchedVar, varEntry, "BX", RIGHT) ;
			loadArrBase (searchedVar, "RAX") ;
			codePrint ("\t\tPUSH RAX\n") ;
		}

		inputEnd = inputEnd->prev ;
		varEntry = varEntry->next ;
		while (varEntry != NULL && varEntry->thisVarST->varType == VAR_PLACEHOLDER)
			varEntry = varEntry->next ;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, -0x30(%rbp)
movq %rsi, %r14
movq %rdi, %r15
movq (%rsi), %rax
cmpl $0x1, 0x30(%rax)
jne 0x3b0e
movq 0x8(%r14), %r14
movq (%r14), %rax
jmp 0x3a1d
movq 0x8(%r15), %rax
movq 0x8(%rax), %rsi
movq -0x30(%rbp), %rdi
callq 0xc430
movq %rax, %r13
movl 0x8(%rax), %eax
cmpl $0x39, %eax
je 0x3a51
cmpl $0x37, %eax
jne 0x3a92
leaq 0x148f0(%rip), %rbx     # 0x18348
movq (%rbx), %r12
movl 0x1c(%r13), %edi
callq 0x158c
movq %r12, %rdi
leaq 0xcc6e(%rip), %rsi      # 0x106dc
leaq 0x148fb(%rip), %rdx     # 0x18370
xorl %eax, %eax
callq 0x1100
movq (%rbx), %rcx
movl $0xa, %esi
movl $0x1, %edx
leaq 0xca02(%rip), %rdi      # 0x10492
jmp 0x3af3
movq %r13, %rdi
callq 0xe88a
testl %eax, %eax
jne 0x3ac9
movq %r13, %rdi
movq %r14, %rsi
leaq 0xc8a1(%rip), %rdx      # 0x1034c
xorl %ecx, %ecx
callq 0x38a8
movq %r13, %rdi
movq %r14, %rsi
leaq 0xcc9b(%rip), %rdx      # 0x1075a
movl $0x1, %ecx
callq 0x38a8
movq %r13, %rdi
leaq 0xcad9(%rip), %rsi      # 0x105ac
callq 0x16e1
leaq 0x14869(%rip), %rax     # 0x18348
movq (%rax), %rcx
movl $0xb, %esi
movl $0x1, %edx
leaq 0xca96(%rip), %rdi      # 0x10589
callq 0x1170
movq 0x40(%r15), %r15
movq 0x8(%r14), %r14
testq %r14, %r14
je 0x3b0e
movq (%r14), %rax
cmpl $0x1, 0x30(%rax)
je 0x3afc
testq %r15, %r15
jne 0x3a30
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: popOutput
void popOutput (astNode *outputHead, moduleST *lst)
{
	varST* searchedVar ;

	while (outputHead != NULL)
	{
		searchedVar = searchVar (lst, outputHead->tok->lexeme) ;
		codePrint ("\t\tPOP AX\n") ;
		codePrint ("\t\tMOV [RBP%s], AX\n", getOffsetStr(searchedVar->offset)) ;

		outputHead = outputHead->next ;
	}

	codePrint ("\n") ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0x3ba1
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x14802(%rip), %r13     # 0x18348
movq 0x8(%r14), %rax
movq 0x8(%rax), %rsi
movq %rbx, %rdi
callq 0xc430
movq %rax, %r15
movq (%r13), %rcx
movl $0x9, %esi
movl $0x1, %edx
leaq 0xc7a5(%rip), %rdi      # 0x10313
callq 0x1170
movq (%r13), %r12
movl 0x1c(%r15), %edi
callq 0x158c
movq %r12, %rdi
leaq 0xce58(%rip), %rsi      # 0x109e2
leaq 0x147df(%rip), %rdx     # 0x18370
xorl %eax, %eax
callq 0x1100
movq 0x38(%r14), %r14
testq %r14, %r14
jne 0x3b46
leaq 0x147a0(%rip), %rax     # 0x18348
movq (%rax), %rsi
movl $0xa, %edi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x10e0
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: retModule
void retModule (moduleST *lst)
{
	codePrint ("\n\t\tMOV RSP, RBP\n") ;
	codePrint ("\t\tPOP RBP\n") ;

	if (lst == realBase->driverST)		// driver module
	{
		#ifdef __linux__
			codePrint ("\t\tMOV RAX, 60\n") ;
			codePrint ("\t\tXOR RDI, RDI\n") ;
			codePrint ("\t\tsyscall\n") ;
		#endif
			
		#ifdef __MACH__
			codePrint ("\t\tMOV RAX, 0x2000001\n") ;
			codePrint ("\t\tXOR RDI, RDI\n") ;
			codePrint ("\t\tsyscall\n") ;
		#endif

		#ifdef _WIN64
			codePrint ("\t\tret\n") ;
		#endif
	}
	else
		codePrint ("\t\tret\n") ;

	printCommentLineNASM () ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x14774(%rip), %r14     # 0x18348
movq (%r14), %rcx
leaq 0xce17(%rip), %rdi      # 0x109f5
movl $0x10, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xce0f(%rip), %rdi      # 0x10a06
movl $0xa, %esi
movl $0x1, %edx
callq 0x1170
leaq 0x2e41b(%rip), %rax     # 0x32028
movq (%rax), %rax
movq (%r14), %rcx
cmpq %rbx, 0xd0(%rax)
je 0x3c2a
leaq 0xd1e9(%rip), %rdi      # 0x10e0c
movl $0x6, %esi
jmp 0x3c68
leaq 0xcde0(%rip), %rdi      # 0x10a11
movl $0xe, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xcdd6(%rip), %rdi      # 0x10a20
movl $0xf, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xcdcd(%rip), %rdi      # 0x10a30
movl $0xa, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xdd68(%rip), %rdi      # 0x119e4
movl $0x65, %esi
movl $0x1, %edx
popq %rbx
popq %r14
popq %rbp
jmp 0x1170
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: freeDynamic
void freeDynamic (varSTentry *varEntry)
{
	if (varEntry == NULL)
		return ;

	char freeReg[5] ;
	RSPAlign () ;

	#if defined __linux__ || defined __MACH__
		strcpy (freeReg, "RDI") ;
	#endif
	#ifdef _WIN64
		strcpy (freeReg, "RCX") ;
		codePrint ("\n\t\tSUB RSP, 32\n") ;
	#endif

	while (varEntry != NULL)
	{
		codePrint ("\n\t\tMOV %s, [RBP%s]\n", freeReg, getOffsetStr (varEntry->thisVarST->offset)) ;

		#if defined __linux__ || defined _WIN64
			codePrint ("\t\tCALL free") ;
		#endif
		#ifdef __MACH__ 
			codePrint ("\t\tCALL _free") ;
		#endif
		codeComment (8, "freeing local dynamic arrays\n") ;

		varEntry = varEntry->next ;
	}

	#ifdef _WIN64
		codePrint ("\t\tADD RSP, 32\n") ;
	#endif

	RSPRestore () ;
}

// Assembly:
testq %rdi, %rdi
je 0x3d37
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x23cb
leaq -0x30(%rbp), %rax
movl $0x494452, (%rax)       # imm = 0x494452
leaq 0x14689(%rip), %r12     # 0x18348
leaq 0xcd89(%rip), %r13      # 0x10a4f
leaq 0xcd8e(%rip), %r14      # 0x10a5b
movq (%r12), %r15
movq (%rbx), %rax
movl 0x1c(%rax), %edi
callq 0x158c
movq %r15, %rdi
leaq 0xcd55(%rip), %rsi      # 0x10a3b
leaq -0x30(%rbp), %rdx
leaq 0x1467f(%rip), %rcx     # 0x18370
xorl %eax, %eax
callq 0x1100
movq (%r12), %rcx
movl $0xb, %esi
movl $0x1, %edx
movq %r13, %rdi
callq 0x1170
movl $0x8, %edi
movq %r14, %rsi
callq 0x153a
movq 0x8(%rbx), %rbx
testq %rbx, %rbx
jne 0x3ccd
callq 0x246c
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: codeGeneration
void codeGeneration(astNode *node)
{
	if (node == NULL)
		return;

	switch (node->id)
	{
		case program :
			codeGeneration (node->child->next) ;		// <otherModules>
			break ;

		case otherModules :
			codeGeneration (node->child) ;					// Do module definitions
			codeGeneration (node->next) ;					// <driverModule> or NULL
			break ;

		case module :
			codePrint ("\n%s:\n", strcmp(node->child->tok->lexeme , "main") ? node->child->tok->lexeme : "@main") ;
			codePrint ("\t\tPUSH RBP\n") ;
			codePrint ("\t\tMOV RBP, RSP\n\n") ;

			moduleGeneration (node->child->next->next->next, NULL) ;
			codeGeneration (node->next) ;					// Moving on to the next module

			break ;

		case driverModule :
			#ifdef __linux__
				codePrint ("\nmain:\n") ;
			#endif

			#ifdef __MACH__
				codePrint ("\n_main:\n") ;
			#endif

			#ifdef _WIN64
				codePrint ("\nWinMain:\n") ;
			#endif

			codePrint ("\t\tPUSH RBP\n") ;
			codePrint ("\t\tMOV RBP, RSP\n\n") ;

			moduleGeneration(node->child, NULL); 				// <statements>
			codeGeneration(node->next); 				// Move to the next child of program

			break ;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0xc4ac(%rip), %r12      # 0x101fc
leaq 0x145f1(%rip), %r15     # 0x18348
leaq 0xced4(%rip), %r14      # 0x10c32
leaq 0xced9(%rip), %r13      # 0x10c3e
testq %rbx, %rbx
je 0x3e83
movl (%rbx), %eax
cmpq $0x9, %rax
ja 0x3e83
movslq (%r12,%rax,4), %rax
addq %r12, %rax
jmpq *%rax
movq 0x30(%rbx), %rbx
jmp 0x3e7a
movq 0x30(%rbx), %rdi
callq 0x3d38
jmp 0x3e7a
movq (%r15), %rcx
movl $0x7, %esi
movl $0x1, %edx
leaq 0xcea1(%rip), %rdi      # 0x10c4f
callq 0x1170
movq (%r15), %rcx
movl $0xb, %esi
movl $0x1, %edx
movq %r14, %rdi
callq 0x1170
movq (%r15), %rcx
movl $0x10, %esi
movl $0x1, %edx
movq %r13, %rdi
callq 0x1170
movq 0x30(%rbx), %rdi
jmp 0x3e73
movq (%r15), %r12
movq 0x30(%rbx), %rax
movq 0x8(%rax), %rax
movq %r14, %r13
movq 0x8(%rax), %r14
movq %r14, %rdi
leaq 0xce0f(%rip), %rsi      # 0x10c11
callq 0x10f0
testl %eax, %eax
leaq 0xce00(%rip), %rax      # 0x10c10
cmoveq %rax, %r14
movq %r12, %rdi
leaq 0xc3de(%rip), %r12      # 0x101fc
leaq 0xce07(%rip), %rsi      # 0x10c2c
movq %r14, %rdx
movq %r13, %r14
leaq 0xce0c(%rip), %r13      # 0x10c3e
xorl %eax, %eax
callq 0x1100
movq (%r15), %rcx
movl $0xb, %esi
movl $0x1, %edx
movq %r14, %rdi
callq 0x1170
movq (%r15), %rcx
movl $0x10, %esi
movl $0x1, %edx
movq %r13, %rdi
callq 0x1170
movq 0x30(%rbx), %rax
movq 0x38(%rax), %rax
movq 0x38(%rax), %rax
movq 0x38(%rax), %rdi
xorl %esi, %esi
callq 0x2c96
movq 0x38(%rbx), %rbx
jmp 0x3d65
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: preamble
void preamble()
{
	codePrint (";;;;;;;;;;; Compiled for 64-bit ") ;

	#ifdef __linux__
		codePrint ("Linux ") ;
	#endif
	#ifdef __MACH__
		codePrint ("macOS ") ;
	#endif
	#ifdef _WIN64
		codePrint ("Windows ") ;
	#endif

	codePrint (";;;;;;;;;;;\n\n") ;

	#if defined __linux__ || defined _WIN64
		codePrint ("extern printf\n") ;
		codePrint ("extern scanf\n") ;
		codePrint ("extern malloc\n") ;
		codePrint ("extern free\n") ;
		codePrint ("extern exit\n") ;

		#ifdef __linux__
			codePrint ("\nglobal main\n") ;
		#endif

		#ifdef _WIN64
			codePrint ("\nglobal WinMain\n") ;
		#endif
	#endif

	#ifdef __MACH__
		codePrint ("extern _printf\n") ;
		codePrint ("extern _scanf\n") ;
		codePrint ("extern _malloc\n") ;
		codePrint ("extern _free\n") ;
		codePrint ("extern _exit\n") ;

		codePrint ("\nglobal _main\n") ;
	#endif

	codePrint ("section .text\n") ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x144a9(%rip), %rbx     # 0x18348
movq (%rbx), %rcx
leaq 0xcdae(%rip), %rdi      # 0x10c57
movl $0x20, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcdb6(%rip), %rdi      # 0x10c78
movl $0x6, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcda4(%rip), %rdi      # 0x10c7f
movl $0xd, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcd99(%rip), %rdi      # 0x10c8d
movl $0xe, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcd8f(%rip), %rdi      # 0x10c9c
movl $0xd, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcd84(%rip), %rdi      # 0x10caa
movl $0xe, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcd7a(%rip), %rdi      # 0x10cb9
movl $0xc, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcd6e(%rip), %rdi      # 0x10cc6
movl $0xc, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcd62(%rip), %rdi      # 0x10cd3
movl $0xd, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcd57(%rip), %rdi      # 0x10ce1
movl $0xe, %esi
movl $0x1, %edx
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x1170
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: errorTF
void errorTF (char *errStr)
{
	RSPAlign () ;

	#if defined __linux__ || defined __MACH__
		codePrint ("\t\tMOV RDI, %s\n", errStr) ;
		codePrint ("\t\tXOR RSI, RSI\n") ;
		codePrint ("\t\tXOR RAX, RAX\n") ;
	#endif
	#ifdef _WIN64
		codePrint ("\t\tMOV RCX, %s\n", errStr) ;
		codePrint ("\t\tXOR RDX, RDX\n") ;
		codePrint ("\t\tSUB RSP, 32\n") ;
	#endif

	#if defined __linux__ || defined _WIN64
		codePrint ("\t\tCALL printf\n") ;
		#ifdef _WIN64
			codePrint ("\t\tADD RSP, 32\n") ;
		#endif
	#endif
	#ifdef __MACH__
		codePrint ("\t\tCALL _printf\n") ;
	#endif

	#if defined __linux__ || defined __MACH__
		codePrint ("\t\tMOV RDI, 1\n") ;
	#endif
	#ifdef _WIN64
		codePrint ("\t\tMOV RCX, 1\n") ;
	#endif

	#if defined __linux__ || defined _WIN64
		codePrint ("\t\tCALL exit\n") ;
	#endif
	#ifdef __MACH__
		codePrint ("\t\tCALL _exit\n") ;
	#endif
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
callq 0x23cb
leaq 0x14385(%rip), %r14     # 0x18348
movq (%r14), %rdi
leaq 0xcd23(%rip), %rsi      # 0x10cf0
movq %rbx, %rdx
xorl %eax, %eax
callq 0x1100
movq (%r14), %rcx
leaq 0xcd1e(%rip), %rdi      # 0x10cff
movl $0xf, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xcd15(%rip), %rdi      # 0x10d0f
movl $0xf, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xcd0c(%rip), %rdi      # 0x10d1f
movl $0xe, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xcd02(%rip), %rdi      # 0x10d2e
movl $0xd, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xccf7(%rip), %rdi      # 0x10d3c
movl $0xc, %esi
movl $0x1, %edx
popq %rbx
popq %r14
popq %rbp
jmp 0x1170
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: printArrStart
void printArrStart ()
{
	codePrint ("\t\tPUSH RDI\n") ;

	#if defined __linux__ || defined __MACH__
		codePrint ("\t\tMOV RDI, @printFormatArray\n") ;
		codePrint ("\t\tXOR RSI, RSI\n") ;
		codePrint ("\t\tXOR RAX, RAX\n") ;
		codePrint ("\t\tPUSH AX\n") ;
		codePrint ("\t\tPUSH BX\n") ;
		codePrint ("\t\tPUSH CX\n") ;
		codePrint ("\t\tPUSH DX\n") ;
	#endif
	#ifdef _WIN64
		codePrint ("\t\tMOV RCX, @printFormatArray\n") ;
		codePrint ("\t\tXOR RDX, RDX\n") ;
		codePrint ("\t\tPUSH BX\n") ;
		codePrint ("\t\tSUB RSP, 38\n") ;
	#endif

	#if defined __linux__ || defined _WIN64
		codePrint ("\t\tCALL printf\n") ;
		#ifdef _WIN64
			codePrint ("\t\tADD RSP, 38\n") ;
		#endif
	#endif
	#ifdef __MACH__
		codePrint ("\t\tCALL _printf\n") ;
	#endif

	#if defined __linux__ || defined __MACH__
		codePrint ("\t\tPOP DX\n") ;
		codePrint ("\t\tPOP CX\n") ;
		codePrint ("\t\tPOP BX\n") ;
		codePrint ("\t\tPOP AX\n") ;
		codePrint ("\t\tPOP RDI\n\n") ;
		codePrint ("\t\tMOV CX, 0\n") ;
	#endif
	#ifdef _WIN64
		codePrint ("\t\tPOP BX\n") ;
		codePrint ("\t\tPOP RDI\n\n") ;
		codePrint ("\t\tMOV AX, 0\n") ;
	#endif

	codePrint ("\n\t.printArr:") ;
	codeComment (8, "printing array") ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x142e3(%rip), %rbx     # 0x18348
movq (%rbx), %rcx
leaq 0xd138(%rip), %rdi      # 0x111a7
movl $0xb, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xccc1(%rip), %rdi      # 0x10d49
movl $0x1d, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcc5e(%rip), %rdi      # 0x10cff
movl $0xf, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcc55(%rip), %rdi      # 0x10d0f
movl $0xf, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xc3bf(%rip), %rdi      # 0x10492
movl $0xa, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcc7b(%rip), %rdi      # 0x10d67
movl $0xa, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcc6d(%rip), %rdi      # 0x10d72
movl $0xa, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcc5f(%rip), %rdi      # 0x10d7d
movl $0xa, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcbe8(%rip), %rdi      # 0x10d1f
movl $0xe, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcc38(%rip), %rdi      # 0x10d88
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcc29(%rip), %rdi      # 0x10d92
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xc20c(%rip), %rdi      # 0x1038e
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xc178(%rip), %rdi      # 0x10313
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcbe8(%rip), %rdi      # 0x10d9c
movl $0xb, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcbdb(%rip), %rdi      # 0x10da8
movl $0xc, %esi
movl $0x1, %edx
callq 0x1170
movq (%rbx), %rcx
leaq 0xcbcf(%rip), %rdi      # 0x10db5
movl $0xc, %esi
movl $0x1, %edx
callq 0x1170
leaq 0xcbc6(%rip), %rsi      # 0x10dc2
movl $0x8, %edi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x153a
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/codegen.c
// Function: printArrEnd
void printArrEnd ()
{
	#if defined __linux__ || defined _WIN64
		codePrint ("\t\tCALL printf\n") ;
		#ifdef _WIN64
			codePrint ("\t\tADD RSP, 36\n") ;
		#endif
	#endif
	#ifdef __MACH__
		codePrint ("\t\tCALL _printf\n") ;
	#endif

	#if defined __linux__ || defined __MACH__
		codePrint ("\t\tPOP DX\n") ;
		codePrint ("\t\tPOP CX\n") ;
		codePrint ("\t\tPOP BX\n") ;
		codePrint ("\t\tPOP AX\n") ;
		codePrint ("\t\tPOP RDI\n\n") ;
		codePrint ("\t\tADD CX, 2\n") ;
		codePrint ("\t\tCMP CX, DX\n") ;
	#endif
	#ifdef _WIN64
		codePrint ("\t\tPOP BX\n") ;
		codePrint ("\t\tPOP AX\n") ;
		codePrint ("\t\tPOP RDI\n\n") ;
		codePrint ("\t\tADD AX, 2\n") ;
		codePrint ("\t\tCMP AX, BX\n") ;
	#endif

	codePrint ("\t\tJNE .printArr\n\n") ;

	#if defined __linux__ || defined __MACH__
		codePrint ("\t\tMOV RDI, @printNewLine\n") ;
		codePrint ("\t\tXOR RSI, RSI\n") ;
		codePrint ("\t\tXOR RAX, RAX\n") ;
	#endif
	#ifdef _WIN64
		codePrint ("\t\tMOV RCX, @printNewLine\n") ;
		codePrint ("\t\tXOR RDX, RDX\n") ;
		codePrint ("\t\tSUB RSP, 32\n") ;
	#endif

	#if defined __linux__ || defined _WIN64
		codePrint ("\t\tCALL printf\n") ;
		#ifdef _WIN64
			codePrint ("\t\tADD RSP, 32\n") ;
		#endif
	#endif
	#ifdef __MACH__
		codePrint ("\t\tCALL _printf\n") ;
	#endif

	RSPRestore () ;
	codePrint ("\n\t\tret\n") ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x1412e(%rip), %r14     # 0x18348
movq (%r14), %rcx
leaq 0xcafb(%rip), %rbx      # 0x10d1f
movl $0xe, %esi
movl $0x1, %edx
movq %rbx, %rdi
callq 0x1170
movq (%r14), %rcx
leaq 0xcb48(%rip), %rdi      # 0x10d88
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xcb39(%rip), %rdi      # 0x10d92
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xc11c(%rip), %rdi      # 0x1038e
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xc088(%rip), %rdi      # 0x10313
movl $0x9, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xcaf8(%rip), %rdi      # 0x10d9c
movl $0xb, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xd18f(%rip), %rdi      # 0x1144c
movl $0xc, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xcafb(%rip), %rdi      # 0x10dd1
movl $0xd, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xcaf0(%rip), %rdi      # 0x10ddf
movl $0x11, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xcae9(%rip), %rdi      # 0x10df1
movl $0x19, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xc9de(%rip), %rdi      # 0x10cff
movl $0xf, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
leaq 0xc9d5(%rip), %rdi      # 0x10d0f
movl $0xf, %esi
movl $0x1, %edx
callq 0x1170
movq (%r14), %rcx
movl $0xe, %esi
movl $0x1, %edx
movq %rbx, %rdi
callq 0x1170
callq 0x246c
movq (%r14), %rcx
leaq 0xca9e(%rip), %rdi      # 0x10e0b
movl $0x7, %esi
movl $0x1, %edx
popq %rbx
popq %r14
popq %rbp
jmp 0x1170
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/ast.c
// Function: connectChildren
void connectChildren (astNode *parent, astNode **siblings, int num)
{
	for (int i = 0 ; i < num - 1; i++)
	{
		siblings[i]->next = siblings[i+1] ;
		siblings[i]->parent = parent ;
	}

	siblings[num-1]->parent = parent ;
	for (int i = num-1 ; i > 0 ; i--)
		siblings[i]->prev = siblings[i-1] ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leal -0x1(%rdx), %ecx
movl %ecx, %eax
cmpl $0x2, %edx
jl 0x5ec0
xorl %r8d, %r8d
movq (%rsi,%r8,8), %r9
movq 0x8(%rsi,%r8,8), %r10
movq %r10, 0x38(%r9)
movq (%rsi,%r8,8), %r9
leaq 0x1(%r8), %r10
movq %rdi, 0x28(%r9)
movq %r10, %r8
cmpq %r10, %rax
jne 0x5e9f
movslq %ecx, %rcx
movq (%rsi,%rcx,8), %rcx
movq %rdi, 0x28(%rcx)
cmpl $0x2, %edx
jl 0x5eea
incq %rax
movq -0x10(%rsi,%rax,8), %rcx
movq -0x8(%rsi,%rax,8), %rdx
movq %rcx, 0x40(%rdx)
decq %rax
cmpq $0x1, %rax
jg 0x5ed3
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/lexer.c
// Function: lexer_init
twinBuffer* lexer_init (FILE *fp)
{
	int buf1_read, buf2_read ;
	twinBuffer *twinBuf = (twinBuffer *) malloc (sizeof(twinBuffer)) ;
	twinBuf->fp = fp ;
 
	if (twinBuf->fp == NULL)
		return NULL ;
 
	twinBuf->buf1 = (char *) malloc (sizeof(char) * (bufSize + 1)) ;
	twinBuf->buf2 = (char *) malloc (sizeof(char) * (bufSize + 1)) ;
 
	buf1_read = fread (twinBuf->buf1, sizeof(char), bufSize, twinBuf->fp) ;
	twinBuf->buf1[buf1_read] = EOF ;
	twinBuf->begin = twinBuf->buf1 ;
	twinBuf->forward = twinBuf->buf1 ;
	twinBuf->where_begin = TWIN_ONE ;
	twinBuf->where_forward = TWIN_ONE ;
 
	buf2_read = fread (twinBuf->buf2, sizeof(char) , bufSize, twinBuf->fp) ;
	twinBuf->buf2[buf2_read] = EOF ;
 
	twinBuf->lineNumber = 1 ;
 
	return twinBuf ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movl $0x38, %edi
callq 0x1120
movq %r14, (%rax)
testq %r14, %r14
je 0x7430
movq %rax, %rbx
movl $0x81, %edi
callq 0x1120
movq %rax, %r12
movq %rax, 0x8(%rbx)
movl $0x81, %edi
callq 0x1120
movq %rax, %r15
movq %rax, 0x10(%rbx)
movl $0x1, %esi
movl $0x80, %edx
movq %r12, %rdi
movq %r14, %rcx
callq 0x1080
cltq
movb $-0x1, %r13b
movb %r13b, (%r12,%rax)
movq %r12, 0x18(%rbx)
movq %r12, 0x20(%rbx)
movq $0x0, 0x28(%rbx)
movl $0x1, %esi
movl $0x80, %edx
movq %r15, %rdi
movq %r14, %rcx
callq 0x1080
cltq
movb %r13b, (%r15,%rax)
movl $0x1, 0x30(%rbx)
jmp 0x7432
xorl %ebx, %ebx
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_O1/anuwu[P]ERPLAG-Compiler/lexer.c
// Function: lexer_destroy
void lexer_destroy (twinBuffer *twinBuf)
{
	free (twinBuf->buf1) ;
	free (twinBuf->buf2) ;
	fclose (twinBuf->fp) ;

	free (twinBuf) ;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x8(%rdi), %rdi
callq 0x1030
movq 0x10(%rbx), %rdi
callq 0x1030
movq (%rbx), %rdi
callq 0x1090
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x1030
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/lexer.c
// Function: getLexemeLineNumber
int getLexemeLineNumber (twinBuffer *twinBuf)
{
	int line = twinBuf->lineNumber ;
 
	if (twinBuf->forward == twinBuf->buf1)
		return line ;
 
	if ((twinBuf->forward == twinBuf->buf2 && twinBuf->buf1[bufSize - 1] == '\n') || (*(twinBuf->forward - 1) == '\n') && *twinBuf->forward != EOF)
		return line - 1 ;
}

// Assembly:
movl 0x30(%rdi), %eax
movq 0x8(%rdi), %rdx
movq 0x20(%rdi), %rcx
cmpq %rdx, %rcx
je 0x74a5
pushq %rbp
movq %rsp, %rbp
cmpq 0x10(%rdi), %rcx
jne 0x7495
cmpb $0xa, 0x7f(%rdx)
je 0x74a0
cmpb $0xa, -0x1(%rcx)
jne 0x74a4
cmpb $-0x1, (%rcx)
je 0x74a4
decl %eax
jmp 0x74a4
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/lexer.c
// Function: resetBeginPointer
void resetBeginPointer (twinBuffer *twinBuf)
{
	if (twinBuf->where_begin == twinBuf->where_forward)
		twinBuf->begin = twinBuf->forward ;
	else
	{
		twinBuf->begin = twinBuf->forward ;
		twinBuf->where_begin = TWIN_TWO ;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl 0x28(%rdi), %eax
movq 0x20(%rdi), %rcx
cmpl 0x2c(%rdi), %eax
movq %rcx, 0x18(%rdi)
je 0x74c1
movl $0x1, 0x28(%rdi)
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/lexer.c
// Function: retract
void retract (twinBuffer *twinBuf)
{
	if (twinBuf->where_forward == TWIN_ONE)
	{
		if (twinBuf->forward == twinBuf->buf1)
			printf ("Cannot retract!\n") ;
		else
			twinBuf->forward-- ;
	}
	else if (twinBuf->where_forward == TWIN_TWO)
	{
		if (twinBuf->forward == twinBuf->buf2)
		{
			twinBuf->forward = &twinBuf->buf1[bufSize - 1] ;
			twinBuf->where_forward = TWIN_ONE ;
		}
		else
			twinBuf->forward-- ;
	}
 
	if (*twinBuf->forward == '\n')
		twinBuf->lineNumber-- ;
 
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl 0x2c(%rdi), %eax
cmpl $0x1, %eax
je 0x772e
testl %eax, %eax
jne 0x7754
movq 0x20(%rbx), %rax
cmpq 0x8(%rbx), %rax
jne 0x7738
leaq 0xa852(%rip), %rdi      # 0x11f79
callq 0x1070
jmp 0x7754
movq 0x20(%rbx), %rax
cmpq 0x10(%rbx), %rax
je 0x7741
decq %rax
movq %rax, 0x20(%rbx)
jmp 0x7754
movq 0x8(%rbx), %rax
addq $0x7f, %rax
movq %rax, 0x20(%rbx)
movl $0x0, 0x2c(%rbx)
movq 0x20(%rbx), %rax
cmpb $0xa, (%rax)
jne 0x7760
decl 0x30(%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/parser.c
// Function: populate_hash
void populate_hash(int index,int enum_value)
{
	if(heads[enum_value].ind == -1)
	{
		heads[enum_value].ind=index;	
	}

	else
	{
		location* tmp=&heads[enum_value];
		while(tmp->next!=NULL)
		{
			tmp=tmp->next;
		}
		tmp->next=init();
		tmp=tmp->next;
		tmp->ind=index;
		tmp->next=NULL;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %edi, %ebx
movslq %esi, %rcx
shlq $0x4, %rcx
leaq 0xf0d5(%rip), %rdx      # 0x18380
leaq (%rdx,%rcx), %rax
cmpl $-0x1, (%rcx,%rdx)
je 0x92dd
movq %rax, %r14
movq 0x8(%rax), %rax
testq %rax, %rax
jne 0x92b5
movl $0x10, %edi
callq 0x1120
xorl %ecx, %ecx
movq %rcx, 0x8(%rax)
movq %rax, 0x8(%r14)
movl %ebx, (%rax)
movq %rcx, 0x8(%rax)
jmp 0x92df
movl %ebx, (%rax)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/anuwu[P]ERPLAG-Compiler/parser.c
// Function: initnode
node * initnode(int l){
	node * tmp = (node*)malloc(sizeof(node));
	tmp->key = (tokenID) l;
	tmp->next = NULL;

	return tmp;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl %edi, %ebx
movl $0x10, %edi
callq 0x1120
movl %ebx, (%rax)
movq $0x0, 0x8(%rax)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq