LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/Couragewang[P]50_clss/TcpServer.cc
// Function: main
int main(int argc, char *argv[])
{
    if(argc != 2){
        Usage(argv[0]);
        exit(1);
    }

    dict.insert(std::pair<std::string, std::string>("apple", "苹果"));
    dict.insert(std::pair<std::string, std::string>("banana", "香蕉"));
    dict.insert(std::pair<std::string, std::string>("peach", "桃子"));
    dict.insert(std::pair<std::string, std::string>("lemon", "柠檬"));

    int port = atoi(argv[1]);
    TcpServer *tsp = new TcpServer(port);
    tsp->InitServer();
    tsp->Start();
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x60, %rsp
movq %rsi, %rbx
cmpl $0x2, %edi
jne 0x25c0
leaq 0x1b44(%rip), %rsi      # 0x4012
leaq 0x1b43(%rip), %rdx      # 0x4018
leaq -0x50(%rbp), %r14
movq %r14, %rdi
callq 0x262e
leaq 0x3cb8(%rip), %rdi      # 0x61a0
movq %r14, %rsi
callq 0x312e
leaq -0x50(%rbp), %rdi
callq 0x2674
leaq 0x1b1f(%rip), %rsi      # 0x401f
leaq 0x1b1f(%rip), %rdx      # 0x4026
movq %r14, %rdi
callq 0x2694
leaq 0x3c8a(%rip), %rdi      # 0x61a0
movq %r14, %rsi
callq 0x312e
leaq -0x50(%rbp), %rdi
callq 0x2674
leaq 0x1aff(%rip), %rsi      # 0x402d
leaq 0x1afe(%rip), %rdx      # 0x4033
movq %r14, %rdi
callq 0x262e
leaq 0x3c5c(%rip), %rdi      # 0x61a0
movq %r14, %rsi
callq 0x312e
leaq -0x50(%rbp), %rdi
callq 0x2674
leaq 0x1ade(%rip), %rsi      # 0x403a
leaq 0x1add(%rip), %rdx      # 0x4040
movq %r14, %rdi
callq 0x262e
leaq 0x3c2e(%rip), %rdi      # 0x61a0
movq %r14, %rsi
callq 0x312e
leaq -0x50(%rbp), %rdi
callq 0x2674
movq 0x8(%rbx), %rdi
callq 0x2260
movl %eax, %ebx
movl $0xb8, %edi
callq 0x2190
movq %rax, %r14
movq %rax, %rdi
movl %ebx, %esi
callq 0x26da
movq %r14, %rdi
callq 0x26f4
movq %r14, %rdi
callq 0x27fc
xorl %eax, %eax
addq $0x60, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq (%rbx), %rsi
leaq -0x70(%rbp), %rdi
leaq -0x50(%rbp), %rdx
callq 0x20c0
leaq -0x70(%rbp), %rdi
callq 0x246c
leaq -0x70(%rbp), %rdi
callq 0x20e0
pushq $0x1
popq %rdi
callq 0x21e0
movq %rax, %rbx
leaq -0x70(%rbp), %rdi
callq 0x20e0
jmp 0x261c
movq %rax, %rbx
jmp 0x261c
movq %rax, %rbx
movq %r14, %rdi
callq 0x2170
jmp 0x261c
jmp 0x2610
jmp 0x2610
jmp 0x2610
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x2674
movq %rbx, %rdi
callq 0x22b0
// File: /workspace/github_cpp_makefile_star2_O2/Couragewang[P]50_clss/./TcpServer.hpp
// Function: TcpServer::InitServer()
void InitServer()
        {
            listen_sock = socket(AF_INET, SOCK_STREAM, 0);
            if(listen_sock < 0){
                std::cerr << "socket error" << std::endl;
                exit(2);
            }

            int opt = 1;
            setsockopt(listen_sock, SOL_SOCKET, SO_REUSEADDR, &opt, sizeof(opt));

            struct sockaddr_in local;
            bzero(&local, sizeof(local));
            local.sin_family = AF_INET;
            local.sin_port = htons(port);
            local.sin_addr.s_addr = htonl(INADDR_ANY);
            //local.sin_addr.s_addr = inet_addr(ip.c_str());
            if(bind(listen_sock, (struct sockaddr*)&local, sizeof(local)) < 0){
                std::cerr << "bind error" << std::endl;
                exit(3);
            }
            if(listen(listen_sock, 5) < 0){
                std::cout << "listen error" << std::endl;
                exit(4);
            }
            signal(SIGCHLD, SIG_IGN);
            pool.InitThreadPool();
        }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
pushq $0x2
popq %rdi
pushq $0x1
popq %rsi
xorl %edx, %edx
callq 0x2070
movl %eax, (%rbx)
testl %eax, %eax
js 0x279a
leaq -0x14(%rbp), %rcx
movl $0x1, (%rcx)
pushq $0x1
popq %rsi
pushq $0x2
popq %rdx
pushq $0x4
popq %r8
movl %eax, %edi
callq 0x22c0
leaq -0x24(%rbp), %r14
pushq $0x10
popq %rsi
movq %r14, %rdi
callq 0x22a0
movw $0x2, (%r14)
movzwl 0x4(%rbx), %eax
rolw $0x8, %ax
movw %ax, 0x2(%r14)
andl $0x0, 0x4(%r14)
movl (%rbx), %edi
pushq $0x10
popq %rdx
movq %r14, %rsi
callq 0x2050
testl %eax, %eax
js 0x27b9
movl (%rbx), %edi
pushq $0x5
popq %rsi
callq 0x21b0
testl %eax, %eax
js 0x27d8
pushq $0x11
popq %rdi
pushq $0x1
popq %rsi
callq 0x21c0
addq $0x8, %rbx
movq %rbx, %rdi
callq 0x2bbc
addq $0x20, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq 0x384f(%rip), %rdi      # 0x5ff0
leaq 0x189f(%rip), %rsi      # 0x4047
callq 0x2180
movq %rax, %rdi
callq 0x20f0
pushq $0x2
jmp 0x27f5
movq 0x3830(%rip), %rdi      # 0x5ff0
leaq 0x188d(%rip), %rsi      # 0x4054
callq 0x2180
movq %rax, %rdi
callq 0x20f0
pushq $0x3
jmp 0x27f5
movq 0x37f1(%rip), %rdi      # 0x5fd0
leaq 0x1879(%rip), %rsi      # 0x405f
callq 0x2180
movq %rax, %rdi
callq 0x20f0
pushq $0x4
popq %rdi
callq 0x21e0
nop
// File: /workspace/github_cpp_makefile_star2_O2/Couragewang[P]50_clss/./ThreadPool.hpp
// Function: ThreadPool::ThreadRountie(void*)
static void *ThreadRountie(void *arg)
        {
            pthread_detach(pthread_self());
            ThreadPool *tp = (ThreadPool*)arg;
            for( ; ; ){
                tp->LockQueue();
                while(tp->IsEmpty()){
                    tp->IdleThread();
                }
                Task t;
                tp->PopTask(t);
                tp->UnlockQueue();
                t.Run();
            }
        }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
callq 0x2160
movq %rax, %rdi
callq 0x2110
leaq 0x58(%rbx), %r14
leaq -0x28(%rbp), %r15
movq %r14, %rdi
callq 0x2220
movq %rbx, %rdi
callq 0x2c60
movq %rbx, %rdi
testb %al, %al
je 0x2c47
callq 0x2c76
jmp 0x2c31
movq %r15, %rsi
callq 0x2c8e
movq %r14, %rdi
callq 0x2120
movl -0x28(%rbp), %edi
callq *-0x20(%rbp)
jmp 0x2c29
nop
// File: /workspace/github_cpp_makefile_star2_O2/Couragewang[P]50_clss/./TcpServer.hpp
// Function: TcpServer::Service(int)
static void Service(int sock)
        {
            while(1){
                char buf[1024];
                ssize_t s = read(sock, buf, sizeof(buf)-1);
                if(s > 0){
                    buf[s] = 0;
                    auto it = dict.find(buf);
                    if(it == dict.end()){
                        write(sock, "NULL", strlen("NULL"));
                        continue;
                    }
                    write(sock, (it->second).c_str(), (it->second).size());
                }
                else if(s == 0){
                    std::cout << "client quit!" << std::endl;
                    break;
                }
                else{
                    std::cerr << "read error" << std::endl;
                    break;
                }
            }
            close(sock);
        }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x428, %rsp            # imm = 0x428
movl %edi, %ebx
leaq -0x450(%rbp), %r14
leaq -0x50(%rbp), %r15
leaq 0x3426(%rip), %r13      # 0x61a8
movl $0x3ff, %edx            # imm = 0x3FF
movl %ebx, %edi
movq %r14, %rsi
callq 0x2200
testq %rax, %rax
jle 0x2df2
movb $0x0, -0x450(%rbp,%rax)
movq %r15, %rdi
movq %r14, %rsi
leaq -0x29(%rbp), %rdx
callq 0x20c0
leaq 0x33ec(%rip), %rdi      # 0x61a0
movq %r15, %rsi
callq 0x2e92
movq %rax, %r12
movq %r15, %rdi
callq 0x20e0
cmpq %r13, %r12
je 0x2ddf
movq 0x40(%r12), %rsi
movq 0x48(%r12), %rdx
movl %ebx, %edi
callq 0x20a0
jmp 0x2d82
movl %ebx, %edi
leaq 0x12a3(%rip), %rsi      # 0x408b
pushq $0x4
popq %rdx
callq 0x20a0
jmp 0x2d82
je 0x2e04
movq 0x31f5(%rip), %rdi      # 0x5ff0
leaq 0x129b(%rip), %rsi      # 0x409d
jmp 0x2e12
movq 0x31c5(%rip), %rdi      # 0x5fd0
leaq 0x127e(%rip), %rsi      # 0x4090
callq 0x2180
movq %rax, %rdi
callq 0x20f0
movl %ebx, %edi
callq 0x22e0
addq $0x428, %rsp            # imm = 0x428
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x20e0
movq %rbx, %rdi
callq 0x22b0
// File: /workspace/github_cpp_makefile_star2_O2/Couragewang[P]50_clss/./ThreadPool.hpp
// Function: ThreadPool::PushTask(Task const&)
void PushTask(const Task &t)
        {
            LockQueue();
            task_queue.push(t);
            WakeupOneThread();
            UnlockQueue();
        }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x58(%rdi), %r15
movq %r15, %rdi
callq 0x2220
leaq 0x8(%r14), %rdi
movq %rbx, %rsi
callq 0x2f32
subq $-0x80, %r14
movq %r14, %rdi
callq 0x2030
movq %r15, %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x2120
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/bit_extractor.cpp
// Function: operator<<(std::ostream&, bit_code)
std::ostream& operator<<(std::ostream& os, const bit_code bc) {
   
   unsigned int n    = bc.mSize;
   unsigned int mask = 1 << (n-1);
      
   os << "0b";
   while (n) {
      if (bc.mValue & mask) {
         os << "1";
      }
      else {
         os << "0";
      }
      mask >>= 1;
      --n;
   }
   
   return os;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %r15
shrq $0x20, %r15
leal -0x1(%r15), %ecx
pushq $0x1
popq %rbp
shll %cl, %ebp
leaq 0x3a60(%rip), %rsi      # 0x6004
callq 0x2180
leaq 0x3a59(%rip), %r12      # 0x6009
leaq 0x3a50(%rip), %r13      # 0x6007
subl $0x1, %r15d
jb 0x25d3
testl %r14d, %ebp
movq %r13, %rsi
cmoveq %r12, %rsi
movq %rbx, %rdi
callq 0x2180
shrl %ebp
jmp 0x25b7
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/hex_out.cpp
// Function: hex_bulk_output(std::ostream&, int, unsigned char*, unsigned long)
void hex_bulk_output(std::ostream &os, const int width, uint8_t *p, size_t size) {
   int column = 0;
   for (uint32_t i=0;i<size;++i) {
      os << std::hex << std::setw(2) << std::setfill('0') << (uint32_t)p[i] << " ";
      
      if (width == ++column) {
         os << std::endl;
         column = 0;
      }
   }
   os << std::endl;
 
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r14
movl %esi, %ebp
movq %rdi, %r15
xorl %r12d, %r12d
xorl %r13d, %r13d
movl %r12d, %r12d
cmpq %rbx, %r12
jae 0x266f
movq (%r15), %rax
movq -0x18(%rax), %rcx
movl 0x18(%r15,%rcx), %edx
andl $-0x4b, %edx
orl $0x8, %edx
movl %edx, 0x18(%r15,%rcx)
movq -0x18(%rax), %rax
movq $0x2, 0x10(%r15,%rax)
movq %r15, %rdi
pushq $0x30
popq %rsi
callq 0x2220
movzbl (%r14,%r12), %esi
movq %rax, %rdi
callq 0x20f0
movq %rax, %rdi
leaq 0x3ed6(%rip), %rsi      # 0x6528
callq 0x2180
incl %r13d
cmpl %ebp, %r13d
jne 0x266a
movq %r15, %rdi
callq 0x20d0
xorl %r13d, %r13d
incl %r12d
jmp 0x2604
movq %r15, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x20d0
nopl (%rax)
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/klv.cpp
// Function: klv_item::klv_item()
klv_item::klv_item() : mKLVList(0) {
   for (int i=0;i<16;++i) {
      mKey[i] = 0;
   }
   mLength = 0;
   mValue = 0;
}

// Assembly:
andq $0x0, 0x20(%rdi)
xorl %eax, %eax
cmpq $0x10, %rax
je 0x269e
movb $0x0, (%rdi,%rax)
incq %rax
jmp 0x268f
andl $0x0, 0x10(%rdi)
andq $0x0, 0x18(%rdi)
retq
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/klv.cpp
// Function: klv_item::parse_value()
bool klv_item::parse_value() {
   int rval = 0;

   switch (mKey[4]) {
   case KLV_RC_DICTIONARY:
      break;
   case KLV_RC_GROUP:
      if (mKey[5] == KLV_GROUP_UNIVERSAL_SET) {
         if (mKLVList) {
            delete mKLVList;
         }

         mKLVList = new std::list<std::shared_ptr<klv_item>>;
         
         // Initialize Bit Extractor
         bit_extractor be(mValue, mLength, BE_BIG_ENDIAN);
         // Need a KLV parser instance
         klv_parser klvp;
         
         klvp.set_verbosity(true);
         klvp.set_validation(true);
         
         bool klv_ret_val;
         do {
            auto p_klvi = std::shared_ptr<klv_item>(new klv_item);
            klv_ret_val = klvp.get_klv_item(*p_klvi, be);
            if (klv_ret_val) {
               mKLVList->push_back(p_klvi);
            }
            std::cout << "    Bytes left: " << be.get_bytes_left() << std::endl;
         } while (true == klv_ret_val);
      }
      else if (mKey[6] == KLV_GROUP_GLOBAL_SET) {
         
      }
      else if (mKey[6] == KLV_GROUP_LOCAL_SET) {
         
      }
      else if (mKey[6] == KLV_GROUP_VARIABLE_LENGTH_PACK) {
         
      }
      else if (mKey[6] == KLV_GROUP_FIXED_LENGTH_PACK) {
         
      }
      break;
   case KLV_RC_WRAPPER:
      break;           
   case KLV_RC_LABEL:
      break;            
   }
   
   return rval;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
cmpb $0x2, 0x4(%rdi)
jne 0x27c3
movq %rdi, %rbx
cmpb $0x1, 0x5(%rdi)
jne 0x27c3
movq 0x20(%rbx), %r14
testq %r14, %r14
je 0x2709
movq %r14, %rdi
callq 0x31a6
pushq $0x18
popq %rsi
movq %r14, %rdi
callq 0x21a0
pushq $0x18
popq %rdi
callq 0x2190
movq %rax, 0x8(%rax)
movq %rax, (%rax)
andq $0x0, 0x10(%rax)
movq %rax, 0x20(%rbx)
movq 0x18(%rbx), %rax
movl 0x10(%rbx), %ecx
leaq 0x10(%rsp), %r14
movq %rax, (%r14)
movl %ecx, 0x8(%r14)
movb $0x0, 0xc(%r14)
andl $0x0, 0x10(%r14)
movb $0x1, 0x14(%r14)
movq %rsp, %r13
movq 0x688b(%rip), %rbp      # 0x8fd8
leaq 0x38b7(%rip), %r15      # 0x600b
pushq $0x28
popq %rdi
callq 0x2190
movq %rax, %r12
movq %rax, %rdi
callq 0x2688
movq %r13, %rdi
movq %r12, %rsi
callq 0x3338
movq (%rsp), %rsi
movq %r14, %rdx
callq 0x27f6
movl %eax, %r12d
testb %al, %al
je 0x2791
movq 0x20(%rbx), %rdi
movq %r13, %rsi
callq 0x3178
movq %rbp, %rdi
movq %r15, %rsi
callq 0x2180
movl 0x18(%rsp), %esi
subl 0x20(%rsp), %esi
movq %rax, %rdi
callq 0x20f0
movq %rax, %rdi
callq 0x20d0
leaq 0x8(%rsp), %rdi
callq 0x31f0
testb %r12b, %r12b
jne 0x2754
xorl %eax, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x31f0
movq %rbx, %rdi
callq 0x2290
nop
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/./bit_extractor.hpp
// Function: bit_extractor::show_bits(unsigned char)
unsigned int show_bits(unsigned char n) {
      unsigned int rval = 0;

      unsigned char *p = mBuffer + mContextBytePos; 
      
      const unsigned char comp_bit_pos = 8 - mContextBitPos;


      rval |= ((unsigned int)*p++ >> mContextBitPos);
      //std::cout << "R0: " << std::hex << rval << std::endl;
      rval |= ((unsigned int)*p++ << comp_bit_pos);
      //std::cout << "R1: " << std::hex << rval << std::endl;
      rval |= ((unsigned int)*p++ << (comp_bit_pos+8));
      //std::cout << "R2: " << std::hex << rval << std::endl;
      rval |= ((unsigned int)*p++ << (comp_bit_pos+16));
      //std::cout << "R3: " << std::hex << rval << std::endl;
      
      if (mContextBitPos) {
         rval |= ((unsigned int)*p++ << (comp_bit_pos+24));
         //std::cout << "R4: " << std::hex << rval << std::endl;
      }
      
      unsigned int mask = g_mask[n-1]; 
      
      rval &= mask;

      if (mEndianess) {
         unsigned int temp1 = 0;
         unsigned int temp2 = 0;
         unsigned int temp3 = 0;
         unsigned int temp4 = 0;

         if (n == 16) {
            temp1 = rval >> 8;

            rval = temp1 | ((rval & 0xFF) << 8);
         }
         else if (n == 24) {
            temp1 = rval & 0xFF;     // First byte
            temp2 = rval & 0xFF0000; // Third byte

            rval  = (temp1 << 16) | (rval & 0xFF00) | (temp2 >> 16);  
         }
         else if (n == 32) {
            temp1 = rval & 0xFF;        // First byte
            temp2 = rval & 0xFF00;      // Second byte            
            temp3 = rval & 0xFF0000;    // Third byte
            temp4 = rval & 0xFF000000;  // Fourth byte
            
            rval = (temp1 << 24) | (temp2 << 8) | (temp3 >> 8) | (temp4 >> 24);
         }
      }

      return rval;
   }

// Assembly:
pushq %rbp
pushq %rbx
movq (%rdi), %r9
movl 0x10(%rdi), %r10d
movb 0xc(%rdi), %r8b
movb $0x8, %dl
subb %r8b, %dl
movzbl (%r9,%r10), %r11d
movl %r8d, %ecx
shrl %cl, %r11d
movzbl 0x1(%r9,%r10), %ebx
movl %edx, %ecx
shll %cl, %ebx
movzbl 0x2(%r9,%r10), %ebp
movb $0x10, %cl
subb %r8b, %cl
shll %cl, %ebp
movzbl 0x3(%r9,%r10), %eax
movb $0x18, %cl
subb %r8b, %cl
shll %cl, %eax
orl %r11d, %ebx
orl %ebp, %eax
orl %ebx, %eax
testb %r8b, %r8b
je 0x32ca
movzbl 0x4(%r9,%r10), %r8d
addb $0x18, %dl
movl %edx, %ecx
shll %cl, %r8d
orl %r8d, %eax
movzbl %sil, %ecx
leaq 0x5e9b(%rip), %rdx      # 0x9170
andl -0x4(%rdx,%rcx,4), %eax
cmpb $0x1, 0x14(%rdi)
jne 0x331f
cmpb $0x20, %sil
je 0x331d
cmpl $0x18, %ecx
je 0x32fe
cmpl $0x10, %ecx
jne 0x331f
movl %eax, %ecx
shrl $0x8, %ecx
shll $0x8, %eax
movzwl %ax, %eax
orl %ecx, %eax
jmp 0x331f
movl $0xff, %ecx
movl %eax, %edx
andl %ecx, %edx
shll $0x10, %edx
movl %eax, %esi
andl $0xff00, %esi           # imm = 0xFF00
orl %edx, %esi
shrl $0x10, %eax
andl %ecx, %eax
orl %esi, %eax
jmp 0x331f
bswapl %eax
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/./mxf_base.hpp
// Function: mxf_file::mxf_file(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
mxf_file(std::string file_name) : m_file_name(file_name) {
      if (!m_is_UL_key_dictionary_init) {
         init_UL_key_dictionary();
         m_is_UL_key_dictionary_init = true;
      }

      std::ifstream in(m_file_name, std::ifstream::ate | std::ifstream::binary);
      if (in.fail()) {
         m_state = -1;
      }
      else {
         m_state = 0;
         
         m_file_size = in.tellg();

         // return at the begining
         in.seekg(0, in.beg);

         std::cout << "Opening : " << m_file_name
                   << " " << m_file_size << " bytes." << std::endl;

         // Allocate mem ory for file
         m_p_data = new uint8_t [m_file_size];

         // Read 
         in.read((char *)m_p_data, m_file_size);
         in.close();
      }
   }

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x208, %rsp            # imm = 0x208
movq %rdi, %rbx
andq $0x0, 0x70(%rdi)
andq $0x0, 0xf8(%rdi)
andq $0x0, 0x168(%rdi)
leaq 0x178(%rdi), %r14
movq %r14, %rdi
callq 0x21f0
leaq 0x1b0(%rbx), %r15
movq %r15, 0x1b8(%rbx)
movq %r15, 0x1b0(%rbx)
andq $0x0, 0x1c0(%rbx)
leaq 0x5cb1(%rip), %r12      # 0x92b8
cmpb $0x0, (%r12)
jne 0x3618
callq 0x4c18
movb $0x1, (%r12)
movq %rsp, %rdi
pushq $0x6
popq %rdx
movq %r14, %rsi
callq 0x2240
movq (%rsp), %rax
movq -0x18(%rax), %rax
testb $0x5, 0x20(%rsp,%rax)
je 0x3641
orl $-0x1, 0x1a8(%rbx)
jmp 0x36e0
andl $0x0, 0x1a8(%rbx)
movq %rsp, %rdi
callq 0x2280
movl %eax, 0x198(%rbx)
movq %rsp, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x21e0
movq 0x596f(%rip), %rdi      # 0x8fd8
leaq 0x2d3f(%rip), %rsi      # 0x63af
callq 0x2180
movq %rax, %rdi
movq %r14, %rsi
callq 0x2170
leaq 0x2ea1(%rip), %rsi      # 0x6528
movq %rax, %rdi
callq 0x2180
movl 0x198(%rbx), %esi
movq %rax, %rdi
callq 0x20f0
leaq 0x2d16(%rip), %rsi      # 0x63ba
movq %rax, %rdi
callq 0x2180
movq %rax, %rdi
callq 0x20d0
movl 0x198(%rbx), %r12d
movq %r12, %rdi
callq 0x2030
movq %rax, 0x1a0(%rbx)
movq %rsp, %rdi
movq %rax, %rsi
movq %r12, %rdx
callq 0x21c0
movq %rsp, %rdi
callq 0x2060
movq %rsp, %rdi
callq 0x2070
addq $0x208, %rsp            # imm = 0x208
popq %rbx
popq %r12
popq %r14
popq %r15
retq
jmp 0x3705
jmp 0x36fb
movq %rax, %r12
jmp 0x3710
movq %rax, %r12
jmp 0x3720
movq %rax, %r12
movq %rsp, %rdi
callq 0x2070
movq %r15, %rdi
callq 0x31a6
movq %r14, %rdi
callq 0x22b8
leaq 0x108(%rbx), %rdi
callq 0x3a10
leaq 0x98(%rbx), %rdi
callq 0x3a1e
addq $0x10, %rbx
movq %rbx, %rdi
callq 0x3a2c
movq %r12, %rdi
callq 0x2290
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/./mxf_base.hpp
// Function: mxf_file::build_klv_list()
bool build_klv_list() {
      bool rval = true;
      if (m_p_data) {
         // Initialize Bit Extractor
         bit_extractor be(m_p_data, m_file_size, BE_BIG_ENDIAN);
         // Need a KLV parser instance
         klv_parser klvp;

         klvp.set_verbosity(true);
         klvp.set_validation(true);

         bool klv_ret_val;
         do {
            auto p_klvi = std::shared_ptr<klv_item>(new klv_item);
            klv_ret_val = klvp.get_klv_item(*p_klvi, be);
            
            if (klv_ret_val) {
               m_klv_list.push_back(p_klvi);
            }
            //std::cout << "  Bytes left: " << be.get_bytes_left() << std::endl; 
         } while (true == klv_ret_val);
      }
      return rval;
   }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq 0x1a0(%rdi), %rax
testq %rax, %rax
je 0x3814
movq %rdi, %rbx
movl 0x198(%rdi), %ecx
leaq 0x20(%rsp), %rdx
movq %rax, (%rdx)
movl %ecx, 0x8(%rdx)
movb $0x0, 0xc(%rdx)
andl $0x0, 0x10(%rdx)
movb $0x1, 0x14(%rdx)
leaq 0x18(%rsp), %r15
movq %r15, %rdi
callq 0x3172
pushq $0x1
popq %rbp
movq %r15, %rdi
movl %ebp, %esi
callq 0x27ea
movq %r15, %rdi
movl %ebp, %esi
callq 0x27f0
addq $0x1b0, %rbx            # imm = 0x1B0
leaq 0x10(%rsp), %r12
pushq $0x28
popq %r13
leaq 0x8(%rsp), %rbp
movq %r13, %rdi
callq 0x2190
movq %rax, %r14
movq %rax, %rdi
callq 0x2688
movq %rbp, %rdi
movq %r14, %rsi
callq 0x3338
movq 0x8(%rsp), %rsi
movq %r15, %rdi
leaq 0x20(%rsp), %rdx
callq 0x27f6
testb %al, %al
je 0x380c
movq %rbx, %rdi
movq %rbp, %rsi
callq 0x3178
movq %r12, %rdi
callq 0x31f0
jmp 0x37c3
movq %r12, %rdi
callq 0x31f0
movb $0x1, %al
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
pushq $0x28
popq %rsi
movq %r14, %rdi
callq 0x21a0
jmp 0x3840
movq %rax, %rbx
movq %r12, %rdi
callq 0x31f0
movq %rbx, %rdi
callq 0x2290
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/./mxf_base.hpp
// Function: mxf_file::parse()
void parse() {
      for (const auto &e: m_klv_list) {
         std::string name =  m_UL_key_dictionary.find(e->mKey);
         if (name == m_partition_pack_name) {
            decode_partition_pack(*e);        
         }
         else if ((name == m_fill_item_name) || 
                  (name == m_operational_pattern_name) || 
                  (name == m_primer_pack_name)) {
         
         }
         e->output(std::cout, "");
         std::cout << " NAME : " << name << std::endl << std::endl;
         std::cout << " PAYLOAD = " << std::endl;
         hex_bulk_output(std::cout, 32, e->mValue, e->mLength);
         std::cout << std::endl; 
      }
   }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdi, 0x10(%rsp)
leaq 0x1b0(%rdi), %rbx
leaq 0x38(%rsp), %r15
leaq 0x18(%rsp), %rbp
movq 0x5765(%rip), %r12      # 0x8fd8
movq %rbx, %r13
movq (%r13), %r13
cmpq %rbx, %r13
je 0x3988
movq 0x10(%r13), %rdx
movq %r15, %rdi
leaq 0x59f7(%rip), %rsi      # 0x9288
callq 0x3a3a
movq %r15, %rdi
leaq 0x5988(%rip), %rsi      # 0x9228
callq 0x3b15
testb %al, %al
je 0x38b9
movq 0x10(%r13), %rsi
movq 0x10(%rsp), %rdi
callq 0x3b3e
jmp 0x38ee
movq %r15, %rdi
leaq 0x5945(%rip), %rsi      # 0x9208
callq 0x3b15
testb %al, %al
jne 0x38ee
movq %r15, %rdi
leaq 0x5972(%rip), %rsi      # 0x9248
callq 0x3b15
testb %al, %al
jne 0x38ee
movq %r15, %rdi
leaq 0x597f(%rip), %rsi      # 0x9268
callq 0x3b15
movq 0x10(%r13), %r14
movq %rbp, %rdi
leaq 0x2c2d(%rip), %rsi      # 0x6529
leaq 0xf(%rsp), %rdx
callq 0x3572
movq %r14, %rdi
movq %r12, %rsi
movq %rbp, %rdx
callq 0x29ee
movq %rbp, %rdi
callq 0x22b8
movq %r12, %rdi
leaq 0x2ac6(%rip), %rsi      # 0x63ec
callq 0x2180
movq %rax, %rdi
movq %r15, %rsi
callq 0x2170
movq %rax, %rdi
callq 0x20d0
movq %rax, %rdi
callq 0x20d0
movq %r12, %rdi
leaq 0x2aa5(%rip), %rsi      # 0x63f5
callq 0x2180
movq %rax, %rdi
callq 0x20d0
movq 0x10(%r13), %rax
movq 0x18(%rax), %rdx
movl 0x10(%rax), %ecx
movq %r12, %rdi
pushq $0x20
popq %rsi
callq 0x25e8
movq %r12, %rdi
callq 0x20d0
movq %r15, %rdi
callq 0x22b8
jmp 0x3876
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x39a8
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0x22b8
jmp 0x39ab
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0x22b8
movq %rbx, %rdi
callq 0x2290
nop
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/./dictionary.hpp
// Function: Dictionary<16>::find[abi:cxx11](Key<16> const&)
std::string find(const Key<T> &x) {
      std::string rval = "NULL";
      bool found = true;
      // Find the root
      auto it = mRootNodes.find(x[0]);
      if (it != mRootNodes.end()) {
         DictionaryNode *current_node = it->second;
         for (int i=1;i<T;i++) {
            // Test if there is a pass-all vertex
            auto pa_it = current_node->mChildrenNodes.find(0xFFFF);
            // Test if there is a matching vertex
            auto it = current_node->mChildrenNodes.find(x[i]);

            // If there is a matching node - take it
            if (it != current_node->mChildrenNodes.end()) {              
               current_node = it->second;
            }
            // Else if there is a pass-all node - take it
            else if (pa_it != current_node->mChildrenNodes.end()) { 
               current_node = pa_it->second;
            }
            // No Match
            else {
               found = false;
               break;
            }
         }
         if (found) {
            rval = current_node->mValue;
         }
      }
      return rval;
   }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, %r14
movq %rsi, %r15
leaq 0x29ac(%rip), %rsi      # 0x6401
leaq 0x7(%rsp), %rdx
movq %rdi, 0x8(%rsp)
callq 0x3572
movzbl (%r14), %eax
leaq 0x16(%rsp), %rsi
movw %ax, (%rsi)
movq %r15, %rdi
callq 0x3b6a
addq $0x8, %r15
cmpq %r15, %rax
je 0x3ae6
pushq $0x1
popq %r15
leaq 0x2(%rsp), %r12
movq 0x28(%rax), %r13
cmpq $0x10, %r15
je 0x3ad9
leaq 0x20(%r13), %rbx
orw $-0x1, 0x4(%rsp)
movq %rbx, %rdi
leaq 0x4(%rsp), %rsi
callq 0x3b6a
movq %rax, %rbp
movzbl (%r14,%r15), %eax
movw %ax, 0x2(%rsp)
movq %rbx, %rdi
movq %r12, %rsi
callq 0x3b6a
addq $0x28, %r13
cmpq %r13, %rax
jne 0x3ad4
cmpq %rax, %rbp
je 0x3ae6
movq %rbp, %rax
incq %r15
jmp 0x3a8a
movq 0x8(%rsp), %rdi
movq %r13, %rsi
callq 0x20e0
movq 0x8(%rsp), %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x3b00
jmp 0x3b00
jmp 0x3b00
movq %rax, %r14
movq 0x8(%rsp), %rdi
callq 0x22b8
movq %r14, %rdi
callq 0x2290
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/./mxf_base.hpp
// Function: mxf_file::decode_partition_pack(klv_item&)
int decode_partition_pack(klv_item &klv) {
      int rval = 0;
      switch (klv.mKey[13]) {
      case 0x02:
         decode_header_partition_pack(klv);
         break;
      case 0x03:
         decode_body_partition_pack(klv);
         break;
      case 0x04:
         decode_footer_partition_pack(klv);
         break;
      }
      return rval;
   }

// Assembly:
pushq %rax
movzbl 0xd(%rsi), %eax
cmpl $0x4, %eax
je 0x3b60
cmpl $0x3, %eax
je 0x3b59
cmpl $0x2, %eax
jne 0x3b65
callq 0x3bcc
jmp 0x3b65
callq 0x4044
jmp 0x3b65
callq 0x44e6
xorl %eax, %eax
popq %rcx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/mxf_base.cpp
// Function: mxf_file::init_UL_key_dictionary()
void mxf_file::init_UL_key_dictionary() {

   m_UL_key_dictionary.add( {0x0006, 0x000E, 0x002B, 0x0034, 
                             0x0001, 0x0001, 0x0001, 0xFFFF, 
                             0x0003, 0x0001, 0x0002, 0x0010, 
                             0x0001, 0x0000, 0x0000, 0x0000}, m_fill_item_name);

   m_UL_key_dictionary.add( {0x0006, 0x000E, 0x002B, 0x0034, 
                             0x0002, 0x0005, 0x0001, 0xFFFF, 
                             0x000D, 0x0001, 0x0002, 0x0001, 
                             0x0001, 0xFFFF, 0xFFFF, 0x0000}, m_partition_pack_name);

   m_UL_key_dictionary.add( {0x0006, 0x000E, 0x002B, 0x0034, 
                             0x0004, 0x0001, 0x0001, 0xFFFF, 
                             0x000D, 0x0001, 0x0002, 0x0001, 
                             0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF}, m_operational_pattern_name);

   m_UL_key_dictionary.add( {0x0006, 0x000E, 0x002B, 0x0034, 
                             0x0002, 0x0005, 0x0001, 0xFFFF, 
                             0x000D, 0x0001, 0x0002, 0x0001, 
                             0x0001, 0x0005, 0x0001, 0x0000}, m_primer_pack_name);   
}

// Assembly:
pushq %r14
pushq %rbx
subq $0xa8, %rsp
leaq 0x45df(%rip), %rsi      # 0x9208
leaq 0x88(%rsp), %rbx
movq %rbx, %rdi
callq 0x21f0
movups 0x1938(%rip), %xmm0     # 0x6578
movups %xmm0, 0x10(%rsp)
movups 0x191c(%rip), %xmm0     # 0x6568
movups %xmm0, (%rsp)
leaq 0x4631(%rip), %rdi      # 0x9288
movq %rbx, %rsi
callq 0x4db4
leaq 0x88(%rsp), %rdi
callq 0x22b8
leaq 0x45b5(%rip), %rsi      # 0x9228
leaq 0x68(%rsp), %rbx
movq %rbx, %rdi
callq 0x21f0
movups 0x1931(%rip), %xmm0     # 0x65b8
movups %xmm0, 0x10(%rsp)
movups 0x1915(%rip), %xmm0     # 0x65a8
movups %xmm0, (%rsp)
leaq 0x45ea(%rip), %rdi      # 0x9288
movq %rbx, %rsi
callq 0x4db4
leaq 0x68(%rsp), %rdi
callq 0x22b8
leaq 0x4591(%rip), %rsi      # 0x9248
leaq 0x48(%rsp), %rbx
movq %rbx, %rdi
callq 0x21f0
movups 0x18cd(%rip), %xmm0     # 0x6598
movups %xmm0, 0x10(%rsp)
movups 0x18b1(%rip), %xmm0     # 0x6588
movups %xmm0, (%rsp)
leaq 0x45a6(%rip), %rdi      # 0x9288
movq %rbx, %rsi
callq 0x4db4
leaq 0x48(%rsp), %rdi
callq 0x22b8
leaq 0x456d(%rip), %rsi      # 0x9268
leaq 0x28(%rsp), %rbx
movq %rbx, %rdi
callq 0x21f0
movups 0x18c9(%rip), %xmm0     # 0x65d8
movups %xmm0, 0x10(%rsp)
movups 0x18ad(%rip), %xmm0     # 0x65c8
movups %xmm0, (%rsp)
leaq 0x4562(%rip), %rdi      # 0x9288
movq %rbx, %rsi
callq 0x4db4
leaq 0x28(%rsp), %rdi
callq 0x22b8
addq $0xa8, %rsp
popq %rbx
popq %r14
retq
jmp 0x4d49
jmp 0x4d49
jmp 0x4d49
movq %rax, %r14
movq %rbx, %rdi
callq 0x22b8
movq %r14, %rdi
callq 0x2290
// File: /workspace/github_cpp_makefile_star2_O2/salleaffaire[P]MXFParser/./dictionary.hpp
// Function: Dictionary<16>::add(Signature<16>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void add(const Signature<T> x, std::string name) {
      DictionaryNode *current_node;

      // Adding the root
      auto it = mRootNodes.find(x[0]);
      if (it == mRootNodes.end()) {
         current_node = new DictionaryNode;
         mRootNodes[x[0]] = current_node;
         //std::cout << "Creating a new root node for " << x[0] << std::endl;
      }
      else {
         current_node = it->second;
         //std::cout << "Following root node for " << x[0] << std::endl; 
      }
      // Adding all other node
      for (int i=1;i<T;i++) {
         auto it = current_node->mChildrenNodes.find(x[i]);
         if (it == current_node->mChildrenNodes.end()) {
            DictionaryNode *new_node = new DictionaryNode;
            current_node->mChildrenNodes[x[i]] = new_node;
            current_node = new_node;
            //std::cout << "Creating a new node for " << x[i] << std::endl;
         }
         else {
            current_node = it->second;
            //std::cout << "Following node for " << x[i] << std::endl;
         }         
      }
      current_node->mValue = name;
   }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, 0x10(%rsp)
movq %rdi, %r15
movzwl 0x50(%rsp), %ebx
leaq 0xe(%rsp), %rsi
movw %bx, (%rsi)
callq 0x3b6a
leaq 0x8(%r15), %rcx
cmpq %rcx, %rax
je 0x4deb
movq 0x28(%rax), %r14
jmp 0x4e11
pushq $0x50
popq %rdi
callq 0x2190
movq %rax, %r14
movq %rax, %rdi
callq 0x4f56
leaq 0xc(%rsp), %rsi
movw %bx, (%rsi)
movq %r15, %rdi
callq 0x4f82
movq %r14, (%rax)
leaq 0x50(%rsp), %rbx
pushq $0x1
popq %r12
leaq 0xa(%rsp), %r15
leaq 0x8(%rsp), %r13
cmpq $0x10, %r12
je 0x4e82
leaq 0x20(%r14), %rbp
movzwl (%rbx,%r12,2), %eax
movw %ax, 0xa(%rsp)
movq %rbp, %rdi
movq %r15, %rsi
callq 0x3b6a
addq $0x28, %r14
cmpq %r14, %rax
je 0x4e52
movq 0x28(%rax), %r14
jmp 0x4e7d
pushq $0x50
popq %rdi
callq 0x2190
movq %rax, %r14
movq %rax, %rdi
callq 0x4f56
movzwl (%rbx,%r12,2), %eax
movw %ax, 0x8(%rsp)
movq %rbp, %rdi
movq %r13, %rsi
callq 0x4f82
movq %r14, (%rax)
incq %r12
jmp 0x4e24
movq %r14, %rdi
movq 0x10(%rsp), %rsi
callq 0x20e0
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/yhirose[P]fizzbuzzlang/fzbz.cc
// Function: parse(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::ostream&)
shared_ptr<Ast> parse(const string& source, ostream& out) {
  parser parser(R"(
    # Syntax Rules
    EXPRESSION              ← TERNARY
    TERNARY                 ← CONDITION ('?' EXPRESSION ':' EXPRESSION)?
    CONDITION               ← MULTIPLICATIVE (ConditionOperator MULTIPLICATIVE)?
    MULTIPLICATIVE          ← CALL (MultiplicativeOperator CALL)*
    CALL                    ← PRIMARY (EXPRESSION)?
    PRIMARY                 ← FOR / Identifier / '(' EXPRESSION ')' / String / Number
    FOR                     ← 'for' Identifier 'from' Number 'to' Number EXPRESSION

    # Token Rules
    ConditionOperator       ← '=='
    MultiplicativeOperator  ← '%'
    Identifier              ← !Keyword < [a-zA-Z][a-zA-Z0-9_]* >
    String                  ← "'" < ([^'] .)* > "'"
    Number                  ← < [0-9]+ >

    Keyword                 ← ('for' / 'from' / 'to') ![a-zA-Z]
    %whitespace             ← [ \t\r\n]*
  )");

  parser.enable_ast();

  parser.set_logger([&](size_t ln, size_t col, const auto& msg) {
    out << ln << ":" << col << ": " << msg << endl;
  });

  shared_ptr<Ast> ast;
  if (parser.parse_n(source.data(), source.size(), ast)) {
    return parser.optimize_ast(ast);
  }

  return nullptr;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xa0, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x2fc39(%rip), %rdx     # 0x39287
leaq -0xb8(%rbp), %r12
movl $0x372, %esi            # imm = 0x372
movq %r12, %rdi
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0xd028
movq %r12, %rdi
callq 0xd094
leaq -0x60(%rbp), %rsi
andq $0x0, 0x8(%rsi)
movq %r15, (%rsi)
leaq 0xba0(%rip), %rax       # 0xa222
movq %rax, 0x18(%rsi)
leaq 0xbed(%rip), %rax       # 0xa27a
movq %rax, 0x10(%rsi)
leaq -0xb8(%rbp), %rdi
callq 0xd0ca
leaq -0x60(%rbp), %rdi
callq 0x3209c
xorps %xmm0, %xmm0
leaq -0x30(%rbp), %rcx
movaps %xmm0, (%rcx)
movq (%r14), %rsi
movq 0x8(%r14), %rdx
leaq -0xb8(%rbp), %rdi
xorl %r8d, %r8d
callq 0xd11a
testb %al, %al
je 0x96fa
leaq -0x40(%rbp), %r14
leaq -0x30(%rbp), %rsi
movq %r14, %rdi
callq 0x30710
leaq -0xb8(%rbp), %rsi
pushq $0x1
popq %rcx
movq %rbx, %rdi
movq %r14, %rdx
callq 0xd1ec
leaq -0x38(%rbp), %rdi
callq 0x1106c
jmp 0x9700
xorps %xmm0, %xmm0
movups %xmm0, (%rbx)
leaq -0x28(%rbp), %rdi
callq 0x1106c
leaq -0xb8(%rbp), %rdi
callq 0xd2b0
movq %rbx, %rax
addq $0xa0, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x38(%rbp), %rdi
callq 0x1106c
jmp 0x9739
movq %rax, %rbx
leaq -0x28(%rbp), %rdi
callq 0x1106c
jmp 0x9755
movq %rax, %rbx
leaq -0x60(%rbp), %rdi
callq 0x3209c
jmp 0x9755
movq %rax, %rbx
leaq -0xb8(%rbp), %rdi
callq 0xd2b0
movq %rbx, %rdi
callq 0x9430
// File: /workspace/github_cpp_makefile_star2_O2/yhirose[P]fizzbuzzlang/fzbz.cc
// Function: eval_ternary(peg::AstBase<peg::EmptyType> const&, std::shared_ptr<Environment>)
Value eval_ternary(const Ast& ast, shared_ptr<Environment> env) {
  auto cond = eval(*ast.nodes[0], env).get<bool>();
  auto val1 = eval(*ast.nodes[1], env);
  auto val2 = eval(*ast.nodes[2], env);
  return cond ? val1 : val2;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq 0xc0(%rsi), %rax
movq (%rax), %r12
leaq -0x68(%rbp), %r13
movq %r13, %rdi
movq %rdx, %rsi
callq 0x30728
leaq -0x90(%rbp), %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x98e6
movq %rbx, -0x38(%rbp)
leaq -0x90(%rbp), %rdi
callq 0xd2de
movb %al, -0x29(%rbp)
leaq -0x90(%rbp), %rdi
callq 0x30740
leaq -0x60(%rbp), %rdi
callq 0x1106c
movq 0xc0(%r15), %rax
movq 0x10(%rax), %rbx
leaq -0x58(%rbp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x30728
leaq -0x90(%rbp), %r13
movq %r13, %rdi
movq %rbx, %rsi
movq %r12, %rdx
callq 0x98e6
leaq -0x50(%rbp), %rdi
callq 0x1106c
movq 0xc0(%r15), %rax
movq 0x20(%rax), %rbx
leaq -0x48(%rbp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x30728
leaq -0xb8(%rbp), %r14
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x98e6
leaq -0x40(%rbp), %rdi
callq 0x1106c
cmpb $0x0, -0x29(%rbp)
cmovneq %r13, %r14
movq -0x38(%rbp), %rbx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x307a4
leaq -0xb8(%rbp), %rdi
callq 0x30740
leaq -0x90(%rbp), %rdi
callq 0x30740
movq %rbx, %rax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0xb8(%rbp), %rdi
callq 0x30740
jmp 0x98aa
movq %rax, %rbx
leaq -0x40(%rbp), %rdi
callq 0x1106c
leaq -0x90(%rbp), %rdi
callq 0x30740
jmp 0x98de
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
jmp 0x98d9
movq %rax, %rbx
leaq -0x90(%rbp), %rdi
callq 0x30740
jmp 0x98d5
movq %rax, %rbx
leaq -0x60(%rbp), %rdi
callq 0x1106c
movq %rbx, %rdi
callq 0x9430
// File: /workspace/github_cpp_makefile_star2_O2/yhirose[P]fizzbuzzlang/fzbz.cc
// Function: eval(peg::AstBase<peg::EmptyType> const&, std::shared_ptr<Environment>)
Value eval(const Ast& ast, shared_ptr<Environment> env) {
  switch (ast.tag) {
    case "TERNARY"_:
      return eval_ternary(ast, env);
    case "CONDITION"_:
      return eval_condition(ast, env);
    case "MULTIPLICATIVE"_:
      return eval_multiplicative(ast, env);
    case "CALL"_:
      return eval_call(ast, env);
    case "FOR"_:
      return eval_for(ast, env);
    case "Identifier"_:
      return Value(env->get_value(ast.token));
    case "String"_:
      return Value(ast.token);
    case "Number"_:
      return Value(ast.token_to_number<long>());
    default:
      return Value();
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x50, %rsp
movq %rsi, %r15
movq %rdi, %rbx
movl 0xa0(%rsi), %eax
cmpl $0x63cc1e70, %eax       # imm = 0x63CC1E70
je 0x9a45
cmpl $0xbd90f163, %eax       # imm = 0xBD90F163
je 0x99f2
cmpl $0xc31de055, %eax       # imm = 0xC31DE055
je 0x9a34
cmpl $0x1323b, %eax          # imm = 0x1323B
je 0x9a0d
cmpl $0x25d362, %eax         # imm = 0x25D362
je 0x997b
cmpl $0xb538ed3, %eax        # imm = 0xB538ED3
je 0x99cb
cmpl $0x36a5c243, %eax       # imm = 0x36A5C243
je 0x99a5
cmpl $0xa93e7fa7, %eax       # imm = 0xA93E7FA7
jne 0x9a03
leaq -0x68(%rbp), %r14
leaq -0x70(%rbp), %r12
movq %r12, %rdi
movq %rdx, %rsi
callq 0x30728
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x9769
leaq -0x68(%rbp), %rdi
jmp 0x9a6a
leaq -0x38(%rbp), %r14
leaq -0x40(%rbp), %r12
movq %r12, %rdi
movq %rdx, %rsi
callq 0x30728
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x9ce2
leaq -0x38(%rbp), %rdi
jmp 0x9a6a
movq (%rdx), %rdi
movq 0xb0(%r15), %rsi
movq 0xb8(%r15), %rdx
callq 0xd46a
movq %rbx, %rdi
movq %rax, %rsi
callq 0x307a4
jmp 0x9a6f
leaq -0x58(%rbp), %r14
leaq -0x60(%rbp), %r12
movq %r12, %rdi
movq %rdx, %rsi
callq 0x30728
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x9a9a
leaq -0x58(%rbp), %rdi
jmp 0x9a6a
movq %r15, %rdi
callq 0xd68c
movq %rax, (%rbx)
movb $0x2, 0x20(%rbx)
jmp 0x9a6f
andq $0x0, (%rbx)
movb $0x0, 0x20(%rbx)
jmp 0x9a6f
leaq -0x28(%rbp), %r14
leaq -0x30(%rbp), %r12
movq %r12, %rdi
movq %rdx, %rsi
callq 0x30728
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x9db5
leaq -0x28(%rbp), %rdi
jmp 0x9a6a
movups 0xb0(%r15), %xmm0
movups %xmm0, (%rbx)
movb $0x3, 0x20(%rbx)
jmp 0x9a6f
leaq -0x48(%rbp), %r14
leaq -0x50(%rbp), %r12
movq %r12, %rdi
movq %rdx, %rsi
callq 0x30728
movq %rbx, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x9b93
leaq -0x48(%rbp), %rdi
callq 0x1106c
movq %rbx, %rax
addq $0x50, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0x9a87
jmp 0x9a87
jmp 0x9a87
jmp 0x9a87
movq %rax, %rbx
movq %r14, %rdi
callq 0x1106c
movq %rbx, %rdi
callq 0x9430
// File: /workspace/github_cpp_makefile_star2_O2/yhirose[P]fizzbuzzlang/fzbz.cc
// Function: eval_multiplicative(peg::AstBase<peg::EmptyType> const&, std::shared_ptr<Environment>)
Value eval_multiplicative(const Ast& ast, shared_ptr<Environment> env) {
  auto l = eval(*ast.nodes[0], env).get<long>();
  for (size_t i = 1; i < ast.nodes.size(); i += 2) {
    auto r = eval(*ast.nodes[i + 1], env).get<long>();
    l = l % r;
  }
  return Value(l);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rdi, %r12
movq %rsi, -0x40(%rbp)
movq 0xc0(%rsi), %rax
movq (%rax), %rbx
leaq -0x68(%rbp), %r14
movq %r14, %rdi
movq %rdx, -0x38(%rbp)
movq %rdx, %rsi
callq 0x30728
leaq -0x90(%rbp), %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x98e6
movq %r12, -0x30(%rbp)
leaq -0x90(%rbp), %rdi
callq 0xd3f0
movq %rax, %r12
leaq -0x90(%rbp), %rdi
callq 0x30740
leaq -0x60(%rbp), %rdi
callq 0x1106c
pushq $0x1
popq %r13
pushq $0x20
popq %rsi
movq -0x40(%rbp), %rcx
movq 0xc0(%rcx), %rax
movq 0xc8(%rcx), %rcx
subq %rax, %rcx
sarq $0x4, %rcx
cmpq %rcx, %r13
jae 0x9c89
movq %rsi, -0x48(%rbp)
movq (%rax,%rsi), %r14
leaq -0x58(%rbp), %rbx
movq %rbx, %rdi
movq -0x38(%rbp), %rsi
callq 0x30728
leaq -0x90(%rbp), %r15
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x98e6
movq %r15, %rdi
callq 0xd3f0
movq %rax, %r14
movq %r15, %rdi
callq 0x30740
leaq -0x50(%rbp), %rdi
callq 0x1106c
movq %r12, %rax
cqto
idivq %r14
addq $0x2, %r13
movq -0x48(%rbp), %rsi
addq $0x20, %rsi
movq %rdx, %r12
jmp 0x9c09
movq -0x30(%rbp), %rax
movq %r12, (%rax)
movb $0x2, 0x20(%rax)
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x90(%rbp), %rdi
callq 0x30740
jmp 0x9cb7
movq %rax, %rbx
leaq -0x60(%rbp), %rdi
jmp 0x9cd5
movq %rax, %rbx
leaq -0x90(%rbp), %rdi
callq 0x30740
jmp 0x9cd1
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x1106c
movq %rbx, %rdi
callq 0x9430
// File: /workspace/github_cpp_makefile_star2_O2/yhirose[P]fizzbuzzlang/fzbz.cc
// Function: eval_for(peg::AstBase<peg::EmptyType> const&, std::shared_ptr<Environment>)
Value eval_for(const Ast& ast, shared_ptr<Environment> env) {
  auto ident = ast.nodes[0]->token;
  auto from = eval(*ast.nodes[1], env).get<long>();
  auto to = eval(*ast.nodes[2], env).get<long>();
  auto& expr = *ast.nodes[3];

  for (auto i = from; i <= to; i++) {
    auto call_env = make_shared<Environment>(env);
    call_env->set_value(ident, Value(i));
    eval(expr, call_env);
  }
  return Value();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movq %rsi, %r12
movq %rdi, %r15
movq 0xc0(%rsi), %rax
movq (%rax), %rcx
movq 0xb0(%rcx), %rsi
movq %rsi, -0x78(%rbp)
movq 0xb8(%rcx), %rcx
movq %rcx, -0x70(%rbp)
movq 0x10(%rax), %rbx
leaq -0xc0(%rbp), %r14
movq %r14, %rdi
movq %rdx, -0x30(%rbp)
movq %rdx, %rsi
callq 0x30728
leaq -0x58(%rbp), %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x98e6
leaq -0x58(%rbp), %rdi
callq 0xd3f0
movq %rax, %r13
leaq -0x58(%rbp), %rdi
callq 0x30740
leaq -0xb8(%rbp), %rdi
callq 0x1106c
movq 0xc0(%r12), %rax
movq 0x20(%rax), %rbx
leaq -0xb0(%rbp), %r14
movq %r14, %rdi
movq -0x30(%rbp), %rsi
callq 0x30728
leaq -0x58(%rbp), %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x98e6
movq %r15, -0x60(%rbp)
leaq -0x58(%rbp), %rdi
callq 0xd3f0
movq %rax, -0x80(%rbp)
leaq -0x58(%rbp), %rdi
callq 0x30740
leaq -0xa8(%rbp), %rdi
callq 0x1106c
movq 0xc0(%r12), %rax
movq 0x30(%rax), %rax
movq %rax, -0x68(%rbp)
leaq -0x90(%rbp), %r14
leaq -0xa0(%rbp), %rbx
leaq -0xe8(%rbp), %r15
cmpq -0x80(%rbp), %r13
jg 0x9f2e
movq %r14, %rdi
movq -0x30(%rbp), %rsi
callq 0xd62a
movq -0x90(%rbp), %rdi
movq %r13, -0x58(%rbp)
movb $0x2, -0x38(%rbp)
movq -0x78(%rbp), %rsi
movq -0x70(%rbp), %rdx
leaq -0x58(%rbp), %r12
movq %r12, %rcx
callq 0xd64a
movq %r12, %rdi
callq 0x30740
movq %rbx, %rdi
movq %r14, %rsi
callq 0x30728
movq %r15, %rdi
movq -0x68(%rbp), %rsi
movq %rbx, %rdx
callq 0x98e6
movq %r15, %rdi
callq 0x30740
leaq -0x98(%rbp), %rdi
callq 0x1106c
leaq -0x88(%rbp), %rdi
callq 0x1106c
incq %r13
jmp 0x9eb2
movq -0x60(%rbp), %rax
andq $0x0, (%rax)
movb $0x0, 0x20(%rax)
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x58(%rbp), %rdi
callq 0x30740
jmp 0x9f5d
movq %rax, %rbx
leaq -0xa8(%rbp), %rdi
jmp 0x9fa4
movq %rax, %rbx
leaq -0x58(%rbp), %rdi
callq 0x30740
jmp 0x9f77
movq %rax, %rbx
leaq -0xb8(%rbp), %rdi
jmp 0x9fa4
movq %rax, %rbx
leaq -0x58(%rbp), %rdi
callq 0x30740
jmp 0x9f9d
movq %rax, %rbx
leaq -0x98(%rbp), %rdi
callq 0x1106c
leaq -0x88(%rbp), %rdi
callq 0x1106c
movq %rbx, %rdi
callq 0x9430
// File: /workspace/github_cpp_makefile_star2_O2/yhirose[P]fizzbuzzlang/fzbz.cc
// Function: interpret(peg::AstBase<peg::EmptyType> const&)
Value interpret(const Ast& ast) {
  auto env = make_shared<Environment>();

  env->set_value("puts", Value(Function([](auto& val) {
                   cout << val.str() << endl;
                   return Value();
                 })));

  return eval(ast, env);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x70, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq -0x30(%rbp), %r15
movq %r15, %rdi
callq 0xd6a7
movq (%r15), %r15
xorps %xmm0, %xmm0
leaq -0x60(%rbp), %rsi
movaps %xmm0, (%rsi)
leaq 0x2be(%rip), %rax       # 0xa2a4
movq %rax, 0x18(%rsi)
leaq 0x319(%rip), %rax       # 0xa30a
movq %rax, 0x10(%rsi)
leaq -0x88(%rbp), %r12
movq %r12, %rdi
callq 0x31452
leaq 0x2f5ef(%rip), %rdx     # 0x395fa
pushq $0x4
popq %rsi
movq %r15, %rdi
movq %r12, %rcx
callq 0xd64a
leaq -0x88(%rbp), %rdi
callq 0x30740
leaq -0x60(%rbp), %rdi
callq 0x3209c
leaq -0x40(%rbp), %r15
leaq -0x30(%rbp), %rsi
movq %r15, %rdi
callq 0x30728
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x98e6
leaq -0x38(%rbp), %rdi
callq 0x1106c
leaq -0x28(%rbp), %rdi
callq 0x1106c
movq %rbx, %rax
addq $0x70, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x38(%rbp), %rdi
callq 0x1106c
jmp 0xa094
movq %rax, %rbx
leaq -0x88(%rbp), %rdi
callq 0x30740
leaq -0x60(%rbp), %rdi
callq 0x3209c
leaq -0x28(%rbp), %rdi
callq 0x1106c
movq %rbx, %rdi
callq 0x9430
// File: /workspace/github_cpp_makefile_star2_O2/yhirose[P]fizzbuzzlang/fzbz.cc
// Function: main
int main(int argc, const char** argv) {
  if (argc < 2) {
    cerr << "usage: fzbz [source file path]" << endl;
    return 1;
  }

  ifstream file{argv[1]};
  if (!file) {
    cerr << "can't open the source file." << endl;
    return 2;
  }

  auto source =
      string(istreambuf_iterator<char>(file), istreambuf_iterator<char>());

  auto ast = parse(source, cerr);
  if (!ast) {
    return 3;
  }

  try {
    interpret(*ast);
  } catch (const exception& e) {
    cerr << e.what() << endl;
    return 4;
  }

  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x268, %rsp            # imm = 0x268
cmpl $0x1, %edi
jg 0xa0d9
movq 0x52f23(%rip), %rdi     # 0x5cfe0
leaq 0x2f53b(%rip), %rsi     # 0x395ff
callq 0x92a0
movq %rax, %rdi
callq 0x9150
pushq $0x1
popq %rbx
jmp 0xa195
movq 0x8(%rsi), %rsi
leaq -0x268(%rbp), %rbx
pushq $0x8
popq %rdx
movq %rbx, %rdi
callq 0x9460
movq (%rbx), %rax
movq -0x18(%rax), %rax
testb $0x5, -0x248(%rbp,%rax)
je 0xa120
movq 0x52ed9(%rip), %rdi     # 0x5cfe0
leaq 0x2f510(%rip), %rsi     # 0x3961e
callq 0x92a0
movq %rax, %rdi
callq 0x9150
pushq $0x2
popq %rbx
jmp 0xa189
movq -0x180(%rbp,%rax), %rsi
leaq -0x28(%rbp), %rax
movq %rax, -0x10(%rax)
leaq -0x38(%rbp), %rdi
pushq $-0x1
popq %rdx
xorl %ecx, %ecx
movl %edx, %r8d
callq 0x38584
movq 0x52e98(%rip), %rdx     # 0x5cfe0
leaq -0x18(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x962c
movq -0x18(%rbp), %rsi
testq %rsi, %rsi
je 0xa174
leaq -0x60(%rbp), %rdi
callq 0x9fb1
leaq -0x60(%rbp), %rdi
callq 0x30740
xorl %ebx, %ebx
jmp 0xa177
pushq $0x3
popq %rbx
leaq -0x10(%rbp), %rdi
callq 0x1106c
leaq -0x38(%rbp), %rdi
callq 0x9140
leaq -0x268(%rbp), %rdi
callq 0x90a0
movl %ebx, %eax
addq $0x268, %rsp            # imm = 0x268
popq %rbx
popq %rbp
retq
movq %rax, %rbx
cmpl $0x1, %edx
jne 0xa1e7
movq %rbx, %rdi
callq 0x9110
movq (%rax), %rcx
movq %rax, %rdi
callq *0x10(%rcx)
movq 0x52e1f(%rip), %rdi     # 0x5cfe0
movq %rax, %rsi
callq 0x92a0
movq %rax, %rdi
callq 0x9150
callq 0x9410
pushq $0x4
jmp 0xa176
movq %rax, %rbx
jmp 0xa1e7
movq %rax, %rbx
callq 0x9410
leaq -0x10(%rbp), %rdi
callq 0x1106c
jmp 0xa1fd
movq %rax, %rdi
callq 0xd6c3
movq %rax, %rbx
leaq -0x38(%rbp), %rdi
callq 0x9140
jmp 0xa20d
jmp 0xa20a
movq %rax, %rbx
leaq -0x268(%rbp), %rdi
callq 0x90a0
movq %rbx, %rdi
callq 0x9430
nop