LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/map.cc
// Function: File::File(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
File::File(const std::string &filename) {
  data = p = nullptr;
  std::ifstream f(filename, std::ios::in | std::ios::binary | std::ios::ate);
  if (!f.is_open()) {
    return;
  }
  auto length = f.tellg();
  data = new uint8_t[length];
  f.seekg(0, std::ios::beg);
  f.read(reinterpret_cast<char*>(data), length);
  f.close();
  p = data;
  end = data + length;
  curLine = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x210, %rsp            # imm = 0x210
movq %rdi, %rbx
leaq 0x30(%rdi), %r15
movq %r15, 0x20(%rdi)
movq $0x0, 0x28(%rdi)
movb $0x0, 0x30(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
leaq 0x8(%rsp), %rdi
movl $0xe, %edx
callq 0x5390
leaq 0x80(%rsp), %rdi
callq 0x50b0
testb %al, %al
je 0xa714
leaq 0x8(%rsp), %rdi
callq 0x53d0
movq %rax, %r14
movq %rax, %rdi
callq 0x5030
movq %rax, (%rbx)
leaq 0x8(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x52d0
movq (%rbx), %rsi
leaq 0x8(%rsp), %rdi
movq %r14, %rdx
callq 0x5290
leaq 0x8(%rsp), %rdi
callq 0x50a0
movq (%rbx), %rax
movq %rax, 0x8(%rbx)
addq %rax, %r14
movq %r14, 0x10(%rbx)
movl $0x1, 0x18(%rbx)
leaq 0x8(%rsp), %rdi
callq 0x50e0
addq $0x210, %rsp            # imm = 0x210
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
jmp 0xa73d
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x50e0
movq 0x20(%rbx), %rdi
cmpq %r15, %rdi
je 0xa751
movq (%r15), %rsi
incq %rsi
callq 0x5230
movq %r14, %rdi
callq 0x53e0
nop
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/map.cc
// Function: File::ws()
void File::ws() {
  while (p < end && isspace(*p)) {
    if (*p == '\n') {
      curLine++;
    }
    p++;
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq 0x8(%rdi), %r14
movq 0x10(%rdi), %r15
cmpq %r15, %r14
jae 0xa79c
movq %rdi, %rbx
movl 0x18(%rdi), %ebp
movb (%r14), %r12b
movzbl %r12b, %edi
callq 0x5070
testl %eax, %eax
je 0xa79c
cmpb $0xa, %r12b
jne 0xa790
incl %ebp
movl %ebp, 0x18(%rbx)
incq %r14
movq %r14, 0x8(%rbx)
cmpq %r15, %r14
jne 0xa775
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/disasm.cc
// Function: Disassembler::hex[abi:cxx11](unsigned int, int)
std::string Disassembler::hex(uint32_t val, int width) {
  static const char *digits = "0123456789abcdef";
  std::string ret;
  if (width == 6) {
    ret = symbols[val];
    if (!ret.empty()) {
      return ret;
    }
    ret = "$00/0000";
    for (size_t i = 0, j = 5 << 2; i < 6; i++, j -= 4) {
      ret[i < 2 ? i + 1 : i + 2] = digits[(val >> j) & 0xf];
    }
    return ret;
  }
  ret = "$";
  std::string h(width, '0');
  for (int i = 0, j = (width - 1) << 2; i < width; i++, j -= 4) {
    h[i] = digits[(val >> j) & 0xf];
  }
  return ret + h;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x50, %rsp
movq %rdi, %rbx
movl %edx, 0xc(%rsp)
leaq 0x20(%rsp), %r15
movq %r15, -0x10(%r15)
movq $0x0, -0x8(%r15)
movb $0x0, (%r15)
cmpl $0x6, %ecx
jne 0xd72e
leaq 0xc(%rsp), %rax
movq %rsi, %rdi
movq %rax, %rsi
callq 0xa7a6
leaq 0x10(%rsp), %rdi
movq %rax, %rsi
callq 0x5170
movq 0x18(%rsp), %rax
testq %rax, %rax
je 0xd7eb
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
movq 0x10(%rsp), %rdx
cmpq %r15, %rdx
je 0xd865
movq %rdx, (%rbx)
movq 0x20(%rsp), %rcx
movq %rcx, 0x10(%rbx)
jmp 0xd87a
movl %ecx, %r14d
movl %edx, %ebp
leaq 0xa4eb(%rip), %rcx      # 0x17c25
leaq 0x10(%rsp), %rdi
movl $0x1, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x5360
movslq %r14d, %rsi
leaq 0x40(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x30(%rsp), %rdi
movl $0x30, %edx
callq 0x5270
testl %r14d, %r14d
jle 0xd7a2
movl %r14d, %eax
leal -0x4(,%r14,4), %ecx
xorl %edx, %edx
leaq 0x9bae(%rip), %rsi      # 0x17331
movl %ebp, %edi
shrl %cl, %edi
andl $0xf, %edi
movb (%rdi,%rsi), %dil
movq 0x30(%rsp), %r8
movb %dil, (%r8,%rdx)
incq %rdx
addl $-0x4, %ecx
cmpq %rdx, %rax
jne 0xd783
leaq 0x10(%rsp), %rsi
leaq 0x30(%rsp), %rdx
movq %rbx, %rdi
callq 0xf03b
movq 0x30(%rsp), %rdi
cmpq %r12, %rdi
je 0xd7cb
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x5230
movq 0x10(%rsp), %rdi
cmpq %r15, %rdi
je 0xd87e
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x5230
jmp 0xd87e
leaq 0x9b50(%rip), %rcx      # 0x17342
leaq 0x10(%rsp), %rdi
movl $0x8, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x5360
movl $0x14, %ecx
xorl %edx, %edx
leaq 0x9b1d(%rip), %rax      # 0x17331
movl 0xc(%rsp), %esi
shrl %cl, %esi
andl $0xf, %esi
movb (%rsi,%rax), %sil
leaq 0x2(%rdx), %rdi
cmpq $0x2, %rdx
leaq 0x1(%rdx), %r8
cmovbq %r8, %rdi
movq 0x10(%rsp), %rdx
movb %sil, (%rdx,%rdi)
addl $-0x4, %ecx
movq %r8, %rdx
cmpq $0x6, %r8
jne 0xd814
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
movq 0x10(%rsp), %rcx
cmpq %r15, %rcx
je 0xd86e
movq %rcx, (%rbx)
movq 0x20(%rsp), %rax
movq %rax, 0x10(%rbx)
jmp 0xd875
movups (%r15), %xmm0
movups %xmm0, (%rcx)
jmp 0xd87a
movups (%r15), %xmm0
movups %xmm0, (%rax)
movq 0x18(%rsp), %rax
movq %rax, 0x8(%rbx)
movq %rbx, %rax
addq $0x50, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x30(%rsp), %rdi
cmpq %r12, %rdi
je 0xd8af
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x5230
jmp 0xd8af
jmp 0xd8ac
movq %rax, %rbx
movq 0x10(%rsp), %rdi
cmpq %r15, %rdi
je 0xd8c6
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x5230
movq %rbx, %rdi
callq 0x53e0
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/disasm.cc
// Function: Disassembler::checkDW[abi:cxx11](unsigned short, unsigned short)
std::string Disassembler::checkDW(uint16_t cur, uint16_t prev) {
  uint32_t addr = (cur << 16) + prev;
  std::string ret = symbols[addr];
  if (ret.empty()) {
    addr = (prev << 16) + cur;
    ret = symbols[addr];
  }
  return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
shll $0x10, %ebp
orl %ecx, %ebp
leaq 0x4(%rsp), %rsi
movl %ebp, (%rsi)
movq %r14, %rdi
callq 0xa7a6
leaq 0x10(%rbx), %r15
movq %r15, (%rbx)
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x688a
cmpq $0x0, 0x8(%rbx)
jne 0xee84
roll $0x10, %ebp
leaq 0x4(%rsp), %rsi
movl %ebp, (%rsi)
movq %r14, %rdi
callq 0xa7a6
movq %rbx, %rdi
movq %rax, %rsi
callq 0x5170
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq (%rbx), %rdi
cmpq %r15, %rdi
je 0xeea8
movq (%r15), %rsi
incq %rsi
callq 0x5230
movq %r14, %rdi
callq 0x53e0
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/api.cc
// Function: Fingerprints::add(std::vector<unsigned char, std::allocator<unsigned char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, unsigned char)
void Fingerprints::add(const std::vector<uint8_t> &keys, std::string name,
                       uint8_t numDB) {
  auto node = root;
  for (auto key : keys) {
    if (node->map.find(key) == node->map.end()) {
      node->map.insert(std::pair<uint8_t, std::shared_ptr<Fingerprint>>
                       (key, std::make_shared<Fingerprint>()));
    }
    node = node->map[key];
  }
  node->name = name;
  node->numDB = numDB;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %ecx, 0x24(%rsp)
movq %rdx, 0x28(%rsp)
movq (%rdi), %rax
movq %rax, 0x10(%rsp)
movq 0x8(%rdi), %rax
movq %rax, 0x18(%rsp)
testq %rax, %rax
je 0xf7e0
movq 0x117f6(%rip), %rcx     # 0x20fc8
cmpb $0x0, (%rcx)
je 0xf7dc
incl 0x8(%rax)
jmp 0xf7e0
lock
incl 0x8(%rax)
movq (%rsi), %rbx
movq 0x8(%rsi), %r14
cmpq %r14, %rbx
je 0xf8fa
leaq 0x18(%rsp), %r15
leaq 0x30(%rsp), %r12
leaq 0xf(%rsp), %r13
movb (%rbx), %al
movb %al, 0xf(%rsp)
movq 0x10(%rsp), %rbp
movq 0x10(%rbp), %rcx
testq %rcx, %rcx
je 0xf83f
leaq 0x8(%rbp), %rsi
movq %rsi, %rdx
xorl %edi, %edi
cmpb %al, 0x20(%rcx)
setb %dil
cmovaeq %rcx, %rdx
movq 0x10(%rcx,%rdi,8), %rcx
testq %rcx, %rcx
jne 0xf81a
cmpq %rsi, %rdx
je 0xf83f
cmpb 0x20(%rdx), %al
jae 0xf8cc
movl $0x68, %edi
callq 0x5220
movabsq $0x100000001, %rcx      # imm = 0x100000001
movq %rcx, 0x8(%rax)
leaq 0x11322(%rip), %rcx     # 0x20b80
movq %rcx, (%rax)
leaq 0x10(%rax), %rcx
leaq 0x18(%rax), %rdx
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rax)
movups %xmm0, 0x30(%rax)
movups %xmm0, 0x40(%rax)
movups %xmm0, 0x10(%rax)
movups %xmm0, 0x50(%rax)
movq $0x0, 0x60(%rax)
movq %rdx, 0x28(%rax)
movq %rdx, 0x30(%rax)
movq %rax, %rdx
addq $0x58, %rdx
movq %rdx, 0x48(%rax)
movb 0xf(%rsp), %dl
movb %dl, 0x30(%rsp)
movq %rcx, 0x38(%rsp)
movq %rax, 0x40(%rsp)
movq %rbp, %rdi
movq %r12, %rsi
callq 0x12000
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0xf8c7
callq 0x671a
movq 0x10(%rsp), %rbp
movq %rbp, %rdi
movq %r13, %rsi
callq 0x11d54
movq (%rax), %rcx
movq %rcx, 0x10(%rsp)
addq $0x8, %rax
movq %r15, %rdi
movq %rax, %rsi
callq 0x7dd0
incq %rbx
cmpq %r14, %rbx
jne 0xf7ff
movq 0x10(%rsp), %rdi
addq $0x38, %rdi
movq 0x28(%rsp), %rsi
callq 0x5170
movq 0x10(%rsp), %rax
movl 0x24(%rsp), %ecx
movb %cl, 0x30(%rax)
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0xf928
callq 0x671a
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0xf94f
movq %rax, %rbx
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0xf952
callq 0x671a
jmp 0xf952
jmp 0xf94f
movq %rax, %rbx
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0xf961
callq 0x671a
movq %rbx, %rdi
callq 0x53e0
nop
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/api.cc
// Function: API::setEnum(std::shared_ptr<TheHandle>, std::shared_ptr<symbol::Symbol>)
void API::setEnum(Handle h, std::shared_ptr<symbol::Symbol> s) {
  auto e = std::static_pointer_cast<symbol::Enum>(s);
  e->type = lookup(h->r32());
  auto num = h->r32();
  for (uint32_t i = 0; i < num; i++) {
    auto value = h->r32();
    e->entries[h->rs()] = value;
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rsi, %r14
movq %rdi, %r12
movq (%rdx), %r15
movq 0x8(%rdx), %rbx
testq %rbx, %rbx
je 0x104af
movq 0x10b27(%rip), %rax     # 0x20fc8
cmpb $0x0, (%rax)
je 0x104ab
incl 0x8(%rbx)
jmp 0x104af
lock
incl 0x8(%rbx)
movq (%r14), %rdi
movq %rbx, 0x8(%rsp)
callq 0x96e8
leaq 0x10(%rsp), %rdi
movq %r12, %rsi
movl %eax, %edx
callq 0x11046
movq 0x30(%r15), %rdi
movaps 0x10(%rsp), %xmm0
movups %xmm0, 0x28(%r15)
testq %rdi, %rdi
je 0x104e3
callq 0x671a
movq (%r14), %rdi
callq 0x96e8
movl %eax, %ebp
testl %eax, %eax
je 0x1053e
addq $0x38, %r15
leaq 0x20(%rsp), %rbx
leaq 0x10(%rsp), %r12
movq (%r14), %rdi
callq 0x96e8
movl %eax, %r13d
movq (%r14), %rsi
movq %r12, %rdi
callq 0x9790
movq %r15, %rdi
movq %r12, %rsi
callq 0x11e36
movl %r13d, (%rax)
movq 0x10(%rsp), %rdi
cmpq %rbx, %rdi
je 0x1053a
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x5230
decl %ebp
jne 0x104ff
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x1054d
callq 0x671a
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x10562
jmp 0x10562
jmp 0x10562
movq %rax, %r14
cmpq $0x0, 0x8(%rsp)
je 0x10577
movq 0x8(%rsp), %rdi
callq 0x671a
movq %r14, %rdi
callq 0x53e0
movq %rax, %r14
movq 0x10(%rsp), %rdi
cmpq %rbx, %rdi
je 0x10565
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x5230
jmp 0x10565
nop
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/api.cc
// Function: API::setRef(std::shared_ptr<TheHandle>, std::shared_ptr<symbol::Symbol>)
void API::setRef(Handle h, std::shared_ptr<symbol::Symbol> s) {
  auto r = std::static_pointer_cast<symbol::Ref>(s);
  auto id = h->r32();
  if (id == 0) {
    r->symbol = nullptr;
  } else {
    r->symbol = lookup(id);
    r->pointer = h->r32();
    r->array = static_cast<int32_t>(h->r32());
    r->reg = h->rs();
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r15
movq %rdi, %r12
movq (%rdx), %r14
movq 0x8(%rdx), %rbx
testq %rbx, %rbx
je 0x105ce
movq 0x10a08(%rip), %rax     # 0x20fc8
cmpb $0x0, (%rax)
je 0x105ca
incl 0x8(%rbx)
jmp 0x105ce
lock
incl 0x8(%rbx)
movq (%r15), %rdi
callq 0x96e8
testl %eax, %eax
je 0x1064f
movq %rsp, %rdi
movq %r12, %rsi
movl %eax, %edx
callq 0x11046
movq 0x30(%r14), %rdi
movaps (%rsp), %xmm0
movups %xmm0, 0x28(%r14)
testq %rdi, %rdi
je 0x105fe
callq 0x671a
movq (%r15), %rdi
callq 0x96e8
movl %eax, 0x38(%r14)
movq (%r15), %rdi
callq 0x96e8
movl %eax, 0x3c(%r14)
movq (%r15), %rsi
movq %rsp, %rdi
callq 0x9790
addq $0x40, %r14
movq %rsp, %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x5280
movq (%r15), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x10665
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x5230
jmp 0x10665
xorps %xmm0, %xmm0
movq 0x30(%r14), %rdi
movups %xmm0, 0x28(%r14)
testq %rdi, %rdi
je 0x10665
callq 0x671a
testq %rbx, %rbx
je 0x10672
movq %rbx, %rdi
callq 0x671a
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
jmp 0x10682
jmp 0x10682
movq %rax, %r14
testq %rbx, %rbx
je 0x10692
movq %rbx, %rdi
callq 0x671a
movq %r14, %rdi
callq 0x53e0
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/api.cc
// Function: API::search(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, unsigned int)
void API::search(std::string keyword, uint32_t org) {
  for (auto &s : symbols) {
    auto it = std::search(s.first.begin(), s.first.end(),
                          keyword.begin(), keyword.end(),
                          [](char a, char b) {
                            return std::toupper(a) == std::toupper(b);
                          });
    if (it != s.first.end()) {
      dumpSymbol(s.second, org);
      printf("\n");
    }
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %edx, 0x4(%rsp)
movq 0x18(%rdi), %r12
movq %rdi, 0x28(%rsp)
leaq 0x8(%rdi), %rax
movq %rax, 0x38(%rsp)
cmpq %rax, %r12
je 0x1122a
movq %rsi, 0x30(%rsp)
movq 0x20(%r12), %r13
movq 0x28(%r12), %rax
leaq (%rax,%r13), %rbp
movq 0x8(%rsi), %rbx
testq %rax, %rax
sete %al
testq %rbx, %rbx
sete %cl
orb %al, %cl
jne 0x1110e
movq (%rsi), %rdx
movq %r13, %rdi
movq %rbp, %rsi
movq %rdx, 0x8(%rsp)
callq 0x11c31
movq %rax, %r13
cmpq $0x1, %rbx
jne 0x1114c
cmpq %rbp, %r13
je 0x1120f
movq 0x40(%r12), %rax
movq %rax, 0x10(%rsp)
movq 0x48(%r12), %rax
movq %rax, 0x18(%rsp)
testq %rax, %rax
je 0x111e1
movq 0xfe8d(%rip), %rcx      # 0x20fc8
cmpb $0x0, (%rcx)
je 0x111dd
incl 0x8(%rax)
jmp 0x111e1
cmpq %rbp, %r13
je 0x1120f
movl $0x2, %eax
subq %rbx, %rax
movq %rax, 0x40(%rsp)
leaq 0x1(%r13), %rax
movq %rax, 0x20(%rsp)
cmpq %rbp, %rax
je 0x1120f
movl $0x1, %ebx
movsbl (%r13,%rbx), %edi
movq 0x8(%rsp), %rax
movsbl (%rax,%rbx), %r14d
callq 0x5420
movl %eax, %r15d
movl %r14d, %edi
callq 0x5420
cmpl %eax, %r15d
jne 0x111c1
movq 0x40(%rsp), %rax
addq %rbx, %rax
cmpq $0x1, %rax
je 0x1110e
leaq (%rbx,%r13), %rax
incq %rax
incq %rbx
cmpq %rbp, %rax
jne 0x11179
jmp 0x1120f
movq 0x20(%rsp), %rdi
movq %rbp, %rsi
movq 0x8(%rsp), %rdx
callq 0x11c31
movq %rax, %r13
cmpq %rbp, %rax
jne 0x11162
jmp 0x1120f
lock
incl 0x8(%rax)
movq 0x28(%rsp), %rdi
leaq 0x10(%rsp), %rsi
movl 0x4(%rsp), %edx
xorl %ecx, %ecx
callq 0x11254
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x11205
callq 0x671a
movl $0xa, %edi
callq 0x52e0
movq %r12, %rdi
callq 0x51a0
movq %rax, %r12
cmpq 0x38(%rsp), %rax
movq 0x30(%rsp), %rsi
jne 0x110d0
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x1124b
callq 0x671a
movq %rbx, %rdi
callq 0x53e0
nop
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/api.cc
// Function: API::dumpRef(std::shared_ptr<symbol::Ref>)
void API::dumpRef(std::shared_ptr<symbol::Ref> ref) {
  for (int i = 0; i < ref->pointer; i++) {
    printf("^");
  }
  printf("%s", ref->symbol->name.c_str());
  if (ref->array > 0) {
    printf("[%d]", ref->array);
  } else if (ref->array == 0) {
    printf("[]");
  }
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq (%rsi), %rax
cmpl $0x0, 0x38(%rax)
je 0x11be1
xorl %ebp, %ebp
movl $0x5e, %edi
callq 0x52e0
incl %ebp
movq (%rbx), %rax
cmpl 0x38(%rax), %ebp
jb 0x11bcd
movq 0x28(%rax), %rax
movq (%rax), %rsi
leaq 0x5fdb(%rip), %rdi      # 0x17bca
xorl %eax, %eax
callq 0x5060
movq (%rbx), %rax
movl 0x3c(%rax), %esi
testl %esi, %esi
jle 0x11c14
leaq 0x5fc6(%rip), %rdi      # 0x17bcd
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x5060
je 0x11c1d
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x5fae(%rip), %rdi      # 0x17bd2
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x5060
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/scanner.cc
// Function: Scanner::getAddress(unsigned int)
Handle Scanner::getAddress(uint32_t address) {
  for (auto &s : segments) {
    if (address >= s.mapped && address < s.mapped + s.length) {
      s.data->seek(address - s.mapped);
      return s.data;
    }
  }
  return nullptr;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x30(%rsi), %r14
movq 0x38(%rsi), %rax
cmpq %rax, %r14
je 0x13dac
movl 0x60(%r14), %ecx
movl %edx, %esi
subl %ecx, %esi
jb 0x13da6
addl 0x8(%r14), %ecx
cmpl %edx, %ecx
ja 0x13dbd
addq $0x68, %r14
jmp 0x13d8f
xorps %xmm0, %xmm0
movups %xmm0, (%rbx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq 0x50(%r14), %rdi
callq 0x98ae
movq 0x50(%r14), %rax
movq %rax, (%rbx)
movq 0x58(%r14), %rax
movq %rax, 0x8(%rbx)
testq %rax, %rax
je 0x13db2
movq 0xd1e7(%rip), %rcx      # 0x20fc8
cmpb $0x0, (%rcx)
je 0x13deb
incl 0x8(%rax)
jmp 0x13db2
lock
incl 0x8(%rax)
jmp 0x13db2
nop
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/scanner.cc
// Function: Scanner::hex[abi:cxx11](unsigned int, unsigned long)
std::string Scanner::hex(uint32_t value, size_t len) {
  static const char *digits = "0123456789abcdef";
  if (len == 6) {
    std::string ret="00/0000";
    for (size_t i = 0, j = 5 << 2; i < 6; i++, j -= 4) {
      ret[i < 2 ? i : i + 1] = digits[(value >> j) & 0xf];
    }
    return ret;
  }
  std::string ret(len, '0');
  for (size_t i = 0, j = (len - 1) << 2; i < len; i++, j -= 4) {
    ret[i] = digits[(value >> j) & 0xf];
  }
  return ret;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebp
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
cmpq $0x6, %rcx
jne 0x13e58
leaq 0x3534(%rip), %rsi      # 0x17343
leaq 0x3534(%rip), %rdx      # 0x1734a
movq %rbx, %rdi
callq 0x6920
movl $0x14, %ecx
xorl %edx, %edx
leaq 0x3505(%rip), %rax      # 0x17331
movl %ebp, %esi
shrl %cl, %esi
andl $0xf, %esi
movb (%rsi,%rax), %sil
leaq 0x1(%rdx), %rdi
cmpq $0x2, %rdx
cmovaeq %rdi, %rdx
movq (%rbx), %r8
movb %sil, (%r8,%rdx)
addl $-0x4, %ecx
movq %rdi, %rdx
cmpq $0x6, %rdi
jne 0x13e2c
jmp 0x13e9e
movq %rcx, %r14
movq %rbx, %rdi
movq %rcx, %rsi
movl $0x30, %edx
callq 0x5270
testq %r14, %r14
je 0x13e9e
leal -0x4(,%r14,4), %ecx
xorl %eax, %eax
leaq 0x34b0(%rip), %rdx      # 0x17331
movl %ebp, %esi
shrl %cl, %esi
andl $0xf, %esi
movb (%rsi,%rdx), %sil
movq (%rbx), %rdi
movb %sil, (%rdi,%rax)
incq %rax
addl $-0x4, %ecx
cmpq %rax, %r14
jne 0x13e81
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/mrkite[P]regs/src/scanner.cc
// Function: Scanner::getBlock(unsigned int)
std::shared_ptr<Block> Scanner::getBlock(uint32_t address) {
  auto res = std::find_if(blocks.begin(), blocks.end(),
                          [address](const std::shared_ptr<Block> n) {
                            return n->address == address;
                          });
  if (res != blocks.end()) {
    return *res;
  }
  auto block = std::make_shared<Block>(address);
  block->branchLen = 0;
  block->length = 0;
  blocks.push_back(block);
  return block;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r14
movq %rdi, 0x10(%rsp)
movq 0xb8(%rsi), %r15
movq 0xc0(%rsi), %rbx
movl %edx, 0x1c(%rsp)
movl %edx, 0xc(%rsp)
movq %rbx, 0x20(%rsp)
subq %r15, %rbx
movq %rbx, %rbp
sarq $0x6, %rbp
testq %rbp, %rbp
jle 0x143b5
incq %rbp
leaq 0xc(%rsp), %r12
movq %r12, %rdi
movq %r15, %rsi
callq 0x15006
testb %al, %al
jne 0x143e7
leaq 0x10(%r15), %r13
movq %r12, %rdi
movq %r13, %rsi
callq 0x15006
testb %al, %al
jne 0x14413
leaq 0x20(%r15), %r13
movq %r12, %rdi
movq %r13, %rsi
callq 0x15006
testb %al, %al
jne 0x14413
leaq 0x30(%r15), %r13
movq %r12, %rdi
movq %r13, %rsi
callq 0x15006
testb %al, %al
jne 0x14413
addq $0x40, %r15
decq %rbp
addq $-0x40, %rbx
cmpq $0x1, %rbp
jg 0x14350
sarq $0x4, %rbx
cmpq $0x1, %rbx
je 0x14407
cmpq $0x2, %rbx
je 0x143ec
cmpq $0x3, %rbx
jne 0x1440e
leaq 0xc(%rsp), %rdi
movq %r15, %rsi
callq 0x15006
testb %al, %al
movq 0x10(%rsp), %rbx
jne 0x14402
addq $0x10, %r15
jmp 0x143f1
movq %r15, %r13
jmp 0x14413
movq 0x10(%rsp), %rbx
leaq 0xc(%rsp), %rdi
movq %r15, %rsi
callq 0x15006
testb %al, %al
je 0x1441a
movq %r15, %r13
jmp 0x14436
movq 0x10(%rsp), %rbx
jmp 0x1441e
movq 0x20(%rsp), %r13
movq 0x10(%rsp), %rbx
jmp 0x14436
addq $0x10, %r15
leaq 0xc(%rsp), %rdi
movq %r15, %rsi
callq 0x15006
testb %al, %al
movq 0x20(%rsp), %r13
cmovneq %r15, %r13
cmpq 0xc0(%r14), %r13
je 0x14464
movq (%r13), %rax
movq %rax, (%rbx)
movq 0x8(%r13), %rax
movq %rax, 0x8(%rbx)
testq %rax, %rax
je 0x144c7
movq 0xcb6e(%rip), %rcx      # 0x20fc8
cmpb $0x0, (%rcx)
je 0x144c3
incl 0x8(%rax)
jmp 0x144c7
addq $0xb8, %r14
movl $0x50, %edi
callq 0x5220
movabsq $0x100000001, %rcx      # imm = 0x100000001
movq %rcx, 0x8(%rax)
leaq 0xc8d6(%rip), %rcx      # 0x20d60
movq %rcx, (%rax)
leaq 0x10(%rax), %rcx
movl 0x1c(%rsp), %edx
movl %edx, 0x10(%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rax)
movups %xmm0, 0x30(%rax)
movups %xmm0, 0x40(%rax)
movq %rax, 0x8(%rbx)
movq %rcx, (%rbx)
movq $0x0, 0x14(%rax)
movq %r14, %rdi
movq %rbx, %rsi
callq 0x15176
jmp 0x144c7
lock
incl 0x8(%rax)
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq 0x8(%rbx), %rdi
testq %rdi, %rdi
je 0x144ea
callq 0x671a
movq %r14, %rdi
callq 0x53e0
// File: /workspace/github_c_makefile_star2_O3/enzo1982[P]smooth/tools/designer/designer.cpp
// Function: Designer::TimerProc()
void Designer::TimerProc()
{
	Designer_EditComponent	*object;
	Bool			 mouseOnWindow = False;

	for (Int i = 0; i < dlgs.Length(); i++)
	{
		object = dlgs.GetNth(i);

		Point	 mousePos = object->GetWindow()->GetMousePosition();

		if (mousePos.x > 0 && mousePos.y > 0 && mousePos.x < object->GetWindow()->GetWidth() && mousePos.y < object->GetWindow()->GetHeight())
		{
			mouseOnWindow = True;

			break;
		}
	}

	if (!mouseOnWindow && (statusbar->GetText() != "Ready")) statusbar->SetText("Ready");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
cmpl $0x0, 0x668(%rdi)
jle 0x4d45
leaq 0x660(%rbx), %r14
xorl %ebp, %ebp
movq %r14, %rdi
movl %ebp, %esi
callq 0x60fe
movq (%rax), %r15
movq %r15, %rdi
callq 0x66e4
movq %rax, %rdi
callq 0x4130
movq %rax, %r12
movq %rax, %r13
shrq $0x20, %r13
testl %r12d, %r12d
setg %al
testl %r13d, %r13d
setg %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x4d3b
movq %r15, %rdi
callq 0x66e4
cmpl %r12d, 0xb0(%rax)
jle 0x4d3b
movq %r15, %rdi
callq 0x66e4
cmpl %r13d, 0xb4(%rax)
jg 0x4d98
incl %ebp
cmpl 0x668(%rbx), %ebp
jl 0x4cdf
movq 0x5d8(%rbx), %rdi
movq (%rdi), %rax
callq *0xa8(%rax)
leaq 0x330b(%rip), %rsi      # 0x8067
movq %rax, %rdi
callq 0x4230
testb %al, %al
je 0x4d98
movq 0x5d8(%rbx), %rbx
leaq 0x32f1(%rip), %rsi      # 0x8067
movq %rsp, %r14
movq %r14, %rdi
callq 0x4340
movq (%rbx), %rax
movq %rbx, %rdi
movq %r14, %rsi
callq *0xa0(%rax)
movq %rsp, %rdi
callq 0x4200
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq %rsp, %rdi
callq 0x4200
movq %rbx, %rdi
callq 0x4150
// File: /workspace/github_c_makefile_star2_O3/enzo1982[P]smooth/tools/designer/designer.cpp
// Function: Designer::ExitProc()
Bool Designer::ExitProc()
{
	for (Int i = 0; i < dlgs.Length(); i++)
	{
		delete dlgs.GetNth(i);
	}

	dlgs.RemoveAll();

	return True;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
leaq 0x660(%rdi), %rbx
cmpl $0x0, 0x668(%rdi)
jle 0x4f42
movq %rdi, %r14
xorl %ebp, %ebp
movq %rbx, %rdi
movl %ebp, %esi
callq 0x60fe
movq (%rax), %rdi
testq %rdi, %rdi
je 0x4f37
movq (%rdi), %rax
callq *0x10(%rax)
incl %ebp
cmpl 0x668(%r14), %ebp
jl 0x4f1f
movq %rbx, %rdi
callq 0x555e
movb $0x1, %al
popq %rbx
popq %r14
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O3/enzo1982[P]smooth/tools/designer/designer.cpp
// Function: Designer::~Designer()
Designer::~Designer()
{
	timer1->Stop();

	DeleteObject(title);
	DeleteObject(wnd);
	DeleteObject(menubar);
	DeleteObject(iconbar);
	DeleteObject(statusbar);
	DeleteObject(timer1);

	delete menu_file;
	delete menu_dialog;
	delete menu_widgets;
	delete menu_widgets_add;
	delete menu_widgets_add_smooth;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
leaq 0x675b(%rip), %rax      # 0xb6b8
movq %rax, (%rdi)
movq 0x608(%rdi), %rdi
callq 0x41a0
movq 0x5c0(%rbx), %rdi
callq 0x43b0
movq 0x5b8(%rbx), %rdi
callq 0x43b0
movq 0x5c8(%rbx), %rdi
callq 0x43b0
movq 0x5d0(%rbx), %rdi
callq 0x43b0
movq 0x5d8(%rbx), %rdi
callq 0x43b0
movq 0x608(%rbx), %rdi
callq 0x43b0
movq 0x5e0(%rbx), %rdi
testq %rdi, %rdi
je 0x4fc6
movq (%rdi), %rax
callq *0x10(%rax)
movq 0x5e8(%rbx), %rdi
testq %rdi, %rdi
je 0x4fd8
movq (%rdi), %rax
callq *0x10(%rax)
movq 0x5f0(%rbx), %rdi
testq %rdi, %rdi
je 0x4fea
movq (%rdi), %rax
callq *0x10(%rax)
movq 0x5f8(%rbx), %rdi
testq %rdi, %rdi
je 0x4ffc
movq (%rdi), %rax
callq *0x10(%rax)
movq 0x600(%rbx), %rdi
testq %rdi, %rdi
je 0x500e
movq (%rdi), %rax
callq *0x10(%rax)
leaq 0x660(%rbx), %rdi
callq 0x551a
leaq 0x628(%rbx), %rdi
callq 0x4200
movq %rbx, %rdi
popq %rbx
jmp 0x4220
movq %rax, %rdi
callq 0x5552
nop
// File: /workspace/github_c_makefile_star2_O3/enzo1982[P]smooth/tools/designer/edit_component.cpp
// Function: Designer_EditComponent::AddObject(short)
Widget *Designer_EditComponent::AddObject(Short objid)
{
	Widget	*newobj;
	Widget	*registrar;
	Point	 pos;
	Size	 size;

	switch (objid)
	{
		case SMOOTH_BUTTON:
			registrar = wnd;

			pos.x	  = 100;
			pos.y	  = 100;
			size.cx	  = 0;
			size.cy	  = 0;

			newobj	  = new Button("Button", pos, size);

			break;
		case SMOOTH_LAYER:
			registrar = wnd;
			newobj	  = new Layer("Layer");

			break;
		case SMOOTH_MENUBAR:
			registrar = wnd;
			newobj	  = new Menubar();

			break;
		default:
			QuickMessage("Unknown object ID!", "Error", Message::Buttons::Ok, Message::Icon::Error);

			return NIL;
	}

	registrar->Add(newobj);

	objects.Add(newobj);

	return newobj;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x50, %rsp
movq %rdi, %r14
xorl %eax, %eax
movq %rax, 0x30(%rsp)
movq %rax, 0x28(%rsp)
cmpl $0x3, %esi
je 0x6793
cmpl $0x2, %esi
je 0x6770
cmpl $0x1, %esi
jne 0x67fc
movq 0x5b8(%r14), %r15
movabsq $0x6400000064, %rax     # imm = 0x6400000064
movq %rax, 0x30(%rsp)
movl $0x0, 0x2c(%rsp)
movl $0x5c8, %edi            # imm = 0x5C8
callq 0x4250
movq %rax, %rbx
leaq 0x1951(%rip), %rsi      # 0x809e
leaq 0x8(%rsp), %rdi
callq 0x4340
leaq 0x8(%rsp), %rsi
leaq 0x30(%rsp), %rdx
leaq 0x28(%rsp), %rcx
movq %rbx, %rdi
callq 0x4190
jmp 0x67c5
movq 0x5b8(%r14), %r15
movl $0x688, %edi            # imm = 0x688
callq 0x4250
movq %rax, %rbx
movq %rax, %rdi
callq 0x4140
movq %rbx, 0x20(%rsp)
jmp 0x67d4
movq 0x5b8(%r14), %r15
movl $0x5b8, %edi            # imm = 0x5B8
callq 0x4250
movq %rax, %rbx
leaq 0x18f7(%rip), %rsi      # 0x80a5
leaq 0x8(%rsp), %rdi
callq 0x4340
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x4100
movq %rbx, 0x20(%rsp)
leaq 0x8(%rsp), %rdi
callq 0x4200
movq (%r15), %rax
movq %r15, %rdi
movq %rbx, %rsi
callq *0x30(%rax)
addq $0x5c8, %r14            # imm = 0x5C8
leaq 0x20(%rsp), %rbx
movq %r14, %rdi
movq %rbx, %rsi
callq 0x6ce2
movq (%rbx), %rax
jmp 0x684a
leaq 0x1a5d(%rip), %rsi      # 0x8260
leaq 0x8(%rsp), %rdi
callq 0x4340
leaq 0x1a5f(%rip), %rsi      # 0x8273
leaq 0x38(%rsp), %rdi
callq 0x4340
leaq 0x8(%rsp), %rdi
leaq 0x38(%rsp), %rsi
xorl %edx, %edx
movl $0x7f01, %ecx           # imm = 0x7F01
callq 0x41c0
leaq 0x38(%rsp), %rdi
callq 0x4200
leaq 0x8(%rsp), %rdi
callq 0x4200
xorl %eax, %eax
addq $0x50, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
leaq 0x38(%rsp), %rdi
callq 0x4200
jmp 0x6884
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x4200
jmp 0x6893
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x4200
jmp 0x689d
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x4200
jmp 0x68b4
movq %rax, %r14
movl $0x5c8, %esi            # imm = 0x5C8
jmp 0x68ac
movq %rax, %r14
movl $0x5b8, %esi            # imm = 0x5B8
jmp 0x68ac
movq %rax, %r14
movl $0x688, %esi            # imm = 0x688
movq %rbx, %rdi
callq 0x4050
movq %r14, %rdi
callq 0x4150
// File: /workspace/github_c_makefile_star2_O3/truenas[P]binaries/src/plx_eeprom.c
// Function: plx_eeprom_read
static uint32_t
plx_eeprom_read(void *mem, u_int addr)
{
	uint32_t val;

	if ((addr > 0x00ffffff) || (addr & 0x3) != 0)
		errx(EX_OSERR, "Incorrect EEPROM address %x", addr);

	/* Write address byte 3. */
	val = read4(mem, 0x26c);
	write4(mem, 0x26c, (val & ~0xff) | (addr >> 24));

	/* Initiate read. */
	addr >>= 2;
	val = read4(mem, 0x260);
	val &= 0xffe00000;
	val |= ((addr & 0x2000) << 7) | (3 << 13) | (addr & 0x1fff);
	write4(mem, 0x260, val);

	/* Wait for completion. */
	val = 100;
	while ((read4(mem, 0x260) & 0x40000) != 0 && val > 0) {
		usleep(100);
		val--;
	}
	if (val == 0)
		errx(EX_OSERR, "EEPROM write timeout");

	/* Read result. */
	val = read4(mem, 0x264);
	return (val);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %edx
testl $0xff000003, %esi       # imm = 0xFF000003
jne 0x191d
movq %rdi, %rbx
andl $0xffffff00, 0x26c(%rdi) # imm = 0xFFFFFF00
movl %edx, %eax
shrl $0x2, %eax
movl $0xffe00000, %ecx       # imm = 0xFFE00000
andl 0x260(%rdi), %ecx
shll $0x5, %edx
andl $0x100000, %edx         # imm = 0x100000
andl $0x1fff, %eax           # imm = 0x1FFF
orl %edx, %eax
addl %ecx, %eax
addl $0x6000, %eax           # imm = 0x6000
movl %eax, 0x260(%rdi)
btl $0x12, 0x260(%rdi)
jae 0x190f
movl $0x64, %r14d
movl $0x64, %edi
callq 0x1150
leal -0x1(%r14), %eax
btl $0x12, 0x260(%rbx)
jae 0x190b
cmpl $0x1, %r14d
movl %eax, %r14d
jne 0x18ea
testl %eax, %eax
je 0x1930
movl 0x264(%rbx), %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x7ad(%rip), %rsi       # 0x20d1
movl $0x47, %edi
xorl %eax, %eax
callq 0x1070
leaq 0x7b6(%rip), %rsi       # 0x20ed
movl $0x47, %edi
xorl %eax, %eax
callq 0x1070
// File: /workspace/github_c_makefile_star2_O3/truenas[P]binaries/src/plx_eeprom.c
// Function: plx_config_print
static void
plx_config_print(char *buf, int n)
{
	int i, r, port, error;
	uint32_t val;

	printf("   #\tPort\tReg\tValue\n");
	printf("--------------------------------\n");
	n /= 6;
	for (i = 0; i < n; i++) {
		printf(" %3d\t", i);
		val = le16dec(&buf[i * 6]);
		port = val >> 10;
		if ((port & 0x38) == 0x20)
			printf("A-LUT %d", port & 0x3);
		else if (port == 0x2c)
			printf("DMA RAM");
		else if ((port & 0x38) == 0x28)
			printf("DMA %d", port & 0x7);
		else if ((port & 0x38) == 0x30)
			printf("S%dP0", port & 0x7);
		else if ((port & 0x38) == 0x38)
			printf("NT%d %c", (port >> 1) & 0x1,
			    (port & 0x1) ? 'V' : 'L');
		else
			printf("%d", port);
		printf("\t%03x\t%08x\n",
		    (val & 0x3ff) * 4, le32dec(&buf[i * 6] + 2));
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x878(%rip), %rdi       # 0x21d2
callq 0x1040
leaq 0x880(%rip), %rdi       # 0x21e6
callq 0x1040
cmpl $0x6, %ebp
jae 0x197f
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %ebp, %eax
movl $0xaaaaaaab, %r13d      # imm = 0xAAAAAAAB
imulq %rax, %r13
shrq $0x22, %r13
addq $0x2, %rbx
leaq 0x7e9(%rip), %r12       # 0x2183
xorl %ebp, %ebp
leaq 0x7b4(%rip), %rdi       # 0x2157
movl %ebp, %esi
xorl %eax, %eax
callq 0x1080
movzbl -0x2(%rbx), %r15d
movzbl -0x1(%rbx), %r14d
movl %r14d, %esi
shrl $0x2, %esi
movl %esi, %eax
andl $-0x8, %eax
cmpl $0x20, %eax
jne 0x19d9
andl $0x3, %esi
leaq 0x78d(%rip), %rdi       # 0x215d
xorl %eax, %eax
callq 0x1080
jmp 0x19ec
cmpl $0x2c, %esi
jne 0x1a15
leaq 0x781(%rip), %rdi       # 0x2166
xorl %eax, %eax
callq 0x1080
andl $0x3, %r14d
shll $0xa, %r14d
leal (%r14,%r15,4), %esi
movl (%rbx), %edx
movq %r12, %rdi
xorl %eax, %eax
callq 0x1080
incq %rbp
addq $0x6, %rbx
cmpq %rbp, %r13
jne 0x199c
jmp 0x1970
cmpl $0x38, %eax
je 0x1a3c
cmpl $0x30, %eax
je 0x1a30
cmpl $0x28, %eax
jne 0x1a66
andl $0x7, %esi
leaq 0x740(%rip), %rdi       # 0x216e
jmp 0x19d0
andl $0x7, %esi
leaq 0x73b(%rip), %rdi       # 0x2175
jmp 0x19d0
movl %r14d, %esi
shrl $0x3, %esi
andl $0x1, %esi
testb $0x4, %r14b
movl $0x56, %edx
movl $0x4c, %eax
cmovel %eax, %edx
leaq 0x71e(%rip), %rdi       # 0x217b
xorl %eax, %eax
callq 0x1080
jmp 0x19ec
leaq 0x705(%rip), %rdi       # 0x2172
jmp 0x19d0
// File: /workspace/github_c_makefile_star2_O3/orangeduck[P]mpc/examples/doge.c
// Function: main
int main(int argc, char **argv) {

  mpc_result_t r;
  
  mpc_parser_t* Adjective = mpc_new("adjective");
  mpc_parser_t* Noun      = mpc_new("noun");
  mpc_parser_t* Phrase    = mpc_new("phrase");
  mpc_parser_t* Doge      = mpc_new("doge");

  mpca_lang(MPCA_LANG_DEFAULT,
    " adjective : \"wow\" | \"many\" | \"so\" | \"such\";                 "
    " noun      : \"lisp\" | \"language\" | \"c\" | \"book\" | \"build\"; "
    " phrase    : <adjective> <noun>;                                     "
    " doge      : /^/ <phrase>* /$/;                                      ",
    Adjective, Noun, Phrase, Doge, NULL);
  
  if (argc > 1) {
    
    if (mpc_parse_contents(argv[1], Doge, &r)) {
      mpc_ast_print(r.output);
      mpc_ast_delete(r.output);
    } else {
      mpc_err_print(r.error);
      mpc_err_delete(r.error);
    }
  
  } else {

    if (mpc_parse_pipe("<stdin>", stdin, Doge, &r)) {
      mpc_ast_print(r.output);
      mpc_ast_delete(r.output);
    } else {
      mpc_err_print(r.error);
      mpc_err_delete(r.error);
    }
  
  }

  mpc_cleanup(4, Adjective, Noun, Phrase, Doge);
  
  return 0;
  
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r13
movl %edi, %ebp
leaq 0x9cce(%rip), %rdi      # 0xb004
callq 0x2f36
movq %rax, %rbx
leaq 0x9cc9(%rip), %rdi      # 0xb00e
callq 0x2f36
movq %rax, %r14
leaq 0x9cbf(%rip), %rdi      # 0xb013
callq 0x2f36
movq %rax, %r15
leaq 0x9cb7(%rip), %rdi      # 0xb01a
callq 0x2f36
movq %rax, %r12
movq $0x0, (%rsp)
leaq 0x9ca5(%rip), %rsi      # 0xb01f
xorl %edi, %edi
movq %rbx, %rdx
movq %r14, %rcx
movq %r15, %r8
movq %rax, %r9
xorl %eax, %eax
callq 0x8a2e
cmpl $0x2, %ebp
jl 0x13aa
movq 0x8(%r13), %rdi
leaq 0x10(%rsp), %r13
movq %r12, %rsi
movq %r13, %rdx
callq 0x2cfe
jmp 0x13cb
movq 0xec2f(%rip), %rax      # 0xffe0
movq (%rax), %rsi
leaq 0x9d67(%rip), %rdi      # 0xb122
leaq 0x10(%rsp), %r13
movq %r12, %rdx
movq %r13, %rcx
callq 0x2c36
movq (%r13), %rdi
testl %eax, %eax
je 0x13e4
callq 0x6be3
movq 0x10(%rsp), %rdi
callq 0x6784
jmp 0x13f3
callq 0x146f
movq 0x10(%rsp), %rdi
callq 0x141c
movl $0x4, %edi
movq %rbx, %rsi
movq %r14, %rdx
movq %r15, %rcx
movq %r12, %r8
xorl %eax, %eax
callq 0x334a
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/theck01[P]offbrand_lib/src/tests/obtest_test.c
// Function: main
int main(){

  int i;
  obtest *test_obj, *a, *b;
  test_obj = obtest_new(1);
  a = obtest_new(3);
  b = obtest_new(3);

  /* ob_retain object, reference count should be 4 */
  for(i=0; i<3; i++){
    ob_retain((obj *)test_obj);
  }

  if(ob_reference_count((obj *)test_obj) != 4){
    fprintf(stderr, "obtest_test: reference count not incrememted correctly by "
                    "ob_retain\nTEST FAILED\n");
    exit(1);
  }

  /* ob_release object until test_obj is deallocated or until ob_release has been
   * called more than 4 times */
  i=0;
  while(++i < 5 && ob_release((obj *)test_obj) != NULL){}

  if(i<4){
    fprintf(stderr, "obtest_test: test_obj ob_released before reference count "
                    "reached zero, TEST FAILED\n");
    exit(1);
	}
  else if(i>4){
    fprintf(stderr, "obtest_test: test_obj not ob_released when reference count "
                    "reached zero\n");
    exit(1);
	}

  if(!ob_has_same_class((obj *)a, (obj *)b)){
    fprintf(stderr, "obtest_test: Two obtest objects were not of the same "
                    "class, TEST FAILED\n");
    exit(1);
  }

  if(!ob_has_class((obj *)a, "obtest")){
    fprintf(stderr, "obtest_test: An obtest object was not considered to be an "
                    "obtest object during check, TEST FAILED\n");
    exit(1);
  }

  ob_hash((obj *)a);

  printf("obtest: TEST PASSED\n");
  return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl $0x1, %edi
callq 0x13a0
movq %rax, %r14
movl $0x3, %ebp
movl $0x3, %edi
callq 0x13a0
movq %rax, %rbx
movl $0x3, %edi
callq 0x13a0
movq %rax, %r15
movq %r14, %rdi
callq 0x17a7
decl %ebp
jne 0x130f
movq %r14, %rdi
callq 0x17de
cmpl $0x4, %eax
jne 0x138b
movl $0x4, %ebp
subl $0x1, %ebp
jb 0x1386
movq %r14, %rdi
callq 0x1772
testq %rax, %rax
jne 0x132d
testl %ebp, %ebp
jne 0x1390
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1814
testb %al, %al
je 0x1395
leaq 0xde2(%rip), %rsi       # 0x213b
movq %rbx, %rdi
callq 0x17ec
testb %al, %al
je 0x139a
movq %rbx, %rdi
callq 0x16b0
leaq 0xe31(%rip), %rdi       # 0x21a5
callq 0x1040
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
callq 0x1154
callq 0x10c0
callq 0x10e5
callq 0x112f
callq 0x110a
nop
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/main.c
// Function: usage
static void
usage(const char *argv0)
{
  printf("\n");
  printf("Usage ... %s [OPTIONS] <file.bc>\n", argv0);
  printf("\n");
  printf("  -f FUNCTION         Function to diagnose [ALL]\n");
  printf("  -l                  Dump lowered function(s)\n");
  printf("  -p                  Dump parsed function(s)\n");
  printf("  -i                  List all functions\n");
  printf("  -n                  Don't try to run code\n");
  printf("\n");
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl $0xa, %edi
callq 0x3040
leaq 0x1f5a6(%rip), %rdi     # 0x230c2
movq %rbx, %rsi
xorl %eax, %eax
callq 0x3190
movl $0xa, %edi
callq 0x3040
leaq 0x1f6d9(%rip), %rdi     # 0x23210
callq 0x30e0
leaq 0x1f6fe(%rip), %rdi     # 0x23241
callq 0x30e0
leaq 0x1f721(%rip), %rdi     # 0x23270
callq 0x30e0
leaq 0x1f743(%rip), %rdi     # 0x2329e
callq 0x30e0
leaq 0x1f760(%rip), %rdi     # 0x232c7
callq 0x30e0
movl $0xa, %edi
popq %rbx
jmp 0x3040
nop
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir_function.c
// Function: vmir_find_function
ir_function_t *
vmir_find_function(ir_unit_t *iu, const char *name)
{
  for(int i = 0; i < VECTOR_LEN(&iu->iu_functions); i++) {
    ir_function_t *f = VECTOR_ITEM(&iu->iu_functions, i);
    if(f->if_name != NULL && !strcmp(f->if_name, name))
      return f;
  }
  return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq 0x2e0(%rdi), %r15
testq %r15, %r15
je 0x3bca
movq %rsi, %rbx
movq 0x2d8(%rdi), %r12
xorl %r13d, %r13d
movq (%r12,%r13,8), %r14
movq 0x20(%r14), %rdi
testq %rdi, %rdi
je 0x3bc2
movq %rbx, %rsi
callq 0x3300
testl %eax, %eax
je 0x3bcd
incq %r13
cmpq %r13, %r15
jne 0x3ba9
xorl %r14d, %r14d
movq %r14, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir_vm.c
// Function: vmir_vm_arg_func
ir_function_t *
vmir_vm_arg_func(const void **rfp, ir_unit_t *iu)
{
  uint32_t fnid = vmir_vm_arg32(rfp);
  if(fnid >= VECTOR_LEN(&iu->iu_functions))
    return NULL;
  return VECTOR_ITEM(&iu->iu_functions, fnid);
}

// Assembly:
movq (%rdi), %rax
leaq -0x4(%rax), %rcx
movq %rcx, (%rdi)
movl -0x4(%rax), %eax
cmpq %rax, 0x2e0(%rsi)
jbe 0x3c65
movq 0x2d8(%rsi), %rcx
movq (%rcx,%rax,8), %rax
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir.c
// Function: vmir_log
static void
vmir_log(ir_unit_t *iu, vmir_log_level_t level, const char *fmt, ...)
{
  if(level > iu->iu_log_level)
    return;

  va_list ap;
  char tmp[1024];
  va_start(ap, fmt);
  vsnprintf(tmp, sizeof(tmp), fmt, ap);
  va_end(ap);

  if(iu->iu_logger) {
    iu->iu_logger(iu, level, tmp);
  } else {
    printf("%s\n", tmp);
  }
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x4d8, %rsp            # imm = 0x4D8
movq %r9, 0x48(%rsp)
testb %al, %al
je 0x40db
movaps %xmm0, 0x50(%rsp)
movaps %xmm1, 0x60(%rsp)
movaps %xmm2, 0x70(%rsp)
movaps %xmm3, 0x80(%rsp)
movaps %xmm4, 0x90(%rsp)
movaps %xmm5, 0xa0(%rsp)
movaps %xmm6, 0xb0(%rsp)
movaps %xmm7, 0xc0(%rsp)
movq %r8, 0x40(%rsp)
movq %rcx, 0x38(%rsp)
cmpl %esi, 0x630(%rdi)
jb 0x4153
movl %esi, %ebx
movq %rdi, %r14
movabsq $0x3000000018, %rax     # imm = 0x3000000018
movq %rsp, %rcx
movq %rax, (%rcx)
leaq 0x4f0(%rsp), %rax
movq %rax, 0x8(%rcx)
leaq 0x20(%rsp), %rax
movq %rax, 0x10(%rcx)
leaq 0xd0(%rsp), %rdi
movl $0x400, %esi            # imm = 0x400
callq 0x3120
movq 0x628(%r14), %rax
testq %rax, %rax
je 0x4146
leaq 0xd0(%rsp), %rdx
movq %r14, %rdi
movl %ebx, %esi
callq *%rax
jmp 0x4153
leaq 0xd0(%rsp), %rdi
callq 0x30e0
addq $0x4d8, %rsp            # imm = 0x4D8
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir_type.c
// Function: type_str
static const char *
type_str(ir_unit_t *iu, const ir_type_t *it)
{
  int len = type_print(NULL, iu, it);
  char *dst = tmpstr(iu, len);
  const char *ret = dst;
  type_print(&dst, iu, it);
  return ret;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
xorl %edi, %edi
movq %r14, %rsi
movq %rbx, %rdx
callq 0xcebd
movq %r14, %rdi
movl %eax, %esi
callq 0xd299
movq %rax, %r15
leaq 0x8(%rsp), %rdi
movq %rax, (%rdi)
movq %r14, %rsi
movq %rbx, %rdx
callq 0xcebd
movq %r15, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir_libc.c
// Function: vmir_mem_alloc
uint32_t
vmir_mem_alloc(ir_unit_t *iu, uint32_t size, void *hostaddr_)
{
  void **hostaddr = hostaddr_;
  void *p = vmir_heap_malloc(iu, size);
  if(p == NULL) {
    if(hostaddr)
      *hostaddr = NULL;
    return 0;
  }
  if(hostaddr)
    *hostaddr = p;
  return p - iu->iu_mem;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rdi, %r14
movq 0x90(%rdi), %rdi
callq 0xa0d0
testq %rax, %rax
je 0x41d0
testq %rbx, %rbx
je 0x41ca
movq %rax, (%rbx)
subl 0x20(%r14), %eax
jmp 0x41de
xorl %eax, %eax
testq %rbx, %rbx
je 0x41de
movq $0x0, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir_libc.c
// Function: vmir_fd_get
static vmir_fd_t *
vfd_get(ir_unit_t *iu, unsigned int fd, int type)
{
  if(fd >= VECTOR_LEN(&iu->iu_vfds))
    return NULL;
  vmir_fd_t *vfd = &VECTOR_ITEM(&iu->iu_vfds, fd);
  if(vfd->type == 0 || (type != -1 && vfd->type != type))
    return NULL; // Bad/Closed fd
  return vfd;
}

// Assembly:
movl %esi, %ecx
cmpq %rcx, 0xd8(%rdi)
jbe 0x9e6a
movq 0xd0(%rdi), %rax
leaq (%rcx,%rcx,2), %rcx
movzbl 0x10(%rax,%rcx,8), %esi
testl %esi, %esi
je 0x9e6a
cmpl $-0x1, %edx
je 0x9e6d
cmpl %edx, %esi
je 0x9e6d
xorl %eax, %eax
retq
leaq (%rax,%rcx,8), %rax
movq (%rax), %rax
retq
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir_libc.c
// Function: vmir_fd_create
int
vmir_fd_create(ir_unit_t *iu, intptr_t handle, int type,
               vmir_fd_release_t *relfunc)
{
  int fd = vfd_create(iu, type);
  vmir_fd_t *vfd = &VECTOR_ITEM(&iu->iu_vfds, fd);
  vfd->fh = handle;
  vfd->release = relfunc;
  return fd;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %r12
movslq 0xe8(%rdi), %rax
cmpq $-0x1, %rax
je 0x9eb4
movq 0xd0(%r12), %rcx
leaq (%rax,%rax,2), %rdx
movl (%rcx,%rdx,8), %edx
movl %edx, 0xe8(%r12)
movl %eax, %r15d
jmp 0x9f24
movq 0xd0(%r12), %rax
movq 0xd8(%r12), %r15
leaq 0x1(%r15), %r13
cmpq 0xe0(%r12), %r13
jbe 0x9efd
leaq (,%r13,2), %rcx
movq %rcx, 0xe0(%r12)
movq %r13, %rcx
shlq $0x4, %rcx
leaq (%rcx,%rcx,2), %rsi
movq %rax, %rdi
callq 0x33c0
movq %rax, 0xd0(%r12)
movq %r13, 0xd8(%r12)
leaq (%r15,%r15,2), %rcx
xorps %xmm0, %xmm0
movups %xmm0, (%rax,%rcx,8)
movq $0x0, 0x10(%rax,%rcx,8)
movq 0xd0(%r12), %rcx
movslq %r15d, %rax
leaq (%rax,%rax,2), %rdx
movb %bpl, 0x10(%rcx,%rdx,8)
leaq (%rax,%rax,2), %rax
movq %r14, (%rcx,%rax,8)
movq %rbx, 0x8(%rcx,%rax,8)
movl %r15d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir_libc.c
// Function: vmir_fd_close
void
vmir_fd_close(ir_unit_t *iu, int fd)
{
  vmir_fd_t *vfd = vfd_get(iu, fd, -1);
  if(vfd == NULL)
    return;
  if(vfd->release)
    vfd->release(iu, vfd->fh);
  vfd->type = 0;
  vfd->freelist = iu->iu_vfd_free;
  iu->iu_vfd_free = fd;
}

// Assembly:
movl %esi, %eax
cmpq %rax, 0xd8(%rdi)
jbe 0x9fd0
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %r14
movq 0xd0(%rdi), %rcx
leaq (%rax,%rax,2), %rax
cmpb $0x0, 0x10(%rcx,%rax,8)
je 0x9fcb
movl %esi, %ebx
leaq (%rcx,%rax,8), %r15
movq 0x8(%r15), %rax
testq %rax, %rax
je 0x9fb5
movq (%r15), %rsi
movq %r14, %rdi
callq *%rax
movb $0x0, 0x10(%r15)
movl 0xe8(%r14), %eax
movl %eax, (%r15)
movl %ebx, 0xe8(%r14)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir_libc.c
// Function: vmir_function_tab_lookup
vm_ext_function_t *
vmir_function_tab_lookup(const char *function,
                         const vmir_function_tab_t *array, int length)
{
  for(int i = 0; i < length; i++) {
    const vmir_function_tab_t *ft = array + i;
    if(!strcmp(function, ft->name)) {
      return ft->extfunc;
    }
  }
  return NULL;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
testl %edx, %edx
jle 0xa00b
movq %rsi, %r14
movq %rdi, %r15
movl %edx, %r12d
shlq $0x4, %r12
xorl %ebx, %ebx
xorl %r13d, %r13d
movq (%r14,%r13), %rsi
movq %r15, %rdi
callq 0x3300
testl %eax, %eax
je 0xa00f
addq $0x10, %r13
cmpq %r13, %r12
jne 0x9ff0
jmp 0xa014
xorl %ebx, %ebx
jmp 0xa014
movq 0x8(%r14,%r13), %rbx
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir_libc.c
// Function: vmir_walk_fds
void
vmir_walk_fds(ir_unit_t *iu,
              void (*fn)(void *opaque, int fd, int type),
              void *opaque)
{
  for(int i = 0; i < VECTOR_LEN(&iu->iu_vfds); i++) {
    vmir_fd_t *vfd = &VECTOR_ITEM(&iu->iu_vfds, i);
    if(vfd->type != 0)
      fn(opaque, i, vfd->type);
  }
}

// Assembly:
movq 0xd8(%rdi), %rax
testq %rax, %rax
je 0xa0cf
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movl $0x10, %r13d
xorl %r12d, %r12d
movq 0xd0(%r15), %rcx
movzbl (%rcx,%r13), %edx
testl %edx, %edx
je 0xa0ba
movq %rbx, %rdi
movl %r12d, %esi
callq *%r14
movq 0xd8(%r15), %rax
incq %r12
addq $0x18, %r13
cmpq %r12, %rax
ja 0xa09a
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/cogbee[P]vmir-latest/src/vmir_libc.c
// Function: vmir_heap_malloc
static void *
vmir_heap_malloc(ir_unit_t *iu, int size)
{
  heap_t *h = iu->iu_heap;
  heap_block_t *hb;
  size += sizeof(heap_block_t);
  size = VMIR_ALIGN(size, 16);

  TAILQ_FOREACH(hb, &h->h_blocks, hb_link) {
    if(hb->hb_magic != HEAP_MAGIC_FREE)
      continue;

    if(size <= hb->hb_size) {
      int remain = hb->hb_size - size;
      if(remain < sizeof(heap_block_t) * 2) {
        size = hb->hb_size;
      } else {
        heap_block_t *split = (void *)hb + size;
        split->hb_magic = HEAP_MAGIC_FREE;
        split->hb_size = remain;
        TAILQ_INSERT_AFTER(&h->h_blocks, hb, split, hb_link);
      }

      hb->hb_magic = HEAP_MAGIC_ALLOC;
      hb->hb_size = size;
      return (void *)(hb + 1);
    }
  }
  return NULL;
}

// Assembly:
movq (%rdi), %rax
testq %rax, %rax
je 0xa0fc
addl $0x27, %esi
movslq %esi, %rcx
andq $-0x10, %rcx
cmpl $0xf4eef4ee, (%rax)     # imm = 0xF4EEF4EE
jne 0xa0f3
movl 0x4(%rax), %edx
movl %edx, %esi
subl %ecx, %esi
jge 0xa0ff
movq 0x8(%rax), %rax
testq %rax, %rax
jne 0xa0e2
xorl %eax, %eax
retq
cmpl $0x30, %esi
jb 0xa143
leaq (%rax,%rcx), %rdx
leaq (%rax,%rcx), %r8
addq $0x8, %r8
movl $0xf4eef4ee, -0x8(%r8)  # imm = 0xF4EEF4EE
movl %esi, -0x4(%r8)
leaq 0x8(%rax), %rsi
movq 0x8(%rax), %r9
movq %r9, (%r8)
addq $0x8, %rdi
leaq 0x10(%r9), %r10
testq %r9, %r9
cmoveq %rdi, %r10
movq %r8, (%r10)
movq %rdx, 0x8(%rax)
movq %rsi, 0x8(%r8)
movl %ecx, %edx
movl $0xa110ced, (%rax)      # imm = 0xA110CED
movl %edx, 0x4(%rax)
addq $0x18, %rax
retq