LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: findfirst
void findfirst(int result[150], int n, int G[][14]){  //find first set of a given non-terminal
int i, k, j = 0, l;

if(n > 51)
    result[0] = n;

else{

for(i = 0; i < 94; i++)
    if(G[i][0] == n){

        
        if (G[i][1] > 51)
            {if(!presentIn(result, G[i][1])){
                    result[j++] = G[i][1];
                }}

        else{
        for(k = 1; k < size_of(G[i]); k++){
            int flag = 0;
            int subresult[150] = {0};

            findfirst(subresult, G[i][k], G);

            for(l = 0; subresult[l]!=0; l++){
                if(subresult[l] == 109)
                    flag = 1;
                else
                if(!presentIn(result, subresult[l])){
                    result[j++] = subresult[l];
                }
                
            }
            
            if(flag!=1)
                break;



        }
            }


    }}

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x298, %rsp            # imm = 0x298
movq %rdi, %r15
cmpl $0x33, %esi
jle 0x316c
movl %esi, (%r15)
jmp 0x32d7
leaq 0x4(%rdx), %rax
movq %rax, -0x38(%rbp)
leaq 0x4(%r15), %r9
xorl %eax, %eax
movl $0x1, %r14d
movabsq $0x100000000, %rdi      # imm = 0x100000000
xorl %r13d, %r13d
movq %rdx, -0x40(%rbp)
movl %esi, -0x2c(%rbp)
movq %r9, -0x58(%rbp)
movq %rax, -0x50(%rbp)
imulq $0x38, %rax, %r8
cmpl %esi, (%rdx,%r8)
jne 0x32ba
addq %rdx, %r8
movl 0x4(%r8), %eax
cmpl $0x33, %eax
jle 0x31e9
movl (%r15), %ecx
testl %ecx, %ecx
je 0x31da
xorl %edx, %edx
movq %r9, %rsi
cmpl %eax, %ecx
cmovel %r14d, %edx
movl (%rsi), %ecx
addq $0x4, %rsi
testl %ecx, %ecx
jne 0x31c2
testl %edx, %edx
jne 0x32ba
movslq %r13d, %rcx
incl %r13d
movl %eax, (%r15,%rcx,4)
jmp 0x32ba
movl $0x1, %ebx
movq %r8, -0x60(%rbp)
cmpl $-0x1, (%r8)
je 0x3210
movq -0x38(%rbp), %rcx
xorl %eax, %eax
addq %rdi, %rax
cmpl $-0x1, (%rcx)
leaq 0x4(%rcx), %rcx
jne 0x31fe
sarq $0x20, %rax
jmp 0x3212
xorl %eax, %eax
cmpq %rax, %rbx
jge 0x32ba
movq %rbx, -0x48(%rbp)
movq %r8, %rbx
xorl %r12d, %r12d
movl $0x258, %edx            # imm = 0x258
leaq -0x2c0(%rbp), %rdi
xorl %esi, %esi
callq 0x20f0
movq -0x48(%rbp), %rax
movl (%rbx,%rax,4), %esi
movq -0x48(%rbp), %rbx
leaq -0x2c0(%rbp), %rdi
movq -0x40(%rbp), %rdx
callq 0x3148
movq -0x58(%rbp), %r9
xorl %eax, %eax
movl -0x2c0(%rbp,%r12,4), %ecx
cmpl $0x6d, %ecx
je 0x3296
testl %ecx, %ecx
je 0x32a0
movl (%r15), %edx
testl %edx, %edx
je 0x328a
xorl %esi, %esi
movq %r9, %rdi
cmpl %ecx, %edx
cmovel %r14d, %esi
movl (%rdi), %edx
addq $0x4, %rdi
testl %edx, %edx
jne 0x3276
testl %esi, %esi
jne 0x329b
movslq %r13d, %rdx
incl %r13d
movl %ecx, (%r15,%rdx,4)
jmp 0x329b
movl $0x1, %eax
incq %r12
jmp 0x3259
incq %rbx
cmpl $0x1, %eax
movabsq $0x100000000, %rdi      # imm = 0x100000000
movq -0x60(%rbp), %r8
je 0x31f2
movq -0x50(%rbp), %rax
incq %rax
addq $0x38, -0x38(%rbp)
cmpq $0x5e, %rax
movl -0x2c(%rbp), %esi
movq -0x40(%rbp), %rdx
jne 0x3198
addq $0x298, %rsp            # imm = 0x298
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: search
parsetree search(parsetree root, int a){       //search a node with value a in parsetree with root as its root 
    parsetree temp;

    if(root == NULL)
        return NULL;
    else if((root->value == a) && !root->isVisited){
        return root;
    }
    else if((temp=search(root->child, a))!=NULL)
        return temp;
    else if ((temp = search(root->right, a))!=NULL)
        return temp;
    else
        return NULL;
    
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl %esi, %r14d
movq %rdi, %rbx
testq %rbx, %rbx
je 0x3569
cmpl %r14d, 0x8(%rbx)
jne 0x3552
cmpl $0x0, 0x3c(%rbx)
je 0x3570
movq 0x18(%rbx), %rdi
movl %r14d, %esi
callq 0x3534
testq %rax, %rax
jne 0x356d
movq 0x28(%rbx), %rbx
jmp 0x3541
xorl %ebx, %ebx
jmp 0x3570
movq %rax, %rbx
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: insert
void insert(parsetree x, int rule, int G[][14], node* Lex){ //to insert a node in the parsetree

    int *r = G[rule-1];
    int i = 1;
    parsetree temp, temp2, right, left;

    x->isVisited = 1;
    x->rule = rule;

    while(r[i]!=-1){
        int j;
        temp = (parsetree) malloc(sizeof (struct Parse_Tree));
        temp->Lex = createnode();
        temp->Lex->tk->line = Lex->tk->line;
        temp->generated = 0;
        //temp->Lex = (node *) malloc sizeof(node);
        //temp->Lex->tk = (tokenInfo *) malloc sizeof (tokenInfo);
        temp->value =  r[i];
        
        if(r[i] > NON_TERMINALS)
        {
            temp->isleaf = 1;
            //temp->Lex = getNextToken();
        }
        else
            {
                //temp->Lex = NULL;
                temp->isleaf = 0;
            }
        temp->left = NULL;
        temp->right = NULL;
        temp->child = NULL;
        temp->parent = x;
        //temp->Lex = Lex;
        temp->isVisited = 0;

        if(x->child==NULL)
            x->child = temp;
        else                            //if x has children already
        {
            temp2 = x->child;
            while(temp2->right!=NULL)
            {
                right = temp2->right;
                temp2 = right;

            }

            temp2->right = temp;
            temp->left = temp2;
             
        }


        i++;
    }

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movslq %esi, %rsi
imulq $0x38, %rsi, %rax
movl $0x1, 0x3c(%rdi)
movq %rdi, -0x30(%rbp)
movl %esi, 0xc(%rdi)
movq %rdx, -0x38(%rbp)
movl -0x34(%rdx,%rax), %r14d
cmpl $-0x1, %r14d
je 0x3679
addq %rax, -0x38(%rbp)
movq (%rcx), %rax
movq %rax, -0x40(%rbp)
movq -0x30(%rbp), %rax
movq 0x18(%rax), %r13
movl $0x1, %ebx
movl $0x40, %edi
callq 0x2150
movq %rax, %r15
movl $0x8, %edi
callq 0x2150
movq %rax, %r12
movl $0x40, %edi
callq 0x2150
movq %rax, (%r12)
movq %r12, (%r15)
movq -0x40(%rbp), %rcx
movl 0x3c(%rcx), %ecx
movl %ecx, 0x3c(%rax)
xorl %ecx, %ecx
movl %ecx, 0x10(%r15)
movl %r14d, 0x8(%r15)
xorl %eax, %eax
cmpl $0x34, %r14d
setge %al
movl %eax, 0x38(%r15)
xorps %xmm0, %xmm0
movups %xmm0, 0x18(%r15)
movq $0x0, 0x28(%r15)
movq -0x30(%rbp), %rax
movq %rax, 0x30(%r15)
movl %ecx, 0x3c(%r15)
movq %r13, %rax
testq %r13, %r13
je 0x3658
movq %rax, %rcx
movq 0x28(%rax), %rax
testq %rax, %rax
jne 0x3642
movq %r15, 0x28(%rcx)
movq %rcx, 0x20(%r15)
jmp 0x3663
movq -0x30(%rbp), %rax
movq %r15, 0x18(%rax)
movq %r15, %r13
movq -0x38(%rbp), %rax
movl -0x34(%rax,%rbx,4), %r14d
incq %rbx
cmpl $-0x1, %r14d
jne 0x35d2
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: pop
int pop(){                  //pop functionality for stack
    int temp = stack[top];
    stack[top] = -1;
    top--;
    return temp;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movslq 0xc394(%rip), %rcx      # 0xfc60
leaq 0x16fbd(%rip), %rdx     # 0x1a890
movl (%rdx,%rcx,4), %eax
movl $0xffffffff, (%rdx,%rcx,4) # imm = 0xFFFFFFFF
decl %ecx
movl %ecx, 0xc37b(%rip)      # 0xfc60
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: printstack
void printstack(){          //print all elements of the stack
    int i;
    for(i=0;i<STACK_SIZE;i++){
        if(stack[i] == -1){
            break;
        }
        printf("%s ",terms[stack[i]]);
    }
    printf("\n");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
leaq 0x16f97(%rip), %r14     # 0x1a890
leaq 0x9180(%rip), %r15      # 0xca80
leaq 0x5c44(%rip), %rbx      # 0x954b
xorl %r12d, %r12d
movslq (%r12,%r14), %rax
cmpq $-0x1, %rax
je 0x392f
movq (%r15,%rax,8), %rsi
movq %rbx, %rdi
xorl %eax, %eax
callq 0x20b0
addq $0x4, %r12
cmpq $0xc8, %r12
jne 0x390a
movl $0xa, %edi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x2040
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: Print_parsing_table
void Print_parsing_table(int table[][TERMINALS]){ //to print the parsing table
    int i;
    int j;
    for(i=0;i<NON_TERMINALS;i++){
        for(j=0;j<TERMINALS;j++){
            if(table[i][j] == -1){
                printf("_ ");
            }else{
                printf("%d ",table[i][j]);
            }
        }
        printf("\n");
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x5bf6(%rip), %r14      # 0x954f
leaq 0x5bf2(%rip), %r15      # 0x9552
xorl %r12d, %r12d
xorl %r13d, %r13d
movl (%rbx,%r13,4), %esi
cmpl $-0x1, %esi
je 0x397b
movq %r15, %rdi
xorl %eax, %eax
callq 0x20b0
jmp 0x3985
movq %r14, %rdi
xorl %eax, %eax
callq 0x20b0
incq %r13
cmpq $0x3a, %r13
jne 0x3966
movl $0xa, %edi
callq 0x2040
incq %r12
addq $0xe8, %rbx
cmpq $0x33, %r12
jne 0x3963
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: pullup
parsetree pullup(parsetree head){
    if(head->left==NULL){
        head->child->right = head->right;
        if(head->right!=NULL)
            head->right->left = head->child;
        head->parent->child = head->child;
        head->child->parent = head->parent;
        parsetree temp = head->child;
        free(head);
        return temp;

    }
    else
    {
        head->left->right = head->child;
        head->child->left = head->left;
        head->child->right = head->right;
        if(head->right!=NULL)
            head->right->left = head->child;
        head->child->parent = head->parent;
        parsetree temp = head->child;
        free(head);
        return temp;
    }
    
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq 0x20(%rdi), %rax
testq %rax, %rax
je 0x3a6a
movq 0x18(%rdi), %rbx
movq %rbx, 0x28(%rax)
movq %rax, 0x20(%rbx)
movq 0x28(%rdi), %rax
movq %rax, 0x28(%rbx)
movq 0x28(%rdi), %rax
testq %rax, %rax
je 0x3a64
movq %rbx, 0x20(%rax)
movq 0x30(%rdi), %rax
jmp 0x3a8f
movq 0x18(%rdi), %rcx
movq 0x28(%rdi), %rax
movq %rax, 0x28(%rcx)
movq 0x28(%rdi), %rax
testq %rax, %rax
je 0x3a83
movq %rcx, 0x20(%rax)
movq 0x30(%rdi), %rax
movq %rcx, 0x18(%rax)
movq 0x18(%rdi), %rbx
movq %rax, 0x30(%rbx)
callq 0x2030
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: countNodes
void countNodes(parsetree head, int *count){

    if(head==NULL)
        return;
    countNodes(head->child, count);

    count[0]++;
    // printf("%d\n", count[0]);


    countNodes(head->right, count); 



}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
testq %r14, %r14
je 0x3bef
movq 0x18(%r14), %rdi
movq %rbx, %rsi
callq 0x3bc9
incl (%rbx)
movq 0x28(%r14), %r14
jmp 0x3bd6
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: ComputeFirstAndFollowSets
void ComputeFirstAndFollowSets(int G[][14], int first[][11], int follow [][15]){ //Compute the first and follow Sets, given Grammar
    int i, j;
    for(i = 1; i < 52; i++){
        //printf("%d - ", i);
        int result[1024] = {0};
        findfirst(result, i, G);
        for(j = 0; result[j]!=0; j++){
             first[i][j] = result[j];

        }

        first[i][j] = -1;

    }

    for(i = 1; i < 52; i++){
        //printf("%d - ", i);
        int result[1024] = {0};
        findfollow(result, i, G);
        for(j = 0; result[j]!=0; j++){
             
             if(result[j]==-1)
                follow[i][j] = 0;
             else{
                follow[i][j] = result[j];
             }
    }

        follow[i][j] = -1;

    }



}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1008, %rsp           # imm = 0x1008
movq %rdx, %rbx
movq %rdi, %r14
movq %rsi, -0x30(%rbp)
leaq 0x2c(%rsi), %r13
movl $0x1, %r12d
movl $0x1000, %edx           # imm = 0x1000
leaq -0x1030(%rbp), %r15
movq %r15, %rdi
xorl %esi, %esi
callq 0x20f0
movq %r15, %rdi
movl %r12d, %esi
movq %r14, %rdx
callq 0x3148
movl -0x1030(%rbp), %ecx
xorl %eax, %eax
testl %ecx, %ecx
je 0x3e69
movl %ecx, (%r13,%rax,4)
movl -0x102c(%rbp,%rax,4), %ecx
incq %rax
jmp 0x3e54
imulq $0x2c, %r12, %rcx
addq -0x30(%rbp), %rcx
movl $0xffffffff, (%rcx,%rax,4) # imm = 0xFFFFFFFF
incq %r12
addq $0x2c, %r13
cmpq $0x34, %r12
jne 0x3e28
addq $0x3c, %rbx
movl $0x1, %r15d
leaq -0x1030(%rbp), %r12
movl $0x1000, %edx           # imm = 0x1000
movq %r12, %rdi
xorl %esi, %esi
callq 0x20f0
movq %r12, %rdi
movl %r15d, %esi
movq %r14, %rdx
callq 0x32e9
xorl %eax, %eax
movl -0x1030(%rbp,%rax), %ecx
xorl %edx, %edx
cmpl $-0x1, %ecx
je 0x3ec9
testl %ecx, %ecx
je 0x3ed2
movl %ecx, %edx
movl %edx, (%rbx,%rax)
addq $0x4, %rax
jmp 0x3eb5
movl $0xffffffff, (%rbx,%rax) # imm = 0xFFFFFFFF
incq %r15
addq $0x3c, %rbx
cmpq $0x34, %r15
jne 0x3e96
addq $0x1008, %rsp           # imm = 0x1008
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: addLexeme
void addLexeme(parsetree head, node* Lex){

    if(head==NULL){
        return;
    }
    else{
    addLexeme(head->child, Lex);

    /*if(head->value > NON_TERMINALS && head->value!=109){
        if(strcmp(Lex->tk->token,"COMMENTMARK")==0){
            Lex = getNextToken();
        }
        if(strcmp(Lex->tk->value,"declare")==0 && head->value!=59){
            Lex = getNextToken();
        }
        head->Lex = Lex;
        printf("%s\n", terms[head->value]);
        Lex = getNextToken();
    }*/
    if(head->isleaf == 1 && head->value!=109 ){
        
        // head->Lex->tk->line = lineno[pop1];
        strcpy(head->Lex->tk->value,arra[popl++]);
         
        //printf("%s     -     %s\n",terms[head->value],head->Lex->tk->value);
    }
    addLexeme(head->right, Lex);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0xbb70(%rip), %r15      # 0xfc70
testq %r14, %r14
je 0x414c
movq 0x18(%r14), %rdi
movq %rbx, %rsi
callq 0x40e9
cmpl $0x1, 0x38(%r14)
jne 0x4146
cmpl $0x6d, 0x8(%r14)
je 0x4146
movq (%r14), %rax
movq (%rax), %rdi
addq $0x1e, %rdi
movslq 0x16828(%rip), %rax     # 0x1a958
leal 0x1(%rax), %ecx
movl %ecx, 0x1681f(%rip)     # 0x1a958
leaq (%rax,%rax,4), %rax
leaq (%r15,%rax,8), %rsi
callq 0x2060
movq 0x28(%r14), %r14
jmp 0x4100
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./parser.c
// Function: populateLexemes
void populateLexemes(parsetree head, char *filename){



    /*FILE* fp = fopen("testcase5.txt","r");
    rewind(fp);
    fseek( fp, 0, SEEK_SET);
    fp = getstream(fp);*/
 
           node* Lex = getNextToken();                  //Call method in lexer
                    int i = 1;
                    int j = 0;
                    while(strcmp(Lex->tk->value,"$")!=0){

                         //if(strcmp(Lex->tk->value, "**")!=0)
                         // lineno[j] = Lex->tk->value;
                         strcpy(arra[j++],Lex->tk->value);

                         //printf("%s \n", arra[j-1]);
                //printf("%d. token = %s, value = %s, line = %d\n", i++,Lex->tk->token, Lex->tk->value, Lex->tk->line);   //print tokens to console
                        free(Lex);
                        node* Lex = getNextToken();
                    }               //Call method in lexer
    addLexeme(head, Lex);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x255b
movq %rax, %r14
movq (%rax), %r15
addq $0x1e, %r15
leaq 0x636b(%rip), %rsi      # 0xa4e9
movq %r15, %rdi
callq 0x2120
testl %eax, %eax
je 0x41ca
leaq 0xbadf(%rip), %r12      # 0xfc70
leaq 0x6351(%rip), %r13      # 0xa4e9
movq %r12, %rdi
movq %r15, %rsi
callq 0x2060
movq %r14, %rdi
callq 0x2030
callq 0x255b
movq (%r14), %r15
addq $0x1e, %r15
movq %r15, %rdi
movq %r13, %rsi
callq 0x2120
addq $0x28, %r12
testl %eax, %eax
jne 0x4198
movq %rbx, %rdi
movq %r14, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x40e9
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./symboltable.h
// Function: create_node
struct tokNode* create_node(char* key,char* type,char* functionname,char* ifnumvalue){
   struct tokNode *node = (struct tokNode *)malloc(sizeof(struct tokNode));
   strcpy(node->name,key);
   strcpy(node->ifnumvalue,ifnumvalue);
   strcpy(node->scope,functionname);
   strcpy(node->type,type);
   node->offset = 0;
   node->width = 0;
   node->next = NULL;
   return node;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %r12
movl $0x58, %edi
callq 0x2150
movq %rax, %r13
movq %rax, %rdi
movq %r12, %rsi
callq 0x2060
leaq 0x1e(%r13), %rdi
movq %rbx, %rsi
callq 0x2060
leaq 0x28(%r13), %rdi
movq %r14, %rsi
callq 0x2060
leaq 0x37(%r13), %rdi
movq %r15, %rsi
callq 0x2060
xorps %xmm0, %xmm0
movups %xmm0, 0x48(%r13)
movq %r13, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./symboltable.h
// Function: create_func_node
struct funcNode* create_func_node(char *lexeme,char *input_parameters,char *output_parameters){
   struct funcNode *node = (struct funcNode *)malloc(sizeof(struct funcNode));
   strcpy(node->name,lexeme);
   strcpy(node->input,input_parameters);
   strcpy(node->output,output_parameters);
   return node;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movl $0xf0, %edi
callq 0x2150
movq %rax, %r12
movq %rax, %rdi
movq %r15, %rsi
callq 0x2060
leaq 0x1e(%r12), %rdi
movq %r14, %rsi
callq 0x2060
leaq 0x82(%r12), %rdi
movq %rbx, %rsi
callq 0x2060
movq %r12, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./symboltable.h
// Function: hash
int hash(char *key)
{
    int value = 0;
    int i;
    for (i = 0; i < strlen(key); i++)
         value += (int)key[i];
    return (value % SIZE);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x20a0
testq %rax, %rax
je 0x47c7
xorl %ecx, %ecx
xorl %edx, %edx
movsbl (%rbx,%rcx), %esi
addl %esi, %edx
incq %rcx
cmpq %rcx, %rax
jne 0x4798
movslq %edx, %rax
imulq $0x66666667, %rax, %rcx # imm = 0x66666667
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x23, %rcx
addl %edx, %ecx
shll $0x2, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
jmp 0x47c9
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./functionsymboltable.h
// Function: hash_insert_func
int hash_insert_func(char *key,char* input_parameters,char* output_parameters)
{
    int h = hash(key);
    struct funcNode* it = create_func_node(key,input_parameters,output_parameters);
    if (it == NULL){
        return 0;
    }
    while(functable->table[h]->next != NULL){
        h++;
    }
    functable->table[h]->next = it;
    strcpy(arr[funcnum++], key);
    return h;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
callq 0x20a0
xorl %r12d, %r12d
testq %rax, %rax
je 0x4824
xorl %ecx, %ecx
movsbl (%rbx,%rcx), %edx
addl %edx, %r12d
incq %rcx
cmpq %rcx, %rax
jne 0x47f3
movslq %r12d, %rax
imulq $0x66666667, %rax, %rcx # imm = 0x66666667
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x23, %rcx
addl %edx, %ecx
shll $0x2, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
movslq %eax, %r12
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x472c
testq %rax, %rax
je 0x488b
leal -0x1(%r12), %r14d
shlq $0x3, %r12
addq 0x18f59(%rip), %r12     # 0x1d7a0
movq (%r12), %rcx
incl %r14d
addq $0x8, %r12
cmpq $0x0, 0xe8(%rcx)
jne 0x4847
movq %rax, 0xe8(%rcx)
movslq 0x18f2e(%rip), %rax     # 0x1d798
leal 0x1(%rax), %ecx
movl %ecx, 0x18f25(%rip)     # 0x1d798
imulq $0x64, %rax, %rax
leaq 0x18f32(%rip), %rdi     # 0x1d7b0
addq %rax, %rdi
movq %rbx, %rsi
callq 0x2060
jmp 0x488e
xorl %r14d, %r14d
movl %r14d, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./functionsymboltable.h
// Function: get_func_hash_value
int get_func_hash_value(char* functionname){
    int h = hash(functionname);
    while(functable->table[h]->next != NULL){
        if(strcmp(functable->table[h]->next->name,functionname) == 0){
            return h;
        }
        h++;
    }
    return -1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
callq 0x20a0
xorl %r15d, %r15d
testq %rax, %rax
je 0x48e8
xorl %ecx, %ecx
movsbl (%rbx,%rcx), %edx
addl %edx, %r15d
incq %rcx
cmpq %rcx, %rax
jne 0x48b7
movslq %r15d, %rax
imulq $0x66666667, %rax, %rcx # imm = 0x66666667
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x23, %rcx
addl %edx, %ecx
shll $0x2, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
movslq %eax, %r15
movq 0x18eb1(%rip), %r12     # 0x1d7a0
movq (%r12,%r15,8), %rax
movq 0xe8(%rax), %rdi
movl $0xffffffff, %r14d      # imm = 0xFFFFFFFF
testq %rdi, %rdi
je 0x4925
movq %rbx, %rsi
callq 0x2120
testl %eax, %eax
je 0x4922
movq 0x8(%r12,%r15,8), %rax
incq %r15
movq 0xe8(%rax), %rdi
jmp 0x4900
movl %r15d, %r14d
movl %r14d, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./functionsymboltable.h
// Function: get_Func_input_type
void get_Func_input_type(char* functionname){
    int i;
    fnode* it;
    char inputtype[1000] = {'\0'};
    int j=1;
    for(i=0;i<SIZE;i++){
        if(functable->table[i]->next != NULL && ((int)(functable->table[i]->next->name) < 100000000)){
            if(strcmp(functable->table[i]->next->name,functionname) == 0){
                strcpy(inputtype, functable->table[i]->next->input);
                printf("I am    %s    module and input parameters are..\n",functable->table[i]->next->name);
                    char *token;
                    token = strtok(functable->table[i]->next->input, ";");
                    while( token != NULL ) {
                       printf( "%d. %s\n", j++,token );
                       token = strtok(NULL, ";");
                    }
                // return functable->table[i]->next->input;
            }
        }
        // return "";
    }
    // return inputtype;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, -0x30(%rbp)
movl $0x1, %r13d
leaq 0x4a63(%rip), %r15      # 0x93b9
leaq 0x4d67(%rip), %r12      # 0x96c4
xorl %ebx, %ebx
movq 0x18e3a(%rip), %rax     # 0x1d7a0
movq (%rax,%rbx,8), %rax
movq 0xe8(%rax), %r14
testq %r14, %r14
sete %al
cmpl $0x5f5e100, %r14d       # imm = 0x5F5E100
setge %cl
orb %al, %cl
jne 0x4995
movq %r14, %rdi
movq -0x30(%rbp), %rsi
callq 0x2120
testl %eax, %eax
je 0x49a6
movl %r13d, %r14d
incq %rbx
movl %r14d, %r13d
cmpq $0x14, %rbx
jne 0x495f
jmp 0x4a02
leaq 0x4ce6(%rip), %rdi      # 0x9693
movq %r14, %rsi
xorl %eax, %eax
callq 0x20b0
movq 0x18de2(%rip), %rax     # 0x1d7a0
movq (%rax,%rbx,8), %rax
movq 0xe8(%rax), %rdi
addq $0x1e, %rdi
movq %r15, %rsi
callq 0x2180
testq %rax, %rax
je 0x4995
leal 0x1(%r13), %r14d
movq %r12, %rdi
movl %r13d, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0x20b0
xorl %edi, %edi
movq %r15, %rsi
callq 0x2180
movl %r14d, %r13d
testq %rax, %rax
jne 0x49da
jmp 0x4998
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./functionsymboltable.h
// Function: get_Func_output_type
void get_Func_output_type(char* functionname){
    int i;
    fnode* it;
    int j=1;
    char outputtype[1000] = {'\0'};
    for(i=0;i<SIZE;i++){
        if(functable->table[i]->next != NULL && ((int)(functable->table[i]->next->name) < 100000000)){
            if(strcmp(functable->table[i]->next->name,functionname) == 0){
                strcpy(outputtype, functable->table[i]->next->output);
                printf("I am    %s    module and output parameters are..\n",functable->table[i]->next->name);
                    char *token;
                    token = strtok(functable->table[i]->next->output, ";");
                    while( token != NULL ) {
                       printf( "%d. %s\n", j++,token );
                       token = strtok(NULL, ";");
                    }
                    // return functable->table[i]->next->output;
            }
        }
    }

    // return "";
    // return outputtype;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, -0x30(%rbp)
movl $0x1, %r13d
leaq 0x4989(%rip), %r15      # 0x93b9
leaq 0x4c8d(%rip), %r12      # 0x96c4
xorl %ebx, %ebx
movq 0x18d60(%rip), %rax     # 0x1d7a0
movq (%rax,%rbx,8), %rax
movq 0xe8(%rax), %r14
testq %r14, %r14
sete %al
cmpl $0x5f5e100, %r14d       # imm = 0x5F5E100
setge %cl
orb %al, %cl
jne 0x4a6f
movq %r14, %rdi
movq -0x30(%rbp), %rsi
callq 0x2120
testl %eax, %eax
je 0x4a80
movl %r13d, %r14d
incq %rbx
movl %r14d, %r13d
cmpq $0x14, %rbx
jne 0x4a39
jmp 0x4ae0
leaq 0x4c45(%rip), %rdi      # 0x96cc
movq %r14, %rsi
xorl %eax, %eax
callq 0x20b0
movq 0x18d08(%rip), %rax     # 0x1d7a0
movq (%rax,%rbx,8), %rax
movq 0xe8(%rax), %rdi
movl $0x82, %eax
addq %rax, %rdi
movq %r15, %rsi
callq 0x2180
testq %rax, %rax
je 0x4a6f
leal 0x1(%r13), %r14d
movq %r12, %rdi
movl %r13d, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0x20b0
xorl %edi, %edi
movq %r15, %rsi
callq 0x2180
movl %r14d, %r13d
testq %rax, %rax
jne 0x4ab8
jmp 0x4a72
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./functionsymboltable.h
// Function: get_Function_input_type
char* get_Function_input_type(char* functionname){
    int i;
    fnode* it;
    char inputtype[1000] = {'\0'};
    int j=1;
    for(i=0;i<SIZE;i++){
        if(functable->table[i]->next != NULL && ((int)(functable->table[i]->next->name) < 100000000)){
            if(strcmp(functable->table[i]->next->name,functionname) == 0){
                strcpy(inputtype, functable->table[i]->next->input);
                
                // return functable->table[i]->next->input;
            }
        }
        // return "";
    }
    return inputtype;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x3e8, %rsp            # imm = 0x3E8
movq %rdi, %rbx
leaq -0x410(%rbp), %r14
xorl %r12d, %r12d
movl $0x3e8, %edx            # imm = 0x3E8
movq %r14, %rdi
xorl %esi, %esi
callq 0x20f0
movq 0x18c7a(%rip), %r13     # 0x1d7a0
movq (%r13,%r12,8), %rax
movq 0xe8(%rax), %r15
testq %r15, %r15
sete %al
cmpl $0x5f5e100, %r15d       # imm = 0x5F5E100
setge %cl
orb %al, %cl
jne 0x4b64
movq %r15, %rdi
movq %rbx, %rsi
callq 0x2120
testl %eax, %eax
jne 0x4b64
addq $0x1e, %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x2060
incq %r12
cmpq $0x14, %r12
jne 0x4b26
leaq -0x410(%rbp), %rax
addq $0x3e8, %rsp            # imm = 0x3E8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./functionsymboltable.h
// Function: get_Function_output_type
char* get_Function_output_type(char* functionname){
    int i;
    fnode* it;
    int j=1;
    char outputtype[1000] = {'\0'};
    for(i=0;i<SIZE;i++){
        if(functable->table[i]->next != NULL && ((int)(functable->table[i]->next->name) < 100000000)){
            if(strcmp(functable->table[i]->next->name,functionname) == 0){
                strcpy(outputtype, functable->table[i]->next->output);
                
                    // return functable->table[i]->next->output;
            }
        }
    }

    // return "";
    return outputtype;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x3e8, %rsp            # imm = 0x3E8
movq %rdi, %rbx
leaq -0x410(%rbp), %r14
xorl %r12d, %r12d
movl $0x3e8, %edx            # imm = 0x3E8
movq %r14, %rdi
xorl %esi, %esi
callq 0x20f0
movq 0x18be3(%rip), %r13     # 0x1d7a0
movq (%r13,%r12,8), %rax
movq 0xe8(%rax), %r15
testq %r15, %r15
sete %al
cmpl $0x5f5e100, %r15d       # imm = 0x5F5E100
setge %cl
orb %al, %cl
jne 0x4bfe
movq %r15, %rdi
movq %rbx, %rsi
callq 0x2120
testl %eax, %eax
jne 0x4bfe
addq $0x82, %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x2060
incq %r12
cmpq $0x14, %r12
jne 0x4bbd
leaq -0x410(%rbp), %rax
addq $0x3e8, %rsp            # imm = 0x3E8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./functionsymboltable.h
// Function: check_func_present
int check_func_present(char* functionname){
    int i;
    fnode* it;
    int j=1;
    for(i=0;i<SIZE;i++){
        if(functable->table[i]->next != NULL && ((int)(functable->table[i]->next->name) < 100000000)){
            if(strcmp(functable->table[i]->next->name,functionname) == 0){
               return 1;
            }
        }
    }
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x18b6c(%rip), %r14     # 0x1d7a0
xorl %r15d, %r15d
movq (%r14,%r15,8), %rax
movq 0xe8(%rax), %rdi
testq %rdi, %rdi
sete %al
cmpl $0x5f5e100, %edi        # imm = 0x5F5E100
setge %cl
orb %al, %cl
jne 0x4c61
movq %rbx, %rsi
callq 0x2120
testl %eax, %eax
je 0x4c6e
incq %r15
cmpq $0x14, %r15
jne 0x4c37
xorl %eax, %eax
jmp 0x4c73
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./functionsymboltable.h
// Function: directfunctionpointer
fnode* directfunctionpointer(char* functionname){
    int i;
    fnode* it;
    int j=1;
    for(i=0;i<SIZE;i++){
        if(functable->table[i]->next != NULL && ((int)(functable->table[i]->next->name) < 100000000)){
            if(strcmp(functable->table[i]->next->name,functionname) == 0){
               return functable->table[i]->next;
            }
        }
    }
    return NULL;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movq 0x18b0d(%rip), %r15     # 0x1d7a0
xorl %r12d, %r12d
movq (%r15,%r12,8), %rax
movq 0xe8(%rax), %r14
testq %r14, %r14
sete %al
cmpl $0x5f5e100, %r14d       # imm = 0x5F5E100
setge %cl
orb %al, %cl
jne 0x4cc4
movq %r14, %rdi
movq %rbx, %rsi
callq 0x2120
testl %eax, %eax
je 0x4cd0
incq %r12
cmpq $0x14, %r12
jne 0x4c96
xorl %r14d, %r14d
movq %r14, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./tokensymboltable.h
// Function: display
void display(char* functionname){
    int i;
    int j = get_func_hash_value(functionname);
      
    for(i=0;i<SIZE;i++){
        pNode* it  = ht->functable[j]->table[i]->next;

        if(it !=NULL && strcmp(it->name,"")!= 0){

            if(strncmp(ht->functable[j]->table[i]->next->type,"ARRAY",5)==0)
                printf("%-3d %-20s %-22s %-20s %-5d %-6d\n",(sequencenumber++),ht->functable[j]->table[i]->next->name,"ARRAY",ht->functable[j]->table[i]->next->scope,ht->functable[j]->table[i]->next->width,offseter);
           
            else
                printf("%-3d %-20s %-22s %-20s %-5d %-6d\n",(sequencenumber++),ht->functable[j]->table[i]->next->name,ht->functable[j]->table[i]->next->type,ht->functable[j]->table[i]->next->scope,ht->functable[j]->table[i]->next->width,offseter);
            offseter += ht->functable[j]->table[i]->next->width;
            //printf("%d.\t%s\t\t%s\t\t%s\t\t%s\t\t%d\n",(sequencenumber++),ht->functable[j]->table[i]->next->name,ht->functable[j]->table[i]->next->type,ht->functable[j]->table[i]->next->ifnumvalue,ht->functable[j]->table[i]->next->scope,ht->functable[j]->table[i]->next->offset); 
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
callq 0x489a
movslq %eax, %r13
leaq 0x4398(%rip), %rbx      # 0x9307
xorl %r14d, %r14d
movq 0x1af4f(%rip), %rax     # 0x1fec8
movq (%rax,%r13,8), %rax
movq (%rax,%r14,8), %rax
movq 0x50(%rax), %r15
testq %r15, %r15
je 0x4ffa
cmpb $0x0, (%r15)
je 0x4ffa
leaq 0x37(%r15), %r12
movl $0x5, %edx
movq %r12, %rdi
movq %rbx, %rsi
callq 0x2050
movl 0x14906(%rip), %esi     # 0x198b0
leal 0x1(%rsi), %ecx
leaq 0x28(%r15), %r8
testl %eax, %eax
movl %ecx, 0x148f7(%rip)     # 0x198b0
movl 0x4c(%r15), %r9d
movl 0x1aefd(%rip), %eax     # 0x1fec0
cmoveq %rbx, %r12
movl %eax, (%rsp)
leaq 0x4734(%rip), %rdi      # 0x9705
movq %r15, %rdx
movq %r12, %rcx
xorl %eax, %eax
callq 0x20b0
movq 0x1aee3(%rip), %rax     # 0x1fec8
movq (%rax,%r13,8), %rax
movq (%rax,%r14,8), %rax
movq 0x50(%rax), %rax
movl 0x4c(%rax), %eax
addl %eax, 0x1aec6(%rip)     # 0x1fec0
incq %r14
cmpq $0x14, %r14
jne 0x4f72
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./tokensymboltable.h
// Function: displaySymbolTable
void displaySymbolTable(){
    int i;
    printf("\t\t\t\t Symbol Table\n");
    printf("%-3s %-20s %-22s %-20s %5s %6s\n","No.","Identifier name","Type", "Module Scope","Width","Offset");
      
    for(i=0; i<funcnum; i++)
        display(arr[i]);

    //assert(0);


}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
leaq 0x582d(%rip), %rdi      # 0xa855
callq 0x2070
leaq 0x473a(%rip), %rax      # 0x976e
movq %rax, (%rsp)
leaq 0x46e8(%rip), %rdi      # 0x9727
leaq 0x4701(%rip), %rsi      # 0x9747
leaq 0x46fe(%rip), %rdx      # 0x974b
leaq 0x5641(%rip), %rcx      # 0xa695
leaq 0x4700(%rip), %r8       # 0x975b
leaq 0x4706(%rip), %r9       # 0x9768
xorl %eax, %eax
callq 0x20b0
cmpl $0x0, 0x18728(%rip)     # 0x1d798
jle 0x5097
leaq 0x18737(%rip), %rbx     # 0x1d7b0
xorl %r14d, %r14d
movq %rbx, %rdi
callq 0x4f52
incq %r14
movslq 0x1870a(%rip), %rax     # 0x1d798
addq $0x64, %rbx
cmpq %rax, %r14
jl 0x507c
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./tokensymboltable.h
// Function: checksymbolpresent
int checksymbolpresent(char* key,char* functionname){
    int j = get_func_hash_value(functionname);
    int h = hash(key);
    if(ht->functable[j]->table[h]==NULL){
        return 0;
    }
    while(ht->functable[j]->table[h]->next != NULL){
        if(strcmp(key,ht->functable[j]->table[h]->next->name) == 0){
            return 1;
        }
        h++;
    }
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x489a
movl %eax, %r14d
movq %rbx, %rdi
callq 0x20a0
xorl %ecx, %ecx
testq %rax, %rax
je 0x50f9
xorl %edx, %edx
movsbl (%rbx,%rdx), %esi
addl %esi, %ecx
incq %rdx
cmpq %rdx, %rax
jne 0x50c9
movslq %ecx, %rax
imulq $0x66666667, %rax, %rcx # imm = 0x66666667
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x23, %rcx
addl %edx, %ecx
shll $0x2, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
movslq %eax, %rcx
movq 0x1adc8(%rip), %rax     # 0x1fec8
movslq %r14d, %rdx
movq (%rax,%rdx,8), %rax
xorl %r14d, %r14d
cmpq $0x0, (%rax,%rcx,8)
je 0x514a
movq (%rax,%rcx,8), %rdx
movq 0x50(%rdx), %rsi
testq %rsi, %rsi
je 0x514a
leaq (%rax,%rcx,8), %r15
addq $0x8, %r15
movq %rbx, %rdi
callq 0x2120
testl %eax, %eax
je 0x5144
movq (%r15), %rax
movq 0x50(%rax), %rsi
addq $0x8, %r15
testq %rsi, %rsi
jne 0x5126
jmp 0x514a
movl $0x1, %r14d
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./tokensymboltable.h
// Function: getoffset
int getoffset(char* key,char* functionname){
    int j = get_func_hash_value(functionname);
    int h = hash(key);
    while(ht->functable[j]->table[h]->next != NULL){
        if(strcmp(key,ht->functable[j]->table[h]->next->name) == 0){
            return ht->functable[j]->table[h]->next->offset;
        }
        h++;
    }
    return -1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x489a
movl %eax, %r14d
movq %rbx, %rdi
callq 0x20a0
xorl %ecx, %ecx
testq %rax, %rax
je 0x51b2
xorl %edx, %edx
movsbl (%rbx,%rdx), %esi
addl %esi, %ecx
incq %rdx
cmpq %rdx, %rax
jne 0x5182
movslq %ecx, %rax
imulq $0x66666667, %rax, %rcx # imm = 0x66666667
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x23, %rcx
addl %edx, %ecx
shll $0x2, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
movslq %eax, %rcx
movq 0x1ad0f(%rip), %rax     # 0x1fec8
movslq %r14d, %rdx
movq (%rax,%rdx,8), %rax
movq (%rax,%rcx,8), %rdx
movq 0x50(%rdx), %r15
movl $0xffffffff, %r14d      # imm = 0xFFFFFFFF
testq %r15, %r15
je 0x5201
leaq (%rax,%rcx,8), %r12
addq $0x8, %r12
movq %rbx, %rdi
movq %r15, %rsi
callq 0x2120
testl %eax, %eax
je 0x51fd
movq (%r12), %rax
movq 0x50(%rax), %r15
addq $0x8, %r12
testq %r15, %r15
jne 0x51db
jmp 0x5201
movl 0x48(%r15), %r14d
movl %r14d, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./tokensymboltable.h
// Function: gettype
char* gettype(char* key,char* functionname){
    int j = get_func_hash_value(functionname);
    int h = hash(key);
    while(ht->functable[j]->table[h]->next != NULL){
        if(strcmp(key,ht->functable[j]->table[h]->next->name) == 0){
            return ht->functable[j]->table[h]->next->type;
        }
        h++;
    }
    return NULL;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x489a
movl %eax, %r14d
movq %rbx, %rdi
callq 0x20a0
xorl %ecx, %ecx
testq %rax, %rax
je 0x5267
xorl %edx, %edx
movsbl (%rbx,%rdx), %esi
addl %esi, %ecx
incq %rdx
cmpq %rdx, %rax
jne 0x5237
movslq %ecx, %rax
imulq $0x66666667, %rax, %rcx # imm = 0x66666667
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x23, %rcx
addl %edx, %ecx
shll $0x2, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
movslq %eax, %rcx
movq 0x1ac5a(%rip), %rax     # 0x1fec8
movslq %r14d, %rdx
movq (%rax,%rdx,8), %rax
movq (%rax,%rcx,8), %rdx
movq 0x50(%rdx), %r15
testq %r15, %r15
je 0x52af
leaq (%rax,%rcx,8), %r12
addq $0x8, %r12
xorl %r14d, %r14d
movq %rbx, %rdi
movq %r15, %rsi
callq 0x2120
testl %eax, %eax
je 0x52b4
movq (%r12), %rax
movq 0x50(%rax), %r15
addq $0x8, %r12
testq %r15, %r15
jne 0x528d
jmp 0x52bb
xorl %r14d, %r14d
jmp 0x52bb
addq $0x37, %r15
movq %r15, %r14
movq %r14, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./tokensymboltable.h
// Function: automateoffset
void automateoffset(char* functionname){
    int i;
    int j = get_func_hash_value(functionname);
    int offset = 0;
    for(i=0;i<SIZE;i++){
        pNode* it  = ht->functable[j]->table[i]->next;
        if(it !=NULL && strcmp(it->name,"")!= 0){
            if(strcmp(ht->functable[j]->table[i]->next->type,"INTEGER") ==0){
            	offset += 4;
            }
            if(strcmp(ht->functable[j]->table[i]->next->type,"REAL") ==0){
            	offset += 8;
            }
            if(strcmp(ht->functable[j]->table[i]->next->type,"STRING") ==0){
            	offset += strlen(ht->functable[j]->table[i]->next->name);
            }
            if(strcmp(ht->functable[j]->table[i]->next->type,"ARRAY") ==0){
            	offset += 0;
            }
         	ht->functable[j]->table[i]->next->offset = offset;   
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
callq 0x489a
movq 0x1abe7(%rip), %rcx     # 0x1fec8
cltq
movq (%rcx,%rax,8), %rcx
xorl %r14d, %r14d
xorl %r15d, %r15d
movq %rcx, -0x30(%rbp)
movq (%rcx,%r14,8), %rax
movq 0x50(%rax), %r12
testq %r12, %r12
je 0x5363
cmpb $0x0, (%r12)
je 0x5363
leaq 0x37(%r12), %r13
movq %r13, %rdi
leaq 0x47a8(%rip), %rsi      # 0x9abc
callq 0x2120
leal 0x4(%r15), %ebx
testl %eax, %eax
cmovnel %r15d, %ebx
movq %r13, %rdi
leaq 0x4799(%rip), %rsi      # 0x9ac6
callq 0x2120
leal 0x8(%rbx), %r15d
testl %eax, %eax
cmovnel %ebx, %r15d
movq %r13, %rdi
leaq 0x43b8(%rip), %rsi      # 0x96fe
callq 0x2120
testl %eax, %eax
jne 0x535a
movq %r12, %rdi
callq 0x20a0
addl %eax, %r15d
movl %r15d, 0x48(%r12)
movq -0x30(%rbp), %rcx
incq %r14
cmpq $0x14, %r14
jne 0x52f1
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./tokensymboltable.h
// Function: getdirectpointer
pNode* getdirectpointer(char* key,char* functionname){
	int j = get_func_hash_value(functionname);
    int h = hash(key);
    while(ht->functable[j]->table[h]->next != NULL){
        if(strcmp(key,ht->functable[j]->table[h]->next->name) == 0){
            return ht->functable[j]->table[h]->next;
        }
        h++;
    }
    return NULL;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x489a
movl %eax, %r14d
movq %rbx, %rdi
callq 0x20a0
xorl %ecx, %ecx
testq %rax, %rax
je 0x53d4
xorl %edx, %edx
movsbl (%rbx,%rdx), %esi
addl %esi, %ecx
incq %rdx
cmpq %rdx, %rax
jne 0x53a4
movslq %ecx, %rax
imulq $0x66666667, %rax, %rcx # imm = 0x66666667
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x23, %rcx
addl %edx, %ecx
shll $0x2, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
movslq %eax, %rcx
movq 0x1aaed(%rip), %rax     # 0x1fec8
movslq %r14d, %rdx
movq (%rax,%rdx,8), %rax
movq (%rax,%rcx,8), %rdx
movq 0x50(%rdx), %r14
testq %r14, %r14
je 0x5416
leaq (%rax,%rcx,8), %r15
addq $0x8, %r15
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2120
testl %eax, %eax
je 0x5419
movq (%r15), %rax
movq 0x50(%rax), %r14
addq $0x8, %r15
testq %r14, %r14
jne 0x53f7
xorl %r14d, %r14d
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./symboltable.c
// Function: createsymboltable
void createsymboltable(){
        functable = (struct func_hash_table*)malloc(sizeof(struct func_hash_table*));
        int i;
        char *t = "";
        char *inp = "";
        char *output = "";
        for (i = 0;i < SIZE;i++) {
            functable->table[i] = create_func_node(t,inp,output);
        }
        ht = (struct hash_of_hash_tables*)malloc(sizeof(struct hash_of_hash_tables));
        int j;
        for (j = 0 ; j < HASHSIZE ; j++) {
                ht->functable[j] = create_table();
                for ( i = 0 ; i < SIZE ; ++i ) {
                    char *key = "";
                    char* functionname = "";
                    char* type = "";
                    char* ifnumvalue = "";
                    ht->functable[j]->table[i] = create_node(key,type,functionname,ifnumvalue);
                }
        }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl $0x8, %edi
callq 0x2150
movq %rax, 0x17d8b(%rip)     # 0x1d7a0
xorl %r14d, %r14d
leaq 0x422f(%rip), %rbx      # 0x9c4e
movq %rbx, %rdi
movq %rbx, %rsi
movq %rbx, %rdx
callq 0x472c
movq 0x17d6c(%rip), %rcx     # 0x1d7a0
movq %rax, (%rcx,%r14,8)
incq %r14
cmpq $0x14, %r14
jne 0x5a1f
movl $0xa0, %edi
callq 0x2150
movq %rax, 0x1a476(%rip)     # 0x1fec8
xorl %r14d, %r14d
leaq 0x41f2(%rip), %rbx      # 0x9c4e
movl $0xa0, %edi
callq 0x2150
movq 0x1a45b(%rip), %rcx     # 0x1fec8
movq %rax, (%rcx,%r14,8)
xorl %r15d, %r15d
movq %rbx, %rdi
movq %rbx, %rsi
movq %rbx, %rdx
movq %rbx, %rcx
callq 0x46bc
movq 0x1a43c(%rip), %rcx     # 0x1fec8
movq (%rcx,%r14,8), %rcx
movq %rax, (%rcx,%r15,8)
incq %r15
cmpq $0x14, %r15
jne 0x5a74
incq %r14
cmpq $0x14, %r14
jne 0x5a5c
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./codegen.c
// Function: declarevariables
void declarevariables(parsetree head, FILE* fp)
{
    int i;
    char datasection[] = "section .data\n\tnumberin_form:\tdb \"%d\",0\n\n\tnumberout_form:\tdb \"%d\",10,0\n";
    fprintf(fp, "%s", datasection);
    fprintf(fp,"section .bss\n");
   
    char* functionname = "driver";
    int j = get_func_hash_value(functionname);
    for(i=0;i<SIZE;i++){
        pNode* it  = ht->functable[j]->table[i]->next;
        if(it !=NULL && strcmp(it->name,"")!= 0){
        	char* yp = "ARRAY";
        	if(strncmp(it->type,yp,5)!=0)
            fprintf(fp,"\t%s:\t resd %d\n",it->name,1);
        	else{

        		char* type = it->type;
        		char *token = NULL;
            		token = strtok(it->type, "(");
            		if(token!=NULL){
                		token = strtok(NULL, ",");
                		token = strtok(NULL, ")");
                		if(token!=NULL)
                		strcpy(type, token);
            			}

            	int range = atoi(type);
            	fprintf(fp,"\t%s:\t resd %d\n",it->name,range);


        	}
        }


    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
leaq 0x401f(%rip), %rdi      # 0xabb0
callq 0x20e0
leaq 0x34b3(%rip), %rdi      # 0xa050
movl $0xd, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x21d0
leaq 0x26d1(%rip), %rdi      # 0x9287
callq 0x489a
movslq %eax, %r14
xorl %r12d, %r12d
movq 0x19300(%rip), %rax     # 0x1fec8
movq (%rax,%r14,8), %rax
movq (%rax,%r12,8), %rax
movq 0x50(%rax), %r13
testq %r13, %r13
je 0x6c63
cmpb $0x0, (%r13)
je 0x6c63
leaq 0x37(%r13), %r15
movl $0x5, %edx
movq %r15, %rdi
leaq 0x2710(%rip), %rsi      # 0x9307
callq 0x2050
movl $0x1, %ecx
testl %eax, %eax
jne 0x6c4f
movq %r15, %rdi
leaq 0x27be(%rip), %rsi      # 0x93cd
callq 0x2180
testq %rax, %rax
je 0x6c45
xorl %edi, %edi
leaq 0x279f(%rip), %rsi      # 0x93c1
callq 0x2180
xorl %edi, %edi
leaq 0x350e(%rip), %rsi      # 0xa13e
callq 0x2180
testq %rax, %rax
je 0x6c45
movq %r15, %rdi
movq %rax, %rsi
callq 0x2060
movq %r15, %rdi
callq 0x2190
movl %eax, %ecx
movq %rbx, %rdi
leaq 0x3405(%rip), %rsi      # 0xa05e
movq %r13, %rdx
xorl %eax, %eax
callq 0x2130
incq %r12
cmpq $0x14, %r12
jne 0x6bc1
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/Gaurang18[P]Compiler-Project-BITS-Pilani/./codegen.c
// Function: codegen
void codegen(parsetree head, FILE* fp){
    /*parseTree mf = ast->child->right;
    parseTree typedefinitions = mf->child->child;
    parseTree decl = typedefinitions->right;*/
    //print("\nsection .data\n");
    declarevariables(head, fp);
    fprintf(fp,"\nsection .text\n");
    fprintf(fp,"global main\n");
    fprintf(fp,"extern scanf\n");
    fprintf(fp,"extern printf\n");
    fprintf(fp,"\nmain :\n");
    //handle_stmt(decl->right->child, output, ht);
    //fclose(fp);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rsi, %rbx
callq 0x6b79
leaq 0x33d9(%rip), %rdi      # 0xa06d
movl $0xf, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x21d0
leaq 0x33d0(%rip), %rdi      # 0xa07d
movl $0xc, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x21d0
leaq 0x33c4(%rip), %rdi      # 0xa08a
movl $0xd, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x21d0
leaq 0x33b9(%rip), %rdi      # 0xa098
movl $0xe, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x21d0
leaq 0x33af(%rip), %rdi      # 0xa0a7
movl $0x8, %esi
movl $0x1, %edx
movq %rbx, %rcx
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x21d0