// File: /workspace/github_cpp_makefile_star2_O1/navrajsaini[P]PL_Compiler_design_project/parser.cpp
// Function: Parse::VarDefB()
void Parse::VarDefB()//variable definition for multiple itirations
{where="VDB";check();
   if(LHS=="id")
   {
      valLength[valLenPtr]++;
      VarList();
   }else if(LHS=="array")
   {
      eKind = ARR;
      match();
      
      VarList();
      if(LHS=="[")
      { 
	 match();
	 bool sVal = 1;
	 if(LHS=="num")
	 {
	    checkVal=ln[tokeNum][2];	    
	 }else if(LHS=="id")
	 {	   
	    index2 = ln[tokeNum][1];
	    ent = bTable.find_all_level(index2);
	    bool lVal = bTable.search(index2);
	    sVal=lVal;
	    //cout<<bTable.inScope;
	    en=1;
	 }	 
	 Const();
	 if(!sVal)
	 {
	    scopeError("Error, Variable not declared in scope");    
	 }
	 bTable.inScope = 0;
	 if(en=1)
	 {
	    for(int i = 0; i < listDepth; i++)
	    {
	       size[i] = ent.value;
	    }
	 }else
	 {
	    for(int i = 0; i<listDepth;i++)
	    {
	       size[i] = checkVal;
	    }
	 }
	 size[0] = checkVal;
	 int tmp = checkVal;
	 valLength[valLenPtr] = valLength[valLenPtr] + checkVal;//
	 if(!checkDefList())
	    scopeError("Ambiguous definition of array");
	 levelOfCurrentBlock[currentLevel] = levelOfCurrentBlock[currentLevel] + (tmp - 1);
	 if(LHS=="]")
	 {
	    match();
	 }else
	    errorReport();
      }
   }else
   {
      errorReport();
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rdi, %rbx
addq $0x5098, %rdi           # imm = 0x5098
movq 0x50a0(%rbx), %rdx
leaq 0x5a66(%rip), %rcx      # 0x13715
movl $0x3, %r8d
xorl %esi, %esi
callq 0x22b0
movq %rbx, %rdi
callq 0xc41a
leaq 0x5050(%rbx), %r14
leaq 0x552d(%rip), %rsi      # 0x131ff
movq %r14, %rdi
callq 0x2080
testl %eax, %eax
je 0xdd07
leaq 0x5a72(%rip), %rsi      # 0x13757
movq %r14, %rdi
callq 0x2080
testl %eax, %eax
je 0xdd2b
movq %rbx, %rdi
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xc1be
movslq 0x71ec(%rbx), %rax
incl 0x71c4(%rbx,%rax,4)
movq %rbx, %rdi
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xdfd4
movl $0x2, 0x4dd8(%rbx)
leaq 0x5070(%rbx), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x2100
movslq 0x2028(%rbx), %rsi
shlq $0x5, %rsi
addq %rbx, %rsi
movq %r14, %rdi
callq 0x2100
incl 0x2028(%rbx)
movq %rbx, %rdi
callq 0xdfd4
leaq 0x58f7(%rip), %rsi      # 0x13669
movq %r14, %rdi
callq 0x2080
testl %eax, %eax
jne 0xdf99
movq %r15, %rdi
movq %r14, %rsi
callq 0x2100
movslq 0x2028(%rbx), %rsi
shlq $0x5, %rsi
addq %rbx, %rsi
movq %r14, %rdi
callq 0x2100
incl 0x2028(%rbx)
leaq 0x5510(%rip), %rsi      # 0x132c0
movq %r14, %rdi
callq 0x2080
testl %eax, %eax
je 0xde82
leaq 0x5438(%rip), %rsi      # 0x131ff
movq %r14, %rdi
callq 0x2080
testl %eax, %eax
jne 0xde9a
movslq 0x2028(%rbx), %rax
leaq (%rax,%rax,2), %rax
movl 0x2034(%rbx,%rax,4), %edx
movl %edx, 0x4de0(%rbx)
leaq 0x4c38(%rbx), %r12
leaq -0x84(%rbp), %r13
movq %r13, %rdi
movq %r12, %rsi
callq 0x109c6
movups (%r13), %xmm0
movups 0xc(%r13), %xmm1
movups %xmm1, 0x4e1c(%rbx)
movups %xmm0, 0x4e10(%rbx)
movl 0x4de0(%rbx), %esi
movq %r12, %rdi
callq 0x10458
movl %eax, %r12d
movb $0x1, 0x4dd1(%rbx)
movq %rbx, %rdi
callq 0xda32
testb %r12b, %r12b
jne 0xdea2
leaq -0x58(%rbp), %r13
movq %r13, -0x10(%r13)
leaq 0x58c5(%rip), %rsi      # 0x13719
leaq 0x58e3(%rip), %rdx      # 0x1373e
leaq -0x68(%rbp), %r12
movq %r12, %rdi
callq 0x42dc
movq %rbx, %rdi
movq %r12, %rsi
callq 0xc53c
movq -0x68(%rbp), %rdi
cmpq %r13, %rdi
je 0xdea2
callq 0x21b0
jmp 0xdea2
movslq 0x2028(%rbx), %rax
leaq (%rax,%rax,2), %rax
movl 0x2038(%rbx,%rax,4), %eax
movl %eax, 0x4de4(%rbx)
movq %rbx, %rdi
callq 0xda32
movb $0x0, 0x4c38(%rbx)
movb $0x1, 0x4dd1(%rbx)
movslq 0x4d88(%rbx), %rax
testq %rax, %rax
jle 0xded3
xorl %ecx, %ecx
movl 0x4e20(%rbx), %edx
movl %edx, 0x4de8(%rbx,%rcx,4)
incq %rcx
cmpq %rcx, %rax
jne 0xdebe
movl 0x4de4(%rbx), %r13d
movl %r13d, 0x4de8(%rbx)
movslq 0x71ec(%rbx), %rax
addl %r13d, 0x71c4(%rbx,%rax,4)
movq %rbx, %rdi
callq 0xc774
testb %al, %al
jne 0xdf3b
leaq -0x38(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x5834(%rip), %rsi      # 0x1373f
leaq 0x584a(%rip), %rdx      # 0x1375c
leaq -0x48(%rbp), %r12
movq %r12, %rdi
callq 0x42dc
movq %rbx, %rdi
movq %r12, %rsi
callq 0xc53c
movq -0x48(%rbp), %rdi
leaq -0x38(%rbp), %rax
cmpq %rax, %rdi
je 0xdf3b
callq 0x21b0
movslq 0x7224(%rbx), %rax
movl 0x71fc(%rbx,%rax,4), %ecx
addl %r13d, %ecx
decl %ecx
movl %ecx, 0x71fc(%rbx,%rax,4)
leaq 0x541f(%rip), %rsi      # 0x1337b
movq %r14, %rdi
callq 0x2080
testl %eax, %eax
je 0xdf72
movq %rbx, %rdi
callq 0xc1be
jmp 0xdf99
movq %r15, %rdi
movq %r14, %rsi
callq 0x2100
movslq 0x2028(%rbx), %rsi
shlq $0x5, %rsi
addq %rbx, %rsi
movq %r14, %rdi
callq 0x2100
incl 0x2028(%rbx)
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x68(%rbp), %rdi
cmpq %r13, %rdi
jne 0xdfc6
jmp 0xdfcb
movq %rax, %rbx
movq -0x48(%rbp), %rdi
leaq -0x38(%rbp), %rax
cmpq %rax, %rdi
je 0xdfcb
callq 0x21b0
movq %rbx, %rdi
callq 0x2310
nop