// File: /workspace/github_c_makefile_star2_O2/chgzm[P]minic/generator.c
// Function: gen
void gen(const TransUnitNode* node) {
    printf(".intel_syntax noprefix\n");

    // init
    label_index              = 2;
    break_label_stack        = create_stack();
    continue_label_stack     = create_stack();
    type_stack               = create_stack();
    current_stmt_label_stack = create_stack();
    size_stack               = create_intstack();
    globalvar_list           = create_vector();
    struct_map               = create_strptrmap(1024);
    enum_map                 = create_strintmap(1024);

    // gen
    for (int i = 0; i < node->external_decl_nodes->size; ++i) {
        process_external_decl(node->external_decl_nodes->elements[i]);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
leaq 0x74ff(%rip), %rdi      # 0x96e9
callq 0x1070
movl $0x2, 0xbef7(%rip)      # 0xe0f0
xorl %eax, %eax
callq 0x81aa
movq %rax, 0xbef1(%rip)      # 0xe0f8
xorl %eax, %eax
callq 0x81aa
movq %rax, 0xbeeb(%rip)      # 0xe100
xorl %eax, %eax
callq 0x81aa
movq %rax, 0xbee5(%rip)      # 0xe108
xorl %eax, %eax
callq 0x81aa
movq %rax, 0xbedf(%rip)      # 0xe110
xorl %eax, %eax
callq 0x823f
movq %rax, 0xbed9(%rip)      # 0xe118
xorl %eax, %eax
callq 0x812e
movq %rax, 0xbed3(%rip)      # 0xe120
movl $0x400, %edi            # imm = 0x400
callq 0x82e4
movq %rax, 0xbeca(%rip)      # 0xe128
movl $0x400, %edi            # imm = 0x400
callq 0x8463
movq %rax, 0xbec1(%rip)      # 0xe130
pushq $0x8
popq %rbp
leaq 0x7352(%rip), %r13      # 0x95cb
xorl %ebx, %ebx
movq 0x30(%rsp), %rax
movq (%rax), %rax
movslq 0x8(%rax), %rcx
cmpq %rcx, %rbx
jge 0x2864
movq (%rax), %rax
movq %rbx, 0x18(%rsp)
movq (%rax,%rbx,8), %rax
movq %rax, 0x8(%rsp)
movq 0x10(%rax), %rax
testq %rax, %rax
je 0x22d6
movq 0x8(%rax), %rax
movq (%rax), %r14
xorl %ebx, %ebx
movslq 0x8(%r14), %rax
cmpq %rax, %rbx
jge 0x22d6
movq 0xbe6d(%rip), %rdi      # 0xe130
movq (%r14), %rax
movq (%rax,%rbx,8), %rsi
movl %ebx, %edx
callq 0x8494
incq %rbx
jmp 0x22b3
movq 0x8(%rsp), %rax
movq 0x8(%rax), %rax
movq %rax, 0x10(%rsp)
testq %rax, %rax
je 0x25e3
movq 0x10(%rsp), %rax
movq (%rax), %rax
movl 0x8(%rax), %ecx
testl %ecx, %ecx
movl $0x0, %edx
cmovlel %edx, %ecx
xorl %edx, %edx
cmpq %rdx, %rcx
je 0x2325
movq (%rax), %rsi
movq (%rsi,%rdx,8), %rsi
movq (%rsi), %rdi
incq %rdx
testq %rdi, %rdi
je 0x2304
callq 0x2873
movq %rax, %r14
jmp 0x2328
xorl %r14d, %r14d
xorl %r15d, %r15d
movq %r14, 0x20(%rsp)
movq 0x10(%rsp), %rax
movq 0x8(%rax), %rbx
movslq 0x8(%rbx), %rax
cmpq %rax, %r15
jge 0x25e3
pushq $0x18
popq %rdi
callq 0x1100
movq %rax, %r12
movq %r14, (%rax)
andl $0x0, 0x10(%r14)
movq (%rbx), %rax
movq %r15, 0x28(%rsp)
movq (%rax,%r15,8), %r15
movq (%r15), %rax
movq (%rax), %rcx
testq %rcx, %rcx
je 0x237a
movl (%rcx), %ecx
movl %ecx, 0x10(%r14)
movl %ebp, %ecx
jmp 0x237e
movl 0x4(%r14), %ecx
movl %ecx, 0x8(%r14)
movq 0x8(%rax), %rbx
movq 0x18(%rbx), %rdi
testq %rdi, %rdi
je 0x2396
callq 0x2a89
jmp 0x2398
xorl %eax, %eax
movl %eax, 0xc(%r14)
movq %rbx, %rdi
callq 0x2abe
movq %rax, %rbx
cmpq $0x0, 0x8(%r15)
movq (%rax), %rsi
leaq 0x71da(%rip), %rdi      # 0x9590
leaq 0x71df(%rip), %rax      # 0x959c
cmoveq %rax, %rdi
xorl %eax, %eax
callq 0x10a0
movq (%rbx), %rdi
callq 0x1190
movq %rax, 0x8(%r12)
movq 0xbd44(%rip), %rdi      # 0xe120
movq %r12, %rsi
callq 0x8167
movq 0x8(%r15), %r15
testq %r15, %r15
je 0x2526
movq (%r15), %rbx
testq %rbx, %rbx
je 0x2447
movq %rbx, %rdi
callq 0x2acb
testb %al, %al
je 0x24b8
movq %rbx, %rdi
callq 0x2b06
movl %eax, %ebx
leaq 0x74d8(%rip), %rdi      # 0x98f2
callq 0x1070
movq 0x8(%r12), %rsi
leaq 0x717f(%rip), %rdi      # 0x95aa
xorl %eax, %eax
callq 0x10a0
leaq 0x7176(%rip), %rdi      # 0x95af
movl %ebx, %esi
xorl %eax, %eax
callq 0x10a0
jmp 0x2515
movq 0x8(%r15), %r15
movq (%r15), %rax
movq (%rax), %rax
movq (%rax), %rax
movq (%rax), %rdi
callq 0x2acb
testb %al, %al
je 0x2533
leaq 0x7487(%rip), %rdi      # 0x98f2
callq 0x1070
movq 0x8(%r12), %rsi
leaq 0x712e(%rip), %rdi      # 0x95aa
xorl %eax, %eax
callq 0x10a0
xorl %ebx, %ebx
leaq 0x7123(%rip), %r14      # 0x95af
movq (%r15), %rax
movslq 0x8(%rax), %rcx
cmpq %rcx, %rbx
jge 0x2515
movq (%rax), %rax
movq (%rax,%rbx,8), %rax
movq (%rax), %rdi
callq 0x2b06
movq %r14, %rdi
movl %eax, %esi
xorl %eax, %eax
callq 0x10a0
incq %rbx
jmp 0x248c
callq 0x2b77
movq %rax, %rbx
leaq 0x742b(%rip), %rdi      # 0x98f2
callq 0x1070
leaq 0x70d7(%rip), %r14      # 0x95aa
movq %r14, %rdi
movq %rbx, %rsi
xorl %eax, %eax
callq 0x10a0
movq (%r15), %rdi
callq 0x2b3e
leaq 0x70cc(%rip), %rdi      # 0x95bb
movq %rax, %rsi
xorl %eax, %eax
callq 0x10a0
movq 0x8(%r12), %rsi
movq %r14, %rdi
xorl %eax, %eax
callq 0x10a0
movq %r13, %rdi
movq %rbx, %rsi
xorl %eax, %eax
callq 0x10a0
leaq 0x73dc(%rip), %rdi      # 0x98f8
callq 0x1070
movq 0x20(%rsp), %r14
movq 0x28(%rsp), %r15
incq %r15
jmp 0x2330
xorl %eax, %eax
callq 0x812e
movq %rax, %rbx
leaq 0x73ae(%rip), %rdi      # 0x98f2
callq 0x1070
xorl %ebp, %ebp
movq (%r15), %rax
movslq 0x8(%rax), %rcx
cmpq %rcx, %rbp
jge 0x25a0
movq (%rax), %rax
movq (%rax,%rbp,8), %r14
callq 0x2b77
movq %rax, %r13
leaq 0x703d(%rip), %rdi      # 0x95aa
movq %rax, %rsi
xorl %eax, %eax
callq 0x10a0
movq (%r14), %rdi
callq 0x2b3e
leaq 0x7035(%rip), %rdi      # 0x95bb
movq %rax, %rsi
xorl %eax, %eax
callq 0x10a0
movq %rbx, %rdi
movq %r13, %rsi
callq 0x8167
incq %rbp
jmp 0x254b
movq 0x8(%r12), %rsi
leaq 0x6ffe(%rip), %rdi      # 0x95aa
xorl %eax, %eax
callq 0x10a0
xorl %r15d, %r15d
pushq $0x8
popq %rbp
leaq 0x700b(%rip), %r13      # 0x95cb
movslq 0x8(%rbx), %rax
cmpq %rax, %r15
jge 0x2515
movq (%rbx), %rax
movq (%rax,%r15,8), %rsi
movq %r13, %rdi
xorl %eax, %eax
callq 0x10a0
incq %r15
jmp 0x25c0
movq 0x8(%rsp), %rax
movq (%rax), %r12
testq %r12, %r12
movq 0x18(%rsp), %rbx
je 0x285c
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x812e
andl $0x0, 0xbb3f(%rip)      # 0xe148
movq %rax, 0xbb30(%rip)      # 0xe140
movq 0x8(%r12), %r15
movq 0x8(%r15), %r14
movq %r14, %rdi
callq 0x2bb2
leaq 0x6f68(%rip), %rdi      # 0x9590
movq %rax, %rsi
xorl %eax, %eax
callq 0x10a0
movq %r14, %rdi
callq 0x2bb2
leaq 0x6f69(%rip), %rdi      # 0x95aa
movq %rax, %rsi
xorl %eax, %eax
callq 0x10a0
movq 0x10(%r12), %rdi
callq 0x2bc2
movl %eax, %r14d
movq %r12, 0x8(%rsp)
movq 0x8(%r12), %rax
testq %rax, %rax
je 0x2683
movq 0x8(%rax), %rax
movq 0x20(%rax), %rax
testq %rax, %rax
je 0x2683
pushq $-0x8
popq %rbx
movq 0x8(%rax), %rax
addl $0x8, %ebx
testq %rax, %rax
jne 0x2677
leaq 0x7076(%rip), %rdi      # 0x9700
callq 0x1070
leaq 0x7075(%rip), %rdi      # 0x970b
callq 0x1070
addl %r14d, %ebx
leaq 0x6f38(%rip), %rdi      # 0x95dd
movl %ebx, %esi
xorl %eax, %eax
callq 0x10a0
movq 0x8(%r15), %rax
movq 0x20(%rax), %rax
testq %rax, %rax
movq 0x18(%rsp), %rbx
je 0x27df
movq 0x8(%rax), %r13
xorl %eax, %eax
movq %r13, %rcx
testq %rcx, %rcx
je 0x26da
movq 0x8(%rcx), %rcx
incl %eax
jmp 0x26cd
movl %eax, %eax
movq %rax, 0x20(%rsp)
pushq $0x1
popq %rcx
testq %r13, %r13
je 0x27df
movq (%r13), %rax
movq 0x8(%rax), %rbp
testq %rbp, %rbp
je 0x27d3
movq 0x20(%rsp), %rdx
movq %rcx, 0x28(%rsp)
subq %rcx, %rdx
movq %rdx, 0x10(%rsp)
movq (%rax), %rax
movl 0x8(%rax), %ecx
testl %ecx, %ecx
movl $0x0, %edx
cmovlel %edx, %ecx
xorl %edx, %edx
cmpq %rdx, %rcx
je 0x2743
movq (%rax), %rsi
movq (%rsi,%rdx,8), %rsi
movq (%rsi), %rdi
incq %rdx
testq %rdi, %rdi
je 0x2722
callq 0x2e58
movq %rax, %r14
jmp 0x2746
xorl %r14d, %r14d
movl 0xb9fb(%rip), %r12d     # 0xe148
addl $0x8, %r12d
movl %r12d, 0xb9f0(%rip)     # 0xe148
movq 0x8(%rbp), %r15
pushq $0x18
popq %rdi
callq 0x1100
movq %rax, %rbx
movq %r14, (%rax)
movl %r12d, 0x14(%rax)
movq (%r15), %rdi
callq 0x1190
movq %rax, 0x8(%rbx)
movq 0xb9bf(%rip), %rdi      # 0xe140
movq %rbx, %rsi
callq 0x8167
movq (%rbp), %rax
testq %rax, %rax
je 0x279f
movl (%rax), %ecx
movq (%rbx), %rax
movl %ecx, 0x10(%rax)
pushq $0x8
popq %rcx
jmp 0x27a5
movq (%rbx), %rax
movl 0x4(%rax), %ecx
movl %ecx, 0x8(%rax)
movl 0x14(%rbx), %esi
leaq 0xb5fe(%rip), %rax      # 0xddb0
movq 0x10(%rsp), %rcx
movq (%rax,%rcx,8), %rdx
leaq 0x6e2a(%rip), %rdi      # 0x95ec
xorl %eax, %eax
callq 0x10a0
movq 0x18(%rsp), %rbx
movq 0x28(%rsp), %rcx
movq 0x8(%r13), %r13
incq %rcx
jmp 0x26e4
movq 0x8(%rsp), %rax
movq 0x10(%rax), %rdi
callq 0x2cfc
movq 0xb95c(%rip), %rsi      # 0xe150
testq %rsi, %rsi
je 0x2807
leaq 0x6daa(%rip), %rdi      # 0x95aa
xorl %eax, %eax
callq 0x10a0
leaq 0x6f0c(%rip), %rdi      # 0x971a
callq 0x1070
leaq 0x6f0f(%rip), %rdi      # 0x9729
callq 0x1070
leaq 0x6f0d(%rip), %rdi      # 0x9733
callq 0x1070
movq 0xb90e(%rip), %rdi      # 0xe140
callq 0x1030
movq 0xb912(%rip), %rdi      # 0xe150
callq 0x1030
andq $0x0, 0xb905(%rip)      # 0xe150
andl $0x0, 0xb8f6(%rip)      # 0xe148
pushq $0x8
popq %rbp
leaq 0x6d6f(%rip), %r13      # 0x95cb
incq %rbx
jmp 0x227b
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq