// File: /workspace/github_cpp_makefile_star2_O2/fondoger[P]C0-Compiler/src/grammar.cpp
// Function: pProgram()
void pProgram()
{
    readSymbol();
    pConstDefinitions(GLOBAL);
    while (true) {
        test(Symset({INTSY, CHARSY, VOIDSY}), Symset({}));
        DataType dtype = (g_sym == INTSY ? DT_INT:
                g_sym == CHARSY ? DT_CHAR : DT_VOID);
        readSymbol();
        if (g_sym == MAINSY) {
            if (dtype != DT_VOID) {
                error(ERR_WRONG_TYPE_OF_MAIN);
            }
            pMainFunctionDefinition();
            // this loop ends only when we found main
            // function's definitions
            break;
        }
        test(Symset({IDENTSY}), Symset({INTSY, CHARSY, VOIDSY}));
        if (g_sym != IDENTSY)
            continue;
        std::string id = g_id;
        readSymbol();
        test(Symset({COMMA, SEMICOLON, LBRACK, LBRACE, LPARENT}), Symset({}));
        if (g_sym == COMMA || g_sym == SEMICOLON || g_sym == LBRACK) {
            // must be variable definition
            pGlobalVariableDefinitionItem(dtype, id);
        } else {
            // must be function definition
            pFunctionDefinition(dtype, id);
            tabClear(LOCAL);    // clear local symbol table
        }
    }
    extraCodeChecking();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x168, %rsp            # imm = 0x168
callq 0x13808
xorl %edi, %edi
callq 0xb618
movabsq $0x300000002, %r12      # imm = 0x300000002
pushq $0x3
popq %r15
leaq 0x19c4b(%rip), %r14     # 0x24610
movq %r12, -0x70(%rbp)
movl $0x4, -0x68(%rbp)
leaq -0x150(%rbp), %rdi
leaq -0x70(%rbp), %rsi
movq %r15, %rdx
callq 0xef20
leaq -0x148(%rbp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0xef20
movq -0x150(%rbp), %rdi
movq -0x148(%rbp), %rsi
callq 0x9f5f
movl (%r14), %ebx
xorl %r13d, %r13d
cmpl $0x3, %ebx
sete %r13b
addl %r13d, %r13d
cmpl $0x2, %ebx
pushq $0x1
popq %rax
cmovel %eax, %r13d
callq 0x13808
cmpl $0xf, (%r14)
je 0xb21b
andl $0x0, -0xb8(%rbp)
leaq -0x140(%rbp), %rdi
leaq -0xb8(%rbp), %rsi
pushq $0x1
popq %rdx
callq 0xef20
movq %r12, -0x70(%rbp)
movl $0x4, -0x68(%rbp)
leaq -0x138(%rbp), %rdi
leaq -0x70(%rbp), %rsi
movq %r15, %rdx
callq 0xef20
movq -0x140(%rbp), %rdi
movq -0x138(%rbp), %rsi
callq 0x9f5f
cmpl $0x0, (%r14)
jne 0xa9c5
leaq -0x130(%rbp), %rdi
leaq 0x19b83(%rip), %rsi     # 0x24618
callq 0x3350
callq 0x13808
leaq -0x70(%rbp), %r15
movups 0xb892(%rip), %xmm0     # 0x1633c
movaps %xmm0, -0x70(%rbp)
movl $0x1d, -0x60(%rbp)
leaq -0x110(%rbp), %rdi
movq %r15, %rsi
pushq $0x5
popq %rdx
callq 0xef20
leaq -0x108(%rbp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0xef20
movq -0x110(%rbp), %rdi
movq -0x108(%rbp), %rsi
callq 0x9f5f
movl (%r14), %eax
cmpq $0x26, %rax
ja 0xaeab
movabsq $0x5080000000, %rcx     # imm = 0x5080000000
btq %rax, %rcx
jae 0xaeab
leaq -0x170(%rbp), %rdi
leaq -0x130(%rbp), %rsi
callq 0x3350
testl %r13d, %r13d
jne 0xab49
movq %r15, %rdi
leaq 0xbceb(%rip), %rsi      # 0x16818
leaq -0xb8(%rbp), %rdx
callq 0x30f0
movq %r15, %rdi
callq 0xa247
movq %r15, %rdi
callq 0x3498
cmpl $0x2, %ebx
leaq 0xb592(%rip), %rsi      # 0x160e5
leaq 0xbafb(%rip), %rax      # 0x16655
cmoveq %rax, %rsi
leaq -0xb8(%rbp), %rdi
leaq -0x100(%rbp), %rdx
callq 0x30f0
movabsq $0x2600000022, %rbx     # imm = 0x2600000022
cmpl $0x1f, (%r14)
jne 0xad49
callq 0x13808
movl $0x11, -0x48(%rbp)
leaq -0xd8(%rbp), %rdi
leaq -0x48(%rbp), %rsi
pushq $0x1
popq %rdx
callq 0xef20
movq %rbx, -0x90(%rbp)
leaq -0xd0(%rbp), %rdi
leaq -0x90(%rbp), %rsi
pushq $0x2
popq %rdx
callq 0xef20
movq -0xd8(%rbp), %rdi
movq -0xd0(%rbp), %rsi
callq 0x9f5f
movl $0x11, -0x48(%rbp)
leaq -0x90(%rbp), %rdi
leaq -0x48(%rbp), %rsi
pushq $0x1
popq %rdx
callq 0xef20
movq -0x90(%rbp), %rax
movl (%r14), %ecx
btq %rcx, %rax
jae 0xae89
leaq 0x19a33(%rip), %rax     # 0x2463c
movl (%rax), %ebx
testl %ebx, %ebx
js 0xb4f9
jne 0xac42
leaq -0x100(%rbp), %r14
movq %r14, %rdi
leaq 0xbc55(%rip), %rsi      # 0x1687b
leaq -0x90(%rbp), %rdx
callq 0x30f0
movq %r14, %rdi
callq 0xa247
movq %r14, %rdi
callq 0x3498
movabsq $0x300000000, %rax      # imm = 0x300000000
movq %rax, -0x48(%rbp)
movl %r13d, -0x40(%rbp)
movl %ebx, -0x3c(%rbp)
orl $-0x1, -0x38(%rbp)
leaq -0x170(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0x14287
movl $0x7, -0x30(%rbp)
leaq -0x90(%rbp), %r14
movq %r14, %rdi
movl %ebx, %esi
callq 0xef70
leaq -0x30(%rbp), %rdi
leaq -0xb8(%rbp), %rsi
leaq -0x170(%rbp), %rdx
movq %r14, %rcx
callq 0x100d0
movq %r14, %rdi
callq 0x3498
callq 0x13808
movl $0x20, -0x30(%rbp)
leaq -0xc8(%rbp), %rdi
leaq -0x30(%rbp), %rsi
pushq $0x1
popq %rdx
callq 0xef20
movabsq $0x2600000022, %rax     # imm = 0x2600000022
movq %rax, -0x90(%rbp)
leaq -0x98(%rbp), %rdi
leaq -0x90(%rbp), %rsi
pushq $0x2
popq %rdx
callq 0xef20
leaq 0x1991e(%rip), %rbx     # 0x24610
movq -0xc8(%rbp), %rdi
movq -0x98(%rbp), %rsi
callq 0x9f5f
movl $0x20, -0x30(%rbp)
leaq -0x90(%rbp), %rdi
leaq -0x30(%rbp), %rsi
pushq $0x1
popq %rdx
callq 0xef20
movl (%rbx), %ebx
movq -0x90(%rbp), %r14
callq 0x13808
btq %rbx, %r14
leaq 0x198d8(%rip), %r14     # 0x24610
movabsq $0x2600000022, %rbx     # imm = 0x2600000022
jb 0xada0
jmp 0xae8e
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, -0x90(%rbp)
movl %r13d, -0x88(%rbp)
orq $-0x1, -0x84(%rbp)
leaq -0x170(%rbp), %r12
movq %r12, %rdi
leaq -0x90(%rbp), %rsi
callq 0x14287
movl $0x7, -0x48(%rbp)
leaq -0x48(%rbp), %rdi
leaq -0xb8(%rbp), %rsi
movq %r12, %rdx
leaq 0x151c5(%rip), %rcx     # 0x1ff60
callq 0x100d0
cmpl $0x24, (%r14)
jne 0xae34
callq 0x13808
andl $0x0, -0x48(%rbp)
leaq -0xc0(%rbp), %rdi
leaq -0x48(%rbp), %rsi
pushq $0x1
popq %rdx
callq 0xef20
movq %rbx, -0x90(%rbp)
leaq -0x50(%rbp), %rdi
leaq -0x90(%rbp), %rsi
pushq $0x2
popq %rdx
callq 0xef20
movq -0xc0(%rbp), %rdi
movq -0x50(%rbp), %rsi
callq 0x9f5f
andl $0x0, -0x48(%rbp)
leaq -0x90(%rbp), %rdi
leaq -0x48(%rbp), %rsi
pushq $0x1
popq %rdx
callq 0xef20
movq -0x90(%rbp), %rax
movl (%r14), %ecx
btq %rcx, %rax
jae 0xae89
leaq -0x170(%rbp), %rdi
leaq 0x197f3(%rip), %rsi     # 0x24618
callq 0x3160
callq 0x13808
jmp 0xab7b
movl $0x26, -0x34(%rbp)
leaq -0x90(%rbp), %rdi
leaq -0x34(%rbp), %rsi
pushq $0x1
popq %rdx
callq 0xef20
movq %rbx, -0x30(%rbp)
leaq -0x48(%rbp), %rdi
leaq -0x30(%rbp), %rsi
pushq $0x2
popq %rdx
callq 0xef20
movq -0x90(%rbp), %rdi
movq -0x48(%rbp), %rsi
callq 0x9f5f
movl $0x26, -0x34(%rbp)
leaq -0x30(%rbp), %rdi
leaq -0x34(%rbp), %rsi
pushq $0x1
popq %rdx
callq 0xef20
callq 0x13808
leaq -0xb8(%rbp), %rdi
callq 0x3498
leaq -0x170(%rbp), %rdi
callq 0x3498
jmp 0xb1fc
movabsq $0x200000000, %rax      # imm = 0x200000000
movq %rax, -0x90(%rbp)
movl %r13d, -0x88(%rbp)
orq $-0x1, -0x84(%rbp)
leaq -0x130(%rbp), %rdi
leaq -0x90(%rbp), %rsi
callq 0x14287
cmpl $0x3, %ebx
leaq 0xb949(%rip), %rsi      # 0x16831
leaq 0xb1f6(%rip), %rax      # 0x160e5
cmoveq %rax, %rsi
cmpl $0x2, %ebx
movl -0x80(%rbp), %eax
movl %eax, 0x15091(%rip)     # 0x1ff90
movups -0x90(%rbp), %xmm0
movups %xmm0, 0x15073(%rip)    # 0x1ff80
leaq 0xb741(%rip), %rax      # 0x16655
cmoveq %rax, %rsi
leaq -0xb8(%rbp), %rdi
movq %r15, %rdx
callq 0x30f0
movl $0x5, -0x70(%rbp)
movq %r15, %rdi
leaq -0xb8(%rbp), %rsi
leaq -0x130(%rbp), %rdx
leaq 0x1501a(%rip), %rcx     # 0x1ff60
callq 0x100d0
cmpl $0x1d, (%r14)
movabsq $0x2600000022, %rbx     # imm = 0x2600000022
leaq -0x100(%rbp), %r13
jne 0xb182
callq 0x13808
movabsq $0x300000002, %rax      # imm = 0x300000002
movq %rax, -0x70(%rbp)
leaq -0x48(%rbp), %rdi
movq %r15, %rsi
pushq $0x2
popq %rdx
callq 0xef20
movl $0x1e, -0x100(%rbp)
leaq -0xd8(%rbp), %rdi
movq %r13, %rsi
pushq $0x1
popq %rdx
callq 0xef20
movq -0x48(%rbp), %rdi
movq -0xd8(%rbp), %rsi
callq 0x9f5f
movabsq $0x300000002, %rax      # imm = 0x300000002
movq %rax, -0x100(%rbp)
movq %r15, %rdi
movq %r13, %rsi
pushq $0x2
popq %rdx
callq 0xef20
movl (%r14), %eax
movq -0x70(%rbp), %rcx
btq %rax, %rcx
jae 0xb16f
xorl %ecx, %ecx
cmpl $0x2, %eax
setne %cl
incl %ecx
movl %ecx, -0x30(%rbp)
callq 0x13808
andl $0x0, -0x70(%rbp)
leaq -0xd0(%rbp), %rdi
movq %r15, %rsi
pushq $0x1
popq %rdx
callq 0xef20
movl $0x1e, -0x100(%rbp)
leaq -0xc8(%rbp), %rdi
movq %r13, %rsi
pushq $0x1
popq %rdx
callq 0xef20
movq -0xd0(%rbp), %rdi
movq -0xc8(%rbp), %rsi
callq 0x9f5f
andl $0x0, -0x100(%rbp)
movq %r15, %rdi
movq %r13, %rsi
pushq $0x1
popq %rdx
callq 0xef20
movq -0x70(%rbp), %rax
movl (%r14), %ecx
btq %rcx, %rax
jae 0xb176
movabsq $0x100000001, %rax      # imm = 0x100000001
movq %rax, -0x100(%rbp)
movl -0x30(%rbp), %eax
movl %eax, -0xf8(%rbp)
orq $-0x1, -0xf4(%rbp)
leaq 0x1958e(%rip), %rdi     # 0x24618
movq %r13, %rsi
callq 0x14287
leaq -0x130(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x13fd0
cmpl $0x1, -0x30(%rbp)
movl $0x6, -0x50(%rbp)
leaq 0xb031(%rip), %rsi      # 0x160e5
leaq 0xb59a(%rip), %rax      # 0x16655
cmoveq %rax, %rsi
movq %r15, %rdi
leaq -0x34(%rbp), %rdx
callq 0x30f0
leaq -0x50(%rbp), %rdi
movq %r15, %rsi
leaq 0x1953f(%rip), %rdx     # 0x24618
leaq 0x14e80(%rip), %rcx     # 0x1ff60
callq 0x100d0
movq %r15, %rdi
callq 0x3498
callq 0x13808
movabsq $0x1e00000024, %rax     # imm = 0x1E00000024
movq %rax, -0x70(%rbp)
leaq -0x98(%rbp), %rdi
movq %r15, %rsi
pushq $0x2
popq %rdx
callq 0xef20
movq %rbx, -0x50(%rbp)
leaq -0xc0(%rbp), %rdi
leaq -0x50(%rbp), %rsi
pushq $0x2
popq %rdx
callq 0xef20
movq -0x98(%rbp), %rdi
movq -0xc0(%rbp), %rsi
callq 0x9f5f
movabsq $0x1e00000024, %rax     # imm = 0x1E00000024
movq %rax, -0x50(%rbp)
movq %r15, %rdi
leaq -0x50(%rbp), %rsi
pushq $0x2
popq %rdx
callq 0xef20
movl (%r14), %eax
movq -0x70(%rbp), %rcx
btq %rax, %rcx
jae 0xb17d
cmpl $0x24, %eax
je 0xaf66
callq 0x13808
jmp 0xb182
callq 0x13808
jmp 0xb182
callq 0x13808
movl $0x21, -0x48(%rbp)
movq %r15, %rdi
leaq -0x48(%rbp), %rsi
pushq $0x1
popq %rdx
callq 0xef20
movq %r13, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0xef20
movq -0x70(%rbp), %rdi
movq -0x100(%rbp), %rsi
callq 0x9f5f
callq 0x13808
pushq $0x1
popq %rdi
callq 0xb618
callq 0xb9c6
callq 0xbd94
movl $0x12, -0x48(%rbp)
leaq -0x48(%rbp), %rdi
leaq 0x14d83(%rip), %rcx     # 0x1ff60
movq %rcx, %rsi
movq %rcx, %rdx
callq 0x100d0
leaq -0xb8(%rbp), %rdi
callq 0x3498
pushq $0x1
popq %rdi
callq 0x1432d
leaq -0x130(%rbp), %rdi
callq 0x3498
movabsq $0x300000002, %r12      # imm = 0x300000002
pushq $0x3
popq %r15
jmp 0xa9c5
testl %r13d, %r13d
je 0xb259
leaq 0xb169(%rip), %rsi      # 0x16390
leaq -0x190(%rbp), %rdi
leaq -0x70(%rbp), %rdx
callq 0x30f0
leaq -0x190(%rbp), %rdi
callq 0xa247
leaq -0x190(%rbp), %rdi
callq 0x3498
cmpl $0xf, (%r14)
jne 0xb518
movups 0xb108(%rip), %xmm0     # 0x16368
movaps %xmm0, -0x100(%rbp)
orl $-0x1, -0xf0(%rbp)
leaq 0xaeae(%rip), %rsi      # 0x16123
leaq -0x70(%rbp), %rdi
leaq -0xb8(%rbp), %rdx
callq 0x30f0
leaq -0x70(%rbp), %rdi
leaq -0x100(%rbp), %rsi
callq 0x14287
leaq -0x70(%rbp), %rdi
callq 0x3498
movl $0x5, -0x98(%rbp)
leaq 0xb582(%rip), %rsi      # 0x16831
leaq -0x70(%rbp), %rdi
leaq -0xc0(%rbp), %rdx
callq 0x30f0
leaq 0xae5d(%rip), %rsi      # 0x16123
leaq -0xb8(%rbp), %rdi
leaq -0x50(%rbp), %rdx
callq 0x30f0
leaq 0x14c83(%rip), %rcx     # 0x1ff60
leaq -0x98(%rbp), %rdi
leaq -0x70(%rbp), %rsi
leaq -0xb8(%rbp), %rdx
callq 0x100d0
leaq -0xb8(%rbp), %rbx
movq %rbx, %rdi
callq 0x3498
leaq -0x70(%rbp), %r13
movq %r13, %rdi
callq 0x3498
callq 0x13808
pushq $0x1d
popq %r14
movl %r14d, (%rbx)
leaq -0x90(%rbp), %r15
leaq -0xb8(%rbp), %r12
pushq $0x1
popq %rbx
movq %r15, %rdi
movq %r12, %rsi
movq %rbx, %rdx
callq 0xef20
movabsq $0x2600000022, %rax     # imm = 0x2600000022
movq %rax, (%r13)
leaq -0x130(%rbp), %r13
leaq -0x70(%rbp), %rsi
pushq $0x2
popq %rdx
movq %r13, %rdi
callq 0xef20
movq (%r15), %rdi
movq (%r13), %rsi
callq 0x9f5f
movl %r14d, (%r12)
leaq -0x70(%rbp), %r15
leaq -0xb8(%rbp), %rsi
movq %r15, %rdi
movq %rbx, %rdx
callq 0xef20
movq (%r15), %rbx
leaq 0x19282(%rip), %rax     # 0x24610
movl (%rax), %r14d
callq 0x13808
btq %r14, %rbx
jae 0xb4e2
pushq $0x1e
popq %r14
leaq -0xb8(%rbp), %r13
movl %r14d, (%r13)
leaq -0x48(%rbp), %r15
pushq $0x1
popq %rbx
movq %r15, %rdi
movq %r13, %rsi
movq %rbx, %rdx
callq 0xef20
leaq -0x70(%rbp), %rsi
movabsq $0x2600000022, %rax     # imm = 0x2600000022
movq %rax, (%rsi)
leaq -0xd8(%rbp), %r12
pushq $0x2
popq %rdx
movq %r12, %rdi
callq 0xef20
movq (%r15), %rdi
movq (%r12), %rsi
callq 0x9f5f
movl %r14d, (%r13)
leaq -0x70(%rbp), %r15
leaq -0xb8(%rbp), %rsi
movq %r15, %rdi
movq %rbx, %rdx
callq 0xef20
movq (%r15), %rbx
leaq 0x191f9(%rip), %rax     # 0x24610
movl (%rax), %r14d
callq 0x13808
btq %r14, %rbx
jae 0xb4e2
pushq $0x21
popq %r14
movl %r14d, (%r13)
leaq -0xd0(%rbp), %r15
pushq $0x1
popq %rbx
movq %r15, %rdi
movq %r13, %rsi
movq %rbx, %rdx
callq 0xef20
leaq -0x70(%rbp), %rsi
movabsq $0x2600000022, %rax     # imm = 0x2600000022
movq %rax, (%rsi)
leaq -0xc8(%rbp), %r12
pushq $0x2
popq %rdx
movq %r12, %rdi
callq 0xef20
movq (%r15), %rdi
movq (%r12), %rsi
callq 0x9f5f
movl %r14d, (%r13)
leaq -0x70(%rbp), %r15
leaq -0xb8(%rbp), %rsi
movq %r15, %rdi
movq %rbx, %rdx
callq 0xef20
movq (%r15), %rbx
leaq 0x19174(%rip), %r15     # 0x24610
movl (%r15), %r14d
callq 0x13808
btq %r14, %rbx
jae 0xb4e2
pushq $0x1
popq %rdi
callq 0xb618
callq 0xb9c6
movq %r15, %rbx
cmpl $0x22, (%rbx)
je 0xb4c6
callq 0xbdb8
jmp 0xb4ba
leaq -0x70(%rbp), %rdi
movl $0x12, (%rdi)
leaq 0x14a89(%rip), %rcx     # 0x1ff60
movq %rcx, %rsi
movq %rcx, %rdx
callq 0x100d0
callq 0x13df6
addq $0x168, %rsp            # imm = 0x168
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xb336(%rip), %rdi      # 0x16836
leaq 0xaedd(%rip), %rsi      # 0x163e4
leaq 0xb333(%rip), %rcx      # 0x16841
movl $0x2cd, %edx            # imm = 0x2CD
callq 0x31c0
leaq 0xb2ca(%rip), %rdi      # 0x167e9
leaq 0xaebe(%rip), %rsi      # 0x163e4
leaq 0xb2cc(%rip), %rcx      # 0x167f9
pushq $0x79
popq %rdx
callq 0x31c0
movq %rax, %rbx
leaq -0x190(%rbp), %rdi
jmp 0xb60b
jmp 0xb567
movq %rax, %rbx
leaq -0xb8(%rbp), %rdi
callq 0x3498
jmp 0xb55e
jmp 0xb55b
jmp 0xb567
movq %rax, %rbx
leaq -0x70(%rbp), %rdi
jmp 0xb60b
movq %rax, %rbx
jmp 0xb610
jmp 0xb5dd
jmp 0xb5dd
jmp 0xb5e9
jmp 0xb5e9
movq %rax, %rbx
leaq -0x70(%rbp), %rdi
jmp 0xb5f3
jmp 0xb588
jmp 0xb5e9
jmp 0xb5e9
jmp 0xb5dd
movq %rax, %rbx
jmp 0xb5f8
movq %rax, %rbx
leaq -0x70(%rbp), %rdi
callq 0x3498
jmp 0xb5e0
jmp 0xb5dd
jmp 0xb5e9
movq %rax, %rbx
leaq -0x100(%rbp), %rdi
jmp 0xb5c0
jmp 0xb5ad
movq %rax, %rbx
jmp 0xb604
jmp 0xb5e9
jmp 0xb5e9
movq %rax, %rbx
leaq -0x90(%rbp), %rdi
callq 0x3498
jmp 0xb5ec
jmp 0xb5e9
jmp 0xb5e9
jmp 0xb5e9
jmp 0xb5e9
jmp 0xb5e9
jmp 0xb5e9
jmp 0xb5e9
jmp 0xb5e9
jmp 0xb5e9
jmp 0xb5e9
jmp 0xb5e9
movq %rax, %rbx
leaq -0xb8(%rbp), %rdi
jmp 0xb5ff
movq %rax, %rbx
leaq -0xb8(%rbp), %rdi
callq 0x3498
leaq -0x170(%rbp), %rdi
callq 0x3498
leaq -0x130(%rbp), %rdi
callq 0x3498
movq %rbx, %rdi
callq 0x3430