LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_destroy
HTSLIB_EXPORT
void hfile_destroy(hFILE *fp)
{
    int save = errno;
    if (fp) free(fp->buffer);
    free(fp);
    errno = save;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
callq 0x4050
movl (%rax), %eax
movl %eax, -0xc(%rbp)
cmpq $0x0, -0x8(%rbp)
je 0x139a9
movq -0x8(%rbp), %rax
movq (%rax), %rdi
callq 0x45a0
movq -0x8(%rbp), %rdi
callq 0x45a0
movl -0xc(%rbp), %eax
movl %eax, -0x10(%rbp)
callq 0x4050
movl -0x10(%rbp), %ecx
movl %ecx, (%rax)
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_init_fixed
hFILE *hfile_init_fixed(size_t struct_size, const char *mode,
                        char *buffer, size_t buf_filled, size_t buf_size)
{
    hFILE *fp = (hFILE *) malloc(struct_size);
    if (fp == NULL) return NULL;

    fp->buffer = fp->begin = buffer;
    fp->end = &fp->buffer[buf_filled];
    fp->limit = &fp->buffer[buf_size];

    fp->offset = 0;
    fp->at_eof = 1;
    fp->mobile = 0;
    fp->readonly = (strchr(mode, 'r') && ! strchr(mode, '+'));
    fp->preserve = 0;
    fp->has_errno = 0;
    return fp;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
movq -0x10(%rbp), %rdi
callq 0x4650
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
jne 0x13a0d
movq $0x0, -0x8(%rbp)
jmp 0x13aea
movq -0x20(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x38(%rbp), %rax
movq %rcx, (%rax)
movq -0x38(%rbp), %rax
movq (%rax), %rcx
addq -0x28(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x38(%rbp), %rax
movq (%rax), %rcx
addq -0x30(%rbp), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x38(%rbp), %rax
movq $0x0, 0x28(%rax)
movq -0x38(%rbp), %rax
movb 0x30(%rax), %cl
andb $-0x2, %cl
orb $0x1, %cl
movb %cl, 0x30(%rax)
movq -0x38(%rbp), %rax
movb 0x30(%rax), %cl
andb $-0x3, %cl
orb $0x0, %cl
movb %cl, 0x30(%rax)
movq -0x18(%rbp), %rdi
movl $0x72, %esi
callq 0x4170
movq %rax, %rcx
xorl %eax, %eax
cmpq $0x0, %rcx
movb %al, -0x39(%rbp)
je 0x13aa8
movq -0x18(%rbp), %rdi
movl $0x2b, %esi
callq 0x4170
cmpq $0x0, %rax
setne %al
xorb $-0x1, %al
movb %al, -0x39(%rbp)
movb -0x39(%rbp), %al
andb $0x1, %al
movzbl %al, %ecx
movq -0x38(%rbp), %rax
movb %cl, %dl
movb 0x30(%rax), %cl
andb $0x1, %dl
shlb $0x2, %dl
andb $-0x5, %cl
orb %dl, %cl
movb %cl, 0x30(%rax)
movq -0x38(%rbp), %rax
movb 0x30(%rax), %cl
andb $-0x9, %cl
orb $0x0, %cl
movb %cl, 0x30(%rax)
movq -0x38(%rbp), %rax
movl $0x0, 0x34(%rax)
movq -0x38(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_set_blksize
HTSLIB_EXPORT
int hfile_set_blksize(hFILE *fp, size_t bufsiz) {
    char *buffer;
    ptrdiff_t curr_used;
    if (!fp) return -1;
    curr_used = (fp->begin > fp->end ? fp->begin : fp->end) - fp->buffer;
    if (bufsiz == 0) bufsiz = 32768;

    // Ensure buffer resize will not erase live data
    if (bufsiz < curr_used)
        return -1;

    if (!(buffer = (char *) realloc(fp->buffer, bufsiz))) return -1;

    fp->begin  = buffer + (fp->begin - fp->buffer);
    fp->end    = buffer + (fp->end   - fp->buffer);
    fp->buffer = buffer;
    fp->limit  = &fp->buffer[bufsiz];

    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0x13b23
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x13c10
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
cmpq 0x10(%rcx), %rax
jbe 0x13b43
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x30(%rbp)
jmp 0x13b4f
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
subq %rcx, %rax
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x13b70
movq $0x8000, -0x18(%rbp)    # imm = 0x8000
movq -0x18(%rbp), %rax
cmpq -0x28(%rbp), %rax
jae 0x13b86
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x13c10
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rsi
callq 0x4820
movq %rax, -0x20(%rbp)
cmpq $0x0, %rax
jne 0x13ba9
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x13c10
movq -0x20(%rbp), %rcx
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rdx
movq (%rdx), %rdx
subq %rdx, %rax
addq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x20(%rbp), %rcx
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rdx
movq (%rdx), %rdx
subq %rdx, %rax
addq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x20(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rcx
addq -0x18(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x18(%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: refill_buffer
static ssize_t refill_buffer(hFILE *fp)
{
    ssize_t n;

    // Move any unread characters to the start of the buffer
    if (fp->mobile && fp->begin > fp->buffer) {
        fp->offset += fp->begin - fp->buffer;
        memmove(fp->buffer, fp->begin, fp->end - fp->begin);
        fp->end = &fp->buffer[fp->end - fp->begin];
        fp->begin = fp->buffer;
    }

    // Read into the available buffer space at fp->[end,limit)
    if (fp->at_eof || fp->end == fp->limit) n = 0;
    else {
        n = fp->backend->read(fp, fp->end, fp->limit - fp->end);
        if (n < 0) { fp->has_errno = errno; return n; }
        else if (n == 0) fp->at_eof = 1;
    }

    fp->end += n;
    return n;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movb 0x30(%rax), %al
shrb %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0x13d1d
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
cmpq (%rcx), %rax
jbe 0x13d1d
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x10(%rbp), %rax
movq (%rax), %rax
subq %rax, %rcx
movq -0x10(%rbp), %rax
addq 0x28(%rax), %rcx
movq %rcx, 0x28(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rdx
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
subq %rax, %rdx
callq 0x4810
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rdx
movq 0x8(%rdx), %rdx
subq %rdx, %rax
addq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x10(%rbp), %rax
movb 0x30(%rax), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
jne 0x13d40
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
cmpq 0x18(%rcx), %rax
jne 0x13d4a
movq $0x0, -0x18(%rbp)
jmp 0x13db4
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq (%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x10(%rbp), %rcx
movq 0x10(%rcx), %rsi
movq -0x10(%rbp), %rcx
movq 0x18(%rcx), %rdx
movq -0x10(%rbp), %rcx
movq 0x10(%rcx), %rcx
subq %rcx, %rdx
callq *%rax
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
jge 0x13d99
callq 0x4050
movl (%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x34(%rax)
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x13dcc
cmpq $0x0, -0x18(%rbp)
jne 0x13db0
movq -0x10(%rbp), %rax
movb 0x30(%rax), %cl
andb $-0x2, %cl
orb $0x1, %cl
movb %cl, 0x30(%rax)
jmp 0x13db2
jmp 0x13db4
movq -0x18(%rbp), %rcx
movq -0x10(%rbp), %rax
addq 0x10(%rax), %rcx
movq %rcx, 0x10(%rax)
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hgets
char *hgets(char *buffer, int size, hFILE *fp)
{
    if (size < 1) {
        fp->has_errno = errno = EINVAL;
        return NULL;
    }
    return hgetln(buffer, size, fp) > 0 ? buffer : NULL;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq %rdx, -0x20(%rbp)
cmpl $0x1, -0x14(%rbp)
jge 0x14039
callq 0x4050
movl $0x16, (%rax)
movq -0x20(%rbp), %rax
movl $0x16, 0x34(%rax)
movq $0x0, -0x8(%rbp)
jmp 0x1406a
movq -0x10(%rbp), %rdi
movslq -0x14(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0x14080
cmpq $0x0, %rax
jle 0x1405a
movq -0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
jmp 0x14062
xorl %eax, %eax
movq %rax, -0x28(%rbp)
jmp 0x14062
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hpeek
ssize_t hpeek(hFILE *fp, void *buffer, size_t nbytes)
{
    size_t n = fp->end - fp->begin;
    while (n < nbytes) {
        ssize_t ret = refill_buffer(fp);
        if (ret < 0) return ret;
        else if (ret == 0) break;
        else n += ret;
    }

    if (n > nbytes) n = nbytes;
    memcpy(buffer, fp->begin, n);
    return n;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rcx
subq %rcx, %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
cmpq -0x20(%rbp), %rax
jae 0x1411c
movq -0x10(%rbp), %rdi
callq 0x13c70
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
jge 0x14103
movq -0x30(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x1414b
cmpq $0x0, -0x30(%rbp)
jne 0x1410c
jmp 0x1411c
movq -0x30(%rbp), %rax
addq -0x28(%rbp), %rax
movq %rax, -0x28(%rbp)
jmp 0x1411a
jmp 0x140db
movq -0x28(%rbp), %rax
cmpq -0x20(%rbp), %rax
jbe 0x1412e
movq -0x20(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
movq -0x28(%rbp), %rdx
callq 0x43b0
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hflush
int hflush(hFILE *fp)
{
    if (flush_buffer(fp) < 0) return EOF;
    if (fp->backend->flush) {
        if (fp->backend->flush(fp) < 0) { fp->has_errno = errno; return EOF; }
    }
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
callq 0x14430
cmpq $0x0, %rax
jge 0x143d4
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x1441a
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
cmpq $0x0, 0x18(%rax)
je 0x14413
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x18(%rax), %rax
movq -0x10(%rbp), %rdi
callq *%rax
cmpl $0x0, %eax
jge 0x14411
callq 0x4050
movl (%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x34(%rax)
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x1441a
jmp 0x14413
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: flush_buffer
static ssize_t flush_buffer(hFILE *fp)
{
    const char *buffer = fp->buffer;
    while (buffer < fp->begin) {
        ssize_t n = fp->backend->write(fp, buffer, fp->begin - buffer);
        if (n < 0) { fp->has_errno = errno; return n; }
        buffer += n;
        fp->offset += n;
    }

    fp->begin = fp->buffer;  // Leave the buffer empty
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
cmpq 0x8(%rcx), %rax
jae 0x144bb
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rdx
movq -0x18(%rbp), %rcx
subq %rcx, %rdx
callq *%rax
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jge 0x1449d
callq 0x4050
movl (%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x34(%rax)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x144d2
movq -0x20(%rbp), %rax
addq -0x18(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x20(%rbp), %rcx
movq -0x10(%rbp), %rax
addq 0x28(%rax), %rcx
movq %rcx, 0x28(%rax)
jmp 0x14447
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hwrite2
HTSLIB_EXPORT
ssize_t hwrite2(hFILE *fp, const void *srcv, size_t totalbytes, size_t ncopied)
{
    const char *src = (const char *) srcv;
    ssize_t ret;
    const size_t capacity = fp->limit - fp->buffer;
    size_t remaining = totalbytes - ncopied;
    src += ncopied;

    ret = flush_buffer(fp);
    if (ret < 0) return ret;

    // Write large blocks out directly from the source buffer
    while (remaining * 2 >= capacity) {
        ssize_t n = fp->backend->write(fp, src, remaining);
        if (n < 0) { fp->has_errno = errno; return n; }
        fp->offset += n;
        src += n, remaining -= n;
    }

    // Just buffer any remaining characters
    memcpy(fp->begin, src, remaining);
    fp->begin += remaining;

    return totalbytes;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
subq %rcx, %rax
movq %rax, -0x40(%rbp)
movq -0x20(%rbp), %rax
subq -0x28(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x28(%rbp), %rax
addq -0x30(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rdi
callq 0x14430
movq %rax, -0x38(%rbp)
cmpq $0x0, -0x38(%rbp)
jge 0x1459f
movq -0x38(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x14645
jmp 0x145a1
movq -0x48(%rbp), %rax
shlq %rax
cmpq -0x40(%rbp), %rax
jb 0x14618
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x30(%rbp), %rsi
movq -0x48(%rbp), %rdx
callq *%rax
movq %rax, -0x50(%rbp)
cmpq $0x0, -0x50(%rbp)
jge 0x145eb
callq 0x4050
movl (%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x34(%rax)
movq -0x50(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x14645
movq -0x50(%rbp), %rcx
movq -0x10(%rbp), %rax
addq 0x28(%rax), %rcx
movq %rcx, 0x28(%rax)
movq -0x50(%rbp), %rax
addq -0x30(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x50(%rbp), %rcx
movq -0x48(%rbp), %rax
subq %rcx, %rax
movq %rax, -0x48(%rbp)
jmp 0x145a1
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x30(%rbp), %rsi
movq -0x48(%rbp), %rdx
callq 0x43b0
movq -0x48(%rbp), %rcx
movq -0x10(%rbp), %rax
addq 0x8(%rax), %rcx
movq %rcx, 0x8(%rax)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hclose
int hclose(hFILE *fp)
{
    int err = fp->has_errno;

    if (writebuffer_is_nonempty(fp) && hflush(fp) < 0) err = fp->has_errno;
    if (!fp->preserve) {
        if (fp->backend->close(fp) < 0) err = errno;
        hfile_destroy(fp);
    }

    if (err) {
        errno = err;
        return EOF;
    }
    else return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movl 0x34(%rax), %eax
movl %eax, -0x14(%rbp)
movq -0x10(%rbp), %rdi
callq 0x13fd0
cmpl $0x0, %eax
je 0x1495c
movq -0x10(%rbp), %rdi
callq 0x143b0
cmpl $0x0, %eax
jge 0x1495c
movq -0x10(%rbp), %rax
movl 0x34(%rax), %eax
movl %eax, -0x14(%rbp)
movq -0x10(%rbp), %rax
movb 0x30(%rax), %al
shrb $0x3, %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
jne 0x1499a
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rdi
callq *%rax
cmpl $0x0, %eax
jge 0x14991
callq 0x4050
movl (%rax), %eax
movl %eax, -0x14(%rbp)
movq -0x10(%rbp), %rdi
callq 0x13980
cmpl $0x0, -0x14(%rbp)
je 0x149b9
movl -0x14(%rbp), %eax
movl %eax, -0x18(%rbp)
callq 0x4050
movl -0x18(%rbp), %ecx
movl %ecx, (%rax)
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x149c0
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hclose_abruptly
void hclose_abruptly(hFILE *fp)
{
    int save = errno;
    if (fp->preserve)
        return;
    if (fp->backend->close(fp) < 0) { /* Ignore subsequent errors */ }
    hfile_destroy(fp);
    errno = save;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
callq 0x4050
movl (%rax), %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
movb 0x30(%rax), %al
shrb $0x3, %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0x149fc
jmp 0x14a2e
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x20(%rax), %rax
movq -0x8(%rbp), %rdi
callq *%rax
cmpl $0x0, %eax
jge 0x14a15
jmp 0x14a15
movq -0x8(%rbp), %rdi
callq 0x13980
movl -0xc(%rbp), %eax
movl %eax, -0x10(%rbp)
callq 0x4050
movl -0x10(%rbp), %ecx
movl %ecx, (%rax)
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hdopen
hFILE *hdopen(int fd, const char *mode)
{
    hFILE_fd *fp = (hFILE_fd*) hfile_init(sizeof (hFILE_fd), mode, blksize(fd));
    if (fp == NULL) return NULL;

    fp->fd = fd;
    fp->is_socket = (strchr(mode, 's') != NULL);
    fp->is_shared = (strchr(mode, 'S') != NULL);
    fp->base.backend = &fd_backend;
    return &fp->base;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movl %edi, -0xc(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x28(%rbp)
movl -0xc(%rbp), %edi
callq 0x14b10
movq -0x28(%rbp), %rsi
movq %rax, %rdx
movl $0x40, %edi
callq 0x13800
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0x14a85
movq $0x0, -0x8(%rbp)
jmp 0x14b04
movl -0xc(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x38(%rax)
movq -0x18(%rbp), %rdi
movl $0x73, %esi
callq 0x4170
cmpq $0x0, %rax
setne %al
andb $0x1, %al
movzbl %al, %ecx
movq -0x20(%rbp), %rax
movb %cl, %dl
movb 0x3c(%rax), %cl
andb $0x1, %dl
andb $-0x2, %cl
orb %dl, %cl
movb %cl, 0x3c(%rax)
movq -0x18(%rbp), %rdi
movl $0x53, %esi
callq 0x4170
cmpq $0x0, %rax
setne %al
andb $0x1, %al
movzbl %al, %ecx
movq -0x20(%rbp), %rax
movb %cl, %dl
movb 0x3c(%rax), %cl
andb $0x1, %dl
shlb %dl
andb $-0x3, %cl
orb %dl, %cl
movb %cl, 0x3c(%rax)
movq -0x20(%rbp), %rax
leaq 0xf80d8(%rip), %rcx     # 0x10cbd0
movq %rcx, 0x20(%rax)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: blksize
static size_t blksize(int fd)
{
#ifdef HAVE_STRUCT_STAT_ST_BLKSIZE
    struct stat sbuf;
    if (fstat(fd, &sbuf) != 0) return 0;

    // Pipes/FIFOs on linux return 4Kb here often, but it's much too small
    // for performant I/O.
    return S_ISFIFO(sbuf.st_mode)
        ? 128*1024
        : sbuf.st_blksize;
#else
    return 0;
#endif
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movl %edi, -0xc(%rbp)
movl -0xc(%rbp), %edi
leaq -0xa0(%rbp), %rsi
callq 0x4870
cmpl $0x0, %eax
je 0x14b3c
movq $0x0, -0x8(%rbp)
jmp 0x14b72
movl -0x88(%rbp), %eax
andl $0xf000, %eax           # imm = 0xF000
cmpl $0x1000, %eax           # imm = 0x1000
jne 0x14b5c
movl $0x20000, %eax          # imm = 0x20000
movq %rax, -0xa8(%rbp)
jmp 0x14b67
movq -0x68(%rbp), %rax
movq %rax, -0xa8(%rbp)
movq -0xa8(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0xb0, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_oflags
HTSLIB_EXPORT
int hfile_oflags(const char *mode)
{
    int rdwr = 0, flags = 0;
    const char *s;
    for (s = mode; *s; s++)
        switch (*s) {
        case 'r': rdwr = O_RDONLY;  break;
        case 'w': rdwr = O_WRONLY; flags |= O_CREAT | O_TRUNC;  break;
        case 'a': rdwr = O_WRONLY; flags |= O_CREAT | O_APPEND;  break;
        case '+': rdwr = O_RDWR;  break;
#ifdef O_CLOEXEC
        case 'e': flags |= O_CLOEXEC;  break;
#endif
#ifdef O_EXCL
        case 'x': flags |= O_EXCL;  break;
#endif
        default:  break;
        }

#ifdef O_BINARY
    flags |= O_BINARY;
#endif

    return rdwr | flags;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl $0x0, -0xc(%rbp)
movl $0x0, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
cmpb $0x0, (%rax)
je 0x14c40
movq -0x18(%rbp), %rax
movsbl (%rax), %eax
movl %eax, -0x1c(%rbp)
subl $0x2b, %eax
je 0x14c15
jmp 0x14bbc
movl -0x1c(%rbp), %eax
subl $0x61, %eax
je 0x14c01
jmp 0x14bc6
movl -0x1c(%rbp), %eax
subl $0x72, %eax
je 0x14be4
jmp 0x14bd0
movl -0x1c(%rbp), %eax
subl $0x77, %eax
je 0x14bed
jmp 0x14bda
movl -0x1c(%rbp), %eax
subl $0x78, %eax
je 0x14c1e
jmp 0x14c2b
movl $0x0, -0xc(%rbp)
jmp 0x14c2d
movl $0x1, -0xc(%rbp)
movl -0x10(%rbp), %eax
orl $0x240, %eax            # imm = 0x240
movl %eax, -0x10(%rbp)
jmp 0x14c2d
movl $0x1, -0xc(%rbp)
movl -0x10(%rbp), %eax
orl $0x440, %eax            # imm = 0x440
movl %eax, -0x10(%rbp)
jmp 0x14c2d
movl $0x2, -0xc(%rbp)
jmp 0x14c2d
movl -0x10(%rbp), %eax
orl $0x80, %eax
movl %eax, -0x10(%rbp)
jmp 0x14c2d
jmp 0x14c2d
jmp 0x14c2f
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x14b9e
movl -0xc(%rbp), %eax
orl -0x10(%rbp), %eax
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_mem_get_buffer
char *hfile_mem_get_buffer(hFILE *file, size_t *length) {
    if (file->backend != &mem_backend) {
        errno = EINVAL;
        return NULL;
    }

    if (length)
        *length = file->buffer - file->limit;

    return file->buffer;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
leaq 0xf7f8d(%rip), %rcx     # 0x10cbf8
cmpq %rcx, 0x20(%rax)
je 0x14c86
callq 0x4050
movl $0x16, (%rax)
movq $0x0, -0x8(%rbp)
jmp 0x14cb1
cmpq $0x0, -0x18(%rbp)
je 0x14ca6
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
subq %rax, %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_mem_steal_buffer
char *hfile_mem_steal_buffer(hFILE *file, size_t *length) {
    char *buf = hfile_mem_get_buffer(file, length);
    if (buf)
        file->buffer = NULL;
    return buf;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x14c50
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
je 0x14cf3
movq -0x8(%rbp), %rax
movq $0x0, (%rax)
movq -0x18(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hopenv_mem
static hFILE *hopenv_mem(const char *filename, const char *mode, va_list args)
{
    char* buffer = va_arg(args, char*);
    size_t sz = va_arg(args, size_t);
    va_end(args);

    hFILE* hf;

    if(!(hf = create_hfile_mem(buffer, mode, sz, sz))){
        free(buffer);
        return NULL;
    }

    return hf;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x48(%rbp)
movl (%rax), %eax
movl %eax, -0x3c(%rbp)
cmpl $0x28, %eax
ja 0x14dbf
movq -0x48(%rbp), %rcx
movl -0x3c(%rbp), %edx
movslq %edx, %rax
addq 0x10(%rcx), %rax
addl $0x8, %edx
movl %edx, (%rcx)
movq %rax, -0x50(%rbp)
jmp 0x14dd6
movq -0x48(%rbp), %rcx
movq 0x8(%rcx), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, 0x8(%rcx)
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x60(%rbp)
movl (%rax), %eax
movl %eax, -0x54(%rbp)
cmpl $0x28, %eax
ja 0x14e0c
movq -0x60(%rbp), %rcx
movl -0x54(%rbp), %edx
movslq %edx, %rax
addq 0x10(%rcx), %rax
addl $0x8, %edx
movl %edx, (%rcx)
movq %rax, -0x68(%rbp)
jmp 0x14e23
movq -0x60(%rbp), %rcx
movq 0x8(%rcx), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, 0x8(%rcx)
movq %rax, -0x68(%rbp)
movq -0x68(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x20(%rbp), %rax
movq -0x28(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x30(%rbp), %rdx
movq -0x30(%rbp), %rcx
callq 0x16590
movq %rax, -0x38(%rbp)
cmpq $0x0, %rax
jne 0x14e64
movq -0x28(%rbp), %rdi
callq 0x45a0
movq $0x0, -0x8(%rbp)
jmp 0x14e6c
movq -0x38(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x70, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_add_scheme_handler
HTSLIB_EXPORT
void hfile_add_scheme_handler(const char *scheme,
                              const struct hFILE_scheme_handler *handler)
{
    int absent;
    if (handler->open == NULL || handler->isremote == NULL) {
        hts_log_warning("Couldn't register scheme handler for %s: missing method", scheme);
        return;
    }
    if (!schemes) {
        if (try_exe_add_scheme_handler(scheme, handler) != 0) {
            hts_log_warning("Couldn't register scheme handler for %s", scheme);
        }
        return;
    }
    khint_t k = kh_put(scheme_string, schemes, scheme, &absent);
    if (absent < 0) {
        hts_log_warning("Couldn't register scheme handler for %s : %s",
                        scheme, strerror(errno));
        return;
    }
    if (absent || priority(handler) > priority(kh_value(schemes, k))) {
        kh_value(schemes, k) = handler;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x0, (%rax)
je 0x14ea5
movq -0x10(%rbp), %rax
cmpq $0x0, 0x8(%rax)
jne 0x14ec8
movq -0x8(%rbp), %rcx
movl $0x3, %edi
leaq 0xda7a0(%rip), %rsi     # 0xef655
leaq 0xda7b2(%rip), %rdx     # 0xef66e
movb $0x0, %al
callq 0x1b030
jmp 0x14fa3
cmpq $0x0, 0xfd0c8(%rip)     # 0x111f98
jne 0x14f07
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x15170
cmpl $0x0, %eax
je 0x14f02
movq -0x8(%rbp), %rcx
movl $0x3, %edi
leaq 0xda761(%rip), %rsi     # 0xef655
leaq 0xda7ab(%rip), %rdx     # 0xef6a6
movb $0x0, %al
callq 0x1b030
jmp 0x14fa3
movq 0xfd08a(%rip), %rdi     # 0x111f98
movq -0x8(%rbp), %rsi
leaq -0x14(%rbp), %rdx
callq 0x15190
movl %eax, -0x18(%rbp)
cmpl $0x0, -0x14(%rbp)
jge 0x14f5b
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
callq 0x4050
movl (%rax), %edi
callq 0x4130
movq -0x20(%rbp), %rcx
movq %rax, %r8
movl $0x3, %edi
leaq 0xda70a(%rip), %rsi     # 0xef655
leaq 0xda77c(%rip), %rdx     # 0xef6ce
movb $0x0, %al
callq 0x1b030
jmp 0x14fa3
cmpl $0x0, -0x14(%rbp)
jne 0x14f8d
movq -0x10(%rbp), %rdi
callq 0x154f0
movl %eax, -0x24(%rbp)
movq 0xfd024(%rip), %rax     # 0x111f98
movq 0x20(%rax), %rax
movl -0x18(%rbp), %ecx
movq (%rax,%rcx,8), %rdi
callq 0x154f0
movl %eax, %ecx
movl -0x24(%rbp), %eax
cmpl %ecx, %eax
jle 0x14fa3
movq -0x10(%rbp), %rdx
movq 0xfd000(%rip), %rax     # 0x111f98
movq 0x20(%rax), %rax
movl -0x18(%rbp), %ecx
movq %rdx, (%rax,%rcx,8)
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: crypt4gh_needed
static hFILE *crypt4gh_needed(const char *url, const char *mode)
{
    const char *u = strncmp(url, "crypt4gh:", 9) == 0 ? url + 9 : url;
#if defined(ENABLE_PLUGINS)
    const char *enable_plugins = "";
#else
    const char *enable_plugins = "You also need to rebuild HTSlib with plug-ins enabled.\n";
#endif

    hts_log_error("Accessing \"%s\" needs the crypt4gh plug-in.\n"
                  "It can be found at "
                  "https://github.com/samtools/htslib-crypt4gh\n"
                  "%s"
                  "If you have the plug-in, please ensure it can be "
                  "found on your HTS_PATH.",
                  u, enable_plugins);

    errno = EPROTONOSUPPORT;
    return NULL;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
leaq 0xda719(%rip), %rsi     # 0xef724
movl $0x9, %edx
callq 0x4200
cmpl $0x0, %eax
jne 0x15028
movq -0x8(%rbp), %rax
addq $0x9, %rax
movq %rax, -0x28(%rbp)
jmp 0x15030
movq -0x8(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq %rax, -0x18(%rbp)
leaq 0xda6ef(%rip), %rax     # 0xef72e
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %r8
movl $0x1, %edi
leaq 0xda70f(%rip), %rsi     # 0xef766
leaq 0xda718(%rip), %rdx     # 0xef776
movb $0x0, %al
callq 0x1b030
callq 0x4050
movl $0x5d, (%rax)
xorl %eax, %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_shutdown
void hfile_shutdown(int do_close_plugin)
{
    pthread_mutex_lock(&plugins_lock);

    if (schemes) {
        kh_destroy(scheme_string, schemes);
        schemes = NULL;
    }

    while (plugins != NULL) {
        struct hFILE_plugin_list *p = plugins;
        if (p->plugin.destroy) p->plugin.destroy();
#ifdef ENABLE_PLUGINS
        if (p->plugin.obj && do_close_plugin) close_plugin(p->plugin.obj);
#endif
        plugins = p->next;
        free(p);
    }

    pthread_mutex_unlock(&plugins_lock);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl %edi, -0x4(%rbp)
leaq 0xfcece(%rip), %rdi     # 0x111f70
callq 0x4730
cmpq $0x0, 0xfcee9(%rip)     # 0x111f98
je 0x150c8
movq 0xfcee0(%rip), %rdi     # 0x111f98
callq 0x15120
movq $0x0, 0xfced0(%rip) # 0x111f98
jmp 0x150ca
cmpq $0x0, 0xfcece(%rip)     # 0x111fa0
je 0x1510b
movq 0xfcec5(%rip), %rax     # 0x111fa0
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x0, 0x18(%rax)
je 0x150f1
movq -0x10(%rbp), %rax
callq *0x18(%rax)
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, 0xfcea0(%rip)     # 0x111fa0
movq -0x10(%rbp), %rdi
callq 0x45a0
jmp 0x150ca
leaq 0xfce5e(%rip), %rdi     # 0x111f70
callq 0x4330
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_list_schemes
HTSLIB_EXPORT
int hfile_list_schemes(const char *plugin, const char *sc_list[], int *nschemes)
{
    pthread_mutex_lock(&plugins_lock);
    if (!schemes && load_hfile_plugins() < 0) {
        pthread_mutex_unlock(&plugins_lock);
        return -1;
    }
    pthread_mutex_unlock(&plugins_lock);

    khiter_t k;
    int ns = 0;

    for (k = kh_begin(schemes); k != kh_end(schemes); k++) {
        if (!kh_exist(schemes, k))
            continue;

        const struct hFILE_scheme_handler *s = kh_value(schemes, k);
        if (plugin && strcmp(s->provider, plugin) != 0)
            continue;

        if (ns < *nschemes)
            sc_list[ns] = kh_key(schemes, k);
        ns++;
    }

    if (*nschemes > ns)
        *nschemes = ns;

    return ns;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
leaq 0xfca45(%rip), %rdi     # 0x111f70
callq 0x4730
cmpq $0x0, 0xfca60(%rip)     # 0x111f98
jne 0x1555c
callq 0x15650
cmpl $0x0, %eax
jge 0x1555c
leaq 0xfca25(%rip), %rdi     # 0x111f70
callq 0x4330
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x15641
leaq 0xfca0d(%rip), %rdi     # 0x111f70
callq 0x4330
movl $0x0, -0x28(%rbp)
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
movq 0xfca18(%rip), %rcx     # 0x111f98
cmpl (%rcx), %eax
je 0x15627
movq 0xfca09(%rip), %rax     # 0x111f98
movq 0x10(%rax), %rax
movl -0x24(%rbp), %ecx
shrl $0x4, %ecx
movl %ecx, %ecx
movl (%rax,%rcx,4), %eax
movl -0x24(%rbp), %ecx
andl $0xf, %ecx
shll %ecx
shrl %cl, %eax
andl $0x3, %eax
cmpl $0x0, %eax
je 0x155b2
jmp 0x15619
movq 0xfc9df(%rip), %rax     # 0x111f98
movq 0x20(%rax), %rax
movl -0x24(%rbp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x155e7
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x10(%rbp), %rsi
callq 0x4690
cmpl $0x0, %eax
je 0x155e7
jmp 0x15619
movl -0x28(%rbp), %eax
movq -0x20(%rbp), %rcx
cmpl (%rcx), %eax
jge 0x15610
movq 0xfc99f(%rip), %rax     # 0x111f98
movq 0x18(%rax), %rax
movl -0x24(%rbp), %ecx
movq (%rax,%rcx,8), %rdx
movq -0x18(%rbp), %rax
movslq -0x28(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x15576
movq -0x20(%rbp), %rax
movl (%rax), %eax
cmpl -0x28(%rbp), %eax
jle 0x1563b
movl -0x28(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, (%rax)
movl -0x28(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_list_plugins
HTSLIB_EXPORT
int hfile_list_plugins(const char *plist[], int *nplugins)
{
    pthread_mutex_lock(&plugins_lock);
    if (!schemes && load_hfile_plugins() < 0) {
        pthread_mutex_unlock(&plugins_lock);
        return -1;
    }
    pthread_mutex_unlock(&plugins_lock);

    int np = 0;
    if (*nplugins)
        plist[np++] = "built-in";

    struct hFILE_plugin_list *p = plugins;
    while (p) {
        if (np < *nplugins)
            plist[np] = p->plugin.name;

        p = p->next;
        np++;
    }

    if (*nplugins > np)
        *nplugins = np;

    return np;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
leaq 0xfc839(%rip), %rdi     # 0x111f70
callq 0x4730
cmpq $0x0, 0xfc854(%rip)     # 0x111f98
jne 0x15768
callq 0x15650
cmpl $0x0, %eax
jge 0x15768
leaq 0xfc819(%rip), %rdi     # 0x111f70
callq 0x4330
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x15803
leaq 0xfc801(%rip), %rdi     # 0x111f70
callq 0x4330
movl $0x0, -0x1c(%rbp)
movq -0x18(%rbp), %rax
cmpl $0x0, (%rax)
je 0x157a1
movq -0x10(%rbp), %rax
movl -0x1c(%rbp), %ecx
movl %ecx, %edx
addl $0x1, %edx
movl %edx, -0x1c(%rbp)
movslq %ecx, %rcx
leaq 0xd9f5e(%rip), %rdx     # 0xef6fb
movq %rdx, (%rax,%rcx,8)
movq 0xfc7f8(%rip), %rax     # 0x111fa0
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
je 0x157e9
movl -0x1c(%rbp), %eax
movq -0x18(%rbp), %rcx
cmpl (%rcx), %eax
jge 0x157d2
movq -0x28(%rbp), %rax
movq 0x10(%rax), %rdx
movq -0x10(%rbp), %rax
movslq -0x1c(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
movq -0x28(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x28(%rbp)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x157ac
movq -0x18(%rbp), %rax
movl (%rax), %eax
cmpl -0x1c(%rbp), %eax
jle 0x157fd
movl -0x1c(%rbp), %ecx
movq -0x18(%rbp), %rax
movl %ecx, (%rax)
movl -0x1c(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hfile_has_plugin
HTSLIB_EXPORT
int hfile_has_plugin(const char *name)
{
    pthread_mutex_lock(&plugins_lock);
    if (!schemes && load_hfile_plugins() < 0) {
        pthread_mutex_unlock(&plugins_lock);
        return -1;
    }
    pthread_mutex_unlock(&plugins_lock);

    struct hFILE_plugin_list *p = plugins;
    while (p) {
        if (strcmp(p->plugin.name, name) == 0)
            return 1;
        p = p->next;
    }

    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
leaq 0xfc74d(%rip), %rdi     # 0x111f70
callq 0x4730
cmpq $0x0, 0xfc768(%rip)     # 0x111f98
jne 0x15851
callq 0x15650
cmpl $0x0, %eax
jge 0x15851
leaq 0xfc72d(%rip), %rdi     # 0x111f70
callq 0x4330
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x158a3
leaq 0xfc718(%rip), %rdi     # 0x111f70
callq 0x4330
movq 0xfc73c(%rip), %rax     # 0x111fa0
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
je 0x1589c
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x10(%rbp), %rsi
callq 0x4690
cmpl $0x0, %eax
jne 0x1588e
movl $0x1, -0x4(%rbp)
jmp 0x158a3
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x18(%rbp)
jmp 0x15868
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hopen
hFILE *hopen(const char *fname, const char *mode, ...)
{
    const struct hFILE_scheme_handler *handler = find_scheme_handler(fname);
    if (handler) {
        if (strchr(mode, ':') == NULL
            || handler->priority < 2000
            || handler->vopen == NULL) {
            return handler->open(fname, mode);
        }
        else {
            hFILE *fp;
            va_list arg;
            va_start(arg, mode);
            fp = handler->vopen(fname, mode, arg);
            va_end(arg);
            return fp;
        }
    }
    else if (strcmp(fname, "-") == 0) return hopen_fd_stdinout(mode);
    else return hopen_fd(fname, mode);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xf0, %rsp
testb %al, %al
je 0x158eb
movaps %xmm0, -0xc0(%rbp)
movaps %xmm1, -0xb0(%rbp)
movaps %xmm2, -0xa0(%rbp)
movaps %xmm3, -0x90(%rbp)
movaps %xmm4, -0x80(%rbp)
movaps %xmm5, -0x70(%rbp)
movaps %xmm6, -0x60(%rbp)
movaps %xmm7, -0x50(%rbp)
movq %r9, -0xc8(%rbp)
movq %r8, -0xd0(%rbp)
movq %rcx, -0xd8(%rbp)
movq %rdx, -0xe0(%rbp)
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rdi
callq 0x15a00
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0x159b9
movq -0x18(%rbp), %rdi
movl $0x3a, %esi
callq 0x4170
cmpq $0x0, %rax
je 0x15953
movq -0x20(%rbp), %rax
cmpl $0x7d0, 0x18(%rax)      # imm = 0x7D0
jl 0x15953
movq -0x20(%rbp), %rax
cmpq $0x0, 0x20(%rax)
jne 0x1596d
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq *%rax
movq %rax, -0x8(%rbp)
jmp 0x159ee
leaq -0x40(%rbp), %rax
leaq -0xf0(%rbp), %rcx
movq %rcx, 0x10(%rax)
leaq 0x10(%rbp), %rcx
movq %rcx, 0x8(%rax)
movl $0x30, 0x4(%rax)
movl $0x10, (%rax)
movq -0x20(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
leaq -0x40(%rbp), %rdx
callq *%rax
movq %rax, -0x28(%rbp)
leaq -0x40(%rbp), %rax
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x159ee
movq -0x10(%rbp), %rdi
leaq 0xdca31(%rip), %rsi     # 0xf23f5
callq 0x4690
cmpl $0x0, %eax
jne 0x159dd
movq -0x18(%rbp), %rdi
callq 0x15b80
movq %rax, -0x8(%rbp)
jmp 0x159ee
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x15bf0
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0xf0, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: find_scheme_handler
static const struct hFILE_scheme_handler *find_scheme_handler(const char *s)
{
    static const struct hFILE_scheme_handler unknown_scheme =
        { hopen_unknown_scheme, hfile_always_local, "built-in", 0 };

    char scheme[12];
    int i;

    for (i = 0; i < sizeof scheme; i++)
        if (isalnum_c(s[i]) || s[i] == '+' || s[i] == '-' || s[i] == '.')
            scheme[i] = tolower_c(s[i]);
        else if (s[i] == ':') break;
        else return NULL;

    // 1 byte schemes are likely windows C:/foo pathnames
    if (i <= 1 || i >= sizeof scheme) return NULL;
    scheme[i] = '\0';

    pthread_mutex_lock(&plugins_lock);
    if (!schemes && load_hfile_plugins() < 0) {
        pthread_mutex_unlock(&plugins_lock);
        return NULL;
    }
    pthread_mutex_unlock(&plugins_lock);

    khint_t k = kh_get(scheme_string, schemes, scheme);
    return (k != kh_end(schemes))? kh_value(schemes, k) : &unknown_scheme;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movl $0x0, -0x20(%rbp)
movslq -0x20(%rbp), %rax
cmpq $0xc, %rax
jae 0x15ab7
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %edi
callq 0x17170
cmpl $0x0, %eax
jne 0x15a6a
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x2b, %eax
je 0x15a6a
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x2d, %eax
je 0x15a6a
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x2e, %eax
jne 0x15a87
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %edi
callq 0x16fa0
movb %al, %cl
movslq -0x20(%rbp), %rax
movb %cl, -0x1c(%rbp,%rax)
jmp 0x15aa7
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x3a, %eax
jne 0x15a9a
jmp 0x15ab7
movq $0x0, -0x8(%rbp)
jmp 0x15b6d
jmp 0x15aa9
movl -0x20(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
jmp 0x15a13
cmpl $0x1, -0x20(%rbp)
jle 0x15ac7
movslq -0x20(%rbp), %rax
cmpq $0xc, %rax
jb 0x15ad4
movq $0x0, -0x8(%rbp)
jmp 0x15b6d
movslq -0x20(%rbp), %rax
movb $0x0, -0x1c(%rbp,%rax)
leaq 0xfc48c(%rip), %rdi     # 0x111f70
callq 0x4730
cmpq $0x0, 0xfc4a7(%rip)     # 0x111f98
jne 0x15b13
callq 0x15650
cmpl $0x0, %eax
jge 0x15b13
leaq 0xfc46c(%rip), %rdi     # 0x111f70
callq 0x4330
movq $0x0, -0x8(%rbp)
jmp 0x15b6d
leaq 0xfc456(%rip), %rdi     # 0x111f70
callq 0x4330
movq 0xfc472(%rip), %rdi     # 0x111f98
leaq -0x1c(%rbp), %rsi
callq 0x171a0
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
movq 0xfc45c(%rip), %rcx     # 0x111f98
cmpl (%rcx), %eax
je 0x15b58
movq 0xfc451(%rip), %rax     # 0x111f98
movq 0x20(%rax), %rax
movl -0x24(%rbp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, -0x30(%rbp)
jmp 0x15b65
leaq 0xf7189(%rip), %rax     # 0x10cce8
movq %rax, -0x30(%rbp)
jmp 0x15b65
movq -0x30(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: hopen_fd
static hFILE *hopen_fd(const char *filename, const char *mode)
{
    hFILE_fd *fp = NULL;
    int fd = open(filename, hfile_oflags(mode), 0666);
    if (fd < 0) goto error;

    fp = (hFILE_fd *) hfile_init(sizeof (hFILE_fd), mode, blksize(fd));
    if (fp == NULL) goto error;

    fp->fd = fd;
    fp->is_socket = 0;
    fp->is_shared = 0;
    fp->base.backend = &fd_backend;
    return &fp->base;

error:
    if (fd >= 0) { int save = errno; (void) close(fd); errno = save; }
    hfile_destroy((hFILE *) fp);
    return NULL;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x18(%rbp), %rdi
callq 0x14b80
movq -0x30(%rbp), %rdi
movl %eax, %esi
movl $0x1b6, %edx            # imm = 0x1B6
movb $0x0, %al
callq 0x4320
movl %eax, -0x24(%rbp)
cmpl $0x0, -0x24(%rbp)
jge 0x15c36
jmp 0x15ca7
movq -0x18(%rbp), %rax
movq %rax, -0x38(%rbp)
movl -0x24(%rbp), %edi
callq 0x14b10
movq -0x38(%rbp), %rsi
movq %rax, %rdx
movl $0x40, %edi
callq 0x13800
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0x15c64
jmp 0x15ca7
movl -0x24(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x38(%rax)
movq -0x20(%rbp), %rax
movb 0x3c(%rax), %cl
andb $-0x2, %cl
orb $0x0, %cl
movb %cl, 0x3c(%rax)
movq -0x20(%rbp), %rax
movb 0x3c(%rax), %cl
andb $-0x3, %cl
orb $0x0, %cl
movb %cl, 0x3c(%rax)
movq -0x20(%rbp), %rax
leaq 0xf6f37(%rip), %rcx     # 0x10cbd0
movq %rcx, 0x20(%rax)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x15ce0
cmpl $0x0, -0x24(%rbp)
jl 0x15ccf
callq 0x4050
movl (%rax), %eax
movl %eax, -0x28(%rbp)
movl -0x24(%rbp), %edi
callq 0x49c0
movl -0x28(%rbp), %eax
movl %eax, -0x3c(%rbp)
callq 0x4050
movl -0x3c(%rbp), %ecx
movl %ecx, (%rax)
movq -0x20(%rbp), %rdi
callq 0x13980
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: haddextension
char *haddextension(struct kstring_t *buffer, const char *filename,
                    int replace, const char *new_extension)
{
    const char *trailing, *end;

    if (find_scheme_handler(filename)) {
        // URL, so alter extensions before any trailing query or fragment parts
        // Allow # symbols in s3 URLs
        trailing = filename + ((strncmp(filename, "s3://", 5) && strncmp(filename, "s3+http://", 10) && strncmp(filename, "s3+https://", 11))  ? strcspn(filename, "?#") : strcspn(filename, "?"));
    }
    else {
        // Local path, so alter extensions at the end of the filename
        trailing = strchr(filename, '\0');
    }

    end = replace? strip_extension(filename, trailing) : trailing;

    buffer->l = 0;
    if (kputsn(filename, end - filename, buffer) >= 0 &&
        kputs(new_extension, buffer) >= 0 &&
        kputs(trailing, buffer) >= 0) return buffer->s;
    else return NULL;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x18(%rbp), %rdi
callq 0x15a00
cmpq $0x0, %rax
je 0x15dfb
movq -0x18(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x18(%rbp), %rdi
leaq 0xd9987(%rip), %rsi     # 0xef704
movl $0x5, %edx
callq 0x4200
cmpl $0x0, %eax
je 0x15dd6
movq -0x18(%rbp), %rdi
leaq 0xd9973(%rip), %rsi     # 0xef70a
movl $0xa, %edx
callq 0x4200
cmpl $0x0, %eax
je 0x15dd6
movq -0x18(%rbp), %rdi
leaq 0xd9964(%rip), %rsi     # 0xef715
movl $0xb, %edx
callq 0x4200
cmpl $0x0, %eax
je 0x15dd6
movq -0x18(%rbp), %rdi
leaq 0xd9956(%rip), %rsi     # 0xef721
callq 0x4090
movq %rax, -0x48(%rbp)
jmp 0x15dea
movq -0x18(%rbp), %rdi
leaq 0xdc73c(%rip), %rsi     # 0xf251d
callq 0x4090
movq %rax, -0x48(%rbp)
movq -0x40(%rbp), %rax
movq -0x48(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0x30(%rbp)
jmp 0x15e0a
movq -0x18(%rbp), %rdi
xorl %esi, %esi
callq 0x4170
movq %rax, -0x30(%rbp)
cmpl $0x0, -0x1c(%rbp)
je 0x15e23
movq -0x18(%rbp), %rdi
movq -0x30(%rbp), %rsi
callq 0x15ea0
movq %rax, -0x50(%rbp)
jmp 0x15e2b
movq -0x30(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq $0x0, (%rax)
movq -0x18(%rbp), %rdi
movq -0x38(%rbp), %rsi
movq -0x18(%rbp), %rax
subq %rax, %rsi
movq -0x10(%rbp), %rdx
callq 0x15f00
cmpl $0x0, %eax
jl 0x15e8d
movq -0x28(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x15fb0
cmpl $0x0, %eax
jl 0x15e8d
movq -0x30(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x15fb0
cmpl $0x0, %eax
jl 0x15e8d
movq -0x10(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x8(%rbp)
jmp 0x15e95
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: strip_extension
static const char *strip_extension(const char *start, const char *limit)
{
    const char *s = limit;
    while (s > start) {
        --s;
        if (*s == '.') return s;
        else if (*s == '/') break;
    }
    return limit;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
cmpq -0x10(%rbp), %rax
jbe 0x15ef2
movq -0x20(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2e, %eax
jne 0x15ee0
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x15efa
movq -0x20(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2f, %eax
jne 0x15eee
jmp 0x15ef2
jmp 0x15ef0
jmp 0x15eb4
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/hfile.c
// Function: knet_open
HTSLIB_EXPORT
knetFile *knet_open(const char *fn, const char *mode) {
    knetFile *fp = calloc(1, sizeof(*fp));
    if (!fp) return NULL;
    if (!(fp->hf = hopen(fn, mode))) {
        free(fp);
        return NULL;
    }

    // FD backend is the only one implementing knet_fileno
    fp->fd = fp->hf->backend == &fd_backend
        ? ((hFILE_fd *)fp->hf)->fd
        : -1;

    return fp;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl $0x1, %edi
movl $0x88, %esi
callq 0x42f0
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0x16044
movq $0x0, -0x8(%rbp)
jmp 0x160be
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movb $0x0, %al
callq 0x158b0
movq -0x20(%rbp), %rcx
movq %rax, 0x80(%rcx)
cmpq $0x0, %rax
jne 0x16077
movq -0x20(%rbp), %rdi
callq 0x45a0
movq $0x0, -0x8(%rbp)
jmp 0x160be
movq -0x20(%rbp), %rax
movq 0x80(%rax), %rax
leaq 0xf6b47(%rip), %rcx     # 0x10cbd0
cmpq %rcx, 0x20(%rax)
jne 0x160a2
movq -0x20(%rbp), %rax
movq 0x80(%rax), %rax
movl 0x38(%rax), %eax
movl %eax, -0x24(%rbp)
jmp 0x160ac
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl %eax, -0x24(%rbp)
jmp 0x160ac
movl -0x24(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x4(%rax)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)