LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: next_option
static const char *next_option(const char *list, struct vec *val,
                               struct vec *eq_val) {
  if (list == NULL || *list == '\0') {
    /* End of the list */
    list = NULL;
  } else {
    val->ptr = list;
    if ((list = strchr(val->ptr, ',')) != NULL) {
      /* Comma found. Store length and shift the list ptr */
      val->len = list - val->ptr;
      list++;
    } else {
      /* This value is the last one */
      list = val->ptr + strlen(val->ptr);
      val->len = list - val->ptr;
    }

    if (eq_val != NULL) {
      /*
       * Value has form "x=y", adjust pointers and lengths
       * so that val points to "x", and eq_val points to "y".
       */
      eq_val->len = 0;
      eq_val->ptr = (const char *) memchr(val->ptr, '=', val->len);
      if (eq_val->ptr != NULL) {
        eq_val->ptr++;  /* Skip over '=' character */
        eq_val->len = val->ptr + val->len - eq_val->ptr;
        val->len = (eq_val->ptr - val->ptr) - 1;
      }
    }
  }

  return list;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
testq %rdi, %rdi
je 0x11d4a
movq %rdi, %r12
cmpb $0x0, (%rdi)
je 0x11d4a
movq %rdx, %r14
movq %rsi, %rbx
movq %r12, (%rsi)
movq %r12, %rdi
movl $0x2c, %esi
callq 0x51e0
testq %rax, %rax
je 0x11d4f
movq %rax, %r15
subq %r12, %rax
incq %r15
jmp 0x11d5d
xorl %r15d, %r15d
jmp 0x11dab
movq %r12, %rdi
callq 0x5210
movq %rax, %r15
addq %r12, %r15
movq %rax, 0x8(%rbx)
testq %r14, %r14
je 0x11dab
movq $0x0, 0x8(%r14)
movq 0x8(%rbx), %r13
movq %r12, %rdi
movl $0x3d, %esi
movq %r13, %rdx
callq 0x5540
movq %rax, (%r14)
testq %rax, %rax
je 0x11dab
leaq 0x1(%rax), %rcx
movq %rcx, (%r14)
movq (%rbx), %rdx
addq %rdx, %r13
subq %rcx, %r13
movq %r13, 0x8(%r14)
notq %rdx
addq %rdx, %rax
incq %rax
movq %rax, 0x8(%rbx)
movq %r15, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: close_all_listening_sockets
static void close_all_listening_sockets(struct mg_context *ctx) {
  struct socket *sp, *tmp;
  for (sp = ctx->listening_sockets; sp != NULL; sp = tmp) {
    tmp = sp->next;
    (void) closesocket(sp->sock);
    free(sp);
  }
}

// Assembly:
testq %rdi, %rdi
je 0x11de6
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rbx), %r14
movl 0x8(%rbx), %edi
callq 0x59c0
movq %rbx, %rdi
callq 0x55d0
movq %r14, %rbx
testq %r14, %r14
jne 0x11dc4
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: close_connection
static void close_connection(struct mg_connection *conn) {
  if (conn->ssl) {
    SSL_free(conn->ssl);
    conn->ssl = NULL;
  }

  if (conn->client.sock != INVALID_SOCKET) {
    close_socket_gracefully(conn->client.sock);
  }
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x2008, %rsp           # imm = 0x2008
movq %rdi, %rbx
movq 0x460(%rdi), %rdi
testq %rdi, %rdi
je 0x12094
callq *0xa75f(%rip)           # 0x1c7e8
movq $0x0, 0x460(%rbx)
movl 0x470(%rbx), %ebx
cmpl $-0x1, %ebx
je 0x120ef
movl %ebx, %edi
movl $0x1, %esi
callq 0x5680
movl %ebx, %edi
movl $0x3, %esi
xorl %edx, %edx
xorl %eax, %eax
callq 0x5290
orl $0x800, %eax            # imm = 0x800
movl %ebx, %edi
movl $0x4, %esi
movl %eax, %edx
xorl %eax, %eax
callq 0x5290
movq %rsp, %r14
movl $0x2000, %edx           # imm = 0x2000
movl %ebx, %edi
movq %r14, %rsi
xorl %ecx, %ecx
callq 0x5180
testl %eax, %eax
jg 0x120d3
movl %ebx, %edi
callq 0x59c0
addq $0x2008, %rsp           # imm = 0x2008
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: get_request_len
static int get_request_len(const char *buf, int buflen) {
  const char *s, *e;
  int len = 0;

  DEBUG_TRACE(("buf: %p, len: %d", buf, buflen));
  for (s = buf, e = s + buflen - 1; len <= 0 && s < e; s++)
    // Control characters are not allowed but >=128 is.
    if (!isprint(* (const unsigned char *) s) && *s != '\r' &&
        *s != '\n' && * (const unsigned char *) s < 128) {
      len = -1;
    } else if (s[0] == '\n' && s[1] == '\n') {
      len = (int) (s - buf) + 2;
    } else if (s[0] == '\n' && &s[1] < e &&
        s[1] == '\r' && s[2] == '\n') {
      len = (int) (s - buf) + 3;
    }

  return len;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movslq %esi, %rax
leaq (%rdi,%rax), %r14
decq %r14
xorl %eax, %eax
cmpq %rdi, %r14
jbe 0x121a6
movq %rdi, %rbx
callq 0x5520
movq (%rax), %rcx
leaq 0x1(%rbx), %rdx
xorl %r8d, %r8d
movl $0x3, %esi
movq %rbx, %rdi
movzbl -0x1(%rdx), %r9d
movb 0x1(%rcx,%r9,2), %al
andb $0x40, %al
cmpb $0x1, %al
movl $0x0, %eax
sbbl %eax, %eax
orl %r8d, %eax
cmpb $0xd, %r9b
cmovel %r8d, %eax
testb %r9b, %r9b
cmovsl %r8d, %eax
cmpb $0xa, %r9b
cmovel %r8d, %eax
jne 0x1218e
movb (%rdx), %al
cmpb $0xa, %al
jne 0x1216d
movl %edi, %eax
subl %ebx, %eax
addl $0x2, %eax
jmp 0x1218e
cmpq %r14, %rdx
setae %r9b
cmpb $0xd, %al
setne %al
orb %r9b, %al
jne 0x1218b
cmpb $0xa, 0x1(%rdx)
movl %r8d, %eax
jne 0x1218e
movl %esi, %eax
jmp 0x1218e
movl %r8d, %eax
testl %eax, %eax
jg 0x121a6
incq %rdi
leaq 0x1(%rdx), %r9
incl %esi
movl %eax, %r8d
cmpq %r14, %rdx
movq %r9, %rdx
jb 0x1212d
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: read_request
static int read_request(FILE *fp, SOCKET sock, SSL *ssl, char *buf, int bufsiz,
                        int *nread) {
  int n, request_len;

  request_len = 0;
  while (*nread < bufsiz && request_len == 0) {
    n = pull(fp, sock, ssl, buf + *nread, bufsiz - *nread);
    if (n <= 0) {
      break;
    } else {
      *nread += n;
      request_len = get_request_len(buf, *nread);
    }
  }

  return request_len;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, (%rsp)
movl (%r9), %r15d
cmpl %r8d, %r15d
jge 0x12213
movq %r9, %rbx
movl %r8d, %ebp
movq %rcx, %r14
movl %esi, %r12d
movq %rdi, %r13
movslq %r15d, %rax
leaq (%r14,%rax), %rcx
movl %ebp, %r8d
subl %eax, %r8d
movq %r13, %rdi
movl %r12d, %esi
movq (%rsp), %rdx
callq 0xe716
testl %eax, %eax
jle 0x12213
movl %eax, %r15d
addl (%rbx), %r15d
movl %r15d, (%rbx)
movq %r14, %rdi
movl %r15d, %esi
callq 0x120fa
cmpl %ebp, %r15d
jge 0x12215
testl %eax, %eax
je 0x121d4
jmp 0x12215
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: send_http_error
static void send_http_error(struct mg_connection *conn, int status,
                            const char *reason, const char *fmt, ...) {
  char buf[BUFSIZ];
  va_list ap;
  int len;

  conn->request_info.status_code = status;

  if (call_user(conn, MG_HTTP_ERROR) == NULL) {
    buf[0] = '\0';
    len = 0;

    /* Errors 1xx, 204 and 304 MUST NOT send a body */
    if (status > 199 && status != 204 && status != 304) {
      len = mg_snprintf(conn, buf, sizeof(buf), "Error %d: %s", status, reason);
      cry(conn, "%s", buf);
      buf[len++] = '\n';

      va_start(ap, fmt);
      len += mg_vsnprintf(conn, buf + len, sizeof(buf) - len, fmt, ap);
      va_end(ap);
    }
    DEBUG_TRACE(("[%s]", buf));

    mg_printf(conn, "HTTP/1.1 %d %s\r\n"
              "Content-Type: text/plain\r\n"
              "Content-Length: %d\r\n"
              "Connection: %s\r\n\r\n", status, reason, len,
              suggest_connection_header(conn));
    conn->num_bytes_sent += mg_printf(conn, "%s", buf);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x20d8, %rsp           # imm = 0x20D8
movq %rcx, %r15
movq %rdx, %r14
movl %esi, %ebp
movq %rdi, %rbx
movq %r8, 0x40(%rsp)
movq %r9, 0x48(%rsp)
testb %al, %al
je 0x12285
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)
movl %esi, 0x4c(%rdi)
movq 0x458(%rdi), %rax
movq 0xc8(%rax), %rcx
movq %rcx, 0x8(%rdi)
movq 0xc0(%rax), %rax
testq %rax, %rax
je 0x122bd
leaq 0x8(%rbx), %rdx
movl $0x1, %edi
movq %rbx, %rsi
callq *%rax
testq %rax, %rax
jne 0x123c5
movb $0x0, 0xd0(%rsp)
xorl %r12d, %r12d
cmpl $0xcc, %ebp
je 0x1236e
cmpl $0x130, %ebp            # imm = 0x130
je 0x1236e
leaq 0x3bb3(%rip), %rcx      # 0x15e9a
leaq 0xd0(%rsp), %r12
movl $0x2000, %edx           # imm = 0x2000
movq %rbx, %rdi
movq %r12, %rsi
movl %ebp, %r8d
movq %r14, %r9
xorl %eax, %eax
callq 0x12579
movl %eax, %r13d
leaq 0x445c(%rip), %rsi      # 0x1676d
movq %rbx, %rdi
movq %r12, %rdx
xorl %eax, %eax
callq 0xfb6a
movslq %r13d, %r12
leaq (%rsp,%r12), %rsi
addq $0xd1, %rsi
movb $0xa, -0x1(%rsi)
movabsq $0x3000000020, %rax     # imm = 0x3000000020
movq %rsp, %r8
movq %rax, (%r8)
leaq 0x2110(%rsp), %rax
movq %rax, 0x8(%r8)
leaq 0x20(%rsp), %rax
movq %rax, 0x10(%r8)
movl $0x1fff, %edx           # imm = 0x1FFF
subq %r12, %rdx
movq %rbx, %rdi
movq %r15, %rcx
callq 0xe91d
addl %eax, %r12d
incl %r12d
movq %rbx, %rdi
callq 0x124f2
testl %eax, %eax
leaq 0x3b84(%rip), %rax      # 0x15f03
leaq 0x3b72(%rip), %r9       # 0x15ef8
cmoveq %rax, %r9
leaq 0x3b16(%rip), %rsi      # 0x15ea7
movq %rbx, %rdi
movl %ebp, %edx
movq %r14, %rcx
movl %r12d, %r8d
xorl %eax, %eax
callq 0xe860
leaq 0x43c3(%rip), %rsi      # 0x1676d
leaq 0xd0(%rsp), %rdx
movq %rbx, %rdi
xorl %eax, %eax
callq 0xe860
cltq
addq %rax, 0x4b0(%rbx)
addq $0x20d8, %rsp           # imm = 0x20D8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: log_access
static void log_access(const struct mg_connection *conn) {
  const struct mg_request_info *ri;
  FILE *fp;
  char date[64];

  fp = conn->ctx->config[ACCESS_LOG_FILE] == NULL ?  NULL :
    mg_fopen(conn->ctx->config[ACCESS_LOG_FILE], "a+");

  if (fp == NULL)
    return;

  (void) strftime(date, sizeof(date), "%d/%b/%Y:%H:%M:%S %z",
      localtime(&conn->birth_time));

  ri = &conn->request_info;

  flockfile(fp);

  (void) fprintf(fp,
      "%s - %s [%s] \"%s %s HTTP/%s\" %d %" INT64_FMT,
      inet_ntoa(conn->client.rsa.u.sin.sin_addr),
      ri->remote_user == NULL ? "-" : ri->remote_user,
      date,
      ri->request_method ? ri->request_method : "-",
      ri->uri ? ri->uri : "-",
      ri->http_version,
      conn->request_info.status_code, conn->num_bytes_sent);
  log_header(conn, "Referer", fp);
  log_header(conn, "User-Agent", fp);
  (void) fputc('\n', fp);
  (void) fflush(fp);

  funlockfile(fp);
  (void) fclose(fp);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq %rdi, %r14
movq 0x458(%rdi), %rax
movq 0x48(%rax), %rdi
testq %rdi, %rdi
je 0x124e8
leaq 0x337c(%rip), %rsi      # 0x1577a
callq 0x55c0
testq %rax, %rax
je 0x124e8
movq %rax, %rbx
leaq 0x4a8(%r14), %rdi
callq 0x5340
leaq 0x3b0e(%rip), %rdx      # 0x15f30
movq %rsp, %r15
movl $0x40, %esi
movq %r15, %rdi
movq %rax, %rcx
callq 0x53a0
movq %rbx, %rdi
callq 0x51b0
movl 0x490(%r14), %edi
callq 0x5220
movq 0x30(%r14), %rcx
testq %rcx, %rcx
leaq 0x3b26(%rip), %rdx      # 0x15f7d
cmoveq %rdx, %rcx
movq 0x10(%r14), %r9
movq 0x18(%r14), %r10
testq %r9, %r9
cmoveq %rdx, %r9
testq %r10, %r10
cmoveq %rdx, %r10
movl 0x4c(%r14), %r11d
leaq 0x3ac9(%rip), %rsi      # 0x15f45
movq %rbx, %rdi
movq %rax, %rdx
movq %r15, %r8
xorl %eax, %eax
pushq 0x4b0(%r14)
pushq %r11
pushq 0x20(%r14)
pushq %r10
callq 0x56f0
addq $0x20, %rsp
leaq 0x3ac3(%rip), %rsi      # 0x15f69
movq %r14, %rdi
movq %rbx, %rdx
callq 0x12760
leaq 0x3ab9(%rip), %rsi      # 0x15f71
movq %r14, %rdi
movq %rbx, %rdx
callq 0x12760
movl $0xa, %edi
movq %rbx, %rsi
callq 0x5630
movq %rbx, %rdi
callq 0x55b0
movq %rbx, %rdi
callq 0x53c0
movq %rbx, %rdi
callq 0x54a0
addq $0x40, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: should_keep_alive
static int should_keep_alive(const struct mg_connection *conn) {
  const char *http_version = conn->request_info.http_version;
  const char *header = mg_get_header(conn, "Connection");
  return (header == NULL && http_version && !strcmp(http_version, "1.1")) ||
      (header != NULL && !mg_strcasecmp(header, "keep-alive"));
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq 0x20(%rdi), %r14
addq $0x8, %rdi
leaq 0x4855(%rip), %rsi      # 0x16d5a
callq 0xe5cf
movq %rax, %rbx
testq %rax, %rax
sete %al
testq %r14, %r14
setne %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x12533
leaq 0x40d9(%rip), %rsi      # 0x16600
movq %r14, %rdi
callq 0x56b0
testl %eax, %eax
jmp 0x12567
testq %rbx, %rbx
je 0x12575
callq 0x50e0
movq (%rax), %rax
xorl %ecx, %ecx
leaq 0x39af(%rip), %rdx      # 0x15ef8
movzbl (%rbx,%rcx), %r8d
movl (%rax,%r8,4), %esi
movzbl (%rcx,%rdx), %edi
movl (%rax,%rdi,4), %edi
testl %r8d, %r8d
je 0x12565
incq %rcx
cmpl %edi, %esi
je 0x12549
cmpl %edi, %esi
sete %al
movzbl %al, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
xorl %eax, %eax
jmp 0x1256a
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: mg_snprintf
static int mg_snprintf(struct mg_connection *conn, char *buf, size_t buflen,
                       const char *fmt, ...) {
  va_list ap;
  int n;

  va_start(ap, fmt);
  n = mg_vsnprintf(conn, buf, buflen, fmt, ap);
  va_end(ap);

  return n;
}

// Assembly:
subq $0xd8, %rsp
leaq 0x20(%rsp), %r10
movq %r8, 0x20(%r10)
movq %r9, 0x28(%r10)
testb %al, %al
je 0x125c8
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 %rsp, %r8
movq %r10, 0x10(%r8)
leaq 0xe0(%rsp), %rax
movq %rax, 0x8(%r8)
movabsq $0x3000000020, %rax     # imm = 0x3000000020
movq %rax, (%r8)
callq 0xe91d
addq $0xd8, %rsp
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: parse_http_headers
static void parse_http_headers(char **buf, struct mg_request_info *ri) {
  int i;

  for (i = 0; i < (int) ARRAY_SIZE(ri->http_headers); i++) {
    ri->http_headers[i].name = skip_quoted(buf, ":", " ", 0);
    ri->http_headers[i].value = skip(buf, "\r\n");
    if (ri->http_headers[i].name[0] == '\0')
      break;
    ri->num_headers = i + 1;
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movl $0x1, %ebp
xorl %r15d, %r15d
leaq 0x2cb3(%rip), %r12      # 0x152c8
leaq 0x3c21(%rip), %r13      # 0x1623d
movq %r14, %rdi
leaq 0x2cb0(%rip), %rsi      # 0x152d6
movq %r12, %rdx
xorl %ecx, %ecx
callq 0x12675
movq %rax, 0x50(%rbx,%r15)
movq %r14, %rdi
movq %r13, %rsi
movq %r13, %rdx
xorl %ecx, %ecx
callq 0x12675
movq %rax, 0x58(%rbx,%r15)
movq 0x50(%rbx,%r15), %rax
cmpb $0x0, (%rax)
je 0x12666
movl %ebp, 0x4c(%rbx)
addq $0x10, %r15
incl %ebp
cmpq $0x400, %r15            # imm = 0x400
jne 0x1261c
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: skip_quoted
static char *skip_quoted(char **buf, const char *delimiters, const char *whitespace, char quotechar) {
  char *p, *begin_word, *end_word, *end_whitespace;

  begin_word = *buf;
  end_word = begin_word + strcspn(begin_word, delimiters);

  /* Check for quotechar */
  if (end_word > begin_word) {
    p = end_word - 1;
    while (*p == quotechar) {
      /* If there is anything beyond end_word, copy it */
      if (*end_word == '\0') {
        *p = '\0';
        break;
      } else {
        size_t end_off = strcspn(end_word + 1, delimiters);
        memmove (p, end_word, end_off + 1);
        p += end_off; /* p must correspond to end_word - 1 */
        end_word += end_off + 1;
      }
    }
    for (p++; p < end_word; p++) {
      *p = '\0';
    }
  }

  if (*end_word == '\0') {
    *buf = end_word;
  } else {
    end_whitespace = end_word + 1 + strspn(end_word + 1, whitespace);

    for (p = end_word; p < end_whitespace; p++) {
      *p = '\0';
    }

    *buf = end_whitespace;
  }

  return begin_word;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %ecx, %ebp
movq %rdx, %r14
movq %rsi, %r13
movq %rdi, %r12
movq (%rdi), %rbx
movq %rbx, %rdi
callq 0x5090
leaq (%rbx,%rax), %r15
testq %rax, %rax
jle 0x12717
movq %r14, 0x8(%rsp)
movq %r12, 0x10(%rsp)
leaq -0x1(%r15), %r12
cmpb %bpl, -0x1(%r15)
jne 0x126f4
cmpb $0x0, (%r15)
je 0x126ef
leaq 0x1(%r15), %rdi
movq %r13, %rsi
callq 0x5090
movq %rax, %r14
leaq 0x1(%rax), %rdx
movq %r12, %rdi
movq %r15, %rsi
callq 0x5870
leaq (%r12,%r14), %rdx
addq %r14, %r15
incq %r15
cmpb %bpl, (%r12,%r14)
movq %rdx, %r12
je 0x126b6
jmp 0x126f7
movb $0x0, (%r12)
movq %r12, %rdx
leaq 0x1(%rdx), %rdi
cmpq %r15, %rdi
jae 0x1270d
notq %rdx
addq %r15, %rdx
xorl %esi, %esi
callq 0x5270
movq 0x10(%rsp), %r12
movq 0x8(%rsp), %r14
cmpb $0x0, (%r15)
je 0x12747
leaq 0x1(%r15), %rdi
movq %r14, %rsi
callq 0x5200
leaq (%r15,%rax), %r14
incq %r14
cmpq %r14, %r15
jae 0x1274a
incq %rax
movq %r15, %rdi
xorl %esi, %esi
movq %rax, %rdx
callq 0x5270
jmp 0x1274a
movq %r15, %r14
movq %r14, (%r12)
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: log_header
static void log_header(const struct mg_connection *conn, const char *header,
                       FILE *fp) {
  const char *header_value;

  if ((header_value = mg_get_header(conn, header)) == NULL) {
    (void) fprintf(fp, "%s", " -");
  } else {
    (void) fprintf(fp, " \"%s\"", header_value);
  }
}

// Assembly:
pushq %rbx
movq %rdx, %rbx
addq $0x8, %rdi
callq 0xe5cf
testq %rax, %rax
je 0x12787
leaq 0x40f4(%rip), %rsi      # 0x1686d
movq %rbx, %rdi
movq %rax, %rdx
xorl %eax, %eax
popq %rbx
jmp 0x56f0
leaq 0x37ee(%rip), %rdi      # 0x15f7c
movq %rbx, %rsi
popq %rbx
jmp 0x5550
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: substitute_index_file
static int substitute_index_file(struct mg_connection *conn, char *path,
                                 size_t path_len, struct mgstat *stp) {
  const char *list = conn->ctx->config[INDEX_FILES];
  struct mgstat st;
  struct vec filename_vec;
  size_t n = strlen(path);
  int found = 0;

  // The 'path' given to us points to the directory. Remove all trailing
  // directory separator characters from the end of the path, and
  // then append single directory separator character.
  while (n > 0 && IS_DIRSEP_CHAR(path[n - 1])) {
    n--;
  }
  path[n] = DIRSEP;

  // Traverse index files list. For each entry, append it to the given
  // path and see if the file exists. If it exists, break the loop
  while ((list = next_option(list, &filename_vec, NULL)) != NULL) {

    // Ignore too long entries that may overflow path buffer
    if (filename_vec.len > path_len - n)
      continue;

    // Prepare full path to the index file
    (void) mg_strlcpy(path + n + 1, filename_vec.ptr, filename_vec.len + 1);

    // Does it exist?
    if (mg_stat(path, &st) == 0) {
      // Yes it does, break the loop
      *stp = st;
      found = 1;
      break;
    }
  }

  // If no index file exists, restore directory path
  if (!found) {
    path[n] = '\0';
  }

  return found;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xb8, %rsp
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r12
movq %rsi, %rdi
callq 0x5210
testq %rax, %rax
movq %rbx, 0x10(%rsp)
je 0x129d0
movq %rax, %r13
cmpb $0x2f, -0x1(%r14,%r13)
jne 0x129d3
decq %r13
jne 0x129c3
xorl %r13d, %r13d
leaq (%r14,%r13), %rax
movq %rax, 0x8(%rsp)
movb $0x2f, (%r14,%r13)
leaq 0x18(%rsp), %rsi
movq %r12, %rdi
xorl %edx, %edx
callq 0x11d0e
testq %rax, %rax
je 0x12a8b
movq %rax, %r12
movl $0x1000, %r15d          # imm = 0x1000
subq %r13, %r15
movq 0x8(%rsp), %rax
leaq 0x1(%rax), %rbx
leaq 0x18(%rsp), %r13
leaq 0x28(%rsp), %rbp
movq 0x20(%rsp), %rax
cmpq %r15, %rax
ja 0x12a76
movq 0x18(%rsp), %rcx
leaq 0x1(%rax), %rsi
movb (%rcx), %dl
testb %dl, %dl
sete %dil
cmpq $0x2, %rsi
setb %sil
orb %dil, %sil
movq %rbx, %rsi
jne 0x12a64
incq %rcx
movq %rbx, %rsi
movb %dl, (%rsi)
incq %rsi
movb (%rcx), %dl
testb %dl, %dl
je 0x12a64
leaq -0x1(%rax), %rdi
incq %rcx
cmpq $0x1, %rax
movq %rdi, %rax
ja 0x12a49
movb $0x0, (%rsi)
movq %r14, %rdi
movq %rbp, %rsi
callq 0x5420
testl %eax, %eax
je 0x12a97
movq %r12, %rdi
movq %r13, %rsi
xorl %edx, %edx
callq 0x11d0e
movq %rax, %r12
testq %rax, %rax
jne 0x12a18
movq 0x8(%rsp), %rax
movb $0x0, (%rax)
xorl %eax, %eax
jmp 0x12acd
movq 0x58(%rsp), %rax
movl $0xf000, %ecx           # imm = 0xF000
andl 0x40(%rsp), %ecx
movq 0x80(%rsp), %rdx
xorl %esi, %esi
cmpl $0x4000, %ecx           # imm = 0x4000
sete %sil
movq 0x10(%rsp), %rcx
movl %esi, (%rcx)
movq %rax, 0x8(%rcx)
movq %rdx, 0x10(%rcx)
movl $0x1, %eax
addq $0xb8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: match_extension
static int match_extension(const char *path, const char *ext_list) {
  struct vec ext_vec;
  size_t path_len;

  path_len = strlen(path);

  while ((ext_list = next_option(ext_list, &ext_vec, NULL)) != NULL)
    if (ext_vec.len < path_len &&
        mg_strncasecmp(path + path_len - ext_vec.len,
          ext_vec.ptr, ext_vec.len) == 0)
      return 1;

  return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %r15
movq %rdi, %rbx
callq 0x5210
movq %rax, %r14
xorl %r13d, %r13d
movq %rsp, %rsi
movq %r15, %rdi
xorl %edx, %edx
callq 0x11d0e
testq %rax, %rax
je 0x130bc
movq %rax, %r15
addq %r14, %rbx
movq %rsp, %r12
movq 0x8(%rsp), %rdx
cmpq %r14, %rdx
jae 0x1309c
movq %rbx, %rdi
subq %rdx, %rdi
movq (%rsp), %rsi
callq 0xea9f
testl %eax, %eax
je 0x130b6
xorl %r13d, %r13d
movq %r15, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq 0x11d0e
movq %rax, %r15
testq %rax, %rax
jne 0x1307f
jmp 0x130bc
movl $0x1, %r13d
movl %r13d, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: handle_ssi_file_request
static void handle_ssi_file_request(struct mg_connection *conn,
                                    const char *path) {
  FILE *fp;

  if ((fp = mg_fopen(path, "rb")) == NULL) {
    send_http_error(conn, 500, http_500_error, "fopen(%s): %s", path,
                    strerror(ERRNO));
  } else {
    set_close_on_exec(fileno(fp));
    mg_printf(conn, "HTTP/1.1 200 OK\r\n"
              "Content-Type: text/html\r\nConnection: %s\r\n\r\n",
              suggest_connection_header(conn));
    send_ssi_file(conn, path, fp, 0);
    (void) fclose(fp);
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x2afd(%rip), %rsi      # 0x16562
movq %rbx, %rdi
callq 0x55c0
testq %rax, %rax
je 0x13ada
movq %rax, %r15
movq %rax, %rdi
callq 0x54f0
movl %eax, %edi
movl $0x2, %esi
movl $0x1, %edx
xorl %eax, %eax
callq 0x5290
movq %r14, %rdi
callq 0x124f2
testl %eax, %eax
leaq 0x2462(%rip), %rax      # 0x15f03
leaq 0x2450(%rip), %rdx      # 0x15ef8
cmoveq %rax, %rdx
leaq 0x2d2e(%rip), %rsi      # 0x167e1
movq %r14, %rdi
xorl %eax, %eax
callq 0xe860
movq %r14, %rdi
movq %rbx, %rsi
movq %r15, %rdx
xorl %ecx, %ecx
callq 0x1476a
movq %r15, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x54a0
callq 0x5060
movl (%rax), %edi
callq 0x51a0
leaq 0x25a2(%rip), %rdx      # 0x1608f
leaq 0x2df7(%rip), %rcx      # 0x168eb
movq %r14, %rdi
movl $0x1f4, %esi            # imm = 0x1F4
movq %rbx, %r8
movq %rax, %r9
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
jmp 0x12224
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: get_document_root
static int get_document_root(const struct mg_connection *conn,
                             struct vec *document_root) {
  const char *root, *uri;
  int len_of_matched_uri;
  struct vec uri_vec, path_vec;

  uri = conn->request_info.uri;
  len_of_matched_uri = 0;
  root = next_option(conn->ctx->config[DOCUMENT_ROOT], document_root, NULL);

  while ((root = next_option(root, &uri_vec, &path_vec)) != NULL) {
    if (memcmp(uri, uri_vec.ptr, uri_vec.len) == 0) {
      *document_root = path_vec;
      len_of_matched_uri = uri_vec.len;
      break;
    }
  }

  return len_of_matched_uri;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %r15
xorl %ebx, %ebx
movq %rsi, %rdi
movq %rdx, (%rsp)
movq %rdx, %rsi
xorl %edx, %edx
callq 0x11d0e
movq %rax, %rbp
leaq 0x8(%rsp), %r12
leaq 0x18(%rsp), %r13
movq %rbp, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x11d0e
testq %rax, %rax
je 0x140f8
movq %rax, %rbp
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %r14
movq %r15, %rdi
movq %r14, %rdx
callq 0x54d0
testl %eax, %eax
jne 0x140ba
movups 0x18(%rsp), %xmm0
movq (%rsp), %rax
movups %xmm0, (%rax)
movl %r14d, %ebx
movl %ebx, %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: compare_dir_entries
static int WINCDECL compare_dir_entries(const void *p1, const void *p2) {
  const struct de *a = (const struct de *) p1, *b = (const struct de *) p2;
  const char *query_string = a->conn->request_info.query_string;
  int cmp_result = 0;

  if (query_string == NULL) {
    query_string = "na";
  }

  if (a->st.is_directory && !b->st.is_directory) {
    return -1;  // Always put directories on top
  } else if (!a->st.is_directory && b->st.is_directory) {
    return 1;   // Always put directories on top
  } else if (*query_string == 'n') {
    cmp_result = strcmp(a->file_name, b->file_name);
  } else if (*query_string == 's') {
    cmp_result = a->st.size == b->st.size ? 0 :
      a->st.size > b->st.size ? 1 : -1;
  } else if (*query_string == 'd') {
    cmp_result = a->st.mtime == b->st.mtime ? 0 :
      a->st.mtime > b->st.mtime ? 1 : -1;
  }

  return query_string[1] == 'd' ? -cmp_result : cmp_result;
}

// Assembly:
pushq %rbx
movq (%rdi), %rax
movq 0x28(%rax), %rax
testq %rax, %rax
leaq 0x1f4b(%rip), %rbx      # 0x164b1
cmovneq %rax, %rbx
cmpl $0x0, 0x10(%rdi)
movl 0x10(%rsi), %eax
je 0x1457e
testl %eax, %eax
jne 0x14587
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
jmp 0x145d9
movl $0x1, %ecx
testl %eax, %eax
jne 0x145d9
movzbl (%rbx), %ecx
cmpl $0x64, %ecx
je 0x145b8
cmpl $0x73, %ecx
je 0x145aa
xorl %eax, %eax
cmpl $0x6e, %ecx
jne 0x145ce
movq 0x8(%rdi), %rdi
movq 0x8(%rsi), %rsi
callq 0x56b0
jmp 0x145ce
movq 0x18(%rdi), %rax
xorl %ecx, %ecx
xorl %edx, %edx
cmpq 0x18(%rsi), %rax
jmp 0x145c4
movq 0x20(%rdi), %rax
xorl %ecx, %ecx
xorl %edx, %edx
cmpq 0x20(%rsi), %rax
setg %dl
leal -0x1(%rdx,%rdx), %eax
cmovel %ecx, %eax
movl %eax, %ecx
negl %ecx
cmpb $0x64, 0x1(%rbx)
cmovnel %eax, %ecx
movl %ecx, %eax
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: send_file_data
static void send_file_data(struct mg_connection *conn, FILE *fp, int64_t len) {
  char buf[BUFSIZ];
  int to_read, num_read, num_written;

  while (len > 0) {
    // Calculate how much to read from the file in the buffer
    to_read = sizeof(buf);
    if ((int64_t) to_read > len)
      to_read = (int) len;

    // Read from file, exit the loop on error
    if ((num_read = fread(buf, 1, (size_t)to_read, fp)) == 0)
      break;

    // Send read bytes to the client, exit the loop on error
    if ((num_written = mg_write(conn, buf, (size_t)num_read)) != num_read)
      break;

    // Both read and were successful, adjust counters
    conn->num_bytes_sent += num_written;
    len -= num_written;
  }
}

// Assembly:
testq %rdx, %rdx
jle 0x14668
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x2008, %rsp           # imm = 0x2008
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movl $0x2000, %ebp           # imm = 0x2000
movq %rsp, %r12
cmpq %rbp, %rbx
movl %ebx, %edx
cmovaeq %rbp, %rdx
movl $0x1, %esi
movq %r12, %rdi
movq %r14, %rcx
callq 0x5780
movq %rax, %r13
testl %r13d, %r13d
je 0x14657
movslq %r13d, %r8
movl 0x470(%r15), %esi
movq 0x460(%r15), %rdx
xorl %edi, %edi
movq %r12, %rcx
callq 0xe799
cmpl %r13d, %eax
jne 0x14657
cltq
addq %rax, 0x4b0(%r15)
subq %rax, %rbx
jg 0x14608
addq $0x2008, %rsp           # imm = 0x2008
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: do_ssi_exec
static void do_ssi_exec(struct mg_connection *conn, char *tag) {
  char cmd[BUFSIZ];
  FILE *fp;

  if (sscanf(tag, " \"%[^\"]\"", cmd) != 1) {
    cry(conn, "Bad SSI #exec: [%s]", tag);
  } else if ((fp = popen(cmd, "r")) == NULL) {
    cry(conn, "Cannot SSI #exec: [%s]: %s", cmd, strerror(ERRNO));
  } else {
    send_file_data(conn, fp, INT64_MAX);
    (void) pclose(fp);
  }
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x2008, %rsp           # imm = 0x2008
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x1d18(%rip), %rsi      # 0x168ab
movq %rsp, %rdx
movq %r14, %rdi
xorl %eax, %eax
callq 0x5490
cmpl $0x1, %eax
jne 0x14bdb
leaq 0x1dd7(%rip), %rsi      # 0x16983
movq %rsp, %rdi
callq 0x5150
testq %rax, %rax
je 0x14bf1
movq %rax, %r14
movabsq $0x7fffffffffffffff, %rdx # imm = 0x7FFFFFFFFFFFFFFF
movq %rbx, %rdi
movq %rax, %rsi
callq 0x145dd
movq %r14, %rdi
callq 0x56c0
jmp 0x14c14
leaq 0x1d17(%rip), %rsi      # 0x168f9
movq %rbx, %rdi
movq %r14, %rdx
xorl %eax, %eax
callq 0xfb6a
jmp 0x14c14
callq 0x5060
movl (%rax), %edi
callq 0x51a0
leaq 0x1d09(%rip), %rsi      # 0x1690d
movq %rsp, %rdx
movq %rbx, %rdi
movq %rax, %rcx
xorl %eax, %eax
callq 0xfb6a
addq $0x2008, %rsp           # imm = 0x2008
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/sisong[P]ApkDiffPatch/src/../HDiffPatch/_atosize.h
// Function: kmg_to_size(char const*, unsigned long, unsigned long*)
hpatch_inline static
hpatch_BOOL kmg_to_size(const char* pkmgnum,size_t slen,size_t* out_size){
    size_t shl;
    size_t v;
    if (slen==0) return hpatch_FALSE;
    switch (pkmgnum[slen-1]) {
        case 'k': case 'K': { shl=10; --slen;} break;
        case 'm': case 'M': { shl=20; --slen;} break;
        case 'g': case 'G': { shl=30; --slen;} break;
        default:            { shl= 0;        } break;
    }
    if (!a_to_size(pkmgnum,slen,&v)) return hpatch_FALSE;
    if (v>(_kSizeMax>>shl)) return hpatch_FALSE;
    *out_size=v<<shl;
    return hpatch_TRUE;
}

// Assembly:
testq %rsi, %rsi
je 0x5c69
movzbl -0x1(%rdi,%rsi), %r8d
xorl %eax, %eax
addl $-0x47, %r8d
cmpl $0x26, %r8d
ja 0x5c6c
movabsq $0x100000001, %rcx      # imm = 0x100000001
btq %r8, %rcx
jb 0x5c5f
movl $0xa, %ecx
movabsq $0x1000000010, %r9      # imm = 0x1000000010
btq %r8, %r9
jb 0x5c64
movabsq $0x4000000040, %rcx     # imm = 0x4000000040
btq %r8, %rcx
jae 0x5c6c
movl $0x14, %ecx
jmp 0x5c64
movl $0x1e, %ecx
decq %rsi
jne 0x5c6e
xorl %eax, %eax
retq
xorl %ecx, %ecx
cmpq $0x1, %rsi
je 0x5c79
cmpb $0x30, (%rdi)
je 0x5c6b
pushq %rbx
movabsq $0x1999999999999999, %r9 # imm = 0x1999999999999999
xorl %eax, %eax
xorl %r10d, %r10d
xorl %r8d, %r8d
movzbl (%rdi,%r10), %r11d
leal -0x30(%r11), %ebx
cmpb $0x9, %bl
ja 0x5cd5
addq $-0x30, %r11
cmpq %r9, %r8
jb 0x5cab
jne 0x5cd5
cmpq $0x5, %r11
ja 0x5cd5
leaq (%r8,%r8,4), %r8
leaq (%r11,%r8,2), %r8
incq %r10
cmpq %r10, %rsi
jne 0x5c8c
movq $-0x1, %rsi
shrq %cl, %rsi
cmpq %rsi, %r8
ja 0x5cd5
shlq %cl, %r8
movq %r8, (%rdx)
movl $0x1, %eax
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O3/sisong[P]ApkDiffPatch/src/../HDiffPatch/_clock_for_demo.h
// Function: clock_s()
static double clock_s(){
        struct timeval t={0,0};
        int ret=gettimeofday(&t,0);
        assert(ret==0);
        if (ret==0)
            return t.tv_sec + t.tv_usec/1000000.0;
        else
            return 0;
    }

// Assembly:
subq $0x18, %rsp
xorps %xmm0, %xmm0
movq %rsp, %rdi
movaps %xmm0, (%rdi)
xorl %esi, %esi
callq 0x4500
testl %eax, %eax
jne 0x5f78
cvtsi2sdq (%rsp), %xmm1
xorps %xmm0, %xmm0
cvtsi2sdq 0x8(%rsp), %xmm0
divsd 0x530d1(%rip), %xmm0    # 0x59040
addsd %xmm1, %xmm0
addq $0x18, %rsp
retq
leaq 0x536e1(%rip), %rdi     # 0x59660
leaq 0x536e1(%rip), %rsi     # 0x59667
leaq 0x536fe(%rip), %rcx     # 0x5968b
movl $0x33, %edx
callq 0x4200
// File: /workspace/github_cpp_makefile_star2_O3/sisong[P]ApkDiffPatch/src/../HDiffPatch/decompress_plugin_demo.h
// Function: zlib_decompress_open(hpatch_TDecompress*, unsigned long long, hpatch_TStreamInput const*, unsigned long long, unsigned long long)
static hpatch_decompressHandle  _zlib_decompress_open(hpatch_TDecompress* decompressPlugin,
                                                          hpatch_StreamPos_t dataSize,
                                                          const hpatch_TStreamInput* codeStream,
                                                          hpatch_StreamPos_t code_begin,
                                                          hpatch_StreamPos_t code_end){
        _zlib_TDecompress* self=0;
        unsigned char* _mem_buf=(unsigned char*)_dec_malloc(sizeof(_zlib_TDecompress)+kDecompressBufSize);
        if (!_mem_buf) _dec_memErr_rt();
        self=_zlib_decompress_open_at(decompressPlugin,codeStream,code_begin,code_end,1,
                                      (_zlib_TDecompress*)_mem_buf,sizeof(_zlib_TDecompress)+kDecompressBufSize);
        if (!self)
            free(_mem_buf);
        return self;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %r8, %r15
movq %rcx, %r12
movq %rdx, %r13
movq %rdi, %r14
movl $0x80a0, %edi           # imm = 0x80A0
callq 0x6a5b
testq %rax, %rax
je 0x678d
movq %rax, %rbx
movb $-0xf, 0xf(%rsp)
cmpq %r12, %r15
jne 0x67a5
cmpl $0x0, 0x28(%r14)
jne 0x6872
addq $0x28, %r14
movl $0x2, (%r14)
jmp 0x6872
cmpl $0x0, 0x28(%r14)
jne 0x687a
movl $0x1, 0x28(%r14)
jmp 0x687a
leaq 0x10(%rsp), %rcx
leaq 0xf(%rsp), %rdx
movq %r13, %rdi
movq %r12, %rsi
callq *0x10(%r13)
testl %eax, %eax
je 0x6872
incq %r12
leaq 0x28(%rbx), %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0x88(%rbx)
movups %xmm0, 0x78(%rbx)
movups %xmm0, 0x68(%rbx)
movups %xmm0, 0x58(%rbx)
movups %xmm0, 0x48(%rbx)
movups %xmm0, 0x38(%rbx)
movups %xmm0, 0x28(%rbx)
movq $0x0, 0x98(%rbx)
movq %rbx, %rax
addq $0xa0, %rax
movq %rax, 0x18(%rbx)
movq $0x8000, 0x20(%rbx)     # imm = 0x8000
movq %r13, 0x10(%rbx)
movq %r12, (%rbx)
movq %r15, 0x8(%rbx)
movsbl 0xf(%rsp), %esi
movb %sil, 0x98(%rbx)
leaq 0x24d(%rip), %rax       # 0x6a75
movq %rax, 0x68(%rbx)
leaq 0x264(%rip), %rax       # 0x6a97
movq %rax, 0x70(%rbx)
movq %rbx, 0x78(%rbx)
leaq 0x52a51(%rip), %rdx     # 0x59293
movl $0x70, %ecx
callq 0x4e72a
testl %eax, %eax
je 0x687c
movl 0x9c(%rbx), %eax
testl %eax, %eax
je 0x6772
cmpl $0x0, 0x28(%r14)
jne 0x6772
movl %eax, 0x28(%r14)
jmp 0x6772
movq %rbx, %rdi
callq 0x43b0
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/sisong[P]ApkDiffPatch/src/../HDiffPatch/decompress_plugin_demo.h
// Function: zlib_decompress_close(hpatch_TDecompress*, void*)
static hpatch_BOOL _zlib_decompress_close_by(struct hpatch_TDecompress* decompressPlugin,
                                                 _zlib_TDecompress* self){
        hpatch_BOOL result=hpatch_TRUE;
        if (!self) return result;
        _dec_onDecErr_up();
        if (self->d_stream.state!=0){
            _dec_close_check(Z_OK==inflateEnd(&self->d_stream));
        }
        memset(self,0,sizeof(_zlib_TDecompress));
        return result;
    }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
testq %rsi, %rsi
je 0x68d4
movq %rsi, %rbx
movq %rdi, %r14
movl 0x9c(%rsi), %eax
testl %eax, %eax
je 0x68b1
cmpl $0x0, 0x28(%r14)
jne 0x68b1
movl %eax, 0x28(%r14)
movl $0x1, %ebp
cmpq $0x0, 0x60(%rbx)
je 0x68ca
leaq 0x28(%rbx), %rdi
callq 0x50454
testl %eax, %eax
jne 0x68e0
movq %rbx, %rdi
callq 0x43b0
jmp 0x68d9
movl $0x1, %ebp
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
movq 0x756e1(%rip), %rax     # 0x7bfc8
movq (%rax), %rcx
leaq 0x52a66(%rip), %rdi     # 0x59357
movl $0x2f, %esi
movl $0x1, %edx
callq 0x4660
xorl %ebp, %ebp
cmpl $0x0, 0x28(%r14)
jne 0x68ca
movl $0x4, 0x28(%r14)
jmp 0x68ca
// File: /workspace/github_cpp_makefile_star2_O3/sisong[P]ApkDiffPatch/src/../HDiffPatch/decompress_plugin_demo.h
// Function: zlib_decompress_part(void*, unsigned char*, unsigned char*)
static hpatch_BOOL _zlib_decompress_part(hpatch_decompressHandle decompressHandle,
                                             unsigned char* out_part_data,unsigned char* out_part_data_end){
        _zlib_TDecompress* self=(_zlib_TDecompress*)decompressHandle;
        assert(out_part_data<=out_part_data_end);
        
        self->d_stream.next_out = out_part_data;
        self->d_stream.avail_out =(uInt)(out_part_data_end-out_part_data);
        while (self->d_stream.avail_out>0) {
            if (!__zlib_do_inflate(self))
                return hpatch_FALSE;//error;
        }
        return hpatch_TRUE;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
cmpq %rdx, %rsi
ja 0x6a3c
movq %rdx, %r15
movq %rdi, %rbx
movq %rsi, 0x40(%rdi)
movl $0x1, %eax
subl %esi, %r15d
movl %r15d, 0x48(%rdi)
je 0x6a2d
leaq 0x28(%rbx), %r14
movl 0x30(%rbx), %r12d
movq (%rbx), %rsi
movq 0x8(%rbx), %r13
subq %rsi, %r13
testl %r12d, %r12d
sete %al
testq %r13, %r13
setne %cl
andb %al, %cl
movl %r15d, %ebp
cmpb $0x1, %cl
jne 0x699e
movq 0x20(%rbx), %r12
cmpq %r13, %r12
cmovaeq %r13, %r12
movq 0x10(%rbx), %rdi
movq 0x18(%rbx), %rdx
movq %rdx, 0x28(%rbx)
leaq (%rdx,%r12), %rcx
callq *0x10(%rdi)
testl %eax, %eax
je 0x6a2b
movl %r12d, 0x30(%rbx)
addq %r12, (%rbx)
subq %r12, %r13
movl 0x48(%rbx), %ebp
movq %r14, %rdi
xorl %esi, %esi
callq 0x4e888
cmpl $0x1, %eax
je 0x69c4
testl %eax, %eax
jne 0x6a15
movl 0x30(%rbx), %eax
movl 0x48(%rbx), %r15d
cmpl %r12d, %eax
jne 0x69f7
cmpl %ebp, %r15d
jne 0x69fa
jmp 0x6a15
movl 0x30(%rbx), %r12d
addq %r12, %r13
je 0x6a0a
movq 0x28(%rbx), %r13
movq 0x40(%rbx), %rbp
movl 0x48(%rbx), %r15d
movq %r14, %rdi
callq 0x4e659
testl %eax, %eax
jne 0x6a15
movq %rbp, 0x40(%rbx)
movq %r13, 0x28(%rbx)
movl %r15d, 0x48(%rbx)
movl %r12d, 0x30(%rbx)
jmp 0x69fa
movl %eax, %r12d
testl %r15d, %r15d
jne 0x694b
movl $0x1, %eax
jmp 0x6a2d
cmpl $0x0, 0x48(%rbx)
movl $0x1, %eax
je 0x6a2d
cmpl $0x0, 0x9c(%rbx)
jne 0x6a2b
addq $0x9c, %rbx
movl $0x3, (%rbx)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x52944(%rip), %rdi     # 0x59387
leaq 0x528e2(%rip), %rsi     # 0x5932c
leaq 0x52957(%rip), %rcx     # 0x593a8
movl $0xf7, %edx
callq 0x4200
// File: /workspace/github_cpp_makefile_star2_O3/sisong[P]ApkDiffPatch/src/../HDiffPatch/compress_plugin_demo.h
// Function: _lzma_SeqOutStream_Write(ISeqOutStream_ const*, void const*, unsigned long)
static size_t __lzma_SeqOutStream_Write(const ISeqOutStream *p, const void *buf, size_t size){
        __lzma_SeqOutStream_t* self=(__lzma_SeqOutStream_t*)p;
        const unsigned char* pdata=(const unsigned char*)buf;
        if (size>0){
            if (!self->out_code->write(self->out_code,self->writeToPos,pdata,pdata+size)){
                self->isCanceled=1;
                return 0;
            }
        }
        self->writeToPos+=size;
        return size;
    }

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rdi, %r14
testq %rdx, %rdx
je 0x6aca
movq %rsi, %rdx
movq 0x8(%r14), %rdi
movq 0x10(%r14), %rsi
leaq (%rdx,%rbx), %rcx
callq *0x18(%rdi)
testl %eax, %eax
je 0x6ad0
addq %rbx, 0x10(%r14)
jmp 0x6ada
movl $0x1, 0x18(%r14)
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O3/sisong[P]ApkDiffPatch/src/../HDiffPatch/compress_plugin_demo.h
// Function: _lzma_SeqInStream_Read(ISeqInStream_ const*, void*, unsigned long*)
static SRes __lzma_SeqInStream_Read(const ISeqInStream *p, void *buf, size_t *size){
        __lzma_SeqInStream_t* self=(__lzma_SeqInStream_t*)p;
        size_t readLen=*size;
        if (readLen+self->readFromPos>self->in_data->streamSize)
            readLen=(size_t)(self->in_data->streamSize-self->readFromPos);
        if (readLen>0){
            unsigned char* pdata=(unsigned char*)buf;
            if (!self->in_data->read(self->in_data,self->readFromPos,pdata,pdata+readLen)){
                *size=0;
                return SZ_ERROR_READ;
            }
        }
        self->readFromPos+=readLen;
        *size=readLen;
        return SZ_OK;
    }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %rdx
movq %rdi, %r14
movq (%rbx), %rax
movq 0x8(%rdi), %rdi
movq 0x10(%r14), %rsi
leaq (%rsi,%rax), %rcx
movq 0x8(%rdi), %r8
movq %r8, %r15
subq %rsi, %r15
cmpq %r8, %rcx
cmovbeq %rax, %r15
testq %r15, %r15
je 0x6b27
leaq (%rdx,%r15), %rcx
callq *0x10(%rdi)
testl %eax, %eax
je 0x6b32
movq 0x10(%r14), %rsi
addq %r15, %rsi
movq %rsi, 0x10(%r14)
xorl %eax, %eax
jmp 0x6b3a
movl $0x8, %eax
xorl %r15d, %r15d
movq %r15, (%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/sisong[P]ApkDiffPatch/src/../HDiffPatch/decompress_plugin_demo.h
// Function: lzma2_open(hpatch_TDecompress*, unsigned long long, hpatch_TStreamInput const*, unsigned long long, unsigned long long)
static hpatch_decompressHandle _lzma2_open(hpatch_TDecompress* decompressPlugin,
                                            hpatch_StreamPos_t dataSize,
                                            const hpatch_TStreamInput* codeStream,
                                            hpatch_StreamPos_t code_begin,
                                            hpatch_StreamPos_t code_end){
        _lzma2_TDecompress* self=0;
        SRes ret;
        unsigned char propsSize=0;
        //load propsSize
        if (code_end-code_begin<1) _dec_openErr_rt();
        if (!codeStream->read(codeStream,code_begin,&propsSize,&propsSize+1)) return 0;
        ++code_begin;
        
        self=(_lzma2_TDecompress*)_dec_malloc(sizeof(_lzma2_TDecompress));
        if (!self) _dec_memErr_rt();
        memset(self,0,sizeof(_lzma2_TDecompress)-kDecompressBufSize);
        self->memAllocBase.Alloc=__lzma2_dec_Alloc;
        *((void**)&self->memAllocBase.Free)=(void*)__dec_free;
        self->codeStream=codeStream;
        self->code_begin=code_begin;
        self->code_end=code_end;
        
        self->decCopyPos=0;
        self->decReadPos=kDecompressBufSize;
        
        Lzma2Dec_Construct(&self->decEnv);
        ret=Lzma2Dec_Allocate(&self->decEnv,propsSize,&self->memAllocBase);
        if (ret!=SZ_OK){ _dec_onDecErr_up(); free(self); _dec_openErr_rt(); }
        Lzma2Dec_Init(&self->decEnv);
        return self;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movb $0x0, 0x7(%rsp)
cmpq %rcx, %r8
jne 0x6b99
cmpl $0x0, 0x28(%rbx)
jne 0x6c63
movl $0x2, 0x28(%rbx)
jmp 0x6c63
movq %r8, %r15
movq %rcx, %r12
movq %rdx, %r13
leaq 0x8(%rsp), %rcx
leaq 0x7(%rsp), %rdx
movq %r13, %rdi
movq %r12, %rsi
callq *0x10(%r13)
testl %eax, %eax
je 0x6c63
movl $0x80d0, %edi           # imm = 0x80D0
callq 0x6a5b
testq %rax, %rax
je 0x6c56
movq %rax, %r14
incq %r12
movq %rax, %rbp
addq $0x28, %rbp
movl $0xa8, %edx
movq %rbp, %rdi
xorl %esi, %esi
callq 0x41c0
leaq 0x27c(%rip), %rax       # 0x6e70
movq %rax, (%r14)
leaq -0x167(%rip), %rax      # 0x6a97
movq %rax, 0x8(%r14)
movq %r13, 0x10(%r14)
movq %r12, 0x18(%r14)
movq %r15, 0x20(%r14)
movq $0x8000, 0xc0(%r14) # imm = 0x8000
movq $0x0, 0x40(%r14)
movzbl 0x7(%rsp), %esi
movq %rbp, %rdi
movq %r14, %rdx
callq 0x5778f
testl %eax, %eax
je 0x6c78
movl 0xc8(%r14), %eax
testl %eax, %eax
je 0x6c49
cmpl $0x0, 0x28(%rbx)
jne 0x6c49
movl %eax, 0x28(%rbx)
movq %r14, %rdi
callq 0x43b0
jmp 0x6b83
cmpl $0x0, 0x28(%rbx)
jne 0x6c63
movl $0x1, 0x28(%rbx)
xorl %r14d, %r14d
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rbp, %rdi
callq 0x577ea
jmp 0x6c66
// File: /workspace/github_cpp_makefile_star2_O3/sisong[P]ApkDiffPatch/src/../HDiffPatch/decompress_plugin_demo.h
// Function: lzma2_close(hpatch_TDecompress*, void*)
static hpatch_BOOL _lzma2_close(struct hpatch_TDecompress* decompressPlugin,
                                    hpatch_decompressHandle decompressHandle){
        _lzma2_TDecompress* self=(_lzma2_TDecompress*)decompressHandle;
        if (!self) return hpatch_TRUE;
        Lzma2Dec_Free(&self->decEnv,&self->memAllocBase);
        _dec_onDecErr_up();
        free(self);
        return hpatch_TRUE;
    }

// Assembly:
testq %rsi, %rsi
je 0x6cbe
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x38(%rsi), %rdi
callq 0x5732c
movl 0xc8(%rbx), %eax
testl %eax, %eax
je 0x6caf
cmpl $0x0, 0x28(%r14)
jne 0x6caf
movl %eax, 0x28(%r14)
movq %rbx, %rdi
callq 0x43b0
addq $0x8, %rsp
popq %rbx
popq %r14
movl $0x1, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/sisong[P]ApkDiffPatch/src/../HDiffPatch/decompress_plugin_demo.h
// Function: lzma_close(hpatch_TDecompress*, void*)
static hpatch_BOOL _lzma_close(struct hpatch_TDecompress* decompressPlugin,
                                   hpatch_decompressHandle decompressHandle){
        _lzma_TDecompress* self=(_lzma_TDecompress*)decompressHandle;
        if (!self) return hpatch_TRUE;
        LzmaDec_Free(&self->decEnv,&self->memAllocBase);
        _dec_onDecErr_up();
        free(self);
        return hpatch_TRUE;
    }

// Assembly:
testq %rsi, %rsi
je 0x7038
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x28(%rsi), %rdi
callq 0x5732c
movl 0xb8(%rbx), %eax
testl %eax, %eax
je 0x7029
cmpl $0x0, 0x28(%r14)
jne 0x7029
movl %eax, 0x28(%r14)
movq %rbx, %rdi
callq 0x43b0
addq $0x8, %rsp
popq %rbx
popq %r14
movl $0x1, %eax
retq