// File: /workspace/github_cpp_makefile_star2_O2/lvandeve[P]lodepng/lodepng_unittest.cpp
// Function: testCustomZlibCompress2()
void testCustomZlibCompress2() {
  std::cout << "testCustomZlibCompress2" << std::endl;
  Image image;
  generateTestImage(image, 5, 5, LCT_RGBA, 8);

  std::vector<unsigned char> encoded;

  lodepng::State state;
  state.encoder.zlibsettings.custom_zlib = lodepng_zlib_compress;

  unsigned error = lodepng::encode(encoded, image.data, image.width, image.height,
                                   state);
  ASSERT_NO_PNG_ERROR(error);

  std::vector<unsigned char> decoded;
  unsigned w, h;
  state.decoder.zlibsettings.ignore_adler32 = 0;
  state.decoder.ignore_crc = 0;
  error = lodepng::decode(decoded, w, h, state, encoded);
  ASSERT_NO_PNG_ERROR(error);
  ASSERT_EQUALS(5, w);
  ASSERT_EQUALS(5, h);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x3d8, %rsp            # imm = 0x3D8
movq 0x7b1ca(%rip), %rdi     # 0xa2fd8
leaq 0x397e0(%rip), %rsi     # 0x615f5
callq 0x21f0
movq %rax, %rdi
callq 0x2100
xorps %xmm0, %xmm0
leaq 0x130(%rsp), %rdi
movaps %xmm0, (%rdi)
andq $0x0, 0x10(%rdi)
pushq $0x5
popq %rdx
pushq $0x6
popq %rcx
pushq $0x8
popq %r8
movl %edx, %esi
callq 0x138c7
xorps %xmm0, %xmm0
movaps %xmm0, 0xb0(%rsp)
andq $0x0, 0xc0(%rsp)
leaq 0x158(%rsp), %rdi
callq 0xb84c
leaq -0x23b59(%rip), %rax    # 0x4315
leaq 0x158(%rsp), %r8
movq %rax, 0x68(%r8)
leaq 0x130(%rsp), %rsi
movl 0x18(%rsi), %edx
movl 0x1c(%rsi), %ecx
leaq 0xb0(%rsp), %rdi
callq 0xbbcf
movl %eax, %ebx
leaq 0x3833f(%rip), %rsi     # 0x601dd
leaq 0x70(%rsp), %rdi
leaq 0xd0(%rsp), %rdx
callq 0x20c0
leaq 0x39756(%rip), %rdx     # 0x6160d
leaq 0x8(%rsp), %rdi
leaq 0x70(%rsp), %rsi
callq 0x5a5df
leaq 0x396f9(%rip), %rsi     # 0x615c6
leaq 0x90(%rsp), %rdi
leaq 0xf0(%rsp), %rdx
callq 0x20c0
movq 0x98(%rsp), %r14
testq %r14, %r14
je 0x27f23
leaq 0x396d0(%rip), %rsi     # 0x615c6
leaq 0x110(%rsp), %rdi
leaq 0x7(%rsp), %rdx
callq 0x20c0
leaq 0x3b896(%rip), %rsi     # 0x637a5
leaq 0x50(%rsp), %rdi
leaq 0x110(%rsp), %rdx
callq 0x5a8d9
jmp 0x27f3c
leaq 0x3969c(%rip), %rsi     # 0x615c6
leaq 0x50(%rsp), %rdi
leaq 0x110(%rsp), %rdx
callq 0x20c0
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
leaq 0x50(%rsp), %rdx
callq 0x5a61f
leaq 0x28(%rsp), %rsi
movl %ebx, %edi
callq 0x13352
leaq 0x28(%rsp), %rdi
callq 0x2270
leaq 0x50(%rsp), %rdi
callq 0x2270
testq %r14, %r14
je 0x27f82
leaq 0x110(%rsp), %rdi
callq 0x2270
leaq 0x90(%rsp), %rdi
callq 0x2270
leaq 0x8(%rsp), %rdi
callq 0x2270
leaq 0x70(%rsp), %rdi
callq 0x2270
xorps %xmm0, %xmm0
leaq 0xf0(%rsp), %rdi
andq $0x0, 0x10(%rdi)
leaq 0x158(%rsp), %rcx
andl $0x0, (%rcx)
movaps %xmm0, (%rdi)
andl $0x0, 0x28(%rcx)
leaq 0x4c(%rsp), %rsi
leaq 0x48(%rsp), %rdx
leaq 0xb0(%rsp), %r8
callq 0xb9ef
movl %eax, %ebx
leaq 0x381f8(%rip), %rsi     # 0x601dd
leaq 0x70(%rsp), %rdi
leaq 0x4(%rsp), %rdx
callq 0x20c0
leaq 0x39617(%rip), %rdx     # 0x61612
leaq 0x8(%rsp), %rdi
leaq 0x70(%rsp), %rsi
callq 0x5a5df
leaq 0x395b5(%rip), %rsi     # 0x615c6
leaq 0x90(%rsp), %rdi
leaq 0x6(%rsp), %rdx
callq 0x20c0
movq 0x98(%rsp), %r14
testq %r14, %r14
je 0x28064
leaq 0x3958f(%rip), %rsi     # 0x615c6
leaq 0xd0(%rsp), %rdi
leaq 0x5(%rsp), %rdx
callq 0x20c0
leaq 0x3b755(%rip), %rsi     # 0x637a5
leaq 0x50(%rsp), %rdi
leaq 0xd0(%rsp), %rdx
callq 0x5a8d9
jmp 0x2807d
leaq 0x3955b(%rip), %rsi     # 0x615c6
leaq 0x50(%rsp), %rdi
leaq 0xd0(%rsp), %rdx
callq 0x20c0
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
leaq 0x50(%rsp), %rdx
callq 0x5a61f
leaq 0x28(%rsp), %rsi
movl %ebx, %edi
callq 0x13352
leaq 0x28(%rsp), %rdi
callq 0x2270
leaq 0x50(%rsp), %rdi
callq 0x2270
testq %r14, %r14
je 0x280c3
leaq 0xd0(%rsp), %rdi
callq 0x2270
leaq 0x90(%rsp), %rdi
callq 0x2270
leaq 0x8(%rsp), %rdi
callq 0x2270
leaq 0x70(%rsp), %rdi
callq 0x2270
cmpl $0x5, 0x4c(%rsp)
jne 0x28135
cmpl $0x5, 0x48(%rsp)
jne 0x28285
leaq 0xf0(%rsp), %rdi
callq 0xea7c
leaq 0x158(%rsp), %rdi
callq 0xb874
leaq 0xb0(%rsp), %rdi
callq 0xea7c
leaq 0x130(%rsp), %rdi
callq 0xea7c
addq $0x3d8, %rsp            # imm = 0x3D8
popq %rbx
popq %r14
retq
leaq 0x380a1(%rip), %rsi     # 0x601dd
leaq 0x90(%rsp), %rdi
leaq 0x4(%rsp), %rdx
callq 0x20c0
leaq 0x394c2(%rip), %rdx     # 0x61617
leaq 0x50(%rsp), %rdi
leaq 0x90(%rsp), %rsi
callq 0x5a5df
leaq 0x3b637(%rip), %rdx     # 0x637a5
leaq 0x70(%rsp), %rdi
leaq 0x50(%rsp), %rsi
callq 0x5a5df
leaq 0x3809f(%rip), %rdx     # 0x60223
leaq 0x8(%rsp), %rdi
leaq 0x70(%rsp), %rsi
callq 0x5a5df
leaq 0x3808b(%rip), %rdx     # 0x60225
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x5a5df
movq 0x7ae28(%rip), %rdi     # 0xa2fd8
leaq 0x28(%rsp), %rsi
callq 0x21d0
leaq 0x28(%rsp), %rdi
callq 0x2270
leaq 0x8(%rsp), %rdi
callq 0x2270
leaq 0x70(%rsp), %rdi
callq 0x2270
leaq 0x50(%rsp), %rdi
callq 0x2270
leaq 0x90(%rsp), %rdi
callq 0x2270
movq 0x7ade2(%rip), %rdi     # 0xa2fd8
leaq 0x60d10(%rip), %rsi     # 0x88f0d
callq 0x21f0
movq %rax, %rbx
leaq 0x70(%rsp), %rsi
movl $0x5, (%rsi)
leaq 0x28(%rsp), %rdi
callq 0x5aaac
leaq 0x28(%rsp), %rsi
movq %rbx, %rdi
callq 0x21d0
leaq 0x3800f(%rip), %rsi     # 0x6023d
movq %rax, %rdi
callq 0x21f0
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
leaq 0x4c(%rsp), %rsi
callq 0x5a957
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x21d0
leaq 0x37ec8(%rip), %rsi     # 0x60124
movq %rax, %rdi
callq 0x21f0
movq %rax, %rdi
callq 0x2100
leaq 0x8(%rsp), %rdi
callq 0x2270
leaq 0x28(%rsp), %rdi
callq 0x2270
jmp 0x283d0
leaq 0x37f51(%rip), %rsi     # 0x601dd
leaq 0x90(%rsp), %rdi
leaq 0x4(%rsp), %rdx
callq 0x20c0
leaq 0x39377(%rip), %rdx     # 0x6161c
leaq 0x50(%rsp), %rdi
leaq 0x90(%rsp), %rsi
callq 0x5a5df
leaq 0x3b4e7(%rip), %rdx     # 0x637a5
leaq 0x70(%rsp), %rdi
leaq 0x50(%rsp), %rsi
callq 0x5a5df
leaq 0x37f7f(%rip), %rdx     # 0x60253
leaq 0x8(%rsp), %rdi
leaq 0x70(%rsp), %rsi
callq 0x5a5df
leaq 0x37f3b(%rip), %rdx     # 0x60225
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x5a5df
movq 0x7acd8(%rip), %rdi     # 0xa2fd8
leaq 0x28(%rsp), %rsi
callq 0x21d0
leaq 0x28(%rsp), %rdi
callq 0x2270
leaq 0x8(%rsp), %rdi
callq 0x2270
leaq 0x70(%rsp), %rdi
callq 0x2270
leaq 0x50(%rsp), %rdi
callq 0x2270
leaq 0x90(%rsp), %rdi
callq 0x2270
movq 0x7ac92(%rip), %rdi     # 0xa2fd8
leaq 0x60bc0(%rip), %rsi     # 0x88f0d
callq 0x21f0
movq %rax, %rbx
leaq 0x70(%rsp), %rsi
movl $0x5, (%rsi)
leaq 0x28(%rsp), %rdi
callq 0x5aaac
leaq 0x28(%rsp), %rsi
movq %rbx, %rdi
callq 0x21d0
leaq 0x37ebf(%rip), %rsi     # 0x6023d
movq %rax, %rdi
callq 0x21f0
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
leaq 0x48(%rsp), %rsi
callq 0x5a957
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x21d0
leaq 0x37d78(%rip), %rsi     # 0x60124
movq %rax, %rdi
callq 0x21f0
movq %rax, %rdi
callq 0x2100
leaq 0x8(%rsp), %rdi
callq 0x2270
leaq 0x28(%rsp), %rdi
callq 0x2270
callq 0x13280
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x2270
jmp 0x283fa
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x2270
jmp 0x2840c
jmp 0x283f7
jmp 0x28409
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x2270
jmp 0x28579
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x2270
jmp 0x28579
jmp 0x2852a
jmp 0x2852a
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x2270
jmp 0x28446
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x2270
jmp 0x28455
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x2270
jmp 0x28464
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x2270
jmp 0x28473
movq %rax, %rbx
leaq 0x70(%rsp), %rdi
callq 0x2270
jmp 0x28482
movq %rax, %rbx
leaq 0x70(%rsp), %rdi
callq 0x2270
jmp 0x28491
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x2270
jmp 0x284a0
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x2270
jmp 0x284b5
movq %rax, %rbx
leaq 0x90(%rsp), %rdi
callq 0x2270
jmp 0x28579
movq %rax, %rbx
leaq 0x90(%rsp), %rdi
callq 0x2270
jmp 0x28579
jmp 0x2851d
jmp 0x28522
jmp 0x2852a
jmp 0x2852a
movq %rax, %rbx
jmp 0x2854b
movq %rax, %rbx
jmp 0x285ae
jmp 0x28513
jmp 0x2858d
movq %rax, %rbx
jmp 0x28546
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x2270
jmp 0x2853c
movq %rax, %rbx
jmp 0x285a9
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x2270
jmp 0x2859f
jmp 0x2858d
movq %rax, %rbx
jmp 0x285f6
jmp 0x2852a
movq %rax, %rbx
jmp 0x28558
movq %rax, %rbx
jmp 0x285bb
movq %rax, %rbx
jmp 0x28579
movq %rax, %rbx
jmp 0x2856f
movq %rax, %rbx
jmp 0x28565
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x2270
testq %r14, %r14
je 0x28558
leaq 0xd0(%rsp), %rdi
callq 0x2270
leaq 0x90(%rsp), %rdi
callq 0x2270
leaq 0x8(%rsp), %rdi
callq 0x2270
leaq 0x70(%rsp), %rdi
callq 0x2270
leaq 0xf0(%rsp), %rdi
callq 0xea7c
jmp 0x285dc
movq %rax, %rbx
jmp 0x285e9
movq %rax, %rbx
jmp 0x285dc
movq %rax, %rbx
jmp 0x285d2
movq %rax, %rbx
jmp 0x285c8
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0x2270
testq %r14, %r14
je 0x285bb
leaq 0x110(%rsp), %rdi
callq 0x2270
leaq 0x90(%rsp), %rdi
callq 0x2270
leaq 0x8(%rsp), %rdi
callq 0x2270
leaq 0x70(%rsp), %rdi
callq 0x2270
leaq 0x158(%rsp), %rdi
callq 0xb874
leaq 0xb0(%rsp), %rdi
callq 0xea7c
leaq 0x130(%rsp), %rdi
callq 0xea7c
movq %rbx, %rdi
callq 0x2380
movq %rax, %rdi
callq 0xe6cc