LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/nilnilnil[P]autocomplete/deps/mongoose/mongoose.c
// Function: send_authorization_request
static void send_authorization_request(struct mg_connection *conn) {
  conn->request_info.status_code = 401;
  (void) mg_printf(conn,
      "HTTP/1.1 401 Unauthorized\r\n"
      "WWW-Authenticate: Digest qop=\"auth\", "
      "realm=\"%s\", nonce=\"%lu\"\r\n\r\n",
      conn->ctx->config[AUTHENTICATION_DOMAIN],
      (unsigned long) time(NULL));
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl $0x191, 0x4c(%rdi)      # imm = 0x191
movq 0x458(%rdi), %rax
movq 0x38(%rax), %r14
xorl %edi, %edi
callq 0x5420
leaq 0x2555(%rip), %rsi      # 0x131e4
movq %rbx, %rdi
movq %r14, %rdx
movq %rax, %rcx
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0xbb9c
// File: /workspace/github_cpp_makefile_star2_O2/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 %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r14
movq %rdi, %rbx
callq 0x51e0
movq %rax, %r15
addq %rax, %rbx
leaq 0x8(%rsp), %r12
pushq $0x1
popq %rbp
xorl %r13d, %r13d
movq %r14, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq 0xdcda
testq %rax, %rax
je 0x10d06
movq %rax, %r14
movq 0x10(%rsp), %rdx
cmpq %r15, %rdx
jae 0x10ccd
movq %rbx, %rdi
subq %rdx, %rdi
movq 0x8(%rsp), %rsi
callq 0xbdab
testl %eax, %eax
jne 0x10ccd
movl %ebp, %r13d
movl %r13d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x18(%rdi), %r15
movq 0x458(%rdi), %rax
movq 0xa0(%rax), %rdi
xorl %ebx, %ebx
movq %rsi, (%rsp)
xorl %edx, %edx
callq 0xdcda
movq %rax, %rbp
leaq 0x8(%rsp), %r12
leaq 0x18(%rsp), %r13
movq %rbp, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0xdcda
testq %rax, %rax
je 0x10d90
movq %rax, %rbp
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %r14
movq %r15, %rdi
movq %r14, %rdx
callq 0x54c0
testl %eax, %eax
jne 0x10d52
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_O2/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 0x2307(%rip), %rbx      # 0x134b1
cmovneq %rax, %rbx
cmpl $0x0, 0x10(%rdi)
movl 0x10(%rsi), %eax
je 0x111bf
testl %eax, %eax
jne 0x111c8
pushq $-0x1
jmp 0x111c5
testl %eax, %eax
je 0x111c8
pushq $0x1
popq %rcx
jmp 0x1121a
movzbl (%rbx), %ecx
cmpl $0x64, %ecx
je 0x111f9
cmpl $0x73, %ecx
je 0x111eb
xorl %eax, %eax
cmpl $0x6e, %ecx
jne 0x1120f
movq 0x8(%rdi), %rdi
movq 0x8(%rsi), %rsi
callq 0x56c0
jmp 0x1120f
movq 0x18(%rdi), %rax
xorl %ecx, %ecx
xorl %edx, %edx
cmpq 0x18(%rsi), %rax
jmp 0x11205
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_O2/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:
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, %r13d          # imm = 0x2000
movq %rsp, %r12
testq %rbx, %rbx
jle 0x11285
cmpq %r13, %rbx
movl %ebx, %edx
cmovaeq %r13, %rdx
movq %r12, %rdi
pushq $0x1
popq %rsi
movq %r14, %rcx
callq 0x5790
movq %rax, %rbp
testl %ebp, %ebp
je 0x11285
movslq %ebp, %rdx
movq %r15, %rdi
movq %r12, %rsi
callq 0xbac3
cmpl %ebp, %eax
jne 0x11285
movslq %ebp, %rax
addq %rax, 0x4b0(%r15)
subq %rax, %rbx
jmp 0x11241
addq $0x2008, %rsp           # imm = 0x2008
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x2134(%rip), %rsi      # 0x138ab
movq %rsp, %rdx
movq %r14, %rdi
xorl %eax, %eax
callq 0x5470
cmpl $0x1, %eax
jne 0x117bf
leaq 0x21f3(%rip), %rsi      # 0x13983
movq %rsp, %rdi
callq 0x5140
testq %rax, %rax
je 0x117d5
movq %rax, %r14
movabsq $0x7fffffffffffffff, %rdx # imm = 0x7FFFFFFFFFFFFFFF
movq %rbx, %rdi
movq %rax, %rsi
callq 0x1121e
movq %r14, %rdi
callq 0x56d0
jmp 0x117f8
leaq 0x2133(%rip), %rsi      # 0x138f9
movq %rbx, %rdi
movq %r14, %rdx
xorl %eax, %eax
callq 0xcd67
jmp 0x117f8
callq 0x5050
movl (%rax), %edi
callq 0x5170
leaq 0x2125(%rip), %rsi      # 0x1390d
movq %rsp, %rdx
movq %rbx, %rdi
movq %rax, %rcx
xorl %eax, %eax
callq 0xcd67
addq $0x2008, %rsp           # imm = 0x2008
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/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:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
testq %rsi, %rsi
je 0x52d8
movq %rdx, %rbx
movzbl -0x1(%rdi,%rsi), %eax
xorl %r14d, %r14d
addl $-0x47, %eax
cmpl $0x26, %eax
ja 0x5326
movabsq $0x100000001, %rcx      # imm = 0x100000001
btq %rax, %rcx
jb 0x52e4
movabsq $0x1000000010, %rcx     # imm = 0x1000000010
btq %rax, %rcx
jb 0x52dd
movabsq $0x4000000040, %rcx     # imm = 0x4000000040
btq %rax, %rcx
jae 0x5326
decq %rsi
pushq $0x14
jmp 0x52e9
xorl %r14d, %r14d
jmp 0x5319
decq %rsi
pushq $0xa
jmp 0x52e9
decq %rsi
pushq $0x1e
popq %r15
leaq 0x8(%rsp), %rdx
callq 0x532b
testl %eax, %eax
je 0x5319
movq 0x8(%rsp), %rax
pushq $-0x1
popq %rdx
movl %r15d, %ecx
shrq %cl, %rdx
cmpq %rdx, %rax
ja 0x5319
movl %r15d, %ecx
shlq %cl, %rax
movq %rax, (%rbx)
pushq $0x1
popq %r14
movl %r14d, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
xorl %r15d, %r15d
jmp 0x52eb
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/../HDiffPatch/_atosize.h
// Function: a_to_size(char const*, unsigned long, unsigned long*)
hpatch_inline static
hpatch_BOOL a_to_size(const char* pnum,size_t slen,size_t* out_size){
    const size_t _kSizeMaxDiv10=_kSizeMax/10;
    const size_t _kSizeMaxMod10=_kSizeMax-_kSizeMaxDiv10*10;
    size_t v=0;
    size_t s;
    if (slen==0) return hpatch_FALSE;
    if ((slen>=2)&(pnum[0]=='0')) return hpatch_FALSE;
    for (s=0; s<slen; ++s) {
        size_t c=pnum[s];
        if (('0'<=c)&(c<='9'))
            ;//empty ok
        else
            return hpatch_FALSE;
        c-='0';
        if (v<_kSizeMaxDiv10)
            ;//empty ok
        else if ((v>_kSizeMaxDiv10)|(c>_kSizeMaxMod10))
            return hpatch_FALSE;
        v=v*10+c;
    }
    *out_size=v;
    return hpatch_TRUE;
}

// Assembly:
xorl %eax, %eax
testq %rsi, %rsi
je 0x533d
cmpq $0x1, %rsi
je 0x533e
cmpb $0x30, (%rdi)
jne 0x533e
retq
movabsq $0x1999999999999999, %rcx # imm = 0x1999999999999999
xorl %r9d, %r9d
xorl %r8d, %r8d
cmpq %r8, %rsi
je 0x5384
movzbl (%rdi,%r8), %r10d
leal -0x30(%r10), %r11d
xorl %eax, %eax
cmpb $0x9, %r11b
ja 0x533d
addq $-0x30, %r10
cmpq %rcx, %r9
jb 0x5375
jne 0x533d
cmpq $0x5, %r10
ja 0x533d
imulq $0xa, %r9, %rax
addq %rax, %r10
incq %r8
movq %r10, %r9
jmp 0x534e
movq %r9, (%rdx)
pushq $0x1
popq %rax
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x4530
testl %eax, %eax
jne 0x55f7
cvtsi2sdq (%rsp), %xmm1
cvtsi2sdq 0x8(%rsp), %xmm0
divsd 0x48a52(%rip), %xmm0    # 0x4e040
addsd %xmm1, %xmm0
addq $0x18, %rsp
retq
leaq 0x49062(%rip), %rdi     # 0x4e660
leaq 0x49062(%rip), %rsi     # 0x4e667
leaq 0x4907f(%rip), %rcx     # 0x4e68b
pushq $0x33
popq %rdx
callq 0x4230
// File: /workspace/github_cpp_makefile_star2_O2/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 0x6000
testq %rax, %rax
je 0x5d4b
movq %rax, %rbx
movb $-0xf, 0xf(%rsp)
cmpq %r12, %r15
jne 0x5d63
cmpl $0x0, 0x28(%r14)
jne 0x5e2b
addq $0x28, %r14
movl $0x2, (%r14)
jmp 0x5e2b
cmpl $0x0, 0x28(%r14)
jne 0x5e33
movl $0x1, 0x28(%r14)
jmp 0x5e33
leaq 0x10(%rsp), %rcx
leaq 0xf(%rsp), %rdx
movq %r13, %rdi
movq %r12, %rsi
callq *0x10(%r13)
testl %eax, %eax
je 0x5e2b
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)
andq $0x0, 0x98(%rbx)
movups %xmm0, 0x38(%rbx)
movups %xmm0, 0x28(%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 0x266(%rip), %rax       # 0x6049
movq %rax, 0x68(%rbx)
leaq 0x27d(%rip), %rax       # 0x606b
movq %rax, 0x70(%rbx)
movq %rbx, 0x78(%rbx)
leaq 0x48496(%rip), %rdx     # 0x4e293
pushq $0x70
popq %rcx
callq 0x44bcf
testl %eax, %eax
je 0x5e35
movl 0x9c(%rbx), %eax
testl %eax, %eax
je 0x5d30
cmpl $0x0, 0x28(%r14)
jne 0x5d30
movl %eax, 0x28(%r14)
jmp 0x5d30
movq %rbx, %rdi
callq 0x43d0
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_O2/sisong[P]ApkDiffPatch/src/../HDiffPatch/decompress_plugin_demo.h
// Function: zlib_decompress_close(hpatch_TDecompress*, void*)
static hpatch_BOOL _zlib_decompress_close(struct hpatch_TDecompress* decompressPlugin,
                                              hpatch_decompressHandle decompressHandle){
        _zlib_TDecompress* self=(_zlib_TDecompress*)decompressHandle;
        hpatch_BOOL result=_zlib_decompress_close_by(decompressPlugin,self);
        if (self) free(self);
        return result;
    }

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
pushq $0x1
popq %rbp
testq %rsi, %rsi
je 0x5e81
movq %rdi, %r14
movl 0x9c(%rbx), %eax
testl %eax, %eax
je 0x5e6d
cmpl $0x0, 0x28(%r14)
jne 0x5e6d
movl %eax, 0x28(%r14)
cmpq $0x0, 0x60(%rbx)
je 0x5e81
leaq 0x28(%rbx), %rdi
callq 0x469ed
testl %eax, %eax
jne 0x5e90
movq %rbx, %rdi
callq 0x43d0
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
movq 0x6f131(%rip), %rax     # 0x74fc8
movq (%rax), %rcx
leaq 0x484b6(%rip), %rdi     # 0x4e357
pushq $0x2f
popq %rsi
pushq $0x1
popq %rdx
callq 0x4680
xorl %ebp, %ebp
cmpl $0x0, 0x28(%r14)
jne 0x5e81
movl $0x4, 0x28(%r14)
jmp 0x5e81
// File: /workspace/github_cpp_makefile_star2_O2/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 0x5fe1
movq %rdx, %r15
movq %rdi, %rbx
movq %rsi, 0x40(%rdi)
subl %esi, %r15d
movl %r15d, 0x48(%rdi)
leaq 0x28(%rdi), %r14
testl %r15d, %r15d
je 0x5fcf
movq (%rbx), %rsi
movq 0x8(%rbx), %r12
subq %rsi, %r12
movl 0x30(%rbx), %r13d
testl %r13d, %r13d
sete %al
testq %r12, %r12
setne %cl
andb %al, %cl
movl %r15d, %ebp
cmpb $0x1, %cl
jne 0x5f48
movq 0x20(%rbx), %r13
cmpq %r12, %r13
cmovaeq %r12, %r13
movq 0x10(%rbx), %rdi
movq 0x18(%rbx), %rdx
movq %rdx, 0x28(%rbx)
leaq (%rdx,%r13), %rcx
callq *0x10(%rdi)
testl %eax, %eax
je 0x5fcb
movl %r13d, 0x30(%rbx)
addq %r13, (%rbx)
subq %r13, %r12
movl 0x48(%rbx), %ebp
movq %r14, %rdi
xorl %esi, %esi
callq 0x44d05
cmpl $0x1, %eax
je 0x5f70
testl %eax, %eax
jne 0x5fb5
movl 0x48(%rbx), %r15d
cmpl %r13d, 0x30(%rbx)
jne 0x5ee8
cmpl %ebp, %r15d
jne 0x5ee8
jmp 0x5fb5
movl 0x30(%rbx), %r13d
addq %r13, %r12
jne 0x5f88
xorl %r15d, %r15d
cmpl $0x0, 0x48(%rbx)
je 0x5ee8
jmp 0x5fb5
movq 0x28(%rbx), %r12
movq 0x40(%rbx), %rbp
movl 0x48(%rbx), %r15d
movq %r14, %rdi
callq 0x44b16
testl %eax, %eax
jne 0x5fb5
movq %rbp, 0x40(%rbx)
movq %r12, 0x28(%rbx)
movl %r15d, 0x48(%rbx)
movl %r13d, 0x30(%rbx)
jmp 0x5ee8
cmpl $0x0, 0x9c(%rbx)
jne 0x5fcb
addq $0x9c, %rbx
movl $0x3, (%rbx)
xorl %eax, %eax
jmp 0x5fd2
pushq $0x1
popq %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x4839f(%rip), %rdi     # 0x4e387
leaq 0x4833d(%rip), %rsi     # 0x4e32c
leaq 0x483b2(%rip), %rcx     # 0x4e3a8
movl $0xf7, %edx
callq 0x4230
// File: /workspace/github_cpp_makefile_star2_O2/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 0x6098
movq %rsi, %rdx
movq 0x8(%r14), %rdi
movq 0x10(%r14), %rsi
leaq (%rdx,%rbx), %rcx
callq *0x18(%rdi)
testl %eax, %eax
je 0x609e
addq %rbx, 0x10(%r14)
jmp 0x60a8
movl $0x1, 0x18(%r14)
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x60f5
leaq (%rdx,%r15), %rcx
callq *0x10(%rdi)
testl %eax, %eax
je 0x6100
movq 0x10(%r14), %rsi
addq %r15, %rsi
movq %rsi, 0x10(%r14)
xorl %eax, %eax
jmp 0x6106
pushq $0x8
popq %rax
xorl %r15d, %r15d
movq %r15, (%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x6165
cmpl $0x0, 0x28(%rbx)
jne 0x622c
movl $0x2, 0x28(%rbx)
jmp 0x622c
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 0x622c
movl $0x80d0, %edi           # imm = 0x80D0
callq 0x6000
testq %rax, %rax
je 0x621f
movq %rax, %r14
incq %r12
movq %rax, %rbp
addq $0x28, %rbp
movl $0xa8, %edx
movq %rbp, %rdi
xorl %esi, %esi
callq 0x41f0
leaq 0x27a(%rip), %rax       # 0x643a
movq %rax, (%r14)
leaq -0x15f(%rip), %rax      # 0x606b
movq %rax, 0x8(%r14)
movq %r13, 0x10(%r14)
movq %r12, 0x18(%r14)
movq %r15, 0x20(%r14)
movq $0x8000, 0xc0(%r14) # imm = 0x8000
andq $0x0, 0x40(%r14)
movzbl 0x7(%rsp), %esi
movq %rbp, %rdi
movq %r14, %rdx
callq 0x4d0f4
testl %eax, %eax
je 0x6241
movl 0xc8(%r14), %eax
testl %eax, %eax
je 0x6212
cmpl $0x0, 0x28(%rbx)
jne 0x6212
movl %eax, 0x28(%rbx)
movq %r14, %rdi
callq 0x43d0
jmp 0x614f
cmpl $0x0, 0x28(%rbx)
jne 0x622c
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 0x4d12f
jmp 0x622f
// File: /workspace/github_cpp_makefile_star2_O2/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 0x6287
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x38(%rsi), %rdi
callq 0x4cd95
movl 0xc8(%rbx), %eax
testl %eax, %eax
je 0x6278
cmpl $0x0, 0x28(%r14)
jne 0x6278
movl %eax, 0x28(%r14)
movq %rbx, %rdi
callq 0x43d0
addq $0x8, %rsp
popq %rbx
popq %r14
pushq $0x1
popq %rax
retq
// File: /workspace/github_cpp_makefile_star2_O2/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 0x65ff
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x28(%rsi), %rdi
callq 0x4cd95
movl 0xb8(%rbx), %eax
testl %eax, %eax
je 0x65f0
cmpl $0x0, 0x28(%r14)
jne 0x65f0
movl %eax, 0x28(%r14)
movq %rbx, %rdi
callq 0x43d0
addq $0x8, %rsp
popq %rbx
popq %r14
pushq $0x1
popq %rax
retq
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/DiffData.cpp
// Function: zipFileData_isSame(UnZipper*, int, UnZipper*, int)
bool zipFileData_isSame(UnZipper* selfZip,int selfIndex,UnZipper* srcZip,int srcIndex){
    uint32_t selfFileSize=UnZipper_file_uncompressedSize(selfZip,selfIndex);
    if (selfFileSize!=UnZipper_file_uncompressedSize(srcZip,srcIndex)) return false;
    if (selfFileSize==0) return true;
    std::vector<TByte> buf(selfFileSize*2);
    hpatch_TStreamOutput stream;
    mem_as_hStreamOutput(&stream,buf.data(),buf.data()+selfFileSize);
    check(UnZipper_fileData_decompressTo(selfZip,selfIndex,&stream));
    mem_as_hStreamOutput(&stream,buf.data()+selfFileSize,buf.data()+selfFileSize*2);
    check(UnZipper_fileData_decompressTo(srcZip,srcIndex,&stream));
    return 0==memcmp(buf.data(),buf.data()+selfFileSize,selfFileSize);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %ecx, %ebx
movq %rdx, %r14
movl %esi, %ebp
movq %rdi, %r13
callq 0x37b03
movl %eax, %r15d
movq %r14, %rdi
movl %ebx, %esi
callq 0x37b03
cmpl %eax, %r15d
jne 0x698a
testl %r15d, %r15d
je 0x698e
leal (%r15,%r15), %r12d
movq %rsp, %rdi
leaq 0x18(%rsp), %rdx
movq %r12, %rsi
callq 0x8384
movq %rsp, %rax
movq (%rax), %rsi
movl %r15d, %r15d
leaq (%rsi,%r15), %rdx
leaq 0x18(%rsp), %rdi
callq 0x3a656
leaq 0x18(%rsp), %rdx
movq %r13, %rdi
movl %ebp, %esi
xorl %ecx, %ecx
callq 0x37f48
testb %al, %al
je 0x69a1
movq (%rsp), %rax
leaq (%rax,%r15), %rsi
addq %rax, %r12
leaq 0x18(%rsp), %rdi
movq %r12, %rdx
callq 0x3a656
leaq 0x18(%rsp), %rdx
movq %r14, %rdi
movl %ebx, %esi
xorl %ecx, %ecx
callq 0x37f48
testb %al, %al
je 0x69c6
movq %rsp, %r14
movq (%r14), %rdi
leaq (%rdi,%r15), %rsi
movq %r15, %rdx
callq 0x4350
testl %eax, %eax
sete %bl
movq %r14, %rdi
callq 0x8b88
jmp 0x6990
xorl %ebx, %ebx
jmp 0x6990
movb $0x1, %bl
movl %ebx, %eax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x48f16(%rip), %rdi     # 0x4f8be
callq 0x4510
leaq 0x4869c(%rip), %rdi     # 0x4f050
leaq 0x4869b(%rip), %rsi     # 0x4f056
leaq 0x486aa(%rip), %rcx     # 0x4f06c
pushq $0x39
jmp 0x69e9
leaq 0x48af6(%rip), %rdi     # 0x4f4c3
callq 0x4510
leaq 0x48677(%rip), %rdi     # 0x4f050
leaq 0x48676(%rip), %rsi     # 0x4f056
leaq 0x48685(%rip), %rcx     # 0x4f06c
pushq $0x3b
popq %rdx
callq 0x4230
movq %rax, %rbx
movq %rsp, %rdi
callq 0x8b88
movq %rbx, %rdi
callq 0x4600
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/DiffData.cpp
// Function: getZipIsSame(char const*, char const*, int, bool*)
bool getZipIsSame(const char* oldZipPath,const char* newZipPath,
                  int newApkFilesRemoved,bool* out_isOldHaveApkV2Sign){
    hpatch_TFileStreamInput    oldZipStream;
    hpatch_TFileStreamInput    newZipStream;
    bool            result=true;
    bool            _isInClear=false;
    
    hpatch_TFileStreamInput_init(&oldZipStream);
    hpatch_TFileStreamInput_init(&newZipStream);
    check_clear(hpatch_TFileStreamInput_open(&oldZipStream,oldZipPath));
    check_clear(hpatch_TFileStreamInput_open(&newZipStream,newZipPath));
    result=getZipIsSameWithStream(&oldZipStream.base,&newZipStream.base,
                                  newApkFilesRemoved,out_isOldHaveApkV2Sign);
clear:
    _isInClear=true;
    check_clear(hpatch_TFileStreamInput_close(&newZipStream));
    check_clear(hpatch_TFileStreamInput_close(&oldZipStream));
    return result;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x80, %rsp
movq %rcx, %rbx
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rsi
xorps %xmm0, %xmm0
leaq 0x40(%rsp), %rdi
movaps %xmm0, (%rdi)
movaps %xmm0, 0x10(%rdi)
movaps %xmm0, 0x20(%rdi)
movaps %xmm0, 0x30(%rdi)
movaps %xmm0, (%rsp)
movaps %xmm0, 0x10(%rsp)
movaps %xmm0, 0x20(%rsp)
movaps %xmm0, 0x30(%rsp)
callq 0x3e9c9
testl %eax, %eax
je 0x6e77
movq %rsp, %rdi
movq %r14, %rsi
callq 0x3e9c9
testl %eax, %eax
je 0x6e9c
leaq 0x40(%rsp), %rdi
movq %rsp, %r14
movq %r14, %rsi
movl %ebp, %edx
movq %rbx, %rcx
callq 0x6a02
movl %eax, %ebx
movq %r14, %rdi
callq 0x3ec30
testl %eax, %eax
je 0x6ec5
leaq 0x40(%rsp), %rdi
callq 0x3ec30
testl %eax, %eax
je 0x6ef0
movl %ebx, %eax
addq $0x80, %rsp
popq %rbx
popq %r14
popq %rbp
retq
leaq 0x487e1(%rip), %rdi     # 0x4f65f
callq 0x4510
leaq 0x481c6(%rip), %rdi     # 0x4f050
leaq 0x481c5(%rip), %rsi     # 0x4f056
leaq 0x48271(%rip), %rcx     # 0x4f109
pushq $0x7a
jmp 0x6ebf
leaq 0x487fa(%rip), %rdi     # 0x4f69d
callq 0x4510
leaq 0x481a1(%rip), %rdi     # 0x4f050
leaq 0x481a0(%rip), %rsi     # 0x4f056
leaq 0x4824c(%rip), %rcx     # 0x4f109
pushq $0x7b
popq %rdx
callq 0x4230
leaq 0x4880f(%rip), %rdi     # 0x4f6db
callq 0x4510
leaq 0x48178(%rip), %rdi     # 0x4f050
leaq 0x48177(%rip), %rsi     # 0x4f056
leaq 0x48223(%rip), %rcx     # 0x4f109
movl $0x80, %edx
callq 0x4230
leaq 0x48818(%rip), %rdi     # 0x4f70f
callq 0x4510
leaq 0x4814d(%rip), %rdi     # 0x4f050
leaq 0x4814c(%rip), %rsi     # 0x4f056
leaq 0x481f8(%rip), %rcx     # 0x4f109
movl $0x81, %edx
callq 0x4230
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/DiffData.cpp
// Function: getCompressedFilesInfosWithZip(UnZipper const*, TCompressedFilesInfos*)
bool getCompressedFilesInfosWithZip(const UnZipper* zip,TCompressedFilesInfos* out_infos){
    TCompressedFilesInfos infos={0};
    int fcount=UnZipper_fileCount(zip);
    for (int i=0;i<fcount;++i){
            if (UnZipper_file_isCompressed(zip,i)){
            infos.compressedCount++;
            infos.sumCompressedSize+=UnZipper_file_compressedSize(zip,i);
            infos.sumCompressedUncompressedSize+=UnZipper_file_uncompressedSize(zip,i);
        }else{
            infos.uncompressedCount++;
            infos.sumUncompressedSize+=UnZipper_file_uncompressedSize(zip,i);
        }
    }
    *out_infos=infos;
    return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, 0x10(%rsp)
movq %rdi, %r14
callq 0x36bfd
movl %eax, %ebp
xorl %ecx, %ecx
testl %eax, %eax
movl $0x0, %eax
movq %rax, (%rsp)
cmovlel %ecx, %ebp
xorl %r13d, %r13d
movq $0x0, 0x8(%rsp)
xorl %r12d, %r12d
xorl %ebx, %ebx
xorl %r15d, %r15d
cmpl %r15d, %ebp
je 0x6fb5
movq %r14, %rdi
movl %r15d, %esi
callq 0x370d6
testb %al, %al
je 0x6f9e
movq (%rsp), %rax
incl %eax
movq %rax, (%rsp)
movq %r14, %rdi
movl %r15d, %esi
callq 0x37b16
movl %eax, %eax
addq %rax, 0x8(%rsp)
movq %r14, %rdi
movl %r15d, %esi
callq 0x37b03
movl %eax, %eax
addq %rax, %r12
jmp 0x6fb0
incl %ebx
movq %r14, %rdi
movl %r15d, %esi
callq 0x37b03
movl %eax, %eax
addq %rax, %r13
incl %r15d
jmp 0x6f5c
movq 0x10(%rsp), %rax
movl %ebx, (%rax)
movq (%rsp), %rcx
movl %ecx, 0x4(%rax)
movq %r13, 0x8(%rax)
movq 0x8(%rsp), %rcx
movq %rcx, 0x10(%rax)
movq %r12, 0x18(%rax)
movb $0x1, %al
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/DiffData.cpp
// Function: getCompressedFilesInfosWithStream(hpatch_TStreamInput const*, TCompressedFilesInfos*)
bool getCompressedFilesInfosWithStream(const hpatch_TStreamInput* zipStream,TCompressedFilesInfos* out_infos){
    UnZipper            zip;
    bool            result=true;
    bool            _isInClear=false;
    UnZipper_init(&zip);
    check_clear(UnZipper_openStream(&zip,zipStream));
    result=getCompressedFilesInfosWithZip(&zip,out_infos);
clear:
    _isInClear=true;
    check_clear(UnZipper_close(&zip));
    return result;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0xb0, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movq %rsp, %r15
movq %r15, %rdi
callq 0x37105
movq %r15, %rdi
movq %r14, %rsi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x3719a
testb %al, %al
je 0x7041
movq %rsp, %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0x6f1b
movq %r14, %rdi
callq 0x37111
testb %al, %al
je 0x706c
movb $0x1, %al
addq $0xb0, %rsp
popq %rbx
popq %r14
popq %r15
retq
leaq 0x486fb(%rip), %rdi     # 0x4f743
callq 0x4510
leaq 0x47ffc(%rip), %rdi     # 0x4f050
leaq 0x47ffb(%rip), %rsi     # 0x4f056
leaq 0x480e2(%rip), %rcx     # 0x4f144
movl $0x9d, %edx
callq 0x4230
leaq 0x486fb(%rip), %rdi     # 0x4f76e
callq 0x4510
leaq 0x47fd1(%rip), %rdi     # 0x4f050
leaq 0x47fd0(%rip), %rsi     # 0x4f056
leaq 0x480b7(%rip), %rcx     # 0x4f144
movl $0xa1, %edx
callq 0x4230
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/DiffData.cpp
// Function: getCompressedFilesInfos(char const*, TCompressedFilesInfos*)
bool getCompressedFilesInfos(const char* zipPath,TCompressedFilesInfos* out_infos){
    hpatch_TFileStreamInput    zipStream;
    bool            result=true;
    bool            _isInClear=false;
    
    hpatch_TFileStreamInput_init(&zipStream);
    check_clear(hpatch_TFileStreamInput_open(&zipStream,zipPath));
    result=getCompressedFilesInfosWithStream(&zipStream.base,out_infos);
clear:
    _isInClear=true;
    check_clear(hpatch_TFileStreamInput_close(&zipStream));
    return result;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rsi, %rbx
movq %rdi, %rsi
xorps %xmm0, %xmm0
movq %rsp, %rdi
movaps %xmm0, 0x30(%rdi)
movaps %xmm0, 0x20(%rdi)
movaps %xmm0, 0x10(%rdi)
movaps %xmm0, (%rdi)
callq 0x3e9c9
testl %eax, %eax
je 0x70e6
movq %rsp, %r14
movq %r14, %rdi
movq %rbx, %rsi
callq 0x6fe5
movq %r14, %rdi
callq 0x3ec30
testl %eax, %eax
je 0x7111
movb $0x1, %al
addq $0x48, %rsp
popq %rbx
popq %r14
retq
leaq 0x4869d(%rip), %rdi     # 0x4f78a
callq 0x4510
leaq 0x47f57(%rip), %rdi     # 0x4f050
leaq 0x47f56(%rip), %rsi     # 0x4f056
leaq 0x4809a(%rip), %rcx     # 0x4f1a1
movl $0xab, %edx
callq 0x4230
leaq 0x486aa(%rip), %rdi     # 0x4f7c2
callq 0x4510
leaq 0x47f2c(%rip), %rdi     # 0x4f050
leaq 0x47f2b(%rip), %rsi     # 0x4f056
leaq 0x4806f(%rip), %rcx     # 0x4f1a1
movl $0xaf, %edx
callq 0x4230
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/DiffData.cpp
// Function: getCompressedIsNormalizedBy(UnZipper*, int, int, bool)
bool getCompressedIsNormalizedBy(UnZipper* zip,int zlibCompressLevel,int zlibCompressMemLevel,bool testReCompressedByApkV2Sign){
    std::vector<TByte> oldCompressedCode;
    std::vector<TByte> newCompressedCode;
    int fileCount=UnZipper_fileCount(zip);
    for (int i=0; i<fileCount; ++i) {
        if (!UnZipper_file_isCompressed(zip,i)) continue;
        if (testReCompressedByApkV2Sign ^ UnZipper_file_isReCompressedByApkV2Sign(zip,i)) continue;
        check(getNormalizedCompressedCode(zip,i,newCompressedCode,zlibCompressLevel,zlibCompressMemLevel));
        size_t compressedSize=UnZipper_file_compressedSize(zip,i);
        if (compressedSize!=newCompressedCode.size()) return false;
        
        ZipFilePos_t pos=UnZipper_fileData_offset(zip,i);
        oldCompressedCode.resize(compressedSize);
        check(UnZipper_fileData_read(zip,pos,oldCompressedCode.data(),oldCompressedCode.data()+compressedSize));
        if (0!=memcmp(newCompressedCode.data(),oldCompressedCode.data(),compressedSize))
            return false;
    }
    return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %ecx, %ebx
movl %edx, 0xc(%rsp)
movl %esi, 0x8(%rsp)
movq %rdi, %r15
xorps %xmm0, %xmm0
movaps %xmm0, 0x30(%rsp)
andq $0x0, 0x40(%rsp)
movaps %xmm0, 0x10(%rsp)
andq $0x0, 0x20(%rsp)
callq 0x36bfd
xorl %r13d, %r13d
testl %eax, %eax
movl $0x0, %r14d
movl %eax, 0x4(%rsp)
cmovgl %eax, %r14d
cmpl %r13d, %r14d
je 0x7244
movq %r15, %rdi
movl %r13d, %esi
callq 0x370d6
testb %al, %al
je 0x723c
movq %r15, %rdi
movl %r13d, %esi
callq 0x370b0
cmpb %bl, %al
jne 0x723c
movq %r15, %rdi
movl %r13d, %esi
leaq 0x10(%rsp), %rdx
movl 0x8(%rsp), %ecx
movl 0xc(%rsp), %r8d
callq 0x72ec
testb %al, %al
je 0x7271
movq %r15, %rdi
movl %r13d, %esi
callq 0x37b16
movl %eax, %r12d
movq 0x18(%rsp), %rax
subq 0x10(%rsp), %rax
cmpq %r12, %rax
jne 0x7244
movq %r15, %rdi
movl %r13d, %esi
callq 0x37b5f
movl %eax, %ebp
leaq 0x30(%rsp), %rdi
movq %r12, %rsi
callq 0x843c
movq 0x30(%rsp), %rdx
leaq (%rdx,%r12), %rcx
movq %r15, %rdi
movl %ebp, %esi
callq 0x3766d
testb %al, %al
je 0x729c
movq 0x10(%rsp), %rdi
movq 0x30(%rsp), %rsi
movq %r12, %rdx
callq 0x4350
testl %eax, %eax
jne 0x7244
incl %r13d
jmp 0x7188
cmpl 0x4(%rsp), %r13d
setge %bl
leaq 0x10(%rsp), %rdi
callq 0x8b88
leaq 0x30(%rsp), %rdi
callq 0x8b88
movl %ebx, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x4857b(%rip), %rdi     # 0x4f7f3
callq 0x4510
leaq 0x47dcc(%rip), %rdi     # 0x4f050
leaq 0x47dcb(%rip), %rsi     # 0x4f056
leaq 0x47f53(%rip), %rcx     # 0x4f1e5
movl $0xcb, %edx
callq 0x4230
leaq 0x485b3(%rip), %rdi     # 0x4f856
callq 0x4510
leaq 0x47da1(%rip), %rdi     # 0x4f050
leaq 0x47da0(%rip), %rsi     # 0x4f056
leaq 0x47f28(%rip), %rcx     # 0x4f1e5
movl $0xd1, %edx
callq 0x4230
jmp 0x72cd
jmp 0x72cd
jmp 0x72cd
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x8b88
leaq 0x30(%rsp), %rdi
callq 0x8b88
movq %rbx, %rdi
callq 0x4600
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/DiffData.cpp
// Function: getNormalizedCompressedCode(UnZipper*, int, std::vector<unsigned char, std::allocator<unsigned char>>&, int, int)
static bool getNormalizedCompressedCode(UnZipper* selfZip,int selfIndex,
                                        std::vector<TByte>& out_compressedCode,
                                        int zlibCompressLevel,int zlibCompressMemLevel){
    size_t selfFileSize=UnZipper_file_uncompressedSize(selfZip,selfIndex);
    size_t maxCodeSize=Zipper_compressData_maxCodeSize(selfFileSize);
    std::vector<TByte>& buf(out_compressedCode);
    buf.resize(maxCodeSize+selfFileSize);
    hpatch_TStreamOutput stream;
    mem_as_hStreamOutput(&stream,buf.data()+maxCodeSize,buf.data()+maxCodeSize+selfFileSize);
    check(UnZipper_fileData_decompressTo(selfZip,selfIndex,&stream));
    size_t compressedSize=Zipper_compressData(buf.data()+maxCodeSize,selfFileSize,buf.data(),
                                              maxCodeSize,zlibCompressLevel,zlibCompressMemLevel);
    buf.resize(compressedSize);
    return compressedSize>0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movl %r8d, 0x4(%rsp)
movl %ecx, (%rsp)
movq %rdx, %rbx
movl %esi, %r13d
movq %rdi, %rbp
callq 0x37b03
movl %eax, %r15d
movq %r15, %rdi
callq 0x3878e
movq %rax, %r12
leaq (%rax,%r15), %rsi
movq %rbx, %rdi
callq 0x843c
movq (%rbx), %rsi
addq %r12, %rsi
leaq (%rsi,%r15), %rdx
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x3a656
movq %rbp, %rdi
movl %r13d, %esi
movq %r14, %rdx
xorl %ecx, %ecx
callq 0x37f48
testb %al, %al
je 0x7395
movq (%rbx), %rdx
movq %r12, %rdi
addq %rdx, %rdi
movq %r15, %rsi
movq %r12, %rcx
movl (%rsp), %r8d
movl 0x4(%rsp), %r9d
callq 0x38793
movq %rax, %r14
movq %rbx, %rdi
movq %rax, %rsi
callq 0x843c
testq %r14, %r14
setne %al
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x48522(%rip), %rdi     # 0x4f8be
callq 0x4510
leaq 0x47ca8(%rip), %rdi     # 0x4f050
leaq 0x47ca7(%rip), %rsi     # 0x4f056
leaq 0x47ff0(%rip), %rcx     # 0x4f3a6
movl $0xbc, %edx
callq 0x4230
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/DiffData.cpp
// Function: getCompressedIsNormalized(UnZipper*, int*, int*, bool)
bool getCompressedIsNormalized(UnZipper* zip,int* out_zlibCompressLevel,
                               int* out_zlibCompressMemLevel,bool testReCompressedByApkV2Sign){
    if (getCompressedIsNormalizedBy(zip,kDefaultZlibCompressLevel,kDefaultZlibCompressMemLevel,testReCompressedByApkV2Sign)){
        *out_zlibCompressLevel=kDefaultZlibCompressLevel;
        *out_zlibCompressMemLevel=kDefaultZlibCompressMemLevel;
        return true;
    }
    if (getCompressedIsNormalizedBy(zip,Z_BEST_COMPRESSION,kDefaultZlibCompressMemLevel,testReCompressedByApkV2Sign)){
        *out_zlibCompressLevel=Z_BEST_COMPRESSION;
        *out_zlibCompressMemLevel=kDefaultZlibCompressMemLevel;
        return true;
    }
    for (int ml=MAX_MEM_LEVEL;ml>=1;--ml){
        for (int cl=Z_BEST_SPEED;cl<=Z_BEST_COMPRESSION;++cl){
            if ((cl==kDefaultZlibCompressLevel)&(ml==kDefaultZlibCompressMemLevel)) continue;
            if ((cl==Z_BEST_COMPRESSION)&(ml==kDefaultZlibCompressMemLevel)) continue;
            if (getCompressedIsNormalizedBy(zip,cl,ml,testReCompressedByApkV2Sign)){
                *out_zlibCompressLevel=cl;
                *out_zlibCompressMemLevel=ml;
                return true;
            }
        }
    }
    return false;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %r13d
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
pushq $0x6
popq %r12
pushq $0x8
popq %rbp
movl %r12d, %esi
movl %ebp, %edx
callq 0x713c
testb %al, %al
jne 0x745b
movzbl %r13b, %r13d
pushq $0x9
popq %r12
pushq $0x8
popq %rbp
movq %r15, %rdi
movl %r12d, %esi
movl %ebp, %edx
movl %r13d, %ecx
callq 0x713c
testb %al, %al
jne 0x745b
movq %rbx, (%rsp)
pushq $0x9
popq %rbp
movl %ebp, %ebx
subl $0x1, %ebx
jb 0x7471
pushq $0x1
popq %r12
cmpl $0xa, %r12d
je 0x7453
cmpl $0x6, %r12d
sete %al
cmpl $0x9, %r12d
sete %cl
cmpl $0x8, %ebp
jne 0x743a
orb %cl, %al
jne 0x744e
movq %r15, %rdi
movl %r12d, %esi
movl %ebp, %edx
movl %r13d, %ecx
callq 0x713c
testb %al, %al
jne 0x7457
incl %r12d
jmp 0x741d
movl %ebx, %ebp
jmp 0x7414
movq (%rsp), %rbx
movl %r12d, (%r14)
movl %ebp, (%rbx)
movb $0x1, %al
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
xorl %eax, %eax
jmp 0x7462
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/DiffData.cpp
// Function: getBaseAlignSize_unsafe(UnZipper*)
size_t getBaseAlignSize_unsafe(UnZipper* self){
    int fCount=UnZipper_fileCount(self);
    ZipFilePos_t minOffset=1024*64; //set search max AlignSize
    std::vector<ZipFilePos_t> offsetList;
    ZipFilePos_t lastDataPos=0;
    for (int i=0; i<fCount; ++i) {
        if (UnZipper_file_isCompressed(self,i)) continue;
        const ZipFilePos_t dataPos=UnZipper_fileData_offset(self,i);
        if (dataPos<=lastDataPos) return 0; // not normalized
        ZipFilePos_t offset=dataPos-lastDataPos;
        lastDataPos=dataPos;
        if (offset<minOffset) minOffset=offset;
        offsetList.push_back(offset);
    }
    if (offsetList.empty())
        return 1;
    for (ZipFilePos_t align=minOffset; align>1; --align) {
        if (_isAligned(offsetList,align))
            return align;
    }
    return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %r14
callq 0x36bfd
movl %eax, %ebp
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rax
movaps %xmm0, (%rax)
andq $0x0, 0x10(%rax)
xorl %eax, %eax
testl %ebp, %ebp
cmovlel %eax, %ebp
movl $0x10000, %r12d         # imm = 0x10000
movl $0x0, 0x8(%rsp)
xorl %r13d, %r13d
cmpl %r13d, %ebp
je 0x7503
movq %r14, %rdi
movl %r13d, %esi
callq 0x370d6
testb %al, %al
jne 0x74fe
movq %r14, %rdi
movl %r13d, %esi
callq 0x37b5f
movl %eax, %r15d
movl %eax, %ebx
subl 0x8(%rsp), %ebx
jbe 0x7559
movl %ebx, 0xc(%rsp)
leaq 0x10(%rsp), %rdi
leaq 0xc(%rsp), %rsi
callq 0x8468
cmpl %r12d, %ebx
cmovbl %ebx, %r12d
movl %r15d, 0x8(%rsp)
incl %r13d
jmp 0x74b5
movq 0x10(%rsp), %rcx
movq 0x18(%rsp), %rsi
pushq $0x1
popq %rbx
cmpq %rsi, %rcx
je 0x755b
subq %rcx, %rsi
sarq $0x2, %rsi
movq %rsi, %rdi
negq %rdi
pushq $-0x1
popq %r8
cmpl $0x2, %r12d
jb 0x755b
movq %r8, %r9
leaq (%rdi,%r9), %rax
cmpq $-0x1, %rax
je 0x7554
movl 0x4(%rcx,%r9,4), %eax
xorl %edx, %edx
divl %r12d
incq %r9
testl %edx, %edx
je 0x752f
cmpq %rsi, %r9
jae 0x7554
decl %r12d
jmp 0x7526
movl %r12d, %ebx
jmp 0x755b
xorl %ebx, %ebx
leaq 0x10(%rsp), %rdi
callq 0x90f0
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x757b
jmp 0x757b
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x90f0
movq %rbx, %rdi
callq 0x4600
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/../../HDiffPatch/libHDiffPatch/HDiff/private_diff/pack_uint.h
// Function: void hdiff_private::packUIntWithTag<unsigned int>(std::vector<unsigned char, std::allocator<unsigned char>>&, unsigned int, int, int)
inline static void packUIntWithTag(std::vector<unsigned char>& out_code,_UInt uValue,
                                   int highTag,const int kTagBit){
    unsigned char  codeBuf[hpatch_kMaxPackedUIntBytes];
    unsigned char* codeEnd=codeBuf;
    if (!hpatch_packUIntWithTag(&codeEnd,codeBuf+hpatch_kMaxPackedUIntBytes,uValue,highTag,kTagBit))
        throw std::runtime_error("packUIntWithTag<_UInt>() hpatch_packUIntWithTag() error!");
    out_code.insert(out_code.end(),codeBuf,codeEnd);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movl %ecx, %r8d
movl %edx, %ecx
movq %rdi, %rbx
leaq 0x5(%rsp), %rax
leaq 0x10(%rsp), %rdi
movq %rax, (%rdi)
leaq 0x10(%rsp), %rax
movl %esi, %edx
movq %rax, %rsi
callq 0x3a508
testl %eax, %eax
je 0x8254
movq 0x8(%rbx), %rsi
movq 0x10(%rsp), %rcx
leaq 0x5(%rsp), %rdx
movq %rbx, %rdi
callq 0x85ae
addq $0x18, %rsp
popq %rbx
popq %r14
retq
pushq $0x10
popq %rdi
callq 0x41c0
movq %rax, %rbx
leaq 0x4719a(%rip), %rsi     # 0x4f400
movq %rax, %rdi
callq 0x4120
movq 0x6cd73(%rip), %rsi     # 0x74fe8
movq 0x6cd3c(%rip), %rdx     # 0x74fb8
movq %rbx, %rdi
callq 0x45b0
movq %rax, %r14
movq %rbx, %rdi
callq 0x4290
movq %r14, %rdi
callq 0x4600
// File: /workspace/github_cpp_makefile_star2_O2/sisong[P]ApkDiffPatch/src/diff/DiffData.cpp
// Function: pushIncList(std::vector<unsigned char, std::allocator<unsigned char>>&, unsigned int const*, unsigned long)
static void pushIncList(std::vector<TByte>& out_data,const uint32_t* list,size_t count){
    uint32_t backValue=~(uint32_t)0;
    for (size_t i=0;i<count;++i){
        uint32_t curValue=list[i];
        packUInt(out_data,(uint32_t)(curValue-(uint32_t)(backValue+1)));
        backValue=curValue;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
pushq $-0x1
popq %rsi
xorl %r12d, %r12d
cmpq %r12, %rbx
je 0x82ca
movl (%r14,%r12,4), %ebp
notl %esi
addl %ebp, %esi
movq %r15, %rdi
callq 0x8201
incq %r12
movl %ebp, %esi
jmp 0x82ae
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq