LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O0/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_02/var_group.c
// Function: get_word
int get_word(char *word, int max_word_len)
{
  skip_blanks();
  skip_comments();
  skip_char_literal();
  skip_string_literal();

  int c = getc(stdin);
  size_t i = 0;

  if (c != EOF)
  {
    word[i++] = c;
  }

  if (!isalpha(c) && c != '_')
  {
    word[i] = '\0';
    return c;
  }

  while ((isalnum(c = getc(stdin)) || c == '_') && i < max_word_len)
  {
    word[i++] = c;
  }
  ungetc(c, stdin);
  word[i] = '\0';

  return word[0];
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
callq 0x16b0
callq 0x1710
callq 0x18b0
callq 0x18d0
movq 0x2c26(%rip), %rax      # 0x3fe0
movq (%rax), %rdi
callq 0x10c0
movl %eax, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
cmpl $-0x1, -0x18(%rbp)
je 0x13ee
movl -0x18(%rbp), %eax
movb %al, %dl
movq -0x10(%rbp), %rax
movq -0x20(%rbp), %rcx
movq %rcx, %rsi
addq $0x1, %rsi
movq %rsi, -0x20(%rbp)
movb %dl, (%rax,%rcx)
callq 0x10d0
movq (%rax), %rax
movslq -0x18(%rbp), %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x400, %eax            # imm = 0x400
cmpl $0x0, %eax
jne 0x1425
cmpl $0x5f, -0x18(%rbp)
je 0x1425
movq -0x10(%rbp), %rax
movq -0x20(%rbp), %rcx
movb $0x0, (%rax,%rcx)
movl -0x18(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x14c4
jmp 0x1427
callq 0x10d0
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movq 0x2ba6(%rip), %rax      # 0x3fe0
movq (%rax), %rdi
callq 0x10c0
movl %eax, %ecx
movq -0x28(%rbp), %rax
movl %ecx, -0x18(%rbp)
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x8, %eax
cmpl $0x0, %eax
jne 0x1465
xorl %eax, %eax
cmpl $0x5f, -0x18(%rbp)
movb %al, -0x29(%rbp)
jne 0x1476
movq -0x20(%rbp), %rax
movslq -0x14(%rbp), %rcx
cmpq %rcx, %rax
setb %al
movb %al, -0x29(%rbp)
movb -0x29(%rbp), %al
testb $0x1, %al
jne 0x147f
jmp 0x149c
movl -0x18(%rbp), %eax
movb %al, %dl
movq -0x10(%rbp), %rax
movq -0x20(%rbp), %rcx
movq %rcx, %rsi
addq $0x1, %rsi
movq %rsi, -0x20(%rbp)
movb %dl, (%rax,%rcx)
jmp 0x1427
movl -0x18(%rbp), %edi
movq 0x2b3a(%rip), %rax      # 0x3fe0
movq (%rax), %rsi
callq 0x10a0
movq -0x10(%rbp), %rax
movq -0x20(%rbp), %rcx
movb $0x0, (%rax,%rcx)
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_02/var_group.c
// Function: bin_search
int bin_search(char *word, char *arr[], int arr_len)
{
  int low = 0;
  int high = arr_len - 1;
  int mid;

  while (low <= high)
  {
    mid = (low + high) / 2;

    int cond = strcmp(word, arr[mid]);
    if (cond < 0)
    {
      high = mid - 1;
    }
    else if (cond > 0)
    {
      low = mid + 1;
    }
    else
    {
      return mid;
    }
  }

  return -1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movl $0x0, -0x20(%rbp)
movl -0x1c(%rbp), %eax
subl $0x1, %eax
movl %eax, -0x24(%rbp)
movl -0x20(%rbp), %eax
cmpl -0x24(%rbp), %eax
jg 0x1552
movl -0x20(%rbp), %eax
addl -0x24(%rbp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, -0x28(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rax
movslq -0x28(%rbp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x1080
movl %eax, -0x2c(%rbp)
cmpl $0x0, -0x2c(%rbp)
jge 0x1535
movl -0x28(%rbp), %eax
subl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x1550
cmpl $0x0, -0x2c(%rbp)
jle 0x1546
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
jmp 0x154e
movl -0x28(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x1559
jmp 0x1550
jmp 0x14f3
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_02/var_group.c
// Function: add_to_list
struct list_node *add_to_list(struct list_node *list_node_p, char *word)
{
  if (list_node_p == NULL)
  {
    list_node_p = (struct list_node *)malloc(sizeof(struct list_node));
    list_node_p->var_group = add_to_tree(list_node_p->var_group, word);
  }
  else if (strncmp(list_node_p->var_group->word, word, var_name_str_cmp_len) == 0)
  {
    list_node_p->var_group = add_to_tree(list_node_p->var_group, word);
  }
  else
  {
    list_node_p->next = add_to_list(list_node_p->next, word);
  }

  return list_node_p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
cmpq $0x0, -0x8(%rbp)
jne 0x15b1
movl $0x10, %edi
callq 0x1090
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rsi
callq 0x18f0
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, (%rax)
jmp 0x160a
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rsi
movslq 0x2af2(%rip), %rdx      # 0x40b8
callq 0x1040
cmpl $0x0, %eax
jne 0x15ec
movq -0x8(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rsi
callq 0x18f0
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, (%rax)
jmp 0x1608
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x10(%rbp), %rsi
callq 0x1570
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x8(%rax)
jmp 0x160a
movq -0x8(%rbp), %rax
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_02/var_group.c
// Function: print_list
void print_list(struct list_node *node_p)
{
  if (node_p != NULL)
  {
    print_tree(node_p->var_group);
    putchar('\n');
    print_list(node_p->next);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
cmpq $0x0, -0x8(%rbp)
je 0x1656
movq -0x8(%rbp), %rax
movq (%rax), %rdi
callq 0x19b0
movl $0xa, %edi
callq 0x1030
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x1620
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_02/var_group.c
// Function: skip_chars_between
void skip_chars_between(char start, char end)
{
  int c = getc(stdin);
  if (c == start)
  {
    while ((c = getc(stdin)) != EOF)
    {
      if (c == '\\')
      {
        if ((c = getc(stdin)) == EOF)
        {
          break;
        }
      }
      else if (c == end)
      {
        return;
      }
    }
  }
  ungetc(c, stdin);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movb %sil, %al
movb %dil, %cl
movb %cl, -0x1(%rbp)
movb %al, -0x2(%rbp)
movq 0x27b5(%rip), %rax      # 0x3fe0
movq (%rax), %rdi
callq 0x10c0
movl %eax, -0x8(%rbp)
movl -0x8(%rbp), %eax
movsbl -0x1(%rbp), %ecx
cmpl %ecx, %eax
jne 0x188e
jmp 0x1843
movq 0x2796(%rip), %rax      # 0x3fe0
movq (%rax), %rdi
callq 0x10c0
movl %eax, -0x8(%rbp)
cmpl $-0x1, %eax
je 0x188c
cmpl $0x5c, -0x8(%rbp)
jne 0x187b
movq 0x2779(%rip), %rax      # 0x3fe0
movq (%rax), %rdi
callq 0x10c0
movl %eax, -0x8(%rbp)
cmpl $-0x1, %eax
jne 0x1879
jmp 0x188c
jmp 0x188a
movl -0x8(%rbp), %eax
movsbl -0x2(%rbp), %ecx
cmpl %ecx, %eax
jne 0x1888
jmp 0x18a0
jmp 0x188a
jmp 0x1843
jmp 0x188e
movl -0x8(%rbp), %edi
movq 0x2748(%rip), %rax      # 0x3fe0
movq (%rax), %rsi
callq 0x10a0
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/ohkimur[P]the-c-programming-language-2nd-edition-solutions/chapter_6/exercise_6_02/var_group.c
// Function: print_tree
void print_tree(struct tree_node *node_p)
{
  if (node_p != NULL)
  {
    print_tree(node_p->left);
    puts(node_p->word);
    print_tree(node_p->right);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
cmpq $0x0, -0x8(%rbp)
je 0x19e9
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rdi
callq 0x19b0
movq -0x8(%rbp), %rax
movq (%rax), %rdi
callq 0x1060
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rdi
callq 0x19b0
addq $0x10, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: lalloc
void *lalloc(size_t n) {
    void *dat = malloc(n);
    if(dat != NULL) {
        bzero(dat, n);
    }
    return dat;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
callq 0x1160
movq %rax, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x138f
movq -0x10(%rbp), %rdi
movq -0x8(%rbp), %rdx
xorl %esi, %esi
callq 0x10e0
movq -0x10(%rbp), %rax
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: statestr
char *statestr(servicestate state) {
    switch(state) {
    case service_status_null:
        return "null";
    case service_status_starting:
        return "starting";
    case service_status_running:
        return "running";
    case service_status_stopping:
        return "stopping";
    case service_status_stopped:
        return "stopped";
    default:
        return "bad";
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edi, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq %rax, -0x18(%rbp)
subq $0x5, %rax
ja 0x1409
movq -0x18(%rbp), %rax
leaq 0x2c45(%rip), %rcx      # 0x4004
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x3188(%rip), %rax      # 0x4557
movq %rax, -0x8(%rbp)
jmp 0x1414
leaq 0x2c40(%rip), %rax      # 0x401c
movq %rax, -0x8(%rbp)
jmp 0x1414
leaq 0x2c3c(%rip), %rax      # 0x4025
movq %rax, -0x8(%rbp)
jmp 0x1414
leaq 0x2c37(%rip), %rax      # 0x402d
movq %rax, -0x8(%rbp)
jmp 0x1414
leaq 0x2c33(%rip), %rax      # 0x4036
movq %rax, -0x8(%rbp)
jmp 0x1414
leaq 0x2c2e(%rip), %rax      # 0x403e
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: setNotify
bool setNotify(struct service* s, struct conn *c) {
    struct conn **onot = s->notify;
    size_t onot_n = s->notify_n;
    size_t nnot_n = onot_n + 1;
    struct conn **nnot = arralloc(struct conn*, nnot_n);
    if(nnot == NULL) {
        return false;
    }
    memcpy(nnot, onot, sizeof(struct notify*) * onot_n);
    nnot[onot_n] = c;
    ref(c);
    free(onot);
    s->notify = nnot;
    s->notify_n++;
    return true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rdi
shlq $0x3, %rdi
callq 0x1360
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
jne 0x1472
movb $0x0, -0x1(%rbp)
jmp 0x14cd
movq -0x38(%rbp), %rdi
movq -0x20(%rbp), %rsi
movq -0x28(%rbp), %rdx
shlq $0x3, %rdx
callq 0x1150
movq -0x18(%rbp), %rdx
movq -0x38(%rbp), %rax
movq -0x28(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
movq -0x18(%rbp), %rax
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
movq -0x20(%rbp), %rdi
callq 0x1030
movq -0x38(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x18(%rax)
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: notify
enum{ notify_fail, notify_success, notify_gone } notify(struct conn *c, struct service* s, struct buf msg) {
    if(c->closed == true) {
        deref(c);   //get rid of reference so the conn can be freed
        return notify_gone;
    }
    byte* ndat = realloc(c->tx.dat, c->tx.len + msg.len);
    if(ndat == NULL) {
        return notify_fail;
    }
    memcpy(ndat + c->tx.len, msg.dat, msg.len);
    c->tx.dat = ndat;
    c->tx.len += msg.len;
    if(c->txoff && (c->tx.len > 0)) {  //tx buffer was just populated
        //enable write in epoll
        struct epoll_event ev = {.events = EPOLLIN | EPOLLOUT, .data = {.ptr = &c->e}};
        if(epoll_ctl(epollfd, EPOLL_CTL_MOD, c->fd, &ev) == -1) {   //failed to enable - close and forget
            fprintf(stderr, "[ERROR] Failed to enable writing on conn %d\n", c->fd);
            close_conn(c);
        } else {
            c->txoff = false;
        }
    }
    return notify_success;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdx, -0x18(%rbp)
movq %rcx, -0x10(%rbp)
movq %rdi, -0x20(%rbp)
movq %rsi, -0x28(%rbp)
movq -0x20(%rbp), %rax
movb 0x18(%rax), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x1, %eax
jne 0x1532
movq -0x20(%rbp), %rcx
movl 0x10(%rcx), %eax
movl %eax, %edx
addl $-0x1, %edx
movl %edx, 0x10(%rcx)
cmpl $0x0, %eax
jne 0x1526
movq -0x20(%rbp), %rdi
callq 0x1030
movl $0x2, -0x4(%rbp)
jmp 0x1616
movq -0x20(%rbp), %rax
movq 0x30(%rax), %rdi
movq -0x20(%rbp), %rax
movq 0x38(%rax), %rsi
addq -0x10(%rbp), %rsi
callq 0x1180
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
jne 0x1562
movl $0x0, -0x4(%rbp)
jmp 0x1616
movq -0x30(%rbp), %rdi
movq -0x20(%rbp), %rax
addq 0x38(%rax), %rdi
movq -0x18(%rbp), %rsi
movq -0x10(%rbp), %rdx
callq 0x1150
movq -0x30(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x30(%rax)
movq -0x10(%rbp), %rcx
movq -0x20(%rbp), %rax
addq 0x38(%rax), %rcx
movq %rcx, 0x38(%rax)
movq -0x20(%rbp), %rax
testb $0x1, 0x19(%rax)
je 0x160f
movq -0x20(%rbp), %rax
cmpq $0x0, 0x38(%rax)
jbe 0x160f
movl $0x5, -0x3c(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x38(%rbp)
movl 0x5b8f(%rip), %edi      # 0x7150
movq -0x20(%rbp), %rax
movl 0x14(%rax), %edx
movl $0x3, %esi
leaq -0x3c(%rbp), %rcx
callq 0x1100
cmpl $-0x1, %eax
jne 0x1605
movq 0x5a16(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
movq -0x20(%rbp), %rax
movl 0x14(%rax), %edx
leaq 0x2a4f(%rip), %rsi      # 0x4042
movb $0x0, %al
callq 0x1140
movq -0x20(%rbp), %rdi
callq 0x1620
jmp 0x160d
movq -0x20(%rbp), %rax
movb $0x0, 0x19(%rax)
jmp 0x160f
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: close_conn
void close_conn(struct conn *c) {   //close a connection
    printf("[INFO] Disconnecting connection %d\n", c->fd);
    if(epoll_ctl(epollfd, EPOLL_CTL_DEL, c->fd, NULL) == -1) {  //not compat before Linux 2.6.9
        fprintf(stderr, "[FATAL] Failed to deregister conn with epoll\n");
        exit(65);
    }
    if(close(c->fd) == -1) {
        fprintf(stderr, "[FATAL] Failed to close fd %d: %s\n", c->fd, strerror(errno));
        exit(65);
    }
    c->closed = true;
    c->fd = -1;
    //wipe rx/tx buffers
    free(c->rx.dat);
    free(c->tx.dat);
    bzero(&c->rx, sizeof(c->rx));
    bzero(&c->tx, sizeof(c->tx));
    deref(c);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movl 0x14(%rax), %esi
leaq 0x2c5e(%rip), %rdi      # 0x4298
movb $0x0, %al
callq 0x10c0
movl 0x5b09(%rip), %edi      # 0x7150
movq -0x8(%rbp), %rax
movl 0x14(%rax), %edx
movl $0x2, %esi
xorl %eax, %eax
movl %eax, %ecx
callq 0x1100
cmpl $-0x1, %eax
jne 0x1683
movq 0x5990(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
leaq 0x2c4a(%rip), %rsi      # 0x42bc
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
movq -0x8(%rbp), %rax
movl 0x14(%rax), %edi
callq 0x10f0
cmpl $-0x1, %eax
jne 0x16da
movq 0x595d(%rip), %rax      # 0x6ff8
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movl 0x14(%rax), %eax
movl %eax, -0xc(%rbp)
callq 0x1040
movl (%rax), %edi
callq 0x1230
movq -0x18(%rbp), %rdi
movl -0xc(%rbp), %edx
movq %rax, %rcx
leaq 0x2c21(%rip), %rsi      # 0x42ea
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
movq -0x8(%rbp), %rax
movb $0x1, 0x18(%rax)
movq -0x8(%rbp), %rax
movl $0xffffffff, 0x14(%rax) # imm = 0xFFFFFFFF
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rdi
callq 0x1030
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rdi
callq 0x1030
movq -0x8(%rbp), %rdi
addq $0x20, %rdi
xorl %esi, %esi
movl $0x10, %edx
callq 0x10e0
movq -0x8(%rbp), %rdi
addq $0x30, %rdi
xorl %esi, %esi
movl $0x10, %edx
callq 0x10e0
movq -0x8(%rbp), %rcx
movl 0x10(%rcx), %eax
movl %eax, %edx
addl $-0x1, %edx
movl %edx, 0x10(%rcx)
cmpl $0x0, %eax
jne 0x174c
movq -0x8(%rbp), %rdi
callq 0x1030
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: findService
struct service* findService(char* name) {
    struct service *s;
    for(s = services.first; s != NULL; s = s->next) {
        if(streq(s->name, name)) {
            return s;
        }
    }
    return s;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq 0x57b5(%rip), %rax      # 0x7158
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
je 0x19dd
movq -0x18(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rsi
callq 0x1130
cmpl $0x0, %eax
jne 0x19cd
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x19e5
jmp 0x19cf
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x18(%rbp)
jmp 0x19a7
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: newService
struct service* newService() {
    struct service* new = alalloc(struct service);
    if(new == NULL) {
        return NULL;
    }
    if(services.first == NULL) {
        services.first = new;
        return new;
    }
    struct service *s, *n;
    for(s = n = services.first; n != NULL; n = n->next) { s = n; }
    s->next = new;
    return new;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl $0x28, %edi
callq 0x1360
movq %rax, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0x1a17
movq $0x0, -0x8(%rbp)
jmp 0x1a76
cmpq $0x0, 0x5739(%rip)      # 0x7158
jne 0x1a36
movq -0x10(%rbp), %rax
movq %rax, 0x572c(%rip)      # 0x7158
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x1a76
movq 0x571b(%rip), %rax      # 0x7158
movq %rax, -0x20(%rbp)
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0x1a62
movq -0x20(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x20(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x20(%rbp)
jmp 0x1a45
movq -0x10(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: rmService
void rmService(char* name) {
    struct service *s, *n;
    for(s = n = services.first; (n != NULL) && (!streq(n->name, name)); n = n->next) { s = n; }
    if(n == NULL) {
        fprintf(stderr, "[FATAL] Service %s does not exist\n", name);
        exit(65);
    }
    s->next = n->next;
    //notifications should already have been dealt with
    free(n->name);
    free(n);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq 0x56c5(%rip), %rax      # 0x7158
movq %rax, -0x18(%rbp)
movq %rax, -0x10(%rbp)
xorl %eax, %eax
cmpq $0x0, -0x18(%rbp)
movb %al, -0x19(%rbp)
je 0x1ac2
movq -0x18(%rbp), %rax
movq (%rax), %rdi
movq -0x8(%rbp), %rsi
callq 0x1130
cmpl $0x0, %eax
sete %al
xorb $-0x1, %al
movb %al, -0x19(%rbp)
movb -0x19(%rbp), %al
testb $0x1, %al
jne 0x1acb
jmp 0x1ae1
movq -0x18(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x18(%rbp)
jmp 0x1a9b
cmpq $0x0, -0x18(%rbp)
jne 0x1b0e
movq 0x5509(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
movq -0x8(%rbp), %rdx
leaq 0x257f(%rip), %rsi      # 0x407c
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x18(%rbp), %rax
movq (%rax), %rdi
callq 0x1030
movq -0x18(%rbp), %rdi
callq 0x1030
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: readBuf
bool readBuf(struct buf *b, int fd) {  //read data from fd into the buffer
    byte dat[1024];
    size_t n = read(fd, dat, 1024);
    if(n < 0) {
        return false;
    } else if(n == 0) {
        return true;
    }
    byte* nd = arralloc(byte, n + b->len);
    if(nd == NULL) {
        return false;
    }
    memcpy(nd, b->dat, b->len);
    memcpy(nd + b->len, dat, n);
    free(b->dat);
    b->dat = nd;
    b->len += n;
    return true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x430, %rsp            # imm = 0x430
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl -0x14(%rbp), %edi
leaq -0x420(%rbp), %rsi
movl $0x400, %edx            # imm = 0x400
callq 0x1110
movq %rax, -0x428(%rbp)
cmpq $0x0, -0x428(%rbp)
jae 0x1b80
movb $0x0, -0x1(%rbp)
jmp 0x1c2e
cmpq $0x0, -0x428(%rbp)
jne 0x1b93
movb $0x1, -0x1(%rbp)
jmp 0x1c2e
jmp 0x1b95
movq -0x428(%rbp), %rdi
movq -0x10(%rbp), %rax
addq 0x8(%rax), %rdi
callq 0x1360
movq %rax, -0x430(%rbp)
cmpq $0x0, -0x430(%rbp)
jne 0x1bc0
movb $0x0, -0x1(%rbp)
jmp 0x1c2e
movq -0x430(%rbp), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdx
callq 0x1150
movq -0x430(%rbp), %rdi
movq -0x10(%rbp), %rax
addq 0x8(%rax), %rdi
leaq -0x420(%rbp), %rsi
movq -0x428(%rbp), %rdx
callq 0x1150
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x1030
movq -0x430(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x428(%rbp), %rcx
movq -0x10(%rbp), %rax
addq 0x8(%rax), %rcx
movq %rcx, 0x8(%rax)
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x430, %rsp            # imm = 0x430
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: writeBuf
bool writeBuf(struct buf* b, int fd) { //write data from buffer into fd
    size_t n = write(fd, b->dat, b->len);
    if(n < 1) {
        return false;
    }
    byte* nd = arralloc(byte, n - b->len);
    if(nd == NULL) {
        return false;
    }
    memcpy(nd, b->dat + n, b->len - n);
    free(b->dat);
    b->dat = nd;
    b->len -= n;
    return true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl -0x14(%rbp), %edi
movq -0x10(%rbp), %rax
movq (%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdx
callq 0x1080
movq %rax, -0x20(%rbp)
cmpq $0x1, -0x20(%rbp)
jae 0x1c77
movb $0x0, -0x1(%rbp)
jmp 0x1ce7
movq -0x20(%rbp), %rdi
movq -0x10(%rbp), %rax
subq 0x8(%rax), %rdi
callq 0x1360
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0x1c99
movb $0x0, -0x1(%rbp)
jmp 0x1ce7
movq -0x28(%rbp), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rsi
addq -0x20(%rbp), %rsi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdx
subq -0x20(%rbp), %rdx
callq 0x1150
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x1030
movq -0x28(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x20(%rbp), %rdx
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rcx
subq %rdx, %rcx
movq %rcx, 0x8(%rax)
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: set_noblock
void set_noblock(int fd) {
    int flags = fcntl(fd, F_GETFL, 0);
    if(flags < 0) {
        goto fail;
    }
    flags |= O_NONBLOCK;
    if(fcntl(fd, F_SETFL, flags) == -1) {
        goto fail;
    }
    return;
fail:
    fprintf(stderr, "[FATAL] Failed to SET O_NONBLOCK on %d: %s\n", fd, strerror(errno));
    exit(65);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0x4(%rbp)
movl -0x4(%rbp), %edi
movl $0x3, %esi
xorl %edx, %edx
movb $0x0, %al
callq 0x1070
movl %eax, -0x8(%rbp)
cmpl $0x0, -0x8(%rbp)
jge 0x1d27
jmp 0x1d51
movl -0x8(%rbp), %eax
orl $0x800, %eax            # imm = 0x800
movl %eax, -0x8(%rbp)
movl -0x4(%rbp), %edi
movl -0x8(%rbp), %edx
movl $0x4, %esi
movb $0x0, %al
callq 0x1070
cmpl $-0x1, %eax
jne 0x1d4b
jmp 0x1d51
addq $0x20, %rsp
popq %rbp
retq
movq 0x52a0(%rip), %rax      # 0x6ff8
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movl -0x4(%rbp), %eax
movl %eax, -0xc(%rbp)
callq 0x1040
movl (%rax), %edi
callq 0x1230
movq -0x18(%rbp), %rdi
movl -0xc(%rbp), %edx
movq %rax, %rcx
leaq 0x231d(%rip), %rsi      # 0x409f
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: addSock
void addSock(int fd) {  //add a socket to epoll
    printf("Sock: %d\n", fd);
    if(listen(fd, backlog) == -1) {
        fprintf(stderr, "[FATAL] Failed to run listen on %d: %s\n", fd, strerror(errno));
        exit(65);
    }
    struct epolldat *d = alalloc(struct epolldat);
    if(d == NULL) {
        fprintf(stderr, "[FATAL] Failed to allocate epolldat for %d: %s\n", fd, strerror(errno));
        exit(65);
    }
    d->typecode = epoll_socket;
    d->sockfd = fd;
    //register with epoll
    struct epoll_event ev = {.events = EPOLLIN, .data = {.ptr = d}};
    if(epoll_ctl(epollfd, EPOLL_CTL_ADD, fd, &ev) == -1) {
        fprintf(stderr, "[FATAL] Failed to register with epoll: %s\n", strerror(errno));
        exit(65);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movl %edi, -0x4(%rbp)
movl -0x4(%rbp), %esi
leaq 0x2316(%rip), %rdi      # 0x40cb
movb $0x0, %al
callq 0x10c0
movl -0x4(%rbp), %edi
movl 0x537b(%rip), %esi      # 0x7140
callq 0x1170
cmpl $-0x1, %eax
jne 0x1e11
movq 0x5222(%rip), %rax      # 0x6ff8
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movl -0x4(%rbp), %eax
movl %eax, -0x20(%rbp)
callq 0x1040
movl (%rax), %edi
callq 0x1230
movq -0x28(%rbp), %rdi
movl -0x20(%rbp), %edx
movq %rax, %rcx
leaq 0x22d5(%rip), %rsi      # 0x40d5
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
movl $0x10, %edi
callq 0x1360
movq %rax, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0x1e68
movq 0x51cb(%rip), %rax      # 0x6ff8
movq (%rax), %rax
movq %rax, -0x38(%rbp)
movl -0x4(%rbp), %eax
movl %eax, -0x2c(%rbp)
callq 0x1040
movl (%rax), %edi
callq 0x1230
movq -0x38(%rbp), %rdi
movl -0x2c(%rbp), %edx
movq %rax, %rcx
leaq 0x22a6(%rip), %rsi      # 0x40fd
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
movq -0x10(%rbp), %rax
movl $0x1, (%rax)
movl -0x4(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x8(%rax)
movl $0x1, -0x1c(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x18(%rbp)
movl 0x52bf(%rip), %edi      # 0x7150
movl -0x4(%rbp), %edx
movl $0x1, %esi
leaq -0x1c(%rbp), %rcx
callq 0x1100
cmpl $-0x1, %eax
jne 0x1ee0
movq 0x514a(%rip), %rax      # 0x6ff8
movq (%rax), %rax
movq %rax, -0x40(%rbp)
callq 0x1040
movl (%rax), %edi
callq 0x1230
movq -0x40(%rbp), %rdi
movq %rax, %rdx
leaq 0x225e(%rip), %rsi      # 0x412d
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: handle_epoll
void handle_epoll(struct epoll_event ev) {  //handle an epoll event
    struct epolldat d = *((struct epolldat*)ev.data.ptr);
    switch(d.typecode) {
    case epoll_conn:
        handle_conn(d.c, ev.events);
        break;
    case epoll_socket:
        handle_socket(d.sockfd, ev.events);
        break;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
leaq 0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movq 0x4(%rax), %rax
movups (%rax), %xmm0
movaps %xmm0, -0x10(%rbp)
movl -0x10(%rbp), %eax
movl %eax, -0x14(%rbp)
testl %eax, %eax
je 0x1f21
jmp 0x1f17
movl -0x14(%rbp), %eax
subl $0x1, %eax
je 0x1f32
jmp 0x1f40
movq -0x20(%rbp), %rax
movq -0x8(%rbp), %rdi
movl (%rax), %esi
callq 0x1f50
jmp 0x1f40
movq -0x20(%rbp), %rax
movl -0x8(%rbp), %edi
movl (%rax), %esi
callq 0x21d0
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: handle_socket
void handle_socket(int sockfd, uint32_t events) {
    if(EPOLL_MODE(events, EPOLLIN)) {
        int fd = accept(sockfd, NULL, NULL);
        if(fd == -1) {
            fprintf(stderr, "[ERROR] Failed to accept connection: %s\n", strerror(errno));
            return;
        }
        struct conn *c = newConn(fd);
        if(c == NULL) {
            fprintf(stderr, "[ERROR] Failed to create conn with fd %d\n", fd);
            if(close(fd) == -1) {
                fprintf(stderr, "[FATAL] Failed to close fd %d\n", fd);
                exit(65);
            }
            return;
        }
    } else if(EPOLL_MODE(events, EPOLLPRI)) {
        fprintf(stderr, "[FATAL] Recieved EPOLLPRI on socket fd %d\n", sockfd);
        exit(65);
    } else if(EPOLL_MODE(events, EPOLLERR)) {
        fprintf(stderr, "[FATAL] Recieved EPOLLERR on socket fd %d\n", sockfd);
        exit(65);
    } else {
        fprintf(stderr, "[FATAL] Recieved unrecognized epoll event %d on socket fd %d\n", events, sockfd);
        exit(65);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movl %edi, -0x4(%rbp)
movl %esi, -0x8(%rbp)
movl -0x8(%rbp), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x22ac
movl -0x4(%rbp), %edi
movq $0x0, -0x18(%rbp)
movq -0x18(%rbp), %rsi
xorl %eax, %eax
movl %eax, %edx
callq 0x11e0
movl %eax, -0xc(%rbp)
cmpl $-0x1, -0xc(%rbp)
jne 0x2242
movq 0x4de3(%rip), %rax      # 0x6ff8
movq (%rax), %rax
movq %rax, -0x28(%rbp)
callq 0x1040
movl (%rax), %edi
callq 0x1230
movq -0x28(%rbp), %rdi
movq %rax, %rdx
leaq 0x1f5c(%rip), %rsi      # 0x4192
movb $0x0, %al
callq 0x1140
jmp 0x2334
movl -0xc(%rbp), %edi
callq 0x2400
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0x22a7
movq 0x4d9c(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
movl -0xc(%rbp), %edx
leaq 0x1f52(%rip), %rsi      # 0x41bb
movb $0x0, %al
callq 0x1140
movl -0xc(%rbp), %edi
callq 0x10f0
cmpl $-0x1, %eax
jne 0x22a2
movq 0x4d74(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
movl -0xc(%rbp), %edx
leaq 0x1f54(%rip), %rsi      # 0x41e5
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
jmp 0x2334
jmp 0x2334
movl -0x8(%rbp), %eax
andl $0x2, %eax
cmpl $0x0, %eax
je 0x22dc
movq 0x4d3a(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
movl -0x4(%rbp), %edx
leaq 0x1f39(%rip), %rsi      # 0x4204
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
movl -0x8(%rbp), %eax
andl $0x8, %eax
cmpl $0x0, %eax
je 0x230c
movq 0x4d0a(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
movl -0x4(%rbp), %edx
leaq 0x1f34(%rip), %rsi      # 0x422f
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
movq 0x4ce5(%rip), %rax      # 0x6ff8
movq (%rax), %rdi
movl -0x8(%rbp), %edx
movl -0x4(%rbp), %ecx
leaq 0x1f37(%rip), %rsi      # 0x425a
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: epoll_cycle
void epoll_cycle() {    //run epoll wait with a timeout and handle the events
    struct epoll_event ev[4];
    int n = epoll_wait(epollfd, ev, 4, 50);
    if(n == -1) {
        fprintf(stderr, "[FATAL] epoll_wait failed: %s\n", strerror(errno));
        exit(65);
        return;
    }
    for(int i = 0; i < n; i++) {
        handle_epoll(ev[i]);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movl 0x4e02(%rip), %edi      # 0x7150
leaq -0x30(%rbp), %rsi
movl $0x4, %edx
movl $0x32, %ecx
callq 0x11a0
movl %eax, -0x34(%rbp)
cmpl $-0x1, -0x34(%rbp)
jne 0x23a3
movq 0x4c87(%rip), %rax      # 0x6ff8
movq (%rax), %rax
movq %rax, -0x50(%rbp)
callq 0x1040
movl (%rax), %edi
callq 0x1230
movq -0x50(%rbp), %rdi
movq %rax, %rdx
leaq 0x1dc6(%rip), %rsi      # 0x4158
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
movl $0x0, -0x38(%rbp)
movl -0x38(%rbp), %eax
cmpl -0x34(%rbp), %eax
jge 0x23f0
movslq -0x38(%rbp), %rcx
leaq -0x30(%rbp), %rax
imulq $0xc, %rcx, %rcx
addq %rcx, %rax
movq (%rax), %rcx
movq %rcx, -0x48(%rbp)
movl 0x8(%rax), %eax
movl %eax, -0x40(%rbp)
leaq -0x48(%rbp), %rax
movq (%rax), %rcx
movq %rcx, (%rsp)
movl 0x8(%rax), %eax
movl %eax, 0x8(%rsp)
callq 0x1ef0
movl -0x38(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x38(%rbp)
jmp 0x23aa
addq $0x60, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: newConn
struct conn *newConn(int fd) { //create a new conn with fd
    printf("[INFO] New connection: %d\n", fd);
    //set up conn data
    struct conn *c = alalloc(struct conn);
    if(c == NULL) {
        return NULL;
    }
    c->e.typecode = epoll_conn;
    c->e.c = c;
    c->fd = fd;
    c->txoff = true;
    //register with epoll
    struct epoll_event ev = {.events = EPOLLIN, .data = {.ptr = &c->e}};
    if(epoll_ctl(epollfd, EPOLL_CTL_ADD, fd, &ev) == -1) {
        fprintf(stderr, "[FATAL] Failed to register with epoll: %s\n", strerror(errno));
        exit(65);
    }
    ref(c); //referenced by epoll
    //tell read and write not to block
    set_noblock(fd);
    return c;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movl %edi, -0xc(%rbp)
movl -0xc(%rbp), %esi
leaq 0x1d62(%rip), %rdi      # 0x4177
movb $0x0, %al
callq 0x10c0
movl $0x40, %edi
callq 0x1360
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x243e
movq $0x0, -0x8(%rbp)
jmp 0x24e7
movq -0x18(%rbp), %rax
movl $0x0, (%rax)
movq -0x18(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x8(%rax)
movl -0xc(%rbp), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x14(%rax)
movq -0x18(%rbp), %rax
movb $0x1, 0x19(%rax)
movl $0x1, -0x24(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x20(%rbp)
movl 0x4cd5(%rip), %edi      # 0x7150
movl -0xc(%rbp), %edx
movl $0x1, %esi
leaq -0x24(%rbp), %rcx
callq 0x1100
cmpl $-0x1, %eax
jne 0x24ca
movq 0x4b60(%rip), %rax      # 0x6ff8
movq (%rax), %rax
movq %rax, -0x30(%rbp)
callq 0x1040
movl (%rax), %edi
callq 0x1230
movq -0x30(%rbp), %rdi
movq %rax, %rdx
leaq 0x1c74(%rip), %rsi      # 0x412d
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
movq -0x18(%rbp), %rax
movl 0x10(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x10(%rax)
movl -0xc(%rbp), %edi
callq 0x1d00
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: conn_has_cmd
bool conn_has_cmd(struct conn *c) { //is there is a full command in the buffer?
    if(c->closed) { return false; }
    struct buf b = c->rx;
    for(size_t i = 0; i < b.len; i++) {
        switch(b.dat[i]) {
        case '\n':
            b.dat[i] = '\0';
        case '\0':
            return true;
        }
    }
    return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
testb $0x1, 0x18(%rax)
je 0x2518
movb $0x0, -0x1(%rbp)
jmp 0x2583
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rcx
movq %rcx, -0x20(%rbp)
movq 0x28(%rax), %rax
movq %rax, -0x18(%rbp)
movq $0x0, -0x28(%rbp)
movq -0x28(%rbp), %rax
cmpq -0x18(%rbp), %rax
jae 0x257f
movq -0x20(%rbp), %rax
movq -0x28(%rbp), %rcx
movzbl (%rax,%rcx), %eax
movl %eax, -0x2c(%rbp)
testl %eax, %eax
je 0x2569
jmp 0x2553
movl -0x2c(%rbp), %eax
subl $0xa, %eax
jne 0x256f
jmp 0x255d
movq -0x20(%rbp), %rax
movq -0x28(%rbp), %rcx
movb $0x0, (%rax,%rcx)
movb $0x1, -0x1(%rbp)
jmp 0x2583
jmp 0x2571
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x2534
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: fexec
bool fexec(int argc, char **argv) { //forks and exec's
    switch(fork()) {
    case -1:    //failure
        return false;
    case 0:;    //child
        char *args[argc + 1];
        for(int i = 0; i < argc; i++) {
            args[i] = argv[i];
        }
        args[argc] = NULL;
        if(execvpe(args[0], args, environ) == -1) {
            fprintf(stderr, "[FATAL] exec failed: %s\n", strerror(errno));
            exit(65);
        }
    }
    return true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
callq 0x1240
movl %eax, %ecx
movl %ecx, -0x28(%rbp)
subl $-0x1, %eax
je 0x282c
jmp 0x2820
movl -0x28(%rbp), %eax
testl %eax, %eax
je 0x2835
jmp 0x28f7
movb $0x0, -0x1(%rbp)
jmp 0x28fb
movl -0x8(%rbp), %eax
incl %eax
movq %rsp, %rcx
movq %rcx, -0x18(%rbp)
leaq 0xf(,%rax,8), %rdx
andq $-0x10, %rdx
movq %rsp, %rcx
subq %rdx, %rcx
movq %rcx, -0x30(%rbp)
movq %rcx, %rsp
movq %rax, -0x20(%rbp)
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl -0x8(%rbp), %eax
jge 0x2890
movq -0x30(%rbp), %rax
movq -0x10(%rbp), %rcx
movslq -0x24(%rbp), %rdx
movq (%rcx,%rdx,8), %rdx
movslq -0x24(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x2865
movq -0x30(%rbp), %rsi
movslq -0x8(%rbp), %rax
movq $0x0, (%rsi,%rax,8)
movq (%rsi), %rdi
movq 0x4736(%rip), %rax      # 0x6fe0
movq (%rax), %rdx
callq 0x10b0
cmpl $-0x1, %eax
jne 0x28f0
movq 0x473a(%rip), %rax      # 0x6ff8
movq (%rax), %rax
movq %rax, -0x38(%rbp)
callq 0x1040
movl (%rax), %edi
callq 0x1230
movq -0x38(%rbp), %rdi
movq %rax, %rdx
leaq 0x1b04(%rip), %rsi      # 0x43e3
movb $0x0, %al
callq 0x1140
movl $0x41, %edi
callq 0x1210
movq -0x18(%rbp), %rax
movq %rax, %rsp
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
movq %rbp, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/panux[P]linit/src/linitd.c
// Function: hasSpace
bool hasSpace(char *str) {
    for(; *str != '\0'; str++) {
        if(*str == ' ') {
            return true;
        }
    }
    return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
je 0x29c6
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x20, %eax
jne 0x29b6
movb $0x1, -0x1(%rbp)
jmp 0x29ca
jmp 0x29b8
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x2998
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pavel-demin[P]ft8d-c/pffft.c
// Function: pffft_aligned_malloc
void *pffft_aligned_malloc(size_t nb_bytes) {
  void *p, *p0 = malloc(nb_bytes + MALLOC_V4SF_ALIGNMENT);
  if (!p0) return (void *) 0;
  p = (void *) (((size_t) p0 + MALLOC_V4SF_ALIGNMENT) & (~((size_t) (MALLOC_V4SF_ALIGNMENT-1))));
  *((void **) p - 1) = p0;
  return p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
addq $0x40, %rdi
callq 0x1100
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0x20be
movq $0x0, -0x8(%rbp)
jmp 0x20e2
movq -0x20(%rbp), %rax
addq $0x40, %rax
andq $-0x40, %rax
movq %rax, -0x18(%rbp)
movq -0x20(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, -0x8(%rax)
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/pavel-demin[P]ft8d-c/pffft.c
// Function: decompose
static int decompose(int n, int *ifac, const int *ntryh) {
  int nl = n, nf = 0, i, j = 0;
  for (j=0; ntryh[j]; ++j) {
    int ntry = ntryh[j];
    while (nl != 1) {
      int nq = nl / ntry;
      int nr = nl - ntry * nq;
      if (nr == 0) {
        ifac[2+nf++] = ntry;
        nl = nq;
        if (ntry == 2 && nf != 1) {
          for (i = 2; i <= nf; ++i) {
            int ib = nf - i + 2;
            ifac[ib + 1] = ifac[ib];
          }
          ifac[2] = 2;
        }
      } else break;
    }
  }
  ifac[0] = n;
  ifac[1] = nf;
  return nf;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl -0x4(%rbp), %eax
movl %eax, -0x1c(%rbp)
movl $0x0, -0x20(%rbp)
movl $0x0, -0x28(%rbp)
movl $0x0, -0x28(%rbp)
movq -0x18(%rbp), %rax
movslq -0x28(%rbp), %rcx
cmpl $0x0, (%rax,%rcx,4)
je 0x2435
movq -0x18(%rbp), %rax
movslq -0x28(%rbp), %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x2c(%rbp)
cmpl $0x1, -0x1c(%rbp)
je 0x2425
movl -0x1c(%rbp), %eax
cltd
idivl -0x2c(%rbp)
movl %eax, -0x30(%rbp)
movl -0x1c(%rbp), %eax
movl -0x2c(%rbp), %ecx
imull -0x30(%rbp), %ecx
subl %ecx, %eax
movl %eax, -0x34(%rbp)
cmpl $0x0, -0x34(%rbp)
jne 0x241e
movl -0x2c(%rbp), %edx
movq -0x10(%rbp), %rax
movl -0x20(%rbp), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, -0x20(%rbp)
addl $0x2, %ecx
movslq %ecx, %rcx
movl %edx, (%rax,%rcx,4)
movl -0x30(%rbp), %eax
movl %eax, -0x1c(%rbp)
cmpl $0x2, -0x2c(%rbp)
jne 0x241c
cmpl $0x1, -0x20(%rbp)
je 0x241c
movl $0x2, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl -0x20(%rbp), %eax
jg 0x2411
movl -0x20(%rbp), %eax
subl -0x24(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movslq -0x38(%rbp), %rcx
movl (%rax,%rcx,4), %edx
movq -0x10(%rbp), %rax
movl -0x38(%rbp), %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movl %edx, (%rax,%rcx,4)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x23d7
movq -0x10(%rbp), %rax
movl $0x2, 0x8(%rax)
jmp 0x2420
jmp 0x2425
jmp 0x237a
jmp 0x2427
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
jmp 0x235a
movl -0x4(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, (%rax)
movl -0x20(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x4(%rax)
movl -0x20(%rbp), %eax
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/pavel-demin[P]ft8d-c/pffft.c
// Function: rffti1_ps
static void rffti1_ps(int n, float *wa, int *ifac)
{
  static const int ntryh[] = { 4,2,3,5,0 };
  int k1, j, ii;

  int nf = decompose(n,ifac,ntryh);
  float argh = (2*M_PI) / n;
  int is = 0;
  int nfm1 = nf - 1;
  int l1 = 1;
  for (k1 = 1; k1 <= nfm1; k1++) {
    int ip = ifac[k1 + 1];
    int ld = 0;
    int l2 = l1*ip;
    int ido = n / l2;
    int ipm = ip - 1;
    for (j = 1; j <= ipm; ++j) {
      float argld;
      int i = is, fi=0;
      ld += l1;
      argld = ld*argh;
      for (ii = 3; ii <= ido; ii += 2) {
        i += 2;
        fi += 1;
        wa[i - 2] = cos(fi*argld);
        wa[i - 1] = sin(fi*argld);
      }
      is += ido;
    }
    l1 = l2;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl -0x4(%rbp), %edi
movq -0x18(%rbp), %rsi
leaq 0x11baf(%rip), %rdx     # 0x18120
callq 0x2330
movl %eax, -0x28(%rbp)
cvtsi2sdl -0x4(%rbp), %xmm1
movsd 0x11afa(%rip), %xmm0    # 0x18080
divsd %xmm1, %xmm0
cvtsd2ss %xmm0, %xmm0
movss %xmm0, -0x2c(%rbp)
movl $0x0, -0x30(%rbp)
movl -0x28(%rbp), %eax
subl $0x1, %eax
movl %eax, -0x34(%rbp)
movl $0x1, -0x38(%rbp)
movl $0x1, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
cmpl -0x34(%rbp), %eax
jg 0x66d5
movq -0x18(%rbp), %rax
movl -0x1c(%rbp), %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movl (%rax,%rcx,4), %eax
movl %eax, -0x3c(%rbp)
movl $0x0, -0x40(%rbp)
movl -0x38(%rbp), %eax
imull -0x3c(%rbp), %eax
movl %eax, -0x44(%rbp)
movl -0x4(%rbp), %eax
cltd
idivl -0x44(%rbp)
movl %eax, -0x48(%rbp)
movl -0x3c(%rbp), %eax
subl $0x1, %eax
movl %eax, -0x4c(%rbp)
movl $0x1, -0x20(%rbp)
movl -0x20(%rbp), %eax
cmpl -0x4c(%rbp), %eax
jg 0x66c1
movl -0x30(%rbp), %eax
movl %eax, -0x54(%rbp)
movl $0x0, -0x58(%rbp)
movl -0x38(%rbp), %eax
addl -0x40(%rbp), %eax
movl %eax, -0x40(%rbp)
cvtsi2ssl -0x40(%rbp), %xmm0
mulss -0x2c(%rbp), %xmm0
movss %xmm0, -0x50(%rbp)
movl $0x3, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl -0x48(%rbp), %eax
jg 0x66aa
movl -0x54(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x54(%rbp)
movl -0x58(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x58(%rbp)
cvtsi2ssl -0x58(%rbp), %xmm0
mulss -0x50(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
callq 0x10b0
cvtsd2ss %xmm0, %xmm0
movq -0x10(%rbp), %rax
movl -0x54(%rbp), %ecx
subl $0x2, %ecx
movslq %ecx, %rcx
movss %xmm0, (%rax,%rcx,4)
cvtsi2ssl -0x58(%rbp), %xmm0
mulss -0x50(%rbp), %xmm0
cvtss2sd %xmm0, %xmm0
callq 0x1130
cvtsd2ss %xmm0, %xmm0
movq -0x10(%rbp), %rax
movl -0x54(%rbp), %ecx
subl $0x1, %ecx
movslq %ecx, %rcx
movss %xmm0, (%rax,%rcx,4)
movl -0x24(%rbp), %eax
addl $0x2, %eax
movl %eax, -0x24(%rbp)
jmp 0x6633
movl -0x48(%rbp), %eax
addl -0x30(%rbp), %eax
movl %eax, -0x30(%rbp)
movl -0x20(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
jmp 0x65fb
movl -0x44(%rbp), %eax
movl %eax, -0x38(%rbp)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x65b1
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/pavel-demin[P]ft8d-c/pffft.c
// Function: reversed_copy
static void reversed_copy(int N, const v4sf *in, int in_stride, v4sf *out) {
  v4sf g0, g1;
  int k;
  INTERLEAVE2(in[0], in[1], g0, g1); in += in_stride;

  *--out = VSWAPHL(g0, g1); // [g0l, g0h], [g1l g1h] -> [g1l, g0h]
  for (k=1; k < N; ++k) {
    v4sf h0, h1;
    INTERLEAVE2(in[0], in[1], h0, h1); in += in_stride;
    *--out = VSWAPHL(g1, h0);
    *--out = VSWAPHL(h0, h1);
    g1 = h1;
  }
  *--out = VSWAPHL(g1, g0);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movl %edi, -0x84(%rbp)
movq %rsi, -0x90(%rbp)
movl %edx, -0x94(%rbp)
movq %rcx, -0xa0(%rbp)
movq -0x90(%rbp), %rax
movaps (%rax), %xmm1
movaps 0x10(%rax), %xmm0
movaps %xmm1, -0x50(%rbp)
movaps %xmm0, -0x60(%rbp)
movaps -0x50(%rbp), %xmm0
movaps -0x60(%rbp), %xmm1
unpcklps %xmm1, %xmm0            # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movaps %xmm0, -0xe0(%rbp)
movq -0x90(%rbp), %rax
movaps (%rax), %xmm1
movaps 0x10(%rax), %xmm0
movaps %xmm1, -0x10(%rbp)
movaps %xmm0, -0x20(%rbp)
movaps -0x10(%rbp), %xmm0
movaps -0x20(%rbp), %xmm1
unpckhps %xmm1, %xmm0            # xmm0 = xmm0[2],xmm1[2],xmm0[3],xmm1[3]
movaps %xmm0, -0xc0(%rbp)
movaps -0xe0(%rbp), %xmm0
movaps %xmm0, -0xb0(%rbp)
movslq -0x94(%rbp), %rcx
movq -0x90(%rbp), %rax
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x90(%rbp)
movapd -0xc0(%rbp), %xmm1
movapd -0xb0(%rbp), %xmm0
movsd %xmm1, %xmm0            # xmm0 = xmm1[0],xmm0[1]
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $-0x10, %rcx
movq %rcx, -0xa0(%rbp)
movaps %xmm0, -0x10(%rax)
movl $0x1, -0xc4(%rbp)
movl -0xc4(%rbp), %eax
cmpl -0x84(%rbp), %eax
jge 0x700f
movq -0x90(%rbp), %rax
movaps (%rax), %xmm1
movaps 0x10(%rax), %xmm0
movaps %xmm1, -0x70(%rbp)
movaps %xmm0, -0x80(%rbp)
movaps -0x70(%rbp), %xmm0
movaps -0x80(%rbp), %xmm1
unpcklps %xmm1, %xmm0            # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movaps %xmm0, -0x110(%rbp)
movq -0x90(%rbp), %rax
movaps (%rax), %xmm1
movaps 0x10(%rax), %xmm0
movaps %xmm1, -0x30(%rbp)
movaps %xmm0, -0x40(%rbp)
movaps -0x30(%rbp), %xmm0
movaps -0x40(%rbp), %xmm1
unpckhps %xmm1, %xmm0            # xmm0 = xmm0[2],xmm1[2],xmm0[3],xmm1[3]
movaps %xmm0, -0x100(%rbp)
movaps -0x110(%rbp), %xmm0
movaps %xmm0, -0xf0(%rbp)
movslq -0x94(%rbp), %rcx
movq -0x90(%rbp), %rax
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x90(%rbp)
movapd -0xf0(%rbp), %xmm1
movapd -0xc0(%rbp), %xmm0
movsd %xmm1, %xmm0            # xmm0 = xmm1[0],xmm0[1]
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $-0x10, %rcx
movq %rcx, -0xa0(%rbp)
movapd %xmm0, -0x10(%rax)
movapd -0x100(%rbp), %xmm1
movapd -0xf0(%rbp), %xmm0
movsd %xmm1, %xmm0            # xmm0 = xmm1[0],xmm0[1]
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $-0x10, %rcx
movq %rcx, -0xa0(%rbp)
movaps %xmm0, -0x10(%rax)
movaps -0x100(%rbp), %xmm0
movaps %xmm0, -0xc0(%rbp)
movl -0xc4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc4(%rbp)
jmp 0x6f06
movapd -0xb0(%rbp), %xmm1
movapd -0xc0(%rbp), %xmm0
movsd %xmm1, %xmm0            # xmm0 = xmm1[0],xmm0[1]
movq -0xa0(%rbp), %rax
movq %rax, %rcx
addq $-0x10, %rcx
movq %rcx, -0xa0(%rbp)
movaps %xmm0, -0x10(%rax)
addq $0x90, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)