LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/bzip2-1.0.6/bzlib.c
// Function: BZ2_bzBuffToBuffDecompress
int BZ_API(BZ2_bzBuffToBuffDecompress) 
                           ( char*         dest, 
                             unsigned int* destLen,
                             char*         source, 
                             unsigned int  sourceLen,
                             int           small,
                             int           verbosity )
{
   bz_stream strm;
   int ret;

   if (dest == NULL || destLen == NULL || 
       source == NULL ||
       (small != 0 && small != 1) ||
       verbosity < 0 || verbosity > 4) 
          return BZ_PARAM_ERROR;

   strm.bzalloc = NULL;
   strm.bzfree = NULL;
   strm.opaque = NULL;
   ret = BZ2_bzDecompressInit ( &strm, verbosity, small );
   if (ret != BZ_OK) return ret;

   strm.next_in = source;
   strm.next_out = dest;
   strm.avail_in = sourceLen;
   strm.avail_out = *destLen;

   ret = BZ2_bzDecompress ( &strm );
   if (ret == BZ_OK) goto output_overflow_or_eof;
   if (ret != BZ_STREAM_END) goto errhandler;

   /* normal termination */
   *destLen -= strm.avail_out;
   BZ2_bzDecompressEnd ( &strm );
   return BZ_OK;

   output_overflow_or_eof:
   if (strm.avail_out > 0) {
      BZ2_bzDecompressEnd ( &strm );
      return BZ_UNEXPECTED_EOF;
   } else {
      BZ2_bzDecompressEnd ( &strm );
      return BZ_OUTBUFF_FULL;
   };      

   errhandler:
   BZ2_bzDecompressEnd ( &strm );
   return ret; 
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x50, %rsp
movl %ecx, %ebp
testq %rdi, %rdi
sete %al
testq %rsi, %rsi
sete %cl
orb %al, %cl
testq %rdx, %rdx
sete %al
orb %cl, %al
movl $0xfffffffe, %r14d      # imm = 0xFFFFFFFE
jne 0x9943f
cmpl $0x2, %r8d
setae %al
cmpl $0x5, %r9d
setae %cl
orb %al, %cl
jne 0x9943f
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r12
xorps %xmm0, %xmm0
movq %rsp, %rdi
movups %xmm0, 0x38(%rdi)
movq $0x0, 0x48(%rdi)
movl %r9d, %esi
movl %r8d, %edx
callq 0x97906
movl %eax, %r14d
testl %eax, %eax
je 0x9944f
movl %r14d, %eax
addq $0x50, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rsp, %rdi
movq %r15, (%rdi)
movq %r12, 0x18(%rdi)
movl %ebp, 0x8(%rdi)
movl (%rbx), %eax
movl %eax, 0x20(%rdi)
callq 0x979dd
testl %eax, %eax
je 0x99484
movl %eax, %r14d
movq %rsp, %rdi
cmpl $0x4, %eax
jne 0x9949e
movl 0x20(%rdi), %eax
subl %eax, (%rbx)
callq 0x988e6
xorl %r14d, %r14d
jmp 0x9943f
movq %rsp, %rdi
movl 0x20(%rdi), %ebx
callq 0x988e6
cmpl $0x1, %ebx
movl $0xfffffff9, %r14d      # imm = 0xFFFFFFF9
sbbl $0x0, %r14d
jmp 0x9943f
callq 0x988e6
jmp 0x9943f
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/bzip2-1.0.6/bzlib.c
// Function: BZ2_bzclose
void BZ_API(BZ2_bzclose) (BZFILE* b)
{
   int bzerr;
   FILE *fp;
   
   if (b==NULL) {return;}
   fp = ((bzFile *)b)->handle;
   if(((bzFile*)b)->writing){
      BZ2_bzWriteClose(&bzerr,b,0,NULL,NULL);
      if(bzerr != BZ_OK){
         BZ2_bzWriteClose(NULL,b,1,NULL,NULL);
      }
   }else{
      BZ2_bzReadClose(&bzerr,b);
   }
   if(fp!=stdin && fp!=stdout){
      fclose(fp);
   }
}

// Assembly:
testq %rdi, %rdi
je 0x9975b
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %r14
movq (%rdi), %rbx
cmpb $0x0, 0x1394(%rdi)
je 0x99725
movq $0x0, (%rsp)
leaq 0xc(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
xorl %edx, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x98c14
cmpl $0x0, (%r15)
je 0x99732
movq $0x0, (%rsp)
xorl %edi, %edi
movq %r14, %rsi
movl $0x1, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x98c14
jmp 0x99732
leaq 0xc(%rsp), %rdi
movq %r14, %rsi
callq 0x98fe7
movq 0xb7857(%rip), %rax     # 0x150f90
cmpq (%rax), %rbx
je 0x99752
movq 0xb7813(%rip), %rax     # 0x150f58
cmpq (%rax), %rbx
je 0x99752
movq %rbx, %rdi
callq 0xb690
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/bzip2-1.0.6/bzlib.c
// Function: BZ2_bzerror
const char * BZ_API(BZ2_bzerror) (BZFILE *b, int *errnum)
{
   int err = ((bzFile *)b)->lastErr;

   if(err>0) err = 0;
   *errnum = err;
   return bzerrorstrings[err*-1];
}

// Assembly:
movl 0x13e8(%rdi), %eax
movl %eax, %ecx
sarl $0x1f, %ecx
andl %eax, %ecx
movl %ecx, (%rsi)
negl %ecx
leaq 0x5e598(%rip), %rdx     # 0xf7d0c
movslq (%rdx,%rcx,4), %rax
addq %rdx, %rax
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/bzip2-1.0.6/bzlib.c
// Function: add_pair_to_block
static
void add_pair_to_block ( EState* s )
{
   Int32 i;
   UChar ch = (UChar)(s->state_in_ch);
   for (i = 0; i < s->state_in_len; i++) {
      BZ_UPDATE_CRC( s->blockCRC, ch );
   }
   s->inUse[s->state_in_ch] = True;
   switch (s->state_in_len) {
      case 1:
         s->block[s->nblock] = (UChar)ch; s->nblock++;
         break;
      case 2:
         s->block[s->nblock] = (UChar)ch; s->nblock++;
         s->block[s->nblock] = (UChar)ch; s->nblock++;
         break;
      case 3:
         s->block[s->nblock] = (UChar)ch; s->nblock++;
         s->block[s->nblock] = (UChar)ch; s->nblock++;
         s->block[s->nblock] = (UChar)ch; s->nblock++;
         break;
      default:
         s->inUse[s->state_in_len-4] = True;
         s->block[s->nblock] = (UChar)ch; s->nblock++;
         s->block[s->nblock] = (UChar)ch; s->nblock++;
         s->block[s->nblock] = (UChar)ch; s->nblock++;
         s->block[s->nblock] = (UChar)ch; s->nblock++;
         s->block[s->nblock] = ((UChar)(s->state_in_len-4));
         s->nblock++;
         break;
   }
}

// Assembly:
movl 0x5c(%rdi), %eax
movslq 0x60(%rdi), %rcx
testq %rcx, %rcx
jle 0x997bd
movzbl %al, %edx
movl 0x288(%rdi), %r9d
leaq 0xb83b7(%rip), %rsi     # 0x151b50
movl %ecx, %r8d
movl %r9d, %r10d
shll $0x8, %r10d
shrl $0x18, %r9d
xorl %edx, %r9d
xorl (%rsi,%r9,4), %r10d
movl %r10d, 0x288(%rdi)
movl %r10d, %r9d
decl %r8d
jne 0x9979c
movb $0x1, 0x80(%rdi,%rax)
cmpl $0x3, %ecx
je 0x997f5
cmpl $0x2, %ecx
je 0x997e4
cmpl $0x1, %ecx
jne 0x99825
leaq 0x40(%rdi), %rcx
movl 0x6c(%rdi), %edx
addq $0x6c, %rdi
jmp 0x99883
leaq 0x40(%rdi), %rcx
movq 0x40(%rdi), %rdx
movslq 0x6c(%rdi), %rsi
movb %al, (%rdx,%rsi)
jmp 0x99817
leaq 0x40(%rdi), %rcx
movq 0x40(%rdi), %rdx
movslq 0x6c(%rdi), %rsi
movb %al, (%rdx,%rsi)
movslq 0x6c(%rdi), %rdx
leaq 0x1(%rdx), %rsi
movl %esi, 0x6c(%rdi)
movq 0x40(%rdi), %rsi
movb %al, 0x1(%rsi,%rdx)
movl 0x6c(%rdi), %edx
incl %edx
movl %edx, 0x6c(%rdi)
addq $0x6c, %rdi
jmp 0x99883
movb $0x1, 0x7c(%rdi,%rcx)
leaq 0x40(%rdi), %rcx
movq 0x40(%rdi), %rdx
movslq 0x6c(%rdi), %rsi
movb %al, (%rdx,%rsi)
movslq 0x6c(%rdi), %rdx
leaq 0x1(%rdx), %rsi
movl %esi, 0x6c(%rdi)
movq 0x40(%rdi), %rsi
movb %al, 0x1(%rsi,%rdx)
movslq 0x6c(%rdi), %rdx
leaq 0x1(%rdx), %rsi
movl %esi, 0x6c(%rdi)
movq 0x40(%rdi), %rsi
movb %al, 0x1(%rsi,%rdx)
movslq 0x6c(%rdi), %rdx
leaq 0x1(%rdx), %rsi
movl %esi, 0x6c(%rdi)
movq 0x40(%rdi), %rsi
movb %al, 0x1(%rsi,%rdx)
movl 0x6c(%rdi), %edx
incl %edx
movl %edx, 0x6c(%rdi)
movb 0x60(%rdi), %al
addq $0x6c, %rdi
addb $-0x4, %al
movq (%rcx), %rcx
movslq %edx, %rdx
movb %al, (%rcx,%rdx)
incl (%rdi)
retq
nop
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzlib.c
// Function: gzdopen
gzFile ZEXPORT gzdopen(int fd, const char *mode) {
    char *path;         /* identifier for error messages */
    gzFile gz;

    if (fd == -1 || (path = (char *)malloc(7 + 3 * sizeof(int))) == NULL)
        return NULL;
#if !defined(NO_snprintf) && !defined(NO_vsnprintf)
    (void)snprintf(path, 7 + 3 * sizeof(int), "<fd:%d>", fd);
#else
    sprintf(path, "<fd:%d>", fd);   /* for debugging */
#endif
    gz = gz_open(path, fd, mode);
    free(path);
    return gz;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
cmpl $-0x1, %edi
je 0x99bd5
movq %rsi, %rbx
movl %edi, %ebp
movl $0x13, %edi
callq 0xb810
testq %rax, %rax
je 0x99bd5
movq %rax, %r14
leaq 0x5e1c5(%rip), %rdx     # 0xf7d6c
movl $0x13, %esi
movq %rax, %rdi
movl %ebp, %ecx
xorl %eax, %eax
callq 0xba10
movq %r14, %rdi
movl %ebp, %esi
movq %rbx, %rdx
callq 0x998ba
movq %rax, %rbx
movq %r14, %rdi
callq 0xb790
movq %rbx, %rax
jmp 0x99bd7
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzlib.c
// Function: gzrewind
int ZEXPORT gzrewind(gzFile file) {
    gz_statep state;

    /* get internal structure */
    if (file == NULL)
        return -1;
    state = (gz_statep)file;

    /* check that we're reading and that there's no error */
    if (state->mode != GZ_READ ||
            (state->err != Z_OK && state->err != Z_BUF_ERROR))
        return -1;

    /* back up and start over */
    if (LSEEK(state->fd, state->start, SEEK_SET) == -1)
        return -1;
    gz_reset(state);
    return 0;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
testq %rdi, %rdi
je 0x99c5a
movq %rdi, %r14
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x99c5a
movl 0x74(%r14), %eax
testl %eax, %eax
je 0x99c3b
cmpl $-0x5, %eax
jne 0x99c5a
movl 0x1c(%r14), %edi
movq 0x48(%r14), %rsi
xorl %edx, %edx
callq 0xb570
cmpq $-0x1, %rax
je 0x99c5a
movq %r14, %rdi
callq 0x99c64
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzlib.c
// Function: gz_reset
local void gz_reset(gz_statep state) {
    state->x.have = 0;              /* no output data available */
    if (state->mode == GZ_READ) {   /* for reading ... */
        state->eof = 0;             /* not at end of file */
        state->past = 0;            /* have not read past end yet */
        state->how = LOOK;          /* look for gzip header */
    }
    else                            /* for writing ... */
        state->reset = 0;           /* no deflateReset pending */
    state->seek = 0;                /* no seek request pending */
    gz_error(state, Z_OK, NULL);    /* clear error */
    state->x.pos = 0;               /* no uncompressed data yet */
    state->strm.avail_in = 0;       /* no input data yet */
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl $0x0, (%rdi)
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x99c88
movq $0x0, 0x50(%rbx)
movl $0x0, 0x44(%rbx)
jmp 0x99c8f
movl $0x0, 0x60(%rbx)
movl $0x0, 0x70(%rbx)
movq 0x78(%rbx), %rdi
testq %rdi, %rdi
je 0x99cb2
cmpl $-0x4, 0x74(%rbx)
je 0x99caa
callq 0xb790
movq $0x0, 0x78(%rbx)
xorl %eax, %eax
movl %eax, 0x74(%rbx)
movq $0x0, 0x10(%rbx)
movl %eax, 0x88(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzlib.c
// Function: gz_error
void ZLIB_INTERNAL gz_error(gz_statep state, int err, const char *msg) {
    /* free previously allocated message and clear */
    if (state->msg != NULL) {
        if (state->err != Z_MEM_ERROR)
            free(state->msg);
        state->msg = NULL;
    }

    /* if fatal, set state->x.have to 0 so that the gzgetc() macro fails */
    if (err != Z_OK && err != Z_BUF_ERROR)
        state->x.have = 0;

    /* set error code, and if no message, then done */
    state->err = err;
    if (msg == NULL)
        return;

    /* for an out of memory error, return literal string when requested */
    if (err == Z_MEM_ERROR)
        return;

    /* construct error message with path */
    if ((state->msg = (char *)malloc(strlen(state->path) + strlen(msg) + 3)) ==
            NULL) {
        state->err = Z_MEM_ERROR;
        return;
    }
#if !defined(NO_snprintf) && !defined(NO_vsnprintf)
    (void)snprintf(state->msg, strlen(state->path) + strlen(msg) + 3,
                   "%s%s%s", state->path, ": ", msg);
#else
    strcpy(state->msg, state->path);
    strcat(state->msg, ": ");
    strcat(state->msg, msg);
#endif
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdx, %rbx
movl %esi, %ebp
movq %rdi, %r14
movq 0x78(%rdi), %rdi
testq %rdi, %rdi
je 0x99e44
cmpl $-0x4, 0x74(%r14)
je 0x99e3c
callq 0xb790
movq $0x0, 0x78(%r14)
cmpl $-0x5, %ebp
je 0x99e54
testl %ebp, %ebp
je 0x99e54
movl $0x0, (%r14)
movl %ebp, 0x74(%r14)
testq %rbx, %rbx
sete %al
cmpl $-0x4, %ebp
sete %cl
orb %al, %cl
jne 0x99ee1
movq 0x20(%r14), %r15
movq %r15, %rdi
callq 0xb260
movq %rax, %r12
movq %rbx, %rdi
callq 0xb260
leaq (%r12,%rax), %rdi
addq $0x3, %rdi
callq 0xb810
movq %rax, 0x78(%r14)
testq %rax, %rax
je 0x99ed9
movq %rax, %r12
movq %r15, %rdi
callq 0xb260
movq %rax, %r14
movq %rbx, %rdi
callq 0xb260
leaq (%r14,%rax), %rsi
addq $0x3, %rsi
leaq 0x5deba(%rip), %rdx     # 0xf7d74
leaq 0x623b7(%rip), %r8      # 0xfc278
movq %r12, %rdi
movq %r15, %rcx
movq %rbx, %r9
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0xba10
movl $0xfffffffc, 0x74(%r14) # imm = 0xFFFFFFFC
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzlib.c
// Function: gztell64
z_off64_t ZEXPORT gztell64(gzFile file) {
    gz_statep state;

    /* get internal structure and check integrity */
    if (file == NULL)
        return -1;
    state = (gz_statep)file;
    if (state->mode != GZ_READ && state->mode != GZ_WRITE)
        return -1;

    /* return position */
    return state->x.pos + (state->seek ? state->skip : 0);
}

// Assembly:
movq $-0x1, %rax
testq %rdi, %rdi
je 0x99f23
movl 0x18(%rdi), %ecx
cmpl $0x79b1, %ecx           # imm = 0x79B1
je 0x99f0e
cmpl $0x1c4f, %ecx           # imm = 0x1C4F
jne 0x99f23
movq 0x10(%rdi), %rcx
cmpl $0x0, 0x70(%rdi)
je 0x99f1e
movq 0x68(%rdi), %rax
jmp 0x99f20
xorl %eax, %eax
addq %rcx, %rax
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzlib.c
// Function: gzoffset64
z_off64_t ZEXPORT gzoffset64(gzFile file) {
    z_off64_t offset;
    gz_statep state;

    /* get internal structure and check integrity */
    if (file == NULL)
        return -1;
    state = (gz_statep)file;
    if (state->mode != GZ_READ && state->mode != GZ_WRITE)
        return -1;

    /* compute and return effective offset in file */
    offset = LSEEK(state->fd, 0, SEEK_CUR);
    if (offset == -1)
        return -1;
    if (state->mode == GZ_READ)             /* reading */
        offset -= state->strm.avail_in;     /* don't count buffered input */
    return offset;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq $-0x1, %rbx
testq %rdi, %rdi
je 0x99fad
movq %rdi, %r14
movl 0x18(%rdi), %eax
cmpl $0x79b1, %eax           # imm = 0x79B1
je 0x99f7d
cmpl $0x1c4f, %eax           # imm = 0x1C4F
jne 0x99fad
movl 0x1c(%r14), %edi
xorl %esi, %esi
movl $0x1, %edx
callq 0xb570
cmpq $-0x1, %rax
je 0x99fad
cmpl $0x1c4f, 0x18(%r14)     # imm = 0x1C4F
movq %rax, %rbx
jne 0x99fad
movl 0x88(%r14), %ecx
subq %rcx, %rax
movq %rax, %rbx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzlib.c
// Function: gzerror
const char * ZEXPORT gzerror(gzFile file, int *errnum) {
    gz_statep state;

    /* get internal structure and check integrity */
    if (file == NULL)
        return NULL;
    state = (gz_statep)file;
    if (state->mode != GZ_READ && state->mode != GZ_WRITE)
        return NULL;

    /* return error information */
    if (errnum != NULL)
        *errnum = state->err;
    return state->err == Z_MEM_ERROR ? "out of memory" :
                                       (state->msg == NULL ? "" : state->msg);
}

// Assembly:
testq %rdi, %rdi
je 0x99ffe
movl 0x18(%rdi), %eax
cmpl $0x79b1, %eax           # imm = 0x79B1
je 0x99fe7
cmpl $0x1c4f, %eax           # imm = 0x1C4F
jne 0x99ffe
movl 0x74(%rdi), %eax
testq %rsi, %rsi
je 0x99ff1
movl %eax, (%rsi)
cmpl $-0x4, %eax
jne 0x9a001
leaq 0x59a2d(%rip), %rax     # 0xf3a2a
retq
xorl %eax, %eax
retq
movq 0x78(%rdi), %rcx
testq %rcx, %rcx
leaq 0x54b28(%rip), %rax     # 0xeeb37
cmovneq %rcx, %rax
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzlib.c
// Function: gzclearerr
void ZEXPORT gzclearerr(gzFile file) {
    gz_statep state;

    /* get internal structure and check integrity */
    if (file == NULL)
        return;
    state = (gz_statep)file;
    if (state->mode != GZ_READ && state->mode != GZ_WRITE)
        return;

    /* clear error and end-of-file */
    if (state->mode == GZ_READ) {
        state->eof = 0;
        state->past = 0;
    }
    gz_error(state, Z_OK, NULL);
}

// Assembly:
testq %rdi, %rdi
je 0x9a05a
pushq %rbx
movq %rdi, %rbx
movl 0x18(%rdi), %eax
cmpl $0x79b1, %eax           # imm = 0x79B1
je 0x9a036
cmpl $0x1c4f, %eax           # imm = 0x1C4F
jne 0x9a059
movq $0x0, 0x50(%rbx)
movq 0x78(%rbx), %rdi
testq %rdi, %rdi
je 0x9a052
cmpl $-0x4, 0x74(%rbx)
je 0x9a04a
callq 0xb790
movq $0x0, 0x78(%rbx)
movl $0x0, 0x74(%rbx)
popq %rbx
retq
nop
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzread.c
// Function: gzread
int ZEXPORT gzread(gzFile file, voidp buf, unsigned len) {
    gz_statep state;

    /* get internal structure */
    if (file == NULL)
        return -1;
    state = (gz_statep)file;

    /* check that we're reading and that there's no (serious) error */
    if (state->mode != GZ_READ ||
            (state->err != Z_OK && state->err != Z_BUF_ERROR))
        return -1;

    /* since an int is returned, make sure len fits in one, otherwise return
       with an error (this avoids a flaw in the interface) */
    if ((int)len < 0) {
        gz_error(state, Z_STREAM_ERROR, "request does not fit in an int");
        return -1;
    }

    /* read len or fewer bytes to buf */
    len = (unsigned)gz_read(state, buf, len);

    /* check for an error */
    if (len == 0 && state->err != Z_OK && state->err != Z_BUF_ERROR)
        return -1;

    /* return the number of bytes read (this is assured to fit in an int) */
    return (int)len;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
testq %rdi, %rdi
je 0x9a0ad
movq %rdi, %r14
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x9a0ad
movl 0x74(%r14), %eax
testl %eax, %eax
je 0x9a083
cmpl $-0x5, %eax
jne 0x9a0ad
testl %edx, %edx
js 0x9a099
movl %edx, %edx
movq %r14, %rdi
callq 0x9a0c6
testl %eax, %eax
je 0x9a0b7
movl %eax, %ebx
jmp 0x9a0ad
leaq 0x5dcf8(%rip), %rdx     # 0xf7d98
movq %r14, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x99e17
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl 0x74(%r14), %ecx
testl %ecx, %ecx
je 0x9a095
cmpl $-0x5, %ecx
je 0x9a095
jmp 0x9a0ad
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzread.c
// Function: gzfread
z_size_t ZEXPORT gzfread(voidp buf, z_size_t size, z_size_t nitems, gzFile file) {
    z_size_t len;
    gz_statep state;

    /* get internal structure */
    if (file == NULL)
        return 0;
    state = (gz_statep)file;

    /* check that we're reading and that there's no (serious) error */
    if (state->mode != GZ_READ ||
            (state->err != Z_OK && state->err != Z_BUF_ERROR))
        return 0;

    /* compute bytes to read -- error on overflow */
    len = nitems * size;
    if (size && len / size != nitems) {
        gz_error(state, Z_STREAM_ERROR, "request does not fit in a size_t");
        return 0;
    }

    /* read len or fewer bytes to buf, return the number of full items read */
    return len ? gz_read(state, buf, len) / size : 0;
}

// Assembly:
testq %rcx, %rcx
je 0x9a250
cmpl $0x1c4f, 0x18(%rcx)     # imm = 0x1C4F
jne 0x9a250
pushq %rbx
movq %rsi, %rbx
movq %rdi, %rsi
movl 0x74(%rcx), %eax
testl %eax, %eax
je 0x9a228
cmpl $-0x5, %eax
jne 0x9a26a
movq %rbx, %rax
mulq %rdx
seto %dl
testq %rbx, %rbx
je 0x9a253
testb %dl, %dl
je 0x9a253
leaq 0x5db76(%rip), %rdx     # 0xf7db7
movq %rcx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x99e17
jmp 0x9a26a
xorl %eax, %eax
retq
testq %rax, %rax
je 0x9a26a
movq %rcx, %rdi
movq %rax, %rdx
callq 0x9a0c6
xorl %edx, %edx
divq %rbx
jmp 0x9a26c
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzread.c
// Function: gzgetc
int ZEXPORT gzgetc(gzFile file) {
    unsigned char buf[1];
    gz_statep state;

    /* get internal structure */
    if (file == NULL)
        return -1;
    state = (gz_statep)file;

    /* check that we're reading and that there's no (serious) error */
    if (state->mode != GZ_READ ||
        (state->err != Z_OK && state->err != Z_BUF_ERROR))
        return -1;

    /* try output buffer (no need to check for skip request) */
    if (state->x.have) {
        state->x.have--;
        state->x.pos++;
        return *(state->x.next)++;
    }

    /* nothing there -- try gz_read() */
    return gz_read(state, buf, 1) < 1 ? -1 : buf[0];
}

// Assembly:
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rdi, %rdi
je 0x9a2d7
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x9a2d7
movl 0x74(%rdi), %ecx
testl %ecx, %ecx
je 0x9a28d
cmpl $-0x5, %ecx
jne 0x9a2d7
movl (%rdi), %eax
testl %eax, %eax
je 0x9a2ab
decl %eax
movl %eax, (%rdi)
incq 0x10(%rdi)
movq 0x8(%rdi), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0x8(%rdi)
movzbl (%rax), %eax
retq
pushq %rbx
subq $0x10, %rsp
leaq 0xf(%rsp), %rbx
movl $0x1, %edx
movq %rbx, %rsi
callq 0x9a0c6
movq %rax, %rcx
movzbl (%rbx), %edx
xorl %eax, %eax
cmpq $0x1, %rcx
sbbl %eax, %eax
orl %edx, %eax
addq $0x10, %rsp
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzread.c
// Function: gz_skip
local int gz_skip(gz_statep state, z_off64_t len) {
    unsigned n;

    /* skip over len bytes or reach end-of-file, whichever comes first */
    while (len)
        /* skip over whatever is in output buffer */
        if (state->x.have) {
            n = GT_OFF(state->x.have) || (z_off64_t)state->x.have > len ?
                (unsigned)len : state->x.have;
            state->x.have -= n;
            state->x.next += n;
            state->x.pos += n;
            len -= n;
        }

        /* output buffer empty -- return if we're at the end of the input */
        else if (state->eof && state->strm.avail_in == 0)
            break;

        /* need more data to skip -- load up output buffer */
        else {
            /* get more output, looking for header if required */
            if (gz_fetch(state) == -1)
                return -1;
        }
    return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
xorl %ebx, %ebx
testq %rsi, %rsi
je 0x9a5d9
movq %rsi, %r14
movq %rdi, %r15
movl (%r15), %eax
testq %rax, %rax
je 0x9a5af
cmpq %rax, %r14
movl %r14d, %ecx
cmovgel %eax, %ecx
subl %ecx, %eax
movl %eax, (%r15)
addq %rcx, 0x8(%r15)
addq %rcx, 0x10(%r15)
subq %rcx, %r14
jmp 0x9a5cd
cmpl $0x0, 0x50(%r15)
je 0x9a5c0
cmpl $0x0, 0x88(%r15)
je 0x9a5d9
movq %r15, %rdi
callq 0x9a733
cmpl $-0x1, %eax
je 0x9a5d4
testq %r14, %r14
jne 0x9a58c
jmp 0x9a5d9
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzread.c
// Function: gz_fetch
local int gz_fetch(gz_statep state) {
    z_streamp strm = &(state->strm);

    do {
        switch(state->how) {
        case LOOK:      /* -> LOOK, COPY (only if never GZIP), or GZIP */
            if (gz_look(state) == -1)
                return -1;
            if (state->how == LOOK)
                return 0;
            break;
        case COPY:      /* -> COPY */
            if (gz_load(state, state->out, state->size << 1, &(state->x.have))
                    == -1)
                return -1;
            state->x.next = state->out;
            return 0;
        case GZIP:      /* -> GZIP or LOOK (if end of gzip stream) */
            strm->avail_out = state->size << 1;
            strm->next_out = state->out;
            if (gz_decomp(state) == -1)
                return -1;
        }
    } while (state->x.have == 0 && (!state->eof || strm->avail_in));
    return 0;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl 0x44(%rbx), %eax
testl %eax, %eax
je 0x9a76f
cmpl $0x2, %eax
je 0x9a74a
cmpl $0x1, %eax
jne 0x9a782
jmp 0x9a79a
movl 0x28(%rbx), %eax
addl %eax, %eax
movl %eax, 0xa0(%rbx)
movq 0x38(%rbx), %rax
movq %rax, 0x98(%rbx)
movq %rbx, %rdi
callq 0x9a908
cmpl $-0x1, %eax
jne 0x9a782
jmp 0x9a7bf
movq %rbx, %rdi
callq 0x9a3ea
cmpl $-0x1, %eax
je 0x9a7bf
cmpl $0x0, 0x44(%rbx)
je 0x9a7bb
xorl %eax, %eax
cmpl $0x0, (%rbx)
jne 0x9a7c4
cmpl $0x0, 0x50(%rbx)
je 0x9a737
cmpl $0x0, 0x88(%rbx)
jne 0x9a737
jmp 0x9a7c4
movq 0x38(%rbx), %rsi
movl 0x28(%rbx), %edx
addl %edx, %edx
movq %rbx, %rdi
movq %rbx, %rcx
callq 0x9a886
cmpl $-0x1, %eax
je 0x9a7bf
movq 0x38(%rbx), %rax
movq %rax, 0x8(%rbx)
xorl %eax, %eax
jmp 0x9a7c4
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzread.c
// Function: gzdirect
int ZEXPORT gzdirect(gzFile file) {
    gz_statep state;

    /* get internal structure */
    if (file == NULL)
        return 0;
    state = (gz_statep)file;

    /* if the state is not known, but we can find out, then do so (this is
       mainly for right after a gzopen() or gzdopen()) */
    if (state->mode == GZ_READ && state->how == LOOK && state->x.have == 0)
        (void)gz_look(state);

    /* return 1 if transparent, 0 if processing a gzip stream */
    return state->direct;
}

// Assembly:
testq %rdi, %rdi
je 0x9a7f0
pushq %rbx
movq %rdi, %rbx
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x9a7eb
cmpl $0x0, 0x44(%rbx)
jne 0x9a7eb
cmpl $0x0, (%rbx)
jne 0x9a7eb
movq %rbx, %rdi
callq 0x9a3ea
movl 0x40(%rbx), %eax
popq %rbx
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzread.c
// Function: gzclose_r
int ZEXPORT gzclose_r(gzFile file) {
    int ret, err;
    gz_statep state;

    /* get internal structure */
    if (file == NULL)
        return Z_STREAM_ERROR;
    state = (gz_statep)file;

    /* check that we're reading */
    if (state->mode != GZ_READ)
        return Z_STREAM_ERROR;

    /* free memory and close file */
    if (state->size) {
        inflateEnd(&(state->strm));
        free(state->out);
        free(state->in);
    }
    err = state->err == Z_BUF_ERROR ? Z_BUF_ERROR : Z_OK;
    gz_error(state, Z_OK, NULL);
    free(state->path);
    ret = close(state->fd);
    free(state);
    return ret ? Z_ERRNO : err;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl $0xfffffffe, %r14d      # imm = 0xFFFFFFFE
testq %rdi, %rdi
je 0x9a878
movq %rdi, %rbx
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x9a878
cmpl $0x0, 0x28(%rbx)
je 0x9a835
leaq 0x80(%rbx), %rdi
callq 0xa273c
movq 0x38(%rbx), %rdi
callq 0xb790
movq 0x30(%rbx), %rdi
callq 0xb790
xorl %eax, %eax
cmpl $-0x5, 0x74(%rbx)
setne %al
leal (%rax,%rax,4), %r15d
addl $-0x5, %r15d
xorl %r14d, %r14d
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x99e17
movq 0x20(%rbx), %rdi
callq 0xb790
movl 0x1c(%rbx), %edi
callq 0xbcd0
movl %eax, %ebp
movq %rbx, %rdi
callq 0xb790
negl %ebp
sbbl %r14d, %r14d
orl %r15d, %r14d
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzread.c
// Function: gz_load
local int gz_load(gz_statep state, unsigned char *buf, unsigned len,
                  unsigned *have) {
    int ret;
    unsigned get, max = ((unsigned)-1 >> 2) + 1;

    *have = 0;
    do {
        get = len - *have;
        if (get > max)
            get = max;
        ret = read(state->fd, buf + *have, get);
        if (ret <= 0)
            break;
        *have += (unsigned)ret;
    } while (*have < len);
    if (ret < 0) {
        gz_error(state, Z_ERRNO, zstrerror());
        return -1;
    }
    if (ret == 0)
        state->eof = 1;
    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %r14
movl %edx, %ebp
movq %rsi, %r15
movq %rdi, %rbx
movl $0x0, (%rcx)
xorl %eax, %eax
movl $0x40000000, %r12d      # imm = 0x40000000
movl %ebp, %edx
subl %eax, %edx
cmpl %r12d, %edx
cmovael %r12d, %edx
movl 0x1c(%rbx), %edi
movl %eax, %esi
addq %r15, %rsi
callq 0xb8e0
testl %eax, %eax
jle 0x9a8cf
addl (%r14), %eax
movl %eax, (%r14)
cmpl %ebp, %eax
jb 0x9a8a7
jmp 0x9a8d8
js 0x9a8e5
movl $0x1, 0x50(%rbx)
xorl %ebp, %ebp
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
callq 0xb060
movl (%rax), %edi
callq 0xb1d0
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movq %rax, %rdx
callq 0x99e17
jmp 0x9a8da
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzread.c
// Function: gz_decomp
local int gz_decomp(gz_statep state) {
    int ret = Z_OK;
    unsigned had;
    z_streamp strm = &(state->strm);

    /* fill output buffer up to end of deflate stream */
    had = strm->avail_out;
    do {
        /* get more input for inflate() */
        if (strm->avail_in == 0 && gz_avail(state) == -1)
            return -1;
        if (strm->avail_in == 0) {
            gz_error(state, Z_BUF_ERROR, "unexpected end of file");
            break;
        }

        /* decompress and handle errors */
        ret = inflate(strm, Z_NO_FLUSH);
        if (ret == Z_STREAM_ERROR || ret == Z_NEED_DICT) {
            gz_error(state, Z_STREAM_ERROR,
                     "internal error: inflate stream corrupt");
            return -1;
        }
        if (ret == Z_MEM_ERROR) {
            gz_error(state, Z_MEM_ERROR, "out of memory");
            return -1;
        }
        if (ret == Z_DATA_ERROR) {              /* deflate stream invalid */
            gz_error(state, Z_DATA_ERROR,
                     strm->msg == NULL ? "compressed data error" : strm->msg);
            return -1;
        }
    } while (strm->avail_out && ret != Z_STREAM_END);

    /* update available output */
    state->x.have = had - strm->avail_out;
    state->x.next = strm->next_out - state->x.have;

    /* if the gzip stream completed successfully, look for another */
    if (ret == Z_STREAM_END)
        state->how = LOOK;

    /* good decompression */
    return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
leaq 0x80(%rdi), %r15
movl 0xa0(%rdi), %r12d
xorl %r14d, %r14d
leaq 0x5d450(%rip), %r13     # 0xf7d7c
cmpl $0x0, 0x88(%rbx)
jne 0x9a953
movq %rbx, %rdi
callq 0x9aa17
cmpl $-0x1, %eax
je 0x9a9c9
cmpl $0x0, 0x88(%rbx)
je 0x9a9d8
movq %r15, %rdi
xorl %esi, %esi
callq 0xa0b70
movl %eax, %r14d
leal 0x4(%r14), %eax
cmpl $0x6, %eax
ja 0x9a973
movslq (%r13,%rax,4), %rax
addq %r13, %rax
jmpq *%rax
movl 0xa0(%rbx), %eax
cmpl $0x1, %r14d
je 0x9a9f2
testl %eax, %eax
jne 0x9a92c
jmp 0x9a9f2
leaq 0x5d482(%rip), %rdx     # 0xf7e0e
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
jmp 0x9a9c4
movq 0xb0(%rbx), %rax
testq %rax, %rax
leaq 0x5d48e(%rip), %rdx     # 0xf7e35
cmovneq %rax, %rdx
movq %rbx, %rdi
movl $0xfffffffd, %esi       # imm = 0xFFFFFFFD
jmp 0x9a9c4
leaq 0x5906e(%rip), %rdx     # 0xf3a2a
movq %rbx, %rdi
movl $0xfffffffc, %esi       # imm = 0xFFFFFFFC
callq 0x99e17
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
leaq 0x5d418(%rip), %rdx     # 0xf7df7
movq %rbx, %rdi
movl $0xfffffffb, %esi       # imm = 0xFFFFFFFB
callq 0x99e17
movl 0xa0(%rbx), %eax
subl %eax, %r12d
movl %r12d, (%rbx)
movq 0x98(%rbx), %rax
subq %r12, %rax
movq %rax, 0x8(%rbx)
xorl %eax, %eax
cmpl $0x1, %r14d
jne 0x9a9ce
movl $0x0, 0x44(%rbx)
jmp 0x9a9ce
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzread.c
// Function: gz_avail
local int gz_avail(gz_statep state) {
    unsigned got;
    z_streamp strm = &(state->strm);

    if (state->err != Z_OK && state->err != Z_BUF_ERROR)
        return -1;
    if (state->eof == 0) {
        if (strm->avail_in) {       /* copy what's there to the start */
            unsigned char *p = state->in;
            unsigned const char *q = strm->next_in;
            unsigned n = strm->avail_in;
            do {
                *p++ = *q++;
            } while (--n);
        }
        if (gz_load(state, state->in + strm->avail_in,
                    state->size - strm->avail_in, &got) == -1)
            return -1;
        strm->avail_in += got;
        strm->next_in = state->in;
    }
    return 0;
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movl 0x74(%rdi), %ecx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testl %ecx, %ecx
je 0x9aa30
cmpl $-0x5, %ecx
jne 0x9aaa4
xorl %eax, %eax
cmpl $0x0, 0x50(%rbx)
jne 0x9aaa4
movl 0x88(%rbx), %eax
testq %rax, %rax
je 0x9aa67
movq 0x30(%rbx), %rcx
movq 0x80(%rbx), %rdx
xorl %esi, %esi
movb (%rdx,%rsi), %dil
movb %dil, (%rcx,%rsi)
incq %rsi
cmpl %esi, %eax
jne 0x9aa50
movl 0x88(%rbx), %eax
jmp 0x9aa69
xorl %eax, %eax
movl %eax, %esi
addq 0x30(%rbx), %rsi
movl 0x28(%rbx), %edx
subl %eax, %edx
leaq 0xc(%rsp), %rcx
movq %rbx, %rdi
callq 0x9a886
movl %eax, %ecx
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpl $-0x1, %ecx
je 0x9aaa4
movl 0xc(%rsp), %eax
addl %eax, 0x88(%rbx)
movq 0x30(%rbx), %rax
movq %rax, 0x80(%rbx)
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
retq
nop
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzwrite.c
// Function: gzfwrite
z_size_t ZEXPORT gzfwrite(voidpc buf, z_size_t size, z_size_t nitems,
                          gzFile file) {
    z_size_t len;
    gz_statep state;

    /* get internal structure */
    if (file == NULL)
        return 0;
    state = (gz_statep)file;

    /* check that we're writing and that there's no error */
    if (state->mode != GZ_WRITE || state->err != Z_OK)
        return 0;

    /* compute bytes to read -- error on overflow */
    len = nitems * size;
    if (size && len / size != nitems) {
        gz_error(state, Z_STREAM_ERROR, "request does not fit in a size_t");
        return 0;
    }

    /* write len bytes to buf, return the number of full items written */
    return len ? gz_write(state, buf, len) / size : 0;
}

// Assembly:
testq %rcx, %rcx
je 0x9ac35
cmpl $0x79b1, 0x18(%rcx)     # imm = 0x79B1
jne 0x9ac35
cmpl $0x0, 0x74(%rcx)
je 0x9ac38
xorl %eax, %eax
retq
pushq %rbx
movq %rsi, %rbx
movq %rdi, %rsi
movq %rbx, %rax
mulq %rdx
seto %dl
testq %rbx, %rbx
je 0x9ac67
testb %dl, %dl
je 0x9ac67
leaq 0x5d15f(%rip), %rdx     # 0xf7db7
movq %rcx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x99e17
jmp 0x9ac7e
testq %rax, %rax
je 0x9ac7e
movq %rcx, %rdi
movq %rax, %rdx
callq 0x9aae8
xorl %edx, %edx
divq %rbx
jmp 0x9ac80
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzwrite.c
// Function: gzputc
int ZEXPORT gzputc(gzFile file, int c) {
    unsigned have;
    unsigned char buf[1];
    gz_statep state;
    z_streamp strm;

    /* get internal structure */
    if (file == NULL)
        return -1;
    state = (gz_statep)file;
    strm = &(state->strm);

    /* check that we're writing and that there's no error */
    if (state->mode != GZ_WRITE || state->err != Z_OK)
        return -1;

    /* check for seek request */
    if (state->seek) {
        state->seek = 0;
        if (gz_zero(state, state->skip) == -1)
            return -1;
    }

    /* try writing to input buffer for speed (state->size == 0 if buffer not
       initialized) */
    if (state->size) {
        if (strm->avail_in == 0)
            strm->next_in = state->in;
        have = (unsigned)((strm->next_in + strm->avail_in) - state->in);
        if (have < state->size) {
            state->in[have] = (unsigned char)c;
            strm->avail_in++;
            state->x.pos++;
            return c & 0xff;
        }
    }

    /* no room in buffer or not initialized, use gz_write() */
    buf[0] = (unsigned char)c;
    if (gz_write(state, buf, 1) != 1)
        return -1;
    return c & 0xff;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
testq %rdi, %rdi
je 0x9ad46
movq %rdi, %r14
cmpl $0x79b1, 0x18(%rdi)     # imm = 0x79B1
jne 0x9ad46
cmpl $0x0, 0x74(%r14)
jne 0x9ad46
movl %esi, %ebx
cmpl $0x0, 0x70(%r14)
je 0x9acd5
movl $0x0, 0x70(%r14)
movq 0x68(%r14), %rsi
movq %r14, %rdi
callq 0x9ad51
cmpl $-0x1, %eax
je 0x9ad46
movl 0x28(%r14), %eax
testl %eax, %eax
je 0x9ad23
movl 0x88(%r14), %edx
testq %rdx, %rdx
je 0x9acf6
movq 0x30(%r14), %rcx
movq 0x80(%r14), %rsi
jmp 0x9ad04
movq 0x30(%r14), %rcx
movq %rcx, 0x80(%r14)
movq %rcx, %rsi
addq %rdx, %rsi
subq %rcx, %rsi
cmpl %esi, %eax
jbe 0x9ad23
movl %esi, %eax
movb %bl, (%rcx,%rax)
incl 0x88(%r14)
incq 0x10(%r14)
movzbl %bl, %ebp
jmp 0x9ad46
leaq 0xf(%rsp), %rsi
movb %bl, (%rsi)
movl $0x1, %edx
movq %r14, %rdi
callq 0x9aae8
cmpq $0x1, %rax
movzbl %bl, %eax
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
cmovel %eax, %ebp
movl %ebp, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzwrite.c
// Function: gz_zero
local int gz_zero(gz_statep state, z_off64_t len) {
    int first;
    unsigned n;
    z_streamp strm = &(state->strm);

    /* consume whatever's left in the input buffer */
    if (strm->avail_in && gz_comp(state, Z_NO_FLUSH) == -1)
        return -1;

    /* compress len zeros (len guaranteed > 0) */
    first = 1;
    while (len) {
        n = GT_OFF(state->size) || (z_off64_t)state->size > len ?
            (unsigned)len : state->size;
        if (first) {
            memset(state->in, 0, n);
            first = 0;
        }
        strm->avail_in = n;
        strm->next_in = state->in;
        state->x.pos += n;
        if (gz_comp(state, Z_NO_FLUSH) == -1)
            return -1;
        len -= n;
    }
    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
cmpl $0x0, 0x88(%rdi)
je 0x9ad76
movq %r14, %rdi
xorl %esi, %esi
callq 0x9b081
cmpl $-0x1, %eax
je 0x9adce
testq %rbx, %rbx
je 0x9adca
xorl %eax, %eax
movl 0x28(%r14), %ecx
cmpq %rcx, %rbx
movl %ebx, %ebp
cmovgel %ecx, %ebp
movl %ebp, %r15d
testb $0x1, %al
jne 0x9ad9e
movq 0x30(%r14), %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0xb2f0
movl %ebp, 0x88(%r14)
movq 0x30(%r14), %rax
movq %rax, 0x80(%r14)
addq %r15, 0x10(%r14)
movq %r14, %rdi
xorl %esi, %esi
callq 0x9b081
cmpl $-0x1, %eax
je 0x9adce
movb $0x1, %al
subq %r15, %rbx
jne 0x9ad7d
xorl %eax, %eax
jmp 0x9add3
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzwrite.c
// Function: gzputs
int ZEXPORT gzputs(gzFile file, const char *s) {
    z_size_t len, put;
    gz_statep state;

    /* get internal structure */
    if (file == NULL)
        return -1;
    state = (gz_statep)file;

    /* check that we're writing and that there's no error */
    if (state->mode != GZ_WRITE || state->err != Z_OK)
        return -1;

    /* write string */
    len = strlen(s);
    if ((int)len < 0 || (unsigned)len != len) {
        gz_error(state, Z_STREAM_ERROR, "string length does not fit in int");
        return -1;
    }
    put = gz_write(state, s, len);
    return put < len ? -1 : (int)len;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
testq %rdi, %rdi
je 0x9ae49
movq %rdi, %r14
cmpl $0x79b1, 0x18(%rdi)     # imm = 0x79B1
jne 0x9ae49
cmpl $0x0, 0x74(%r14)
jne 0x9ae49
movq %rsi, %r15
movq %rsi, %rdi
callq 0xb260
testq $-0x80000000, %rax      # imm = 0x80000000
jne 0x9ae35
movq %rax, %r12
movq %r14, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x9aae8
cmpq %r12, %rax
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
cmovael %r12d, %ebx
jmp 0x9ae49
leaq 0x5d043(%rip), %rdx     # 0xf7e7f
movq %r14, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x99e17
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzwrite.c
// Function: gz_init
local int gz_init(gz_statep state) {
    int ret;
    z_streamp strm = &(state->strm);

    /* allocate input buffer (double size for gzprintf) */
    state->in = (unsigned char *)malloc(state->want << 1);
    if (state->in == NULL) {
        gz_error(state, Z_MEM_ERROR, "out of memory");
        return -1;
    }

    /* only need output buffer and deflate state if compressing */
    if (!state->direct) {
        /* allocate output buffer */
        state->out = (unsigned char *)malloc(state->want);
        if (state->out == NULL) {
            free(state->in);
            gz_error(state, Z_MEM_ERROR, "out of memory");
            return -1;
        }

        /* allocate deflate memory, set up for gzip compression */
        strm->zalloc = Z_NULL;
        strm->zfree = Z_NULL;
        strm->opaque = Z_NULL;
        ret = deflateInit2(strm, state->level, Z_DEFLATED,
                           MAX_WBITS + 16, DEF_MEM_LEVEL, state->strategy);
        if (ret != Z_OK) {
            free(state->out);
            free(state->in);
            gz_error(state, Z_MEM_ERROR, "out of memory");
            return -1;
        }
        strm->next_in = NULL;
    }

    /* mark state as initialized */
    state->size = state->want;

    /* initialize write buffer if compressing */
    if (!state->direct) {
        strm->avail_out = state->size;
        strm->next_out = state->out;
        state->x.next = strm->next_out;
    }
    return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movl 0x2c(%rdi), %r15d
leal (%r15,%r15), %edi
callq 0xb810
movq %rax, 0x30(%rbx)
testq %rax, %rax
je 0x9b032
cmpl $0x0, 0x40(%rbx)
je 0x9afbd
movl %r15d, 0x28(%rbx)
xorl %eax, %eax
jmp 0x9b04b
movq %rax, %r14
movq %r15, %rdi
callq 0xb810
movq %rax, 0x38(%rbx)
testq %rax, %rax
je 0x9b02a
leaq 0x80(%rbx), %rdi
xorps %xmm0, %xmm0
movups %xmm0, 0xc0(%rbx)
movq $0x0, 0xd0(%rbx)
movl 0x58(%rbx), %esi
movl 0x5c(%rbx), %r9d
leaq 0x5ce50(%rip), %rax     # 0xf7e4b
movl $0x8, %edx
movl $0x1f, %ecx
movl $0x8, %r8d
pushq $0x70
pushq %rax
callq 0x9b4ab
addq $0x10, %rsp
testl %eax, %eax
je 0x9b051
movq 0x38(%rbx), %rdi
callq 0xb790
movq 0x30(%rbx), %rdi
jmp 0x9b02d
movq %r14, %rdi
callq 0xb790
leaq 0x589f1(%rip), %rdx     # 0xf3a2a
movq %rbx, %rdi
movl $0xfffffffc, %esi       # imm = 0xFFFFFFFC
callq 0x99e17
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r14
popq %r15
retq
movq $0x0, 0x80(%rbx)
movl 0x2c(%rbx), %ecx
movl %ecx, 0x28(%rbx)
xorl %eax, %eax
cmpl $0x0, 0x40(%rbx)
jne 0x9b04b
movl %ecx, 0xa0(%rbx)
movq 0x38(%rbx), %rcx
movq %rcx, 0x98(%rbx)
movq %rcx, 0x8(%rbx)
jmp 0x9b04b
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzwrite.c
// Function: gzflush
int ZEXPORT gzflush(gzFile file, int flush) {
    gz_statep state;

    /* get internal structure */
    if (file == NULL)
        return Z_STREAM_ERROR;
    state = (gz_statep)file;

    /* check that we're writing and that there's no error */
    if (state->mode != GZ_WRITE || state->err != Z_OK)
        return Z_STREAM_ERROR;

    /* check flush parameter */
    if (flush < 0 || flush > Z_FINISH)
        return Z_STREAM_ERROR;

    /* check for seek request */
    if (state->seek) {
        state->seek = 0;
        if (gz_zero(state, state->skip) == -1)
            return state->err;
    }

    /* compress remaining data with requested flush */
    (void)gz_comp(state, flush);
    return state->err;
}

// Assembly:
movl $0xfffffffe, %eax       # imm = 0xFFFFFFFE
testq %rdi, %rdi
je 0x9b323
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
cmpl $0x79b1, 0x18(%rdi)     # imm = 0x79B1
jne 0x9b31d
movl %esi, %ebp
cmpl $0x4, %esi
ja 0x9b31d
cmpl $0x0, 0x74(%rbx)
jne 0x9b31d
cmpl $0x0, 0x70(%rbx)
je 0x9b310
movl $0x0, 0x70(%rbx)
movq 0x68(%rbx), %rsi
movq %rbx, %rdi
callq 0x9ad51
cmpl $-0x1, %eax
je 0x9b31a
movq %rbx, %rdi
movl %ebp, %esi
callq 0x9b081
movl 0x74(%rbx), %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzwrite.c
// Function: gzsetparams
int ZEXPORT gzsetparams(gzFile file, int level, int strategy) {
    gz_statep state;
    z_streamp strm;

    /* get internal structure */
    if (file == NULL)
        return Z_STREAM_ERROR;
    state = (gz_statep)file;
    strm = &(state->strm);

    /* check that we're writing and that there's no error */
    if (state->mode != GZ_WRITE || state->err != Z_OK || state->direct)
        return Z_STREAM_ERROR;

    /* if no change is requested, then do nothing */
    if (level == state->level && strategy == state->strategy)
        return Z_OK;

    /* check for seek request */
    if (state->seek) {
        state->seek = 0;
        if (gz_zero(state, state->skip) == -1)
            return state->err;
    }

    /* change compression parameters for subsequent input */
    if (state->size) {
        /* flush previous input with previous parameters before changing */
        if (strm->avail_in && gz_comp(state, Z_BLOCK) == -1)
            return state->err;
        deflateParams(strm, level, strategy);
    }
    state->level = level;
    state->strategy = strategy;
    return Z_OK;
}

// Assembly:
movl $0xfffffffe, %eax       # imm = 0xFFFFFFFE
testq %rdi, %rdi
je 0x9b3c1
pushq %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
cmpl $0x79b1, 0x18(%rdi)     # imm = 0x79B1
jne 0x9b3bd
cmpl $0x0, 0x74(%rbx)
jne 0x9b3bd
cmpl $0x0, 0x40(%rbx)
jne 0x9b3bd
movl %edx, %ebp
movl %esi, %r14d
cmpl %esi, 0x58(%rbx)
jne 0x9b35f
xorl %eax, %eax
cmpl %ebp, 0x5c(%rbx)
je 0x9b3bd
cmpl $0x0, 0x70(%rbx)
je 0x9b37d
movl $0x0, 0x70(%rbx)
movq 0x68(%rbx), %rsi
movq %rbx, %rdi
callq 0x9ad51
cmpl $-0x1, %eax
je 0x9b3ba
cmpl $0x0, 0x28(%rbx)
je 0x9b3af
cmpl $0x0, 0x88(%rbx)
je 0x9b39e
movq %rbx, %rdi
movl $0x5, %esi
callq 0x9b081
cmpl $-0x1, %eax
je 0x9b3ba
leaq 0x80(%rbx), %rdi
movl %r14d, %esi
movl %ebp, %edx
callq 0x9bfa5
movl %r14d, 0x58(%rbx)
movl %ebp, 0x5c(%rbx)
xorl %eax, %eax
jmp 0x9b3bd
movl 0x74(%rbx), %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/genometools[P]genometools/src/external/zlib-1.3.0.1/gzwrite.c
// Function: gzclose_w
int ZEXPORT gzclose_w(gzFile file) {
    int ret = Z_OK;
    gz_statep state;

    /* get internal structure */
    if (file == NULL)
        return Z_STREAM_ERROR;
    state = (gz_statep)file;

    /* check that we're writing */
    if (state->mode != GZ_WRITE)
        return Z_STREAM_ERROR;

    /* check for seek request */
    if (state->seek) {
        state->seek = 0;
        if (gz_zero(state, state->skip) == -1)
            ret = state->err;
    }

    /* flush, free memory, and close file */
    if (gz_comp(state, Z_FINISH) == -1)
        ret = state->err;
    if (state->size) {
        if (!state->direct) {
            (void)deflateEnd(&(state->strm));
            free(state->out);
        }
        free(state->in);
    }
    gz_error(state, Z_OK, NULL);
    free(state->path);
    if (close(state->fd) == -1)
        ret = Z_ERRNO;
    free(state);
    return ret;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl $0xfffffffe, %ebx       # imm = 0xFFFFFFFE
testq %rdi, %rdi
je 0x9b478
movq %rdi, %r14
cmpl $0x79b1, 0x18(%rdi)     # imm = 0x79B1
jne 0x9b478
xorl %ebx, %ebx
cmpl $0x0, 0x70(%r14)
je 0x9b40a
movl $0x0, 0x70(%r14)
movq 0x68(%r14), %rsi
movq %r14, %rdi
callq 0x9ad51
cmpl $-0x1, %eax
jne 0x9b40a
movl 0x74(%r14), %ebx
movq %r14, %rdi
movl $0x4, %esi
callq 0x9b081
cmpl $-0x1, %eax
jne 0x9b420
movl 0x74(%r14), %ebx
cmpl $0x0, 0x28(%r14)
je 0x9b44c
cmpl $0x0, 0x40(%r14)
jne 0x9b443
leaq 0x80(%r14), %rdi
callq 0x9b77e
movq 0x38(%r14), %rdi
callq 0xb790
movq 0x30(%r14), %rdi
callq 0xb790
movq %r14, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x99e17
movq 0x20(%r14), %rdi
callq 0xb790
movl 0x1c(%r14), %edi
callq 0xbcd0
cmpl $-0x1, %eax
cmovel %eax, %ebx
movq %r14, %rdi
callq 0xb790
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop