LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/bgzf.c
// Function: bgzf_write
ssize_t bgzf_write(BGZF *fp, const void *data, size_t length)
{
    if ( !fp->is_compressed )
        return hwrite(fp->fp, data, length);

    const uint8_t *input = (const uint8_t*)data;
    ssize_t remaining = length;
    assert(fp->is_write);
    while (remaining > 0) {
        uint8_t* buffer = (uint8_t*)fp->uncompressed_block;
        int copy_length = BGZF_BLOCK_SIZE - fp->block_offset;
        if (copy_length > remaining) copy_length = remaining;
        memcpy(buffer + fp->block_offset, input, copy_length);
        fp->block_offset += copy_length;
        input += copy_length;
        remaining -= copy_length;
        if (fp->block_offset == BGZF_BLOCK_SIZE) {
            if (lazy_flush(fp) != 0) return -1;
        }
    }
    return length - remaining;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movl (%rax), %eax
shrl $0x1d, %eax
andl $0x3, %eax
cmpl $0x0, %eax
jne 0x9d243
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0x9d090
movq %rax, -0x8(%rbp)
jmp 0x9d33f
movq -0x18(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
movl (%rax), %eax
shrl $0x10, %eax
andl $0x3, %eax
cmpl $0x0, %eax
je 0x9d266
jmp 0x9d285
leaq 0x46963(%rip), %rdi     # 0xe3bd0
leaq 0x468a1(%rip), %rsi     # 0xe3b15
movl $0x308, %edx            # imm = 0x308
leaq 0x4695d(%rip), %rcx     # 0xe3bdd
callq 0x6450
jmp 0x9d287
cmpq $0x0, -0x30(%rbp)
jle 0x9d333
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rcx
movl $0xff00, %eax           # imm = 0xFF00
subl 0xc(%rcx), %eax
movl %eax, -0x3c(%rbp)
movslq -0x3c(%rbp), %rax
cmpq -0x30(%rbp), %rax
jle 0x9d2be
movq -0x30(%rbp), %rax
movl %eax, -0x3c(%rbp)
movq -0x38(%rbp), %rdi
movq -0x10(%rbp), %rax
movslq 0xc(%rax), %rax
addq %rax, %rdi
movq -0x28(%rbp), %rsi
movslq -0x3c(%rbp), %rdx
callq 0x6570
movl -0x3c(%rbp), %ecx
movq -0x10(%rbp), %rax
addl 0xc(%rax), %ecx
movl %ecx, 0xc(%rax)
movl -0x3c(%rbp), %ecx
movq -0x28(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movslq -0x3c(%rbp), %rcx
movq -0x30(%rbp), %rax
subq %rcx, %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
cmpl $0xff00, 0xc(%rax)      # imm = 0xFF00
jne 0x9d32e
movq -0x10(%rbp), %rdi
callq 0x9d180
cmpl $0x0, %eax
je 0x9d32c
movq $-0x1, -0x8(%rbp)
jmp 0x9d33f
jmp 0x9d32e
jmp 0x9d287
movq -0x20(%rbp), %rax
subq -0x30(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/bgzf.c
// Function: mt_destroy
static void mt_destroy(mtaux_t *mt)
{
    int i;
    // signal all workers to quit
    pthread_mutex_lock(&mt->lock);
    mt->done = 1; mt->proc_cnt = 0;
    pthread_cond_broadcast(&mt->cv);
    pthread_mutex_unlock(&mt->lock);
    for (i = 1; i < mt->n_threads; ++i) pthread_join(mt->tid[i], 0); // worker 0 is effectively launched by the master thread
    // free other data allocated on heap
    for (i = 0; i < mt->n_blks; ++i) free(mt->blk[i]);
    for (i = 0; i < mt->n_threads; ++i) free(mt->w[i].buf);
    free(mt->blk); free(mt->len); free(mt->w); free(mt->tid);
    pthread_cond_destroy(&mt->cv);
    pthread_mutex_destroy(&mt->lock);
    free(mt);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
addq $0x38, %rdi
callq 0x6ae0
movq -0x8(%rbp), %rax
movl $0x1, 0xc(%rax)
movq -0x8(%rbp), %rax
movl $0x0, 0x10(%rax)
movq -0x8(%rbp), %rdi
addq $0x60, %rdi
callq 0x6240
movq -0x8(%rbp), %rdi
addq $0x38, %rdi
callq 0x64e0
movl $0x1, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl (%rcx), %eax
jge 0x9d5af
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movslq -0xc(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x6610
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x9d580
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl 0x4(%rcx), %eax
jge 0x9d5e2
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0xc(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
callq 0x6880
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x9d5b6
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl (%rcx), %eax
jge 0x9d61b
movq -0x8(%rbp), %rax
movq 0x28(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rdi
callq 0x6880
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x9d5e9
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x6880
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rdi
callq 0x6880
movq -0x8(%rbp), %rax
movq 0x28(%rax), %rdi
callq 0x6880
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rdi
callq 0x6880
movq -0x8(%rbp), %rdi
addq $0x60, %rdi
callq 0x6e70
movq -0x8(%rbp), %rdi
addq $0x38, %rdi
callq 0x6840
movq -0x8(%rbp), %rdi
callq 0x6880
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/bgzf.c
// Function: free_cache
static void free_cache(BGZF *fp)
{
    khint_t k;
    khash_t(cache) *h = (khash_t(cache)*)fp->cache;
    if (fp->is_write) return;
    for (k = kh_begin(h); k < kh_end(h); ++k)
        if (kh_exist(h, k)) free(kh_val(h, k).block);
    kh_destroy(cache, h);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq 0x30(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movl (%rax), %eax
shrl $0x10, %eax
andl $0x3, %eax
cmpl $0x0, %eax
je 0x9d70b
jmp 0x9d773
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x18(%rbp), %rcx
cmpl (%rcx), %eax
jae 0x9d76a
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0xc(%rbp), %ecx
shrl $0x4, %ecx
movl %ecx, %ecx
movl (%rax,%rcx,4), %eax
movl -0xc(%rbp), %ecx
andl $0xf, %ecx
shll %ecx
shrl %cl, %eax
andl $0x3, %eax
cmpl $0x0, %eax
jne 0x9d75d
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rax
movl -0xc(%rbp), %ecx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rdi
callq 0x6880
jmp 0x9d75f
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x9d712
movq -0x18(%rbp), %rdi
callq 0x9f660
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/bgzf.c
// Function: bgzf_check_EOF
int bgzf_check_EOF(BGZF *fp)
{
    uint8_t buf[28];
    off_t offset = htell(fp->fp);
    if (hseek(fp->fp, -28, SEEK_END) < 0) {
        if (errno == ESPIPE) { hclearerr(fp->fp); return 2; }
        else return -1;
    }
    if ( hread(fp->fp, buf, 28) != 28 ) return -1;
    if ( hseek(fp->fp, offset, SEEK_SET) < 0 ) return -1;
    return (memcmp("\037\213\010\4\0\0\0\0\0\377\6\0\102\103\2\0\033\0\3\0\0\0\0\0\0\0\0\0", buf, 28) == 0)? 1 : 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
callq 0x9bfd0
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
movq $-0x1c, %rsi
movl $0x2, %edx
callq 0xa2250
cmpq $0x0, %rax
jge 0x9d805
callq 0x6060
cmpl $0x1d, (%rax)
jne 0x9d7fc
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
callq 0x9d880
movl $0x2, -0x4(%rbp)
jmp 0x9d873
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x9d873
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
leaq -0x30(%rbp), %rsi
movl $0x1c, %edx
callq 0x9bf30
cmpq $0x1c, %rax
je 0x9d82a
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x9d873
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
movq -0x38(%rbp), %rsi
xorl %edx, %edx
callq 0xa2250
cmpq $0x0, %rax
jge 0x9d84c
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x9d873
leaq -0x30(%rbp), %rsi
leaq 0x4649c(%rip), %rdi     # 0xe3cf3
movl $0x1c, %edx
callq 0x62d0
movl %eax, %edx
xorl %eax, %eax
movl $0x1, %ecx
cmpl $0x0, %edx
cmovel %ecx, %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/bgzf.c
// Function: bgzf_seek
int64_t bgzf_seek(BGZF* fp, int64_t pos, int where)
{
    int block_offset;
    int64_t block_address;

    if (fp->is_write || where != SEEK_SET) {
        fp->errcode |= BGZF_ERR_MISUSE;
        return -1;
    }
    block_offset = pos & 0xFFFF;
    block_address = pos >> 16;
    if (hseek(fp->fp, block_address, SEEK_SET) < 0) {
        fp->errcode |= BGZF_ERR_IO;
        return -1;
    }
    fp->block_length = 0;  // indicates current block has not been loaded
    fp->block_address = block_address;
    fp->block_offset = block_offset;
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq -0x10(%rbp), %rax
movl (%rax), %eax
shrl $0x10, %eax
andl $0x3, %eax
cmpl $0x0, %eax
jne 0x9d8ca
cmpl $0x0, -0x1c(%rbp)
je 0x9d8f8
movq -0x10(%rbp), %rax
movl (%rax), %edx
andl $0xffff, %edx           # imm = 0xFFFF
orl $0x8, %edx
movl (%rax), %ecx
andl $0xffff, %edx           # imm = 0xFFFF
andl $0xffff0000, %ecx       # imm = 0xFFFF0000
orl %edx, %ecx
movl %ecx, (%rax)
movq $-0x1, -0x8(%rbp)
jmp 0x9d97e
movq -0x18(%rbp), %rax
andq $0xffff, %rax           # imm = 0xFFFF
movl %eax, -0x20(%rbp)
movq -0x18(%rbp), %rax
sarq $0x10, %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
movq -0x28(%rbp), %rsi
xorl %edx, %edx
callq 0xa2250
cmpq $0x0, %rax
jge 0x9d955
movq -0x10(%rbp), %rax
movl (%rax), %edx
andl $0xffff, %edx           # imm = 0xFFFF
orl $0x4, %edx
movl (%rax), %ecx
andl $0xffff, %edx           # imm = 0xFFFF
andl $0xffff0000, %ecx       # imm = 0xFFFF0000
orl %edx, %ecx
movl %ecx, (%rax)
movq $-0x1, -0x8(%rbp)
jmp 0x9d97e
movq -0x10(%rbp), %rax
movl $0x0, 0x8(%rax)
movq -0x28(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
movl -0x20(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0xc(%rax)
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/bgzf.c
// Function: bgzf_is_bgzf
int bgzf_is_bgzf(const char *fn)
{
    uint8_t buf[16];
    int n;
    hFILE *fp;
    if ((fp = hopen(fn, "r")) == 0) return 0;
    n = hread(fp, buf, 16);
    if ( hclose(fp) < 0 ) return -1;
    if (n != 16) return 0;
    return memcmp(g_magic, buf, 16) == 0? 1 : 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
leaq 0x423ef(%rip), %rsi     # 0xdfd96
callq 0xa2a70
movq %rax, -0x30(%rbp)
cmpq $0x0, %rax
jne 0x9d9bf
movl $0x0, -0x4(%rbp)
jmp 0x9da2b
movq -0x30(%rbp), %rdi
leaq -0x20(%rbp), %rsi
movl $0x10, %edx
callq 0x9bf30
movl %eax, -0x24(%rbp)
movq -0x30(%rbp), %rdi
callq 0xa23e0
cmpl $0x0, %eax
jge 0x9d9eb
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x9da2b
cmpl $0x10, -0x24(%rbp)
je 0x9d9fa
movl $0x0, -0x4(%rbp)
jmp 0x9da2b
leaq -0x20(%rbp), %rax
movups (%rax), %xmm0
movaps 0x460c8(%rip), %xmm1    # 0xe3ad0
pcmpeqb %xmm1, %xmm0
pmovmskb %xmm0, %eax
subl $0xffff, %eax           # imm = 0xFFFF
setne %al
movzbl %al, %edx
xorl %eax, %eax
movl $0x1, %ecx
cmpl $0x0, %edx
cmovel %ecx, %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/bgzf.c
// Function: bgzf_getc
int bgzf_getc(BGZF *fp)
{
    int c;
    if (fp->block_offset >= fp->block_length) {
        if (bgzf_read_block(fp) != 0) return -2; /* error */
        if (fp->block_length == 0) return -1; /* end-of-file */
    }
    c = ((unsigned char*)fp->uncompressed_block)[fp->block_offset++];
    if (fp->block_offset == fp->block_length) {
        fp->block_address = htell(fp->fp);
        fp->block_offset = 0;
        fp->block_length = 0;
    }
    fp->uncompressed_address++;
    return c;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movl 0xc(%rax), %eax
movq -0x10(%rbp), %rcx
cmpl 0x8(%rcx), %eax
jl 0x9da8b
movq -0x10(%rbp), %rdi
callq 0x9b9a0
cmpl $0x0, %eax
je 0x9da76
movl $0xfffffffe, -0x4(%rbp) # imm = 0xFFFFFFFE
jmp 0x9db00
movq -0x10(%rbp), %rax
cmpl $0x0, 0x8(%rax)
jne 0x9da89
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x9db00
jmp 0x9da8b
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rdx
movl 0xc(%rdx), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, 0xc(%rdx)
movslq %ecx, %rcx
movzbl (%rax,%rcx), %eax
movl %eax, -0x14(%rbp)
movq -0x10(%rbp), %rax
movl 0xc(%rax), %eax
movq -0x10(%rbp), %rcx
cmpl 0x8(%rcx), %eax
jne 0x9daea
movq -0x10(%rbp), %rax
movq 0x38(%rax), %rdi
callq 0x9bfd0
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0xc(%rax)
movq -0x10(%rbp), %rax
movl $0x0, 0x8(%rax)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x18(%rax)
movl -0x14(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/bgzf.c
// Function: mode2level
static int mode2level(const char *__restrict mode)
{
    int i, compress_level = -1;
    for (i = 0; mode[i]; ++i)
        if (mode[i] >= '0' && mode[i] <= '9') break;
    if (mode[i]) compress_level = (int)mode[i] - '0';
    if (strchr(mode, 'u')) compress_level = -2;
    return compress_level;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movl $0xffffffff, -0x10(%rbp) # imm = 0xFFFFFFFF
movl $0x0, -0xc(%rbp)
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
cmpb $0x0, (%rax,%rcx)
je 0x9e929
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x30, %eax
jl 0x9e91c
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x39, %eax
jg 0x9e91c
jmp 0x9e929
jmp 0x9e91e
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x9e8ea
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
cmpb $0x0, (%rax,%rcx)
je 0x9e949
movq -0x8(%rbp), %rax
movslq -0xc(%rbp), %rcx
movsbl (%rax,%rcx), %eax
subl $0x30, %eax
movl %eax, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movl $0x75, %esi
callq 0x6260
cmpq $0x0, %rax
je 0x9e964
movl $0xfffffffe, -0x10(%rbp) # imm = 0xFFFFFFFE
movl -0x10(%rbp), %eax
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/bgzf.c
// Function: worker_aux
static int worker_aux(worker_t *w)
{
    int i, stop = 0;
    // wait for condition: to process or all done
    pthread_mutex_lock(&w->mt->lock);
    while (!w->toproc && !w->mt->done)
        pthread_cond_wait(&w->mt->cv, &w->mt->lock);
    if (w->mt->done) stop = 1;
    w->toproc = 0;
    pthread_mutex_unlock(&w->mt->lock);
    if (stop) return 1; // to quit the thread
    w->errcode = 0;
    for (i = w->i; i < w->mt->curr; i += w->mt->n_threads) {
        size_t clen = BGZF_MAX_BLOCK_SIZE;
        if (bgzf_compress(w->buf, &clen, w->mt->blk[i], w->mt->len[i], w->compress_level) != 0)
            w->errcode |= BGZF_ERR_ZLIB;
        memcpy(w->mt->blk[i], w->buf, clen);
        w->mt->len[i] = clen;
    }
    __sync_fetch_and_add(&w->mt->proc_cnt, 1);
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movl $0x0, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
addq $0x38, %rdi
callq 0x6ae0
movq -0x10(%rbp), %rcx
xorl %eax, %eax
cmpl $0x0, 0x18(%rcx)
movb %al, -0x21(%rbp)
jne 0x9f445
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x0, 0xc(%rax)
setne %al
xorb $-0x1, %al
movb %al, -0x21(%rbp)
movb -0x21(%rbp), %al
testb $0x1, %al
jne 0x9f44e
jmp 0x9f46b
movq -0x10(%rbp), %rax
movq (%rax), %rdi
addq $0x60, %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rsi
addq $0x38, %rsi
callq 0x6b90
jmp 0x9f423
movq -0x10(%rbp), %rax
movq (%rax), %rax
cmpl $0x0, 0xc(%rax)
je 0x9f47f
movl $0x1, -0x18(%rbp)
movq -0x10(%rbp), %rax
movl $0x0, 0x18(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
addq $0x38, %rdi
callq 0x64e0
cmpl $0x0, -0x18(%rbp)
je 0x9f4ac
movl $0x1, -0x4(%rbp)
jmp 0x9f58f
movq -0x10(%rbp), %rax
movl $0x0, 0x14(%rax)
movq -0x10(%rbp), %rax
movl 0x10(%rax), %eax
movl %eax, -0x14(%rbp)
movl -0x14(%rbp), %eax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
cmpl 0x8(%rcx), %eax
jge 0x9f57d
movq $0x10000, -0x20(%rbp)   # imm = 0x10000
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rdi
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movslq -0x14(%rbp), %rcx
movq (%rax,%rcx,8), %rdx
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x20(%rax), %rax
movslq -0x14(%rbp), %rcx
movslq (%rax,%rcx,4), %rcx
movq -0x10(%rbp), %rax
movl 0x1c(%rax), %r8d
leaq -0x20(%rbp), %rsi
callq 0x9b750
cmpl $0x0, %eax
je 0x9f52d
movq -0x10(%rbp), %rax
movl 0x14(%rax), %ecx
orl $0x1, %ecx
movl %ecx, 0x14(%rax)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movslq -0x14(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
movq -0x20(%rbp), %rdx
callq 0x6570
movq -0x20(%rbp), %rax
movl %eax, %edx
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x20(%rax), %rax
movslq -0x14(%rbp), %rcx
movl %edx, (%rax,%rcx,4)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl (%rax), %eax
addl -0x14(%rbp), %eax
movl %eax, -0x14(%rbp)
jmp 0x9f4c1
movq -0x10(%rbp), %rax
movq (%rax), %rax
lock
incl 0x10(%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/bgzf.c
// Function: bgzf_gzip_compress
static int bgzf_gzip_compress(BGZF *fp, void *_dst, size_t *dlen, const void *src, size_t slen, int level)
{
    uint8_t *dst = (uint8_t*)_dst;
    z_stream *zs = fp->gz_stream;
    int flush = slen ? Z_NO_FLUSH : Z_FINISH;
    zs->next_in   = (Bytef*)src;
    zs->avail_in  = slen;
    zs->next_out  = dst;
    zs->avail_out = *dlen;
    if ( deflate(zs, flush) == Z_STREAM_ERROR ) return -1;
    *dlen = *dlen - zs->avail_out;
    return 0;
}

// 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 %r8, -0x30(%rbp)
movl %r9d, -0x34(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x10(%rbp), %rax
movq 0x58(%rax), %rax
movq %rax, -0x48(%rbp)
movq -0x30(%rbp), %rdx
movl $0x4, %eax
xorl %ecx, %ecx
cmpq $0x0, %rdx
cmovnel %ecx, %eax
movl %eax, -0x4c(%rbp)
movq -0x28(%rbp), %rcx
movq -0x48(%rbp), %rax
movq %rcx, (%rax)
movq -0x30(%rbp), %rax
movl %eax, %ecx
movq -0x48(%rbp), %rax
movl %ecx, 0x8(%rax)
movq -0x40(%rbp), %rcx
movq -0x48(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movl %eax, %ecx
movq -0x48(%rbp), %rax
movl %ecx, 0x20(%rax)
movq -0x48(%rbp), %rdi
movl -0x4c(%rbp), %esi
callq 0x6300
cmpl $-0x2, %eax
jne 0x9f637
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x9f656
movq -0x20(%rbp), %rax
movq (%rax), %rcx
movq -0x48(%rbp), %rax
movl 0x20(%rax), %eax
subq %rax, %rcx
movq -0x20(%rbp), %rax
movq %rcx, (%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/faidx.c
// Function: fai_insert_index
static inline void fai_insert_index(faidx_t *idx, const char *name, int len, int line_len, int line_blen, uint64_t offset)
{
    char *name_key = strdup(name);
    int absent;
    khint_t k = kh_put(s, idx->hash, name_key, &absent);
    faidx1_t *v = &kh_value(idx->hash, k);

    if (! absent) {
        fprintf(stderr, "[fai_build_core] ignoring duplicate sequence \"%s\" at byte offset %"PRIu64"\n", name, offset);
        free(name_key);
        return;
    }

    if (idx->n == idx->m) {
        idx->m = idx->m? idx->m<<1 : 16;
        idx->name = (char**)realloc(idx->name, sizeof(char*) * idx->m);
    }
    idx->name[idx->n++] = name_key;
    v->len = len;
    v->line_len = line_len;
    v->line_blen = line_blen;
    v->offset = offset;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movl %ecx, -0x18(%rbp)
movl %r8d, -0x1c(%rbp)
movq %r9, -0x28(%rbp)
movq -0x10(%rbp), %rdi
callq 0x6dd0
movq %rax, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x30(%rbp), %rsi
leaq -0x34(%rbp), %rdx
callq 0xa1020
movl %eax, -0x38(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x20(%rax), %rax
movl -0x38(%rbp), %ecx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
cmpl $0x0, -0x34(%rbp)
jne 0x9fac1
movq 0x65536(%rip), %rax     # 0x104fd0
movq (%rax), %rdi
movq -0x10(%rbp), %rdx
movq -0x28(%rbp), %rcx
leaq 0x445c8(%rip), %rsi     # 0xe4074
movb $0x0, %al
callq 0x6a80
movq -0x30(%rbp), %rdi
callq 0x6880
jmp 0x9fb6e
movq -0x8(%rbp), %rax
movl 0x8(%rax), %eax
movq -0x8(%rbp), %rcx
cmpl 0xc(%rcx), %eax
jne 0x9fb21
movq -0x8(%rbp), %rax
cmpl $0x0, 0xc(%rax)
je 0x9fae9
movq -0x8(%rbp), %rax
movl 0xc(%rax), %eax
shll %eax
movl %eax, -0x44(%rbp)
jmp 0x9faf3
movl $0x10, %eax
movl %eax, -0x44(%rbp)
jmp 0x9faf3
movl -0x44(%rbp), %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0xc(%rax)
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rdi
movq -0x8(%rbp), %rax
movslq 0xc(%rax), %rsi
shlq $0x3, %rsi
callq 0x6c80
movq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x30(%rbp), %rdx
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x8(%rbp), %rsi
movl 0x8(%rsi), %ecx
movl %ecx, %edi
addl $0x1, %edi
movl %edi, 0x8(%rsi)
movslq %ecx, %rcx
movq %rdx, (%rax,%rcx,8)
movslq -0x14(%rbp), %rcx
movq -0x40(%rbp), %rax
movq %rcx, 0x8(%rax)
movl -0x18(%rbp), %ecx
movq -0x40(%rbp), %rax
movl %ecx, (%rax)
movl -0x1c(%rbp), %ecx
movq -0x40(%rbp), %rax
movl %ecx, 0x4(%rax)
movq -0x28(%rbp), %rcx
movq -0x40(%rbp), %rax
movq %rcx, 0x10(%rax)
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/faidx.c
// Function: fai_save
void fai_save(const faidx_t *fai, FILE *fp)
{
    khint_t k;
    int i;
    for (i = 0; i < fai->n; ++i) {
        faidx1_t x;
        k = kh_get(s, fai->hash, fai->name[i]);
        x = kh_value(fai->hash, k);
#ifdef _WIN32
        fprintf(fp, "%s\t%d\t%ld\t%d\t%d\n", fai->name[i], (int)x.len, (long)x.offset, (int)x.line_blen, (int)x.line_len);
#else
        fprintf(fp, "%s\t%d\t%lld\t%d\t%d\n", fai->name[i], (int)x.len, (long long)x.offset, (int)x.line_blen, (int)x.line_len);
#endif
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl $0x0, -0x18(%rbp)
movl -0x18(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl 0x8(%rcx), %eax
jge 0x9ff68
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movslq -0x18(%rbp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x9ff70
movl %eax, -0x14(%rbp)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movq 0x20(%rax), %rax
movl -0x14(%rbp), %ecx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq (%rax), %rcx
movq %rcx, -0x30(%rbp)
movq 0x8(%rax), %rcx
movq %rcx, -0x28(%rbp)
movq 0x10(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rax
movslq -0x18(%rbp), %rcx
movq (%rax,%rcx,8), %rdx
movq -0x28(%rbp), %rax
movl %eax, %ecx
movq -0x20(%rbp), %r8
movl -0x2c(%rbp), %r9d
movl -0x30(%rbp), %eax
leaq 0x43e76(%rip), %rsi     # 0xe3dc6
movl %eax, (%rsp)
movb $0x0, %al
callq 0x6a80
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
jmp 0x9fec7
addq $0x40, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/faidx.c
// Function: fai_read
faidx_t *fai_read(FILE *fp)
{
    faidx_t *fai;
    char *buf, *p;
    int len, line_len, line_blen;
#ifdef _WIN32
    long offset;
#else
    long long offset;
#endif
    fai = (faidx_t*)calloc(1, sizeof(faidx_t));
    fai->hash = kh_init(s);
    buf = (char*)calloc(0x10000, 1);
    while (!feof(fp) && fgets(buf, 0x10000, fp)) {
        for (p = buf; *p && isgraph(*p); ++p);
        *p = 0; ++p;
#ifdef _WIN32
        sscanf(p, "%d%ld%d%d", &len, &offset, &line_blen, &line_len);
#else
        sscanf(p, "%d%lld%d%d", &len, &offset, &line_blen, &line_len);
#endif
        fai_insert_index(fai, buf, len, line_len, line_blen, offset);
    }
    free(buf);
    return fai;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl $0x1, %edi
movl $0x20, %esi
callq 0x6460
movq %rax, -0x10(%rbp)
callq 0x9fa10
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x18(%rax)
movl $0x10000, %edi          # imm = 0x10000
movl $0x1, %esi
callq 0x6460
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdi
callq 0x6bc0
movl %eax, %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x39(%rbp)
jne 0xa0133
movq -0x18(%rbp), %rdi
movq -0x8(%rbp), %rdx
movl $0x10000, %esi          # imm = 0x10000
callq 0x6c00
cmpq $0x0, %rax
setne %al
movb %al, -0x39(%rbp)
movb -0x39(%rbp), %al
testb $0x1, %al
jne 0xa013f
jmp 0xa01ea
movq -0x18(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movsbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x3a(%rbp)
je 0xa017c
callq 0x6780
movq (%rax), %rax
movq -0x20(%rbp), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x8000, %eax           # imm = 0x8000
cmpl $0x0, %eax
setne %al
movb %al, -0x3a(%rbp)
movb -0x3a(%rbp), %al
testb $0x1, %al
jne 0xa0185
jmp 0xa0195
jmp 0xa0187
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
jmp 0xa0147
movq -0x20(%rbp), %rax
movb $0x0, (%rax)
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
leaq 0x43c25(%rip), %rsi     # 0xe3dd8
leaq -0x24(%rbp), %rdx
leaq -0x38(%rbp), %rcx
leaq -0x2c(%rbp), %r8
leaq -0x28(%rbp), %r9
movb $0x0, %al
callq 0x66d0
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movl -0x24(%rbp), %edx
movl -0x28(%rbp), %ecx
movl -0x2c(%rbp), %r8d
movq -0x38(%rbp), %r9
callq 0x9fa30
jmp 0xa0102
movq -0x18(%rbp), %rdi
callq 0x6880
movq -0x10(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/hfile.c
// Function: hfile_init
hFILE *hfile_init(size_t struct_size, const char *mode, size_t capacity)
{
    hFILE *fp = (hFILE *) malloc(struct_size);
    if (fp == NULL) goto error;

    if (capacity == 0) capacity = 32768;
    // FIXME For now, clamp input buffer sizes so mpileup doesn't eat memory
    if (strchr(mode, 'r') && capacity > 32768) capacity = 32768;

    fp->buffer = (char *) malloc(capacity);
    if (fp->buffer == NULL) goto error;

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

    fp->offset = 0;
    fp->at_eof = 0;
    fp->has_errno = 0;
    return fp;

error:
    hfile_destroy(fp);
    return NULL;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rdi
callq 0x69c0
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0xa19ed
jmp 0xa1a9c
cmpq $0x0, -0x20(%rbp)
jne 0xa19fc
movq $0x8000, -0x20(%rbp)    # imm = 0x8000
movq -0x18(%rbp), %rdi
movl $0x72, %esi
callq 0x6260
cmpq $0x0, %rax
je 0xa1a22
cmpq $0x8000, -0x20(%rbp)    # imm = 0x8000
jbe 0xa1a22
movq $0x8000, -0x20(%rbp)    # imm = 0x8000
movq -0x20(%rbp), %rdi
callq 0x69c0
movq %rax, %rcx
movq -0x28(%rbp), %rax
movq %rcx, (%rax)
movq -0x28(%rbp), %rax
cmpq $0x0, (%rax)
jne 0xa1a41
jmp 0xa1a9c
movq -0x28(%rbp), %rax
movq (%rax), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x28(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x28(%rbp), %rax
movq (%rax), %rcx
addq -0x20(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x18(%rax)
movq -0x28(%rbp), %rax
movq $0x0, 0x28(%rax)
movq -0x28(%rbp), %rax
movb 0x30(%rax), %cl
andb $-0x2, %cl
orb $0x0, %cl
movb %cl, 0x30(%rax)
movq -0x28(%rbp), %rax
movl $0x0, 0x34(%rax)
movq -0x28(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0xa1aad
movq -0x28(%rbp), %rdi
callq 0xa1ac0
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/hfile.c
// Function: hseek
off_t hseek(hFILE *fp, off_t offset, int whence)
{
    off_t curpos, pos;

    if (writebuffer_is_nonempty(fp)) {
        int ret = flush_buffer(fp);
        if (ret < 0) return ret;
    }

    curpos = htell(fp);

    // Relative offsets are given relative to the hFILE's stream position,
    // which may differ from the backend's physical position due to buffering
    // read-ahead.  Correct for this by converting to an absolute position.
    if (whence == SEEK_CUR) {
        if (curpos + offset < 0) {
            // Either a negative offset resulted in a position before the
            // start of the file, or we overflowed when given a positive offset
            fp->has_errno = errno = (offset < 0)? EINVAL : EOVERFLOW;
            return -1;
        }

        whence = SEEK_SET;
        offset = curpos + offset;
    }

    // TODO Avoid seeking if the desired position is within our read buffer

    pos = fp->backend->seek(fp, offset, whence);
    if (pos < 0) { fp->has_errno = errno; return pos; }

    // Seeking succeeded, so discard any non-empty read buffer
    fp->begin = fp->end = fp->buffer;
    fp->at_eof = 0;

    fp->offset = pos;
    return pos;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq -0x10(%rbp), %rdi
callq 0xa2380
cmpl $0x0, %eax
je 0xa2292
movq -0x10(%rbp), %rdi
callq 0xa1fe0
movl %eax, -0x34(%rbp)
cmpl $0x0, -0x34(%rbp)
jge 0xa2290
movslq -0x34(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0xa2373
jmp 0xa2292
movq -0x10(%rbp), %rdi
callq 0xa23b0
movq %rax, -0x28(%rbp)
cmpl $0x1, -0x1c(%rbp)
jne 0xa22fc
movq -0x28(%rbp), %rax
addq -0x18(%rbp), %rax
cmpq $0x0, %rax
jge 0xa22e9
movq -0x18(%rbp), %rdx
movl $0x4b, %eax
movl $0x16, %ecx
cmpq $0x0, %rdx
cmovll %ecx, %eax
movl %eax, -0x38(%rbp)
callq 0x6060
movl -0x38(%rbp), %ecx
movl %ecx, (%rax)
movq -0x10(%rbp), %rax
movl %ecx, 0x34(%rax)
movq $-0x1, -0x8(%rbp)
jmp 0xa2373
movl $0x0, -0x1c(%rbp)
movq -0x28(%rbp), %rax
addq -0x18(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x10(%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movl -0x1c(%rbp), %edx
callq *%rax
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
jge 0xa2338
callq 0x6060
movl (%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x34(%rax)
movq -0x30(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0xa2373
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x10(%rax)
movq -0x10(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x10(%rbp), %rax
movb 0x30(%rax), %cl
andb $-0x2, %cl
orb $0x0, %cl
movb %cl, 0x30(%rax)
movq -0x30(%rbp), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x28(%rax)
movq -0x30(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/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->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 0xa2380
cmpl $0x0, %eax
je 0xa241c
movq -0x10(%rbp), %rdi
callq 0xa1f60
cmpl $0x0, %eax
jge 0xa241c
movq -0x10(%rbp), %rax
movl 0x34(%rax), %eax
movl %eax, -0x14(%rbp)
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rdi
callq *%rax
cmpl $0x0, %eax
jge 0xa243d
callq 0x6060
movl (%rax), %eax
movl %eax, -0x14(%rbp)
movq -0x10(%rbp), %rdi
callq 0xa1ac0
cmpl $0x0, -0x14(%rbp)
je 0xa2465
movl -0x14(%rbp), %eax
movl %eax, -0x18(%rbp)
callq 0x6060
movl -0x18(%rbp), %ecx
movl %ecx, (%rax)
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0xa246c
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/hfile.c
// Function: hclose_abruptly
void hclose_abruptly(hFILE *fp)
{
    int save = errno;
    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 0x6060
movl (%rax), %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x20(%rax), %rax
movq -0x8(%rbp), %rdi
callq *%rax
cmpl $0x0, %eax
jge 0xa24af
jmp 0xa24af
movq -0x8(%rbp), %rdi
callq 0xa1ac0
movl -0xc(%rbp), %eax
movl %eax, -0x10(%rbp)
callq 0x6060
movl -0x10(%rbp), %ecx
movl %ecx, (%rax)
addq $0x10, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/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) return handler->open(fname, mode);
    else if (strcmp(fname, "-") == 0) return hopen_fd_stdinout(mode);
    else return hopen_fd(fname, mode);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rdi
callq 0xa2af0
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0xa2aab
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq *%rax
movq %rax, -0x8(%rbp)
jmp 0xa2ae0
movq -0x10(%rbp), %rdi
leaq 0x3b3ac(%rip), %rsi     # 0xdde62
callq 0x6a40
cmpl $0x0, %eax
jne 0xa2acf
movq -0x18(%rbp), %rdi
callq 0xa2c60
movq %rax, -0x8(%rbp)
jmp 0xa2ae0
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0xa2ca0
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/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(s[i]) || s[i] == '+' || s[i] == '-' || s[i] == '.')
            scheme[i] = tolower(s[i]);
        else if (s[i] == ':') break;
        else return NULL;

    if (i == 0 || i >= sizeof scheme) return NULL;
    scheme[i] = '\0';

    pthread_mutex_lock(&lockInit);
    if (! schemes) {
        // TODO Wrap this in a critical section for multi-threading
        load_hfile_plugins();
    }
    pthread_mutex_unlock(&lockInit);

    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 0xa2bb4
callq 0x6780
movq (%rax), %rax
movq -0x10(%rbp), %rcx
movslq -0x20(%rbp), %rdx
movsbl (%rcx,%rdx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x8, %eax
cmpl $0x0, %eax
jne 0xa2b67
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x2b, %eax
je 0xa2b67
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x2d, %eax
je 0xa2b67
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x2e, %eax
jne 0xa2b84
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %edi
callq 0x6ab0
movb %al, %cl
movslq -0x20(%rbp), %rax
movb %cl, -0x1c(%rbp,%rax)
jmp 0xa2ba4
movq -0x10(%rbp), %rax
movslq -0x20(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x3a, %eax
jne 0xa2b97
jmp 0xa2bb4
movq $0x0, -0x8(%rbp)
jmp 0xa2c4c
jmp 0xa2ba6
movl -0x20(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
jmp 0xa2b03
cmpl $0x0, -0x20(%rbp)
je 0xa2bc4
movslq -0x20(%rbp), %rax
cmpq $0xc, %rax
jb 0xa2bce
movq $0x0, -0x8(%rbp)
jmp 0xa2c4c
movslq -0x20(%rbp), %rax
movb $0x0, -0x1c(%rbp,%rax)
leaq 0x77f6a(%rip), %rdi     # 0x11ab48
callq 0x6ae0
cmpq $0x0, 0x77f55(%rip)     # 0x11ab40
jne 0xa2bf2
callq 0xa3700
leaq 0x77f4f(%rip), %rdi     # 0x11ab48
callq 0x64e0
movq 0x77f3b(%rip), %rdi     # 0x11ab40
leaq -0x1c(%rbp), %rsi
callq 0xa35b0
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
movq 0x77f25(%rip), %rcx     # 0x11ab40
cmpl (%rcx), %eax
je 0xa2c37
movq 0x77f1a(%rip), %rax     # 0x11ab40
movq 0x20(%rax), %rax
movl -0x24(%rbp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, -0x30(%rbp)
jmp 0xa2c44
leaq 0x62082(%rip), %rax     # 0x104cc0
movq %rax, -0x30(%rbp)
jmp 0xa2c44
movq -0x30(%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/icebert[P]pblat/htslib/hfile.c
// Function: fd_write
static ssize_t fd_write(hFILE *fpv, const void *buffer, size_t nbytes)
{
    hFILE_fd *fp = (hFILE_fd *) fpv;
    ssize_t n;
    do {
        n = fp->is_socket?  send(fp->fd, buffer, nbytes, 0)
                         : write(fp->fd, buffer, nbytes);
    } while (n < 0 && errno == EINTR);
    return n;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movb 0x3c(%rax), %al
andb $0x1, %al
movzbl %al, %eax
cmpl $0x0, %eax
je 0xa2ee9
movq -0x20(%rbp), %rax
movl 0x38(%rax), %edi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
xorl %ecx, %ecx
callq 0x6340
movq %rax, -0x30(%rbp)
jmp 0xa2f01
movq -0x20(%rbp), %rax
movl 0x38(%rax), %edi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq 0x6250
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x28(%rbp)
xorl %eax, %eax
cmpq $0x0, -0x28(%rbp)
movb %al, -0x31(%rbp)
jge 0xa2f23
callq 0x6060
cmpl $0x4, (%rax)
sete %al
movb %al, -0x31(%rbp)
movb -0x31(%rbp), %al
testb $0x1, %al
jne 0xa2ebc
movq -0x28(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/hfile.c
// Function: fd_flush
static int fd_flush(hFILE *fpv)
{
    hFILE_fd *fp = (hFILE_fd *) fpv;
    int ret;
    do {
#ifdef HAVE_FDATASYNC
        ret = fdatasync(fp->fd);
#else
        ret = fsync(fp->fd);
#endif
        // Ignore invalid-for-fsync(2) errors due to being, e.g., a pipe,
        // and operation-not-supported errors (Mac OS X)
        if (ret < 0 && (errno == EINVAL || errno == ENOTSUP)) ret = 0;
    } while (ret < 0 && errno == EINTR);
    return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movl 0x38(%rax), %edi
callq 0x65c0
movl %eax, -0x14(%rbp)
cmpl $0x0, -0x14(%rbp)
jge 0xa2fc4
callq 0x6060
cmpl $0x16, (%rax)
je 0xa2fbd
callq 0x6060
cmpl $0x5f, (%rax)
jne 0xa2fc4
movl $0x0, -0x14(%rbp)
jmp 0xa2fc6
xorl %eax, %eax
cmpl $0x0, -0x14(%rbp)
movb %al, -0x15(%rbp)
jge 0xa2fdf
callq 0x6060
cmpl $0x4, (%rax)
sete %al
movb %al, -0x15(%rbp)
movb -0x15(%rbp), %al
testb $0x1, %al
jne 0xa2f94
movl -0x14(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/hfile.c
// Function: fd_close
static int fd_close(hFILE *fpv)
{
    hFILE_fd *fp = (hFILE_fd *) fpv;
    int ret;
    do {
#ifdef HAVE_CLOSESOCKET
        ret = fp->is_socket? closesocket(fp->fd) : close(fp->fd);
#else
        ret = close(fp->fd);
#endif
    } while (ret < 0 && errno == EINTR);
    return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movl 0x38(%rax), %edi
callq 0x6e90
movl %eax, -0x14(%rbp)
xorl %eax, %eax
cmpl $0x0, -0x14(%rbp)
movb %al, -0x15(%rbp)
jge 0xa302c
callq 0x6060
cmpl $0x4, (%rax)
sete %al
movb %al, -0x15(%rbp)
movb -0x15(%rbp), %al
testb $0x1, %al
jne 0xa3004
movl -0x14(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/hfile.c
// Function: hopen_mem
static hFILE *hopen_mem(const char *data, const char *mode)
{
    if (strncmp(data, "data:", 5) == 0) data += 5;

    // TODO Implement write modes, which will require memory allocation
    if (strchr(mode, 'r') == NULL) { errno = EINVAL; return NULL; }

    hFILE_mem *fp = (hFILE_mem *) hfile_init(sizeof (hFILE_mem), mode, 0);
    if (fp == NULL) return NULL;

    fp->buffer = data;
    fp->length = strlen(data);
    fp->pos = 0;
    fp->base.backend = &mem_backend;
    return &fp->base;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rdi
leaq 0x409f2(%rip), %rsi     # 0xe417d
movl $0x5, %edx
callq 0x6320
cmpl $0x0, %eax
jne 0xa37a6
movq -0x10(%rbp), %rax
addq $0x5, %rax
movq %rax, -0x10(%rbp)
movq -0x18(%rbp), %rdi
movl $0x72, %esi
callq 0x6260
cmpq $0x0, %rax
jne 0xa37cf
callq 0x6060
movl $0x16, (%rax)
movq $0x0, -0x8(%rbp)
jmp 0xa3839
movq -0x18(%rbp), %rsi
movl $0x50, %edi
xorl %eax, %eax
movl %eax, %edx
callq 0xa19c0
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0xa37f6
movq $0x0, -0x8(%rbp)
jmp 0xa3839
movq -0x10(%rbp), %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x38(%rax)
movq -0x10(%rbp), %rdi
callq 0x62c0
movq %rax, %rcx
movq -0x20(%rbp), %rax
movq %rcx, 0x40(%rax)
movq -0x20(%rbp), %rax
movq $0x0, 0x48(%rax)
movq -0x20(%rbp), %rax
leaq 0x614f3(%rip), %rcx     # 0x104d20
movq %rcx, 0x20(%rax)
movq -0x20(%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/icebert[P]pblat/htslib/hfile.c
// Function: hopen_fd_fileuri
static hFILE *hopen_fd_fileuri(const char *url, const char *mode)
{
    if (strncmp(url, "file://localhost/", 17) == 0) url += 16;
    else if (strncmp(url, "file:///", 8) == 0) url += 7;
    else { errno = EPROTONOSUPPORT; return NULL; }

    return hopen_fd(url, mode);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rdi
leaq 0x40918(%rip), %rsi     # 0xe4183
movl $0x11, %edx
callq 0x6320
cmpl $0x0, %eax
jne 0xa3888
movq -0x10(%rbp), %rax
addq $0x10, %rax
movq %rax, -0x10(%rbp)
jmp 0xa38c7
movq -0x10(%rbp), %rdi
leaq 0x40902(%rip), %rsi     # 0xe4195
movl $0x8, %edx
callq 0x6320
cmpl $0x0, %eax
jne 0xa38b0
movq -0x10(%rbp), %rax
addq $0x7, %rax
movq %rax, -0x10(%rbp)
jmp 0xa38c5
callq 0x6060
movl $0x5d, (%rax)
movq $0x0, -0x8(%rbp)
jmp 0xa38d8
jmp 0xa38c7
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0xa2ca0
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/icebert[P]pblat/htslib/hfile.c
// Function: init_add_plugin
static int init_add_plugin(void *obj, int (*init)(struct hFILE_plugin *),
                           const char *pluginname)
{
    struct hFILE_plugin_list *p = malloc (sizeof (struct hFILE_plugin_list));
    if (p == NULL) abort();

    p->plugin.api_version = 1;
    p->plugin.obj = obj;
    p->plugin.name = NULL;
    p->plugin.destroy = NULL;

    int ret = (*init)(&p->plugin);

    if (ret != 0) {
        if (hts_verbose >= 4)
            fprintf(stderr, "[W::load_hfile_plugins] "
                    "initialisation failed for plugin \"%s\": %d\n",
                    pluginname, ret);
        free(p);
        return ret;
    }

    if (hts_verbose >= 5)
        fprintf(stderr, "[M::load_hfile_plugins] loaded \"%s\"\n", pluginname);

    p->next = plugins, plugins = p;
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movl $0x28, %edi
callq 0x69c0
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0xa393e
callq 0x63b0
movq -0x28(%rbp), %rax
movl $0x1, (%rax)
movq -0x10(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x28(%rbp), %rax
movq $0x0, 0x10(%rax)
movq -0x28(%rbp), %rax
movq $0x0, 0x18(%rax)
movq -0x18(%rbp), %rax
movq -0x28(%rbp), %rdi
callq *%rax
movl %eax, -0x2c(%rbp)
cmpl $0x0, -0x2c(%rbp)
je 0xa39bb
leaq 0x6365a(%rip), %rax     # 0x106fe0
cmpl $0x4, (%rax)
jl 0xa39aa
movq 0x6163e(%rip), %rax     # 0x104fd0
movq (%rax), %rdi
movq -0x20(%rbp), %rdx
movl -0x2c(%rbp), %ecx
leaq 0x407fb(%rip), %rsi     # 0xe419e
movb $0x0, %al
callq 0x6a80
movq -0x28(%rbp), %rdi
callq 0x6880
movl -0x2c(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0xa3a04
leaq 0x6361e(%rip), %rax     # 0x106fe0
cmpl $0x5, (%rax)
jl 0xa39e3
movq 0x61602(%rip), %rax     # 0x104fd0
movq (%rax), %rdi
movq -0x20(%rbp), %rdx
leaq 0x40805(%rip), %rsi     # 0xe41e1
movb $0x0, %al
callq 0x6a80
movq 0x77186(%rip), %rcx     # 0x11ab70
movq -0x28(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x28(%rbp), %rax
movq %rax, 0x77173(%rip)     # 0x11ab70
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/hfile.c
// Function: mem_read
static ssize_t mem_read(hFILE *fpv, void *buffer, size_t nbytes)
{
    hFILE_mem *fp = (hFILE_mem *) fpv;
    size_t avail = fp->length - fp->pos;
    if (nbytes > avail) nbytes = avail;
    memcpy(buffer, fp->buffer + fp->pos, nbytes);
    fp->pos += nbytes;
    return nbytes;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq 0x40(%rax), %rax
movq -0x20(%rbp), %rcx
subq 0x48(%rcx), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rax
cmpq -0x28(%rbp), %rax
jbe 0xa3a52
movq -0x28(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rax
movq 0x38(%rax), %rsi
movq -0x20(%rbp), %rax
addq 0x48(%rax), %rsi
movq -0x18(%rbp), %rdx
callq 0x6570
movq -0x18(%rbp), %rcx
movq -0x20(%rbp), %rax
addq 0x48(%rax), %rcx
movq %rcx, 0x48(%rax)
movq -0x18(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/htslib/hfile.c
// Function: mem_seek
static off_t mem_seek(hFILE *fpv, off_t offset, int whence)
{
    hFILE_mem *fp = (hFILE_mem *) fpv;
    size_t absoffset = (offset >= 0)? offset : -offset;
    size_t origin;

    switch (whence) {
    case SEEK_SET: origin = 0; break;
    case SEEK_CUR: origin = fp->pos; break;
    case SEEK_END: origin = fp->length; break;
    default: errno = EINVAL; return -1;
    }

    if ((offset  < 0 && absoffset > origin) ||
        (offset >= 0 && absoffset > fp->length - origin)) {
        errno = EINVAL;
        return -1;
    }

    fp->pos = origin + offset;
    return fp->pos;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movl %edx, -0x1c(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x18(%rbp)
jl 0xa3abc
movq -0x18(%rbp), %rax
movq %rax, -0x40(%rbp)
jmp 0xa3ac6
xorl %eax, %eax
subq -0x18(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x30(%rbp)
movl -0x1c(%rbp), %eax
movl %eax, -0x44(%rbp)
testl %eax, %eax
je 0xa3aee
jmp 0xa3ada
movl -0x44(%rbp), %eax
subl $0x1, %eax
je 0xa3af8
jmp 0xa3ae4
movl -0x44(%rbp), %eax
subl $0x2, %eax
je 0xa3b06
jmp 0xa3b14
movq $0x0, -0x38(%rbp)
jmp 0xa3b29
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rax
movq %rax, -0x38(%rbp)
jmp 0xa3b29
movq -0x28(%rbp), %rax
movq 0x40(%rax), %rax
movq %rax, -0x38(%rbp)
jmp 0xa3b29
callq 0x6060
movl $0x16, (%rax)
movq $-0x1, -0x8(%rbp)
jmp 0xa3b87
cmpq $0x0, -0x18(%rbp)
jge 0xa3b3a
movq -0x30(%rbp), %rax
cmpq -0x38(%rbp), %rax
ja 0xa3b56
cmpq $0x0, -0x18(%rbp)
jl 0xa3b6b
movq -0x30(%rbp), %rax
movq -0x28(%rbp), %rcx
movq 0x40(%rcx), %rcx
subq -0x38(%rbp), %rcx
cmpq %rcx, %rax
jbe 0xa3b6b
callq 0x6060
movl $0x16, (%rax)
movq $-0x1, -0x8(%rbp)
jmp 0xa3b87
movq -0x38(%rbp), %rcx
addq -0x18(%rbp), %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x48(%rax)
movq -0x28(%rbp), %rax
movq 0x48(%rax), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)