// File: /workspace/github_c_makefile_star2_O3/patriciogonzalezvivo[P]tprint/include/std/stb_image.h
// Function: stbi__create_png_image_raw(stbi__png*, unsigned char*, unsigned int, int, unsigned int, unsigned int, int, int)
static int stbi__create_png_image_raw(stbi__png *a, stbi_uc *raw, stbi__uint32 raw_len, int out_n, stbi__uint32 x, stbi__uint32 y, int depth, int color)
{
   stbi__context *s = a->s;
   stbi__uint32 i,j,stride = x*out_n;
   stbi__uint32 img_len, img_width_bytes;
   int k;
   int img_n = s->img_n; // copy it into a local for later

   STBI_ASSERT(out_n == s->img_n || out_n == s->img_n+1);
   a->out = (stbi_uc *) stbi__malloc(x * y * out_n); // extra bytes to write off the end into
   if (!a->out) return stbi__err("outofmem", "Out of memory");

   img_width_bytes = (((img_n * x * depth) + 7) >> 3);
   img_len = (img_width_bytes + 1) * y;
   if (s->img_x == x && s->img_y == y) {
      if (raw_len != img_len) return stbi__err("not enough pixels","Corrupt PNG");
   } else { // interlaced:
      if (raw_len < img_len) return stbi__err("not enough pixels","Corrupt PNG");
   }

   for (j=0; j < y; ++j) {
      stbi_uc *cur = a->out + stride*j;
      stbi_uc *prior = cur - stride;
      int filter = *raw++;
      int filter_bytes = img_n;
      int width = x;
      if (filter > 4)
         return stbi__err("invalid filter","Corrupt PNG");

      if (depth < 8) {
         STBI_ASSERT(img_width_bytes <= x);
         cur += x*out_n - img_width_bytes; // store output to the rightmost img_len bytes, so we can decode in place
         filter_bytes = 1;
         width = img_width_bytes;
      }

      // if first row, use special filter that doesn't sample previous row
      if (j == 0) filter = first_row_filter[filter];

      // handle first byte explicitly
      for (k=0; k < filter_bytes; ++k) {
         switch (filter) {
            case STBI__F_none       : cur[k] = raw[k]; break;
            case STBI__F_sub        : cur[k] = raw[k]; break;
            case STBI__F_up         : cur[k] = STBI__BYTECAST(raw[k] + prior[k]); break;
            case STBI__F_avg        : cur[k] = STBI__BYTECAST(raw[k] + (prior[k]>>1)); break;
            case STBI__F_paeth      : cur[k] = STBI__BYTECAST(raw[k] + stbi__paeth(0,prior[k],0)); break;
            case STBI__F_avg_first  : cur[k] = raw[k]; break;
            case STBI__F_paeth_first: cur[k] = raw[k]; break;
         }
      }

      if (depth == 8) {
         if (img_n != out_n)
            cur[img_n] = 255; // first pixel
         raw += img_n;
         cur += out_n;
         prior += out_n;
      } else {
         raw += 1;
         cur += 1;
         prior += 1;
      }

      // this is a little gross, so that we don't switch per-pixel or per-component
      if (depth < 8 || img_n == out_n) {
         int nk = (width - 1)*img_n;
         #define CASE(f) \
             case f:     \
                for (k=0; k < nk; ++k)
         switch (filter) {
            // "none" filter turns into a memcpy here; make that explicit.
            case STBI__F_none:         memcpy(cur, raw, nk); break;
            CASE(STBI__F_sub)          cur[k] = STBI__BYTECAST(raw[k] + cur[k-filter_bytes]); break;
            CASE(STBI__F_up)           cur[k] = STBI__BYTECAST(raw[k] + prior[k]); break;
            CASE(STBI__F_avg)          cur[k] = STBI__BYTECAST(raw[k] + ((prior[k] + cur[k-filter_bytes])>>1)); break;
            CASE(STBI__F_paeth)        cur[k] = STBI__BYTECAST(raw[k] + stbi__paeth(cur[k-filter_bytes],prior[k],prior[k-filter_bytes])); break;
            CASE(STBI__F_avg_first)    cur[k] = STBI__BYTECAST(raw[k] + (cur[k-filter_bytes] >> 1)); break;
            CASE(STBI__F_paeth_first)  cur[k] = STBI__BYTECAST(raw[k] + stbi__paeth(cur[k-filter_bytes],0,0)); break;
         }
         #undef CASE
         raw += nk;
      } else {
         STBI_ASSERT(img_n+1 == out_n);
         #define CASE(f) \
             case f:     \
                for (i=x-1; i >= 1; --i, cur[img_n]=255,raw+=img_n,cur+=out_n,prior+=out_n) \
                   for (k=0; k < img_n; ++k)
         switch (filter) {
            CASE(STBI__F_none)         cur[k] = raw[k]; break;
            CASE(STBI__F_sub)          cur[k] = STBI__BYTECAST(raw[k] + cur[k-out_n]); break;
            CASE(STBI__F_up)           cur[k] = STBI__BYTECAST(raw[k] + prior[k]); break;
            CASE(STBI__F_avg)          cur[k] = STBI__BYTECAST(raw[k] + ((prior[k] + cur[k-out_n])>>1)); break;
            CASE(STBI__F_paeth)        cur[k] = STBI__BYTECAST(raw[k] + stbi__paeth(cur[k-out_n],prior[k],prior[k-out_n])); break;
            CASE(STBI__F_avg_first)    cur[k] = STBI__BYTECAST(raw[k] + (cur[k-out_n] >> 1)); break;
            CASE(STBI__F_paeth_first)  cur[k] = STBI__BYTECAST(raw[k] + stbi__paeth(cur[k-out_n],0,0)); break;
         }
         #undef CASE
      }
   }

   // we make a separate pass to expand bits to pixels; for performance,
   // this could run two scanlines behind the above code, so it won't
   // intefere with filtering but will still be in the cache.
   if (depth < 8) {
      for (j=0; j < y; ++j) {
         stbi_uc *cur = a->out + stride*j;
         stbi_uc *in  = a->out + stride*j + x*out_n - img_width_bytes;
         // unpack 1/2/4-bit into a 8-bit buffer. allows us to keep the common 8-bit path optimal at minimal cost for 1/2/4-bit
         // png guarante byte alignment, if width is not multiple of 8/4/2 we'll decode dummy trailing data that will be skipped in the later loop
         stbi_uc scale = (color == 0) ? stbi__depth_scale_table[depth] : 1; // scale grayscale values to 0..255 range

         // note that the final byte might overshoot and write more data than desired.
         // we can allocate enough data that this never writes out of memory, but it
         // could also overwrite the next scanline. can it overwrite non-empty data
         // on the next scanline? yes, consider 1-pixel-wide scanlines with 1-bit-per-pixel.
         // so we need to explicitly clamp the final ones

         if (depth == 4) {
            for (k=x*img_n; k >= 2; k-=2, ++in) {
               *cur++ = scale * ((*in >> 4)       );
               *cur++ = scale * ((*in     ) & 0x0f);
            }
            if (k > 0) *cur++ = scale * ((*in >> 4)       );
         } else if (depth == 2) {
            for (k=x*img_n; k >= 4; k-=4, ++in) {
               *cur++ = scale * ((*in >> 6)       );
               *cur++ = scale * ((*in >> 4) & 0x03);
               *cur++ = scale * ((*in >> 2) & 0x03);
               *cur++ = scale * ((*in     ) & 0x03);
            }
            if (k > 0) *cur++ = scale * ((*in >> 6)       );
            if (k > 1) *cur++ = scale * ((*in >> 4) & 0x03);
            if (k > 2) *cur++ = scale * ((*in >> 2) & 0x03);
         } else if (depth == 1) {
            for (k=x*img_n; k >= 8; k-=8, ++in) {
               *cur++ = scale * ((*in >> 7)       );
               *cur++ = scale * ((*in >> 6) & 0x01);
               *cur++ = scale * ((*in >> 5) & 0x01);
               *cur++ = scale * ((*in >> 4) & 0x01);
               *cur++ = scale * ((*in >> 3) & 0x01);
               *cur++ = scale * ((*in >> 2) & 0x01);
               *cur++ = scale * ((*in >> 1) & 0x01);
               *cur++ = scale * ((*in     ) & 0x01);
            }
            if (k > 0) *cur++ = scale * ((*in >> 7)       );
            if (k > 1) *cur++ = scale * ((*in >> 6) & 0x01);
            if (k > 2) *cur++ = scale * ((*in >> 5) & 0x01);
            if (k > 3) *cur++ = scale * ((*in >> 4) & 0x01);
            if (k > 4) *cur++ = scale * ((*in >> 3) & 0x01);
            if (k > 5) *cur++ = scale * ((*in >> 2) & 0x01);
            if (k > 6) *cur++ = scale * ((*in >> 1) & 0x01);
         }
         if (img_n != out_n) {
            // insert alpha = 255
            stbi_uc *cur = a->out + stride*j;
            int i;
            if (img_n == 1) {
               for (i=x-1; i >= 0; --i) {
                  cur[i*2+1] = 255;
                  cur[i*2+0] = cur[i];
               }
            } else {
               STBI_ASSERT(img_n == 3);
               for (i=x-1; i >= 0; --i) {
                  cur[i*4+3] = 255;
                  cur[i*4+2] = cur[i*3+2];
                  cur[i*4+1] = cur[i*3+1];
                  cur[i*4+0] = cur[i*3+0];
               }
            }
         }
      }
   }

   return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movl %edx, %r15d
movq (%rdi), %rbx
movl 0x8(%rbx), %edx
cmpl %ecx, %edx
sete %al
movq %rdx, 0x48(%rsp)
incl %edx
movl %edx, 0x74(%rsp)
cmpl %ecx, %edx
sete %dl
orb %al, %dl
je 0x1d50f
movl %r9d, %r13d
movl %r8d, %ebp
movq %rsi, %r12
movq %rdi, %r14
movl %r8d, %eax
movl %ecx, 0x1c(%rsp)
imull %ecx, %eax
movl %eax, 0x18(%rsp)
movl %eax, %edi
imull %r9d, %edi
callq 0x8420
movq %r14, 0x68(%rsp)
movq %rax, 0x18(%r14)
testq %rax, %rax
je 0x1d0b0
movq 0x48(%rsp), %r14
movl %r14d, %eax
imull %ebp, %eax
movl %eax, 0x14(%rsp)
imull 0xe0(%rsp), %eax
addl $0x7, %eax
shrl $0x3, %eax
movq %rax, 0x58(%rsp)
incl %eax
imull %r13d, %eax
movq %rbp, 0x60(%rsp)
cmpl %ebp, (%rbx)
jne 0x1ca28
cmpl %r13d, 0x4(%rbx)
jne 0x1ca28
cmpl %r15d, %eax
je 0x1ca2d
leaq 0x48ab(%rip), %rax      # 0x212ce
jmp 0x1d0c0
cmpl %r15d, %eax
ja 0x1ca1c
movl $0x1, %eax
testl %r13d, %r13d
je 0x1d0c9
movl %r14d, %r15d
movslq %r14d, %rbx
movl 0x1c(%rsp), %ecx
cmpl %ecx, %r14d
sete %al
movl 0x18(%rsp), %edx
movl %edx, %esi
movq %rsi, %rdi
negq %rdi
movq %rdi, 0x38(%rsp)
cmpl $0x8, 0xe0(%rsp)
setl %dil
subl 0x58(%rsp), %edx
movq %rdx, 0x98(%rsp)
movslq %ecx, %r11
orb %al, %dil
movb %dil, 0x13(%rsp)
movq 0x60(%rsp), %rax
decl %eax
movl %eax, 0xc(%rsp)
movl %r13d, %eax
movq %rax, 0x78(%rsp)
movq %r11, %rax
negq %rax
movq %rax, 0x30(%rsp)
movq %rsi, 0x88(%rsp)
subq %rsi, %rax
movq %rax, 0x90(%rsp)
xorl %esi, %esi
xorl %edx, %edx
movq %rbx, 0x80(%rsp)
movq %r11, 0x20(%rsp)
movzbl (%r12), %r10d
cmpq $0x4, %r10
ja 0x1d0b9
movq 0x68(%rsp), %rax
movq 0x18(%rax), %rdi
movl 0x18(%rsp), %eax
movl %eax, %ecx
imull %edx, %ecx
movq %rdi, 0x40(%rsp)
addq %rdi, %rcx
movq %rcx, %rax
movl %r14d, %ebp
movq 0x60(%rsp), %rdi
movl %edi, %r8d
cmpl $0x7, 0xe0(%rsp)
jg 0x1cb28
movq %rdx, %r9
movq 0x58(%rsp), %rdx
cmpl %edi, %edx
ja 0x1d4d1
movq 0x98(%rsp), %rax
addq %rcx, %rax
movl $0x1, %ebp
movl %edx, %r8d
movq %r9, %rdx
movl %r8d, 0x50(%rsp)
movq %rdx, 0xa0(%rsp)
testq %rdx, %rdx
jne 0x1cb45
leaq 0x40fb(%rip), %rdx      # 0x20c3c
movb (%r10,%rdx), %r10b
movl %esi, %esi
movq %rsi, 0x28(%rsp)
leaq 0x1(%r12), %rdi
movzbl %r10b, %r11d
movl %ebp, %r8d
testl %ebp, %ebp
jle 0x1cbb1
movl %r8d, %edx
movq 0x38(%rsp), %rsi
movq 0x40(%rsp), %r9
leaq (%r9,%rsi), %r13
addq 0x28(%rsp), %r13
xorl %esi, %esi
cmpb $0x6, %r10b
ja 0x1cba9
leaq 0x3ed3(%rip), %rbp      # 0x20a54
movslq (%rbp,%r11,4), %r9
addq %rbp, %r9
jmpq *%r9
movb (%rdi,%rsi), %r9b
jmp 0x1cba5
movb (%r13,%rsi), %r9b
jmp 0x1cba1
movb (%r13,%rsi), %r9b
shrb %r9b
addb (%rdi,%rsi), %r9b
movb %r9b, (%rax,%rsi)
incq %rsi
cmpq %rsi, %rdx
jne 0x1cb74
cmpl $0x8, 0xe0(%rsp)
jne 0x1cbda
movl 0x1c(%rsp), %esi
cmpl %esi, %r14d
movl 0x50(%rsp), %r9d
je 0x1cbcd
movb $-0x1, (%rax,%rbx)
addq %rbx, %rdi
movq 0x20(%rsp), %rdx
movq %rdi, %r12
jmp 0x1cbec
addq $0x2, %r12
movl $0x1, %edx
movl 0x1c(%rsp), %esi
movl 0x50(%rsp), %r9d
leaq (%rax,%rdx), %rdi
cmpb $0x0, 0x13(%rsp)
je 0x1cc2b
decl %r9d
imull %r14d, %r9d
movslq %r9d, %rbp
cmpb $0x6, %r10b
ja 0x1ce41
leaq 0x3e7a(%rip), %rsi      # 0x20a8c
movslq (%rsi,%r11,4), %rcx
addq %rsi, %rcx
jmpq *%rcx
movq %r12, %rsi
movq %rbp, %rdx
callq 0x8290
jmp 0x1ce41
cmpl %esi, 0x74(%rsp)
jne 0x1d4f0
cmpb $0x6, %r10b
ja 0x1ce49
addq 0x38(%rsp), %rcx
addq %rdx, %rcx
leaq 0x3e22(%rip), %r8       # 0x20a70
movslq (%r8,%r11,4), %rsi
addq %r8, %rsi
jmpq *%rsi
movl 0xc(%rsp), %eax
testl %eax, %eax
movq 0x20(%rsp), %r11
je 0x1ce49
testl %r14d, %r14d
jle 0x1cc7e
xorl %ecx, %ecx
movb (%r12,%rcx), %dl
movb %dl, (%rdi,%rcx)
incq %rcx
cmpq %rcx, %r15
jne 0x1cc6f
movb $-0x1, (%rdi,%rbx)
addq %rbx, %r12
addq %r11, %rdi
decl %eax
jne 0x1cc68
jmp 0x1ce49
testl %r9d, %r9d
jle 0x1ce41
movslq %r8d, %rsi
movl %r9d, %ecx
movq %rcx, 0x50(%rsp)
movq %rdx, %r8
subq %rsi, %r8
addq %r8, %rax
movq 0x40(%rsp), %rcx
addq 0x38(%rsp), %rcx
addq 0x28(%rsp), %rdx
movq %rdx, %r8
subq %rsi, %r8
addq %rcx, %r8
addq %rcx, %rdx
xorl %esi, %esi
movzbl (%rax,%rsi), %r9d
movzbl (%rdx,%rsi), %r11d
movzbl (%r8,%rsi), %r10d
leal (%r11,%r9), %ebx
subl %r10d, %ebx
movl %ebx, %ecx
subl %r9d, %ecx
movl %ecx, %r13d
negl %r13d
cmovsl %ecx, %r13d
movl %ebx, %ecx
subl %r11d, %ecx
movl %ecx, %r14d
negl %r14d
cmovsl %ecx, %r14d
subl %r10d, %ebx
movl %ebx, %ecx
negl %ecx
cmovsl %ebx, %ecx
cmpl %ecx, %r14d
ja 0x1cd11
movl %r11d, %r10d
cmpl %ecx, %r13d
cmoval %r10d, %r9d
cmpl %r14d, %r13d
cmoval %r10d, %r9d
addb (%r12,%rsi), %r9b
movb %r9b, (%rdi,%rsi)
incq %rsi
cmpq %rsi, 0x50(%rsp)
movq 0x80(%rsp), %rbx
jne 0x1cccb
jmp 0x1ce41
testl %r9d, %r9d
jle 0x1ce41
movl %r9d, %eax
movq 0x40(%rsp), %rcx
addq 0x38(%rsp), %rcx
addq 0x28(%rsp), %rdx
addq %rcx, %rdx
xorl %ecx, %ecx
movb (%rdx,%rcx), %sil
addb (%r12,%rcx), %sil
movb %sil, (%rdi,%rcx)
incq %rcx
cmpq %rcx, %rax
jne 0x1cd5e
jmp 0x1ce41
testl %r9d, %r9d
jle 0x1ce41
movslq %r8d, %rsi
movl %r9d, %ecx
movq %rdx, %r8
subq %rsi, %r8
addq %r8, %rax
movq 0x40(%rsp), %rsi
addq 0x38(%rsp), %rsi
addq 0x28(%rsp), %rdx
addq %rsi, %rdx
xorl %esi, %esi
movzbl (%rdx,%rsi), %r8d
movzbl (%rax,%rsi), %r9d
addl %r8d, %r9d
shrl %r9d
addb (%r12,%rsi), %r9b
movb %r9b, (%rdi,%rsi)
incq %rsi
cmpq %rsi, %rcx
jne 0x1cda3
jmp 0x1ce41
testl %r9d, %r9d
jle 0x1ce41
movslq %r8d, %rsi
movl %r9d, %ecx
subq %rsi, %rdx
addq %rdx, %rax
xorl %edx, %edx
movb (%rax,%rdx), %sil
addb (%r12,%rdx), %sil
movb %sil, (%rdi,%rdx)
incq %rdx
cmpq %rdx, %rcx
jne 0x1cdd8
jmp 0x1ce41
testl %r9d, %r9d
jle 0x1ce41
movslq %r8d, %rsi
movl %r9d, %ecx
subq %rsi, %rdx
addq %rdx, %rax
xorl %edx, %edx
movb (%rax,%rdx), %sil
shrb %sil
addb (%r12,%rdx), %sil
movb %sil, (%rdi,%rdx)
incq %rdx
cmpq %rdx, %rcx
jne 0x1ce01
jmp 0x1ce41
testl %r9d, %r9d
jle 0x1ce41
movslq %r8d, %rsi
movl %r9d, %ecx
subq %rsi, %rdx
addq %rdx, %rax
xorl %edx, %edx
movb (%rax,%rdx), %sil
addb (%r12,%rdx), %sil
movb %sil, (%rdi,%rdx)
incq %rdx
cmpq %rdx, %rcx
jne 0x1ce2d
addq %rbp, %r12
movq 0x48(%rsp), %r14
movq 0xa0(%rsp), %rdx
incq %rdx
movq 0x28(%rsp), %rsi
addl 0x18(%rsp), %esi
cmpq 0x78(%rsp), %rdx
jne 0x1cac1
jmp 0x1d0db
movl 0xc(%rsp), %esi
testl %esi, %esi
je 0x1ce49
addq 0x30(%rsp), %rax
addq %rdx, %rax
movq 0x40(%rsp), %r8
addq 0x90(%rsp), %r8
addq 0x28(%rsp), %rdx
addq %r8, %rdx
testl %r14d, %r14d
jle 0x1cefe
xorl %r8d, %r8d
movzbl (%rax,%r8), %r9d
movzbl (%rcx,%r8), %r11d
movzbl (%rdx,%r8), %r10d
leal (%r11,%r9), %ebx
subl %r10d, %ebx
movl %ebx, %ebp
subl %r9d, %ebp
movl %ebp, %r13d
negl %r13d
cmovsl %ebp, %r13d
movl %ebx, %ebp
subl %r11d, %ebp
movl %ebp, %r14d
negl %r14d
cmovsl %ebp, %r14d
subl %r10d, %ebx
movl %ebx, %ebp
negl %ebp
cmovsl %ebx, %ebp
cmpl %ebp, %r14d
ja 0x1cee0
movl %r11d, %r10d
cmpl %ebp, %r13d
cmoval %r10d, %r9d
cmpl %r14d, %r13d
cmoval %r10d, %r9d
addb (%r12,%r8), %r9b
movb %r9b, (%rdi,%r8)
incq %r8
cmpq %r8, %r15
jne 0x1ce9a
movq 0x80(%rsp), %rbx
movb $-0x1, (%rdi,%rbx)
addq %rbx, %r12
movq 0x20(%rsp), %r11
addq %r11, %rdi
addq %r11, %rcx
addq %r11, %rax
addq %r11, %rdx
decl %esi
movq 0x48(%rsp), %r14
jne 0x1ce92
jmp 0x1ce49
movl 0xc(%rsp), %edx
movl %edx, %eax
testl %edx, %edx
movq 0x20(%rsp), %r11
je 0x1ce49
testl %r14d, %r14d
jle 0x1cf5e
xorl %edx, %edx
movb (%rcx,%rdx), %sil
addb (%r12,%rdx), %sil
movb %sil, (%rdi,%rdx)
incq %rdx
cmpq %rdx, %r15
jne 0x1cf4a
movb $-0x1, (%rdi,%rbx)
addq %rbx, %r12
addq %r11, %rdi
addq %r11, %rcx
decl %eax
jne 0x1cf43
jmp 0x1ce49
movl 0xc(%rsp), %esi
testl %esi, %esi
movq 0x20(%rsp), %r11
je 0x1ce49
addq 0x30(%rsp), %rax
addq %rdx, %rax
movl %esi, %edx
testl %r14d, %r14d
jle 0x1cfb6
xorl %esi, %esi
movzbl (%rcx,%rsi), %r8d
movzbl (%rax,%rsi), %r9d
addl %r8d, %r9d
shrl %r9d
addb (%r12,%rsi), %r9b
movb %r9b, (%rdi,%rsi)
incq %rsi
cmpq %rsi, %r15
jne 0x1cf96
movb $-0x1, (%rdi,%rbx)
addq %rbx, %r12
addq %r11, %rdi
addq %r11, %rcx
addq %r11, %rax
decl %edx
jne 0x1cf8f
jmp 0x1ce49
movl 0xc(%rsp), %ecx
testl %ecx, %ecx
movq 0x20(%rsp), %r11
je 0x1ce49
addq 0x30(%rsp), %rax
addq %rdx, %rax
testl %r14d, %r14d
jle 0x1d003
xorl %edx, %edx
movb (%rax,%rdx), %sil
addb (%r12,%rdx), %sil
movb %sil, (%rdi,%rdx)
incq %rdx
cmpq %rdx, %r15
jne 0x1cfef
movb $-0x1, (%rdi,%rbx)
addq %rbx, %r12
addq %r11, %rdi
addq %r11, %rax
decl %ecx
jne 0x1cfe8
jmp 0x1ce49
movl 0xc(%rsp), %ecx
testl %ecx, %ecx
movq 0x20(%rsp), %r11
je 0x1ce49
addq 0x30(%rsp), %rax
addq %rdx, %rax
testl %r14d, %r14d
jle 0x1d050
xorl %edx, %edx
movb (%rax,%rdx), %sil
shrb %sil
addb (%r12,%rdx), %sil
movb %sil, (%rdi,%rdx)
incq %rdx
cmpq %rdx, %r15
jne 0x1d039
movb $-0x1, (%rdi,%rbx)
addq %rbx, %r12
addq %r11, %rdi
addq %r11, %rax
decl %ecx
jne 0x1d032
jmp 0x1ce49
movl 0xc(%rsp), %ecx
testl %ecx, %ecx
movq 0x20(%rsp), %r11
je 0x1ce49
addq 0x30(%rsp), %rax
addq %rdx, %rax
testl %r14d, %r14d
jle 0x1d09a
xorl %edx, %edx
movb (%rax,%rdx), %sil
addb (%r12,%rdx), %sil
movb %sil, (%rdi,%rdx)
incq %rdx
cmpq %rdx, %r15
jne 0x1d086
movb $-0x1, (%rdi,%rbx)
addq %rbx, %r12
addq %r11, %rdi
addq %r11, %rax
decl %ecx
jne 0x1d07f
jmp 0x1ce49
leaq 0x3ee0(%rip), %rax      # 0x20f97
jmp 0x1d0c0
leaq 0x4220(%rip), %rax      # 0x212e0
movq %rax, 0xa321(%rip)      # 0x273e8
xorl %eax, %eax
addq $0xa8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl 0xe0(%rsp), %r13d
cmpl $0x7, %r13d
jg 0x1d4c7
movl 0x58(%rsp), %ecx
movl %r13d, %edx
movq 0x60(%rsp), %r8
decl %r8d
movq 0x88(%rsp), %rax
movq %rax, %rsi
subq %rcx, %rsi
negq %rcx
leaq (%r8,%r8,2), %rdi
addq $0x2, %rdi
movq %rdi, 0x28(%rsp)
movq %r8, %rdi
incq %r8
xorl %r9d, %r9d
addq %rax, %rcx
leaq 0x3a83(%rip), %r10      # 0x20bb0
xorl %r11d, %r11d
xorl %ebx, %ebx
movq 0x68(%rsp), %r12
movb $0x1, %bpl
cmpl $0x0, 0xe8(%rsp)
jne 0x1d148
movb (%rdx,%r10), %bpl
movq 0x18(%r12), %r15
movl 0x18(%rsp), %eax
movl %eax, %r12d
imull %ebx, %r12d
addq %r15, %r12
leaq (%r12,%rcx), %r14
movl %r11d, %r11d
cmpl $0x4, %r13d
je 0x1d3c0
cmpl $0x2, %r13d
je 0x1d307
cmpl $0x1, %r13d
jne 0x1d422
movl 0x14(%rsp), %r13d
movl %r13d, %eax
cmpl $0x8, %r13d
jl 0x1d247
leaq (%r15,%rsi), %r14
movl 0x14(%rsp), %eax
movl %eax, %r12d
movb (%r14,%r11), %al
sarb $0x7, %al
andb %bpl, %al
movb %al, (%r15,%r11)
movb (%r14,%r11), %al
addb %al, %al
sarb $0x7, %al
andb %bpl, %al
movb %al, 0x1(%r15,%r11)
movb (%r14,%r11), %al
shlb $0x2, %al
sarb $0x7, %al
andb %bpl, %al
movb %al, 0x2(%r15,%r11)
movb (%r14,%r11), %al
shlb $0x3, %al
sarb $0x7, %al
andb %bpl, %al
movb %al, 0x3(%r15,%r11)
movb (%r14,%r11), %al
shlb $0x4, %al
sarb $0x7, %al
andb %bpl, %al
movb %al, 0x4(%r15,%r11)
movb (%r14,%r11), %al
shlb $0x5, %al
sarb $0x7, %al
andb %bpl, %al
movb %al, 0x5(%r15,%r11)
movb (%r14,%r11), %al
shlb $0x6, %al
sarb $0x7, %al
andb %bpl, %al
movb %al, 0x6(%r15,%r11)
testb $0x1, (%r14,%r11)
movzbl %bpl, %eax
cmovel %r9d, %eax
movb %al, 0x7(%r15,%r11)
leal -0x8(%r12), %eax
incq %r14
addq $0x8, %r15
cmpl $0xf, %r12d
ja 0x1d19a
addq %r11, %r14
addq %r11, %r15
movq %r15, %r12
testl %eax, %eax
jle 0x1d422
movb (%r14), %r15b
sarb $0x7, %r15b
andb %bpl, %r15b
movb %r15b, (%r12)
cmpl $0x1, %eax
je 0x1d422
movb (%r14), %r15b
addb %r15b, %r15b
sarb $0x7, %r15b
andb %bpl, %r15b
movb %r15b, 0x1(%r12)
cmpl $0x3, %eax
jb 0x1d422
movb (%r14), %r15b
shlb $0x2, %r15b
sarb $0x7, %r15b
andb %bpl, %r15b
movb %r15b, 0x2(%r12)
cmpl $0x3, %eax
je 0x1d422
movb (%r14), %r15b
shlb $0x3, %r15b
sarb $0x7, %r15b
andb %bpl, %r15b
movb %r15b, 0x3(%r12)
cmpl $0x5, %eax
jb 0x1d422
movb (%r14), %r15b
shlb $0x4, %r15b
sarb $0x7, %r15b
andb %bpl, %r15b
movb %r15b, 0x4(%r12)
cmpl $0x5, %eax
je 0x1d422
movb (%r14), %r15b
shlb $0x5, %r15b
sarb $0x7, %r15b
andb %bpl, %r15b
movb %r15b, 0x5(%r12)
cmpl $0x7, %eax
jne 0x1d422
movb (%r14), %al
shlb $0x6, %al
sarb $0x7, %al
andb %bpl, %al
movb %al, 0x6(%r12)
jmp 0x1d422
movl 0x14(%rsp), %eax
movl %eax, %r13d
cmpl $0x4, %eax
jl 0x1d378
leaq (%r15,%rsi), %r14
movl 0x14(%rsp), %r13d
movl %r13d, %r12d
movb (%r14,%r11), %al
shrb $0x6, %al
mulb %bpl
movb %al, (%r15,%r11)
movb (%r14,%r11), %al
shrb $0x4, %al
andb $0x3, %al
mulb %bpl
movb %al, 0x1(%r15,%r11)
movb (%r14,%r11), %al
shrb $0x2, %al
andb $0x3, %al
mulb %bpl
movb %al, 0x2(%r15,%r11)
movb (%r14,%r11), %al
andb $0x3, %al
mulb %bpl
movb %al, 0x3(%r15,%r11)
leal -0x4(%r12), %r13d
incq %r14
addq $0x4, %r15
cmpl $0x7, %r12d
ja 0x1d31c
addq %r11, %r14
addq %r11, %r15
movq %r15, %r12
testl %r13d, %r13d
jle 0x1d422
movb (%r14), %al
shrb $0x6, %al
mulb %bpl
movb %al, (%r12)
cmpl $0x1, %r13d
je 0x1d422
movb (%r14), %al
shrb $0x4, %al
andb $0x3, %al
mulb %bpl
movb %al, 0x1(%r12)
cmpl $0x3, %r13d
jne 0x1d422
movb (%r14), %al
shrb $0x2, %al
andb $0x3, %al
mulb %bpl
movb %al, 0x2(%r12)
jmp 0x1d422
movl 0x14(%rsp), %r13d
movl %r13d, %eax
cmpl $0x2, %r13d
jl 0x1d410
leaq (%r15,%rsi), %r14
movl 0x14(%rsp), %eax
movl %eax, %r12d
movb (%r14,%r11), %al
shrb $0x4, %al
mulb %bpl
movb %al, (%r15,%r11)
movb (%r14,%r11), %al
andb $0xf, %al
mulb %bpl
movb %al, 0x1(%r15,%r11)
leal -0x2(%r12), %eax
incq %r14
addq $0x2, %r15
cmpl $0x3, %r12d
ja 0x1d3d6
addq %r11, %r14
addq %r11, %r15
movq %r15, %r12
cmpl $0x1, %eax
jne 0x1d422
movb (%r14), %al
shrb $0x4, %al
mulb %bpl
movb %al, (%r12)
movq 0x48(%rsp), %rax
cmpl 0x1c(%rsp), %eax
movq 0x68(%rsp), %r12
je 0x1d4ac
movq 0x18(%r12), %rax
movq 0x48(%rsp), %r14
cmpl $0x1, %r14d
je 0x1d48d
cmpl $0x3, %r14d
jne 0x1d52e
movq %rdi, %r14
testl %r14d, %r14d
js 0x1d4ac
addq %r11, %rax
movq 0x28(%rsp), %r14
addq %rax, %r14
movq %r8, %r15
movb $-0x1, -0x1(%rax,%r15,4)
movb (%r14), %bpl
movb %bpl, -0x2(%rax,%r15,4)
movb -0x1(%r14), %bpl
movb %bpl, -0x3(%rax,%r15,4)
movb -0x2(%r14), %bpl
movb %bpl, -0x4(%rax,%r15,4)
addq $-0x3, %r14
decq %r15
jg 0x1d462
jmp 0x1d4ac
testl %edi, %edi
js 0x1d4ac
addq %r11, %rax
movq %r8, %r14
movb $-0x1, -0x1(%rax,%r14,2)
movb -0x1(%rax,%r14), %bpl
movb %bpl, -0x2(%rax,%r14,2)
decq %r14
jg 0x1d497
incq %rbx
addl 0x18(%rsp), %r11d
cmpq 0x78(%rsp), %rbx
movl 0xe0(%rsp), %r13d
jne 0x1d137
movl $0x1, %eax
jmp 0x1d0c9
leaq 0x3e17(%rip), %rdi      # 0x212ef
leaq 0x3b88(%rip), %rsi      # 0x21067
leaq 0x3d78(%rip), %rcx      # 0x2125e
movl $0xf93, %edx            # imm = 0xF93
callq 0x8200
leaq 0x3e0d(%rip), %rdi      # 0x21304
leaq 0x3b69(%rip), %rsi      # 0x21067
leaq 0x3d59(%rip), %rcx      # 0x2125e
movl $0xfc8, %edx            # imm = 0xFC8
callq 0x8200
leaq 0x3d1f(%rip), %rdi      # 0x21235
leaq 0x3b4a(%rip), %rsi      # 0x21067
leaq 0x3d3a(%rip), %rcx      # 0x2125e
movl $0xf7d, %edx            # imm = 0xF7D
callq 0x8200
leaq 0x3de0(%rip), %rdi      # 0x21315
leaq 0x3b2b(%rip), %rsi      # 0x21067
leaq 0x3d1b(%rip), %rcx      # 0x2125e
movl $0x1018, %edx           # imm = 0x1018
callq 0x8200