LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/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 0x99e99
cmpl $0x2, %r8d
setae %al
cmpl $0x5, %r9d
setae %cl
orb %al, %cl
jne 0x99e99
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 0x9839a
movl %eax, %r14d
testl %eax, %eax
je 0x99ea9
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 0x98471
testl %eax, %eax
je 0x99ede
movl %eax, %r14d
movq %rsp, %rdi
cmpl $0x4, %eax
jne 0x99ef8
movl 0x20(%rdi), %eax
subl %eax, (%rbx)
callq 0x99386
xorl %r14d, %r14d
jmp 0x99e99
movq %rsp, %rdi
movl 0x20(%rdi), %ebx
callq 0x99386
cmpl $0x1, %ebx
movl $0xfffffff9, %r14d      # imm = 0xFFFFFFF9
sbbl $0x0, %r14d
jmp 0x99e99
callq 0x99386
jmp 0x99e99
// File: /workspace/github_c_makefile_star2_O1/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 0x9a1b5
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %r14
movq (%rdi), %rbx
cmpb $0x0, 0x1394(%rdi)
je 0x9a17f
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 0x99681
cmpl $0x0, (%r15)
je 0x9a18c
movq $0x0, (%rsp)
xorl %edi, %edi
movq %r14, %rsi
movl $0x1, %edx
xorl %ecx, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x99681
jmp 0x9a18c
leaq 0xc(%rsp), %rdi
movq %r14, %rsi
callq 0x99a4d
movq 0xb6dfd(%rip), %rax     # 0x150f90
cmpq (%rax), %rbx
je 0x9a1ac
movq 0xb6db9(%rip), %rax     # 0x150f58
cmpq (%rax), %rbx
je 0x9a1ac
movq %rbx, %rdi
callq 0xb690
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x5dbd6(%rip), %rdx     # 0xf7da4
movslq (%rdx,%rcx,4), %rax
addq %rdx, %rax
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9a217
movzbl %al, %edx
movl 0x288(%rdi), %r9d
leaq 0xb795d(%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 0x9a1f6
movb $0x1, 0x80(%rdi,%rax)
cmpl $0x3, %ecx
je 0x9a24f
cmpl $0x2, %ecx
je 0x9a23e
cmpl $0x1, %ecx
jne 0x9a27f
leaq 0x40(%rdi), %rcx
movl 0x6c(%rdi), %edx
addq $0x6c, %rdi
jmp 0x9a2dd
leaq 0x40(%rdi), %rcx
movq 0x40(%rdi), %rdx
movslq 0x6c(%rdi), %rsi
movb %al, (%rdx,%rsi)
jmp 0x9a271
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 0x9a2dd
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
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O1/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 0x9a621
movq %rsi, %rbx
movl %edi, %ebp
movl $0x13, %edi
callq 0xb810
testq %rax, %rax
je 0x9a621
movq %rax, %r14
leaq 0x5d811(%rip), %rdx     # 0xf7e04
movl $0x13, %esi
movq %rax, %rdi
movl %ebp, %ecx
xorl %eax, %eax
callq 0xba10
movq %r14, %rdi
movl %ebp, %esi
movq %rbx, %rdx
callq 0x9a316
movq %rax, %rbx
movq %r14, %rdi
callq 0xb790
movq %rbx, %rax
jmp 0x9a623
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9a6a6
movq %rdi, %r14
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x9a6a6
movl 0x74(%r14), %eax
testl %eax, %eax
je 0x9a687
cmpl $-0x5, %eax
jne 0x9a6a6
movl 0x1c(%r14), %edi
movq 0x48(%r14), %rsi
xorl %edx, %edx
callq 0xb570
cmpq $-0x1, %rax
je 0x9a6a6
movq %r14, %rdi
callq 0x9a6b0
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9a6d4
movq $0x0, 0x50(%rbx)
movl $0x0, 0x44(%rbx)
jmp 0x9a6db
movl $0x0, 0x60(%rbx)
movl $0x0, 0x70(%rbx)
movq 0x78(%rbx), %rdi
testq %rdi, %rdi
je 0x9a6fe
cmpl $-0x4, 0x74(%rbx)
je 0x9a6f6
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_O1/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 0x9a890
cmpl $-0x4, 0x74(%r14)
je 0x9a888
callq 0xb790
movq $0x0, 0x78(%r14)
cmpl $-0x5, %ebp
je 0x9a8a0
testl %ebp, %ebp
je 0x9a8a0
movl $0x0, (%r14)
movl %ebp, 0x74(%r14)
testq %rbx, %rbx
sete %al
cmpl $-0x4, %ebp
sete %cl
orb %al, %cl
jne 0x9a92d
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 0x9a925
movq %rax, %r12
movq %r15, %rdi
callq 0xb260
movq %rax, %r14
movq %rbx, %rdi
callq 0xb260
leaq (%r14,%rax), %rsi
addq $0x3, %rsi
leaq 0x5d506(%rip), %rdx     # 0xf7e0c
leaq 0x619fb(%rip), %r8      # 0xfc308
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_O1/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 0x9a96f
movl 0x18(%rdi), %ecx
cmpl $0x79b1, %ecx           # imm = 0x79B1
je 0x9a95a
cmpl $0x1c4f, %ecx           # imm = 0x1C4F
jne 0x9a96f
movq 0x10(%rdi), %rcx
cmpl $0x0, 0x70(%rdi)
je 0x9a96a
movq 0x68(%rdi), %rax
jmp 0x9a96c
xorl %eax, %eax
addq %rcx, %rax
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9a9f9
movq %rdi, %r14
movl 0x18(%rdi), %eax
cmpl $0x79b1, %eax           # imm = 0x79B1
je 0x9a9c9
cmpl $0x1c4f, %eax           # imm = 0x1C4F
jne 0x9a9f9
movl 0x1c(%r14), %edi
xorl %esi, %esi
movl $0x1, %edx
callq 0xb570
cmpq $-0x1, %rax
je 0x9a9f9
cmpl $0x1c4f, 0x18(%r14)     # imm = 0x1C4F
movq %rax, %rbx
jne 0x9a9f9
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_O1/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 0x9aa4b
movl 0x18(%rdi), %eax
cmpl $0x79b1, %eax           # imm = 0x79B1
je 0x9aa33
cmpl $0x1c4f, %eax           # imm = 0x1C4F
jne 0x9aa4b
testq %rsi, %rsi
je 0x9aa3d
movl 0x74(%rdi), %eax
movl %eax, (%rsi)
cmpl $-0x4, 0x74(%rdi)
jne 0x9aa4e
leaq 0x59040(%rip), %rax     # 0xf3a8a
retq
xorl %eax, %eax
retq
movq 0x78(%rdi), %rcx
testq %rcx, %rcx
leaq 0x54123(%rip), %rax     # 0xeeb7f
cmovneq %rcx, %rax
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9aaa7
pushq %rbx
movq %rdi, %rbx
movl 0x18(%rdi), %eax
cmpl $0x79b1, %eax           # imm = 0x79B1
je 0x9aa83
cmpl $0x1c4f, %eax           # imm = 0x1C4F
jne 0x9aaa6
movq $0x0, 0x50(%rbx)
movq 0x78(%rbx), %rdi
testq %rdi, %rdi
je 0x9aa9f
cmpl $-0x4, 0x74(%rbx)
je 0x9aa97
callq 0xb790
movq $0x0, 0x78(%rbx)
movl $0x0, 0x74(%rbx)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9aaf9
movq %rdi, %r14
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x9aaf9
movl 0x74(%r14), %eax
testl %eax, %eax
je 0x9aacf
cmpl $-0x5, %eax
jne 0x9aaf9
testl %edx, %edx
js 0x9aae5
movl %edx, %edx
movq %r14, %rdi
callq 0x9ab12
testl %eax, %eax
je 0x9ab03
movl %eax, %ebx
jmp 0x9aaf9
leaq 0x5d344(%rip), %rdx     # 0xf7e30
movq %r14, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x9a863
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl 0x74(%r14), %ecx
testl %ecx, %ecx
je 0x9aae1
cmpl $-0x5, %ecx
je 0x9aae1
jmp 0x9aaf9
// File: /workspace/github_c_makefile_star2_O1/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 0x9ac9b
cmpl $0x1c4f, 0x18(%rcx)     # imm = 0x1C4F
jne 0x9ac9b
pushq %rbx
movq %rsi, %rbx
movq %rdi, %rsi
movl 0x74(%rcx), %eax
testl %eax, %eax
je 0x9ac73
cmpl $-0x5, %eax
jne 0x9acb5
movq %rbx, %rax
mulq %rdx
seto %dl
testq %rbx, %rbx
je 0x9ac9e
testb %dl, %dl
je 0x9ac9e
leaq 0x5d1c3(%rip), %rdx     # 0xf7e4f
movq %rcx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x9a863
jmp 0x9acb5
xorl %eax, %eax
retq
testq %rax, %rax
je 0x9acb5
movq %rcx, %rdi
movq %rax, %rdx
callq 0x9ab12
xorl %edx, %edx
divq %rbx
jmp 0x9acb7
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9ad22
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x9ad22
movl 0x74(%rdi), %ecx
testl %ecx, %ecx
je 0x9acd8
cmpl $-0x5, %ecx
jne 0x9ad22
movl (%rdi), %eax
testl %eax, %eax
je 0x9acf6
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 0x9ab12
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_O1/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 0x9b024
movq %rsi, %r14
movq %rdi, %r15
movl (%r15), %eax
testq %rax, %rax
je 0x9affa
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 0x9b018
cmpl $0x0, 0x50(%r15)
je 0x9b00b
cmpl $0x0, 0x88(%r15)
je 0x9b024
movq %r15, %rdi
callq 0x9b160
cmpl $-0x1, %eax
je 0x9b01f
testq %r14, %r14
jne 0x9afd7
jmp 0x9b024
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
movl %ebx, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9b19c
cmpl $0x2, %eax
je 0x9b177
cmpl $0x1, %eax
jne 0x9b1af
jmp 0x9b1c7
movl 0x28(%rbx), %eax
addl %eax, %eax
movl %eax, 0xa0(%rbx)
movq 0x38(%rbx), %rax
movq %rax, 0x98(%rbx)
movq %rbx, %rdi
callq 0x9b33a
cmpl $-0x1, %eax
jne 0x9b1af
jmp 0x9b1ec
movq %rbx, %rdi
callq 0x9ae37
cmpl $-0x1, %eax
je 0x9b1ec
cmpl $0x0, 0x44(%rbx)
je 0x9b1e8
xorl %eax, %eax
cmpl $0x0, (%rbx)
jne 0x9b1f1
cmpl $0x0, 0x50(%rbx)
je 0x9b164
cmpl $0x0, 0x88(%rbx)
jne 0x9b164
jmp 0x9b1f1
movq 0x38(%rbx), %rsi
movl 0x28(%rbx), %edx
addl %edx, %edx
movq %rbx, %rdi
movq %rbx, %rcx
callq 0x9b2b3
cmpl $-0x1, %eax
je 0x9b1ec
movq 0x38(%rbx), %rax
movq %rax, 0x8(%rbx)
xorl %eax, %eax
jmp 0x9b1f1
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9b21d
pushq %rbx
movq %rdi, %rbx
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x9b218
cmpl $0x0, 0x44(%rbx)
jne 0x9b218
cmpl $0x0, (%rbx)
jne 0x9b218
movq %rbx, %rdi
callq 0x9ae37
movl 0x40(%rbx), %eax
popq %rbx
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9b2a5
movq %rdi, %rbx
cmpl $0x1c4f, 0x18(%rdi)     # imm = 0x1C4F
jne 0x9b2a5
cmpl $0x0, 0x28(%rbx)
je 0x9b262
leaq 0x80(%rbx), %rdi
callq 0xa2f92
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 0x9a863
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_O1/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)
movl $0x40000000, %r12d      # imm = 0x40000000
movl (%r14), %esi
movl %ebp, %edx
subl %esi, %edx
cmpl %r12d, %edx
cmovael %r12d, %edx
movl 0x1c(%rbx), %edi
addq %r15, %rsi
callq 0xb8e0
testl %eax, %eax
jle 0x9b2fb
movl (%r14), %ecx
addl %eax, %ecx
movl %ecx, (%r14)
cmpl %ebp, %ecx
jb 0x9b2d2
testl %eax, %eax
js 0x9b30e
xorl %ebp, %ebp
testl %eax, %eax
jne 0x9b32f
movl $0x1, 0x50(%rbx)
jmp 0x9b32f
callq 0xb060
movl (%rax), %edi
callq 0xb1d0
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movq %rax, %rdx
callq 0x9a863
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x5cab6(%rip), %r13     # 0xf7e14
cmpl $0x0, 0x88(%rbx)
jne 0x9b378
movq %rbx, %rdi
callq 0x9b442
cmpl $-0x1, %eax
je 0x9b433
cmpl $0x0, 0x88(%rbx)
je 0x9b3c3
movq %r15, %rdi
xorl %esi, %esi
callq 0xa159a
movl %eax, %r14d
leal 0x4(%r14), %eax
cmpl $0x6, %eax
ja 0x9b3a1
movslq (%r13,%rax,4), %rax
addq %r13, %rax
jmpq *%rax
cmpl $0x1, %r14d
je 0x9b3d7
cmpl $0x0, 0xa0(%rbx)
jne 0x9b35e
jmp 0x9b3d7
leaq 0x5caed(%rip), %rdx     # 0xf7ea6
movq %rbx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
jmp 0x9b42e
leaq 0x5cac5(%rip), %rdx     # 0xf7e8f
movq %rbx, %rdi
movl $0xfffffffb, %esi       # imm = 0xFFFFFFFB
callq 0x9a863
subl 0xa0(%rbx), %r12d
movl %r12d, (%rbx)
movq 0x98(%rbx), %rax
subq %r12, %rax
movq %rax, 0x8(%rbx)
xorl %eax, %eax
cmpl $0x1, %r14d
jne 0x9b438
movl $0x0, 0x44(%rbx)
jmp 0x9b438
leaq 0x58683(%rip), %rdx     # 0xf3a8a
movq %rbx, %rdi
movl $0xfffffffc, %esi       # imm = 0xFFFFFFFC
jmp 0x9b42e
movq 0xb0(%rbx), %rax
testq %rax, %rax
leaq 0x5caab(%rip), %rdx     # 0xf7ecd
cmovneq %rax, %rdx
movq %rbx, %rdi
movl $0xfffffffd, %esi       # imm = 0xFFFFFFFD
callq 0x9a863
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/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 %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movl 0x74(%rdi), %eax
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
testl %eax, %eax
je 0x9b45a
cmpl $-0x5, %eax
jne 0x9b4c4
cmpl $0x0, 0x50(%r14)
jne 0x9b4c2
movl 0x88(%r14), %eax
testq %rax, %rax
je 0x9b489
movq 0x30(%r14), %rcx
movq 0x80(%r14), %rdx
xorl %esi, %esi
movb (%rdx,%rsi), %dil
movb %dil, (%rcx,%rsi)
incq %rsi
cmpl %esi, %eax
jne 0x9b47a
movl 0x28(%r14), %edx
movl 0x88(%r14), %esi
subl %esi, %edx
addq 0x30(%r14), %rsi
leaq 0x4(%rsp), %rcx
movq %r14, %rdi
callq 0x9b2b3
cmpl $-0x1, %eax
je 0x9b4c4
movl 0x4(%rsp), %eax
addl %eax, 0x88(%r14)
movq 0x30(%r14), %rax
movq %rax, 0x80(%r14)
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_c_makefile_star2_O1/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 0x9b651
cmpl $0x79b1, 0x18(%rcx)     # imm = 0x79B1
jne 0x9b651
cmpl $0x0, 0x74(%rcx)
je 0x9b654
xorl %eax, %eax
retq
pushq %rbx
movq %rsi, %rbx
movq %rdi, %rsi
movq %rbx, %rax
mulq %rdx
seto %dl
testq %rbx, %rbx
je 0x9b683
testb %dl, %dl
je 0x9b683
leaq 0x5c7db(%rip), %rdx     # 0xf7e4f
movq %rcx, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x9a863
jmp 0x9b69a
testq %rax, %rax
je 0x9b69a
movq %rcx, %rdi
movq %rax, %rdx
callq 0x9b50c
xorl %edx, %edx
divq %rbx
jmp 0x9b69c
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9b75a
movq %rdi, %r14
cmpl $0x79b1, 0x18(%rdi)     # imm = 0x79B1
jne 0x9b75a
cmpl $0x0, 0x74(%r14)
jne 0x9b75a
movl %esi, %ebx
cmpl $0x0, 0x70(%r14)
je 0x9b6f1
movl $0x0, 0x70(%r14)
movq 0x68(%r14), %rsi
movq %r14, %rdi
callq 0x9b765
cmpl $-0x1, %eax
je 0x9b75a
movl 0x28(%r14), %ecx
testl %ecx, %ecx
je 0x9b737
movl 0x88(%r14), %eax
testq %rax, %rax
jne 0x9b710
movq 0x30(%r14), %rdx
movq %rdx, 0x80(%r14)
addq 0x80(%r14), %rax
movq 0x30(%r14), %rdx
subq %rdx, %rax
cmpl %eax, %ecx
jbe 0x9b737
movl %eax, %eax
movb %bl, (%rdx,%rax)
incl 0x88(%r14)
incq 0x10(%r14)
movzbl %bl, %ebp
jmp 0x9b75a
leaq 0xf(%rsp), %rsi
movb %bl, (%rsi)
movl $0x1, %edx
movq %r14, %rdi
callq 0x9b50c
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_O1/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 0x9b78a
movq %r14, %rdi
xorl %esi, %esi
callq 0x9ba91
cmpl $-0x1, %eax
je 0x9b7e2
testq %rbx, %rbx
je 0x9b7de
xorl %eax, %eax
movl 0x28(%r14), %ecx
cmpq %rcx, %rbx
movl %ebx, %ebp
cmovgel %ecx, %ebp
movl %ebp, %r15d
testb $0x1, %al
jne 0x9b7b2
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 0x9ba91
cmpl $-0x1, %eax
je 0x9b7e2
movb $0x1, %al
subq %r15, %rbx
jne 0x9b791
xorl %eax, %eax
jmp 0x9b7e7
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9b85d
movq %rdi, %r14
cmpl $0x79b1, 0x18(%rdi)     # imm = 0x79B1
jne 0x9b85d
cmpl $0x0, 0x74(%r14)
jne 0x9b85d
movq %rsi, %r15
movq %rsi, %rdi
callq 0xb260
testq $-0x80000000, %rax      # imm = 0x80000000
jne 0x9b849
movq %rax, %r12
movq %r14, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x9b50c
cmpq %r12, %rax
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
cmovael %r12d, %ebx
jmp 0x9b85d
leaq 0x5c6c7(%rip), %rdx     # 0xf7f17
movq %r14, %rdi
movl $0xfffffffe, %esi       # imm = 0xFFFFFFFE
callq 0x9a863
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9ba66
cmpl $0x0, 0x40(%rbx)
je 0x9b9ee
movl 0x2c(%rbx), %ecx
movl %ecx, 0x28(%rbx)
xorl %eax, %eax
cmpl $0x0, 0x40(%rbx)
jne 0x9ba7f
movl %ecx, 0xa0(%rbx)
movq 0x38(%rbx), %rcx
movq %rcx, 0x98(%rbx)
movq %rcx, 0x8(%rbx)
jmp 0x9ba7f
movq %rax, %r14
movq %r15, %rdi
callq 0xb810
movq %rax, 0x38(%rbx)
testq %rax, %rax
je 0x9ba5e
leaq 0x80(%rbx), %r14
xorps %xmm0, %xmm0
movups %xmm0, 0xc0(%rbx)
movq $0x0, 0xd0(%rbx)
movl 0x58(%rbx), %esi
movl 0x5c(%rbx), %r9d
leaq 0x5c4b7(%rip), %rax     # 0xf7ee3
movq %r14, %rdi
movl $0x8, %edx
movl $0x1f, %ecx
movl $0x8, %r8d
pushq $0x70
pushq %rax
callq 0x9bea3
addq $0x10, %rsp
testl %eax, %eax
je 0x9ba85
movq 0x38(%rbx), %rdi
callq 0xb790
movq 0x30(%rbx), %rdi
jmp 0x9ba61
movq %r14, %rdi
callq 0xb790
leaq 0x5801d(%rip), %rdx     # 0xf3a8a
movq %rbx, %rdi
movl $0xfffffffc, %esi       # imm = 0xFFFFFFFC
callq 0x9a863
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r14
popq %r15
retq
movq $0x0, (%r14)
jmp 0x9b9c2
// File: /workspace/github_c_makefile_star2_O1/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 0x9bd1c
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
cmpl $0x79b1, 0x18(%rdi)     # imm = 0x79B1
jne 0x9bd16
movl %esi, %ebp
cmpl $0x4, %esi
ja 0x9bd16
cmpl $0x0, 0x74(%rbx)
jne 0x9bd16
cmpl $0x0, 0x70(%rbx)
je 0x9bd09
movl $0x0, 0x70(%rbx)
movq 0x68(%rbx), %rsi
movq %rbx, %rdi
callq 0x9b765
cmpl $-0x1, %eax
je 0x9bd13
movq %rbx, %rdi
movl %ebp, %esi
callq 0x9ba91
movl 0x74(%rbx), %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9bdba
pushq %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
cmpl $0x79b1, 0x18(%rdi)     # imm = 0x79B1
jne 0x9bdb6
cmpl $0x0, 0x74(%rbx)
jne 0x9bdb6
cmpl $0x0, 0x40(%rbx)
jne 0x9bdb6
movl %edx, %ebp
movl %esi, %r14d
cmpl %esi, 0x58(%rbx)
jne 0x9bd58
xorl %eax, %eax
cmpl %ebp, 0x5c(%rbx)
je 0x9bdb6
cmpl $0x0, 0x70(%rbx)
je 0x9bd76
movl $0x0, 0x70(%rbx)
movq 0x68(%rbx), %rsi
movq %rbx, %rdi
callq 0x9b765
cmpl $-0x1, %eax
je 0x9bdb3
cmpl $0x0, 0x28(%rbx)
je 0x9bda8
cmpl $0x0, 0x88(%rbx)
je 0x9bd97
movq %rbx, %rdi
movl $0x5, %esi
callq 0x9ba91
cmpl $-0x1, %eax
je 0x9bdb3
leaq 0x80(%rbx), %rdi
movl %r14d, %esi
movl %ebp, %edx
callq 0x9c980
movl %r14d, 0x58(%rbx)
movl %ebp, 0x5c(%rbx)
xorl %eax, %eax
jmp 0x9bdb6
movl 0x74(%rbx), %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/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 0x9be71
movq %rdi, %r14
cmpl $0x79b1, 0x18(%rdi)     # imm = 0x79B1
jne 0x9be71
xorl %ebx, %ebx
cmpl $0x0, 0x70(%r14)
je 0x9be03
movl $0x0, 0x70(%r14)
movq 0x68(%r14), %rsi
movq %r14, %rdi
callq 0x9b765
cmpl $-0x1, %eax
jne 0x9be03
movl 0x74(%r14), %ebx
movq %r14, %rdi
movl $0x4, %esi
callq 0x9ba91
cmpl $-0x1, %eax
jne 0x9be19
movl 0x74(%r14), %ebx
cmpl $0x0, 0x28(%r14)
je 0x9be45
cmpl $0x0, 0x40(%r14)
jne 0x9be3c
leaq 0x80(%r14), %rdi
callq 0x9c179
movq 0x38(%r14), %rdi
callq 0xb790
movq 0x30(%r14), %rdi
callq 0xb790
movq %r14, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x9a863
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