// File: /workspace/github_cpp_makefile_star2_O3/mhe[P]raytracerframework_cpp/lodepng.cpp
// Function: LodePNG_convert(unsigned char*, unsigned char const*, LodePNG_InfoColor*, LodePNG_InfoColor*, unsigned int, unsigned int)
unsigned LodePNG_convert(unsigned char* out, const unsigned char* in, LodePNG_InfoColor* infoOut, LodePNG_InfoColor* infoIn, unsigned w, unsigned h)
{
  const size_t numpixels = w * h; /*amount of pixels*/
  const unsigned OUT_BYTES = LodePNG_InfoColor_getBpp(infoOut) / 8; /*bytes per pixel in the output image*/
  const unsigned OUT_ALPHA = LodePNG_InfoColor_isAlphaType(infoOut); /*use 8-bit alpha channel*/
  size_t i, c, bp = 0; /*bitpointer, used by less-than-8-bit color types*/
  
  /*cases where in and out already have the same format*/
  if(LodePNG_InfoColor_equal(infoIn, infoOut))
  {
    size_t i, size = (w * h * LodePNG_InfoColor_getBpp(infoIn) + 7) / 8;
    for(i = 0; i < size; i++) out[i] = in[i];
    return 0;
  }

  if((infoOut->colorType == 2 || infoOut->colorType == 6) && infoOut->bitDepth == 8)
  {
    if(infoIn->bitDepth == 8)
    {
      switch(infoIn->colorType)
      {
        case 0: /*greyscale color*/
          for(i = 0; i < numpixels; i++)
          {
            if(OUT_ALPHA) out[OUT_BYTES * i + 3] = 255;
            out[OUT_BYTES * i + 0] = out[OUT_BYTES * i + 1] = out[OUT_BYTES * i + 2] = in[i];
            if(OUT_ALPHA && infoIn->key_defined && in[i] == infoIn->key_r) out[OUT_BYTES * i + 3] = 0;
          }
        break;
        case 2: /*RGB color*/
          for(i = 0; i < numpixels; i++)
          {
            if(OUT_ALPHA) out[OUT_BYTES * i + 3] = 255;
            for(c = 0; c < 3; c++) out[OUT_BYTES * i + c] = in[3 * i + c];
            if(OUT_ALPHA && infoIn->key_defined == 1 && in[3 * i + 0] == infoIn->key_r && in[3 * i + 1] == infoIn->key_g && in[3 * i + 2] == infoIn->key_b) out[OUT_BYTES * i + 3] = 0;
          }
        break;
        case 3: /*indexed color (palette)*/
          for(i = 0; i < numpixels; i++)
          {
            if(OUT_ALPHA) out[OUT_BYTES * i + 3] = 255;
            if(in[i] >= infoIn->palettesize) return 46;
            for(c = 0; c < OUT_BYTES; c++) out[OUT_BYTES * i + c] = infoIn->palette[4 * in[i] + c]; /*get rgb colors from the palette*/
          }
        break;
        case 4: /*greyscale with alpha*/
          for(i = 0; i < numpixels; i++)
          {
            out[OUT_BYTES * i + 0] = out[OUT_BYTES * i + 1] = out[OUT_BYTES * i + 2] = in[2 * i + 0];
            if(OUT_ALPHA) out[OUT_BYTES * i + 3] = in[2 * i + 1];
          }
        break;
        case 6: /*RGB with alpha*/
          for(i = 0; i < numpixels; i++)
          {
            for(c = 0; c < OUT_BYTES; c++) out[OUT_BYTES * i + c] = in[4 * i + c];
          }
        break;
        default: break;
      }
    }
    else if(infoIn->bitDepth == 16)
    {
      switch(infoIn->colorType)
      {
        case 0: /*greyscale color*/
          for(i = 0; i < numpixels; i++)
          {
            if(OUT_ALPHA) out[OUT_BYTES * i + 3] = 255;
            out[OUT_BYTES * i + 0] = out[OUT_BYTES * i + 1] = out[OUT_BYTES * i + 2] = in[2 * i];
            if(OUT_ALPHA && infoIn->key_defined && 256U * in[i] + in[i + 1] == infoIn->key_r) out[OUT_BYTES * i + 3] = 0;
          }
        break;
        case 2: /*RGB color*/
          for(i = 0; i < numpixels; i++)
          {
            if(OUT_ALPHA) out[OUT_BYTES * i + 3] = 255;
            for(c = 0; c < 3; c++) out[OUT_BYTES * i + c] = in[6 * i + 2 * c];
            if(OUT_ALPHA && infoIn->key_defined && 256U * in[6 * i + 0] + in[6 * i + 1] == infoIn->key_r && 256U * in[6 * i + 2] + in[6 * i + 3] == infoIn->key_g && 256U * in[6 * i + 4] + in[6 * i + 5] == infoIn->key_b) out[OUT_BYTES * i + 3] = 0;
          }
        break;
        case 4: /*greyscale with alpha*/
          for(i = 0; i < numpixels; i++)
          {
            out[OUT_BYTES * i + 0] = out[OUT_BYTES * i + 1] = out[OUT_BYTES * i + 2] = in[4 * i]; /*most significant byte*/
            if(OUT_ALPHA) out[OUT_BYTES * i + 3] = in[4 * i + 2];
          }
        break;
        case 6: /*RGB with alpha*/
          for(i = 0; i < numpixels; i++)
          {
            for(c = 0; c < OUT_BYTES; c++) out[OUT_BYTES * i + c] = in[8 * i + 2 * c];
          }
          break;
        default: break;
      }
    }
    else /*infoIn->bitDepth is less than 8 bit per channel*/
    {
      switch(infoIn->colorType)
      {
        case 0: /*greyscale color*/
          for(i = 0; i < numpixels; i++)
          {
            unsigned value = readBitsFromReversedStream(&bp, in, infoIn->bitDepth);
            if(OUT_ALPHA) out[OUT_BYTES * i + 3] = 255;
            if(OUT_ALPHA && infoIn->key_defined && value && ((1U << infoIn->bitDepth) - 1U) == infoIn->key_r && ((1U << infoIn->bitDepth) - 1U)) out[OUT_BYTES * i + 3] = 0;
            value = (value * 255) / ((1 << infoIn->bitDepth) - 1); /*scale value from 0 to 255*/
            out[OUT_BYTES * i + 0] = out[OUT_BYTES * i + 1] = out[OUT_BYTES * i + 2] = (unsigned char)(value);
          }
        break;
        case 3: /*indexed color (palette)*/
          for(i = 0; i < numpixels; i++)
          {
            unsigned value = readBitsFromReversedStream(&bp, in, infoIn->bitDepth);
            if(OUT_ALPHA) out[OUT_BYTES * i + 3] = 255;
            if(value >= infoIn->palettesize) return 47;
            for(c = 0; c < OUT_BYTES; c++) out[OUT_BYTES * i + c] = infoIn->palette[4 * value + c]; /*get rgb colors from the palette*/
          }
        break;
        default: break;
      }
    }
  }
  else if(LodePNG_InfoColor_isGreyscaleType(infoOut) && infoOut->bitDepth == 8) /*conversion from greyscale to greyscale*/
  {
    if(!LodePNG_InfoColor_isGreyscaleType(infoIn)) return 62;
    if(infoIn->bitDepth == 8)
    {
      switch(infoIn->colorType)
      {
        case 0: /*greyscale color*/
          for(i = 0; i < numpixels; i++)
          {
            if(OUT_ALPHA) out[OUT_BYTES * i + 1] = 255;
            out[OUT_BYTES * i] = in[i];
            if(OUT_ALPHA && infoIn->key_defined && in[i] == infoIn->key_r) out[OUT_BYTES * i + 1] = 0;
          }
        break;
        case 4: /*greyscale with alpha*/
          for(i = 0; i < numpixels; i++)
          {
            out[OUT_BYTES * i + 0] = in[2 * i + 0];
            if(OUT_ALPHA) out[OUT_BYTES * i + 1] = in[2 * i + 1];
          }
        break;
        default: return 31;
      }
    }
    else if(infoIn->bitDepth == 16)
    {
      switch(infoIn->colorType)
      {
        case 0: /*greyscale color*/
          for(i = 0; i < numpixels; i++)
          {
            if(OUT_ALPHA) out[OUT_BYTES * i + 1] = 255;
            out[OUT_BYTES * i] = in[2 * i];
            if(OUT_ALPHA && infoIn->key_defined && 256U * in[i] + in[i + 1] == infoIn->key_r) out[OUT_BYTES * i + 1] = 0;
          }
        break;
        case 4: /*greyscale with alpha*/
          for(i = 0; i < numpixels; i++)
          {
            out[OUT_BYTES * i] = in[4 * i]; /*most significant byte*/
            if(OUT_ALPHA) out[OUT_BYTES * i + 1] = in[4 * i + 2]; /*most significant byte*/
          }
        break;
        default: return 31;
      }
    }
    else /*infoIn->bitDepth is less than 8 bit per channel*/
    {
      if(infoIn->colorType != 0) return 31; /*colorType 0 is the only greyscale type with < 8 bits per channel*/
      for(i = 0; i < numpixels; i++)
      {
        unsigned value = readBitsFromReversedStream(&bp, in, infoIn->bitDepth);
        if(OUT_ALPHA) out[OUT_BYTES * i + 1] = 255;
        if(OUT_ALPHA && infoIn->key_defined && value && ((1U << infoIn->bitDepth) - 1U) == infoIn->key_r && ((1U << infoIn->bitDepth) - 1U)) out[OUT_BYTES * i + 1] = 0;
        value = (value * 255) / ((1 << infoIn->bitDepth) - 1); /*scale value from 0 to 255*/
        out[OUT_BYTES * i] = (unsigned char)(value);
      }
    }
  }
  else return 59;
  
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rcx, %r10
imull %r9d, %r8d
movl (%rdx), %r14d
xorl %eax, %eax
cmpq $0x6, %r14
ja 0x1cf35
leaq 0x13c5b(%rip), %rax     # 0x30b8c
movl (%rax,%r14,4), %eax
movl 0x4(%rdx), %ebx
movl (%r10), %r11d
cmpl %r14d, %r11d
jne 0x1cf8c
cmpl %ebx, 0x4(%r10)
jne 0x1cf8c
xorl %ecx, %ecx
movl $0x0, %eax
cmpl $0x6, %r14d
ja 0x1cf5e
leaq 0x13c32(%rip), %rax     # 0x30b8c
movl (%rax,%r14,4), %eax
imull %eax, %r8d
imull %r8d, %ebx
addl $0x7, %ebx
cmpl $0x8, %ebx
jb 0x1d79f
shrl $0x3, %ebx
xorl %ecx, %ecx
xorl %eax, %eax
movb (%rsi,%rax), %dl
movb %dl, (%rdi,%rax)
incq %rax
cmpq %rax, %rbx
jne 0x1cf79
jmp 0x1d79f
imull %ebx, %eax
movl %eax, %edx
shrl $0x3, %edx
movl %r14d, %r9d
shrl $0x2, %r9d
movl %r14d, %ecx
orl $0x4, %ecx
cmpl $0x6, %ecx
jne 0x1d048
movl $0x3b, %ecx
cmpl $0x8, %ebx
jne 0x1d79f
movl 0x4(%r10), %ecx
cmpl $0x10, %ecx
je 0x1d0d1
cmpl $0x8, %ecx
jne 0x1d152
xorl %ecx, %ecx
cmpl $0x6, %r11d
ja 0x1d79f
movl %r11d, %r11d
leaq 0x13818(%rip), %rbx     # 0x307fc
movslq (%rbx,%r11,4), %r11
addq %rbx, %r11
jmpq *%r11
testq %r8, %r8
je 0x1d79f
addq $0x3, %rdi
movl %edx, %eax
xorl %edx, %edx
testb $0x1, %r9b
jne 0x1d013
movb (%rsi,%rdx), %cl
movb %cl, -0x1(%rdi)
movb %cl, -0x2(%rdi)
movb %cl, -0x3(%rdi)
jmp 0x1d036
movb $-0x1, (%rdi)
movb (%rsi,%rdx), %cl
movb %cl, -0x1(%rdi)
movb %cl, -0x2(%rdi)
movb %cl, -0x3(%rdi)
cmpl $0x0, 0x18(%r10)
je 0x1d036
movzbl (%rsi,%rdx), %ecx
cmpl %ecx, 0x1c(%r10)
jne 0x1d036
movb $0x0, (%rdi)
incq %rdx
addq %rax, %rdi
xorl %ecx, %ecx
cmpq %rdx, %r8
jne 0x1cfff
jmp 0x1d79f
andl $-0x5, %r14d
xorl $0x8, %ebx
movl $0x3b, %ecx
orl %r14d, %ebx
jne 0x1d79f
movl $0x3e, %ecx
testl $0xfffffffb, %r11d      # imm = 0xFFFFFFFB
jne 0x1d79f
movl 0x4(%r10), %eax
cmpl $0x10, %eax
je 0x1d448
cmpl $0x8, %eax
jne 0x1d494
testl %r11d, %r11d
je 0x1d702
movl $0x1f, %ecx
cmpl $0x4, %r11d
jne 0x1d79f
testq %r8, %r8
je 0x1d796
movl %edx, %eax
incq %rdi
xorl %edx, %edx
movb (%rsi,%rdx,2), %cl
movb %cl, -0x1(%rdi)
testb $0x1, %r9b
je 0x1d0bf
movb 0x1(%rsi,%rdx,2), %cl
movb %cl, (%rdi)
incq %rdx
addq %rax, %rdi
xorl %ecx, %ecx
cmpq %rdx, %r8
jne 0x1d0ad
jmp 0x1d79f
xorl %ecx, %ecx
cmpl $0x6, %r11d
ja 0x1d79f
movl %r11d, %r11d
leaq 0x136f9(%rip), %rbx     # 0x307e0
movslq (%rbx,%r11,4), %r11
addq %rbx, %r11
jmpq *%r11
testq %r8, %r8
je 0x1d79f
addq $0x3, %rdi
movl %edx, %eax
xorl %edx, %edx
testb $0x1, %r9b
jne 0x1d116
movb (%rsi,%rdx,2), %cl
movb %cl, -0x1(%rdi)
movb %cl, -0x2(%rdi)
movb %cl, -0x3(%rdi)
jmp 0x1d140
movb $-0x1, (%rdi)
movb (%rsi,%rdx,2), %cl
movb %cl, -0x1(%rdi)
movb %cl, -0x2(%rdi)
movb %cl, -0x3(%rdi)
cmpl $0x0, 0x18(%r10)
je 0x1d140
movzwl (%rsi,%rdx), %ecx
rolw $0x8, %cx
movzwl %cx, %ecx
cmpl 0x1c(%r10), %ecx
jne 0x1d140
movb $0x0, (%rdi)
incq %rdx
addq %rax, %rdi
xorl %ecx, %ecx
cmpq %rdx, %r8
jne 0x1d102
jmp 0x1d79f
xorl %ecx, %ecx
testl %r11d, %r11d
movq %r8, -0x40(%rbp)
je 0x1d23c
cmpl $0x3, %r11d
jne 0x1d79f
testq %r8, %r8
je 0x1d79f
movl %edx, %r11d
cmpq $0x1, %r11
movq %r11, -0x38(%rbp)
adcq $0x0, %r11
xorl %ebx, %ebx
movq %rdi, %r14
xorl %r15d, %r15d
movl %eax, -0x2c(%rbp)
movl %r9d, %r8d
movl 0x4(%r10), %edx
xorl %r12d, %r12d
testq %rdx, %rdx
je 0x1d1da
movq %rdx, %r13
movq %r15, %rcx
shrq $0x3, %rcx
movzbl (%rsi,%rcx), %ecx
movl %r15d, %r9d
notb %r9b
movzbl %r9b, %r9d
andl $0x7, %r9d
xorl %eax, %eax
btl %r9d, %ecx
setb %al
incq %r15
leaq -0x1(%r13), %rcx
shll %cl, %eax
addl %eax, %r12d
addq $-0x2, %r13
cmpq %rdx, %r13
movq %rcx, %r13
jb 0x1d1a0
movl %r8d, %r9d
testb $0x1, %r9b
movl -0x2c(%rbp), %ecx
je 0x1d1f3
movq %rbx, %rax
imulq -0x38(%rbp), %rax
movb $-0x1, 0x3(%rdi,%rax)
movl %r12d, %eax
cmpq %rax, 0x10(%r10)
movq -0x40(%rbp), %rdx
jbe 0x1d6f8
cmpl $0x8, %ecx
jb 0x1d225
shll $0x2, %r12d
xorl %ecx, %ecx
movq 0x8(%r10), %rax
addq %r12, %rax
movb (%rcx,%rax), %al
movb %al, (%r14,%rcx)
incq %rcx
cmpq %rcx, %r11
jne 0x1d20f
incq %rbx
addq -0x38(%rbp), %r14
xorl %ecx, %ecx
cmpq %rdx, %rbx
jne 0x1d18e
jmp 0x1d79f
testq %r8, %r8
je 0x1d79f
movl %edx, %r11d
xorl %ebx, %ebx
xorl %r14d, %r14d
movl 0x4(%r10), %edx
xorl %r15d, %r15d
testq %rdx, %rdx
je 0x1d299
movq %rdx, %rax
movq %r14, %rcx
shrq $0x3, %rcx
movzbl (%rsi,%rcx), %ecx
movl %r14d, %r12d
notb %r12b
movzbl %r12b, %r12d
andl $0x7, %r12d
xorl %r13d, %r13d
btl %r12d, %ecx
setb %r13b
incq %r14
leaq -0x1(%rax), %rcx
shll %cl, %r13d
addl %r13d, %r15d
addq $-0x2, %rax
cmpq %rdx, %rax
movq %rcx, %rax
jb 0x1d25c
movq %rbx, %r12
imulq %r11, %r12
testb $0x1, %r9b
jne 0x1d2e4
movl %r15d, %eax
shll $0x8, %eax
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
movl %edx, %ecx
shll %cl, %r13d
subl %r15d, %eax
notl %r13d
xorl %ecx, %ecx
xorl %edx, %edx
divl %r13d
movb %al, 0x2(%rdi,%r12)
movb %al, 0x1(%rdi,%r12)
movb %al, (%rdi,%r12)
incq %rbx
cmpq -0x40(%rbp), %rbx
jne 0x1d24d
jmp 0x1d79f
movb $-0x1, 0x3(%rdi,%r12)
movl 0x4(%r10), %edx
testl %r15d, %r15d
je 0x1d2a6
cmpl $0x0, 0x18(%r10)
je 0x1d2a6
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl %edx, %ecx
shll %cl, %eax
testl %edx, %edx
je 0x1d2a6
xorl 0x1c(%r10), %eax
cmpl $-0x1, %eax
jne 0x1d2a6
movb $0x0, 0x3(%rdi,%r12)
movl 0x4(%r10), %edx
jmp 0x1d2a6
testq %r8, %r8
je 0x1d79f
movl %edx, %eax
addq $0x3, %rdi
xorl %edx, %edx
movb (%rsi,%rdx,4), %cl
movb %cl, -0x1(%rdi)
movb %cl, -0x2(%rdi)
movb %cl, -0x3(%rdi)
testb $0x1, %r9b
je 0x1d345
movb 0x2(%rsi,%rdx,4), %cl
movb %cl, (%rdi)
incq %rdx
addq %rax, %rdi
xorl %ecx, %ecx
cmpq %rdx, %r8
jne 0x1d32d
jmp 0x1d79f
testq %r8, %r8
je 0x1d79f
movl %edx, %eax
xorl %edx, %edx
movq %rdi, %r11
movq %rsi, %rbx
movq %rdx, %rcx
imulq %rax, %rcx
testb $0x1, %r9b
je 0x1d37c
movb $-0x1, 0x3(%rdi,%rcx)
leaq (%rdx,%rdx), %r14
leaq (%r14,%r14,2), %r14
xorl %r15d, %r15d
movb (%rbx,%r15,2), %r12b
movb %r12b, (%r11,%r15)
incq %r15
cmpq $0x3, %r15
jne 0x1d387
testb $0x1, %r9b
je 0x1d3e8
cmpl $0x0, 0x18(%r10)
je 0x1d3e8
movzwl (%rsi,%r14), %r15d
rolw $0x8, %r15w
movzwl %r15w, %r15d
cmpl 0x1c(%r10), %r15d
jne 0x1d3e8
movzwl 0x2(%rsi,%r14), %r15d
rolw $0x8, %r15w
movzwl %r15w, %r15d
cmpl 0x20(%r10), %r15d
jne 0x1d3e8
movzwl 0x4(%rsi,%r14), %r14d
rolw $0x8, %r14w
movzwl %r14w, %r14d
cmpl 0x24(%r10), %r14d
jne 0x1d3e8
movb $0x0, 0x3(%rdi,%rcx)
incq %rdx
addq $0x6, %rbx
addq %rax, %r11
xorl %ecx, %ecx
cmpq %r8, %rdx
jne 0x1d36a
jmp 0x1d79f
testq %r8, %r8
je 0x1d79f
movl %edx, %edx
cmpq $0x1, %rdx
movq %rdx, %r9
adcq $0x0, %r9
xorl %r10d, %r10d
cmpl $0x8, %eax
jb 0x1d432
xorl %ecx, %ecx
movb (%rsi,%rcx,2), %r11b
movb %r11b, (%rdi,%rcx)
incq %rcx
cmpq %rcx, %r9
jne 0x1d422
incq %r10
addq $0x8, %rsi
addq %rdx, %rdi
xorl %ecx, %ecx
cmpq %r8, %r10
jne 0x1d41b
jmp 0x1d79f
testl %r11d, %r11d
je 0x1d749
movl $0x1f, %ecx
cmpl $0x4, %r11d
jne 0x1d79f
testq %r8, %r8
je 0x1d796
movl %edx, %eax
incq %rdi
xorl %edx, %edx
movb (%rsi,%rdx,4), %cl
movb %cl, -0x1(%rdi)
testb $0x1, %r9b
je 0x1d482
movb 0x2(%rsi,%rdx,4), %cl
movb %cl, (%rdi)
incq %rdx
addq %rax, %rdi
xorl %ecx, %ecx
cmpq %rdx, %r8
jne 0x1d470
jmp 0x1d79f
movl $0x1f, %ecx
testl %r11d, %r11d
jne 0x1d79f
testq %r8, %r8
je 0x1d796
movl %edx, %r11d
xorl %ebx, %ebx
xorl %r14d, %r14d
movl %r9d, %r13d
movl 0x4(%r10), %edx
xorl %r15d, %r15d
testq %rdx, %rdx
je 0x1d502
movq %rdx, %rax
movq %r14, %rcx
shrq $0x3, %rcx
movzbl (%rsi,%rcx), %ecx
movl %r14d, %r9d
notb %r9b
movzbl %r9b, %r12d
andl $0x7, %r12d
xorl %r9d, %r9d
btl %r12d, %ecx
setb %r9b
incq %r14
leaq -0x1(%rax), %rcx
shll %cl, %r9d
addl %r9d, %r15d
addq $-0x2, %rax
cmpq %rdx, %rax
movq %rcx, %rax
jb 0x1d4c5
movq %rbx, %r12
imulq %r11, %r12
movl %r13d, %eax
testb $0x1, %al
jne 0x1d546
movl %r15d, %eax
shll $0x8, %eax
subl %r15d, %eax
movl $0xffffffff, %r9d       # imm = 0xFFFFFFFF
movl %edx, %ecx
shll %cl, %r9d
notl %r9d
xorl %ecx, %ecx
xorl %edx, %edx
divl %r9d
movl %r13d, %r9d
movb %al, (%rdi,%r12)
incq %rbx
cmpq %r8, %rbx
jne 0x1d4b3
jmp 0x1d79f
movb $-0x1, 0x1(%rdi,%r12)
movl 0x4(%r10), %edx
testl %r15d, %r15d
je 0x1d510
cmpl $0x0, 0x18(%r10)
je 0x1d510
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl %edx, %ecx
shll %cl, %eax
testl %edx, %edx
je 0x1d510
xorl 0x1c(%r10), %eax
cmpl $-0x1, %eax
jne 0x1d510
movb $0x0, 0x1(%rdi,%r12)
movl 0x4(%r10), %edx
jmp 0x1d510
testq %r8, %r8
je 0x1d79f
movl %edx, %edx
cmpq $0x1, %rdx
movq %rdx, %r11
adcq $0x0, %r11
xorl %ebx, %ebx
movq %rdi, %r14
testb $0x1, %r9b
je 0x1d5ab
movq %rbx, %rcx
imulq %rdx, %rcx
movb $-0x1, 0x3(%rdi,%rcx)
movzbl (%rsi,%rbx), %ecx
cmpq %rcx, 0x10(%r10)
jbe 0x1d79a
cmpl $0x8, %eax
jb 0x1d5dd
xorl %ecx, %ecx
movzbl (%rsi,%rbx), %r15d
shlq $0x2, %r15
addq 0x8(%r10), %r15
movb (%rcx,%r15), %r15b
movb %r15b, (%r14,%rcx)
incq %rcx
cmpq %rcx, %r11
jne 0x1d5c0
incq %rbx
addq %rdx, %r14
xorl %ecx, %ecx
cmpq %r8, %rbx
jne 0x1d599
jmp 0x1d79f
testq %r8, %r8
je 0x1d79f
movl %edx, %eax
xorl %edx, %edx
movq %rdi, %r11
movq %rsi, %rbx
movq %rdx, %rcx
imulq %rax, %rcx
testb $0x1, %r9b
je 0x1d614
movb $-0x1, 0x3(%rdi,%rcx)
leaq (%rdx,%rdx,2), %r14
xorl %r15d, %r15d
movb (%rbx,%r15), %r12b
movb %r12b, (%r11,%r15)
incq %r15
cmpq $0x3, %r15
jne 0x1d61b
testb $0x1, %r9b
je 0x1d661
cmpl $0x1, 0x18(%r10)
jne 0x1d661
movzbl (%rsi,%r14), %r15d
cmpl %r15d, 0x1c(%r10)
jne 0x1d661
movzbl 0x1(%rsi,%r14), %r15d
cmpl %r15d, 0x20(%r10)
jne 0x1d661
movzbl 0x2(%rsi,%r14), %r14d
cmpl %r14d, 0x24(%r10)
jne 0x1d661
movb $0x0, 0x3(%rdi,%rcx)
incq %rdx
addq $0x3, %rbx
addq %rax, %r11
xorl %ecx, %ecx
cmpq %r8, %rdx
jne 0x1d602
jmp 0x1d79f
testq %r8, %r8
je 0x1d79f
movl %edx, %eax
addq $0x3, %rdi
xorl %edx, %edx
movb (%rsi,%rdx,2), %cl
movb %cl, -0x1(%rdi)
movb %cl, -0x2(%rdi)
movb %cl, -0x3(%rdi)
testb $0x1, %r9b
je 0x1d6a0
movb 0x1(%rsi,%rdx,2), %cl
movb %cl, (%rdi)
incq %rdx
addq %rax, %rdi
xorl %ecx, %ecx
cmpq %rdx, %r8
jne 0x1d688
jmp 0x1d79f
testq %r8, %r8
je 0x1d79f
movl %edx, %edx
cmpq $0x1, %rdx
movq %rdx, %r9
adcq $0x0, %r9
xorl %r10d, %r10d
cmpl $0x8, %eax
jb 0x1d6e2
xorl %ecx, %ecx
movb (%rsi,%rcx), %r11b
movb %r11b, (%rdi,%rcx)
incq %rcx
cmpq %rcx, %r9
jne 0x1d6d2
incq %r10
addq $0x4, %rsi
addq %rdx, %rdi
xorl %ecx, %ecx
cmpq %r8, %r10
jne 0x1d6cb
jmp 0x1d79f
movl $0x2f, %ecx
jmp 0x1d79f
testq %r8, %r8
je 0x1d796
incq %rdi
movl %edx, %eax
xorl %edx, %edx
testb $0x1, %r9b
jne 0x1d720
movb (%rsi,%rdx), %cl
movb %cl, -0x1(%rdi)
jmp 0x1d73a
movb $-0x1, (%rdi)
movzbl (%rsi,%rdx), %ecx
movb %cl, -0x1(%rdi)
cmpl $0x0, 0x18(%r10)
je 0x1d73a
cmpl %ecx, 0x1c(%r10)
jne 0x1d73a
movb $0x0, (%rdi)
incq %rdx
addq %rax, %rdi
xorl %ecx, %ecx
cmpq %rdx, %r8
jne 0x1d712
jmp 0x1d79f
testq %r8, %r8
je 0x1d796
incq %rdi
movl %edx, %eax
xorl %edx, %edx
testb $0x1, %r9b
jne 0x1d763
movb (%rsi,%rdx,2), %cl
movb %cl, -0x1(%rdi)
jmp 0x1d787
movb $-0x1, (%rdi)
movb (%rsi,%rdx,2), %cl
movb %cl, -0x1(%rdi)
cmpl $0x0, 0x18(%r10)
je 0x1d787
movzwl (%rsi,%rdx), %ecx
rolw $0x8, %cx
movzwl %cx, %ecx
cmpl 0x1c(%r10), %ecx
jne 0x1d787
movb $0x0, (%rdi)
incq %rdx
addq %rax, %rdi
xorl %ecx, %ecx
cmpq %rdx, %r8
jne 0x1d755
jmp 0x1d79f
xorl %ecx, %ecx
jmp 0x1d79f
movl $0x2e, %ecx
movl %ecx, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq